-
Notifications
You must be signed in to change notification settings - Fork 9
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
[Feature] Increases classification level options #12399
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good! I just found a couple more places needing tweaked.
apps/web/src/utils/nameUtils.tsx
Outdated
@@ -149,7 +149,7 @@ export const wrapAbbr = (text: ReactNode, intl: IntlShape, title?: string) => { | |||
} | |||
switch (stringifyText) { | |||
// Regex that matches all IT classifications with levels | |||
case /[IT]-0\d/.exec(stringifyText)?.input: | |||
case /[IT]-[0-9]\d/.exec(stringifyText)?.input: | |||
return ( | |||
<abbr title={intl.formatMessage(getAbbreviations("IT"))}> | |||
<span aria-label={splitAndJoin(stringifyText.replace("-0", ""))}> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is removing the colon in aria labels for single digit classifications but leaving it for double digit ones.
For example "IT-03" => "I T 3" as opposed to "IT-19" => "I T - 1 9".
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Created #12424 for possible related refactoring for the future. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You've gotten everything I can find! 👍
🤖 Resolves #12248.
👋 Introduction
This PR increases classification level options and accounts for the absence or presence of a leading zero in the levels.
🧪 Testing
make refresh-api; make seed-fresh; pnpm i; pnpm build:fresh