@pathscale/ui 0.0.10 → 0.0.12

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 (175) hide show
  1. package/README.md +53 -0
  2. package/dist/Avatar-Dkd_kPlV.d.ts +40 -0
  3. package/dist/CollapseTitle-BNxog3is.d.ts +12 -0
  4. package/dist/{Field-DfUn85_1.d.ts → Field-DI2PA30N.d.ts} +1 -1
  5. package/dist/Mask-CPb596Mg.d.ts +16 -0
  6. package/dist/Menu-DgO4SHmA.d.ts +45 -0
  7. package/dist/{Progress-gN0xqhAF.d.ts → Progress-ChF4ior8.d.ts} +2 -2
  8. package/dist/Steps-Dk-UPL6r.d.ts +38 -0
  9. package/dist/{Tabs-BEnRV6GG.d.ts → Tabs-WiUU0xsM.d.ts} +1 -1
  10. package/dist/chunk/2OJYONJ3.js +40 -0
  11. package/dist/chunk/2VQ2762Z.js +80 -0
  12. package/dist/chunk/2XPPNBYK.js +164 -0
  13. package/dist/chunk/3I23P4TJ.js +33 -0
  14. package/dist/chunk/5HG7XWVC.jsx +2956 -0
  15. package/dist/chunk/5IJ7WEIF.js +43 -0
  16. package/dist/chunk/5O6WC3OB.jsx +67 -0
  17. package/dist/chunk/6P5JIKPF.jsx +51 -0
  18. package/dist/chunk/BHLLVOVR.js +46 -0
  19. package/dist/chunk/DJI5XKAV.js +31 -0
  20. package/dist/chunk/DN3P54J2.jsx +43 -0
  21. package/dist/chunk/DVFQAAZR.js +43 -0
  22. package/dist/chunk/EDDBK4J6.js +42 -0
  23. package/dist/chunk/FZRQDGPD.jsx +54 -0
  24. package/dist/chunk/G5UEZ2VC.js +49 -0
  25. package/dist/chunk/GL7JG772.js +114 -0
  26. package/dist/chunk/HEOKGP5U.js +55 -0
  27. package/dist/chunk/HUHXQCKK.js +16 -0
  28. package/dist/chunk/I36LHZUY.jsx +31 -0
  29. package/dist/chunk/IG323YKF.jsx +50 -0
  30. package/dist/chunk/JQ4HSRDP.js +142 -0
  31. package/dist/chunk/JSQBKK7L.jsx +50 -0
  32. package/dist/chunk/K3WO7SRD.js +1 -0
  33. package/dist/chunk/KQ3RAWCE.jsx +57 -0
  34. package/dist/chunk/KXJZKDJX.jsx +0 -0
  35. package/dist/chunk/L4A67X7S.js +7 -0
  36. package/dist/chunk/LGDDR242.jsx +159 -0
  37. package/dist/chunk/MM2DZQL3.js +46 -0
  38. package/dist/chunk/MZWBWFDD.js +151 -0
  39. package/dist/chunk/O7LDJCQS.jsx +18 -0
  40. package/dist/chunk/Q4442PU4.js +42 -0
  41. package/dist/chunk/R5G3PODL.jsx +11 -0
  42. package/dist/chunk/R6ZBT7CY.jsx +55 -0
  43. package/dist/chunk/RHEFVSMJ.jsx +52 -0
  44. package/dist/chunk/{G6RG4LR7.js → SPEY5RMB.js} +2 -5
  45. package/dist/chunk/STFCLC5R.js +2954 -0
  46. package/dist/chunk/SVJIYMYJ.jsx +156 -0
  47. package/dist/chunk/SYWB4UN3.jsx +64 -0
  48. package/dist/chunk/{KACNXPUM.jsx → T2LDLYWV.jsx} +2 -4
  49. package/dist/chunk/UNKDNDT3.js +62 -0
  50. package/dist/chunk/XM3KF5LV.jsx +179 -0
  51. package/dist/chunk/XQCSYRVP.jsx +168 -0
  52. package/dist/chunk/YWIT2MRI.jsx +43 -0
  53. package/dist/chunk/ZYEP35R3.jsx +60 -0
  54. package/dist/components/{progress → Progress}/index.d.ts +1 -1
  55. package/dist/components/accordion/index.d.ts +17 -5
  56. package/dist/components/accordion/index.js +1 -1
  57. package/dist/components/accordion/index.jsx +6 -4
  58. package/dist/components/avatar/index.d.ts +4 -4
  59. package/dist/components/avatar/index.js +1 -1
  60. package/dist/components/avatar/index.jsx +3 -2
  61. package/dist/components/badge/index.d.ts +17 -0
  62. package/dist/components/badge/index.js +1 -0
  63. package/dist/components/badge/index.jsx +8 -0
  64. package/dist/components/breadcrumbs/index.d.ts +9 -0
  65. package/dist/components/breadcrumbs/index.js +1 -0
  66. package/dist/components/breadcrumbs/index.jsx +7 -0
  67. package/dist/components/button/index.d.ts +28 -6
  68. package/dist/components/button/index.js +1 -1
  69. package/dist/components/button/index.jsx +5 -5
  70. package/dist/components/checkbox/index.d.ts +13 -5
  71. package/dist/components/checkbox/index.js +1 -1
  72. package/dist/components/checkbox/index.jsx +5 -4
  73. package/dist/components/collapse/index.d.ts +15 -0
  74. package/dist/components/collapse/index.js +1 -0
  75. package/dist/components/collapse/index.jsx +14 -0
  76. package/dist/components/field/index.d.ts +1 -1
  77. package/dist/components/fileinput/index.d.ts +16 -0
  78. package/dist/components/fileinput/index.js +1 -0
  79. package/dist/components/fileinput/index.jsx +8 -0
  80. package/dist/components/input/index.d.ts +13 -8
  81. package/dist/components/input/index.js +1 -1
  82. package/dist/components/input/index.jsx +5 -6
  83. package/dist/components/join/index.d.ts +11 -0
  84. package/dist/components/join/index.js +1 -0
  85. package/dist/components/join/index.jsx +9 -0
  86. package/dist/components/mask/index.d.ts +7 -0
  87. package/dist/components/mask/index.js +1 -0
  88. package/dist/components/mask/index.jsx +8 -0
  89. package/dist/components/menu/index.d.ts +6 -64
  90. package/dist/components/menu/index.js +1 -1
  91. package/dist/components/menu/index.jsx +4 -7
  92. package/dist/components/pagination/index.d.ts +6 -6
  93. package/dist/components/pagination/index.js +1 -1
  94. package/dist/components/pagination/index.jsx +6 -4
  95. package/dist/components/polymorphic/index.d.ts +1 -2
  96. package/dist/components/polymorphic/index.js +1 -1
  97. package/dist/components/polymorphic/index.jsx +1 -1
  98. package/dist/components/select/index.d.ts +12 -5
  99. package/dist/components/select/index.js +1 -1
  100. package/dist/components/select/index.jsx +5 -4
  101. package/dist/components/steps/index.d.ts +3 -4
  102. package/dist/components/steps/index.js +1 -1
  103. package/dist/components/steps/index.jsx +3 -2
  104. package/dist/components/tabs/index.d.ts +2 -2
  105. package/dist/components/textarea/index.d.ts +12 -5
  106. package/dist/components/textarea/index.js +1 -1
  107. package/dist/components/textarea/index.jsx +5 -4
  108. package/dist/components/toggle/index.d.ts +15 -0
  109. package/dist/components/toggle/index.js +1 -0
  110. package/dist/components/toggle/index.jsx +8 -0
  111. package/dist/components/tooltip/index.d.ts +14 -5
  112. package/dist/components/tooltip/index.js +1 -1
  113. package/dist/components/tooltip/index.jsx +5 -4
  114. package/dist/index.d.ts +23 -18
  115. package/dist/index.js +23 -20
  116. package/dist/index.jsx +80 -65
  117. package/dist/types-CUG9pToa.d.ts +15 -0
  118. package/package.json +4 -2
  119. package/dist/Accordion-JZGWxBMK.d.ts +0 -27
  120. package/dist/Avatar-CzIirpVq.d.ts +0 -33
  121. package/dist/Button-B50OLXuV.d.ts +0 -63
  122. package/dist/Checkbox-CzeDsQLA.d.ts +0 -32
  123. package/dist/Input-BGHHmBBR.d.ts +0 -42
  124. package/dist/Pagination-CJtlFMHy.d.ts +0 -43
  125. package/dist/Select-CWCDBvec.d.ts +0 -44
  126. package/dist/Steps-1miUeyCD.d.ts +0 -34
  127. package/dist/Switch-CW6QtO1Y.d.ts +0 -76
  128. package/dist/Tag-BPrhn-Ne.d.ts +0 -42
  129. package/dist/Textarea-Cpdk7m6S.d.ts +0 -37
  130. package/dist/Tooltip-BfPongoz.d.ts +0 -53
  131. package/dist/Upload-CRljD5jf.d.ts +0 -39
  132. package/dist/chunk/3VOILEMN.js +0 -187
  133. package/dist/chunk/C4745OZS.jsx +0 -101
  134. package/dist/chunk/CJZGTNJZ.js +0 -115
  135. package/dist/chunk/DBQ7IOPU.js +0 -189
  136. package/dist/chunk/EB7KXR65.js +0 -102
  137. package/dist/chunk/EE4HXMKA.js +0 -165
  138. package/dist/chunk/ELRAUORW.jsx +0 -179
  139. package/dist/chunk/F33TSIEQ.jsx +0 -181
  140. package/dist/chunk/GA2HCFRS.jsx +0 -228
  141. package/dist/chunk/GWFGP2JQ.jsx +0 -179
  142. package/dist/chunk/LAQPAV5I.jsx +0 -187
  143. package/dist/chunk/LI3HCFL7.jsx +0 -132
  144. package/dist/chunk/MI773TMC.js +0 -107
  145. package/dist/chunk/MMTAND25.jsx +0 -126
  146. package/dist/chunk/NZKPDBTE.js +0 -118
  147. package/dist/chunk/NZZRKP74.js +0 -214
  148. package/dist/chunk/O2IMHWMY.js +0 -159
  149. package/dist/chunk/OMRJVDZV.js +0 -173
  150. package/dist/chunk/OYAKKETQ.js +0 -111
  151. package/dist/chunk/PNPC2OI3.jsx +0 -156
  152. package/dist/chunk/QHJOIUYT.jsx +0 -117
  153. package/dist/chunk/QONDPQ2I.jsx +0 -105
  154. package/dist/chunk/R6COBCN7.jsx +0 -100
  155. package/dist/chunk/T7IZ26YC.jsx +0 -194
  156. package/dist/chunk/TT2JYGLU.js +0 -218
  157. package/dist/chunk/V6Y5E7BL.js +0 -133
  158. package/dist/chunk/WB6NEEQV.jsx +0 -107
  159. package/dist/chunk/WYHYWDOM.js +0 -164
  160. package/dist/chunk/XD34JKSU.jsx +0 -201
  161. package/dist/chunk/YDEDUOFM.js +0 -102
  162. package/dist/components/breadcrumb/index.d.ts +0 -47
  163. package/dist/components/breadcrumb/index.js +0 -1
  164. package/dist/components/breadcrumb/index.jsx +0 -9
  165. package/dist/components/switch/index.d.ts +0 -8
  166. package/dist/components/switch/index.js +0 -1
  167. package/dist/components/switch/index.jsx +0 -7
  168. package/dist/components/tag/index.d.ts +0 -8
  169. package/dist/components/tag/index.js +0 -1
  170. package/dist/components/tag/index.jsx +0 -7
  171. package/dist/components/upload/index.d.ts +0 -8
  172. package/dist/components/upload/index.js +0 -1
  173. package/dist/components/upload/index.jsx +0 -7
  174. /package/dist/components/{progress → Progress}/index.js +0 -0
  175. /package/dist/components/{progress → Progress}/index.jsx +0 -0
@@ -1,159 +0,0 @@
1
- import { cva } from './HKS7ET6T.js';
2
- import { delegateEvents, createComponent, template, className, insert, spread, mergeProps as mergeProps$1 } from 'solid-js/web';
3
- import { Show, mergeProps, splitProps, createSignal } from 'solid-js';
4
-
5
- // src/components/input/Input.styles.ts
6
- var inputWrapperClass = "relative flex items-center";
7
- var inputVariants = cva(
8
- [
9
- "block w-full appearance-none outline-none bg-transparent",
10
- "border transition-colors duration-200",
11
- "disabled:opacity-50 disabled:cursor-not-allowed"
12
- ],
13
- {
14
- variants: {
15
- color: {
16
- danger: "border-red-500 text-red-600",
17
- success: "border-green-500 text-green-600",
18
- warning: "border-orange-500 text-orange-600"
19
- },
20
- rounded: {
21
- true: "rounded-full",
22
- false: "rounded-md"
23
- },
24
- expanded: {
25
- true: "w-full",
26
- false: "w-fit"
27
- },
28
- loading: {
29
- true: "opacity-50",
30
- false: ""
31
- },
32
- hasLeftIcon: {
33
- true: "pl-10",
34
- false: "pl-4"
35
- },
36
- hasRightIcon: {
37
- true: "pr-10",
38
- false: "pr-4"
39
- }
40
- },
41
- defaultVariants: {
42
- color: void 0,
43
- rounded: false,
44
- expanded: true,
45
- loading: false,
46
- hasLeftIcon: false,
47
- hasRightIcon: false
48
- }
49
- }
50
- );
51
- var iconLeftClass = "absolute left-3 top-1/2 -translate-y-1/2 pointer-events-none text-gray-400";
52
- var iconRightClass = "absolute right-3 top-1/2 -translate-y-1/2 text-gray-400";
53
- var iconButtonClass = "absolute right-3 top-1/2 -translate-y-1/2 text-gray-500";
54
- var _tmpl$ = /* @__PURE__ */ template(`<svg viewBox="64 64 896 896"tabIndex=-1 width=1em height=1em fill=currentColor aria-hidden=true><path d="M942.2 486.2Q889.47 375.11 816.7 305l-50.88 50.88C807.31 395.53 843.45 447.4 874.7 512 791.5 684.2 673.4 766 512 766q-72.67 0-133.87-22.38L323 798.75Q408 838 512 838q288.3 0 430.2-300.3a60.29 60.29 0 000-51.5zm-63.57-320.64L836 122.88a8 8 0 00-11.32 0L715.31 232.2Q624.86 186 512 186q-288.3 0-430.2 300.3a60.3 60.3 0 000 51.5q56.69 119.4 136.5 191.41L112.48 835a8 8 0 000 11.31L155.17 889a8 8 0 0011.31 0l712.15-712.12a8 8 0 000-11.32zM149.3 512C232.6 339.8 350.7 258 512 258c54.54 0 104.13 9.36 149.12 28.39l-70.3 70.3a176 176 0 00-238.13 238.13l-83.42 83.42C223.1 637.49 183.3 582.28 149.3 512zm246.7 0a112.11 112.11 0 01146.2-106.69L401.31 546.2A112 112 0 01396 512z"></path><path d="M508 624c-3.46 0-6.87-.16-10.25-.47l-52.82 52.82a176.09 176.09 0 00227.42-227.42l-52.82 52.82c.31 3.38.47 6.79.47 10.25a111.94 111.94 0 01-112 112z">`);
55
- var _tmpl$2 = /* @__PURE__ */ template(`<svg viewBox="64 64 896 896"tabIndex=-1 width=1em height=1em fill=currentColor aria-hidden=true><path d="M942.2 486.2C847.4 286.5 704.1 186 512 186c-192.2 0-335.4 100.5-430.2 300.3a60.3 60.3 0 000 51.5C176.6 737.5 319.9 838 512 838c192.2 0 335.4-100.5 430.2-300.3 7.7-16.2 7.7-35 0-51.5zM512 766c-161.3 0-279.4-81.8-362.7-254C232.6 339.8 350.7 258 512 258c161.3 0 279.4 81.8 362.7 254C791.5 684.2 673.4 766 512 766zm-4-430c-97.2 0-176 78.8-176 176s78.8 176 176 176 176-78.8 176-176-78.8-176-176-176zm0 288c-61.9 0-112-50.1-112-112s50.1-112 112-112 112 50.1 112 112-50.1 112-112 112z">`);
56
- var EyeIcon = (props) => {
57
- return createComponent(Show, {
58
- get when() {
59
- return props.invisible;
60
- },
61
- get fallback() {
62
- return createComponent(EyeOpen, {});
63
- },
64
- get children() {
65
- return createComponent(EyeInvisible, {});
66
- }
67
- });
68
- };
69
- var EyeInvisible = () => _tmpl$();
70
- var EyeOpen = () => _tmpl$2();
71
- var EyeIcon_default = EyeIcon;
72
-
73
- // src/components/input/Input.tsx
74
- var _tmpl$3 = /* @__PURE__ */ template(`<span>`);
75
- var _tmpl$22 = /* @__PURE__ */ template(`<button type=button>`);
76
- var _tmpl$32 = /* @__PURE__ */ template(`<div><input>`);
77
- var Input = (props) => {
78
- const defaultedProps = mergeProps({
79
- type: "text",
80
- placeholder: ""
81
- }, props);
82
- const [localProps, variantProps, otherProps] = splitProps(defaultedProps, ["type", "passwordReveal", "leftIcon", "rightIcon", "class", "value", "onInput", "name"], ["color", "rounded", "expanded", "loading", "hasLeftIcon", "hasRightIcon"]);
83
- const [showPassword, setShowPassword] = createSignal(false);
84
- const resolvedType = () => localProps.passwordReveal && showPassword() ? "text" : localProps.type ?? "text";
85
- const inputClass = inputVariants({
86
- ...variantProps,
87
- hasLeftIcon: !!localProps.leftIcon,
88
- hasRightIcon: !!(localProps.rightIcon || localProps.passwordReveal),
89
- class: localProps.class
90
- });
91
- return (() => {
92
- var _el$ = _tmpl$32(), _el$3 = _el$.firstChild;
93
- className(_el$, inputWrapperClass);
94
- insert(_el$, createComponent(Show, {
95
- get when() {
96
- return localProps.leftIcon;
97
- },
98
- get children() {
99
- var _el$2 = _tmpl$3();
100
- className(_el$2, iconLeftClass);
101
- insert(_el$2, () => localProps.leftIcon);
102
- return _el$2;
103
- }
104
- }), _el$3);
105
- className(_el$3, inputClass);
106
- spread(_el$3, mergeProps$1({
107
- get type() {
108
- return resolvedType();
109
- },
110
- get ["aria-invalid"]() {
111
- return variantProps.color === "danger" ? "true" : void 0;
112
- },
113
- get value() {
114
- return localProps.value;
115
- },
116
- get onInput() {
117
- return localProps.onInput;
118
- },
119
- get name() {
120
- return localProps.name;
121
- }
122
- }, otherProps), false, false);
123
- insert(_el$, createComponent(Show, {
124
- get when() {
125
- return localProps.passwordReveal && !localProps.rightIcon;
126
- },
127
- get children() {
128
- var _el$4 = _tmpl$22();
129
- _el$4.$$click = () => setShowPassword((p) => !p);
130
- className(_el$4, iconButtonClass);
131
- insert(_el$4, createComponent(EyeIcon_default, {
132
- get invisible() {
133
- return showPassword();
134
- }
135
- }));
136
- return _el$4;
137
- }
138
- }), null);
139
- insert(_el$, createComponent(Show, {
140
- get when() {
141
- return localProps.rightIcon && !localProps.passwordReveal;
142
- },
143
- get children() {
144
- var _el$5 = _tmpl$3();
145
- className(_el$5, iconRightClass);
146
- insert(_el$5, () => localProps.rightIcon);
147
- return _el$5;
148
- }
149
- }), null);
150
- return _el$;
151
- })();
152
- };
153
- var Input_default = Input;
154
- delegateEvents(["click"]);
155
-
156
- // src/components/input/index.ts
157
- var input_default = Input_default;
158
-
159
- export { EyeIcon_default, input_default };
@@ -1,173 +0,0 @@
1
- import { cva, classes } from './HKS7ET6T.js';
2
- import { template, className, spread, mergeProps, insert, createComponent, memo, effect, setAttribute } from 'solid-js/web';
3
- import { splitProps, createMemo, untrack, Show } from 'solid-js';
4
-
5
- // src/components/select/Select.styles.ts
6
- var selectVariants = cva(
7
- [
8
- "flex items-center appearance-none",
9
- "border outline-none",
10
- "transition bg-white text-gray-700",
11
- "disabled:opacity-50 disabled:cursor-not-allowed",
12
- "pl-3"
13
- // margen izquierdo por defecto
14
- ],
15
- {
16
- variants: {
17
- size: {
18
- sm: "text-sm py-1 px-2",
19
- md: "text-base py-2 px-3",
20
- lg: "text-lg py-2 px-4"
21
- },
22
- color: {
23
- primary: "border border-gray-300 focus:border-primary",
24
- info: "border border-blue-500 focus:border-blue-600",
25
- success: "border border-green-500 focus:border-green-600",
26
- warning: "border border-yellow-500 focus:border-yellow-600",
27
- danger: "border border-red-500 focus:border-red-600"
28
- },
29
- loading: {
30
- true: "cursor-wait opacity-75",
31
- false: ""
32
- },
33
- expanded: {
34
- true: "w-full",
35
- false: "w-fit"
36
- },
37
- rounded: {
38
- true: "rounded",
39
- false: "rounded-none"
40
- }
41
- },
42
- defaultVariants: {
43
- size: "md",
44
- color: "primary",
45
- loading: false,
46
- expanded: false,
47
- rounded: false
48
- }
49
- }
50
- );
51
- var wrapperClass = "relative w-full group cursor-pointer";
52
- var selectPaddingClass = "w-full pr-8";
53
- var caretIconBaseClass = "absolute right-2 top-1/2 -translate-y-1/2 w-4 h-4 pointer-events-none transition-colors";
54
- var spinnerIconBaseClass = "absolute right-2 top-1/2 -translate-y-1/2 w-4 h-4 animate-spin pointer-events-none";
55
- var getIconColor = (color) => {
56
- switch (color) {
57
- case "success":
58
- return "text-green-500 group-hover:text-green-600";
59
- case "danger":
60
- return "text-red-500 group-hover:text-red-600";
61
- case "warning":
62
- return "text-yellow-500 group-hover:text-yellow-600";
63
- case "info":
64
- return "text-blue-500 group-hover:text-blue-600";
65
- case "primary":
66
- default:
67
- return "text-gray-500 group-hover:text-gray-700";
68
- }
69
- };
70
- var getSpinnerColor = (color) => {
71
- switch (color) {
72
- case "success":
73
- return "text-green-500";
74
- case "danger":
75
- return "text-red-500";
76
- case "warning":
77
- return "text-yellow-500";
78
- case "info":
79
- return "text-blue-500";
80
- case "primary":
81
- default:
82
- return "text-gray-500";
83
- }
84
- };
85
- var _tmpl$ = /* @__PURE__ */ template(`<svg fill=none stroke=currentColor stroke-width=2 viewBox="0 0 24 24"><path d="M6 9l6 6 6-6">`);
86
- var CaretDownIcon = (props) => (() => {
87
- var _el$ = _tmpl$();
88
- effect(() => setAttribute(_el$, "class", `${caretIconBaseClass} ${props.class ?? ""}`));
89
- return _el$;
90
- })();
91
- var CaretDownIcon_default = CaretDownIcon;
92
- var _tmpl$2 = /* @__PURE__ */ template(`<svg xmlns=http://www.w3.org/2000/svg fill=none viewBox="0 0 24 24"stroke-width=2><circle class=opacity-25 cx=12 cy=12 r=10 stroke=currentColor></circle><path class=opacity-75 fill=currentColor d="M4 12a8 8 0 018-8v4a4 4 0 00-4 4H4z">`);
93
- var SpinnerIcon = (props) => (() => {
94
- var _el$ = _tmpl$2();
95
- effect(() => setAttribute(_el$, "class", `${spinnerIconBaseClass} ${props.class ?? ""}`));
96
- return _el$;
97
- })();
98
- var SpinnerIcon_default = SpinnerIcon;
99
-
100
- // src/components/select/Select.tsx
101
- var _tmpl$3 = /* @__PURE__ */ template(`<option value disabled hidden>`);
102
- var _tmpl$22 = /* @__PURE__ */ template(`<div><select>`);
103
- var Select = (props) => {
104
- const [localProps, variantProps, otherProps] = splitProps(props, ["placeholder", "value", "nativeSize", "onChange", "onFocus", "onBlur"], ["class", ...selectVariants.variantKeys]);
105
- const empty = createMemo(() => untrack(() => localProps.value === null || localProps.value === void 0));
106
- const selectClass = createMemo(() => classes(selectVariants(variantProps), variantProps.class, selectPaddingClass));
107
- return (() => {
108
- var _el$ = _tmpl$22(), _el$2 = _el$.firstChild;
109
- className(_el$, wrapperClass);
110
- spread(_el$2, mergeProps({
111
- get ["class"]() {
112
- return selectClass();
113
- },
114
- get size() {
115
- return localProps.nativeSize;
116
- },
117
- get value() {
118
- return localProps.value;
119
- },
120
- get onChange() {
121
- return localProps.onChange;
122
- },
123
- get onFocus() {
124
- return localProps.onFocus;
125
- },
126
- get onBlur() {
127
- return localProps.onBlur;
128
- }
129
- }, otherProps), false, true);
130
- insert(_el$2, createComponent(Show, {
131
- get when() {
132
- return memo(() => !!localProps.placeholder)() && empty();
133
- },
134
- get children() {
135
- var _el$3 = _tmpl$3();
136
- insert(_el$3, () => localProps.placeholder);
137
- return _el$3;
138
- }
139
- }), null);
140
- insert(_el$2, () => props.children, null);
141
- insert(_el$, createComponent(Show, {
142
- get when() {
143
- return variantProps.loading;
144
- },
145
- get children() {
146
- return createComponent(SpinnerIcon_default, {
147
- get ["class"]() {
148
- return `${spinnerIconBaseClass} ${getSpinnerColor(variantProps.color)}`;
149
- }
150
- });
151
- }
152
- }), null);
153
- insert(_el$, createComponent(Show, {
154
- get when() {
155
- return !variantProps.loading;
156
- },
157
- get children() {
158
- return createComponent(CaretDownIcon_default, {
159
- get ["class"]() {
160
- return `${caretIconBaseClass} ${getIconColor(variantProps.color)}`;
161
- }
162
- });
163
- }
164
- }), null);
165
- return _el$;
166
- })();
167
- };
168
- var Select_default = Select;
169
-
170
- // src/components/select/index.ts
171
- var select_default = Select_default;
172
-
173
- export { select_default };
@@ -1,111 +0,0 @@
1
- import { cva } from './HKS7ET6T.js';
2
- import { template, spread, insert, createComponent, memo, effect, className } from 'solid-js/web';
3
- import { splitProps, Show } from 'solid-js';
4
-
5
- // src/components/tooltip/Tooltip.styles.ts
6
- var tooltipVariants = cva(
7
- [
8
- "absolute z-10 px-3 py-1 text-white text-sm",
9
- "opacity-0 group-hover:opacity-100",
10
- "pointer-events-none transition-opacity duration-200",
11
- "max-w-xs break-words",
12
- "after:content-[''] after:absolute after:w-2 after:h-2 after:rotate-45 after:bg-inherit"
13
- ].join(" "),
14
- {
15
- variants: {
16
- type: {
17
- info: "bg-blue-500",
18
- success: "bg-green-500",
19
- warning: "bg-yellow-500",
20
- danger: "bg-red-500",
21
- primary: "bg-indigo-500",
22
- gray: "bg-gray-700"
23
- },
24
- size: {
25
- sm: "text-xs",
26
- md: "text-sm",
27
- lg: "text-base"
28
- },
29
- rounded: {
30
- true: "rounded",
31
- false: "rounded-none"
32
- },
33
- dashed: {
34
- true: "border border-white border-dashed",
35
- false: ""
36
- },
37
- multilined: {
38
- true: "whitespace-pre-wrap",
39
- false: "whitespace-nowrap overflow-hidden text-ellipsis"
40
- },
41
- animated: {
42
- true: "transition-opacity duration-300 ease-in-out",
43
- false: ""
44
- },
45
- position: {
46
- top: "bottom-full left-1/2 -translate-x-1/2 mb-1 after:top-full after:left-1/2 after:-translate-x-1/2 after:-mt-1",
47
- bottom: "top-full left-1/2 -translate-x-1/2 mt-1 after:bottom-full after:left-1/2 after:-translate-x-1/2 after:-mb-1",
48
- left: "right-full top-1/2 -translate-y-1/2 mr-1 after:left-full after:top-1/2 after:-translate-y-1/2 after:-ml-1",
49
- right: "left-full top-1/2 -translate-y-1/2 ml-1 after:right-full after:top-1/2 after:-translate-y-1/2 after:-mr-1"
50
- }
51
- },
52
- defaultVariants: {
53
- type: "primary",
54
- size: "md",
55
- rounded: true,
56
- dashed: false,
57
- multilined: false,
58
- animated: true,
59
- position: "top"
60
- }
61
- }
62
- );
63
-
64
- // src/components/tooltip/Tooltip.tsx
65
- var _tmpl$ = /* @__PURE__ */ template(`<span>`);
66
- var _tmpl$2 = /* @__PURE__ */ template(`<span class="relative inline-block group">`);
67
- var _tmpl$3 = /* @__PURE__ */ template(`<div class=block>`);
68
- var Tooltip = (props) => {
69
- const [local, variantProps, otherProps] = splitProps(props, ["label", "delay", "always", "children"], ["type", "size", "position", "rounded", "dashed", "multilined", "animated"]);
70
- return (() => {
71
- var _el$ = _tmpl$2();
72
- spread(_el$, otherProps, false, true);
73
- insert(_el$, () => local.children, null);
74
- insert(_el$, createComponent(Show, {
75
- get when() {
76
- return local.label;
77
- },
78
- get children() {
79
- var _el$2 = _tmpl$();
80
- _el$2.style.setProperty("pointer-events", "none");
81
- insert(_el$2, (() => {
82
- var _c$ = memo(() => !!variantProps.multilined);
83
- return () => _c$() ? local.label.split("\n").map((line, index) => (() => {
84
- var _el$3 = _tmpl$3();
85
- insert(_el$3, line);
86
- return _el$3;
87
- })()) : local.label;
88
- })());
89
- effect((_p$) => {
90
- var _v$ = tooltipVariants(variantProps), _v$2 = `${local.delay ?? 0}ms`, _v$3 = local.always ? 1 : void 0;
91
- _v$ !== _p$.e && className(_el$2, _p$.e = _v$);
92
- _v$2 !== _p$.t && ((_p$.t = _v$2) != null ? _el$2.style.setProperty("transition-delay", _v$2) : _el$2.style.removeProperty("transition-delay"));
93
- _v$3 !== _p$.a && ((_p$.a = _v$3) != null ? _el$2.style.setProperty("opacity", _v$3) : _el$2.style.removeProperty("opacity"));
94
- return _p$;
95
- }, {
96
- e: void 0,
97
- t: void 0,
98
- a: void 0
99
- });
100
- return _el$2;
101
- }
102
- }), null);
103
- return _el$;
104
- })();
105
- };
106
- var Tooltip_default = Tooltip;
107
-
108
- // src/components/tooltip/index.ts
109
- var tooltip_default = Tooltip_default;
110
-
111
- export { tooltip_default };
@@ -1,156 +0,0 @@
1
- import {
2
- cva
3
- } from "./P7WPLZNA.jsx";
4
-
5
- // src/components/input/Input.tsx
6
- import {
7
- createSignal,
8
- mergeProps,
9
- Show as Show2,
10
- splitProps
11
- } from "solid-js";
12
-
13
- // src/components/input/Input.styles.ts
14
- var inputWrapperClass = "relative flex items-center";
15
- var inputVariants = cva(
16
- [
17
- "block w-full appearance-none outline-none bg-transparent",
18
- "border transition-colors duration-200",
19
- "disabled:opacity-50 disabled:cursor-not-allowed"
20
- ],
21
- {
22
- variants: {
23
- color: {
24
- danger: "border-red-500 text-red-600",
25
- success: "border-green-500 text-green-600",
26
- warning: "border-orange-500 text-orange-600"
27
- },
28
- rounded: {
29
- true: "rounded-full",
30
- false: "rounded-md"
31
- },
32
- expanded: {
33
- true: "w-full",
34
- false: "w-fit"
35
- },
36
- loading: {
37
- true: "opacity-50",
38
- false: ""
39
- },
40
- hasLeftIcon: {
41
- true: "pl-10",
42
- false: "pl-4"
43
- },
44
- hasRightIcon: {
45
- true: "pr-10",
46
- false: "pr-4"
47
- }
48
- },
49
- defaultVariants: {
50
- color: void 0,
51
- rounded: false,
52
- expanded: true,
53
- loading: false,
54
- hasLeftIcon: false,
55
- hasRightIcon: false
56
- }
57
- }
58
- );
59
- var iconLeftClass = "absolute left-3 top-1/2 -translate-y-1/2 pointer-events-none text-gray-400";
60
- var iconRightClass = "absolute right-3 top-1/2 -translate-y-1/2 text-gray-400";
61
- var iconButtonClass = "absolute right-3 top-1/2 -translate-y-1/2 text-gray-500";
62
-
63
- // src/components/input/EyeIcon.tsx
64
- import { Show } from "solid-js";
65
- var EyeIcon = (props) => {
66
- return <Show when={props.invisible} fallback={<EyeOpen />}>
67
- <EyeInvisible />
68
- </Show>;
69
- };
70
- var EyeInvisible = () => <svg
71
- viewBox="64 64 896 896"
72
- tabIndex="-1"
73
- width="1em"
74
- height="1em"
75
- fill="currentColor"
76
- aria-hidden="true"
77
- >
78
- <path d="M942.2 486.2Q889.47 375.11 816.7 305l-50.88 50.88C807.31 395.53 843.45 447.4 874.7 512 791.5 684.2 673.4 766 512 766q-72.67 0-133.87-22.38L323 798.75Q408 838 512 838q288.3 0 430.2-300.3a60.29 60.29 0 000-51.5zm-63.57-320.64L836 122.88a8 8 0 00-11.32 0L715.31 232.2Q624.86 186 512 186q-288.3 0-430.2 300.3a60.3 60.3 0 000 51.5q56.69 119.4 136.5 191.41L112.48 835a8 8 0 000 11.31L155.17 889a8 8 0 0011.31 0l712.15-712.12a8 8 0 000-11.32zM149.3 512C232.6 339.8 350.7 258 512 258c54.54 0 104.13 9.36 149.12 28.39l-70.3 70.3a176 176 0 00-238.13 238.13l-83.42 83.42C223.1 637.49 183.3 582.28 149.3 512zm246.7 0a112.11 112.11 0 01146.2-106.69L401.31 546.2A112 112 0 01396 512z" />
79
- <path d="M508 624c-3.46 0-6.87-.16-10.25-.47l-52.82 52.82a176.09 176.09 0 00227.42-227.42l-52.82 52.82c.31 3.38.47 6.79.47 10.25a111.94 111.94 0 01-112 112z" />
80
- </svg>;
81
- var EyeOpen = () => <svg
82
- viewBox="64 64 896 896"
83
- tabIndex="-1"
84
- width="1em"
85
- height="1em"
86
- fill="currentColor"
87
- aria-hidden="true"
88
- >
89
- <path d="M942.2 486.2C847.4 286.5 704.1 186 512 186c-192.2 0-335.4 100.5-430.2 300.3a60.3 60.3 0 000 51.5C176.6 737.5 319.9 838 512 838c192.2 0 335.4-100.5 430.2-300.3 7.7-16.2 7.7-35 0-51.5zM512 766c-161.3 0-279.4-81.8-362.7-254C232.6 339.8 350.7 258 512 258c161.3 0 279.4 81.8 362.7 254C791.5 684.2 673.4 766 512 766zm-4-430c-97.2 0-176 78.8-176 176s78.8 176 176 176 176-78.8 176-176-78.8-176-176-176zm0 288c-61.9 0-112-50.1-112-112s50.1-112 112-112 112 50.1 112 112-50.1 112-112 112z" />
90
- </svg>;
91
- var EyeIcon_default = EyeIcon;
92
-
93
- // src/components/input/Input.tsx
94
- var Input = (props) => {
95
- const defaultedProps = mergeProps({ type: "text", placeholder: "" }, props);
96
- const [localProps, variantProps, otherProps] = splitProps(
97
- defaultedProps,
98
- [
99
- "type",
100
- "passwordReveal",
101
- "leftIcon",
102
- "rightIcon",
103
- "class",
104
- "value",
105
- "onInput",
106
- "name"
107
- ],
108
- ["color", "rounded", "expanded", "loading", "hasLeftIcon", "hasRightIcon"]
109
- );
110
- const [showPassword, setShowPassword] = createSignal(false);
111
- const resolvedType = () => localProps.passwordReveal && showPassword() ? "text" : localProps.type ?? "text";
112
- const inputClass = inputVariants({
113
- ...variantProps,
114
- hasLeftIcon: !!localProps.leftIcon,
115
- hasRightIcon: !!(localProps.rightIcon || localProps.passwordReveal),
116
- class: localProps.class
117
- });
118
- return <div class={inputWrapperClass}>
119
- <Show2 when={localProps.leftIcon}>
120
- <span class={iconLeftClass}>{localProps.leftIcon}</span>
121
- </Show2>
122
-
123
- <input
124
- type={resolvedType()}
125
- class={inputClass}
126
- aria-invalid={variantProps.color === "danger" ? "true" : void 0}
127
- value={localProps.value}
128
- onInput={localProps.onInput}
129
- name={localProps.name}
130
- {...otherProps}
131
- />
132
-
133
- <Show2 when={localProps.passwordReveal && !localProps.rightIcon}>
134
- <button
135
- type="button"
136
- onClick={() => setShowPassword((p) => !p)}
137
- class={iconButtonClass}
138
- >
139
- <EyeIcon_default invisible={showPassword()} />
140
- </button>
141
- </Show2>
142
-
143
- <Show2 when={localProps.rightIcon && !localProps.passwordReveal}>
144
- <span class={iconRightClass}>{localProps.rightIcon}</span>
145
- </Show2>
146
- </div>;
147
- };
148
- var Input_default = Input;
149
-
150
- // src/components/input/index.ts
151
- var input_default = Input_default;
152
-
153
- export {
154
- EyeIcon_default,
155
- input_default
156
- };