@coopdigital/react 0.19.1 → 0.19.3

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 (77) hide show
  1. package/dist/components/AlertBanner/AlertBanner.d.ts +4 -14
  2. package/dist/components/AlertBanner/AlertBanner.js +0 -10
  3. package/dist/components/Author/Author.d.ts +5 -8
  4. package/dist/components/Author/Author.js +0 -3
  5. package/dist/components/Button/Button.d.ts +0 -3
  6. package/dist/components/Button/Button.js +0 -3
  7. package/dist/components/Card/Card.d.ts +0 -3
  8. package/dist/components/Card/Card.js +0 -3
  9. package/dist/components/Expandable/Expandable.d.ts +0 -4
  10. package/dist/components/Expandable/Expandable.js +0 -4
  11. package/dist/components/Icon/AddIcon.js +12 -0
  12. package/dist/components/Icon/ArrowDownIcon.js +12 -0
  13. package/dist/components/Icon/ArrowLeftIcon.js +12 -0
  14. package/dist/components/Icon/ArrowRightIcon.js +12 -0
  15. package/dist/components/Icon/ArrowUpIcon.js +12 -0
  16. package/dist/components/Icon/AvatarAltIcon.js +12 -0
  17. package/dist/components/Icon/AvatarIcon.js +12 -0
  18. package/dist/components/Icon/BasketIcon.js +12 -0
  19. package/dist/components/Icon/CalendarIcon.js +12 -0
  20. package/dist/components/Icon/ChevronDownIcon.js +12 -0
  21. package/dist/components/Icon/ChevronLeftIcon.js +12 -0
  22. package/dist/components/Icon/ChevronRightIcon.js +12 -0
  23. package/dist/components/Icon/ChevronUpIcon.js +12 -0
  24. package/dist/components/Icon/ClockIcon.js +12 -0
  25. package/dist/components/Icon/CloseAltIcon.js +12 -0
  26. package/dist/components/Icon/CloseIcon.js +12 -0
  27. package/dist/components/Icon/CoopCardIcon.js +12 -0
  28. package/dist/components/Icon/CoopIcon.js +12 -0
  29. package/dist/components/Icon/CoopLocationIcon.js +12 -0
  30. package/dist/components/Icon/DownloadIcon.js +12 -0
  31. package/dist/components/Icon/HomeIcon.js +12 -0
  32. package/dist/components/Icon/InformationIcon.js +12 -0
  33. package/dist/components/Icon/LocationIcon.js +12 -0
  34. package/dist/components/Icon/MailIcon.js +12 -0
  35. package/dist/components/Icon/MenuIcon.js +12 -0
  36. package/dist/components/Icon/MessageIcon.js +12 -0
  37. package/dist/components/Icon/MinusIcon.js +12 -0
  38. package/dist/components/Icon/OpenNewIcon.js +12 -0
  39. package/dist/components/Icon/PencilIcon.js +12 -0
  40. package/dist/components/Icon/PhoneIcon.js +12 -0
  41. package/dist/components/Icon/QuestionIcon.js +12 -0
  42. package/dist/components/Icon/ScooterIcon.js +12 -0
  43. package/dist/components/Icon/SettingsIcon.js +12 -0
  44. package/dist/components/Icon/TickAltIcon.js +12 -0
  45. package/dist/components/Icon/TickIcon.js +12 -0
  46. package/dist/components/Icon/VanIcon.js +12 -0
  47. package/dist/components/Icon/WarningIcon.js +12 -0
  48. package/dist/components/Icon/WriteIcon.js +12 -0
  49. package/dist/components/Icon/index.js +40 -0
  50. package/dist/components/Image/Image.d.ts +0 -3
  51. package/dist/components/Image/Image.js +0 -3
  52. package/dist/components/Pill/Pill.d.ts +0 -3
  53. package/dist/components/Pill/Pill.js +0 -3
  54. package/dist/components/SearchBox/SearchBox.d.ts +0 -17
  55. package/dist/components/SearchBox/SearchBox.js +0 -17
  56. package/dist/components/Signpost/Signpost.d.ts +0 -3
  57. package/dist/components/Signpost/Signpost.js +0 -3
  58. package/dist/components/SkipNav/SkipNav.d.ts +0 -17
  59. package/dist/components/SkipNav/SkipNav.js +0 -17
  60. package/dist/components/Squircle/Squircle.d.ts +2 -5
  61. package/dist/components/Squircle/Squircle.js +0 -3
  62. package/dist/components/Tag/Tag.d.ts +0 -10
  63. package/dist/components/Tag/Tag.js +0 -10
  64. package/package.json +8 -3
  65. package/src/components/AlertBanner/AlertBanner.tsx +4 -14
  66. package/src/components/Author/Author.tsx +5 -9
  67. package/src/components/Button/Button.tsx +0 -3
  68. package/src/components/Card/Card.tsx +0 -3
  69. package/src/components/Expandable/Expandable.tsx +0 -5
  70. package/src/components/Image/Image.tsx +0 -3
  71. package/src/components/Pill/Pill.tsx +0 -3
  72. package/src/components/SearchBox/SearchBox.tsx +0 -17
  73. package/src/components/Signpost/Signpost.tsx +0 -4
  74. package/src/components/SkipNav/SkipNav.tsx +0 -17
  75. package/src/components/Squircle/Squircle.tsx +2 -6
  76. package/src/components/Tag/Tag.tsx +0 -11
  77. /package/src/components/Icon/{index.tsx → index.ts} +0 -0
@@ -0,0 +1,12 @@
1
+ import { __rest } from '../../node_modules/tslib/tslib.es6.js';
2
+ import { jsxs, jsx } from 'react/jsx-runtime';
3
+ import { useId } from 'react';
4
+
5
+ const QuestionIcon = (_a) => {
6
+ var { alt, className } = _a, props = __rest(_a, ["alt", "className"]);
7
+ const id = useId();
8
+ const componentProps = Object.assign({ "aria-labelledby": alt ? id : undefined, className: `coop-icon ${className !== null && className !== void 0 ? className : ""}`.trim(), "data-icon": "question", fill: "none", role: alt ? "img" : undefined, viewBox: "0 0 32 32" }, props);
9
+ return (jsxs("svg", Object.assign({}, componentProps, { children: [alt ? jsx("title", { id: id, children: alt }) : null, jsx("path", { d: "M16 0a16 16 0 1 0 16 16A16 16 0 0 0 16 0m0 30a14 14 0 1 1 14-14 14 14 0 0 1-14 14", fill: "currentColor" }), jsx("path", { d: "M15.89 20.32a1.58 1.58 0 0 0-1.14.46 1.5 1.5 0 0 0-.47 1.1 1.3 1.3 0 0 0 .13.6 1.6 1.6 0 0 0 .35.48 1.7 1.7 0 0 0 .51.33 1.6 1.6 0 0 0 .62.12 1.55 1.55 0 0 0 1.11-.47 1.48 1.48 0 0 0 .47-1.1 1.4 1.4 0 0 0-.47-1.08 1.6 1.6 0 0 0-1.11-.44M19.11 9.71A4.3 4.3 0 0 0 17.74 9a5.2 5.2 0 0 0-1.63-.25 5.4 5.4 0 0 0-1.73.25 4.5 4.5 0 0 0-1.38.78 4.3 4.3 0 0 0-1 1.28 5 5 0 0 0-.51 1.71l2.41.23a2.7 2.7 0 0 1 .16-.78 1.9 1.9 0 0 1 .41-.67 2.1 2.1 0 0 1 .64-.46 1.9 1.9 0 0 1 .84-.17 1.78 1.78 0 0 1 1.39.53 1.84 1.84 0 0 1 .49 1.31 1.9 1.9 0 0 1-.27 1 4 4 0 0 1-.65.76l-.9.86a5.4 5.4 0 0 0-.63.68 3.05 3.05 0 0 0-.63 1.39 5.4 5.4 0 0 0-.07.86v.76h2.37v-.52a4 4 0 0 1 .06-.74 1.8 1.8 0 0 1 .21-.56 2.7 2.7 0 0 1 .4-.52c.17-.18.39-.38.65-.61s.59-.52.84-.77a5 5 0 0 0 .63-.77 3.4 3.4 0 0 0 .4-.88 4.2 4.2 0 0 0 .14-1.13 3.8 3.8 0 0 0-.38-1.64 3.6 3.6 0 0 0-.89-1.22", fill: "currentColor" })] })));
10
+ };
11
+
12
+ export { QuestionIcon };
@@ -0,0 +1,12 @@
1
+ import { __rest } from '../../node_modules/tslib/tslib.es6.js';
2
+ import { jsxs, jsx } from 'react/jsx-runtime';
3
+ import { useId } from 'react';
4
+
5
+ const ScooterIcon = (_a) => {
6
+ var { alt, className } = _a, props = __rest(_a, ["alt", "className"]);
7
+ const id = useId();
8
+ const componentProps = Object.assign({ "aria-labelledby": alt ? id : undefined, className: `coop-icon ${className !== null && className !== void 0 ? className : ""}`.trim(), "data-icon": "scooter", fill: "none", role: alt ? "img" : undefined, viewBox: "0 0 32 32" }, props);
9
+ return (jsxs("svg", Object.assign({}, componentProps, { children: [alt ? jsx("title", { id: id, children: alt }) : null, jsxs("g", { clipPath: "url(#a)", clipRule: "evenodd", fill: "currentColor", fillRule: "evenodd", children: [jsx("path", { d: "M41.292 18.293a1 1 0 0 1 1.414 0C43.88 19.465 44.6 21.014 44.6 22.8c0 3.452-2.747 6.2-6.2 6.2-3.333 0-6.08-2.622-6.2-5.964a1 1 0 1 1 2-.072 4.19 4.19 0 0 0 4.2 4.036c2.348 0 4.2-1.852 4.2-4.2 0-1.214-.48-2.265-1.307-3.093a1 1 0 0 1 0-1.414M1.1 23a9.28 9.28 0 0 1 9.3-9.3 9.28 9.28 0 0 1 9.3 9.3 1 1 0 0 1-1 1H2.1a1 1 0 0 1-1-1m2.067-1h14.466a7.28 7.28 0 0 0-7.233-6.3A7.28 7.28 0 0 0 3.167 22" }), jsx("path", { d: "M34.754 13.161c3.98-1.476 8.72.438 10.545 4.203a1 1 0 1 1-1.8.872c-1.374-2.834-5.032-4.32-8.052-3.199l-.006.003c-.933.339-1.796.939-2.494 1.724a1 1 0 0 1-1.495-1.328c.9-1.014 2.036-1.813 3.302-2.275M10.4 29.3a6.164 6.164 0 0 1-6.2-6.2h2c0 2.348 1.852 4.2 4.2 4.2s4.2-1.852 4.2-4.2h2c0 3.452-2.749 6.2-6.2 6.2", fill: "currentColor" }), jsx("path", { d: "M21.3 1a1 1 0 0 1 1-1h5.1a1 1 0 0 1 .869.503l7.1 12.4a1 1 0 1 1-1.736.994L26.821 2h-4.52a1 1 0 0 1-1-1M8.585 9.2c3.42-.1 6.556-.012 9.806 1.829 2.713 1.52 4.878 4.116 5.858 7.055a1 1 0 0 1-1.898.632c-.82-2.46-2.654-4.663-4.94-5.943l-.004-.003c-2.745-1.555-5.404-1.67-8.778-1.57H8a1 1 0 1 1 0-2z", fill: "currentColor" }), jsx("path", { d: "M45.33 17.434a1 1 0 0 1-.564 1.297l-12.2 4.8-.05.018c-.966.322-1.976.551-3.116.551H2.1a1 1 0 1 1 0-2h27.3c.851 0 1.634-.167 2.459-.44l12.174-4.79a1 1 0 0 1 1.297.564M0 5.7a1 1 0 0 1 1-1h9.9a1 1 0 1 1 0 2H1a1 1 0 0 1-1-1M1.8 10.2a1 1 0 0 1 1-1h2a1 1 0 1 1 0 2h-2a1 1 0 0 1-1-1M3.2 1a1 1 0 0 1 1-1h7.1a1 1 0 1 1 0 2H4.2a1 1 0 0 1-1-1", fill: "currentColor" })] }), jsx("defs", { children: jsx("clipPath", { id: "a", children: jsx("path", { d: "M0 0h45.4v29.3H0z", fill: "currentColor" }) }) })] })));
10
+ };
11
+
12
+ export { ScooterIcon };
@@ -0,0 +1,12 @@
1
+ import { __rest } from '../../node_modules/tslib/tslib.es6.js';
2
+ import { jsxs, jsx } from 'react/jsx-runtime';
3
+ import { useId } from 'react';
4
+
5
+ const SettingsIcon = (_a) => {
6
+ var { alt, className } = _a, props = __rest(_a, ["alt", "className"]);
7
+ const id = useId();
8
+ const componentProps = Object.assign({ "aria-labelledby": alt ? id : undefined, className: `coop-icon ${className !== null && className !== void 0 ? className : ""}`.trim(), "data-icon": "settings", fill: "none", role: alt ? "img" : undefined, viewBox: "0 0 32 32" }, props);
9
+ return (jsxs("svg", Object.assign({}, componentProps, { children: [alt ? jsx("title", { id: id, children: alt }) : null, jsx("path", { d: "M16 2a14 14 0 0 1 2.13.16v3.57l1.34.47a10.2 10.2 0 0 1 3.27 1.89l1.08.91 1.23-.71 1.86-1.08a14 14 0 0 1 2.14 3.69L27.18 12l-1.18.7.26 1.39a10.6 10.6 0 0 1 0 3.8L26 19.28l1.23.71 1.88 1.09a14.2 14.2 0 0 1-2.14 3.69l-1.86-1.08-1.28-.69-1.07.92a10.6 10.6 0 0 1-3.3 1.9l-1.33.47v3.57A14 14 0 0 1 16 30a14 14 0 0 1-2.13-.16v-3.57l-1.34-.47a10.2 10.2 0 0 1-3.27-1.9L8.18 23 7 23.69l-1.91 1.08A14.1 14.1 0 0 1 3 21.08L4.82 20l1.23-.71-.26-1.39a10.6 10.6 0 0 1 0-3.8l.26-1.39L4.82 12 3 10.92a14.5 14.5 0 0 1 2.08-3.69l1.86 1.08L8.16 9l1.08-.9a10.6 10.6 0 0 1 3.3-1.9l1.33-.47V2.16A14 14 0 0 1 16 2m0 21a7 7 0 1 0-7-7 7 7 0 0 0 7 7m0-23a16 16 0 0 0-3.53.39.76.76 0 0 0-.6.75v3.18a12.7 12.7 0 0 0-3.93 2.26L5.2 5a.75.75 0 0 0-.38-.1.77.77 0 0 0-.57.25 15.9 15.9 0 0 0-3.53 6.1.78.78 0 0 0 .35.91l2.75 1.59a12.3 12.3 0 0 0 0 4.52l-2.75 1.58a.79.79 0 0 0-.35.9 16 16 0 0 0 3.53 6.11.8.8 0 0 0 .57.25.7.7 0 0 0 .38-.11L8 25.42a12.3 12.3 0 0 0 3.92 2.26v3.18a.77.77 0 0 0 .61.75A16.2 16.2 0 0 0 16 32a16 16 0 0 0 3.53-.39.76.76 0 0 0 .6-.75v-3.18a12.5 12.5 0 0 0 3.92-2.26L26.8 27a.79.79 0 0 0 1-.15 16 16 0 0 0 3.53-6.11.8.8 0 0 0-.36-.9l-2.75-1.59a12.8 12.8 0 0 0 0-4.53l2.75-1.59a.78.78 0 0 0 .35-.9 16.1 16.1 0 0 0-3.53-6.1.76.76 0 0 0-.57-.26.73.73 0 0 0-.42.13l-2.75 1.57a12.3 12.3 0 0 0-3.92-2.26V1.14a.77.77 0 0 0-.61-.75A16.2 16.2 0 0 0 16 0m0 21a5 5 0 1 1 5-5 5 5 0 0 1-5 5", fill: "currentColor" })] })));
10
+ };
11
+
12
+ export { SettingsIcon };
@@ -0,0 +1,12 @@
1
+ import { __rest } from '../../node_modules/tslib/tslib.es6.js';
2
+ import { jsxs, jsx } from 'react/jsx-runtime';
3
+ import { useId } from 'react';
4
+
5
+ const TickAltIcon = (_a) => {
6
+ var { alt, className } = _a, props = __rest(_a, ["alt", "className"]);
7
+ const id = useId();
8
+ const componentProps = Object.assign({ "aria-labelledby": alt ? id : undefined, className: `coop-icon ${className !== null && className !== void 0 ? className : ""}`.trim(), "data-icon": "tick-alt", fill: "none", role: alt ? "img" : undefined, viewBox: "0 0 32 32" }, props);
9
+ return (jsxs("svg", Object.assign({}, componentProps, { children: [alt ? jsx("title", { id: id, children: alt }) : null, jsx("path", { d: "M12.7 22a1 1 0 0 1-.71-.29L8.3 18a1 1 0 0 1 0-1.42 1 1 0 0 1 1.41 0l3 3 9.41-9.38a1 1 0 0 1 1.42 0 1 1 0 0 1 0 1.41L13.4 21.69a1 1 0 0 1-.7.31", fill: "currentColor" }), jsx("path", { d: "M16 2A14 14 0 1 1 2 16 14 14 0 0 1 16 2m0-2a16 16 0 1 0 16 16A16 16 0 0 0 16 0", fill: "currentColor" })] })));
10
+ };
11
+
12
+ export { TickAltIcon };
@@ -0,0 +1,12 @@
1
+ import { __rest } from '../../node_modules/tslib/tslib.es6.js';
2
+ import { jsxs, jsx } from 'react/jsx-runtime';
3
+ import { useId } from 'react';
4
+
5
+ const TickIcon = (_a) => {
6
+ var { alt, className } = _a, props = __rest(_a, ["alt", "className"]);
7
+ const id = useId();
8
+ const componentProps = Object.assign({ "aria-labelledby": alt ? id : undefined, className: `coop-icon ${className !== null && className !== void 0 ? className : ""}`.trim(), "data-icon": "tick", fill: "none", role: alt ? "img" : undefined, viewBox: "0 0 32 32" }, props);
9
+ return (jsxs("svg", Object.assign({}, componentProps, { children: [alt ? jsx("title", { id: id, children: alt }) : null, jsx("path", { d: "M10.41 26a1 1 0 0 1-.71-.3l-6.42-6.59a1 1 0 0 1 1.44-1.39l5.69 5.85L27.28 6.3a1 1 0 1 1 1.44 1.4l-17.59 18a1 1 0 0 1-.72.3", fill: "currentColor" })] })));
10
+ };
11
+
12
+ export { TickIcon };
@@ -0,0 +1,12 @@
1
+ import { __rest } from '../../node_modules/tslib/tslib.es6.js';
2
+ import { jsxs, jsx } from 'react/jsx-runtime';
3
+ import { useId } from 'react';
4
+
5
+ const VanIcon = (_a) => {
6
+ var { alt, className } = _a, props = __rest(_a, ["alt", "className"]);
7
+ const id = useId();
8
+ const componentProps = Object.assign({ "aria-labelledby": alt ? id : undefined, className: `coop-icon ${className !== null && className !== void 0 ? className : ""}`.trim(), "data-icon": "van", fill: "none", role: alt ? "img" : undefined, viewBox: "0 0 32 32" }, props);
9
+ return (jsxs("svg", Object.assign({}, componentProps, { children: [alt ? jsx("title", { id: id, children: alt }) : null, jsx("path", { d: "M31.05 3H9.8a1 1 0 0 0-1 1v.2H3.06a1 1 0 0 0-1 .86L.89 12.64a1 1 0 0 0-.89 1v10a1 1 0 0 0 1 1h3a5 5 0 0 0 9.9 0H18a5 5 0 0 0 9.89 0h3.21a1 1 0 0 0 .72-.3 1 1 0 0 0 .18-.72V4a1 1 0 0 0-.95-1M3.91 6.24H8.8v6.38H2.93ZM8.92 27A3 3 0 0 1 6 24.71a2.9 2.9 0 0 1-.12-.83 3.1 3.1 0 0 1 .25-1.22 3 3 0 0 1 5.53 0 3.3 3.3 0 0 1 .24 1.22 3.3 3.3 0 0 1-.11.83A3 3 0 0 1 8.92 27M23 27a3 3 0 0 1-2.89-2.24 2.9 2.9 0 0 1-.12-.83 3.1 3.1 0 0 1 .25-1.22 3 3 0 0 1 5.53 0 3.3 3.3 0 0 1 .23 1.17 3.3 3.3 0 0 1-.11.83A3 3 0 0 1 23 27m4.87-4.29a5 5 0 0 0-9.74 0H13.8a5 5 0 0 0-9.75 0H2v-8h7.8a1 1 0 0 0 1-1V5.05H30v17.61Z", fill: "currentColor" })] })));
10
+ };
11
+
12
+ export { VanIcon };
@@ -0,0 +1,12 @@
1
+ import { __rest } from '../../node_modules/tslib/tslib.es6.js';
2
+ import { jsxs, jsx } from 'react/jsx-runtime';
3
+ import { useId } from 'react';
4
+
5
+ const WarningIcon = (_a) => {
6
+ var { alt, className } = _a, props = __rest(_a, ["alt", "className"]);
7
+ const id = useId();
8
+ const componentProps = Object.assign({ "aria-labelledby": alt ? id : undefined, className: `coop-icon ${className !== null && className !== void 0 ? className : ""}`.trim(), "data-icon": "warning", fill: "none", role: alt ? "img" : undefined, viewBox: "0 0 32 32" }, props);
9
+ return (jsxs("svg", Object.assign({}, componentProps, { children: [alt ? jsx("title", { id: id, children: alt }) : null, jsx("path", { d: "M2.35 28.08 16.06 4.46l13.71 23.62Zm29.32-.7L17.56 3.07A1.73 1.73 0 0 0 16.06 2a1.94 1.94 0 0 0-1.5 1.1L.35 27.38C-.45 28.77.15 30 1.85 30h28.32a1.6 1.6 0 0 0 1.5-2.62", fill: "currentColor" }), jsx("path", { d: "M14.52 24.19A1.44 1.44 0 0 1 15 23.1a1.54 1.54 0 0 1 1.13-.46 1.63 1.63 0 0 1 1.12.44 1.39 1.39 0 0 1 .48 1.07 1.48 1.48 0 0 1-.47 1.1 1.62 1.62 0 0 1-1.74.34 1.6 1.6 0 0 1-.51-.32 1.3 1.3 0 0 1-.35-.48 1.3 1.3 0 0 1-.14-.6m2.8-3h-2.4v-9.71h2.4Z", fill: "currentColor" })] })));
10
+ };
11
+
12
+ export { WarningIcon };
@@ -0,0 +1,12 @@
1
+ import { __rest } from '../../node_modules/tslib/tslib.es6.js';
2
+ import { jsxs, jsx } from 'react/jsx-runtime';
3
+ import { useId } from 'react';
4
+
5
+ const WriteIcon = (_a) => {
6
+ var { alt, className } = _a, props = __rest(_a, ["alt", "className"]);
7
+ const id = useId();
8
+ const componentProps = Object.assign({ "aria-labelledby": alt ? id : undefined, className: `coop-icon ${className !== null && className !== void 0 ? className : ""}`.trim(), "data-icon": "write", fill: "none", role: alt ? "img" : undefined, viewBox: "0 0 32 32" }, props);
9
+ return (jsxs("svg", Object.assign({}, componentProps, { children: [alt ? jsx("title", { id: id, children: alt }) : null, jsx("path", { d: "M19.67 10.13 17.9 11.9H7a1 1 0 0 1 0-2h12a1 1 0 0 1 .67.23M14.9 14.9l-2 2H7a1 1 0 0 1 0-2ZM20 15.9a1 1 0 0 1-1 1h-1.87l2-2a1 1 0 0 1 .82.59.85.85 0 0 1 .05.41M19 21.9H7a1 1 0 0 1 0-2h12a1 1 0 1 1 0 2", fill: "currentColor" }), jsx("path", { d: "M24.08 10v20h-22V6h21.73l1.54-1.54a1.9 1.9 0 0 0-1-.44H2.07a2 2 0 0 0-2 2V30a2 2 0 0 0 2 2h22a2 2 0 0 0 2-2V8Z", fill: "currentColor" }), jsx("path", { d: "M30.62 3.41 28.5 1.29a1 1 0 0 0-1.42 0L22.38 6l-3.9 3.9-5 5-1.33 1.33a1 1 0 0 0-.27.48v.19l-.6 2.57a.8.8 0 0 0 0 .43 1 1 0 0 0 1.19.77l2.74-.67a.64.64 0 0 0 .29-.13.6.6 0 0 0 .19-.14l2.85-2.86 1.4-1.39L30.62 4.82a1 1 0 0 0 0-1.41M15 19.06l-2.75.63.62-2.75 6.82-6.81L23.81 6l1.54-1.54L27.79 2l2.13 2.12Z", fill: "currentColor" }), jsx("path", { d: "M31.33 2.7 29.21.58a2.06 2.06 0 0 0-2.83 0L11.44 15.52a2.1 2.1 0 0 0-.54 1l-.09.41-.54 2.34a2.18 2.18 0 0 0 .54 1.87 2 2 0 0 0 1.4.58 1.8 1.8 0 0 0 .46-.05l2.75-.67a2.1 2.1 0 0 0 1-.54L31.33 5.53a2 2 0 0 0 0-2.83M15 19.06l-2.75.63.62-2.75 6.82-6.81L23.81 6l1.54-1.54L27.79 2l2.13 2.12Z", fill: "currentColor" })] })));
10
+ };
11
+
12
+ export { WriteIcon };
@@ -0,0 +1,40 @@
1
+ export { AddIcon } from './AddIcon.js';
2
+ export { ArrowDownIcon } from './ArrowDownIcon.js';
3
+ export { ArrowLeftIcon } from './ArrowLeftIcon.js';
4
+ export { ArrowRightIcon } from './ArrowRightIcon.js';
5
+ export { ArrowUpIcon } from './ArrowUpIcon.js';
6
+ export { AvatarAltIcon } from './AvatarAltIcon.js';
7
+ export { AvatarIcon } from './AvatarIcon.js';
8
+ export { BasketIcon } from './BasketIcon.js';
9
+ export { CalendarIcon } from './CalendarIcon.js';
10
+ export { ChevronDownIcon } from './ChevronDownIcon.js';
11
+ export { ChevronLeftIcon } from './ChevronLeftIcon.js';
12
+ export { ChevronRightIcon } from './ChevronRightIcon.js';
13
+ export { ChevronUpIcon } from './ChevronUpIcon.js';
14
+ export { ClockIcon } from './ClockIcon.js';
15
+ export { CloseAltIcon } from './CloseAltIcon.js';
16
+ export { CloseIcon } from './CloseIcon.js';
17
+ export { CoopCardIcon } from './CoopCardIcon.js';
18
+ export { CoopIcon } from './CoopIcon.js';
19
+ export { CoopLocationIcon } from './CoopLocationIcon.js';
20
+ export { DownloadIcon } from './DownloadIcon.js';
21
+ export { HomeIcon } from './HomeIcon.js';
22
+ export { InformationIcon } from './InformationIcon.js';
23
+ export { LoadingIcon } from './LoadingIcon.js';
24
+ export { LocationIcon } from './LocationIcon.js';
25
+ export { MailIcon } from './MailIcon.js';
26
+ export { MenuIcon } from './MenuIcon.js';
27
+ export { MessageIcon } from './MessageIcon.js';
28
+ export { MinusIcon } from './MinusIcon.js';
29
+ export { OpenNewIcon } from './OpenNewIcon.js';
30
+ export { PencilIcon } from './PencilIcon.js';
31
+ export { PhoneIcon } from './PhoneIcon.js';
32
+ export { QuestionIcon } from './QuestionIcon.js';
33
+ export { ScooterIcon } from './ScooterIcon.js';
34
+ export { SearchIcon } from './SearchIcon.js';
35
+ export { SettingsIcon } from './SettingsIcon.js';
36
+ export { TickAltIcon } from './TickAltIcon.js';
37
+ export { TickIcon } from './TickIcon.js';
38
+ export { VanIcon } from './VanIcon.js';
39
+ export { WarningIcon } from './WarningIcon.js';
40
+ export { WriteIcon } from './WriteIcon.js';
@@ -11,8 +11,5 @@ export interface ImageProps extends HTMLAttributes<HTMLImageElement> {
11
11
  /** **(Optional)** Specifies width of the Image */
12
12
  width?: string;
13
13
  }
14
- /**
15
- * A wrapper around the image HTML tag, to help implement best practices like lazy loading, and assist with cropping and sizing images.
16
- */
17
14
  export declare const Image: ({ alt, crop, height, src, width, ...props }: ImageProps) => JSX.Element;
18
15
  export default Image;
@@ -21,9 +21,6 @@ const getContentfulParams = (src, width, height) => {
21
21
  width: (_b = url.searchParams.get("w")) !== null && _b !== void 0 ? _b : width,
22
22
  };
23
23
  };
24
- /**
25
- * A wrapper around the image HTML tag, to help implement best practices like lazy loading, and assist with cropping and sizing images.
26
- */
27
24
  const Image = (_a) => {
28
25
  var { alt, crop, height, src, width = "640" } = _a, props = __rest(_a, ["alt", "crop", "height", "src", "width"]);
29
26
  let params = { height, src, width };
@@ -19,8 +19,5 @@ export interface PillProps extends HTMLAttributes<HTMLAnchorElement> {
19
19
  /** **(Optional)** Specifies what should be the Pill size. */
20
20
  size?: "sm" | "md" | "lg" | "xl";
21
21
  }
22
- /**
23
- * The Pill component is a small, sligtly rounded label used to link and highlight information such as categories or articles. It can be customised with different content and styles to suit various use cases.
24
- */
25
22
  export declare const Pill: ({ as, background, badge, badgeBackground, children, className, href, size, ...props }: PillProps) => JSX.Element;
26
23
  export default Pill;
@@ -4,9 +4,6 @@ import { clsx } from '../../node_modules/clsx/dist/clsx.js';
4
4
  import React from 'react';
5
5
  import { bgPropToClass } from '../../utils/index.js';
6
6
 
7
- /**
8
- * The Pill component is a small, sligtly rounded label used to link and highlight information such as categories or articles. It can be customised with different content and styles to suit various use cases.
9
- */
10
7
  const Pill = (_a) => {
11
8
  var { as, background = "tint-grey", badge, badgeBackground = "offers-red", children, className = "", href, size = "md" } = _a, props = __rest(_a, ["as", "background", "badge", "badgeBackground", "children", "className", "href", "size"]);
12
9
  let element = href ? "a" : "span";
@@ -27,22 +27,5 @@ export interface SearchBoxProps extends HTMLAttributes<HTMLInputElement> {
27
27
  /** **(Optional)** Receives the variant to be applied to SearchBox component. */
28
28
  variant?: "green" | "blue" | "white" | "grey" | "green-ghost" | "blue-ghost" | "white-ghost" | "grey-ghost";
29
29
  }
30
- /**
31
- * SearchBox component allows a person to enter a word or a phrase to find relevant content.
32
- *
33
- * The `label` prop is mandatory but not visible by default (it is visible for screen readers). You can make it visible to humans by setting `labelVisible` to true.
34
- *
35
- * If you are using a single icon with no text for `button.label`, ensure you pass an `alt` property to the icon for accessibility purposes.
36
- *
37
- * You can provide an `action` to submit input like a normal HTML form, or an `onSubmit` callback to handle submissions client-side.
38
- *
39
- * **Good to know:** SearchBox requires both `SearchBox` and `Button` css/scss files.
40
- *
41
- * ```
42
- * import "@coopdigital/styles/components/Searchbox.css"
43
- * import "@coopdigital/styles/components/Button.css"
44
- *
45
- * ```
46
- */
47
30
  export declare const SearchBox: ({ action, "aria-placeholder": ariaPlaceholder, autoCapitalize, autoComplete, button, className, label, labelVisible, name, onSubmit, placeholder, size, variant, ...props }: SearchBoxProps) => JSX.Element;
48
31
  export default SearchBox;
@@ -8,23 +8,6 @@ const defaultButtonProps = {
8
8
  label: React.createElement(SearchIcon, { alt: "Search", stroke: "currentColor", strokeWidth: 2 }),
9
9
  loadingText: "",
10
10
  };
11
- /**
12
- * SearchBox component allows a person to enter a word or a phrase to find relevant content.
13
- *
14
- * The `label` prop is mandatory but not visible by default (it is visible for screen readers). You can make it visible to humans by setting `labelVisible` to true.
15
- *
16
- * If you are using a single icon with no text for `button.label`, ensure you pass an `alt` property to the icon for accessibility purposes.
17
- *
18
- * You can provide an `action` to submit input like a normal HTML form, or an `onSubmit` callback to handle submissions client-side.
19
- *
20
- * **Good to know:** SearchBox requires both `SearchBox` and `Button` css/scss files.
21
- *
22
- * ```
23
- * import "@coopdigital/styles/components/Searchbox.css"
24
- * import "@coopdigital/styles/components/Button.css"
25
- *
26
- * ```
27
- */
28
11
  const SearchBox = (_a) => {
29
12
  var _b, _c;
30
13
  var { action, "aria-placeholder": ariaPlaceholder, autoCapitalize = "off", autoComplete = "off", button = defaultButtonProps, className, label, labelVisible = false, name = "query", onSubmit, placeholder, size = "md", variant = "green" } = _a, props = __rest(_a, ["action", "aria-placeholder", "autoCapitalize", "autoComplete", "button", "className", "label", "labelVisible", "name", "onSubmit", "placeholder", "size", "variant"]);
@@ -15,8 +15,5 @@ export interface SignpostProps extends HTMLAttributes<HTMLDivElement> {
15
15
  /** **(Optional)** Specifies the image URL and alt text of the Signpost */
16
16
  image?: ImageProps;
17
17
  }
18
- /**
19
- * Signposts allow you to create links to permanent content you think people are looking for.
20
- */
21
18
  export declare const Signpost: ({ as, children, className, headingLevel, href, image, ...props }: SignpostProps) => JSX.Element;
22
19
  export default Signpost;
@@ -3,9 +3,6 @@ import { jsxs, jsx } from 'react/jsx-runtime';
3
3
  import React from 'react';
4
4
  import { Image } from '../Image/Image.js';
5
5
 
6
- /**
7
- * Signposts allow you to create links to permanent content you think people are looking for.
8
- */
9
6
  const Signpost = (_a) => {
10
7
  var { as, children, className = "", headingLevel = "h3", href, image } = _a, props = __rest(_a, ["as", "children", "className", "headingLevel", "href", "image"]);
11
8
  let element = "a";
@@ -14,22 +14,5 @@ export interface SkipNavProps extends HTMLAttributes<HTMLDivElement> {
14
14
  * Defaults to a single link anchored to `#main` */
15
15
  links?: SkipNavLink[];
16
16
  }
17
- /**
18
- * The Skip Nav component allows screen reader and keyboard users to go directly to the main content.
19
- *
20
- * ### Links
21
- * Links within the skip navigation component should take the user directly to the main areas of the page. These are usually the:
22
- * - navigation
23
- * - main content
24
- * - footer
25
- * - search (if applicable)
26
- *
27
- *
28
- * ### Using skip navigation on a page
29
- * - The skip navigation function should be the first thing that appears on a page when it has loaded and a user presses the tab key.
30
- * - Pressing the tab key again should then cycle through 'skip to main content', 'skip to navigation' and 'skip to footer' links.
31
- * - Pressing enter will take the user to the correct part of the page and apply the focus ring to the first interactive element in that section.
32
- * - If the user tabs through the skip navigation without selecting an option the Co‑op logo should be the next element that has the focus ring applied.
33
- */
34
17
  export declare const SkipNav: ({ className, isVisible, links, ...props }: SkipNavProps) => JSX.Element;
35
18
  export default SkipNav;
@@ -2,23 +2,6 @@ import { __rest } from '../../node_modules/tslib/tslib.es6.js';
2
2
  import { jsx } from 'react/jsx-runtime';
3
3
 
4
4
  const defaultLinks = [{ href: "#main", label: "Skip to main content" }];
5
- /**
6
- * The Skip Nav component allows screen reader and keyboard users to go directly to the main content.
7
- *
8
- * ### Links
9
- * Links within the skip navigation component should take the user directly to the main areas of the page. These are usually the:
10
- * - navigation
11
- * - main content
12
- * - footer
13
- * - search (if applicable)
14
- *
15
- *
16
- * ### Using skip navigation on a page
17
- * - The skip navigation function should be the first thing that appears on a page when it has loaded and a user presses the tab key.
18
- * - Pressing the tab key again should then cycle through 'skip to main content', 'skip to navigation' and 'skip to footer' links.
19
- * - Pressing enter will take the user to the correct part of the page and apply the focus ring to the first interactive element in that section.
20
- * - If the user tabs through the skip navigation without selecting an option the Co‑op logo should be the next element that has the focus ring applied.
21
- */
22
5
  const SkipNav = (_a) => {
23
6
  var { className = "", isVisible = false, links = defaultLinks } = _a, props = __rest(_a, ["className", "isVisible", "links"]);
24
7
  const componentProps = Object.assign({ className: `coop-skip-nav ${className}` }, props);
@@ -1,6 +1,6 @@
1
- import type { JSX } from "react";
1
+ import type { HTMLAttributes, JSX } from "react";
2
2
  import { CoopBlue, Green, OffersRed } from "../../types/colors";
3
- export interface SquircleProps {
3
+ export interface SquircleProps extends HTMLAttributes<HTMLDivElement> {
4
4
  /** **(Optional)** Specifies the background color of the Squircle. */
5
5
  background?: OffersRed | CoopBlue | Green;
6
6
  /** **(Optional)** Represents the content inside the Squircle component. It can be any valid JSX or string. */
@@ -10,8 +10,5 @@ export interface SquircleProps {
10
10
  /** **(Optional)** Specifies what should be the Squircle size */
11
11
  size?: "sm" | "md" | "lg";
12
12
  }
13
- /**
14
- * Squircle to use on components like Cards, etc.
15
- */
16
13
  export declare const Squircle: ({ background, children, className, size, ...props }: SquircleProps) => JSX.Element;
17
14
  export default Squircle;
@@ -2,9 +2,6 @@ import { __rest } from '../../node_modules/tslib/tslib.es6.js';
2
2
  import { jsx } from 'react/jsx-runtime';
3
3
  import { bgPropToClass } from '../../utils/index.js';
4
4
 
5
- /**
6
- * Squircle to use on components like Cards, etc.
7
- */
8
5
  const Squircle = (_a) => {
9
6
  var { background = "offers-red", children, className, size = "lg" } = _a, props = __rest(_a, ["background", "children", "className", "size"]);
10
7
  const componentProps = Object.assign({ className: `coop-squircle ${bgPropToClass(background, className)} ${className !== null && className !== void 0 ? className : ""}`, "data-size": size.length && size !== "lg" ? size : undefined }, props);
@@ -13,15 +13,5 @@ export interface TagProps extends HTMLAttributes<HTMLAnchorElement> {
13
13
  /** **(Optional)** Specifies the URL that the Tag component will link to when clicked. */
14
14
  href?: string;
15
15
  }
16
- /**
17
- * Tag is a simple component that is meant to communicate a brief message such as categories.
18
- *
19
- * It has similarities with Pill component but also has differences such as:
20
- * - Tag doesn't accept a badge option
21
- * - Tags have more rounded corners compared to Pill
22
- * - Tags are more compact compared to Pill
23
- * - Tag components should be used as tags to communicate brief message while Pill component is more versatile and has more styling options
24
- *
25
- */
26
16
  export declare const Tag: ({ as, background, children, className, href, ...props }: TagProps) => JSX.Element;
27
17
  export default Tag;
@@ -3,16 +3,6 @@ import { clsx } from '../../node_modules/clsx/dist/clsx.js';
3
3
  import React from 'react';
4
4
  import { bgPropToClass } from '../../utils/index.js';
5
5
 
6
- /**
7
- * Tag is a simple component that is meant to communicate a brief message such as categories.
8
- *
9
- * It has similarities with Pill component but also has differences such as:
10
- * - Tag doesn't accept a badge option
11
- * - Tags have more rounded corners compared to Pill
12
- * - Tags are more compact compared to Pill
13
- * - Tag components should be used as tags to communicate brief message while Pill component is more versatile and has more styling options
14
- *
15
- */
16
6
  const Tag = (_a) => {
17
7
  var { as, background = "tint-grey", children, className = "", href } = _a, props = __rest(_a, ["as", "background", "children", "className", "href"]);
18
8
  let element = href ? "a" : "span";
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@coopdigital/react",
3
3
  "type": "module",
4
- "version": "0.19.1",
4
+ "version": "0.19.3",
5
5
  "private": false,
6
6
  "publishConfig": {
7
7
  "access": "public"
@@ -10,6 +10,10 @@
10
10
  ".": {
11
11
  "types": "./dist/index.d.ts",
12
12
  "default": "./dist/index.js"
13
+ },
14
+ "./Icon": {
15
+ "types": "./dist/components/Icon/index.d.ts",
16
+ "default": "./dist/components/Icon/index.js"
13
17
  }
14
18
  },
15
19
  "files": [
@@ -34,6 +38,7 @@
34
38
  "test:e2e:ui": "npx playwright test --ui",
35
39
  "test:e2e:ci": "npx playwright test --shard=$CI_NODE_INDEX/$CI_NODE_TOTAL",
36
40
  "build": "tsx scripts build",
41
+ "build:docs": "tsx scripts build-docs",
37
42
  "build:icons": "tsx scripts build-icons",
38
43
  "build:storybook": "storybook build --disable-telemetry && npm run storybook:fix-paths",
39
44
  "storybook": "storybook dev -p 6006",
@@ -45,7 +50,7 @@
45
50
  "description": "",
46
51
  "devDependencies": {
47
52
  "@axe-core/playwright": "^4.10.1",
48
- "@coopdigital/styles": "^0.16.1",
53
+ "@coopdigital/styles": "^0.16.3",
49
54
  "@playwright/test": "^1.52.0",
50
55
  "@storybook/addon-a11y": "^8.6.12",
51
56
  "@storybook/addon-essentials": "^8.6.12",
@@ -70,5 +75,5 @@
70
75
  "dependencies": {
71
76
  "clsx": "^2.1.1"
72
77
  },
73
- "gitHead": "8c11cfec54452dacb609b1a61075a2dbc1142ad1"
78
+ "gitHead": "4b0b52bb134f10067e1c87b0ba9afab3504f5368"
74
79
  }
@@ -1,26 +1,16 @@
1
1
  import type { HTMLAttributes, JSX, ReactNode } from "react"
2
2
 
3
3
  export interface AlertBannerProps extends HTMLAttributes<HTMLDivElement> {
4
- /** **(Optional)** Represents the content inside the AlertBanner component. It can be any valid JSX or string. */
4
+ /** **(Optional)** Main content inside the banner. It can be any valid JSX or string. */
5
5
  children?: string | ReactNode
6
- /** **(Optional)** Receives any className to be applied to AlertBanner component. */
6
+ /** **(Optional)** Additional CSS classes to be applied to the component. */
7
7
  className?: string
8
- /** Specifies the AlertBanner heading. */
8
+ /** Main title of the banner, rendered as a `h2`. */
9
9
  heading: string
10
- /** **(Optional)** Specifies the AlertBanner variant. */
10
+ /** **(Optional)** Specify which banner variant to use. */
11
11
  variant?: "black" | "default"
12
12
  }
13
13
 
14
- /**
15
- * The Alert Banner component is used to highlight events that might limit availability of a service we provide.
16
- * <br />
17
- * - the service the user is trying to access is experiencing problems
18
- * - planned system maintenance is coming soon
19
- * - the user’s login session is about to expire
20
- * <br />
21
- * <p>Only use alert notifications when absolutely necessary. Using them too often could make the problem worse.<p/>
22
- *
23
- */
24
14
  export const AlertBanner = ({
25
15
  children,
26
16
  className = "",
@@ -3,22 +3,18 @@ import type { HTMLAttributes, JSX } from "react"
3
3
  import { Image, ImageProps } from "../Image"
4
4
 
5
5
  export interface AuthorProps extends HTMLAttributes<HTMLDivElement> {
6
- /** **(Optional)** Specifies the content author */
6
+ /** **(Optional)** Specify the content author. */
7
7
  author?: string
8
- /** **(Optional)** Receives any className to be applied to Author component. */
8
+ /** **(Optional)** Additional CSS classes to be applied to the component. */
9
9
  className?: string
10
- /** **(Optional)** Specifies the date. Refer to Experience Library guidance on date formats. We advise using the following format (dd mmmm yyyy) eg: 1 January 2000. */
10
+ /** **(Optional)** Specify the date. Refer to Experience Library guidance on date formats. We advise using the following format (dd mmmm yyyy) eg: 1 January 2000. */
11
11
  date?: string
12
- /** **(Optional)** Specifies the text that will prefix the date, e.g. "Published" */
12
+ /** **(Optional)** Specify the text that will prefix the date, e.g. "Published". */
13
13
  datePrefix?: string
14
- /** **(Optional)** Specifies the image properties of Author */
14
+ /** **(Optional)** Specify Image properties of the Author avatar. */
15
15
  image?: ImageProps
16
16
  }
17
17
 
18
- /**
19
- * Author is a component that can be used inside any article or Card component to communicate respective author and date of publication.
20
- */
21
-
22
18
  export const Author = ({
23
19
  author = "Co-op team",
24
20
  className = "",
@@ -48,9 +48,6 @@ type OnClickHandler =
48
48
  | React.MouseEventHandler<HTMLButtonElement | HTMLAnchorElement>
49
49
  | ((event: React.MouseEvent<HTMLButtonElement | HTMLAnchorElement>) => Promise<void>)
50
50
 
51
- /**
52
- * The Button component is an interactive element that people can use to take an action.
53
- */
54
51
  export const Button = ({
55
52
  as,
56
53
  children,
@@ -58,9 +58,6 @@ function getCardLinkElement(as: CardProps["as"], href?: string) {
58
58
  }
59
59
  }
60
60
 
61
- /**
62
- * A Card lets you highlight and link to more in-depth content on another page. The component typically includes a heading, image, and an optional description.
63
- */
64
61
  export const Card = ({
65
62
  as,
66
63
  background,
@@ -16,11 +16,6 @@ export interface ExpandableProps extends DetailsHTMLAttributes<HTMLDetailsElemen
16
16
  summary: React.ReactNode
17
17
  }
18
18
 
19
- /**
20
- * The Expandable component wraps content in an expandable block using the details/summary HTML elements.
21
- * It can be used to reveal more context for a specific issue or action.
22
- */
23
-
24
19
  export const Expandable = ({
25
20
  background = "tint-grey",
26
21
  children,
@@ -34,9 +34,6 @@ const getContentfulParams = (src: string, width: string, height: string | undefi
34
34
  }
35
35
  }
36
36
 
37
- /**
38
- * A wrapper around the image HTML tag, to help implement best practices like lazy loading, and assist with cropping and sizing images.
39
- */
40
37
  export const Image = ({
41
38
  alt,
42
39
  crop,
@@ -26,9 +26,6 @@ export interface PillProps extends HTMLAttributes<HTMLAnchorElement> {
26
26
  size?: "sm" | "md" | "lg" | "xl"
27
27
  }
28
28
 
29
- /**
30
- * The Pill component is a small, sligtly rounded label used to link and highlight information such as categories or articles. It can be customised with different content and styles to suit various use cases.
31
- */
32
29
  export const Pill = ({
33
30
  as,
34
31
  background = "tint-grey",
@@ -42,23 +42,6 @@ const defaultButtonProps: SearchBoxProps["button"] = {
42
42
  loadingText: "",
43
43
  }
44
44
 
45
- /**
46
- * SearchBox component allows a person to enter a word or a phrase to find relevant content.
47
- *
48
- * The `label` prop is mandatory but not visible by default (it is visible for screen readers). You can make it visible to humans by setting `labelVisible` to true.
49
- *
50
- * If you are using a single icon with no text for `button.label`, ensure you pass an `alt` property to the icon for accessibility purposes.
51
- *
52
- * You can provide an `action` to submit input like a normal HTML form, or an `onSubmit` callback to handle submissions client-side.
53
- *
54
- * **Good to know:** SearchBox requires both `SearchBox` and `Button` css/scss files.
55
- *
56
- * ```
57
- * import "@coopdigital/styles/components/Searchbox.css"
58
- * import "@coopdigital/styles/components/Button.css"
59
- *
60
- * ```
61
- */
62
45
  export const SearchBox = ({
63
46
  action,
64
47
  "aria-placeholder": ariaPlaceholder,
@@ -20,10 +20,6 @@ export interface SignpostProps extends HTMLAttributes<HTMLDivElement> {
20
20
  image?: ImageProps
21
21
  }
22
22
 
23
- /**
24
- * Signposts allow you to create links to permanent content you think people are looking for.
25
- */
26
-
27
23
  export const Signpost = ({
28
24
  as,
29
25
  children,
@@ -19,23 +19,6 @@ export interface SkipNavProps extends HTMLAttributes<HTMLDivElement> {
19
19
 
20
20
  const defaultLinks = [{ href: "#main", label: "Skip to main content" }]
21
21
 
22
- /**
23
- * The Skip Nav component allows screen reader and keyboard users to go directly to the main content.
24
- *
25
- * ### Links
26
- * Links within the skip navigation component should take the user directly to the main areas of the page. These are usually the:
27
- * - navigation
28
- * - main content
29
- * - footer
30
- * - search (if applicable)
31
- *
32
- *
33
- * ### Using skip navigation on a page
34
- * - The skip navigation function should be the first thing that appears on a page when it has loaded and a user presses the tab key.
35
- * - Pressing the tab key again should then cycle through 'skip to main content', 'skip to navigation' and 'skip to footer' links.
36
- * - Pressing enter will take the user to the correct part of the page and apply the focus ring to the first interactive element in that section.
37
- * - If the user tabs through the skip navigation without selecting an option the Co‑op logo should be the next element that has the focus ring applied.
38
- */
39
22
  export const SkipNav = ({
40
23
  className = "",
41
24
  isVisible = false,