[HDS-5541] UI: Align color and border-radius styles to HDS tokens #31583
+111
−111
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Description
If merged, this PR would update color and border-radius styles to reference HDS tokens. This is done in order to ensure greater alignment with HDS, and improve the flexibility of styles in Cloud UI to reflect any changes to HDS tokens.
The changes made should result in no visual changes. The values updated are a 1:1 match for values that were already present in HDS tokens.
Color
Any hard-coded color values have been updated to references HDS tokens instead. Additionally some instances of styles that already referenced HDS color tokens have been updated from referencing the core palette to referencing the semantic palette.
The semantic color tokens of the HDS token library are more agnostic, and embed meaning into color names, making it easier to select correct consistent values across applications. By relying on semantic tokens instead of the core palette, it will also be easier in the future to support potential efforts like theming, major style updates, etc.
There are semantic color groups for common styles such as
foreground
(typography color),surface
(background color), etc.Example update:
--token-color-palette-neutral-700
->--token-color-foreground-strong
If an instance of a core color palette token did not align to a semantic token, that style was left untouched. Ex: If
--token-color-palette-neutral-700
was being used for a background color it was left as is, sinceforeground
is specifically for typography colors.Core palette to semantic tokens map
Border Radius
The HDS token library also contains tokens for border-radius, and in this PR any hard-coded border-radius values that aligned to values present in the tokens have been updated.
Border radius tokens map
External Links
TODO only if you're a HashiCorp employee
backport/
label that matches the desired release branch.PCI review checklist
Examples of changes to security controls include using new access control methods, adding or removing logging pipelines, etc.