Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add extra tracking modifier for inputs #1222

Closed
wants to merge 2 commits into from

Conversation

36degrees
Copy link
Contributor

This adds a --extra-tracking modifier for inputs which increases the tracking, and turns on tabular numbers.

The idea is that this modifier would be used for inputs asking for e.g. reference or phone numbers, where the user would be checking back one character at a time.

This was inspired by alphagov/notifications-admin#1545

Without modifier

localhost_3000_components_input_extra-tracking-reference_preview 1

With modifier

localhost_3000_components_input_extra-tracking-reference_preview 2

Questions…

  • is this useful?
  • is there a better name than --extra-tracking?
  • is it an issue that the width modifiers behave differently, because 1ex has a different width?

@NickColley
Copy link
Contributor

NickColley commented Feb 26, 2019

Is this useful?

We could raise this on the backlog as a suggestion, since this could be quick for service teams to implement and try out?

@quis
Copy link
Member

quis commented Mar 5, 2019

Thanks for picking this up, I’d be really happy to see it go into the Design System. Couple of thoughts:

Naming things

Would --extra-letter-spacing or --more-letter-spacing be better names? Although ‘tracking’ means the same thing (in a typography context) it is ambiguous. Letter spacing is also a commonly-used term; letter-spacing is the name of the CSS property.

Spaces

Something that came up discussing this with @tombye

Should there be/is there some associated guidance about being forgiving about spaces being typed in these kinds of field? There’s some discussion on the phone numbers issue in the backlog already, but it feels like a wider thing than that.

People often use spaces to ‘chunk’ long numbers (phone numbers, credit card numbers, licence numbers) to make them easier to transcribe. Services should be forgiving of this and not respond with validation errors.

@timpaul timpaul force-pushed the add-input-reference-modifier branch 2 times, most recently from 9272deb to 048d555 Compare March 11, 2019 15:42
@36degrees
Copy link
Contributor Author

Closing this for now as it's been deprioritised.

@36degrees 36degrees closed this Apr 25, 2019
@NickColley NickColley deleted the add-input-reference-modifier branch December 9, 2019 14:57
@quis
Copy link
Member

quis commented Jul 14, 2020

Noticed a nice example of this from Amazon the other day:

IMG_1169

@frankieroberto
Copy link
Contributor

@36degrees @timpaul any chance of resurrecting this? I think it could be useful for a number of patterns asking for numerical codes, including security (2FA) codes.

@36degrees 36degrees added the awaiting triage Needs triaging by team label Feb 19, 2021
@colinrotherham colinrotherham removed the awaiting triage Needs triaging by team label Jan 18, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

7 participants