@guardian/stand 0.0.32 → 0.0.34

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.
Files changed (56) hide show
  1. package/dist/components/intended-audience-signifier/FlagIcons.cjs +128 -0
  2. package/dist/components/intended-audience-signifier/FlagIcons.js +9 -0
  3. package/dist/components/intended-audience-signifier/IntendedAudienceSignifier.cjs +67 -0
  4. package/dist/components/intended-audience-signifier/IntendedAudienceSignifier.js +35 -0
  5. package/dist/components/intended-audience-signifier/styles.cjs +31 -0
  6. package/dist/components/intended-audience-signifier/styles.js +28 -0
  7. package/dist/components/link/Link.cjs +37 -0
  8. package/dist/components/link/Link.js +17 -0
  9. package/dist/components/link/styles.cjs +31 -0
  10. package/dist/components/link/styles.js +28 -0
  11. package/dist/index.cjs +6 -2
  12. package/dist/index.js +3 -1
  13. package/dist/intended-audience-signifier.cjs +9 -0
  14. package/dist/intended-audience-signifier.js +2 -0
  15. package/dist/link.cjs +9 -0
  16. package/dist/link.js +2 -0
  17. package/dist/styleD/build/css/base/typography.css +2 -2
  18. package/dist/styleD/build/css/component/TopBar.css +2 -2
  19. package/dist/styleD/build/css/component/alertBanner.css +1 -1
  20. package/dist/styleD/build/css/component/autocomplete.css +1 -1
  21. package/dist/styleD/build/css/component/avatar.css +1 -1
  22. package/dist/styleD/build/css/component/button.css +3 -3
  23. package/dist/styleD/build/css/component/checkbox.css +2 -2
  24. package/dist/styleD/build/css/component/favicon.css +1 -1
  25. package/dist/styleD/build/css/component/form.css +1 -1
  26. package/dist/styleD/build/css/component/inlineMessage.css +1 -1
  27. package/dist/styleD/build/css/component/intendedAudienceSignifier.css +25 -0
  28. package/dist/styleD/build/css/component/link.css +12 -0
  29. package/dist/styleD/build/css/component/menu.css +3 -3
  30. package/dist/styleD/build/css/component/radioGroup.css +3 -3
  31. package/dist/styleD/build/css/component/select.css +2 -2
  32. package/dist/styleD/build/css/component/tagTable.css +1 -1
  33. package/dist/styleD/build/css/component/textArea.css +2 -2
  34. package/dist/styleD/build/css/component/textInput.css +2 -2
  35. package/dist/styleD/build/css/component/userMenu.css +6 -6
  36. package/dist/styleD/build/css/semantic/typography.css +61 -61
  37. package/dist/styleD/build/typescript/component/intendedAudienceSignifier.cjs +29 -0
  38. package/dist/styleD/build/typescript/component/intendedAudienceSignifier.js +27 -0
  39. package/dist/styleD/build/typescript/component/link.cjs +24 -0
  40. package/dist/styleD/build/typescript/component/link.js +22 -0
  41. package/dist/types/components/intended-audience-signifier/FlagIcons.d.ts +5 -0
  42. package/dist/types/components/intended-audience-signifier/IntendedAudienceSignifier.d.ts +2 -0
  43. package/dist/types/components/intended-audience-signifier/sandbox.d.ts +5 -0
  44. package/dist/types/components/intended-audience-signifier/styles.d.ts +6 -0
  45. package/dist/types/components/intended-audience-signifier/types.d.ts +8 -0
  46. package/dist/types/components/link/Link.d.ts +2 -0
  47. package/dist/types/components/link/sandbox.d.ts +5 -0
  48. package/dist/types/components/link/styles.d.ts +7 -0
  49. package/dist/types/components/link/types.d.ts +11 -0
  50. package/dist/types/components/typography/types.d.ts +3 -2
  51. package/dist/types/index.d.ts +6 -2
  52. package/dist/types/intended-audience-signifier.d.ts +19 -0
  53. package/dist/types/link.d.ts +19 -0
  54. package/dist/types/styleD/build/typescript/component/intendedAudienceSignifier.d.ts +29 -0
  55. package/dist/types/styleD/build/typescript/component/link.d.ts +24 -0
  56. package/package.json +40 -19
@@ -0,0 +1,128 @@
1
+ 'use strict';
2
+
3
+ var jsxRuntime = require('@emotion/react/jsx-runtime');
4
+
5
+ const ukFlag = /* @__PURE__ */ jsxRuntime.jsxs(
6
+ "svg",
7
+ {
8
+ height: "12px",
9
+ xmlns: "http://www.w3.org/2000/svg",
10
+ id: "flag-icons-gb",
11
+ viewBox: "0 0 640 480",
12
+ children: [
13
+ /* @__PURE__ */ jsxRuntime.jsx("path", { fill: "#012169", d: "M0 0h640v480H0z" }),
14
+ /* @__PURE__ */ jsxRuntime.jsx(
15
+ "path",
16
+ {
17
+ fill: "#FFF",
18
+ d: "m75 0 244 181L562 0h78v62L400 241l240 178v61h-80L320 301 81 480H0v-60l239-178L0 64V0z"
19
+ }
20
+ ),
21
+ /* @__PURE__ */ jsxRuntime.jsx(
22
+ "path",
23
+ {
24
+ fill: "#C8102E",
25
+ d: "m424 281 216 159v40L369 281zm-184 20 6 35L54 480H0zM640 0v3L391 191l2-44L590 0zM0 0l239 176h-60L0 42z"
26
+ }
27
+ ),
28
+ /* @__PURE__ */ jsxRuntime.jsx("path", { fill: "#FFF", d: "M241 0v480h160V0zM0 160v160h640V160z" }),
29
+ /* @__PURE__ */ jsxRuntime.jsx("path", { fill: "#C8102E", d: "M0 193v96h640v-96zM273 0v480h96V0z" })
30
+ ]
31
+ }
32
+ );
33
+ const usFlag = /* @__PURE__ */ jsxRuntime.jsxs(
34
+ "svg",
35
+ {
36
+ height: "12px",
37
+ xmlns: "http://www.w3.org/2000/svg",
38
+ id: "flag-icons-us",
39
+ viewBox: "0 0 640 480",
40
+ children: [
41
+ /* @__PURE__ */ jsxRuntime.jsx("path", { fill: "#bd3d44", d: "M0 0h640v480H0" }),
42
+ /* @__PURE__ */ jsxRuntime.jsx(
43
+ "path",
44
+ {
45
+ stroke: "#fff",
46
+ strokeWidth: "37",
47
+ d: "M0 55.3h640M0 129h640M0 203h640M0 277h640M0 351h640M0 425h640"
48
+ }
49
+ ),
50
+ /* @__PURE__ */ jsxRuntime.jsx("path", { fill: "#192f5d", d: "M0 0h364.8v258.5H0" }),
51
+ /* @__PURE__ */ jsxRuntime.jsx("marker", { id: "us-a", markerHeight: "30", markerWidth: "30", children: /* @__PURE__ */ jsxRuntime.jsx("path", { fill: "#fff", d: "m14 0 9 27L0 10h28L5 27z" }) }),
52
+ /* @__PURE__ */ jsxRuntime.jsx(
53
+ "path",
54
+ {
55
+ fill: "none",
56
+ markerMid: "url(#us-a)",
57
+ d: "m0 0 16 11h61 61 61 61 60L47 37h61 61 60 61L16 63h61 61 61 61 60L47 89h61 61 60 61L16 115h61 61 61 61 60L47 141h61 61 60 61L16 166h61 61 61 61 60L47 192h61 61 60 61L16 218h61 61 61 61 60z"
58
+ }
59
+ )
60
+ ]
61
+ }
62
+ );
63
+ const auFlag = /* @__PURE__ */ jsxRuntime.jsxs(
64
+ "svg",
65
+ {
66
+ height: "12px",
67
+ xmlns: "http://www.w3.org/2000/svg",
68
+ id: "flag-icons-au",
69
+ viewBox: "0 0 640 480",
70
+ children: [
71
+ /* @__PURE__ */ jsxRuntime.jsx("path", { fill: "#00008B", d: "M0 0h640v480H0z" }),
72
+ /* @__PURE__ */ jsxRuntime.jsx(
73
+ "path",
74
+ {
75
+ fill: "#fff",
76
+ d: "m37.5 0 122 90.5L281 0h39v31l-120 89.5 120 89V240h-40l-120-89.5L40.5 240H0v-30l119.5-89L0 32V0z"
77
+ }
78
+ ),
79
+ /* @__PURE__ */ jsxRuntime.jsx(
80
+ "path",
81
+ {
82
+ fill: "red",
83
+ d: "M212 140.5 320 220v20l-135.5-99.5zm-92 10 3 17.5-96 72H0zM320 0v1.5l-124.5 94 1-22L295 0zM0 0l119.5 88h-30L0 21z"
84
+ }
85
+ ),
86
+ /* @__PURE__ */ jsxRuntime.jsx("path", { fill: "#fff", d: "M120.5 0v240h80V0zM0 80v80h320V80z" }),
87
+ /* @__PURE__ */ jsxRuntime.jsx("path", { fill: "red", d: "M0 96.5v48h320v-48zM136.5 0v240h48V0z" }),
88
+ /* @__PURE__ */ jsxRuntime.jsx(
89
+ "path",
90
+ {
91
+ fill: "#fff",
92
+ d: "m527 396.7-20.5 2.6 2.2 20.5-14.8-14.4-14.7 14.5 2-20.5-20.5-2.4 17.3-11.2-10.9-17.5 19.6 6.5 6.9-19.5 7.1 19.4 19.5-6.7-10.7 17.6zm-3.7-117.2 2.7-13-9.8-9 13.2-1.5 5.5-12.1 5.5 12.1 13.2 1.5-9.8 9 2.7 13-11.6-6.6zm-104.1-60-20.3 2.2 1.8 20.3-14.4-14.5-14.8 14.1 2.4-20.3-20.2-2.7 17.3-10.8-10.5-17.5 19.3 6.8L387 178l6.7 19.3 19.4-6.3-10.9 17.3 17.1 11.2ZM623 186.7l-20.9 2.7 2.3 20.9-15.1-14.7-15 14.8 2.1-21-20.9-2.4 17.7-11.5-11.1-17.9 20 6.7 7-19.8 7.2 19.8 19.9-6.9-11 18zm-96.1-83.5-20.7 2.3 1.9 20.8-14.7-14.8-15.1 14.4 2.4-20.7-20.7-2.8 17.7-11L467 73.5l19.7 6.9 7.3-19.5 6.8 19.7 19.8-6.5-11.1 17.6zM234 385.7l-45.8 5.4 4.6 45.9-32.8-32.4-33 32.2 4.9-45.9-45.8-5.8 38.9-24.8-24-39.4 43.6 15 15.8-43.4 15.5 43.5 43.7-14.7-24.3 39.2 38.8 25.1Z"
93
+ }
94
+ )
95
+ ]
96
+ }
97
+ );
98
+ const globeIcon = /* @__PURE__ */ jsxRuntime.jsx(
99
+ "svg",
100
+ {
101
+ style: { marginTop: "2px" },
102
+ width: "16px",
103
+ height: "16px",
104
+ fill: "#000000",
105
+ viewBox: "0 0 16 16",
106
+ children: /* @__PURE__ */ jsxRuntime.jsx("path", { d: "M8 0a8 8 0 1 0 0 16A8 8 0 0 0 8 0M3.668 2.501l-.288.646a.847.847 0 0 0 1.479.815l.245-.368a.81.81 0 0 1 1.034-.275.81.81 0 0 0 .724 0l.261-.13a1 1 0 0 1 .775-.05l.984.34q.118.04.243.054c.784.093.855.377.694.801-.155.41-.616.617-1.035.487l-.01-.003C8.274 4.663 7.748 4.5 6 4.5 4.8 4.5 3.5 5.62 3.5 7c0 1.96.826 2.166 1.696 2.382.46.115.935.233 1.304.618.449.467.393 1.181.339 1.877C6.755 12.96 6.674 14 8.5 14c1.75 0 3-3.5 3-4.5 0-.262.208-.468.444-.7.396-.392.87-.86.556-1.8-.097-.291-.396-.568-.641-.756-.174-.133-.207-.396-.052-.551a.33.33 0 0 1 .42-.042l1.085.724c.11.072.255.058.348-.035.15-.15.415-.083.489.117.16.43.445 1.05.849 1.357L15 8A7 7 0 1 1 3.668 2.501" })
107
+ }
108
+ );
109
+ const DoubleChevronRightSvg = /* @__PURE__ */ jsxRuntime.jsxs(
110
+ "svg",
111
+ {
112
+ width: "13",
113
+ height: "13",
114
+ viewBox: "0 0 9 7",
115
+ fill: "none",
116
+ xmlns: "http://www.w3.org/2000/svg",
117
+ children: [
118
+ /* @__PURE__ */ jsxRuntime.jsx("path", { d: "M5.75 0H3.5L6 3.5L3.5 7H5.75L8.25 3.5L5.75 0Z", fill: "#545454" }),
119
+ /* @__PURE__ */ jsxRuntime.jsx("path", { d: "M2.25 0H0L2.5 3.5L0 7H2.25L4.75 3.5L2.25 0Z", fill: "#545454" })
120
+ ]
121
+ }
122
+ );
123
+
124
+ exports.DoubleChevronRightSvg = DoubleChevronRightSvg;
125
+ exports.auFlag = auFlag;
126
+ exports.globeIcon = globeIcon;
127
+ exports.ukFlag = ukFlag;
128
+ exports.usFlag = usFlag;
@@ -0,0 +1,9 @@
1
+ import { jsxs, jsx } from '@emotion/react/jsx-runtime';
2
+
3
+ const ukFlag = jsxs("svg", { height: "12px", xmlns: "http://www.w3.org/2000/svg", id: "flag-icons-gb", viewBox: "0 0 640 480", children: [jsx("path", { fill: "#012169", d: "M0 0h640v480H0z" }), jsx("path", { fill: "#FFF", d: "m75 0 244 181L562 0h78v62L400 241l240 178v61h-80L320 301 81 480H0v-60l239-178L0 64V0z" }), jsx("path", { fill: "#C8102E", d: "m424 281 216 159v40L369 281zm-184 20 6 35L54 480H0zM640 0v3L391 191l2-44L590 0zM0 0l239 176h-60L0 42z" }), jsx("path", { fill: "#FFF", d: "M241 0v480h160V0zM0 160v160h640V160z" }), jsx("path", { fill: "#C8102E", d: "M0 193v96h640v-96zM273 0v480h96V0z" })] });
4
+ const usFlag = jsxs("svg", { height: "12px", xmlns: "http://www.w3.org/2000/svg", id: "flag-icons-us", viewBox: "0 0 640 480", children: [jsx("path", { fill: "#bd3d44", d: "M0 0h640v480H0" }), jsx("path", { stroke: "#fff", strokeWidth: "37", d: "M0 55.3h640M0 129h640M0 203h640M0 277h640M0 351h640M0 425h640" }), jsx("path", { fill: "#192f5d", d: "M0 0h364.8v258.5H0" }), jsx("marker", { id: "us-a", markerHeight: "30", markerWidth: "30", children: jsx("path", { fill: "#fff", d: "m14 0 9 27L0 10h28L5 27z" }) }), jsx("path", { fill: "none", markerMid: "url(#us-a)", d: "m0 0 16 11h61 61 61 61 60L47 37h61 61 60 61L16 63h61 61 61 61 60L47 89h61 61 60 61L16 115h61 61 61 61 60L47 141h61 61 60 61L16 166h61 61 61 61 60L47 192h61 61 60 61L16 218h61 61 61 61 60z" })] });
5
+ const auFlag = jsxs("svg", { height: "12px", xmlns: "http://www.w3.org/2000/svg", id: "flag-icons-au", viewBox: "0 0 640 480", children: [jsx("path", { fill: "#00008B", d: "M0 0h640v480H0z" }), jsx("path", { fill: "#fff", d: "m37.5 0 122 90.5L281 0h39v31l-120 89.5 120 89V240h-40l-120-89.5L40.5 240H0v-30l119.5-89L0 32V0z" }), jsx("path", { fill: "red", d: "M212 140.5 320 220v20l-135.5-99.5zm-92 10 3 17.5-96 72H0zM320 0v1.5l-124.5 94 1-22L295 0zM0 0l119.5 88h-30L0 21z" }), jsx("path", { fill: "#fff", d: "M120.5 0v240h80V0zM0 80v80h320V80z" }), jsx("path", { fill: "red", d: "M0 96.5v48h320v-48zM136.5 0v240h48V0z" }), jsx("path", { fill: "#fff", d: "m527 396.7-20.5 2.6 2.2 20.5-14.8-14.4-14.7 14.5 2-20.5-20.5-2.4 17.3-11.2-10.9-17.5 19.6 6.5 6.9-19.5 7.1 19.4 19.5-6.7-10.7 17.6zm-3.7-117.2 2.7-13-9.8-9 13.2-1.5 5.5-12.1 5.5 12.1 13.2 1.5-9.8 9 2.7 13-11.6-6.6zm-104.1-60-20.3 2.2 1.8 20.3-14.4-14.5-14.8 14.1 2.4-20.3-20.2-2.7 17.3-10.8-10.5-17.5 19.3 6.8L387 178l6.7 19.3 19.4-6.3-10.9 17.3 17.1 11.2ZM623 186.7l-20.9 2.7 2.3 20.9-15.1-14.7-15 14.8 2.1-21-20.9-2.4 17.7-11.5-11.1-17.9 20 6.7 7-19.8 7.2 19.8 19.9-6.9-11 18zm-96.1-83.5-20.7 2.3 1.9 20.8-14.7-14.8-15.1 14.4 2.4-20.7-20.7-2.8 17.7-11L467 73.5l19.7 6.9 7.3-19.5 6.8 19.7 19.8-6.5-11.1 17.6zM234 385.7l-45.8 5.4 4.6 45.9-32.8-32.4-33 32.2 4.9-45.9-45.8-5.8 38.9-24.8-24-39.4 43.6 15 15.8-43.4 15.5 43.5 43.7-14.7-24.3 39.2 38.8 25.1Z" })] });
6
+ const globeIcon = jsx("svg", { style: { marginTop: "2px" }, width: "16px", height: "16px", fill: "#000000", viewBox: "0 0 16 16", children: jsx("path", { d: "M8 0a8 8 0 1 0 0 16A8 8 0 0 0 8 0M3.668 2.501l-.288.646a.847.847 0 0 0 1.479.815l.245-.368a.81.81 0 0 1 1.034-.275.81.81 0 0 0 .724 0l.261-.13a1 1 0 0 1 .775-.05l.984.34q.118.04.243.054c.784.093.855.377.694.801-.155.41-.616.617-1.035.487l-.01-.003C8.274 4.663 7.748 4.5 6 4.5 4.8 4.5 3.5 5.62 3.5 7c0 1.96.826 2.166 1.696 2.382.46.115.935.233 1.304.618.449.467.393 1.181.339 1.877C6.755 12.96 6.674 14 8.5 14c1.75 0 3-3.5 3-4.5 0-.262.208-.468.444-.7.396-.392.87-.86.556-1.8-.097-.291-.396-.568-.641-.756-.174-.133-.207-.396-.052-.551a.33.33 0 0 1 .42-.042l1.085.724c.11.072.255.058.348-.035.15-.15.415-.083.489.117.16.43.445 1.05.849 1.357L15 8A7 7 0 1 1 3.668 2.501" }) });
7
+ const DoubleChevronRightSvg = jsxs("svg", { width: "13", height: "13", viewBox: "0 0 9 7", fill: "none", xmlns: "http://www.w3.org/2000/svg", children: [jsx("path", { d: "M5.75 0H3.5L6 3.5L3.5 7H5.75L8.25 3.5L5.75 0Z", fill: "#545454" }), jsx("path", { d: "M2.25 0H0L2.5 3.5L0 7H2.25L4.75 3.5L2.25 0Z", fill: "#545454" })] });
8
+
9
+ export { DoubleChevronRightSvg, auFlag, globeIcon, ukFlag, usFlag };
@@ -0,0 +1,67 @@
1
+ 'use strict';
2
+
3
+ var jsxRuntime = require('@emotion/react/jsx-runtime');
4
+ var mergeDeep = require('../../util/mergeDeep.cjs');
5
+ var FlagIcons = require('./FlagIcons.cjs');
6
+ var styles = require('./styles.cjs');
7
+
8
+ const sourceIcons = {
9
+ UK: FlagIcons.ukFlag,
10
+ US: FlagIcons.usFlag,
11
+ AUS: FlagIcons.auFlag,
12
+ Global: FlagIcons.globeIcon
13
+ };
14
+ const getSourceIconElement = (sourceTag, audience) => {
15
+ if (audience === "Global") {
16
+ return FlagIcons.globeIcon;
17
+ }
18
+ return sourceIcons[sourceTag];
19
+ };
20
+ const getIntendedAudienceIconElement = (sourceTag, audience) => {
21
+ if (audience === "Domestic for Domestic") {
22
+ return getSourceIconElement(sourceTag, audience);
23
+ }
24
+ if (audience === "Global" || audience === "Domestic For Global") {
25
+ return FlagIcons.globeIcon;
26
+ }
27
+ return sourceIcons[audience];
28
+ };
29
+ function IntendedAudienceSignifier({
30
+ source,
31
+ intendedAudience,
32
+ theme = {},
33
+ cssOverrides,
34
+ className,
35
+ ...props
36
+ }) {
37
+ const mergedTheme = mergeDeep.mergeDeep(styles.defaultIntendedAudienceSignifierTheme, theme);
38
+ if (intendedAudience === "Don't know") {
39
+ return /* @__PURE__ */ jsxRuntime.jsx(
40
+ "div",
41
+ {
42
+ ...props,
43
+ className,
44
+ css: [styles.intendedAudienceSignifierStyles(mergedTheme), cssOverrides],
45
+ children: /* @__PURE__ */ jsxRuntime.jsx("span", { children: "Don\u2018t know" })
46
+ }
47
+ );
48
+ }
49
+ return /* @__PURE__ */ jsxRuntime.jsxs(
50
+ "div",
51
+ {
52
+ ...props,
53
+ className,
54
+ css: [styles.intendedAudienceSignifierStyles(mergedTheme), cssOverrides],
55
+ children: [
56
+ /* @__PURE__ */ jsxRuntime.jsx("div", { children: getSourceIconElement(source, intendedAudience) }),
57
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { children: [
58
+ " ",
59
+ FlagIcons.DoubleChevronRightSvg
60
+ ] }),
61
+ /* @__PURE__ */ jsxRuntime.jsx("div", { children: getIntendedAudienceIconElement(source, intendedAudience) })
62
+ ]
63
+ }
64
+ );
65
+ }
66
+
67
+ exports.IntendedAudienceSignifier = IntendedAudienceSignifier;
@@ -0,0 +1,35 @@
1
+ import { jsx, jsxs } from '@emotion/react/jsx-runtime';
2
+ import { mergeDeep } from '../../util/mergeDeep.js';
3
+ import { DoubleChevronRightSvg, globeIcon, auFlag, usFlag, ukFlag } from './FlagIcons.js';
4
+ import { intendedAudienceSignifierStyles, defaultIntendedAudienceSignifierTheme } from './styles.js';
5
+
6
+ const sourceIcons = {
7
+ UK: ukFlag,
8
+ US: usFlag,
9
+ AUS: auFlag,
10
+ Global: globeIcon
11
+ };
12
+ const getSourceIconElement = (sourceTag, audience) => {
13
+ if (audience === "Global") {
14
+ return globeIcon;
15
+ }
16
+ return sourceIcons[sourceTag];
17
+ };
18
+ const getIntendedAudienceIconElement = (sourceTag, audience) => {
19
+ if (audience === "Domestic for Domestic") {
20
+ return getSourceIconElement(sourceTag, audience);
21
+ }
22
+ if (audience === "Global" || audience === "Domestic For Global") {
23
+ return globeIcon;
24
+ }
25
+ return sourceIcons[audience];
26
+ };
27
+ function IntendedAudienceSignifier({ source, intendedAudience, theme = {}, cssOverrides, className, ...props }) {
28
+ const mergedTheme = mergeDeep(defaultIntendedAudienceSignifierTheme, theme);
29
+ if (intendedAudience === "Don't know") {
30
+ return jsx("div", { ...props, className, css: [intendedAudienceSignifierStyles(mergedTheme), cssOverrides], children: jsx("span", { children: "Don\u2018t know" }) });
31
+ }
32
+ return jsxs("div", { ...props, className, css: [intendedAudienceSignifierStyles(mergedTheme), cssOverrides], children: [jsx("div", { children: getSourceIconElement(source, intendedAudience) }), jsxs("div", { children: [" ", DoubleChevronRightSvg] }), jsx("div", { children: getIntendedAudienceIconElement(source, intendedAudience) })] });
33
+ }
34
+
35
+ export { IntendedAudienceSignifier };
@@ -0,0 +1,31 @@
1
+ 'use strict';
2
+
3
+ var react = require('@emotion/react');
4
+ var intendedAudienceSignifier = require('../../styleD/build/typescript/component/intendedAudienceSignifier.cjs');
5
+
6
+ const defaultIntendedAudienceSignifierTheme = intendedAudienceSignifier.componentIntendedAudienceSignifier;
7
+ const intendedAudienceSignifierStyles = (theme) => react.css`
8
+ display: ${theme.display};
9
+ flex-direction: ${theme.flexDirection};
10
+ justify-content: ${theme.justifyContent};
11
+ align-items: ${theme.alignItems};
12
+ color: ${theme.color};
13
+ font-weight: ${theme.typography.fontWeight};
14
+ font-size: ${theme.typography.fontSize};
15
+ line-height: ${theme.typography.lineHeight};
16
+ border-width: ${theme.borderWidth};
17
+ border-style: ${theme.borderStyle};
18
+ border-color: ${theme.borderColor};
19
+ border-radius: ${theme.borderRadius};
20
+ padding: ${theme.paddingY} ${theme.paddingX};
21
+ box-sizing: ${theme.boxSizing};
22
+ width: ${theme.width};
23
+ gap: ${theme.gap};
24
+ svg {
25
+ height: ${theme.svg.height};
26
+ width: ${theme.svg.width};
27
+ }
28
+ `;
29
+
30
+ exports.defaultIntendedAudienceSignifierTheme = defaultIntendedAudienceSignifierTheme;
31
+ exports.intendedAudienceSignifierStyles = intendedAudienceSignifierStyles;
@@ -0,0 +1,28 @@
1
+ import { css } from '@emotion/react';
2
+ import { componentIntendedAudienceSignifier } from '../../styleD/build/typescript/component/intendedAudienceSignifier.js';
3
+
4
+ const defaultIntendedAudienceSignifierTheme = componentIntendedAudienceSignifier;
5
+ const intendedAudienceSignifierStyles = (theme) => css`
6
+ display: ${theme.display};
7
+ flex-direction: ${theme.flexDirection};
8
+ justify-content: ${theme.justifyContent};
9
+ align-items: ${theme.alignItems};
10
+ color: ${theme.color};
11
+ font-weight: ${theme.typography.fontWeight};
12
+ font-size: ${theme.typography.fontSize};
13
+ line-height: ${theme.typography.lineHeight};
14
+ border-width: ${theme.borderWidth};
15
+ border-style: ${theme.borderStyle};
16
+ border-color: ${theme.borderColor};
17
+ border-radius: ${theme.borderRadius};
18
+ padding: ${theme.paddingY} ${theme.paddingX};
19
+ box-sizing: ${theme.boxSizing};
20
+ width: ${theme.width};
21
+ gap: ${theme.gap};
22
+ svg {
23
+ height: ${theme.svg.height};
24
+ width: ${theme.svg.width};
25
+ }
26
+ `;
27
+
28
+ export { defaultIntendedAudienceSignifierTheme, intendedAudienceSignifierStyles };
@@ -0,0 +1,37 @@
1
+ 'use strict';
2
+
3
+ var jsxRuntime = require('@emotion/react/jsx-runtime');
4
+ var reactAriaComponents = require('react-aria-components');
5
+ var colors = require('../../styleD/build/typescript/semantic/colors.cjs');
6
+ var mergeDeep = require('../../util/mergeDeep.cjs');
7
+ var styles = require('../typography/styles.cjs');
8
+ var styles$1 = require('./styles.cjs');
9
+
10
+ function Link({
11
+ children,
12
+ typography = "body-sm",
13
+ theme = {},
14
+ cssOverrides,
15
+ className,
16
+ ...props
17
+ }) {
18
+ const mergedTheme = mergeDeep.mergeDeep(styles$1.defaultLinkTheme, theme);
19
+ return /* @__PURE__ */ jsxRuntime.jsx(
20
+ reactAriaComponents.Link,
21
+ {
22
+ css: [
23
+ styles.typographyStyles(
24
+ { color: colors.semanticColors.text.strong },
25
+ { variant: typography }
26
+ ),
27
+ styles$1.linkStyles(mergedTheme),
28
+ cssOverrides
29
+ ],
30
+ className,
31
+ ...props,
32
+ children
33
+ }
34
+ );
35
+ }
36
+
37
+ exports.Link = Link;
@@ -0,0 +1,17 @@
1
+ import { jsx } from '@emotion/react/jsx-runtime';
2
+ import { Link as Link$1 } from 'react-aria-components';
3
+ import { semanticColors } from '../../styleD/build/typescript/semantic/colors.js';
4
+ import { mergeDeep } from '../../util/mergeDeep.js';
5
+ import { typographyStyles } from '../typography/styles.js';
6
+ import { linkStyles, defaultLinkTheme } from './styles.js';
7
+
8
+ function Link({ children, typography = "body-sm", theme = {}, cssOverrides, className, ...props }) {
9
+ const mergedTheme = mergeDeep(defaultLinkTheme, theme);
10
+ return jsx(Link$1, { css: [
11
+ typographyStyles({ color: semanticColors.text.strong }, { variant: typography }),
12
+ linkStyles(mergedTheme),
13
+ cssOverrides
14
+ ], className, ...props, children });
15
+ }
16
+
17
+ export { Link };
@@ -0,0 +1,31 @@
1
+ 'use strict';
2
+
3
+ var react = require('@emotion/react');
4
+ var link = require('../../styleD/build/typescript/component/link.cjs');
5
+
6
+ const defaultLinkTheme = link.componentLink;
7
+ const linkStyles = (theme) => {
8
+ return react.css`
9
+ text-decoration: underline;
10
+ text-decoration-style: solid;
11
+ text-underline-offset: 8%;
12
+ text-decoration-thickness: 5%;
13
+ ${theme.shared.enabled};
14
+ &[data-hovered] {
15
+ color: ${theme.shared.hover.color};
16
+ cursor: ${theme.shared.hover.cursor};
17
+ }
18
+ &[data-pressed] {
19
+ color: ${theme.shared.pressed.color};
20
+ }
21
+ &[data-disabled] {
22
+ color: ${theme.shared.disabled.color};
23
+ }
24
+ &[data-focus-visible] {
25
+ outline: ${theme.shared.focus.outline};
26
+ }
27
+ `;
28
+ };
29
+
30
+ exports.defaultLinkTheme = defaultLinkTheme;
31
+ exports.linkStyles = linkStyles;
@@ -0,0 +1,28 @@
1
+ import { css } from '@emotion/react';
2
+ import { componentLink } from '../../styleD/build/typescript/component/link.js';
3
+
4
+ const defaultLinkTheme = componentLink;
5
+ const linkStyles = (theme) => {
6
+ return css`
7
+ text-decoration: underline;
8
+ text-decoration-style: solid;
9
+ text-underline-offset: 8%;
10
+ text-decoration-thickness: 5%;
11
+ ${theme.shared.enabled};
12
+ &[data-hovered] {
13
+ color: ${theme.shared.hover.color};
14
+ cursor: ${theme.shared.hover.cursor};
15
+ }
16
+ &[data-pressed] {
17
+ color: ${theme.shared.pressed.color};
18
+ }
19
+ &[data-disabled] {
20
+ color: ${theme.shared.disabled.color};
21
+ }
22
+ &[data-focus-visible] {
23
+ outline: ${theme.shared.focus.outline};
24
+ }
25
+ `;
26
+ };
27
+
28
+ export { defaultLinkTheme, linkStyles };
package/dist/index.cjs CHANGED
@@ -4,7 +4,7 @@ var autocomplete = require('./styleD/build/typescript/component/autocomplete.cjs
4
4
  var byline = require('./styleD/build/typescript/component/byline.cjs');
5
5
  var tagTable = require('./styleD/build/typescript/component/tagTable.cjs');
6
6
  var userMenu = require('./styleD/build/typescript/component/userMenu.cjs');
7
- var alertBanner = require('./styleD/build/typescript/component/alertBanner.cjs');
7
+ var intendedAudienceSignifier = require('./styleD/build/typescript/component/intendedAudienceSignifier.cjs');
8
8
  var avatar = require('./styleD/build/typescript/component/avatar.cjs');
9
9
  var button = require('./styleD/build/typescript/component/button.cjs');
10
10
  var checkbox = require('./styleD/build/typescript/component/checkbox.cjs');
@@ -14,6 +14,8 @@ var form = require('./styleD/build/typescript/component/form.cjs');
14
14
  var icon = require('./styleD/build/typescript/component/icon.cjs');
15
15
  var inlineMessage = require('./styleD/build/typescript/component/inlineMessage.cjs');
16
16
  var menu = require('./styleD/build/typescript/component/menu.cjs');
17
+ var link = require('./styleD/build/typescript/component/link.cjs');
18
+ var alertBanner = require('./styleD/build/typescript/component/alertBanner.cjs');
17
19
  var radioGroup = require('./styleD/build/typescript/component/radioGroup.cjs');
18
20
  var select = require('./styleD/build/typescript/component/select.cjs');
19
21
  var textArea = require('./styleD/build/typescript/component/textArea.cjs');
@@ -37,7 +39,7 @@ exports.componentAutocomplete = autocomplete.componentAutocomplete;
37
39
  exports.componentByline = byline.componentByline;
38
40
  exports.componentTagTable = tagTable.componentTagTable;
39
41
  exports.componentUserMenu = userMenu.componentUserMenu;
40
- exports.componentAlertBanner = alertBanner.componentAlertBanner;
42
+ exports.componentIntendedAudienceSignifier = intendedAudienceSignifier.componentIntendedAudienceSignifier;
41
43
  exports.componentAvatar = avatar.componentAvatar;
42
44
  exports.componentButton = button.componentButton;
43
45
  exports.componentCheckbox = checkbox.componentCheckbox;
@@ -47,6 +49,8 @@ exports.componentForm = form.componentForm;
47
49
  exports.componentIcon = icon.componentIcon;
48
50
  exports.componentInlineMessage = inlineMessage.componentInlineMessage;
49
51
  exports.componentMenu = menu.componentMenu;
52
+ exports.componentLink = link.componentLink;
53
+ exports.componentAlertBanner = alertBanner.componentAlertBanner;
50
54
  exports.componentRadioGroup = radioGroup.componentRadioGroup;
51
55
  exports.componentSelect = select.componentSelect;
52
56
  exports.componentTextArea = textArea.componentTextArea;
package/dist/index.js CHANGED
@@ -2,7 +2,7 @@ export { componentAutocomplete } from './styleD/build/typescript/component/autoc
2
2
  export { componentByline } from './styleD/build/typescript/component/byline.js';
3
3
  export { componentTagTable } from './styleD/build/typescript/component/tagTable.js';
4
4
  export { componentUserMenu } from './styleD/build/typescript/component/userMenu.js';
5
- export { componentAlertBanner } from './styleD/build/typescript/component/alertBanner.js';
5
+ export { componentIntendedAudienceSignifier } from './styleD/build/typescript/component/intendedAudienceSignifier.js';
6
6
  export { componentAvatar } from './styleD/build/typescript/component/avatar.js';
7
7
  export { componentButton } from './styleD/build/typescript/component/button.js';
8
8
  export { componentCheckbox } from './styleD/build/typescript/component/checkbox.js';
@@ -12,6 +12,8 @@ export { componentForm } from './styleD/build/typescript/component/form.js';
12
12
  export { componentIcon } from './styleD/build/typescript/component/icon.js';
13
13
  export { componentInlineMessage } from './styleD/build/typescript/component/inlineMessage.js';
14
14
  export { componentMenu } from './styleD/build/typescript/component/menu.js';
15
+ export { componentLink } from './styleD/build/typescript/component/link.js';
16
+ export { componentAlertBanner } from './styleD/build/typescript/component/alertBanner.js';
15
17
  export { componentRadioGroup } from './styleD/build/typescript/component/radioGroup.js';
16
18
  export { componentSelect } from './styleD/build/typescript/component/select.js';
17
19
  export { componentTextArea } from './styleD/build/typescript/component/textArea.js';
@@ -0,0 +1,9 @@
1
+ 'use strict';
2
+
3
+ var IntendedAudienceSignifier = require('./components/intended-audience-signifier/IntendedAudienceSignifier.cjs');
4
+ var intendedAudienceSignifier = require('./styleD/build/typescript/component/intendedAudienceSignifier.cjs');
5
+
6
+
7
+
8
+ exports.IntendedAudienceSignifier = IntendedAudienceSignifier.IntendedAudienceSignifier;
9
+ exports.componentIntendedAudienceSignifier = intendedAudienceSignifier.componentIntendedAudienceSignifier;
@@ -0,0 +1,2 @@
1
+ export { IntendedAudienceSignifier } from './components/intended-audience-signifier/IntendedAudienceSignifier.js';
2
+ export { componentIntendedAudienceSignifier } from './styleD/build/typescript/component/intendedAudienceSignifier.js';
package/dist/link.cjs ADDED
@@ -0,0 +1,9 @@
1
+ 'use strict';
2
+
3
+ var Link = require('./components/link/Link.cjs');
4
+ var link = require('./styleD/build/typescript/component/link.cjs');
5
+
6
+
7
+
8
+ exports.Link = Link.Link;
9
+ exports.componentLink = link.componentLink;
package/dist/link.js ADDED
@@ -0,0 +1,2 @@
1
+ export { Link } from './components/link/Link.js';
2
+ export { componentLink } from './styleD/build/typescript/component/link.js';
@@ -51,9 +51,9 @@
51
51
  --base-typography-letter-spacing-densest-px: -1px;
52
52
  --base-typography-letter-spacing-denser-px: -0.5px;
53
53
  --base-typography-letter-spacing-dense-px: -0.2px;
54
- --base-typography-letter-spacing-default-px: 0;
54
+ --base-typography-letter-spacing-default-px: 0px;
55
55
  --base-typography-letter-spacing-densest-rem: -0.0625rem;
56
56
  --base-typography-letter-spacing-denser-rem: -0.03125rem;
57
57
  --base-typography-letter-spacing-dense-rem: -0.0125rem;
58
- --base-typography-letter-spacing-default-rem: 0;
58
+ --base-typography-letter-spacing-default-rem: 0rem;
59
59
  }
@@ -82,7 +82,7 @@
82
82
  --component-top-bar-tool-name-gap: 8px;
83
83
  --component-top-bar-tool-name-typography-font: normal 700 1.25rem/1.15
84
84
  'GH Guardian Headline';
85
- --component-top-bar-tool-name-typography-letter-spacing: 0;
85
+ --component-top-bar-tool-name-typography-letter-spacing: 0rem;
86
86
  --component-top-bar-tool-name-typography-font-width: 100;
87
87
  --component-top-bar-tool-name-divider-border: 0.0625rem solid #cccccc;
88
88
  --component-top-bar-tool-name-divider-height: 2rem;
@@ -103,7 +103,7 @@
103
103
  --component-top-bar-tool-name-hover-link-opacity: 0;
104
104
  --component-top-bar-tool-name-hover-link-typography-font: normal 700
105
105
  0.875rem/1.3 'Open Sans';
106
- --component-top-bar-tool-name-hover-link-typography-letter-spacing: 0;
106
+ --component-top-bar-tool-name-hover-link-typography-letter-spacing: 0rem;
107
107
  --component-top-bar-tool-name-hover-link-typography-font-width: 95;
108
108
  --component-top-bar-tool-name-hover-link-position: absolute;
109
109
  --component-top-bar-tool-name-hover-link-width: 100%;
@@ -21,7 +21,7 @@
21
21
  --component-alert-banner-shared-content-color: #000000;
22
22
  --component-alert-banner-shared-content-typography-font: normal 460
23
23
  0.875rem/1.3 'Open Sans';
24
- --component-alert-banner-shared-content-typography-letter-spacing: 0;
24
+ --component-alert-banner-shared-content-typography-letter-spacing: 0rem;
25
25
  --component-alert-banner-shared-content-typography-font-width: 95;
26
26
  --component-alert-banner-shared-content-icon-color: #545454;
27
27
  --component-alert-banner-information-background-color: #e8f0fb;
@@ -14,7 +14,7 @@
14
14
  --component-autocomplete-listbox-border-style: solid;
15
15
  --component-autocomplete-listbox-border-color: #8d8d8d;
16
16
  --component-autocomplete-listbox-padding-y: 8px;
17
- --component-autocomplete-listbox-padding-x: 0;
17
+ --component-autocomplete-listbox-padding-x: 0px;
18
18
  --component-autocomplete-listbox-background-color: #ffffff;
19
19
  --component-autocomplete-listbox-item-padding-y: 8px;
20
20
  --component-autocomplete-listbox-item-padding-x: 12px;
@@ -76,7 +76,7 @@
76
76
  --component-avatar-shared-button-disabled-cursor: not-allowed;
77
77
  --component-avatar-sm-size: 2rem;
78
78
  --component-avatar-sm-typography-font: normal 700 0.75rem/1 'Open Sans';
79
- --component-avatar-sm-typography-letter-spacing: 0;
79
+ --component-avatar-sm-typography-letter-spacing: 0rem;
80
80
  --component-avatar-sm-typography-font-width: 95;
81
81
  --component-avatar-md-size: 2.5rem;
82
82
  --component-avatar-md-typography-font: normal 700 0.875rem/1 'Open Sans';
@@ -33,7 +33,7 @@
33
33
  --component-button-primary-xs-padding-with-icon-icon-left-left: 0.25rem;
34
34
  --component-button-primary-xs-typography-font: normal 700 0.75rem/1
35
35
  'Open Sans';
36
- --component-button-primary-xs-typography-letter-spacing: 0;
36
+ --component-button-primary-xs-typography-letter-spacing: 0rem;
37
37
  --component-button-primary-xs-typography-font-width: 95;
38
38
  --component-button-primary-xs-icon-size: 1.125rem;
39
39
  --component-button-primary-xs-icon-gap: 0.25rem;
@@ -95,7 +95,7 @@
95
95
  --component-button-secondary-xs-padding-with-icon-icon-left-left: 0.25rem;
96
96
  --component-button-secondary-xs-typography-font: normal 700 0.75rem/1
97
97
  'Open Sans';
98
- --component-button-secondary-xs-typography-letter-spacing: 0;
98
+ --component-button-secondary-xs-typography-letter-spacing: 0rem;
99
99
  --component-button-secondary-xs-typography-font-width: 95;
100
100
  --component-button-secondary-xs-icon-size: 1.125rem;
101
101
  --component-button-secondary-xs-icon-gap: 0.25rem;
@@ -157,7 +157,7 @@
157
157
  --component-button-tertiary-xs-padding-with-icon-icon-left-left: 0.25rem;
158
158
  --component-button-tertiary-xs-typography-font: normal 700 0.75rem/1
159
159
  'Open Sans';
160
- --component-button-tertiary-xs-typography-letter-spacing: 0;
160
+ --component-button-tertiary-xs-typography-letter-spacing: 0rem;
161
161
  --component-button-tertiary-xs-typography-font-width: 95;
162
162
  --component-button-tertiary-xs-icon-size: 1.125rem;
163
163
  --component-button-tertiary-xs-icon-gap: 0.25rem;
@@ -39,11 +39,11 @@
39
39
  --component-checkbox-input-shared-disabled-indicator-selected-background-color: #dcdcdc;
40
40
  --component-checkbox-input-sm-typography-font: normal 460 0.875rem/1.3
41
41
  'Open Sans';
42
- --component-checkbox-input-sm-typography-letter-spacing: 0;
42
+ --component-checkbox-input-sm-typography-letter-spacing: 0rem;
43
43
  --component-checkbox-input-sm-typography-font-width: 95;
44
44
  --component-checkbox-input-sm-indicator-size: 1.25rem;
45
45
  --component-checkbox-input-md-typography-font: normal 460 1rem/1.3 'Open Sans';
46
- --component-checkbox-input-md-typography-letter-spacing: 0;
46
+ --component-checkbox-input-md-typography-letter-spacing: 0rem;
47
47
  --component-checkbox-input-md-typography-font-width: 95;
48
48
  --component-checkbox-input-md-indicator-size: 1.5rem;
49
49
  --component-checkbox-group-shared-display: flex;
@@ -12,6 +12,6 @@
12
12
  --component-favicon-user-select: none;
13
13
  --component-favicon-typography-font: normal 700 1.25rem/1.15
14
14
  'GH Guardian Headline';
15
- --component-favicon-typography-letter-spacing: 0;
15
+ --component-favicon-typography-letter-spacing: 0rem;
16
16
  --component-favicon-typography-font-width: 100;
17
17
  }
@@ -12,7 +12,7 @@
12
12
  --component-form-input-shared-description-color: #545454;
13
13
  --component-form-input-shared-description-typography-font: normal 460
14
14
  0.875rem/1.3 'Open Sans';
15
- --component-form-input-shared-description-typography-letter-spacing: 0;
15
+ --component-form-input-shared-description-typography-letter-spacing: 0rem;
16
16
  --component-form-input-shared-description-typography-font-width: 95;
17
17
  --component-form-input-shared-description-disabled-color: #999999;
18
18
  --component-form-input-sm-label-typography-font: normal 700 0.875rem/1.15
@@ -10,7 +10,7 @@
10
10
  --component-inline-message-shared-icon-align-self: flex-start;
11
11
  --component-inline-message-shared-typography-font: normal 460 0.875rem/1.3
12
12
  'Open Sans';
13
- --component-inline-message-shared-typography-letter-spacing: 0;
13
+ --component-inline-message-shared-typography-letter-spacing: 0rem;
14
14
  --component-inline-message-shared-typography-font-width: 95;
15
15
  --component-inline-message-error-color: #8c2113;
16
16
  --component-inline-message-success-color: #326528;