RobinHerbots / Inputmask

Input Mask plugin
https://robinherbots.github.io/Inputmask/
MIT License
6.4k stars 2.17k forks source link

Euro symbol mask bug #1363

Open pavoleichler opened 8 years ago

pavoleichler commented 8 years ago

A tilde (~) character is displayed in the masked currency input, when you insert a euro symbol (€).

Set up a currency inputmask with a suffix ' €':

    $(this.ui.inputCurrency).each(function () {
        $(this).inputmask('currency', {
            digits: 0,
            allowMinus: false,
            suffix: ' €',
            groupSeparator: ' ',
            radixPoint: ',',
            prefix: '',
            rightAlign: false,
            removeMaskOnSubmit: true,
            max: $(this).data('max')
        });
    });

Now select the input, enter a few digits and then insert the € euro symbol (either by pressing Alt Gr + E on supported keyboards or by pasting it).

Instead of: 123 € the input now displays something like: 123~€

rruebner commented 7 years ago

Confirmed. But i think the problem is the space before the Euro symbol, you can see the problem with normal characters too, e. g. ' A'. I tried it without space '€' and it worked.