Skip to content

Commit

Permalink
Update EuiToken colors
Browse files Browse the repository at this point in the history
  • Loading branch information
ryankeairns committed Dec 18, 2024
1 parent e136ce3 commit 6044cef
Show file tree
Hide file tree
Showing 2 changed files with 27 additions and 27 deletions.
6 changes: 3 additions & 3 deletions packages/eui/src/components/token/token.styles.ts
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ const getTokenColor = (
: euiTheme.colors.darkShade;

const backgroundLightColor = isDarkMode
? shade(iconColor, 0.7)
? shade(iconColor, 0.9)
: tint(iconColor, 0.9);

const getIconVisColor = (
Expand All @@ -68,12 +68,12 @@ const getTokenColor = (
const lightColor = hasVisColorAdjustment
? makeHighContrastColor(iconColor)(backgroundLightColor)
: isVizColor
? getIconVisColor(euiTheme, color)
? shade(getIconVisColor(euiTheme, color), .3)
: iconColor;

const boxShadowColor = isDarkMode
? shade(iconColor, 0.6)
: tint(iconColor, 0.7);
: tint(iconColor, 0.2);

const darkColor = isColorDark(...chroma(backgroundDarkColor).rgb())
? euiTheme.colors.ghost
Expand Down
48 changes: 24 additions & 24 deletions packages/eui/src/components/token/token_map.ts
Original file line number Diff line number Diff line change
Expand Up @@ -310,24 +310,24 @@ export const TOKEN_MAP_BOREALIS: {
[mapType in EuiTokenMapType]: Omit<TokenProps, 'iconType'>;
} = {
tokenAlias: {
shape: 'circle',
color: 'euiColorVis1',
shape: 'square',
color: 'euiColorVis0',
},
tokenAnnotation: {
shape: 'square',
color: 'euiColorVis8',
},
tokenArray: {
shape: 'square',
color: 'euiColorVis3',
color: 'euiColorVis4',
},
tokenBinary: {
shape: 'square',
color: 'euiColorVis5',
color: 'euiColorVis6',
},
tokenBoolean: {
shape: 'square',
color: 'euiColorVis3',
color: 'euiColorVis4',
},
tokenClass: {
shape: 'circle',
Expand All @@ -343,27 +343,27 @@ export const TOKEN_MAP_BOREALIS: {
},
tokenDate: {
shape: 'square',
color: 'euiColorVis9',
color: 'euiColorVis8',
},
tokenDimension: {
shape: 'square',
color: 'euiColorVis2',
},
tokenElement: {
shape: 'square',
color: 'euiColorVis1',
color: 'euiColorVis0',
},
tokenEnum: {
shape: 'circle',
color: 'euiColorVis1',
color: 'euiColorVis0',
},
tokenEnumMember: {
shape: 'square',
color: 'euiColorVis3',
color: 'euiColorVis4',
},
tokenEvent: {
shape: 'circle',
color: 'euiColorVis5',
color: 'euiColorVis6',
},
tokenException: {
shape: 'circle',
Expand All @@ -379,7 +379,7 @@ export const TOKEN_MAP_BOREALIS: {
},
tokenFlattened: {
shape: 'square',
color: 'euiColorVis3',
color: 'euiColorVis4',
},
tokenFunction: {
shape: 'circle',
Expand All @@ -391,7 +391,7 @@ export const TOKEN_MAP_BOREALIS: {
},
tokenHistogram: {
shape: 'square',
color: 'euiColorVis9',
color: 'euiColorVis0',
},
tokenInterface: {
shape: 'circle',
Expand Down Expand Up @@ -427,7 +427,7 @@ export const TOKEN_MAP_BOREALIS: {
},
tokenModule: {
shape: 'square',
color: 'euiColorVis5',
color: 'euiColorVis6',
},
tokenNamespace: {
shape: 'square',
Expand All @@ -447,39 +447,39 @@ export const TOKEN_MAP_BOREALIS: {
},
tokenObject: {
shape: 'circle',
color: 'euiColorVis1',
color: 'euiColorVis0',
},
tokenOperator: {
shape: 'circle',
color: 'euiColorVis5',
color: 'euiColorVis6',
},
tokenPackage: {
shape: 'square',
color: 'euiColorVis0',
},
tokenParameter: {
shape: 'square',
color: 'euiColorVis5',
color: 'euiColorVis6',
},
tokenPercolator: {
shape: 'square',
color: 'euiColorVis9',
color: 'euiColorVis0',
},
tokenProperty: {
shape: 'circle',
color: 'euiColorVis4',
},
tokenRange: {
shape: 'circle',
color: 'euiColorVis5',
color: 'euiColorVis6',
},
tokenRankFeature: {
shape: 'square',
color: 'euiColorVis7',
color: 'euiColorVis8',
},
tokenRankFeatures: {
shape: 'square',
color: 'euiColorVis1',
color: 'euiColorVis0',
},
tokenRepo: {
shape: 'square',
Expand All @@ -495,7 +495,7 @@ export const TOKEN_MAP_BOREALIS: {
},
tokenShape: {
shape: 'circle',
color: 'euiColorVis7',
color: 'euiColorVis8',
},
tokenString: {
shape: 'square',
Expand All @@ -515,15 +515,15 @@ export const TOKEN_MAP_BOREALIS: {
},
tokenText: {
shape: 'square',
color: 'euiColorVis1',
color: 'euiColorVis0',
},
tokenTokenCount: {
shape: 'square',
color: 'euiColorVis5',
color: 'euiColorVis6',
},
tokenVariable: {
shape: 'circle',
color: 'euiColorVis3',
color: 'euiColorVis4',
},
tokenVectorDense: {
shape: 'square',
Expand Down

0 comments on commit 6044cef

Please sign in to comment.