fromsrc 0.0.2 → 0.0.21

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 (408) hide show
  1. package/dist/access.d.ts +7 -7
  2. package/dist/access.js +12 -5
  3. package/dist/adapter.js +8 -16
  4. package/dist/adapterbrowser.js +6 -10
  5. package/dist/adapternext.js +7 -18
  6. package/dist/adapterreactrouter.js +5 -9
  7. package/dist/adapterremix.js +8 -17
  8. package/dist/adaptertanstack.js +6 -10
  9. package/dist/algolia.js +43 -21
  10. package/dist/analytics.d.ts +1 -1
  11. package/dist/analytics.js +16 -10
  12. package/dist/ansi.js +76 -37
  13. package/dist/api.d.ts +10 -10
  14. package/dist/api.js +14 -11
  15. package/dist/audit.d.ts +6 -6
  16. package/dist/audit.js +29 -10
  17. package/dist/autotype.js +20 -10
  18. package/dist/batch.d.ts +6 -6
  19. package/dist/batch.js +16 -9
  20. package/dist/changelog.js +28 -14
  21. package/dist/changelogutil.d.ts +4 -4
  22. package/dist/changelogutil.js +33 -13
  23. package/dist/cli.d.ts +6 -6
  24. package/dist/cli.js +7 -3
  25. package/dist/client.d.ts +1 -1
  26. package/dist/codesample.d.ts +4 -4
  27. package/dist/codesample.js +63 -24
  28. package/dist/collapse.js +31 -13
  29. package/dist/collections.js +36 -16
  30. package/dist/components/accordion.d.ts +1 -1
  31. package/dist/components/accordion.js +5 -1
  32. package/dist/components/alert.d.ts +1 -1
  33. package/dist/components/alert.js +24 -13
  34. package/dist/components/announce.js +40 -17
  35. package/dist/components/autofill.js +17 -7
  36. package/dist/components/avatar.js +4 -4
  37. package/dist/components/avatarstack.js +2 -2
  38. package/dist/components/backtotop.d.ts +1 -1
  39. package/dist/components/backtotop.js +17 -4
  40. package/dist/components/badge.js +9 -4
  41. package/dist/components/banner.js +22 -5
  42. package/dist/components/breadcrumb.js +11 -4
  43. package/dist/components/breadcrumbnav.js +37 -21
  44. package/dist/components/button.js +23 -8
  45. package/dist/components/callout.d.ts +1 -1
  46. package/dist/components/callout.js +33 -29
  47. package/dist/components/changelog.js +21 -8
  48. package/dist/components/checkbox.js +32 -19
  49. package/dist/components/code.d.ts +1 -1
  50. package/dist/components/code.js +6 -3
  51. package/dist/components/codeblock.js +157 -39
  52. package/dist/components/codecopy.d.ts +1 -1
  53. package/dist/components/codecopy.js +36 -13
  54. package/dist/components/codegroup.js +87 -25
  55. package/dist/components/collapsible.d.ts +1 -1
  56. package/dist/components/collapsible.js +5 -1
  57. package/dist/components/command.d.ts +1 -1
  58. package/dist/components/command.js +42 -15
  59. package/dist/components/compare.js +20 -8
  60. package/dist/components/content.js +121 -79
  61. package/dist/components/copybutton.d.ts +1 -1
  62. package/dist/components/copybutton.js +14 -7
  63. package/dist/components/countdown.js +9 -3
  64. package/dist/components/create.js +34 -24
  65. package/dist/components/definition.js +11 -4
  66. package/dist/components/diffview.js +63 -29
  67. package/dist/components/divider.js +5 -1
  68. package/dist/components/docheader.js +8 -1
  69. package/dist/components/doclinkcard.js +27 -3
  70. package/dist/components/dropdown.d.ts +1 -1
  71. package/dist/components/dropdown.js +32 -11
  72. package/dist/components/dynamiccode.js +5 -3
  73. package/dist/components/editlink.js +35 -23
  74. package/dist/components/embed.js +15 -7
  75. package/dist/components/endpoint.d.ts +3 -3
  76. package/dist/components/endpoint.js +24 -9
  77. package/dist/components/errormessage.d.ts +1 -1
  78. package/dist/components/errormessage.js +4 -1
  79. package/dist/components/expandcode.d.ts +1 -1
  80. package/dist/components/expandcode.js +6 -2
  81. package/dist/components/feature.js +8 -1
  82. package/dist/components/featuregrid.d.ts +4 -4
  83. package/dist/components/featuregrid.js +7 -1
  84. package/dist/components/feedback.js +6 -2
  85. package/dist/components/feedbackwidget.js +10 -4
  86. package/dist/components/files.d.ts +1 -1
  87. package/dist/components/files.js +52 -18
  88. package/dist/components/folder.d.ts +1 -1
  89. package/dist/components/folder.js +21 -4
  90. package/dist/components/footer.js +5 -1
  91. package/dist/components/formlabel.d.ts +1 -1
  92. package/dist/components/formlabel.js +31 -18
  93. package/dist/components/github.js +43 -14
  94. package/dist/components/graph.js +38 -14
  95. package/dist/components/heading.js +36 -29
  96. package/dist/components/headingcopy.js +13 -5
  97. package/dist/components/hero.js +20 -14
  98. package/dist/components/highlight.d.ts +2 -2
  99. package/dist/components/highlight.js +14 -8
  100. package/dist/components/hover.d.ts +2 -2
  101. package/dist/components/hover.js +11 -4
  102. package/dist/components/icons.js +4 -1
  103. package/dist/components/inlinetoc.js +3 -1
  104. package/dist/components/input.js +13 -3
  105. package/dist/components/install.js +34 -24
  106. package/dist/components/kbd.js +19 -11
  107. package/dist/components/langicon.d.ts +1 -1
  108. package/dist/components/langicon.js +22 -17
  109. package/dist/components/language.d.ts +1 -1
  110. package/dist/components/language.js +12 -4
  111. package/dist/components/lastupdated.d.ts +2 -2
  112. package/dist/components/lastupdated.js +36 -12
  113. package/dist/components/link.d.ts +1 -1
  114. package/dist/components/linkcard.js +3 -1
  115. package/dist/components/list.d.ts +1 -1
  116. package/dist/components/list.js +4 -1
  117. package/dist/components/math.js +33 -8
  118. package/dist/components/mermaid.js +3 -3
  119. package/dist/components/mobilenav.d.ts +2 -1
  120. package/dist/components/mobilenav.js +116 -47
  121. package/dist/components/modal.d.ts +1 -1
  122. package/dist/components/modal.js +9 -2
  123. package/dist/components/navlink.js +17 -3
  124. package/dist/components/openapi.d.ts +1 -1
  125. package/dist/components/openapi.js +102 -32
  126. package/dist/components/openapischema.d.ts +1 -1
  127. package/dist/components/openapischema.js +29 -9
  128. package/dist/components/openapitags.js +6 -2
  129. package/dist/components/pagetransition.js +5 -3
  130. package/dist/components/pagination.js +3 -2
  131. package/dist/components/panel.js +91 -15
  132. package/dist/components/playground.d.ts +1 -1
  133. package/dist/components/playground.js +153 -50
  134. package/dist/components/popover.js +9 -7
  135. package/dist/components/prelink.js +40 -9
  136. package/dist/components/prevnext.d.ts +1 -1
  137. package/dist/components/prevnext.js +36 -16
  138. package/dist/components/progress.js +2 -2
  139. package/dist/components/property.js +3 -1
  140. package/dist/components/quote.d.ts +2 -2
  141. package/dist/components/quote.js +32 -4
  142. package/dist/components/radio.js +36 -18
  143. package/dist/components/rating.js +14 -3
  144. package/dist/components/recent.d.ts +1 -1
  145. package/dist/components/recent.js +26 -10
  146. package/dist/components/responsive.js +21 -13
  147. package/dist/components/results.js +8 -4
  148. package/dist/components/screenshot.js +61 -21
  149. package/dist/components/scrollprogress.js +9 -5
  150. package/dist/components/scrollspy.d.ts +2 -2
  151. package/dist/components/scrollspy.js +9 -3
  152. package/dist/components/search.js +47 -18
  153. package/dist/components/searchbutton.js +3 -1
  154. package/dist/components/searchdialog.js +35 -22
  155. package/dist/components/searcher.d.ts +1 -1
  156. package/dist/components/searcher.js +51 -26
  157. package/dist/components/select.js +27 -13
  158. package/dist/components/shortcuts.d.ts +1 -1
  159. package/dist/components/shortcuts.js +57 -38
  160. package/dist/components/sidebar.d.ts +2 -1
  161. package/dist/components/sidebar.js +221 -56
  162. package/dist/components/sidebarfilter.d.ts +1 -1
  163. package/dist/components/sidebarfilter.js +30 -6
  164. package/dist/components/sidebarscript.d.ts +5 -0
  165. package/dist/components/sidebarscript.js +18 -0
  166. package/dist/components/skeleton.js +15 -3
  167. package/dist/components/spinner.js +13 -3
  168. package/dist/components/status.js +20 -8
  169. package/dist/components/steps.js +3 -1
  170. package/dist/components/switch.js +4 -4
  171. package/dist/components/table.js +37 -12
  172. package/dist/components/tabnav.d.ts +1 -1
  173. package/dist/components/tabnav.js +48 -36
  174. package/dist/components/tabs.d.ts +1 -1
  175. package/dist/components/tabs.js +56 -40
  176. package/dist/components/tag.js +8 -3
  177. package/dist/components/terminal.js +14 -4
  178. package/dist/components/textarea.js +96 -82
  179. package/dist/components/theme.d.ts +1 -1
  180. package/dist/components/theme.js +25 -3
  181. package/dist/components/themeprovider.d.ts +4 -4
  182. package/dist/components/themeprovider.js +16 -5
  183. package/dist/components/toast.d.ts +1 -1
  184. package/dist/components/toast.js +23 -14
  185. package/dist/components/toc/default.d.ts +1 -1
  186. package/dist/components/toc/default.js +28 -13
  187. package/dist/components/toc/hook.js +28 -14
  188. package/dist/components/toc/index.js +8 -4
  189. package/dist/components/toc/inline.js +12 -2
  190. package/dist/components/toc/minimal.js +11 -5
  191. package/dist/components/toc/zigzag.d.ts +1 -1
  192. package/dist/components/toc/zigzag.js +37 -17
  193. package/dist/components/tocprogress.d.ts +1 -1
  194. package/dist/components/tocprogress.js +66 -34
  195. package/dist/components/tooltip.d.ts +1 -1
  196. package/dist/components/tooltip.js +20 -8
  197. package/dist/components/trigger.js +13 -5
  198. package/dist/components/twoslash.js +49 -26
  199. package/dist/components/typetable.js +23 -4
  200. package/dist/components/typewriter.js +6 -2
  201. package/dist/components/version.js +40 -14
  202. package/dist/components/video.js +25 -15
  203. package/dist/components/zoom.js +6 -2
  204. package/dist/config.d.ts +2 -2
  205. package/dist/config.js +56 -30
  206. package/dist/content.d.ts +5 -5
  207. package/dist/content.js +121 -57
  208. package/dist/contentcache.d.ts +10 -10
  209. package/dist/contentcache.js +9 -5
  210. package/dist/contentdiff.d.ts +4 -4
  211. package/dist/contentdiff.js +16 -8
  212. package/dist/contributors.d.ts +4 -4
  213. package/dist/contributors.js +49 -19
  214. package/dist/diff.d.ts +6 -6
  215. package/dist/diff.js +37 -16
  216. package/dist/draft.d.ts +11 -11
  217. package/dist/draft.js +9 -5
  218. package/dist/env.js +21 -7
  219. package/dist/export.js +4 -4
  220. package/dist/frontmatter.js +11 -9
  221. package/dist/github.js +60 -30
  222. package/dist/gitsource.d.ts +1 -1
  223. package/dist/gitsource.js +16 -9
  224. package/dist/hash.d.ts +6 -6
  225. package/dist/hash.js +19 -7
  226. package/dist/highlight.d.ts +4 -4
  227. package/dist/highlight.js +34 -14
  228. package/dist/hooks/anchor.js +26 -14
  229. package/dist/hooks/arrownav.js +25 -7
  230. package/dist/hooks/async.js +3 -3
  231. package/dist/hooks/battery.js +11 -3
  232. package/dist/hooks/breakpoint.js +10 -2
  233. package/dist/hooks/clickoutside.js +10 -3
  234. package/dist/hooks/clipboard-paste.js +7 -3
  235. package/dist/hooks/clipboard.d.ts +2 -2
  236. package/dist/hooks/clipboard.js +21 -15
  237. package/dist/hooks/copy.js +11 -6
  238. package/dist/hooks/countdown.js +1 -1
  239. package/dist/hooks/counter.js +1 -1
  240. package/dist/hooks/escapekey.js +6 -1
  241. package/dist/hooks/eventlistener.js +3 -1
  242. package/dist/hooks/eventsource.js +4 -2
  243. package/dist/hooks/eyedropper.js +7 -3
  244. package/dist/hooks/favicon.js +1 -1
  245. package/dist/hooks/fetch.js +12 -4
  246. package/dist/hooks/focustrap.js +20 -8
  247. package/dist/hooks/focuswithin.js +6 -2
  248. package/dist/hooks/form.d.ts +2 -2
  249. package/dist/hooks/form.js +15 -2
  250. package/dist/hooks/fullscreen.js +1 -1
  251. package/dist/hooks/geolocation.js +8 -8
  252. package/dist/hooks/hotkeys.js +19 -7
  253. package/dist/hooks/hover.d.ts +4 -1
  254. package/dist/hooks/hover.js +3 -1
  255. package/dist/hooks/idle.js +13 -3
  256. package/dist/hooks/infinitescroll.js +4 -2
  257. package/dist/hooks/interval.js +3 -1
  258. package/dist/hooks/inview.js +7 -3
  259. package/dist/hooks/keyboard.js +36 -12
  260. package/dist/hooks/keypress.js +6 -2
  261. package/dist/hooks/list.js +11 -1
  262. package/dist/hooks/longpress.js +3 -3
  263. package/dist/hooks/map.js +1 -1
  264. package/dist/hooks/measure.js +16 -7
  265. package/dist/hooks/mediarecorder.js +7 -3
  266. package/dist/hooks/networkstate.js +4 -2
  267. package/dist/hooks/os.js +12 -4
  268. package/dist/hooks/pagination.js +6 -4
  269. package/dist/hooks/permission.js +6 -2
  270. package/dist/hooks/queue.js +4 -2
  271. package/dist/hooks/readprogress.js +6 -2
  272. package/dist/hooks/resizeobserver.js +6 -4
  273. package/dist/hooks/script.js +1 -1
  274. package/dist/hooks/scrolllock.js +6 -2
  275. package/dist/hooks/scrollspy.js +4 -2
  276. package/dist/hooks/selection.js +6 -3
  277. package/dist/hooks/share.js +18 -9
  278. package/dist/hooks/speechrecognition.js +7 -3
  279. package/dist/hooks/stepper.js +4 -4
  280. package/dist/hooks/storage.js +9 -3
  281. package/dist/hooks/stylesheet.js +4 -2
  282. package/dist/hooks/textselection.js +6 -3
  283. package/dist/hooks/throttle.js +6 -2
  284. package/dist/hooks/undoredo.js +19 -11
  285. package/dist/hooks/vibrate.js +3 -1
  286. package/dist/hooks/viewtransition.js +8 -4
  287. package/dist/hooks/wakelock.js +12 -7
  288. package/dist/hooks/websocket.js +4 -2
  289. package/dist/hooks/windowsize.js +2 -2
  290. package/dist/i18n.d.ts +2 -2
  291. package/dist/i18n.js +27 -14
  292. package/dist/index.d.ts +1 -0
  293. package/dist/index.js +1 -0
  294. package/dist/lastmodified.js +11 -5
  295. package/dist/linkcheck.d.ts +6 -6
  296. package/dist/linkcheck.js +55 -14
  297. package/dist/llms.js +20 -4
  298. package/dist/manifest.js +7 -7
  299. package/dist/mcp.js +28 -22
  300. package/dist/mdtoc.d.ts +4 -4
  301. package/dist/mdtoc.js +11 -5
  302. package/dist/mdxscope.d.ts +2 -2
  303. package/dist/mdxscope.js +3 -1
  304. package/dist/meta.js +19 -7
  305. package/dist/migrate.js +35 -25
  306. package/dist/navgen.d.ts +8 -8
  307. package/dist/navgen.js +73 -30
  308. package/dist/navtree.d.ts +1 -1
  309. package/dist/navtree.js +39 -19
  310. package/dist/oembed.d.ts +4 -4
  311. package/dist/oembed.js +24 -18
  312. package/dist/ogimage.d.ts +11 -11
  313. package/dist/ogimage.js +24 -24
  314. package/dist/openapi.js +60 -33
  315. package/dist/openapiguard.js +21 -11
  316. package/dist/openapiutil.js +66 -20
  317. package/dist/orama.js +52 -34
  318. package/dist/pipeline.d.ts +4 -4
  319. package/dist/pipeline.js +4 -4
  320. package/dist/preload.d.ts +2 -2
  321. package/dist/preload.js +4 -4
  322. package/dist/ranking.d.ts +6 -6
  323. package/dist/ranking.js +39 -13
  324. package/dist/readtime.js +3 -1
  325. package/dist/redirects.d.ts +2 -2
  326. package/dist/redirects.js +20 -12
  327. package/dist/rehype.js +16 -9
  328. package/dist/rehypeautolink.d.ts +2 -2
  329. package/dist/rehypeautolink.js +25 -23
  330. package/dist/rehypecode.js +38 -28
  331. package/dist/rehypecopy.js +17 -13
  332. package/dist/rehypeinline.js +33 -27
  333. package/dist/rehypelinks.js +28 -20
  334. package/dist/rehyperaw.js +9 -3
  335. package/dist/rehypeslug.d.ts +1 -1
  336. package/dist/rehypeslug.js +23 -19
  337. package/dist/rehypetablewrap.d.ts +2 -2
  338. package/dist/rehypetablewrap.js +9 -5
  339. package/dist/rehypetoc.d.ts +1 -1
  340. package/dist/rehypetoc.js +15 -7
  341. package/dist/remark.js +28 -13
  342. package/dist/remarkadmonition.js +40 -14
  343. package/dist/remarkannotation.d.ts +2 -2
  344. package/dist/remarkannotation.js +26 -10
  345. package/dist/remarkbadge.js +43 -31
  346. package/dist/remarkblockmath.js +29 -15
  347. package/dist/remarkcallout.js +32 -14
  348. package/dist/remarkcaption.js +28 -16
  349. package/dist/remarkcodetitle.js +29 -13
  350. package/dist/remarkcolumns.js +22 -10
  351. package/dist/remarkdetails.js +34 -14
  352. package/dist/remarkdirective.js +47 -20
  353. package/dist/remarkembed.js +38 -22
  354. package/dist/remarkfiletree.js +29 -19
  355. package/dist/remarkfootnote.js +46 -18
  356. package/dist/remarkgfm.js +13 -8
  357. package/dist/remarkheadingid.js +16 -6
  358. package/dist/remarkimage.js +54 -34
  359. package/dist/remarkinclude.js +20 -8
  360. package/dist/remarkinstall.js +20 -12
  361. package/dist/remarklinkcard.js +33 -14
  362. package/dist/remarkmath.js +34 -15
  363. package/dist/remarkmermaid.js +10 -6
  364. package/dist/remarkmeta.d.ts +2 -2
  365. package/dist/remarkmeta.js +15 -5
  366. package/dist/remarkreadingtime.d.ts +2 -2
  367. package/dist/remarkreadingtime.js +3 -1
  368. package/dist/remarksteps.js +26 -14
  369. package/dist/remarkstructure.js +16 -10
  370. package/dist/remarktabs.js +31 -14
  371. package/dist/remarktoc.js +40 -24
  372. package/dist/remarkts2js.js +51 -40
  373. package/dist/remarktwoslash.d.ts +4 -4
  374. package/dist/remarktwoslash.js +24 -14
  375. package/dist/remarkvideo.d.ts +4 -4
  376. package/dist/remarkvideo.js +42 -16
  377. package/dist/schema.d.ts +14 -14
  378. package/dist/schema.js +2 -2
  379. package/dist/search.js +106 -48
  380. package/dist/searchindex.js +86 -34
  381. package/dist/searchpolicy.js +1 -1
  382. package/dist/searchscore.js +5 -5
  383. package/dist/searchtypo.js +30 -10
  384. package/dist/seo.d.ts +2 -2
  385. package/dist/seo.js +14 -14
  386. package/dist/shortcodes.d.ts +4 -4
  387. package/dist/shortcodes.js +25 -20
  388. package/dist/sitemap.js +18 -8
  389. package/dist/snippets.js +26 -18
  390. package/dist/source.js +75 -41
  391. package/dist/stats.d.ts +4 -4
  392. package/dist/stats.js +18 -12
  393. package/dist/testing.d.ts +7 -7
  394. package/dist/testing.js +74 -29
  395. package/dist/themeutil.d.ts +6 -6
  396. package/dist/themeutil.js +145 -27
  397. package/dist/typegen.js +31 -12
  398. package/dist/validate.js +19 -7
  399. package/dist/validator.d.ts +11 -11
  400. package/dist/validator.js +68 -19
  401. package/dist/versioning.d.ts +7 -7
  402. package/dist/versioning.js +27 -11
  403. package/dist/watcher.js +39 -15
  404. package/dist/webhook.d.ts +6 -6
  405. package/dist/webhook.js +34 -12
  406. package/dist/workspace.js +26 -12
  407. package/package.json +137 -137
  408. package/styles/reset.css +1 -1
@@ -13,26 +13,44 @@ function Table({
13
13
  caption,
14
14
  className = ""
15
15
  }) {
16
- const [sortKey, setSortKey] = useState(defaultSort ?? null);
17
- const [sortDir, setSortDir] = useState(defaultSort ? defaultDirection : null);
16
+ const [sortKey, setSortKey] = useState(
17
+ defaultSort ?? null
18
+ );
19
+ const [sortDir, setSortDir] = useState(
20
+ defaultSort ? defaultDirection : null
21
+ );
18
22
  const id = useId();
19
23
  const sorted = useMemo(() => {
20
- if (!sortKey || !sortDir) return data;
24
+ if (!sortKey || !sortDir) {
25
+ return data;
26
+ }
21
27
  return [...data].sort((a, b) => {
22
28
  const va = a[sortKey];
23
29
  const vb = b[sortKey];
24
- if (va === vb) return 0;
25
- if (va == null) return 1;
26
- if (vb == null) return -1;
27
- const cmp = va < vb ? -1 : 1;
30
+ if (va === vb) {
31
+ return 0;
32
+ }
33
+ if (va == null) {
34
+ return 1;
35
+ }
36
+ if (vb == null) {
37
+ return -1;
38
+ }
39
+ const na = typeof va === "number" ? va : String(va);
40
+ const nb = typeof vb === "number" ? vb : String(vb);
41
+ const cmp = na < nb ? -1 : na > nb ? 1 : 0;
28
42
  return sortDir === "asc" ? cmp : -cmp;
29
43
  });
30
44
  }, [data, sortKey, sortDir]);
31
45
  const handleSort = useCallback(
32
46
  (key) => {
33
47
  if (sortKey === key) {
34
- setSortDir(sortDir === "asc" ? "desc" : sortDir === "desc" ? null : "asc");
35
- if (sortDir === "desc") setSortKey(null);
48
+ setSortDir(
49
+ sortDir === "asc" ? "desc" : sortDir === "desc" ? null : "asc"
50
+ );
51
+ if (sortDir === "desc") {
52
+ setSortKey(null);
53
+ }
36
54
  } else {
37
55
  setSortKey(key);
38
56
  setSortDir("asc");
@@ -44,8 +62,12 @@ function Table({
44
62
  const getSortLabel = useCallback(
45
63
  (col) => {
46
64
  if (sortKey === col.key) {
47
- if (sortDir === "asc") return `${col.header}, sorted ascending`;
48
- if (sortDir === "desc") return `${col.header}, sorted descending`;
65
+ if (sortDir === "asc") {
66
+ return `${col.header}, sorted ascending`;
67
+ }
68
+ if (sortDir === "desc") {
69
+ return `${col.header}, sorted descending`;
70
+ }
49
71
  }
50
72
  return `${col.header}, sortable`;
51
73
  },
@@ -119,7 +141,10 @@ function Table({
119
141
  }
120
142
  );
121
143
  }
122
- const SortIcon = memo(function SortIcon2({ active, direction }) {
144
+ const SortIcon = memo(function SortIcon2({
145
+ active,
146
+ direction
147
+ }) {
123
148
  return /* @__PURE__ */ jsx(
124
149
  "svg",
125
150
  {
@@ -25,6 +25,6 @@ interface TabNavDropdownProps {
25
25
  tabs: NavTab[];
26
26
  label?: string;
27
27
  }
28
- declare function TabNavDropdown({ tabs, label }: TabNavDropdownProps): ReactNode;
28
+ declare function TabNavDropdown({ tabs, label, }: TabNavDropdownProps): ReactNode;
29
29
 
30
30
  export { type NavTab, TabNav, TabNavDropdown, type TabNavDropdownProps, type TabNavProps };
@@ -26,37 +26,50 @@ function TabNav({ tabs, label = "Navigation" }) {
26
26
  direction: "both",
27
27
  wrap: true
28
28
  });
29
- if (next === index) return;
29
+ if (next === index) {
30
+ return;
31
+ }
30
32
  e.preventDefault();
31
33
  refs.current[next]?.focus();
32
34
  },
33
35
  [tabs.length]
34
36
  );
35
- return /* @__PURE__ */ jsx("nav", { "aria-label": label, role: "tablist", className: "flex gap-1 p-1 bg-surface rounded-lg", children: tabs.map((tab, i) => {
36
- const active = isActive(tab);
37
- return /* @__PURE__ */ jsxs(
38
- Link,
39
- {
40
- ref: (el) => {
41
- refs.current[i] = el;
42
- },
43
- href: tab.href,
44
- role: "tab",
45
- tabIndex: active ? 0 : -1,
46
- "aria-selected": active,
47
- "aria-current": active ? "page" : void 0,
48
- onKeyDown: (e) => handleKeyDown(e, i),
49
- className: `flex items-center gap-2 px-3 py-1.5 rounded-md text-sm font-medium transition-colors ${active ? "bg-bg text-fg shadow-sm" : "text-muted hover:text-fg hover:bg-bg/50"}`,
50
- children: [
51
- tab.icon && /* @__PURE__ */ jsx("span", { className: "w-4 h-4", "aria-hidden": "true", children: tab.icon }),
52
- tab.label
53
- ]
54
- },
55
- tab.id
56
- );
57
- }) });
37
+ return /* @__PURE__ */ jsx(
38
+ "nav",
39
+ {
40
+ "aria-label": label,
41
+ role: "tablist",
42
+ className: "flex gap-1 p-1 bg-surface rounded-lg",
43
+ children: tabs.map((tab, i) => {
44
+ const active = isActive(tab);
45
+ return /* @__PURE__ */ jsxs(
46
+ Link,
47
+ {
48
+ ref: (el) => {
49
+ refs.current[i] = el;
50
+ },
51
+ href: tab.href,
52
+ role: "tab",
53
+ tabIndex: active ? 0 : -1,
54
+ "aria-selected": active,
55
+ "aria-current": active ? "page" : void 0,
56
+ onKeyDown: (e) => handleKeyDown(e, i),
57
+ className: `flex items-center gap-2 px-3 py-1.5 rounded-md text-sm font-medium transition-colors ${active ? "bg-bg text-fg shadow-sm" : "text-muted hover:text-fg hover:bg-bg/50"}`,
58
+ children: [
59
+ tab.icon && /* @__PURE__ */ jsx("span", { className: "w-4 h-4", "aria-hidden": "true", children: tab.icon }),
60
+ tab.label
61
+ ]
62
+ },
63
+ tab.id
64
+ );
65
+ })
66
+ }
67
+ );
58
68
  }
59
- function TabNavDropdown({ tabs, label = "Navigation" }) {
69
+ function TabNavDropdown({
70
+ tabs,
71
+ label = "Navigation"
72
+ }) {
60
73
  const pathname = usePathname();
61
74
  const [open, setOpen] = useState(false);
62
75
  const [focused, setFocused] = useState(0);
@@ -90,7 +103,7 @@ function TabNavDropdown({ tabs, label = "Navigation" }) {
90
103
  (e) => {
91
104
  if (e.key === "ArrowDown" || e.key === "ArrowUp") {
92
105
  e.preventDefault();
93
- openMenu(currentIndex >= 0 ? currentIndex : 0);
106
+ openMenu(Math.max(currentIndex, 0));
94
107
  }
95
108
  },
96
109
  [currentIndex, openMenu]
@@ -111,7 +124,9 @@ function TabNavDropdown({ tabs, label = "Navigation" }) {
111
124
  current: index,
112
125
  wrap: true
113
126
  });
114
- if (next === index) return;
127
+ if (next === index) {
128
+ return;
129
+ }
115
130
  e.preventDefault();
116
131
  setFocused(next);
117
132
  optionRefs.current[next]?.focus();
@@ -122,17 +137,14 @@ function TabNavDropdown({ tabs, label = "Navigation" }) {
122
137
  if (open) {
123
138
  closeMenu();
124
139
  } else {
125
- openMenu(currentIndex >= 0 ? currentIndex : 0);
140
+ openMenu(Math.max(currentIndex, 0));
126
141
  }
127
142
  }, [open, closeMenu, openMenu, currentIndex]);
128
- const handleBlur = useCallback(
129
- (e) => {
130
- if (!containerRef.current?.contains(e.relatedTarget)) {
131
- setOpen(false);
132
- }
133
- },
134
- []
135
- );
143
+ const handleBlur = useCallback((e) => {
144
+ if (!containerRef.current?.contains(e.relatedTarget)) {
145
+ setOpen(false);
146
+ }
147
+ }, []);
136
148
  return /* @__PURE__ */ jsxs("nav", { "aria-label": label, className: "relative", ref: containerRef, children: [
137
149
  /* @__PURE__ */ jsxs(
138
150
  "button",
@@ -5,7 +5,7 @@ interface TabsProps {
5
5
  defaultValue?: string;
6
6
  children: ReactNode;
7
7
  }
8
- declare function Tabs({ items, defaultValue, children }: TabsProps): JSX.Element;
8
+ declare function Tabs({ items, defaultValue, children, }: TabsProps): JSX.Element;
9
9
  interface TabProps {
10
10
  value: string;
11
11
  children: ReactNode;
@@ -4,7 +4,11 @@ import { createContext, useState, useId, useRef, useCallback, useContext } from
4
4
  import { getNextIndex } from '../hooks/arrownav';
5
5
 
6
6
  const TabsContext = createContext(null);
7
- function Tabs({ items, defaultValue, children }) {
7
+ function Tabs({
8
+ items,
9
+ defaultValue,
10
+ children
11
+ }) {
8
12
  const [active, setActive] = useState(defaultValue ?? items[0] ?? "");
9
13
  const id = useId();
10
14
  const tabsRef = useRef(null);
@@ -37,7 +41,9 @@ function Tabs({ items, defaultValue, children }) {
37
41
  direction: "horizontal",
38
42
  wrap: true
39
43
  });
40
- if (nextIndex === currentIndex) return;
44
+ if (nextIndex === currentIndex) {
45
+ return;
46
+ }
41
47
  e.preventDefault();
42
48
  const nextItem = items[nextIndex];
43
49
  if (nextItem !== void 0) {
@@ -48,48 +54,58 @@ function Tabs({ items, defaultValue, children }) {
48
54
  },
49
55
  [active, items]
50
56
  );
51
- return /* @__PURE__ */ jsx(TabsContext.Provider, { value: { active, setActive, id, getTabId, getPanelId }, children: /* @__PURE__ */ jsxs("div", { className: "my-6", children: [
52
- /* @__PURE__ */ jsx(
53
- "div",
54
- {
55
- ref: tabsRef,
56
- role: "tablist",
57
- onKeyDown: handleKeyDown,
58
- className: "flex border-b border-line",
59
- children: items.map((item) => /* @__PURE__ */ jsx(
60
- "button",
57
+ return /* @__PURE__ */ jsx(
58
+ TabsContext.Provider,
59
+ {
60
+ value: { active, getPanelId, getTabId, id, setActive },
61
+ children: /* @__PURE__ */ jsxs("div", { className: "my-6", children: [
62
+ /* @__PURE__ */ jsx(
63
+ "div",
61
64
  {
62
- id: getTabId(item),
63
- type: "button",
64
- role: "tab",
65
- "aria-selected": active === item,
66
- "aria-controls": getPanelId(item),
67
- tabIndex: active === item ? 0 : -1,
68
- onClick: () => setActive(item),
69
- className: `px-4 py-2 text-sm font-medium transition-colors border-b -mb-px ${active === item ? "text-fg border-fg" : "text-muted hover:text-fg border-transparent"}`,
70
- children: item
71
- },
72
- item
73
- ))
74
- }
75
- ),
76
- /* @__PURE__ */ jsx(
77
- "div",
78
- {
79
- id: getPanelId(active),
80
- role: "tabpanel",
81
- "aria-labelledby": getTabId(active),
82
- tabIndex: 0,
83
- className: "pt-4",
84
- children
85
- }
86
- )
87
- ] }) });
65
+ ref: tabsRef,
66
+ role: "tablist",
67
+ onKeyDown: handleKeyDown,
68
+ className: "flex border-b border-line",
69
+ children: items.map((item) => /* @__PURE__ */ jsx(
70
+ "button",
71
+ {
72
+ id: getTabId(item),
73
+ type: "button",
74
+ role: "tab",
75
+ "aria-selected": active === item,
76
+ "aria-controls": getPanelId(item),
77
+ tabIndex: active === item ? 0 : -1,
78
+ onClick: () => setActive(item),
79
+ className: `px-4 py-2 text-sm font-medium transition-colors border-b -mb-px ${active === item ? "text-fg border-fg" : "text-muted hover:text-fg border-transparent"}`,
80
+ children: item
81
+ },
82
+ item
83
+ ))
84
+ }
85
+ ),
86
+ /* @__PURE__ */ jsx(
87
+ "div",
88
+ {
89
+ id: getPanelId(active),
90
+ role: "tabpanel",
91
+ "aria-labelledby": getTabId(active),
92
+ tabIndex: 0,
93
+ className: "pt-4",
94
+ children
95
+ }
96
+ )
97
+ ] })
98
+ }
99
+ );
88
100
  }
89
101
  function Tab({ value, children }) {
90
102
  const context = useContext(TabsContext);
91
- if (!context) return null;
92
- if (context.active !== value) return null;
103
+ if (!context) {
104
+ return null;
105
+ }
106
+ if (context.active !== value) {
107
+ return null;
108
+ }
93
109
  return /* @__PURE__ */ jsx(Fragment, { children });
94
110
  }
95
111
 
@@ -3,13 +3,18 @@ import { jsx } from 'react/jsx-runtime';
3
3
  import { memo } from 'react';
4
4
 
5
5
  const styles = {
6
+ danger: "bg-red-500/10 border-red-500/20 text-red-400",
6
7
  default: "bg-surface border-line text-muted",
7
8
  primary: "bg-accent/10 border-accent/20 text-accent",
8
9
  success: "bg-emerald-500/10 border-emerald-500/20 text-emerald-400",
9
- warning: "bg-amber-500/10 border-amber-500/20 text-amber-400",
10
- danger: "bg-red-500/10 border-red-500/20 text-red-400"
10
+ warning: "bg-amber-500/10 border-amber-500/20 text-amber-400"
11
11
  };
12
- function TagBase({ variant = "default", className, children, ...props }) {
12
+ function TagBase({
13
+ variant = "default",
14
+ className,
15
+ children,
16
+ ...props
17
+ }) {
13
18
  return /* @__PURE__ */ jsx(
14
19
  "span",
15
20
  {
@@ -2,7 +2,10 @@
2
2
  import { jsxs, jsx } from 'react/jsx-runtime';
3
3
  import { memo, useState, useRef, useCallback, useEffect } from 'react';
4
4
 
5
- const Terminal = memo(function Terminal2({ title = "Terminal", children }) {
5
+ const Terminal = memo(function Terminal2({
6
+ title = "Terminal",
7
+ children
8
+ }) {
6
9
  return /* @__PURE__ */ jsxs("div", { className: "my-6 rounded-xl border border-line overflow-hidden", children: [
7
10
  /* @__PURE__ */ jsxs("div", { className: "flex items-center gap-2 px-4 py-2.5 bg-[#0a0a0a] border-b border-line", children: [
8
11
  /* @__PURE__ */ jsxs("div", { className: "flex gap-1.5", "aria-hidden": "true", children: [
@@ -15,13 +18,18 @@ const Terminal = memo(function Terminal2({ title = "Terminal", children }) {
15
18
  /* @__PURE__ */ jsx("div", { className: "p-4 bg-[#0a0a0a] font-mono text-sm", children })
16
19
  ] });
17
20
  });
18
- const Line = memo(function Line2({ prompt = "$", children }) {
21
+ const Line = memo(function Line2({
22
+ prompt = "$",
23
+ children
24
+ }) {
19
25
  return /* @__PURE__ */ jsxs("div", { className: "flex gap-2", children: [
20
26
  /* @__PURE__ */ jsx("span", { className: "text-emerald-400 select-none shrink-0", children: prompt }),
21
27
  /* @__PURE__ */ jsx("span", { className: "text-zinc-300", children })
22
28
  ] });
23
29
  });
24
- const Output = memo(function Output2({ children }) {
30
+ const Output = memo(function Output2({
31
+ children
32
+ }) {
25
33
  return /* @__PURE__ */ jsx("div", { className: "text-zinc-500 pl-5", children });
26
34
  });
27
35
  const caretStyle = {
@@ -48,7 +56,9 @@ function Typed({ text, speed = 50 }) {
48
56
  reset();
49
57
  }, [text, reset]);
50
58
  useEffect(() => {
51
- if (done) return;
59
+ if (done) {
60
+ return;
61
+ }
52
62
  const interval = setInterval(tick, speed);
53
63
  return () => clearInterval(interval);
54
64
  }, [text, speed, done, tick]);
@@ -9,92 +9,106 @@ const variants = {
9
9
  error: "border-red-500/50 bg-red-500/5 text-fg placeholder:text-muted focus:border-red-500"
10
10
  };
11
11
  const sizes = {
12
- sm: "px-2.5 py-1.5 text-xs min-h-[60px]",
12
+ lg: "px-4 py-3 text-base min-h-[100px]",
13
13
  md: "px-3 py-2 text-sm min-h-[80px]",
14
- lg: "px-4 py-3 text-base min-h-[100px]"
14
+ sm: "px-2.5 py-1.5 text-xs min-h-[60px]"
15
15
  };
16
- const Textarea = memo(forwardRef(function Textarea2({
17
- variant = "default",
18
- size = "md",
19
- label,
20
- error,
21
- hint,
22
- autoresize = false,
23
- showCount = false,
24
- tooltip,
25
- maxLength,
26
- className = "",
27
- id,
28
- value,
29
- defaultValue,
30
- onChange,
31
- ...props
32
- }, ref) {
33
- const generatedId = useId();
34
- const textareaId = id || generatedId;
35
- const errorId = error ? `${textareaId}-error` : void 0;
36
- const hintId = hint && !error ? `${textareaId}-hint` : void 0;
37
- const countId = showCount ? `${textareaId}-count` : void 0;
38
- const describedBy = [errorId, hintId, countId].filter(Boolean).join(" ") || void 0;
39
- const actualVariant = error ? "error" : variant;
40
- const internalRef = useRef(null);
41
- const [charCount, setCharCount] = useState(() => {
42
- const initial = value ?? defaultValue ?? "";
43
- return typeof initial === "string" ? initial.length : 0;
44
- });
45
- const resize = useCallback(() => {
46
- const textarea = internalRef.current;
47
- if (!textarea || !autoresize) return;
48
- textarea.style.height = "auto";
49
- textarea.style.height = `${textarea.scrollHeight}px`;
50
- }, [autoresize]);
51
- useEffect(() => {
52
- resize();
53
- }, [resize, value]);
54
- const handleChange = (e) => {
55
- setCharCount(e.target.value.length);
56
- if (autoresize) resize();
57
- onChange?.(e);
58
- };
59
- const setRefs = useCallback(
60
- (node) => {
61
- internalRef.current = node;
62
- if (typeof ref === "function") {
63
- ref(node);
64
- } else if (ref) {
65
- ref.current = node;
16
+ const Textarea = memo(
17
+ forwardRef(function Textarea2({
18
+ variant = "default",
19
+ size = "md",
20
+ label,
21
+ error,
22
+ hint,
23
+ autoresize = false,
24
+ showCount = false,
25
+ tooltip,
26
+ maxLength,
27
+ className = "",
28
+ id,
29
+ value,
30
+ defaultValue,
31
+ onChange,
32
+ ...props
33
+ }, ref) {
34
+ const generatedId = useId();
35
+ const textareaId = id || generatedId;
36
+ const errorId = error ? `${textareaId}-error` : void 0;
37
+ const hintId = hint && !error ? `${textareaId}-hint` : void 0;
38
+ const countId = showCount ? `${textareaId}-count` : void 0;
39
+ const describedBy = [errorId, hintId, countId].filter(Boolean).join(" ") || void 0;
40
+ const actualVariant = error ? "error" : variant;
41
+ const internalRef = useRef(null);
42
+ const [charCount, setCharCount] = useState(() => {
43
+ const initial = value ?? defaultValue ?? "";
44
+ return typeof initial === "string" ? initial.length : 0;
45
+ });
46
+ const resize = useCallback(() => {
47
+ const textarea = internalRef.current;
48
+ if (!textarea || !autoresize) {
49
+ return;
66
50
  }
67
- },
68
- [ref]
69
- );
70
- return /* @__PURE__ */ jsxs("div", { className: "flex flex-col gap-1.5", children: [
71
- label && /* @__PURE__ */ jsx(FormLabel, { label, tooltip, htmlFor: textareaId }),
72
- /* @__PURE__ */ jsx(
73
- "textarea",
74
- {
75
- ref: setRefs,
76
- id: textareaId,
77
- "aria-invalid": actualVariant === "error" ? true : void 0,
78
- "aria-describedby": describedBy,
79
- maxLength,
80
- value,
81
- defaultValue,
82
- onChange: handleChange,
83
- className: `rounded-md border outline-none transition-colors resize-vertical ${variants[actualVariant]} ${sizes[size]} ${autoresize ? "resize-none overflow-hidden" : ""} ${className}`.trim(),
84
- ...props
51
+ textarea.style.height = "auto";
52
+ textarea.style.height = `${textarea.scrollHeight}px`;
53
+ }, [autoresize]);
54
+ useEffect(() => {
55
+ resize();
56
+ }, [resize, value]);
57
+ const handleChange = (e) => {
58
+ setCharCount(e.target.value.length);
59
+ if (autoresize) {
60
+ resize();
85
61
  }
86
- ),
87
- /* @__PURE__ */ jsxs("div", { className: "flex justify-between gap-2", children: [
88
- /* @__PURE__ */ jsxs("div", { className: "flex-1", children: [
89
- error && /* @__PURE__ */ jsx(ErrorMessage, { id: errorId, children: error }),
90
- hint && !error && /* @__PURE__ */ jsx("span", { id: hintId, className: "text-xs text-muted", children: hint })
91
- ] }),
92
- showCount && /* @__PURE__ */ jsxs("span", { id: countId, className: "text-xs text-muted", "aria-live": "polite", children: [
93
- charCount,
94
- maxLength ? `/${maxLength}` : ""
62
+ onChange?.(e);
63
+ };
64
+ const setRefs = useCallback(
65
+ (node) => {
66
+ internalRef.current = node;
67
+ if (typeof ref === "function") {
68
+ ref(node);
69
+ } else if (ref) {
70
+ ref.current = node;
71
+ }
72
+ },
73
+ [ref]
74
+ );
75
+ return /* @__PURE__ */ jsxs("div", { className: "flex flex-col gap-1.5", children: [
76
+ label && /* @__PURE__ */ jsx(FormLabel, { label, tooltip, htmlFor: textareaId }),
77
+ /* @__PURE__ */ jsx(
78
+ "textarea",
79
+ {
80
+ ref: setRefs,
81
+ id: textareaId,
82
+ "aria-invalid": actualVariant === "error" ? true : void 0,
83
+ "aria-describedby": describedBy,
84
+ maxLength,
85
+ value,
86
+ defaultValue,
87
+ onChange: handleChange,
88
+ className: `rounded-md border outline-none transition-colors resize-vertical ${variants[actualVariant]} ${sizes[size]} ${autoresize ? "resize-none overflow-hidden" : ""} ${className}`.trim(),
89
+ ...props
90
+ }
91
+ ),
92
+ /* @__PURE__ */ jsxs("div", { className: "flex justify-between gap-2", children: [
93
+ /* @__PURE__ */ jsxs("div", { className: "flex-1", children: [
94
+ error && /* @__PURE__ */ jsx(ErrorMessage, { id: errorId, children: error }),
95
+ hint && !error && /* @__PURE__ */ jsx("span", { id: hintId, className: "text-xs text-muted", children: hint })
96
+ ] }),
97
+ showCount && /* @__PURE__ */ jsxs(
98
+ "span",
99
+ {
100
+ id: countId,
101
+ className: "text-xs text-muted",
102
+ "aria-live": "polite",
103
+ children: [
104
+ charCount,
105
+ maxLength ? `/${maxLength}` : ""
106
+ ]
107
+ }
108
+ )
95
109
  ] })
96
- ] })
97
- ] });
98
- }));
110
+ ] });
111
+ })
112
+ );
99
113
 
100
114
  export { Textarea };
@@ -5,7 +5,7 @@ type Theme = "light" | "dark" | "system";
5
5
  interface ThemeToggleProps {
6
6
  defaultTheme?: Theme;
7
7
  }
8
- declare function ThemeToggleBase({ defaultTheme }: ThemeToggleProps): JSX.Element;
8
+ declare function ThemeToggleBase({ defaultTheme, }: ThemeToggleProps): JSX.Element;
9
9
  declare const ThemeToggle: react.MemoExoticComponent<typeof ThemeToggleBase>;
10
10
 
11
11
  export { type Theme, ThemeToggle, type ThemeToggleProps };
@@ -11,7 +11,9 @@ function resolves(theme) {
11
11
  }
12
12
  return theme;
13
13
  }
14
- function ThemeToggleBase({ defaultTheme = "dark" }) {
14
+ function ThemeToggleBase({
15
+ defaultTheme = "dark"
16
+ }) {
15
17
  const [theme, setTheme] = useState(null);
16
18
  const [resolved, setResolved] = useState(null);
17
19
  useEffect(() => {
@@ -21,7 +23,9 @@ function ThemeToggleBase({ defaultTheme = "dark" }) {
21
23
  setResolved(resolves(initial));
22
24
  }, [defaultTheme]);
23
25
  useEffect(() => {
24
- if (!theme) return;
26
+ if (!theme) {
27
+ return;
28
+ }
25
29
  const apply = () => {
26
30
  const r = resolves(theme);
27
31
  setResolved(r);
@@ -57,7 +61,25 @@ function ThemeToggleBase({ defaultTheme = "dark" }) {
57
61
  onClick: toggle,
58
62
  className: "p-2 text-muted hover:text-fg transition-colors",
59
63
  "aria-label": `switch to ${resolved === "dark" ? "light" : "dark"} theme`,
60
- children: resolved === "dark" ? /* @__PURE__ */ jsx("svg", { "aria-hidden": "true", viewBox: "0 0 16 16", fill: "currentColor", className: "size-4", children: /* @__PURE__ */ jsx("path", { d: "M8 12a4 4 0 100-8 4 4 0 000 8zM8 0a.75.75 0 01.75.75v1.5a.75.75 0 01-1.5 0V.75A.75.75 0 018 0zm0 13a.75.75 0 01.75.75v1.5a.75.75 0 01-1.5 0v-1.5A.75.75 0 018 13zM3.05 2.343a.75.75 0 011.06 0l1.061 1.061a.75.75 0 01-1.06 1.06L3.05 3.404a.75.75 0 010-1.06zm8.84 8.84a.75.75 0 011.06 0l1.06 1.06a.75.75 0 01-1.06 1.061l-1.06-1.06a.75.75 0 010-1.06zM16 8a.75.75 0 01-.75.75h-1.5a.75.75 0 010-1.5h1.5A.75.75 0 0116 8zM3 8a.75.75 0 01-.75.75H.75a.75.75 0 010-1.5h1.5A.75.75 0 013 8zm10.657-4.95a.75.75 0 010 1.061l-1.06 1.06a.75.75 0 11-1.061-1.06l1.06-1.06a.75.75 0 011.06 0zm-8.84 8.84a.75.75 0 010 1.06l-1.06 1.06a.75.75 0 11-1.061-1.06l1.06-1.06a.75.75 0 011.06 0z" }) }) : /* @__PURE__ */ jsx("svg", { "aria-hidden": "true", viewBox: "0 0 16 16", fill: "currentColor", className: "size-4", children: /* @__PURE__ */ jsx("path", { d: "M9.598 1.591a.75.75 0 01.785-.175 7 7 0 11-8.967 8.967.75.75 0 01.961-.96 5.5 5.5 0 007.046-7.046.75.75 0 01.175-.786zm1.616 1.945a7 7 0 01-7.678 7.678 5.5 5.5 0 107.678-7.678z" }) })
64
+ children: resolved === "dark" ? /* @__PURE__ */ jsx(
65
+ "svg",
66
+ {
67
+ "aria-hidden": "true",
68
+ viewBox: "0 0 16 16",
69
+ fill: "currentColor",
70
+ className: "size-4",
71
+ children: /* @__PURE__ */ jsx("path", { d: "M8 12a4 4 0 100-8 4 4 0 000 8zM8 0a.75.75 0 01.75.75v1.5a.75.75 0 01-1.5 0V.75A.75.75 0 018 0zm0 13a.75.75 0 01.75.75v1.5a.75.75 0 01-1.5 0v-1.5A.75.75 0 018 13zM3.05 2.343a.75.75 0 011.06 0l1.061 1.061a.75.75 0 01-1.06 1.06L3.05 3.404a.75.75 0 010-1.06zm8.84 8.84a.75.75 0 011.06 0l1.06 1.06a.75.75 0 01-1.06 1.061l-1.06-1.06a.75.75 0 010-1.06zM16 8a.75.75 0 01-.75.75h-1.5a.75.75 0 010-1.5h1.5A.75.75 0 0116 8zM3 8a.75.75 0 01-.75.75H.75a.75.75 0 010-1.5h1.5A.75.75 0 013 8zm10.657-4.95a.75.75 0 010 1.061l-1.06 1.06a.75.75 0 11-1.061-1.06l1.06-1.06a.75.75 0 011.06 0zm-8.84 8.84a.75.75 0 010 1.06l-1.06 1.06a.75.75 0 11-1.061-1.06l1.06-1.06a.75.75 0 011.06 0z" })
72
+ }
73
+ ) : /* @__PURE__ */ jsx(
74
+ "svg",
75
+ {
76
+ "aria-hidden": "true",
77
+ viewBox: "0 0 16 16",
78
+ fill: "currentColor",
79
+ className: "size-4",
80
+ children: /* @__PURE__ */ jsx("path", { d: "M9.598 1.591a.75.75 0 01.785-.175 7 7 0 11-8.967 8.967.75.75 0 01.961-.96 5.5 5.5 0 007.046-7.046.75.75 0 01.175-.786zm1.616 1.945a7 7 0 01-7.678 7.678 5.5 5.5 0 107.678-7.678z" })
81
+ }
82
+ )
61
83
  }
62
84
  );
63
85
  }