@pathscale/ui 0.1.0 → 0.1.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 (267) hide show
  1. package/LICENSE +1 -0
  2. package/README.md +59 -1
  3. package/dist/components/accordion/Accordion.d.ts +25 -0
  4. package/dist/components/accordion/index.d.ts +1 -0
  5. package/dist/components/alert/Alert.d.ts +17 -0
  6. package/dist/components/alert/index.d.ts +1 -0
  7. package/dist/components/artboard/Artboard.d.ts +9 -0
  8. package/dist/components/artboard/index.d.ts +1 -0
  9. package/dist/components/avatar/Avatar.d.ts +26 -0
  10. package/dist/components/avatar/AvatarGroup.d.ts +15 -0
  11. package/dist/components/avatar/index.d.ts +3 -8
  12. package/dist/components/background/Background.d.ts +5 -0
  13. package/dist/components/background/index.d.ts +1 -0
  14. package/dist/components/badge/Badge.d.ts +19 -0
  15. package/dist/components/badge/index.d.ts +1 -0
  16. package/dist/components/bottom-sheet/BottomSheet.d.ts +11 -0
  17. package/dist/components/bottom-sheet/index.d.ts +2 -0
  18. package/dist/components/breadcrumbs/Breadcrumbs.d.ts +7 -0
  19. package/dist/components/breadcrumbs/BreadcrumbsItem.d.ts +6 -0
  20. package/dist/components/breadcrumbs/index.d.ts +2 -0
  21. package/dist/components/browsermockup/BrowserMockup.d.ts +10 -0
  22. package/dist/components/browsermockup/index.d.ts +2 -0
  23. package/dist/components/button/Button.d.ts +36 -0
  24. package/dist/components/button/index.d.ts +1 -9
  25. package/dist/components/calendar/Calendar.d.ts +27 -0
  26. package/dist/components/calendar/index.d.ts +1 -0
  27. package/dist/components/card/Card.d.ts +28 -0
  28. package/dist/components/card/CardActions.d.ts +4 -0
  29. package/dist/components/card/CardBody.d.ts +4 -0
  30. package/dist/components/card/CardImage.d.ts +3 -0
  31. package/dist/components/card/CardTitle.d.ts +6 -0
  32. package/dist/components/card/index.d.ts +1 -0
  33. package/dist/components/carousel/Carousel.d.ts +15 -0
  34. package/dist/components/carousel/CarouselItem.d.ts +6 -0
  35. package/dist/components/carousel/index.d.ts +3 -0
  36. package/dist/components/chatbubble/ChatBubble.d.ts +13 -0
  37. package/dist/components/chatbubble/ChatBubbleAvatar.d.ts +6 -0
  38. package/dist/components/chatbubble/ChatBubbleFooter.d.ts +5 -0
  39. package/dist/components/chatbubble/ChatBubbleHeader.d.ts +5 -0
  40. package/dist/components/chatbubble/ChatBubbleMessage.d.ts +7 -0
  41. package/dist/components/chatbubble/ChatBubbleTime.d.ts +5 -0
  42. package/dist/components/chatbubble/index.d.ts +1 -0
  43. package/dist/components/checkbox/Checkbox.d.ts +20 -0
  44. package/dist/components/checkbox/index.d.ts +1 -0
  45. package/dist/components/codemockup/CodeMockup.d.ts +5 -0
  46. package/dist/components/codemockup/CodeMockupLine.d.ts +12 -0
  47. package/dist/components/codemockup/index.d.ts +2 -0
  48. package/dist/components/collapse/Collapse.d.ts +20 -0
  49. package/dist/components/collapse/CollapseContent.d.ts +4 -0
  50. package/dist/components/collapse/CollapseDetails.d.ts +17 -0
  51. package/dist/components/collapse/CollapseTitle.d.ts +9 -0
  52. package/dist/components/collapse/index.d.ts +4 -0
  53. package/dist/components/connectionstatus/ConnectionStatus.d.ts +59 -0
  54. package/dist/components/connectionstatus/index.d.ts +2 -0
  55. package/dist/components/copy-button/CopyButton.d.ts +11 -0
  56. package/dist/components/copy-button/index.d.ts +2 -0
  57. package/dist/components/countdown/Countdown.d.ts +7 -0
  58. package/dist/components/countdown/index.d.ts +1 -0
  59. package/dist/components/diff/Diff.d.ts +7 -0
  60. package/dist/components/diff/index.d.ts +1 -0
  61. package/dist/components/divider/Divider.d.ts +21 -0
  62. package/dist/components/divider/Divider.styles.d.ts +25 -0
  63. package/dist/components/divider/index.d.ts +2 -0
  64. package/dist/components/dock/Dock.d.ts +14 -0
  65. package/dist/components/dock/DockItem.d.ts +9 -0
  66. package/dist/components/dock/DockLabel.d.ts +6 -0
  67. package/dist/components/dock/index.d.ts +3 -0
  68. package/dist/components/drawer/Drawer.d.ts +14 -0
  69. package/dist/components/drawer/index.d.ts +1 -0
  70. package/dist/components/dropdown/Dropdown.d.ts +28 -0
  71. package/dist/components/dropdown/DropdownDetails.d.ts +14 -0
  72. package/dist/components/dropdown/DropdownItem.d.ts +19 -0
  73. package/dist/components/dropdown/DropdownMenu.d.ts +9 -0
  74. package/dist/components/dropdown/DropdownToggle.d.ts +17 -0
  75. package/dist/components/dropdown/dropdownContext.d.ts +9 -0
  76. package/dist/components/dropdown/index.d.ts +2 -0
  77. package/dist/components/fileinput/FileInput.d.ts +14 -0
  78. package/dist/components/fileinput/index.d.ts +1 -0
  79. package/dist/components/flex/Flex.d.ts +18 -0
  80. package/dist/components/flex/index.d.ts +1 -0
  81. package/dist/components/footer/Footer.d.ts +11 -0
  82. package/dist/components/footer/FooterTitle.d.ts +4 -0
  83. package/dist/components/footer/index.d.ts +3 -0
  84. package/dist/components/form/Form.d.ts +22 -0
  85. package/dist/components/form/FormDropdown.d.ts +25 -0
  86. package/dist/components/form/FormField.d.ts +14 -0
  87. package/dist/components/form/Label.d.ts +7 -0
  88. package/dist/components/form/NumberField.d.ts +20 -0
  89. package/dist/components/form/PasswordField.d.ts +16 -0
  90. package/dist/components/form/ValidatedForm.d.ts +26 -0
  91. package/dist/components/form/index.d.ts +4 -0
  92. package/dist/components/grid/Grid.d.ts +18 -0
  93. package/dist/components/grid/index.d.ts +1 -0
  94. package/dist/components/hero/Hero.d.ts +10 -0
  95. package/dist/components/hero/HeroContent.d.ts +6 -0
  96. package/dist/components/hero/HeroOverlay.d.ts +6 -0
  97. package/dist/components/hero/index.d.ts +4 -0
  98. package/dist/components/icon/Icon.d.ts +11 -0
  99. package/dist/components/icon/index.d.ts +1 -0
  100. package/dist/components/indicator/Indicator.d.ts +30 -0
  101. package/dist/components/indicator/index.d.ts +2 -0
  102. package/dist/components/input/Input.d.ts +23 -0
  103. package/dist/components/input/index.d.ts +3 -8
  104. package/dist/components/join/Join.d.ts +9 -0
  105. package/dist/components/join/index.d.ts +2 -0
  106. package/dist/components/kbd/Kbd.d.ts +4 -0
  107. package/dist/components/kbd/index.d.ts +1 -0
  108. package/dist/components/link/Link.d.ts +12 -0
  109. package/dist/components/link/index.d.ts +1 -0
  110. package/dist/components/loading/Loading.d.ts +14 -0
  111. package/dist/components/loading/index.d.ts +1 -0
  112. package/dist/components/mask/Mask.d.ts +14 -0
  113. package/dist/components/mask/index.d.ts +2 -0
  114. package/dist/components/menu/Menu.d.ts +21 -0
  115. package/dist/components/menu/MenuDetails.d.ts +8 -0
  116. package/dist/components/menu/MenuDropdown.d.ts +12 -0
  117. package/dist/components/menu/MenuItem.d.ts +9 -0
  118. package/dist/components/menu/MenuTitle.d.ts +8 -0
  119. package/dist/components/menu/index.d.ts +3 -0
  120. package/dist/components/modal/Modal.d.ts +26 -0
  121. package/dist/components/modal/ModalActions.d.ts +3 -0
  122. package/dist/components/modal/ModalBody.d.ts +3 -0
  123. package/dist/components/modal/ModalHeader.d.ts +3 -0
  124. package/dist/components/modal/ModalLegacy.d.ts +8 -0
  125. package/dist/components/modal/index.d.ts +6 -0
  126. package/dist/components/navbar/Navbar.d.ts +15 -0
  127. package/dist/components/navbar/NavbarRow.d.ts +9 -0
  128. package/dist/components/navbar/NavbarSection.d.ts +8 -0
  129. package/dist/components/navbar/NavbarStack.d.ts +10 -0
  130. package/dist/components/navbar/index.d.ts +4 -0
  131. package/dist/components/pagination/Pagination.d.ts +4 -0
  132. package/dist/components/pagination/index.d.ts +2 -0
  133. package/dist/components/phonemockup/PhoneMockup.d.ts +8 -0
  134. package/dist/components/phonemockup/index.d.ts +1 -0
  135. package/dist/components/progress/Progress.d.ts +14 -0
  136. package/dist/components/progress/index.d.ts +1 -0
  137. package/dist/components/props-table/PropsTable.d.ts +14 -0
  138. package/dist/components/props-table/index.d.ts +2 -0
  139. package/dist/components/radialprogress/RadialProgress.d.ts +10 -0
  140. package/dist/components/radialprogress/index.d.ts +1 -0
  141. package/dist/components/radio/Radio.d.ts +16 -0
  142. package/dist/components/radio/index.d.ts +1 -0
  143. package/dist/components/range/Range.d.ts +12 -0
  144. package/dist/components/range/index.d.ts +1 -0
  145. package/dist/components/rating/Rating.d.ts +23 -0
  146. package/dist/components/rating/RatingHidden.d.ts +4 -0
  147. package/dist/components/rating/RatingItem.d.ts +9 -0
  148. package/dist/components/rating/index.d.ts +4 -0
  149. package/dist/components/select/Select.d.ts +15 -0
  150. package/dist/components/select/index.d.ts +1 -0
  151. package/dist/components/showcase/ShowcaseBlock.d.ts +10 -0
  152. package/dist/components/showcase/index.d.ts +2 -0
  153. package/dist/components/showcase-section/ShowcaseSection.d.ts +8 -0
  154. package/dist/components/showcase-section/index.d.ts +2 -0
  155. package/dist/components/sidenav/Sidenav.d.ts +14 -0
  156. package/dist/components/sidenav/SidenavButton.d.ts +9 -0
  157. package/dist/components/sidenav/SidenavGroup.d.ts +10 -0
  158. package/dist/components/sidenav/SidenavItem.d.ts +8 -0
  159. package/dist/components/sidenav/SidenavLink.d.ts +9 -0
  160. package/dist/components/sidenav/SidenavMenu.d.ts +5 -0
  161. package/dist/components/sidenav/index.d.ts +12 -0
  162. package/dist/components/skeleton/Skeleton.d.ts +5 -0
  163. package/dist/components/skeleton/index.d.ts +1 -0
  164. package/dist/components/stack/Stack.d.ts +17 -0
  165. package/dist/components/stack/index.d.ts +2 -0
  166. package/dist/components/stat-card/StatCard.d.ts +22 -0
  167. package/dist/components/stat-card/StatCardSection.d.ts +5 -0
  168. package/dist/components/stat-card/index.d.ts +1 -0
  169. package/dist/components/stats/Stat.d.ts +12 -0
  170. package/dist/components/stats/StatSection.d.ts +6 -0
  171. package/dist/components/stats/Stats.d.ts +15 -0
  172. package/dist/components/stats/index.d.ts +1 -0
  173. package/dist/components/status/Status.d.ts +8 -0
  174. package/dist/components/status/index.d.ts +2 -0
  175. package/dist/components/steps/Step.d.ts +19 -0
  176. package/dist/components/steps/Steps.d.ts +18 -0
  177. package/dist/components/steps/index.d.ts +2 -0
  178. package/dist/components/streaming-table/StreamingTable.d.ts +26 -0
  179. package/dist/components/streaming-table/createRowStore.d.ts +7 -0
  180. package/dist/components/streaming-table/createStreamingTableStore.d.ts +13 -0
  181. package/dist/components/streaming-table/index.d.ts +5 -0
  182. package/dist/components/streaming-table/types.d.ts +46 -0
  183. package/dist/components/svgbackground/SvgBackground.d.ts +21 -0
  184. package/dist/components/svgbackground/index.d.ts +2 -0
  185. package/dist/components/swap/Swap.d.ts +12 -0
  186. package/dist/components/swap/index.d.ts +1 -0
  187. package/dist/components/table/EnhancedTable.d.ts +45 -0
  188. package/dist/components/table/Table.d.ts +18 -0
  189. package/dist/components/table/TableBody.d.ts +5 -0
  190. package/dist/components/table/TableCell.d.ts +7 -0
  191. package/dist/components/table/TableFooter.d.ts +7 -0
  192. package/dist/components/table/TableHead.d.ts +7 -0
  193. package/dist/components/table/TableHeadCell.d.ts +7 -0
  194. package/dist/components/table/TableRow.d.ts +8 -0
  195. package/dist/components/table/index.d.ts +4 -0
  196. package/dist/components/tabs/RadioTab.d.ts +16 -0
  197. package/dist/components/tabs/Tab.d.ts +12 -0
  198. package/dist/components/tabs/Tabs.d.ts +12 -0
  199. package/dist/components/tabs/index.d.ts +4 -0
  200. package/dist/components/textarea/Textarea.d.ts +14 -0
  201. package/dist/components/textarea/index.d.ts +1 -8
  202. package/dist/components/timeline/Timeline.d.ts +11 -0
  203. package/dist/components/timeline/TimelineEnd.d.ts +6 -0
  204. package/dist/components/timeline/TimelineItem.d.ts +8 -0
  205. package/dist/components/timeline/TimelineMiddle.d.ts +4 -0
  206. package/dist/components/timeline/TimelineStart.d.ts +6 -0
  207. package/dist/components/timeline/index.d.ts +5 -0
  208. package/dist/components/toast/Toast.d.ts +21 -0
  209. package/dist/components/toast/index.d.ts +1 -0
  210. package/dist/components/toastcontainer/ToastContainer.d.ts +2 -0
  211. package/dist/components/toastcontainer/index.d.ts +1 -0
  212. package/dist/components/toggle/Toggle.d.ts +19 -0
  213. package/dist/components/toggle/index.d.ts +1 -0
  214. package/dist/components/tooltip/Tooltip.d.ts +15 -0
  215. package/dist/components/tooltip/index.d.ts +1 -0
  216. package/dist/components/types.d.ts +15 -0
  217. package/dist/components/utils.d.ts +9 -0
  218. package/dist/components/windowmockup/WindowMockup.d.ts +11 -0
  219. package/dist/components/windowmockup/index.d.ts +1 -0
  220. package/dist/index.d.ts +93 -7
  221. package/dist/index.js +12922 -4
  222. package/dist/lib/iterable.d.ts +9 -0
  223. package/dist/lib/props/index.d.ts +1 -0
  224. package/dist/lib/props/types.d.ts +1 -0
  225. package/dist/lib/refs/index.d.ts +2 -0
  226. package/dist/lib/refs/mergeRefs.d.ts +7 -0
  227. package/dist/lib/refs/types.d.ts +1 -0
  228. package/dist/lib/style/classes.d.ts +33 -0
  229. package/dist/lib/style/index.d.ts +1 -0
  230. package/dist/lib/tag/createIsButton.d.ts +21 -0
  231. package/dist/lib/tag/createTagName.d.ts +12 -0
  232. package/dist/lib/tag/index.d.ts +2 -0
  233. package/dist/sidenav/Sidenav.css +150 -0
  234. package/dist/stores/index.d.ts +1 -0
  235. package/dist/stores/toastStore.d.ts +17 -0
  236. package/dist/styles/icons/generated-icons.css +1 -0
  237. package/package.json +63 -43
  238. package/dist/Avatar-CzIirpVq.d.ts +0 -33
  239. package/dist/Button-BOYHKShy.d.ts +0 -63
  240. package/dist/Input-CvNxe1rq.d.ts +0 -34
  241. package/dist/Textarea-5_oQknZn.d.ts +0 -37
  242. package/dist/chunk/3MUBOGZG.js +0 -213
  243. package/dist/chunk/EB7KXR65.js +0 -102
  244. package/dist/chunk/G6RG4LR7.js +0 -87
  245. package/dist/chunk/HEJAQSH5.jsx +0 -100
  246. package/dist/chunk/HKS7ET6T.js +0 -56
  247. package/dist/chunk/KACNXPUM.jsx +0 -103
  248. package/dist/chunk/NLD5D3P7.jsx +0 -94
  249. package/dist/chunk/P7WPLZNA.jsx +0 -59
  250. package/dist/chunk/UTRNHAP4.js +0 -95
  251. package/dist/chunk/VMEDFWWG.js +0 -102
  252. package/dist/chunk/WB6NEEQV.jsx +0 -107
  253. package/dist/chunk/YZ3ID3UY.jsx +0 -226
  254. package/dist/classes-B_S9K-9I.d.ts +0 -13
  255. package/dist/components/avatar/index.js +0 -1
  256. package/dist/components/avatar/index.jsx +0 -7
  257. package/dist/components/button/index.js +0 -1
  258. package/dist/components/button/index.jsx +0 -8
  259. package/dist/components/input/index.js +0 -1
  260. package/dist/components/input/index.jsx +0 -7
  261. package/dist/components/polymorphic/index.d.ts +0 -35
  262. package/dist/components/polymorphic/index.js +0 -1
  263. package/dist/components/polymorphic/index.jsx +0 -8
  264. package/dist/components/textarea/index.js +0 -1
  265. package/dist/components/textarea/index.jsx +0 -7
  266. package/dist/index.css +0 -73
  267. package/dist/index.jsx +0 -20
@@ -0,0 +1,9 @@
1
+ /**
2
+ * Creates a function that calls a series of callbacks in order with the same arguments.
3
+ *
4
+ * @param callbacks An iterable of callback functions to invoke.
5
+ * @returns A function that will execute all callbacks with the provided arguments.
6
+ */
7
+ export declare function chain<Args extends [] | unknown[]>(callbacks: {
8
+ [Symbol.iterator]: () => IterableIterator<((...args: Args) => unknown) | undefined>;
9
+ }): (...args: Args) => void;
@@ -0,0 +1 @@
1
+ export type { OverrideProps } from "./types";
@@ -0,0 +1 @@
1
+ export type OverrideProps<T, P> = Omit<T, keyof P> & P;
@@ -0,0 +1,2 @@
1
+ export { mergeRefs } from "./mergeRefs";
2
+ export type { ElementOf } from "./types";
@@ -0,0 +1,7 @@
1
+ /**
2
+ * Utility for chaining multiple `ref` assignments with `props.ref` forwarding.
3
+ *
4
+ * @param refs An array of refs to merge.
5
+ * @returns A function that assigns the element to all provided refs.
6
+ */
7
+ export declare function mergeRefs<T>(...refs: (T | ((value: T) => void) | undefined)[]): (element: T) => void;
@@ -0,0 +1 @@
1
+ export type ElementOf<T> = T extends keyof HTMLElementTagNameMap ? HTMLElementTagNameMap[T] : unknown;
@@ -0,0 +1,33 @@
1
+ export type ClassArgs = string | number | boolean | null | undefined | ClassArgs[];
2
+ export type ClassProps = {
3
+ class?: ClassArgs;
4
+ };
5
+ export type OmitUndefined<T> = T extends undefined ? never : T;
6
+ export type StringToBoolean<T> = T extends "true" | "false" ? boolean : T;
7
+ export type ConfigSchema = Record<string, Record<string, ClassArgs>>;
8
+ export type ConfigVariants<T extends ConfigSchema> = {
9
+ [Variant in keyof T]?: StringToBoolean<keyof T[Variant]> | null | undefined;
10
+ };
11
+ export type ConfigVariantsMulti<T extends ConfigSchema> = {
12
+ [Variant in keyof T]?: StringToBoolean<keyof T[Variant]> | StringToBoolean<keyof T[Variant]>[] | undefined;
13
+ };
14
+ export type Config<T> = T extends ConfigSchema ? {
15
+ variants?: T;
16
+ defaultVariants?: ConfigVariants<T>;
17
+ compoundVariants?: (T extends ConfigSchema ? (ConfigVariants<T> | ConfigVariantsMulti<T>) & ClassProps : ClassProps)[];
18
+ } : never;
19
+ export type VariantKeys<T extends ConfigSchema> = keyof T;
20
+ export type VariantProps<Component extends (...args: []) => unknown> = Omit<OmitUndefined<Parameters<Component>[0]>, "class">;
21
+ /**
22
+ * Joins classes into a single string.
23
+ *
24
+ * @param args The args to join.
25
+ * @returns A string of joined class names, excluding any falsy values.
26
+ */
27
+ export declare function classes(...args: ClassArgs[]): string;
28
+ export declare function falsyToString<T>(value: T): string | T;
29
+ export type CvaProps<T> = T extends ConfigSchema ? ConfigVariants<T> & ClassProps : ClassProps;
30
+ export declare function cva<T extends ConfigSchema>(base?: ClassArgs, config?: Config<T>): {
31
+ (props?: CvaProps<T>): string;
32
+ variantKeys: (keyof T)[];
33
+ };
@@ -0,0 +1 @@
1
+ export { classes, cva, type ClassArgs, type ClassProps, type VariantProps, } from "./classes";
@@ -0,0 +1,21 @@
1
+ import { type Accessor } from "solid-js";
2
+ export declare const BUTTON_INPUT_TYPES: string[];
3
+ /**
4
+ * Checks if the given tag name or input type represent a button.
5
+ *
6
+ * @param tagName The name of the tag to check.
7
+ * @param type The type attribute of the input element.
8
+ * @returns `true` if the tag is a button or an input of a button type; otherwise, `false`.
9
+ */
10
+ export declare function isButton(tagName: string, type?: string): boolean;
11
+ /**
12
+ * Creates a memoized signal that checks if the element is a button.
13
+ *
14
+ * @param props.element The element to check.
15
+ * @param props.type An optional button input type to consider.
16
+ * @returns A memoized signal indicating if the element is a button.
17
+ */
18
+ export declare function createIsButton(props: {
19
+ element: Accessor<HTMLElement | null>;
20
+ type?: string | undefined;
21
+ }): Accessor<boolean>;
@@ -0,0 +1,12 @@
1
+ import { type Accessor } from "solid-js";
2
+ /**
3
+ * Creates a memoized signal with the lowercase tag name of the element.
4
+ *
5
+ * @param props.element The element to get the tag name of.
6
+ * @param props.fallback The fallback tag name to use if the element is `null`.
7
+ * @returns A memoized signal with the lowercase tag name of the element.
8
+ */
9
+ export declare function createTagName(props: {
10
+ element: Accessor<HTMLElement | null>;
11
+ fallback: string;
12
+ }): Accessor<string>;
@@ -0,0 +1,2 @@
1
+ export { BUTTON_INPUT_TYPES, createIsButton, isButton } from "./createIsButton";
2
+ export { createTagName } from "./createTagName";
@@ -0,0 +1,150 @@
1
+ .sidenav {
2
+ @apply h-screen bg-base-200 border-r border-base-300 flex flex-col transition-all duration-300 ease-in-out sticky top-0;
3
+ width: 16rem;
4
+ }
5
+
6
+ .sidenav-closed {
7
+ @apply -translate-x-full;
8
+ }
9
+
10
+ .sidenav-open {
11
+ @apply translate-x-0;
12
+ }
13
+
14
+ .sidenav-desktop {
15
+ @apply relative transform-none shadow-none;
16
+ }
17
+
18
+ .sidenav-collapsed {
19
+ width: 4rem;
20
+ @apply flex flex-col items-center py-8;
21
+ }
22
+
23
+ .sidenav-header {
24
+ @apply p-4 border-b border-base-300 flex items-center justify-between flex-shrink-0;
25
+ }
26
+
27
+ .sidenav-collapsed .sidenav-header {
28
+ @apply p-0 border-none;
29
+ }
30
+
31
+ .sidenav-title {
32
+ @apply text-lg font-semibold text-base-content truncate;
33
+ }
34
+
35
+ .sidenav-close {
36
+ @apply btn btn-ghost btn-sm p-1 hover:bg-base-300;
37
+ }
38
+
39
+ .sidenav-content {
40
+ @apply flex-1 overflow-y-auto;
41
+ }
42
+
43
+ .sidenav-menu {
44
+ @apply flex flex-col flex-1 p-4 space-y-4;
45
+ }
46
+
47
+ .sidenav-collapsed .sidenav-menu {
48
+ @apply p-0 items-center space-y-6;
49
+ }
50
+
51
+ .sidenav-item {
52
+ @apply w-full;
53
+ }
54
+
55
+ .sidenav-collapsed .sidenav-item {
56
+ @apply w-auto;
57
+ }
58
+
59
+ .sidenav-item-link,
60
+ .sidenav-item-button {
61
+ @apply flex items-center px-3 py-2 text-base-content transition-colors duration-300 transform rounded-lg hover:bg-base-300 gap-3;
62
+ }
63
+
64
+ .sidenav-collapsed .sidenav-item-link,
65
+ .sidenav-collapsed .sidenav-item-button {
66
+ @apply w-10 h-10 p-1.5 justify-center;
67
+ }
68
+
69
+ .sidenav-item-active .sidenav-item-link,
70
+ .sidenav-item-active .sidenav-item-button {
71
+ @apply bg-primary text-primary-content hover:bg-primary/90;
72
+ }
73
+
74
+ .sidenav-children {
75
+ @apply p-4 text-base-content;
76
+ }
77
+
78
+ .sidenav-footer {
79
+ @apply mt-auto p-4 border-t border-base-300 flex-shrink-0 text-base-content/70;
80
+ }
81
+
82
+ .sidenav-collapsed .sidenav-footer {
83
+ @apply p-0 border-none flex flex-col items-center space-y-6;
84
+ }
85
+
86
+ .sidenav-group {
87
+ @apply space-y-2 mb-4 w-full;
88
+ }
89
+
90
+ .sidenav-collapsed .sidenav-group {
91
+ @apply mb-0 space-y-2;
92
+ }
93
+
94
+ .sidenav-group-label {
95
+ @apply px-3 py-2 text-xs font-semibold text-base-content/70 uppercase tracking-wider;
96
+ }
97
+
98
+ .sidenav-group-items {
99
+ @apply space-y-1 w-full pl-3;
100
+ }
101
+
102
+ .sidenav-collapsed .sidenav-group-items {
103
+ @apply pl-0 space-y-2;
104
+ }
105
+
106
+ .sidenav-collapsed .sidenav-group-label {
107
+ @apply hidden;
108
+ }
109
+
110
+ .sidenav-collapsed .sidenav-item-label {
111
+ @apply hidden;
112
+ }
113
+
114
+ .sidenav-item-link svg,
115
+ .sidenav-item-button svg {
116
+ @apply w-5 h-5 flex-shrink-0;
117
+ }
118
+
119
+ .sidenav-collapsed .sidenav-item-link,
120
+ .sidenav-collapsed .sidenav-item-button {
121
+ @apply relative;
122
+ }
123
+
124
+ .sidenav-collapsed .sidenav-item-link:hover::after,
125
+ .sidenav-collapsed .sidenav-item-button:hover::after {
126
+ content: attr(title);
127
+ @apply absolute left-full ml-2 px-2 py-1 bg-base-300 text-base-content rounded text-sm whitespace-nowrap z-50;
128
+ }
129
+
130
+ .sidenav-overlay {
131
+ @apply fixed inset-0 bg-base-content/50 z-40 transition-opacity duration-300;
132
+ }
133
+
134
+ .sidenav-overlay-hidden {
135
+ @apply opacity-0 pointer-events-none;
136
+ }
137
+
138
+ .sidenav-overlay-visible {
139
+ @apply opacity-100;
140
+ }
141
+
142
+ @media (min-width: 768px) {
143
+ .sidenav-desktop {
144
+ @apply relative transform-none shadow-none;
145
+ }
146
+
147
+ .sidenav-overlay {
148
+ @apply hidden;
149
+ }
150
+ }
@@ -0,0 +1 @@
1
+ export * from "./toastStore";
@@ -0,0 +1,17 @@
1
+ export type ToastType = "info" | "success" | "warning" | "error";
2
+ export interface ToastItem {
3
+ id: string;
4
+ message: string;
5
+ type: ToastType;
6
+ timestamp: number;
7
+ }
8
+ export declare const toastStore: {
9
+ toasts: import("solid-js").Accessor<ToastItem[]>;
10
+ addToast: (message: string, type?: ToastType, duration?: number) => string;
11
+ removeToast: (id: string) => void;
12
+ clearAll: () => void;
13
+ showError: (message: string) => string;
14
+ showSuccess: (message: string) => string;
15
+ showWarning: (message: string) => string;
16
+ showInfo: (message: string) => string;
17
+ };
@@ -0,0 +1 @@
1
+ .iconify{background-color:currentColor;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat;-webkit-mask-size:100% 100%;mask-size:100% 100%}.iconify,.iconify-color{display:inline-block;height:1em;width:1em}.iconify-color{background-repeat:no-repeat;background-size:100% 100%}.icon-[mdi-light--chevron-down]{--svg:url("data:image/svg+xml;charset=utf-8,%3Csvg width='24' height='24' viewBox='0 0 24 24'%3E%3Cpath fill='currentColor' d='m5.84 9.59 5.66 5.66 5.66-5.66-.71-.7-4.95 4.95-4.95-4.95z'/%3E%3C/svg%3E")}.icon-[mdi-light--chevron-down].iconify{-webkit-mask-image:var(--svg);mask-image:var(--svg)}.icon-[mdi-light--chevron-down].iconify-color{background-image:var(--svg)}.icon-[mdi-light--chevron-left]{--svg:url("data:image/svg+xml;charset=utf-8,%3Csvg width='24' height='24' viewBox='0 0 24 24'%3E%3Cpath fill='currentColor' d='M14.41 18.16 8.75 12.5l5.66-5.66.7.71-4.95 4.95 4.95 4.95z'/%3E%3C/svg%3E")}.icon-[mdi-light--chevron-left].iconify{-webkit-mask-image:var(--svg);mask-image:var(--svg)}.icon-[mdi-light--chevron-left].iconify-color{background-image:var(--svg)}.icon-[mdi-light--chevron-right]{--svg:url("data:image/svg+xml;charset=utf-8,%3Csvg width='24' height='24' viewBox='0 0 24 24'%3E%3Cpath fill='currentColor' d='m8.59 18.16 5.66-5.66-5.66-5.66-.7.71 4.95 4.95-4.95 4.95z'/%3E%3C/svg%3E")}.icon-[mdi-light--chevron-right].iconify{-webkit-mask-image:var(--svg);mask-image:var(--svg)}.icon-[mdi-light--chevron-right].iconify-color{background-image:var(--svg)}.icon-[mdi-light--chevron-up]{--svg:url("data:image/svg+xml;charset=utf-8,%3Csvg width='24' height='24' viewBox='0 0 24 24'%3E%3Cpath fill='currentColor' d='m5.84 15.41 5.66-5.66 5.66 5.66-.71.7-4.95-4.95-4.95 4.95z'/%3E%3C/svg%3E")}.icon-[mdi-light--chevron-up].iconify{-webkit-mask-image:var(--svg);mask-image:var(--svg)}.icon-[mdi-light--chevron-up].iconify-color{background-image:var(--svg)}.icon-[mdi-light--eye]{--svg:url("data:image/svg+xml;charset=utf-8,%3Csvg width='24' height='24' viewBox='0 0 24 24'%3E%3Cpath fill='currentColor' d='M11.5 18c4 0 7.46-2.22 9.24-5.5C18.96 9.22 15.5 7 11.5 7s-7.46 2.22-9.24 5.5C4.04 15.78 7.5 18 11.5 18m0-12c4.56 0 8.5 2.65 10.36 6.5C20 16.35 16.06 19 11.5 19S3 16.35 1.14 12.5C3 8.65 6.94 6 11.5 6m0 2C14 8 16 10 16 12.5S14 17 11.5 17 7 15 7 12.5 9 8 11.5 8m0 1A3.5 3.5 0 0 0 8 12.5a3.5 3.5 0 0 0 3.5 3.5 3.5 3.5 0 0 0 3.5-3.5A3.5 3.5 0 0 0 11.5 9'/%3E%3C/svg%3E")}.icon-[mdi-light--eye].iconify{-webkit-mask-image:var(--svg);mask-image:var(--svg)}.icon-[mdi-light--eye].iconify-color{background-image:var(--svg)}.icon-[mdi-light--eye-off]{--svg:url("data:image/svg+xml;charset=utf-8,%3Csvg width='24' height='24' viewBox='0 0 24 24'%3E%3Cpath fill='currentColor' d='M2.54 4.71 3.25 4 20 20.75l-.71.71-3.34-3.35c-1.37.57-2.87.89-4.45.89-4.56 0-8.5-2.65-10.36-6.5.97-2 2.49-3.67 4.36-4.82zM11.5 18c1.29 0 2.53-.23 3.67-.66l-1.12-1.13c-.73.5-1.6.79-2.55.79C9 17 7 15 7 12.5c0-.95.29-1.82.79-2.55L6.24 8.41a10.64 10.64 0 0 0-3.98 4.09C4.04 15.78 7.5 18 11.5 18m9.24-5.5C18.96 9.22 15.5 7 11.5 7c-1.15 0-2.27.19-3.31.53l-.78-.78C8.68 6.26 10.06 6 11.5 6c4.56 0 8.5 2.65 10.36 6.5a11.47 11.47 0 0 1-4.07 4.63l-.72-.73c1.53-.96 2.8-2.3 3.67-3.9M11.5 8C14 8 16 10 16 12.5c0 .82-.22 1.58-.6 2.24l-.74-.74c.22-.46.34-.96.34-1.5A3.5 3.5 0 0 0 11.5 9c-.54 0-1.04.12-1.5.34l-.74-.74c.66-.38 1.42-.6 2.24-.6M8 12.5a3.5 3.5 0 0 0 3.5 3.5c.67 0 1.29-.19 1.82-.5L8.5 10.68c-.31.53-.5 1.15-.5 1.82'/%3E%3C/svg%3E")}.icon-[mdi-light--eye-off].iconify{-webkit-mask-image:var(--svg);mask-image:var(--svg)}.icon-[mdi-light--eye-off].iconify-color{background-image:var(--svg)}.icon-[mdi-light--unfold-more-horizontal]{--svg:url("data:image/svg+xml;charset=utf-8,%3Csvg width='24' height='24' viewBox='0 0 24 24'%3E%3Cpath fill='currentColor' d='m15.74 8.83-.7.71L11.5 6 7.96 9.54l-.7-.71 4.24-4.24zm0 7.34-4.24 4.24-4.24-4.24.7-.71L11.5 19l3.54-3.54z'/%3E%3C/svg%3E")}.icon-[mdi-light--unfold-more-horizontal].iconify{-webkit-mask-image:var(--svg);mask-image:var(--svg)}.icon-[mdi-light--unfold-more-horizontal].iconify-color{background-image:var(--svg)}
package/package.json CHANGED
@@ -1,60 +1,80 @@
1
1
  {
2
2
  "name": "@pathscale/ui",
3
- "version": "0.1.0",
4
- "description": "Highly opinionated SolidJS component library — batteries and kitchen sink included, but optimized and shiny.",
5
- "keywords": ["solid", "solidjs"],
6
- "homepage": "https://github.com/pathscale/ui",
7
- "bugs": {
8
- "url": "https://github.com/pathscale/ui/issues"
9
- },
3
+ "version": "0.1.1",
4
+ "author": "pathscale",
10
5
  "repository": {
11
6
  "type": "git",
12
7
  "url": "https://github.com/pathscale/ui"
13
8
  },
14
9
  "license": "MIT",
15
- "author": "pathscale",
16
- "sideEffects": false,
17
- "type": "module",
18
- "exports": {
19
- ".": {
20
- "types": "./dist/index.d.ts",
21
- "solid": "./dist/index.jsx",
22
- "default": "./dist/index.js"
23
- },
24
- "./*": {
25
- "types": "./dist/components/*/index.d.ts",
26
- "solid": "./dist/components/*/index.jsx",
27
- "default": "./dist/components/*/index.js"
28
- }
10
+ "description": "Highly opinionated SolidJS component library — batteries and kitchen sink included, but optimized and shiny.",
11
+ "files": [
12
+ "dist"
13
+ ],
14
+ "homepage": "https://github.com/pathscale/ui",
15
+ "keywords": [
16
+ "solid",
17
+ "solidjs"
18
+ ],
19
+ "bugs": {
20
+ "url": "https://github.com/pathscale/ui/issues"
29
21
  },
30
22
  "main": "./dist/index.js",
23
+ "module": "./dist/index.js",
31
24
  "types": "./dist/index.d.ts",
32
- "typesVersions": {
33
- "*": {
34
- "*": ["./dist/index.d.ts"]
35
- }
36
- },
37
- "files": ["dist"],
38
- "scripts": {
39
- "build": "tsup",
40
- "clean": "rm -rf dist node_modules",
41
- "dev": "vite serve playground --host",
42
- "format": "biome format --write",
43
- "lint": "biome lint --write"
44
- },
45
25
  "devDependencies": {
46
26
  "@biomejs/biome": "1.9.4",
47
- "@tailwindcss/vite": "^4.1.6",
27
+ "@felte/solid": "^1.2.11",
28
+ "@felte/validator-zod": "^1.0.15",
29
+ "@iconify/json": "^2.2.342",
30
+ "@iconify/utils": "^2.3.0",
31
+ "@rsbuild/core": "^1.3.20",
32
+ "@rsbuild/plugin-solid": "^1.0.5",
33
+ "@rslib/core": "^0.9.0",
34
+ "@tanstack/solid-table": "^8.21.3",
48
35
  "@types/bun": "^1.2.12",
49
- "esbuild-plugin-solid": "^0.6.0",
50
- "tailwindcss": "^4.1.6",
51
- "tsup": "^8.4.0",
36
+ "babel-preset-solid": "^1.9.6",
37
+ "clsx": "^2.1.1",
38
+ "cssnano": "^7.0.7",
39
+ "postcss": "^8.5.4",
40
+ "postcss-cli": "^11.0.1",
41
+ "svgo": "^3.3.2",
42
+ "tailwind-merge": "^3.3.0",
52
43
  "typescript": "^5.8.3",
53
- "vite": "^6.3.5",
54
- "vite-plugin-solid": "^2.11.6",
55
- "vite-tsconfig-paths": "^5.1.4"
44
+ "zod": "^3.22.4",
45
+ "cally": "^0.8.0"
46
+ },
47
+ "dependencies": {
48
+ "@iconify/tailwind4": "^1.0.6",
49
+ "@solid-primitives/event-listener": "^2.3.0",
50
+ "@solid-primitives/intersection-observer": "^2.1.3",
51
+ "@solid-primitives/keyboard": "^1.2.5",
52
+ "@solid-primitives/media": "^2.2.5",
53
+ "@solid-primitives/props": "^3.1.8",
54
+ "@solid-primitives/resize-observer": "^2.0.22",
55
+ "@solid-primitives/scheduled": "^1.4.1",
56
+ "@solid-primitives/scroll": "^2.0.20",
57
+ "@solid-primitives/storage": "^2.1.1",
58
+ "@solid-primitives/utils": "^6.2.1",
59
+ "rsbuild-plugin-iconify": "^1.0.3",
60
+ "solid-js": "^1.9.7"
56
61
  },
57
62
  "peerDependencies": {
58
- "solid-js": "^1.8"
59
- }
63
+ "@felte/solid": "^1.2.0",
64
+ "@felte/validator-zod": "^1.0.0",
65
+ "@tanstack/solid-table": "^8.0.0",
66
+ "solid-js": "^1.9",
67
+ "zod": "^3.22.0"
68
+ },
69
+ "scripts": {
70
+ "build": "rslib build && bun scripts/copy-css.js",
71
+ "build:watch": "rslib build --watch",
72
+ "dev": "rslib dev",
73
+ "preview": "rslib preview",
74
+ "clean": "rm -rf dist node_modules",
75
+ "format": "bun biome format --write",
76
+ "lint": "bun biome lint --write"
77
+ },
78
+ "sideEffects": false,
79
+ "type": "module"
60
80
  }
@@ -1,33 +0,0 @@
1
- import { Component, ComponentProps } from 'solid-js';
2
- import { C as ConfigVariants, a as ClassProps, V as VariantProps } from './classes-B_S9K-9I.js';
3
-
4
- declare const avatarVariants: {
5
- (props?: (ConfigVariants<{
6
- size: {
7
- sm: string;
8
- md: string;
9
- lg: string;
10
- };
11
- shape: {
12
- circle: string;
13
- rounded: string;
14
- };
15
- variant: {
16
- filled: string;
17
- outlined: string;
18
- ghost: string;
19
- };
20
- }> & ClassProps) | undefined): string;
21
- variantKeys: ("size" | "shape" | "variant")[];
22
- };
23
-
24
- type AvatarVariantProps = VariantProps<typeof avatarVariants>;
25
- type AvatarProps = AvatarVariantProps & ClassProps & ComponentProps<"img"> & {
26
- src?: string;
27
- dataSrc?: string;
28
- alt?: string;
29
- text?: string;
30
- };
31
- declare const Avatar: Component<AvatarProps>;
32
-
33
- export { Avatar as A, type AvatarProps as a, avatarVariants as b };
@@ -1,63 +0,0 @@
1
- import * as solid_js from 'solid-js';
2
- import { ValidComponent } from 'solid-js';
3
- import { PolymorphicProps, PolymorphicButtonSharedProps, PolymorphicButtonElementProps } from './components/polymorphic/index.js';
4
- import { C as ConfigVariants, a as ClassProps, V as VariantProps } from './classes-B_S9K-9I.js';
5
-
6
- declare const buttonVariants: {
7
- (props?: (ConfigVariants<{
8
- size: {
9
- sm: string;
10
- md: string;
11
- lg: string;
12
- };
13
- color: {
14
- inverse: string;
15
- primary: string;
16
- secondary: string;
17
- tertiary: string;
18
- accent: string;
19
- positive: string;
20
- destructive: string;
21
- };
22
- align: {
23
- start: string;
24
- center: string;
25
- end: string;
26
- };
27
- shape: {
28
- circle: string;
29
- rounded: string;
30
- };
31
- spacing: {
32
- 0: string;
33
- xs: string;
34
- sm: string;
35
- md: string;
36
- lg: string;
37
- };
38
- loading: {
39
- true: string;
40
- false: string;
41
- };
42
- stretched: {
43
- true: string;
44
- false: string;
45
- };
46
- variant: {
47
- fill: string[];
48
- gray: string[];
49
- ghost: string[];
50
- };
51
- }> & ClassProps) | undefined): string;
52
- variantKeys: ("size" | "color" | "align" | "shape" | "spacing" | "loading" | "stretched" | "variant")[];
53
- };
54
-
55
- type ButtonVariantProps = VariantProps<typeof buttonVariants>;
56
- type ButtonSharedProps<T extends ValidComponent = "button"> = PolymorphicButtonSharedProps<T> & ClassProps;
57
- type ButtonElementProps = PolymorphicButtonElementProps & ButtonSharedProps & {
58
- "aria-busy": "true" | undefined;
59
- };
60
- type ButtonProps<T extends ValidComponent = "button"> = Partial<ButtonVariantProps> & Partial<ButtonSharedProps<T>>;
61
- declare const Button: <T extends ValidComponent = "button">(props: PolymorphicProps<T, ButtonProps<T>>) => solid_js.JSX.Element;
62
-
63
- export { Button as B, type ButtonElementProps as a, type ButtonProps as b, type ButtonSharedProps as c, type ButtonVariantProps as d };
@@ -1,34 +0,0 @@
1
- import { ComponentProps, JSX } from 'solid-js';
2
- import { C as ConfigVariants, a as ClassProps, V as VariantProps } from './classes-B_S9K-9I.js';
3
-
4
- declare const inputVariants: {
5
- (props?: (ConfigVariants<{
6
- color: {
7
- danger: string;
8
- success: string;
9
- warning: string;
10
- };
11
- rounded: {
12
- true: string;
13
- false: string;
14
- };
15
- expanded: {
16
- true: string;
17
- false: string;
18
- };
19
- loading: {
20
- true: string;
21
- false: string;
22
- };
23
- }> & ClassProps) | undefined): string;
24
- variantKeys: ("color" | "rounded" | "loading" | "expanded")[];
25
- };
26
-
27
- type InputProps = Partial<VariantProps<typeof inputVariants> & ClassProps & ComponentProps<"input">> & {
28
- leftIcon?: JSX.Element;
29
- rightIcon?: JSX.Element;
30
- passwordReveal?: boolean;
31
- };
32
- declare const Input: (props: InputProps) => JSX.Element;
33
-
34
- export { Input as I, type InputProps as a };
@@ -1,37 +0,0 @@
1
- import { Component, ComponentProps } from 'solid-js';
2
- import { C as ConfigVariants, a as ClassProps, V as VariantProps } from './classes-B_S9K-9I.js';
3
-
4
- declare const textareaVariants: {
5
- (props?: (ConfigVariants<{
6
- size: {
7
- sm: string;
8
- md: string;
9
- lg: string;
10
- };
11
- color: {
12
- primary: string;
13
- info: string;
14
- success: string;
15
- warning: string;
16
- danger: string;
17
- };
18
- loading: {
19
- true: string;
20
- false: string;
21
- };
22
- resize: {
23
- none: string;
24
- both: string;
25
- x: string;
26
- y: string;
27
- };
28
- }> & ClassProps) | undefined): string;
29
- variantKeys: ("size" | "color" | "loading" | "resize")[];
30
- };
31
-
32
- type TextareaProps = VariantProps<typeof textareaVariants> & ClassProps & ComponentProps<"textarea"> & {
33
- hasCounter?: boolean;
34
- };
35
- declare const Textarea: Component<TextareaProps>;
36
-
37
- export { Textarea as T, type TextareaProps as a };