@kujoforall/paper-ui 0.1.0 → 0.2.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 (553) hide show
  1. package/CHANGELOG.md +94 -0
  2. package/README.md +50 -7
  3. package/dist/components/editor/block-text.d.ts.map +1 -1
  4. package/dist/components/editor/block-text.js +52 -17
  5. package/dist/components/editor/block-text.js.map +1 -1
  6. package/dist/components/editor/blocks.d.ts.map +1 -1
  7. package/dist/components/editor/blocks.js +17 -13
  8. package/dist/components/editor/blocks.js.map +1 -1
  9. package/dist/components/editor/document-editor.d.ts.map +1 -1
  10. package/dist/components/editor/document-editor.js +4 -2
  11. package/dist/components/editor/document-editor.js.map +1 -1
  12. package/dist/components/editor/document-view.d.ts.map +1 -1
  13. package/dist/components/editor/document-view.js +17 -12
  14. package/dist/components/editor/document-view.js.map +1 -1
  15. package/dist/components/editor/editor-state.d.ts +7 -0
  16. package/dist/components/editor/editor-state.d.ts.map +1 -1
  17. package/dist/components/editor/editor-state.js +28 -3
  18. package/dist/components/editor/editor-state.js.map +1 -1
  19. package/dist/components/editor/extensions/kit-blocks.d.ts +34 -0
  20. package/dist/components/editor/extensions/kit-blocks.d.ts.map +1 -0
  21. package/dist/components/editor/extensions/kit-blocks.js +201 -0
  22. package/dist/components/editor/extensions/kit-blocks.js.map +1 -0
  23. package/dist/components/editor/extensions/spoiler.d.ts.map +1 -1
  24. package/dist/components/editor/extensions/spoiler.js +2 -2
  25. package/dist/components/editor/extensions/spoiler.js.map +1 -1
  26. package/dist/components/editor/index.d.ts +1 -0
  27. package/dist/components/editor/index.d.ts.map +1 -1
  28. package/dist/components/editor/index.js +1 -0
  29. package/dist/components/editor/index.js.map +1 -1
  30. package/dist/components/editor/kinds.js +1 -1
  31. package/dist/components/editor/kinds.js.map +1 -1
  32. package/dist/components/editor/look.d.ts +18 -0
  33. package/dist/components/editor/look.d.ts.map +1 -0
  34. package/dist/components/editor/look.js +21 -0
  35. package/dist/components/editor/look.js.map +1 -0
  36. package/dist/components/three/model-viewer.d.ts +36 -0
  37. package/dist/components/three/model-viewer.d.ts.map +1 -0
  38. package/dist/components/three/model-viewer.js +338 -0
  39. package/dist/components/three/model-viewer.js.map +1 -0
  40. package/dist/components/ui/accent-picker.js +1 -1
  41. package/dist/components/ui/accent-picker.js.map +1 -1
  42. package/dist/components/ui/alert-dialog.d.ts +29 -0
  43. package/dist/components/ui/alert-dialog.d.ts.map +1 -0
  44. package/dist/components/ui/alert-dialog.js +72 -0
  45. package/dist/components/ui/alert-dialog.js.map +1 -0
  46. package/dist/components/ui/animated-height.d.ts +6 -0
  47. package/dist/components/ui/animated-height.d.ts.map +1 -0
  48. package/dist/components/ui/animated-height.js +26 -0
  49. package/dist/components/ui/animated-height.js.map +1 -0
  50. package/dist/components/ui/app-shell.d.ts +1 -0
  51. package/dist/components/ui/app-shell.d.ts.map +1 -1
  52. package/dist/components/ui/app-shell.js +5 -3
  53. package/dist/components/ui/app-shell.js.map +1 -1
  54. package/dist/components/ui/avatar.d.ts +30 -0
  55. package/dist/components/ui/avatar.d.ts.map +1 -0
  56. package/dist/components/ui/avatar.js +50 -0
  57. package/dist/components/ui/avatar.js.map +1 -0
  58. package/dist/components/ui/badge.d.ts +3 -3
  59. package/dist/components/ui/badge.d.ts.map +1 -1
  60. package/dist/components/ui/badge.js +2 -2
  61. package/dist/components/ui/badge.js.map +1 -1
  62. package/dist/components/ui/banner.d.ts +33 -0
  63. package/dist/components/ui/banner.d.ts.map +1 -0
  64. package/dist/components/ui/banner.js +21 -0
  65. package/dist/components/ui/banner.js.map +1 -0
  66. package/dist/components/ui/breadcrumbs.js +1 -1
  67. package/dist/components/ui/breadcrumbs.js.map +1 -1
  68. package/dist/components/ui/button.d.ts +8 -6
  69. package/dist/components/ui/button.d.ts.map +1 -1
  70. package/dist/components/ui/button.js +91 -26
  71. package/dist/components/ui/button.js.map +1 -1
  72. package/dist/components/ui/calendar.d.ts.map +1 -1
  73. package/dist/components/ui/calendar.js +6 -5
  74. package/dist/components/ui/calendar.js.map +1 -1
  75. package/dist/components/ui/callout.d.ts +23 -4
  76. package/dist/components/ui/callout.d.ts.map +1 -1
  77. package/dist/components/ui/callout.js +28 -15
  78. package/dist/components/ui/callout.js.map +1 -1
  79. package/dist/components/ui/card.d.ts +13 -8
  80. package/dist/components/ui/card.d.ts.map +1 -1
  81. package/dist/components/ui/card.js +10 -9
  82. package/dist/components/ui/card.js.map +1 -1
  83. package/dist/components/ui/checkbox.d.ts +9 -4
  84. package/dist/components/ui/checkbox.d.ts.map +1 -1
  85. package/dist/components/ui/checkbox.js +25 -5
  86. package/dist/components/ui/checkbox.js.map +1 -1
  87. package/dist/components/ui/choice-label.d.ts +13 -0
  88. package/dist/components/ui/choice-label.d.ts.map +1 -0
  89. package/dist/components/ui/choice-label.js +17 -0
  90. package/dist/components/ui/choice-label.js.map +1 -0
  91. package/dist/components/ui/collapsible.d.ts +10 -0
  92. package/dist/components/ui/collapsible.d.ts.map +1 -0
  93. package/dist/components/ui/collapsible.js +21 -0
  94. package/dist/components/ui/collapsible.js.map +1 -0
  95. package/dist/components/ui/collection-layout.d.ts +24 -0
  96. package/dist/components/ui/collection-layout.d.ts.map +1 -0
  97. package/dist/components/ui/collection-layout.js +16 -0
  98. package/dist/components/ui/collection-layout.js.map +1 -0
  99. package/dist/components/ui/combobox.d.ts +10 -0
  100. package/dist/components/ui/combobox.d.ts.map +1 -0
  101. package/dist/components/ui/combobox.js +93 -0
  102. package/dist/components/ui/combobox.js.map +1 -0
  103. package/dist/components/ui/command-menu.d.ts +5 -2
  104. package/dist/components/ui/command-menu.d.ts.map +1 -1
  105. package/dist/components/ui/command-menu.js +31 -6
  106. package/dist/components/ui/command-menu.js.map +1 -1
  107. package/dist/components/ui/context-menu.d.ts +19 -0
  108. package/dist/components/ui/context-menu.d.ts.map +1 -0
  109. package/dist/components/ui/context-menu.js +42 -0
  110. package/dist/components/ui/context-menu.js.map +1 -0
  111. package/dist/components/ui/copy-button.d.ts +11 -0
  112. package/dist/components/ui/copy-button.d.ts.map +1 -0
  113. package/dist/components/ui/copy-button.js +48 -0
  114. package/dist/components/ui/copy-button.js.map +1 -0
  115. package/dist/components/ui/database/calendar-view.d.ts +10 -0
  116. package/dist/components/ui/database/calendar-view.d.ts.map +1 -0
  117. package/dist/components/ui/database/calendar-view.js +65 -0
  118. package/dist/components/ui/database/calendar-view.js.map +1 -0
  119. package/dist/components/ui/database/card-views.d.ts +22 -0
  120. package/dist/components/ui/database/card-views.d.ts.map +1 -0
  121. package/dist/components/ui/database/card-views.js +74 -0
  122. package/dist/components/ui/database/card-views.js.map +1 -0
  123. package/dist/components/ui/database/cells.d.ts +20 -0
  124. package/dist/components/ui/database/cells.d.ts.map +1 -0
  125. package/dist/components/ui/database/cells.js +132 -0
  126. package/dist/components/ui/database/cells.js.map +1 -0
  127. package/dist/components/ui/database/database.d.ts +19 -0
  128. package/dist/components/ui/database/database.d.ts.map +1 -0
  129. package/dist/components/ui/database/database.js +102 -0
  130. package/dist/components/ui/database/database.js.map +1 -0
  131. package/dist/components/ui/database/icons.d.ts +5 -0
  132. package/dist/components/ui/database/icons.d.ts.map +1 -0
  133. package/dist/components/ui/database/icons.js +13 -0
  134. package/dist/components/ui/database/icons.js.map +1 -0
  135. package/dist/components/ui/database/table-view.d.ts +11 -0
  136. package/dist/components/ui/database/table-view.d.ts.map +1 -0
  137. package/dist/components/ui/database/table-view.js +157 -0
  138. package/dist/components/ui/database/table-view.js.map +1 -0
  139. package/dist/components/ui/date-picker.d.ts +6 -1
  140. package/dist/components/ui/date-picker.d.ts.map +1 -1
  141. package/dist/components/ui/date-picker.js +20 -12
  142. package/dist/components/ui/date-picker.js.map +1 -1
  143. package/dist/components/ui/date-time-picker.d.ts +3 -1
  144. package/dist/components/ui/date-time-picker.d.ts.map +1 -1
  145. package/dist/components/ui/date-time-picker.js +17 -15
  146. package/dist/components/ui/date-time-picker.js.map +1 -1
  147. package/dist/components/ui/dialog.d.ts +13 -9
  148. package/dist/components/ui/dialog.d.ts.map +1 -1
  149. package/dist/components/ui/dialog.js +33 -3
  150. package/dist/components/ui/dialog.js.map +1 -1
  151. package/dist/components/ui/document-layout.d.ts +15 -0
  152. package/dist/components/ui/document-layout.d.ts.map +1 -0
  153. package/dist/components/ui/document-layout.js +15 -0
  154. package/dist/components/ui/document-layout.js.map +1 -0
  155. package/dist/components/ui/dropdown-menu.d.ts +14 -10
  156. package/dist/components/ui/dropdown-menu.d.ts.map +1 -1
  157. package/dist/components/ui/dropdown-menu.js +22 -13
  158. package/dist/components/ui/dropdown-menu.js.map +1 -1
  159. package/dist/components/ui/editable-text.d.ts +9 -2
  160. package/dist/components/ui/editable-text.d.ts.map +1 -1
  161. package/dist/components/ui/editable-text.js +27 -10
  162. package/dist/components/ui/editable-text.js.map +1 -1
  163. package/dist/components/ui/empty-state.d.ts +11 -0
  164. package/dist/components/ui/empty-state.d.ts.map +1 -0
  165. package/dist/components/ui/empty-state.js +9 -0
  166. package/dist/components/ui/empty-state.js.map +1 -0
  167. package/dist/components/ui/error-state.d.ts +20 -0
  168. package/dist/components/ui/error-state.d.ts.map +1 -0
  169. package/dist/components/ui/error-state.js +17 -0
  170. package/dist/components/ui/error-state.js.map +1 -0
  171. package/dist/components/ui/field-button.d.ts +2 -1
  172. package/dist/components/ui/field-button.d.ts.map +1 -1
  173. package/dist/components/ui/field-button.js +7 -5
  174. package/dist/components/ui/field-button.js.map +1 -1
  175. package/dist/components/ui/file-preview.js +1 -1
  176. package/dist/components/ui/file-preview.js.map +1 -1
  177. package/dist/components/ui/file-uploader.d.ts.map +1 -1
  178. package/dist/components/ui/file-uploader.js +5 -4
  179. package/dist/components/ui/file-uploader.js.map +1 -1
  180. package/dist/components/ui/filter-builder.d.ts +18 -0
  181. package/dist/components/ui/filter-builder.d.ts.map +1 -0
  182. package/dist/components/ui/filter-builder.js +98 -0
  183. package/dist/components/ui/filter-builder.js.map +1 -0
  184. package/dist/components/ui/focus-shell.d.ts +14 -0
  185. package/dist/components/ui/focus-shell.d.ts.map +1 -0
  186. package/dist/components/ui/focus-shell.js +13 -0
  187. package/dist/components/ui/focus-shell.js.map +1 -0
  188. package/dist/components/ui/handle-row.d.ts +11 -1
  189. package/dist/components/ui/handle-row.d.ts.map +1 -1
  190. package/dist/components/ui/handle-row.js +101 -32
  191. package/dist/components/ui/handle-row.js.map +1 -1
  192. package/dist/components/ui/header-bar.d.ts +5 -0
  193. package/dist/components/ui/header-bar.d.ts.map +1 -0
  194. package/dist/components/ui/header-bar.js +10 -0
  195. package/dist/components/ui/header-bar.js.map +1 -0
  196. package/dist/components/ui/hover-card.d.ts +6 -0
  197. package/dist/components/ui/hover-card.d.ts.map +1 -0
  198. package/dist/components/ui/hover-card.js +13 -0
  199. package/dist/components/ui/hover-card.js.map +1 -0
  200. package/dist/components/ui/image-block.js +4 -4
  201. package/dist/components/ui/image-block.js.map +1 -1
  202. package/dist/components/ui/image-card.d.ts.map +1 -1
  203. package/dist/components/ui/image-card.js +5 -4
  204. package/dist/components/ui/image-card.js.map +1 -1
  205. package/dist/components/ui/image-framer.d.ts +24 -0
  206. package/dist/components/ui/image-framer.d.ts.map +1 -0
  207. package/dist/components/ui/image-framer.js +89 -0
  208. package/dist/components/ui/image-framer.js.map +1 -0
  209. package/dist/components/ui/image-viewer.d.ts.map +1 -1
  210. package/dist/components/ui/image-viewer.js +38 -5
  211. package/dist/components/ui/image-viewer.js.map +1 -1
  212. package/dist/components/ui/image.d.ts +25 -3
  213. package/dist/components/ui/image.d.ts.map +1 -1
  214. package/dist/components/ui/image.js +50 -21
  215. package/dist/components/ui/image.js.map +1 -1
  216. package/dist/components/ui/index.d.ts +54 -11
  217. package/dist/components/ui/index.d.ts.map +1 -1
  218. package/dist/components/ui/index.js +53 -10
  219. package/dist/components/ui/index.js.map +1 -1
  220. package/dist/components/ui/input.d.ts +71 -12
  221. package/dist/components/ui/input.d.ts.map +1 -1
  222. package/dist/components/ui/input.js +236 -23
  223. package/dist/components/ui/input.js.map +1 -1
  224. package/dist/components/ui/link-block.d.ts.map +1 -1
  225. package/dist/components/ui/link-block.js +1 -1
  226. package/dist/components/ui/link-block.js.map +1 -1
  227. package/dist/components/ui/list-detail.d.ts +23 -0
  228. package/dist/components/ui/list-detail.d.ts.map +1 -0
  229. package/dist/components/ui/list-detail.js +33 -0
  230. package/dist/components/ui/list-detail.js.map +1 -0
  231. package/dist/components/ui/listbox.d.ts +7 -0
  232. package/dist/components/ui/listbox.d.ts.map +1 -0
  233. package/dist/components/ui/listbox.js +29 -0
  234. package/dist/components/ui/listbox.js.map +1 -0
  235. package/dist/components/ui/mac-card.js +1 -1
  236. package/dist/components/ui/mac-card.js.map +1 -1
  237. package/dist/components/ui/month-picker.d.ts +13 -0
  238. package/dist/components/ui/month-picker.d.ts.map +1 -0
  239. package/dist/components/ui/month-picker.js +53 -0
  240. package/dist/components/ui/month-picker.js.map +1 -0
  241. package/dist/components/ui/multi-select.d.ts +22 -0
  242. package/dist/components/ui/multi-select.d.ts.map +1 -0
  243. package/dist/components/ui/multi-select.js +88 -0
  244. package/dist/components/ui/multi-select.js.map +1 -0
  245. package/dist/components/ui/nav-tree.d.ts.map +1 -1
  246. package/dist/components/ui/nav-tree.js +10 -3
  247. package/dist/components/ui/nav-tree.js.map +1 -1
  248. package/dist/components/ui/page.d.ts +16 -5
  249. package/dist/components/ui/page.d.ts.map +1 -1
  250. package/dist/components/ui/page.js +23 -10
  251. package/dist/components/ui/page.js.map +1 -1
  252. package/dist/components/ui/pagination.d.ts +26 -0
  253. package/dist/components/ui/pagination.d.ts.map +1 -0
  254. package/dist/components/ui/pagination.js +54 -0
  255. package/dist/components/ui/pagination.js.map +1 -0
  256. package/dist/components/ui/picker-panel.d.ts +13 -0
  257. package/dist/components/ui/picker-panel.d.ts.map +1 -0
  258. package/dist/components/ui/picker-panel.js +19 -0
  259. package/dist/components/ui/picker-panel.js.map +1 -0
  260. package/dist/components/ui/popover.d.ts +2 -2
  261. package/dist/components/ui/popover.d.ts.map +1 -1
  262. package/dist/components/ui/popover.js +1 -1
  263. package/dist/components/ui/popover.js.map +1 -1
  264. package/dist/components/ui/progress.d.ts +11 -1
  265. package/dist/components/ui/progress.d.ts.map +1 -1
  266. package/dist/components/ui/progress.js +17 -4
  267. package/dist/components/ui/progress.js.map +1 -1
  268. package/dist/components/ui/property.d.ts +2 -6
  269. package/dist/components/ui/property.d.ts.map +1 -1
  270. package/dist/components/ui/property.js +6 -22
  271. package/dist/components/ui/property.js.map +1 -1
  272. package/dist/components/ui/radio-group.d.ts +8 -0
  273. package/dist/components/ui/radio-group.d.ts.map +1 -0
  274. package/dist/components/ui/radio-group.js +18 -0
  275. package/dist/components/ui/radio-group.js.map +1 -0
  276. package/dist/components/ui/rating.d.ts +14 -0
  277. package/dist/components/ui/rating.d.ts.map +1 -0
  278. package/dist/components/ui/rating.js +61 -0
  279. package/dist/components/ui/rating.js.map +1 -0
  280. package/dist/components/ui/save-status.d.ts +8 -0
  281. package/dist/components/ui/save-status.d.ts.map +1 -0
  282. package/dist/components/ui/save-status.js +31 -0
  283. package/dist/components/ui/save-status.js.map +1 -0
  284. package/dist/components/ui/segmented.d.ts +15 -7
  285. package/dist/components/ui/segmented.d.ts.map +1 -1
  286. package/dist/components/ui/segmented.js +8 -6
  287. package/dist/components/ui/segmented.js.map +1 -1
  288. package/dist/components/ui/select-menu.d.ts +3 -1
  289. package/dist/components/ui/select-menu.d.ts.map +1 -1
  290. package/dist/components/ui/select-menu.js +2 -2
  291. package/dist/components/ui/select-menu.js.map +1 -1
  292. package/dist/components/ui/select.d.ts +7 -2
  293. package/dist/components/ui/select.d.ts.map +1 -1
  294. package/dist/components/ui/select.js +19 -5
  295. package/dist/components/ui/select.js.map +1 -1
  296. package/dist/components/ui/selection-bar.js +1 -1
  297. package/dist/components/ui/selection-bar.js.map +1 -1
  298. package/dist/components/ui/settings-layout.d.ts +34 -0
  299. package/dist/components/ui/settings-layout.d.ts.map +1 -0
  300. package/dist/components/ui/settings-layout.js +16 -0
  301. package/dist/components/ui/settings-layout.js.map +1 -0
  302. package/dist/components/ui/share-link.d.ts +14 -0
  303. package/dist/components/ui/share-link.d.ts.map +1 -0
  304. package/dist/components/ui/share-link.js +16 -0
  305. package/dist/components/ui/share-link.js.map +1 -0
  306. package/dist/components/ui/sheet.d.ts +21 -0
  307. package/dist/components/ui/sheet.d.ts.map +1 -0
  308. package/dist/components/ui/sheet.js +53 -0
  309. package/dist/components/ui/sheet.js.map +1 -0
  310. package/dist/components/ui/sidebar.d.ts +82 -0
  311. package/dist/components/ui/sidebar.d.ts.map +1 -0
  312. package/dist/components/ui/sidebar.js +258 -0
  313. package/dist/components/ui/sidebar.js.map +1 -0
  314. package/dist/components/ui/skeleton.d.ts +8 -0
  315. package/dist/components/ui/skeleton.d.ts.map +1 -0
  316. package/dist/components/ui/skeleton.js +15 -0
  317. package/dist/components/ui/skeleton.js.map +1 -0
  318. package/dist/components/ui/spinner.d.ts +12 -0
  319. package/dist/components/ui/spinner.d.ts.map +1 -0
  320. package/dist/components/ui/spinner.js +14 -0
  321. package/dist/components/ui/spinner.js.map +1 -0
  322. package/dist/components/ui/spotlight.d.ts.map +1 -1
  323. package/dist/components/ui/spotlight.js +14 -11
  324. package/dist/components/ui/spotlight.js.map +1 -1
  325. package/dist/components/ui/step-dialog.js +3 -3
  326. package/dist/components/ui/step-dialog.js.map +1 -1
  327. package/dist/components/ui/steps-layout.d.ts +20 -0
  328. package/dist/components/ui/steps-layout.d.ts.map +1 -0
  329. package/dist/components/ui/steps-layout.js +26 -0
  330. package/dist/components/ui/steps-layout.js.map +1 -0
  331. package/dist/components/ui/switch.d.ts +8 -0
  332. package/dist/components/ui/switch.d.ts.map +1 -0
  333. package/dist/components/ui/switch.js +21 -0
  334. package/dist/components/ui/switch.js.map +1 -0
  335. package/dist/components/ui/table.d.ts +13 -5
  336. package/dist/components/ui/table.d.ts.map +1 -1
  337. package/dist/components/ui/table.js +65 -12
  338. package/dist/components/ui/table.js.map +1 -1
  339. package/dist/components/ui/tabs.d.ts +7 -0
  340. package/dist/components/ui/tabs.d.ts.map +1 -0
  341. package/dist/components/ui/tabs.js +19 -0
  342. package/dist/components/ui/tabs.js.map +1 -0
  343. package/dist/components/ui/theme-toggle.d.ts +14 -0
  344. package/dist/components/ui/theme-toggle.d.ts.map +1 -1
  345. package/dist/components/ui/theme-toggle.js +69 -41
  346. package/dist/components/ui/theme-toggle.js.map +1 -1
  347. package/dist/components/ui/time-list.d.ts +16 -0
  348. package/dist/components/ui/time-list.d.ts.map +1 -0
  349. package/dist/components/ui/time-list.js +49 -0
  350. package/dist/components/ui/time-list.js.map +1 -0
  351. package/dist/components/ui/time-picker.d.ts +37 -11
  352. package/dist/components/ui/time-picker.d.ts.map +1 -1
  353. package/dist/components/ui/time-picker.js +130 -52
  354. package/dist/components/ui/time-picker.js.map +1 -1
  355. package/dist/components/ui/toast.d.ts +18 -0
  356. package/dist/components/ui/toast.d.ts.map +1 -0
  357. package/dist/components/ui/toast.js +77 -0
  358. package/dist/components/ui/toast.js.map +1 -0
  359. package/dist/components/ui/toggle.d.ts +15 -0
  360. package/dist/components/ui/toggle.d.ts.map +1 -0
  361. package/dist/components/ui/toggle.js +55 -0
  362. package/dist/components/ui/toggle.js.map +1 -0
  363. package/dist/components/ui/tooltip.d.ts +1 -1
  364. package/dist/components/ui/tooltip.d.ts.map +1 -1
  365. package/dist/components/ui/tooltip.js +13 -2
  366. package/dist/components/ui/tooltip.js.map +1 -1
  367. package/dist/components/ui/top-bar.d.ts +25 -0
  368. package/dist/components/ui/top-bar.d.ts.map +1 -0
  369. package/dist/components/ui/top-bar.js +23 -0
  370. package/dist/components/ui/top-bar.js.map +1 -0
  371. package/dist/components/ui/typography.d.ts +11 -5
  372. package/dist/components/ui/typography.d.ts.map +1 -1
  373. package/dist/components/ui/typography.js +31 -5
  374. package/dist/components/ui/typography.js.map +1 -1
  375. package/dist/components/ui/video-block.d.ts.map +1 -1
  376. package/dist/components/ui/video-block.js +5 -1
  377. package/dist/components/ui/video-block.js.map +1 -1
  378. package/dist/hooks/use-dismiss.d.ts +5 -0
  379. package/dist/hooks/use-dismiss.d.ts.map +1 -0
  380. package/dist/hooks/use-dismiss.js +23 -0
  381. package/dist/hooks/use-dismiss.js.map +1 -0
  382. package/dist/hooks/use-escape-first.d.ts +3 -0
  383. package/dist/hooks/use-escape-first.d.ts.map +1 -0
  384. package/dist/hooks/use-escape-first.js +27 -0
  385. package/dist/hooks/use-escape-first.js.map +1 -0
  386. package/dist/hooks/use-media-query.d.ts +5 -0
  387. package/dist/hooks/use-media-query.d.ts.map +1 -0
  388. package/dist/hooks/use-media-query.js +16 -0
  389. package/dist/hooks/use-media-query.js.map +1 -0
  390. package/dist/hooks/use-save-queue.d.ts.map +1 -1
  391. package/dist/hooks/use-save-queue.js +19 -7
  392. package/dist/hooks/use-save-queue.js.map +1 -1
  393. package/dist/hooks/use-selection.d.ts.map +1 -1
  394. package/dist/hooks/use-selection.js +10 -1
  395. package/dist/hooks/use-selection.js.map +1 -1
  396. package/dist/lib/database.d.ts +92 -0
  397. package/dist/lib/database.d.ts.map +1 -0
  398. package/dist/lib/database.js +272 -0
  399. package/dist/lib/database.js.map +1 -0
  400. package/dist/lib/dates.d.ts +16 -0
  401. package/dist/lib/dates.d.ts.map +1 -1
  402. package/dist/lib/dates.js +27 -0
  403. package/dist/lib/dates.js.map +1 -1
  404. package/dist/lib/keys.d.ts +18 -0
  405. package/dist/lib/keys.d.ts.map +1 -0
  406. package/dist/lib/keys.js +66 -0
  407. package/dist/lib/keys.js.map +1 -0
  408. package/dist/lib/number.d.ts +4 -0
  409. package/dist/lib/number.d.ts.map +1 -0
  410. package/dist/lib/number.js +33 -0
  411. package/dist/lib/number.js.map +1 -0
  412. package/dist/lib/pointer.d.ts +2 -0
  413. package/dist/lib/pointer.d.ts.map +1 -0
  414. package/dist/lib/pointer.js +4 -0
  415. package/dist/lib/pointer.js.map +1 -0
  416. package/dist/lib/prepare-image.d.ts +43 -0
  417. package/dist/lib/prepare-image.d.ts.map +1 -0
  418. package/dist/lib/prepare-image.js +105 -0
  419. package/dist/lib/prepare-image.js.map +1 -0
  420. package/dist/lib/rich-text-dom.d.ts +2 -0
  421. package/dist/lib/rich-text-dom.d.ts.map +1 -1
  422. package/dist/lib/rich-text-dom.js +5 -3
  423. package/dist/lib/rich-text-dom.js.map +1 -1
  424. package/dist/lib/theme.d.ts +6 -0
  425. package/dist/lib/theme.d.ts.map +1 -0
  426. package/dist/lib/theme.js +15 -0
  427. package/dist/lib/theme.js.map +1 -0
  428. package/dist/lib/time.d.ts +19 -0
  429. package/dist/lib/time.d.ts.map +1 -0
  430. package/dist/lib/time.js +91 -0
  431. package/dist/lib/time.js.map +1 -0
  432. package/dist/lib/utils.d.ts.map +1 -1
  433. package/dist/lib/utils.js +20 -2
  434. package/dist/lib/utils.js.map +1 -1
  435. package/dist/styles/notion.css +342 -51
  436. package/package.json +27 -4
  437. package/src/components/editor/block-text.tsx +58 -17
  438. package/src/components/editor/blocks.tsx +19 -14
  439. package/src/components/editor/document-editor.tsx +7 -2
  440. package/src/components/editor/document-view.tsx +37 -24
  441. package/src/components/editor/editor-state.tsx +31 -3
  442. package/src/components/editor/extensions/kit-blocks.tsx +452 -0
  443. package/src/components/editor/extensions/spoiler.tsx +9 -4
  444. package/src/components/editor/index.ts +1 -0
  445. package/src/components/editor/kinds.ts +1 -1
  446. package/src/components/editor/look.tsx +36 -0
  447. package/src/components/three/model-viewer.tsx +514 -0
  448. package/src/components/ui/accent-picker.tsx +2 -2
  449. package/src/components/ui/alert-dialog.tsx +136 -0
  450. package/src/components/ui/animated-height.tsx +34 -0
  451. package/src/components/ui/app-shell.tsx +9 -7
  452. package/src/components/ui/avatar.tsx +106 -0
  453. package/src/components/ui/badge.tsx +4 -4
  454. package/src/components/ui/banner.tsx +53 -0
  455. package/src/components/ui/breadcrumbs.tsx +1 -1
  456. package/src/components/ui/button.tsx +115 -41
  457. package/src/components/ui/calendar.tsx +8 -7
  458. package/src/components/ui/callout.tsx +41 -42
  459. package/src/components/ui/card.tsx +27 -58
  460. package/src/components/ui/checkbox.tsx +53 -19
  461. package/src/components/ui/choice-label.tsx +43 -0
  462. package/src/components/ui/collapsible.tsx +58 -0
  463. package/src/components/ui/collection-layout.tsx +69 -0
  464. package/src/components/ui/combobox.tsx +155 -0
  465. package/src/components/ui/command-menu.tsx +61 -31
  466. package/src/components/ui/context-menu.tsx +89 -0
  467. package/src/components/ui/copy-button.tsx +80 -0
  468. package/src/components/ui/database/calendar-view.tsx +180 -0
  469. package/src/components/ui/database/card-views.tsx +221 -0
  470. package/src/components/ui/database/cells.tsx +237 -0
  471. package/src/components/ui/database/database.tsx +279 -0
  472. package/src/components/ui/database/icons.ts +15 -0
  473. package/src/components/ui/database/table-view.tsx +311 -0
  474. package/src/components/ui/date-picker.tsx +99 -61
  475. package/src/components/ui/date-time-picker.tsx +68 -62
  476. package/src/components/ui/dialog.tsx +48 -21
  477. package/src/components/ui/document-layout.tsx +52 -0
  478. package/src/components/ui/dropdown-menu.tsx +33 -31
  479. package/src/components/ui/editable-text.tsx +40 -7
  480. package/src/components/ui/empty-state.tsx +35 -0
  481. package/src/components/ui/error-state.tsx +67 -0
  482. package/src/components/ui/field-button.tsx +11 -9
  483. package/src/components/ui/file-preview.tsx +1 -1
  484. package/src/components/ui/file-uploader.tsx +23 -24
  485. package/src/components/ui/filter-builder.tsx +304 -0
  486. package/src/components/ui/focus-shell.tsx +48 -0
  487. package/src/components/ui/handle-row.tsx +176 -40
  488. package/src/components/ui/header-bar.tsx +15 -0
  489. package/src/components/ui/hover-card.tsx +30 -0
  490. package/src/components/ui/image-block.tsx +6 -6
  491. package/src/components/ui/image-card.tsx +18 -25
  492. package/src/components/ui/image-framer.tsx +160 -0
  493. package/src/components/ui/image-viewer.tsx +53 -10
  494. package/src/components/ui/image.tsx +133 -29
  495. package/src/components/ui/index.ts +106 -11
  496. package/src/components/ui/input.tsx +437 -65
  497. package/src/components/ui/link-block.tsx +5 -2
  498. package/src/components/ui/list-detail.tsx +115 -0
  499. package/src/components/ui/listbox.ts +26 -0
  500. package/src/components/ui/mac-card.tsx +5 -5
  501. package/src/components/ui/month-picker.tsx +119 -0
  502. package/src/components/ui/multi-select.tsx +221 -0
  503. package/src/components/ui/nav-tree.tsx +11 -5
  504. package/src/components/ui/page.tsx +63 -15
  505. package/src/components/ui/pagination.tsx +143 -0
  506. package/src/components/ui/picker-panel.tsx +69 -0
  507. package/src/components/ui/popover.tsx +3 -3
  508. package/src/components/ui/progress.tsx +56 -16
  509. package/src/components/ui/property.tsx +6 -37
  510. package/src/components/ui/radio-group.tsx +61 -0
  511. package/src/components/ui/rating.tsx +122 -0
  512. package/src/components/ui/save-status.tsx +53 -0
  513. package/src/components/ui/segmented.tsx +48 -16
  514. package/src/components/ui/select-menu.tsx +11 -3
  515. package/src/components/ui/select.tsx +33 -10
  516. package/src/components/ui/selection-bar.tsx +1 -1
  517. package/src/components/ui/settings-layout.tsx +117 -0
  518. package/src/components/ui/share-link.tsx +66 -0
  519. package/src/components/ui/sheet.tsx +90 -0
  520. package/src/components/ui/sidebar.tsx +627 -0
  521. package/src/components/ui/skeleton.tsx +22 -0
  522. package/src/components/ui/spinner.tsx +28 -0
  523. package/src/components/ui/spotlight.tsx +21 -21
  524. package/src/components/ui/step-dialog.tsx +6 -6
  525. package/src/components/ui/steps-layout.tsx +91 -0
  526. package/src/components/ui/switch.tsx +55 -0
  527. package/src/components/ui/table.tsx +75 -18
  528. package/src/components/ui/tabs.tsx +41 -0
  529. package/src/components/ui/theme-toggle.tsx +74 -83
  530. package/src/components/ui/time-list.tsx +106 -0
  531. package/src/components/ui/time-picker.tsx +305 -134
  532. package/src/components/ui/toast.tsx +132 -0
  533. package/src/components/ui/toggle.tsx +76 -0
  534. package/src/components/ui/tooltip.tsx +20 -6
  535. package/src/components/ui/top-bar.tsx +118 -0
  536. package/src/components/ui/typography.tsx +45 -9
  537. package/src/components/ui/video-block.tsx +9 -3
  538. package/src/hooks/use-dismiss.ts +24 -0
  539. package/src/hooks/use-escape-first.ts +25 -0
  540. package/src/hooks/use-media-query.ts +23 -0
  541. package/src/hooks/use-save-queue.ts +19 -7
  542. package/src/hooks/use-selection.ts +8 -1
  543. package/src/lib/database.ts +322 -0
  544. package/src/lib/dates.ts +36 -0
  545. package/src/lib/keys.ts +72 -0
  546. package/src/lib/number.ts +29 -0
  547. package/src/lib/pointer.ts +3 -0
  548. package/src/lib/prepare-image.ts +141 -0
  549. package/src/lib/rich-text-dom.ts +5 -3
  550. package/src/lib/theme.ts +18 -0
  551. package/src/lib/time.ts +83 -0
  552. package/src/lib/utils.ts +21 -2
  553. package/src/styles/notion.css +342 -51
@@ -1,6 +1,7 @@
1
1
  import { type VariantProps } from "class-variance-authority";
2
- import type { ComponentPropsWithoutRef, ElementType, ReactNode } from "react";
3
- type HeadingLevel = "title" | 1 | 2 | 3;
2
+ import { type ComponentProps, type ComponentPropsWithoutRef, type ElementType, type ReactNode } from "react";
3
+ import { type Platform } from "../../lib/keys.js";
4
+ type HeadingLevel = "display" | "title" | 1 | 2 | 3;
4
5
  export interface HeadingProps extends Omit<ComponentPropsWithoutRef<"h1">, "color"> {
5
6
  level?: HeadingLevel;
6
7
  as?: ElementType;
@@ -9,8 +10,8 @@ export interface HeadingProps extends Omit<ComponentPropsWithoutRef<"h1">, "colo
9
10
  }
10
11
  export declare function Heading({ level, as, flush, className, ...props }: HeadingProps): import("react").JSX.Element;
11
12
  declare const textVariants: (props?: ({
12
- tone?: "default" | "danger" | "accent" | "secondary" | "tertiary" | null | undefined;
13
- size?: "body" | "caption" | "sm" | null | undefined;
13
+ tone?: "accent" | "default" | "disabled" | "secondary" | "tertiary" | "success" | "warning" | "info" | "danger" | null | undefined;
14
+ size?: "caption" | "lead" | "body" | "micro" | "sm" | null | undefined;
14
15
  weight?: "normal" | "medium" | "semibold" | null | undefined;
15
16
  } & import("class-variance-authority/types").ClassProp) | undefined) => string;
16
17
  export interface TextProps extends Omit<ComponentPropsWithoutRef<"p">, "color">, VariantProps<typeof textVariants> {
@@ -19,7 +20,12 @@ export interface TextProps extends Omit<ComponentPropsWithoutRef<"p">, "color">,
19
20
  export declare function Text({ as, tone, size, weight, className, ...props }: TextProps): import("react").JSX.Element;
20
21
  /** Inline code. Tinted, not boxed — a box would outrank the paragraph. */
21
22
  export declare function Code({ className, ...props }: ComponentPropsWithoutRef<"code">): import("react").JSX.Element;
22
- export declare function Kbd({ className, ...props }: ComponentPropsWithoutRef<"kbd">): import("react").JSX.Element;
23
+ export declare function Kbd({ className, ...props }: ComponentProps<"kbd">): import("react").JSX.Element;
24
+ export declare function usePlatform(): Platform;
25
+ export declare function Shortcut({ keys, className }: {
26
+ keys: string;
27
+ className?: string;
28
+ }): import("react").JSX.Element;
23
29
  /**
24
30
  * Long-form content wrapper. Applies the reading measure plus the
25
31
  * vertical rhythm Notion uses between blocks. Wrap raw markdown output
@@ -1 +1 @@
1
- {"version":3,"file":"typography.d.ts","sourceRoot":"","sources":["../../../src/components/ui/typography.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAO,KAAK,YAAY,EAAE,MAAM,0BAA0B,CAAC;AAClE,OAAO,KAAK,EAAE,wBAAwB,EAAE,WAAW,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAsB9E,KAAK,YAAY,GAAG,OAAO,GAAG,CAAC,GAAG,CAAC,GAAG,CAAC,CAAC;AASxC,MAAM,WAAW,YACb,SAAQ,IAAI,CAAC,wBAAwB,CAAC,IAAI,CAAC,EAAE,OAAO,CAAC;IACrD,KAAK,CAAC,EAAE,YAAY,CAAC;IACrB,EAAE,CAAC,EAAE,WAAW,CAAC;IACjB,wEAAwE;IACxE,KAAK,CAAC,EAAE,OAAO,CAAC;CACnB;AAED,wBAAgB,OAAO,CAAC,EACpB,KAAS,EACT,EAAE,EACF,KAAK,EACL,SAAS,EACT,GAAG,KAAK,EACX,EAAE,YAAY,+BAYd;AAED,QAAA,MAAM,YAAY;;;;8EAqBhB,CAAC;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2
2
  import { cva } from "class-variance-authority";
3
+ import { useSyncExternalStore } from "react";
4
+ import { platform, shortcutKeys, speakShortcut } from "../../lib/keys.js";
3
5
  import { cn } from "../../lib/utils.js";
6
+ import { CODE_CLASSES } from "../../lib/rich-text-dom.js";
4
7
  /* ────────────────────────────────────────────────────────────────────────
5
8
  Typography carries the entire hierarchy in this system. There are no
6
9
  boxes around headings, no coloured section bars, no rules above titles.
@@ -10,6 +13,7 @@ import { cn } from "../../lib/utils.js";
10
13
  const headingVariants = cva("text-ink font-sans text-balance", {
11
14
  variants: {
12
15
  level: {
16
+ display: "text-display mt-0 mb-2",
13
17
  title: "text-title mt-0 mb-2",
14
18
  1: "text-h1 mt-8 mb-1",
15
19
  2: "text-h2 mt-6 mb-1",
@@ -19,6 +23,7 @@ const headingVariants = cva("text-ink font-sans text-balance", {
19
23
  defaultVariants: { level: 1 },
20
24
  });
21
25
  const defaultTag = {
26
+ display: "h1",
22
27
  title: "h1",
23
28
  1: "h1",
24
29
  2: "h2",
@@ -34,13 +39,20 @@ const textVariants = cva("font-sans", {
34
39
  default: "text-ink",
35
40
  secondary: "text-ink-secondary",
36
41
  tertiary: "text-ink-tertiary",
37
- accent: "text-accent",
42
+ disabled: "text-ink-disabled",
43
+ // Words in the accent: pulled toward the ink, so they read as text.
44
+ accent: "text-accent-text",
45
+ success: "text-success",
46
+ warning: "text-warning",
47
+ info: "text-info",
38
48
  danger: "text-danger",
39
49
  },
40
50
  size: {
51
+ lead: "text-lead",
41
52
  body: "text-body",
42
53
  sm: "text-sm",
43
54
  caption: "text-caption",
55
+ micro: "text-micro",
44
56
  },
45
57
  weight: {
46
58
  normal: "font-normal",
@@ -56,10 +68,24 @@ export function Text({ as, tone, size, weight, className, ...props }) {
56
68
  }
57
69
  /** Inline code. Tinted, not boxed — a box would outrank the paragraph. */
58
70
  export function Code({ className, ...props }) {
59
- return (_jsx("code", { className: cn("bg-tag-red-bg/70 px-1.5 py-0.5 rounded-[3px] font-mono text-tag-red-ink text-[0.85em]", className), ...props }));
71
+ return (_jsx("code", { className: cn(CODE_CLASSES, className), ...props }));
60
72
  }
73
+ /* One key, as printed on a keyboard. For a combination, use Shortcut. */
61
74
  export function Kbd({ className, ...props }) {
62
- return (_jsx("kbd", { className: cn("inline-flex justify-center items-center bg-surface shadow-xs px-1.5 rounded-[3px] min-w-5 h-5 font-sans font-medium text-ink-secondary text-caption", className), ...props }));
75
+ return (_jsx("kbd", { className: cn("inline-flex justify-center items-center bg-surface shadow-xs px-1.5 rounded-small min-w-5 h-5 font-sans font-medium text-ink-secondary text-caption", className), ...props }));
76
+ }
77
+ /* Which platform's keys to show. "other" on the server and in the first render
78
+ after it, so a server-rendered page hydrates cleanly; the right one next. */
79
+ export function usePlatform() {
80
+ return useSyncExternalStore(noSubscription, platform, () => "other");
81
+ }
82
+ const noSubscription = () => () => { };
83
+ /* A keyboard shortcut written once ("mod+shift+k") and shown right where it is
84
+ read: ⌘ ⇧ K on a Mac, Ctrl Shift K elsewhere. A screen reader hears the keys by
85
+ name ("Command Shift K"), not the symbols. */
86
+ export function Shortcut({ keys, className }) {
87
+ const on = usePlatform();
88
+ return (_jsxs("span", { className: cn("inline-flex items-center gap-0.5 align-middle", className), children: [_jsx("span", { className: "sr-only", children: speakShortcut(keys, on) }), shortcutKeys(keys, on).map((key, i) => (_jsx(Kbd, { "aria-hidden": true, children: key.shown }, i)))] }));
63
89
  }
64
90
  /**
65
91
  * Long-form content wrapper. Applies the reading measure plus the
@@ -67,6 +93,6 @@ export function Kbd({ className, ...props }) {
67
93
  * in this and it looks intentional with no further work.
68
94
  */
69
95
  export function Prose({ children, className, serif, }) {
70
- return (_jsx("div", { className: cn("measure text-ink text-body", serif && "font-serif", "[&>*+*]:mt-3", "[&_p]:text-ink [&_p]:leading-[1.6]", "[&_a]:text-ink [&_a]:underline [&_a]:decoration-ink-tertiary [&_a]:underline-offset-2 [&_a:hover]:decoration-ink", "[&_strong]:font-semibold", "[&_ul]:list-disc [&_ul]:pl-6 [&_ol]:list-decimal [&_ol]:pl-6", "[&_li]:mt-1 [&_li]:leading-[1.6]", "[&_blockquote]:border-ink/40 [&_blockquote]:pl-4 [&_blockquote]:border-l-2 [&_blockquote]:text-ink", "[&_hr]:my-6 [&_hr]:border-hairline", className), children: children }));
96
+ return (_jsx("div", { className: cn("measure text-ink text-body", serif && "font-serif", "[&>*+*]:mt-3", "[&_p]:text-ink [&_p]:leading-prose", "[&_a]:link", "[&_strong]:font-semibold", "[&_ul]:list-disc [&_ul]:pl-6 [&_ol]:list-decimal [&_ol]:pl-6", "[&_li]:mt-1 [&_li]:leading-prose", "[&_blockquote]:border-ink/40 [&_blockquote]:pl-4 [&_blockquote]:border-l-2 [&_blockquote]:text-ink", "[&_hr]:my-6 [&_hr]:border-hairline", className), children: children }));
71
97
  }
72
98
  //# sourceMappingURL=typography.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"typography.js","sourceRoot":"","sources":["../../../src/components/ui/typography.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,GAAG,EAAqB,MAAM,0BAA0B,CAAC;AAElE,OAAO,EAAE,EAAE,EAAE,MAAM,oBAAoB,CAAC;AAExC;;;;;8EAK8E;AAE9E,MAAM,eAAe,GAAG,GAAG,CAAC,iCAAiC,EAAE;IAC3D,QAAQ,EAAE;QACN,KAAK,EAAE;YACH,KAAK,EAAE,sBAAsB;YAC7B,CAAC,EAAE,mBAAmB;YACtB,CAAC,EAAE,mBAAmB;YACtB,CAAC,EAAE,qBAAqB;SAC3B;KACJ;IACD,eAAe,EAAE,EAAE,KAAK,EAAE,CAAC,EAAE;CAChC,CAAC,CAAC;AAIH,MAAM,UAAU,GAAgC;IAC5C,KAAK,EAAE,IAAI;IACX,CAAC,EAAE,IAAI;IACP,CAAC,EAAE,IAAI;IACP,CAAC,EAAE,IAAI;CACV,CAAC;AAUF,MAAM,UAAU,OAAO,CAAC,EACpB,KAAK,GAAG,CAAC,EACT,EAAE,EACF,KAAK,EACL,SAAS,EACT,GAA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GAAG,KAAK,EACuB;IAC/B,OAAO,CACH,eACI,SAAS,EAAE,EAAE,CACT,uFAAuF,EACvF,SAAS,CACZ,KACG,KAAK,GACX,CACL,CAAC;AACN,CAAC;AAED,MAAM,UAAU,GAAG,CAAC,EAAE,SAAS,EAAE,GAAG,KAAK,EAAmC;IACxE,OAAO,CACH,cACI,SAAS,EAAE,EAAE,CACT,qJAAqJ,EACrJ,SAAS,CACZ,KACG,KAAK,GACX,CACL,CAAC;AACN,CAAC;AAED;;;;GAIG;AACH,MAAM,UAAU,KAAK,CAAC,EAClB,QAAQ,EACR,SAAS,EACT,KAAK,GAKR;IACG,OAAO,CACH,cACI,SAAS,EAAE,EAAE,CACT,4BAA4B,EAC5B,KAAK,IAAI,YAAY,EACrB,cAAc,EACd,oCAAoC,EACpC,kHAAkH,EAClH,0BAA0B,EAC1B,8DAA8D,EAC9D,kCAAkC,EAClC,oGAAoG,EACpG,oCAAoC,EACpC,SAAS,CACZ,YAEA,QAAQ,GACP,CACT,CAAC;AACN,CAAC"}
1
+ {"version":3,"file":"typography.js","sourceRoot":"","sources":["../../../src/components/ui/typography.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,GAAG,EAAqB,MAAM,0BAA0B,CAAC;AAClE,OAAO,EAAE,oBAAoB,EAAwF,MAAM,OAAO,CAAC;AACnI,OAAO,EAAE,QAAQ,EAAE,YAAY,EAAE,aAAa,EAAiB,MAAM,mBAAmB,CAAC;AACzF,OAAO,EAAE,EAAE,EAAE,MAAM,oBAAoB,CAAC;AACxC,OAAO,EAAE,YAAY,EAAE,MAAM,4BAA4B,CAAC;AAE1D;;;;;8EAK8E;AAE9E,MAAM,eAAe,GAAG,GAAG,CAAC,iCAAiC,EAAE;IAC3D,QAAQ,EAAE;QACN,KAAK,EAAE;YACH,OAAO,EAAE,wBAAwB;YACjC,KAAK,EAAE,sBAAsB;YAC7B,CAAC,EAAE,mBAAmB;YACtB,CAAC,EAAE,mBAAmB;YACtB,CAAC,EAAE,qBA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M,SAAS,EAAC,SAAS,YAAE,aAAa,CAAC,IAAI,EAAE,EAAE,CAAC,GAAQ,EACzD,YAAY,CAAC,IAAI,EAAE,EAAE,CAAC,CAAC,GAAG,CAAC,CAAC,GAAG,EAAE,CAAC,EAAE,EAAE,CAAC,CACpC,KAAC,GAAG,mCACC,GAAG,CAAC,KAAK,IADJ,CAAC,CAEL,CACT,CAAC,IACC,CACV,CAAC;AACN,CAAC;AAED;;;;GAIG;AACH,MAAM,UAAU,KAAK,CAAC,EAClB,QAAQ,EACR,SAAS,EACT,KAAK,GAKR;IACG,OAAO,CACH,cACI,SAAS,EAAE,EAAE,CACT,4BAA4B,EAC5B,KAAK,IAAI,YAAY,EACrB,cAAc,EACd,oCAAoC,EACpC,YAAY,EACZ,0BAA0B,EAC1B,8DAA8D,EAC9D,kCAAkC,EAClC,oGAAoG,EACpG,oCAAoC,EACpC,SAAS,CACZ,YAEA,QAAQ,GACP,CACT,CAAC;AACN,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"video-block.d.ts","sourceRoot":"","sources":["../../../src/components/ui/video-block.tsx"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAUvC,wBAAgB,UAAU,CAAC,EACvB,GAAG,EACH,MAAM,EACN,KAAK,EACL,OAAO,EACP,KAAe,EACf,SAAS,GACZ,EAAE;IACC,gDAAgD;IAChD,GAAG,CAAC,EAAE,MAAM,CAAC;IACb,MAAM,CAAC,EAAE,CAAC,GAAG,EAAE,MAAM,KAAK,IAAI,CAAC;IAC/B,uFAAuF;IACvF,KAAK,CAAC,EAAE,CAAC,GAAG,EAAE,MAAM,KAAK,MAAM,GAAG,IAAI,CAAC;IACvC,gDAAgD;IAChD,OAAO,CAAC,EAAE,SAAS,CAAC;IACpB,+BAA+B;IAC/B,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,SAAS,CAAC,EAAE,MAAM,CAAC;CACtB,sCA4BA"}
1
+ {"version":3,"file":"video-block.d.ts","sourceRoot":"","sources":["../../../src/components/ui/video-block.tsx"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAUvC,wBAAgB,UAAU,CAAC,EACvB,GAAG,EACH,MAAM,EACN,KAAK,EACL,OAAO,EACP,KAAe,EACf,SAAS,GACZ,EAAE;IACC,gDAAgD;IAChD,GAAG,CAAC,EAAE,MAAM,CAAC;IACb,MAAM,CAAC,EAAE,CAAC,GAAG,EAAE,MAAM,KAAK,IAAI,CAAC;IAC/B,uFAAuF;IACvF,KAAK,CAAC,EAAE,CAAC,GAAG,EAAE,MAAM,KAAK,MAAM,GAAG,IAAI,CAAC;IACvC,gDAAgD;IAChD,OAAO,CAAC,EAAE,SAAS,CAAC;IACpB,+BAA+B;IAC/B,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,SAAS,CAAC,EAAE,MAAM,CAAC;CACtB,sCAiCA"}
@@ -1,5 +1,6 @@
1
1
  "use client";
2
2
  import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
3
+ import { cn } from "../../lib/utils.js";
3
4
  import { SquarePlay } from "lucide-react";
4
5
  import { videoEmbed } from "../../lib/embed.js";
5
6
  import { AddressField } from "./address-field.js";
@@ -13,6 +14,9 @@ export function VideoBlock({ url, onLink, check, caption, title = "Video", class
13
14
  const embed = url ? videoEmbed(url) : null;
14
15
  if (embed === null)
15
16
  return onLink ? (_jsx(AddressField, { icon: _jsx(SquarePlay, {}), placeholder: "Paste a YouTube or Vimeo link, then Enter", check: (link) => (videoEmbed(link) === null ? "That is not a YouTube or Vimeo link." : null) ?? check?.(link) ?? null, onCommit: onLink, className: className })) : null;
16
- return (_jsxs("figure", { className: className, children: [_jsx("div", { className: "aspect-video overflow-hidden rounded-surface bg-surface-sunken", children: _jsx("iframe", { src: embed, title: title, className: "size-full", allow: "fullscreen; picture-in-picture; encrypted-media", sandbox: "allow-scripts allow-same-origin allow-presentation allow-popups", referrerPolicy: "strict-origin-when-cross-origin", loading: "lazy" }) }), caption !== undefined && _jsx("figcaption", { className: "mt-1.5 text-sm text-ink-secondary", children: caption })] }));
17
+ return (
18
+ // min-w-0: in a grid or flex row the player shrinks to the room there is; an
19
+ // iframe's natural width otherwise pushed a phone's page sideways.
20
+ _jsxs("figure", { className: cn("w-full min-w-0", className), children: [_jsx("div", { className: "relative bg-surface-sunken rounded-surface w-full overflow-hidden aspect-video", children: _jsx("iframe", { src: embed, title: title, className: "absolute inset-0 size-full", allow: "fullscreen; picture-in-picture; encrypted-media", sandbox: "allow-scripts allow-same-origin allow-presentation allow-popups", referrerPolicy: "strict-origin-when-cross-origin", loading: "lazy" }) }), caption !== undefined && _jsx("figcaption", { className: "mt-1.5 text-sm text-ink-secondary", children: caption })] }));
17
21
  }
18
22
  //# sourceMappingURL=video-block.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"video-block.js","sourceRoot":"","sources":["../../../src/components/ui/video-block.tsx"],"names":[],"mappings":"AAAA,YAAY,CAAC;;AAEb,OAAO,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;AAE1C,OAAO,EAAE,UAAU,EAAE,MAAM,oBAAoB,CAAC;AAChD,OAAO,EAAE,YAAY,EAAE,MAAM,oBAAqB,CAAC;AAEnD;;;;;wCAKwC;AACxC,MAAM,UAAU,UAAU,CAAC,EACvB,GAAG,EACH,MAAM,EACN,KAAK,EACL,OAAO,EACP,KAAK,GAAG,OAAO,EACf,SAAS,GAYZ;IACG,MAAM,KAAK,GAAG,GAAG,CAAC,CAAC,CAAC,UAAU,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,IAAI,CAAC;IAC3C,IAAI,KAAK,KAAK,IAAI;QACd,OAAO,MAAM,CAAC,CAAC,CAAC,CACZ,KAAC,YAAY,IACT,IAAI,EAAE,KAAC,UAAU,KAAG,EACpB,WAAW,EAAC,2CAA2C,EACvD,KAAK,EAAE,CAAC,IAAI,EAAE,EAAE,CAAC,CAAC,UAAU,CAAC,IAA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U,KAAG,EACpB,WAAW,EAAC,2CAA2C,EACvD,KAAK,EAAE,CAAC,IAAI,EAAE,EAAE,CAAC,CAAC,UAAU,CAAC,IAAI,CAAC,KAAK,IAAI,CAAC,CAAC,CAAC,sCAAsC,CAAC,CAAC,CAAC,IAAI,CAAC,IAAI,KAAK,EAAE,CAAC,IAAI,CAAC,IAAI,IAAI,EACrH,QAAQ,EAAE,MAAM,EAChB,SAAS,EAAE,SAAS,GACtB,CACL,CAAC,CAAC,CAAC,IAAI,CAAC;IACb,OAAO;IACH,6EAA6E;IAC7E,mEAAmE;IACnE,kBAAQ,SAAS,EAAE,EAAE,CAAC,gBAAgB,EAAE,SAAS,CAAC,aAI9C,cAAK,SAAS,EAAC,gFAAgF,YAC3F,iBACI,GAAG,EAAE,KAAK,EACV,KAAK,EAAE,KAAK,EACZ,SAAS,EAAC,4BAA4B,EACtC,KAAK,EAAC,iDAAiD,EACvD,OAAO,EAAC,iEAAiE,EACzE,cAAc,EAAC,iCAAiC,EAChD,OAAO,EAAC,MAAM,GAChB,GACA,EACL,OAAO,KAAK,SAAS,IAAI,qBAAY,SAAS,EAAC,mCAAmC,YAAE,OAAO,GAAc,IACrG,CACZ,CAAC;AACN,CAAC"}
@@ -0,0 +1,5 @@
1
+ export declare function useDismiss(onClose: () => void): {
2
+ open: boolean;
3
+ dismiss: () => void;
4
+ };
5
+ //# sourceMappingURL=use-dismiss.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"use-dismiss.d.ts","sourceRoot":"","sources":["../../src/hooks/use-dismiss.ts"],"names":[],"mappings":"AAaA,wBAAgB,UAAU,CAAC,OAAO,EAAE,MAAM,IAAI,GAAG;IAAE,IAAI,EAAE,OAAO,CAAC;IAAC,OAAO,EAAE,MAAM,IAAI,CAAA;CAAE,CAUtF"}
@@ -0,0 +1,23 @@
1
+ "use client";
2
+ import { useCallback, useRef, useState } from "react";
3
+ // A little longer than the dialog's closing animation.
4
+ const CLOSING_MS = 170;
5
+ /* For a dialog that only exists while it is open (`{thing && <ThingDialog />}`).
6
+ Unmounting it on close would skip its closing animation, so it first closes,
7
+ then tells its parent once the animation has played. Pass `open` to the Dialog and
8
+ call `dismiss` wherever `onClose` would have gone.
9
+
10
+ From endgame, 2026-12-05. */
11
+ export function useDismiss(onClose) {
12
+ const [open, setOpen] = useState(true);
13
+ const done = useRef(false);
14
+ const dismiss = useCallback(() => {
15
+ if (done.current)
16
+ return;
17
+ done.current = true;
18
+ setOpen(false);
19
+ setTimeout(onClose, CLOSING_MS);
20
+ }, [onClose]);
21
+ return { open, dismiss };
22
+ }
23
+ //# sourceMappingURL=use-dismiss.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"use-dismiss.js","sourceRoot":"","sources":["../../src/hooks/use-dismiss.ts"],"names":[],"mappings":"AAAA,YAAY,CAAC;AAEb,OAAO,EAAE,WAAW,EAAE,MAAM,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAC;AAEtD,uDAAuD;AACvD,MAAM,UAAU,GAAG,GAAG,CAAC;AAEvB;;;;;+BAK+B;AAC/B,MAAM,UAAU,UAAU,CAAC,OAAmB;IAC1C,MAAM,CAAC,IAAI,EAAE,OAAO,CAAC,GAAG,QAAQ,CAAC,IAAI,CAAC,CAAC;IACvC,MAAM,IAAI,GAAG,MAAM,CAAC,KAAK,CAAC,CAAC;IAC3B,MAAM,OAAO,GAAG,WAAW,CAAC,GAAG,EAAE;QAC7B,IAAI,IAAI,CAAC,OAAO;YAAE,OAAO;QACzB,IAAI,CAAC,OAAO,GAAG,IAAI,CAAC;QACpB,OAAO,CAAC,KAAK,CAAC,CAAC;QACf,UAAU,CAAC,OAAO,EAAE,UAAU,CAAC,CAAC;IACpC,CAAC,EAAE,CAAC,OAAO,CAAC,CAAC,CAAC;IACd,OAAO,EAAE,IAAI,EAAE,OAAO,EAAE,CAAC;AAC7B,CAAC"}
@@ -0,0 +1,3 @@
1
+ import { type RefObject } from "react";
2
+ export declare function useEscapeFirst(active: boolean, target: RefObject<Element | null> | ((el: EventTarget | null) => boolean), onEscape: () => void): void;
3
+ //# sourceMappingURL=use-escape-first.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"use-escape-first.d.ts","sourceRoot":"","sources":["../../src/hooks/use-escape-first.ts"],"names":[],"mappings":"AAEA,OAAO,EAAqB,KAAK,SAAS,EAAE,MAAM,OAAO,CAAC;AAO1D,wBAAgB,cAAc,CAAC,MAAM,EAAE,OAAO,EAAE,MAAM,EAAE,SAAS,CAAC,OAAO,GAAG,IAAI,CAAC,GAAG,CAAC,CAAC,EAAE,EAAE,WAAW,GAAG,IAAI,KAAK,OAAO,CAAC,EAAE,QAAQ,EAAE,MAAM,IAAI,QAe9I"}
@@ -0,0 +1,27 @@
1
+ "use client";
2
+ import { useEffect, useRef } from "react";
3
+ /* Escape, while `active`, does `onEscape` and nothing else: a list closes without
4
+ closing the dialog around it. A Radix dialog listens for Escape on the document as
5
+ the key travels down the tree, before the field hears it, so stopping it in the
6
+ field's own handler is too late; the window hears it first of all. Only keys from
7
+ `target` (an element, or a test of the event's target) count. */
8
+ export function useEscapeFirst(active, target, onEscape) {
9
+ const latest = useRef(onEscape);
10
+ latest.current = onEscape;
11
+ useEffect(() => {
12
+ if (!active)
13
+ return;
14
+ const onKey = (e) => {
15
+ if (e.key !== "Escape" || e.isComposing)
16
+ return;
17
+ const ours = typeof target === "function" ? target(e.target) : e.target === target.current;
18
+ if (!ours)
19
+ return;
20
+ e.stopPropagation();
21
+ latest.current();
22
+ };
23
+ window.addEventListener("keydown", onKey, { capture: true });
24
+ return () => window.removeEventListener("keydown", onKey, { capture: true });
25
+ }, [active, target]);
26
+ }
27
+ //# sourceMappingURL=use-escape-first.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"use-escape-first.js","sourceRoot":"","sources":["../../src/hooks/use-escape-first.ts"],"names":[],"mappings":"AAAA,YAAY,CAAC;AAEb,OAAO,EAAE,SAAS,EAAE,MAAM,EAAkB,MAAM,OAAO,CAAC;AAE1D;;;;mEAImE;AACnE,MAAM,UAAU,cAAc,CAAC,MAAe,EAAE,MAAyE,EAAE,QAAoB;IAC3I,MAAM,MAAM,GAAG,MAAM,CAAC,QAAQ,CAAC,CAAC;IAChC,MAAM,CAAC,OAAO,GAAG,QAAQ,CAAC;IAC1B,SAAS,CAAC,GAAG,EAAE;QACX,IAAI,CAAC,MAAM;YAAE,OAAO;QACpB,MAAM,KAAK,GAAG,CAAC,CAAgB,EAAE,EAAE;YAC/B,IAAI,CAAC,CAAC,GAAG,KAAK,QAAQ,IAAI,CAAC,CAAC,WAAW;gBAAE,OAAO;YAChD,MAAM,IAAI,GAAG,OAAO,MAAM,KAAK,UAAU,CAAC,CAAC,CAAC,MAAM,CAAC,CAAC,CAAC,MAAM,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,MAAM,KAAK,MAAM,CAAC,OAAO,CAAC;YAC3F,IAAI,CAAC,IAAI;gBAAE,OAAO;YAClB,CAAC,CAAC,eAAe,EAAE,CAAC;YACpB,MAAM,CAAC,OAAO,EAAE,CAAC;QACrB,CAAC,CAAC;QACF,MAAM,CAAC,gBAAgB,CAAC,SAAS,EAAE,KAAK,EAAE,EAAE,OAAO,EAAE,IAAI,EAAE,CAAC,CAAC;QAC7D,OAAO,GAAG,EAAE,CAAC,MAAM,CAAC,mBAAmB,CAAC,SAAS,EAAE,KAAK,EAAE,EAAE,OAAO,EAAE,IAAI,EAAE,CAAC,CAAC;IACjF,CAAC,EAAE,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC,CAAC;AACzB,CAAC"}
@@ -0,0 +1,5 @@
1
+ export declare function useMediaQuery(query: string): boolean;
2
+ /** Narrower than Tailwind's `md` (48rem): where the kit's layouts switch to their phone shape. */
3
+ export declare const PHONE_QUERY = "(max-width: 47.99rem)";
4
+ export declare const useIsPhone: () => boolean;
5
+ //# sourceMappingURL=use-media-query.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"use-media-query.d.ts","sourceRoot":"","sources":["../../src/hooks/use-media-query.ts"],"names":[],"mappings":"AAOA,wBAAgB,aAAa,CAAC,KAAK,EAAE,MAAM,GAAG,OAAO,CAUpD;AAED,kGAAkG;AAClG,eAAO,MAAM,WAAW,0BAA0B,CAAC;AAEnD,eAAO,MAAM,UAAU,QAAO,OAAqC,CAAC"}
@@ -0,0 +1,16 @@
1
+ "use client";
2
+ import { useSyncExternalStore } from "react";
3
+ /* Whether a media query matches now, kept up to date as the window changes. False
4
+ on the server and in the first render after it, so a server-rendered page and
5
+ its hydration agree; it settles on the next render. */
6
+ export function useMediaQuery(query) {
7
+ return useSyncExternalStore((onChange) => {
8
+ const list = window.matchMedia(query);
9
+ list.addEventListener("change", onChange);
10
+ return () => list.removeEventListener("change", onChange);
11
+ }, () => window.matchMedia(query).matches, () => false);
12
+ }
13
+ /** Narrower than Tailwind's `md` (48rem): where the kit's layouts switch to their phone shape. */
14
+ export const PHONE_QUERY = "(max-width: 47.99rem)";
15
+ export const useIsPhone = () => useMediaQuery(PHONE_QUERY);
16
+ //# sourceMappingURL=use-media-query.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"use-media-query.js","sourceRoot":"","sources":["../../src/hooks/use-media-query.ts"],"names":[],"mappings":"AAAA,YAAY,CAAC;AAEb,OAAO,EAAE,oBAAoB,EAAE,MAAM,OAAO,CAAC;AAE7C;;yDAEyD;AACzD,MAAM,UAAU,aAAa,CAAC,KAAa;IACvC,OAAO,oBAAoB,CACvB,CAAC,QAAQ,EAAE,EAAE;QACT,MAAM,IAAI,GAAG,MAAM,CAAC,UAAU,CAAC,KAAK,CAAC,CAAC;QACtC,IAAI,CAAC,gBAAgB,CAAC,QAAQ,EAAE,QAAQ,CAAC,CAAC;QAC1C,OAAO,GAAG,EAAE,CAAC,IAAI,CAAC,mBAAmB,CAAC,QAAQ,EAAE,QAAQ,CAAC,CAAC;IAC9D,CAAC,EACD,GAAG,EAAE,CAAC,MAAM,CAAC,UAAU,CAAC,KAAK,CAAC,CAAC,OAAO,EACtC,GAAG,EAAE,CAAC,KAAK,CACd,CAAC;AACN,CAAC;AAED,kGAAkG;AAClG,MAAM,CAAC,MAAM,WAAW,GAAG,uBAAuB,CAAC;AAEnD,MAAM,CAAC,MAAM,UAAU,GAAG,GAAY,EAAE,CAAC,aAAa,CAAC,WAAW,CAAC,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"use-save-queue.d.ts","sourceRoot":"","sources":["../../src/hooks/use-save-queue.ts"],"names":[],"mappings":"AAcA,wBAAgB,YAAY,CAAC,CAAC,EAAE,EAC5B,IAAI,EACJ,KAAW,GACd,EAAE;IAGC,IAAI,EAAE,CAAC,GAAG,EAAE,CAAC,EAAE,IAAI,EAAE;QAAE,SAAS,EAAE,OAAO,CAAA;KAAE,KAAK,OAAO,CAAC,OAAO,CAAC,CAAC;IACjE,KAAK,CAAC,EAAE,MAAM,CAAC;CAClB;;mBAQqC,MAAM,OAAO,CAAC,OAAO,CAAC;oBAkB9C,CAAC;iBARD,CAAC;kBANsB,CAAC;EA+BrC"}
1
+ {"version":3,"file":"use-save-queue.d.ts","sourceRoot":"","sources":["../../src/hooks/use-save-queue.ts"],"names":[],"mappings":"AAcA,wBAAgB,YAAY,CAAC,CAAC,EAAE,EAC5B,IAAI,EACJ,KAAW,GACd,EAAE;IAGC,IAAI,EAAE,CAAC,GAAG,EAAE,CAAC,EAAE,IAAI,EAAE;QAAE,SAAS,EAAE,OAAO,CAAA;KAAE,KAAK,OAAO,CAAC,OAAO,CAAC,CAAC;IACjE,KAAK,CAAC,EAAE,MAAM,CAAC;CAClB;;mBAQqC,MAAM,OAAO,CAAC,OAAO,CAAC;oBAkB9C,CAAC;iBARD,CAAC;kBANsB,CAAC;EA2CrC"}
@@ -8,7 +8,7 @@ import { useCallback, useEffect, useRef, useState } from "react";
8
8
 
9
9
  Everything goes to the server one request at a time, in the order it was asked
10
10
  for, so a move can never overtake the edit before it. Pending saves are flushed
11
- when the page is hidden. The first failure is kept in `error` and nothing is
11
+ when the page is hidden or closed, at once and as keepalive requests. The first failure is kept in `error` and nothing is
12
12
  retried: show it and offer a reload, rather than guess what the server holds. */
13
13
  export function useSaveQueue({ save, delay = 600, }) {
14
14
  const [error, setError] = useState(null);
@@ -18,7 +18,7 @@ export function useSaveQueue({ save, delay = 600, }) {
18
18
  const saver = useRef(save);
19
19
  saver.current = save;
20
20
  const enqueue = useCallback((job) => {
21
- queue.current = queue.current.then(job).catch((err) => setError(err.message));
21
+ queue.current = queue.current.then(job).catch((err) => setError((first) => first ?? err.message));
22
22
  }, []);
23
23
  const cancel = useCallback((key) => {
24
24
  clearTimeout(timers.current.get(key));
@@ -33,13 +33,25 @@ export function useSaveQueue({ save, delay = 600, }) {
33
33
  timers.current.set(key, setTimeout(() => flush(key), delay));
34
34
  }, [cancel, flush, delay]);
35
35
  useEffect(() => {
36
- const flushAll = () => [...timers.current.keys()].forEach((key) => flush(key, true));
37
- window.addEventListener("pagehide", flushAll);
36
+ // The page is going (closed, or hidden on a phone, which may be the last
37
+ // signal before the app is killed): pending saves go now, as keepalive
38
+ // requests, not behind one already on its way, which may never finish.
39
+ const sendNow = () => {
40
+ for (const key of [...timers.current.keys()]) {
41
+ cancel(key);
42
+ saver.current(key, { keepalive: true }).catch((err) => setError((first) => first ?? err.message));
43
+ }
44
+ };
45
+ const onHidden = () => document.visibilityState === "hidden" && sendNow();
46
+ window.addEventListener("pagehide", sendNow);
47
+ document.addEventListener("visibilitychange", onHidden);
38
48
  return () => {
39
- window.removeEventListener("pagehide", flushAll);
40
- flushAll();
49
+ window.removeEventListener("pagehide", sendNow);
50
+ document.removeEventListener("visibilitychange", onHidden);
51
+ // Unmounting within a living page: saved in their turn.
52
+ [...timers.current.keys()].forEach((key) => flush(key));
41
53
  };
42
- }, [flush]);
54
+ }, [flush, cancel]);
43
55
  return { error, enqueue, schedule, flush, cancel };
44
56
  }
45
57
  //# sourceMappingURL=use-save-queue.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"use-save-queue.js","s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M,CAAC,OAAO,CAAC,IAAI,EAAE,CAAC,CAAC,OAAO,CAAC,CAAC,GAAG,EAAE,EAAE,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC,CAAC;QAC5D,CAAC,CAAC;IACN,CAAC,EAAE,CAAC,KAAK,EAAE,MAAM,CAAC,CAAC,CAAC;IAEpB,OAAO,EAAE,KAAK,EAAE,OAAO,EAAE,QAAQ,EAAE,KAAK,EAAE,MAAM,EAAE,CAAC;AACvD,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"use-selection.d.ts","sourceRoot":"","sources":["../../src/hooks/use-selection.ts"],"names":[],"mappings":"AAIA,MAAM,MAAM,SAAS,GAAG;IAAE,GAAG,EAAE,GAAG,CAAC,MAAM,CAAC,CAAC;IAAC,MAAM,EAAE,CAAC,EAAE,EAAE,MAAM,EAAE,KAAK,EAAE,OAAO,KAAK,IAAI,CAAA;CAAE,CAAC;AAQ3F,wBAAgB,YAAY,CAAC,KAAK,EAAE,MAAM,EAAE,GAAG;IAAE,SAAS,EAAE,SAAS,GAAG,IAAI,CAAC;IAAC,KAAK,EAAE,MAAM,IAAI,CAAC;IAAC,IAAI,EAAE,MAAM,IAAI,CAAA;CAAE,CA+BlH"}
1
+ {"version":3,"file":"use-selection.d.ts","sourceRoot":"","sources":["../../src/hooks/use-selection.ts"],"names":[],"mappings":"AAIA,MAAM,MAAM,SAAS,GAAG;IAAE,GAAG,EAAE,GAAG,CAAC,MAAM,CAAC,CAAC;IAAC,MAAM,EAAE,CAAC,EAAE,EAAE,MAAM,EAAE,KAAK,EAAE,OAAO,KAAK,IAAI,CAAA;CAAE,CAAC;AAQ3F,wBAAgB,YAAY,CAAC,KAAK,EAAE,MAAM,EAAE,GAAG;IAAE,SAAS,EAAE,SAAS,GAAG,IAAI,CAAC;IAAC,KAAK,EAAE,MAAM,IAAI,CAAC;IAAC,IAAI,EAAE,MAAM,IAAI,CAAA;CAAE,CAsClH"}
@@ -17,7 +17,16 @@ export function useSelection(order) {
17
17
  useEffect(() => {
18
18
  if (!selecting)
19
19
  return;
20
- const onKey = (event) => event.key === "Escape" && stop();
20
+ // Escape ends the selection, unless it was meant for something over the page:
21
+ // the confirm() asked about deleting the selection, a menu, a list. That
22
+ // closes, and the selection stays.
23
+ const onKey = (event) => {
24
+ if (event.key !== "Escape" || event.defaultPrevented)
25
+ return;
26
+ if (document.querySelector('[role="dialog"], [role="alertdialog"], [role="menu"], [role="listbox"]'))
27
+ return;
28
+ stop();
29
+ };
21
30
  window.addEventListener("keydown", onKey);
22
31
  return () => window.removeEventListener("keydown", onKey);
23
32
  }, [selecting]);
@@ -1 +1 @@
1
- {"version":3,"file":"use-selection.js","sourceRoot":"","sources":["../../src/hooks/use-selection.ts"],"names":[],"mappings":"AAAA,YAAY,CAAC;AAEb,OAAO,EAAE,SAAS,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAC;AAI5C;;;;;YAKY;AACZ,MAAM,UAAU,YAAY,CAAC,KAAe;IACxC,MAAM,CAAC,GAAG,EAAE,MAAM,CAAC,GAAG,QAAQ,CAAqB,IAAI,CAAC,CAAC;IACzD,MAAM,CAAC,MAAM,EAAE,SAAS,CAAC,GAAG,QAAQ,CAAgB,IAAI,CAAC,CAAC;IAC1D,MAAM,SAAS,GAAG,GAAG,KAAK,IAAI,CAAC;IAE/B,MAAM,IAAI,GAAG,GAAG,EAAE;QACd,MAAM,CAAC,IAAI,CAAC,CAAC;QACb,SAAS,CAAC,IAAI,CAAC,CAAC;IACpB,CAAC,CAAC;IACF,SAAS,CAAC,GAAG,EAAE;QACX,IAAI,CAAC,SAAS;YAAE,OAAO;QACvB,MAAM,KAAK,GAAG,CAAC,KAAoB,EAAE,EAAE,CAAC,KAAK,CAAC,GAAG,KAAK,QAAQ,IAAI,IAAI,EAAE,CAAC;QACzE,MAAM,CAAC,gBAAgB,CAAC,SAAS,EAAE,KAAK,CAAC,CAAC;QAC1C,OAAO,GAAG,EAAE,CAAC,MAAM,CAAC,mBAAmB,CAAC,S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AI,GAAG,IAAI,GAAG,CAAC,IAAI,CAAC,CAAC;YAC3B,MAAM,IAAI,GAAG,MAAM,KAAK,IAAI,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,KAAK,CAAC,OAAO,CAAC,MAAM,CAAC,CAAC;YAC1D,MAAM,EAAE,GAAG,KAAK,CAAC,OAAO,CAAC,EAAE,CAAC,CAAC;YAC7B,IAAI,KAAK,IAAI,IAAI,KAAK,CAAC,CAAC,IAAI,EAAE,KAAK,CAAC,CAAC,EAAE,CAAC;gBACpC,KAAK,MAAM,OAAO,IAAI,KAAK,CAAC,KAAK,CAAC,IAAI,CAAC,GAAG,CAAC,IAAI,EAAE,EAAE,CAAC,EAAE,IAAI,CAAC,GAAG,CAAC,IAAI,EAAE,EAAE,CAAC,GAAG,CAAC,CAAC;oBAAE,IAAI,CAAC,GAAG,CAAC,OAAO,CAAC,CAAC;YACrG,CAAC;iBAAM,IAAI,IAAI,CAAC,GAAG,CAAC,EAAE,CAAC;gBAAE,IAAI,CAAC,MAAM,CAAC,EAAE,CAAC,CAAC;;gBACpC,IAAI,CAAC,GAAG,CAAC,EAAE,CAAC,CAAC;YAClB,OAAO,IAAI,CAAC;QAChB,CAAC,CAAC,CAAC;QACH,SAAS,CAAC,EAAE,CAAC,CAAC;IAClB,CAAC,CAAC;IAEF,OAAO,EAAE,SAAS,EAAE,GAAG,KAAK,IAAI,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,EAAE,GAAG,EAAE,MAAM,EAAE,EAAE,KAAK,EAAE,GAAG,EAAE,CAAC,MAAM,CAAC,IAAI,GAAG,EAAE,CAAC,EAAE,IAAI,EAAE,CAAC;AACtG,CAAC"}
@@ -0,0 +1,92 @@
1
+ export type PropertyType = "title" | "text" | "number" | "select" | "multiSelect" | "date" | "checkbox" | "url";
2
+ export type TagColor = "gray" | "brown" | "orange" | "yellow" | "green" | "blue" | "purple" | "pink" | "red";
3
+ export type PropertyOption = {
4
+ id: string;
5
+ name: string;
6
+ color: TagColor;
7
+ };
8
+ export type Property = {
9
+ id: string;
10
+ name: string;
11
+ type: PropertyType;
12
+ options?: PropertyOption[];
13
+ };
14
+ export type Value = string | number | boolean | string[] | null;
15
+ export type Row = {
16
+ id: string;
17
+ values: Record<string, Value>;
18
+ cover?: string | null;
19
+ };
20
+ export type FilterOp = "contains" | "notContains" | "is" | "isNot" | "isEmpty" | "isNotEmpty" | "gt" | "lt" | "gte" | "lte" | "before" | "after" | "onOrBefore" | "onOrAfter";
21
+ export type Filter = {
22
+ id: string;
23
+ property: string;
24
+ op: FilterOp;
25
+ value?: Value;
26
+ };
27
+ export type Match = "all" | "any";
28
+ export type Sort = {
29
+ property: string;
30
+ direction: "asc" | "desc";
31
+ };
32
+ /** What can be asked of each kind of property, in the order a menu shows them, with their words. */
33
+ export declare const OPS: Record<PropertyType, readonly {
34
+ op: FilterOp;
35
+ label: string;
36
+ }[]>;
37
+ /** Whether an op needs a value to compare with (is empty does not). */
38
+ export declare const needsValue: (op: FilterOp) => op is "before" | "after" | "is" | "contains" | "notContains" | "isNot" | "gt" | "lt" | "gte" | "lte" | "onOrBefore" | "onOrAfter";
39
+ export declare const isEmpty: (v: Value | undefined) => boolean;
40
+ /** A filter just added for `property`: its first op, and for a checkbox, checked. */
41
+ export declare function newFilter(property: Property, id: string): Filter;
42
+ /** Whether `row` passes `filter`. A filter still missing its value lets everything through, so a half-written one never empties the view. */
43
+ export declare function passes(row: Row, filter: Filter, property: Property | undefined): boolean;
44
+ /** Whether a filter says anything yet: its property exists, and it has a value if it needs one. */
45
+ export declare function isActive(filter: Filter, property: Property | undefined): boolean;
46
+ /** Rows passing all (or any) of the filters. Filters that say nothing yet (a deleted property, a value not given) are left out,
47
+ so with "any" a half-written one does not let every row through. */
48
+ export declare function filterRows(rows: readonly Row[], properties: readonly Property[], filters: readonly Filter[], match?: Match): Row[];
49
+ /** How two values of `property` order, ascending. Empty sorts last, whichever way. */
50
+ export declare function compareValues(a: Value | undefined, b: Value | undefined, property: Property): number;
51
+ /** Sorted by each sort in turn; rows equal on all of them keep their order. */
52
+ export declare function sortRows(rows: readonly Row[], properties: readonly Property[], sorts: readonly Sort[]): Row[];
53
+ export type Group = {
54
+ key: string | null;
55
+ option: PropertyOption | null;
56
+ rows: Row[];
57
+ };
58
+ /** Rows by a select (or a checkbox): a group per option in its order, then "No value". Empty groups are kept, for a board's columns. */
59
+ export declare function groupRows(rows: readonly Row[], property: Property): Group[];
60
+ /** The first title property, which names a row. */
61
+ export declare const titleOf: (properties: readonly Property[]) => Property | undefined;
62
+ /** A value as words, for a screen reader or a plain cell. */
63
+ export declare function valueText(v: Value | undefined, property: Property): string;
64
+ export type ViewKind = "table" | "board" | "gallery" | "list" | "calendar";
65
+ /** One way of seeing the rows. A view keeps its own filter, sort, hidden properties and, per kind, what it groups or dates by. */
66
+ export type View = {
67
+ id: string;
68
+ name: string;
69
+ kind: ViewKind;
70
+ sort: Sort[];
71
+ filter: Filter[];
72
+ match?: Match;
73
+ /** A board's columns: a select property. */
74
+ groupBy?: string;
75
+ /** A calendar's days: a date property. */
76
+ dateProperty?: string;
77
+ /** Properties not shown (a table's columns, a card's lines). */
78
+ hidden: string[];
79
+ /** A table's column widths, in px, by property. */
80
+ widths?: Record<string, number>;
81
+ /** A table's column order, by property id; any not listed follow in the properties' order. */
82
+ order?: string[];
83
+ };
84
+ /** Rows whose words (title, text, url, select and multi-select names) contain `query`, ignoring case. */
85
+ export declare function searchRows(rows: readonly Row[], properties: readonly Property[], query: string): Row[];
86
+ /** What a view shows: searched, filtered, then sorted. */
87
+ export declare function applyView(rows: readonly Row[], properties: readonly Property[], view: Pick<View, "filter" | "sort" | "match">, query?: string): Row[];
88
+ /** A view's properties to show, in its order, without the hidden ones. The title always shows. */
89
+ export declare function shownProperties(properties: readonly Property[], view: Pick<View, "hidden" | "order">): Property[];
90
+ /** A fresh view of `kind`, choosing what a board groups by and a calendar dates by. */
91
+ export declare function newView(kind: ViewKind, properties: readonly Property[], id: string, name?: string): View;
92
+ //# sourceMappingURL=database.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"database.d.ts","sourceRoot":"","sources":["../../src/lib/database.ts"],"names":[],"mappings":"AASA,MAAM,MAAM,YAAY,GAAG,OAAO,GAAG,MAAM,GAAG,QAAQ,GAAG,QAAQ,GAAG,aAAa,GAAG,MAAM,GAAG,UAAU,GAAG,KAAK,CAAC;AAEhH,MAAM,MAAM,QAAQ,GAAG,MAAM,GAAG,OAAO,GAAG,QAAQ,GAAG,QAAQ,GAAG,OAAO,GAAG,MAAM,GAAG,QAAQ,GAAG,MAAM,GAAG,KAAK,CAAC;AAE7G,MAAM,MAAM,cAAc,GAAG;IAAE,EAAE,EAAE,MAAM,CAAC;IAAC,IAAI,EAAE,MAAM,CAAC;IAAC,KAAK,EAAE,QAAQ,CAAA;CAAE,CAAC;AAE3E,MAAM,MAAM,QAAQ,GAAG;IAAE,EAAE,EAAE,MAAM,CAAC;IAAC,IAAI,EAAE,MAAM,CAAC;IAAC,IAAI,EAAE,YAAY,CAAC;IAAC,OAAO,CAAC,EAAE,cAAc,EAAE,CAAA;CAAE,CAAC;AAEpG,MAAM,MAAM,KAAK,GAAG,MAAM,GAAG,MAAM,GAAG,OAAO,GAAG,MAAM,EAAE,GAAG,IAAI,CAAC;AAEhE,MAAM,MAAM,GAAG,GAAG;IAAE,EAAE,EAAE,MAAM,CAAC;IAAC,MAAM,EAAE,MAAM,CAAC,MAAM,EAAE,KAAK,CAAC,CAAC;IAAC,KAAK,CAAC,EAAE,MAAM,GAAG,IAAI,CAAA;CAAE,CAAC;AAEvF,MAAM,MAAM,QAAQ,GACd,UAAU,GACV,aAAa,GACb,IAAI,GACJ,OAAO,GACP,SAAS,GACT,YAAY,GACZ,IAAI,GACJ,IAAI,GACJ,KAAK,GACL,KAAK,GACL,QAAQ,GACR,OAAO,GACP,YAAY,GACZ,WAAW,CAAC;AAElB,MAAM,MAAM,MAAM,GAAG;IAAE,EAAE,EAAE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