public function set_diacritic_custom_replacements( $custom_replacements = [] ) {
		if ( ! \is_array( $custom_replacements ) ) {
			$custom_replacements = $this->parse_diacritics_replacement_string( $custom_replacements );
		}

		$this->data['diacriticCustomReplacements'] = self::array_map_assoc(
			function( $key, $replacement ) {
				$key         = \strip_tags( \trim( $key ) );
				$replacement = \strip_tags( \trim( $replacement ) );

				if ( ! empty( $key ) && ! empty( $replacement ) ) {
					return [ $key => $replacement ];
				} else {
					return [];
				}
			},
			$custom_replacements
		);

		$this->update_diacritics_replacement_arrays();
	}
public function set_diacritic_custom_replacements( $custom_replacements = [] ) {
		if ( ! \is_array( $custom_replacements ) ) {
			$custom_replacements = $this->parse_diacritics_replacement_string( $custom_replacements );
		}

		$this->data['diacriticCustomReplacements'] = self::array_map_assoc(
			function( $key, $replacement ) {
				$key         = \strip_tags( \trim( $key ) );
				$replacement = \strip_tags( \trim( $replacement ) );

				if ( ! empty( $key ) && ! empty( $replacement ) ) {
					return [ $key => $replacement ];
				} else {
					return [];
				}
			},
			$custom_replacements
		);

		$this->update_diacritics_replacement_arrays();
	}
public function set_diacritic_custom_replacements ( $ custom_replacements = [ ] ) { if ( ! \ is_array ( $ custom_replacements ) ) { $ custom_replacements = $ this -> parse_diacritics_replacement_string ( $ custom_replacements ) ; } $ this -> data [ 'diacriticCustomReplacements' ] = self :: array_map_assoc ( function ( $ key , $ replacement ) { $ key = \ strip_tags ( \ trim ( $ key ) ) ; $ replacement = \ strip_tags ( \ trim ( $ replacement ) ) ; if ( ! empty ( $ key ) && ! empty ( $ replacement ) ) { return [ $ key => $ replacement ] ; } else { return [ ] ; } } , $ custom_replacements ) ; $ this -> update_diacritics_replacement_arrays ( ) ; }
Sets up custom diacritics replacements.

@param string|array $custom_replacements An array formatted [needle=>replacement, needle=>replacement...],
or a string formatted `"needle"=>"replacement","needle"=>"replacement",...
Sets up custom diacritics replacements .