@revolist/ui 4.0.1-rc → 4.0.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 (427) hide show
  1. package/LICENSE +21 -0
  2. package/MIGRATION.md +36 -0
  3. package/OWNERSHIP.md +32 -32
  4. package/README.md +405 -264
  5. package/_button.scss +6 -2
  6. package/_chunks/arrow-up-Cw8hW9vp.js +4 -0
  7. package/_chunks/calculator-CDWOuAcp.js +4 -0
  8. package/_chunks/calendar-DJqiFwFT.js +258 -0
  9. package/_chunks/chart-frame-hcOlnQ1K.js +145 -0
  10. package/_chunks/{chevron-right-sxHQMSkq.js → check-BwI7iCAm.js} +2 -2
  11. package/_chunks/{chevron-left-D0nc4Z5S.js → chevron-right-CM3ljziP.js} +2 -2
  12. package/_chunks/choice-chips-yr6Uzmof.js +126 -0
  13. package/_chunks/clock-BOhPNlW3.js +4 -0
  14. package/_chunks/color-palette-DMJUChWC.js +92 -0
  15. package/_chunks/{color-picker-BRv-__AM.js → color-picker-CMWxQlWt.js} +61 -56
  16. package/_chunks/component-DyWiItBR.js +878 -0
  17. package/_chunks/{component-metadata-BENbgTjU.js → component-metadata-BKd7U8OW.js} +0 -12
  18. package/_chunks/configurator-actions-DCodxcUw.js +155 -0
  19. package/_chunks/configurator-field-icon-CmcM_sPs.js +53 -0
  20. package/_chunks/control-CbOYUakE.js +118 -0
  21. package/_chunks/{controller-CmLo-Ajc.js → controller-hRBm_Lfz.js} +15 -15
  22. package/_chunks/controls-DD1qvPfE.js +650 -0
  23. package/_chunks/{date-control-CYCkb1aQ.js → date-control-XI2cpKI_.js} +21 -21
  24. package/_chunks/date-time-CGJdC1Qa.js +807 -0
  25. package/_chunks/{delete-button-DnpmDNEJ.js → delete-button-CW9vjLnk.js} +7 -7
  26. package/_chunks/dialog.parts-CJ3FVxC9.js +131 -0
  27. package/_chunks/duration-CBJWK82T.js +272 -0
  28. package/_chunks/editor-commit-Bq3wSgvr.js +12 -0
  29. package/_chunks/editor-popup-ByU7qiub.js +82 -0
  30. package/_chunks/field-configurator-B-qtIwx1.js +288 -0
  31. package/_chunks/field-context-D57PnBbH.js +5 -0
  32. package/_chunks/framework-mount-Bk4O_T7T.js +54 -0
  33. package/_chunks/hooks.module-CG3gN83z.js +157 -0
  34. package/_chunks/icon-toolbar-DSjOdwM7.js +134 -0
  35. package/_chunks/jsxRuntime.module-F6UFnpT-.js +30 -0
  36. package/_chunks/magnifying-glass-CvrTDSkB.js +4 -0
  37. package/_chunks/minus-BOAR3A1C.js +4 -0
  38. package/_chunks/mount-C7i5gsKI.js +267 -0
  39. package/_chunks/native-Blr3byjO.js +32 -0
  40. package/_chunks/native-control-B9MNibfa.js +649 -0
  41. package/_chunks/{number-input-NnH57J4j.js → number-input-CgbZes5B.js} +89 -89
  42. package/_chunks/picker-DqpjDC90.js +122 -0
  43. package/_chunks/plus-CbGRkIGl.js +4 -0
  44. package/_chunks/popover-controller-D-AvKQ7B.js +102 -0
  45. package/_chunks/popup-C35Isk7p.js +378 -0
  46. package/_chunks/preact.module-BBM36DnO.js +290 -0
  47. package/_chunks/{rating-choice-CWAsNQNS.js → rating-choice-WDrfiluf.js} +10 -10
  48. package/_chunks/render-m5eMMwFR.js +83 -0
  49. package/_chunks/reorder-list-C4HSda4n.js +59 -0
  50. package/_chunks/request-trail-SHynDFdM.js +762 -0
  51. package/_chunks/rich-text-CtjqRvv8.js +842 -0
  52. package/_chunks/rotate-left-BF6G883o.js +4 -0
  53. package/_chunks/rotate-right-Iha5ScJ1.js +4 -0
  54. package/_chunks/selection-list-tooltips-BtWjpP6M.js +41 -0
  55. package/_chunks/title-tooltip-Cw6LOZhb.js +11 -0
  56. package/_chunks/tooltip-D4xkio5G.js +54 -0
  57. package/_chunks/tooltip-owner-DjdvqKzz.js +19 -0
  58. package/_chunks/tooltip-session-B6X6x8G_.js +110 -0
  59. package/_chunks/tooltip-text-BXsUEmBH.js +12 -0
  60. package/_chunks/top-layer-popup-CNSDdfJV.js +59 -0
  61. package/_dialog.scss +55 -21
  62. package/_form.scss +71 -21
  63. package/_legend.scss +25 -7
  64. package/_shared/data-query/index.d.ts +2 -2
  65. package/_shared/data-query/load-options.d.ts +2 -2
  66. package/_variables.scss +34 -32
  67. package/_vendor/preact/LICENSE +21 -0
  68. package/_vendor/preact/compat/src/index.d.ts +353 -0
  69. package/_vendor/preact/compat/src/suspense-list.d.ts +16 -0
  70. package/_vendor/preact/compat/src/suspense.d.ts +19 -0
  71. package/_vendor/preact/hooks/src/index.d.ts +145 -0
  72. package/_vendor/preact/src/dom.d.ts +2548 -0
  73. package/_vendor/preact/src/index.d.ts +373 -0
  74. package/_vendor/preact/src/jsx.d.ts +2958 -0
  75. package/_view-switcher.scss +6 -0
  76. package/activity-message.d.ts +2 -2
  77. package/activity-message.js +16 -16
  78. package/ai/_chat.scss +227 -0
  79. package/ai/_style.scss +170 -39
  80. package/ai/chat.d.ts +65 -0
  81. package/ai/components.d.ts +35 -6
  82. package/ai/index.d.ts +3 -0
  83. package/ai/index.js +3 -3
  84. package/ai/mount.d.ts +59 -6
  85. package/ai/prompt-history.d.ts +13 -0
  86. package/ai/request-trail.d.ts +9 -3
  87. package/ai/results/_style.scss +83 -0
  88. package/ai/results/index.d.ts +11 -0
  89. package/ai/results/metrics.d.ts +5 -0
  90. package/ai/results/table.d.ts +5 -0
  91. package/ai/results/text.d.ts +5 -0
  92. package/ai/results/types.d.ts +29 -0
  93. package/ai/transcript.d.ts +27 -0
  94. package/ai/translation-context.d.ts +1 -1
  95. package/ai/translations.d.ts +1 -1
  96. package/alert.d.ts +2 -2
  97. package/angular/angular.d.ts +1 -1
  98. package/angular/angular.js +13 -10
  99. package/assignee/assignee.scss +28 -6
  100. package/assignee/field.d.ts +2 -2
  101. package/assignee/index.js +86 -87
  102. package/assignee/layout.d.ts +2 -2
  103. package/assignee/picker.d.ts +1 -1
  104. package/avatar/avatar.style.scss +23 -6
  105. package/avatar/index.d.ts +25 -2
  106. package/avatar/index.js +42 -41
  107. package/badge.d.ts +1 -1
  108. package/badge.view.d.ts +8 -0
  109. package/brush-range/_brush-range.scss +55 -49
  110. package/brush-range/component.d.ts +2 -4
  111. package/brush-range/component.js +19 -19
  112. package/buttons/delete-button.d.ts +2 -1
  113. package/buttons/delete-button.js +1 -1
  114. package/buttons/delete-button.style.scss +6 -2
  115. package/buttons/remove-button.d.ts +2 -2
  116. package/buttons/remove-button.js +3 -3
  117. package/buttons/remove-button.style.scss +1 -1
  118. package/buttons/svg-button.d.ts +3 -2
  119. package/buttons/svg-button.js +23 -23
  120. package/calendar/_calendar.scss +27 -26
  121. package/calendar/calendar.d.ts +1 -1
  122. package/calendar/calendar.js +1 -1
  123. package/calendar/caption.d.ts +1 -1
  124. package/calendar/day.d.ts +1 -1
  125. package/calendar/day.js +4 -4
  126. package/calendar/header.d.ts +1 -1
  127. package/calendar/header.js +34 -35
  128. package/calendar/index.js +2 -2
  129. package/calendar/month-grid.d.ts +1 -1
  130. package/calendar/month-grid.js +37 -37
  131. package/calendar/picker.d.ts +1 -1
  132. package/calendar/types.d.ts +1 -1
  133. package/calendar/year-grid.d.ts +1 -1
  134. package/calendar/year-grid.js +12 -12
  135. package/cell-input.scss +3 -7
  136. package/cell-visuals/badge.style.scss +6 -3
  137. package/cell-visuals/bar-chart.style.scss +2 -1
  138. package/cell-visuals/progress-line-value.renderer.style.scss +4 -2
  139. package/cell-visuals/progress-line.style.scss +1 -4
  140. package/cell-visuals/sparkline.style.scss +2 -1
  141. package/cell-visuals/timeline.style.css +4 -2
  142. package/checkbox/checkbox.scss +6 -24
  143. package/checkbox/index.d.ts +2 -2
  144. package/checkbox/index.js +9 -9
  145. package/choice-chips/index.d.ts +4 -2
  146. package/choice-chips/index.js +1 -1
  147. package/color-palette/color-palette.d.ts +1 -1
  148. package/color-palette/color-palette.js +1 -1
  149. package/color-palette/color-palette.style.scss +88 -25
  150. package/color-palette/color-picker.d.ts +1 -1
  151. package/color-palette/color-picker.js +2 -2
  152. package/color-palette/color-picker.style.scss +23 -10
  153. package/color-palette/common-palettes.d.ts +1 -1
  154. package/color-palette/common-palettes.js +1 -1
  155. package/color-palette/native.d.ts +15 -2
  156. package/component-catalog.d.ts +42 -29
  157. package/configurator-actions.d.ts +67 -0
  158. package/configurator-actions.js +1 -0
  159. package/configurator-aggregation-list.d.ts +14 -0
  160. package/configurator-aggregation-list.js +63 -0
  161. package/configurator-drop-zone.d.ts +39 -0
  162. package/configurator-drop-zone.js +66 -0
  163. package/configurator-field-icon.d.ts +10 -0
  164. package/configurator-field-icon.js +1 -0
  165. package/configurator-focus.d.ts +4 -0
  166. package/configurator-focus.js +39 -0
  167. package/configurator-sections.d.ts +42 -0
  168. package/configurator-sections.js +71 -0
  169. package/control-attributes.js +7 -7
  170. package/control-presentation.d.ts +8 -2
  171. package/control-presentation.js +31 -26
  172. package/controls.d.ts +23 -11
  173. package/controls.js +4 -3
  174. package/core/editor-commit.d.ts +1 -1
  175. package/core/editor-popup-position.d.ts +6 -2
  176. package/core/editor-popup.d.ts +5 -1
  177. package/core/editor-popup.js +1 -1
  178. package/core/popover-controller.d.ts +35 -0
  179. package/core/popup-ownership.d.ts +2 -0
  180. package/core/selection-list-tooltips.d.ts +2 -0
  181. package/core/title-tooltip.d.ts +2 -0
  182. package/core/tooltip-session.d.ts +29 -0
  183. package/core/tooltip-surface.d.ts +13 -0
  184. package/core/tooltip-text.d.ts +6 -0
  185. package/core/tooltip.d.ts +35 -0
  186. package/core/top-layer-popup.d.ts +4 -0
  187. package/core/top-layer-popup.js +1 -23
  188. package/date-time/attach.d.ts +1 -1
  189. package/date-time/date-control.d.ts +2 -2
  190. package/date-time/field.d.ts +4 -3
  191. package/date-time/index.js +1 -1
  192. package/date-time/picker.d.ts +1 -1
  193. package/date-time/style.scss +242 -39
  194. package/date-time/time-control.d.ts +1 -1
  195. package/date-time/time-selection.d.ts +3 -1
  196. package/date-time/types.d.ts +6 -2
  197. package/dialog/dialog-action-footer.d.ts +17 -2
  198. package/dialog/dialog.dom.d.ts +15 -2
  199. package/dialog/dialog.dom.js +53 -53
  200. package/dialog/dialog.parts.d.ts +18 -18
  201. package/dialog/dialog.parts.js +1 -1
  202. package/dialog/dialog.preact.d.ts +1 -1
  203. package/dialog/dialog.preact.js +6 -6
  204. package/distribution-chart/_distribution-chart.scss +113 -77
  205. package/distribution-chart/area-chart.d.ts +1 -1
  206. package/distribution-chart/area-chart.js +25 -25
  207. package/distribution-chart/bar-chart.d.ts +6 -3
  208. package/distribution-chart/bar-chart.js +10 -6
  209. package/distribution-chart/chart-frame.d.ts +3 -2
  210. package/distribution-chart/index.d.ts +2 -2
  211. package/distribution-chart/index.js +6 -6
  212. package/distribution-chart/line-chart.d.ts +1 -1
  213. package/distribution-chart/line-chart.js +9 -9
  214. package/distribution-chart/types.d.ts +1 -1
  215. package/dropdown/content.d.ts +3 -2
  216. package/dropdown/content.js +1 -141
  217. package/dropdown/control.d.ts +14 -0
  218. package/dropdown/control.js +1 -0
  219. package/dropdown/control.view.d.ts +6 -0
  220. package/dropdown/dropdown.service.d.ts +1 -1
  221. package/dropdown/dropdown.service.js +9 -9
  222. package/dropdown/dropdown.types.d.ts +5 -1
  223. package/dropdown/editor-dropdown.style.scss +54 -16
  224. package/dropdown/index.d.ts +1 -1
  225. package/dropdown/index.js +3 -4
  226. package/dropdown/lookup-field.d.ts +6 -1
  227. package/dropdown/lookup-field.js +42 -41
  228. package/dropdown/popup.d.ts +2 -2
  229. package/dropdown/popup.js +1 -140
  230. package/duration/controls.d.ts +1 -1
  231. package/duration/index.d.ts +2 -2
  232. package/duration/index.js +1 -1
  233. package/duration/style.scss +1 -1
  234. package/editor-actions.d.ts +1 -1
  235. package/editor-actions.js +21 -20
  236. package/editor-layout/index.d.ts +5 -5
  237. package/editor-layout/index.js +43 -38
  238. package/editor-layout/style.scss +82 -18
  239. package/field-configurator.d.ts +40 -2
  240. package/field-configurator.js +4 -170
  241. package/field-expansion.d.ts +9 -0
  242. package/field-reorder.hook.js +32 -32
  243. package/fieldset.d.ts +3 -0
  244. package/filter/filters/slider/_single-slider.scss +57 -38
  245. package/filter/filters/slider/_slider.scss +41 -33
  246. package/filter/filters/slider/control.js +2 -0
  247. package/filter/filters/slider/preact.js +3 -3
  248. package/filter/filters/slider/runtime.js +49 -22
  249. package/filter/filters/slider/single.d.ts +1 -1
  250. package/filter/filters/slider/single.js +23 -23
  251. package/filter-badge.d.ts +1 -1
  252. package/filter-badge.js +23 -22
  253. package/filter-controls.d.ts +1 -2
  254. package/filter-controls.js +29 -30
  255. package/form-controls/field-context.d.ts +5 -0
  256. package/form-controls/index.d.ts +10 -2
  257. package/form-controls/index.js +17 -22
  258. package/form-controls/presentation.d.ts +2 -2
  259. package/form-controls/presentation.js +59 -51
  260. package/formatting/comparison-preview.d.ts +1 -1
  261. package/formatting/icon-controls.d.ts +1 -1
  262. package/formatting/index.d.ts +1 -1
  263. package/formatting/index.js +106 -100
  264. package/formatting/inspector-section.d.ts +1 -1
  265. package/formatting/styles.scss +14 -57
  266. package/formatting/typography-controls.d.ts +1 -1
  267. package/framework-mount.d.ts +1 -1
  268. package/framework.js +237 -226
  269. package/history-controls.d.ts +14 -0
  270. package/history-controls.js +27 -0
  271. package/icon-toolbar.d.ts +62 -0
  272. package/icon-toolbar.js +1 -0
  273. package/icons/icon.d.ts +2 -2
  274. package/icons/icon.js +1 -1
  275. package/legend.d.ts +2 -2
  276. package/legend.js +12 -12
  277. package/masked-input/index.d.ts +1 -1
  278. package/masked-input/index.js +109 -109
  279. package/native-control.d.ts +14 -13
  280. package/native-control.js +3 -26
  281. package/native-controls.d.ts +54 -2
  282. package/native-styles.css +1 -1
  283. package/native-styles.scss +6 -2
  284. package/native.d.ts +3 -3
  285. package/native.js +49 -45
  286. package/number-input/index.d.ts +2 -2
  287. package/number-input/index.js +1 -1
  288. package/package.json +88 -15
  289. package/pagination.d.ts +3 -0
  290. package/pagination.js +50 -40
  291. package/pdf-viewer/component.d.ts +1 -1
  292. package/pdf-viewer/controller.js +1 -1
  293. package/pdf-viewer/header.d.ts +2 -2
  294. package/pdf-viewer/index.d.ts +2 -2
  295. package/pdf-viewer/index.js +13 -13
  296. package/pdf-viewer/search-bar.d.ts +2 -2
  297. package/pdf-viewer/status.d.ts +2 -2
  298. package/pdf-viewer/style.scss +205 -45
  299. package/pdf-viewer/toolbar.d.ts +1 -1
  300. package/pickers.d.ts +6 -2
  301. package/preact-mount.d.ts +1 -1
  302. package/preact-mount.js +2 -2
  303. package/preact.d.ts +15 -10
  304. package/preact.js +109 -64
  305. package/progress/_bar.scss +9 -3
  306. package/progress/_circular.scss +2 -1
  307. package/rating-choice.d.ts +1 -1
  308. package/rating-choice.js +1 -1
  309. package/react-adapter.d.ts +5 -3
  310. package/react-control.d.ts +1 -0
  311. package/react.d.ts +20 -11
  312. package/react.js +72 -88
  313. package/reorder-list.d.ts +2 -2
  314. package/reorder-list.js +1 -1
  315. package/reorder-list.scss +59 -17
  316. package/resource-picker/resource-picker-avatar.d.ts +1 -1
  317. package/resource-picker/resource-picker-avatar.js +14 -14
  318. package/resource-picker/resource-picker-option.d.ts +1 -1
  319. package/resource-picker/resource-picker-option.js +28 -28
  320. package/resource-picker/resource-picker-popup.d.ts +1 -1
  321. package/resource-picker/resource-picker-popup.js +3 -3
  322. package/resource-picker/resource-picker.d.ts +1 -1
  323. package/resource-picker/resource-picker.js +68 -66
  324. package/resource-picker/resource-picker.scss +66 -35
  325. package/rich-text/engine.d.ts +17 -19
  326. package/rich-text/format-html.d.ts +2 -0
  327. package/rich-text/index.d.ts +11 -7
  328. package/rich-text/index.js +1 -1
  329. package/rich-text/model.d.ts +6 -3
  330. package/rich-text/render-model.d.ts +4 -5
  331. package/rich-text/style.scss +295 -55
  332. package/rich-text/syntax.d.ts +5 -2
  333. package/rich-text/toolbar.d.ts +7 -7
  334. package/rich-text/translations.d.ts +5 -15
  335. package/search-input/index.js +12 -12
  336. package/search-input/native.d.ts +21 -2
  337. package/segmented-switch/index.d.ts +1 -1
  338. package/segmented-switch/index.js +1 -1
  339. package/select.d.ts +22 -0
  340. package/select.js +1 -0
  341. package/selection-list.d.ts +1 -0
  342. package/selection-list.js +3 -1
  343. package/status-feedback/exit-snapshot.js +1 -1
  344. package/status-feedback/index.js +2 -2
  345. package/status-feedback/popover.js +9 -9
  346. package/status-feedback/render.d.ts +2 -2
  347. package/status-feedback/render.js +3 -44
  348. package/status-feedback/status-feedback.scss +130 -34
  349. package/status-feedback/types.d.ts +4 -0
  350. package/status-feedback/use-auto-dismiss.d.ts +3 -0
  351. package/styles/_activity-message.scss +24 -7
  352. package/styles/_alert.scss +78 -17
  353. package/styles/_cell-editor-frame.scss +11 -0
  354. package/styles/_compositions.scss +404 -82
  355. package/styles/_control.scss +42 -12
  356. package/styles/_disclosure.scss +15 -5
  357. package/styles/_editor-counter.scss +16 -6
  358. package/styles/_editor-slider.scss +8 -4
  359. package/styles/_field-configurator.scss +321 -23
  360. package/styles/_fields-grid.scss +49 -0
  361. package/styles/_filter-controls.scss +10 -2
  362. package/styles/_icon-action.scss +48 -15
  363. package/styles/_loading.scss +12 -3
  364. package/styles/_motion.scss +32 -9
  365. package/styles/_palette.scss +0 -24
  366. package/styles/_primitives.scss +376 -116
  367. package/styles/_theme.scss +130 -86
  368. package/styles/_thresholds.scss +28 -25
  369. package/styles/_time-grid.scss +8 -3
  370. package/styles/_tokens.scss +6 -1
  371. package/styles/configurator-actions.scss +241 -0
  372. package/styles/pagination.css +213 -0
  373. package/styles/{legacy-rating.css → rating.css} +8 -3
  374. package/styles.css +1 -1
  375. package/styles.scss +3 -5
  376. package/surfaces.d.ts +38 -2
  377. package/surfaces.js +37 -134
  378. package/svelte/UiComponent.server.js +1 -48
  379. package/svelte/UiComponent.svelte +44 -32
  380. package/svelte.d.ts +1 -1
  381. package/svelte.js +33 -68
  382. package/switch/index.js +3 -2
  383. package/time-grid.d.ts +1 -2
  384. package/time-grid.js +43 -42
  385. package/timeline-track/_style.scss +96 -24
  386. package/timeline-track/component.d.ts +5 -1
  387. package/timeline-track/index.js +91 -74
  388. package/timeline-track/model.d.ts +9 -0
  389. package/timeline-track/model.js +10 -1
  390. package/ui.css +1 -1
  391. package/view-switcher.d.ts +23 -0
  392. package/vue-adapter.d.ts +1 -1
  393. package/vue.d.ts +160 -144
  394. package/vue.js +149 -178
  395. package/_chunks/calendar-BsDxCYhI.js +0 -248
  396. package/_chunks/chart-frame-BvxbmEU9.js +0 -126
  397. package/_chunks/choice-chips-0HfOnK_4.js +0 -110
  398. package/_chunks/color-palette-BmZ7kH9R.js +0 -94
  399. package/_chunks/component-D4PH5UZT.js +0 -859
  400. package/_chunks/control-tooltip-BCNzQCXE.js +0 -100
  401. package/_chunks/controls-NEL5tDaz.js +0 -615
  402. package/_chunks/date-time-DjucJmbc.js +0 -769
  403. package/_chunks/dialog.parts-Dt3KinUz.js +0 -134
  404. package/_chunks/dropdown-CkGQBm1Q.js +0 -357
  405. package/_chunks/duration-BCaktcvz.js +0 -270
  406. package/_chunks/editor-commit-D6Rf5rGz.js +0 -12
  407. package/_chunks/editor-popup-B7fu_A_T.js +0 -81
  408. package/_chunks/framework-mount-BKIOsvY-.js +0 -54
  409. package/_chunks/mount-0-8opf1j.js +0 -90
  410. package/_chunks/native.view-8q_nwQ7x.js +0 -32
  411. package/_chunks/picker-oazJ7sO_.js +0 -121
  412. package/_chunks/reorder-list-BV3kZXso.js +0 -59
  413. package/_chunks/request-trail-D0oVzdRd.js +0 -347
  414. package/_chunks/rich-text-2Rla349o.js +0 -477
  415. package/avatar/index.view.d.ts +0 -25
  416. package/color-palette/native.view.d.ts +0 -15
  417. package/control-presentation.view.d.ts +0 -8
  418. package/dialog/dialog-action-footer.view.d.ts +0 -20
  419. package/dialog/dialog.dom.view.d.ts +0 -15
  420. package/form-controls/index.view.d.ts +0 -12
  421. package/formatting/control-tooltip.d.ts +0 -27
  422. package/native-controls.view.d.ts +0 -54
  423. package/react-native-select.d.ts +0 -6
  424. package/search-input/native.view.d.ts +0 -21
  425. package/styles/legacy-pagination.css +0 -112
  426. package/surfaces.view.d.ts +0 -63
  427. package/vue-native-select.d.ts +0 -9
@@ -0,0 +1,878 @@
1
+ import { c as e, i as t } from "./preact.module-BBM36DnO.js";
2
+ import { i as n, n as r, r as i, t as a } from "./hooks.module-CG3gN83z.js";
3
+ import { t as o } from "./jsxRuntime.module-F6UFnpT-.js";
4
+ import { createControlId as s } from "../core/control-id.js";
5
+ import { n as c, t as l } from "./popover-controller-D-AvKQ7B.js";
6
+ import { SvgIcon as u } from "../icons/icon.js";
7
+ import { l as d, n as f } from "./native-control-B9MNibfa.js";
8
+ import { n as p } from "./popup-C35Isk7p.js";
9
+ import { t as m } from "./chevron-down-GbplLa6s.js";
10
+ import { D as h, F as g, I as _, R as v, b as y, g as b, l as x, p as S, t as C } from "./controls-DD1qvPfE.js";
11
+ import { n as w, t as T } from "./chevron-right-CM3ljziP.js";
12
+ import { t as E } from "./xmark-DD_PBvZI.js";
13
+ import { t as D } from "./tooltip-text-BXsUEmBH.js";
14
+ import { DialogController as O, attachMenuKeyboard as k } from "../surfaces.js";
15
+ import { t as A } from "./rotate-right-Iha5ScJ1.js";
16
+ import { t as j } from "./chevron-up-BLuNMPDn.js";
17
+ import { avatarTemplate as M } from "../avatar/index.js";
18
+ import { renderProgressBar as ee } from "../progress/bar.js";
19
+ import { t as te } from "./plus-CbGRkIGl.js";
20
+ import { t as ne } from "./minus-BOAR3A1C.js";
21
+ import { SearchInput as re } from "../search-input/index.js";
22
+ import { s as N } from "./iso-B0YHBK7m.js";
23
+ import { f as P, h as F, o as I } from "./model-mPO2tG2f.js";
24
+ import { n as L, t as R } from "./date-control-XI2cpKI_.js";
25
+ import { t as z } from "./calendar-DJqiFwFT.js";
26
+ import { t as B } from "./magnifying-glass-CvrTDSkB.js";
27
+ import { t as V } from "./controller-hRBm_Lfz.js";
28
+ //#region src/pickers.tsx
29
+ function H(e) {
30
+ return /* @__PURE__ */ o(d, {
31
+ ...e,
32
+ className: `rv-combobox ${e.className ?? ""}`,
33
+ config: {
34
+ ...e.config,
35
+ search: !0,
36
+ multiSelect: !1
37
+ }
38
+ });
39
+ }
40
+ function U(e) {
41
+ return /* @__PURE__ */ o(d, {
42
+ ...e,
43
+ className: `rv-multi-select ${e.className ?? ""}`,
44
+ config: {
45
+ ...e.config,
46
+ multiSelect: !0
47
+ }
48
+ });
49
+ }
50
+ function ie(t) {
51
+ return M(e, t);
52
+ }
53
+ function ae(t) {
54
+ return ee(e, t);
55
+ }
56
+ function W({ open: e, anchor: t, appendTo: n, closeOnOutside: r, closeOnEscape: s, onClose: c, children: u, label: d, className: f = "", role: p = "dialog" }) {
57
+ let m = a(null), h = a(c);
58
+ h.current = c;
59
+ let g = a({
60
+ closeOnOutside: r,
61
+ closeOnEscape: s
62
+ }).current;
63
+ return g.closeOnOutside = r, g.closeOnEscape = s, i(() => {
64
+ if (!e || !t || !m.current) return;
65
+ let r = m.current, i = new l(), a = !0;
66
+ i.open({
67
+ anchor: t,
68
+ appendTo: n,
69
+ get closeOnOutside() {
70
+ return g.closeOnOutside;
71
+ },
72
+ get closeOnEscape() {
73
+ return g.closeOnEscape;
74
+ },
75
+ content: m.current,
76
+ display: p === "menu" ? "grid" : void 0,
77
+ onClose: () => {
78
+ a && h.current();
79
+ }
80
+ });
81
+ let o = p === "menu" ? k(r, () => i.close(), g) : void 0;
82
+ return () => {
83
+ a = !1, o?.(), i.destroy(), r.hidden = !0;
84
+ };
85
+ }, [
86
+ e,
87
+ t,
88
+ p,
89
+ n
90
+ ]), /* @__PURE__ */ o("div", {
91
+ ref: m,
92
+ class: `rv-popover ${p === "menu" ? "rv-menu " : ""}${f}`,
93
+ role: p,
94
+ "aria-label": d,
95
+ hidden: !e,
96
+ children: e ? u : null
97
+ });
98
+ }
99
+ function oe({ text: e, children: t }) {
100
+ let n = a(null);
101
+ return i(() => {
102
+ let t = n.current;
103
+ if (!t) return;
104
+ let r = new c(), i, a = () => {
105
+ let n = t.querySelector("button, input, a[href], [tabindex]") ?? t;
106
+ n !== i && (r.bind(n, e), i = n);
107
+ };
108
+ a();
109
+ let o = new t.ownerDocument.defaultView.MutationObserver(a);
110
+ return o.observe(t, {
111
+ childList: !0,
112
+ subtree: !0,
113
+ attributes: !0,
114
+ attributeFilter: ["href", "tabindex"]
115
+ }), t.addEventListener("focus", a, !0), t.addEventListener("pointerenter", a, !0), () => {
116
+ o.disconnect(), t.removeEventListener("focus", a, !0), t.removeEventListener("pointerenter", a, !0), r.destroy();
117
+ };
118
+ }, [e]), /* @__PURE__ */ o("span", {
119
+ ref: n,
120
+ class: "rv-tooltip-anchor",
121
+ children: t
122
+ });
123
+ }
124
+ function G({ open: e, title: r, closeLabel: s, onClose: c, children: l, footer: u, draggable: d, returnFocus: f }) {
125
+ let m = a(null), h = a(c);
126
+ h.current = c;
127
+ let [g, _] = n();
128
+ return i(() => {
129
+ if (!e || !m.current) {
130
+ _(void 0);
131
+ return;
132
+ }
133
+ let t = new O(m.current.ownerDocument), n = !0, i = t.open({
134
+ title: r,
135
+ closeLabel: s,
136
+ draggable: d,
137
+ returnFocus: f,
138
+ surfaceClass: "rv-ui-dialog",
139
+ onClose: () => {
140
+ _(void 0), n && h.current();
141
+ }
142
+ });
143
+ return _({
144
+ body: i.body,
145
+ footer: i.footer
146
+ }), () => {
147
+ n = !1, t.destroy();
148
+ };
149
+ }, [
150
+ e,
151
+ r,
152
+ s,
153
+ d,
154
+ f
155
+ ]), /* @__PURE__ */ o(t, { children: [
156
+ /* @__PURE__ */ o("span", {
157
+ ref: m,
158
+ hidden: !0
159
+ }),
160
+ g && p(l, g.body),
161
+ g && u && p(u, g.footer)
162
+ ] });
163
+ }
164
+ function se({ onConfirm: e, confirmLabel: n, cancelLabel: r, pending: i, ...a }) {
165
+ return /* @__PURE__ */ o(G, {
166
+ ...a,
167
+ footer: /* @__PURE__ */ o(t, { children: [/* @__PURE__ */ o(C, {
168
+ disabled: i,
169
+ onClick: a.onClose,
170
+ children: r
171
+ }), /* @__PURE__ */ o(C, {
172
+ variant: "primary",
173
+ disabled: i,
174
+ onClick: e,
175
+ children: n
176
+ })] })
177
+ });
178
+ }
179
+ function ce({ value: e, onChange: t, label: r, openLabel: a, disabled: c, readOnly: l, ...d }) {
180
+ let [f, p] = n(!1), [m, h] = n(null), [g, _] = n(e && N(e) ? e : F()), [v, y] = n(P(g, d.calendarSystem)), [b] = n(() => s("rv-date-picker"));
181
+ return i(() => {
182
+ (c || l) && p(!1);
183
+ }, [c, l]), /* @__PURE__ */ o("div", {
184
+ class: "rv-date-picker",
185
+ children: [
186
+ /* @__PURE__ */ o(R, {
187
+ label: r,
188
+ value: e ?? "",
189
+ minDate: d.minDate,
190
+ maxDate: d.maxDate,
191
+ disabled: c,
192
+ readOnly: l,
193
+ onChange: (e) => {
194
+ typeof e != "string" || c || l || e && (d.minDate && e < d.minDate || d.maxDate && e > d.maxDate) || (!e || N(e)) && t(e || void 0);
195
+ }
196
+ }),
197
+ /* @__PURE__ */ o(C, {
198
+ ref: h,
199
+ "aria-label": a,
200
+ "aria-haspopup": "dialog",
201
+ "aria-expanded": f,
202
+ "aria-controls": b,
203
+ disabled: c || l,
204
+ onClick: () => {
205
+ e && N(e) && (_(e), y(P(e, d.calendarSystem))), p(!f);
206
+ },
207
+ children: /* @__PURE__ */ o(u, { svg: L })
208
+ }),
209
+ /* @__PURE__ */ o(W, {
210
+ open: f,
211
+ anchor: m,
212
+ onClose: () => p(!1),
213
+ label: r,
214
+ children: /* @__PURE__ */ o("div", {
215
+ id: b,
216
+ children: /* @__PURE__ */ o(z, {
217
+ ...d,
218
+ month: v,
219
+ focusedDate: g,
220
+ selection: e ? {
221
+ from: e,
222
+ to: e
223
+ } : void 0,
224
+ onMonthChange: y,
225
+ onFocusedDateChange: _,
226
+ onSelect: (e) => {
227
+ t(e), p(!1), m?.focus();
228
+ }
229
+ })
230
+ })
231
+ })
232
+ ]
233
+ });
234
+ }
235
+ function le({ value: e, onChange: t, label: r, fromLabel: a, toLabel: c, openLabel: l, disabled: d, readOnly: f, ...p }) {
236
+ let [m, h] = n(!1), [g, _] = n(null), [v, y] = n(), [b, x] = n(e?.from ?? F()), [S, w] = n(P(b, p.calendarSystem)), [T] = n(() => s("rv-date-picker"));
237
+ i(() => {
238
+ (d || f) && (h(!1), y(void 0));
239
+ }, [d, f]);
240
+ let E = (n, r) => {
241
+ if (d || f || !N(r) || p.minDate && r < p.minDate || p.maxDate && r > p.maxDate) return;
242
+ let i = r;
243
+ t(I(n === "from" ? i : e?.from ?? i, n === "to" ? i : e?.to ?? i));
244
+ };
245
+ return /* @__PURE__ */ o("div", {
246
+ class: "rv-date-range-picker",
247
+ role: "group",
248
+ "aria-label": r,
249
+ children: [
250
+ /* @__PURE__ */ o(R, {
251
+ label: a,
252
+ value: e?.from ?? "",
253
+ disabled: d,
254
+ readOnly: f,
255
+ minDate: p.minDate,
256
+ maxDate: p.maxDate,
257
+ onChange: (e) => {
258
+ typeof e == "string" && E("from", e);
259
+ }
260
+ }),
261
+ /* @__PURE__ */ o(R, {
262
+ label: c,
263
+ value: e?.to ?? "",
264
+ disabled: d,
265
+ readOnly: f,
266
+ minDate: p.minDate,
267
+ maxDate: p.maxDate,
268
+ onChange: (e) => {
269
+ typeof e == "string" && E("to", e);
270
+ }
271
+ }),
272
+ /* @__PURE__ */ o(C, {
273
+ ref: _,
274
+ disabled: d || f,
275
+ "aria-label": l,
276
+ "aria-haspopup": "dialog",
277
+ "aria-expanded": m,
278
+ "aria-controls": T,
279
+ onClick: () => {
280
+ y(void 0), e && (x(e.from), w(P(e.from, p.calendarSystem))), h(!m);
281
+ },
282
+ children: /* @__PURE__ */ o(u, { svg: L })
283
+ }),
284
+ /* @__PURE__ */ o(W, {
285
+ open: m,
286
+ anchor: g,
287
+ onClose: () => {
288
+ h(!1), y(void 0);
289
+ },
290
+ label: r,
291
+ children: /* @__PURE__ */ o("div", {
292
+ id: T,
293
+ children: /* @__PURE__ */ o(z, {
294
+ ...p,
295
+ month: S,
296
+ focusedDate: b,
297
+ selection: v ? I(v, b) : e,
298
+ onMonthChange: w,
299
+ onFocusedDateChange: x,
300
+ onSelect: (e) => {
301
+ v ? (t(I(v, e)), y(void 0), h(!1), g?.focus()) : y(e);
302
+ }
303
+ })
304
+ })
305
+ })
306
+ ]
307
+ });
308
+ }
309
+ //#endregion
310
+ //#region src/pdf-viewer/translations.ts
311
+ var K = {
312
+ viewer: "PDF document",
313
+ pages: "Document pages",
314
+ toolbar: "PDF tools",
315
+ first: "First page",
316
+ last: "Last page",
317
+ open: "Open PDF",
318
+ previous: "Previous page",
319
+ next: "Next page",
320
+ zoomPercentage: "{percent}%",
321
+ page: "Page",
322
+ of: "of",
323
+ zoom: "Zoom",
324
+ zoomIn: "Zoom in",
325
+ zoomOut: "Zoom out",
326
+ fitWidth: "Fit width",
327
+ fitPage: "Fit page",
328
+ rotate: "Rotate clockwise",
329
+ search: "Find in document",
330
+ previousMatch: "Previous match",
331
+ nextMatch: "Next match",
332
+ closeSearch: "Close search",
333
+ matches: "matches",
334
+ noMatches: "No matches",
335
+ searching: "Searching…",
336
+ download: "Download PDF",
337
+ print: "Print PDF",
338
+ printing: "Preparing print…",
339
+ loading: "Loading PDF…",
340
+ empty: "Open a PDF to get started",
341
+ emptyHint: "View, search, print and download your document.",
342
+ errorDescription: "Check the document and try again.",
343
+ operationError: "Unable to complete the PDF operation. Try again.",
344
+ printDocument: "PDF print document",
345
+ pageCount: "{of} {pages}",
346
+ pageSummary: "{page} {of} {pages}",
347
+ matchSummary: "{match} / {total} {matches}",
348
+ error: "Unable to display this PDF",
349
+ retry: "Retry",
350
+ more: "More PDF tools",
351
+ cancelPrint: "Cancel printing"
352
+ };
353
+ function q(e, t) {
354
+ return e.replace(/\{(\w+)\}/g, (e, n) => String(t[n] ?? e));
355
+ }
356
+ function J(e) {
357
+ return {
358
+ ...K,
359
+ ...Object.fromEntries(Object.entries(e ?? {}).filter(([, e]) => typeof e == "string"))
360
+ };
361
+ }
362
+ //#endregion
363
+ //#region src/pdf-viewer/toolbar-options.ts
364
+ function Y(e) {
365
+ return e === !1 ? { tools: [] } : Array.isArray(e) ? { tools: e } : e ?? {};
366
+ }
367
+ function X(e, t) {
368
+ let n = Y(e);
369
+ return t === "navigation" && (!n.boundaryButtons || n.buttons?.first === !1 && n.buttons?.last === !1) && n.buttons?.previous === !1 && n.buttons?.next === !1 && n.showPageInput === !1 && n.showPageCount === !1 || t === "zoom" && n.buttons?.zoomOut === !1 && n.buttons?.zoomIn === !1 && n.showZoomSelect === !1 ? !1 : (!n.tools || n.tools.includes(t)) && (![
370
+ "open",
371
+ "search",
372
+ "rotate",
373
+ "download",
374
+ "print"
375
+ ].includes(t) || n.buttons?.[t] !== !1);
376
+ }
377
+ //#endregion
378
+ //#region src/pdf-viewer/icons.ts
379
+ var Z = {
380
+ previous: w,
381
+ next: T,
382
+ document: "<svg xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"0 0 576 512\"><!--! Font Awesome Free 7.3.1 by @fontawesome - https://fontawesome.com License - https://fontawesome.com/license/free (Icons: CC BY 4.0, Fonts: SIL OFL 1.1, Code: MIT License) Copyright 2026 Fonticons, Inc. --><path fill=\"currentColor\" d=\"M96 0C60.7 0 32 28.7 32 64l0 384c0 35.3 28.7 64 64 64l80 0 0-112c0-35.3 28.7-64 64-64l176 0 0-165.5c0-17-6.7-33.3-18.7-45.3L290.7 18.7C278.7 6.7 262.5 0 245.5 0L96 0zM357.5 176L264 176c-13.3 0-24-10.7-24-24L240 58.5 357.5 176zM240 380c-11 0-20 9-20 20l0 128c0 11 9 20 20 20s20-9 20-20l0-28 12 0c33.1 0 60-26.9 60-60s-26.9-60-60-60l-32 0zm32 80l-12 0 0-40 12 0c11 0 20 9 20 20s-9 20-20 20zm96-80c-11 0-20 9-20 20l0 128c0 11 9 20 20 20l32 0c28.7 0 52-23.3 52-52l0-64c0-28.7-23.3-52-52-52l-32 0zm20 128l0-88 12 0c6.6 0 12 5.4 12 12l0 64c0 6.6-5.4 12-12 12l-12 0zm88-108l0 128c0 11 9 20 20 20s20-9 20-20l0-44 28 0c11 0 20-9 20-20s-9-20-20-20l-28 0 0-24 28 0c11 0 20-9 20-20s-9-20-20-20l-48 0c-11 0-20 9-20 20z\"/></svg>",
383
+ open: "<svg xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"0 0 576 512\"><!--! Font Awesome Free 7.3.1 by @fontawesome - https://fontawesome.com License - https://fontawesome.com/license/free (Icons: CC BY 4.0, Fonts: SIL OFL 1.1, Code: MIT License) Copyright 2026 Fonticons, Inc. --><path fill=\"currentColor\" d=\"M56 225.6L32.4 296.2 32.4 96c0-35.3 28.7-64 64-64l138.7 0c13.8 0 27.3 4.5 38.4 12.8l38.4 28.8c5.5 4.2 12.3 6.4 19.2 6.4l117.3 0c35.3 0 64 28.7 64 64l0 16-365.4 0c-41.3 0-78 26.4-91.1 65.6zM477.8 448L99 448c-32.8 0-55.9-32.1-45.5-63.2l48-144C108 221.2 126.4 208 147 208l378.8 0c32.8 0 55.9 32.1 45.5 63.2l-48 144c-6.5 19.6-24.9 32.8-45.5 32.8z\"/></svg>",
384
+ search: B,
385
+ minus: ne,
386
+ plus: te,
387
+ rotate: A,
388
+ download: "<svg xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"0 0 448 512\"><!--! Font Awesome Free 7.3.1 by @fontawesome - https://fontawesome.com License - https://fontawesome.com/license/free (Icons: CC BY 4.0, Fonts: SIL OFL 1.1, Code: MIT License) Copyright 2026 Fonticons, Inc. --><path fill=\"currentColor\" d=\"M256 32c0-17.7-14.3-32-32-32s-32 14.3-32 32l0 210.7-41.4-41.4c-12.5-12.5-32.8-12.5-45.3 0s-12.5 32.8 0 45.3l96 96c12.5 12.5 32.8 12.5 45.3 0l96-96c12.5-12.5 12.5-32.8 0-45.3s-32.8-12.5-45.3 0L256 242.7 256 32zM64 320c-35.3 0-64 28.7-64 64l0 32c0 35.3 28.7 64 64 64l320 0c35.3 0 64-28.7 64-64l0-32c0-35.3-28.7-64-64-64l-46.9 0-56.6 56.6c-31.2 31.2-81.9 31.2-113.1 0L110.9 320 64 320zm304 56a24 24 0 1 1 0 48 24 24 0 1 1 0-48z\"/></svg>",
389
+ print: "<svg xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"0 0 512 512\"><!--! Font Awesome Free 7.3.1 by @fontawesome - https://fontawesome.com License - https://fontawesome.com/license/free (Icons: CC BY 4.0, Fonts: SIL OFL 1.1, Code: MIT License) Copyright 2026 Fonticons, Inc. --><path fill=\"currentColor\" d=\"M64 64C64 28.7 92.7 0 128 0L341.5 0c17 0 33.3 6.7 45.3 18.7l42.5 42.5c12 12 18.7 28.3 18.7 45.3l0 37.5-384 0 0-80zM0 256c0-35.3 28.7-64 64-64l384 0c35.3 0 64 28.7 64 64l0 96c0 17.7-14.3 32-32 32l-32 0 0 64c0 35.3-28.7 64-64 64l-256 0c-35.3 0-64-28.7-64-64l0-64-32 0c-17.7 0-32-14.3-32-32l0-96zM128 416l0 32 256 0 0-96-256 0 0 64zM456 272a24 24 0 1 0 -48 0 24 24 0 1 0 48 0z\"/></svg>",
390
+ close: E,
391
+ up: j,
392
+ down: m,
393
+ more: "<svg xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"0 0 128 512\"><!--! Font Awesome Free 7.3.1 by @fontawesome - https://fontawesome.com License - https://fontawesome.com/license/free (Icons: CC BY 4.0, Fonts: SIL OFL 1.1, Code: MIT License) Copyright 2026 Fonticons, Inc. --><path fill=\"currentColor\" d=\"M64 144a56 56 0 1 1 0-112 56 56 0 1 1 0 112zm0 224c30.9 0 56 25.1 56 56s-25.1 56-56 56-56-25.1-56-56 25.1-56 56-56zm56-112c0 30.9-25.1 56-56 56s-56-25.1-56-56 25.1-56 56-56 56 25.1 56 56z\"/></svg>"
394
+ };
395
+ //#endregion
396
+ //#region src/pdf-viewer/toolbar.tsx
397
+ function Q(e) {
398
+ let { controller: r, state: s } = e, c = J(e.text), l = Y(e.config), p = s.status === "ready", m = (e) => l.buttons?.[e] !== !1, h = (e) => {
399
+ let t = l.buttons?.[e];
400
+ return t === !1 ? {} : t ?? {};
401
+ }, v = (t) => X(e.config, t), [x, w] = n(!1), T = a(null), E = a(null), [D, O] = n(String(s.page || "")), k = Number.isFinite(l.zoomStep) && l.zoomStep > 1 ? l.zoomStep : 1.25, A = [...new Set((l.zoomLevels ?? [
402
+ "page-width",
403
+ "page-fit",
404
+ .5,
405
+ .75,
406
+ 1,
407
+ 1.25,
408
+ 1.5,
409
+ 2,
410
+ 3,
411
+ 5
412
+ ]).filter((e) => e === "page-width" || e === "page-fit" || typeof e == "number" && Number.isFinite(e) && e >= .25 && e <= 5))];
413
+ A.includes(s.zoom) || A.push(s.zoom), i(() => {
414
+ O(String(s.page || ""));
415
+ }, [s.page, r]), i(() => {
416
+ w(!1);
417
+ }, [
418
+ e.config,
419
+ p,
420
+ r
421
+ ]), i(() => {
422
+ if (!x) return;
423
+ E.current?.querySelector("[role=\"menuitem\"]:not(:disabled)")?.focus();
424
+ let e = T.current, t = new ResizeObserver(() => {
425
+ e && !e.getClientRects().length && w(!1);
426
+ });
427
+ return e && t.observe(e), () => t.disconnect();
428
+ }, [x]);
429
+ let j = () => {
430
+ w(!1), T.current?.focus({ preventScroll: !0 });
431
+ }, M = () => {
432
+ D.trim() && Number.isFinite(Number(D)) && r.goToPage(Number(D)), O(String(r.snapshot.page));
433
+ };
434
+ return [
435
+ "open",
436
+ "navigation",
437
+ "zoom",
438
+ "search",
439
+ "rotate",
440
+ "download",
441
+ "print"
442
+ ].some(v) ? /* @__PURE__ */ o(t, { children: [/* @__PURE__ */ o(g, {
443
+ label: c.toolbar,
444
+ className: `rv-pdf-viewer__toolbar rv-toolbar--surface ${l.className ?? ""}`,
445
+ children: [
446
+ v("open") && /* @__PURE__ */ o(_, { children: /* @__PURE__ */ o(C, {
447
+ variant: "ghost",
448
+ size: "compact",
449
+ ...h("open"),
450
+ title: h("open").title ?? c.open,
451
+ "aria-label": c.open,
452
+ onClick: () => e.onOpen(),
453
+ children: [/* @__PURE__ */ o(u, { svg: Z.open }), /* @__PURE__ */ o("span", {
454
+ class: "rv-pdf-viewer__open-label",
455
+ children: c.open
456
+ })]
457
+ }) }),
458
+ v("navigation") && (l.boundaryButtons || m("previous") || m("next") || l.showPageInput !== !1 || l.showPageCount !== !1) && /* @__PURE__ */ o(_, {
459
+ label: c.page,
460
+ children: /* @__PURE__ */ o(y, {
461
+ page: s.page - 1,
462
+ pageCount: s.pageCount,
463
+ onChange: (e) => r.goToPage(e + 1),
464
+ label: c.page,
465
+ previousLabel: c.previous,
466
+ nextLabel: c.next,
467
+ firstLabel: c.first,
468
+ lastLabel: c.last,
469
+ variant: "icons",
470
+ disabled: !p,
471
+ boundaryButtons: l.boundaryButtons,
472
+ buttons: {
473
+ first: l.buttons?.first,
474
+ previous: l.buttons?.previous,
475
+ next: l.buttons?.next,
476
+ last: l.buttons?.last
477
+ },
478
+ children: [l.showPageInput !== !1 && /* @__PURE__ */ o(f, {
479
+ class: "rv-pdf-viewer__page-input",
480
+ type: "number",
481
+ min: 1,
482
+ max: s.pageCount || 1,
483
+ disabled: !p,
484
+ "aria-label": c.page,
485
+ value: D,
486
+ onInput: (e) => O(e.currentTarget.value),
487
+ onChange: M,
488
+ onKeyDown: (e) => {
489
+ e.key === "Enter" && (e.preventDefault(), M()), e.key === "Escape" && (e.preventDefault(), O(String(s.page)));
490
+ }
491
+ }), l.showPageCount !== !1 && /* @__PURE__ */ o("span", {
492
+ class: "rv-pdf-viewer__page-count",
493
+ children: q(c.pageCount, {
494
+ of: c.of,
495
+ pages: s.pageCount
496
+ })
497
+ })]
498
+ })
499
+ }),
500
+ v("zoom") && (m("zoomOut") || m("zoomIn") || l.showZoomSelect !== !1) && /* @__PURE__ */ o(_, {
501
+ label: c.zoom,
502
+ children: [
503
+ m("zoomOut") && /* @__PURE__ */ o(S, {
504
+ ...h("zoomOut"),
505
+ label: c.zoomOut,
506
+ icon: Z.minus,
507
+ size: "compact",
508
+ disabled: !p || s.scale <= .25 || !!h("zoomOut").disabled,
509
+ onClick: () => r.setZoom(s.scale / k)
510
+ }),
511
+ l.showZoomSelect !== !1 && /* @__PURE__ */ o("div", {
512
+ class: "rv-pdf-viewer__zoom-select",
513
+ children: /* @__PURE__ */ o(d, {
514
+ className: "rv-select",
515
+ config: {
516
+ ariaLabel: c.zoom,
517
+ portalTarget: e.appendTo
518
+ },
519
+ disabled: !p,
520
+ value: String(s.zoom),
521
+ source: A.map((e) => ({
522
+ value: String(e),
523
+ label: e === "page-width" ? c.fitWidth : e === "page-fit" ? c.fitPage : q(c.zoomPercentage, { percent: Math.round(e * 100) })
524
+ })),
525
+ onChange: (e) => {
526
+ let t = String(e);
527
+ r.setZoom(t === "page-fit" || t === "page-width" ? t : Number(t));
528
+ }
529
+ })
530
+ }),
531
+ m("zoomIn") && /* @__PURE__ */ o(S, {
532
+ ...h("zoomIn"),
533
+ label: c.zoomIn,
534
+ icon: Z.plus,
535
+ size: "compact",
536
+ disabled: !p || s.scale >= 5 || !!h("zoomIn").disabled,
537
+ onClick: () => r.setZoom(s.scale * k)
538
+ })
539
+ ]
540
+ }),
541
+ v("search") && /* @__PURE__ */ o(_, { children: m("search") && /* @__PURE__ */ o(S, {
542
+ ...h("search"),
543
+ label: c.search,
544
+ icon: Z.search,
545
+ size: "compact",
546
+ disabled: !p || !!h("search").disabled,
547
+ "aria-expanded": e.searchOpen,
548
+ "aria-controls": e.searchId,
549
+ "aria-keyshortcuts": "Control+f Meta+f",
550
+ onClick: (t) => e.onToggleSearch(t.currentTarget)
551
+ }) }),
552
+ (v("rotate") || v("download") || v("print")) && /* @__PURE__ */ o(_, {
553
+ className: "rv-pdf-viewer__actions rv-pdf-viewer__desktop-actions",
554
+ children: [
555
+ v("rotate") && /* @__PURE__ */ o(S, {
556
+ ...h("rotate"),
557
+ label: c.rotate,
558
+ icon: Z.rotate,
559
+ size: "compact",
560
+ disabled: !p || !!h("rotate").disabled,
561
+ onClick: () => r.rotate()
562
+ }),
563
+ v("download") && /* @__PURE__ */ o(S, {
564
+ ...h("download"),
565
+ label: c.download,
566
+ icon: Z.download,
567
+ size: "compact",
568
+ disabled: !p || !!h("download").disabled,
569
+ onClick: () => void r.download()
570
+ }),
571
+ v("print") && /* @__PURE__ */ o(S, {
572
+ ...h("print"),
573
+ label: c.print,
574
+ icon: Z.print,
575
+ size: "compact",
576
+ disabled: !p || s.printing || !!h("print").disabled,
577
+ busy: s.printing,
578
+ onClick: () => void r.print()
579
+ })
580
+ ]
581
+ }),
582
+ (v("rotate") || v("download") || v("print")) && /* @__PURE__ */ o(_, {
583
+ className: "rv-pdf-viewer__more",
584
+ children: /* @__PURE__ */ o(C, {
585
+ ref: T,
586
+ variant: "ghost",
587
+ size: "compact",
588
+ className: "rv-btn-icon",
589
+ title: c.more,
590
+ "aria-label": c.more,
591
+ "aria-haspopup": "menu",
592
+ "aria-expanded": x,
593
+ disabled: !p,
594
+ onClick: () => w(!x),
595
+ onKeyDown: (e) => {
596
+ e.key === "ArrowDown" && (e.preventDefault(), w(!0));
597
+ },
598
+ children: /* @__PURE__ */ o(u, { svg: Z.more })
599
+ })
600
+ })
601
+ ]
602
+ }), /* @__PURE__ */ o(W, {
603
+ open: x,
604
+ anchor: T.current,
605
+ appendTo: e.appendTo,
606
+ onClose: () => w(!1),
607
+ role: "menu",
608
+ label: c.more,
609
+ children: /* @__PURE__ */ o("div", {
610
+ ref: E,
611
+ class: "rv-pdf-viewer__menu",
612
+ children: [
613
+ v("rotate") && /* @__PURE__ */ o(b, {
614
+ className: h("rotate").className,
615
+ disabled: !!h("rotate").disabled,
616
+ onClick: () => {
617
+ r.rotate(), j();
618
+ },
619
+ children: [/* @__PURE__ */ o(u, { svg: Z.rotate }), c.rotate]
620
+ }),
621
+ v("download") && /* @__PURE__ */ o(b, {
622
+ className: h("download").className,
623
+ disabled: !!h("download").disabled,
624
+ onClick: () => {
625
+ r.download(), j();
626
+ },
627
+ children: [/* @__PURE__ */ o(u, { svg: Z.download }), c.download]
628
+ }),
629
+ v("print") && /* @__PURE__ */ o(b, {
630
+ className: h("print").className,
631
+ disabled: s.printing || !!h("print").disabled,
632
+ onClick: () => {
633
+ r.print(), j();
634
+ },
635
+ children: [/* @__PURE__ */ o(u, { svg: Z.print }), c.print]
636
+ })
637
+ ]
638
+ })
639
+ })] }) : null;
640
+ }
641
+ //#endregion
642
+ //#region src/pdf-viewer/search-bar.tsx
643
+ function ue({ id: e, controller: t, state: n, text: r, onClose: a, inputRef: s }) {
644
+ let c = n.status === "ready";
645
+ return i(() => {
646
+ s.current?.focus();
647
+ }, []), /* @__PURE__ */ o("div", {
648
+ id: e,
649
+ class: "rv-pdf-viewer__search",
650
+ role: "search",
651
+ "aria-label": r.search,
652
+ onKeyDown: (e) => {
653
+ e.key === "Escape" && (e.preventDefault(), e.stopPropagation(), a());
654
+ },
655
+ children: [/* @__PURE__ */ o(re, {
656
+ icon: /* @__PURE__ */ o(u, { svg: Z.search }),
657
+ inputRef: s,
658
+ "aria-label": r.search,
659
+ placeholder: r.search,
660
+ value: n.query,
661
+ disabled: !c,
662
+ onValueChange: (e) => t.search(e),
663
+ onKeyDown: (e) => {
664
+ e.key === "Enter" && (e.preventDefault(), t.search(n.query, e.shiftKey, !0));
665
+ }
666
+ }), /* @__PURE__ */ o("div", {
667
+ class: "rv-pdf-viewer__find-controls",
668
+ children: [
669
+ /* @__PURE__ */ o("span", {
670
+ role: "status",
671
+ class: "rv-pdf-viewer__matches",
672
+ children: n.query ? n.searching ? r.searching : n.matchCount ? q(r.matchSummary, {
673
+ match: n.match,
674
+ total: n.matchCount,
675
+ matches: r.matches
676
+ }) : r.noMatches : ""
677
+ }),
678
+ /* @__PURE__ */ o(S, {
679
+ label: r.previousMatch,
680
+ icon: Z.up,
681
+ size: "compact",
682
+ disabled: !c || !n.matchCount,
683
+ onClick: () => t.search(n.query, !0, !0)
684
+ }),
685
+ /* @__PURE__ */ o(S, {
686
+ label: r.nextMatch,
687
+ icon: Z.down,
688
+ size: "compact",
689
+ disabled: !c || !n.matchCount,
690
+ onClick: () => t.search(n.query, !1, !0)
691
+ }),
692
+ /* @__PURE__ */ o(S, {
693
+ label: r.closeSearch,
694
+ icon: Z.close,
695
+ size: "compact",
696
+ onClick: a
697
+ })
698
+ ]
699
+ })]
700
+ });
701
+ }
702
+ //#endregion
703
+ //#region src/pdf-viewer/header.tsx
704
+ function de({ state: e, text: n, onCancelPrint: r, showDetails: i = !0 }) {
705
+ let a = e.status === "ready";
706
+ return /* @__PURE__ */ o("header", {
707
+ class: "rv-pdf-viewer__header",
708
+ children: [
709
+ i && /* @__PURE__ */ o(t, { children: [/* @__PURE__ */ o(u, {
710
+ svg: Z.document,
711
+ className: "rv-svg-icon rv-pdf-viewer__document-icon"
712
+ }), /* @__PURE__ */ o(D, {
713
+ class: "rv-pdf-viewer__filename",
714
+ title: e.fileName,
715
+ children: e.fileName
716
+ })] }),
717
+ /* @__PURE__ */ o("span", {
718
+ class: "rv-pdf-viewer__summary",
719
+ "aria-live": "polite",
720
+ children: e.printing ? n.printing : a ? q(n.pageSummary, {
721
+ page: e.page,
722
+ of: n.of,
723
+ pages: e.pageCount
724
+ }) : ""
725
+ }),
726
+ e.printing && /* @__PURE__ */ o(C, {
727
+ variant: "ghost",
728
+ size: "compact",
729
+ onClick: () => r(),
730
+ children: n.cancelPrint
731
+ })
732
+ ]
733
+ });
734
+ }
735
+ //#endregion
736
+ //#region src/pdf-viewer/status.tsx
737
+ function fe({ state: e, text: n, controller: r, canOpen: i, onOpen: a }) {
738
+ return e.status === "loading" ? /* @__PURE__ */ o(t, { children: [/* @__PURE__ */ o(h, { label: n.loading }), /* @__PURE__ */ o("span", { children: n.loading })] }) : e.status === "error" ? /* @__PURE__ */ o(v, {
739
+ tone: "danger",
740
+ title: n.error,
741
+ description: n.errorDescription,
742
+ actions: /* @__PURE__ */ o(t, { children: [r.canRetry && /* @__PURE__ */ o(C, {
743
+ size: "compact",
744
+ onClick: () => void r.retry(),
745
+ children: n.retry
746
+ }), i && /* @__PURE__ */ o(C, {
747
+ size: "compact",
748
+ onClick: () => a(),
749
+ children: n.open
750
+ })] })
751
+ }) : /* @__PURE__ */ o(x, {
752
+ title: n.empty,
753
+ description: n.emptyHint,
754
+ children: i && /* @__PURE__ */ o(C, {
755
+ variant: "primary",
756
+ onClick: () => a(),
757
+ children: n.open
758
+ })
759
+ });
760
+ }
761
+ //#endregion
762
+ //#region src/pdf-viewer/component.tsx
763
+ function pe(e) {
764
+ let t = r(() => new V(e), [
765
+ e.workerSrc,
766
+ e.documentOptions,
767
+ e.initialPage,
768
+ e.initialZoom,
769
+ e.l10n
770
+ ]);
771
+ return /* @__PURE__ */ o($, {
772
+ ...e,
773
+ controller: t
774
+ });
775
+ }
776
+ function $(e) {
777
+ let { controller: t } = e, [r, c] = n(t.snapshot), [l, u] = n(!1), [d] = n(() => s("rv-pdf-search")), p = a(null), m = a(null), h = a(null), g = a(null), _ = a(null), y = J(e.text), b = r.status === "ready", x = Y(e.toolbar).buttons, S = (e) => {
778
+ let t = x?.[e];
779
+ return t !== !1 && !t?.disabled;
780
+ }, C = X(e.toolbar, "search") && S("search"), w = X(e.toolbar, "open") && S("open");
781
+ t.setCallbacks(e), t.setPrintTitle(y.printDocument), i(() => {
782
+ let n = t.subscribe(c);
783
+ return t.attach(h.current).catch(() => {}), e.onReady?.(t), () => {
784
+ n(), t.destroy();
785
+ };
786
+ }, [t]), i(() => {
787
+ t.load(e.source ?? null, e.fileName);
788
+ }, [
789
+ t,
790
+ e.source,
791
+ e.fileName
792
+ ]);
793
+ let T = () => {
794
+ t.clearSearch(), u(!1);
795
+ let e = p.current;
796
+ e?.isConnected && !e.hasAttribute("disabled") ? e.focus({ preventScroll: !0 }) : h.current?.focus({ preventScroll: !0 });
797
+ }, E = (e) => {
798
+ l || (p.current = e), u(!0), _.current?.focus();
799
+ };
800
+ i(() => {
801
+ C || (t.clearSearch(), u(!1), l && h.current?.focus({ preventScroll: !0 }));
802
+ }, [C, t]);
803
+ let D = {
804
+ controller: t,
805
+ state: r,
806
+ text: y,
807
+ config: e.toolbar,
808
+ searchOpen: l,
809
+ searchId: d,
810
+ appendTo: m.current ?? void 0,
811
+ onOpen: () => g.current?.click(),
812
+ onToggleSearch: (e) => l ? T() : E(e)
813
+ };
814
+ return /* @__PURE__ */ o("section", {
815
+ ref: m,
816
+ class: `rv-pdf-viewer ${e.className ?? ""}`,
817
+ style: { height: e.height ?? 640 },
818
+ "aria-label": y.viewer,
819
+ onKeyDown: (e) => {
820
+ (e.ctrlKey || e.metaKey) && e.key.toLowerCase() === "f" && b && C && (e.preventDefault(), E(e.target));
821
+ },
822
+ children: [
823
+ (e.showHeader !== !1 || r.printing) && /* @__PURE__ */ o(de, {
824
+ showDetails: e.showHeader !== !1,
825
+ state: r,
826
+ text: y,
827
+ onCancelPrint: () => t.cancelPrint()
828
+ }),
829
+ e.toolbar !== !1 && (e.renderToolbar ? e.renderToolbar(t, r, D) : /* @__PURE__ */ o(Q, { ...D })),
830
+ /* @__PURE__ */ o(f, {
831
+ ref: g,
832
+ type: "file",
833
+ accept: "application/pdf,.pdf",
834
+ hidden: !0,
835
+ "aria-label": y.open,
836
+ onChange: (e) => {
837
+ let n = e.currentTarget.files?.[0];
838
+ e.currentTarget.value = "", n && t.load(n);
839
+ }
840
+ }),
841
+ l && C && /* @__PURE__ */ o(ue, {
842
+ inputRef: _,
843
+ id: d,
844
+ controller: t,
845
+ state: r,
846
+ text: y,
847
+ onClose: T
848
+ }),
849
+ /* @__PURE__ */ o("div", {
850
+ class: "rv-pdf-viewer__body",
851
+ "aria-busy": r.status === "loading",
852
+ children: [/* @__PURE__ */ o("div", {
853
+ ref: h,
854
+ class: "rv-pdf-viewer__viewport",
855
+ tabIndex: 0,
856
+ role: "region",
857
+ "aria-label": y.pages
858
+ }), !b && /* @__PURE__ */ o("div", {
859
+ class: "rv-pdf-viewer__status",
860
+ children: e.renderStatus ? e.renderStatus(r) : /* @__PURE__ */ o(fe, {
861
+ state: r,
862
+ text: y,
863
+ controller: t,
864
+ canOpen: w,
865
+ onOpen: D.onOpen
866
+ })
867
+ })]
868
+ }),
869
+ b && r.error && /* @__PURE__ */ o(v, {
870
+ className: "rv-pdf-viewer__error",
871
+ tone: "danger",
872
+ description: y.operationError
873
+ })
874
+ ]
875
+ });
876
+ }
877
+ //#endregion
878
+ export { ie as a, ce as c, U as d, W as f, K as i, le as l, oe as m, $ as n, H as o, ae as p, Q as r, se as s, pe as t, G as u };