Skip to content

refactor(Select): Design tokens

Jeremy Elder requested to merge jeldergl-refactor-select into main

What does this MR do?

  • Update GlSelect to use design tokens.
  • Modify component output to reliably use a custom chevron icon that also works in forced-colors mode.

Related to exploratory work in !4472 (closed).

Screenshots or screen recordings

Before/After:

  • Rest
  • Rest dark
  • Disabled
  • Disabled dark
  • forced-colors
  • forced-colors disabled
Before After Notes
CleanShot_2024-08-12_at_14.05.26_2x CleanShot_2024-08-12_at_14.02.03_2x Chevron color matches text
CleanShot_2024-08-12_at_14.05.39_2x CleanShot_2024-08-12_at_14.02.31_2x Matches other form elements in dark mode
CleanShot_2024-08-12_at_14.05.54_2x CleanShot_2024-08-12_at_14.02.56_2x Chevron color matches text
CleanShot_2024-08-12_at_14.06.09_2x CleanShot_2024-08-12_at_14.03.22_2x Matches other form elements in dark mode
CleanShot_2024-08-12_at_14.06.58_2x CleanShot_2024-08-12_at_14.03.57_2x Chevron matches text (CanvasText)
CleanShot_2024-08-12_at_14.07.15_2x CleanShot_2024-08-12_at_14.04.33_2x Chevron matches text (GrayText)

Integration merge requests

Does this MR meet the acceptance criteria?

This checklist encourages the authors, reviewers, and maintainers of merge requests (MRs) to confirm changes were analyzed for conformity with the project's guidelines, security and accessibility.

Toggle the acceptance checklist

Conformity

  • Code review guidelines.
  • GitLab UI's contributing guidelines.
  • If it changes a Pajamas-compliant component's look & feel, the MR has been reviewed by a UX designer.
  • If it changes GitLab UI's documentation guidelines, the MR has been reviewed by a Technical Writer.
  • If the MR changes a component's API, integration MR(s) have been opened (see integration merge requests above).
  • Added the ~"component:*" label(s) if applicable.

Accessibility

If this MR adds or modifies a component, take a few moments to review the following:

  • All actions and functionality can be done with a keyboard.
  • Links, buttons, and controls have a visible focus state.
  • All content is presented in text or with a text equivalent. For example, alt text for SVG, or aria-label for icons that have meaning or perform actions.
  • Changes in a component’s state are announced by a screen reader. For example, changing aria-expanded="false" to aria-expanded="true" when an accordion is expanded.
  • Color combinations have sufficient contrast.
Edited by Jeremy Elder

Merge request reports