@coopdigital/react 1.1.1 → 1.1.2
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.
|
@@ -204,8 +204,10 @@ const shouldClose = (mode, value, closeOnSelect) => {
|
|
|
204
204
|
else
|
|
205
205
|
return false;
|
|
206
206
|
};
|
|
207
|
+
/* eslint-disable @typescript-eslint/no-unused-vars */
|
|
207
208
|
const isSingle = (m, d) => m === "single";
|
|
208
209
|
const isMultiple = (m, d) => m === "multiple";
|
|
209
210
|
const isRange = (m, d) => m === "range";
|
|
211
|
+
/* eslint-enable @typescript-eslint/no-unused-vars */
|
|
210
212
|
|
|
211
213
|
export { getDateValues, getDefaultMonth, getEndDate, getISODateString, getInitialDate, getMultipleDate, getRangeDate, getRangeFromString, getSingleDate, getStartDate, isMultiple, isRange, isSingle, isValidDate, isValidRangeFrom, isValidRangeTo, shouldClose, shouldSkipParsing };
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { type FieldsetHTMLAttributes, type JSX, Ref } from "react";
|
|
1
|
+
import { type FieldsetHTMLAttributes, HTMLAttributes, type JSX, Ref } from "react";
|
|
2
2
|
import { StandardSizes } from "../../../src/types";
|
|
3
3
|
import { type ErrorProps } from "../FieldMarkers/Error";
|
|
4
4
|
import { type HintProps } from "../FieldMarkers/Hint";
|
|
@@ -48,7 +48,7 @@ export declare const Fieldset: {
|
|
|
48
48
|
};
|
|
49
49
|
};
|
|
50
50
|
};
|
|
51
|
-
interface FieldsetFieldsProps {
|
|
51
|
+
interface FieldsetFieldsProps extends HTMLAttributes<HTMLDivElement> {
|
|
52
52
|
/** **(Optional)** Specify whether all descendent Fields should render inside a box. */
|
|
53
53
|
boxed?: boolean;
|
|
54
54
|
/** **(Optional)** Form elements inside the Fieldset.Fields container. */
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@coopdigital/react",
|
|
3
3
|
"type": "module",
|
|
4
|
-
"version": "1.1.
|
|
4
|
+
"version": "1.1.2",
|
|
5
5
|
"private": false,
|
|
6
6
|
"publishConfig": {
|
|
7
7
|
"access": "public"
|
|
@@ -52,7 +52,8 @@
|
|
|
52
52
|
"serve:storybook:test": "serve -p 9000 ./storybook-test",
|
|
53
53
|
"build:storybook:local": "storybook build --disable-telemetry",
|
|
54
54
|
"serve:storybook:local": "serve -p 9000 ./storybook-static",
|
|
55
|
-
"storybook": "storybook dev -p 6006"
|
|
55
|
+
"storybook": "storybook dev -p 6006",
|
|
56
|
+
"typecheck": "tsc --noEmit --jsx preserve --skipLibCheck"
|
|
56
57
|
},
|
|
57
58
|
"author": "",
|
|
58
59
|
"license": "MIT",
|
|
@@ -60,19 +61,19 @@
|
|
|
60
61
|
"devDependencies": {
|
|
61
62
|
"@axe-core/playwright": "^4.11.1",
|
|
62
63
|
"@playwright/test": "^1.59.1",
|
|
63
|
-
"@storybook/addon-a11y": "^10.3.
|
|
64
|
-
"@storybook/addon-docs": "^10.3.
|
|
65
|
-
"@storybook/addon-onboarding": "^10.3.
|
|
66
|
-
"@storybook/react-vite": "^10.3.
|
|
64
|
+
"@storybook/addon-a11y": "^10.3.5",
|
|
65
|
+
"@storybook/addon-docs": "^10.3.5",
|
|
66
|
+
"@storybook/addon-onboarding": "^10.3.5",
|
|
67
|
+
"@storybook/react-vite": "^10.3.5",
|
|
67
68
|
"@testing-library/jest-dom": "^6.9.1",
|
|
68
69
|
"@testing-library/react": "^16.3.2",
|
|
69
70
|
"@types/react": "^19.2.14",
|
|
70
71
|
"@types/react-dom": "^19.2.3",
|
|
71
|
-
"react": "^19.2.
|
|
72
|
-
"react-dom": "^19.2.
|
|
72
|
+
"react": "^19.2.5",
|
|
73
|
+
"react-dom": "^19.2.5",
|
|
73
74
|
"resize-observer-polyfill": "^1.5.1",
|
|
74
75
|
"serve": "^14.2.6",
|
|
75
|
-
"storybook": "^10.3.
|
|
76
|
+
"storybook": "^10.3.5",
|
|
76
77
|
"storybook-addon-tag-badges": "^3.1.0"
|
|
77
78
|
},
|
|
78
79
|
"peerDependencies": {
|
|
@@ -83,10 +84,10 @@
|
|
|
83
84
|
"storybook": "$storybook"
|
|
84
85
|
},
|
|
85
86
|
"dependencies": {
|
|
86
|
-
"@coopdigital/styles": "^1.1.
|
|
87
|
+
"@coopdigital/styles": "^1.1.2",
|
|
87
88
|
"@radix-ui/react-popover": "^1.1.15",
|
|
88
89
|
"clsx": "^2.1.1",
|
|
89
90
|
"react-day-picker": "^9.12.0"
|
|
90
91
|
},
|
|
91
|
-
"gitHead": "
|
|
92
|
+
"gitHead": "773259f20340eb832f4ec5a5241df5140f34ab43"
|
|
92
93
|
}
|
|
@@ -264,6 +264,8 @@ export const shouldClose = (mode: Mode, value: DateType, closeOnSelect?: boolean
|
|
|
264
264
|
else return false
|
|
265
265
|
}
|
|
266
266
|
|
|
267
|
+
/* eslint-disable @typescript-eslint/no-unused-vars */
|
|
267
268
|
export const isSingle = (m: Mode, d: DateType): d is Date & DateBase => m === "single"
|
|
268
269
|
export const isMultiple = (m: Mode, d: DateType): d is Date[] & DateBase => m === "multiple"
|
|
269
270
|
export const isRange = (m: Mode, d: DateType): d is DateRange & DateBase => m === "range"
|
|
271
|
+
/* eslint-enable @typescript-eslint/no-unused-vars */
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import clsx from "clsx"
|
|
2
|
-
import { type FieldsetHTMLAttributes, type JSX, Ref } from "react"
|
|
2
|
+
import { type FieldsetHTMLAttributes, HTMLAttributes, type JSX, Ref } from "react"
|
|
3
3
|
|
|
4
4
|
import { StandardSizes } from "../../../src/types"
|
|
5
5
|
import { Error as BaseError, type ErrorProps } from "../FieldMarkers/Error"
|
|
@@ -51,7 +51,7 @@ export const Fieldset = ({
|
|
|
51
51
|
)
|
|
52
52
|
}
|
|
53
53
|
|
|
54
|
-
interface FieldsetFieldsProps {
|
|
54
|
+
interface FieldsetFieldsProps extends HTMLAttributes<HTMLDivElement> {
|
|
55
55
|
/** **(Optional)** Specify whether all descendent Fields should render inside a box. */
|
|
56
56
|
boxed?: boolean
|
|
57
57
|
/** **(Optional)** Form elements inside the Fieldset.Fields container. */
|