surveyjs / custom-widgets

The collection of custom widgets for SurveyJS: Survey Library and Survey Creator :package:
https://surveyjs.io
MIT License
79 stars 78 forks source link

jQuery Inputmask - A Numeric Placeholder is not used by a Decimal input mask #329

Closed JaneSjs closed 1 year ago

JaneSjs commented 1 year ago

Original issue: T11864 - jQuery Inputmask - Do not diplay a decimal zero 0 placeholder mask when an input box receives focus.


Task: remove a numeric placeholder for a decimal input mask.

It was suggested at the Inputmask community (https://github.com/RobinHerbots/Inputmask/issues/2670) to use a placeholder option.

const inputmask = SurveyCore.CustomWidgetCollection.Instance.getCustomWidgetByName(
  "maskedit"
);

inputmask.widgetJson.numericPlaceholder = "";

This works for currency fields: image

However, this property is not applied to decimal fields. image

Expected behavior: an empty string placeholder is applied to decimal fields. image