@ztwoint/z-ui 0.1.109 → 0.1.110
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/components/radio/z2-radio.d.ts +3 -3
- package/dist/components/radio/z2-radio.js +46 -50
- package/dist/components/radio-card/radio-card.d.ts +10 -0
- package/dist/components/table/components/cell/avatar-cell.js +1 -1
- package/dist/components/table/table-provider.js +1 -1
- package/dist/components/table-card/table-card.js +1 -1
- package/dist/css/config/colors/semantic/text.css +3 -1
- package/dist/css/styles/tailwind.css +1 -1
- package/dist/index.d.ts +1 -0
- package/dist/index.js +4 -4
- package/dist/types/components/radio/z2-radio.d.ts +3 -3
- package/dist/types/components/radio-card/radio-card.d.ts +10 -0
- package/dist/types/index.d.ts +1 -0
- package/package.json +1 -1
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
2
|
import * as RadioGroupPrimitive from '@radix-ui/react-radio-group';
|
|
3
3
|
declare function Z2RadioGroup({ ...props }: React.ComponentProps<typeof RadioGroupPrimitive.Root>): import("react/jsx-runtime").JSX.Element;
|
|
4
|
-
declare
|
|
5
|
-
size?:
|
|
6
|
-
}
|
|
4
|
+
declare const Z2RadioGroupItem: React.ForwardRefExoticComponent<Omit<RadioGroupPrimitive.RadioGroupItemProps & React.RefAttributes<HTMLButtonElement>, "ref"> & {
|
|
5
|
+
size?: "sm" | "default" | "lg";
|
|
6
|
+
} & React.RefAttributes<HTMLButtonElement>>;
|
|
7
7
|
declare function Z2RadioGroupIndicator({ className, ...props }: React.ComponentProps<typeof RadioGroupPrimitive.Indicator>): import("react/jsx-runtime").JSX.Element;
|
|
8
8
|
export { Z2RadioGroup, Z2RadioGroupItem, Z2RadioGroupIndicator };
|
|
@@ -1,55 +1,51 @@
|
|
|
1
1
|
import { jsx as t } from "react/jsx-runtime";
|
|
2
|
+
import * as l from "react";
|
|
2
3
|
import * as o from "@radix-ui/react-radio-group";
|
|
3
4
|
import { cn as d } from "../../lib/utils.js";
|
|
4
|
-
function
|
|
5
|
+
function b({ ...e }) {
|
|
5
6
|
return /* @__PURE__ */ t(o.Root, { "data-slot": "radio-group", ...e });
|
|
6
7
|
}
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
"
|
|
17
|
-
"
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
)
|
|
49
|
-
}
|
|
50
|
-
);
|
|
51
|
-
}
|
|
52
|
-
function i({
|
|
8
|
+
const u = l.forwardRef(({ className: e, children: r, size: a = "default", ...s }, i) => /* @__PURE__ */ t(
|
|
9
|
+
o.Item,
|
|
10
|
+
{
|
|
11
|
+
ref: i,
|
|
12
|
+
"data-slot": "radio-group-item",
|
|
13
|
+
"data-size": a,
|
|
14
|
+
className: d(
|
|
15
|
+
// Base styles
|
|
16
|
+
"aspect-square rounded-full border-2 border-stroke-solid-high bg-surface-neutral-default",
|
|
17
|
+
"transition-all duration-200 ease-in-out relative",
|
|
18
|
+
"focus:outline-none",
|
|
19
|
+
// Size variants
|
|
20
|
+
"data-[size=sm]:size-3 data-[size=default]:size-4 data-[size=lg]:size-5",
|
|
21
|
+
// State styles
|
|
22
|
+
"hover:border-stroke-solid-hover hover:bg-surface-neutral-hover",
|
|
23
|
+
"data-[state=checked]:border-surface-accent-default data-[state=checked]:bg-surface-accent-default",
|
|
24
|
+
"data-[state=checked]:hover:border-surface-accent-hover data-[state=checked]:hover:bg-surface-accent-hover",
|
|
25
|
+
// Disabled state
|
|
26
|
+
"disabled:cursor-not-allowed disabled:opacity-50",
|
|
27
|
+
"disabled:border-stroke-solid-light disabled:bg-surface-neutral-disabled",
|
|
28
|
+
"disabled:hover:border-stroke-solid-light disabled:hover:bg-surface-neutral-disabled",
|
|
29
|
+
"disabled:data-[state=checked]:border-stroke-solid-light disabled:data-[state=checked]:bg-surface-neutral-disabled",
|
|
30
|
+
e
|
|
31
|
+
),
|
|
32
|
+
...s,
|
|
33
|
+
children: r ?? /* @__PURE__ */ t(
|
|
34
|
+
c,
|
|
35
|
+
{
|
|
36
|
+
className: d(
|
|
37
|
+
"rounded-full bg-surface-neutral-default",
|
|
38
|
+
"transition-all duration-200 ease-in-out",
|
|
39
|
+
a === "sm" && "size-1.5",
|
|
40
|
+
a === "default" && "size-2",
|
|
41
|
+
a === "lg" && "size-2.5"
|
|
42
|
+
)
|
|
43
|
+
}
|
|
44
|
+
)
|
|
45
|
+
}
|
|
46
|
+
));
|
|
47
|
+
u.displayName = "Z2RadioGroupItem";
|
|
48
|
+
function c({
|
|
53
49
|
className: e,
|
|
54
50
|
...r
|
|
55
51
|
}) {
|
|
@@ -66,7 +62,7 @@ function i({
|
|
|
66
62
|
);
|
|
67
63
|
}
|
|
68
64
|
export {
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
65
|
+
b as Z2RadioGroup,
|
|
66
|
+
c as Z2RadioGroupIndicator,
|
|
67
|
+
u as Z2RadioGroupItem
|
|
72
68
|
};
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
declare function Z2RadioCard({ primaryText, supportText, value, id, disabled, className, itemClassName, }: {
|
|
2
|
+
primaryText: string;
|
|
3
|
+
supportText: string;
|
|
4
|
+
value: string;
|
|
5
|
+
id?: string;
|
|
6
|
+
disabled?: boolean;
|
|
7
|
+
className?: string;
|
|
8
|
+
itemClassName?: string;
|
|
9
|
+
}): import("react/jsx-runtime").JSX.Element;
|
|
10
|
+
export default Z2RadioCard;
|
|
@@ -39,7 +39,7 @@ import "react-dom";
|
|
|
39
39
|
import "../../../../node_modules/@atlaskit/pragmatic-drag-and-drop/dist/esm/util/changing-window/count-events-for-safari.js";
|
|
40
40
|
import "../../../../node_modules/@atlaskit/pragmatic-drag-and-drop/dist/esm/ledger/dispatch-consumer-event.js";
|
|
41
41
|
import "@radix-ui/react-slot";
|
|
42
|
-
import "
|
|
42
|
+
import "../../../radio/z2-radio.js";
|
|
43
43
|
import "../../../segmented-control/item.js";
|
|
44
44
|
import "@radix-ui/react-popover";
|
|
45
45
|
import "../../../dynamic-table/z2-table.js";
|
|
@@ -44,7 +44,7 @@ import "react-dom";
|
|
|
44
44
|
import "../../node_modules/@atlaskit/pragmatic-drag-and-drop/dist/esm/util/changing-window/count-events-for-safari.js";
|
|
45
45
|
import "../../node_modules/@atlaskit/pragmatic-drag-and-drop/dist/esm/ledger/dispatch-consumer-event.js";
|
|
46
46
|
import "@radix-ui/react-slot";
|
|
47
|
-
import "
|
|
47
|
+
import "../radio/z2-radio.js";
|
|
48
48
|
import "../segmented-control/item.js";
|
|
49
49
|
import "@radix-ui/react-popover";
|
|
50
50
|
import "../dynamic-table/z2-table.js";
|
|
@@ -39,7 +39,7 @@ import "react-dom";
|
|
|
39
39
|
import "../../node_modules/@atlaskit/pragmatic-drag-and-drop/dist/esm/util/changing-window/count-events-for-safari.js";
|
|
40
40
|
import "../../node_modules/@atlaskit/pragmatic-drag-and-drop/dist/esm/ledger/dispatch-consumer-event.js";
|
|
41
41
|
import "@radix-ui/react-slot";
|
|
42
|
-
import "
|
|
42
|
+
import "../radio/z2-radio.js";
|
|
43
43
|
import "../segmented-control/item.js";
|
|
44
44
|
import "@radix-ui/react-popover";
|
|
45
45
|
import "../dynamic-table/z2-table.js";
|
|
@@ -4,6 +4,7 @@
|
|
|
4
4
|
--text-neutral-primary: var(--neutral-950);
|
|
5
5
|
--text-neutral-secondary: var(--neutral-600);
|
|
6
6
|
--text-neutral-muted: var(--neutral-400);
|
|
7
|
+
--text-neutral-pale: var(--neutral-200);
|
|
7
8
|
|
|
8
9
|
/* Text Colors - Inverted */
|
|
9
10
|
--text-inverted-primary: var(--neutral-00);
|
|
@@ -41,6 +42,7 @@
|
|
|
41
42
|
--text-neutral-primary: var(--neutral-950);
|
|
42
43
|
--text-neutral-secondary: var(--neutral-500);
|
|
43
44
|
--text-neutral-muted: var(--neutral-400);
|
|
45
|
+
--text-neutral-pale: var(--neutral-200);
|
|
44
46
|
|
|
45
47
|
/* Text Colors - Inverted - Dark Mode */
|
|
46
48
|
--text-inverted-primary: var(--neutral-00);
|
|
@@ -80,7 +82,7 @@
|
|
|
80
82
|
--color-text-neutral-primary: var(--text-neutral-primary);
|
|
81
83
|
--color-text-neutral-secondary: var(--text-neutral-secondary);
|
|
82
84
|
--color-text-neutral-muted: var(--text-neutral-muted);
|
|
83
|
-
|
|
85
|
+
--color-text-neutral-pale: var(--text-neutral-pale);
|
|
84
86
|
/* Text Colors - Inverted */
|
|
85
87
|
--color-text-inverted-primary: var(--text-inverted-primary);
|
|
86
88
|
--color-text-inverted-secondary: var(--text-inverted-secondary);
|