@raystack/apsara 0.41.1 → 0.41.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.
- package/dist/avatar/avatar.d.ts +3 -3
- package/dist/avatar/avatar.d.ts.map +1 -1
- package/dist/badge/badge.d.ts +1 -1
- package/dist/body/body.d.ts +1 -1
- package/dist/body/body.d.ts.map +1 -1
- package/dist/box/box.d.ts +1 -1
- package/dist/box/box.d.ts.map +1 -1
- package/dist/button/button.d.ts +1 -1
- package/dist/checkbox/checkbox.d.ts +2 -2
- package/dist/checkbox/checkbox.d.ts.map +1 -1
- package/dist/container/container.d.ts +1 -1
- package/dist/container/container.d.ts.map +1 -1
- package/dist/dialog/dialog.d.ts +2 -2
- package/dist/dialog/dialog.d.ts.map +1 -1
- package/dist/display/display.d.ts +1 -1
- package/dist/display/display.d.ts.map +1 -1
- package/dist/dropdown-menu/dropdown-menu.d.ts +5 -5
- package/dist/emptystate/emptystate.d.ts +1 -1
- package/dist/emptystate/emptystate.d.ts.map +1 -1
- package/dist/errorstate/errorstate.d.ts +1 -1
- package/dist/errorstate/errorstate.d.ts.map +1 -1
- package/dist/flex/flex.d.ts +1 -1
- package/dist/grid/grid.d.ts +1 -1
- package/dist/grid/grid.d.ts.map +1 -1
- package/dist/headline/headline.d.ts +1 -1
- package/dist/headline/headline.d.ts.map +1 -1
- package/dist/image/image.d.ts +1 -1
- package/dist/image/image.d.ts.map +1 -1
- package/dist/inputfield/inputfield.d.ts +1 -1
- package/dist/inputfield/inputfield.d.ts.map +1 -1
- package/dist/label/label.d.ts +1 -1
- package/dist/label/label.d.ts.map +1 -1
- package/dist/link/link.d.ts +1 -1
- package/dist/link/link.d.ts.map +1 -1
- package/dist/node_modules/.pnpm/@radix-ui_react-slot@1.0.2_@types_react@18.2.12_react@18.2.0/node_modules/@radix-ui/react-slot/dist/index.cjs +2 -0
- package/dist/node_modules/.pnpm/@radix-ui_react-slot@1.0.2_@types_react@18.2.12_react@18.2.0/node_modules/@radix-ui/react-slot/dist/index.cjs.map +1 -1
- package/dist/node_modules/.pnpm/@radix-ui_react-slot@1.0.2_@types_react@18.2.12_react@18.2.0/node_modules/@radix-ui/react-slot/dist/index.js +2 -1
- package/dist/node_modules/.pnpm/@radix-ui_react-slot@1.0.2_@types_react@18.2.12_react@18.2.0/node_modules/@radix-ui/react-slot/dist/index.js.map +1 -1
- package/dist/radio/radio.d.ts +2 -2
- package/dist/radio/radio.d.ts.map +1 -1
- package/dist/scroll-area/scrollarea.d.ts +2 -2
- package/dist/select/select.d.ts +2 -2
- package/dist/separator/separator.d.ts +1 -1
- package/dist/separator/separator.d.ts.map +1 -1
- package/dist/sheet/sheet.d.ts +2 -2
- package/dist/sheet/sheet.d.ts.map +1 -1
- package/dist/sidebar/sidebar.d.ts +3 -3
- package/dist/sidebar/sidebar.d.ts.map +1 -1
- package/dist/style.css +1 -1
- package/dist/switch/switch.d.ts +2 -2
- package/dist/switch/switch.d.ts.map +1 -1
- package/dist/table/table.d.ts +7 -7
- package/dist/tabs/tabs.d.ts +4 -4
- package/dist/tabs/tabs.d.ts.map +1 -1
- package/dist/text/text.d.ts +1 -1
- package/dist/text/text.d.ts.map +1 -1
- package/dist/textarea/textarea.d.ts +2 -2
- package/dist/textarea/textarea.d.ts.map +1 -1
- package/dist/textfield/textfield.d.ts +2 -2
- package/dist/textfield/textfield.d.ts.map +1 -1
- package/dist/title/title.d.ts +1 -1
- package/dist/title/title.d.ts.map +1 -1
- package/dist/toggle-group/togglegroup.d.ts +2 -2
- package/dist/toggle-group/togglegroup.d.ts.map +1 -1
- package/dist/v1/components/announcement-bar/announcement-bar.d.ts +1 -1
- package/dist/v1/components/announcement-bar/announcement-bar.d.ts.map +1 -1
- package/dist/v1/components/avatar/avatar.d.ts +1 -1
- package/dist/v1/components/avatar/avatar.d.ts.map +1 -1
- package/dist/v1/components/badge/badge.d.ts +1 -1
- package/dist/v1/components/badge/badge.d.ts.map +1 -1
- package/dist/v1/components/box/box.d.ts +1 -1
- package/dist/v1/components/box/box.d.ts.map +1 -1
- package/dist/v1/components/breadcrumb/breadcrumb.d.ts +1 -1
- package/dist/v1/components/button/button.d.ts +1 -1
- package/dist/v1/components/callout/callout.d.ts +1 -1
- package/dist/v1/components/callout/callout.d.ts.map +1 -1
- package/dist/v1/components/checkbox/checkbox.d.ts +1 -1
- package/dist/v1/components/checkbox/checkbox.d.ts.map +1 -1
- package/dist/v1/components/chip/chip.d.ts +1 -1
- package/dist/v1/components/chip/chip.d.ts.map +1 -1
- package/dist/v1/components/container/container.d.ts +1 -1
- package/dist/v1/components/container/container.d.ts.map +1 -1
- package/dist/v1/components/dialog/dialog.d.ts +1 -1
- package/dist/v1/components/dialog/dialog.d.ts.map +1 -1
- package/dist/v1/components/dropdown-menu/dropdown-menu.d.ts +5 -5
- package/dist/v1/components/flex/flex.d.ts +1 -1
- package/dist/v1/components/headline/headline.cjs +8 -4
- package/dist/v1/components/headline/headline.cjs.map +1 -1
- package/dist/v1/components/headline/headline.d.ts +20 -4
- package/dist/v1/components/headline/headline.d.ts.map +1 -1
- package/dist/v1/components/headline/headline.js +8 -4
- package/dist/v1/components/headline/headline.js.map +1 -1
- package/dist/v1/components/headline/headline.module.css.cjs +1 -1
- package/dist/v1/components/headline/headline.module.css.js +1 -1
- package/dist/v1/components/headline/index.d.ts +1 -1
- package/dist/v1/components/headline/index.d.ts.map +1 -1
- package/dist/v1/components/icon-button/icon-button.d.ts +1 -1
- package/dist/v1/components/icon-button/icon-button.d.ts.map +1 -1
- package/dist/v1/components/image/image.d.ts +1 -1
- package/dist/v1/components/image/image.d.ts.map +1 -1
- package/dist/v1/components/indicator/indicator.d.ts +1 -1
- package/dist/v1/components/indicator/indicator.d.ts.map +1 -1
- package/dist/v1/components/input-field/input-field.d.ts +1 -1
- package/dist/v1/components/input-field/input-field.d.ts.map +1 -1
- package/dist/v1/components/label/label.d.ts +1 -1
- package/dist/v1/components/label/label.d.ts.map +1 -1
- package/dist/v1/components/link/link.cjs +17 -63
- package/dist/v1/components/link/link.cjs.map +1 -1
- package/dist/v1/components/link/link.d.ts +2 -11
- package/dist/v1/components/link/link.d.ts.map +1 -1
- package/dist/v1/components/link/link.js +17 -63
- package/dist/v1/components/link/link.js.map +1 -1
- package/dist/v1/components/link/link.module.css.cjs +1 -1
- package/dist/v1/components/link/link.module.css.js +1 -1
- package/dist/v1/components/list/list.d.ts +1 -1
- package/dist/v1/components/list/list.d.ts.map +1 -1
- package/dist/v1/components/radio/radio.d.ts +1 -1
- package/dist/v1/components/radio/radio.d.ts.map +1 -1
- package/dist/v1/components/select/select.d.ts +4 -5
- package/dist/v1/components/select/select.d.ts.map +1 -1
- package/dist/v1/components/sheet/sheet.d.ts +2 -2
- package/dist/v1/components/sheet/sheet.d.ts.map +1 -1
- package/dist/v1/components/side-panel/side-panel.d.ts +1 -1
- package/dist/v1/components/side-panel/side-panel.d.ts.map +1 -1
- package/dist/v1/components/slider/slider.d.ts +1 -1
- package/dist/v1/components/slider/slider.d.ts.map +1 -1
- package/dist/v1/components/spinner/spinner.d.ts +1 -1
- package/dist/v1/components/spinner/spinner.d.ts.map +1 -1
- package/dist/v1/components/table/table.d.ts +4 -4
- package/dist/v1/components/tabs/tabs.d.ts +1 -1
- package/dist/v1/components/tabs/tabs.d.ts.map +1 -1
- package/dist/v1/components/text/index.d.ts +1 -1
- package/dist/v1/components/text/index.d.ts.map +1 -1
- package/dist/v1/components/text/text.cjs +61 -7
- package/dist/v1/components/text/text.cjs.map +1 -1
- package/dist/v1/components/text/text.d.ts +40 -8
- package/dist/v1/components/text/text.d.ts.map +1 -1
- package/dist/v1/components/text/text.js +92 -39
- package/dist/v1/components/text/text.js.map +1 -1
- package/dist/v1/components/text/text.module.css.cjs +2 -2
- package/dist/v1/components/text/text.module.css.js +2 -2
- package/dist/v1/components/textfield/textfield.d.ts +2 -2
- package/dist/v1/components/textfield/textfield.d.ts.map +1 -1
- package/dist/v1/components/tooltip/tooltip.d.ts +1 -1
- package/dist/v1/components/tooltip/tooltip.d.ts.map +1 -1
- package/dist/v1/node_modules/.pnpm/@radix-ui_react-slot@1.0.2_@types_react@18.2.12_react@18.2.0/node_modules/@radix-ui/react-slot/dist/index.cjs +2 -0
- package/dist/v1/node_modules/.pnpm/@radix-ui_react-slot@1.0.2_@types_react@18.2.12_react@18.2.0/node_modules/@radix-ui/react-slot/dist/index.cjs.map +1 -1
- package/dist/v1/node_modules/.pnpm/@radix-ui_react-slot@1.0.2_@types_react@18.2.12_react@18.2.0/node_modules/@radix-ui/react-slot/dist/index.js +2 -1
- package/dist/v1/node_modules/.pnpm/@radix-ui_react-slot@1.0.2_@types_react@18.2.12_react@18.2.0/node_modules/@radix-ui/react-slot/dist/index.js.map +1 -1
- package/dist/v1/style.css +1 -1
- package/package.json +1 -1
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import * as TabsPrimitive from "@radix-ui/react-tabs";
|
|
2
2
|
import { type VariantProps } from "class-variance-authority";
|
|
3
3
|
import { ComponentPropsWithoutRef, ReactNode } from "react";
|
|
4
|
-
declare const root: (props?: import("class-variance-authority/
|
|
4
|
+
declare const root: (props?: import("class-variance-authority/types").ClassProp | undefined) => string;
|
|
5
5
|
interface TabsRootProps extends ComponentPropsWithoutRef<typeof TabsPrimitive.Root>, VariantProps<typeof root> {
|
|
6
6
|
defaultValue?: string;
|
|
7
7
|
'aria-label'?: string;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"tabs.d.ts","sourceRoot":"","sources":["../../../../v1/components/tabs/tabs.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,aAAa,MAAM,sBAAsB,CAAC;AACtD,OAAO,EAAO,KAAK,YAAY,EAAE,MAAM,0BAA0B,CAAC;AAClE,OAAO,EAAE,wBAAwB,EAA0B,SAAS,EAAE,MAAM,OAAO,CAAC;AAIpF,QAAA,MAAM,IAAI,
|
|
1
|
+
{"version":3,"file":"tabs.d.ts","sourceRoot":"","sources":["../../../../v1/components/tabs/tabs.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,aAAa,MAAM,sBAAsB,CAAC;AACtD,OAAO,EAAO,KAAK,YAAY,EAAE,MAAM,0BAA0B,CAAC;AAClE,OAAO,EAAE,wBAAwB,EAA0B,SAAS,EAAE,MAAM,OAAO,CAAC;AAIpF,QAAA,MAAM,IAAI,oFAAmB,CAAC;AAK9B,UAAU,aACR,SAAQ,wBAAwB,CAAC,OAAO,aAAa,CAAC,IAAI,CAAC,EACzD,YAAY,CAAC,OAAO,IAAI,CAAC;IAC3B,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,YAAY,CAAC,EAAE,MAAM,CAAC;CACvB;AAED,UAAU,gBACR,SAAQ,wBAAwB,CAAC,OAAO,aAAa,CAAC,OAAO,CAAC;IAC9D,IAAI,CAAC,EAAE,SAAS,CAAC;IACjB,QAAQ,CAAC,EAAE,OAAO,CAAC;CACpB;AA0DD,eAAO,MAAM,IAAI;;;;;CAKhB,CAAC"}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export
|
|
1
|
+
export * from "./text";
|
|
2
2
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../v1/components/text/index.tsx"],"names":[],"mappings":"AAAA,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../v1/components/text/index.tsx"],"names":[],"mappings":"AAAA,cAAc,QAAQ,CAAC"}
|
|
@@ -1,10 +1,12 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
3
|
var jsxRuntime = require('../../node_modules/.pnpm/react@18.2.0/node_modules/react/jsx-runtime.cjs');
|
|
4
|
-
var index = require('../../node_modules/.pnpm/class-variance-authority@0.7.1/node_modules/class-variance-authority/dist/index.cjs');
|
|
4
|
+
var index$1 = require('../../node_modules/.pnpm/class-variance-authority@0.7.1/node_modules/class-variance-authority/dist/index.cjs');
|
|
5
|
+
var React = require('react');
|
|
6
|
+
var index = require('../../node_modules/.pnpm/@radix-ui_react-slot@1.0.2_@types_react@18.2.12_react@18.2.0/node_modules/@radix-ui/react-slot/dist/index.cjs');
|
|
5
7
|
var text_module = require('./text.module.css.cjs');
|
|
6
8
|
|
|
7
|
-
const
|
|
9
|
+
const textVariants = index$1.cva(text_module.default.text, {
|
|
8
10
|
variants: {
|
|
9
11
|
variant: {
|
|
10
12
|
primary: text_module.default["text-primary"],
|
|
@@ -17,6 +19,11 @@ const text = index.cva(text_module.default.text, {
|
|
|
17
19
|
success: text_module.default["text-success"],
|
|
18
20
|
},
|
|
19
21
|
size: {
|
|
22
|
+
micro: text_module.default["text-micro"],
|
|
23
|
+
mini: text_module.default["text-mini"],
|
|
24
|
+
small: text_module.default["text-small"],
|
|
25
|
+
regular: text_module.default["text-regular"],
|
|
26
|
+
large: text_module.default["text-large"],
|
|
20
27
|
1: text_module.default["text-1"],
|
|
21
28
|
2: text_module.default["text-2"],
|
|
22
29
|
3: text_module.default["text-3"],
|
|
@@ -29,6 +36,8 @@ const text = index.cva(text_module.default.text, {
|
|
|
29
36
|
10: text_module.default["text-10"],
|
|
30
37
|
},
|
|
31
38
|
weight: {
|
|
39
|
+
regular: text_module.default["text-weight-regular"],
|
|
40
|
+
medium: text_module.default["text-weight-medium"],
|
|
32
41
|
bold: text_module.default["text-weight-bold"],
|
|
33
42
|
bolder: text_module.default["text-weight-bolder"],
|
|
34
43
|
normal: text_module.default["text-weight-normal"],
|
|
@@ -43,16 +52,61 @@ const text = index.cva(text_module.default.text, {
|
|
|
43
52
|
800: text_module.default["text-weight-800"],
|
|
44
53
|
900: text_module.default["text-weight-900"],
|
|
45
54
|
},
|
|
55
|
+
transform: {
|
|
56
|
+
capitalize: text_module.default["text-transform-capitalize"],
|
|
57
|
+
uppercase: text_module.default["text-transform-uppercase"],
|
|
58
|
+
lowercase: text_module.default["text-transform-lowercase"],
|
|
59
|
+
},
|
|
60
|
+
align: {
|
|
61
|
+
center: text_module.default["text-align-center"],
|
|
62
|
+
start: text_module.default["text-align-start"],
|
|
63
|
+
end: text_module.default["text-align-end"],
|
|
64
|
+
justify: text_module.default["text-align-justify"],
|
|
65
|
+
},
|
|
66
|
+
lineClamp: {
|
|
67
|
+
1: [text_module.default["text-line-clamp"], text_module.default["text-line-clamp-1"]],
|
|
68
|
+
2: [text_module.default["text-line-clamp"], text_module.default["text-line-clamp-2"]],
|
|
69
|
+
3: [text_module.default["text-line-clamp"], text_module.default["text-line-clamp-3"]],
|
|
70
|
+
4: [text_module.default["text-line-clamp"], text_module.default["text-line-clamp-4"]],
|
|
71
|
+
5: [text_module.default["text-line-clamp"], text_module.default["text-line-clamp-5"]],
|
|
72
|
+
},
|
|
73
|
+
underline: {
|
|
74
|
+
true: text_module.default["text-underline"],
|
|
75
|
+
},
|
|
76
|
+
strikeThrough: {
|
|
77
|
+
true: text_module.default["text-strike-through"],
|
|
78
|
+
},
|
|
79
|
+
italic: {
|
|
80
|
+
true: text_module.default["text-italic"],
|
|
81
|
+
},
|
|
46
82
|
},
|
|
47
83
|
defaultVariants: {
|
|
48
84
|
variant: "primary",
|
|
49
|
-
size:
|
|
50
|
-
weight:
|
|
85
|
+
size: "small",
|
|
86
|
+
weight: "regular",
|
|
51
87
|
},
|
|
88
|
+
compoundVariants: [
|
|
89
|
+
{
|
|
90
|
+
strikeThrough: true,
|
|
91
|
+
underline: true,
|
|
92
|
+
className: text_module.default["text-italic-strike-through"],
|
|
93
|
+
},
|
|
94
|
+
],
|
|
52
95
|
});
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
96
|
+
const Text = React.forwardRef(({ className, size, variant, weight, transform, align, lineClamp, underline, strikeThrough, italic, as: Component = "span", children, ...rest }, ref) => (jsxRuntime.jsxRuntimeExports.jsx(index.Root, { ref: ref, className: textVariants({
|
|
97
|
+
size,
|
|
98
|
+
className,
|
|
99
|
+
weight,
|
|
100
|
+
variant,
|
|
101
|
+
transform,
|
|
102
|
+
align,
|
|
103
|
+
lineClamp,
|
|
104
|
+
underline,
|
|
105
|
+
strikeThrough,
|
|
106
|
+
italic,
|
|
107
|
+
}), ...rest, children: jsxRuntime.jsxRuntimeExports.jsx(Component, { children: children }) })));
|
|
108
|
+
Text.displayName = "Text";
|
|
56
109
|
|
|
57
110
|
exports.Text = Text;
|
|
111
|
+
exports.textVariants = textVariants;
|
|
58
112
|
//# sourceMappingURL=text.cjs.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"text.cjs","sources":["../../../../v1/components/text/text.tsx"],"sourcesContent":["import { cva, VariantProps } from \"class-variance-authority\";\nimport {
|
|
1
|
+
{"version":3,"file":"text.cjs","sources":["../../../../v1/components/text/text.tsx"],"sourcesContent":["import { cva, type VariantProps } from \"class-variance-authority\";\nimport { ComponentPropsWithoutRef, forwardRef } from \"react\";\nimport * as Slot from \"@radix-ui/react-slot\";\nimport styles from \"./text.module.css\";\n\nexport const textVariants = cva(styles.text, {\n variants: {\n variant: {\n primary: styles[\"text-primary\"],\n secondary: styles[\"text-secondary\"],\n tertiary: styles[\"text-tertiary\"],\n emphasis: styles[\"text-emphasis\"],\n accent: styles[\"text-accent\"],\n attention: styles[\"text-attention\"],\n danger: styles[\"text-danger\"],\n success: styles[\"text-success\"],\n },\n size: {\n micro: styles[\"text-micro\"],\n mini: styles[\"text-mini\"],\n small: styles[\"text-small\"],\n regular: styles[\"text-regular\"],\n large: styles[\"text-large\"],\n 1: styles[\"text-1\"],\n 2: styles[\"text-2\"],\n 3: styles[\"text-3\"],\n 4: styles[\"text-4\"],\n 5: styles[\"text-5\"],\n 6: styles[\"text-6\"],\n 7: styles[\"text-7\"],\n 8: styles[\"text-8\"],\n 9: styles[\"text-9\"],\n 10: styles[\"text-10\"],\n },\n weight: {\n regular: styles[\"text-weight-regular\"],\n medium: styles[\"text-weight-medium\"],\n bold: styles[\"text-weight-bold\"],\n bolder: styles[\"text-weight-bolder\"],\n normal: styles[\"text-weight-normal\"],\n lighter: styles[\"text-weight-lighter\"],\n 100: styles[\"text-weight-100\"],\n 200: styles[\"text-weight-200\"],\n 300: styles[\"text-weight-300\"],\n 400: styles[\"text-weight-400\"],\n 500: styles[\"text-weight-500\"],\n 600: styles[\"text-weight-600\"],\n 700: styles[\"text-weight-700\"],\n 800: styles[\"text-weight-800\"],\n 900: styles[\"text-weight-900\"],\n },\n transform: {\n capitalize: styles[\"text-transform-capitalize\"],\n uppercase: styles[\"text-transform-uppercase\"],\n lowercase: styles[\"text-transform-lowercase\"],\n },\n align: {\n center: styles[\"text-align-center\"],\n start: styles[\"text-align-start\"],\n end: styles[\"text-align-end\"],\n justify: styles[\"text-align-justify\"],\n },\n lineClamp: {\n 1: [styles[\"text-line-clamp\"], styles[\"text-line-clamp-1\"]],\n 2: [styles[\"text-line-clamp\"], styles[\"text-line-clamp-2\"]],\n 3: [styles[\"text-line-clamp\"], styles[\"text-line-clamp-3\"]],\n 4: [styles[\"text-line-clamp\"], styles[\"text-line-clamp-4\"]],\n 5: [styles[\"text-line-clamp\"], styles[\"text-line-clamp-5\"]],\n },\n underline: {\n true: styles[\"text-underline\"],\n },\n strikeThrough: {\n true: styles[\"text-strike-through\"],\n },\n italic: {\n true: styles[\"text-italic\"],\n },\n },\n defaultVariants: {\n variant: \"primary\",\n size: \"small\",\n weight: \"regular\",\n },\n compoundVariants: [\n {\n strikeThrough: true,\n underline: true,\n className: styles[\"text-italic-strike-through\"],\n },\n ],\n});\n\nexport type TextBaseProps = VariantProps<typeof textVariants> & {\n /**\n * @remarks Use \"micro\" | \"mini\" | \"small\" | \"regular\" | \"large\"\n */\n size?:\n | 1\n | 2\n | 3\n | 4\n | 5\n | 6\n | 7\n | 8\n | 9\n | 10\n | \"micro\"\n | \"mini\"\n | \"small\"\n | \"regular\"\n | \"large\";\n /**\n * @remarks Use \"regular\" | \"medium\"\n */\n weight?:\n | \"regular\"\n | \"medium\"\n | \"bold\"\n | \"bolder\"\n | \"normal\"\n | \"lighter\"\n | 100\n | 200\n | 300\n | 400\n | 500\n | 600\n | 700\n | 800\n | 900;\n};\n\ntype TextSpanProps = { as?: \"span\" } & ComponentPropsWithoutRef<\"span\">;\ntype TextDivProps = { as: \"div\" } & ComponentPropsWithoutRef<\"div\">;\ntype TextLabelProps = { as: \"label\" } & ComponentPropsWithoutRef<\"label\">;\ntype TextPProps = { as: \"p\" } & ComponentPropsWithoutRef<\"p\">;\ntype TextAProps = { as: \"a\" } & ComponentPropsWithoutRef<\"a\">;\ntype TextProps = TextBaseProps &\n (TextSpanProps | TextDivProps | TextLabelProps | TextPProps | TextAProps);\ntype TextRef =\n | HTMLSpanElement\n | HTMLParagraphElement\n | HTMLDivElement\n | HTMLLabelElement\n | HTMLAnchorElement;\n\nexport const Text = forwardRef<TextRef, TextProps>(\n (\n {\n className,\n size,\n variant,\n weight,\n transform,\n align,\n lineClamp,\n underline,\n strikeThrough,\n italic,\n as: Component = \"span\",\n children,\n ...rest\n },\n ref,\n ) => (\n <Slot.Root\n ref={ref}\n className={textVariants({\n size,\n className,\n weight,\n variant,\n transform,\n align,\n lineClamp,\n underline,\n strikeThrough,\n italic,\n })}\n {...rest}>\n <Component>{children}</Component>\n </Slot.Root>\n ),\n);\n\nText.displayName = \"Text\";\n"],"names":["cva","styles","forwardRef","_jsx","Slot.Root"],"mappings":";;;;;;;;MAKa,YAAY,GAAGA,WAAG,CAACC,mBAAM,CAAC,IAAI,EAAE;AAC3C,IAAA,QAAQ,EAAE;AACR,QAAA,OAAO,EAAE;AACP,YAAA,OAAO,EAAEA,mBAAM,CAAC,cAAc,CAAC;AAC/B,YAAA,SAAS,EAAEA,mBAAM,CAAC,gBAAgB,CAAC;AACnC,YAAA,QAAQ,EAAEA,mBAAM,CAAC,eAAe,CAAC;AACjC,YAAA,QAAQ,EAAEA,mBAAM,CAAC,eAAe,CAAC;AACjC,YAAA,MAAM,EAAEA,mBAAM,CAAC,aAAa,CAAC;AAC7B,YAAA,SAAS,EAAEA,mBAAM,CAAC,gBAAgB,CAAC;AAC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QACT,aAAa;QACb,MAAM;KACP,CAAC,EAAA,GACE,IAAI,EAAA,QAAA,EACRD,gCAAC,CAAA,SAAS,EAAE,EAAA,QAAA,EAAA,QAAQ,EAAa,CAAA,EAAA,CACvB,CACb,EACD;AAEF,IAAI,CAAC,WAAW,GAAG,MAAM;;;;;"}
|
|
@@ -1,11 +1,43 @@
|
|
|
1
|
-
import { VariantProps } from "class-variance-authority";
|
|
2
|
-
import {
|
|
3
|
-
declare const
|
|
1
|
+
import { type VariantProps } from "class-variance-authority";
|
|
2
|
+
import { ComponentPropsWithoutRef } from "react";
|
|
3
|
+
export declare const textVariants: (props?: ({
|
|
4
4
|
variant?: "primary" | "secondary" | "tertiary" | "emphasis" | "accent" | "attention" | "danger" | "success" | null | undefined;
|
|
5
|
-
size?: 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | null | undefined;
|
|
6
|
-
weight?: "bold" | "bolder" | "normal" | "lighter" |
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
5
|
+
size?: "small" | "large" | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | "micro" | "mini" | "regular" | 10 | null | undefined;
|
|
6
|
+
weight?: "medium" | "bold" | "regular" | "bolder" | "normal" | "lighter" | 100 | 200 | 300 | 400 | 500 | 600 | 700 | 800 | 900 | null | undefined;
|
|
7
|
+
transform?: "capitalize" | "uppercase" | "lowercase" | null | undefined;
|
|
8
|
+
align?: "start" | "center" | "end" | "justify" | null | undefined;
|
|
9
|
+
lineClamp?: 1 | 2 | 3 | 4 | 5 | null | undefined;
|
|
10
|
+
underline?: boolean | null | undefined;
|
|
11
|
+
strikeThrough?: boolean | null | undefined;
|
|
12
|
+
italic?: boolean | null | undefined;
|
|
13
|
+
} & import("class-variance-authority/types").ClassProp) | undefined) => string;
|
|
14
|
+
export type TextBaseProps = VariantProps<typeof textVariants> & {
|
|
15
|
+
/**
|
|
16
|
+
* @remarks Use "micro" | "mini" | "small" | "regular" | "large"
|
|
17
|
+
*/
|
|
18
|
+
size?: 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | "micro" | "mini" | "small" | "regular" | "large";
|
|
19
|
+
/**
|
|
20
|
+
* @remarks Use "regular" | "medium"
|
|
21
|
+
*/
|
|
22
|
+
weight?: "regular" | "medium" | "bold" | "bolder" | "normal" | "lighter" | 100 | 200 | 300 | 400 | 500 | 600 | 700 | 800 | 900;
|
|
23
|
+
};
|
|
24
|
+
type TextSpanProps = {
|
|
25
|
+
as?: "span";
|
|
26
|
+
} & ComponentPropsWithoutRef<"span">;
|
|
27
|
+
type TextDivProps = {
|
|
28
|
+
as: "div";
|
|
29
|
+
} & ComponentPropsWithoutRef<"div">;
|
|
30
|
+
type TextLabelProps = {
|
|
31
|
+
as: "label";
|
|
32
|
+
} & ComponentPropsWithoutRef<"label">;
|
|
33
|
+
type TextPProps = {
|
|
34
|
+
as: "p";
|
|
35
|
+
} & ComponentPropsWithoutRef<"p">;
|
|
36
|
+
type TextAProps = {
|
|
37
|
+
as: "a";
|
|
38
|
+
} & ComponentPropsWithoutRef<"a">;
|
|
39
|
+
type TextProps = TextBaseProps & (TextSpanProps | TextDivProps | TextLabelProps | TextPProps | TextAProps);
|
|
40
|
+
type TextRef = HTMLSpanElement | HTMLParagraphElement | HTMLDivElement | HTMLLabelElement | HTMLAnchorElement;
|
|
41
|
+
export declare const Text: import("react").ForwardRefExoticComponent<TextProps & import("react").RefAttributes<TextRef>>;
|
|
10
42
|
export {};
|
|
11
43
|
//# sourceMappingURL=text.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"text.d.ts","sourceRoot":"","sources":["../../../../v1/components/text/text.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAO,YAAY,EAAE,MAAM,0BAA0B,CAAC;
|
|
1
|
+
{"version":3,"file":"text.d.ts","sourceRoot":"","sources":["../../../../v1/components/text/text.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAO,KAAK,YAA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AK,OAAO,GACR,eAAe,GACf,oBAAoB,GACpB,cAAc,GACd,gBAAgB,GAChB,iBAAiB,CAAC;AAEtB,eAAO,MAAM,IAAI,+FAqChB,CAAC"}
|
|
@@ -1,56 +1,109 @@
|
|
|
1
1
|
import { j as jsxRuntimeExports } from '../../node_modules/.pnpm/react@18.2.0/node_modules/react/jsx-runtime.js';
|
|
2
2
|
import { cva } from '../../node_modules/.pnpm/class-variance-authority@0.7.1/node_modules/class-variance-authority/dist/index.js';
|
|
3
|
-
import
|
|
3
|
+
import { forwardRef } from 'react';
|
|
4
|
+
import { Root as $5e63c961fc1ce211$export$be92b6f5f03c0fe9 } from '../../node_modules/.pnpm/@radix-ui_react-slot@1.0.2_@types_react@18.2.12_react@18.2.0/node_modules/@radix-ui/react-slot/dist/index.js';
|
|
5
|
+
import styles from './text.module.css.js';
|
|
4
6
|
|
|
5
|
-
const
|
|
7
|
+
const textVariants = cva(styles.text, {
|
|
6
8
|
variants: {
|
|
7
9
|
variant: {
|
|
8
|
-
primary:
|
|
9
|
-
secondary:
|
|
10
|
-
tertiary:
|
|
11
|
-
emphasis:
|
|
12
|
-
accent:
|
|
13
|
-
attention:
|
|
14
|
-
danger:
|
|
15
|
-
success:
|
|
10
|
+
primary: styles["text-primary"],
|
|
11
|
+
secondary: styles["text-secondary"],
|
|
12
|
+
tertiary: styles["text-tertiary"],
|
|
13
|
+
emphasis: styles["text-emphasis"],
|
|
14
|
+
accent: styles["text-accent"],
|
|
15
|
+
attention: styles["text-attention"],
|
|
16
|
+
danger: styles["text-danger"],
|
|
17
|
+
success: styles["text-success"],
|
|
16
18
|
},
|
|
17
19
|
size: {
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
20
|
+
micro: styles["text-micro"],
|
|
21
|
+
mini: styles["text-mini"],
|
|
22
|
+
small: styles["text-small"],
|
|
23
|
+
regular: styles["text-regular"],
|
|
24
|
+
large: styles["text-large"],
|
|
25
|
+
1: styles["text-1"],
|
|
26
|
+
2: styles["text-2"],
|
|
27
|
+
3: styles["text-3"],
|
|
28
|
+
4: styles["text-4"],
|
|
29
|
+
5: styles["text-5"],
|
|
30
|
+
6: styles["text-6"],
|
|
31
|
+
7: styles["text-7"],
|
|
32
|
+
8: styles["text-8"],
|
|
33
|
+
9: styles["text-9"],
|
|
34
|
+
10: styles["text-10"],
|
|
28
35
|
},
|
|
29
36
|
weight: {
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
37
|
+
regular: styles["text-weight-regular"],
|
|
38
|
+
medium: styles["text-weight-medium"],
|
|
39
|
+
bold: styles["text-weight-bold"],
|
|
40
|
+
bolder: styles["text-weight-bolder"],
|
|
41
|
+
normal: styles["text-weight-normal"],
|
|
42
|
+
lighter: styles["text-weight-lighter"],
|
|
43
|
+
100: styles["text-weight-100"],
|
|
44
|
+
200: styles["text-weight-200"],
|
|
45
|
+
300: styles["text-weight-300"],
|
|
46
|
+
400: styles["text-weight-400"],
|
|
47
|
+
500: styles["text-weight-500"],
|
|
48
|
+
600: styles["text-weight-600"],
|
|
49
|
+
700: styles["text-weight-700"],
|
|
50
|
+
800: styles["text-weight-800"],
|
|
51
|
+
900: styles["text-weight-900"],
|
|
52
|
+
},
|
|
53
|
+
transform: {
|
|
54
|
+
capitalize: styles["text-transform-capitalize"],
|
|
55
|
+
uppercase: styles["text-transform-uppercase"],
|
|
56
|
+
lowercase: styles["text-transform-lowercase"],
|
|
57
|
+
},
|
|
58
|
+
align: {
|
|
59
|
+
center: styles["text-align-center"],
|
|
60
|
+
start: styles["text-align-start"],
|
|
61
|
+
end: styles["text-align-end"],
|
|
62
|
+
justify: styles["text-align-justify"],
|
|
63
|
+
},
|
|
64
|
+
lineClamp: {
|
|
65
|
+
1: [styles["text-line-clamp"], styles["text-line-clamp-1"]],
|
|
66
|
+
2: [styles["text-line-clamp"], styles["text-line-clamp-2"]],
|
|
67
|
+
3: [styles["text-line-clamp"], styles["text-line-clamp-3"]],
|
|
68
|
+
4: [styles["text-line-clamp"], styles["text-line-clamp-4"]],
|
|
69
|
+
5: [styles["text-line-clamp"], styles["text-line-clamp-5"]],
|
|
70
|
+
},
|
|
71
|
+
underline: {
|
|
72
|
+
true: styles["text-underline"],
|
|
73
|
+
},
|
|
74
|
+
strikeThrough: {
|
|
75
|
+
true: styles["text-strike-through"],
|
|
76
|
+
},
|
|
77
|
+
italic: {
|
|
78
|
+
true: styles["text-italic"],
|
|
43
79
|
},
|
|
44
80
|
},
|
|
45
81
|
defaultVariants: {
|
|
46
82
|
variant: "primary",
|
|
47
|
-
size:
|
|
48
|
-
weight:
|
|
83
|
+
size: "small",
|
|
84
|
+
weight: "regular",
|
|
49
85
|
},
|
|
86
|
+
compoundVariants: [
|
|
87
|
+
{
|
|
88
|
+
strikeThrough: true,
|
|
89
|
+
underline: true,
|
|
90
|
+
className: styles["text-italic-strike-through"],
|
|
91
|
+
},
|
|
92
|
+
],
|
|
50
93
|
});
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
94
|
+
const Text = forwardRef(({ className, size, variant, weight, transform, align, lineClamp, underline, strikeThrough, italic, as: Component = "span", children, ...rest }, ref) => (jsxRuntimeExports.jsx($5e63c961fc1ce211$export$be92b6f5f03c0fe9, { ref: ref, className: textVariants({
|
|
95
|
+
size,
|
|
96
|
+
className,
|
|
97
|
+
weight,
|
|
98
|
+
variant,
|
|
99
|
+
transform,
|
|
100
|
+
align,
|
|
101
|
+
lineClamp,
|
|
102
|
+
underline,
|
|
103
|
+
strikeThrough,
|
|
104
|
+
italic,
|
|
105
|
+
}), ...rest, children: jsxRuntimeExports.jsx(Component, { children: children }) })));
|
|
106
|
+
Text.displayName = "Text";
|
|
54
107
|
|
|
55
|
-
export { Text };
|
|
108
|
+
export { Text, textVariants };
|
|
56
109
|
//# sourceMappingURL=text.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"text.js","sources":["../../../../v1/components/text/text.tsx"],"sourcesContent":["import { cva, VariantProps } from \"class-variance-authority\";\nimport {
|
|
1
|
+
{"version":3,"file":"text.js","sources":["../../../../v1/components/text/text.tsx"],"sourcesContent":["import { cva, type VariantProps } from \"class-variance-authority\";\nimport { ComponentPropsWithoutRef, forwardRef } from \"react\";\nimport * as Slot from \"@radix-ui/react-slot\";\nimport styles from \"./text.module.css\";\n\nexport const textVariants = cva(styles.text, {\n variants: {\n variant: {\n primary: styles[\"text-primary\"],\n secondary: styles[\"text-secondary\"],\n tertiary: styles[\"text-tertiary\"],\n emphasis: styles[\"text-emphasis\"],\n accent: styles[\"text-accent\"],\n attention: styles[\"text-attention\"],\n danger: styles[\"text-danger\"],\n success: styles[\"text-success\"],\n },\n size: {\n micro: styles[\"text-micro\"],\n mini: styles[\"text-mini\"],\n small: styles[\"text-small\"],\n regular: styles[\"text-regular\"],\n large: styles[\"text-large\"],\n 1: styles[\"text-1\"],\n 2: styles[\"text-2\"],\n 3: styles[\"text-3\"],\n 4: styles[\"text-4\"],\n 5: styles[\"text-5\"],\n 6: styles[\"text-6\"],\n 7: styles[\"text-7\"],\n 8: styles[\"text-8\"],\n 9: styles[\"text-9\"],\n 10: styles[\"text-10\"],\n },\n weight: {\n regular: styles[\"text-weight-regular\"],\n medium: styles[\"text-weight-medium\"],\n bold: styles[\"text-weight-bold\"],\n bolder: styles[\"text-weight-bolder\"],\n normal: styles[\"text-weight-normal\"],\n lighter: styles[\"text-weight-lighter\"],\n 100: styles[\"text-weight-100\"],\n 200: styles[\"text-weight-200\"],\n 300: styles[\"text-weight-300\"],\n 400: styles[\"text-weight-400\"],\n 500: styles[\"text-weight-500\"],\n 600: styles[\"text-weight-600\"],\n 700: styles[\"text-weight-700\"],\n 800: styles[\"text-weight-800\"],\n 900: styles[\"text-weight-900\"],\n },\n transform: {\n capitalize: styles[\"text-transform-capitalize\"],\n uppercase: styles[\"text-transform-uppercase\"],\n lowercase: styles[\"text-transform-lowercase\"],\n },\n align: {\n center: styles[\"text-align-center\"],\n start: styles[\"text-align-start\"],\n end: styles[\"text-align-end\"],\n justify: styles[\"text-align-justify\"],\n },\n lineClamp: {\n 1: [styles[\"text-line-clamp\"], styles[\"text-line-clamp-1\"]],\n 2: [styles[\"text-line-clamp\"], styles[\"text-line-clamp-2\"]],\n 3: [styles[\"text-line-clamp\"], styles[\"text-line-clamp-3\"]],\n 4: [styles[\"text-line-clamp\"], styles[\"text-line-clamp-4\"]],\n 5: [styles[\"text-line-clamp\"], styles[\"text-line-clamp-5\"]],\n },\n underline: {\n true: styles[\"text-underline\"],\n },\n strikeThrough: {\n true: styles[\"text-strike-through\"],\n },\n italic: {\n true: styles[\"text-italic\"],\n },\n },\n defaultVariants: {\n variant: \"primary\",\n size: \"small\",\n weight: \"regular\",\n },\n compoundVariants: [\n {\n strikeThrough: true,\n underline: true,\n className: styles[\"text-italic-strike-through\"],\n },\n ],\n});\n\nexport type TextBaseProps = VariantProps<typeof textVariants> & {\n /**\n * @remarks Use \"micro\" | \"mini\" | \"small\" | \"regular\" | \"large\"\n */\n size?:\n | 1\n | 2\n | 3\n | 4\n | 5\n | 6\n | 7\n | 8\n | 9\n | 10\n | \"micro\"\n | \"mini\"\n | \"small\"\n | \"regular\"\n | \"large\";\n /**\n * @remarks Use \"regular\" | \"medium\"\n */\n weight?:\n | \"regular\"\n | \"medium\"\n | \"bold\"\n | \"bolder\"\n | \"normal\"\n | \"lighter\"\n | 100\n | 200\n | 300\n | 400\n | 500\n | 600\n | 700\n | 800\n | 900;\n};\n\ntype TextSpanProps = { as?: \"span\" } & ComponentPropsWithoutRef<\"span\">;\ntype TextDivProps = { as: \"div\" } & ComponentPropsWithoutRef<\"div\">;\ntype TextLabelProps = { as: \"label\" } & ComponentPropsWithoutRef<\"label\">;\ntype TextPProps = { as: \"p\" } & ComponentPropsWithoutRef<\"p\">;\ntype TextAProps = { as: \"a\" } & ComponentPropsWithoutRef<\"a\">;\ntype TextProps = TextBaseProps &\n (TextSpanProps | TextDivProps | TextLabelProps | TextPProps | TextAProps);\ntype TextRef =\n | HTMLSpanElement\n | HTMLParagraphElement\n | HTMLDivElement\n | HTMLLabelElement\n | HTMLAnchorElement;\n\nexport const Text = forwardRef<TextRef, TextProps>(\n (\n {\n className,\n size,\n variant,\n weight,\n transform,\n align,\n lineClamp,\n underline,\n strikeThrough,\n italic,\n as: Component = \"span\",\n children,\n ...rest\n },\n ref,\n ) => (\n <Slot.Root\n ref={ref}\n className={textVariants({\n size,\n className,\n weight,\n variant,\n transform,\n align,\n lineClamp,\n underline,\n strikeThrough,\n italic,\n })}\n {...rest}>\n <Component>{children}</Component>\n </Slot.Root>\n ),\n);\n\nText.displayName = \"Text\";\n"],"names":["_jsx","Slot.Root"],"mappings":";;;;;;MAKa,YAAY,GAAG,GAAG,CAAC,MAAM,CAAC,IAAI,EAAE;AAC3C,IAAA,QAAQ,EAAE;AACR,QAAA,OAAO,EAAE;AACP,YAAA,OAAO,EAAE,MAAM,CAAC,cAAc,CAAC;AAC/B,YAAA,SAAS,EAAE,MAAM,CAAC,gBAAgB,CAAC;AACnC,YAAA,QAAQ,EAAE,MAAM,CAAC,eAAe,CAAC;AACjC,YAAA,QAAQ,EAAE,MAAM,CAAC,eAAe,CAAC;AACjC,YAAA,MAAM,EAAE,MAAM,CAAC,aAAa,CAAC;AAC7B,YAAA,SAAS,EAAE,MAAM,CAAC,gBAAgB,CAAC;AACnC,YAAA,MAAM,EAAE,MAAM,CAAC,aAAa,CAAC;AAC7B,YAAA,OAAO,EAAE,MAAM,CAAC,cAAc,CAAC;AAChC,SAAA;AACD,QAAA,IAAI,EAAE;AACJ,YAAA,KAAK,EAAE,MAAM,CAAC,YAAY,CAAC;AAC3B,YAAA,IAAI,EAAE,MAAM,CAAC,W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D,QAAA,aAAa,EAAE;AACb,YAAA,IAAI,EAAE,MAAM,CAAC,qBAAqB,CAAC;AACpC,SAAA;AACD,QAAA,MAAM,EAAE;AACN,YAAA,IAAI,EAAE,MAAM,CAAC,aAAa,CAAC;AAC5B,SAAA;AACF,KAAA;AACD,IAAA,eAAe,EAAE;AACf,QAAA,OAAO,EAAE,SAAS;AAClB,QAAA,IAAI,EAAE,OAAO;AACb,QAAA,MAAM,EAAE,SAAS;AAClB,KAAA;AACD,IAAA,gBAAgB,EAAE;AAChB,QAAA;AACE,YAAA,aAAa,EAAE,IAAI;AACnB,YAAA,SAAS,EAAE,IAAI;AACf,YAAA,SAAS,EAAE,MAAM,CAAC,4BAA4B,CAAC;AAChD,SAAA;AACF,KAAA;AACF,CAAA,EAAE;AAyDU,MAAA,IAAI,GAAG,UAAU,CAC5B,CACE,EACE,SAAS,EACT,IAAI,EACJ,OAAO,EACP,MAAM,EACN,SAAS,EACT,KAAK,EACL,SAAS,EACT,SAAS,EACT,aAAa,EACb,MAAM,EACN,EAAE,EAAE,SAAS,GAAG,MAAM,EACtB,QAAQ,EACR,GAAG,IAAI,EACR,EACD,GAAG,MAEHA,qBAAC,CAAAC,yCAAS,EACR,EAAA,GAAG,EAAE,GAAG,EACR,SAAS,EAAE,YAAY,CAAC;QACtB,IAAI;QACJ,SAAS;QACT,MAAM;QACN,OAAO;QACP,SAAS;QACT,KAAK;QACL,SAAS;QACT,SAAS;QACT,aAAa;QACb,MAAM;KACP,CAAC,EAAA,GACE,IAAI,EAAA,QAAA,EACRD,qBAAC,CAAA,SAAS,EAAE,EAAA,QAAA,EAAA,QAAQ,EAAa,CAAA,EAAA,CACvB,CACb,EACD;AAEF,IAAI,CAAC,WAAW,GAAG,MAAM;;;;"}
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
|
-
var
|
|
5
|
+
var styles = {"text":"text-module_text__tFuTL","text-micro":"text-module_text-micro__GSUAc","text-mini":"text-module_text-mini__fIuvK","text-small":"text-module_text-small__Q3nLf","text-regular":"text-module_text-regular__8a0m1","text-large":"text-module_text-large__IFXes","text-1":"text-module_text-1__-2-1Q","text-2":"text-module_text-2__5ZsOG","text-3":"text-module_text-3__U15pQ","text-4":"text-module_text-4__9N-7-","text-5":"text-module_text-5__e0fbX","text-6":"text-module_text-6__BUzVU","text-7":"text-module_text-7__No7hH","text-8":"text-module_text-8__yNdGp","text-9":"text-module_text-9__DSyEB","text-10":"text-module_text-10__k14Sp","text-weight-regular":"text-module_text-weight-regular__Bb12b","text-weight-medium":"text-module_text-weight-medium__TMOcw","text-weight-bold":"text-module_text-weight-bold__7ih3v","text-weight-bolder":"text-module_text-weight-bolder__mVFaj","text-weight-normal":"text-module_text-weight-normal__WnUcI","text-weight-lighter":"text-module_text-weight-lighter__5rGlI","text-weight-100":"text-module_text-weight-100__yQW-Y","text-weight-200":"text-module_text-weight-200__y7kFi","text-weight-300":"text-module_text-weight-300__dCeJe","text-weight-400":"text-module_text-weight-400__GRCMw","text-weight-500":"text-module_text-weight-500__1LhmO","text-weight-600":"text-module_text-weight-600__w51eJ","text-weight-700":"text-module_text-weight-700__oz9p8","text-weight-800":"text-module_text-weight-800__nnim6","text-weight-900":"text-module_text-weight-900__Ol4Lo","text-primary":"text-module_text-primary__3JNcv","text-secondary":"text-module_text-secondary__qhbTE","text-tertiary":"text-module_text-tertiary__-Bta6","text-emphasis":"text-module_text-emphasis__nmBMl","text-accent":"text-module_text-accent__oymau","text-attention":"text-module_text-attention__Ugy-6","text-danger":"text-module_text-danger__7pZHX","text-success":"text-module_text-success__aRO0z","text-transform-capitalize":"text-module_text-transform-capitalize__s3Df7","text-transform-uppercase":"text-module_text-transform-uppercase__Juinc","text-transform-lowercase":"text-module_text-transform-lowercase__T7WO4","text-align-center":"text-module_text-align-center__WKK-d","text-align-start":"text-module_text-align-start__TssZj","text-align-end":"text-module_text-align-end__nUYaq","text-align-justify":"text-module_text-align-justify__ma8h9","text-line-clamp":"text-module_text-line-clamp__ruTvG","text-line-clamp-1":"text-module_text-line-clamp-1__pwDt2","text-line-clamp-2":"text-module_text-line-clamp-2__Ldcfo","text-line-clamp-3":"text-module_text-line-clamp-3__lYBCv","text-line-clamp-4":"text-module_text-line-clamp-4__lwOTX","text-line-clamp-5":"text-module_text-line-clamp-5__Vz1i1","text-underline":"text-module_text-underline__akQaR","text-strike-through":"text-module_text-strike-through__94QfL","text-italic-strike-through":"text-module_text-italic-strike-through__5mMnz","text-italic":"text-module_text-italic__PDStX","text___micro":"text-module_text-micro__GSUAc","text___mini":"text-module_text-mini__fIuvK","text___small":"text-module_text-small__Q3nLf","text___regular":"text-module_text-regular__8a0m1","text___large":"text-module_text-large__IFXes","text___1":"text-module_text-1__-2-1Q","text___2":"text-module_text-2__5ZsOG","text___3":"text-module_text-3__U15pQ","text___4":"text-module_text-4__9N-7-","text___5":"text-module_text-5__e0fbX","text___6":"text-module_text-6__BUzVU","text___7":"text-module_text-7__No7hH","text___8":"text-module_text-8__yNdGp","text___9":"text-module_text-9__DSyEB","text___10":"text-module_text-10__k14Sp","text___weight___regular":"text-module_text-weight-regular__Bb12b","text___weight___medium":"text-module_text-weight-medium__TMOcw","text___weight___bold":"text-module_text-weight-bold__7ih3v","text___weight___bolder":"text-module_text-weight-bolder__mVFaj","text___weight___normal":"text-module_text-weight-normal__WnUcI","text___weight___lighter":"text-module_text-weight-lighter__5rGlI","text___weight___100":"text-module_text-weight-100__yQW-Y","text___weight___200":"text-module_text-weight-200__y7kFi","text___weight___300":"text-module_text-weight-300__dCeJe","text___weight___400":"text-module_text-weight-400__GRCMw","text___weight___500":"text-module_text-weight-500__1LhmO","text___weight___600":"text-module_text-weight-600__w51eJ","text___weight___700":"text-module_text-weight-700__oz9p8","text___weight___800":"text-module_text-weight-800__nnim6","text___weight___900":"text-module_text-weight-900__Ol4Lo","text___primary":"text-module_text-primary__3JNcv","text___secondary":"text-module_text-secondary__qhbTE","text___tertiary":"text-module_text-tertiary__-Bta6","text___emphasis":"text-module_text-emphasis__nmBMl","text___accent":"text-module_text-accent__oymau","text___attention":"text-module_text-attention__Ugy-6","text___danger":"text-module_text-danger__7pZHX","text___success":"text-module_text-success__aRO0z","text___transform___capitalize":"text-module_text-transform-capitalize__s3Df7","text___transform___uppercase":"text-module_text-transform-uppercase__Juinc","text___transform___lowercase":"text-module_text-transform-lowercase__T7WO4","text___align___center":"text-module_text-align-center__WKK-d","text___align___start":"text-module_text-align-start__TssZj","text___align___end":"text-module_text-align-end__nUYaq","text___align___justify":"text-module_text-align-justify__ma8h9","text___line___clamp":"text-module_text-line-clamp__ruTvG","text___line___clamp___1":"text-module_text-line-clamp-1__pwDt2","text___line___clamp___2":"text-module_text-line-clamp-2__Ldcfo","text___line___clamp___3":"text-module_text-line-clamp-3__lYBCv","text___line___clamp___4":"text-module_text-line-clamp-4__lwOTX","text___line___clamp___5":"text-module_text-line-clamp-5__Vz1i1","text___underline":"text-module_text-underline__akQaR","text___strike___through":"text-module_text-strike-through__94QfL","text___italic___strike___through":"text-module_text-italic-strike-through__5mMnz","text___italic":"text-module_text-italic__PDStX"};
|
|
6
6
|
|
|
7
|
-
exports.default =
|
|
7
|
+
exports.default = styles;
|
|
8
8
|
//# sourceMappingURL=text.module.css.cjs.map
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
var
|
|
1
|
+
var styles = {"text":"text-module_text__tFuTL","text-micro":"text-module_text-micro__GSUAc","text-mini":"text-module_text-mini__fIuvK","text-small":"text-module_text-small__Q3nLf","text-regular":"text-module_text-regular__8a0m1","text-large":"text-module_text-large__IFXes","text-1":"text-module_text-1__-2-1Q","text-2":"text-module_text-2__5ZsOG","text-3":"text-module_text-3__U15pQ","text-4":"text-module_text-4__9N-7-","text-5":"text-module_text-5__e0fbX","text-6":"text-module_text-6__BUzVU","text-7":"text-module_text-7__No7hH","text-8":"text-module_text-8__yNdGp","text-9":"text-module_text-9__DSyEB","text-10":"text-module_text-10__k14Sp","text-weight-regular":"text-module_text-weight-regular__Bb12b","text-weight-medium":"text-module_text-weight-medium__TMOcw","text-weight-bold":"text-module_text-weight-bold__7ih3v","text-weight-bolder":"text-module_text-weight-bolder__mVFaj","text-weight-normal":"text-module_text-weight-normal__WnUcI","text-weight-lighter":"text-module_text-weight-lighter__5rGlI","text-weight-100":"text-module_text-weight-100__yQW-Y","text-weight-200":"text-module_text-weight-200__y7kFi","text-weight-300":"text-module_text-weight-300__dCeJe","text-weight-400":"text-module_text-weight-400__GRCMw","text-weight-500":"text-module_text-weight-500__1LhmO","text-weight-600":"text-module_text-weight-600__w51eJ","text-weight-700":"text-module_text-weight-700__oz9p8","text-weight-800":"text-module_text-weight-800__nnim6","text-weight-900":"text-module_text-weight-900__Ol4Lo","text-primary":"text-module_text-primary__3JNcv","text-secondary":"text-module_text-secondary__qhbTE","text-tertiary":"text-module_text-tertiary__-Bta6","text-emphasis":"text-module_text-emphasis__nmBMl","text-accent":"text-module_text-accent__oymau","text-attention":"text-module_text-attention__Ugy-6","text-danger":"text-module_text-danger__7pZHX","text-success":"text-module_text-success__aRO0z","text-transform-capitalize":"text-module_text-transform-capitalize__s3Df7","text-transform-uppercase":"text-module_text-transform-uppercase__Juinc","text-transform-lowercase":"text-module_text-transform-lowercase__T7WO4","text-align-center":"text-module_text-align-center__WKK-d","text-align-start":"text-module_text-align-start__TssZj","text-align-end":"text-module_text-align-end__nUYaq","text-align-justify":"text-module_text-align-justify__ma8h9","text-line-clamp":"text-module_text-line-clamp__ruTvG","text-line-clamp-1":"text-module_text-line-clamp-1__pwDt2","text-line-clamp-2":"text-module_text-line-clamp-2__Ldcfo","text-line-clamp-3":"text-module_text-line-clamp-3__lYBCv","text-line-clamp-4":"text-module_text-line-clamp-4__lwOTX","text-line-clamp-5":"text-module_text-line-clamp-5__Vz1i1","text-underline":"text-module_text-underline__akQaR","text-strike-through":"text-module_text-strike-through__94QfL","text-italic-strike-through":"text-module_text-italic-strike-through__5mMnz","text-italic":"text-module_text-italic__PDStX","text___micro":"text-module_text-micro__GSUAc","text___mini":"text-module_text-mini__fIuvK","text___small":"text-module_text-small__Q3nLf","text___regular":"text-module_text-regular__8a0m1","text___large":"text-module_text-large__IFXes","text___1":"text-module_text-1__-2-1Q","text___2":"text-module_text-2__5ZsOG","text___3":"text-module_text-3__U15pQ","text___4":"text-module_text-4__9N-7-","text___5":"text-module_text-5__e0fbX","text___6":"text-module_text-6__BUzVU","text___7":"text-module_text-7__No7hH","text___8":"text-module_text-8__yNdGp","text___9":"text-module_text-9__DSyEB","text___10":"text-module_text-10__k14Sp","text___weight___regular":"text-module_text-weight-regular__Bb12b","text___weight___medium":"text-module_text-weight-medium__TMOcw","text___weight___bold":"text-module_text-weight-bold__7ih3v","text___weight___bolder":"text-module_text-weight-bolder__mVFaj","text___weight___normal":"text-module_text-weight-normal__WnUcI","text___weight___lighter":"text-module_text-weight-lighter__5rGlI","text___weight___100":"text-module_text-weight-100__yQW-Y","text___weight___200":"text-module_text-weight-200__y7kFi","text___weight___300":"text-module_text-weight-300__dCeJe","text___weight___400":"text-module_text-weight-400__GRCMw","text___weight___500":"text-module_text-weight-500__1LhmO","text___weight___600":"text-module_text-weight-600__w51eJ","text___weight___700":"text-module_text-weight-700__oz9p8","text___weight___800":"text-module_text-weight-800__nnim6","text___weight___900":"text-module_text-weight-900__Ol4Lo","text___primary":"text-module_text-primary__3JNcv","text___secondary":"text-module_text-secondary__qhbTE","text___tertiary":"text-module_text-tertiary__-Bta6","text___emphasis":"text-module_text-emphasis__nmBMl","text___accent":"text-module_text-accent__oymau","text___attention":"text-module_text-attention__Ugy-6","text___danger":"text-module_text-danger__7pZHX","text___success":"text-module_text-success__aRO0z","text___transform___capitalize":"text-module_text-transform-capitalize__s3Df7","text___transform___uppercase":"text-module_text-transform-uppercase__Juinc","text___transform___lowercase":"text-module_text-transform-lowercase__T7WO4","text___align___center":"text-module_text-align-center__WKK-d","text___align___start":"text-module_text-align-start__TssZj","text___align___end":"text-module_text-align-end__nUYaq","text___align___justify":"text-module_text-align-justify__ma8h9","text___line___clamp":"text-module_text-line-clamp__ruTvG","text___line___clamp___1":"text-module_text-line-clamp-1__pwDt2","text___line___clamp___2":"text-module_text-line-clamp-2__Ldcfo","text___line___clamp___3":"text-module_text-line-clamp-3__lYBCv","text___line___clamp___4":"text-module_text-line-clamp-4__lwOTX","text___line___clamp___5":"text-module_text-line-clamp-5__Vz1i1","text___underline":"text-module_text-underline__akQaR","text___strike___through":"text-module_text-strike-through__94QfL","text___italic___strike___through":"text-module_text-italic-strike-through__5mMnz","text___italic":"text-module_text-italic__PDStX"};
|
|
2
2
|
|
|
3
|
-
export {
|
|
3
|
+
export { styles as default };
|
|
4
4
|
//# sourceMappingURL=text.module.css.js.map
|
|
@@ -5,7 +5,7 @@ declare const textfield: (props?: ({
|
|
|
5
5
|
state?: "invalid" | "valid" | null | undefined;
|
|
6
6
|
hasLeadingElement?: boolean | null | undefined;
|
|
7
7
|
hasTrailingElement?: boolean | null | undefined;
|
|
8
|
-
} & import("class-variance-authority/
|
|
8
|
+
} & import("class-variance-authority/types").ClassProp) | undefined) => string;
|
|
9
9
|
export type TextfieldProps = Omit<InputHTMLAttributes<HTMLInputElement>, "size"> & PropsWithChildren<VariantProps<typeof textfield>> & {
|
|
10
10
|
leading?: React.ReactElement;
|
|
11
11
|
trailing?: React.ReactElement;
|
|
@@ -19,7 +19,7 @@ export declare const TextField: import("react").ForwardRefExoticComponent<Omit<I
|
|
|
19
19
|
state?: "invalid" | "valid" | null | undefined;
|
|
20
20
|
hasLeadingElement?: boolean | null | undefined;
|
|
21
21
|
hasTrailingElement?: boolean | null | undefined;
|
|
22
|
-
} & import("class-variance-authority/
|
|
22
|
+
} & import("class-variance-authority/types").ClassProp) | undefined) => string> & {
|
|
23
23
|
children?: import("react").ReactNode;
|
|
24
24
|
} & {
|
|
25
25
|
leading?: import("react").ReactElement<any, string | import("react").JSXElementConstructor<any>> | undefined;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"textfield.d.ts","sourceRoot":"","sources":["../../../../v1/components/textfield/textfield.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAW,YAAY,EAAE,MAAM,0BAA0B,CAAC;AACjE,OAAO,EAAc,mBAAmB,EAAE,iBAAiB,EAAE,MAAM,OAAO,CAAC;AAK3E,QAAA,MAAM,SAAS;;;;;
|
|
1
|
+
{"version":3,"file":"textfield.d.ts","sourceRoot":"","sources":["../../../../v1/components/textfield/textfield.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAW,YAAY,EAAE,MAAM,0BAA0B,CAAC;AACjE,OAAO,EAAc,mBAAmB,EAAE,iBAAiB,EAAE,MAAM,OAAO,CAAC;AAK3E,QAAA,MAAM,SAAS;;;;;8EAsBb,CAAC;AAEH,MAAM,MAAM,cAAc,GAAG,IAAI,CAC/B,mBAAmB,CAAC,gBAAgB,CAAC,EACrC,MAAM,CACP,GACC,iBAAiB,CAAC,YAAY,CAAC,OAAO,SAAS,CAAC,CAAC,GAAG;IAClD,OAAO,CAAC,EAAE,KAAK,CAAC,YAAY,CAAC;IAC7B,QAAQ,CAAC,EAAE,KAAK,CAAC,YAAY,CAAC;IAC9B,SAAS,CAAC,EAAE;QAAE,WAAW,CAAC,EAAE,MAAM,CAAC;QAAC,YAAY,CAAC,EAAE,MAAM,CAAA;KAAE,CAAC;CAC7D,CAAC;AAEJ,eAAO,MAAM,SAAS;;;;;;;;;;;;;;oDAsDrB,CAAC"}
|
|
@@ -3,7 +3,7 @@ import { VariantProps } from "class-variance-authority";
|
|
|
3
3
|
import React from "react";
|
|
4
4
|
declare const tooltip: (props?: ({
|
|
5
5
|
side?: "top" | "right" | "bottom" | "left" | "top-left" | "top-right" | "bottom-left" | "bottom-right" | null | undefined;
|
|
6
|
-
} & import("class-variance-authority/
|
|
6
|
+
} & import("class-variance-authority/types").ClassProp) | undefined) => string;
|
|
7
7
|
interface TooltipProps extends VariantProps<typeof tooltip> {
|
|
8
8
|
disabled?: boolean;
|
|
9
9
|
children: React.ReactNode;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"tooltip.d.ts","sourceRoot":"","sources":["../../../../v1/components/tooltip/tooltip.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,gBAAgB,MAAM,yBAAyB,CAAC;AAC5D,OAAO,EAAO,YAAY,EAAE,MAAM,0BAA0B,CAAC;AAE7D,OAAO,KAAK,MAAM,OAAO,CAAC;AAK1B,QAAA,MAAM,OAAO;;
|
|
1
|
+
{"version":3,"file":"tooltip.d.ts","sourceRoot":"","sources":["../../../../v1/components/tooltip/tooltip.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,gBAAgB,MAAM,yBAAyB,CAAC;AAC5D,OAAO,EAAO,YAAY,EAAE,MAAM,0BAA0B,CAAC;AAE7D,OAAO,KAAK,MAAM,OAAO,CAAC;AAK1B,QAAA,MAAM,OAAO;;8EAgBX,CAAC;AAEH,UAAU,YAAa,SAAQ,YAAY,CAAC,OAAO,OAAO,CAAC;IACzD,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,QAAQ,EAAE,KAAK,CAAC,SAAS,CAAC;IAC1B,OAAO,EAAE,KAAK,CAAC,SAAS,CAAC;IACzB,UAAU,CAAC,EAAE;QACX,OAAO,CAAC,EAAE,MAAM,CAAC;QACjB,OAAO,CAAC,EAAE,MAAM,CAAC;QACjB,KAAK,CAAC,EAAE,MAAM,CAAC;KAChB,CAAC;IACF,YAAY,CAAC,EAAE,KAAK,CAAC,aAAa,CAAC;IACnC,YAAY,CAAC,EAAE,KAAK,CAAC,aAAa,CAAC;IACnC,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB,iBAAiB,CAAC,EAAE,MAAM,CAAC;IAC3B,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB,SAAS,CAAC,EAAE,OAAO,CAAC;CACrB;AAED,eAAO,MAAM,OAAO,EAAE,KAAK,CAAC,EAAE,CAAC,YAAY,CAuD1C,CAAC;AAIF,eAAO,MAAM,eAAe,iDAA4B,CAAC"}
|
|
@@ -79,7 +79,9 @@ function $5e63c961fc1ce211$var$mergeProps(slotProps, childProps) {
|
|
|
79
79
|
...overrideProps
|
|
80
80
|
};
|
|
81
81
|
}
|
|
82
|
+
const $5e63c961fc1ce211$export$be92b6f5f03c0fe9 = $5e63c961fc1ce211$export$8c6ed5c666ac1360;
|
|
82
83
|
|
|
84
|
+
exports.Root = $5e63c961fc1ce211$export$be92b6f5f03c0fe9;
|
|
83
85
|
exports.Slot = $5e63c961fc1ce211$export$8c6ed5c666ac1360;
|
|
84
86
|
exports.Slottable = $5e63c961fc1ce211$export$d9f1ccf0bdb05d45;
|
|
85
87
|
//# sourceMappingURL=index.cjs.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.cjs","sources":["../../../../../../../../../../../node_modules/.pnpm/@radix-ui+react-slot@1.0.2_@types+react@18.2.12_react@18.2.0/node_modules/@radix-ui/react-slot/dist/index.mjs"],"sourcesContent":["import $9IrjX$babelruntimehelpersesmextends from \"@babel/runtime/helpers/esm/extends\";\nimport {forwardRef as $9IrjX$forwardRef, Children as $9IrjX$Children, isValidElement as $9IrjX$isValidElement, createElement as $9IrjX$createElement, cloneElement as $9IrjX$cloneElement, Fragment as $9IrjX$Fragment} from \"react\";\nimport {composeRefs as $9IrjX$composeRefs} from \"@radix-ui/react-compose-refs\";\n\n\n\n\n/* -------------------------------------------------------------------------------------------------\n * Slot\n * -----------------------------------------------------------------------------------------------*/ const $5e63c961fc1ce211$export$8c6ed5c666ac1360 = /*#__PURE__*/ $9IrjX$forwardRef((props, forwardedRef)=>{\n const { children: children , ...slotProps } = props;\n const childrenArray = $9IrjX$Children.toArray(children);\n const slottable = childrenArray.find($5e63c961fc1ce211$var$isSlottable);\n if (slottable) {\n // the new element to render is the one passed as a child of `Slottable`\n const newElement = slottable.props.children;\n const newChildren = childrenArray.map((child)=>{\n if (child === slottable) {\n // because the new element will be the one rendered, we are only interested\n // in grabbing its children (`newElement.props.children`)\n if ($9IrjX$Children.count(newElement) > 1) return $9IrjX$Children.only(null);\n return /*#__PURE__*/ $9IrjX$isValidElement(newElement) ? newElement.props.children : null;\n } else return child;\n });\n return /*#__PURE__*/ $9IrjX$createElement($5e63c961fc1ce211$var$SlotClone, $9IrjX$babelruntimehelpersesmextends({}, slotProps, {\n ref: forwardedRef\n }), /*#__PURE__*/ $9IrjX$isValidElement(newElement) ? /*#__PURE__*/ $9IrjX$cloneElement(newElement, undefined, newChildren) : null);\n }\n return /*#__PURE__*/ $9IrjX$createElement($5e63c961fc1ce211$var$SlotClone, $9IrjX$babelruntimehelpersesmextends({}, slotProps, {\n ref: forwardedRef\n }), children);\n});\n$5e63c961fc1ce211$export$8c6ed5c666ac1360.displayName = 'Slot';\n/* -------------------------------------------------------------------------------------------------\n * SlotClone\n * -----------------------------------------------------------------------------------------------*/ const $5e63c961fc1ce211$var$SlotClone = /*#__PURE__*/ $9IrjX$forwardRef((props, forwardedRef)=>{\n const { children: children , ...slotProps } = props;\n if (/*#__PURE__*/ $9IrjX$isValidElement(children)) return /*#__PURE__*/ $9IrjX$cloneElement(children, {\n ...$5e63c961fc1ce211$var$mergeProps(slotProps, children.props),\n ref: forwardedRef ? $9IrjX$composeRefs(forwardedRef, children.ref) : children.ref\n });\n return $9IrjX$Children.count(children) > 1 ? $9IrjX$Children.only(null) : null;\n});\n$5e63c961fc1ce211$var$SlotClone.displayName = 'SlotClone';\n/* -------------------------------------------------------------------------------------------------\n * Slottable\n * -----------------------------------------------------------------------------------------------*/ const $5e63c961fc1ce211$export$d9f1ccf0bdb05d45 = ({ children: children })=>{\n return /*#__PURE__*/ $9IrjX$createElement($9IrjX$Fragment, null, children);\n};\n/* ---------------------------------------------------------------------------------------------- */ function $5e63c961fc1ce211$var$isSlottable(child) {\n return /*#__PURE__*/ $9IrjX$isValidElement(child) && child.type === $5e63c961fc1ce211$export$d9f1ccf0bdb05d45;\n}\nfunction $5e63c961fc1ce211$var$mergeProps(slotProps, childProps) {\n // all child props should override\n const overrideProps = {\n ...childProps\n };\n for(const propName in childProps){\n const slotPropValue = slotProps[propName];\n const childPropValue = childProps[propName];\n const isHandler = /^on[A-Z]/.test(propName);\n if (isHandler) {\n // if the handler exists on both, we compose them\n if (slotPropValue && childPropValue) overrideProps[propName] = (...args)=>{\n childPropValue(...args);\n slotPropValue(...args);\n };\n else if (slotPropValue) overrideProps[propName] = slotPropValue;\n } else if (propName === 'style') overrideProps[propName] = {\n ...slotPropValue,\n ...childPropValue\n };\n else if (propName === 'className') overrideProps[propName] = [\n slotPropValue,\n childPropValue\n ].filter(Boolean).join(' ');\n }\n return {\n ...slotProps,\n ...overrideProps\n };\n}\nconst $5e63c961fc1ce211$export$be92b6f5f03c0fe9 = $5e63c961fc1ce211$export$8c6ed5c666ac1360;\n\n\n\n\nexport {$5e63c961fc1ce211$export$8c6ed5c666ac1360 as Slot, $5e63c961fc1ce211$export$d9f1ccf0bdb05d45 as Slottable, $5e63c961fc1ce211$export$be92b6f5f03c0fe9 as Root};\n//# sourceMappingURL=index.mjs.map\n"],"names":["$9IrjX$forwardRef","$9IrjX$Children","$9IrjX$isValidElement","$9IrjX$createElement","$9IrjX$babelruntimehelpersesmextends","$9IrjX$cloneElement","$9IrjX$composeRefs","$9IrjX$Fragment"],"mappings":";;;;;;AAOA;AACA;AACA,qGAA0G,MAAC,yCAAyC,iBAAiBA,gBAAiB,CAAC,CAAC,KAAK,EAAE,YAAY,GAAG;AAC9M,IAAI,MAAM,EAAE,QAAQ,EAAE,QAAQ,GAAG,GAAG,SAAS,EAAE,GAAG,KAAK,CAAC;AACxD,IAAI,MAAM,aAAa,GAAGC,cAAe,CAAC,OAAO,CAAC,QAAQ,CAAC,CAAC;AAC5D,IAAI,MAAM,SAAS,GAAG,aAAa,CAAC,IAAI,CAAC,iCAAiC,CAAC,CAAC;AAC5E,IAAI,IAAI,SAAS,EAAE;AACnB;AACA,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AAQ,CAAC,GAAG,CAAC,GAAG,IAAI,GAAG;AACtF,gBAAgB,cAAc,CAAC,GAAG,IAAI,CAAC,CAAC;AACxC,gBAAgB,aAAa,CAAC,GAAG,IAAI,CAAC,CAAC;AACvC,aAAa,CAAC;AACd,iBAAiB,IAAI,aAAa,EAAE,aAAa,CAAC,QAAQ,CAAC,GAAG,aAAa,CAAC;AAC5E,SAAS,MAAM,IAAI,QAAQ,KAAK,OAAO,EAAE,aAAa,CAAC,QAAQ,CAAC,GAAG;AACnE,YAAY,GAAG,aAAa;AAC5B,YAAY,GAAG,cAAc;AAC7B,SAAS,CAAC;AACV,aAAa,IAAI,QAAQ,KAAK,WAAW,EAAE,aAAa,CAAC,QAAQ,CAAC,GAAG;AACrE,YAAY,aAAa;AACzB,YAAY,cAAc;AAC1B,SAAS,CAAC,MAAM,CAAC,OAAO,CAAC,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC;AACpC,KAAK;AACL,IAAI,OAAO;AACX,QAAQ,GAAG,SAAS;AACpB,QAAQ,GAAG,aAAa;AACxB,KAAK,CAAC;AACN
|
|
1
|
+
{"version":3,"file":"index.cjs","sources":["../../../../../../../../../../../node_modules/.pnpm/@radix-ui+react-slot@1.0.2_@types+react@18.2.12_react@18.2.0/node_modules/@radix-ui/react-slot/dist/index.mjs"],"sourcesContent":["import $9IrjX$babelruntimehelpersesmextends from \"@babel/runtime/helpers/esm/extends\";\nimport {forwardRef as $9IrjX$forwardRef, Children as $9IrjX$Children, isValidElement as $9IrjX$isValidElement, createElement as $9IrjX$createElement, cloneElement as $9IrjX$cloneElement, Fragment as $9IrjX$Fragment} from \"react\";\nimport {composeRefs as $9IrjX$composeRefs} from \"@radix-ui/react-compose-refs\";\n\n\n\n\n/* -------------------------------------------------------------------------------------------------\n * Slot\n * -----------------------------------------------------------------------------------------------*/ const $5e63c961fc1ce211$export$8c6ed5c666ac1360 = /*#__PURE__*/ $9IrjX$forwardRef((props, forwardedRef)=>{\n const { children: children , ...slotProps } = props;\n const childrenArray = $9IrjX$Children.toArray(children);\n const slottable = childrenArray.find($5e63c961fc1ce211$var$isSlottable);\n if (slottable) {\n // the new element to render is the one passed as a child of `Slottable`\n const newElement = slottable.props.children;\n const newChildren = childrenArray.map((child)=>{\n if (child === slottable) {\n // because the new element will be the one rendered, we are only interested\n // in grabbing its children (`newElement.props.children`)\n if ($9IrjX$Children.count(newElement) > 1) return $9IrjX$Children.only(null);\n return /*#__PURE__*/ $9IrjX$isValidElement(newElement) ? newElement.props.children : null;\n } else return child;\n });\n return /*#__PURE__*/ $9IrjX$createElement($5e63c961fc1ce211$var$SlotClone, $9IrjX$babelruntimehelpersesmextends({}, slotProps, {\n ref: forwardedRef\n }), /*#__PURE__*/ $9IrjX$isValidElement(newElement) ? /*#__PURE__*/ $9IrjX$cloneElement(newElement, undefined, newChildren) : null);\n }\n return /*#__PURE__*/ $9IrjX$createElement($5e63c961fc1ce211$var$SlotClone, $9IrjX$babelruntimehelpersesmextends({}, slotProps, {\n ref: forwardedRef\n }), children);\n});\n$5e63c961fc1ce211$export$8c6ed5c666ac1360.displayName = 'Slot';\n/* -------------------------------------------------------------------------------------------------\n * SlotClone\n * -----------------------------------------------------------------------------------------------*/ const $5e63c961fc1ce211$var$SlotClone = /*#__PURE__*/ $9IrjX$forwardRef((props, forwardedRef)=>{\n const { children: children , ...slotProps } = props;\n if (/*#__PURE__*/ $9IrjX$isValidElement(children)) return /*#__PURE__*/ $9IrjX$cloneElement(children, {\n ...$5e63c961fc1ce211$var$mergeProps(slotProps, children.props),\n ref: forwardedRef ? $9IrjX$composeRefs(forwardedRef, children.ref) : children.ref\n });\n return $9IrjX$Children.count(children) > 1 ? $9IrjX$Children.only(null) : null;\n});\n$5e63c961fc1ce211$var$SlotClone.displayName = 'SlotClone';\n/* -------------------------------------------------------------------------------------------------\n * Slottable\n * -----------------------------------------------------------------------------------------------*/ const $5e63c961fc1ce211$export$d9f1ccf0bdb05d45 = ({ children: children })=>{\n return /*#__PURE__*/ $9IrjX$createElement($9IrjX$Fragment, null, children);\n};\n/* ---------------------------------------------------------------------------------------------- */ function $5e63c961fc1ce211$var$isSlottable(child) {\n return /*#__PURE__*/ $9IrjX$isValidElement(child) && child.type === $5e63c961fc1ce211$export$d9f1ccf0bdb05d45;\n}\nfunction $5e63c961fc1ce211$var$mergeProps(slotProps, childProps) {\n // all child props should override\n const overrideProps = {\n ...childProps\n };\n for(const propName in childProps){\n const slotPropValue = slotProps[propName];\n const childPropValue = childProps[propName];\n const isHandler = /^on[A-Z]/.test(propName);\n if (isHandler) {\n // if the handler exists on both, we compose them\n if (slotPropValue && childPropValue) overrideProps[propName] = (...args)=>{\n childPropValue(...args);\n slotPropValue(...args);\n };\n else if (slotPropValue) overrideProps[propName] = slotPropValue;\n } else if (propName === 'style') overrideProps[propName] = {\n ...slotPropValue,\n ...childPropValue\n };\n else if (propName === 'className') overrideProps[propName] = [\n slotPropValue,\n childPropValue\n ].filter(Boolean).join(' ');\n }\n return {\n ...slotProps,\n ...overrideProps\n };\n}\nconst $5e63c961fc1ce211$export$be92b6f5f03c0fe9 = $5e63c961fc1ce211$export$8c6ed5c666ac1360;\n\n\n\n\nexport {$5e63c961fc1ce211$export$8c6ed5c666ac1360 as Slot, $5e63c961fc1ce211$export$d9f1ccf0bdb05d45 as Slottable, $5e63c961fc1ce211$export$be92b6f5f03c0fe9 as Root};\n//# sourceMappingURL=index.mjs.map\n"],"names":["$9IrjX$forwardRef","$9IrjX$Children","$9IrjX$isValidElement","$9IrjX$createElement","$9IrjX$babelruntimehelpersesmextends","$9IrjX$cloneElement","$9IrjX$composeRefs","$9IrjX$Fragment"],"mappings":";;;;;;AAOA;AACA;AACA,qGAA0G,MAAC,yCAAyC,iBAAiBA,gBAAiB,CAAC,CAAC,KAAK,EAAE,YAAY,GAAG;AAC9M,IAAI,MAAM,EAAE,QAAQ,EAAE,QAAQ,GAAG,GAAG,SAAS,EAAE,GAAG,KAAK,CAAC;AACxD,IAAI,MAAM,aAAa,GAA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ACpD,QAAQ,MAAM,SAAS,GAAG,UAAU,CAAC,IAAI,CAAC,QAAQ,CAAC,CAAC;AACpD,QAAQ,IAAI,SAAS,EAAE;AACvB;AACA,YAAY,IAAI,aAAa,IAAI,cAAc,EAAE,aAAa,CAAC,QAAQ,CAAC,GAAG,CAAC,GAAG,IAAI,GAAG;AACtF,gBAAgB,cAAc,CAAC,GAAG,IAAI,CAAC,CAAC;AACxC,gBAAgB,aAAa,CAAC,GAAG,IAAI,CAAC,CAAC;AACvC,aAAa,CAAC;AACd,iBAAiB,IAAI,aAAa,EAAE,aAAa,CAAC,QAAQ,CAAC,GAAG,aAAa,CAAC;AAC5E,SAAS,MAAM,IAAI,QAAQ,KAAK,OAAO,EAAE,aAAa,CAAC,QAAQ,CAAC,GAAG;AACnE,YAAY,GAAG,aAAa;AAC5B,YAAY,GAAG,cAAc;AAC7B,SAAS,CAAC;AACV,aAAa,IAAI,QAAQ,KAAK,WAAW,EAAE,aAAa,CAAC,QAAQ,CAAC,GAAG;AACrE,YAAY,aAAa;AACzB,YAAY,cAAc;AAC1B,SAAS,CAAC,MAAM,CAAC,OAAO,CAAC,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC;AACpC,KAAK;AACL,IAAI,OAAO;AACX,QAAQ,GAAG,SAAS;AACpB,QAAQ,GAAG,aAAa;AACxB,KAAK,CAAC;AACN,CAAC;AACI,MAAC,yCAAyC,GAAG;;;;;;","x_google_ignoreList":[0]}
|
|
@@ -77,6 +77,7 @@ function $5e63c961fc1ce211$var$mergeProps(slotProps, childProps) {
|
|
|
77
77
|
...overrideProps
|
|
78
78
|
};
|
|
79
79
|
}
|
|
80
|
+
const $5e63c961fc1ce211$export$be92b6f5f03c0fe9 = $5e63c961fc1ce211$export$8c6ed5c666ac1360;
|
|
80
81
|
|
|
81
|
-
export { $5e63c961fc1ce211$export$8c6ed5c666ac1360 as Slot, $5e63c961fc1ce211$export$d9f1ccf0bdb05d45 as Slottable };
|
|
82
|
+
export { $5e63c961fc1ce211$export$be92b6f5f03c0fe9 as Root, $5e63c961fc1ce211$export$8c6ed5c666ac1360 as Slot, $5e63c961fc1ce211$export$d9f1ccf0bdb05d45 as Slottable };
|
|
82
83
|
//# sourceMappingURL=index.js.map
|