braid-design-system 32.9.2 → 32.10.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -1,5 +1,50 @@
1
1
  # braid-design-system
2
2
 
3
+ ## 32.10.0
4
+
5
+ ### Minor Changes
6
+
7
+ - **seekJobs:** Change link colour to neutral ([#1347](https://github.com/seek-oss/braid-design-system/pull/1347))
8
+
9
+ Changing the `foregroundColor` token for `link` on the `seekJobs` theme to align with neutral text.
10
+ Our different approach to using colour has seen links dialled back to compete less with other messaging and CTAs.
11
+
12
+ This affects the following usages across the system:
13
+
14
+ - `vars.foregroundColor.link`
15
+ - `Text` (using `tone="link"`)
16
+ - `TextLink` and (`TextLinkButton`)
17
+
18
+ ### Patch Changes
19
+
20
+ - **TextLink, TextLinkButton:** Underline regular links in non-legacy themes ([#1347](https://github.com/seek-oss/braid-design-system/pull/1347))
21
+
22
+ To improve affordance beyond primarily being colour, a `TextLink` (and `TextLinkButton`) will now always be underlined, in line with [best practice accessibility guidelines].
23
+
24
+ Given this has not been the case previously, this decision has been applied to non-legacy themes only, as such only affecting consumers of `seekJobs`, `docs` and `wireframe`.
25
+
26
+ [best practice accessibility guidelines]: https://webaim.org/techniques/hypertext/link_text#appearance
27
+
28
+ - **TextLink, TextLinkButton:** Apply themed focus outline ([#1347](https://github.com/seek-oss/braid-design-system/pull/1347))
29
+
30
+ Apply a focus outline using the relevant focus attributes from the theme, bringing `TextLink` (and `TextLinkButton`) into line with the focus treatment applied to rest of the system.
31
+
32
+ - **TextLink, TextLinkButton:** Reduce `weak` links to `regular` font weight ([#1347](https://github.com/seek-oss/braid-design-system/pull/1347))
33
+
34
+ The font weight of a `weak` link is now reduced to `regular` weight, reducing the link's visual prominence in addition to following the neutral text colour.
35
+
36
+ - **docs:** Lighten soft background tokens ([#1347](https://github.com/seek-oss/braid-design-system/pull/1347))
37
+
38
+ Lighten the `brandAccentSoft` and `formAccentSoft` background tokens for the `docs` theme.
39
+
40
+ - **Dialog, Drawer:** Adapt max height to available viewport space ([#1352](https://github.com/seek-oss/braid-design-system/pull/1352))
41
+
42
+ Make use of the new [dynamic viewport units] for applying a max height to modal elements such as `Dialog` and `Drawer`. These new units take into account dynamic browser toolbars that expand and contract as the user scrolls, ensuring the browser interface never obscures the web site content.
43
+
44
+ Fix also incorporates fallback for older browsers to use regular viewport units.
45
+
46
+ [Dynamic Viewport units]: https://web.dev/viewport-units/
47
+
3
48
  ## 32.9.2
4
49
 
5
50
  ### Patch Changes
@@ -2025,7 +2025,7 @@ const useLinkStyles = ({
2025
2025
  return clsx__default.default(
2026
2026
  styles_lib_components_TextLink_TextLink_css_cjs.base,
2027
2027
  linkStyles,
2028
- styles_lib_css_typography_css_cjs.fontWeight.medium,
2028
+ weight !== "weak" ? styles_lib_css_typography_css_cjs.fontWeight.medium : void 0,
2029
2029
  showVisited ? [
2030
2030
  styles_lib_components_TextLink_TextLink_css_cjs.visitedLightMode[backgroundLightness.lightMode],
2031
2031
  styles_lib_components_TextLink_TextLink_css_cjs.visitedDarkMode[backgroundLightness.darkMode]
@@ -2018,7 +2018,7 @@ const useLinkStyles = ({
2018
2018
  return clsx(
2019
2019
  base$3,
2020
2020
  linkStyles,
2021
- fontWeight.medium,
2021
+ weight !== "weak" ? fontWeight.medium : void 0,
2022
2022
  showVisited ? [
2023
2023
  visitedLightMode[backgroundLightness.lightMode],
2024
2024
  visitedDarkMode[backgroundLightness.darkMode]
package/dist/reset.d.ts CHANGED
@@ -2623,6 +2623,7 @@ declare const vars$1: {
2623
2623
  readonly weak: `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
2624
2624
  readonly regular: `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
2625
2625
  };
2626
+ readonly linkDecoration: `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
2626
2627
  readonly inlineFieldSize: {
2627
2628
  readonly standard: `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
2628
2629
  readonly small: `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
@@ -6,36 +6,28 @@ const styles_lib_themes_vars_css_cjs = require("../../themes/vars.css.cjs");
6
6
  fileScope.setFileScope("src/lib/components/TextLink/TextLink.css.ts?used", "braid-design-system");
7
7
  const textLinkVars = css.createThemeContract({
8
8
  color: null,
9
- colorHover: null,
10
- textDecoration: null,
11
- textDecorationHover: null
9
+ colorHover: null
12
10
  });
13
11
  const lightModeRegularLinkVars = css.assignVars(textLinkVars, {
14
12
  color: styles_lib_themes_vars_css_cjs.vars.foregroundColor.link,
15
- colorHover: styles_lib_themes_vars_css_cjs.vars.foregroundColor.linkHover,
16
- textDecoration: "none",
17
- textDecorationHover: "underline"
13
+ colorHover: styles_lib_themes_vars_css_cjs.vars.foregroundColor.linkHover
18
14
  });
19
15
  const darkModeRegularLinkVars = css.assignVars(textLinkVars, {
20
16
  color: styles_lib_themes_vars_css_cjs.vars.foregroundColor.linkLight,
21
- colorHover: styles_lib_themes_vars_css_cjs.vars.foregroundColor.linkLight,
22
- textDecoration: "none",
23
- textDecorationHover: "underline"
17
+ colorHover: styles_lib_themes_vars_css_cjs.vars.foregroundColor.linkLight
24
18
  });
25
19
  const weakLinkVars = css.assignVars(textLinkVars, {
26
20
  color: "inherit",
27
- colorHover: "inherit",
28
- textDecoration: "underline",
29
- textDecorationHover: "underline"
21
+ colorHover: "inherit"
30
22
  });
31
23
  const base = css.style({
32
24
  color: textLinkVars.color,
33
- textDecoration: textLinkVars.textDecoration,
34
- textDecorationThickness: "0.1em",
25
+ textDecoration: styles_lib_themes_vars_css_cjs.vars.linkDecoration,
26
+ textDecorationThickness: "0.08em",
35
27
  textUnderlineOffset: 3,
36
28
  ":hover": {
37
29
  color: textLinkVars.colorHover,
38
- textDecoration: textLinkVars.textDecorationHover,
30
+ textDecoration: "underline",
39
31
  /*
40
32
  Duplicating the thickness rule due to inconsistent support
41
33
  for shorthand properties of `text-decoration`. Without this,
@@ -45,14 +37,18 @@ const base = css.style({
45
37
  We also cannot use the long-form `text-decoration-line` due
46
38
  to browser support policy of Edge 16+.
47
39
  */
48
- textDecorationThickness: "0.1em"
40
+ textDecorationThickness: "0.08em"
49
41
  },
50
- ":focus": {
51
- color: textLinkVars.colorHover
42
+ ":focus-visible": {
43
+ color: textLinkVars.colorHover,
44
+ outline: `${styles_lib_themes_vars_css_cjs.vars.focusRingSize} solid ${styles_lib_themes_vars_css_cjs.vars.borderColor.focus}`,
45
+ outlineOffset: "0.2em",
46
+ borderRadius: styles_lib_themes_vars_css_cjs.vars.borderRadius.small
52
47
  }
53
48
  }, "base");
54
49
  const weakLink = css.style({
55
- vars: weakLinkVars
50
+ vars: weakLinkVars,
51
+ textDecoration: "underline"
56
52
  }, "weakLink");
57
53
  const regularLinkLightMode = css.styleVariants({
58
54
  light: {
@@ -5,36 +5,28 @@ import { vars } from "../../themes/vars.css.mjs";
5
5
  setFileScope("src/lib/components/TextLink/TextLink.css.ts?used", "braid-design-system");
6
6
  const textLinkVars = createThemeContract({
7
7
  color: null,
8
- colorHover: null,
9
- textDecoration: null,
10
- textDecorationHover: null
8
+ colorHover: null
11
9
  });
12
10
  const lightModeRegularLinkVars = assignVars(textLinkVars, {
13
11
  color: vars.foregroundColor.link,
14
- colorHover: vars.foregroundColor.linkHover,
15
- textDecoration: "none",
16
- textDecorationHover: "underline"
12
+ colorHover: vars.foregroundColor.linkHover
17
13
  });
18
14
  const darkModeRegularLinkVars = assignVars(textLinkVars, {
19
15
  color: vars.foregroundColor.linkLight,
20
- colorHover: vars.foregroundColor.linkLight,
21
- textDecoration: "none",
22
- textDecorationHover: "underline"
16
+ colorHover: vars.foregroundColor.linkLight
23
17
  });
24
18
  const weakLinkVars = assignVars(textLinkVars, {
25
19
  color: "inherit",
26
- colorHover: "inherit",
27
- textDecoration: "underline",
28
- textDecorationHover: "underline"
20
+ colorHover: "inherit"
29
21
  });
30
22
  const base = style({
31
23
  color: textLinkVars.color,
32
- textDecoration: textLinkVars.textDecoration,
33
- textDecorationThickness: "0.1em",
24
+ textDecoration: vars.linkDecoration,
25
+ textDecorationThickness: "0.08em",
34
26
  textUnderlineOffset: 3,
35
27
  ":hover": {
36
28
  color: textLinkVars.colorHover,
37
- textDecoration: textLinkVars.textDecorationHover,
29
+ textDecoration: "underline",
38
30
  /*
39
31
  Duplicating the thickness rule due to inconsistent support
40
32
  for shorthand properties of `text-decoration`. Without this,
@@ -44,14 +36,18 @@ const base = style({
44
36
  We also cannot use the long-form `text-decoration-line` due
45
37
  to browser support policy of Edge 16+.
46
38
  */
47
- textDecorationThickness: "0.1em"
39
+ textDecorationThickness: "0.08em"
48
40
  },
49
- ":focus": {
50
- color: textLinkVars.colorHover
41
+ ":focus-visible": {
42
+ color: textLinkVars.colorHover,
43
+ outline: `${vars.focusRingSize} solid ${vars.borderColor.focus}`,
44
+ outlineOffset: "0.2em",
45
+ borderRadius: vars.borderRadius.small
51
46
  }
52
47
  }, "base");
53
48
  const weakLink = style({
54
- vars: weakLinkVars
49
+ vars: weakLinkVars,
50
+ textDecoration: "underline"
55
51
  }, "weakLink");
56
52
  const regularLinkLightMode = styleVariants({
57
53
  light: {
@@ -89,34 +89,55 @@ const horiztontalTransition = css.style(styles_lib_css_responsiveStyle_cjs.respo
89
89
  transition: `transform .175s ${easeOut}, opacity .175s ${easeOut}`
90
90
  }
91
91
  }), "horiztontalTransition");
92
- const modalContainer = css.style({
93
- maxHeight: "100vh",
94
- maxWidth: "100vw"
95
- }, "modalContainer");
96
92
  const pointerEventsAll = css.style({
97
93
  pointerEvents: "all"
98
94
  }, "pointerEventsAll");
95
+ const gutterSizeVar = css.createVar("gutterSizeVar");
96
+ const fullHeightVar = css.createVar("fullHeightVar");
97
+ const fullWidthVar = css.createVar("fullWidthVar");
99
98
  const viewportHeight = css.style({
100
- maxHeight: "100vh"
99
+ maxHeight: fullHeightVar
101
100
  }, "viewportHeight");
102
101
  const maxSize = {
103
- center: css.style(styles_lib_css_responsiveStyle_cjs.responsiveStyle({
102
+ center: css.style([{
103
+ maxHeight: cssUtils.calc.subtract(fullHeightVar, cssUtils.calc.multiply(gutterSizeVar, 2)),
104
+ maxWidth: cssUtils.calc.subtract(fullWidthVar, cssUtils.calc.multiply(gutterSizeVar, 2))
105
+ }, styles_lib_css_responsiveStyle_cjs.responsiveStyle({
104
106
  mobile: {
105
- maxHeight: cssUtils.calc.subtract("100vh", cssUtils.calc.multiply(styles_lib_themes_vars_css_cjs.vars.space[styles_lib_components_private_Modal_ModalExternalGutter_cjs.externalGutter[0]], 2)),
106
- maxWidth: cssUtils.calc.subtract("100vw", cssUtils.calc.multiply(styles_lib_themes_vars_css_cjs.vars.space[styles_lib_components_private_Modal_ModalExternalGutter_cjs.externalGutter[0]], 2))
107
+ vars: {
108
+ [gutterSizeVar]: styles_lib_themes_vars_css_cjs.vars.space[styles_lib_components_private_Modal_ModalExternalGutter_cjs.externalGutter.mobile]
109
+ }
107
110
  },
108
111
  tablet: {
109
- maxHeight: cssUtils.calc.subtract("100vh", cssUtils.calc.multiply(styles_lib_themes_vars_css_cjs.vars.space[styles_lib_components_private_Modal_ModalExternalGutter_cjs.externalGutter[1]], 2)),
110
- maxWidth: cssUtils.calc.subtract("100vw", cssUtils.calc.multiply(styles_lib_themes_vars_css_cjs.vars.space[styles_lib_components_private_Modal_ModalExternalGutter_cjs.externalGutter[1]], 2))
112
+ vars: {
113
+ [gutterSizeVar]: styles_lib_themes_vars_css_cjs.vars.space[styles_lib_components_private_Modal_ModalExternalGutter_cjs.externalGutter.tablet]
114
+ }
111
115
  },
112
116
  desktop: {
113
- maxHeight: cssUtils.calc.subtract("100vh", cssUtils.calc.multiply(styles_lib_themes_vars_css_cjs.vars.space[styles_lib_components_private_Modal_ModalExternalGutter_cjs.externalGutter[2]], 2)),
114
- maxWidth: cssUtils.calc.subtract("100vw", cssUtils.calc.multiply(styles_lib_themes_vars_css_cjs.vars.space[styles_lib_components_private_Modal_ModalExternalGutter_cjs.externalGutter[2]], 2))
117
+ vars: {
118
+ [gutterSizeVar]: styles_lib_themes_vars_css_cjs.vars.space[styles_lib_components_private_Modal_ModalExternalGutter_cjs.externalGutter.desktop]
119
+ }
115
120
  }
116
- }), "maxSize_center"),
121
+ })], "maxSize_center"),
117
122
  right: viewportHeight,
118
123
  left: viewportHeight
119
124
  };
125
+ const modalContainer = css.style({
126
+ vars: {
127
+ [fullHeightVar]: "100vh",
128
+ [fullWidthVar]: "100vw"
129
+ },
130
+ "@supports": {
131
+ "(height: 1dvh)": {
132
+ vars: {
133
+ [fullHeightVar]: "100dvh",
134
+ [fullWidthVar]: "100dvw"
135
+ }
136
+ }
137
+ },
138
+ maxHeight: fullHeightVar,
139
+ maxWidth: fullWidthVar
140
+ }, "modalContainer");
120
141
  const headingRoot = css.style({
121
142
  overflowWrap: "break-word"
122
143
  }, "headingRoot");
@@ -1,5 +1,5 @@
1
1
  import { setFileScope, endFileScope } from "@vanilla-extract/css/fileScope";
2
- import { style } from "@vanilla-extract/css";
2
+ import { style, createVar } from "@vanilla-extract/css";
3
3
  import { calc } from "@vanilla-extract/css-utils";
4
4
  import { externalGutter } from "./ModalExternalGutter.mjs";
5
5
  import { responsiveStyle } from "../../../css/responsiveStyle.mjs";
@@ -88,34 +88,55 @@ const horiztontalTransition = style(responsiveStyle({
88
88
  transition: `transform .175s ${easeOut}, opacity .175s ${easeOut}`
89
89
  }
90
90
  }), "horiztontalTransition");
91
- const modalContainer = style({
92
- maxHeight: "100vh",
93
- maxWidth: "100vw"
94
- }, "modalContainer");
95
91
  const pointerEventsAll = style({
96
92
  pointerEvents: "all"
97
93
  }, "pointerEventsAll");
94
+ const gutterSizeVar = createVar("gutterSizeVar");
95
+ const fullHeightVar = createVar("fullHeightVar");
96
+ const fullWidthVar = createVar("fullWidthVar");
98
97
  const viewportHeight = style({
99
- maxHeight: "100vh"
98
+ maxHeight: fullHeightVar
100
99
  }, "viewportHeight");
101
100
  const maxSize = {
102
- center: style(responsiveStyle({
101
+ center: style([{
102
+ maxHeight: calc.subtract(fullHeightVar, calc.multiply(gutterSizeVar, 2)),
103
+ maxWidth: calc.subtract(fullWidthVar, calc.multiply(gutterSizeVar, 2))
104
+ }, responsiveStyle({
103
105
  mobile: {
104
- maxHeight: calc.subtract("100vh", calc.multiply(vars.space[externalGutter[0]], 2)),
105
- maxWidth: calc.subtract("100vw", calc.multiply(vars.space[externalGutter[0]], 2))
106
+ vars: {
107
+ [gutterSizeVar]: vars.space[externalGutter.mobile]
108
+ }
106
109
  },
107
110
  tablet: {
108
- maxHeight: calc.subtract("100vh", calc.multiply(vars.space[externalGutter[1]], 2)),
109
- maxWidth: calc.subtract("100vw", calc.multiply(vars.space[externalGutter[1]], 2))
111
+ vars: {
112
+ [gutterSizeVar]: vars.space[externalGutter.tablet]
113
+ }
110
114
  },
111
115
  desktop: {
112
- maxHeight: calc.subtract("100vh", calc.multiply(vars.space[externalGutter[2]], 2)),
113
- maxWidth: calc.subtract("100vw", calc.multiply(vars.space[externalGutter[2]], 2))
116
+ vars: {
117
+ [gutterSizeVar]: vars.space[externalGutter.desktop]
118
+ }
114
119
  }
115
- }), "maxSize_center"),
120
+ })], "maxSize_center"),
116
121
  right: viewportHeight,
117
122
  left: viewportHeight
118
123
  };
124
+ const modalContainer = style({
125
+ vars: {
126
+ [fullHeightVar]: "100vh",
127
+ [fullWidthVar]: "100vw"
128
+ },
129
+ "@supports": {
130
+ "(height: 1dvh)": {
131
+ vars: {
132
+ [fullHeightVar]: "100dvh",
133
+ [fullWidthVar]: "100dvw"
134
+ }
135
+ }
136
+ },
137
+ maxHeight: fullHeightVar,
138
+ maxWidth: fullWidthVar
139
+ }, "modalContainer");
119
140
  const headingRoot = style({
120
141
  overflowWrap: "break-word"
121
142
  }, "headingRoot");
@@ -1,3 +1,7 @@
1
1
  "use strict";
2
- const externalGutter = ["xsmall", "gutter", "xlarge"];
2
+ const externalGutter = {
3
+ mobile: "xsmall",
4
+ tablet: "gutter",
5
+ desktop: "xlarge"
6
+ };
3
7
  exports.externalGutter = externalGutter;
@@ -1,4 +1,8 @@
1
- const externalGutter = ["xsmall", "gutter", "xlarge"];
1
+ const externalGutter = {
2
+ mobile: "xsmall",
3
+ tablet: "gutter",
4
+ desktop: "xlarge"
5
+ };
2
6
  export {
3
7
  externalGutter
4
8
  };
@@ -216,9 +216,9 @@ const tokens = {
216
216
  brandAccent,
217
217
  brandAccentActive: brandAccent,
218
218
  brandAccentHover: sideEffects_lib_themes_baseTokens_apac_cjs.palette.grey["700"],
219
- brandAccentSoft: sideEffects_lib_themes_baseTokens_apac_cjs.palette.grey["200"],
220
- brandAccentSoftActive: polished.darken(0.025, sideEffects_lib_themes_baseTokens_apac_cjs.palette.grey["200"]),
221
- brandAccentSoftHover: polished.darken(0.05, sideEffects_lib_themes_baseTokens_apac_cjs.palette.grey["200"]),
219
+ brandAccentSoft: sideEffects_lib_themes_baseTokens_apac_cjs.palette.grey["100"],
220
+ brandAccentSoftActive: polished.darken(0.025, sideEffects_lib_themes_baseTokens_apac_cjs.palette.grey["100"]),
221
+ brandAccentSoftHover: polished.darken(0.05, sideEffects_lib_themes_baseTokens_apac_cjs.palette.grey["100"]),
222
222
  caution: sideEffects_lib_themes_baseTokens_apac_cjs.palette.yellow["500"],
223
223
  cautionLight: sideEffects_lib_themes_baseTokens_apac_cjs.palette.yellow["100"],
224
224
  critical: sideEffects_lib_themes_baseTokens_apac_cjs.palette.red["600"],
@@ -231,9 +231,9 @@ const tokens = {
231
231
  formAccent,
232
232
  formAccentActive: sideEffects_lib_themes_baseTokens_apac_cjs.palette.indigo["700"],
233
233
  formAccentHover: polished.darken(0.05, sideEffects_lib_themes_baseTokens_apac_cjs.palette.indigo["600"]),
234
- formAccentSoft: sideEffects_lib_themes_baseTokens_apac_cjs.palette.indigo["100"],
235
- formAccentSoftActive: polished.darken(0.05, sideEffects_lib_themes_baseTokens_apac_cjs.palette.indigo["100"]),
236
- formAccentSoftHover: polished.darken(0.025, sideEffects_lib_themes_baseTokens_apac_cjs.palette.indigo["100"]),
234
+ formAccentSoft: sideEffects_lib_themes_baseTokens_apac_cjs.palette.indigo["50"],
235
+ formAccentSoftActive: polished.darken(0.05, sideEffects_lib_themes_baseTokens_apac_cjs.palette.indigo["50"]),
236
+ formAccentSoftHover: polished.darken(0.025, sideEffects_lib_themes_baseTokens_apac_cjs.palette.indigo["50"]),
237
237
  info: sideEffects_lib_themes_baseTokens_apac_cjs.palette.blue["600"],
238
238
  infoLight: sideEffects_lib_themes_baseTokens_apac_cjs.palette.blue["100"],
239
239
  neutral: sideEffects_lib_themes_baseTokens_apac_cjs.palette.grey["800"],
@@ -213,9 +213,9 @@ const tokens = {
213
213
  brandAccent,
214
214
  brandAccentActive: brandAccent,
215
215
  brandAccentHover: palette.grey["700"],
216
- brandAccentSoft: palette.grey["200"],
217
- brandAccentSoftActive: darken(0.025, palette.grey["200"]),
218
- brandAccentSoftHover: darken(0.05, palette.grey["200"]),
216
+ brandAccentSoft: palette.grey["100"],
217
+ brandAccentSoftActive: darken(0.025, palette.grey["100"]),
218
+ brandAccentSoftHover: darken(0.05, palette.grey["100"]),
219
219
  caution: palette.yellow["500"],
220
220
  cautionLight: palette.yellow["100"],
221
221
  critical: palette.red["600"],
@@ -228,9 +228,9 @@ const tokens = {
228
228
  formAccent,
229
229
  formAccentActive: palette.indigo["700"],
230
230
  formAccentHover: darken(0.05, palette.indigo["600"]),
231
- formAccentSoft: palette.indigo["100"],
232
- formAccentSoftActive: darken(0.05, palette.indigo["100"]),
233
- formAccentSoftHover: darken(0.025, palette.indigo["100"]),
231
+ formAccentSoft: palette.indigo["50"],
232
+ formAccentSoftActive: darken(0.05, palette.indigo["50"]),
233
+ formAccentSoftHover: darken(0.025, palette.indigo["50"]),
234
234
  info: palette.blue["600"],
235
235
  infoLight: palette.blue["100"],
236
236
  neutral: palette.grey["800"],
@@ -65,7 +65,7 @@ const fontSizeToCapHeight = (grid, definition, fontMetrics) => {
65
65
  };
66
66
  };
67
67
  const makeVanillaTheme = (braidTokens) => {
68
- const { name, displayName, ...tokens } = braidTokens;
68
+ const { name, displayName, legacy, ...tokens } = braidTokens;
69
69
  const { webFont, ...typography } = tokens.typography;
70
70
  const { foreground, background } = tokens.color;
71
71
  const textSize = mapValues__default.default(
@@ -103,6 +103,12 @@ const makeVanillaTheme = (braidTokens) => {
103
103
  tokens.typography.fontWeight[tokens.typography.heading.weight.regular]
104
104
  )
105
105
  },
106
+ /*
107
+ Going forward, all links variants should be underlined as an accessibility
108
+ best practice. However, to maintain existing behaviour we are sunsetting
109
+ the old style based on the `legacy` theme flag, e.g. `apac`.
110
+ */
111
+ linkDecoration: legacy ? "none" : "underline",
106
112
  inlineFieldSize: {
107
113
  standard: getInlineFieldSize("standard"),
108
114
  small: getInlineFieldSize("small")
@@ -62,7 +62,7 @@ const fontSizeToCapHeight = (grid, definition, fontMetrics) => {
62
62
  };
63
63
  };
64
64
  const makeVanillaTheme = (braidTokens) => {
65
- const { name, displayName, ...tokens } = braidTokens;
65
+ const { name, displayName, legacy, ...tokens } = braidTokens;
66
66
  const { webFont, ...typography } = tokens.typography;
67
67
  const { foreground, background } = tokens.color;
68
68
  const textSize = mapValues(
@@ -100,6 +100,12 @@ const makeVanillaTheme = (braidTokens) => {
100
100
  tokens.typography.fontWeight[tokens.typography.heading.weight.regular]
101
101
  )
102
102
  },
103
+ /*
104
+ Going forward, all links variants should be underlined as an accessibility
105
+ best practice. However, to maintain existing behaviour we are sunsetting
106
+ the old style based on the `legacy` theme flag, e.g. `apac`.
107
+ */
108
+ linkDecoration: legacy ? "none" : "underline",
103
109
  inlineFieldSize: {
104
110
  standard: getInlineFieldSize("standard"),
105
111
  small: getInlineFieldSize("small")
@@ -159,9 +159,9 @@ const tokens = sideEffects_lib_themes_baseTokens_apac_cjs.makeTokens({
159
159
  foreground: {
160
160
  formAccent: sideEffects_lib_themes_baseTokens_apac_cjs.palette.violet["500"],
161
161
  formAccentLight: sideEffects_lib_themes_baseTokens_apac_cjs.palette.violet["300"],
162
- link: sideEffects_lib_themes_baseTokens_apac_cjs.palette.violet["500"],
163
- linkHover: sideEffects_lib_themes_baseTokens_apac_cjs.palette.violet["500"],
164
- linkLight: sideEffects_lib_themes_baseTokens_apac_cjs.palette.violet["300"],
162
+ link: sideEffects_lib_themes_baseTokens_apac_cjs.palette.grey["700"],
163
+ linkHover: sideEffects_lib_themes_baseTokens_apac_cjs.palette.grey["700"],
164
+ linkLight: "#fff",
165
165
  linkVisited: sideEffects_lib_themes_baseTokens_apac_cjs.palette.purple["800"],
166
166
  linkLightVisited: sideEffects_lib_themes_baseTokens_apac_cjs.palette.purple["200"],
167
167
  promote: sideEffects_lib_themes_baseTokens_apac_cjs.palette.purple["700"],
@@ -158,9 +158,9 @@ const tokens = makeTokens({
158
158
  foreground: {
159
159
  formAccent: palette.violet["500"],
160
160
  formAccentLight: palette.violet["300"],
161
- link: palette.violet["500"],
162
- linkHover: palette.violet["500"],
163
- linkLight: palette.violet["300"],
161
+ link: palette.grey["700"],
162
+ linkHover: palette.grey["700"],
163
+ linkLight: "#fff",
164
164
  linkVisited: palette.purple["800"],
165
165
  linkLightVisited: palette.purple["200"],
166
166
  promote: palette.purple["700"],
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "braid-design-system",
3
- "version": "32.9.2",
3
+ "version": "32.10.0",
4
4
  "description": "Themeable design system for the SEEK Group",
5
5
  "homepage": "https://seek-oss.github.io/braid-design-system/",
6
6
  "bugs": {
@@ -179,7 +179,7 @@
179
179
  "babel-plugin-transform-remove-imports": "^1.7.0",
180
180
  "change-case": "^4.1.2",
181
181
  "cheerio": "1.0.0-rc.11",
182
- "chromatic": "^5.10.2",
182
+ "chromatic": "^6.24.1",
183
183
  "fast-glob": "^3.2.12",
184
184
  "fs-extra": "^10.1.0",
185
185
  "html-validate": "^7.1.1",