Questions tagged [input-mask]

A string expression, defined by a developer, that governs what a user is allowed to enter in as input in a text box.

An input mask is in general a set of rules, that entered data must conform to, mainly used for the purposes of data integrity by preventing transcription errors. The syntax of this string expression differs from implementation to implementation, but the fundamental input types are all supported.

Some frequent uses of input masks include entry of telephone numbers, ZIP or postal codes, times and dates.

229 questions
3
votes
2 answers

Qt QLineEdit Input Validation

How would one set an input validator on a QLineEdit such that it restricts it to a valid IP address? i.e. x.x.x.x where x must be between 0 and 255.and x can not be empty
3
votes
1 answer

AngularJS: inputMask not working in angularJS table

I have two date fields within a ng-repeat table, the code looks like this:
Lance Shi
  • 1,127
  • 3
  • 13
  • 28
3
votes
1 answer

Primefaces inputMask server side validation

When using a component we specify how to validate it with a required, maxlength or a validator and those validation are enforced on the server which is great. When using Primefaces inputMask we can specify a mask. The mask lead us to think that…
ForguesR
  • 3,558
  • 1
  • 17
  • 39
3
votes
2 answers

javascript input masking for numeric and english keyboard only

I have an input field that has a masking of "999999999". It works perfectly fine on English keyboard but I am also able to enter Japanese/Chinese characters into it (breaking the masking). Is there a way to restrict the input to english keyboard…
night mare
  • 129
  • 1
  • 4
  • 14
2
votes
1 answer

Input mask for Time that fills from right to left and optional 3 digits for hours (angularjs)

I'm having some trouble finding what I need. In my angularjs project, we're using angular-input-mask for the inputs. What I need is a mask for time like this: 000:00 But the first digit must be optional, and that's why I need the mask to fill from…
2
votes
1 answer

PrimeNg InputMask onBlur event doesn't update model properly

I am working on a custom component which is supposed to be used as a "time only" input. For that I am using the primeNg inputMask with the mask "99:99". Then it should be additionally filtered if the numbers are higher than 23:59. The way I am doing…
MrJami
  • 685
  • 4
  • 16
2
votes
1 answer

Using array in Javascript

I'm using a jQuery plugin to build an input mask, but my code is too large. The user must not be able to start the phone number with zero. The error message has to disappear when he types the right number. How can I optimize this code? Can I use an…
2
votes
0 answers

Maximum update depth exceeded when updating input

I have made currency input mask: let resultArr = value.split("").map((x) => { return !isNaN(+x) && x !== " " ? "n" : ""; }); resultArr = resultArr.join("").replace(/\B(?=([n]{3})+(?![n]))/g, ","); //1234 => nnnn, 1234 =>…
Pavel
  • 37
  • 1
  • 8
2
votes
0 answers

Bug using Japanese IME in react-input-mask

When I input full-width characters, the existing input are pushing to the right hand side. See the bug here: https://i.stack.imgur.com/sEkms.jpg How can I prevent this to happen since it's working when using normal numeric characters. …
Ayaka
  • 197
  • 1
  • 13
2
votes
1 answer

how to mask input IP Address in React

I need IP Address mask input because ip address can be 999.99.999.99 or 99.9.99.9 react-input-mask doesn't support different length.What do you suggest?
aslibahar
  • 23
  • 1
  • 4
2
votes
1 answer

Store unmasked InputMask value in Formik and Material-UI

Alright, so I have this implementation of Input Mask over a custom styled implementation of Material UI's text field, inside a Formik form:
Omar Hussein
  • 1,057
  • 2
  • 13
  • 31
2
votes
1 answer

Using react input mask (InputMask) with formik

My question is somewhat similar to this SO question but I cannot get the value (just digits). I have the following formikField (
Maddy
  • 2,025
  • 5
  • 26
  • 59
2
votes
2 answers

How to use pipe in input text using ngModel Angular

I had dropdown component (list of credit card) that bind dropdown value on input, Using ngModel I managed to bind dropdown value on input, then I need to display credit card number on input field that looks like bullet special character: 4444 ••••…
coder
  • 99
  • 1
  • 12
2
votes
0 answers

How to disallow to input minus sign(-) in jQuery Inputmask?

this is my first entry in here, hope that I won't fail some rules. I have an input field in HTML file that takes Port numbers from 0 to 65535 which is defined as min, max. And I have a jQuery Input mask in JS file that is supposed to allow only…
Orcun
  • 21
  • 4
2
votes
1 answer

How to dynamically mask a text field with swift

I'm trying to use a dynamic mask for a text field according to the number of characters entered. I tried to use VMaskTextField, AKMaskField and now I'm using InputMask (https://github.com/RedMadRobot/input-mask-ios) and I was only able to make one…
1 2
3
15 16