stargazer-ui 1.5.21 → 1.5.23

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 (377) hide show
  1. package/.babelrc.json +10 -0
  2. package/.eslintrc.cjs +18 -0
  3. package/.gitattributes +2 -0
  4. package/LICENSE +21 -0
  5. package/dev/index.html +16 -0
  6. package/dev/index.jsx +46 -0
  7. package/dev/index.scss +74 -0
  8. package/dev/pages/ButtonPage.jsx +44 -0
  9. package/dev/pages/CardPage.jsx +81 -0
  10. package/dev/pages/DropdownPage.jsx +32 -0
  11. package/dev/pages/FormPage.jsx +163 -0
  12. package/dev/pages/ListPage.jsx +52 -0
  13. package/dev/pages/ModalPage.jsx +38 -0
  14. package/dev/pages/OverlayPage.jsx +39 -0
  15. package/dev/pages/components.jsx +19 -0
  16. package/dev/stargazerui.css +3762 -0
  17. package/dev/stargazerui.css.map +1 -0
  18. package/dev/test.jsx +87 -0
  19. package/package.json +79 -1
  20. package/rollup.config.js +140 -0
  21. package/scripts/writePackageJsons.js +42 -0
  22. package/src/Bar/Bar.tsx +0 -0
  23. package/src/Bar/Bar.type.ts +9 -0
  24. package/src/Bar/index.ts +0 -0
  25. package/src/Button/Button.tsx +20 -0
  26. package/src/Button/Button.types.ts +8 -0
  27. package/src/Button/index.ts +3 -0
  28. package/src/ButtonGroup/ButtonGroup.tsx +14 -0
  29. package/src/ButtonGroup/ButtonGroup.types.ts +8 -0
  30. package/src/ButtonGroup/index.ts +3 -0
  31. package/src/Card/Card.tsx +70 -0
  32. package/src/Card/Card.types.ts +33 -0
  33. package/src/Card/index.ts +3 -0
  34. package/src/CloseButton/CloseButton.tsx +14 -0
  35. package/src/CloseButton/CloseButton.types.ts +6 -0
  36. package/src/CloseButton/index.ts +3 -0
  37. package/src/Dropdown/Dropdown.tsx +441 -0
  38. package/src/Dropdown/Dropdown.types.ts +60 -0
  39. package/src/Dropdown/index.ts +4 -0
  40. package/src/FileUploadButton/FileUploadButton.tsx +27 -0
  41. package/src/FileUploadButton/FileUploadButton.types.ts +9 -0
  42. package/src/FileUploadButton/index.ts +3 -0
  43. package/src/FloatingLabel/FloatingLabel.tsx +22 -0
  44. package/src/FloatingLabel/FloatingLabel.types.ts +11 -0
  45. package/src/FloatingLabel/index.ts +3 -0
  46. package/src/Form/Form.tsx +399 -0
  47. package/src/Form/Form.types.ts +169 -0
  48. package/src/Form/FormSelect.tsx +620 -0
  49. package/src/Form/index.ts +4 -0
  50. package/src/InputGroup/InputGroup.tsx +46 -0
  51. package/src/InputGroup/InputGroup.types.ts +22 -0
  52. package/src/InputGroup/index.ts +4 -0
  53. package/src/List/List.tsx +112 -0
  54. package/src/List/List.types.ts +34 -0
  55. package/src/List/index.ts +4 -0
  56. package/src/Modal/Modal.tsx +229 -0
  57. package/src/Modal/Modal.types.ts +49 -0
  58. package/src/Modal/index.ts +4 -0
  59. package/src/Nav/Nav.tsx +43 -0
  60. package/src/Nav/Nav.types.ts +21 -0
  61. package/src/Nav/index.ts +4 -0
  62. package/src/NavBar/Navbar.tsx +57 -0
  63. package/src/NavBar/Navbar.types.ts +24 -0
  64. package/src/NavBar/index.ts +4 -0
  65. package/src/NavDropdown/NavDropdown.tsx +93 -0
  66. package/src/NavDropdown/NavDropdown.types.ts +7 -0
  67. package/src/NavDropdown/index.ts +3 -0
  68. package/src/Overlay/Overlay.tsx +305 -0
  69. package/src/Overlay/Overlay.types.ts +24 -0
  70. package/{Overlay/index.d.ts → src/Overlay/index.ts} +3 -3
  71. package/src/Popout/Popout.tsx +155 -0
  72. package/src/Popout/Popout.types.ts +42 -0
  73. package/src/Popout/index.ts +3 -0
  74. package/src/Spinner/Spinner.tsx +15 -0
  75. package/src/Spinner/Spinner.types.ts +7 -0
  76. package/src/Spinner/index.ts +3 -0
  77. package/src/Table/Table.tsx +16 -0
  78. package/src/Table/Table.types.ts +9 -0
  79. package/src/Table/index.ts +3 -0
  80. package/src/Tabs/Tabs.tsx +233 -0
  81. package/src/Tabs/Tabs.types.ts +52 -0
  82. package/src/Tabs/index.ts +3 -0
  83. package/src/ToggleButton/ToggleButton.tsx +21 -0
  84. package/src/ToggleButton/ToggleButton.types.ts +8 -0
  85. package/src/ToggleButton/index.ts +3 -0
  86. package/src/assets/tooltip-pointer.svg +3 -0
  87. package/src/assets/warning.svg +39 -0
  88. package/{hooks/index.d.ts → src/hooks/index.ts} +7 -6
  89. package/src/hooks/useClassname.ts +5 -0
  90. package/src/hooks/useDraggable.ts +186 -0
  91. package/src/hooks/useKeepElementFocused.ts +37 -0
  92. package/src/hooks/useQueryParams.ts +12 -0
  93. package/src/hooks/useScreenSize.ts +24 -0
  94. package/src/index.ts +21 -0
  95. package/src/styles/_Card.scss +166 -0
  96. package/src/styles/_CloseButton.scss +51 -0
  97. package/src/styles/_CustomButton.scss +134 -0
  98. package/src/styles/_Dropdown.scss +127 -0
  99. package/src/styles/_FloatingLabel.scss +56 -0
  100. package/src/styles/_Forms.scss +7 -0
  101. package/src/styles/_Grid.scss +178 -0
  102. package/src/styles/_InputGroup.scss +71 -0
  103. package/src/styles/_List.scss +62 -0
  104. package/src/styles/_Modal.scss +234 -0
  105. package/src/styles/_ModalOld.scss +242 -0
  106. package/src/styles/_Nav.scss +36 -0
  107. package/src/styles/_NavBar.scss +116 -0
  108. package/src/styles/_NavDropdown.scss +33 -0
  109. package/src/styles/_OffCanvas.scss +260 -0
  110. package/src/styles/_OverLay.scss +79 -0
  111. package/src/styles/_Popout.scss +75 -0
  112. package/src/styles/_Resizable.scss +64 -0
  113. package/src/styles/_Spinner.scss +19 -0
  114. package/src/styles/_Table.scss +34 -0
  115. package/src/styles/_Tabs.scss +129 -0
  116. package/src/styles/_colors.scss +510 -0
  117. package/src/styles/_components.scss +41 -0
  118. package/src/styles/_functions.scss +134 -0
  119. package/src/styles/_mixins.scss +26 -0
  120. package/src/styles/_reset.scss +239 -0
  121. package/src/styles/_utilities.scss +2480 -0
  122. package/src/styles/_variables.scss +164 -0
  123. package/src/styles/forms/_FormCheck.scss +270 -0
  124. package/src/styles/forms/_FormControl.scss +135 -0
  125. package/src/styles/forms/_FormGroup.scss +26 -0
  126. package/src/styles/forms/_FormLabel.scss +3 -0
  127. package/src/styles/forms/_FormSelect.scss +222 -0
  128. package/src/styles/forms/_FormSlider.scss +116 -0
  129. package/src/styles/forms/_FormText.scss +6 -0
  130. package/{utils/BaseTypes.d.ts → src/utils/BaseTypes.ts} +32 -25
  131. package/src/utils/ContrastingColor.ts +25 -0
  132. package/src/utils/CreateSyntheticEvent.ts +30 -0
  133. package/src/utils/FileImportExport.js +50 -0
  134. package/src/utils/IsInputKey.ts +18 -0
  135. package/src/utils/MergeClassnames.ts +5 -0
  136. package/src/utils/MergeRefs.ts +12 -0
  137. package/src/utils/createFastContext.tsx +119 -0
  138. package/src/utils/index.ts +4 -0
  139. package/src/vite-env.d.ts +1 -0
  140. package/tsconfig-build.json +4 -0
  141. package/tsconfig.json +79 -0
  142. package/tsconfig.node.json +10 -0
  143. package/types/BaseTypes.d.ts +19 -0
  144. package/{Button → types/components/Button}/Button.types.d.ts +2 -1
  145. package/types/components/Button/index.d.ts +1 -0
  146. package/{Card → types/components/Card}/Card.d.ts +12 -12
  147. package/{Card → types/components/Card}/Card.types.d.ts +1 -3
  148. package/types/components/Card/index.d.ts +1 -0
  149. package/{CloseButton → types/components/CloseButton}/CloseButton.types.d.ts +1 -1
  150. package/types/components/CloseButton/index.d.ts +1 -0
  151. package/types/components/Dropdown/Dropdown.d.ts +71 -0
  152. package/{Dropdown → types/components/Dropdown}/Dropdown.types.d.ts +12 -13
  153. package/types/components/Dropdown/index.d.ts +1 -0
  154. package/{FloatingLabel → types/components/FloatingLabel}/FloatingLabel.types.d.ts +1 -1
  155. package/types/components/FloatingLabel/index.d.ts +1 -0
  156. package/types/components/Form/Form.d.ts +17 -0
  157. package/types/components/Form/Form.types.d.ts +50 -0
  158. package/types/components/Form/index.d.ts +1 -0
  159. package/types/components/InputGroup/InputGroup.d.ts +6 -0
  160. package/types/components/InputGroup/InputGroup.types.d.ts +10 -0
  161. package/types/components/InputGroup/index.d.ts +1 -0
  162. package/{Modal → types/components/Modal}/Modal.d.ts +19 -19
  163. package/{Modal → types/components/Modal}/Modal.types.d.ts +2 -3
  164. package/types/components/Modal/index.d.ts +1 -0
  165. package/{Nav → types/components/Nav}/Nav.d.ts +12 -12
  166. package/{Nav → types/components/Nav}/Nav.types.d.ts +1 -1
  167. package/types/components/Nav/index.d.ts +1 -0
  168. package/{NavBar → types/components/NavBar}/Navbar.d.ts +8 -7
  169. package/{NavBar → types/components/NavBar}/Navbar.types.d.ts +1 -2
  170. package/types/components/NavBar/index.d.ts +1 -0
  171. package/types/components/NavDropdown/NavDropdown.d.ts +35 -0
  172. package/{NavDropdown → types/components/NavDropdown}/NavDropdown.types.d.ts +1 -2
  173. package/types/components/NavDropdown/index.d.ts +1 -0
  174. package/{Popout → types/components/Popout}/Popout.d.ts +6 -6
  175. package/{Popout → types/components/Popout}/Popout.types.d.ts +1 -1
  176. package/types/components/Popout/index.d.ts +1 -0
  177. package/types/components/Spinner/index.d.ts +1 -0
  178. package/{Table → types/components/Table}/Table.types.d.ts +1 -1
  179. package/types/components/Table/index.d.ts +1 -0
  180. package/{Tabs → types/components/Tabs}/Tabs.types.d.ts +2 -12
  181. package/types/components/Tabs/index.d.ts +1 -0
  182. package/types/components/ToggleButton/ToggleButton.d.ts +9 -0
  183. package/types/components/ToggleButton/ToggleButton.types.d.ts +0 -0
  184. package/types/components/ToggleButton/index.d.ts +1 -0
  185. package/types/components/index.d.ts +16 -0
  186. package/types/index.d.ts +1 -0
  187. package/vite.config.js +57 -0
  188. package/vite.config.js.timestamp-1708777378490-e94428ceb2bf9.mjs +42 -0
  189. package/Bar/Bar.type.d.ts +0 -6
  190. package/Bar/index.js +0 -2
  191. package/Bar/index.js.map +0 -1
  192. package/Bar/package.json +0 -1
  193. package/Button/Button.js +0 -15
  194. package/Button/Button.js.map +0 -1
  195. package/Button/index.d.ts +0 -3
  196. package/Button/index.js +0 -7
  197. package/Button/index.js.map +0 -1
  198. package/Button/package.json +0 -1
  199. package/ButtonGroup/ButtonGroup.d.ts +0 -4
  200. package/ButtonGroup/ButtonGroup.js +0 -11
  201. package/ButtonGroup/ButtonGroup.js.map +0 -1
  202. package/ButtonGroup/ButtonGroup.types.d.ts +0 -7
  203. package/ButtonGroup/index.d.ts +0 -3
  204. package/ButtonGroup/index.js +0 -7
  205. package/ButtonGroup/index.js.map +0 -1
  206. package/ButtonGroup/package.json +0 -1
  207. package/Card/Card.js +0 -42
  208. package/Card/Card.js.map +0 -1
  209. package/Card/index.d.ts +0 -3
  210. package/Card/index.js +0 -7
  211. package/Card/index.js.map +0 -1
  212. package/Card/package.json +0 -1
  213. package/CloseButton/CloseButton.js +0 -11
  214. package/CloseButton/CloseButton.js.map +0 -1
  215. package/CloseButton/index.d.ts +0 -3
  216. package/CloseButton/index.js +0 -7
  217. package/CloseButton/index.js.map +0 -1
  218. package/CloseButton/package.json +0 -1
  219. package/Dropdown/Dropdown.d.ts +0 -39
  220. package/Dropdown/Dropdown.js +0 -380
  221. package/Dropdown/Dropdown.js.map +0 -1
  222. package/Dropdown/index.d.ts +0 -4
  223. package/Dropdown/index.js +0 -8
  224. package/Dropdown/index.js.map +0 -1
  225. package/Dropdown/package.json +0 -1
  226. package/FileUploadButton/FileUploadButton.d.ts +0 -4
  227. package/FileUploadButton/FileUploadButton.js +0 -20
  228. package/FileUploadButton/FileUploadButton.js.map +0 -1
  229. package/FileUploadButton/FileUploadButton.types.d.ts +0 -7
  230. package/FileUploadButton/index.d.ts +0 -3
  231. package/FileUploadButton/index.js +0 -7
  232. package/FileUploadButton/index.js.map +0 -1
  233. package/FileUploadButton/package.json +0 -1
  234. package/FloatingLabel/FloatingLabel.js +0 -15
  235. package/FloatingLabel/FloatingLabel.js.map +0 -1
  236. package/FloatingLabel/index.d.ts +0 -3
  237. package/FloatingLabel/index.js +0 -7
  238. package/FloatingLabel/index.js.map +0 -1
  239. package/FloatingLabel/package.json +0 -1
  240. package/Form/Form.d.ts +0 -37
  241. package/Form/Form.js +0 -227
  242. package/Form/Form.js.map +0 -1
  243. package/Form/Form.types.d.ts +0 -159
  244. package/Form/FormSelect.d.ts +0 -12
  245. package/Form/FormSelect.js +0 -492
  246. package/Form/FormSelect.js.map +0 -1
  247. package/Form/index.d.ts +0 -4
  248. package/Form/index.js +0 -8
  249. package/Form/index.js.map +0 -1
  250. package/Form/package.json +0 -1
  251. package/InputGroup/InputGroup.d.ts +0 -7
  252. package/InputGroup/InputGroup.js +0 -31
  253. package/InputGroup/InputGroup.js.map +0 -1
  254. package/InputGroup/InputGroup.types.d.ts +0 -17
  255. package/InputGroup/index.d.ts +0 -4
  256. package/InputGroup/index.js +0 -7
  257. package/InputGroup/index.js.map +0 -1
  258. package/InputGroup/package.json +0 -1
  259. package/List/List.d.ts +0 -14
  260. package/List/List.js +0 -77
  261. package/List/List.js.map +0 -1
  262. package/List/List.types.d.ts +0 -28
  263. package/List/index.d.ts +0 -3
  264. package/List/index.js +0 -7
  265. package/List/index.js.map +0 -1
  266. package/List/package.json +0 -1
  267. package/Modal/Modal.js +0 -157
  268. package/Modal/Modal.js.map +0 -1
  269. package/Modal/index.d.ts +0 -3
  270. package/Modal/index.js +0 -7
  271. package/Modal/index.js.map +0 -1
  272. package/Modal/package.json +0 -1
  273. package/Nav/Nav.js +0 -29
  274. package/Nav/Nav.js.map +0 -1
  275. package/Nav/index.d.ts +0 -4
  276. package/Nav/index.js +0 -7
  277. package/Nav/index.js.map +0 -1
  278. package/Nav/package.json +0 -1
  279. package/NavBar/Navbar.js +0 -36
  280. package/NavBar/Navbar.js.map +0 -1
  281. package/NavBar/index.d.ts +0 -4
  282. package/NavBar/index.js +0 -8
  283. package/NavBar/index.js.map +0 -1
  284. package/NavBar/package.json +0 -1
  285. package/NavDropdown/NavDropdown.d.ts +0 -19
  286. package/NavDropdown/NavDropdown.js +0 -75
  287. package/NavDropdown/NavDropdown.js.map +0 -1
  288. package/NavDropdown/index.d.ts +0 -3
  289. package/NavDropdown/index.js +0 -7
  290. package/NavDropdown/index.js.map +0 -1
  291. package/NavDropdown/package.json +0 -1
  292. package/Overlay/Overlay.d.ts +0 -4
  293. package/Overlay/Overlay.js +0 -241
  294. package/Overlay/Overlay.js.map +0 -1
  295. package/Overlay/Overlay.types.d.ts +0 -22
  296. package/Overlay/index.js +0 -7
  297. package/Overlay/index.js.map +0 -1
  298. package/Overlay/package.json +0 -1
  299. package/Popout/Popout.js +0 -111
  300. package/Popout/Popout.js.map +0 -1
  301. package/Popout/index.d.ts +0 -3
  302. package/Popout/index.js +0 -7
  303. package/Popout/index.js.map +0 -1
  304. package/Popout/package.json +0 -1
  305. package/Spinner/Spinner.js +0 -11
  306. package/Spinner/Spinner.js.map +0 -1
  307. package/Spinner/index.d.ts +0 -3
  308. package/Spinner/index.js +0 -7
  309. package/Spinner/index.js.map +0 -1
  310. package/Spinner/package.json +0 -1
  311. package/Table/Table.js +0 -12
  312. package/Table/Table.js.map +0 -1
  313. package/Table/index.d.ts +0 -3
  314. package/Table/index.js +0 -7
  315. package/Table/index.js.map +0 -1
  316. package/Table/package.json +0 -1
  317. package/Tabs/Tabs.js +0 -162
  318. package/Tabs/Tabs.js.map +0 -1
  319. package/Tabs/index.d.ts +0 -3
  320. package/Tabs/index.js +0 -7
  321. package/Tabs/index.js.map +0 -1
  322. package/Tabs/package.json +0 -1
  323. package/ToggleButton/ToggleButton.d.ts +0 -4
  324. package/ToggleButton/ToggleButton.js +0 -18
  325. package/ToggleButton/ToggleButton.js.map +0 -1
  326. package/ToggleButton/ToggleButton.types.d.ts +0 -7
  327. package/ToggleButton/index.d.ts +0 -3
  328. package/ToggleButton/index.js +0 -7
  329. package/ToggleButton/index.js.map +0 -1
  330. package/ToggleButton/package.json +0 -1
  331. package/hooks/index.js +0 -7
  332. package/hooks/index.js.map +0 -1
  333. package/hooks/package.json +0 -1
  334. package/hooks/useClassname.d.ts +0 -2
  335. package/hooks/useClassname.js +0 -7
  336. package/hooks/useClassname.js.map +0 -1
  337. package/hooks/useDraggable.d.ts +0 -23
  338. package/hooks/useDraggable.js +0 -147
  339. package/hooks/useDraggable.js.map +0 -1
  340. package/hooks/useKeepElementFocused.d.ts +0 -2
  341. package/hooks/useKeepElementFocused.js +0 -37
  342. package/hooks/useKeepElementFocused.js.map +0 -1
  343. package/hooks/useQueryParams.d.ts +0 -2
  344. package/hooks/useQueryParams.js +0 -13
  345. package/hooks/useQueryParams.js.map +0 -1
  346. package/hooks/useScreenSize.d.ts +0 -5
  347. package/hooks/useScreenSize.js +0 -21
  348. package/hooks/useScreenSize.js.map +0 -1
  349. package/index.d.ts +0 -19
  350. package/index.js +0 -20
  351. package/index.js.map +0 -1
  352. package/styles/stargazerui.css +0 -6658
  353. package/styles/stargazerui.css.map +0 -1
  354. package/utils/ContrastingColor.d.ts +0 -1
  355. package/utils/CreateSyntheticEvent.d.ts +0 -2
  356. package/utils/CreateSyntheticEvent.js +0 -33
  357. package/utils/CreateSyntheticEvent.js.map +0 -1
  358. package/utils/IsInputKey.d.ts +0 -7
  359. package/utils/IsInputKey.js +0 -20
  360. package/utils/IsInputKey.js.map +0 -1
  361. package/utils/MergeClassnames.d.ts +0 -2
  362. package/utils/MergeClassnames.js +0 -7
  363. package/utils/MergeClassnames.js.map +0 -1
  364. package/utils/MergeRefs.d.ts +0 -1
  365. package/utils/MergeRefs.js +0 -16
  366. package/utils/MergeRefs.js.map +0 -1
  367. package/utils/createFastContext.d.ts +0 -16
  368. package/utils/createFastContext.js +0 -101
  369. package/utils/createFastContext.js.map +0 -1
  370. package/utils/index.d.ts +0 -4
  371. /package/{Button → types/components/Button}/Button.d.ts +0 -0
  372. /package/{CloseButton → types/components/CloseButton}/CloseButton.d.ts +0 -0
  373. /package/{FloatingLabel → types/components/FloatingLabel}/FloatingLabel.d.ts +0 -0
  374. /package/{Spinner → types/components/Spinner}/Spinner.d.ts +0 -0
  375. /package/{Spinner → types/components/Spinner}/Spinner.types.d.ts +0 -0
  376. /package/{Table → types/components/Table}/Table.d.ts +0 -0
  377. /package/{Tabs → types/components/Tabs}/Tabs.d.ts +0 -0
@@ -0,0 +1,35 @@
1
+ import React from "react";
2
+ import { NavDropdownType } from "./NavDropdown.types";
3
+ declare const _default: React.ForwardRefExoticComponent<Omit<NavDropdownType, "ref"> & React.RefAttributes<HTMLDivElement>> & {
4
+ Toggle: React.ForwardRefExoticComponent<(Omit<{
5
+ children: React.ReactNode;
6
+ className?: string | undefined;
7
+ navDropdown?: boolean | undefined;
8
+ as?: React.ElementType<any, keyof React.JSX.IntrinsicElements> | undefined;
9
+ variant?: string | undefined;
10
+ } & React.ClassAttributes<HTMLAnchorElement> & React.AnchorHTMLAttributes<HTMLAnchorElement>, "ref"> | Omit<{
11
+ children: React.ReactNode;
12
+ className?: string | undefined;
13
+ navDropdown?: boolean | undefined;
14
+ as?: React.ElementType<any, keyof React.JSX.IntrinsicElements> | undefined;
15
+ variant?: string | undefined;
16
+ } & React.ClassAttributes<HTMLButtonElement> & React.ButtonHTMLAttributes<HTMLButtonElement>, "ref"> | Omit<{
17
+ children: React.ReactNode;
18
+ className?: string | undefined;
19
+ navDropdown?: boolean | undefined;
20
+ as?: React.ElementType<any, keyof React.JSX.IntrinsicElements> | undefined;
21
+ variant?: string | undefined;
22
+ } & React.ClassAttributes<HTMLElement> & React.HTMLAttributes<HTMLElement>, "ref">) & React.RefAttributes<HTMLAnchorElement | HTMLButtonElement>>;
23
+ Menu: React.ForwardRefExoticComponent<Omit<import("../Dropdown/Dropdown.types").DropdownMenuType, "ref"> & React.RefAttributes<HTMLUListElement>>;
24
+ Item: React.ForwardRefExoticComponent<(Omit<{
25
+ children: React.ReactNode;
26
+ as?: React.ElementType<any, keyof React.JSX.IntrinsicElements> | undefined;
27
+ className?: string | undefined;
28
+ } & React.ClassAttributes<HTMLAnchorElement> & React.AnchorHTMLAttributes<HTMLAnchorElement>, "ref"> | Omit<{
29
+ children: React.ReactNode;
30
+ as?: React.ElementType<any, keyof React.JSX.IntrinsicElements> | undefined;
31
+ className?: string | undefined;
32
+ } & React.ClassAttributes<HTMLButtonElement> & React.ButtonHTMLAttributes<HTMLButtonElement>, "ref">) & React.RefAttributes<HTMLAnchorElement | HTMLButtonElement>>;
33
+ Divider: React.ForwardRefExoticComponent<Omit<import("../Dropdown/Dropdown.types").DropdownDividerType, "ref"> & React.RefAttributes<HTMLHRElement>>;
34
+ };
35
+ export default _default;
@@ -1,6 +1,5 @@
1
1
  import { DropdownType } from "../Dropdown/Dropdown.types";
2
- import { BaseDivType } from "../utils";
3
2
  export type NavDropdownType = {
4
3
  toggleProps?: any;
5
4
  menuProps?: any;
6
- } & DropdownType & BaseDivType;
5
+ } & DropdownType;
@@ -0,0 +1 @@
1
+ export { default } from "./NavDropdown";
@@ -3,16 +3,16 @@ import { PopoutType, PopoutBodyType, PopoutFooterType, PopoutTextType, PopoutTit
3
3
  declare const _default: React.ForwardRefExoticComponent<Omit<PopoutType, "ref"> & React.RefAttributes<HTMLDialogElement>> & {
4
4
  Header: React.ForwardRefExoticComponent<(Omit<{
5
5
  children: React.ReactNode;
6
- className?: string;
7
- as?: React.ElementType;
6
+ className?: string | undefined;
7
+ as?: React.ElementType<any, keyof React.JSX.IntrinsicElements> | undefined;
8
8
  } & React.ClassAttributes<HTMLDivElement> & React.HTMLAttributes<HTMLDivElement>, "ref"> | Omit<{
9
9
  children: React.ReactNode;
10
- className?: string;
11
- as?: React.ElementType;
10
+ className?: string | undefined;
11
+ as?: React.ElementType<any, keyof React.JSX.IntrinsicElements> | undefined;
12
12
  } & React.ClassAttributes<HTMLHeadingElement> & React.HTMLAttributes<HTMLHeadingElement>, "ref"> | Omit<{
13
13
  children: React.ReactNode;
14
- className?: string;
15
- as?: React.ElementType;
14
+ className?: string | undefined;
15
+ as?: React.ElementType<any, keyof React.JSX.IntrinsicElements> | undefined;
16
16
  } & React.ClassAttributes<HTMLSpanElement> & React.HTMLAttributes<HTMLSpanElement>, "ref">) & React.RefAttributes<HTMLDivElement | HTMLHeadingElement | HTMLSpanElement>>;
17
17
  Title: React.ForwardRefExoticComponent<Omit<PopoutTitleType, "ref"> & React.RefAttributes<HTMLHeadingElement>>;
18
18
  Body: React.ForwardRefExoticComponent<Omit<PopoutBodyType, "ref"> & React.RefAttributes<HTMLDivElement>>;
@@ -1,5 +1,5 @@
1
1
  import { ReactNode } from "react";
2
- import { BaseDialogType, BaseDivType, BaseHeadingType, BaseParagraphType, BaseSpanType } from "../utils/BaseTypes";
2
+ import { BaseDialogType, BaseDivType, BaseHeadingType, BaseParagraphType, BaseSpanType } from "../../BaseTypes";
3
3
  export type PopoutType = {
4
4
  children: ReactNode;
5
5
  initialPosition?: {
@@ -0,0 +1 @@
1
+ export { default } from "./Popout";
@@ -0,0 +1 @@
1
+ export { default } from "./Spinner";
@@ -1,5 +1,5 @@
1
1
  import { ReactNode } from "react";
2
- import { BaseTableType } from "../utils/BaseTypes";
2
+ import { BaseTableType } from "../../BaseTypes";
3
3
  export type TableType = {
4
4
  children: ReactNode;
5
5
  size?: string;
@@ -0,0 +1 @@
1
+ export { default } from "./Table";
@@ -1,11 +1,10 @@
1
- import { BaseButtonType, BaseDivType } from "../utils/BaseTypes";
1
+ /// <reference types="react" />
2
+ import { BaseButtonType, BaseDivType } from "../../BaseTypes";
2
3
  export type TabsContextType = {
3
4
  activeTab: string;
4
5
  setActiveTab: React.Dispatch<React.SetStateAction<string>>;
5
6
  controlId: string;
6
7
  activeClass: string;
7
- onTabChange: Function | undefined;
8
- setQueryParam?: Function;
9
8
  };
10
9
  export type TabsType = {
11
10
  children: React.ReactNode;
@@ -13,20 +12,11 @@ export type TabsType = {
13
12
  controlId: string;
14
13
  activeClassName?: string;
15
14
  defaultActive: string;
16
- active?: string;
17
- onTabChange?: Function;
18
- queryParam?: string;
19
- setQueryParam?: Function;
20
15
  } & BaseDivType;
21
16
  export type TabsControlsType = {
22
17
  children: React.ReactNode;
23
18
  className?: string;
24
19
  } & BaseDivType;
25
- export type TabsScrollButtonType = {
26
- className?: string;
27
- left?: boolean;
28
- controlsRef?: React.RefObject<HTMLDivElement>;
29
- } & BaseButtonType;
30
20
  export type TabsButtonType = {
31
21
  children: React.ReactNode;
32
22
  className?: string;
@@ -0,0 +1 @@
1
+ export { default } from "./Tabs";
@@ -0,0 +1,9 @@
1
+ import React, { ReactNode } from "react";
2
+ import { BaseButtonType } from "../../BaseTypes";
3
+ type ToggleButtonType = {
4
+ children: ReactNode;
5
+ toggled?: boolean;
6
+ onClick?: <T>(event: T) => T;
7
+ } & BaseButtonType;
8
+ declare const ToggleButton: React.ForwardRefExoticComponent<Omit<ToggleButtonType, "ref"> & React.RefAttributes<HTMLButtonElement>>;
9
+ export default ToggleButton;
@@ -0,0 +1 @@
1
+ export { default } from "./ToggleButton";
@@ -0,0 +1,16 @@
1
+ export { default as Button } from "./Button";
2
+ export { default as Card } from "./Card";
3
+ export { default as CloseButton } from "./CloseButton";
4
+ export { default as Dropdown } from "./Dropdown";
5
+ export { default as FloatingLabel } from "./FloatingLabel";
6
+ export { default as Form } from "./Form";
7
+ export { default as InputGroup } from "./InputGroup";
8
+ export { default as Modal } from "./Modal";
9
+ export { default as Nav } from "./Nav";
10
+ export { default as NavBar } from "./NavBar";
11
+ export { default as NavDropdown } from "./NavDropdown";
12
+ export { default as Popout } from "./Popout";
13
+ export { default as Spinner } from "./Spinner";
14
+ export { default as Table } from "./Table";
15
+ export { default as Tabs } from "./Tabs";
16
+ export { default as ToggleButton } from "./ToggleButton";
@@ -0,0 +1 @@
1
+ export * from "./components";
package/vite.config.js ADDED
@@ -0,0 +1,57 @@
1
+ import { defineConfig } from 'vite';
2
+ import react from '@vitejs/plugin-react';
3
+ import dts from 'vite-plugin-dts';
4
+ //these are needed to preserve the folder structure so every component has its own entry point
5
+ import path, { extname, relative, resolve } from 'path'
6
+ import { fileURLToPath } from 'node:url'
7
+ import { glob } from 'glob'
8
+
9
+ export default defineConfig(({ command, mode }) => {
10
+ if (command === 'serve') {
11
+ // Dev config
12
+ return {
13
+ plugins: [react(), dts()],
14
+ root: path.resolve(__dirname, 'dev'),
15
+ build: {
16
+ outDir: path.resolve(__dirname, 'dist'),
17
+ },
18
+ };
19
+ } else {
20
+ // Build config
21
+ return {
22
+ plugins: [react(), dts()],
23
+ build: {
24
+ lib: {
25
+ entry: path.resolve(__dirname, 'src/index.ts'),
26
+ name: 'ui',
27
+ formats: ['es'],
28
+ fileName: (format) => `ui.${format}.js`
29
+ },
30
+ rollupOptions: {
31
+ external: ['react', 'react-dom', 'react/jsx-runtime'],
32
+ input: Object.fromEntries(
33
+ glob.sync('src/**/*.{ts,tsx}').map(file => [
34
+ // The name of the entry point
35
+ // lib/nested/foo.ts becomes nested/foo
36
+ relative(
37
+ 'src',
38
+ file.slice(0, file.length - extname(file).length)
39
+ ),
40
+ // The absolute path to the entry file
41
+ // lib/nested/foo.ts becomes /project/lib/nested/foo.ts
42
+ fileURLToPath(new URL(file, import.meta.url))
43
+ ])
44
+ ),
45
+ output: {
46
+ inlineDynamicImports: false,
47
+ entryFileNames: '[name].js',
48
+ globals: {
49
+ react: 'React',
50
+ 'react-dom': 'ReactDOM',
51
+ }
52
+ }
53
+ }
54
+ }
55
+ };
56
+ }
57
+ });
@@ -0,0 +1,42 @@
1
+ // vite.config.js
2
+ import { defineConfig } from "file:///E:/TestApps/stargazer-ui/node_modules/vite/dist/node/index.js";
3
+ import react from "file:///E:/TestApps/stargazer-ui/node_modules/@vitejs/plugin-react/dist/index.mjs";
4
+ import dts from "file:///E:/TestApps/stargazer-ui/node_modules/vite-plugin-dts/dist/index.mjs";
5
+ import path from "path";
6
+ var __vite_injected_original_dirname = "E:\\TestApps\\stargazer-ui";
7
+ var vite_config_default = defineConfig(({ command, mode }) => {
8
+ if (command === "serve") {
9
+ return {
10
+ plugins: [react()],
11
+ root: path.resolve(__vite_injected_original_dirname, "dev"),
12
+ build: {
13
+ outDir: path.resolve(__vite_injected_original_dirname, "dist")
14
+ }
15
+ };
16
+ } else {
17
+ return {
18
+ plugins: [react(), dts()],
19
+ build: {
20
+ lib: {
21
+ entry: path.resolve(__vite_injected_original_dirname, "src/index.js"),
22
+ name: "ui",
23
+ formats: ["es", "umd"],
24
+ fileName: (format) => `ui.${format}.js`
25
+ },
26
+ rollupOptions: {
27
+ external: ["react", "react-dom"],
28
+ output: {
29
+ globals: {
30
+ react: "React",
31
+ "react-dom": "ReactDOM"
32
+ }
33
+ }
34
+ }
35
+ }
36
+ };
37
+ }
38
+ });
39
+ export {
40
+ vite_config_default as default
41
+ };
42
+ //# sourceMappingURL=data:application/json;base64,ewogICJ2ZXJzaW9uIjogMywKICAic291cmNlcyI6IFsidml0ZS5jb25maWcuanMiXSwKICAic291cmNlc0NvbnRlbnQiOiBbImNvbnN0IF9fdml0ZV9pbmplY3RlZF9vcmlnaW5hbF9kaXJuYW1lID0gXCJFOlxcXFxUZXN0QXBwc1xcXFxzdGFyZ2F6ZXItdWlcIjtjb25zdCBfX3ZpdGVfaW5qZWN0ZWRfb3JpZ2luYWxfZmlsZW5hbWUgPSBcIkU6XFxcXFRlc3RBcHBzXFxcXHN0YXJnYXplci11aVxcXFx2aXRlLmNvbmZpZy5qc1wiO2NvbnN0IF9fdml0ZV9pbmplY3RlZF9vcmlnaW5hbF9pbXBvcnRfbWV0YV91cmwgPSBcImZpbGU6Ly8vRTovVGVzdEFwcHMvc3RhcmdhemVyLXVpL3ZpdGUuY29uZmlnLmpzXCI7aW1wb3J0IHsgZGVmaW5lQ29uZmlnIH0gZnJvbSAndml0ZSc7XHJcbmltcG9ydCByZWFjdCBmcm9tICdAdml0ZWpzL3BsdWdpbi1yZWFjdCc7XHJcbmltcG9ydCBkdHMgZnJvbSAndml0ZS1wbHVnaW4tZHRzJztcclxuaW1wb3J0IHBhdGggZnJvbSAncGF0aCc7XHJcblxyXG5leHBvcnQgZGVmYXVsdCBkZWZpbmVDb25maWcoKHsgY29tbWFuZCwgbW9kZSB9KSA9PiB7XHJcbiAgaWYgKGNvbW1hbmQgPT09ICdzZXJ2ZScpIHtcclxuICAgIC8vIERldiBjb25maWdcclxuICAgIHJldHVybiB7XHJcbiAgICAgIHBsdWdpbnM6IFtyZWFjdCgpXSxcclxuICAgICAgcm9vdDogcGF0aC5yZXNvbHZlKF9fZGlybmFtZSwgJ2RldicpLFxyXG4gICAgICBidWlsZDoge1xyXG4gICAgICAgIG91dERpcjogcGF0aC5yZXNvbHZlKF9fZGlybmFtZSwgJ2Rpc3QnKSxcclxuICAgICAgfSxcclxuICAgIH07XHJcbiAgfSBlbHNlIHtcclxuICAgIC8vIEJ1aWxkIGNvbmZpZ1xyXG4gICAgcmV0dXJuIHtcclxuICAgICAgcGx1Z2luczogW3JlYWN0KCksIGR0cygpXSxcclxuICAgICAgYnVpbGQ6IHtcclxuICAgICAgICBsaWI6IHtcclxuICAgICAgICAgIGVudHJ5OiBwYXRoLnJlc29sdmUoX19kaXJuYW1lLCAnc3JjL2luZGV4LmpzJyksXHJcbiAgICAgICAgICBuYW1lOiAndWknLFxyXG4gICAgICAgICAgZm9ybWF0czogWydlcycsICd1bWQnXSxcclxuICAgICAgICAgIGZpbGVOYW1lOiAoZm9ybWF0KSA9PiBgdWkuJHtmb3JtYXR9LmpzYFxyXG4gICAgICAgIH0sXHJcbiAgICAgICAgcm9sbHVwT3B0aW9uczoge1xyXG4gICAgICAgICAgZXh0ZXJuYWw6IFsncmVhY3QnLCAncmVhY3QtZG9tJ10sXHJcbiAgICAgICAgICBvdXRwdXQ6IHtcclxuICAgICAgICAgICAgZ2xvYmFsczoge1xyXG4gICAgICAgICAgICAgIHJlYWN0OiAnUmVhY3QnLFxyXG4gICAgICAgICAgICAgICdyZWFjdC1kb20nOiAnUmVhY3RET00nXHJcbiAgICAgICAgICAgIH1cclxuICAgICAgICAgIH1cclxuICAgICAgICB9XHJcbiAgICAgIH1cclxuICAgIH07XHJcbiAgfVxyXG59KTsiXSwKICAibWFwcGluZ3MiOiAiO0FBQWdRLFNBQVMsb0JBQW9CO0FBQzdSLE9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/index.js DELETED
@@ -1,2 +0,0 @@
1
- 'use client';
2
- //# sourceMappingURL=index.js.map
package/Bar/index.js.map DELETED
@@ -1 +0,0 @@
1
- {"version":3,"file":"index.js","sources":[],"sourcesContent":[],"names":[],"mappings":";"}
package/Bar/package.json DELETED
@@ -1 +0,0 @@
1
- {"name":"stargazer-ui/Bar","private":false,"module":"./index.js","types":"./index.d.ts","peerDependencies":{"lodash":"^4.17.21","react":">=17.0.0","react-dom":">=17.0.0"}}
package/Button/Button.js DELETED
@@ -1,15 +0,0 @@
1
- 'use client';
2
- import { jsx } from 'react/jsx-runtime';
3
- import { forwardRef } from 'react';
4
- import mergeClassnames from '../utils/MergeClassnames.js';
5
-
6
- const Button = forwardRef(({ children, variant = "primary", className, ...rest }, ref) => {
7
- const variants = ["primary", "secondary", "success", "info", "warning", "danger", "dark", "light", "custom"]; //["red", "blue", "yellow", "green", "purple"]
8
- const variantTest = variants.find(variantTest => variantTest === variant) ? variant : "primary";
9
- const computedClassnames = mergeClassnames("sg-button", `sg-button-${variantTest}`, className);
10
- return (jsx("button", { ref: ref, type: "button", className: computedClassnames, ...rest, children: children }));
11
- });
12
- Button.displayName = "Button";
13
-
14
- export { Button as default };
15
- //# sourceMappingURL=Button.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"Button.js","sources":["../../src/Button/Button.tsx"],"sourcesContent":[null],"names":["_jsx"],"mappings":";;;;;AAMM,MAAA,MAAM,GAAG,UAAU,CAAiC,CAAC,EAAC,QAAQ,EAAE,OAAO,GAAC,SAAS,EAAE,SAAS,EAAE,GAAG,IAAI,EAAC,EAAE,GAAG,KAAI;IACjH,MAAM,QAAQ,GAAG,CAAC,SAAS,EAAE,WAAW,EAAE,SAAS,EAAE,MAAM,EAAE,SAAS,EAAE,QAAQ,EAAE,MAAM,EAAE,OAAO,EAAE,QAAQ,CAAC,CAAA;IAC5G,MAAM,WAAW,GAAG,QAAQ,CAAC,IAAI,CAAC,WAAW,IAAI,WAAW,KAAK,OAAO,CAAC,GAAG,OAAO,GAAG,SAAS;AAC/F,IAAA,MAAM,kBAAkB,GAAG,eAAe,CAAC,WAAW,EAAE,CAAa,UAAA,EAAA,WAAW,CAAE,CAAA,EAAE,SAAS,CAAC;AAC9F,IAAA,QACIA,GAAQ,CAAA,QAAA,EAAA,EAAA,GAAG,EAAE,GAAG,EAAE,IAAI,EAAC,QAAQ,EAAC,SAAS,EAAE,kBAAkB,EAAM,GAAA,IAAI,YAClE,QAAQ,EAAA,CACJ;AAEjB,CAAC;AAED,MAAM,CAAC,WAAW,GAAG,QAAQ;;;;"}
package/Button/index.d.ts DELETED
@@ -1,3 +0,0 @@
1
- import Button from "./Button";
2
- export default Button;
3
- export type { ButtonType } from "./Button.types";
package/Button/index.js DELETED
@@ -1,7 +0,0 @@
1
- 'use client';
2
- import Button from './Button.js';
3
-
4
-
5
-
6
- export { Button as default };
7
- //# sourceMappingURL=index.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"index.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;"}
@@ -1 +0,0 @@
1
- {"name":"stargazer-ui/Button","private":false,"module":"./index.js","types":"./index.d.ts","peerDependencies":{"lodash":"^4.17.21","react":">=17.0.0","react-dom":">=17.0.0"}}
@@ -1,4 +0,0 @@
1
- import React from "react";
2
- import { ButtonGroupType } from "./ButtonGroup.types";
3
- declare const ButtonGroup: React.ForwardRefExoticComponent<Omit<ButtonGroupType, "ref"> & React.RefAttributes<HTMLDivElement>>;
4
- export default ButtonGroup;
@@ -1,11 +0,0 @@
1
- 'use client';
2
- import { jsx } from 'react/jsx-runtime';
3
- import { forwardRef } from 'react';
4
-
5
- const ButtonGroup = forwardRef(({ children, className, vertical = false, ...restProps }, ref) => {
6
- return (jsx("div", { ref: ref, role: "group", className: `sg-button-group${vertical ? "-vertical" : ""}${className ? " " + className : ""}`, ...restProps, children: children }));
7
- });
8
- ButtonGroup.displayName = "ButtonGroup";
9
-
10
- export { ButtonGroup as default };
11
- //# sourceMappingURL=ButtonGroup.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"ButtonGroup.js","sources":["../../src/ButtonGroup/ButtonGroup.tsx"],"sourcesContent":[null],"names":["_jsx"],"mappings":";;;;AAGM,MAAA,WAAW,GAAG,UAAU,CAAmC,CAAC,EAAE,QAAQ,EAAE,SAAS,EAAE,QAAQ,GAAC,KAAK,EAAE,GAAG,SAAS,EAAC,EAAE,GAAG,KAAI;AAC3H,IAAA,QACIA,GAAK,CAAA,KAAA,EAAA,EAAA,GAAG,EAAE,GAAG,EAAE,IAAI,EAAC,OAAO,EAAC,SAAS,EAAE,CAAkB,eAAA,EAAA,QAAQ,GAAG,WAAW,GAAG,EAAE,GAAG,SAAS,GAAG,GAAG,GAAC,SAAS,GAAG,EAAE,EAAE,EAAM,GAAA,SAAS,YACjI,QAAQ,EAAA,CACP;AAEd,CAAC;AAED,WAAW,CAAC,WAAW,GAAG,aAAa;;;;"}
@@ -1,7 +0,0 @@
1
- import { ReactNode } from "react";
2
- import { BaseDivType } from "../utils/BaseTypes";
3
- export type ButtonGroupType = {
4
- children: ReactNode;
5
- className?: string;
6
- vertical?: boolean;
7
- } & BaseDivType;
@@ -1,3 +0,0 @@
1
- import ButtonGroup from "./ButtonGroup";
2
- export default ButtonGroup;
3
- export type { ButtonGroupType } from "./ButtonGroup.types";
@@ -1,7 +0,0 @@
1
- 'use client';
2
- import ButtonGroup from './ButtonGroup.js';
3
-
4
-
5
-
6
- export { ButtonGroup as default };
7
- //# sourceMappingURL=index.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"index.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;"}
@@ -1 +0,0 @@
1
- {"name":"stargazer-ui/ButtonGroup","private":false,"module":"./index.js","types":"./index.d.ts","peerDependencies":{"lodash":"^4.17.21","react":">=17.0.0","react-dom":">=17.0.0"}}
package/Card/Card.js DELETED
@@ -1,42 +0,0 @@
1
- 'use client';
2
- import { jsx } from 'react/jsx-runtime';
3
- import { forwardRef } from 'react';
4
-
5
- const Card = forwardRef(({ children, className, variant, inverted = false, ...restProps }, ref) => {
6
- return (jsx("div", { ref: ref, className: `sg-card${className ? " " + className : ""}${variant ? " " + variant : ""}${inverted ? " inverted" : ""}`, ...restProps, children: children }));
7
- });
8
- Card.displayName = "Card";
9
- const Header = forwardRef(({ as = "div", className, children, ...restProps }, ref) => {
10
- let validAs = ["div", "span", "h1", "h2", "h3", "h4", "h5", "h6"];
11
- let Component = validAs.find(valid => valid === as) ? as : "div";
12
- return (jsx(Component, { ref: ref, className: `sg-card-header ${className}`, ...restProps, children: children }));
13
- });
14
- Header.displayName = "CardHeader";
15
- const Title = forwardRef(({ as = "h5", className, children, ...restProps }, ref) => {
16
- let validAs = ["h1", "h2", "h3", "h4", "h5", "h6"];
17
- let Component = validAs.find(valid => valid === as) ? as : "h5";
18
- return (jsx(Component, { ref: ref, className: `sg-card-title${className ? " " + className : ""}`, ...restProps, children: children }));
19
- });
20
- Title.displayName = "CardTitle";
21
- const Body = forwardRef(({ children, className, ...restProps }, ref) => {
22
- return (jsx("div", { ref: ref, className: `sg-card-body ${className}`, ...restProps, children: children }));
23
- });
24
- Body.displayName = "CardBody";
25
- const Text = forwardRef(({ children, className, ...restProps }, ref) => {
26
- return (jsx("p", { ref: ref, className: `sg-card-text ${className}`, ...restProps, children: children }));
27
- });
28
- Text.displayName = "CardText";
29
- const Footer = forwardRef(({ children, className, ...restProps }, ref) => {
30
- return (jsx("div", { ref: ref, className: `sg-card-footer ${className}`, ...restProps, children: children }));
31
- });
32
- Footer.displayName = "CardFooter";
33
- var Card$1 = Object.assign(Card, {
34
- Header: Header,
35
- Body: Body,
36
- Title: Title,
37
- Text: Text,
38
- Footer: Footer
39
- });
40
-
41
- export { Card$1 as default };
42
- //# sourceMappingURL=Card.js.map
package/Card/Card.js.map DELETED
@@ -1 +0,0 @@
1
- {"version":3,"file":"Card.js","sources":["../../src/Card/Card.tsx"],"sourcesContent":[null],"names":["_jsx"],"mappings":";;;;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GAAK,CAAA,KAAA,EAAA,EAAA,GAAG,EAAE,GAAG,EAAE,SAAS,EAAE,CAAkB,eAAA,EAAA,SAAS,EAAE,EAAM,GAAA,SAAS,YACjE,QAAQ,EAAA,CACP;AAEd,CAAC,CAAC;AACF,MAAM,CAAC,WAAW,GAAG,YAAY;AAEjC,aAAgB,MAAM,CAAC,MAAM,CAAC,IAAI,EAAE;AAChC,IAAA,MAAM,EAAE,MAAM;AACd,IAAA,IAAI,EAAE,IAAI;AACV,IAAA,KAAK,EAAE,KAAK;AACZ,IAAA,IAAI,EAAE,IAAI;AACV,IAAA,MAAM,EAAE;AACX,CAAA,CAAC;;;;"}
package/Card/index.d.ts DELETED
@@ -1,3 +0,0 @@
1
- import Card from "./Card";
2
- export default Card;
3
- export type { CardBodyType, CardFooterType, CardHeaderPossible, CardHeaderType, CardTextType, CardType } from "./Card.types";
package/Card/index.js DELETED
@@ -1,7 +0,0 @@
1
- 'use client';
2
- import Card from './Card.js';
3
-
4
-
5
-
6
- export { Card as default };
7
- //# sourceMappingURL=index.js.map
package/Card/index.js.map DELETED
@@ -1 +0,0 @@
1
- {"version":3,"file":"index.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;"}
package/Card/package.json DELETED
@@ -1 +0,0 @@
1
- {"name":"stargazer-ui/Card","private":false,"module":"./index.js","types":"./index.d.ts","peerDependencies":{"lodash":"^4.17.21","react":">=17.0.0","react-dom":">=17.0.0"}}
@@ -1,11 +0,0 @@
1
- 'use client';
2
- import { jsx } from 'react/jsx-runtime';
3
- import { forwardRef } from 'react';
4
-
5
- const CloseButton = forwardRef(({ className, variant = false, ...restProps }, ref) => {
6
- return (jsx("button", { ref: ref, className: `sg-button-close${variant ? " sg-button-close-white" : ""} ${className}`, ...restProps, children: jsx("span", { className: "sg-close-visually-hidden-label", children: "Close" }) }));
7
- });
8
- CloseButton.displayName = "CloseButton";
9
-
10
- export { CloseButton as default };
11
- //# sourceMappingURL=CloseButton.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"CloseButton.js","sources":["../../src/CloseButton/CloseButton.tsx"],"sourcesContent":[null],"names":["_jsx"],"mappings":";;;;AAIA,MAAM,WAAW,GAAG,UAAU,CAAsC,CAAC,EAAC,SAAS,EAAE,OAAO,GAAG,KAAK,EAAE,GAAG,SAAS,EAAC,EAAE,GAAG,KAAI;AACpH,IAAA,QACIA,GAAA,CAAA,QAAA,EAAA,EAAQ,GAAG,EAAE,GAAG,EAAE,SAAS,EAAE,CAAkB,eAAA,EAAA,OAAO,GAAG,wBAAwB,GAAG,EAAE,CAAA,CAAA,EAAI,SAAS,CAAA,CAAE,KAAM,SAAS,EAAA,QAAA,EAChHA,GAAM,CAAA,MAAA,EAAA,EAAA,SAAS,EAAC,gCAAgC,EAAa,QAAA,EAAA,OAAA,EAAA,CAAA,EAAA,CACxD;AAEjB,CAAC;AACD,WAAW,CAAC,WAAW,GAAG,aAAa;;;;"}
@@ -1,3 +0,0 @@
1
- import CloseButton from "./CloseButton";
2
- export default CloseButton;
3
- export type { CloseButtonType } from "./CloseButton.types";
@@ -1,7 +0,0 @@
1
- 'use client';
2
- import CloseButton from './CloseButton.js';
3
-
4
-
5
-
6
- export { CloseButton as default };
7
- //# sourceMappingURL=index.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"index.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;"}
@@ -1 +0,0 @@
1
- {"name":"stargazer-ui/CloseButton","private":false,"module":"./index.js","types":"./index.d.ts","peerDependencies":{"lodash":"^4.17.21","react":">=17.0.0","react-dom":">=17.0.0"}}
@@ -1,39 +0,0 @@
1
- import React from "react";
2
- import { DropdownContextType, DropdownDividerType, DropdownMenuType, DropdownToggleType, DropdownType } from "./Dropdown.types";
3
- export declare const DropdownContext: React.Context<DropdownContextType | null>;
4
- export declare const DropdownContextProvider: ({ children, value }: {
5
- children: React.ReactNode;
6
- value: DropdownContextType;
7
- }) => import("react/jsx-runtime").JSX.Element;
8
- export declare const useDropdownContext: () => DropdownContextType;
9
- export declare const Toggle: React.ForwardRefExoticComponent<Omit<DropdownToggleType, "ref"> & React.RefAttributes<HTMLButtonElement>>;
10
- export declare const Menu: React.ForwardRefExoticComponent<Omit<DropdownMenuType, "ref"> & React.RefAttributes<HTMLUListElement>>;
11
- export declare const Item: React.ForwardRefExoticComponent<(Omit<{
12
- children: React.ReactNode;
13
- as?: React.ElementType;
14
- className?: string;
15
- liProps: import("..").BaseLItemType;
16
- } & React.ClassAttributes<HTMLAnchorElement> & React.AnchorHTMLAttributes<HTMLAnchorElement>, "ref"> | Omit<{
17
- children: React.ReactNode;
18
- as?: React.ElementType;
19
- className?: string;
20
- liProps: import("..").BaseLItemType;
21
- } & React.ClassAttributes<HTMLButtonElement> & React.ButtonHTMLAttributes<HTMLButtonElement>, "ref">) & React.RefAttributes<HTMLAnchorElement | HTMLButtonElement>>;
22
- export declare const Divider: React.ForwardRefExoticComponent<Omit<DropdownDividerType, "ref"> & React.RefAttributes<HTMLHRElement>>;
23
- declare const _default: React.ForwardRefExoticComponent<Omit<DropdownType, "ref"> & React.RefAttributes<HTMLButtonElement>> & {
24
- Toggle: React.ForwardRefExoticComponent<Omit<DropdownToggleType, "ref"> & React.RefAttributes<HTMLButtonElement>>;
25
- Menu: React.ForwardRefExoticComponent<Omit<DropdownMenuType, "ref"> & React.RefAttributes<HTMLUListElement>>;
26
- Item: React.ForwardRefExoticComponent<(Omit<{
27
- children: React.ReactNode;
28
- as?: React.ElementType;
29
- className?: string;
30
- liProps: import("..").BaseLItemType;
31
- } & React.ClassAttributes<HTMLAnchorElement> & React.AnchorHTMLAttributes<HTMLAnchorElement>, "ref"> | Omit<{
32
- children: React.ReactNode;
33
- as?: React.ElementType;
34
- className?: string;
35
- liProps: import("..").BaseLItemType;
36
- } & React.ClassAttributes<HTMLButtonElement> & React.ButtonHTMLAttributes<HTMLButtonElement>, "ref">) & React.RefAttributes<HTMLAnchorElement | HTMLButtonElement>>;
37
- Divider: React.ForwardRefExoticComponent<Omit<DropdownDividerType, "ref"> & React.RefAttributes<HTMLHRElement>>;
38
- };
39
- export default _default;