rocksolidjs 0.1.0

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 (347) hide show
  1. package/LICENSE.txt +21 -0
  2. package/README.md +0 -0
  3. package/dist/Accordion/Accordion.d.ts +12 -0
  4. package/dist/Accordion/Accordion.js +1 -0
  5. package/dist/Accordion/index.d.ts +2 -0
  6. package/dist/Accordion/index.js +1 -0
  7. package/dist/Accordion/style.d.ts +4 -0
  8. package/dist/Accordion/style.js +1 -0
  9. package/dist/AccordionContext/AccordionContext.d.ts +10 -0
  10. package/dist/AccordionContext/AccordionContext.js +1 -0
  11. package/dist/AccordionContext/index.d.ts +1 -0
  12. package/dist/AccordionContext/index.js +1 -0
  13. package/dist/AccordionDetails/AccordionDetails.d.ts +8 -0
  14. package/dist/AccordionDetails/AccordionDetails.js +1 -0
  15. package/dist/AccordionDetails/index.d.ts +2 -0
  16. package/dist/AccordionDetails/index.js +1 -0
  17. package/dist/AccordionDetails/style.d.ts +64 -0
  18. package/dist/AccordionDetails/style.js +1 -0
  19. package/dist/AccordionSummary/AccordionSummary.d.ts +15 -0
  20. package/dist/AccordionSummary/AccordionSummary.js +1 -0
  21. package/dist/AccordionSummary/index.d.ts +2 -0
  22. package/dist/AccordionSummary/index.js +1 -0
  23. package/dist/AccordionSummary/style.d.ts +4 -0
  24. package/dist/AccordionSummary/style.js +1 -0
  25. package/dist/Alert/Alert.d.ts +26 -0
  26. package/dist/Alert/Alert.js +1 -0
  27. package/dist/Alert/index.d.ts +2 -0
  28. package/dist/Alert/index.js +1 -0
  29. package/dist/Alert/style.d.ts +82 -0
  30. package/dist/Alert/style.js +1 -0
  31. package/dist/Avatar/Avatar.d.ts +20 -0
  32. package/dist/Avatar/Avatar.js +1 -0
  33. package/dist/Avatar/index.d.ts +2 -0
  34. package/dist/Avatar/index.js +1 -0
  35. package/dist/Avatar/style.d.ts +130 -0
  36. package/dist/Avatar/style.js +1 -0
  37. package/dist/Backdrop/Backdrop.d.ts +7 -0
  38. package/dist/Backdrop/Backdrop.js +1 -0
  39. package/dist/Backdrop/index.d.ts +2 -0
  40. package/dist/Backdrop/index.js +1 -0
  41. package/dist/Backdrop/style.d.ts +4 -0
  42. package/dist/Backdrop/style.js +1 -0
  43. package/dist/Badge/Badge.d.ts +21 -0
  44. package/dist/Badge/Badge.js +1 -0
  45. package/dist/Badge/index.d.ts +2 -0
  46. package/dist/Badge/index.js +1 -0
  47. package/dist/Badge/style.d.ts +214 -0
  48. package/dist/Badge/style.js +1 -0
  49. package/dist/Breadcrumbs/Breadcrumbs.d.ts +14 -0
  50. package/dist/Breadcrumbs/Breadcrumbs.js +1 -0
  51. package/dist/Breadcrumbs/index.d.ts +2 -0
  52. package/dist/Breadcrumbs/index.js +1 -0
  53. package/dist/Breadcrumbs/style.d.ts +64 -0
  54. package/dist/Breadcrumbs/style.js +1 -0
  55. package/dist/Button/Button.d.ts +24 -0
  56. package/dist/Button/Button.js +1 -0
  57. package/dist/Button/index.d.ts +2 -0
  58. package/dist/Button/index.js +1 -0
  59. package/dist/Button/style.d.ts +238 -0
  60. package/dist/Button/style.js +1 -0
  61. package/dist/Card/Card.d.ts +10 -0
  62. package/dist/Card/Card.js +1 -0
  63. package/dist/Card/index.d.ts +2 -0
  64. package/dist/Card/index.js +1 -0
  65. package/dist/Card/style.d.ts +46 -0
  66. package/dist/Card/style.js +1 -0
  67. package/dist/CardContent/CardContent.d.ts +6 -0
  68. package/dist/CardContent/CardContent.js +1 -0
  69. package/dist/CardContent/index.d.ts +2 -0
  70. package/dist/CardContent/index.js +1 -0
  71. package/dist/CardContent/style.d.ts +4 -0
  72. package/dist/CardContent/style.js +1 -0
  73. package/dist/CardDescription/CardDescription.d.ts +8 -0
  74. package/dist/CardDescription/CardDescription.js +1 -0
  75. package/dist/CardDescription/index.d.ts +2 -0
  76. package/dist/CardDescription/index.js +1 -0
  77. package/dist/CardDescription/style.d.ts +4 -0
  78. package/dist/CardDescription/style.js +1 -0
  79. package/dist/CardFooter/CardFooter.d.ts +6 -0
  80. package/dist/CardFooter/CardFooter.js +1 -0
  81. package/dist/CardFooter/index.d.ts +2 -0
  82. package/dist/CardFooter/index.js +1 -0
  83. package/dist/CardFooter/style.d.ts +4 -0
  84. package/dist/CardFooter/style.js +1 -0
  85. package/dist/CardHeader/CardHeader.d.ts +6 -0
  86. package/dist/CardHeader/CardHeader.js +1 -0
  87. package/dist/CardHeader/index.d.ts +2 -0
  88. package/dist/CardHeader/index.js +1 -0
  89. package/dist/CardHeader/style.d.ts +4 -0
  90. package/dist/CardHeader/style.js +1 -0
  91. package/dist/CardTitle/CardTitle.d.ts +8 -0
  92. package/dist/CardTitle/CardTitle.js +1 -0
  93. package/dist/CardTitle/index.d.ts +2 -0
  94. package/dist/CardTitle/index.js +1 -0
  95. package/dist/CardTitle/style.d.ts +4 -0
  96. package/dist/CardTitle/style.js +1 -0
  97. package/dist/Checkbox/Checkbox.d.ts +18 -0
  98. package/dist/Checkbox/Checkbox.js +1 -0
  99. package/dist/Checkbox/index.d.ts +2 -0
  100. package/dist/Checkbox/index.js +1 -0
  101. package/dist/Checkbox/style.d.ts +88 -0
  102. package/dist/Checkbox/style.js +1 -0
  103. package/dist/Chip/Chip.d.ts +25 -0
  104. package/dist/Chip/Chip.js +1 -0
  105. package/dist/Chip/index.d.ts +2 -0
  106. package/dist/Chip/index.js +1 -0
  107. package/dist/Chip/style.d.ts +298 -0
  108. package/dist/Chip/style.js +1 -0
  109. package/dist/Dialog/Dialog.d.ts +20 -0
  110. package/dist/Dialog/Dialog.js +1 -0
  111. package/dist/Dialog/index.d.ts +2 -0
  112. package/dist/Dialog/index.js +1 -0
  113. package/dist/Dialog/style.d.ts +34 -0
  114. package/dist/Dialog/style.js +1 -0
  115. package/dist/DialogActions/DialogActions.d.ts +7 -0
  116. package/dist/DialogActions/DialogActions.js +1 -0
  117. package/dist/DialogActions/index.d.ts +2 -0
  118. package/dist/DialogActions/index.js +1 -0
  119. package/dist/DialogActions/style.d.ts +4 -0
  120. package/dist/DialogActions/style.js +1 -0
  121. package/dist/DialogContent/DialogContent.d.ts +7 -0
  122. package/dist/DialogContent/DialogContent.js +1 -0
  123. package/dist/DialogContent/index.d.ts +2 -0
  124. package/dist/DialogContent/index.js +1 -0
  125. package/dist/DialogContent/style.d.ts +4 -0
  126. package/dist/DialogContent/style.js +1 -0
  127. package/dist/DialogTitle/DialogTitle.d.ts +8 -0
  128. package/dist/DialogTitle/DialogTitle.js +1 -0
  129. package/dist/DialogTitle/index.d.ts +2 -0
  130. package/dist/DialogTitle/index.js +1 -0
  131. package/dist/DialogTitle/style.d.ts +4 -0
  132. package/dist/DialogTitle/style.js +1 -0
  133. package/dist/Divider/Divider.d.ts +11 -0
  134. package/dist/Divider/Divider.js +1 -0
  135. package/dist/Divider/index.d.ts +2 -0
  136. package/dist/Divider/index.js +1 -0
  137. package/dist/Divider/style.d.ts +34 -0
  138. package/dist/Divider/style.js +1 -0
  139. package/dist/IconButton/IconButton.d.ts +6 -0
  140. package/dist/IconButton/IconButton.js +1 -0
  141. package/dist/IconButton/index.d.ts +2 -0
  142. package/dist/IconButton/index.js +1 -0
  143. package/dist/IconButton/style.d.ts +40 -0
  144. package/dist/IconButton/style.js +1 -0
  145. package/dist/Input/Input.d.ts +27 -0
  146. package/dist/Input/Input.js +1 -0
  147. package/dist/Input/index.d.ts +2 -0
  148. package/dist/Input/index.js +1 -0
  149. package/dist/Input/style.d.ts +232 -0
  150. package/dist/Input/style.js +1 -0
  151. package/dist/Label/Label.d.ts +16 -0
  152. package/dist/Label/Label.js +1 -0
  153. package/dist/Label/index.d.ts +2 -0
  154. package/dist/Label/index.js +1 -0
  155. package/dist/Label/style.d.ts +118 -0
  156. package/dist/Label/style.js +1 -0
  157. package/dist/Link/Link.d.ts +15 -0
  158. package/dist/Link/Link.js +1 -0
  159. package/dist/Link/index.d.ts +2 -0
  160. package/dist/Link/index.js +1 -0
  161. package/dist/Link/style.d.ts +40 -0
  162. package/dist/Link/style.js +1 -0
  163. package/dist/Progress/Progress.d.ts +21 -0
  164. package/dist/Progress/Progress.js +1 -0
  165. package/dist/Progress/index.d.ts +2 -0
  166. package/dist/Progress/index.js +1 -0
  167. package/dist/Progress/style.d.ts +112 -0
  168. package/dist/Progress/style.js +1 -0
  169. package/dist/Radio/Radio.d.ts +19 -0
  170. package/dist/Radio/Radio.js +1 -0
  171. package/dist/Radio/index.d.ts +2 -0
  172. package/dist/Radio/index.js +1 -0
  173. package/dist/Radio/style.d.ts +76 -0
  174. package/dist/Radio/style.js +1 -0
  175. package/dist/RadioGroup/RadioGroup.d.ts +10 -0
  176. package/dist/RadioGroup/RadioGroup.js +1 -0
  177. package/dist/RadioGroup/index.d.ts +2 -0
  178. package/dist/RadioGroup/index.js +1 -0
  179. package/dist/RadioGroupContext/RadioGroupContext.d.ts +8 -0
  180. package/dist/RadioGroupContext/RadioGroupContext.js +1 -0
  181. package/dist/RadioGroupContext/index.d.ts +1 -0
  182. package/dist/RadioGroupContext/index.js +1 -0
  183. package/dist/Select/Select.d.ts +22 -0
  184. package/dist/Select/Select.js +1 -0
  185. package/dist/Select/index.d.ts +2 -0
  186. package/dist/Select/index.js +1 -0
  187. package/dist/Select/style.d.ts +124 -0
  188. package/dist/Select/style.js +1 -0
  189. package/dist/Skeleton/Skeleton.d.ts +9 -0
  190. package/dist/Skeleton/Skeleton.js +1 -0
  191. package/dist/Skeleton/index.d.ts +2 -0
  192. package/dist/Skeleton/index.js +1 -0
  193. package/dist/Skeleton/style.d.ts +34 -0
  194. package/dist/Skeleton/style.js +1 -0
  195. package/dist/Spinner/Spinner.d.ts +13 -0
  196. package/dist/Spinner/Spinner.js +1 -0
  197. package/dist/Spinner/index.d.ts +2 -0
  198. package/dist/Spinner/index.js +1 -0
  199. package/dist/Spinner/style.d.ts +112 -0
  200. package/dist/Spinner/style.js +1 -0
  201. package/dist/Switch/Switch.d.ts +23 -0
  202. package/dist/Switch/Switch.js +1 -0
  203. package/dist/Switch/index.d.ts +2 -0
  204. package/dist/Switch/index.js +1 -0
  205. package/dist/Switch/style.d.ts +226 -0
  206. package/dist/Switch/style.js +1 -0
  207. package/dist/Tab/Tab.d.ts +18 -0
  208. package/dist/Tab/Tab.js +1 -0
  209. package/dist/Tab/index.d.ts +2 -0
  210. package/dist/Tab/index.js +1 -0
  211. package/dist/Tab/style.d.ts +94 -0
  212. package/dist/Tab/style.js +1 -0
  213. package/dist/TabPanel/TabPanel.d.ts +7 -0
  214. package/dist/TabPanel/TabPanel.js +1 -0
  215. package/dist/TabPanel/index.d.ts +2 -0
  216. package/dist/TabPanel/index.js +1 -0
  217. package/dist/Table/Table.d.ts +7 -0
  218. package/dist/Table/Table.js +1 -0
  219. package/dist/Table/index.d.ts +2 -0
  220. package/dist/Table/index.js +1 -0
  221. package/dist/Table/style.d.ts +4 -0
  222. package/dist/Table/style.js +1 -0
  223. package/dist/TableBody/TableBody.d.ts +4 -0
  224. package/dist/TableBody/TableBody.js +1 -0
  225. package/dist/TableBody/index.d.ts +2 -0
  226. package/dist/TableBody/index.js +1 -0
  227. package/dist/TableCell/TableCell.d.ts +11 -0
  228. package/dist/TableCell/TableCell.js +1 -0
  229. package/dist/TableCell/index.d.ts +2 -0
  230. package/dist/TableCell/index.js +1 -0
  231. package/dist/TableCell/style.d.ts +70 -0
  232. package/dist/TableCell/style.js +1 -0
  233. package/dist/TableContext/TableContext.d.ts +6 -0
  234. package/dist/TableContext/TableContext.js +1 -0
  235. package/dist/TableContext/index.d.ts +1 -0
  236. package/dist/TableContext/index.js +1 -0
  237. package/dist/TableFooter/TableFooter.d.ts +4 -0
  238. package/dist/TableFooter/TableFooter.js +1 -0
  239. package/dist/TableFooter/index.d.ts +2 -0
  240. package/dist/TableFooter/index.js +1 -0
  241. package/dist/TableFooter/style.d.ts +4 -0
  242. package/dist/TableFooter/style.js +1 -0
  243. package/dist/TableHead/TableHead.d.ts +4 -0
  244. package/dist/TableHead/TableHead.js +1 -0
  245. package/dist/TableHead/index.d.ts +2 -0
  246. package/dist/TableHead/index.js +1 -0
  247. package/dist/TableHeadContext/TableHeadContext.d.ts +5 -0
  248. package/dist/TableHeadContext/TableHeadContext.js +1 -0
  249. package/dist/TableHeadContext/index.d.ts +1 -0
  250. package/dist/TableHeadContext/index.js +1 -0
  251. package/dist/TableRow/TableRow.d.ts +7 -0
  252. package/dist/TableRow/TableRow.js +1 -0
  253. package/dist/TableRow/index.d.ts +2 -0
  254. package/dist/TableRow/index.js +1 -0
  255. package/dist/TableRow/style.d.ts +34 -0
  256. package/dist/TableRow/style.js +1 -0
  257. package/dist/Tabs/Tabs.d.ts +12 -0
  258. package/dist/Tabs/Tabs.js +1 -0
  259. package/dist/Tabs/TabsContentContext.d.ts +7 -0
  260. package/dist/Tabs/TabsContentContext.js +1 -0
  261. package/dist/Tabs/index.d.ts +2 -0
  262. package/dist/Tabs/index.js +1 -0
  263. package/dist/Tabs/style.d.ts +94 -0
  264. package/dist/Tabs/style.js +1 -0
  265. package/dist/TabsContext/TabsContext.d.ts +10 -0
  266. package/dist/TabsContext/TabsContext.js +1 -0
  267. package/dist/TabsContext/context.d.ts +8 -0
  268. package/dist/TabsContext/context.js +3 -0
  269. package/dist/TabsContext/index.d.ts +2 -0
  270. package/dist/TabsContext/index.js +1 -0
  271. package/dist/Textarea/Textarea.d.ts +16 -0
  272. package/dist/Textarea/Textarea.js +1 -0
  273. package/dist/Textarea/index.d.ts +2 -0
  274. package/dist/Textarea/index.js +1 -0
  275. package/dist/Textarea/style.d.ts +160 -0
  276. package/dist/Textarea/style.js +1 -0
  277. package/dist/ThemeProvider/ThemeContext.d.ts +8 -0
  278. package/dist/ThemeProvider/ThemeContext.js +1 -0
  279. package/dist/ThemeProvider/ThemeProvider.d.ts +8 -0
  280. package/dist/ThemeProvider/ThemeProvider.js +1 -0
  281. package/dist/ThemeProvider/componentsTV.d.ts +1498 -0
  282. package/dist/ThemeProvider/componentsTV.js +1 -0
  283. package/dist/ThemeProvider/index.d.ts +3 -0
  284. package/dist/ThemeProvider/index.js +1 -0
  285. package/dist/Typography/Typography.d.ts +15 -0
  286. package/dist/Typography/Typography.js +1 -0
  287. package/dist/Typography/index.d.ts +2 -0
  288. package/dist/Typography/index.js +1 -0
  289. package/dist/Typography/style.d.ts +154 -0
  290. package/dist/Typography/style.js +1 -0
  291. package/dist/_chunks/dist-C-sN40SQ.js +1 -0
  292. package/dist/icons/Alert.d.ts +3 -0
  293. package/dist/icons/Alert.js +1 -0
  294. package/dist/icons/AngleDown.d.ts +3 -0
  295. package/dist/icons/AngleDown.js +1 -0
  296. package/dist/icons/AngleUp.d.ts +3 -0
  297. package/dist/icons/AngleUp.js +1 -0
  298. package/dist/icons/CheckboxChecked.d.ts +3 -0
  299. package/dist/icons/CheckboxChecked.js +1 -0
  300. package/dist/icons/CheckboxUnchecked.d.ts +3 -0
  301. package/dist/icons/CheckboxUnchecked.js +1 -0
  302. package/dist/icons/Checkmark.d.ts +3 -0
  303. package/dist/icons/Checkmark.js +1 -0
  304. package/dist/icons/Cross.d.ts +3 -0
  305. package/dist/icons/Cross.js +1 -0
  306. package/dist/icons/Error.d.ts +3 -0
  307. package/dist/icons/Error.js +1 -0
  308. package/dist/icons/Info.d.ts +3 -0
  309. package/dist/icons/Info.js +1 -0
  310. package/dist/icons/RadioChecked.d.ts +3 -0
  311. package/dist/icons/RadioChecked.js +1 -0
  312. package/dist/icons/RadioUnchecked.d.ts +3 -0
  313. package/dist/icons/RadioUnchecked.js +1 -0
  314. package/dist/icons/Warning.d.ts +3 -0
  315. package/dist/icons/Warning.js +1 -0
  316. package/dist/index.css +6 -0
  317. package/dist/index.d.ts +137 -0
  318. package/dist/index.js +1 -0
  319. package/dist/styles/createTheme.d.ts +4 -0
  320. package/dist/styles/createTheme.js +2 -0
  321. package/dist/styles/index.d.ts +8 -0
  322. package/dist/styles/index.js +1 -0
  323. package/dist/styles/theme/colors.d.ts +24 -0
  324. package/dist/styles/theme/colors.js +1 -0
  325. package/dist/styles/theme/disabled.d.ts +10 -0
  326. package/dist/styles/theme/disabled.js +1 -0
  327. package/dist/styles/theme/index.d.ts +20 -0
  328. package/dist/styles/theme/index.js +1 -0
  329. package/dist/styles/theme/rounded.d.ts +11 -0
  330. package/dist/styles/theme/rounded.js +1 -0
  331. package/dist/styles/theme/shadow.d.ts +10 -0
  332. package/dist/styles/theme/shadow.js +1 -0
  333. package/dist/styles/theme/themeSchema.d.ts +4 -0
  334. package/dist/styles/theme/themeSchema.js +1 -0
  335. package/dist/styles/theme/typography.d.ts +29 -0
  336. package/dist/styles/theme/typography.js +1 -0
  337. package/dist/styles/theme/utilities.d.ts +7 -0
  338. package/dist/styles/theme/utilities.js +1 -0
  339. package/dist/styles/useTheme.d.ts +2 -0
  340. package/dist/styles/useTheme.js +1 -0
  341. package/dist/utils/asVariant.d.ts +2 -0
  342. package/dist/utils/asVariant.js +1 -0
  343. package/dist/utils/cn.d.ts +2 -0
  344. package/dist/utils/cn.js +1 -0
  345. package/dist/utils/typedKeys.d.ts +2 -0
  346. package/dist/utils/typedKeys.js +1 -0
  347. package/package.json +257 -0
@@ -0,0 +1 @@
1
+ import{n as e}from"../_chunks/dist-C-sN40SQ.js";import t from"../styles/theme/index.js";var n=(n=t)=>e({base:[`px-4 py-2`,n.typography.variants.body2,n.typography.colors.textSecondary]}),r=n();export{n as cardContent,r as default};
@@ -0,0 +1,8 @@
1
+ import { JSXElement } from 'solid-js';
2
+ import { TypographyProps } from '../Typography/Typography';
3
+ export type CardDescriptionProps = {
4
+ class?: string;
5
+ children?: JSXElement;
6
+ } & TypographyProps;
7
+ declare const CardDescription: (props: CardDescriptionProps) => import("solid-js").JSX.Element;
8
+ export default CardDescription;
@@ -0,0 +1 @@
1
+ import e from"../utils/cn.js";import t from"./style.js";import{useThemeContext as n}from"../ThemeProvider/ThemeContext.js";import"../ThemeProvider/index.js";import r from"../Typography/Typography.js";import{createComponent as i,mergeProps as a}from"solid-js/web";import{createMemo as o,splitProps as s}from"solid-js";var c=c=>{let[l,u]=s(c,[`class`,`children`]),d=n(),f=o(()=>d?d.componentsTV.cardDescription():t());return i(r,a({as:`p`,color:`textSecondary`},u,{get class(){return e(f(),l.class)},get children(){return l.children}}))};export{c as default};
@@ -0,0 +1,2 @@
1
+ export { default } from './CardDescription';
2
+ export * from './CardDescription';
@@ -0,0 +1 @@
1
+ import"./CardDescription.js";
@@ -0,0 +1,4 @@
1
+ import { Theme } from '../styles/theme';
2
+ export declare const cardDescription: (theme?: Theme) => import('tailwind-variants').TVReturnType<{} | {} | {}, undefined, string[], {} | {}, undefined, import('tailwind-variants').TVReturnTypeLike<unknown, undefined>>;
3
+ declare const _default: import('tailwind-variants').TVReturnType<{} | {} | {}, undefined, string[], {} | {}, undefined, import('tailwind-variants').TVReturnTypeLike<unknown, undefined>>;
4
+ export default _default;
@@ -0,0 +1 @@
1
+ import{n as e}from"../_chunks/dist-C-sN40SQ.js";import t from"../styles/theme/index.js";var n=(n=t)=>e({base:[`pt-1`,n.typography.variants.body2,n.typography.colors.textSecondary]}),r=n();export{n as cardDescription,r as default};
@@ -0,0 +1,6 @@
1
+ import { ComponentProps } from 'solid-js';
2
+ export type CardFooterProps = {
3
+ class?: string;
4
+ } & ComponentProps<"div">;
5
+ declare const CardFooter: (props: CardFooterProps) => import("solid-js").JSX.Element;
6
+ export default CardFooter;
@@ -0,0 +1 @@
1
+ import e from"../utils/cn.js";import t from"./style.js";import{useThemeContext as n}from"../ThemeProvider/ThemeContext.js";import"../ThemeProvider/index.js";import{insert as r,mergeProps as i,spread as a,template as o}from"solid-js/web";import{createMemo as s,splitProps as c}from"solid-js";var l=o(`<div>`),u=o=>{let[u,d]=c(o,[`children`,`class`]),f=n(),p=s(()=>f?f.componentsTV.cardFooter():t());return(()=>{var t=l();return a(t,i(d,{get class(){return e(p(),u.class)}}),!1,!0),r(t,()=>u.children),t})()};export{u as default};
@@ -0,0 +1,2 @@
1
+ export { default } from './CardFooter';
2
+ export * from './CardFooter';
@@ -0,0 +1 @@
1
+ import"./CardFooter.js";
@@ -0,0 +1,4 @@
1
+ import { Theme } from '../styles/theme';
2
+ export declare const cardFooter: (_theme?: Theme) => import('tailwind-variants').TVReturnType<{} | {} | {}, undefined, "flex items-center gap-2 px-4 py-2", {} | {}, undefined, import('tailwind-variants').TVReturnTypeLike<unknown, undefined>>;
3
+ declare const _default: import('tailwind-variants').TVReturnType<{} | {} | {}, undefined, "flex items-center gap-2 px-4 py-2", {} | {}, undefined, import('tailwind-variants').TVReturnTypeLike<unknown, undefined>>;
4
+ export default _default;
@@ -0,0 +1 @@
1
+ import{n as e}from"../_chunks/dist-C-sN40SQ.js";import t from"../styles/theme/index.js";var n=(n=t)=>e({base:`flex items-center gap-2 px-4 py-2`}),r=n();export{n as cardFooter,r as default};
@@ -0,0 +1,6 @@
1
+ import { ComponentProps } from 'solid-js';
2
+ export type CardHeaderProps = {
3
+ class?: string;
4
+ } & ComponentProps<"div">;
5
+ declare const CardHeader: (props: CardHeaderProps) => import("solid-js").JSX.Element;
6
+ export default CardHeader;
@@ -0,0 +1 @@
1
+ import e from"../utils/cn.js";import t from"./style.js";import{useThemeContext as n}from"../ThemeProvider/ThemeContext.js";import"../ThemeProvider/index.js";import{insert as r,mergeProps as i,spread as a,template as o}from"solid-js/web";import{createMemo as s,splitProps as c}from"solid-js";var l=o(`<div>`),u=o=>{let[u,d]=c(o,[`children`,`class`]),f=n(),p=s(()=>f?f.componentsTV.cardHeader():t());return(()=>{var t=l();return a(t,i(d,{get class(){return e(p(),u.class)}}),!1,!0),r(t,()=>u.children),t})()};export{u as default};
@@ -0,0 +1,2 @@
1
+ export { default } from './CardHeader';
2
+ export * from './CardHeader';
@@ -0,0 +1 @@
1
+ import"./CardHeader.js";
@@ -0,0 +1,4 @@
1
+ import { Theme } from '../styles/theme';
2
+ export declare const cardHeader: (_theme?: Theme) => import('tailwind-variants').TVReturnType<{} | {} | {}, undefined, "px-4 pt-4 pb-2", {} | {}, undefined, import('tailwind-variants').TVReturnTypeLike<unknown, undefined>>;
3
+ declare const _default: import('tailwind-variants').TVReturnType<{} | {} | {}, undefined, "px-4 pt-4 pb-2", {} | {}, undefined, import('tailwind-variants').TVReturnTypeLike<unknown, undefined>>;
4
+ export default _default;
@@ -0,0 +1 @@
1
+ import{n as e}from"../_chunks/dist-C-sN40SQ.js";import t from"../styles/theme/index.js";var n=(n=t)=>e({base:`px-4 pt-4 pb-2`}),r=n();export{n as cardHeader,r as default};
@@ -0,0 +1,8 @@
1
+ import { JSXElement } from 'solid-js';
2
+ import { TypographyProps } from '../Typography/Typography';
3
+ export type CardTitleProps = {
4
+ class?: string;
5
+ children?: JSXElement;
6
+ } & TypographyProps;
7
+ declare const CardTitle: (props: CardTitleProps) => import("solid-js").JSX.Element;
8
+ export default CardTitle;
@@ -0,0 +1 @@
1
+ import e from"../utils/cn.js";import t from"./style.js";import{useThemeContext as n}from"../ThemeProvider/ThemeContext.js";import"../ThemeProvider/index.js";import r from"../Typography/Typography.js";import{createComponent as i,mergeProps as a}from"solid-js/web";import{createMemo as o,splitProps as s}from"solid-js";var c=c=>{let[l,u]=s(c,[`class`,`children`]),d=n(),f=o(()=>d?d.componentsTV.cardTitle():t());return i(r,a({as:`h2`,color:`textPrimary`},u,{get class(){return e(f(),l.class)},get children(){return l.children}}))};export{c as default};
@@ -0,0 +1,2 @@
1
+ export { default } from './CardTitle';
2
+ export * from './CardTitle';
@@ -0,0 +1 @@
1
+ import"./CardTitle.js";
@@ -0,0 +1,4 @@
1
+ import { Theme } from '../styles/theme';
2
+ export declare const cardTitle: (theme?: Theme) => import('tailwind-variants').TVReturnType<{} | {} | {}, undefined, string[], {} | {}, undefined, import('tailwind-variants').TVReturnTypeLike<unknown, undefined>>;
3
+ declare const _default: import('tailwind-variants').TVReturnType<{} | {} | {}, undefined, string[], {} | {}, undefined, import('tailwind-variants').TVReturnTypeLike<unknown, undefined>>;
4
+ export default _default;
@@ -0,0 +1 @@
1
+ import{n as e}from"../_chunks/dist-C-sN40SQ.js";import t from"../styles/theme/index.js";var n=(n=t)=>e({base:[n.typography.variants.h5,n.typography.colors.textPrimary]}),r=n();export{n as cardTitle,r as default};
@@ -0,0 +1,18 @@
1
+ import { ComponentProps } from 'solid-js';
2
+ import { IconButtonProps } from '../IconButton';
3
+ type CheckboxSlotProps = {
4
+ base?: ComponentProps<"span">;
5
+ };
6
+ export type CheckboxProps = {
7
+ checked?: boolean;
8
+ class?: string;
9
+ color?: IconButtonProps["color"];
10
+ defaultChecked?: boolean;
11
+ disabled?: boolean;
12
+ id?: string;
13
+ onChange?: (event: Event, checked: boolean) => void;
14
+ size?: IconButtonProps["size"];
15
+ slotProps?: CheckboxSlotProps;
16
+ } & Omit<ComponentProps<"input">, "onChange">;
17
+ declare const Checkbox: (props: CheckboxProps) => import("solid-js").JSX.Element;
18
+ export default Checkbox;
@@ -0,0 +1 @@
1
+ import e from"../utils/cn.js";import t from"./style.js";import{useThemeContext as n}from"../ThemeProvider/ThemeContext.js";import"../ThemeProvider/index.js";import r from"../IconButton/IconButton.js";import"../IconButton/index.js";import i from"../icons/CheckboxChecked.js";import a from"../icons/CheckboxUnchecked.js";import{createComponent as o,memo as s,mergeProps as c,spread as l,template as u}from"solid-js/web";import{createMemo as d,createSignal as f,splitProps as p}from"solid-js";var m=u(`<input>`),h=u=>{let[h,g]=p(u,[`checked`,`class`,`color`,`defaultChecked`,`disabled`,`id`,`onChange`,`size`,`slotProps`,`children`]),_=n(),v=typeof h.checked==`boolean`,[y,b]=f(!!h.defaultChecked),x=d(()=>v?h.checked:y()),S=e=>{let t=e.currentTarget.checked;v||b(t),h.onChange?.(e,t)},C=d(()=>{let e={checked:x(),disabled:h.disabled};return _?_.componentsTV.checkbox(e):t(e)});return o(r,c(()=>h.slotProps?.base,{as:`span`,get class(){return e(C().base(),h.slotProps?.base?.class)},get color(){return h.color},get size(){return h.size},get disabled(){return h.disabled},get children(){return[s(()=>s(()=>!!x())()?o(i,{}):o(a,{})),(()=>{var t=m();return l(t,c(g,{get id(){return h.id},type:`checkbox`,get checked(){return x()},onChange:S,get disabled(){return h.disabled},get class(){return e(C().input(),h.class)}}),!1,!1),t})()]}}))};export{h as default};
@@ -0,0 +1,2 @@
1
+ export { default } from './Checkbox';
2
+ export * from './Checkbox';
@@ -0,0 +1 @@
1
+ import"./Checkbox.js";
@@ -0,0 +1,88 @@
1
+ import { Theme } from '../styles/theme';
2
+ export declare const checkbox: (theme?: Theme) => import('tailwind-variants').TVReturnType<{
3
+ checked: {
4
+ true: {};
5
+ false: {};
6
+ };
7
+ disabled: {
8
+ true: {
9
+ base: string[];
10
+ };
11
+ false: {};
12
+ };
13
+ }, {
14
+ base: string[];
15
+ input: string;
16
+ }, undefined, {
17
+ checked: {
18
+ true: {};
19
+ false: {};
20
+ };
21
+ disabled: {
22
+ true: {
23
+ base: string[];
24
+ };
25
+ false: {};
26
+ };
27
+ }, {
28
+ base: string[];
29
+ input: string;
30
+ }, import('tailwind-variants').TVReturnTypeLike<{
31
+ checked: {
32
+ true: {};
33
+ false: {};
34
+ };
35
+ disabled: {
36
+ true: {
37
+ base: string[];
38
+ };
39
+ false: {};
40
+ };
41
+ }, {
42
+ base: string[];
43
+ input: string;
44
+ }>>;
45
+ declare const _default: import('tailwind-variants').TVReturnType<{
46
+ checked: {
47
+ true: {};
48
+ false: {};
49
+ };
50
+ disabled: {
51
+ true: {
52
+ base: string[];
53
+ };
54
+ false: {};
55
+ };
56
+ }, {
57
+ base: string[];
58
+ input: string;
59
+ }, undefined, {
60
+ checked: {
61
+ true: {};
62
+ false: {};
63
+ };
64
+ disabled: {
65
+ true: {
66
+ base: string[];
67
+ };
68
+ false: {};
69
+ };
70
+ }, {
71
+ base: string[];
72
+ input: string;
73
+ }, import('tailwind-variants').TVReturnTypeLike<{
74
+ checked: {
75
+ true: {};
76
+ false: {};
77
+ };
78
+ disabled: {
79
+ true: {
80
+ base: string[];
81
+ };
82
+ false: {};
83
+ };
84
+ }, {
85
+ base: string[];
86
+ input: string;
87
+ }>>;
88
+ export default _default;
@@ -0,0 +1 @@
1
+ import{n as e}from"../_chunks/dist-C-sN40SQ.js";import t from"../styles/theme/index.js";var n=(n=t)=>e({slots:{base:[`relative`,n.focusWithin],input:`absolute inset-0 w-full h-full opacity-0 outline-none`},variants:{checked:{true:{},false:{}},disabled:{true:{base:[n.disabled.state]},false:{}}},compoundVariants:[{checked:!1,disabled:!1,class:{base:[n.typography.colors.textTertiary]}}]}),r=n();export{n as checkbox,r as default};
@@ -0,0 +1,25 @@
1
+ import { ComponentProps, JSXElement } from 'solid-js';
2
+ import { VariantProps } from 'tailwind-variants';
3
+ import { TypographyProps } from '../Typography/Typography';
4
+ import { ThemeColors } from '../styles/theme/colors';
5
+ import { default as chipDefaultStyles } from './style';
6
+ type ChipVariants = VariantProps<typeof chipDefaultStyles>;
7
+ type ChipSlotProps = {
8
+ deleteIcon?: ComponentProps<"span">;
9
+ label?: TypographyProps;
10
+ };
11
+ export type ChipProps = {
12
+ avatar?: JSXElement;
13
+ color?: keyof ThemeColors;
14
+ deleteIcon?: JSXElement;
15
+ disabled?: ChipVariants["disabled"];
16
+ icon?: JSXElement;
17
+ label: string;
18
+ onClick?: (event: MouseEvent) => void;
19
+ onDelete?: (event: MouseEvent) => void;
20
+ size?: ChipVariants["size"];
21
+ slotProps?: ChipSlotProps;
22
+ variant?: ChipVariants["variant"];
23
+ } & Omit<ComponentProps<"div">, "onClick">;
24
+ declare const Chip: (props: ChipProps) => import("solid-js").JSX.Element;
25
+ export default Chip;
@@ -0,0 +1 @@
1
+ import e from"../utils/cn.js";import t from"./style.js";import{useThemeContext as n}from"../ThemeProvider/ThemeContext.js";import"../ThemeProvider/index.js";import r from"../Typography/Typography.js";import i from"../icons/Cross.js";import{Dynamic as a,createComponent as o,insert as s,memo as c,mergeProps as l,spread as u,template as d}from"solid-js/web";import{createMemo as f,mergeProps as p,splitProps as m}from"solid-js";var h=d(`<span>`),g=d=>{let g=p({color:`default`,variant:`filled`,size:`medium`,disabled:!1},d),[_,v]=m(g,[`avatar`,`class`,`color`,`deleteIcon`,`disabled`,`icon`,`label`,`onClick`,`onDelete`,`slotProps`,`variant`,`size`,`children`]),y=n(),b=f(()=>_.avatar?_.avatar:_.icon?_.icon:null),x=f(()=>!!_.avatar),S=f(()=>typeof _.onDelete==`function`),C=f(()=>typeof _.onClick==`function`),w=e=>{_.disabled||(e.stopPropagation(),_.onDelete?.(e))},T=f(()=>{let e={color:_.color,disabled:_.disabled,variant:_.variant,size:_.size,hasAvatarElement:x(),hasDeleteIcon:S(),clickable:C()};return y?y.componentsTV.chip(e):t(e)}),E=f(()=>S()?_.deleteIcon?_.deleteIcon:o(i,{}):null);return o(a,l(v,{get component(){return C()?`button`:`div`},get"aria-disabled"(){return _.disabled},get onClick(){return c(()=>!_.disabled)()?_.onClick:void 0},get tabIndex(){return C()&&!_.disabled?0:void 0},get class(){return e(T().base(),_.class)},get children(){return[c(()=>b()),o(r,l(()=>_.slotProps?.label,{as:`span`,variant:`inherit`,get class(){return e(T().label(),_.slotProps?.label?.class)},get children(){return _.label}})),(()=>{var t=h();return u(t,l(()=>_.slotProps?.deleteIcon,{get class(){return e(T().deleteIcon(),_.slotProps?.deleteIcon?.class)},onClick:w}),!1,!0),s(t,E),t})()]}}))};export{g as default};
@@ -0,0 +1,2 @@
1
+ export { default } from './Chip';
2
+ export * from './Chip';
@@ -0,0 +1 @@
1
+ import"./Chip.js";
@@ -0,0 +1,298 @@
1
+ import { Theme } from '../styles/theme';
2
+ export declare const chip: (theme?: Theme) => import('tailwind-variants').TVReturnType<{
3
+ color: Record<"default" | "success" | "warning" | "info" | "error", {}>;
4
+ variant: {
5
+ solid: {};
6
+ filled: {};
7
+ outlined: {
8
+ base: string;
9
+ };
10
+ };
11
+ disabled: {
12
+ true: {
13
+ base: string;
14
+ };
15
+ false: {
16
+ deleteIcon: string;
17
+ };
18
+ };
19
+ size: {
20
+ small: {
21
+ base: string;
22
+ deleteIcon: string;
23
+ };
24
+ medium: {
25
+ base: string;
26
+ deleteIcon: string;
27
+ };
28
+ large: {
29
+ base: string;
30
+ deleteIcon: string;
31
+ };
32
+ };
33
+ clickable: {
34
+ true: {
35
+ base: string[];
36
+ };
37
+ false: {};
38
+ };
39
+ hasDeleteIcon: {
40
+ true: {};
41
+ false: {};
42
+ };
43
+ hasAvatarElement: {
44
+ true: {};
45
+ false: {};
46
+ };
47
+ }, {
48
+ base: string[];
49
+ label: string;
50
+ deleteIcon: string;
51
+ }, undefined, {
52
+ color: Record<"default" | "success" | "warning" | "info" | "error", {}>;
53
+ variant: {
54
+ solid: {};
55
+ filled: {};
56
+ outlined: {
57
+ base: string;
58
+ };
59
+ };
60
+ disabled: {
61
+ true: {
62
+ base: string;
63
+ };
64
+ false: {
65
+ deleteIcon: string;
66
+ };
67
+ };
68
+ size: {
69
+ small: {
70
+ base: string;
71
+ deleteIcon: string;
72
+ };
73
+ medium: {
74
+ base: string;
75
+ deleteIcon: string;
76
+ };
77
+ large: {
78
+ base: string;
79
+ deleteIcon: string;
80
+ };
81
+ };
82
+ clickable: {
83
+ true: {
84
+ base: string[];
85
+ };
86
+ false: {};
87
+ };
88
+ hasDeleteIcon: {
89
+ true: {};
90
+ false: {};
91
+ };
92
+ hasAvatarElement: {
93
+ true: {};
94
+ false: {};
95
+ };
96
+ }, {
97
+ base: string[];
98
+ label: string;
99
+ deleteIcon: string;
100
+ }, import('tailwind-variants').TVReturnTypeLike<{
101
+ color: Record<"default" | "success" | "warning" | "info" | "error", {}>;
102
+ variant: {
103
+ solid: {};
104
+ filled: {};
105
+ outlined: {
106
+ base: string;
107
+ };
108
+ };
109
+ disabled: {
110
+ true: {
111
+ base: string;
112
+ };
113
+ false: {
114
+ deleteIcon: string;
115
+ };
116
+ };
117
+ size: {
118
+ small: {
119
+ base: string;
120
+ deleteIcon: string;
121
+ };
122
+ medium: {
123
+ base: string;
124
+ deleteIcon: string;
125
+ };
126
+ large: {
127
+ base: string;
128
+ deleteIcon: string;
129
+ };
130
+ };
131
+ clickable: {
132
+ true: {
133
+ base: string[];
134
+ };
135
+ false: {};
136
+ };
137
+ hasDeleteIcon: {
138
+ true: {};
139
+ false: {};
140
+ };
141
+ hasAvatarElement: {
142
+ true: {};
143
+ false: {};
144
+ };
145
+ }, {
146
+ base: string[];
147
+ label: string;
148
+ deleteIcon: string;
149
+ }>>;
150
+ declare const _default: import('tailwind-variants').TVReturnType<{
151
+ color: Record<"default" | "success" | "warning" | "info" | "error", {}>;
152
+ variant: {
153
+ solid: {};
154
+ filled: {};
155
+ outlined: {
156
+ base: string;
157
+ };
158
+ };
159
+ disabled: {
160
+ true: {
161
+ base: string;
162
+ };
163
+ false: {
164
+ deleteIcon: string;
165
+ };
166
+ };
167
+ size: {
168
+ small: {
169
+ base: string;
170
+ deleteIcon: string;
171
+ };
172
+ medium: {
173
+ base: string;
174
+ deleteIcon: string;
175
+ };
176
+ large: {
177
+ base: string;
178
+ deleteIcon: string;
179
+ };
180
+ };
181
+ clickable: {
182
+ true: {
183
+ base: string[];
184
+ };
185
+ false: {};
186
+ };
187
+ hasDeleteIcon: {
188
+ true: {};
189
+ false: {};
190
+ };
191
+ hasAvatarElement: {
192
+ true: {};
193
+ false: {};
194
+ };
195
+ }, {
196
+ base: string[];
197
+ label: string;
198
+ deleteIcon: string;
199
+ }, undefined, {
200
+ color: Record<"default" | "success" | "warning" | "info" | "error", {}>;
201
+ variant: {
202
+ solid: {};
203
+ filled: {};
204
+ outlined: {
205
+ base: string;
206
+ };
207
+ };
208
+ disabled: {
209
+ true: {
210
+ base: string;
211
+ };
212
+ false: {
213
+ deleteIcon: string;
214
+ };
215
+ };
216
+ size: {
217
+ small: {
218
+ base: string;
219
+ deleteIcon: string;
220
+ };
221
+ medium: {
222
+ base: string;
223
+ deleteIcon: string;
224
+ };
225
+ large: {
226
+ base: string;
227
+ deleteIcon: string;
228
+ };
229
+ };
230
+ clickable: {
231
+ true: {
232
+ base: string[];
233
+ };
234
+ false: {};
235
+ };
236
+ hasDeleteIcon: {
237
+ true: {};
238
+ false: {};
239
+ };
240
+ hasAvatarElement: {
241
+ true: {};
242
+ false: {};
243
+ };
244
+ }, {
245
+ base: string[];
246
+ label: string;
247
+ deleteIcon: string;
248
+ }, import('tailwind-variants').TVReturnTypeLike<{
249
+ color: Record<"default" | "success" | "warning" | "info" | "error", {}>;
250
+ variant: {
251
+ solid: {};
252
+ filled: {};
253
+ outlined: {
254
+ base: string;
255
+ };
256
+ };
257
+ disabled: {
258
+ true: {
259
+ base: string;
260
+ };
261
+ false: {
262
+ deleteIcon: string;
263
+ };
264
+ };
265
+ size: {
266
+ small: {
267
+ base: string;
268
+ deleteIcon: string;
269
+ };
270
+ medium: {
271
+ base: string;
272
+ deleteIcon: string;
273
+ };
274
+ large: {
275
+ base: string;
276
+ deleteIcon: string;
277
+ };
278
+ };
279
+ clickable: {
280
+ true: {
281
+ base: string[];
282
+ };
283
+ false: {};
284
+ };
285
+ hasDeleteIcon: {
286
+ true: {};
287
+ false: {};
288
+ };
289
+ hasAvatarElement: {
290
+ true: {};
291
+ false: {};
292
+ };
293
+ }, {
294
+ base: string[];
295
+ label: string;
296
+ deleteIcon: string;
297
+ }>>;
298
+ export default _default;
@@ -0,0 +1 @@
1
+ import{n as e}from"../_chunks/dist-C-sN40SQ.js";import t from"../styles/theme/index.js";import n from"../utils/asVariant.js";import r from"../utils/typedKeys.js";var i=[`solid`,`filled`,`outlined`],a=(a=t)=>e({slots:{base:[`inline-flex items-center gap-1`,`font-normal align-middle`,a.typography.colors.textPrimary,a.rounded.full],label:``,deleteIcon:`shrink-0`},variants:{color:n(a.colors,()=>({})),variant:{solid:{},filled:{},outlined:{base:`border`}},disabled:{true:{base:`user-event-none`},false:{deleteIcon:`cursor-pointer`}},size:{small:{base:`h-6 px-1.5 gap-[2px] text-xs`,deleteIcon:`text-md`},medium:{base:`h-7 px-2.5 gap-[3px] text-sm`,deleteIcon:`text-lg`},large:{base:`h-8 px-3 gap-1 text-normal`,deleteIcon:`text-xl`}},clickable:{true:{base:[a.focus]},false:{}},hasDeleteIcon:{true:{},false:{}},hasAvatarElement:{true:{},false:{}}},compoundVariants:[...r(a.colors).flatMap(e=>i.map(t=>{let n=a.colors[e][t];return[{color:e,variant:t,clickable:!1,disabled:!1,class:{base:[n.background,n.border,n.text]}},{color:e,variant:t,clickable:!0,disabled:!1,class:{base:[`cursor-pointer`,n.background,n.border,n.text,n.hover,n.active]}},{color:e,variant:t,disabled:!0,class:{base:[a.disabled.text,[`outlined`].includes(t)?a.disabled.border:``,[`solid`,`filled`].includes(t)?a.disabled.background:``]}}]}).flat()),{hasDeleteIcon:!0,size:`small`,class:{base:`ps-1.5 pe-1`}},{hasDeleteIcon:!0,size:`medium`,class:{base:`ps-2.5 pe-1.5`}},{hasDeleteIcon:!0,size:`large`,class:{base:`ps-3 pe-2`}},{hasAvatarElement:!0,size:`small`,class:{base:`ps-[2px]`,label:`ps-[1px]`}},{hasAvatarElement:!0,size:`medium`,class:{base:`ps-[3px]`,label:`ps-[2px]`}},{hasAvatarElement:!0,size:`large`,class:{base:`ps-1`,label:`ps-[3px]`}}]}),o=a();export{a as chip,o as default};
@@ -0,0 +1,20 @@
1
+ import { ComponentProps, JSXElement } from 'solid-js';
2
+ import { VariantProps } from 'tailwind-variants';
3
+ import { BackdropProps } from '../Backdrop';
4
+ import { default as dialogDefaultStyles } from './style';
5
+ type DialogVariants = VariantProps<typeof dialogDefaultStyles>;
6
+ type DialogSlotProps = {
7
+ backdrop?: BackdropProps;
8
+ };
9
+ export type DialogCloseReason = "escape" | "backdrop";
10
+ export type DialogProps = {
11
+ children?: JSXElement;
12
+ class?: string;
13
+ fullscreen?: DialogVariants["fullscreen"];
14
+ onClose?: (event: Event, reason: DialogCloseReason) => void;
15
+ open?: boolean;
16
+ role?: "alertdialog" | "dialog";
17
+ slotProps?: DialogSlotProps;
18
+ } & Omit<ComponentProps<"div">, "onClose">;
19
+ declare const Dialog: (props: DialogProps) => import("solid-js").JSX.Element;
20
+ export default Dialog;
@@ -0,0 +1 @@
1
+ import e from"../utils/cn.js";import t from"./style.js";import{useThemeContext as n}from"../ThemeProvider/ThemeContext.js";import"../ThemeProvider/index.js";import r from"../Backdrop/Backdrop.js";import"../Backdrop/index.js";import{Portal as i,createComponent as a,insert as o,mergeProps as s,spread as c,template as l,use as u}from"solid-js/web";import{Show as d,createEffect as f,createMemo as p,mergeProps as m,onCleanup as h,splitProps as g}from"solid-js";var _=l(`<div role=dialog aria-modal=true>`),v=[`a[href]`,`button:not([disabled])`,`input:not([disabled])`,`select:not([disabled])`,`textarea:not([disabled])`,`[tabindex]:not([tabindex='-1'])`].join(`,`),y=l=>{let y=m({fullscreen:!1},l),[b,x]=g(y,[`class`,`children`,`fullscreen`,`open`,`onClose`,`slotProps`]),S=n(),C,w=()=>C?Array.from(C.querySelectorAll(v)).filter(e=>{let t=getComputedStyle(e);return!e.hasAttribute(`disabled`)&&t.display!==`none`&&t.visibility!==`hidden`}):[],T=()=>{let e=w()[0];e?e.focus():C.focus()},E=()=>{let e=w(),t=e[e.length-1];t?t.focus():C.focus()},D=e=>{if(!b.open||!C)return;if(e.key===`Escape`){e.preventDefault(),b.onClose?.(e,`escape`);return}if(e.key!==`Tab`)return;let t=w();if(t.length===0){e.preventDefault(),C.focus();return}let n=t[0],r=t[t.length-1],i=document.activeElement;if(!C.contains(i)){e.preventDefault(),e.shiftKey?E():T();return}if(e.shiftKey&&i===n){e.preventDefault(),r.focus();return}!e.shiftKey&&i===r&&(e.preventDefault(),n.focus())},O=e=>{if(!b.open||!C)return;let t=e.target;t instanceof Node&&(C.contains(t)||T())};f(()=>{if(!b.open){document.body.classList.remove(`overflow-hidden`);return}document.body.classList.add(`overflow-hidden`),document.addEventListener(`keydown`,D),document.addEventListener(`focusin`,O),h(()=>{document.removeEventListener(`keydown`,D),document.removeEventListener(`focusin`,O)})});let k=e=>{e.target===C||C.contains(e.target)||(b.onClose?.(e,`backdrop`),b.slotProps?.backdrop?.onClick?.(e))},A=p(()=>{let e={fullscreen:b.fullscreen};return S?S.componentsTV.dialog(e):t(e)});return a(d,{get when(){return b.open},get children(){return a(i,{get children(){return a(r,s(()=>b.slotProps?.backdrop,{onClick:k,get children(){var t=_(),n=C;return typeof n==`function`?u(n,t):C=t,c(t,s(x,{get class(){return e(A(),b.class)}}),!1,!0),o(t,()=>b.children),t}}))}})}})};export{y as default};
@@ -0,0 +1,2 @@
1
+ export { default } from './Dialog';
2
+ export * from './Dialog';
@@ -0,0 +1 @@
1
+ import"./Dialog.js";
@@ -0,0 +1,34 @@
1
+ import { Theme } from '../styles/theme';
2
+ export declare const dialog: (theme?: Theme) => import('tailwind-variants').TVReturnType<{
3
+ fullscreen: {
4
+ true: "w-full h-full";
5
+ false: string[];
6
+ };
7
+ }, undefined, string[], {
8
+ fullscreen: {
9
+ true: "w-full h-full";
10
+ false: string[];
11
+ };
12
+ }, undefined, import('tailwind-variants').TVReturnTypeLike<{
13
+ fullscreen: {
14
+ true: "w-full h-full";
15
+ false: string[];
16
+ };
17
+ }, undefined>>;
18
+ declare const _default: import('tailwind-variants').TVReturnType<{
19
+ fullscreen: {
20
+ true: "w-full h-full";
21
+ false: string[];
22
+ };
23
+ }, undefined, string[], {
24
+ fullscreen: {
25
+ true: "w-full h-full";
26
+ false: string[];
27
+ };
28
+ }, undefined, import('tailwind-variants').TVReturnTypeLike<{
29
+ fullscreen: {
30
+ true: "w-full h-full";
31
+ false: string[];
32
+ };
33
+ }, undefined>>;
34
+ export default _default;