@purpurds/grid 5.11.0 → 5.11.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/grid.item.d.ts
CHANGED
|
@@ -14,5 +14,5 @@ export type ItemProps = {
|
|
|
14
14
|
noColGap?: boolean;
|
|
15
15
|
};
|
|
16
16
|
export declare const Item: ({ children, className, ["data-testid"]: dataTestId, colSpanSm, colSpanMd, colSpanLg, noColGap, }: ItemProps) => React.JSX.Element;
|
|
17
|
-
export declare const isItem: (child: ReactChild | ReactElement | ReactFragment | ReactPortal | string | number | boolean | null | undefined) => child is
|
|
17
|
+
export declare const isItem: (child: ReactChild | ReactElement | ReactFragment | ReactPortal | string | number | boolean | null | undefined) => child is ReactElement<ItemProps>;
|
|
18
18
|
//# sourceMappingURL=grid.item.d.ts.map
|
package/dist/grid.item.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"grid.item.d.ts","sourceRoot":"","sources":["../src/grid.item.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,EAEZ,UAAU,EACV,YAAY,EACZ,aAAa,EACb,SAAS,EACT,WAAW,EACZ,MAAM,OAAO,CAAC;AAOf,MAAM,MAAM,SAAS,GAAG;IACtB,QAAQ,EAAE,SAAS,CAAC;IACpB,CAAC,aAAa,CAAC,CAAC,EAAE,MAAM,CAAC;IACzB,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,kEAAkE;IAClE,SAAS,CAAC,EAAE,CAAC,GAAG,CAAC,GAAG,CAAC,GAAG,CAAC,CAAC;IAC1B,mEAAmE;IACnE,SAAS,CAAC,EAAE,CAAC,GAAG,CAAC,GAAG,CAAC,GAAG,CAAC,GAAG,CAAC,GAAG,CAAC,GAAG,CAAC,GAAG,CAAC,CAAC;IAC1C,kEAAkE;IAClE,SAAS,CAAC,EAAE,CAAC,GAAG,CAAC,GAAG,CAAC,GAAG,CAAC,GAAG,CAAC,GAAG,CAA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aAAa,GACb,WAAW,GACX,MAAM,GACN,MAAM,GACN,OAAO,GACP,IAAI,GACJ,SAAS,KACZ,KAAK,IAAI,YAAY,CAAC,SAAS,CAG+C,CAAC"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@purpurds/grid",
|
|
3
|
-
"version": "5.11.
|
|
3
|
+
"version": "5.11.1",
|
|
4
4
|
"license": "AGPL-3.0-only",
|
|
5
5
|
"main": "./dist/grid.cjs.js",
|
|
6
6
|
"types": "./dist/grid.d.ts",
|
|
@@ -15,33 +15,34 @@
|
|
|
15
15
|
"source": "src/grid.tsx",
|
|
16
16
|
"dependencies": {
|
|
17
17
|
"classnames": "~2.5.0",
|
|
18
|
-
"@purpurds/tokens": "5.11.
|
|
18
|
+
"@purpurds/tokens": "5.11.1"
|
|
19
19
|
},
|
|
20
20
|
"devDependencies": {
|
|
21
21
|
"@rushstack/eslint-patch": "~1.10.0",
|
|
22
|
-
"@storybook/blocks": "
|
|
23
|
-
"@storybook/react": "
|
|
22
|
+
"@storybook/blocks": "^8.2.6",
|
|
23
|
+
"@storybook/react": "^8.2.6",
|
|
24
|
+
"storybook": "^8.2.6",
|
|
24
25
|
"@telia/base-rig": "~8.2.0",
|
|
25
26
|
"@telia/react-rig": "~3.2.0",
|
|
26
27
|
"@testing-library/dom": "~9.3.3",
|
|
27
28
|
"@testing-library/jest-dom": "~6.4.0",
|
|
28
29
|
"@testing-library/react": "~14.3.0",
|
|
29
30
|
"@types/node": "20.12.12",
|
|
30
|
-
"@types/react-dom": "
|
|
31
|
-
"@types/react": "
|
|
31
|
+
"@types/react-dom": "^18.3.0",
|
|
32
|
+
"@types/react": "^18.3.3",
|
|
32
33
|
"builtin-modules": "~3.3.0",
|
|
33
34
|
"eslint-plugin-testing-library": "~6.2.0",
|
|
34
|
-
"eslint": "
|
|
35
|
+
"eslint": "^8.57.0",
|
|
35
36
|
"jsdom": "~22.1.0",
|
|
36
37
|
"lint-staged": "~10.5.3",
|
|
37
38
|
"prettier": "~2.8.8",
|
|
38
|
-
"react-dom": "
|
|
39
|
-
"react": "
|
|
40
|
-
"typescript": "
|
|
41
|
-
"vite": "
|
|
39
|
+
"react-dom": "^18.3.1",
|
|
40
|
+
"react": "^18.3.1",
|
|
41
|
+
"typescript": "^5.5.4",
|
|
42
|
+
"vite": "5.3.4",
|
|
42
43
|
"vitest": "~1.5.0",
|
|
43
|
-
"@purpurds/
|
|
44
|
-
"@purpurds/
|
|
44
|
+
"@purpurds/component-rig": "1.0.0",
|
|
45
|
+
"@purpurds/link": "5.11.1"
|
|
45
46
|
},
|
|
46
47
|
"scripts": {
|
|
47
48
|
"build:dev": "vite",
|
package/src/grid.stories.tsx
CHANGED
|
@@ -6,7 +6,7 @@ import type { Meta, StoryObj } from "@storybook/react";
|
|
|
6
6
|
|
|
7
7
|
import { Grid } from "./grid";
|
|
8
8
|
|
|
9
|
-
const meta
|
|
9
|
+
const meta = {
|
|
10
10
|
title: "Components/Grid",
|
|
11
11
|
component: Grid,
|
|
12
12
|
parameters: {
|
|
@@ -22,16 +22,25 @@ const meta: Meta<typeof Grid> = {
|
|
|
22
22
|
["data-testid"]: { control: { type: "text" } },
|
|
23
23
|
className: { control: { type: "text" } },
|
|
24
24
|
children: { control: { type: "text" } },
|
|
25
|
-
colsSm: {
|
|
26
|
-
|
|
27
|
-
|
|
25
|
+
colsSm: {
|
|
26
|
+
control: { type: "range", min: 1, max: 4, step: 1 },
|
|
27
|
+
table: { type: { summary: "1 | 2 | 3 | 4" } },
|
|
28
|
+
},
|
|
29
|
+
colsMd: {
|
|
30
|
+
control: { type: "range", min: 1, max: 8, step: 1 },
|
|
31
|
+
table: { type: { summary: "1 | 2 | 3 | 4 | 5 | 6 | 7 | 8" } },
|
|
32
|
+
},
|
|
33
|
+
colsLg: {
|
|
34
|
+
control: { type: "range", min: 1, max: 12, step: 1 },
|
|
35
|
+
table: { type: { summary: "1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12" } },
|
|
36
|
+
},
|
|
28
37
|
},
|
|
29
38
|
args: {
|
|
30
39
|
colsSm: 2,
|
|
31
40
|
colsMd: 4,
|
|
32
41
|
colsLg: 6,
|
|
33
42
|
},
|
|
34
|
-
}
|
|
43
|
+
} satisfies Meta<typeof Grid>;
|
|
35
44
|
|
|
36
45
|
export default meta;
|
|
37
46
|
|
|
@@ -4,7 +4,7 @@ import type { Meta, StoryObj } from "@storybook/react";
|
|
|
4
4
|
|
|
5
5
|
import { Grid } from "./grid";
|
|
6
6
|
|
|
7
|
-
const meta
|
|
7
|
+
const meta = {
|
|
8
8
|
title: "Components/Grid",
|
|
9
9
|
component: Grid.Item,
|
|
10
10
|
parameters: {
|
|
@@ -32,13 +32,6 @@ const meta: Meta<typeof Grid.Item> = {
|
|
|
32
32
|
colSpanMd: 8,
|
|
33
33
|
colSpanLg: 12,
|
|
34
34
|
},
|
|
35
|
-
};
|
|
36
|
-
|
|
37
|
-
export default meta;
|
|
38
|
-
|
|
39
|
-
type Story = StoryObj<typeof Grid.Item>;
|
|
40
|
-
|
|
41
|
-
export const Item: Story = {
|
|
42
35
|
render: ({ children, ...args }) => (
|
|
43
36
|
<Grid.Item {...args}>
|
|
44
37
|
<div style={{ border: "1px solid lightgray", padding: ".5rem" }}>
|
|
@@ -47,4 +40,10 @@ export const Item: Story = {
|
|
|
47
40
|
</div>
|
|
48
41
|
</Grid.Item>
|
|
49
42
|
),
|
|
50
|
-
}
|
|
43
|
+
} satisfies Meta<typeof Grid.Item>;
|
|
44
|
+
|
|
45
|
+
export default meta;
|
|
46
|
+
|
|
47
|
+
type Story = StoryObj<typeof Grid.Item>;
|
|
48
|
+
|
|
49
|
+
export const Item: Story = {};
|