@lunar-js/lunar 0.0.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.
Files changed (162) hide show
  1. package/CHANGELOG.md +12 -0
  2. package/LICENSE +21 -0
  3. package/README.md +41 -0
  4. package/dist/components/composite/Card/Card.d.ts +64 -0
  5. package/dist/components/composite/Card/Card.d.ts.map +1 -0
  6. package/dist/components/composite/Card/Card.js +86 -0
  7. package/dist/components/composite/Card/Card.js.map +1 -0
  8. package/dist/components/composite/Card/card.css.js +62 -0
  9. package/dist/components/composite/Card/card.css.js.map +1 -0
  10. package/dist/components/composite/Dialog/Dialog.d.ts +45 -0
  11. package/dist/components/composite/Dialog/Dialog.d.ts.map +1 -0
  12. package/dist/components/composite/Dialog/Dialog.js +117 -0
  13. package/dist/components/composite/Dialog/Dialog.js.map +1 -0
  14. package/dist/components/composite/Dialog/DialogProvider.d.ts +11 -0
  15. package/dist/components/composite/Dialog/DialogProvider.d.ts.map +1 -0
  16. package/dist/components/composite/Dialog/DialogProvider.js +19 -0
  17. package/dist/components/composite/Dialog/DialogProvider.js.map +1 -0
  18. package/dist/components/composite/Dialog/dialog.css.js +104 -0
  19. package/dist/components/composite/Dialog/dialog.css.js.map +1 -0
  20. package/dist/components/primitives/Button/Button.d.ts +27 -0
  21. package/dist/components/primitives/Button/Button.d.ts.map +1 -0
  22. package/dist/components/primitives/Button/Button.js +25 -0
  23. package/dist/components/primitives/Button/Button.js.map +1 -0
  24. package/dist/components/primitives/Button/button.css.d.ts +16 -0
  25. package/dist/components/primitives/Button/button.css.d.ts.map +1 -0
  26. package/dist/components/primitives/Button/button.css.js +202 -0
  27. package/dist/components/primitives/Button/button.css.js.map +1 -0
  28. package/dist/components/primitives/Button/button.types.d.ts +8 -0
  29. package/dist/components/primitives/Button/button.types.d.ts.map +1 -0
  30. package/dist/components/primitives/Input/Input.d.ts +12 -0
  31. package/dist/components/primitives/Input/Input.d.ts.map +1 -0
  32. package/dist/components/primitives/Input/Input.js +21 -0
  33. package/dist/components/primitives/Input/Input.js.map +1 -0
  34. package/dist/components/primitives/Input/input.css.js +54 -0
  35. package/dist/components/primitives/Input/input.css.js.map +1 -0
  36. package/dist/components/primitives/Label/Label.d.ts +13 -0
  37. package/dist/components/primitives/Label/Label.d.ts.map +1 -0
  38. package/dist/components/primitives/Label/Label.js +22 -0
  39. package/dist/components/primitives/Label/Label.js.map +1 -0
  40. package/dist/components/primitives/Label/label.css.js +35 -0
  41. package/dist/components/primitives/Label/label.css.js.map +1 -0
  42. package/dist/components/primitives/Typography/Text.d.ts +40 -0
  43. package/dist/components/primitives/Typography/Text.d.ts.map +1 -0
  44. package/dist/components/primitives/Typography/Text.js +28 -0
  45. package/dist/components/primitives/Typography/Text.js.map +1 -0
  46. package/dist/components/primitives/Typography/text.css.d.ts +31 -0
  47. package/dist/components/primitives/Typography/text.css.d.ts.map +1 -0
  48. package/dist/components/primitives/Typography/text.css.js +1019 -0
  49. package/dist/components/primitives/Typography/text.css.js.map +1 -0
  50. package/dist/components/primitives/Typography/text.types.d.ts +10 -0
  51. package/dist/components/primitives/Typography/text.types.d.ts.map +1 -0
  52. package/dist/constants/theming.d.ts +10 -0
  53. package/dist/constants/theming.d.ts.map +1 -0
  54. package/dist/constants/theming.js +11 -0
  55. package/dist/constants/theming.js.map +1 -0
  56. package/dist/hooks/dialog.d.ts +7 -0
  57. package/dist/hooks/dialog.d.ts.map +1 -0
  58. package/dist/hooks/dialog.js +14 -0
  59. package/dist/hooks/dialog.js.map +1 -0
  60. package/dist/hooks/refs.js +23 -0
  61. package/dist/hooks/refs.js.map +1 -0
  62. package/dist/hooks/theme.d.ts +7 -0
  63. package/dist/hooks/theme.d.ts.map +1 -0
  64. package/dist/hooks/theme.js +14 -0
  65. package/dist/hooks/theme.js.map +1 -0
  66. package/dist/hooks/utils.js +6 -0
  67. package/dist/hooks/utils.js.map +1 -0
  68. package/dist/index.d.ts +20 -0
  69. package/dist/index.js +20 -0
  70. package/dist/styles.css.d.ts +4 -0
  71. package/dist/styles.css.js +5 -0
  72. package/dist/themes/ThemeProvider/ThemeProvider.d.ts +19 -0
  73. package/dist/themes/ThemeProvider/ThemeProvider.d.ts.map +1 -0
  74. package/dist/themes/ThemeProvider/ThemeProvider.js +25 -0
  75. package/dist/themes/ThemeProvider/ThemeProvider.js.map +1 -0
  76. package/dist/themes/regal.css.d.ts +5 -0
  77. package/dist/themes/regal.css.d.ts.map +1 -0
  78. package/dist/themes/regal.css.js +720 -0
  79. package/dist/themes/regal.css.js.map +1 -0
  80. package/dist/themes/styles/color-scheme.css.d.ts +6 -0
  81. package/dist/themes/styles/color-scheme.css.d.ts.map +1 -0
  82. package/dist/themes/styles/color-scheme.css.js +9 -0
  83. package/dist/themes/styles/color-scheme.css.js.map +1 -0
  84. package/dist/themes/styles/utilities.d.ts +125 -0
  85. package/dist/themes/styles/utilities.d.ts.map +1 -0
  86. package/dist/themes/styles/utilities.js +129 -0
  87. package/dist/themes/styles/utilities.js.map +1 -0
  88. package/dist/themes/tokens/primitives/borders.d.ts +22 -0
  89. package/dist/themes/tokens/primitives/borders.d.ts.map +1 -0
  90. package/dist/themes/tokens/primitives/borders.js +23 -0
  91. package/dist/themes/tokens/primitives/borders.js.map +1 -0
  92. package/dist/themes/tokens/primitives/colors.d.ts +100 -0
  93. package/dist/themes/tokens/primitives/colors.d.ts.map +1 -0
  94. package/dist/themes/tokens/primitives/colors.js +101 -0
  95. package/dist/themes/tokens/primitives/colors.js.map +1 -0
  96. package/dist/themes/tokens/primitives/shadows.d.ts +14 -0
  97. package/dist/themes/tokens/primitives/shadows.d.ts.map +1 -0
  98. package/dist/themes/tokens/primitives/shadows.js +15 -0
  99. package/dist/themes/tokens/primitives/shadows.js.map +1 -0
  100. package/dist/themes/tokens/primitives/spacing.d.ts +41 -0
  101. package/dist/themes/tokens/primitives/spacing.d.ts.map +1 -0
  102. package/dist/themes/tokens/primitives/spacing.js +42 -0
  103. package/dist/themes/tokens/primitives/spacing.js.map +1 -0
  104. package/dist/themes/tokens/primitives/typography.d.ts +105 -0
  105. package/dist/themes/tokens/primitives/typography.d.ts.map +1 -0
  106. package/dist/themes/tokens/primitives/typography.js +106 -0
  107. package/dist/themes/tokens/primitives/typography.js.map +1 -0
  108. package/dist/themes/tokens/semantic/borders.js +23 -0
  109. package/dist/themes/tokens/semantic/borders.js.map +1 -0
  110. package/dist/themes/tokens/semantic/colors.js +145 -0
  111. package/dist/themes/tokens/semantic/colors.js.map +1 -0
  112. package/dist/themes/tokens/semantic/shadows.js +15 -0
  113. package/dist/themes/tokens/semantic/shadows.js.map +1 -0
  114. package/dist/themes/tokens/semantic/spacing.js +70 -0
  115. package/dist/themes/tokens/semantic/spacing.js.map +1 -0
  116. package/dist/themes/tokens/semantic/typography.js +34 -0
  117. package/dist/themes/tokens/semantic/typography.js.map +1 -0
  118. package/dist/themes/tokens/tokens.css.d.ts +714 -0
  119. package/dist/themes/tokens/tokens.css.d.ts.map +1 -0
  120. package/dist/themes/tokens/tokens.css.js +36 -0
  121. package/dist/themes/tokens/tokens.css.js.map +1 -0
  122. package/dist/types/theming.d.ts +7 -0
  123. package/dist/types/theming.d.ts.map +1 -0
  124. package/package.json +80 -0
  125. package/src/components/composite/Card/Card.tsx +62 -0
  126. package/src/components/composite/Card/card.css.ts +79 -0
  127. package/src/components/composite/Dialog/Dialog.tsx +150 -0
  128. package/src/components/composite/Dialog/DialogProvider.tsx +21 -0
  129. package/src/components/composite/Dialog/dialog.css.ts +137 -0
  130. package/src/components/primitives/Button/Button.tsx +35 -0
  131. package/src/components/primitives/Button/button.css.ts +236 -0
  132. package/src/components/primitives/Button/button.types.ts +23 -0
  133. package/src/components/primitives/Input/Input.tsx +13 -0
  134. package/src/components/primitives/Input/input.css.ts +64 -0
  135. package/src/components/primitives/Label/Label.tsx +15 -0
  136. package/src/components/primitives/Label/label.css.ts +39 -0
  137. package/src/components/primitives/Typography/Text.tsx +55 -0
  138. package/src/components/primitives/Typography/text.css.ts +1091 -0
  139. package/src/components/primitives/Typography/text.types.ts +55 -0
  140. package/src/constants/theming.ts +16 -0
  141. package/src/hooks/dialog.ts +15 -0
  142. package/src/hooks/refs.ts +34 -0
  143. package/src/hooks/theme.ts +15 -0
  144. package/src/hooks/utils.ts +3 -0
  145. package/src/index.css.ts +26 -0
  146. package/src/index.ts +111 -0
  147. package/src/themes/ThemeProvider/ThemeProvider.tsx +39 -0
  148. package/src/themes/regal.css.ts +741 -0
  149. package/src/themes/styles/color-scheme.css.ts +11 -0
  150. package/src/themes/styles/utilities.ts +140 -0
  151. package/src/themes/tokens/primitives/borders.ts +21 -0
  152. package/src/themes/tokens/primitives/colors.ts +114 -0
  153. package/src/themes/tokens/primitives/shadows.ts +12 -0
  154. package/src/themes/tokens/primitives/spacing.ts +39 -0
  155. package/src/themes/tokens/primitives/typography.ts +125 -0
  156. package/src/themes/tokens/semantic/borders.ts +21 -0
  157. package/src/themes/tokens/semantic/colors.ts +166 -0
  158. package/src/themes/tokens/semantic/shadows.ts +12 -0
  159. package/src/themes/tokens/semantic/spacing.ts +75 -0
  160. package/src/themes/tokens/semantic/typography.ts +35 -0
  161. package/src/themes/tokens/tokens.css.ts +42 -0
  162. package/src/types/theming.ts +14 -0
@@ -0,0 +1,27 @@
1
+ import { ButtonSize, ButtonVariant } from "./button.types.js";
2
+ import { ComponentProps, FC } from "react";
3
+
4
+ //#region src/components/primitives/Button/Button.d.ts
5
+ interface ButtonProps extends ComponentProps<'button'> {
6
+ /**
7
+ * When true, the button will render as a child component using Radix UI's Slot primitive.
8
+ * This allows the button styles to be applied to any element while maintaining accessibility.
9
+ */
10
+ asChild?: boolean;
11
+ /**
12
+ * The visual style variant of the button.
13
+ */
14
+ variant?: ButtonVariant;
15
+ /**
16
+ * The size of the button, affecting padding and font size.
17
+ */
18
+ size?: ButtonSize;
19
+ }
20
+ /**
21
+ * Versatile button component with multiple variants and sizes.
22
+ * Supports rendering as child components via Radix UI's Slot primitive for flexible composition.
23
+ */
24
+ declare const Button: FC<ButtonProps>;
25
+ //#endregion
26
+ export { Button, type ButtonProps };
27
+ //# sourceMappingURL=Button.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"Button.d.ts","names":[],"sources":["../../../../src/components/primitives/Button/Button.tsx"],"sourcesContent":[],"mappings":";;;;UAOU,WAAA,SAAoB;;AAFqC;;;SAe1D,CAAA,EAAA,OAAA;;;AAbmC;EAwB3C,OAAA,CAAA,EAfW,aAeX;;;;SAXQ;;;;;;cAOH,QAAQ,GAAG"}
@@ -0,0 +1,25 @@
1
+ import { buttonVariants } from "./button.css.js";
2
+ import clsx from "clsx";
3
+ import { jsx } from "react/jsx-runtime";
4
+ import { Slot } from "@radix-ui/react-slot";
5
+
6
+ //#region src/components/primitives/Button/Button.tsx
7
+ /**
8
+ * Versatile button component with multiple variants and sizes.
9
+ * Supports rendering as child components via Radix UI's Slot primitive for flexible composition.
10
+ */
11
+ const Button = ({ className, size, variant, asChild = false, ...props }) => {
12
+ return /* @__PURE__ */ jsx(asChild ? Slot : "button", {
13
+ "data-slot": "button",
14
+ className: clsx(buttonVariants({
15
+ variant,
16
+ size
17
+ }), className),
18
+ ...props
19
+ });
20
+ };
21
+ var Button_default = Button;
22
+
23
+ //#endregion
24
+ export { Button_default as default };
25
+ //# sourceMappingURL=Button.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"Button.js","names":["Button: FC<ButtonProps>"],"sources":["../../../../src/components/primitives/Button/Button.tsx"],"sourcesContent":["import { type ComponentProps, type FC } from 'react';\nimport { Slot } from '@radix-ui/react-slot';\nimport clsx from 'clsx';\n\nimport { buttonVariants } from './button.css.js';\nimport type { ButtonSize, ButtonVariant } from './button.types.js';\n\ninterface ButtonProps extends ComponentProps<'button'> {\n /**\n * When true, the button will render as a child component using Radix UI's Slot primitive.\n * This allows the button styles to be applied to any element while maintaining accessibility.\n */\n asChild?: boolean;\n /**\n * The visual style variant of the button.\n */\n variant?: ButtonVariant;\n /**\n * The size of the button, affecting padding and font size.\n */\n size?: ButtonSize;\n}\n\n/**\n * Versatile button component with multiple variants and sizes.\n * Supports rendering as child components via Radix UI's Slot primitive for flexible composition.\n */\nconst Button: FC<ButtonProps> = ({ className, size, variant, asChild = false, ...props }) => {\n const Comp = asChild ? Slot : 'button';\n\n return <Comp data-slot=\"button\" className={clsx(buttonVariants({ variant, size }), className)} {...props} />;\n};\n\nexport type { ButtonProps };\nexport default Button;\n"],"mappings":";;;;;;;;;;AA2BA,MAAMA,UAA2B,EAAE,WAAW,MAAM,SAAS,UAAU,OAAO,GAAG,YAAY;AAG3F,QAAO,oBAFM,UAAU,OAAO;EAEjB,aAAU;EAAS,WAAW,KAAK,eAAe;GAAE;GAAS;GAAM,CAAC,EAAE,UAAU;EAAE,GAAI;GAAS;;AAI9G,qBAAe"}
@@ -0,0 +1,16 @@
1
+ import "@vanilla-extract/css";
2
+ import "@vanilla-extract/recipes";
3
+
4
+ //#region src/components/primitives/Button/button.css.d.ts
5
+ declare const BUTTON_VARIANT__PRIMARY = "primary";
6
+ declare const BUTTON_VARIANT__SECONDARY = "secondary";
7
+ declare const BUTTON_VARIANT__OUTLINE = "outline";
8
+ declare const BUTTON_VARIANT__DESTRUCTIVE = "destructive";
9
+ declare const BUTTON_VARIANT__GHOST = "ghost";
10
+ declare const BUTTON_VARIANT__LINK = "link";
11
+ declare const BUTTON_SIZE__LARGE = "large";
12
+ declare const BUTTON_SIZE__MEDIUM = "medium";
13
+ declare const BUTTON_SIZE__SMALL = "small";
14
+ //#endregion
15
+ export { BUTTON_SIZE__LARGE, BUTTON_SIZE__MEDIUM, BUTTON_SIZE__SMALL, BUTTON_VARIANT__DESTRUCTIVE, BUTTON_VARIANT__GHOST, BUTTON_VARIANT__LINK, BUTTON_VARIANT__OUTLINE, BUTTON_VARIANT__PRIMARY, BUTTON_VARIANT__SECONDARY };
16
+ //# sourceMappingURL=button.css.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"button.css.d.ts","names":[],"sources":["../../../../src/components/primitives/Button/button.css.ts"],"sourcesContent":[],"mappings":";;;;cAOM,uBAAA;cACA,yBAAA;cACA,uBAAA;cACA,2BAAA;AAWc,cAVd,qBAAA,GAJuB,OAAA;AAAA,cAKvB,oBAAA,GAJyB,MAAA;AAAA,cAMzB,kBAAA,GALuB,OAAA;AAAA,cAMvB,mBAAA,GAL2B,QAAA;AAAA,cAM3B,kBAAA,GALqB,OAAA"}
@@ -0,0 +1,202 @@
1
+ import { themeContract } from "../../../themes/tokens/tokens.css.js";
2
+ import { COLORS__PURE } from "../../../themes/tokens/primitives/colors.js";
3
+ import { withCustomOutline, withSafeTransition } from "../../../themes/styles/utilities.js";
4
+ import { createVar } from "@vanilla-extract/css";
5
+ import { recipe } from "@vanilla-extract/recipes";
6
+
7
+ //#region src/components/primitives/Button/button.css.ts
8
+ const BUTTON_VARIANT__PRIMARY = "primary";
9
+ const BUTTON_VARIANT__SECONDARY = "secondary";
10
+ const BUTTON_VARIANT__OUTLINE = "outline";
11
+ const BUTTON_VARIANT__DESTRUCTIVE = "destructive";
12
+ const BUTTON_VARIANT__GHOST = "ghost";
13
+ const BUTTON_VARIANT__LINK = "link";
14
+ const BUTTON_SIZE__LARGE = "large";
15
+ const BUTTON_SIZE__MEDIUM = "medium";
16
+ const BUTTON_SIZE__SMALL = "small";
17
+ const internalFontSize = createVar();
18
+ const internalPadding = createVar();
19
+ const buttonVariants = recipe({
20
+ base: [
21
+ withCustomOutline(themeContract.colors.shadow.interactive),
22
+ withSafeTransition({ transition: "all 0.2s ease-in-out" }),
23
+ {
24
+ display: "inline-flex",
25
+ alignItems: "center",
26
+ justifyContent: "center",
27
+ borderRadius: themeContract.borderRadius.md,
28
+ fontSize: internalFontSize,
29
+ padding: internalPadding,
30
+ fontWeight: themeContract.typography.body.md.medium.fontWeight,
31
+ gap: "0.5rem",
32
+ whiteSpace: "nowrap",
33
+ flexShrink: 0,
34
+ border: "0",
35
+ cursor: "pointer",
36
+ userSelect: "none",
37
+ position: "relative",
38
+ textDecoration: "none",
39
+ outlineColor: COLORS__PURE.transparent,
40
+ ":disabled": { cursor: "not-allowed" }
41
+ }
42
+ ],
43
+ variants: {
44
+ variant: {
45
+ [BUTTON_VARIANT__PRIMARY]: {
46
+ backgroundColor: themeContract.colors.action.bg.primary.default,
47
+ color: themeContract.colors.action.color.primary,
48
+ selectors: {
49
+ "&:hover:not(:disabled)": { backgroundColor: themeContract.colors.action.bg.primary.hover },
50
+ "&:hover:not(:focus-visible)": { boxShadow: `0 1px 3px ${themeContract.colors.shadow.subtle}` },
51
+ "&:active:not(:disabled)": {
52
+ backgroundColor: themeContract.colors.action.bg.primary.active,
53
+ transform: "translateY(1px)"
54
+ }
55
+ },
56
+ ":disabled": {
57
+ backgroundColor: themeContract.colors.action.bg.primary.disabled,
58
+ color: themeContract.colors.text.disabled
59
+ }
60
+ },
61
+ [BUTTON_VARIANT__SECONDARY]: {
62
+ backgroundColor: themeContract.colors.action.bg.secondary.default,
63
+ borderColor: themeContract.colors.border.action.secondary,
64
+ color: themeContract.colors.text.primary,
65
+ selectors: {
66
+ "&:hover:not(:disabled)": {
67
+ backgroundColor: themeContract.colors.action.bg.secondary.hover,
68
+ boxShadow: `0 1px 3px ${themeContract.colors.shadow.subtle}`
69
+ },
70
+ "&:active:not(:disabled)": {
71
+ backgroundColor: themeContract.colors.action.bg.secondary.active,
72
+ transform: "translateY(1px)"
73
+ }
74
+ },
75
+ ":disabled": {
76
+ backgroundColor: themeContract.colors.action.bg.secondary.disabled,
77
+ color: themeContract.colors.text.disabled
78
+ }
79
+ },
80
+ [BUTTON_VARIANT__OUTLINE]: {
81
+ backgroundColor: themeContract.colors.action.bg.outline.default,
82
+ border: themeContract.borderWidth[1],
83
+ borderStyle: "solid",
84
+ borderColor: themeContract.colors.border.interactive.default,
85
+ color: themeContract.colors.text.interactive.default,
86
+ selectors: {
87
+ "&:hover:not(:disabled)": {
88
+ backgroundColor: themeContract.colors.action.bg.outline.hover,
89
+ borderColor: themeContract.colors.border.interactive.hover,
90
+ color: themeContract.colors.text.interactive.hover,
91
+ boxShadow: `0 1px 3px ${themeContract.colors.shadow.subtle}`
92
+ },
93
+ "&:active:not(:disabled)": {
94
+ backgroundColor: themeContract.colors.action.bg.outline.active,
95
+ borderColor: themeContract.colors.border.interactive.active,
96
+ color: themeContract.colors.text.interactive.active,
97
+ transform: "translateY(1px)"
98
+ }
99
+ },
100
+ ":disabled": {
101
+ backgroundColor: themeContract.colors.action.bg.outline.disabled,
102
+ borderColor: themeContract.colors.border.action.disabled,
103
+ color: themeContract.colors.action.color.outline.disabled
104
+ }
105
+ },
106
+ [BUTTON_VARIANT__GHOST]: {
107
+ backgroundColor: themeContract.colors.action.ghost.default,
108
+ borderColor: themeContract.colors.action.ghost.default,
109
+ color: themeContract.colors.text.interactive.default,
110
+ selectors: {
111
+ "&:hover:not(:disabled)": {
112
+ backgroundColor: themeContract.colors.action.ghost.hover,
113
+ color: themeContract.colors.text.interactive.hover
114
+ },
115
+ "&:active:not(:disabled)": {
116
+ backgroundColor: themeContract.colors.action.ghost.active,
117
+ color: themeContract.colors.text.interactive.active,
118
+ transform: "translateY(1px)"
119
+ }
120
+ },
121
+ ":disabled": {
122
+ backgroundColor: themeContract.colors.action.ghost.disabled,
123
+ color: themeContract.colors.text.disabled
124
+ }
125
+ },
126
+ [BUTTON_VARIANT__LINK]: [withSafeTransition({ transition: "background-size 400ms" }), {
127
+ alignSelf: "center",
128
+ color: themeContract.colors.text.interactive.default,
129
+ background: `none, linear-gradient(to right, ${themeContract.colors.text.interactive.hover}, ${themeContract.colors.text.interactive.hover})`,
130
+ backgroundRepeat: "no-repeat",
131
+ backgroundPosition: "100% 100%, 0 100%",
132
+ backgroundSize: `100% calc(${internalFontSize} / 4), 0 calc(${internalFontSize} / 4)`,
133
+ borderRadius: themeContract.borderRadius.none,
134
+ textWrap: "nowrap",
135
+ padding: "0",
136
+ paddingBottom: "0.2em",
137
+ height: "min-content",
138
+ selectors: {
139
+ "&:hover:not(:disabled)": {
140
+ backgroundSize: `0 calc(${internalFontSize} / 4), 100% calc(${internalFontSize} / 4)`,
141
+ color: themeContract.colors.text.interactive.hover
142
+ },
143
+ "&:focus:not(:disabled)": {
144
+ backgroundSize: `0 calc(${internalFontSize} / 4), 100% calc(${internalFontSize} / 4)`,
145
+ color: themeContract.colors.text.interactive.hover
146
+ },
147
+ "&:active:not(:disabled)": {
148
+ backgroundSize: `0 calc(${internalFontSize} / 4), 100% calc(${internalFontSize} / 4)`,
149
+ color: themeContract.colors.text.interactive.active
150
+ }
151
+ },
152
+ ":disabled": {
153
+ color: themeContract.colors.text.disabled,
154
+ textDecoration: "none"
155
+ },
156
+ ":focus-visible": { boxShadow: "none" }
157
+ }],
158
+ [BUTTON_VARIANT__DESTRUCTIVE]: [withCustomOutline(themeContract.colors.shadow.destructive), {
159
+ backgroundColor: themeContract.colors.action.destructive.default,
160
+ borderColor: themeContract.colors.border.action.destructive,
161
+ color: themeContract.colors.text.inverse,
162
+ selectors: {
163
+ "&:hover:not(:disabled)": {
164
+ backgroundColor: themeContract.colors.action.destructive.hover,
165
+ boxShadow: `0 1px 3px ${themeContract.colors.shadow.subtle}`
166
+ },
167
+ "&:active:not(:disabled)": {
168
+ backgroundColor: themeContract.colors.action.destructive.active,
169
+ transform: "translateY(1px)"
170
+ }
171
+ },
172
+ ":disabled": {
173
+ backgroundColor: themeContract.colors.action.destructive.disabled,
174
+ borderColor: themeContract.colors.border.action.disabled,
175
+ color: themeContract.colors.text.disabled
176
+ }
177
+ }]
178
+ },
179
+ size: {
180
+ [BUTTON_SIZE__SMALL]: { vars: {
181
+ [internalFontSize]: themeContract.typography.body.sm.medium.fontSize,
182
+ [internalPadding]: `${themeContract.spacing[1.5]} ${themeContract.spacing[3]}`
183
+ } },
184
+ [BUTTON_SIZE__MEDIUM]: { vars: {
185
+ [internalFontSize]: themeContract.typography.body.md.medium.fontSize,
186
+ [internalPadding]: `${themeContract.spacing[2]} ${themeContract.spacing[4]}`
187
+ } },
188
+ [BUTTON_SIZE__LARGE]: { vars: {
189
+ [internalFontSize]: themeContract.typography.body.lg.medium.fontSize,
190
+ [internalPadding]: `${themeContract.spacing[3]} ${themeContract.spacing[6]}`
191
+ } }
192
+ }
193
+ },
194
+ defaultVariants: {
195
+ variant: BUTTON_VARIANT__PRIMARY,
196
+ size: BUTTON_SIZE__MEDIUM
197
+ }
198
+ });
199
+
200
+ //#endregion
201
+ export { BUTTON_SIZE__LARGE, BUTTON_SIZE__MEDIUM, BUTTON_SIZE__SMALL, BUTTON_VARIANT__DESTRUCTIVE, BUTTON_VARIANT__GHOST, BUTTON_VARIANT__LINK, BUTTON_VARIANT__OUTLINE, BUTTON_VARIANT__PRIMARY, BUTTON_VARIANT__SECONDARY, buttonVariants };
202
+ //# sourceMappingURL=button.css.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"button.css.js","names":[],"sources":["../../../../src/components/primitives/Button/button.css.ts"],"sourcesContent":["import { createVar } from '@vanilla-extract/css';\nimport { recipe } from '@vanilla-extract/recipes';\n\nimport { themeContract } from '../../../themes/tokens/tokens.css.js';\nimport { withCustomOutline, withSafeTransition } from '../../../themes/styles/utilities.js';\nimport { COLORS__PURE } from '../../../themes/tokens/primitives/colors.js';\n\nconst BUTTON_VARIANT__PRIMARY = 'primary';\nconst BUTTON_VARIANT__SECONDARY = 'secondary';\nconst BUTTON_VARIANT__OUTLINE = 'outline';\nconst BUTTON_VARIANT__DESTRUCTIVE = 'destructive';\nconst BUTTON_VARIANT__GHOST = 'ghost';\nconst BUTTON_VARIANT__LINK = 'link';\n\nconst BUTTON_SIZE__LARGE = 'large';\nconst BUTTON_SIZE__MEDIUM = 'medium';\nconst BUTTON_SIZE__SMALL = 'small';\n\nconst internalFontSize = createVar();\nconst internalPadding = createVar();\n\nconst buttonVariants = recipe({\n base: [\n withCustomOutline(themeContract.colors.shadow.interactive),\n withSafeTransition({ transition: 'all 0.2s ease-in-out' }),\n {\n display: 'inline-flex',\n alignItems: 'center',\n justifyContent: 'center',\n borderRadius: themeContract.borderRadius.md,\n fontSize: internalFontSize,\n padding: internalPadding,\n fontWeight: themeContract.typography.body.md.medium.fontWeight,\n gap: '0.5rem',\n whiteSpace: 'nowrap',\n flexShrink: 0,\n border: '0',\n cursor: 'pointer',\n userSelect: 'none',\n position: 'relative',\n textDecoration: 'none',\n outlineColor: COLORS__PURE.transparent,\n ':disabled': {\n cursor: 'not-allowed',\n },\n },\n ],\n variants: {\n variant: {\n [BUTTON_VARIANT__PRIMARY]: {\n backgroundColor: themeContract.colors.action.bg.primary.default,\n color: themeContract.colors.action.color.primary,\n selectors: {\n '&:hover:not(:disabled)': {\n backgroundColor: themeContract.colors.action.bg.primary.hover,\n },\n '&:hover:not(:focus-visible)': {\n boxShadow: `0 1px 3px ${themeContract.colors.shadow.subtle}`,\n },\n '&:active:not(:disabled)': {\n backgroundColor: themeContract.colors.action.bg.primary.active,\n transform: 'translateY(1px)',\n },\n },\n ':disabled': {\n backgroundColor: themeContract.colors.action.bg.primary.disabled,\n color: themeContract.colors.text.disabled,\n },\n },\n [BUTTON_VARIANT__SECONDARY]: {\n backgroundColor: themeContract.colors.action.bg.secondary.default,\n borderColor: themeContract.colors.border.action.secondary,\n color: themeContract.colors.text.primary,\n selectors: {\n '&:hover:not(:disabled)': {\n backgroundColor: themeContract.colors.action.bg.secondary.hover,\n boxShadow: `0 1px 3px ${themeContract.colors.shadow.subtle}`,\n },\n '&:active:not(:disabled)': {\n backgroundColor: themeContract.colors.action.bg.secondary.active,\n transform: 'translateY(1px)',\n },\n },\n ':disabled': {\n backgroundColor: themeContract.colors.action.bg.secondary.disabled,\n color: themeContract.colors.text.disabled,\n },\n },\n [BUTTON_VARIANT__OUTLINE]: {\n backgroundColor: themeContract.colors.action.bg.outline.default,\n border: themeContract.borderWidth[1],\n borderStyle: 'solid',\n borderColor: themeContract.colors.border.interactive.default,\n color: themeContract.colors.text.interactive.default,\n selectors: {\n '&:hover:not(:disabled)': {\n backgroundColor: themeContract.colors.action.bg.outline.hover,\n borderColor: themeContract.colors.border.interactive.hover,\n color: themeContract.colors.text.interactive.hover,\n boxShadow: `0 1px 3px ${themeContract.colors.shadow.subtle}`,\n },\n '&:active:not(:disabled)': {\n backgroundColor: themeContract.colors.action.bg.outline.active,\n borderColor: themeContract.colors.border.interactive.active,\n color: themeContract.colors.text.interactive.active,\n transform: 'translateY(1px)',\n },\n },\n ':disabled': {\n backgroundColor: themeContract.colors.action.bg.outline.disabled,\n borderColor: themeContract.colors.border.action.disabled,\n color: themeContract.colors.action.color.outline.disabled,\n },\n },\n [BUTTON_VARIANT__GHOST]: {\n backgroundColor: themeContract.colors.action.ghost.default,\n borderColor: themeContract.colors.action.ghost.default,\n color: themeContract.colors.text.interactive.default,\n selectors: {\n '&:hover:not(:disabled)': {\n backgroundColor: themeContract.colors.action.ghost.hover,\n color: themeContract.colors.text.interactive.hover,\n },\n '&:active:not(:disabled)': {\n backgroundColor: themeContract.colors.action.ghost.active,\n color: themeContract.colors.text.interactive.active,\n transform: 'translateY(1px)',\n },\n },\n ':disabled': {\n backgroundColor: themeContract.colors.action.ghost.disabled,\n color: themeContract.colors.text.disabled,\n },\n },\n [BUTTON_VARIANT__LINK]: [\n withSafeTransition({\n transition: 'background-size 400ms',\n }),\n {\n alignSelf: 'center',\n color: themeContract.colors.text.interactive.default,\n background: `none, linear-gradient(to right, ${themeContract.colors.text.interactive.hover}, ${themeContract.colors.text.interactive.hover})`,\n backgroundRepeat: 'no-repeat',\n backgroundPosition: '100% 100%, 0 100%',\n backgroundSize: `100% calc(${internalFontSize} / 4), 0 calc(${internalFontSize} / 4)`,\n borderRadius: themeContract.borderRadius.none,\n textWrap: 'nowrap',\n padding: '0',\n paddingBottom: '0.2em',\n height: 'min-content',\n selectors: {\n '&:hover:not(:disabled)': {\n backgroundSize: `0 calc(${internalFontSize} / 4), 100% calc(${internalFontSize} / 4)`,\n color: themeContract.colors.text.interactive.hover,\n },\n '&:focus:not(:disabled)': {\n backgroundSize: `0 calc(${internalFontSize} / 4), 100% calc(${internalFontSize} / 4)`,\n color: themeContract.colors.text.interactive.hover,\n },\n '&:active:not(:disabled)': {\n backgroundSize: `0 calc(${internalFontSize} / 4), 100% calc(${internalFontSize} / 4)`,\n color: themeContract.colors.text.interactive.active,\n },\n },\n ':disabled': {\n color: themeContract.colors.text.disabled,\n textDecoration: 'none',\n },\n ':focus-visible': {\n boxShadow: 'none',\n },\n },\n ],\n [BUTTON_VARIANT__DESTRUCTIVE]: [\n withCustomOutline(themeContract.colors.shadow.destructive),\n {\n backgroundColor: themeContract.colors.action.destructive.default,\n borderColor: themeContract.colors.border.action.destructive,\n color: themeContract.colors.text.inverse,\n selectors: {\n '&:hover:not(:disabled)': {\n backgroundColor: themeContract.colors.action.destructive.hover,\n boxShadow: `0 1px 3px ${themeContract.colors.shadow.subtle}`,\n },\n '&:active:not(:disabled)': {\n backgroundColor: themeContract.colors.action.destructive.active,\n transform: 'translateY(1px)',\n },\n },\n ':disabled': {\n backgroundColor: themeContract.colors.action.destructive.disabled,\n borderColor: themeContract.colors.border.action.disabled,\n color: themeContract.colors.text.disabled,\n },\n },\n ],\n },\n size: {\n [BUTTON_SIZE__SMALL]: {\n vars: {\n [internalFontSize]: themeContract.typography.body.sm.medium.fontSize,\n [internalPadding]: `${themeContract.spacing[1.5]} ${themeContract.spacing[3]}`,\n },\n },\n [BUTTON_SIZE__MEDIUM]: {\n vars: {\n [internalFontSize]: themeContract.typography.body.md.medium.fontSize,\n [internalPadding]: `${themeContract.spacing[2]} ${themeContract.spacing[4]}`,\n },\n },\n [BUTTON_SIZE__LARGE]: {\n vars: {\n [internalFontSize]: themeContract.typography.body.lg.medium.fontSize,\n [internalPadding]: `${themeContract.spacing[3]} ${themeContract.spacing[6]}`,\n },\n },\n },\n },\n defaultVariants: {\n variant: BUTTON_VARIANT__PRIMARY,\n size: BUTTON_SIZE__MEDIUM,\n },\n});\n\nexport {\n BUTTON_VARIANT__PRIMARY,\n BUTTON_VARIANT__SECONDARY,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cAAc,OAAO,KAAK;IACjC,WAAW;KACT,0BAA0B;MACxB,iBAAiB,cAAc,OAAO,OAAO,YAAY;MACzD,WAAW,aAAa,cAAc,OAAO,OAAO;MACrD;KACD,2BAA2B;MACzB,iBAAiB,cAAc,OAAO,OAAO,YAAY;MACzD,WAAW;MACZ;KACF;IACD,aAAa;KACX,iBAAiB,cAAc,OAAO,OAAO,YAAY;KACzD,aAAa,cAAc,OAAO,OAAO,OAAO;KAChD,OAAO,cAAc,OAAO,KAAK;KAClC;IACF,CACF;GACF;EACD,MAAM;IACH,qBAAqB,EACpB,MAAM;KACH,mBAAmB,cAAc,WAAW,KAAK,GAAG,OAAO;KAC3D,kBAAkB,GAAG,cAAc,QAAQ,KAAK,GAAG,cAAc,QAAQ;IAC3E,EACF;IACA,sBAAsB,EACrB,MAAM;KACH,mBAAmB,cAAc,WAAW,KAAK,GAAG,OAAO;KAC3D,kBAAkB,GAAG,cAAc,QAAQ,GAAG,GAAG,cAAc,QAAQ;IACzE,EACF;IACA,qBAAqB,EACpB,MAAM;KACH,mBAAmB,cAAc,WAAW,KAAK,GAAG,OAAO;KAC3D,kBAAkB,GAAG,cAAc,QAAQ,GAAG,GAAG,cAAc,QAAQ;IACzE,EACF;GACF;EACF;CACD,iBAAiB;EACf,SAAS;EACT,MAAM;EACP;CACF,CAAC"}
@@ -0,0 +1,8 @@
1
+ import { BUTTON_SIZE__LARGE, BUTTON_SIZE__MEDIUM, BUTTON_SIZE__SMALL, BUTTON_VARIANT__DESTRUCTIVE, BUTTON_VARIANT__GHOST, BUTTON_VARIANT__LINK, BUTTON_VARIANT__OUTLINE, BUTTON_VARIANT__PRIMARY, BUTTON_VARIANT__SECONDARY } from "./button.css.js";
2
+
3
+ //#region src/components/primitives/Button/button.types.d.ts
4
+ type ButtonVariant = typeof BUTTON_VARIANT__PRIMARY | typeof BUTTON_VARIANT__SECONDARY | typeof BUTTON_VARIANT__OUTLINE | typeof BUTTON_VARIANT__DESTRUCTIVE | typeof BUTTON_VARIANT__GHOST | typeof BUTTON_VARIANT__LINK;
5
+ type ButtonSize = typeof BUTTON_SIZE__LARGE | typeof BUTTON_SIZE__MEDIUM | typeof BUTTON_SIZE__SMALL;
6
+ //#endregion
7
+ export { type ButtonSize, type ButtonVariant };
8
+ //# sourceMappingURL=button.types.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"button.types.d.ts","names":[],"sources":["../../../../src/components/primitives/Button/button.types.ts"],"sourcesContent":[],"mappings":";;;KAYK,aAAA,UACM,iCACA,mCACA,iCACA,qCACA,+BACA;KAEN,UAAA,UAAoB,4BAA4B,6BAA6B"}
@@ -0,0 +1,12 @@
1
+ import { ComponentProps, FC } from "react";
2
+
3
+ //#region src/components/primitives/Input/Input.d.ts
4
+
5
+ /**
6
+ * Standard input component with consistent styling and design system integration.
7
+ * Extends native HTML input element with theme-aware styling.
8
+ */
9
+ declare const Input: FC<ComponentProps<'input'>>;
10
+ //#endregion
11
+ export { Input };
12
+ //# sourceMappingURL=Input.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"Input.d.ts","names":[],"sources":["../../../../src/components/primitives/Input/Input.tsx"],"sourcesContent":[],"mappings":";;;;;;AAAqD;;cAQ/C,KAAU,EAAH,EAAG,CAAA,cAAA,CAAA,OAAA,CAAA,CAAA"}
@@ -0,0 +1,21 @@
1
+ import { input } from "./input.css.js";
2
+ import clsx from "clsx";
3
+ import { jsx } from "react/jsx-runtime";
4
+
5
+ //#region src/components/primitives/Input/Input.tsx
6
+ /**
7
+ * Standard input component with consistent styling and design system integration.
8
+ * Extends native HTML input element with theme-aware styling.
9
+ */
10
+ const Input = ({ className, ...props }) => {
11
+ return /* @__PURE__ */ jsx("input", {
12
+ "data-slot": "input",
13
+ className: clsx(input, className),
14
+ ...props
15
+ });
16
+ };
17
+ var Input_default = Input;
18
+
19
+ //#endregion
20
+ export { Input_default as default };
21
+ //# sourceMappingURL=Input.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"Input.js","names":["Input: FC<ComponentProps<'input'>>"],"sources":["../../../../src/components/primitives/Input/Input.tsx"],"sourcesContent":["import { type ComponentProps, type FC } from 'react';\nimport clsx from 'clsx';\nimport { input } from './input.css.js';\n\n/**\n * Standard input component with consistent styling and design system integration.\n * Extends native HTML input element with theme-aware styling.\n */\nconst Input: FC<ComponentProps<'input'>> = ({ className, ...props }) => {\n return <input data-slot=\"input\" className={clsx(input, className)} {...props} />;\n};\n\nexport default Input;\n"],"mappings":";;;;;;;;;AAQA,MAAMA,SAAsC,EAAE,WAAW,GAAG,YAAY;AACtE,QAAO,oBAAC;EAAM,aAAU;EAAQ,WAAW,KAAK,OAAO,UAAU;EAAE,GAAI;GAAS;;AAGlF,oBAAe"}
@@ -0,0 +1,54 @@
1
+ import { BREAKPOINT__MD } from "../../../constants/theming.js";
2
+ import { themeContract } from "../../../themes/tokens/tokens.css.js";
3
+ import { COLORS__PURE } from "../../../themes/tokens/primitives/colors.js";
4
+ import { withBreakpoint, withCustomOutline, withSafeTransition } from "../../../themes/styles/utilities.js";
5
+ import { style } from "@vanilla-extract/css";
6
+
7
+ //#region src/components/primitives/Input/input.css.ts
8
+ const input = style([
9
+ withBreakpoint(BREAKPOINT__MD, { fontSize: themeContract.typography.body.sm.medium.fontSize }),
10
+ withCustomOutline(themeContract.colors.shadow.focus),
11
+ withSafeTransition({ transition: "color 150ms ease-in-out, box-shadow 150ms ease-in-out" }),
12
+ {
13
+ width: "100%",
14
+ minWidth: 0,
15
+ boxSizing: "border-box",
16
+ borderRadius: themeContract.borderRadius.md,
17
+ border: `${themeContract.borderWidth[1]} solid ${themeContract.colors.input.border.default}`,
18
+ backgroundColor: COLORS__PURE.transparent,
19
+ paddingLeft: themeContract.spacing[3],
20
+ paddingRight: themeContract.spacing[3],
21
+ paddingTop: themeContract.spacing[1],
22
+ paddingBottom: themeContract.spacing[1],
23
+ fontSize: themeContract.typography.body.md.medium.fontSize,
24
+ lineHeight: themeContract.typography.body.md.medium.lineHeight,
25
+ boxShadow: themeContract.boxShadow.sm,
26
+ color: themeContract.colors.text.primary,
27
+ selectors: {
28
+ "&[aria-invalid=\"true\"]": { borderColor: themeContract.colors.border.error },
29
+ ...withCustomOutline(themeContract.colors.shadow.destructive, "&[aria-invalid=\"true\"]")
30
+ },
31
+ "::file-selector-button": {
32
+ display: "inline-flex",
33
+ border: 0,
34
+ backgroundColor: COLORS__PURE.transparent,
35
+ fontSize: themeContract.typography.body.md.medium.fontSize,
36
+ fontWeight: themeContract.typography.body.md.medium.fontWeight,
37
+ color: themeContract.colors.text.primary
38
+ },
39
+ "::placeholder": { color: themeContract.colors.input.text.placeholder },
40
+ "::selection": {
41
+ backgroundColor: themeContract.colors.action.bg.primary.default,
42
+ color: themeContract.colors.action.color.primary
43
+ },
44
+ ":disabled": {
45
+ pointerEvents: "none",
46
+ cursor: "not-allowed",
47
+ opacity: "0.5"
48
+ }
49
+ }
50
+ ]);
51
+
52
+ //#endregion
53
+ export { input };
54
+ //# sourceMappingURL=input.css.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"input.css.js","names":[],"sources":["../../../../src/components/primitives/Input/input.css.ts"],"sourcesContent":["import { style } from '@vanilla-extract/css';\n\nimport { themeContract } from '../../../themes/tokens/tokens.css.js';\nimport { withBreakpoint, withCustomOutline, withSafeTransition } from '../../../themes/styles/utilities.js';\nimport { BREAKPOINT__MD } from '../../../constants/theming.js';\nimport { COLORS__PURE } from '../../../themes/tokens/primitives/colors.js';\n\nconst input = style([\n withBreakpoint(BREAKPOINT__MD, {\n fontSize: themeContract.typography.body.sm.medium.fontSize,\n }),\n withCustomOutline(themeContract.colors.shadow.focus),\n withSafeTransition({\n transition: 'color 150ms ease-in-out, box-shadow 150ms ease-in-out',\n }),\n {\n width: '100%',\n minWidth: 0,\n boxSizing: 'border-box',\n borderRadius: themeContract.borderRadius.md,\n border: `${themeContract.borderWidth[1]} solid ${themeContract.colors.input.border.default}`,\n backgroundColor: COLORS__PURE.transparent,\n paddingLeft: themeContract.spacing[3],\n paddingRight: themeContract.spacing[3],\n paddingTop: themeContract.spacing[1],\n paddingBottom: themeContract.spacing[1],\n fontSize: themeContract.typography.body.md.medium.fontSize,\n lineHeight: themeContract.typography.body.md.medium.lineHeight,\n boxShadow: themeContract.boxShadow.sm,\n color: themeContract.colors.text.primary,\n selectors: {\n '&[aria-invalid=\"true\"]': {\n borderColor: themeContract.colors.border.error,\n },\n ...withCustomOutline(themeContract.colors.shadow.destructive, '&[aria-invalid=\"true\"]'),\n },\n\n '::file-selector-button': {\n display: 'inline-flex',\n border: 0,\n backgroundColor: COLORS__PURE.transparent,\n fontSize: themeContract.typography.body.md.medium.fontSize,\n fontWeight: themeContract.typography.body.md.medium.fontWeight,\n color: themeContract.colors.text.primary,\n },\n\n '::placeholder': {\n color: themeContract.colors.input.text.placeholder,\n },\n\n '::selection': {\n backgroundColor: themeContract.colors.action.bg.primary.default,\n color: themeContract.colors.action.color.primary,\n },\n\n ':disabled': {\n pointerEvents: 'none',\n cursor: 'not-allowed',\n opacity: '0.5',\n },\n },\n]);\n\nexport { input };\n"],"mappings":";;;;;;;AAOA,MAAM,QAAQ,MAAM;CAClB,eAAe,gBAAgB,EAC7B,UAAU,cAAc,WAAW,KAAK,GAAG,OAAO,UACnD,CAAC;CACF,kBAAkB,cAAc,OAAO,OAAO,MAAM;CACpD,mBAAmB,EACjB,YAAY,yDACb,CAAC;CACF;EACE,OAAO;EACP,UAAU;EACV,WAAW;EACX,cAAc,cAAc,aAAa;EACzC,QAAQ,GAAG,cAAc,YAAY,GAAG,SAAS,cAAc,OAAO,MAAM,OAAO;EACnF,iBAAiB,aAAa;EAC9B,aAAa,cAAc,QAAQ;EACnC,cAAc,cAAc,QAAQ;EACpC,YAAY,cAAc,QAAQ;EAClC,eAAe,cAAc,QAAQ;EACrC,UAAU,cAAc,WAAW,KAAK,GAAG,OAAO;EAClD,YAAY,cAAc,WAAW,KAAK,GAAG,OAAO;EACpD,WAAW,cAAc,UAAU;EACnC,OAAO,cAAc,OAAO,KAAK;EACjC,WAAW;GACT,4BAA0B,EACxB,aAAa,cAAc,OAAO,OAAO,OAC1C;GACD,GAAG,kBAAkB,cAAc,OAAO,OAAO,aAAa,2BAAyB;GACxF;EAED,0BAA0B;GACxB,SAAS;GACT,QAAQ;GACR,iBAAiB,aAAa;GAC9B,UAAU,cAAc,WAAW,KAAK,GAAG,OAAO;GAClD,YAAY,cAAc,WAAW,KAAK,GAAG,OAAO;GACpD,OAAO,cAAc,OAAO,KAAK;GAClC;EAED,iBAAiB,EACf,OAAO,cAAc,OAAO,MAAM,KAAK,aACxC;EAED,eAAe;GACb,iBAAiB,cAAc,OAAO,OAAO,GAAG,QAAQ;GACxD,OAAO,cAAc,OAAO,OAAO,MAAM;GAC1C;EAED,aAAa;GACX,eAAe;GACf,QAAQ;GACR,SAAS;GACV;EACF;CACF,CAAC"}
@@ -0,0 +1,13 @@
1
+ import { ComponentProps, FC } from "react";
2
+ import * as LabelPrimitive from "@radix-ui/react-label";
3
+
4
+ //#region src/components/primitives/Label/Label.d.ts
5
+
6
+ /**
7
+ * Accessible label component built on Radix UI's Label primitive.
8
+ * Provides proper form control labeling with consistent styling.
9
+ */
10
+ declare const Label: FC<ComponentProps<typeof LabelPrimitive.Root>>;
11
+ //#endregion
12
+ export { Label };
13
+ //# sourceMappingURL=Label.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"Label.d.ts","names":[],"sources":["../../../../src/components/primitives/Label/Label.tsx"],"sourcesContent":[],"mappings":";;;;;;;AACwD;;cASlD,KAAgC,EAAzB,EAAwC,CAArC,cAAqC,CAAA,OAAf,cAAA,CAAe,IAAA,CAAA,CAAA"}
@@ -0,0 +1,22 @@
1
+ import { label } from "./label.css.js";
2
+ import clsx from "clsx";
3
+ import { jsx } from "react/jsx-runtime";
4
+ import * as LabelPrimitive from "@radix-ui/react-label";
5
+
6
+ //#region src/components/primitives/Label/Label.tsx
7
+ /**
8
+ * Accessible label component built on Radix UI's Label primitive.
9
+ * Provides proper form control labeling with consistent styling.
10
+ */
11
+ const Label = ({ className, ...props }) => {
12
+ return /* @__PURE__ */ jsx(LabelPrimitive.Root, {
13
+ "data-slot": "label",
14
+ className: clsx(label, className),
15
+ ...props
16
+ });
17
+ };
18
+ var Label_default = Label;
19
+
20
+ //#endregion
21
+ export { Label_default as default };
22
+ //# sourceMappingURL=Label.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"Label.js","names":["Label: FC<ComponentProps<typeof LabelPrimitive.Root>>"],"sources":["../../../../src/components/primitives/Label/Label.tsx"],"sourcesContent":["import { type ComponentProps, type FC } from 'react';\nimport * as LabelPrimitive from '@radix-ui/react-label';\nimport clsx from 'clsx';\n\nimport { label } from './label.css.js';\n\n/**\n * Accessible label component built on Radix UI's Label primitive.\n * Provides proper form control labeling with consistent styling.\n */\nconst Label: FC<ComponentProps<typeof LabelPrimitive.Root>> = ({ className, ...props }) => {\n return <LabelPrimitive.Root data-slot=\"label\" className={clsx(label, className)} {...props} />;\n};\n\nexport default Label;\n"],"mappings":";;;;;;;;;;AAUA,MAAMA,SAAyD,EAAE,WAAW,GAAG,YAAY;AACzF,QAAO,oBAAC,eAAe;EAAK,aAAU;EAAQ,WAAW,KAAK,OAAO,UAAU;EAAE,GAAI;GAAS;;AAGhG,oBAAe"}
@@ -0,0 +1,35 @@
1
+ import { themeContract } from "../../../themes/tokens/tokens.css.js";
2
+ import { style } from "@vanilla-extract/css";
3
+
4
+ //#region src/components/primitives/Label/label.css.ts
5
+ const label = style({
6
+ display: "flex",
7
+ alignItems: "center",
8
+ gap: themeContract.spacing[2],
9
+ fontSize: themeContract.typography.label.lg.medium.fontSize,
10
+ lineHeight: themeContract.typography.label.lg.medium.lineHeight,
11
+ fontWeight: themeContract.typography.label.lg.medium.fontWeight,
12
+ userSelect: "none",
13
+ selectors: {
14
+ "[data-disabled=\"true\"] &": {
15
+ pointerEvents: "none",
16
+ opacity: .5
17
+ },
18
+ ":disabled + &": {
19
+ cursor: "not-allowed",
20
+ opacity: .5
21
+ },
22
+ "input:disabled + &": {
23
+ cursor: "not-allowed",
24
+ opacity: .5
25
+ },
26
+ ":is(input, select, textarea):disabled + &": {
27
+ cursor: "not-allowed",
28
+ opacity: .5
29
+ }
30
+ }
31
+ });
32
+
33
+ //#endregion
34
+ export { label };
35
+ //# sourceMappingURL=label.css.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"label.css.js","names":[],"sources":["../../../../src/components/primitives/Label/label.css.ts"],"sourcesContent":["import { style } from '@vanilla-extract/css';\n\nimport { themeContract } from '../../../themes/tokens/tokens.css.js';\n\nconst label = style({\n display: 'flex',\n alignItems: 'center',\n gap: themeContract.spacing[2],\n\n fontSize: themeContract.typography.label.lg.medium.fontSize,\n lineHeight: themeContract.typography.label.lg.medium.lineHeight,\n fontWeight: themeContract.typography.label.lg.medium.fontWeight,\n\n userSelect: 'none',\n\n selectors: {\n '[data-disabled=\"true\"] &': {\n pointerEvents: 'none',\n opacity: 0.5,\n },\n\n ':disabled + &': {\n cursor: 'not-allowed',\n opacity: 0.5,\n },\n\n 'input:disabled + &': {\n cursor: 'not-allowed',\n opacity: 0.5,\n },\n\n ':is(input, select, textarea):disabled + &': {\n cursor: 'not-allowed',\n opacity: 0.5,\n },\n },\n});\n\nexport { label };\n"],"mappings":";;;;AAIA,MAAM,QAAQ,MAAM;CAClB,SAAS;CACT,YAAY;CACZ,KAAK,cAAc,QAAQ;CAE3B,UAAU,cAAc,WAAW,MAAM,GAAG,OAAO;CACnD,YAAY,cAAc,WAAW,MAAM,GAAG,OAAO;CACrD,YAAY,cAAc,WAAW,MAAM,GAAG,OAAO;CAErD,YAAY;CAEZ,WAAW;EACT,8BAA4B;GAC1B,eAAe;GACf,SAAS;GACV;EAED,iBAAiB;GACf,QAAQ;GACR,SAAS;GACV;EAED,sBAAsB;GACpB,QAAQ;GACR,SAAS;GACV;EAED,6CAA6C;GAC3C,QAAQ;GACR,SAAS;GACV;EACF;CACF,CAAC"}
@@ -0,0 +1,40 @@
1
+ import { TextColor, TextSize, TextType, TextWeight } from "./text.types.js";
2
+ import { ComponentProps, FC } from "react";
3
+
4
+ //#region src/components/primitives/Typography/Text.d.ts
5
+ interface TextProps extends ComponentProps<'h1'> {
6
+ /**
7
+ * When true, the component will render as a child component using Radix UI's Slot primitive.
8
+ * This allows the text styles to be applied to any element while maintaining accessibility.
9
+ */
10
+ asChild?: boolean;
11
+ /**
12
+ * HTML element to render as.
13
+ */
14
+ as: 'h1' | 'h2' | 'h3' | 'h4' | 'h5' | 'h6' | 'span' | 'p' | 'small';
15
+ /**
16
+ * Text style variant that determines the overall visual appearance.
17
+ */
18
+ variant?: TextType;
19
+ /**
20
+ * Visual size variant - independent of semantic HTML element.
21
+ * Allows for flexible styling while maintaining proper semantic structure.
22
+ */
23
+ size?: TextSize;
24
+ /**
25
+ * Color variant for the text.
26
+ */
27
+ color?: TextColor;
28
+ /**
29
+ * Font weight variant for the text.
30
+ */
31
+ weight?: TextWeight;
32
+ }
33
+ /**
34
+ * Flexible text component that supports multiple HTML elements with consistent styling.
35
+ * Allows semantic HTML structure while providing design system typography variants.
36
+ */
37
+ declare const Text: FC<TextProps>;
38
+ //#endregion
39
+ export { Text, type TextProps };
40
+ //# sourceMappingURL=Text.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"Text.d.ts","names":[],"sources":["../../../../src/components/primitives/Typography/Text.tsx"],"sourcesContent":[],"mappings":";;;;UAOU,SAAA,SAAkB;;AAFqD;;;SAoBxE,CAAA,EAAA,OAAA;;;;EAlBiC,EAAA,EAAA,IAAA,GAAA,IAAA,GAAA,IAAA,GAAA,IAAA,GAAA,IAAA,GAAA,IAAA,GAAA,MAAA,GAAA,GAAA,GAAA,OAAA;EAiCpC;;;SAAM,CAAA,EApBA,QAoBA;EAAE;;;;SAfL;;;;UAIC;;;;WAIC;;;;;;cAOL,MAAM,GAAG"}
@@ -0,0 +1,28 @@
1
+ import { textVariants } from "./text.css.js";
2
+ import clsx from "clsx";
3
+ import { jsx } from "react/jsx-runtime";
4
+ import { Slot } from "@radix-ui/react-slot";
5
+
6
+ //#region src/components/primitives/Typography/Text.tsx
7
+ /**
8
+ * Flexible text component that supports multiple HTML elements with consistent styling.
9
+ * Allows semantic HTML structure while providing design system typography variants.
10
+ */
11
+ const Text = ({ ref, className, asChild, as: tag, variant, size, color, weight, ...props }) => {
12
+ return /* @__PURE__ */ jsx(asChild ? Slot : tag, {
13
+ ref,
14
+ "data-slot": tag,
15
+ className: clsx(textVariants({
16
+ variant,
17
+ size,
18
+ color,
19
+ weight
20
+ }), className),
21
+ ...props
22
+ });
23
+ };
24
+ var Text_default = Text;
25
+
26
+ //#endregion
27
+ export { Text_default as default };
28
+ //# sourceMappingURL=Text.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"Text.js","names":["Text: FC<TextProps>"],"sources":["../../../../src/components/primitives/Typography/Text.tsx"],"sourcesContent":["import type { ComponentProps, FC } from 'react';\nimport { Slot } from '@radix-ui/react-slot';\nimport clsx from 'clsx';\n\nimport { textVariants } from './text.css.js';\nimport type { TextColor, TextSize, TextType, TextWeight } from './text.types.js';\n\ninterface TextProps extends ComponentProps<'h1'> {\n /**\n * When true, the component will render as a child component using Radix UI's Slot primitive.\n * This allows the text styles to be applied to any element while maintaining accessibility.\n */\n asChild?: boolean;\n /**\n * HTML element to render as.\n */\n as: 'h1' | 'h2' | 'h3' | 'h4' | 'h5' | 'h6' | 'span' | 'p' | 'small';\n /**\n * Text style variant that determines the overall visual appearance.\n */\n variant?: TextType;\n /**\n * Visual size variant - independent of semantic HTML element.\n * Allows for flexible styling while maintaining proper semantic structure.\n */\n size?: TextSize;\n /**\n * Color variant for the text.\n */\n color?: TextColor;\n /**\n * Font weight variant for the text.\n */\n weight?: TextWeight;\n}\n\n/**\n * Flexible text component that supports multiple HTML elements with consistent styling.\n * Allows semantic HTML structure while providing design system typography variants.\n */\nconst Text: FC<TextProps> = ({ ref, className, asChild, as: tag, variant, size, color, weight, ...props }) => {\n const Comp = asChild ? Slot : tag;\n\n return (\n <Comp\n ref={ref}\n data-slot={tag}\n className={clsx(textVariants({ variant, size, color, weight }), className)}\n {...props}\n />\n );\n};\n\nexport type { TextProps };\nexport default Text;\n"],"mappings":";;;;;;;;;;AAwCA,MAAMA,QAAuB,EAAE,KAAK,WAAW,SAAS,IAAI,KAAK,SAAS,MAAM,OAAO,QAAQ,GAAG,YAAY;AAG5G,QACE,oBAHW,UAAU,OAAO;EAIrB;EACL,aAAW;EACX,WAAW,KAAK,aAAa;GAAE;GAAS;GAAM;GAAO;GAAQ,CAAC,EAAE,UAAU;EAC1E,GAAI;GACJ;;AAKN,mBAAe"}