Skip to content

Mapping of umlauts broken #50

@qqilihq

Description

@qqilihq

Hi all,

previous versions of Limax mapped German umlauts to the proper counterpart (e.g. ü will become ue). With the change in #44 and 4.0 unfortunately this breaks, and ü will now be mapped to a simple u which would be considered “less correct” in German.

Also, trying to fix it via a custom mapping will not help, as the _.deburr replacement happens without considering the given mappings. Our current workaround replaces them before applying limax:

  const fixedMapping = {
    ä: 'ae',
    Ä: 'Ae',
    ö: 'oe',
    Ö: 'Oe',
    ü: 'ue',
    Ü: 'Ue'
  };
  let fixedInput = input;
  for (const mapping of Object.entries(fixedMapping)) {
    fixedInput = fixedInput.replaceAll(mapping[0], mapping[1]);
  }

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions