Masked IBAN field
An IBAN input grouped by 4 as you type, checking country, length and the mod-97 key, then shown masked once saved.
- Tailwind
- React
- CSS
- WordPress
Description
A wrong IBAN means a transfer rejected a few days later. This field formats the IBAN while typing or pasting (uppercase, groups of 4, dashes and spaces removed) without making the caret jump, announces progress (“France: 12 of 27 characters”) in an aria-live region, then checks on submit the country code, the country-specific length and the ISO 13616 mod-97 check digits, computed in chunks to stay exact without BigInt. Messages say what to fix: unsupported country, missing characters or a typo. Once saved, the IBAN is only partly shown (BE68 •••• •••• 7034) and the field becomes read-only; going back to it lets you type a new one. The list of accepted countries is one object at the top of the script. aria-invalid and linked messages, focus on the first error, monospace font to proofread the number, AA contrast in light and dark mode, no horizontal scrolling from 360 px. Example: the customer area of a health insurer.
Code
Loading the code…
The code of this component in
Archive contents
champ-iban-masque-html-tailwind.zip3 files · 6 Ko
- index.html8 Ko
- README.md4 Ko
- LICENSE.md1 Ko
Tags
Updated on December 2, 2026.
Reviews
No reviews yet.
In the same spirit

A recruitment form for small businesses: target position, introduction, CV checked in the browser and GDPR consent, with inline errors.
- Tailwind
- React
- CSS
- WordPress

A quote request form whose labels, hints and error messages are full French sentences, still readable at 320 px: nothing overflows, nothing is cut off, and each error is tied to its field.
- Tailwind
- React
- CSS
- WordPress

Visitors pick a package and tick options: the pre-tax total, VAT and total including tax update live, and the summary is sent with the contact form.
- Tailwind
- React
- CSS
- WordPress

A short NPS survey: a 0 to 10 score as radio buttons, then a follow-up question adapted to whether the customer is a detractor, passive or promoter.
- Tailwind
- React
- CSS
- WordPress