@coopdigital/react 0.16.0 → 0.18.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.
Files changed (87) hide show
  1. package/README.md +2 -2
  2. package/dist/components/Icon/AddIcon.d.ts +6 -0
  3. package/dist/components/Icon/ArrowDownIcon.d.ts +6 -0
  4. package/dist/components/Icon/ArrowLeftIcon.d.ts +6 -0
  5. package/dist/components/Icon/ArrowRightIcon.d.ts +6 -0
  6. package/dist/components/Icon/ArrowUpIcon.d.ts +6 -0
  7. package/dist/components/Icon/AvatarAltIcon.d.ts +6 -0
  8. package/dist/components/Icon/AvatarIcon.d.ts +6 -0
  9. package/dist/components/Icon/BasketIcon.d.ts +6 -0
  10. package/dist/components/Icon/CalendarIcon.d.ts +6 -0
  11. package/dist/components/Icon/ChevronDownIcon.d.ts +6 -0
  12. package/dist/components/Icon/ChevronLeftIcon.d.ts +6 -0
  13. package/dist/components/Icon/ChevronRightIcon.d.ts +6 -0
  14. package/dist/components/Icon/ChevronUpIcon.d.ts +6 -0
  15. package/dist/components/Icon/ClockIcon.d.ts +6 -0
  16. package/dist/components/Icon/CloseAltIcon.d.ts +6 -0
  17. package/dist/components/Icon/CloseIcon.d.ts +6 -0
  18. package/dist/components/Icon/CoopCardIcon.d.ts +6 -0
  19. package/dist/components/Icon/CoopIcon.d.ts +6 -0
  20. package/dist/components/Icon/CoopLocationIcon.d.ts +6 -0
  21. package/dist/components/Icon/DownloadIcon.d.ts +6 -0
  22. package/dist/components/Icon/HomeIcon.d.ts +6 -0
  23. package/dist/components/Icon/InformationIcon.d.ts +6 -0
  24. package/dist/components/Icon/LocationIcon.d.ts +6 -0
  25. package/dist/components/Icon/MailIcon.d.ts +6 -0
  26. package/dist/components/Icon/MenuIcon.d.ts +6 -0
  27. package/dist/components/Icon/MessageIcon.d.ts +6 -0
  28. package/dist/components/Icon/MinusIcon.d.ts +6 -0
  29. package/dist/components/Icon/OpenNewIcon.d.ts +6 -0
  30. package/dist/components/Icon/PencilIcon.d.ts +6 -0
  31. package/dist/components/Icon/PhoneIcon.d.ts +6 -0
  32. package/dist/components/Icon/QuestionIcon.d.ts +6 -0
  33. package/dist/components/Icon/ScooterIcon.d.ts +6 -0
  34. package/dist/components/Icon/SearchIcon.d.ts +6 -0
  35. package/dist/components/Icon/SettingsIcon.d.ts +6 -0
  36. package/dist/components/Icon/TickAltIcon.d.ts +6 -0
  37. package/dist/components/Icon/TickIcon.d.ts +6 -0
  38. package/dist/components/Icon/VanIcon.d.ts +6 -0
  39. package/dist/components/Icon/WarningIcon.d.ts +6 -0
  40. package/dist/components/Icon/WriteIcon.d.ts +6 -0
  41. package/dist/components/Icon/index.d.ts +39 -13
  42. package/dist/components/RootSVG/RootSVG.d.ts +1 -2
  43. package/dist/components/RootSVG/RootSVG.js +2 -2
  44. package/package.json +4 -3
  45. package/src/components/Icon/AddIcon.tsx +30 -0
  46. package/src/components/Icon/ArrowDownIcon.tsx +27 -0
  47. package/src/components/Icon/ArrowLeftIcon.tsx +27 -0
  48. package/src/components/Icon/ArrowRightIcon.tsx +27 -0
  49. package/src/components/Icon/ArrowUpIcon.tsx +27 -0
  50. package/src/components/Icon/AvatarAltIcon.tsx +34 -0
  51. package/src/components/Icon/AvatarIcon.tsx +30 -0
  52. package/src/components/Icon/BasketIcon.tsx +30 -0
  53. package/src/components/Icon/CalendarIcon.tsx +30 -0
  54. package/src/components/Icon/ChevronDownIcon.tsx +26 -0
  55. package/src/components/Icon/ChevronLeftIcon.tsx +26 -0
  56. package/src/components/Icon/ChevronRightIcon.tsx +26 -0
  57. package/src/components/Icon/ChevronUpIcon.tsx +26 -0
  58. package/src/components/Icon/ClockIcon.tsx +30 -0
  59. package/src/components/Icon/CloseAltIcon.tsx +34 -0
  60. package/src/components/Icon/CloseIcon.tsx +30 -0
  61. package/src/components/Icon/CoopCardIcon.tsx +27 -0
  62. package/src/components/Icon/CoopIcon.tsx +27 -0
  63. package/src/components/Icon/CoopLocationIcon.tsx +34 -0
  64. package/src/components/Icon/DownloadIcon.tsx +31 -0
  65. package/src/components/Icon/HomeIcon.tsx +34 -0
  66. package/src/components/Icon/InformationIcon.tsx +30 -0
  67. package/src/components/Icon/LocationIcon.tsx +30 -0
  68. package/src/components/Icon/MailIcon.tsx +26 -0
  69. package/src/components/Icon/MenuIcon.tsx +26 -0
  70. package/src/components/Icon/MessageIcon.tsx +26 -0
  71. package/src/components/Icon/MinusIcon.tsx +26 -0
  72. package/src/components/Icon/OpenNewIcon.tsx +30 -0
  73. package/src/components/Icon/PencilIcon.tsx +26 -0
  74. package/src/components/Icon/PhoneIcon.tsx +26 -0
  75. package/src/components/Icon/QuestionIcon.tsx +30 -0
  76. package/src/components/Icon/ScooterIcon.tsx +42 -0
  77. package/src/components/Icon/SearchIcon.tsx +30 -0
  78. package/src/components/Icon/SettingsIcon.tsx +26 -0
  79. package/src/components/Icon/TickAltIcon.tsx +30 -0
  80. package/src/components/Icon/TickIcon.tsx +26 -0
  81. package/src/components/Icon/VanIcon.tsx +26 -0
  82. package/src/components/Icon/WarningIcon.tsx +30 -0
  83. package/src/components/Icon/WriteIcon.tsx +38 -0
  84. package/src/components/Icon/index.tsx +39 -36
  85. package/src/components/RootSVG/RootSVG.tsx +2 -22
  86. package/dist/components/Icon/template.d.ts +0 -11
  87. package/src/components/Icon/template.tsx +0 -29
package/README.md CHANGED
@@ -33,8 +33,8 @@ npm install @coopdigital/react @coopdigital/styles
33
33
  Import the components that you need, along with the main stylesheet and the corresponding component styles:
34
34
  ```
35
35
  import { Pill } from "@coopdigital/react"
36
- import "@coopdigital/styles/dist/main.css"
37
- import "@coopdigital/styles/dist/components/Pill.css"
36
+ import "@coopdigital/styles/main.css"
37
+ import "@coopdigital/styles/components/Pill.css"
38
38
  ```
39
39
 
40
40
  Alternatively if your project uses SASS you can import the source stylesheets:
@@ -0,0 +1,6 @@
1
+ import { type SVGProps } from "react";
2
+ interface IconProps extends SVGProps<SVGSVGElement> {
3
+ alt?: string;
4
+ }
5
+ export declare const AddIcon: ({ alt, className, ...props }: IconProps) => import("react/jsx-runtime").JSX.Element;
6
+ export {};
@@ -0,0 +1,6 @@
1
+ import { type SVGProps } from "react";
2
+ interface IconProps extends SVGProps<SVGSVGElement> {
3
+ alt?: string;
4
+ }
5
+ export declare const ArrowDownIcon: ({ alt, className, ...props }: IconProps) => import("react/jsx-runtime").JSX.Element;
6
+ export {};
@@ -0,0 +1,6 @@
1
+ import { type SVGProps } from "react";
2
+ interface IconProps extends SVGProps<SVGSVGElement> {
3
+ alt?: string;
4
+ }
5
+ export declare const ArrowLeftIcon: ({ alt, className, ...props }: IconProps) => import("react/jsx-runtime").JSX.Element;
6
+ export {};
@@ -0,0 +1,6 @@
1
+ import { type SVGProps } from "react";
2
+ interface IconProps extends SVGProps<SVGSVGElement> {
3
+ alt?: string;
4
+ }
5
+ export declare const ArrowRightIcon: ({ alt, className, ...props }: IconProps) => import("react/jsx-runtime").JSX.Element;
6
+ export {};
@@ -0,0 +1,6 @@
1
+ import { type SVGProps } from "react";
2
+ interface IconProps extends SVGProps<SVGSVGElement> {
3
+ alt?: string;
4
+ }
5
+ export declare const ArrowUpIcon: ({ alt, className, ...props }: IconProps) => import("react/jsx-runtime").JSX.Element;
6
+ export {};
@@ -0,0 +1,6 @@
1
+ import { type SVGProps } from "react";
2
+ interface IconProps extends SVGProps<SVGSVGElement> {
3
+ alt?: string;
4
+ }
5
+ export declare const AvatarAltIcon: ({ alt, className, ...props }: IconProps) => import("react/jsx-runtime").JSX.Element;
6
+ export {};
@@ -0,0 +1,6 @@
1
+ import { type SVGProps } from "react";
2
+ interface IconProps extends SVGProps<SVGSVGElement> {
3
+ alt?: string;
4
+ }
5
+ export declare const AvatarIcon: ({ alt, className, ...props }: IconProps) => import("react/jsx-runtime").JSX.Element;
6
+ export {};
@@ -0,0 +1,6 @@
1
+ import { type SVGProps } from "react";
2
+ interface IconProps extends SVGProps<SVGSVGElement> {
3
+ alt?: string;
4
+ }
5
+ export declare const BasketIcon: ({ alt, className, ...props }: IconProps) => import("react/jsx-runtime").JSX.Element;
6
+ export {};
@@ -0,0 +1,6 @@
1
+ import { type SVGProps } from "react";
2
+ interface IconProps extends SVGProps<SVGSVGElement> {
3
+ alt?: string;
4
+ }
5
+ export declare const CalendarIcon: ({ alt, className, ...props }: IconProps) => import("react/jsx-runtime").JSX.Element;
6
+ export {};
@@ -0,0 +1,6 @@
1
+ import { type SVGProps } from "react";
2
+ interface IconProps extends SVGProps<SVGSVGElement> {
3
+ alt?: string;
4
+ }
5
+ export declare const ChevronDownIcon: ({ alt, className, ...props }: IconProps) => import("react/jsx-runtime").JSX.Element;
6
+ export {};
@@ -0,0 +1,6 @@
1
+ import { type SVGProps } from "react";
2
+ interface IconProps extends SVGProps<SVGSVGElement> {
3
+ alt?: string;
4
+ }
5
+ export declare const ChevronLeftIcon: ({ alt, className, ...props }: IconProps) => import("react/jsx-runtime").JSX.Element;
6
+ export {};
@@ -0,0 +1,6 @@
1
+ import { type SVGProps } from "react";
2
+ interface IconProps extends SVGProps<SVGSVGElement> {
3
+ alt?: string;
4
+ }
5
+ export declare const ChevronRightIcon: ({ alt, className, ...props }: IconProps) => import("react/jsx-runtime").JSX.Element;
6
+ export {};
@@ -0,0 +1,6 @@
1
+ import { type SVGProps } from "react";
2
+ interface IconProps extends SVGProps<SVGSVGElement> {
3
+ alt?: string;
4
+ }
5
+ export declare const ChevronUpIcon: ({ alt, className, ...props }: IconProps) => import("react/jsx-runtime").JSX.Element;
6
+ export {};
@@ -0,0 +1,6 @@
1
+ import { type SVGProps } from "react";
2
+ interface IconProps extends SVGProps<SVGSVGElement> {
3
+ alt?: string;
4
+ }
5
+ export declare const ClockIcon: ({ alt, className, ...props }: IconProps) => import("react/jsx-runtime").JSX.Element;
6
+ export {};
@@ -0,0 +1,6 @@
1
+ import { type SVGProps } from "react";
2
+ interface IconProps extends SVGProps<SVGSVGElement> {
3
+ alt?: string;
4
+ }
5
+ export declare const CloseAltIcon: ({ alt, className, ...props }: IconProps) => import("react/jsx-runtime").JSX.Element;
6
+ export {};
@@ -0,0 +1,6 @@
1
+ import { type SVGProps } from "react";
2
+ interface IconProps extends SVGProps<SVGSVGElement> {
3
+ alt?: string;
4
+ }
5
+ export declare const CloseIcon: ({ alt, className, ...props }: IconProps) => import("react/jsx-runtime").JSX.Element;
6
+ export {};
@@ -0,0 +1,6 @@
1
+ import { type SVGProps } from "react";
2
+ interface IconProps extends SVGProps<SVGSVGElement> {
3
+ alt?: string;
4
+ }
5
+ export declare const CoopCardIcon: ({ alt, className, ...props }: IconProps) => import("react/jsx-runtime").JSX.Element;
6
+ export {};
@@ -0,0 +1,6 @@
1
+ import { type SVGProps } from "react";
2
+ interface IconProps extends SVGProps<SVGSVGElement> {
3
+ alt?: string;
4
+ }
5
+ export declare const CoopIcon: ({ alt, className, ...props }: IconProps) => import("react/jsx-runtime").JSX.Element;
6
+ export {};
@@ -0,0 +1,6 @@
1
+ import { type SVGProps } from "react";
2
+ interface IconProps extends SVGProps<SVGSVGElement> {
3
+ alt?: string;
4
+ }
5
+ export declare const CoopLocationIcon: ({ alt, className, ...props }: IconProps) => import("react/jsx-runtime").JSX.Element;
6
+ export {};
@@ -0,0 +1,6 @@
1
+ import { type SVGProps } from "react";
2
+ interface IconProps extends SVGProps<SVGSVGElement> {
3
+ alt?: string;
4
+ }
5
+ export declare const DownloadIcon: ({ alt, className, ...props }: IconProps) => import("react/jsx-runtime").JSX.Element;
6
+ export {};
@@ -0,0 +1,6 @@
1
+ import { type SVGProps } from "react";
2
+ interface IconProps extends SVGProps<SVGSVGElement> {
3
+ alt?: string;
4
+ }
5
+ export declare const HomeIcon: ({ alt, className, ...props }: IconProps) => import("react/jsx-runtime").JSX.Element;
6
+ export {};
@@ -0,0 +1,6 @@
1
+ import { type SVGProps } from "react";
2
+ interface IconProps extends SVGProps<SVGSVGElement> {
3
+ alt?: string;
4
+ }
5
+ export declare const InformationIcon: ({ alt, className, ...props }: IconProps) => import("react/jsx-runtime").JSX.Element;
6
+ export {};
@@ -0,0 +1,6 @@
1
+ import { type SVGProps } from "react";
2
+ interface IconProps extends SVGProps<SVGSVGElement> {
3
+ alt?: string;
4
+ }
5
+ export declare const LocationIcon: ({ alt, className, ...props }: IconProps) => import("react/jsx-runtime").JSX.Element;
6
+ export {};
@@ -0,0 +1,6 @@
1
+ import { type SVGProps } from "react";
2
+ interface IconProps extends SVGProps<SVGSVGElement> {
3
+ alt?: string;
4
+ }
5
+ export declare const MailIcon: ({ alt, className, ...props }: IconProps) => import("react/jsx-runtime").JSX.Element;
6
+ export {};
@@ -0,0 +1,6 @@
1
+ import { type SVGProps } from "react";
2
+ interface IconProps extends SVGProps<SVGSVGElement> {
3
+ alt?: string;
4
+ }
5
+ export declare const MenuIcon: ({ alt, className, ...props }: IconProps) => import("react/jsx-runtime").JSX.Element;
6
+ export {};
@@ -0,0 +1,6 @@
1
+ import { type SVGProps } from "react";
2
+ interface IconProps extends SVGProps<SVGSVGElement> {
3
+ alt?: string;
4
+ }
5
+ export declare const MessageIcon: ({ alt, className, ...props }: IconProps) => import("react/jsx-runtime").JSX.Element;
6
+ export {};
@@ -0,0 +1,6 @@
1
+ import { type SVGProps } from "react";
2
+ interface IconProps extends SVGProps<SVGSVGElement> {
3
+ alt?: string;
4
+ }
5
+ export declare const MinusIcon: ({ alt, className, ...props }: IconProps) => import("react/jsx-runtime").JSX.Element;
6
+ export {};
@@ -0,0 +1,6 @@
1
+ import { type SVGProps } from "react";
2
+ interface IconProps extends SVGProps<SVGSVGElement> {
3
+ alt?: string;
4
+ }
5
+ export declare const OpenNewIcon: ({ alt, className, ...props }: IconProps) => import("react/jsx-runtime").JSX.Element;
6
+ export {};
@@ -0,0 +1,6 @@
1
+ import { type SVGProps } from "react";
2
+ interface IconProps extends SVGProps<SVGSVGElement> {
3
+ alt?: string;
4
+ }
5
+ export declare const PencilIcon: ({ alt, className, ...props }: IconProps) => import("react/jsx-runtime").JSX.Element;
6
+ export {};
@@ -0,0 +1,6 @@
1
+ import { type SVGProps } from "react";
2
+ interface IconProps extends SVGProps<SVGSVGElement> {
3
+ alt?: string;
4
+ }
5
+ export declare const PhoneIcon: ({ alt, className, ...props }: IconProps) => import("react/jsx-runtime").JSX.Element;
6
+ export {};
@@ -0,0 +1,6 @@
1
+ import { type SVGProps } from "react";
2
+ interface IconProps extends SVGProps<SVGSVGElement> {
3
+ alt?: string;
4
+ }
5
+ export declare const QuestionIcon: ({ alt, className, ...props }: IconProps) => import("react/jsx-runtime").JSX.Element;
6
+ export {};
@@ -0,0 +1,6 @@
1
+ import { type SVGProps } from "react";
2
+ interface IconProps extends SVGProps<SVGSVGElement> {
3
+ alt?: string;
4
+ }
5
+ export declare const ScooterIcon: ({ alt, className, ...props }: IconProps) => import("react/jsx-runtime").JSX.Element;
6
+ export {};
@@ -0,0 +1,6 @@
1
+ import { type SVGProps } from "react";
2
+ interface IconProps extends SVGProps<SVGSVGElement> {
3
+ alt?: string;
4
+ }
5
+ export declare const SearchIcon: ({ alt, className, ...props }: IconProps) => import("react/jsx-runtime").JSX.Element;
6
+ export {};
@@ -0,0 +1,6 @@
1
+ import { type SVGProps } from "react";
2
+ interface IconProps extends SVGProps<SVGSVGElement> {
3
+ alt?: string;
4
+ }
5
+ export declare const SettingsIcon: ({ alt, className, ...props }: IconProps) => import("react/jsx-runtime").JSX.Element;
6
+ export {};
@@ -0,0 +1,6 @@
1
+ import { type SVGProps } from "react";
2
+ interface IconProps extends SVGProps<SVGSVGElement> {
3
+ alt?: string;
4
+ }
5
+ export declare const TickAltIcon: ({ alt, className, ...props }: IconProps) => import("react/jsx-runtime").JSX.Element;
6
+ export {};
@@ -0,0 +1,6 @@
1
+ import { type SVGProps } from "react";
2
+ interface IconProps extends SVGProps<SVGSVGElement> {
3
+ alt?: string;
4
+ }
5
+ export declare const TickIcon: ({ alt, className, ...props }: IconProps) => import("react/jsx-runtime").JSX.Element;
6
+ export {};
@@ -0,0 +1,6 @@
1
+ import { type SVGProps } from "react";
2
+ interface IconProps extends SVGProps<SVGSVGElement> {
3
+ alt?: string;
4
+ }
5
+ export declare const VanIcon: ({ alt, className, ...props }: IconProps) => import("react/jsx-runtime").JSX.Element;
6
+ export {};
@@ -0,0 +1,6 @@
1
+ import { type SVGProps } from "react";
2
+ interface IconProps extends SVGProps<SVGSVGElement> {
3
+ alt?: string;
4
+ }
5
+ export declare const WarningIcon: ({ alt, className, ...props }: IconProps) => import("react/jsx-runtime").JSX.Element;
6
+ export {};
@@ -0,0 +1,6 @@
1
+ import { type SVGProps } from "react";
2
+ interface IconProps extends SVGProps<SVGSVGElement> {
3
+ alt?: string;
4
+ }
5
+ export declare const WriteIcon: ({ alt, className, ...props }: IconProps) => import("react/jsx-runtime").JSX.Element;
6
+ export {};
@@ -1,13 +1,39 @@
1
- import { type SVGProps } from "react";
2
- export interface IconProps extends SVGProps<SVGSVGElement> {
3
- /** **(Optional)** Alt text for the Icon. Will be rendered in a title tag in the SVG. */
4
- alt?: string;
5
- /** **(Optional)** Additional class names to forward to the Icon. */
6
- className?: string;
7
- /** The name of the icon to render. See the readme for how to add new icons. */
8
- icon?: IconName;
9
- }
10
- export declare const Icon: ({ alt, className, icon, ...props }: IconProps) => import("react/jsx-runtime").JSX.Element;
11
- export default Icon;
12
- export declare const iconNames: readonly ["arrow-right", "chevron", "search"];
13
- export type IconName = (typeof iconNames)[number];
1
+ export { AddIcon } from "./AddIcon";
2
+ export { ArrowDownIcon } from "./ArrowDownIcon";
3
+ export { ArrowLeftIcon } from "./ArrowLeftIcon";
4
+ export { ArrowRightIcon } from "./ArrowRightIcon";
5
+ export { ArrowUpIcon } from "./ArrowUpIcon";
6
+ export { AvatarAltIcon } from "./AvatarAltIcon";
7
+ export { AvatarIcon } from "./AvatarIcon";
8
+ export { BasketIcon } from "./BasketIcon";
9
+ export { CalendarIcon } from "./CalendarIcon";
10
+ export { ChevronDownIcon } from "./ChevronDownIcon";
11
+ export { ChevronLeftIcon } from "./ChevronLeftIcon";
12
+ export { ChevronRightIcon } from "./ChevronRightIcon";
13
+ export { ChevronUpIcon } from "./ChevronUpIcon";
14
+ export { ClockIcon } from "./ClockIcon";
15
+ export { CloseAltIcon } from "./CloseAltIcon";
16
+ export { CloseIcon } from "./CloseIcon";
17
+ export { CoopCardIcon } from "./CoopCardIcon";
18
+ export { CoopIcon } from "./CoopIcon";
19
+ export { CoopLocationIcon } from "./CoopLocationIcon";
20
+ export { DownloadIcon } from "./DownloadIcon";
21
+ export { HomeIcon } from "./HomeIcon";
22
+ export { InformationIcon } from "./InformationIcon";
23
+ export { LocationIcon } from "./LocationIcon";
24
+ export { MailIcon } from "./MailIcon";
25
+ export { MenuIcon } from "./MenuIcon";
26
+ export { MessageIcon } from "./MessageIcon";
27
+ export { MinusIcon } from "./MinusIcon";
28
+ export { OpenNewIcon } from "./OpenNewIcon";
29
+ export { PencilIcon } from "./PencilIcon";
30
+ export { PhoneIcon } from "./PhoneIcon";
31
+ export { QuestionIcon } from "./QuestionIcon";
32
+ export { ScooterIcon } from "./ScooterIcon";
33
+ export { SearchIcon } from "./SearchIcon";
34
+ export { SettingsIcon } from "./SettingsIcon";
35
+ export { TickAltIcon } from "./TickAltIcon";
36
+ export { TickIcon } from "./TickIcon";
37
+ export { VanIcon } from "./VanIcon";
38
+ export { WarningIcon } from "./WarningIcon";
39
+ export { WriteIcon } from "./WriteIcon";
@@ -1,3 +1,2 @@
1
- import { JSX } from "react";
2
- export declare const RootSVG: () => JSX.Element;
1
+ export declare const RootSVG: () => import("react/jsx-runtime").JSX.Element;
3
2
  export default RootSVG;
@@ -1,7 +1,7 @@
1
- import { jsxs, jsx } from 'react/jsx-runtime';
1
+ import { jsx } from 'react/jsx-runtime';
2
2
 
3
3
  const RootSVG = () => {
4
- return (jsxs("svg", { height: "0", width: "0", xmlns: "http://www.w3.org/2000/svg", children: [jsx("symbol", { fill: "currentColor", id: "arrow-right", viewBox: "0 0 22 20", children: jsx("path", { clipRule: "evenodd", d: "M11.127 1.65a.9.9 0 0 1 1.246-1.3l8.812 8.46a1.65 1.65 0 0 1 0 2.38l-8.812 8.46a.9.9 0 0 1-1.246-1.3l7.76-7.45H1.25a.9.9 0 1 1 0-1.8h17.638z", fill: "currentColor", fillRule: "evenodd" }) }), jsx("symbol", { id: "chevron", viewBox: "0 0 16 29", children: jsx("path", { d: "M2 28.1a1.6 1.6 0 0 1-1.2-2.7l11-10.9-11-11a1.6 1.6 0 1 1 2.2-2l12 12a1.6 1.6 0 0 1 0 2.2l-12 12c-.3.4-.7.5-1 .5z" }) }), jsx("symbol", { fill: "currentColor", id: "search", viewBox: "0 0 24 24", children: jsx("path", { clipRule: "evenodd", d: "M4.65 10.5a5.85 5.85 0 1 1 11.7 0 5.85 5.85 0 0 1-11.7 0m5.85-7.65a7.65 7.65 0 1 0 4.736 13.658l4.378 4.378a.9.9 0 1 0 1.273-1.273l-4.378-4.378A7.65 7.65 0 0 0 10.5 2.85", fill: "currentColor", fillRule: "evenodd" }) }), jsx("defs", { children: jsx("clipPath", { clipPathUnits: "objectBoundingBox", id: "squircle", children: jsx("path", { d: "M0,0.5 C0,0.165,0.165,0,0.5,0 S1,0.165,1,0.5 S0.835,1,0.5,1 S0,0.835,0,0.5" }) }) })] }));
4
+ return (jsx("svg", { height: "0", width: "0", xmlns: "http://www.w3.org/2000/svg", children: jsx("defs", { children: jsx("clipPath", { clipPathUnits: "objectBoundingBox", id: "squircle", children: jsx("path", { d: "M0,0.5 C0,0.165,0.165,0,0.5,0 S1,0.165,1,0.5 S0.835,1,0.5,1 S0,0.835,0,0.5" }) }) }) }));
5
5
  };
6
6
 
7
7
  export { RootSVG, RootSVG as default };
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@coopdigital/react",
3
3
  "type": "module",
4
- "version": "0.16.0",
4
+ "version": "0.18.0",
5
5
  "private": false,
6
6
  "publishConfig": {
7
7
  "access": "public"
@@ -34,6 +34,7 @@
34
34
  "test:e2e:ui": "npx playwright test --ui",
35
35
  "test:e2e:ci": "npx playwright test --shard=$CI_NODE_INDEX/$CI_NODE_TOTAL",
36
36
  "build": "tsx scripts build",
37
+ "build:icons": "tsx scripts build-icons",
37
38
  "build:storybook": "storybook build --disable-telemetry && npm run storybook:fix-paths",
38
39
  "storybook": "storybook dev -p 6006",
39
40
  "storybook:playwright": "storybook dev -p 9000",
@@ -44,7 +45,7 @@
44
45
  "description": "",
45
46
  "devDependencies": {
46
47
  "@axe-core/playwright": "^4.10.1",
47
- "@coopdigital/styles": "^0.15.0",
48
+ "@coopdigital/styles": "^0.15.2",
48
49
  "@playwright/test": "^1.51.1",
49
50
  "@storybook/addon-a11y": "^8.6.12",
50
51
  "@storybook/addon-essentials": "^8.6.12",
@@ -66,5 +67,5 @@
66
67
  "react": "^19.0.0",
67
68
  "react-dom": "^19.0.0"
68
69
  },
69
- "gitHead": "802023453505543e6b360e7e390bed6f983abf1a"
70
+ "gitHead": "0fa78c25e19ac1c1dc6af564c570e94646e71bc4"
70
71
  }
@@ -0,0 +1,30 @@
1
+ import { type SVGProps, useId } from "react"
2
+
3
+ interface IconProps extends SVGProps<SVGSVGElement> {
4
+ alt?: string
5
+ }
6
+
7
+ export const AddIcon = ({ alt, className, ...props }: IconProps) => {
8
+ const id = useId()
9
+ const componentProps = {
10
+ "aria-labelledby": alt ? id : undefined,
11
+ className: `coop-icon ${className ?? ""}`.trim(),
12
+ fill: "none",
13
+ role: alt ? "img" : undefined,
14
+ viewBox: "0 0 32 32",
15
+ ...props,
16
+ }
17
+ return (
18
+ <svg {...componentProps}>
19
+ {alt ? <title id={id}>{alt}</title> : null}
20
+ <path
21
+ d="M24.7 16.72a1 1 0 0 1-.7.28H8a1 1 0 1 1 0-2h16a1 1 0 0 1 1 1 1 1 0 0 1-.3.72"
22
+ fill="currentColor"
23
+ />
24
+ <path
25
+ d="M16.72 24.7a1 1 0 0 1-.72.3 1 1 0 0 1-1-1V8a1 1 0 0 1 2 0v16a1 1 0 0 1-.28.7"
26
+ fill="currentColor"
27
+ />
28
+ </svg>
29
+ )
30
+ }
@@ -0,0 +1,27 @@
1
+ import { type SVGProps, useId } from "react"
2
+
3
+ interface IconProps extends SVGProps<SVGSVGElement> {
4
+ alt?: string
5
+ }
6
+
7
+ export const ArrowDownIcon = ({ alt, className, ...props }: IconProps) => {
8
+ const id = useId()
9
+ const componentProps = {
10
+ "aria-labelledby": alt ? id : undefined,
11
+ className: `coop-icon ${className ?? ""}`.trim(),
12
+ fill: "none",
13
+ role: alt ? "img" : undefined,
14
+ viewBox: "0 0 32 32",
15
+ ...props,
16
+ }
17
+ return (
18
+ <svg {...componentProps}>
19
+ {alt ? <title id={id}>{alt}</title> : null}
20
+ <path d="M15 28.66V3a1 1 0 0 1 2 0v25.66a1 1 0 0 1-2 0" fill="currentColor" />
21
+ <path
22
+ d="M3 17a1 1 0 0 1 .29-.71 1 1 0 0 1 1.42 0L16 27.58l11.29-11.29a1 1 0 0 1 1.42 0 1 1 0 0 1 0 1.41l-12 12a1 1 0 0 1-1.41 0l-12-12A1 1 0 0 1 3 17"
23
+ fill="currentColor"
24
+ />
25
+ </svg>
26
+ )
27
+ }
@@ -0,0 +1,27 @@
1
+ import { type SVGProps, useId } from "react"
2
+
3
+ interface IconProps extends SVGProps<SVGSVGElement> {
4
+ alt?: string
5
+ }
6
+
7
+ export const ArrowLeftIcon = ({ alt, className, ...props }: IconProps) => {
8
+ const id = useId()
9
+ const componentProps = {
10
+ "aria-labelledby": alt ? id : undefined,
11
+ className: `coop-icon ${className ?? ""}`.trim(),
12
+ fill: "none",
13
+ role: alt ? "img" : undefined,
14
+ viewBox: "0 0 32 32",
15
+ ...props,
16
+ }
17
+ return (
18
+ <svg {...componentProps}>
19
+ {alt ? <title id={id}>{alt}</title> : null}
20
+ <path d="M3.34 17H29a1 1 0 0 0 0-2H3.34a1 1 0 0 0 0 2" fill="currentColor" />
21
+ <path
22
+ d="M15 29a1 1 0 0 0 .71-.29 1 1 0 0 0 0-1.42L5.12 16.71a1 1 0 0 1 0-1.42L15.71 4.71a1 1 0 0 0 0-1.42 1 1 0 0 0-1.41 0l-12 12a1 1 0 0 0 0 1.42l12 12a1 1 0 0 0 .7.29"
23
+ fill="currentColor"
24
+ />
25
+ </svg>
26
+ )
27
+ }
@@ -0,0 +1,27 @@
1
+ import { type SVGProps, useId } from "react"
2
+
3
+ interface IconProps extends SVGProps<SVGSVGElement> {
4
+ alt?: string
5
+ }
6
+
7
+ export const ArrowRightIcon = ({ alt, className, ...props }: IconProps) => {
8
+ const id = useId()
9
+ const componentProps = {
10
+ "aria-labelledby": alt ? id : undefined,
11
+ className: `coop-icon ${className ?? ""}`.trim(),
12
+ fill: "none",
13
+ role: alt ? "img" : undefined,
14
+ viewBox: "0 0 32 32",
15
+ ...props,
16
+ }
17
+ return (
18
+ <svg {...componentProps}>
19
+ {alt ? <title id={id}>{alt}</title> : null}
20
+ <path d="M28.7 15H3a1 1 0 0 0 0 2h25.7a1 1 0 0 0 0-2" fill="currentColor" />
21
+ <path
22
+ d="M17 3a1 1 0 0 0-.7.3 1 1 0 0 0 0 1.4l10.6 10.6a1 1 0 0 1 0 1.4L16.3 27.3a1 1 0 0 0 0 1.4 1 1 0 0 0 1.4 0l12-12a1 1 0 0 0 0-1.4l-12-12A1 1 0 0 0 17 3"
23
+ fill="currentColor"
24
+ />
25
+ </svg>
26
+ )
27
+ }
@@ -0,0 +1,27 @@
1
+ import { type SVGProps, useId } from "react"
2
+
3
+ interface IconProps extends SVGProps<SVGSVGElement> {
4
+ alt?: string
5
+ }
6
+
7
+ export const ArrowUpIcon = ({ alt, className, ...props }: IconProps) => {
8
+ const id = useId()
9
+ const componentProps = {
10
+ "aria-labelledby": alt ? id : undefined,
11
+ className: `coop-icon ${className ?? ""}`.trim(),
12
+ fill: "none",
13
+ role: alt ? "img" : undefined,
14
+ viewBox: "0 0 32 32",
15
+ ...props,
16
+ }
17
+ return (
18
+ <svg {...componentProps}>
19
+ {alt ? <title id={id}>{alt}</title> : null}
20
+ <path d="M17 3.34V29a1 1 0 0 1-2 0V3.34a1 1 0 0 1 2 0" fill="currentColor" />
21
+ <path
22
+ d="M29 15a1 1 0 0 1-.29.71 1 1 0 0 1-1.42 0L16 4.42 4.71 15.71a1 1 0 0 1-1.42 0 1 1 0 0 1 0-1.41l12-12a1 1 0 0 1 1.41 0l12 12a1 1 0 0 1 .3.7"
23
+ fill="currentColor"
24
+ />
25
+ </svg>
26
+ )
27
+ }
@@ -0,0 +1,34 @@
1
+ import { type SVGProps, useId } from "react"
2
+
3
+ interface IconProps extends SVGProps<SVGSVGElement> {
4
+ alt?: string
5
+ }
6
+
7
+ export const AvatarAltIcon = ({ alt, className, ...props }: IconProps) => {
8
+ const id = useId()
9
+ const componentProps = {
10
+ "aria-labelledby": alt ? id : undefined,
11
+ className: `coop-icon ${className ?? ""}`.trim(),
12
+ fill: "none",
13
+ role: alt ? "img" : undefined,
14
+ viewBox: "0 0 32 32",
15
+ ...props,
16
+ }
17
+ return (
18
+ <svg {...componentProps}>
19
+ {alt ? <title id={id}>{alt}</title> : null}
20
+ <path
21
+ d="M16 32a16 16 0 1 1 16-16 16 16 0 0 1-16 16m0-30a14 14 0 1 0 14 14A14 14 0 0 0 16 2"
22
+ fill="currentColor"
23
+ />
24
+ <path
25
+ d="M16 8a5 5 0 1 1-5 5 5 5 0 0 1 5-5m0-2a7 7 0 1 0 7 7 7 7 0 0 0-7-7"
26
+ fill="currentColor"
27
+ />
28
+ <path
29
+ d="M5.64 27.85a.7.7 0 0 1-.19 0 1 1 0 0 1-.79-1.17A10.7 10.7 0 0 1 15.16 18h1.68a10.7 10.7 0 0 1 10.5 8.67 1 1 0 0 1-.79 1.17 1 1 0 0 1-1.17-.84 8.72 8.72 0 0 0-8.54-7h-1.68a8.72 8.72 0 0 0-8.54 7 1 1 0 0 1-.98.85"
30
+ fill="currentColor"
31
+ />
32
+ </svg>
33
+ )
34
+ }