@bridgebrew/ui 0.0.0-stage → 0.1.9

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 (411) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +39 -2
  3. package/SOURCE.md +182 -0
  4. package/dist/build.js +871 -0
  5. package/dist/theme-css.js +896 -0
  6. package/dist/themes.js +69 -0
  7. package/dist/types/build/stylesheet.d.ts +31 -0
  8. package/dist/types/components/composite/command/command.d.ts +94 -0
  9. package/dist/types/components/composite/command/index.d.ts +2 -0
  10. package/dist/types/components/composite/draft-bar/draft-bar.d.ts +12 -0
  11. package/dist/types/components/composite/draft-bar/index.d.ts +2 -0
  12. package/dist/types/components/composite/image-field/image-field.d.ts +33 -0
  13. package/dist/types/components/composite/image-field/index.d.ts +2 -0
  14. package/dist/types/components/composite/list/index.d.ts +3 -0
  15. package/dist/types/components/composite/list/list-swipe.d.ts +28 -0
  16. package/dist/types/components/composite/list/list.d.ts +95 -0
  17. package/dist/types/components/composite/picker/index.d.ts +2 -0
  18. package/dist/types/components/composite/picker/picker.d.ts +44 -0
  19. package/dist/types/components/composite/prompt-field/index.d.ts +2 -0
  20. package/dist/types/components/composite/prompt-field/prompt-field.d.ts +18 -0
  21. package/dist/types/components/composite/properties/index.d.ts +2 -0
  22. package/dist/types/components/composite/properties/properties.d.ts +24 -0
  23. package/dist/types/components/composite/snooze-menu/index.d.ts +4 -0
  24. package/dist/types/components/composite/snooze-menu/presets.d.ts +36 -0
  25. package/dist/types/components/composite/snooze-menu/snooze-menu.d.ts +27 -0
  26. package/dist/types/components/composite/tag-input/index.d.ts +2 -0
  27. package/dist/types/components/composite/tag-input/tag-input.d.ts +22 -0
  28. package/dist/types/components/composite/wizard/index.d.ts +2 -0
  29. package/dist/types/components/composite/wizard/wizard.d.ts +53 -0
  30. package/dist/types/components/core/avatar/avatar.d.ts +16 -0
  31. package/dist/types/components/core/avatar/index.d.ts +2 -0
  32. package/dist/types/components/core/badge/badge.d.ts +8 -0
  33. package/dist/types/components/core/badge/index.d.ts +2 -0
  34. package/dist/types/components/core/breadcrumb/breadcrumb.d.ts +21 -0
  35. package/dist/types/components/core/breadcrumb/index.d.ts +2 -0
  36. package/dist/types/components/core/bullets/bullets.d.ts +15 -0
  37. package/dist/types/components/core/bullets/index.d.ts +2 -0
  38. package/dist/types/components/core/button/button.d.ts +14 -0
  39. package/dist/types/components/core/button/index.d.ts +2 -0
  40. package/dist/types/components/core/card/card.d.ts +16 -0
  41. package/dist/types/components/core/card/index.d.ts +2 -0
  42. package/dist/types/components/core/checkbox/checkbox.d.ts +15 -0
  43. package/dist/types/components/core/checkbox/index.d.ts +2 -0
  44. package/dist/types/components/core/cluster/cluster.d.ts +5 -0
  45. package/dist/types/components/core/cluster/index.d.ts +1 -0
  46. package/dist/types/components/core/code-block/code-block.d.ts +18 -0
  47. package/dist/types/components/core/code-block/index.d.ts +2 -0
  48. package/dist/types/components/core/collapsible/collapsible.d.ts +8 -0
  49. package/dist/types/components/core/collapsible/index.d.ts +1 -0
  50. package/dist/types/components/core/colour-picker/colour-picker.d.ts +25 -0
  51. package/dist/types/components/core/colour-picker/index.d.ts +4 -0
  52. package/dist/types/components/core/combobox/combobox.d.ts +63 -0
  53. package/dist/types/components/core/combobox/index.d.ts +2 -0
  54. package/dist/types/components/core/detail/detail.d.ts +12 -0
  55. package/dist/types/components/core/detail/index.d.ts +1 -0
  56. package/dist/types/components/core/dialog/dialog.d.ts +43 -0
  57. package/dist/types/components/core/dialog/drag.d.ts +4 -0
  58. package/dist/types/components/core/dialog/index.d.ts +2 -0
  59. package/dist/types/components/core/drop-zone/drop-zone.d.ts +23 -0
  60. package/dist/types/components/core/drop-zone/index.d.ts +2 -0
  61. package/dist/types/components/core/dropdown-menu/dropdown-menu.d.ts +78 -0
  62. package/dist/types/components/core/dropdown-menu/index.d.ts +2 -0
  63. package/dist/types/components/core/editable-field/editable-field.d.ts +42 -0
  64. package/dist/types/components/core/editable-field/index.d.ts +2 -0
  65. package/dist/types/components/core/empty-state/empty-state.d.ts +11 -0
  66. package/dist/types/components/core/empty-state/index.d.ts +2 -0
  67. package/dist/types/components/core/field/field.d.ts +31 -0
  68. package/dist/types/components/core/field/index.d.ts +2 -0
  69. package/dist/types/components/core/icon/icon-sets.d.ts +38 -0
  70. package/dist/types/components/core/icon/icon.d.ts +14 -0
  71. package/dist/types/components/core/icon/index.d.ts +2 -0
  72. package/dist/types/components/core/input/index.d.ts +4 -0
  73. package/dist/types/components/core/input/input.d.ts +22 -0
  74. package/dist/types/components/core/input/textarea.d.ts +8 -0
  75. package/dist/types/components/core/kbd/index.d.ts +2 -0
  76. package/dist/types/components/core/kbd/kbd.d.ts +7 -0
  77. package/dist/types/components/core/label/index.d.ts +2 -0
  78. package/dist/types/components/core/label/label.d.ts +13 -0
  79. package/dist/types/components/core/main-content/index.d.ts +2 -0
  80. package/dist/types/components/core/main-content/main-content.d.ts +18 -0
  81. package/dist/types/components/core/pane/index.d.ts +1 -0
  82. package/dist/types/components/core/pane/pane.d.ts +12 -0
  83. package/dist/types/components/core/pick-menu/index.d.ts +4 -0
  84. package/dist/types/components/core/pick-menu/pick-menu.d.ts +57 -0
  85. package/dist/types/components/core/pick-menu/tag-menu.d.ts +19 -0
  86. package/dist/types/components/core/popover/index.d.ts +2 -0
  87. package/dist/types/components/core/popover/popover.d.ts +22 -0
  88. package/dist/types/components/core/progress/index.d.ts +2 -0
  89. package/dist/types/components/core/progress/progress.d.ts +13 -0
  90. package/dist/types/components/core/resizable/index.d.ts +2 -0
  91. package/dist/types/components/core/resizable/resizable.d.ts +15 -0
  92. package/dist/types/components/core/resizable/use-remembered-layout.d.ts +31 -0
  93. package/dist/types/components/core/screen-link/index.d.ts +2 -0
  94. package/dist/types/components/core/screen-link/screen-link.d.ts +52 -0
  95. package/dist/types/components/core/scroll-area/index.d.ts +2 -0
  96. package/dist/types/components/core/scroll-area/scroll-area.d.ts +13 -0
  97. package/dist/types/components/core/scroll-area/steps.d.ts +5 -0
  98. package/dist/types/components/core/section/index.d.ts +2 -0
  99. package/dist/types/components/core/section/section.d.ts +16 -0
  100. package/dist/types/components/core/segment-group/index.d.ts +2 -0
  101. package/dist/types/components/core/segment-group/segment-group.d.ts +24 -0
  102. package/dist/types/components/core/select/index.d.ts +2 -0
  103. package/dist/types/components/core/select/select.d.ts +39 -0
  104. package/dist/types/components/core/skeleton/index.d.ts +2 -0
  105. package/dist/types/components/core/skeleton/skeleton.d.ts +13 -0
  106. package/dist/types/components/core/slider/index.d.ts +2 -0
  107. package/dist/types/components/core/slider/slider.d.ts +9 -0
  108. package/dist/types/components/core/sortable/index.d.ts +2 -0
  109. package/dist/types/components/core/sortable/sortable.d.ts +53 -0
  110. package/dist/types/components/core/split-view/index.d.ts +2 -0
  111. package/dist/types/components/core/split-view/split-view.d.ts +28 -0
  112. package/dist/types/components/core/status-icon/index.d.ts +2 -0
  113. package/dist/types/components/core/status-icon/status-icon.d.ts +13 -0
  114. package/dist/types/components/core/table/collapsible-rows.d.ts +7 -0
  115. package/dist/types/components/core/table/expand-toggle.d.ts +10 -0
  116. package/dist/types/components/core/table/group-header.d.ts +14 -0
  117. package/dist/types/components/core/table/index.d.ts +8 -0
  118. package/dist/types/components/core/table/table.d.ts +31 -0
  119. package/dist/types/components/core/tabs/index.d.ts +2 -0
  120. package/dist/types/components/core/tabs/tabs.d.ts +20 -0
  121. package/dist/types/components/core/tag-pill/index.d.ts +2 -0
  122. package/dist/types/components/core/tag-pill/tag-pill.d.ts +25 -0
  123. package/dist/types/components/core/thumbnail/index.d.ts +2 -0
  124. package/dist/types/components/core/thumbnail/thumbnail.d.ts +23 -0
  125. package/dist/types/components/core/toast/index.d.ts +2 -0
  126. package/dist/types/components/core/toast/toast.d.ts +88 -0
  127. package/dist/types/components/core/toggle/index.d.ts +2 -0
  128. package/dist/types/components/core/toggle/toggle.d.ts +9 -0
  129. package/dist/types/components/core/toggle-group/index.d.ts +2 -0
  130. package/dist/types/components/core/toggle-group/toggle-group.d.ts +21 -0
  131. package/dist/types/components/core/tooltip/index.d.ts +2 -0
  132. package/dist/types/components/core/tooltip/tooltip.d.ts +33 -0
  133. package/dist/types/components/layout/multi-pane/index.d.ts +4 -0
  134. package/dist/types/components/layout/multi-pane/list-detail.d.ts +17 -0
  135. package/dist/types/components/layout/multi-pane/multi-pane.d.ts +34 -0
  136. package/dist/types/components/layout/single-pane/index.d.ts +2 -0
  137. package/dist/types/components/layout/single-pane/single-pane.d.ts +11 -0
  138. package/dist/types/components/shell/app-shell/app-shell.d.ts +12 -0
  139. package/dist/types/components/shell/app-shell/index.d.ts +2 -0
  140. package/dist/types/components/shell/sidebar/index.d.ts +2 -0
  141. package/dist/types/components/shell/sidebar/sidebar-group.d.ts +45 -0
  142. package/dist/types/components/shell/sidebar/sidebar-item.d.ts +19 -0
  143. package/dist/types/components/shell/sidebar/sidebar-resize-handle.d.ts +17 -0
  144. package/dist/types/components/shell/sidebar/sidebar-tree.d.ts +42 -0
  145. package/dist/types/components/shell/sidebar/sidebar.d.ts +27 -0
  146. package/dist/types/components/template/address-book-template/address-book-template.d.ts +15 -0
  147. package/dist/types/components/template/address-book-template/index.d.ts +2 -0
  148. package/dist/types/components/template/mail-template/index.d.ts +2 -0
  149. package/dist/types/components/template/mail-template/mail-template.d.ts +11 -0
  150. package/dist/types/components/template/use-narrow.d.ts +3 -0
  151. package/dist/types/index.d.ts +149 -0
  152. package/dist/types/kit/check-rendering.d.ts +3 -0
  153. package/dist/types/kit/kit.d.ts +76 -0
  154. package/dist/types/lib/clipboard.d.ts +5 -0
  155. package/dist/types/lib/dates.d.ts +9 -0
  156. package/dist/types/lib/json.d.ts +26 -0
  157. package/dist/types/lib/keys.d.ts +15 -0
  158. package/dist/types/lib/utils.d.ts +2 -0
  159. package/dist/types/lib/view-scope.d.ts +22 -0
  160. package/dist/types/profile/profile.d.ts +34 -0
  161. package/dist/types/theme/appearance.d.ts +31 -0
  162. package/dist/types/theme/boot.d.ts +3 -0
  163. package/dist/types/theme/client-appearance-react.d.ts +3 -0
  164. package/dist/types/theme/client-appearance.d.ts +69 -0
  165. package/dist/types/theme/generate-tokens.d.ts +45 -0
  166. package/dist/types/theme/pack-themes-react.d.ts +24 -0
  167. package/dist/types/theme/palette.d.ts +111 -0
  168. package/dist/types/theme/semantic-mapping.d.ts +28 -0
  169. package/dist/types/theme/set-theme.d.ts +30 -0
  170. package/dist/types/theme/theme-colours.d.ts +14 -0
  171. package/dist/types/theme/theme-css.d.ts +3 -0
  172. package/dist/types/theme/themes.d.ts +63 -0
  173. package/dist/types/theme/wallpaper-sheet.d.ts +16 -0
  174. package/dist/types/theme/wallpaper-theme-react.d.ts +7 -0
  175. package/dist/types/theme/wallpaper-theme.d.ts +37 -0
  176. package/package.json +87 -3
  177. package/src/build/stylesheet.ts +128 -0
  178. package/src/components/composite/command/command.meta.yaml +74 -0
  179. package/src/components/composite/command/command.tsx +939 -0
  180. package/src/components/composite/command/index.ts +17 -0
  181. package/src/components/composite/draft-bar/draft-bar.meta.yaml +19 -0
  182. package/src/components/composite/draft-bar/draft-bar.tsx +57 -0
  183. package/src/components/composite/draft-bar/index.ts +2 -0
  184. package/src/components/composite/image-field/image-field.meta.yaml +69 -0
  185. package/src/components/composite/image-field/image-field.tsx +267 -0
  186. package/src/components/composite/image-field/index.ts +2 -0
  187. package/src/components/composite/list/index.ts +18 -0
  188. package/src/components/composite/list/list-swipe.tsx +163 -0
  189. package/src/components/composite/list/list.meta.yaml +238 -0
  190. package/src/components/composite/list/list.tsx +868 -0
  191. package/src/components/composite/picker/index.ts +2 -0
  192. package/src/components/composite/picker/picker.meta.yaml +103 -0
  193. package/src/components/composite/picker/picker.tsx +276 -0
  194. package/src/components/composite/prompt-field/index.ts +2 -0
  195. package/src/components/composite/prompt-field/prompt-field.meta.yaml +60 -0
  196. package/src/components/composite/prompt-field/prompt-field.tsx +81 -0
  197. package/src/components/composite/properties/index.ts +9 -0
  198. package/src/components/composite/properties/properties.meta.yaml +56 -0
  199. package/src/components/composite/properties/properties.tsx +132 -0
  200. package/src/components/composite/snooze-menu/index.ts +11 -0
  201. package/src/components/composite/snooze-menu/presets.ts +169 -0
  202. package/src/components/composite/snooze-menu/snooze-menu.meta.yaml +58 -0
  203. package/src/components/composite/snooze-menu/snooze-menu.tsx +146 -0
  204. package/src/components/composite/tag-input/index.ts +2 -0
  205. package/src/components/composite/tag-input/tag-input.meta.yaml +51 -0
  206. package/src/components/composite/tag-input/tag-input.tsx +404 -0
  207. package/src/components/composite/wizard/index.ts +2 -0
  208. package/src/components/composite/wizard/wizard.meta.yaml +73 -0
  209. package/src/components/composite/wizard/wizard.tsx +256 -0
  210. package/src/components/core/avatar/avatar.meta.yaml +71 -0
  211. package/src/components/core/avatar/avatar.tsx +92 -0
  212. package/src/components/core/avatar/index.ts +2 -0
  213. package/src/components/core/badge/badge.meta.yaml +34 -0
  214. package/src/components/core/badge/badge.tsx +23 -0
  215. package/src/components/core/badge/index.ts +2 -0
  216. package/src/components/core/breadcrumb/breadcrumb.meta.yaml +45 -0
  217. package/src/components/core/breadcrumb/breadcrumb.tsx +110 -0
  218. package/src/components/core/breadcrumb/index.ts +2 -0
  219. package/src/components/core/bullets/bullets.meta.yaml +37 -0
  220. package/src/components/core/bullets/bullets.tsx +60 -0
  221. package/src/components/core/bullets/index.ts +2 -0
  222. package/src/components/core/button/button.meta.yaml +91 -0
  223. package/src/components/core/button/button.tsx +93 -0
  224. package/src/components/core/button/index.ts +2 -0
  225. package/src/components/core/card/card.meta.yaml +94 -0
  226. package/src/components/core/card/card.tsx +54 -0
  227. package/src/components/core/card/index.ts +2 -0
  228. package/src/components/core/checkbox/checkbox.meta.yaml +59 -0
  229. package/src/components/core/checkbox/checkbox.tsx +106 -0
  230. package/src/components/core/checkbox/index.ts +2 -0
  231. package/src/components/core/cluster/cluster.meta.yaml +4 -0
  232. package/src/components/core/cluster/cluster.tsx +17 -0
  233. package/src/components/core/cluster/index.ts +1 -0
  234. package/src/components/core/code-block/code-block.meta.yaml +30 -0
  235. package/src/components/core/code-block/code-block.tsx +93 -0
  236. package/src/components/core/code-block/index.ts +2 -0
  237. package/src/components/core/collapsible/collapsible.meta.yaml +34 -0
  238. package/src/components/core/collapsible/collapsible.tsx +54 -0
  239. package/src/components/core/collapsible/index.ts +1 -0
  240. package/src/components/core/colour-picker/colour-picker.meta.yaml +52 -0
  241. package/src/components/core/colour-picker/colour-picker.tsx +314 -0
  242. package/src/components/core/colour-picker/index.ts +4 -0
  243. package/src/components/core/combobox/combobox.meta.yaml +75 -0
  244. package/src/components/core/combobox/combobox.tsx +288 -0
  245. package/src/components/core/combobox/index.ts +2 -0
  246. package/src/components/core/detail/detail.meta.yaml +13 -0
  247. package/src/components/core/detail/detail.tsx +73 -0
  248. package/src/components/core/detail/index.ts +1 -0
  249. package/src/components/core/dialog/dialog.meta.yaml +95 -0
  250. package/src/components/core/dialog/dialog.tsx +254 -0
  251. package/src/components/core/dialog/drag.ts +40 -0
  252. package/src/components/core/dialog/index.ts +25 -0
  253. package/src/components/core/drop-zone/drop-zone.meta.yaml +55 -0
  254. package/src/components/core/drop-zone/drop-zone.tsx +146 -0
  255. package/src/components/core/drop-zone/index.ts +2 -0
  256. package/src/components/core/dropdown-menu/dropdown-menu.meta.yaml +118 -0
  257. package/src/components/core/dropdown-menu/dropdown-menu.tsx +407 -0
  258. package/src/components/core/dropdown-menu/index.ts +32 -0
  259. package/src/components/core/editable-field/editable-field.meta.yaml +120 -0
  260. package/src/components/core/editable-field/editable-field.tsx +346 -0
  261. package/src/components/core/editable-field/index.ts +2 -0
  262. package/src/components/core/empty-state/empty-state.meta.yaml +21 -0
  263. package/src/components/core/empty-state/empty-state.tsx +42 -0
  264. package/src/components/core/empty-state/index.ts +2 -0
  265. package/src/components/core/field/field.meta.yaml +37 -0
  266. package/src/components/core/field/field.tsx +100 -0
  267. package/src/components/core/field/index.ts +9 -0
  268. package/src/components/core/icon/curated-names.json +107 -0
  269. package/src/components/core/icon/icon-sets.ts +109 -0
  270. package/src/components/core/icon/icon.meta.yaml +30 -0
  271. package/src/components/core/icon/icon.tsx +93 -0
  272. package/src/components/core/icon/index.ts +2 -0
  273. package/src/components/core/input/index.ts +4 -0
  274. package/src/components/core/input/input.meta.yaml +98 -0
  275. package/src/components/core/input/input.tsx +133 -0
  276. package/src/components/core/input/textarea.meta.yaml +79 -0
  277. package/src/components/core/input/textarea.tsx +63 -0
  278. package/src/components/core/kbd/index.ts +2 -0
  279. package/src/components/core/kbd/kbd.meta.yaml +12 -0
  280. package/src/components/core/kbd/kbd.tsx +29 -0
  281. package/src/components/core/label/index.ts +2 -0
  282. package/src/components/core/label/label.meta.yaml +55 -0
  283. package/src/components/core/label/label.tsx +72 -0
  284. package/src/components/core/main-content/index.ts +2 -0
  285. package/src/components/core/main-content/main-content.meta.yaml +23 -0
  286. package/src/components/core/main-content/main-content.tsx +49 -0
  287. package/src/components/core/pane/index.ts +1 -0
  288. package/src/components/core/pane/pane.meta.yaml +13 -0
  289. package/src/components/core/pane/pane.tsx +64 -0
  290. package/src/components/core/pick-menu/index.ts +4 -0
  291. package/src/components/core/pick-menu/pick-menu.meta.yaml +36 -0
  292. package/src/components/core/pick-menu/pick-menu.tsx +348 -0
  293. package/src/components/core/pick-menu/tag-menu.meta.yaml +7 -0
  294. package/src/components/core/pick-menu/tag-menu.tsx +79 -0
  295. package/src/components/core/popover/index.ts +2 -0
  296. package/src/components/core/popover/popover.meta.yaml +16 -0
  297. package/src/components/core/popover/popover.tsx +66 -0
  298. package/src/components/core/progress/index.ts +2 -0
  299. package/src/components/core/progress/progress.meta.yaml +47 -0
  300. package/src/components/core/progress/progress.tsx +56 -0
  301. package/src/components/core/resizable/index.ts +13 -0
  302. package/src/components/core/resizable/resizable.meta.yaml +110 -0
  303. package/src/components/core/resizable/resizable.tsx +125 -0
  304. package/src/components/core/resizable/use-remembered-layout.ts +261 -0
  305. package/src/components/core/screen-link/index.ts +2 -0
  306. package/src/components/core/screen-link/screen-link.meta.yaml +34 -0
  307. package/src/components/core/screen-link/screen-link.tsx +100 -0
  308. package/src/components/core/scroll-area/index.ts +2 -0
  309. package/src/components/core/scroll-area/scroll-area.meta.yaml +72 -0
  310. package/src/components/core/scroll-area/scroll-area.tsx +95 -0
  311. package/src/components/core/scroll-area/steps.tsx +72 -0
  312. package/src/components/core/section/index.ts +2 -0
  313. package/src/components/core/section/section.meta.yaml +72 -0
  314. package/src/components/core/section/section.tsx +93 -0
  315. package/src/components/core/segment-group/index.ts +2 -0
  316. package/src/components/core/segment-group/segment-group.meta.yaml +71 -0
  317. package/src/components/core/segment-group/segment-group.tsx +166 -0
  318. package/src/components/core/select/index.ts +20 -0
  319. package/src/components/core/select/select.meta.yaml +48 -0
  320. package/src/components/core/select/select.tsx +226 -0
  321. package/src/components/core/skeleton/index.ts +2 -0
  322. package/src/components/core/skeleton/skeleton.meta.yaml +50 -0
  323. package/src/components/core/skeleton/skeleton.tsx +71 -0
  324. package/src/components/core/slider/index.ts +2 -0
  325. package/src/components/core/slider/slider.meta.yaml +55 -0
  326. package/src/components/core/slider/slider.tsx +46 -0
  327. package/src/components/core/sortable/index.ts +16 -0
  328. package/src/components/core/sortable/sortable.meta.yaml +125 -0
  329. package/src/components/core/sortable/sortable.tsx +471 -0
  330. package/src/components/core/split-view/index.ts +2 -0
  331. package/src/components/core/split-view/split-view.meta.yaml +85 -0
  332. package/src/components/core/split-view/split-view.tsx +193 -0
  333. package/src/components/core/status-icon/index.ts +2 -0
  334. package/src/components/core/status-icon/status-icon.meta.yaml +64 -0
  335. package/src/components/core/status-icon/status-icon.tsx +94 -0
  336. package/src/components/core/table/collapsible-rows.tsx +30 -0
  337. package/src/components/core/table/expand-toggle.tsx +58 -0
  338. package/src/components/core/table/group-header.tsx +35 -0
  339. package/src/components/core/table/index.ts +26 -0
  340. package/src/components/core/table/table.meta.yaml +67 -0
  341. package/src/components/core/table/table.tsx +166 -0
  342. package/src/components/core/tabs/index.ts +2 -0
  343. package/src/components/core/tabs/tabs.meta.yaml +57 -0
  344. package/src/components/core/tabs/tabs.tsx +74 -0
  345. package/src/components/core/tag-pill/index.ts +2 -0
  346. package/src/components/core/tag-pill/tag-pill.meta.yaml +19 -0
  347. package/src/components/core/tag-pill/tag-pill.tsx +102 -0
  348. package/src/components/core/thumbnail/index.ts +2 -0
  349. package/src/components/core/thumbnail/thumbnail.meta.yaml +59 -0
  350. package/src/components/core/thumbnail/thumbnail.tsx +162 -0
  351. package/src/components/core/toast/index.ts +12 -0
  352. package/src/components/core/toast/toast.meta.yaml +93 -0
  353. package/src/components/core/toast/toast.tsx +763 -0
  354. package/src/components/core/toggle/index.ts +2 -0
  355. package/src/components/core/toggle/toggle.meta.yaml +53 -0
  356. package/src/components/core/toggle/toggle.tsx +44 -0
  357. package/src/components/core/toggle-group/index.ts +2 -0
  358. package/src/components/core/toggle-group/toggle-group.meta.yaml +59 -0
  359. package/src/components/core/toggle-group/toggle-group.tsx +68 -0
  360. package/src/components/core/tooltip/index.ts +7 -0
  361. package/src/components/core/tooltip/tooltip.meta.yaml +93 -0
  362. package/src/components/core/tooltip/tooltip.tsx +198 -0
  363. package/src/components/layout/multi-pane/index.ts +4 -0
  364. package/src/components/layout/multi-pane/list-detail.tsx +45 -0
  365. package/src/components/layout/multi-pane/multi-pane.meta.yaml +67 -0
  366. package/src/components/layout/multi-pane/multi-pane.tsx +158 -0
  367. package/src/components/layout/single-pane/index.ts +2 -0
  368. package/src/components/layout/single-pane/single-pane.meta.yaml +35 -0
  369. package/src/components/layout/single-pane/single-pane.tsx +48 -0
  370. package/src/components/shell/app-shell/app-shell.meta.yaml +65 -0
  371. package/src/components/shell/app-shell/app-shell.tsx +61 -0
  372. package/src/components/shell/app-shell/index.ts +2 -0
  373. package/src/components/shell/sidebar/index.ts +35 -0
  374. package/src/components/shell/sidebar/sidebar-group.tsx +254 -0
  375. package/src/components/shell/sidebar/sidebar-item.tsx +88 -0
  376. package/src/components/shell/sidebar/sidebar-resize-handle.tsx +101 -0
  377. package/src/components/shell/sidebar/sidebar-tree.tsx +325 -0
  378. package/src/components/shell/sidebar/sidebar.meta.yaml +126 -0
  379. package/src/components/shell/sidebar/sidebar.tsx +142 -0
  380. package/src/components/template/address-book-template/address-book-template.meta.yaml +22 -0
  381. package/src/components/template/address-book-template/address-book-template.tsx +201 -0
  382. package/src/components/template/address-book-template/index.ts +2 -0
  383. package/src/components/template/mail-template/index.ts +2 -0
  384. package/src/components/template/mail-template/mail-template.meta.yaml +22 -0
  385. package/src/components/template/mail-template/mail-template.tsx +731 -0
  386. package/src/components/template/use-narrow.ts +18 -0
  387. package/src/index.ts +505 -0
  388. package/src/kit/check-rendering.tsx +130 -0
  389. package/src/kit/kit.tsx +177 -0
  390. package/src/lib/clipboard.ts +27 -0
  391. package/src/lib/dates.ts +13 -0
  392. package/src/lib/json.ts +59 -0
  393. package/src/lib/keys.ts +54 -0
  394. package/src/lib/utils.ts +12 -0
  395. package/src/lib/view-scope.tsx +60 -0
  396. package/src/profile/profile.ts +238 -0
  397. package/src/theme/appearance.ts +198 -0
  398. package/src/theme/boot.ts +6 -0
  399. package/src/theme/client-appearance-react.ts +14 -0
  400. package/src/theme/client-appearance.ts +284 -0
  401. package/src/theme/generate-tokens.ts +658 -0
  402. package/src/theme/pack-themes-react.ts +107 -0
  403. package/src/theme/palette.ts +301 -0
  404. package/src/theme/semantic-mapping.ts +165 -0
  405. package/src/theme/set-theme.ts +162 -0
  406. package/src/theme/theme-colours.ts +60 -0
  407. package/src/theme/theme-css.ts +15 -0
  408. package/src/theme/themes.ts +133 -0
  409. package/src/theme/wallpaper-sheet.ts +58 -0
  410. package/src/theme/wallpaper-theme-react.ts +60 -0
  411. package/src/theme/wallpaper-theme.ts +231 -0
package/dist/themes.js ADDED
@@ -0,0 +1,69 @@
1
+ // src/theme/themes.ts
2
+ var THEMES = [
3
+ { id: "bridge-light", label: "Bridge Light", type: "light" },
4
+ { id: "bridge-dark", label: "Bridge Dark", type: "dark" },
5
+ { id: "wallpaper-light", label: "Wallpaper Light", type: "light", wallpaper: true },
6
+ { id: "wallpaper-dark", label: "Wallpaper Dark", type: "dark", wallpaper: true }
7
+ ];
8
+ var BRIDGE_THEMES = THEMES.filter((theme) => !theme.wallpaper);
9
+ var DEFAULT_THEME = { light: "bridge-light", dark: "bridge-dark" };
10
+ var RENAMED = { light: "linear-light", dark: "linear-dark" };
11
+ var THEME_STORAGE_KEY = "bridge.theme";
12
+ var packThemes = [];
13
+ var PACK_THEMES_EVENT = "bridge:pack-themes";
14
+ function setPackThemes(themes) {
15
+ const next = themes.filter(({ id }) => !THEMES.some((theme) => theme.id === id));
16
+ if (JSON.stringify(next) === JSON.stringify(packThemes)) return;
17
+ packThemes = next;
18
+ if (typeof window !== "undefined") window.dispatchEvent(new Event(PACK_THEMES_EVENT));
19
+ }
20
+ function packThemesOfAttribute(value) {
21
+ return (value ?? "").split(" ").map((each) => each.split(":")).filter(
22
+ (pair) => /^[a-z0-9-]+$/.test(pair[0] ?? "") && (pair[1] === "light" || pair[1] === "dark")
23
+ ).map(([id, type]) => ({ id, label: id, type }));
24
+ }
25
+ if (typeof document !== "undefined")
26
+ packThemes = packThemesOfAttribute(document.documentElement.dataset.packThemes);
27
+ var allThemes = () => [...THEMES, ...packThemes];
28
+ var knownThemeId = (id) => themeOf(id)?.id;
29
+ var themeOf = (id) => {
30
+ const current = (id && RENAMED[id]) ?? id;
31
+ return allThemes().find((theme) => theme.id === current);
32
+ };
33
+ function themeOfMode(id, mode) {
34
+ const theme = themeOf(id);
35
+ if (!theme) return void 0;
36
+ if (theme.type === mode) return theme.id;
37
+ const stemOf = (id2) => id2.replace(/(?:^|-)(?:light|dark)$/, "");
38
+ const stem = stemOf(theme.id);
39
+ return allThemes().find((each) => each.type === mode && stemOf(each.id) === stem)?.id;
40
+ }
41
+ function modeOf({ mode, own, bridge, systemDark }) {
42
+ if (mode === "light" || mode === "dark") return mode;
43
+ if (mode !== "system") {
44
+ const chosen = themeOf(own)?.type ?? (own === "system" ? void 0 : themeOf(bridge)?.type);
45
+ if (chosen) return chosen;
46
+ }
47
+ return systemDark ? "dark" : "light";
48
+ }
49
+ function resolveTheme(sources) {
50
+ const mode = modeOf(sources);
51
+ const id = themeOfMode(sources.own, mode) ?? themeOfMode(sources.proposal?.[mode], mode) ?? themeOfMode(sources.bridge, mode) ?? DEFAULT_THEME[mode];
52
+ return { id, mode };
53
+ }
54
+ var modeOfTheme = (id) => themeOf(id)?.type ?? "light";
55
+ export {
56
+ BRIDGE_THEMES,
57
+ DEFAULT_THEME,
58
+ PACK_THEMES_EVENT,
59
+ THEMES,
60
+ THEME_STORAGE_KEY,
61
+ allThemes,
62
+ knownThemeId,
63
+ modeOf,
64
+ modeOfTheme,
65
+ packThemesOfAttribute,
66
+ resolveTheme,
67
+ setPackThemes,
68
+ themeOfMode
69
+ };
@@ -0,0 +1,31 @@
1
+ /** Source files whose classes the stylesheet carries: absolute globs (`/a/b/**\/*.{ts,tsx}`), and those left out. */
2
+ export interface Sources {
3
+ include: string[];
4
+ exclude?: string[];
5
+ }
6
+ /** The kit's stylesheet: Tailwind's theme and utilities layers (no preflight: bare HTML elements stay the browser's, the
7
+ * kit resets only its own `[data-slot]` elements) for the classes the kit's sources (tests left out) and the host's
8
+ * `sources` use, and the theme tokens from the default themes' `palettes`. Not minified; with its classes, which a
9
+ * plugin's own utilities leave out (`compileUtilities`). */
10
+ export declare function compileStylesheet({ sources, palettes, }: {
11
+ sources: Sources;
12
+ palettes: string;
13
+ }): Promise<{
14
+ css: string;
15
+ classes: string[];
16
+ }>;
17
+ /** A plugin outside the host's own: the Tailwind utilities its bundled `js` uses, in the kit's layers, so its classes
18
+ * work as in the host's own plugins, against the theme of `palettes` (only the variables a utility needs come with
19
+ * it). Without the classes in `skip` (the kit's stylesheet's): loaded after it, in the same layer, a plugin's `.hidden`
20
+ * would win over the kit's `@2xl/pm:flex` on the host's own elements. Not minified; `undefined` when it uses none. */
21
+ export declare function compileUtilities({ js, skip, palettes, }: {
22
+ js: string;
23
+ skip: Set<string>;
24
+ palettes: string;
25
+ }): Promise<string | undefined>;
26
+ /** Tailwind's classes and the theme's token names as the kit's stylesheet has them, for checking a plugin's own
27
+ * stylesheet. */
28
+ export declare function stylesheetDesign(palettes: string): Promise<{
29
+ isUtility: (name: string) => boolean;
30
+ tokens: Set<string>;
31
+ }>;
@@ -0,0 +1,94 @@
1
+ import * as React from "react";
2
+ import { formatKeys } from "../../../lib/keys";
3
+ interface Command {
4
+ /** Unique among its siblings: a sequence and the menu find the live command again by its id path. */
5
+ id: string;
6
+ label: string;
7
+ keys?: string;
8
+ group?: string;
9
+ /** `where`: the ⌘K menu's ↵ with a modifier on a `placeable` command (research-034): ⌘↵ beside, ⌥↵ a new desk, ⇧↵
10
+ * floating, ⇧⌘↵ maximized; none: here. */
11
+ run: (where?: Placement) => void;
12
+ disabled?: boolean;
13
+ children?: Command[];
14
+ /** An icon name of the kit's set (`Icon`), drawn before the label in the ⌘K menu. */
15
+ icon?: string;
16
+ /** A second line under the label (a session's node and time, a window's desk). */
17
+ description?: string;
18
+ /** Going somewhere (a screen, a workspace, a window) rather than doing something: left out after `>`. */
19
+ navigation?: boolean;
20
+ /** A source's search answered it (its content matched, maybe not its label): listed whatever is typed. */
21
+ found?: boolean;
22
+ /** Opens something a window can show: ↵'s modifiers choose where (`run`'s `where`). */
23
+ placeable?: boolean;
24
+ }
25
+ /** Where ⌘K opens a placeable command (research-034). */
26
+ type Placement = "beside" | "desk" | "float" | "max";
27
+ interface CommandScopeProps {
28
+ /** The scope handles keys (and shows hints) only while its window/screen is focused. */
29
+ active: boolean;
30
+ /** "hold" (default): hints show while ⌘ is held; "always": whenever active (a user setting). */
31
+ hints?: "hold" | "always";
32
+ /** What the commands act on now (the open record's name, "2 selected"), a chip above the ⌘K search. */
33
+ subject?: string;
34
+ children?: React.ReactNode;
35
+ }
36
+ type CommandGetter = () => Command[];
37
+ interface CommandRegistry {
38
+ register: (getter: CommandGetter) => () => void;
39
+ /** Tells subscribers the registered commands changed (a screen re-rendered them, a subject changed). */
40
+ changed: () => void;
41
+ all: () => Command[];
42
+ subscribe: (listener: () => void) => () => void;
43
+ getVersion: () => number;
44
+ }
45
+ /** What a focused screen's commands are, for a palette drawn above every screen (research-034: Bridge's `commands`
46
+ * plugin): its commands as they are now, what they act on, and a change. */
47
+ interface CommandSource {
48
+ /** How many scopes it sits in (0: none): the innermost speaks for the focused screen. */
49
+ depth: number;
50
+ /** Not a screen's: a workspace plugin's commands for anywhere in its workspace ("New contact"), or Bridge's own (the
51
+ * shell's, the rail's); listed after the focused screen's, the workspace's first. None: the focused screen's. */
52
+ level?: "workspace" | "bridge";
53
+ /** The plugin it comes from (its key): a workspace's plugins are listed in the workspace's own order. */
54
+ owner?: string;
55
+ /** Its content searched (research-034's universal search): the records answering `query` as commands (a contact
56
+ * to open), asked while the user types; `signal` aborts a search a newer one replaced. */
57
+ search?: (query: string, signal: AbortSignal) => Promise<Command[]>;
58
+ commands: () => Command[];
59
+ subject: () => string | undefined;
60
+ subscribe: (listener: () => void) => () => void;
61
+ }
62
+ /** Where an active CommandScope hands its commands instead of opening its own ⌘K menu (the page's shell provides it
63
+ * from Bridge's `commands` plugin); none: each scope opens its own. */
64
+ interface CommandHost {
65
+ register: (source: CommandSource) => () => void;
66
+ }
67
+ /** Provides a CommandHost to every CommandScope below. */
68
+ declare const CommandHostProvider: React.Provider<CommandHost | null>;
69
+ /** Register the calling component's commands while it is mounted. The latest
70
+ * array wins; they are removed when it unmounts. */
71
+ declare function useCommands(commands: Command[]): void;
72
+ /** The commands registered in the nearest CommandScope (its screen's and its extensions'), as they are now: for a menu
73
+ * listing what acts on a target (a row's right-click shows the selection's commands, extensions' included). */
74
+ declare function useScopeCommands(): Command[];
75
+ declare function CommandScope({ active, hints, subject, children }: CommandScopeProps): React.JSX.Element;
76
+ interface KeyHintProps {
77
+ keys: string;
78
+ children: React.ReactNode;
79
+ }
80
+ declare function KeyHint({ keys, children }: KeyHintProps): React.JSX.Element;
81
+ interface CommandMenuProps {
82
+ registry: CommandRegistry;
83
+ subject?: string | undefined;
84
+ onClose: () => void;
85
+ /** `false`: closing gives the focus back to nothing (the desktop app gives it to the page the palette was over). */
86
+ finalFocus?: boolean | undefined;
87
+ /** The search typed, as it changes (a host searches its sources' content with it). */
88
+ onSearch?: ((search: string) => void) | undefined;
89
+ /** A window manager is there: the footer says ↵'s modifiers on a placeable command. */
90
+ placements?: boolean | undefined;
91
+ }
92
+ declare function CommandMenu({ registry, subject, onClose, finalFocus, onSearch, placements, }: CommandMenuProps): React.JSX.Element;
93
+ export { CommandScope, useCommands, useScopeCommands, KeyHint, CommandMenu, CommandHostProvider, formatKeys, };
94
+ export type { Command, CommandScopeProps, CommandHost, CommandSource, CommandRegistry, Placement };
@@ -0,0 +1,2 @@
1
+ export { CommandScope, useCommands, useScopeCommands, KeyHint, CommandMenu, CommandHostProvider, formatKeys, } from "./command";
2
+ export type { Command, CommandScopeProps, CommandHost, CommandSource, CommandRegistry, Placement, } from "./command";
@@ -0,0 +1,12 @@
1
+ import * as React from "react";
2
+ interface DraftBarProps extends Omit<React.ComponentProps<"div">, "children"> {
3
+ /** Where the draft is kept ("Not created yet · kept on this device"). */
4
+ message: React.ReactNode;
5
+ /** What stops Create ("A first or last name is needed."): shown instead of the message, as an alert. */
6
+ error?: React.ReactNode;
7
+ onCancel: () => void;
8
+ onCreate: () => void;
9
+ }
10
+ declare function DraftBar({ message, error, onCancel, onCreate, className, ...props }: DraftBarProps): React.JSX.Element;
11
+ export { DraftBar };
12
+ export type { DraftBarProps };
@@ -0,0 +1,2 @@
1
+ export { DraftBar } from "./draft-bar";
2
+ export type { DraftBarProps } from "./draft-bar";
@@ -0,0 +1,33 @@
1
+ import * as React from "react";
2
+ /** What an `ImageField` reads of its value: the file's name and size, shown under the image. */
3
+ interface ImageFieldValue {
4
+ name?: string;
5
+ size?: number;
6
+ }
7
+ interface ImageFieldProps<V extends ImageFieldValue> extends Omit<React.ComponentProps<"div">, "onChange" | "defaultValue"> {
8
+ /** What the image is ("Illustration"): the group's accessible name, and the image's alt without a file name. */
9
+ label: string;
10
+ /** The image held; `null` or absent: none. */
11
+ value: V | null | undefined;
12
+ /** Sends `file` and answers the value to hold (`progress`: 0 to 1, `undefined` while unknown). A rejection is shown
13
+ * in place: its message, and its `hint` when it has one. */
14
+ upload: (file: File, progress: (fraction: number | undefined) => void) => Promise<V>;
15
+ /** The URL the image is shown from. */
16
+ viewUrl: (value: V) => Promise<string>;
17
+ /** A new value once uploaded, or `null` (Remove). */
18
+ onChange: (value: V | null) => void;
19
+ /** What it takes, as `<input accept>` (default `image/*`). */
20
+ accept?: string;
21
+ /** The frame's width over its height (default 16 / 9); the image is contained in it, never cropped. */
22
+ ratio?: number;
23
+ /** Shows the image only: no Upload, Replace, Remove, no drop. */
24
+ disabled?: boolean;
25
+ /** A problem from outside (the record's save of the value failed), shown in place. */
26
+ error?: string;
27
+ }
28
+ /** An image held by a form or a record: its thumbnail in a fixed frame (contained), its name and size, Upload (a file
29
+ * picker or a drop), Replace and Remove, the progress while it uploads, and a refusal in place. It sends nothing
30
+ * itself: `upload` and `viewUrl` do. */
31
+ declare function ImageField<V extends ImageFieldValue>({ label, value, upload, viewUrl, onChange, accept, ratio, disabled, error, className, ...props }: ImageFieldProps<V>): React.JSX.Element;
32
+ export { ImageField };
33
+ export type { ImageFieldProps, ImageFieldValue };
@@ -0,0 +1,2 @@
1
+ export { ImageField } from "./image-field";
2
+ export type { ImageFieldProps, ImageFieldValue } from "./image-field";
@@ -0,0 +1,3 @@
1
+ export { List, listVariants, ListItem, listItemVariants, ListGroup, BulkBar, BulkAction, BulkSeparator, } from "./list";
2
+ export type { ListProps, ListItemProps, ListGroupProps, BulkBarProps, BulkActionProps, } from "./list";
3
+ export type { SwipeAction } from "./list-swipe";
@@ -0,0 +1,28 @@
1
+ import * as React from "react";
2
+ interface SwipeAction {
3
+ /** Its name, under its icon. */
4
+ label: string;
5
+ /** A lucide icon by its kebab-case name (the kit's Icon). */
6
+ icon: string;
7
+ /** Its colour: accent (default), destructive, warning or neutral. */
8
+ tone?: "accent" | "destructive" | "warning" | "neutral";
9
+ onAction: () => void;
10
+ }
11
+ /** The swipe of one row: its offset, the handlers for the row, and the actions to draw behind it. */
12
+ declare function useSwipe(start: SwipeAction[] | undefined, end: SwipeAction[] | undefined): {
13
+ enabled: boolean;
14
+ offset: number;
15
+ dragging: boolean;
16
+ handlers: {
17
+ onPointerDown(event: React.PointerEvent<HTMLElement>): void;
18
+ onPointerMove(event: React.PointerEvent<HTMLElement>): void;
19
+ onPointerUp(event: React.PointerEvent<HTMLElement>): void;
20
+ onPointerCancel(): void;
21
+ };
22
+ swallowClick: () => boolean;
23
+ /** Close it (a click on the row while open closes, rather than opens). */
24
+ close: () => void;
25
+ actions: (side: "start" | "end") => React.JSX.Element | null;
26
+ };
27
+ export { useSwipe };
28
+ export type { SwipeAction };
@@ -0,0 +1,95 @@
1
+ import * as React from "react";
2
+ import { type VariantProps } from "class-variance-authority";
3
+ import { type SwipeAction } from "./list-swipe";
4
+ type ListVariant = "default" | "records";
5
+ declare const listVariants: (props?: import("class-variance-authority/types").ClassProp | undefined) => string;
6
+ interface ListProps extends Omit<React.ComponentProps<"div">, "onSelect">, VariantProps<typeof listVariants> {
7
+ /** Selection behavior: "none" (default), "single", or "multiple" */
8
+ selectionMode?: "single" | "multiple" | "none";
9
+ /** Currently selected key (single selection mode) */
10
+ selectedKey?: string | undefined;
11
+ /** Currently selected keys (multiple selection mode) */
12
+ selectedKeys?: string[];
13
+ /** Called when selection changes */
14
+ onSelectionChange?: (keys: string[]) => void;
15
+ /** Single selection: moving with the arrow keys, Home, or End also selects (a master/detail list). */
16
+ selectionFollowsFocus?: boolean;
17
+ /** "records" is Linear's list: a cursor (focus), an open row, and a multiple selection kept apart. */
18
+ variant?: ListVariant;
19
+ /** Records: the key of the open row (marked with data-open). */
20
+ openKey?: string;
21
+ /** Records: called when a row is opened (a plain click or Enter on the cursor). */
22
+ onOpen?: (key: string) => void;
23
+ /** Records: moving the cursor (J/K, arrows) opens the row too, for a list with its card beside it. */
24
+ openFollowsCursor?: boolean;
25
+ }
26
+ declare function List({ className, selectionMode, selectedKey, selectedKeys: selectedKeysProp, onSelectionChange, selectionFollowsFocus, variant, openKey, onOpen, openFollowsCursor, children, onKeyDown, ...props }: ListProps): React.JSX.Element;
27
+ declare const listItemVariants: (props?: ({
28
+ size?: "auto" | "default" | "lg" | "sm" | null | undefined;
29
+ } & import("class-variance-authority/types").ClassProp) | undefined) => string;
30
+ interface ListItemProps extends React.ComponentProps<"div">, VariantProps<typeof listItemVariants> {
31
+ /** Accessible text description of this item */
32
+ textValue?: string;
33
+ /** Unique key for selection tracking */
34
+ value?: string | undefined;
35
+ /** Whether this item is disabled */
36
+ disabled?: boolean;
37
+ /** Before the text (an Avatar, an Icon) */
38
+ leading?: React.ReactNode;
39
+ /** A second, muted line under the children; the row defaults to size "lg" */
40
+ description?: React.ReactNode;
41
+ /** At the end of the row, muted (a date, a count) */
42
+ trailing?: React.ReactNode;
43
+ /** Records: the row's properties as a table's columns (tags, an organization), from 560px of list only. */
44
+ properties?: React.ReactNode;
45
+ /** Records: not yet saved (research-033's mockup): all grey, its name in italics, a grey avatar (no Draft pill:
46
+ * owner); only the background follows the state. Marked with data-draft. */
47
+ draft?: boolean;
48
+ /** Records, a draft: its ✕ at the row's end ("Cancel draft"). */
49
+ onCancelDraft?: () => void;
50
+ /** Records: a mark in the row checkbox's place (a mail's unread dot), shown while the checkbox is hidden; the
51
+ * checkbox takes its place on hover and while rows are selected. Decorative: say what it means in textValue. */
52
+ marker?: React.ReactNode;
53
+ /** On touch, the actions a swipe to the right uncovers (at the row's start); a full swipe runs the first. */
54
+ swipeStart?: SwipeAction[];
55
+ /** On touch, the actions a swipe to the left uncovers (at the row's end); a full swipe runs the first. */
56
+ swipeEnd?: SwipeAction[];
57
+ }
58
+ declare function ListItem({ className, size, textValue, value, disabled, leading, description, trailing, properties, draft, onCancelDraft, marker, swipeStart, swipeEnd, children, onClick, onPointerDown, onPointerMove, onPointerUp, onPointerCancel, style, onAuxClick, onContextMenu, ...props }: ListItemProps): React.JSX.Element;
59
+ declare const listGroupHeaderVariants: (props?: ({
60
+ variant?: "index" | "property" | "records" | "section" | null | undefined;
61
+ } & import("class-variance-authority/types").ClassProp) | undefined) => string;
62
+ interface ListGroupProps extends React.ComponentProps<"div">, VariantProps<typeof listGroupHeaderVariants> {
63
+ /** The group's heading ("A", "Favorites"), shown above its items and sticky while they scroll */
64
+ label: string;
65
+ /** Records: a caret header that toggles its rows. */
66
+ collapsible?: boolean;
67
+ /** Records: a muted count shown after the label. */
68
+ count?: number;
69
+ /** Records: called by the header's + button. */
70
+ onAdd?: () => void;
71
+ /** Records: the + button's accessible name (default "Add"). */
72
+ addLabel?: string;
73
+ /** Records: start collapsed. */
74
+ defaultCollapsed?: boolean;
75
+ }
76
+ declare function ListGroup({ className, label, variant, collapsible, count, onAdd, addLabel, defaultCollapsed, children, ...props }: ListGroupProps): React.JSX.Element;
77
+ interface BulkBarProps extends React.ComponentProps<"div"> {
78
+ /** How many rows are selected; the bar draws nothing at 0. */
79
+ count: number;
80
+ /** Clear the selection (the X button). */
81
+ onClear?: () => void;
82
+ /** Floats over its pane, at the bottom centre (the pane positioned): the mockup's selection bar. */
83
+ floating?: boolean;
84
+ }
85
+ declare function BulkBar({ count, onClear, floating, children, className, ...props }: BulkBarProps): React.JSX.Element | null;
86
+ interface BulkActionProps extends React.ComponentProps<"button"> {
87
+ /** Its keys, as the kit writes them ("L", "Meta+Backspace"), drawn as keycaps after the label. */
88
+ keys?: string;
89
+ }
90
+ /** One of BulkBar's actions: a quiet button, its label and its keys. */
91
+ declare function BulkAction({ keys, className, children, ...props }: BulkActionProps): React.JSX.Element;
92
+ /** A thin rule between BulkBar's actions (before "More"). */
93
+ declare function BulkSeparator(): React.JSX.Element;
94
+ export { List, listVariants, ListItem, listItemVariants, ListGroup, BulkBar, BulkAction, BulkSeparator, };
95
+ export type { ListProps, ListItemProps, ListGroupProps, BulkBarProps, BulkActionProps };
@@ -0,0 +1,2 @@
1
+ export { Picker } from "./picker";
2
+ export type { PickerProps } from "./picker";
@@ -0,0 +1,44 @@
1
+ import * as React from "react";
2
+ interface PickerProps<Item> {
3
+ /** The selected item, or `null` (the trigger shows `placeholder`). */
4
+ value: Item | null;
5
+ /** Called with the picked item. The picked label shows until `value` changes or the returned promise settles (a
6
+ * failed save: back to `value`). */
7
+ onValueChange: (item: Item) => void | Promise<unknown>;
8
+ /** What the popup offers now. */
9
+ items: readonly Item[];
10
+ /** The item's label, shown on the trigger and matched by the default filter. */
11
+ itemToString: (item: Item) => string;
12
+ /** The item's identity, for the selected check and React keys. */
13
+ itemToKey: (item: Item) => string;
14
+ /** An option's row content; defaults to its label. */
15
+ renderItem?: (item: Item) => React.ReactNode;
16
+ /** The leading icon, on the trigger and on each option. */
17
+ itemIcon?: (item: Item) => React.ReactNode;
18
+ /** Called with the text the user types in the search, and with "" once the popup has closed. */
19
+ onInputChange?: (text: string) => void;
20
+ /** Called when the popup opens or closes (e.g. to retry a failed load on open). */
21
+ onOpenChange?: (open: boolean) => void;
22
+ /** `null` shows `items` as they are (the caller filters, e.g. on the server); by default `contains`, any case and accent. */
23
+ filter?: null;
24
+ /** While nothing is shown, "Loading…" instead of `emptyText`. */
25
+ loading?: boolean;
26
+ /** Shown when no item matches. Defaults to "No results". */
27
+ emptyText?: React.ReactNode;
28
+ /** The search input's placeholder, e.g. "Change status…". Defaults to "Search…". */
29
+ searchPlaceholder?: string;
30
+ /** Shown (muted) on the trigger while `value` is `null`. Defaults to "None". */
31
+ placeholder?: string;
32
+ disabled?: boolean;
33
+ readOnly?: boolean;
34
+ /** The `property` button heights. Defaults to `default`. */
35
+ size?: "sm" | "default";
36
+ /** The trigger's corner: the kit's `rounded-default` pill, or a `round` (rounded-full) one. */
37
+ shape?: "default" | "round";
38
+ "aria-label"?: string;
39
+ /** On the trigger. */
40
+ className?: string;
41
+ }
42
+ declare function Picker<Item>({ value, onValueChange, items, itemToString, itemToKey, renderItem, itemIcon, onInputChange, onOpenChange, filter, loading, emptyText, searchPlaceholder, placeholder, disabled, readOnly, size, shape, "aria-label": ariaLabel, className, }: PickerProps<Item>): React.JSX.Element;
43
+ export { Picker };
44
+ export type { PickerProps };
@@ -0,0 +1,2 @@
1
+ export { PromptField } from "./prompt-field";
2
+ export type { PromptFieldProps } from "./prompt-field";
@@ -0,0 +1,18 @@
1
+ import * as React from "react";
2
+ interface PromptFieldProps {
3
+ value: string;
4
+ /** The text changed (typing, a recall). */
5
+ onValueChange: (value: string) => void;
6
+ /** Enter, or Send: the value to send. */
7
+ onSubmit: () => void;
8
+ disabled?: boolean;
9
+ placeholder?: string;
10
+ "aria-label"?: string;
11
+ className?: string;
12
+ textareaRef?: React.Ref<HTMLTextAreaElement>;
13
+ }
14
+ /** A message field and its Send: Enter submits (Shift+Enter a newline, Enter while composing is the input
15
+ * method's), Send is off while disabled or the value is blank. */
16
+ declare function PromptField({ value, onValueChange, onSubmit, disabled, placeholder, "aria-label": label, className, textareaRef, }: PromptFieldProps): React.JSX.Element;
17
+ export { PromptField };
18
+ export type { PromptFieldProps };
@@ -0,0 +1,2 @@
1
+ export { Properties, propertiesVariants, PropertyRow, propertyRowVariants, PropertyPlaceholder, PropertyGrid, } from "./properties";
2
+ export type { PropertiesProps, PropertyRowProps } from "./properties";
@@ -0,0 +1,24 @@
1
+ import * as React from "react";
2
+ import { type VariantProps } from "class-variance-authority";
3
+ declare const propertiesVariants: (props?: import("class-variance-authority/types").ClassProp | undefined) => string;
4
+ interface PropertiesProps extends React.ComponentProps<"div">, VariantProps<typeof propertiesVariants> {
5
+ }
6
+ declare function Properties({ className, children, ...props }: PropertiesProps): React.JSX.Element;
7
+ declare const propertyRowVariants: (props?: import("class-variance-authority/types").ClassProp | undefined) => string;
8
+ interface PropertyRowProps extends React.ComponentProps<"div">, VariantProps<typeof propertyRowVariants> {
9
+ /** Label text (e.g., "Status", "Priority") */
10
+ label: string;
11
+ /** A value with its own height (notes, an address, tags): padded, not set on the label's line. */
12
+ tall?: boolean;
13
+ /** A ✕ at the row's end, shown on hover or focus: removes the field. */
14
+ onRemove?: () => void;
15
+ /** The ✕'s name and tooltip ("Remove tags"). */
16
+ removeLabel?: string;
17
+ }
18
+ declare function PropertyRow({ className, label, tall, onRemove, removeLabel, children, ...props }: PropertyRowProps): React.JSX.Element;
19
+ /** An always-shown field with no value yet ("Add email"): its placeholder text, a click adds one. */
20
+ declare function PropertyPlaceholder({ className, type, ...props }: React.ComponentProps<"button">): React.JSX.Element;
21
+ /** A value in parts (an address): a grid of fields, the first across, then a narrow and a wide one per line. */
22
+ declare function PropertyGrid({ className, ...props }: React.ComponentProps<"div">): React.JSX.Element;
23
+ export { Properties, propertiesVariants, PropertyRow, propertyRowVariants, PropertyPlaceholder, PropertyGrid, };
24
+ export type { PropertiesProps, PropertyRowProps };
@@ -0,0 +1,4 @@
1
+ export { SnoozeMenu, SnoozeDialog } from "./snooze-menu";
2
+ export type { SnoozeMenuProps, SnoozeDialogProps } from "./snooze-menu";
3
+ export { snoozePresets, snoozeChoicesOf, snoozeWakeLabel, customSnooze, DEFAULT_SNOOZE_CHOICES, MAX_SNOOZE_MINUTES, } from "./presets";
4
+ export type { SnoozePreset, SnoozeChoice, SnoozeDay } from "./presets";
@@ -0,0 +1,36 @@
1
+ declare const WEEKDAYS: readonly ["sunday", "monday", "tuesday", "wednesday", "thursday", "friday", "saturday"];
2
+ export type SnoozeDay = "today" | "tomorrow" | (typeof WEEKDAYS)[number];
3
+ /** A snooze choice as a setting keeps it: a delay from the snooze (`after`, in minutes), or a time (HH:mm, local) on a
4
+ * day: today, tomorrow, or a weekday's next occurrence after today. */
5
+ export type SnoozeChoice = {
6
+ when: "after";
7
+ minutes: number;
8
+ } | {
9
+ when: SnoozeDay;
10
+ time: string;
11
+ };
12
+ export declare const DEFAULT_SNOOZE_CHOICES: readonly SnoozeChoice[];
13
+ /** The longest delay a choice may have, in minutes (30 days). */
14
+ export declare const MAX_SNOOZE_MINUTES: number;
15
+ /** The choices in a setting's value (read from outside the kit, so unchecked): its well-formed entries, the others left
16
+ * out, a field left unset its default (after a delay of 60 minutes, at 09:00); `undefined` when it is no list (the
17
+ * default choices apply then). */
18
+ export declare function snoozeChoicesOf(value: unknown): SnoozeChoice[] | undefined;
19
+ export interface SnoozePreset {
20
+ /** The choice it comes from: `after:60`, `tomorrow:09:00`. */
21
+ id: string;
22
+ label: string;
23
+ /** The time column: "6:00 PM", or "Mon 9:00 AM" for a day the label does not name. */
24
+ when: string;
25
+ /** The wake time, ISO. */
26
+ until: string;
27
+ }
28
+ /** The presets offered at `now` from `choices` (default: Bridge's), soonest first, one per wake minute. */
29
+ export declare function snoozePresets(now?: Date, choices?: readonly SnoozeChoice[]): SnoozePreset[];
30
+ /** How long until `until`, compact: "45m", "2h", "3d"; minutes round up so a snoozed row never reads "0m"; "now" once
31
+ * past. */
32
+ export declare function snoozeWakeLabel(until: string, now?: Date): string;
33
+ /** The wake time of a local `date` (YYYY-MM-DD) and `time` (HH:mm), ISO; `null` when it is not after `now`, malformed,
34
+ * or does not exist (a day that rolls over, a time skipped by a DST change). */
35
+ export declare function customSnooze(date: string, time: string, now?: Date): string | null;
36
+ export {};
@@ -0,0 +1,27 @@
1
+ import * as React from "react";
2
+ import { type SnoozeChoice } from "./presets";
3
+ interface SnoozeMenuProps {
4
+ /** A preset was chosen: its wake time, ISO. */
5
+ onSnooze: (until: string) => void;
6
+ /** "Custom…" was chosen: open a SnoozeDialog. */
7
+ onCustom: () => void;
8
+ /** The choices offered, usually the plugin's setting (`snoozeChoicesOf`); default: Bridge's. */
9
+ choices?: readonly SnoozeChoice[] | undefined;
10
+ /** The time the presets are computed from (default: now). */
11
+ now?: Date;
12
+ disabled?: boolean | undefined;
13
+ }
14
+ declare function SnoozeMenu({ onSnooze, onCustom, choices, now, disabled }: SnoozeMenuProps): React.JSX.Element;
15
+ interface SnoozeDialogProps {
16
+ open: boolean;
17
+ onOpenChange: (open: boolean) => void;
18
+ /** The chosen wake time, ISO; the dialog closes. */
19
+ onSnooze: (until: string) => void;
20
+ /** What is snoozed, for the title ("Snooze Fix the build"). */
21
+ subject?: string | undefined;
22
+ /** The time "now" is (default: the real one): the default date is the next day, and past times are refused. */
23
+ now?: Date;
24
+ }
25
+ declare function SnoozeDialog({ open, onOpenChange, onSnooze, subject, now }: SnoozeDialogProps): React.JSX.Element;
26
+ export { SnoozeMenu, SnoozeDialog };
27
+ export type { SnoozeMenuProps, SnoozeDialogProps };
@@ -0,0 +1,2 @@
1
+ export { TagInput } from "./tag-input";
2
+ export type { TagInputProps } from "./tag-input";
@@ -0,0 +1,22 @@
1
+ import * as React from "react";
2
+ interface TagOption {
3
+ value: string;
4
+ label?: string;
5
+ }
6
+ interface TagInputProps extends Omit<React.ComponentProps<"input">, "value" | "defaultValue" | "onChange" | "size"> {
7
+ /** The tags, in order. */
8
+ value: string[];
9
+ /** Called with the next tags when one is added or removed. */
10
+ onChange: (value: string[]) => void;
11
+ /** The values the input may suggest, each with the text shown for it. */
12
+ options?: TagOption[] | undefined;
13
+ /** With `options`: only an option's value may be added; other text is refused. */
14
+ strict?: boolean | undefined;
15
+ /** Lets the chips be reordered with Alt+arrows or by dragging. */
16
+ sortable?: boolean | undefined;
17
+ /** The frame's height on one line, as Input's (h-sm, h-md, h-lg). Defaults to `default` (h-md). */
18
+ size?: "sm" | "default" | "lg" | undefined;
19
+ }
20
+ declare function TagInput({ value, onChange, options, strict, sortable, size, className, disabled: disabledProp, name, onFocus, onKeyDown, onBlur, ...props }: TagInputProps): React.JSX.Element;
21
+ export { TagInput };
22
+ export type { TagInputProps, TagOption };
@@ -0,0 +1,2 @@
1
+ export { Wizard, WizardStep, useWizard } from "./wizard";
2
+ export type { WizardProps, WizardStepProps } from "./wizard";