@mittwald/flow-remote-vue-components 1.6.0-next.6 → 1.6.0-next.60

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 (433) hide show
  1. package/README.md +2 -2
  2. package/dist/js/RemoteRoot.mjs +1 -2
  3. package/dist/js/components-base/src/action/ActionState.mjs +1 -2
  4. package/dist/js/components-base/src/index.mjs +5 -2
  5. package/dist/js/components-base/src/lib/array.mjs +1 -2
  6. package/dist/js/components-base/src/list/ListModelContext.mjs +1 -2
  7. package/dist/js/components-base/src/list/filter/ListDateRangeFilter.mjs +2 -2
  8. package/dist/js/components-base/src/list/filter/ListDateRangeFilter.mjs.map +1 -1
  9. package/dist/js/components-base/src/list/filter/ListFilter.mjs +5 -3
  10. package/dist/js/components-base/src/list/filter/ListFilter.mjs.map +1 -1
  11. package/dist/js/components-base/src/list/filter/ListFilterValue.mjs +1 -2
  12. package/dist/js/components-base/src/list/filter/dateRange.mjs +38 -15
  13. package/dist/js/components-base/src/list/filter/dateRange.mjs.map +1 -1
  14. package/dist/js/components-base/src/list/filter/dateTimeRangeFields.mjs +52 -0
  15. package/dist/js/components-base/src/list/filter/dateTimeRangeFields.mjs.map +1 -0
  16. package/dist/js/components-base/src/list/filter/formatDateRange.mjs +24 -0
  17. package/dist/js/components-base/src/list/filter/formatDateRange.mjs.map +1 -0
  18. package/dist/js/components-base/src/list/item/ListItem.mjs +1 -2
  19. package/dist/js/components-base/src/list/item/ListItemCollection.mjs +1 -2
  20. package/dist/js/components-base/src/list/loading/ListLoaderState.mjs +11 -7
  21. package/dist/js/components-base/src/list/loading/ListLoaderState.mjs.map +1 -1
  22. package/dist/js/components-base/src/list/loading/types.mjs +1 -2
  23. package/dist/js/components-base/src/list/pagination/ListBatchesController.mjs +1 -2
  24. package/dist/js/components-base/src/list/search/ListSearch.mjs +1 -2
  25. package/dist/js/components-base/src/list/sorting/ListSorting.mjs +1 -2
  26. package/dist/js/components-base/src/list/table/ListTable.mjs +1 -2
  27. package/dist/js/components-base/src/list/viewMode/ListViewMode.mjs +1 -2
  28. package/dist/js/components-base/src/overlay/OverlayState.mjs +193 -0
  29. package/dist/js/components-base/src/overlay/OverlayState.mjs.map +1 -0
  30. package/dist/js/index.mjs +2 -1
  31. package/dist/js/remote-vue-components/src/auto-generated/AccentBox.mjs +1 -2
  32. package/dist/js/remote-vue-components/src/auto-generated/Accordion.mjs +1 -2
  33. package/dist/js/remote-vue-components/src/auto-generated/AccordionGroup.mjs +1 -2
  34. package/dist/js/remote-vue-components/src/auto-generated/ActionGroup.mjs +1 -2
  35. package/dist/js/remote-vue-components/src/auto-generated/Alert.mjs +1 -2
  36. package/dist/js/remote-vue-components/src/auto-generated/AlertBadge.mjs +1 -2
  37. package/dist/js/remote-vue-components/src/auto-generated/AlertIcon.mjs +1 -2
  38. package/dist/js/remote-vue-components/src/auto-generated/AlertText.mjs +1 -2
  39. package/dist/js/remote-vue-components/src/auto-generated/Align.mjs +1 -2
  40. package/dist/js/remote-vue-components/src/auto-generated/Area.mjs +1 -2
  41. package/dist/js/remote-vue-components/src/auto-generated/Autocomplete.mjs +1 -2
  42. package/dist/js/remote-vue-components/src/auto-generated/Avatar.mjs +1 -2
  43. package/dist/js/remote-vue-components/src/auto-generated/AvatarStack.mjs +1 -2
  44. package/dist/js/remote-vue-components/src/auto-generated/Badge.mjs +1 -2
  45. package/dist/js/remote-vue-components/src/auto-generated/Bar.mjs +1 -2
  46. package/dist/js/remote-vue-components/src/auto-generated/BigNumber.mjs +1 -2
  47. package/dist/js/remote-vue-components/src/auto-generated/Breadcrumb.mjs +3 -3
  48. package/dist/js/remote-vue-components/src/auto-generated/Breadcrumb.mjs.map +1 -1
  49. package/dist/js/remote-vue-components/src/auto-generated/Button.mjs +2 -2
  50. package/dist/js/remote-vue-components/src/auto-generated/Button.mjs.map +1 -1
  51. package/dist/js/remote-vue-components/src/auto-generated/CartesianChart.mjs +1 -2
  52. package/dist/js/remote-vue-components/src/auto-generated/CartesianGrid.mjs +1 -2
  53. package/dist/js/remote-vue-components/src/auto-generated/ChartGrid.mjs +1 -2
  54. package/dist/js/remote-vue-components/src/auto-generated/ChartLegend.mjs +1 -2
  55. package/dist/js/remote-vue-components/src/auto-generated/ChartTooltip.mjs +1 -2
  56. package/dist/js/remote-vue-components/src/auto-generated/Chat.mjs +1 -2
  57. package/dist/js/remote-vue-components/src/auto-generated/Checkbox.mjs +3 -3
  58. package/dist/js/remote-vue-components/src/auto-generated/Checkbox.mjs.map +1 -1
  59. package/dist/js/remote-vue-components/src/auto-generated/CheckboxButton.mjs +3 -3
  60. package/dist/js/remote-vue-components/src/auto-generated/CheckboxButton.mjs.map +1 -1
  61. package/dist/js/remote-vue-components/src/auto-generated/CheckboxGroup.mjs +3 -3
  62. package/dist/js/remote-vue-components/src/auto-generated/CheckboxGroup.mjs.map +1 -1
  63. package/dist/js/remote-vue-components/src/auto-generated/ClearPropsContext.mjs +1 -2
  64. package/dist/js/remote-vue-components/src/auto-generated/CoachMark.mjs +3 -3
  65. package/dist/js/remote-vue-components/src/auto-generated/CoachMark.mjs.map +1 -1
  66. package/dist/js/remote-vue-components/src/auto-generated/CodeBlock.mjs +1 -2
  67. package/dist/js/remote-vue-components/src/auto-generated/CodeEditor.mjs +1 -2
  68. package/dist/js/remote-vue-components/src/auto-generated/Color.mjs +1 -2
  69. package/dist/js/remote-vue-components/src/auto-generated/ColumnLayout.mjs +1 -2
  70. package/dist/js/remote-vue-components/src/auto-generated/Combine.mjs +1 -2
  71. package/dist/js/remote-vue-components/src/auto-generated/ComboBox.mjs +3 -3
  72. package/dist/js/remote-vue-components/src/auto-generated/ComboBox.mjs.map +1 -1
  73. package/dist/js/remote-vue-components/src/auto-generated/ComponentPropsContextProvider.mjs +1 -2
  74. package/dist/js/remote-vue-components/src/auto-generated/Content.mjs +1 -2
  75. package/dist/js/remote-vue-components/src/auto-generated/ContextMenu.mjs +3 -3
  76. package/dist/js/remote-vue-components/src/auto-generated/ContextMenu.mjs.map +1 -1
  77. package/dist/js/remote-vue-components/src/auto-generated/ContextMenuContent.mjs +3 -3
  78. package/dist/js/remote-vue-components/src/auto-generated/ContextMenuContent.mjs.map +1 -1
  79. package/dist/js/remote-vue-components/src/auto-generated/ContextMenuSection.mjs +1 -2
  80. package/dist/js/remote-vue-components/src/auto-generated/ContextMenuTrigger.mjs +1 -2
  81. package/dist/js/remote-vue-components/src/auto-generated/ContextualHelp.mjs +3 -3
  82. package/dist/js/remote-vue-components/src/auto-generated/ContextualHelp.mjs.map +1 -1
  83. package/dist/js/remote-vue-components/src/auto-generated/ContextualHelpTrigger.mjs +1 -2
  84. package/dist/js/remote-vue-components/src/auto-generated/CopyButton.mjs +2 -2
  85. package/dist/js/remote-vue-components/src/auto-generated/CopyButton.mjs.map +1 -1
  86. package/dist/js/remote-vue-components/src/auto-generated/CounterBadge.mjs +1 -2
  87. package/dist/js/remote-vue-components/src/auto-generated/DatePicker.mjs +3 -3
  88. package/dist/js/remote-vue-components/src/auto-generated/DatePicker.mjs.map +1 -1
  89. package/dist/js/remote-vue-components/src/auto-generated/DateRangePicker.mjs +2 -2
  90. package/dist/js/remote-vue-components/src/auto-generated/DateRangePicker.mjs.map +1 -1
  91. package/dist/js/remote-vue-components/src/auto-generated/DialogTrigger.mjs +1 -2
  92. package/dist/js/remote-vue-components/src/auto-generated/Div.mjs +1 -2
  93. package/dist/js/remote-vue-components/src/auto-generated/DonutChart.mjs +3 -3
  94. package/dist/js/remote-vue-components/src/auto-generated/DonutChart.mjs.map +1 -1
  95. package/dist/js/remote-vue-components/src/auto-generated/FieldDescription.mjs +1 -2
  96. package/dist/js/remote-vue-components/src/auto-generated/FieldError.mjs +3 -3
  97. package/dist/js/remote-vue-components/src/auto-generated/FieldError.mjs.map +1 -1
  98. package/dist/js/remote-vue-components/src/auto-generated/FileCard.mjs +1 -2
  99. package/dist/js/remote-vue-components/src/auto-generated/FileCardList.mjs +1 -2
  100. package/dist/js/remote-vue-components/src/auto-generated/FileDropZone.mjs +1 -2
  101. package/dist/js/remote-vue-components/src/auto-generated/FileField.mjs +1 -2
  102. package/dist/js/remote-vue-components/src/auto-generated/Flex.mjs +1 -2
  103. package/dist/js/remote-vue-components/src/auto-generated/Header.mjs +1 -2
  104. package/dist/js/remote-vue-components/src/auto-generated/HeaderNavigation.mjs +1 -2
  105. package/dist/js/remote-vue-components/src/auto-generated/Heading.mjs +1 -2
  106. package/dist/js/remote-vue-components/src/auto-generated/Icon.mjs +1 -2
  107. package/dist/js/remote-vue-components/src/auto-generated/IllustratedMessage.mjs +1 -2
  108. package/dist/js/remote-vue-components/src/auto-generated/Image.mjs +1 -2
  109. package/dist/js/remote-vue-components/src/auto-generated/ImageCropper.mjs +1 -2
  110. package/dist/js/remote-vue-components/src/auto-generated/Initials.mjs +1 -2
  111. package/dist/js/remote-vue-components/src/auto-generated/InlineCode.mjs +1 -2
  112. package/dist/js/remote-vue-components/src/auto-generated/ItemsGridList.mjs +3 -3
  113. package/dist/js/remote-vue-components/src/auto-generated/ItemsGridList.mjs.map +1 -1
  114. package/dist/js/remote-vue-components/src/auto-generated/ItemsGridListItem.mjs +3 -3
  115. package/dist/js/remote-vue-components/src/auto-generated/ItemsGridListItem.mjs.map +1 -1
  116. package/dist/js/remote-vue-components/src/auto-generated/Kbd.mjs +1 -2
  117. package/dist/js/remote-vue-components/src/auto-generated/Label.mjs +1 -2
  118. package/dist/js/remote-vue-components/src/auto-generated/LabeledValue.mjs +1 -2
  119. package/dist/js/remote-vue-components/src/auto-generated/LayoutCard.mjs +1 -2
  120. package/dist/js/remote-vue-components/src/auto-generated/Legend.mjs +1 -2
  121. package/dist/js/remote-vue-components/src/auto-generated/LightBoxGallery.mjs +1 -2
  122. package/dist/js/remote-vue-components/src/auto-generated/LightBoxGalleryItem.mjs +1 -2
  123. package/dist/js/remote-vue-components/src/auto-generated/Line.mjs +1 -2
  124. package/dist/js/remote-vue-components/src/auto-generated/Link.mjs +2 -2
  125. package/dist/js/remote-vue-components/src/auto-generated/Link.mjs.map +1 -1
  126. package/dist/js/remote-vue-components/src/auto-generated/ListEmptyView.mjs +1 -2
  127. package/dist/js/remote-vue-components/src/auto-generated/ListEmptyViewContainer.mjs +1 -2
  128. package/dist/js/remote-vue-components/src/auto-generated/ListItemViewContent.mjs +1 -2
  129. package/dist/js/remote-vue-components/src/auto-generated/ListSummary.mjs +1 -2
  130. package/dist/js/remote-vue-components/src/auto-generated/LoadingSpinner.mjs +1 -2
  131. package/dist/js/remote-vue-components/src/auto-generated/Markdown.mjs +1 -2
  132. package/dist/js/remote-vue-components/src/auto-generated/MarkdownEditor.mjs +3 -3
  133. package/dist/js/remote-vue-components/src/auto-generated/MarkdownEditor.mjs.map +1 -1
  134. package/dist/js/remote-vue-components/src/auto-generated/MenuItem.mjs +3 -3
  135. package/dist/js/remote-vue-components/src/auto-generated/MenuItem.mjs.map +1 -1
  136. package/dist/js/remote-vue-components/src/auto-generated/MenuTrigger.mjs +1 -2
  137. package/dist/js/remote-vue-components/src/auto-generated/Message.mjs +1 -2
  138. package/dist/js/remote-vue-components/src/auto-generated/MessageSeparator.mjs +1 -2
  139. package/dist/js/remote-vue-components/src/auto-generated/MessageThread.mjs +1 -2
  140. package/dist/js/remote-vue-components/src/auto-generated/Navigation.mjs +1 -2
  141. package/dist/js/remote-vue-components/src/auto-generated/NavigationGroup.mjs +1 -2
  142. package/dist/js/remote-vue-components/src/auto-generated/Notification.mjs +1 -2
  143. package/dist/js/remote-vue-components/src/auto-generated/NumberField.mjs +3 -3
  144. package/dist/js/remote-vue-components/src/auto-generated/NumberField.mjs.map +1 -1
  145. package/dist/js/remote-vue-components/src/auto-generated/Option.mjs +3 -3
  146. package/dist/js/remote-vue-components/src/auto-generated/Option.mjs.map +1 -1
  147. package/dist/js/remote-vue-components/src/auto-generated/OverlayContent.mjs +1 -2
  148. package/dist/js/remote-vue-components/src/auto-generated/PasswordCreationField.mjs +3 -3
  149. package/dist/js/remote-vue-components/src/auto-generated/PasswordCreationField.mjs.map +1 -1
  150. package/dist/js/remote-vue-components/src/auto-generated/PopoverContent.mjs +1 -2
  151. package/dist/js/remote-vue-components/src/auto-generated/ProgressBar.mjs +3 -3
  152. package/dist/js/remote-vue-components/src/auto-generated/ProgressBar.mjs.map +1 -1
  153. package/dist/js/remote-vue-components/src/auto-generated/Radio.mjs +3 -3
  154. package/dist/js/remote-vue-components/src/auto-generated/Radio.mjs.map +1 -1
  155. package/dist/js/remote-vue-components/src/auto-generated/RadioButton.mjs +3 -3
  156. package/dist/js/remote-vue-components/src/auto-generated/RadioButton.mjs.map +1 -1
  157. package/dist/js/remote-vue-components/src/auto-generated/RadioGroup.mjs +3 -3
  158. package/dist/js/remote-vue-components/src/auto-generated/RadioGroup.mjs.map +1 -1
  159. package/dist/js/remote-vue-components/src/auto-generated/RangeCalendar.mjs +2 -2
  160. package/dist/js/remote-vue-components/src/auto-generated/RangeCalendar.mjs.map +1 -1
  161. package/dist/js/remote-vue-components/src/auto-generated/Rating.mjs +3 -3
  162. package/dist/js/remote-vue-components/src/auto-generated/Rating.mjs.map +1 -1
  163. package/dist/js/remote-vue-components/src/auto-generated/RatingSegment.mjs +3 -3
  164. package/dist/js/remote-vue-components/src/auto-generated/RatingSegment.mjs.map +1 -1
  165. package/dist/js/remote-vue-components/src/auto-generated/SearchField.mjs +3 -3
  166. package/dist/js/remote-vue-components/src/auto-generated/SearchField.mjs.map +1 -1
  167. package/dist/js/remote-vue-components/src/auto-generated/Section.mjs +1 -2
  168. package/dist/js/remote-vue-components/src/auto-generated/Segment.mjs +3 -3
  169. package/dist/js/remote-vue-components/src/auto-generated/Segment.mjs.map +1 -1
  170. package/dist/js/remote-vue-components/src/auto-generated/SegmentedControl.mjs +3 -3
  171. package/dist/js/remote-vue-components/src/auto-generated/SegmentedControl.mjs.map +1 -1
  172. package/dist/js/remote-vue-components/src/auto-generated/Select.mjs +3 -3
  173. package/dist/js/remote-vue-components/src/auto-generated/Select.mjs.map +1 -1
  174. package/dist/js/remote-vue-components/src/auto-generated/Separator.mjs +6 -3
  175. package/dist/js/remote-vue-components/src/auto-generated/Separator.mjs.map +1 -1
  176. package/dist/js/remote-vue-components/src/auto-generated/Skeleton.mjs +1 -2
  177. package/dist/js/remote-vue-components/src/auto-generated/SkeletonMode.mjs +1 -2
  178. package/dist/js/remote-vue-components/src/auto-generated/SkeletonText.mjs +1 -2
  179. package/dist/js/remote-vue-components/src/auto-generated/Slider.mjs +3 -3
  180. package/dist/js/remote-vue-components/src/auto-generated/Slider.mjs.map +1 -1
  181. package/dist/js/remote-vue-components/src/auto-generated/Switch.mjs +3 -3
  182. package/dist/js/remote-vue-components/src/auto-generated/Switch.mjs.map +1 -1
  183. package/dist/js/remote-vue-components/src/auto-generated/Tab.mjs +3 -3
  184. package/dist/js/remote-vue-components/src/auto-generated/Tab.mjs.map +1 -1
  185. package/dist/js/remote-vue-components/src/auto-generated/TabNavigation.mjs +1 -2
  186. package/dist/js/remote-vue-components/src/auto-generated/TabTitle.mjs +3 -3
  187. package/dist/js/remote-vue-components/src/auto-generated/TabTitle.mjs.map +1 -1
  188. package/dist/js/remote-vue-components/src/auto-generated/Table.mjs +3 -3
  189. package/dist/js/remote-vue-components/src/auto-generated/Table.mjs.map +1 -1
  190. package/dist/js/remote-vue-components/src/auto-generated/TableBody.mjs +6 -3
  191. package/dist/js/remote-vue-components/src/auto-generated/TableBody.mjs.map +1 -1
  192. package/dist/js/remote-vue-components/src/auto-generated/TableCell.mjs +3 -3
  193. package/dist/js/remote-vue-components/src/auto-generated/TableCell.mjs.map +1 -1
  194. package/dist/js/remote-vue-components/src/auto-generated/TableColumn.mjs +3 -3
  195. package/dist/js/remote-vue-components/src/auto-generated/TableColumn.mjs.map +1 -1
  196. package/dist/js/remote-vue-components/src/auto-generated/TableFooterRow.mjs +3 -3
  197. package/dist/js/remote-vue-components/src/auto-generated/TableFooterRow.mjs.map +1 -1
  198. package/dist/js/remote-vue-components/src/auto-generated/TableHeader.mjs +6 -3
  199. package/dist/js/remote-vue-components/src/auto-generated/TableHeader.mjs.map +1 -1
  200. package/dist/js/remote-vue-components/src/auto-generated/TableRow.mjs +3 -3
  201. package/dist/js/remote-vue-components/src/auto-generated/TableRow.mjs.map +1 -1
  202. package/dist/js/remote-vue-components/src/auto-generated/Tabs.mjs +3 -3
  203. package/dist/js/remote-vue-components/src/auto-generated/Tabs.mjs.map +1 -1
  204. package/dist/js/remote-vue-components/src/auto-generated/Text.mjs +1 -2
  205. package/dist/js/remote-vue-components/src/auto-generated/TextArea.mjs +3 -3
  206. package/dist/js/remote-vue-components/src/auto-generated/TextArea.mjs.map +1 -1
  207. package/dist/js/remote-vue-components/src/auto-generated/TextField.mjs +3 -3
  208. package/dist/js/remote-vue-components/src/auto-generated/TextField.mjs.map +1 -1
  209. package/dist/js/remote-vue-components/src/auto-generated/TimeField.mjs +3 -3
  210. package/dist/js/remote-vue-components/src/auto-generated/TimeField.mjs.map +1 -1
  211. package/dist/js/remote-vue-components/src/auto-generated/Tooltip.mjs +3 -3
  212. package/dist/js/remote-vue-components/src/auto-generated/Tooltip.mjs.map +1 -1
  213. package/dist/js/remote-vue-components/src/auto-generated/TooltipTrigger.mjs +1 -2
  214. package/dist/js/remote-vue-components/src/auto-generated/TranslationProvider.mjs +1 -2
  215. package/dist/js/remote-vue-components/src/auto-generated/Truncate.mjs +1 -2
  216. package/dist/js/remote-vue-components/src/auto-generated/TunnelEntry.mjs +1 -2
  217. package/dist/js/remote-vue-components/src/auto-generated/XAxis.mjs +1 -2
  218. package/dist/js/remote-vue-components/src/auto-generated/YAxis.mjs +1 -2
  219. package/dist/js/remote-vue-components/src/components/Action.mjs +2 -3
  220. package/dist/js/remote-vue-components/src/components/ActionBatch.mjs +1 -2
  221. package/dist/js/remote-vue-components/src/components/BrowserOnly.mjs +1 -2
  222. package/dist/js/remote-vue-components/src/components/CountryOptions.mjs +1 -2
  223. package/dist/js/remote-vue-components/src/components/DeprecationWarningProvider.mjs +16 -11
  224. package/dist/js/remote-vue-components/src/components/DeprecationWarningProvider.mjs.map +1 -1
  225. package/dist/js/remote-vue-components/src/components/Form.mjs +1 -2
  226. package/dist/js/remote-vue-components/src/components/LoadingIndicator.mjs +1 -2
  227. package/dist/js/remote-vue-components/src/components/NotificationProvider.mjs +1 -2
  228. package/dist/js/remote-vue-components/src/components/SettingsProvider.mjs +1 -2
  229. package/dist/js/remote-vue-components/src/components/Wrap.mjs +1 -2
  230. package/dist/js/remote-vue-components/src/composables/remoteContext.mjs +1 -2
  231. package/dist/js/remote-vue-components/src/composables/useComponentUsage.mjs +1 -2
  232. package/dist/js/remote-vue-components/src/composables/useIsMounted.mjs +1 -2
  233. package/dist/js/remote-vue-components/src/composables/useOnChange.mjs +1 -2
  234. package/dist/js/remote-vue-components/src/composables/useWatchPathname.mjs +1 -2
  235. package/dist/js/remote-vue-components/src/icons/IconSetProvider.mjs +1 -2
  236. package/dist/js/remote-vue-components/src/icons/components/IconAI.mjs +1 -2
  237. package/dist/js/remote-vue-components/src/icons/components/IconAIHosting.mjs +1 -2
  238. package/dist/js/remote-vue-components/src/icons/components/IconAnalytics.mjs +1 -2
  239. package/dist/js/remote-vue-components/src/icons/components/IconApp.mjs +1 -2
  240. package/dist/js/remote-vue-components/src/icons/components/IconAscending.mjs +1 -2
  241. package/dist/js/remote-vue-components/src/icons/components/IconAttachment.mjs +1 -2
  242. package/dist/js/remote-vue-components/src/icons/components/IconAutoresponder.mjs +1 -2
  243. package/dist/js/remote-vue-components/src/icons/components/IconBackLink.mjs +1 -2
  244. package/dist/js/remote-vue-components/src/icons/components/IconBackup.mjs +1 -2
  245. package/dist/js/remote-vue-components/src/icons/components/IconBold.mjs +1 -2
  246. package/dist/js/remote-vue-components/src/icons/components/IconCamera.mjs +1 -2
  247. package/dist/js/remote-vue-components/src/icons/components/IconCertificate.mjs +1 -2
  248. package/dist/js/remote-vue-components/src/icons/components/IconChangelog.mjs +1 -2
  249. package/dist/js/remote-vue-components/src/icons/components/IconCheck.mjs +1 -2
  250. package/dist/js/remote-vue-components/src/icons/components/IconCheckboxChecked.mjs +1 -2
  251. package/dist/js/remote-vue-components/src/icons/components/IconCheckboxEmpty.mjs +1 -2
  252. package/dist/js/remote-vue-components/src/icons/components/IconCheckboxIndeterminate.mjs +1 -2
  253. package/dist/js/remote-vue-components/src/icons/components/IconChevronDown.mjs +1 -2
  254. package/dist/js/remote-vue-components/src/icons/components/IconChevronLeft.mjs +1 -2
  255. package/dist/js/remote-vue-components/src/icons/components/IconChevronRight.mjs +1 -2
  256. package/dist/js/remote-vue-components/src/icons/components/IconChevronUp.mjs +1 -2
  257. package/dist/js/remote-vue-components/src/icons/components/IconClose.mjs +1 -2
  258. package/dist/js/remote-vue-components/src/icons/components/IconCode.mjs +1 -2
  259. package/dist/js/remote-vue-components/src/icons/components/IconContainer.mjs +1 -2
  260. package/dist/js/remote-vue-components/src/icons/components/IconContextMenu.mjs +1 -2
  261. package/dist/js/remote-vue-components/src/icons/components/IconContextMenuVertical.mjs +1 -2
  262. package/dist/js/remote-vue-components/src/icons/components/IconContract.mjs +1 -2
  263. package/dist/js/remote-vue-components/src/icons/components/IconContractPartner.mjs +1 -2
  264. package/dist/js/remote-vue-components/src/icons/components/IconContributor.mjs +1 -2
  265. package/dist/js/remote-vue-components/src/icons/components/IconCopy.mjs +1 -2
  266. package/dist/js/remote-vue-components/src/icons/components/IconCronjob.mjs +1 -2
  267. package/dist/js/remote-vue-components/src/icons/components/IconCustomer.mjs +1 -2
  268. package/dist/js/remote-vue-components/src/icons/components/IconDanger.mjs +1 -2
  269. package/dist/js/remote-vue-components/src/icons/components/IconDashboard.mjs +1 -2
  270. package/dist/js/remote-vue-components/src/icons/components/IconDatabase.mjs +1 -2
  271. package/dist/js/remote-vue-components/src/icons/components/IconDate.mjs +1 -2
  272. package/dist/js/remote-vue-components/src/icons/components/IconDelete.mjs +1 -2
  273. package/dist/js/remote-vue-components/src/icons/components/IconDeliveryBox.mjs +1 -2
  274. package/dist/js/remote-vue-components/src/icons/components/IconDescending.mjs +1 -2
  275. package/dist/js/remote-vue-components/src/icons/components/IconDesktop.mjs +1 -2
  276. package/dist/js/remote-vue-components/src/icons/components/IconDirectory.mjs +1 -2
  277. package/dist/js/remote-vue-components/src/icons/components/IconDnsSubZone.mjs +1 -2
  278. package/dist/js/remote-vue-components/src/icons/components/IconDnsZone.mjs +1 -2
  279. package/dist/js/remote-vue-components/src/icons/components/IconDomain.mjs +1 -2
  280. package/dist/js/remote-vue-components/src/icons/components/IconDownload.mjs +1 -2
  281. package/dist/js/remote-vue-components/src/icons/components/IconEdit.mjs +1 -2
  282. package/dist/js/remote-vue-components/src/icons/components/IconEmail.mjs +1 -2
  283. package/dist/js/remote-vue-components/src/icons/components/IconEmailArchive.mjs +1 -2
  284. package/dist/js/remote-vue-components/src/icons/components/IconExtension.mjs +1 -2
  285. package/dist/js/remote-vue-components/src/icons/components/IconExternalLink.mjs +1 -2
  286. package/dist/js/remote-vue-components/src/icons/components/IconFailed.mjs +1 -2
  287. package/dist/js/remote-vue-components/src/icons/components/IconFeedback.mjs +1 -2
  288. package/dist/js/remote-vue-components/src/icons/components/IconFile.mjs +1 -2
  289. package/dist/js/remote-vue-components/src/icons/components/IconFilter.mjs +1 -2
  290. package/dist/js/remote-vue-components/src/icons/components/IconForwardAddress.mjs +1 -2
  291. package/dist/js/remote-vue-components/src/icons/components/IconForwardLink.mjs +1 -2
  292. package/dist/js/remote-vue-components/src/icons/components/IconHide.mjs +1 -2
  293. package/dist/js/remote-vue-components/src/icons/components/IconHome.mjs +1 -2
  294. package/dist/js/remote-vue-components/src/icons/components/IconImage.mjs +1 -2
  295. package/dist/js/remote-vue-components/src/icons/components/IconInfo.mjs +1 -2
  296. package/dist/js/remote-vue-components/src/icons/components/IconInvite.mjs +1 -2
  297. package/dist/js/remote-vue-components/src/icons/components/IconInvoice.mjs +1 -2
  298. package/dist/js/remote-vue-components/src/icons/components/IconItalic.mjs +1 -2
  299. package/dist/js/remote-vue-components/src/icons/components/IconKnowledgeHint.mjs +1 -2
  300. package/dist/js/remote-vue-components/src/icons/components/IconLanguage.mjs +1 -2
  301. package/dist/js/remote-vue-components/src/icons/components/IconLeadFyndr.mjs +1 -2
  302. package/dist/js/remote-vue-components/src/icons/components/IconLink.mjs +1 -2
  303. package/dist/js/remote-vue-components/src/icons/components/IconLock.mjs +1 -2
  304. package/dist/js/remote-vue-components/src/icons/components/IconLockOpen.mjs +1 -2
  305. package/dist/js/remote-vue-components/src/icons/components/IconLogout.mjs +1 -2
  306. package/dist/js/remote-vue-components/src/icons/components/IconMainUser.mjs +1 -2
  307. package/dist/js/remote-vue-components/src/icons/components/IconMarketplace.mjs +1 -2
  308. package/dist/js/remote-vue-components/src/icons/components/IconMaximize.mjs +1 -2
  309. package/dist/js/remote-vue-components/src/icons/components/IconMember.mjs +1 -2
  310. package/dist/js/remote-vue-components/src/icons/components/IconMenu.mjs +1 -2
  311. package/dist/js/remote-vue-components/src/icons/components/IconMinimize.mjs +1 -2
  312. package/dist/js/remote-vue-components/src/icons/components/IconMinus.mjs +1 -2
  313. package/dist/js/remote-vue-components/src/icons/components/IconMittwald.mjs +1 -2
  314. package/dist/js/remote-vue-components/src/icons/components/IconMobile.mjs +1 -2
  315. package/dist/js/remote-vue-components/src/icons/components/IconMonitoring.mjs +1 -2
  316. package/dist/js/remote-vue-components/src/icons/components/IconMove.mjs +1 -2
  317. package/dist/js/remote-vue-components/src/icons/components/IconNewsletter.mjs +1 -2
  318. package/dist/js/remote-vue-components/src/icons/components/IconNotification.mjs +1 -2
  319. package/dist/js/remote-vue-components/src/icons/components/IconNumber.mjs +1 -2
  320. package/dist/js/remote-vue-components/src/icons/components/IconOrder.mjs +1 -2
  321. package/dist/js/remote-vue-components/src/icons/components/IconOrderedList.mjs +1 -2
  322. package/dist/js/remote-vue-components/src/icons/components/IconPassword.mjs +1 -2
  323. package/dist/js/remote-vue-components/src/icons/components/IconPath.mjs +1 -2
  324. package/dist/js/remote-vue-components/src/icons/components/IconPause.mjs +1 -2
  325. package/dist/js/remote-vue-components/src/icons/components/IconPayment.mjs +1 -2
  326. package/dist/js/remote-vue-components/src/icons/components/IconPending.mjs +1 -2
  327. package/dist/js/remote-vue-components/src/icons/components/IconPicture.mjs +1 -2
  328. package/dist/js/remote-vue-components/src/icons/components/IconPlus.mjs +1 -2
  329. package/dist/js/remote-vue-components/src/icons/components/IconProject.mjs +1 -2
  330. package/dist/js/remote-vue-components/src/icons/components/IconQuote.mjs +1 -2
  331. package/dist/js/remote-vue-components/src/icons/components/IconRadioOff.mjs +1 -2
  332. package/dist/js/remote-vue-components/src/icons/components/IconRadioOn.mjs +1 -2
  333. package/dist/js/remote-vue-components/src/icons/components/IconRedo.mjs +1 -2
  334. package/dist/js/remote-vue-components/src/icons/components/IconRefresh.mjs +1 -2
  335. package/dist/js/remote-vue-components/src/icons/components/IconRegistry.mjs +1 -2
  336. package/dist/js/remote-vue-components/src/icons/components/IconSave.mjs +1 -2
  337. package/dist/js/remote-vue-components/src/icons/components/IconSearch.mjs +1 -2
  338. package/dist/js/remote-vue-components/src/icons/components/IconSecurity.mjs +1 -2
  339. package/dist/js/remote-vue-components/src/icons/components/IconSend.mjs +1 -2
  340. package/dist/js/remote-vue-components/src/icons/components/IconServer.mjs +1 -2
  341. package/dist/js/remote-vue-components/src/icons/components/IconSettings.mjs +1 -2
  342. package/dist/js/remote-vue-components/src/icons/components/IconShare.mjs +1 -2
  343. package/dist/js/remote-vue-components/src/icons/components/IconShow.mjs +1 -2
  344. package/dist/js/remote-vue-components/src/icons/components/IconSorting.mjs +1 -2
  345. package/dist/js/remote-vue-components/src/icons/components/IconSsh.mjs +1 -2
  346. package/dist/js/remote-vue-components/src/icons/components/IconSshKey.mjs +1 -2
  347. package/dist/js/remote-vue-components/src/icons/components/IconSshSftp.mjs +1 -2
  348. package/dist/js/remote-vue-components/src/icons/components/IconStack.mjs +1 -2
  349. package/dist/js/remote-vue-components/src/icons/components/IconStar.mjs +1 -2
  350. package/dist/js/remote-vue-components/src/icons/components/IconStarFilled.mjs +1 -2
  351. package/dist/js/remote-vue-components/src/icons/components/IconStart.mjs +1 -2
  352. package/dist/js/remote-vue-components/src/icons/components/IconStrikeThrough.mjs +1 -2
  353. package/dist/js/remote-vue-components/src/icons/components/IconSubdomain.mjs +1 -2
  354. package/dist/js/remote-vue-components/src/icons/components/IconSucceeded.mjs +1 -2
  355. package/dist/js/remote-vue-components/src/icons/components/IconSuccess.mjs +1 -2
  356. package/dist/js/remote-vue-components/src/icons/components/IconSupport.mjs +1 -2
  357. package/dist/js/remote-vue-components/src/icons/components/IconTerminate.mjs +1 -2
  358. package/dist/js/remote-vue-components/src/icons/components/IconTicket.mjs +1 -2
  359. package/dist/js/remote-vue-components/src/icons/components/IconTime.mjs +1 -2
  360. package/dist/js/remote-vue-components/src/icons/components/IconUnavailable.mjs +1 -2
  361. package/dist/js/remote-vue-components/src/icons/components/IconUndo.mjs +1 -2
  362. package/dist/js/remote-vue-components/src/icons/components/IconUnorderedList.mjs +1 -2
  363. package/dist/js/remote-vue-components/src/icons/components/IconUpload.mjs +1 -2
  364. package/dist/js/remote-vue-components/src/icons/components/IconUser.mjs +1 -2
  365. package/dist/js/remote-vue-components/src/icons/components/IconVhost.mjs +1 -2
  366. package/dist/js/remote-vue-components/src/icons/components/IconView.mjs +1 -2
  367. package/dist/js/remote-vue-components/src/icons/components/IconVolume.mjs +1 -2
  368. package/dist/js/remote-vue-components/src/icons/components/IconWarning.mjs +1 -2
  369. package/dist/js/remote-vue-components/src/icons/lib/createIcon.mjs +1 -2
  370. package/dist/js/remote-vue-components/src/lib/composition.mjs +1 -2
  371. package/dist/js/remote-vue-components/src/lib/controlledRemoteValue.mjs +1 -2
  372. package/dist/js/remote-vue-components/src/lib/createFlowRemoteComponent.mjs +1 -2
  373. package/dist/js/remote-vue-components/src/lib/handlers.mjs +1 -2
  374. package/dist/js/remote-vue-components/src/lib/isRenderError.mjs +1 -2
  375. package/dist/js/remote-vue-components/src/lib/mobxSelector.mjs +1 -2
  376. package/dist/js/remote-vue-components/src/lib/propKeys.mjs +1 -2
  377. package/dist/js/remote-vue-components/src/lib/stringifyError.mjs +1 -2
  378. package/dist/js/remote-vue-components/src/lib/vModel.mjs +1 -2
  379. package/dist/js/remote-vue-components/src/list/ActiveFilters.mjs +6 -4
  380. package/dist/js/remote-vue-components/src/list/ActiveFilters.mjs.map +1 -1
  381. package/dist/js/remote-vue-components/src/list/AllFiltersModal.mjs +4 -4
  382. package/dist/js/remote-vue-components/src/list/AllFiltersModal.mjs.map +1 -1
  383. package/dist/js/remote-vue-components/src/list/ComposableLoader.mjs +1 -2
  384. package/dist/js/remote-vue-components/src/list/DateTimeRangeFields.mjs +99 -0
  385. package/dist/js/remote-vue-components/src/list/DateTimeRangeFields.mjs.map +1 -0
  386. package/dist/js/remote-vue-components/src/list/Footer.mjs +1 -2
  387. package/dist/js/remote-vue-components/src/list/Header.mjs +13 -9
  388. package/dist/js/remote-vue-components/src/list/Header.mjs.map +1 -1
  389. package/dist/js/remote-vue-components/src/list/Item.mjs +1 -2
  390. package/dist/js/remote-vue-components/src/list/Items.mjs +1 -2
  391. package/dist/js/remote-vue-components/src/list/List.mjs +1 -2
  392. package/dist/js/remote-vue-components/src/list/ListItemView.mjs +1 -2
  393. package/dist/js/remote-vue-components/src/list/Table.mjs +1 -2
  394. package/dist/js/remote-vue-components/src/list/dateRangeFilter.mjs +15 -8
  395. package/dist/js/remote-vue-components/src/list/dateRangeFilter.mjs.map +1 -1
  396. package/dist/js/remote-vue-components/src/list/itemContext.mjs +1 -2
  397. package/dist/js/remote-vue-components/src/list/listContext.mjs +1 -2
  398. package/dist/js/remote-vue-components/src/list/locales.mjs +15 -2
  399. package/dist/js/remote-vue-components/src/list/locales.mjs.map +1 -1
  400. package/dist/js/remote-vue-components/src/list/metadata.mjs +1 -2
  401. package/dist/js/remote-vue-components/src/list/model.mjs +1 -2
  402. package/dist/js/remote-vue-components/src/list/settings.mjs +1 -2
  403. package/dist/js/remote-vue-components/src/list/setupComponents.mjs +1 -2
  404. package/dist/js/remote-vue-components/src/list/styles.mjs +8 -3
  405. package/dist/js/remote-vue-components/src/list/styles.mjs.map +1 -1
  406. package/dist/js/remote-vue-components/src/overlays/LightBox.mjs +1 -2
  407. package/dist/js/remote-vue-components/src/overlays/Modal.mjs +15 -20
  408. package/dist/js/remote-vue-components/src/overlays/Modal.mjs.map +1 -1
  409. package/dist/js/remote-vue-components/src/overlays/Popover.mjs +1 -2
  410. package/dist/js/remote-vue-components/src/overlays/childProps.mjs +1 -2
  411. package/dist/js/remote-vue-components/src/overlays/createOverlayTrigger.mjs +1 -2
  412. package/dist/js/remote-vue-components/src/overlays/locales.mjs +1 -2
  413. package/dist/js/remote-vue-components/src/overlays/overlayController.mjs +58 -65
  414. package/dist/js/remote-vue-components/src/overlays/overlayController.mjs.map +1 -1
  415. package/dist/js/remote-vue-components/src/overlays/triggers.mjs +1 -2
  416. package/dist/js/remote-vue-components/src/version.mjs +2 -3
  417. package/dist/types/_bundled/flow-components-base/index.d.ts +4 -1
  418. package/dist/types/_bundled/flow-components-base/list/filter/ListFilter.d.ts +2 -0
  419. package/dist/types/_bundled/flow-components-base/list/filter/dateRange.d.ts +24 -1
  420. package/dist/types/_bundled/flow-components-base/list/filter/dateTimeRangeFields.d.ts +34 -0
  421. package/dist/types/_bundled/flow-components-base/list/filter/formatDateRange.d.ts +7 -0
  422. package/dist/types/_bundled/flow-components-base/list/loading/ListLoaderState.d.ts +5 -0
  423. package/dist/types/_bundled/flow-components-base/overlay/OverlayState.d.ts +94 -0
  424. package/dist/types/components/DeprecationWarningProvider.d.ts +2 -4
  425. package/dist/types/list/DateTimeRangeFields.d.ts +43 -0
  426. package/dist/types/list/dateRangeFilter.d.ts +6 -6
  427. package/dist/types/list/index.d.ts +1 -0
  428. package/dist/types/list/locales.d.ts +14 -0
  429. package/dist/types/list/styles.d.ts +6 -0
  430. package/dist/types/list/types.d.ts +8 -2
  431. package/dist/types/overlays/Modal.d.ts +2 -2
  432. package/dist/types/overlays/overlayController.d.ts +28 -18
  433. package/package.json +14 -14
@@ -0,0 +1,99 @@
1
+ import { composition } from "../lib/composition.mjs";
2
+ import { DatePicker } from "../auto-generated/DatePicker.mjs";
3
+ import { Div } from "../auto-generated/Div.mjs";
4
+ import { FieldError } from "../auto-generated/FieldError.mjs";
5
+ import { Label } from "../auto-generated/Label.mjs";
6
+ import { TimeField } from "../auto-generated/TimeField.mjs";
7
+ import watchMobxValue from "../lib/mobxSelector.mjs";
8
+ import { getListDateTimeRangeUpdate, isListDateTimeRangeEndBeforeStart, listDateTimeRangeFieldsFromValue, toListCalendarDate, toListTime } from "../../../components-base/src/list/filter/dateTimeRangeFields.mjs";
9
+ import "../../../components-base/src/index.mjs";
10
+ import { injectListModel } from "./listContext.mjs";
11
+ import { useListTexts } from "./locales.mjs";
12
+ import { className, dateTimeRangeStyles } from "./styles.mjs";
13
+ import { defineComponent, h, shallowRef, useId, watch } from "vue";
14
+ // src/list/DateTimeRangeFields.ts
15
+ /**
16
+ * Flow's `DateTimeRangeFields`: start and end, each a date and a time, for a
17
+ * filter with `granularity: "minute"`.
18
+ *
19
+ * Which input is valid and when it applies is `components-base`'s
20
+ * (`getListDateTimeRangeUpdate`), so both bindings apply the same ranges. What
21
+ * is held here is the input itself, which may be invalid for a while — a year
22
+ * typed digit by digit, an end before its start — while the filter keeps the
23
+ * last valid range.
24
+ */
25
+ var DateTimeRangeFields = defineComponent({
26
+ name: "ListDateTimeRangeFields",
27
+ props: {
28
+ filter: {
29
+ type: Object,
30
+ required: true
31
+ },
32
+ class: {
33
+ type: String,
34
+ default: void 0
35
+ }
36
+ },
37
+ setup(props) {
38
+ const list = injectListModel();
39
+ const texts = useListTexts();
40
+ const rangeErrorId = useId();
41
+ const tableRevision = watchMobxValue(() => list.listTable.revision);
42
+ let appliedValue = props.filter.getValue();
43
+ const fields = shallowRef(listDateTimeRangeFieldsFromValue(appliedValue));
44
+ watch(tableRevision, () => {
45
+ const value = props.filter.getValue();
46
+ if (value !== appliedValue) {
47
+ appliedValue = value;
48
+ fields.value = listDateTimeRangeFieldsFromValue(value);
49
+ }
50
+ });
51
+ const update = (change) => {
52
+ const next = {
53
+ ...fields.value,
54
+ ...change
55
+ };
56
+ fields.value = next;
57
+ const newValue = getListDateTimeRangeUpdate(next, appliedValue, props.filter.dateTimeRangeLimits);
58
+ if (newValue === void 0) return;
59
+ appliedValue = newValue;
60
+ if (newValue) props.filter.setValue(newValue);
61
+ else props.filter.clear();
62
+ };
63
+ const label = (key) => () => h(Label, { optional: false }, () => texts.value(key));
64
+ return () => {
65
+ const limits = props.filter.dateTimeRangeLimits;
66
+ const minValue = toListCalendarDate(limits?.minValue);
67
+ const maxValue = toListCalendarDate(limits?.maxValue);
68
+ const hasRangeError = isListDateTimeRangeEndBeforeStart(fields.value);
69
+ const describedBy = hasRangeError ? rangeErrorId : void 0;
70
+ const datePicker = (side, labelKey) => h(DatePicker, {
71
+ value: fields.value[side],
72
+ onChange: (date) => update({ [side]: toListCalendarDate(date) }),
73
+ minValue,
74
+ maxValue,
75
+ "aria-describedby": describedBy,
76
+ isDateUnavailable: limits?.isDateUnavailable
77
+ }, () => [label(labelKey)(), h(FieldError)]);
78
+ const timeField = (side, labelKey) => h(TimeField, {
79
+ value: fields.value[side],
80
+ onChange: (time) => update({ [side]: toListTime(time) }),
81
+ "aria-describedby": describedBy
82
+ }, label(labelKey));
83
+ return h(Div, { class: className(dateTimeRangeStyles.fields, props.class) }, () => [
84
+ datePicker("startDate", "dateRange.startDate"),
85
+ timeField("startTime", "dateRange.startTime"),
86
+ datePicker("endDate", "dateRange.endDate"),
87
+ timeField("endTime", "dateRange.endTime"),
88
+ hasRangeError ? h(FieldError, {
89
+ id: rangeErrorId,
90
+ class: dateTimeRangeStyles.rangeError
91
+ }, () => texts.value("dateRange.endBeforeStart")) : null
92
+ ]);
93
+ };
94
+ }
95
+ });
96
+ composition(DateTimeRangeFields);
97
+ export { DateTimeRangeFields, DateTimeRangeFields as default };
98
+
99
+ //# sourceMappingURL=DateTimeRangeFields.mjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"DateTimeRangeFields.mjs","names":[],"sources":["../../../../../src/list/DateTimeRangeFields.ts"],"sourcesContent":["import {\n DatePicker,\n Div,\n FieldError,\n Label,\n TimeField,\n} from \"@/auto-generated\";\nimport { watchMobxValue } from \"@/lib/mobxSelector\";\nimport {\n getListDateTimeRangeUpdate,\n isListDateTimeRangeEndBeforeStart,\n listDateTimeRangeFieldsFromValue,\n toListCalendarDate,\n toListTime,\n type ListDateRange,\n type ListDateTimeRangeFields,\n type ListDateTimeRangeLimits,\n} from \"@mittwald/flow-components-base\";\nimport {\n defineComponent,\n h,\n shallowRef,\n useId,\n watch,\n type PropType,\n} from \"vue\";\nimport { composition } from \"@/lib/composition\";\nimport { injectListModel } from \"./listContext\";\nimport { useListTexts, type ListTextKey } from \"./locales\";\nimport { className, dateTimeRangeStyles } from \"./styles\";\n\n/** What the fields need of a date-range filter, and nothing more. */\nexport interface DateTimeRangeFilter {\n readonly dateTimeRangeLimits?: ListDateTimeRangeLimits;\n getValue(): ListDateRange | null;\n setValue(range: ListDateRange): void;\n clear(): void;\n}\n\n/**\n * Flow's `DateTimeRangeFields`: start and end, each a date and a time, for a\n * filter with `granularity: \"minute\"`.\n *\n * Which input is valid and when it applies is `components-base`'s\n * (`getListDateTimeRangeUpdate`), so both bindings apply the same ranges. What\n * is held here is the input itself, which may be invalid for a while — a year\n * typed digit by digit, an end before its start — while the filter keeps the\n * last valid range.\n */\nexport const DateTimeRangeFields = defineComponent({\n name: \"ListDateTimeRangeFields\",\n\n props: {\n filter: {\n type: Object as PropType<DateTimeRangeFilter>,\n required: true,\n },\n class: { type: String, default: undefined },\n },\n\n setup(props) {\n const list = injectListModel();\n const texts = useListTexts();\n const rangeErrorId = useId();\n\n /* The filter's value is table state, read through the table's revision. */\n const tableRevision = watchMobxValue(() => list.listTable.revision);\n\n let appliedValue = props.filter.getValue();\n const fields = shallowRef(listDateTimeRangeFieldsFromValue(appliedValue));\n\n /* A range set elsewhere — the chip, \"Reset filters\" — replaces the input. */\n watch(tableRevision, () => {\n const value = props.filter.getValue();\n if (value !== appliedValue) {\n appliedValue = value;\n fields.value = listDateTimeRangeFieldsFromValue(value);\n }\n });\n\n const update = (change: Partial<ListDateTimeRangeFields>) => {\n const next = { ...fields.value, ...change };\n fields.value = next;\n\n const newValue = getListDateTimeRangeUpdate(\n next,\n appliedValue,\n props.filter.dateTimeRangeLimits,\n );\n if (newValue === undefined) {\n return;\n }\n\n appliedValue = newValue;\n\n if (newValue) {\n props.filter.setValue(newValue);\n } else {\n props.filter.clear();\n }\n };\n\n const label = (key: ListTextKey) => () =>\n h(Label, { optional: false }, () => texts.value(key));\n\n return () => {\n const limits = props.filter.dateTimeRangeLimits;\n const minValue = toListCalendarDate(limits?.minValue);\n const maxValue = toListCalendarDate(limits?.maxValue);\n const hasRangeError = isListDateTimeRangeEndBeforeStart(fields.value);\n const describedBy = hasRangeError ? rangeErrorId : undefined;\n\n const datePicker = (\n side: \"startDate\" | \"endDate\",\n labelKey: ListTextKey,\n ) =>\n h(\n DatePicker,\n {\n value: fields.value[side],\n onChange: (date: Parameters<typeof toListCalendarDate>[0]) =>\n update({ [side]: toListCalendarDate(date) }),\n minValue,\n maxValue,\n \"aria-describedby\": describedBy,\n isDateUnavailable: limits?.isDateUnavailable,\n } as never,\n () => [label(labelKey)(), h(FieldError)],\n );\n\n const timeField = (\n side: \"startTime\" | \"endTime\",\n labelKey: ListTextKey,\n ) =>\n h(\n TimeField,\n {\n value: fields.value[side],\n onChange: (time: Parameters<typeof toListTime>[0]) =>\n update({ [side]: toListTime(time) }),\n \"aria-describedby\": describedBy,\n } as never,\n label(labelKey),\n );\n\n return h(\n Div,\n { class: className(dateTimeRangeStyles.fields, props.class) },\n () => [\n datePicker(\"startDate\", \"dateRange.startDate\"),\n timeField(\"startTime\", \"dateRange.startTime\"),\n datePicker(\"endDate\", \"dateRange.endDate\"),\n timeField(\"endTime\", \"dateRange.endTime\"),\n hasRangeError\n ? h(\n FieldError,\n { id: rangeErrorId, class: dateTimeRangeStyles.rangeError },\n () => texts.value(\"dateRange.endBeforeStart\"),\n )\n : null,\n ],\n );\n };\n },\n});\n\ncomposition(DateTimeRangeFields);\n\nexport default DateTimeRangeFields;\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;AAiDA,IAAa,sBAAsB,gBAAgB;CACjD,MAAM;CAEN,OAAO;EACL,QAAQ;GACN,MAAM;GACN,UAAU;EACZ;EACA,OAAO;GAAE,MAAM;GAAQ,SAAS,KAAA;EAAU;CAC5C;CAEA,MAAM,OAAO;EACX,MAAM,OAAO,gBAAgB;EAC7B,MAAM,QAAQ,aAAa;EAC3B,MAAM,eAAe,MAAM;EAG3B,MAAM,gBAAgB,qBAAqB,KAAK,UAAU,QAAQ;EAElE,IAAI,eAAe,MAAM,OAAO,SAAS;EACzC,MAAM,SAAS,WAAW,iCAAiC,YAAY,CAAC;EAGxE,MAAM,qBAAqB;GACzB,MAAM,QAAQ,MAAM,OAAO,SAAS;GACpC,IAAI,UAAU,cAAc;IAC1B,eAAe;IACf,OAAO,QAAQ,iCAAiC,KAAK;GACvD;EACF,CAAC;EAED,MAAM,UAAU,WAA6C;GAC3D,MAAM,OAAO;IAAE,GAAG,OAAO;IAAO,GAAG;GAAO;GAC1C,OAAO,QAAQ;GAEf,MAAM,WAAW,2BACf,MACA,cACA,MAAM,OAAO,mBACf;GACA,IAAI,aAAa,KAAA,GACf;GAGF,eAAe;GAEf,IAAI,UACF,MAAM,OAAO,SAAS,QAAQ;QAE9B,MAAM,OAAO,MAAM;EAEvB;EAEA,MAAM,SAAS,cACb,EAAE,OAAO,EAAE,UAAU,MAAM,SAAS,MAAM,MAAM,GAAG,CAAC;EAEtD,aAAa;GACX,MAAM,SAAS,MAAM,OAAO;GAC5B,MAAM,WAAW,mBAAmB,QAAQ,QAAQ;GACpD,MAAM,WAAW,mBAAmB,QAAQ,QAAQ;GACpD,MAAM,gBAAgB,kCAAkC,OAAO,KAAK;GACpE,MAAM,cAAc,gBAAgB,eAAe,KAAA;GAEnD,MAAM,cACJ,MACA,aAEA,EACE,YACA;IACE,OAAO,OAAO,MAAM;IACpB,WAAW,SACT,OAAO,GAAG,OAAO,mBAAmB,IAAI,EAAE,CAAC;IAC7C;IACA;IACA,oBAAoB;IACpB,mBAAmB,QAAQ;GAC7B,SACM,CAAC,MAAM,QAAQ,CAAC,CAAC,GAAG,EAAE,UAAU,CAAC,CACzC;GAEF,MAAM,aACJ,MACA,aAEA,EACE,WACA;IACE,OAAO,OAAO,MAAM;IACpB,WAAW,SACT,OAAO,GAAG,OAAO,WAAW,IAAI,EAAE,CAAC;IACrC,oBAAoB;GACtB,GACA,MAAM,QAAQ,CAChB;GAEF,OAAO,EACL,KACA,EAAE,OAAO,UAAU,oBAAoB,QAAQ,MAAM,KAAK,EAAE,SACtD;IACJ,WAAW,aAAa,qBAAqB;IAC7C,UAAU,aAAa,qBAAqB;IAC5C,WAAW,WAAW,mBAAmB;IACzC,UAAU,WAAW,mBAAmB;IACxC,gBACI,EACE,YACA;KAAE,IAAI;KAAc,OAAO,oBAAoB;IAAW,SACpD,MAAM,MAAM,0BAA0B,CAC9C,IACA;GACN,CACF;EACF;CACF;AACF,CAAC;AAED,YAAY,mBAAmB"}
@@ -8,7 +8,7 @@ import { injectListModel } from "./listContext.mjs";
8
8
  import { useListTexts } from "./locales.mjs";
9
9
  import { listStyles } from "./styles.mjs";
10
10
  import { defineComponent, h } from "vue";
11
- //#region src/list/Footer.ts
11
+ // src/list/Footer.ts
12
12
  /** How many items are shown, and the way to ask for more. */
13
13
  var Footer = defineComponent({
14
14
  name: "ListFooter",
@@ -47,7 +47,6 @@ var Footer = defineComponent({
47
47
  }
48
48
  });
49
49
  composition(Footer);
50
- //#endregion
51
50
  export { Footer, Footer as default };
52
51
 
53
52
  //# sourceMappingURL=Footer.mjs.map
@@ -16,16 +16,16 @@ import watchMobxValue from "../lib/mobxSelector.mjs";
16
16
  import { createOverlayController } from "../overlays/overlayController.mjs";
17
17
  import { injectListModel } from "./listContext.mjs";
18
18
  import { useListTexts } from "./locales.mjs";
19
- import { listStyles } from "./styles.mjs";
19
+ import { dateTimeRangeStyles, listStyles } from "./styles.mjs";
20
20
  import { Popover } from "../overlays/Popover.mjs";
21
21
  import { PopoverTrigger } from "../overlays/triggers.mjs";
22
22
  import { isDateRangeFilter } from "./dateRangeFilter.mjs";
23
23
  import { ActiveFilters } from "./ActiveFilters.mjs";
24
+ import { DateTimeRangeFields } from "./DateTimeRangeFields.mjs";
24
25
  import { AllFiltersModal } from "./AllFiltersModal.mjs";
25
26
  import { defineComponent, h, onBeforeUnmount, ref, watch } from "vue";
26
- //#region src/list/Header.ts
27
+ // src/list/Header.ts
27
28
  var autoSubmitTimeout = 500;
28
- var dateRangeCalendarClass = "flow--list--header--filter-context-menu--calendar";
29
29
  var availableViewModes = (shape) => {
30
30
  const modes = [];
31
31
  if (shape.itemView?.showList) modes.push("list");
@@ -67,11 +67,12 @@ var renderSortingMenu = (list, texts, isDisabled) => {
67
67
  }, () => `${sorting.name ?? String(sorting.property)} ${sorting.directionName ?? ""}`.trim())))]);
68
68
  };
69
69
  /**
70
- * A date-range filter is a calendar in a popover, not a menu of values.
70
+ * A date-range filter is a calendar in a popover, not a menu of values — or,
71
+ * with `granularity: "minute"`, date and time fields.
71
72
  *
72
73
  * The same shape Flow's React list gives it — the calendar closes the popover
73
74
  * when a range is picked, because a range is complete the moment its second end
74
- * is.
75
+ * is. The fields leave it open: they apply as they are typed.
75
76
  */
76
77
  var renderDateRangeFilter = (filter, isDisabled, calendarLabel, controller) => h(PopoverTrigger, {
77
78
  key: filter.storageKey,
@@ -80,9 +81,12 @@ var renderDateRangeFilter = (filter, isDisabled, calendarLabel, controller) => h
80
81
  placement: "bottom end",
81
82
  isDialogContent: true,
82
83
  "aria-label": calendarLabel
83
- }, () => h(RangeCalendar, {
84
- ...filter.dateRangeOptions,
85
- class: dateRangeCalendarClass,
84
+ }, () => filter.granularity === "minute" ? h(DateTimeRangeFields, {
85
+ filter,
86
+ class: dateTimeRangeStyles.popover
87
+ }) : h(RangeCalendar, {
88
+ ...filter.rangeCalendarProps,
89
+ class: dateTimeRangeStyles.calendar,
86
90
  value: filter.getValue(),
87
91
  onChange: (range) => {
88
92
  filter.setValue(range);
@@ -185,6 +189,7 @@ var Header = defineComponent({
185
189
  viewModes: modes
186
190
  }),
187
191
  list.search ? h(SearchField, {
192
+ key: isDisabled ? "disabled" : "enabled",
188
193
  class: listStyles.searchField,
189
194
  isDisabled,
190
195
  autoFocus: searchShape?.autoFocus,
@@ -201,7 +206,6 @@ var Header = defineComponent({
201
206
  }
202
207
  });
203
208
  composition(Header);
204
- //#endregion
205
209
  export { Header, Header as default };
206
210
 
207
211
  //# sourceMappingURL=Header.mjs.map
@@ -1 +1 @@
1
- {"version":3,"file":"Header.mjs","names":[],"sources":["../../../../../src/list/Header.ts"],"sourcesContent":["import {\n Button,\n ContextMenu,\n ContextMenuTrigger,\n Div,\n MenuItem,\n RangeCalendar,\n SearchField,\n Text,\n} from \"@/auto-generated\";\nimport { Popover } from \"@/overlays/Popover\";\nimport { PopoverTrigger } from \"@/overlays/triggers\";\nimport {\n IconAscending,\n IconDescending,\n IconFilter,\n IconSorting,\n IconView,\n} from \"@/icons\";\nimport { watchMobxValue } from \"@/lib/mobxSelector\";\nimport {\n createOverlayController,\n type OverlayController,\n} from \"@/overlays/overlayController\";\nimport {\n defineComponent,\n h,\n onBeforeUnmount,\n ref,\n watch,\n type VNodeChild,\n} from \"vue\";\nimport { ActiveFilters } from \"./ActiveFilters\";\nimport { AllFiltersModal } from \"./AllFiltersModal\";\nimport { isDateRangeFilter } from \"./dateRangeFilter\";\nimport { injectListModel, type AnyListModel } from \"./listContext\";\nimport { useListTexts, type ListTextFormatter } from \"./locales\";\nimport type { ListRenderShape } from \"./model\";\nimport { listStyles } from \"./styles\";\nimport type { ListRendered } from \"./types\";\nimport { composition } from \"@/lib/composition\";\n\nconst autoSubmitTimeout = 500;\n\n/* `FilterContextMenus.module.scss`'s `.calendar`. */\nconst dateRangeCalendarClass =\n \"flow--list--header--filter-context-menu--calendar\";\n\n/*\n * What the header needs of a sorting and of a filter, and nothing more.\n *\n * Not the classes themselves: a list of concrete filters is not assignable to\n * a list of generic ones, because a row model sits in a contravariant position\n * deep inside `Column`, so `Table<any>` and `Table<never>` never meet. Reading\n * only the members it renders keeps the header out of that entirely.\n */\ninterface HeaderSorting {\n readonly id: string;\n readonly name?: string;\n readonly property: unknown;\n readonly direction: \"asc\" | \"desc\";\n readonly directionName?: string;\n isSorted(): boolean;\n enable(): void;\n}\n\ninterface HeaderFilterValue {\n readonly id: string;\n readonly isActive: boolean;\n toggle(): void;\n render(): ListRendered;\n}\n\ninterface HeaderDateRangeFilter {\n readonly storageKey: string;\n readonly name?: string;\n readonly property: unknown;\n readonly dateRangeOptions?: Record<string, unknown>;\n getValue(): unknown;\n setValue(range: unknown): void;\n}\n\ninterface HeaderFilter {\n readonly storageKey: string;\n readonly mode: string;\n readonly priority: \"primary\" | \"secondary\";\n readonly name?: string;\n readonly property: unknown;\n readonly values: HeaderFilterValue[];\n readonly isSelectAllAvailable: boolean;\n selectAll(): void;\n setActiveValueIds(ids: Iterable<unknown>): void;\n}\n\n/** Which layouts this list can actually show. */\ntype ViewMode = \"list\" | \"table\" | \"tiles\";\n\nconst availableViewModes = (shape: ListRenderShape<never>): ViewMode[] => {\n const modes: ViewMode[] = [];\n if (shape.itemView?.showList) {\n modes.push(\"list\");\n }\n if (shape.table) {\n modes.push(\"table\");\n }\n if (shape.itemView?.showTiles) {\n modes.push(\"tiles\");\n }\n return modes;\n};\n\nconst outlineButton = (isDisabled: boolean) => ({\n variant: \"outline\" as const,\n color: \"secondary\" as const,\n class: listStyles.hideOnMobile,\n isDisabled,\n});\n\nconst renderViewModeMenu = (\n list: AnyListModel,\n modes: ViewMode[],\n texts: ListTextFormatter,\n isDisabled: boolean,\n selected: ViewMode,\n): VNodeChild => {\n if (modes.length <= 1) {\n return null;\n }\n\n return h(ContextMenuTrigger, null, () => [\n h(\n Button,\n { ...outlineButton(isDisabled), \"aria-label\": texts(\"settings\") },\n () => [\n h(Text, null, () => texts(`settings.viewMode.${selected}`)),\n h(IconView),\n ],\n ),\n h(ContextMenu, { selectionMode: \"single\", selectedKeys: [selected] }, () =>\n modes.map((mode) =>\n h(\n MenuItem,\n { key: mode, id: mode, onAction: () => list.viewMode.set(mode) },\n () => texts(`settings.viewMode.${mode}`),\n ),\n ),\n ),\n ]);\n};\n\nconst renderSortingMenu = (\n list: AnyListModel,\n texts: ListTextFormatter,\n isDisabled: boolean,\n): VNodeChild => {\n const sortings = list.visibleSorting as HeaderSorting[];\n\n if (sortings.length === 0) {\n return null;\n }\n\n const active = sortings.find((s) => s.isSorted());\n\n return h(ContextMenuTrigger, null, () => [\n h(Button, outlineButton(isDisabled), () => [\n h(Text, null, () =>\n active ? (active.name ?? String(active.property)) : texts(\"sorting\"),\n ),\n h(\n active\n ? active.direction === \"asc\"\n ? IconAscending\n : IconDescending\n : IconSorting,\n ),\n ]),\n h(\n ContextMenu,\n {\n selectionMode: \"single\",\n selectedKeys: active ? [active.id] : [],\n },\n () =>\n sortings.map((sorting) =>\n h(\n MenuItem,\n {\n key: sorting.id,\n id: sorting.id,\n onAction: () => sorting.enable(),\n },\n () =>\n `${sorting.name ?? String(sorting.property)} ${sorting.directionName ?? \"\"}`.trim(),\n ),\n ),\n ),\n ]);\n};\n\n/**\n * A date-range filter is a calendar in a popover, not a menu of values.\n *\n * The same shape Flow's React list gives it — the calendar closes the popover\n * when a range is picked, because a range is complete the moment its second end\n * is.\n */\nconst renderDateRangeFilter = (\n filter: HeaderDateRangeFilter,\n isDisabled: boolean,\n calendarLabel: string,\n controller: OverlayController,\n): VNodeChild =>\n h(PopoverTrigger, { key: filter.storageKey, controller }, () => [\n h(Button, outlineButton(isDisabled), () => [\n h(Text, null, () => filter.name ?? String(filter.property)),\n h(IconFilter),\n ]),\n h(\n Popover,\n {\n placement: \"bottom end\",\n isDialogContent: true,\n \"aria-label\": calendarLabel,\n },\n () =>\n /*\n * Cast at the call, because the options are whatever the consumer\n * handed the filter: an open record does not match a typed component's\n * props, and TypeScript then resolves `h` to its instance overload.\n */\n h(RangeCalendar, {\n ...filter.dateRangeOptions,\n class: dateRangeCalendarClass,\n value: filter.getValue(),\n onChange: (range: unknown) => {\n filter.setValue(range);\n controller.close();\n },\n } as never),\n ),\n ]);\n\nconst renderFilterMenu = (\n filter: HeaderFilter,\n isDisabled: boolean,\n): VNodeChild => {\n const selectionMode = filter.mode === \"one\" ? \"single\" : \"multiple\";\n const values = filter.values;\n\n return h(ContextMenuTrigger, { key: filter.storageKey }, () => [\n h(Button, outlineButton(isDisabled), () => [\n h(Text, null, () => filter.name ?? String(filter.property)),\n h(IconFilter),\n ]),\n h(\n ContextMenu,\n {\n selectionMode,\n selectedKeys: values.filter((v) => v.isActive).map((v) => v.id),\n /*\n * Flow's: a multiple-choice menu reports its whole selection, and the\n * \"Select all\" entry the host adds reports it as `\"all\"`.\n */\n onSelectionChange:\n selectionMode === \"multiple\"\n ? (keys: unknown) =>\n keys === \"all\"\n ? filter.selectAll()\n : filter.setActiveValueIds(keys as Iterable<unknown>)\n : undefined,\n showSelectAll: filter.isSelectAllAvailable,\n },\n () =>\n values.map((value) =>\n h(\n MenuItem,\n {\n key: value.id,\n id: value.id,\n /* A multiple choice goes through `onSelectionChange`. */\n onAction: () => {\n if (selectionMode === \"single\" && !value.isActive) {\n value.toggle();\n }\n },\n },\n () => value.render(),\n ),\n ),\n ),\n ]);\n};\n\n/**\n * The list's controls: layout, sorting, filters, search — plus the app's own\n * `ActionGroup`, which the `List` hands over as the `actions` slot.\n *\n * Each one is a remote element the host materialises — a context menu trigger\n * with a button and a menu — and what they act on is the shared model, so a\n * filter behaves here exactly as it does in React.\n */\nexport const Header = defineComponent({\n name: \"ListHeader\",\n\n setup(_props, { slots }) {\n const list = injectListModel();\n const texts = useListTexts();\n\n const isEmpty = watchMobxValue(() => list.isEmpty);\n const isInitiallyLoading = watchMobxValue(\n () => list.loaderState.isInitiallyLoading,\n );\n const emptyViewType = watchMobxValue(() => list.getEmptyViewType());\n const viewMode = watchMobxValue(() => list.viewMode.value);\n /* Filters and sortings read the table, so they follow its revision. */\n const tableRevision = watchMobxValue(() => list.listTable.revision);\n const renderShape = watchMobxValue(() => list.renderShape);\n\n /*\n * One controller per date filter, kept for as long as the header is.\n * Created in the render it would be a new one every time — and a range\n * takes two clicks, so the popover would forget the first between them.\n */\n const dateControllers = new Map<string, OverlayController>();\n const dateController = (key: string): OverlayController => {\n const existing = dateControllers.get(key);\n if (existing) {\n return existing;\n }\n const created = createOverlayController();\n dateControllers.set(key, created);\n return created;\n };\n\n /*\n * Flow's `DefaultSearchFieldRender`: the field holds what is typed, and a\n * search is submitted after a pause — or, with `autoSubmit={false}`, on\n * Enter. Escape and the clear button clear at once.\n */\n const searchShape = list.shape.search;\n const autoSubmit = searchShape?.autoSubmit !== false;\n const searchInput = ref(list.search?.value ?? \"\");\n let previousSearch = \"\";\n let submitTimeout: ReturnType<typeof setTimeout> | undefined;\n\n const submitSearch = () => {\n if (searchInput.value.trim() === \"\") {\n list.search?.setValue(undefined);\n } else if (previousSearch !== searchInput.value) {\n previousSearch = searchInput.value;\n list.search?.setValue(searchInput.value);\n }\n };\n\n const clearSearch = () => {\n clearTimeout(submitTimeout);\n list.search?.setValue(undefined);\n searchInput.value = \"\";\n };\n\n watch(searchInput, () => {\n clearTimeout(submitTimeout);\n if (autoSubmit) {\n submitTimeout = setTimeout(submitSearch, autoSubmitTimeout);\n }\n });\n\n /* A search set from outside the field — a reset — shows in it. */\n const searchValue = watchMobxValue(() => {\n void list.listTable.revision;\n return list.search?.value;\n });\n watch(searchValue, (value) => {\n searchInput.value = value ?? \"\";\n });\n\n const onSearchKeyUp = (event: { key?: string } | undefined) => {\n if (event?.key === \"Enter\" && !autoSubmit) {\n submitSearch();\n } else if (event?.key === \"Escape\") {\n clearSearch();\n }\n };\n\n onBeforeUnmount(() => clearTimeout(submitTimeout));\n\n return () => {\n void tableRevision.value;\n\n const noItemsAvailable = isEmpty.value && emptyViewType.value === \"list\";\n const isDisabled = isInitiallyLoading.value || noItemsAvailable;\n const modes = availableViewModes(renderShape.value);\n\n const actions = slots.actions?.();\n\n /*\n * The header is rendered even with nothing in it, because Flow's is: it\n * holds the app's own `ActionGroup`, and a list that gained one would\n * otherwise change the DOM around it.\n *\n * Asked of the model rather than of what the options rendered — the\n * all-filters modal decides for itself whether it has anything to show.\n */\n const hasOptions =\n list.filters.length > 0 ||\n list.visibleSorting.length > 0 ||\n !!list.search ||\n modes.length > 1;\n\n /*\n * Nothing to show yet and nothing to configure it with: Flow hides the\n * header rather than dropping it, so what an app put in it keeps its\n * state across the switch to and from the empty view.\n */\n if (noItemsAvailable) {\n return h(\n Div,\n { class: listStyles.hideVisuallyActions, \"aria-hidden\": true },\n /*\n * Same nesting and same classes as the branch below, which is what\n * Flow's comment on this branch asks for — the tunnel's content has\n * to survive the switch. React arrives at the inner class by reusing\n * the element rather than by setting it: a `className` that goes from\n * set to undefined never reaches the host, so the previous one stays.\n *\n * `[actions, null]`, not `actions`: Vue wraps a nested array in a\n * fragment, so only the same array shape keeps the actions at the\n * same position in the same fragment — anything else remounts them,\n * and a modal open from the header closes.\n */\n () =>\n h(Div, { class: listStyles.headerContent }, () => [actions, null]),\n );\n }\n\n const options: VNodeChild[] = [\n renderViewModeMenu(\n list,\n modes,\n texts.value,\n isDisabled,\n viewMode.value,\n ),\n renderSortingMenu(list, texts.value, isDisabled),\n /*\n * Primary only. A secondary filter is reachable through the\n * all-filters modal, which is the whole reason that modal shows on\n * desktop at all.\n */\n ...(list.filters as HeaderFilter[])\n .filter((filter) => filter.priority === \"primary\")\n .map((filter) =>\n isDateRangeFilter(filter)\n ? renderDateRangeFilter(\n filter as unknown as HeaderDateRangeFilter,\n isDisabled,\n texts.value(\"dateRange\"),\n dateController(filter.storageKey),\n )\n : renderFilterMenu(filter, isDisabled),\n ),\n h(AllFiltersModal, { isDisabled, viewModes: modes }),\n list.search\n ? h(SearchField, {\n class: listStyles.searchField,\n isDisabled,\n autoFocus: searchShape?.autoFocus,\n value: searchInput.value,\n onChange: (value: string) => {\n searchInput.value = value;\n },\n onKeyUp: onSearchKeyUp,\n onClear: clearSearch,\n })\n : null,\n ];\n\n return h(\n Div,\n {\n class: [\n listStyles.header,\n list.search ? listStyles.headerWithSearch : undefined,\n ]\n .filter(Boolean)\n .join(\" \"),\n },\n () => [\n h(Div, { class: listStyles.headerContent }, () => [\n actions,\n hasOptions\n ? h(Div, { class: listStyles.headerOptions }, () => options)\n : null,\n ]),\n h(ActiveFilters, { isDisabled }),\n ],\n );\n };\n },\n});\n\ncomposition(Header);\n\nexport default Header;\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;AA0CA,IAAM,oBAAoB;AAG1B,IAAM,yBACJ;AAmDF,IAAM,sBAAsB,UAA8C;CACxE,MAAM,QAAoB,CAAC;CAC3B,IAAI,MAAM,UAAU,UAClB,MAAM,KAAK,MAAM;CAEnB,IAAI,MAAM,OACR,MAAM,KAAK,OAAO;CAEpB,IAAI,MAAM,UAAU,WAClB,MAAM,KAAK,OAAO;CAEpB,OAAO;AACT;AAEA,IAAM,iBAAiB,gBAAyB;CAC9C,SAAS;CACT,OAAO;CACP,OAAO,WAAW;CAClB;AACF;AAEA,IAAM,sBACJ,MACA,OACA,OACA,YACA,aACe;CACf,IAAI,MAAM,UAAU,GAClB,OAAO;CAGT,OAAO,EAAE,oBAAoB,YAAY,CACvC,EACE,QACA;EAAE,GAAG,cAAc,UAAU;EAAG,cAAc,MAAM,UAAU;CAAE,SAC1D,CACJ,EAAE,MAAM,YAAY,MAAM,qBAAqB,UAAU,CAAC,GAC1D,EAAE,QAAQ,CACZ,CACF,GACA,EAAE,aAAa;EAAE,eAAe;EAAU,cAAc,CAAC,QAAQ;CAAE,SACjE,MAAM,KAAK,SACT,EACE,UAC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,KACA;IAAE,OAAO,WAAW;IAAqB,eAAe;GAAK,SAc3D,EAAE,KAAK,EAAE,OAAO,WAAW,cAAc,SAAS,CAAC,SAAS,IAAI,CAAC,CACrE;GAGF,MAAM,UAAwB;IAC5B,mBACE,MACA,OACA,MAAM,OACN,YACA,SAAS,KACX;IACA,kBAAkB,MAAM,MAAM,OAAO,UAAU;IAM/C,GAAI,KAAK,QACN,QAAQ,WAAW,OAAO,aAAa,SAAS,CAAC,CACjD,KAAK,WACJ,kBAAkB,MAAM,IACpB,sBACE,QACA,YACA,MAAM,MAAM,WAAW,GACvB,eAAe,OAAO,UAAU,CAClC,IACA,iBAAiB,QAAQ,UAAU,CACzC;IACF,EAAE,iBAAiB;KAAE;KAAY,WAAW;IAAM,CAAC;IACnD,KAAK,SACD,EAAE,aAAa;KACb,OAAO,WAAW;KAClB;KACA,WAAW,aAAa;KACxB,OAAO,YAAY;KACnB,WAAW,UAAkB;MAC3B,YAAY,QAAQ;KACtB;KACA,SAAS;KACT,SAAS;IACX,CAAC,IACD;GACN;GAEA,OAAO,EACL,KACA,EACE,OAAO,CACL,WAAW,QACX,KAAK,SAAS,WAAW,mBAAmB,KAAA,CAC9C,CAAC,CACE,OAAO,OAAO,CAAC,CACf,KAAK,GAAG,EACb,SACM,CACJ,EAAE,KAAK,EAAE,OAAO,WAAW,cAAc,SAAS,CAChD,SACA,aACI,EAAE,KAAK,EAAE,OAAO,WAAW,cAAc,SAAS,OAAO,IACzD,IACN,CAAC,GACD,EAAE,eAAe,EAAE,WAAW,CAAC,CACjC,CACF;EACF;CACF;AACF,CAAC;AAED,YAAY,MAAM"}
1
+ {"version":3,"file":"Header.mjs","names":[],"sources":["../../../../../src/list/Header.ts"],"sourcesContent":["import {\n Button,\n ContextMenu,\n ContextMenuTrigger,\n Div,\n MenuItem,\n RangeCalendar,\n SearchField,\n Text,\n} from \"@/auto-generated\";\nimport { Popover } from \"@/overlays/Popover\";\nimport { PopoverTrigger } from \"@/overlays/triggers\";\nimport {\n IconAscending,\n IconDescending,\n IconFilter,\n IconSorting,\n IconView,\n} from \"@/icons\";\nimport { watchMobxValue } from \"@/lib/mobxSelector\";\nimport {\n createOverlayController,\n type OverlayController,\n} from \"@/overlays/overlayController\";\nimport {\n defineComponent,\n h,\n onBeforeUnmount,\n ref,\n watch,\n type VNodeChild,\n} from \"vue\";\nimport { ActiveFilters } from \"./ActiveFilters\";\nimport { AllFiltersModal } from \"./AllFiltersModal\";\nimport { isDateRangeFilter } from \"./dateRangeFilter\";\nimport {\n DateTimeRangeFields,\n type DateTimeRangeFilter,\n} from \"./DateTimeRangeFields\";\nimport { injectListModel, type AnyListModel } from \"./listContext\";\nimport { useListTexts, type ListTextFormatter } from \"./locales\";\nimport type { ListRenderShape } from \"./model\";\nimport { dateTimeRangeStyles, listStyles } from \"./styles\";\nimport type { ListRendered } from \"./types\";\nimport { composition } from \"@/lib/composition\";\nimport type { ListDateRange } from \"@mittwald/flow-components-base\";\n\nconst autoSubmitTimeout = 500;\n\n/*\n * What the header needs of a sorting and of a filter, and nothing more.\n *\n * Not the classes themselves: a list of concrete filters is not assignable to\n * a list of generic ones, because a row model sits in a contravariant position\n * deep inside `Column`, so `Table<any>` and `Table<never>` never meet. Reading\n * only the members it renders keeps the header out of that entirely.\n */\ninterface HeaderSorting {\n readonly id: string;\n readonly name?: string;\n readonly property: unknown;\n readonly direction: \"asc\" | \"desc\";\n readonly directionName?: string;\n isSorted(): boolean;\n enable(): void;\n}\n\ninterface HeaderFilterValue {\n readonly id: string;\n readonly isActive: boolean;\n toggle(): void;\n render(): ListRendered;\n}\n\ninterface HeaderDateRangeFilter extends DateTimeRangeFilter {\n readonly storageKey: string;\n readonly name?: string;\n readonly property: unknown;\n readonly granularity: \"day\" | \"minute\";\n readonly rangeCalendarProps: Record<string, unknown>;\n}\n\ninterface HeaderFilter {\n readonly storageKey: string;\n readonly mode: string;\n readonly priority: \"primary\" | \"secondary\";\n readonly name?: string;\n readonly property: unknown;\n readonly values: HeaderFilterValue[];\n readonly isSelectAllAvailable: boolean;\n selectAll(): void;\n setActiveValueIds(ids: Iterable<unknown>): void;\n}\n\n/** Which layouts this list can actually show. */\ntype ViewMode = \"list\" | \"table\" | \"tiles\";\n\nconst availableViewModes = (shape: ListRenderShape<never>): ViewMode[] => {\n const modes: ViewMode[] = [];\n if (shape.itemView?.showList) {\n modes.push(\"list\");\n }\n if (shape.table) {\n modes.push(\"table\");\n }\n if (shape.itemView?.showTiles) {\n modes.push(\"tiles\");\n }\n return modes;\n};\n\nconst outlineButton = (isDisabled: boolean) => ({\n variant: \"outline\" as const,\n color: \"secondary\" as const,\n class: listStyles.hideOnMobile,\n isDisabled,\n});\n\nconst renderViewModeMenu = (\n list: AnyListModel,\n modes: ViewMode[],\n texts: ListTextFormatter,\n isDisabled: boolean,\n selected: ViewMode,\n): VNodeChild => {\n if (modes.length <= 1) {\n return null;\n }\n\n return h(ContextMenuTrigger, null, () => [\n h(\n Button,\n { ...outlineButton(isDisabled), \"aria-label\": texts(\"settings\") },\n () => [\n h(Text, null, () => texts(`settings.viewMode.${selected}`)),\n h(IconView),\n ],\n ),\n h(ContextMenu, { selectionMode: \"single\", selectedKeys: [selected] }, () =>\n modes.map((mode) =>\n h(\n MenuItem,\n { key: mode, id: mode, onAction: () => list.viewMode.set(mode) },\n () => texts(`settings.viewMode.${mode}`),\n ),\n ),\n ),\n ]);\n};\n\nconst renderSortingMenu = (\n list: AnyListModel,\n texts: ListTextFormatter,\n isDisabled: boolean,\n): VNodeChild => {\n const sortings = list.visibleSorting as HeaderSorting[];\n\n if (sortings.length === 0) {\n return null;\n }\n\n const active = sortings.find((s) => s.isSorted());\n\n return h(ContextMenuTrigger, null, () => [\n h(Button, outlineButton(isDisabled), () => [\n h(Text, null, () =>\n active ? (active.name ?? String(active.property)) : texts(\"sorting\"),\n ),\n h(\n active\n ? active.direction === \"asc\"\n ? IconAscending\n : IconDescending\n : IconSorting,\n ),\n ]),\n h(\n ContextMenu,\n {\n selectionMode: \"single\",\n selectedKeys: active ? [active.id] : [],\n },\n () =>\n sortings.map((sorting) =>\n h(\n MenuItem,\n {\n key: sorting.id,\n id: sorting.id,\n onAction: () => sorting.enable(),\n },\n () =>\n `${sorting.name ?? String(sorting.property)} ${sorting.directionName ?? \"\"}`.trim(),\n ),\n ),\n ),\n ]);\n};\n\n/**\n * A date-range filter is a calendar in a popover, not a menu of values — or,\n * with `granularity: \"minute\"`, date and time fields.\n *\n * The same shape Flow's React list gives it — the calendar closes the popover\n * when a range is picked, because a range is complete the moment its second end\n * is. The fields leave it open: they apply as they are typed.\n */\nconst renderDateRangeFilter = (\n filter: HeaderDateRangeFilter,\n isDisabled: boolean,\n calendarLabel: string,\n controller: OverlayController,\n): VNodeChild =>\n h(PopoverTrigger, { key: filter.storageKey, controller }, () => [\n h(Button, outlineButton(isDisabled), () => [\n h(Text, null, () => filter.name ?? String(filter.property)),\n h(IconFilter),\n ]),\n h(\n Popover,\n {\n placement: \"bottom end\",\n isDialogContent: true,\n \"aria-label\": calendarLabel,\n },\n () =>\n filter.granularity === \"minute\"\n ? h(DateTimeRangeFields, {\n filter,\n class: dateTimeRangeStyles.popover,\n })\n : /*\n * Cast at the call, because the options are whatever the consumer\n * handed the filter: an open record does not match a typed\n * component's props, and TypeScript then resolves `h` to its\n * instance overload.\n */\n h(RangeCalendar, {\n ...filter.rangeCalendarProps,\n class: dateTimeRangeStyles.calendar,\n value: filter.getValue(),\n onChange: (range: ListDateRange) => {\n filter.setValue(range);\n controller.close();\n },\n } as never),\n ),\n ]);\n\nconst renderFilterMenu = (\n filter: HeaderFilter,\n isDisabled: boolean,\n): VNodeChild => {\n const selectionMode = filter.mode === \"one\" ? \"single\" : \"multiple\";\n const values = filter.values;\n\n return h(ContextMenuTrigger, { key: filter.storageKey }, () => [\n h(Button, outlineButton(isDisabled), () => [\n h(Text, null, () => filter.name ?? String(filter.property)),\n h(IconFilter),\n ]),\n h(\n ContextMenu,\n {\n selectionMode,\n selectedKeys: values.filter((v) => v.isActive).map((v) => v.id),\n /*\n * Flow's: a multiple-choice menu reports its whole selection, and the\n * \"Select all\" entry the host adds reports it as `\"all\"`.\n */\n onSelectionChange:\n selectionMode === \"multiple\"\n ? (keys: unknown) =>\n keys === \"all\"\n ? filter.selectAll()\n : filter.setActiveValueIds(keys as Iterable<unknown>)\n : undefined,\n showSelectAll: filter.isSelectAllAvailable,\n },\n () =>\n values.map((value) =>\n h(\n MenuItem,\n {\n key: value.id,\n id: value.id,\n /* A multiple choice goes through `onSelectionChange`. */\n onAction: () => {\n if (selectionMode === \"single\" && !value.isActive) {\n value.toggle();\n }\n },\n },\n () => value.render(),\n ),\n ),\n ),\n ]);\n};\n\n/**\n * The list's controls: layout, sorting, filters, search — plus the app's own\n * `ActionGroup`, which the `List` hands over as the `actions` slot.\n *\n * Each one is a remote element the host materialises — a context menu trigger\n * with a button and a menu — and what they act on is the shared model, so a\n * filter behaves here exactly as it does in React.\n */\nexport const Header = defineComponent({\n name: \"ListHeader\",\n\n setup(_props, { slots }) {\n const list = injectListModel();\n const texts = useListTexts();\n\n const isEmpty = watchMobxValue(() => list.isEmpty);\n const isInitiallyLoading = watchMobxValue(\n () => list.loaderState.isInitiallyLoading,\n );\n const emptyViewType = watchMobxValue(() => list.getEmptyViewType());\n const viewMode = watchMobxValue(() => list.viewMode.value);\n /* Filters and sortings read the table, so they follow its revision. */\n const tableRevision = watchMobxValue(() => list.listTable.revision);\n const renderShape = watchMobxValue(() => list.renderShape);\n\n /*\n * One controller per date filter, kept for as long as the header is.\n * Created in the render it would be a new one every time — and a range\n * takes two clicks, so the popover would forget the first between them.\n */\n const dateControllers = new Map<string, OverlayController>();\n const dateController = (key: string): OverlayController => {\n const existing = dateControllers.get(key);\n if (existing) {\n return existing;\n }\n const created = createOverlayController();\n dateControllers.set(key, created);\n return created;\n };\n\n /*\n * Flow's `DefaultSearchFieldRender`: the field holds what is typed, and a\n * search is submitted after a pause — or, with `autoSubmit={false}`, on\n * Enter. Escape and the clear button clear at once.\n */\n const searchShape = list.shape.search;\n const autoSubmit = searchShape?.autoSubmit !== false;\n const searchInput = ref(list.search?.value ?? \"\");\n let previousSearch = \"\";\n let submitTimeout: ReturnType<typeof setTimeout> | undefined;\n\n const submitSearch = () => {\n if (searchInput.value.trim() === \"\") {\n list.search?.setValue(undefined);\n } else if (previousSearch !== searchInput.value) {\n previousSearch = searchInput.value;\n list.search?.setValue(searchInput.value);\n }\n };\n\n const clearSearch = () => {\n clearTimeout(submitTimeout);\n list.search?.setValue(undefined);\n searchInput.value = \"\";\n };\n\n watch(searchInput, () => {\n clearTimeout(submitTimeout);\n if (autoSubmit) {\n submitTimeout = setTimeout(submitSearch, autoSubmitTimeout);\n }\n });\n\n /* A search set from outside the field — a reset — shows in it. */\n const searchValue = watchMobxValue(() => {\n void list.listTable.revision;\n return list.search?.value;\n });\n watch(searchValue, (value) => {\n searchInput.value = value ?? \"\";\n });\n\n const onSearchKeyUp = (event: { key?: string } | undefined) => {\n if (event?.key === \"Enter\" && !autoSubmit) {\n submitSearch();\n } else if (event?.key === \"Escape\") {\n clearSearch();\n }\n };\n\n onBeforeUnmount(() => clearTimeout(submitTimeout));\n\n return () => {\n void tableRevision.value;\n\n const noItemsAvailable = isEmpty.value && emptyViewType.value === \"list\";\n const isDisabled = isInitiallyLoading.value || noItemsAvailable;\n const modes = availableViewModes(renderShape.value);\n\n const actions = slots.actions?.();\n\n /*\n * The header is rendered even with nothing in it, because Flow's is: it\n * holds the app's own `ActionGroup`, and a list that gained one would\n * otherwise change the DOM around it.\n *\n * Asked of the model rather than of what the options rendered — the\n * all-filters modal decides for itself whether it has anything to show.\n */\n const hasOptions =\n list.filters.length > 0 ||\n list.visibleSorting.length > 0 ||\n !!list.search ||\n modes.length > 1;\n\n /*\n * Nothing to show yet and nothing to configure it with: Flow hides the\n * header rather than dropping it, so what an app put in it keeps its\n * state across the switch to and from the empty view.\n */\n if (noItemsAvailable) {\n return h(\n Div,\n { class: listStyles.hideVisuallyActions, \"aria-hidden\": true },\n /*\n * Same nesting and same classes as the branch below, which is what\n * Flow's comment on this branch asks for — the tunnel's content has\n * to survive the switch. React arrives at the inner class by reusing\n * the element rather than by setting it: a `className` that goes from\n * set to undefined never reaches the host, so the previous one stays.\n *\n * `[actions, null]`, not `actions`: Vue wraps a nested array in a\n * fragment, so only the same array shape keeps the actions at the\n * same position in the same fragment — anything else remounts them,\n * and a modal open from the header closes.\n */\n () =>\n h(Div, { class: listStyles.headerContent }, () => [actions, null]),\n );\n }\n\n const options: VNodeChild[] = [\n renderViewModeMenu(\n list,\n modes,\n texts.value,\n isDisabled,\n viewMode.value,\n ),\n renderSortingMenu(list, texts.value, isDisabled),\n /*\n * Primary only. A secondary filter is reachable through the\n * all-filters modal, which is the whole reason that modal shows on\n * desktop at all.\n */\n ...(list.filters as HeaderFilter[])\n .filter((filter) => filter.priority === \"primary\")\n .map((filter) =>\n isDateRangeFilter(filter)\n ? renderDateRangeFilter(\n filter as unknown as HeaderDateRangeFilter,\n isDisabled,\n texts.value(\"dateRange\"),\n dateController(filter.storageKey),\n )\n : renderFilterMenu(filter, isDisabled),\n ),\n h(AllFiltersModal, { isDisabled, viewModes: modes }),\n list.search\n ? h(SearchField, {\n /* autoFocus acts on mount only — remount once enabled. */\n key: isDisabled ? \"disabled\" : \"enabled\",\n class: listStyles.searchField,\n isDisabled,\n autoFocus: searchShape?.autoFocus,\n value: searchInput.value,\n onChange: (value: string) => {\n searchInput.value = value;\n },\n onKeyUp: onSearchKeyUp,\n onClear: clearSearch,\n })\n : null,\n ];\n\n return h(\n Div,\n {\n class: [\n listStyles.header,\n list.search ? listStyles.headerWithSearch : undefined,\n ]\n .filter(Boolean)\n .join(\" \"),\n },\n () => [\n h(Div, { class: listStyles.headerContent }, () => [\n actions,\n hasOptions\n ? h(Div, { class: listStyles.headerOptions }, () => options)\n : null,\n ]),\n h(ActiveFilters, { isDisabled }),\n ],\n );\n };\n },\n});\n\ncomposition(Header);\n\nexport default Header;\n"],"mappings":";;;;;;;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AiB;KAAE;KAAY,WAAW;IAAM,CAAC;IACnD,KAAK,SACD,EAAE,aAAa;KAEb,KAAK,aAAa,aAAa;KAC/B,OAAO,WAAW;KAClB;KACA,WAAW,aAAa;KACxB,OAAO,YAAY;KACnB,WAAW,UAAkB;MAC3B,YAAY,QAAQ;KACtB;KACA,SAAS;KACT,SAAS;IACX,CAAC,IACD;GACN;GAEA,OAAO,EACL,KACA,EACE,OAAO,CACL,WAAW,QACX,KAAK,SAAS,WAAW,mBAAmB,KAAA,CAC9C,CAAC,CACE,OAAO,OAAO,CAAC,CACf,KAAK,GAAG,EACb,SACM,CACJ,EAAE,KAAK,EAAE,OAAO,WAAW,cAAc,SAAS,CAChD,SACA,aACI,EAAE,KAAK,EAAE,OAAO,WAAW,cAAc,SAAS,OAAO,IACzD,IACN,CAAC,GACD,EAAE,eAAe,EAAE,WAAW,CAAC,CACjC,CACF;EACF;CACF;AACF,CAAC;AAED,YAAY,MAAM"}
@@ -4,7 +4,7 @@ import watchMobxValue from "../lib/mobxSelector.mjs";
4
4
  import { injectListModel } from "./listContext.mjs";
5
5
  import { provideItemAccordion } from "./itemContext.mjs";
6
6
  import { computed, defineComponent, h, ref, useId } from "vue";
7
- //#region src/list/Item.ts
7
+ // src/list/Item.ts
8
8
  /**
9
9
  * One item of the list.
10
10
  *
@@ -58,7 +58,6 @@ var ListItemRow = defineComponent({
58
58
  }
59
59
  });
60
60
  composition(ListItemRow);
61
- //#endregion
62
61
  export { ListItemRow, ListItemRow as default };
63
62
 
64
63
  //# sourceMappingURL=Item.mjs.map
@@ -13,7 +13,7 @@ import { injectListModel } from "./listContext.mjs";
13
13
  import { className, listStyles } from "./styles.mjs";
14
14
  import { ListItemRow } from "./Item.mjs";
15
15
  import { defineComponent, h } from "vue";
16
- //#region src/list/Items.ts
16
+ // src/list/Items.ts
17
17
  /**
18
18
  * The list's items, as a grid list.
19
19
  *
@@ -65,7 +65,6 @@ var Items = defineComponent({
65
65
  }
66
66
  });
67
67
  composition(Items);
68
- //#endregion
69
68
  export { Items, Items as default };
70
69
 
71
70
  //# sourceMappingURL=Items.mjs.map
@@ -20,7 +20,7 @@ import { ListModel } from "./model.mjs";
20
20
  import { useListSettings } from "./settings.mjs";
21
21
  import { ListFilter, ListItem, ListLoaderAsync, ListLoaderComposable, ListSearch, ListSorting, ListStaticData, ListTable, ListTableBody, ListTableCell, ListTableColumn, ListTableHeader, ListTableRow, findSetup, findSetups, isListSetupComponent } from "./setupComponents.mjs";
22
22
  import { computed, defineComponent, h, onBeforeUnmount, onMounted, watch } from "vue";
23
- //#region src/list/List.ts
23
+ // src/list/List.ts
24
24
  var passesContextOn = /* @__PURE__ */ new Set([
25
25
  Action,
26
26
  ModalTrigger,
@@ -286,7 +286,6 @@ var List = defineComponent({
286
286
  }
287
287
  });
288
288
  composition(List);
289
- //#endregion
290
289
  export { List, List as default };
291
290
 
292
291
  //# sourceMappingURL=List.mjs.map
@@ -22,7 +22,7 @@ import { itemViewStyles, listStyles } from "./styles.mjs";
22
22
  import { ModalTrigger, PopoverTrigger } from "../overlays/triggers.mjs";
23
23
  import { injectItemAccordion } from "./itemContext.mjs";
24
24
  import { Fragment, cloneVNode, defineComponent, h } from "vue";
25
- //#region src/list/ListItemView.ts
25
+ // src/list/ListItemView.ts
26
26
  var overlayTriggers = /* @__PURE__ */ new Set([
27
27
  ContextMenuTrigger,
28
28
  ContextualHelpTrigger,
@@ -134,7 +134,6 @@ var ListItemView = defineComponent({
134
134
  }
135
135
  });
136
136
  composition(ListItemView);
137
- //#endregion
138
137
  export { ListItemView, ListItemView as default };
139
138
 
140
139
  //# sourceMappingURL=ListItemView.mjs.map
@@ -10,7 +10,7 @@ import watchMobxValue from "../lib/mobxSelector.mjs";
10
10
  import { injectListModel } from "./listContext.mjs";
11
11
  import { className } from "./styles.mjs";
12
12
  import { defineComponent, h } from "vue";
13
- //#region src/list/Table.ts
13
+ // src/list/Table.ts
14
14
  var tableStyles = {
15
15
  table: "flow--list--table",
16
16
  isLoading: "flow--list--table--is-loading",
@@ -72,7 +72,6 @@ var ListTableView = defineComponent({
72
72
  }
73
73
  });
74
74
  composition(ListTableView);
75
- //#endregion
76
75
  export { ListTableView, ListTableView as default };
77
76
 
78
77
  //# sourceMappingURL=Table.mjs.map
@@ -1,12 +1,12 @@
1
1
  import { ListDateRangeFilter } from "../../../components-base/src/list/filter/ListDateRangeFilter.mjs";
2
2
  import "../../../components-base/src/index.mjs";
3
- //#region src/list/dateRangeFilter.ts
3
+ // src/list/dateRangeFilter.ts
4
4
  /**
5
- * A date-range filter, with the options its calendar takes.
5
+ * A date-range filter, with the options its fields take.
6
6
  *
7
7
  * The column, the comparison and the stored value are the shared
8
8
  * `ListDateRangeFilter`, so a Vue list and a React list filter the same dates
9
- * the same way. What a binding adds is only what its calendar accepts.
9
+ * the same way. What a binding adds is only what its fields accept.
10
10
  */
11
11
  var DateRangeFilter = class extends ListDateRangeFilter {
12
12
  /** Handed to the `RangeCalendar` — a minimum date, unavailable days, … */
@@ -15,13 +15,20 @@ var DateRangeFilter = class extends ListDateRangeFilter {
15
15
  super(context, shape);
16
16
  this.dateRangeOptions = shape.dateRangeOptions;
17
17
  }
18
+ get granularity() {
19
+ return this.dateRangeOptions?.granularity === "minute" ? "minute" : "day";
20
+ }
21
+ get rangeCalendarProps() {
22
+ if (this.granularity === "minute") return {};
23
+ const { granularity, ...props } = this.dateRangeOptions ?? {};
24
+ return props;
25
+ }
26
+ get dateTimeRangeLimits() {
27
+ return this.granularity === "minute" ? this.dateRangeOptions : void 0;
28
+ }
18
29
  };
19
30
  /** Whether a filter is one of these, without reaching for the class. */
20
31
  var isDateRangeFilter = (filter) => filter.mode === "dateRange";
21
- /** `01/03/2024`, the way `Intl` writes it for the host's locale. */
22
- var formatDate = (date) => new Date(date.year, date.month - 1, date.day).toLocaleDateString();
23
- var formatDateRange = (range) => [range.start, range.end].map((date) => date ? formatDate(date) : "").join(" - ");
24
- //#endregion
25
- export { DateRangeFilter, formatDate, formatDateRange, isDateRangeFilter };
32
+ export { DateRangeFilter, isDateRangeFilter };
26
33
 
27
34
  //# sourceMappingURL=dateRangeFilter.mjs.map
@@ -1 +1 @@
1
- {"version":3,"file":"dateRangeFilter.mjs","names":[],"sources":["../../../../../src/list/dateRangeFilter.ts"],"sourcesContent":["import { ListDateRangeFilter } from \"@mittwald/flow-components-base\";\nimport type {\n ListDateParts,\n ListDateRange,\n ListModelContext,\n} from \"@mittwald/flow-components-base\";\nimport type { ListRendered, VueListFilterShape } from \"./types\";\n\n/**\n * A date-range filter, with the options its calendar takes.\n *\n * The column, the comparison and the stored value are the shared\n * `ListDateRangeFilter`, so a Vue list and a React list filter the same dates\n * the same way. What a binding adds is only what its calendar accepts.\n */\nexport class DateRangeFilter<T = never> extends ListDateRangeFilter<\n T,\n never,\n ListRendered\n> {\n /** Handed to the `RangeCalendar` — a minimum date, unavailable days, … */\n public readonly dateRangeOptions?: Record<string, unknown>;\n\n public constructor(\n context: ListModelContext<T>,\n shape: VueListFilterShape<T>,\n ) {\n super(context, shape as never);\n this.dateRangeOptions = (\n shape as { dateRangeOptions?: Record<string, unknown> }\n ).dateRangeOptions;\n }\n}\n\n/** Whether a filter is one of these, without reaching for the class. */\nexport const isDateRangeFilter = (filter: {\n readonly mode: string;\n}): filter is DateRangeFilter<never> => filter.mode === \"dateRange\";\n\n/** `01/03/2024`, the way `Intl` writes it for the host's locale. */\nexport const formatDate = (date: ListDateParts): string =>\n new Date(date.year, date.month - 1, date.day).toLocaleDateString();\n\nexport const formatDateRange = (range: ListDateRange): string =>\n [range.start, range.end]\n .map((date) => (date ? formatDate(date) : \"\"))\n .join(\" - \");\n"],"mappings":";;;;;;;;;;AAeA,IAAa,kBAAb,cAAgD,oBAI9C;;CAEA;CAEA,YACE,SACA,OACA;EACA,MAAM,SAAS,KAAc;EAC7B,KAAK,mBACH,MACA;CACJ;AACF;;AAGA,IAAa,qBAAqB,WAEM,OAAO,SAAS;;AAGxD,IAAa,cAAc,SACzB,IAAI,KAAK,KAAK,MAAM,KAAK,QAAQ,GAAG,KAAK,GAAG,CAAC,CAAC,mBAAmB;AAEnE,IAAa,mBAAmB,UAC9B,CAAC,MAAM,OAAO,MAAM,GAAG,CAAC,CACrB,KAAK,SAAU,OAAO,WAAW,IAAI,IAAI,EAAG,CAAC,CAC7C,KAAK,KAAK"}
1
+ {"version":3,"file":"dateRangeFilter.mjs","names":[],"sources":["../../../../../src/list/dateRangeFilter.ts"],"sourcesContent":["import { ListDateRangeFilter } from \"@mittwald/flow-components-base\";\nimport type {\n ListDateTimeRangeLimits,\n ListModelContext,\n} from \"@mittwald/flow-components-base\";\nimport type { ListRendered, VueListFilterShape } from \"./types\";\n\n/**\n * A date-range filter, with the options its fields take.\n *\n * The column, the comparison and the stored value are the shared\n * `ListDateRangeFilter`, so a Vue list and a React list filter the same dates\n * the same way. What a binding adds is only what its fields accept.\n */\nexport class DateRangeFilter<T = never> extends ListDateRangeFilter<\n T,\n never,\n ListRendered\n> {\n /** Handed to the `RangeCalendar` — a minimum date, unavailable days, … */\n public readonly dateRangeOptions?: Record<string, unknown>;\n\n public constructor(\n context: ListModelContext<T>,\n shape: VueListFilterShape<T>,\n ) {\n super(context, shape as never);\n this.dateRangeOptions = (\n shape as { dateRangeOptions?: Record<string, unknown> }\n ).dateRangeOptions;\n }\n\n public get granularity(): \"day\" | \"minute\" {\n return this.dateRangeOptions?.granularity === \"minute\" ? \"minute\" : \"day\";\n }\n\n public get rangeCalendarProps(): Record<string, unknown> {\n if (this.granularity === \"minute\") {\n return {};\n }\n // eslint-disable-next-line @typescript-eslint/no-unused-vars\n const { granularity, ...props } = this.dateRangeOptions ?? {};\n return props;\n }\n\n public get dateTimeRangeLimits(): ListDateTimeRangeLimits | undefined {\n return this.granularity === \"minute\"\n ? (this.dateRangeOptions as ListDateTimeRangeLimits)\n : undefined;\n }\n}\n\n/** Whether a filter is one of these, without reaching for the class. */\nexport const isDateRangeFilter = (filter: {\n readonly mode: string;\n}): filter is DateRangeFilter<never> => filter.mode === \"dateRange\";\n"],"mappings":";;;;;;;;;;AAcA,IAAa,kBAAb,cAAgD,oBAI9C;;CAEA;CAEA,YACE,SACA,OACA;EACA,MAAM,SAAS,KAAc;EAC7B,KAAK,mBACH,MACA;CACJ;CAEA,IAAW,cAAgC;EACzC,OAAO,KAAK,kBAAkB,gBAAgB,WAAW,WAAW;CACtE;CAEA,IAAW,qBAA8C;EACvD,IAAI,KAAK,gBAAgB,UACvB,OAAO,CAAC;EAGV,MAAM,EAAE,aAAa,GAAG,UAAU,KAAK,oBAAoB,CAAC;EAC5D,OAAO;CACT;CAEA,IAAW,sBAA2D;EACpE,OAAO,KAAK,gBAAgB,WACvB,KAAK,mBACN,KAAA;CACN;AACF;;AAGA,IAAa,qBAAqB,WAEM,OAAO,SAAS"}
@@ -1,10 +1,9 @@
1
1
  import { inject, provide } from "vue";
2
- //#region src/list/itemContext.ts
2
+ // src/list/itemContext.ts
3
3
  var key = Symbol("flowListItemAccordion");
4
4
  var provideItemAccordion = (accordion) => provide(key, accordion);
5
5
  /** `undefined` outside a list item. */
6
6
  var injectItemAccordion = () => inject(key, void 0);
7
- //#endregion
8
7
  export { injectItemAccordion, provideItemAccordion };
9
8
 
10
9
  //# sourceMappingURL=itemContext.mjs.map
@@ -1,5 +1,5 @@
1
1
  import { inject, provide } from "vue";
2
- //#region src/list/listContext.ts
2
+ // src/list/listContext.ts
3
3
  var listModelKey = Symbol("flowListModel");
4
4
  var provideListModel = (model) => provide(listModelKey, model);
5
5
  var injectListModel = () => {
@@ -7,7 +7,6 @@ var injectListModel = () => {
7
7
  if (!model) throw new Error("This component must be used inside a <List />.");
8
8
  return model;
9
9
  };
10
- //#endregion
11
10
  export { injectListModel, provideListModel };
12
11
 
13
12
  //# sourceMappingURL=listContext.mjs.map
@@ -1,9 +1,16 @@
1
1
  import { useLanguage } from "../composables/remoteContext.mjs";
2
2
  import { computed } from "vue";
3
- //#region src/list/locales.ts
3
+ // src/list/locales.ts
4
4
  var texts = {
5
5
  "en-US": {
6
6
  dateRange: "Date range",
7
+ "dateRange.endBeforeStart": "The end must not be before the start.",
8
+ "dateRange.endDate": "End date",
9
+ "dateRange.endTime": "End time",
10
+ "dateRange.from": "from {date}",
11
+ "dateRange.startDate": "Start date",
12
+ "dateRange.startTime": "Start time",
13
+ "dateRange.until": "until {date}",
7
14
  filters: "Filters",
8
15
  "filters.all": "All filters",
9
16
  "filters.clear": "Clear filters",
@@ -34,6 +41,13 @@ var texts = {
34
41
  },
35
42
  "de-DE": {
36
43
  dateRange: "Zeitraum",
44
+ "dateRange.endBeforeStart": "Das Ende darf nicht vor dem Start liegen.",
45
+ "dateRange.endDate": "Enddatum",
46
+ "dateRange.endTime": "Endzeit",
47
+ "dateRange.from": "ab {date}",
48
+ "dateRange.startDate": "Startdatum",
49
+ "dateRange.startTime": "Startzeit",
50
+ "dateRange.until": "bis {date}",
37
51
  filters: "Filter",
38
52
  "filters.all": "Alle Filter",
39
53
  "filters.clear": "Filter entfernen",
@@ -78,7 +92,6 @@ var useListTexts = () => {
78
92
  return (key, values = {}) => table[key].replace(/\{(\w+)\}/g, (placeholder, name) => name in values ? String(values[name]) : placeholder);
79
93
  });
80
94
  };
81
- //#endregion
82
95
  export { texts, useListTexts };
83
96
 
84
97
  //# sourceMappingURL=locales.mjs.map
@@ -1 +1 @@
1
- {"version":3,"file":"locales.mjs","names":[],"sources":["../../../../../src/list/locales.ts"],"sourcesContent":["import { useLanguage } from \"@/composables/remoteContext\";\nimport { computed, type ComputedRef } from \"vue\";\n\n/*\n * Copied from `packages/components/src/components/List/locales/*.locale.json`.\n *\n * Flow's strings are compiled into the React bundle by a locale plugin and are\n * not importable from a published package, so a Vue binding has to carry its\n * own — the same trade as the overlays' strings (`src/overlays/locales.ts`), at\n * a larger count. A rewording on the Flow side fails\n * `src/tests/CopiedTexts.test.ts`.\n */\nexport const texts = {\n \"en-US\": {\n dateRange: \"Date range\",\n filters: \"Filters\",\n \"filters.all\": \"All filters\",\n \"filters.clear\": \"Clear filters\",\n \"filters.clearSelection\": \"Clear selection\",\n \"filters.deselectAll\": \"Deselect all\",\n \"filters.reset\": \"Reset filters\",\n \"filters.selectAll\": \"Select all\",\n \"filters.store\": \"Store filters\",\n loadingMore: \"Loading more items\",\n \"noItems.heading\": \"No items available\",\n \"noItems.text\":\n \"Once there are items available, they will be displayed here.\",\n \"noResult.heading\": \"No search results found\",\n \"noResult.text\":\n \"Your search did not return any results. Please adjust the search query or your filters.\",\n options: \"Options\",\n paginationInfo: \"Showing {visibleItemsCount} of {totalItemsCount}\",\n reset: \"Reset\",\n /*\n * One key per branch, because Flow's is ICU (`{n, select, 1 {…} other {…}}`)\n * and this binding carries a `{name}` formatter rather than an ICU parser.\n * The two branches are picked in code — see `AllFiltersModal`.\n */\n \"results.show.one\": \"Show {totalItemCount} result\",\n \"results.show.other\": \"Show {totalItemCount} Results\",\n settings: \"Settings\",\n \"settings.viewMode\": \"View\",\n \"settings.viewMode.list\": \"List\",\n \"settings.viewMode.table\": \"Table\",\n \"settings.viewMode.tiles\": \"Tiles\",\n showMore: \"Show more\",\n sorting: \"Sorting\",\n \"toggleExpandButton.collapse\": \"Show less\",\n \"toggleExpandButton.expand\": \"Show more\",\n },\n \"de-DE\": {\n dateRange: \"Zeitraum\",\n filters: \"Filter\",\n \"filters.all\": \"Alle Filter\",\n \"filters.clear\": \"Filter entfernen\",\n \"filters.clearSelection\": \"Auswahl aufheben\",\n \"filters.deselectAll\": \"Alle abwählen\",\n \"filters.reset\": \"Filter zurücksetzen\",\n \"filters.selectAll\": \"Alle auswählen\",\n \"filters.store\": \"Filter speichern\",\n loadingMore: \"Weitere Einträge werden geladen\",\n \"noItems.heading\": \"Keine Einträge vorhanden\",\n \"noItems.text\":\n \"Sobald Einträge vorhanden sind, werden sie hier angezeigt.\",\n \"noResult.heading\": \"Keine Suchergebnisse gefunden\",\n \"noResult.text\":\n \"Deine Suche ergab keine Ergebnisse. Bitte passe die Suchanfrage oder deine Filter an.\",\n options: \"Optionen\",\n paginationInfo:\n \"{visibleItemsCount} von insgesamt {totalItemsCount} angezeigt\",\n reset: \"Zurücksetzen\",\n \"results.show.one\": \"{totalItemCount} Ergebnis anzeigen\",\n \"results.show.other\": \"{totalItemCount} Ergebnisse anzeigen\",\n settings: \"Einstellungen\",\n \"settings.viewMode\": \"Ansicht\",\n \"settings.viewMode.list\": \"Liste\",\n \"settings.viewMode.table\": \"Tabelle\",\n \"settings.viewMode.tiles\": \"Raster\",\n showMore: \"Mehr anzeigen\",\n sorting: \"Sortierung\",\n \"toggleExpandButton.collapse\": \"Weniger anzeigen\",\n \"toggleExpandButton.expand\": \"Mehr anzeigen\",\n },\n} as const;\n\nexport type ListTextKey = keyof (typeof texts)[\"en-US\"];\n\nexport type ListTextFormatter = (\n key: ListTextKey,\n values?: Record<string, string | number>,\n) => string;\n\n/**\n * The list's texts in the host's language.\n *\n * Only `{name}` placeholders, not ICU: the two strings that interpolate count\n * items, and neither pluralizes. A string that needed a plural rule would need\n * a formatter, and the honest fix then is `@flr-generate` on the List rather\n * than an ICU parser in a binding.\n */\nexport const useListTexts = (): ComputedRef<ListTextFormatter> => {\n const language = useLanguage();\n\n return computed(() => {\n const table = language.value?.startsWith(\"de\")\n ? texts[\"de-DE\"]\n : texts[\"en-US\"];\n\n return (key, values = {}) =>\n table[key].replace(/\\{(\\w+)\\}/g, (placeholder, name: string) =>\n name in values ? String(values[name]) : placeholder,\n );\n });\n};\n"],"mappings":";;;AAYA,IAAa,QAAQ;CACnB,SAAS;EACP,WAAW;EACX,SAAS;EACT,eAAe;EACf,iBAAiB;EACjB,0BAA0B;EAC1B,uBAAuB;EACvB,iBAAiB;EACjB,qBAAqB;EACrB,iBAAiB;EACjB,aAAa;EACb,mBAAmB;EACnB,gBACE;EACF,oBAAoB;EACpB,iBACE;EACF,SAAS;EACT,gBAAgB;EAChB,OAAO;EAMP,oBAAoB;EACpB,sBAAsB;EACtB,UAAU;EACV,qBAAqB;EACrB,0BAA0B;EAC1B,2BAA2B;EAC3B,2BAA2B;EAC3B,UAAU;EACV,SAAS;EACT,+BAA+B;EAC/B,6BAA6B;CAC/B;CACA,SAAS;EACP,WAAW;EACX,SAAS;EACT,eAAe;EACf,iBAAiB;EACjB,0BAA0B;EAC1B,uBAAuB;EACvB,iBAAiB;EACjB,qBAAqB;EACrB,iBAAiB;EACjB,aAAa;EACb,mBAAmB;EACnB,gBACE;EACF,oBAAoB;EACpB,iBACE;EACF,SAAS;EACT,gBACE;EACF,OAAO;EACP,oBAAoB;EACpB,sBAAsB;EACtB,UAAU;EACV,qBAAqB;EACrB,0BAA0B;EAC1B,2BAA2B;EAC3B,2BAA2B;EAC3B,UAAU;EACV,SAAS;EACT,+BAA+B;EAC/B,6BAA6B;CAC/B;AACF;;;;;;;;;AAiBA,IAAa,qBAAqD;CAChE,MAAM,WAAW,YAAY;CAE7B,OAAO,eAAe;EACpB,MAAM,QAAQ,SAAS,OAAO,WAAW,IAAI,IACzC,MAAM,WACN,MAAM;EAEV,QAAQ,KAAK,SAAS,CAAC,MACrB,MAAM,IAAI,CAAC,QAAQ,eAAe,aAAa,SAC7C,QAAQ,SAAS,OAAO,OAAO,KAAK,IAAI,WAC1C;CACJ,CAAC;AACH"}
1
+ {"version":3,"file":"locales.mjs","names":[],"sources":["../../../../../src/list/locales.ts"],"sourcesContent":["import { useLanguage } from \"@/composables/remoteContext\";\nimport { computed, type ComputedRef } from \"vue\";\n\n/*\n * Copied from `packages/components/src/components/List/locales/*.locale.json`.\n *\n * Flow's strings are compiled into the React bundle by a locale plugin and are\n * not importable from a published package, so a Vue binding has to carry its\n * own — the same trade as the overlays' strings (`src/overlays/locales.ts`), at\n * a larger count. A rewording on the Flow side fails\n * `src/tests/CopiedTexts.test.ts`.\n */\nexport const texts = {\n \"en-US\": {\n dateRange: \"Date range\",\n \"dateRange.endBeforeStart\": \"The end must not be before the start.\",\n \"dateRange.endDate\": \"End date\",\n \"dateRange.endTime\": \"End time\",\n \"dateRange.from\": \"from {date}\",\n \"dateRange.startDate\": \"Start date\",\n \"dateRange.startTime\": \"Start time\",\n \"dateRange.until\": \"until {date}\",\n filters: \"Filters\",\n \"filters.all\": \"All filters\",\n \"filters.clear\": \"Clear filters\",\n \"filters.clearSelection\": \"Clear selection\",\n \"filters.deselectAll\": \"Deselect all\",\n \"filters.reset\": \"Reset filters\",\n \"filters.selectAll\": \"Select all\",\n \"filters.store\": \"Store filters\",\n loadingMore: \"Loading more items\",\n \"noItems.heading\": \"No items available\",\n \"noItems.text\":\n \"Once there are items available, they will be displayed here.\",\n \"noResult.heading\": \"No search results found\",\n \"noResult.text\":\n \"Your search did not return any results. Please adjust the search query or your filters.\",\n options: \"Options\",\n paginationInfo: \"Showing {visibleItemsCount} of {totalItemsCount}\",\n reset: \"Reset\",\n /*\n * One key per branch, because Flow's is ICU (`{n, select, 1 {…} other {…}}`)\n * and this binding carries a `{name}` formatter rather than an ICU parser.\n * The two branches are picked in code — see `AllFiltersModal`.\n */\n \"results.show.one\": \"Show {totalItemCount} result\",\n \"results.show.other\": \"Show {totalItemCount} Results\",\n settings: \"Settings\",\n \"settings.viewMode\": \"View\",\n \"settings.viewMode.list\": \"List\",\n \"settings.viewMode.table\": \"Table\",\n \"settings.viewMode.tiles\": \"Tiles\",\n showMore: \"Show more\",\n sorting: \"Sorting\",\n \"toggleExpandButton.collapse\": \"Show less\",\n \"toggleExpandButton.expand\": \"Show more\",\n },\n \"de-DE\": {\n dateRange: \"Zeitraum\",\n \"dateRange.endBeforeStart\": \"Das Ende darf nicht vor dem Start liegen.\",\n \"dateRange.endDate\": \"Enddatum\",\n \"dateRange.endTime\": \"Endzeit\",\n \"dateRange.from\": \"ab {date}\",\n \"dateRange.startDate\": \"Startdatum\",\n \"dateRange.startTime\": \"Startzeit\",\n \"dateRange.until\": \"bis {date}\",\n filters: \"Filter\",\n \"filters.all\": \"Alle Filter\",\n \"filters.clear\": \"Filter entfernen\",\n \"filters.clearSelection\": \"Auswahl aufheben\",\n \"filters.deselectAll\": \"Alle abwählen\",\n \"filters.reset\": \"Filter zurücksetzen\",\n \"filters.selectAll\": \"Alle auswählen\",\n \"filters.store\": \"Filter speichern\",\n loadingMore: \"Weitere Einträge werden geladen\",\n \"noItems.heading\": \"Keine Einträge vorhanden\",\n \"noItems.text\":\n \"Sobald Einträge vorhanden sind, werden sie hier angezeigt.\",\n \"noResult.heading\": \"Keine Suchergebnisse gefunden\",\n \"noResult.text\":\n \"Deine Suche ergab keine Ergebnisse. Bitte passe die Suchanfrage oder deine Filter an.\",\n options: \"Optionen\",\n paginationInfo:\n \"{visibleItemsCount} von insgesamt {totalItemsCount} angezeigt\",\n reset: \"Zurücksetzen\",\n \"results.show.one\": \"{totalItemCount} Ergebnis anzeigen\",\n \"results.show.other\": \"{totalItemCount} Ergebnisse anzeigen\",\n settings: \"Einstellungen\",\n \"settings.viewMode\": \"Ansicht\",\n \"settings.viewMode.list\": \"Liste\",\n \"settings.viewMode.table\": \"Tabelle\",\n \"settings.viewMode.tiles\": \"Raster\",\n showMore: \"Mehr anzeigen\",\n sorting: \"Sortierung\",\n \"toggleExpandButton.collapse\": \"Weniger anzeigen\",\n \"toggleExpandButton.expand\": \"Mehr anzeigen\",\n },\n} as const;\n\nexport type ListTextKey = keyof (typeof texts)[\"en-US\"];\n\nexport type ListTextFormatter = (\n key: ListTextKey,\n values?: Record<string, string | number>,\n) => string;\n\n/**\n * The list's texts in the host's language.\n *\n * Only `{name}` placeholders, not ICU: the two strings that interpolate count\n * items, and neither pluralizes. A string that needed a plural rule would need\n * a formatter, and the honest fix then is `@flr-generate` on the List rather\n * than an ICU parser in a binding.\n */\nexport const useListTexts = (): ComputedRef<ListTextFormatter> => {\n const language = useLanguage();\n\n return computed(() => {\n const table = language.value?.startsWith(\"de\")\n ? texts[\"de-DE\"]\n : texts[\"en-US\"];\n\n return (key, values = {}) =>\n table[key].replace(/\\{(\\w+)\\}/g, (placeholder, name: string) =>\n name in values ? String(values[name]) : placeholder,\n );\n });\n};\n"],"mappings":";;;AAYA,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OAAO,OAAO,KAAK,IAAI,WAC1C;CACJ,CAAC;AACH"}
@@ -1,6 +1,6 @@
1
1
  import watchMobxValue from "../lib/mobxSelector.mjs";
2
2
  import { injectListModel } from "./listContext.mjs";
3
- //#region src/list/metadata.ts
3
+ // src/list/metadata.ts
4
4
  /**
5
5
  * What the loader reported beside its data.
6
6
  *
@@ -16,7 +16,6 @@ var useListMetadata = () => {
16
16
  const list = injectListModel();
17
17
  return watchMobxValue(() => list.loaderState.metadata);
18
18
  };
19
- //#endregion
20
19
  export { useListMetadata as default, useListMetadata };
21
20
 
22
21
  //# sourceMappingURL=metadata.mjs.map
@@ -13,7 +13,7 @@ import { isRef } from "vue";
13
13
  import { action, makeObservable, observable } from "mobx";
14
14
  import { hash } from "object-code";
15
15
  import { getCoreRowModel, getFacetedUniqueValues, getFilteredRowModel, getPaginationRowModel, getSortedRowModel } from "@tanstack/table-core";
16
- //#region src/list/model.ts
16
+ // src/list/model.ts
17
17
  var emptyData = [];
18
18
  /** The same items in the same order, whether or not it is the same array. */
19
19
  var isSameData = (current, next) => current === next || current !== void 0 && current.length === next.length && current.every((item, index) => item === next[index]);
@@ -386,7 +386,6 @@ var ListModel = class {
386
386
  return Array.from(defs.values());
387
387
  }
388
388
  };
389
- //#endregion
390
389
  export { ListModel };
391
390
 
392
391
  //# sourceMappingURL=model.mjs.map
@@ -1,5 +1,5 @@
1
1
  import { injectSettings } from "../components/SettingsProvider.mjs";
2
- //#region src/list/settings.ts
2
+ // src/list/settings.ts
3
3
  /**
4
4
  * Which keys survive how.
5
5
  *
@@ -56,7 +56,6 @@ var useListSettings = (storageKey) => {
56
56
  const store = injectSettings();
57
57
  return storageKey && store ? createListSettings(store, storageKey) : void 0;
58
58
  };
59
- //#endregion
60
59
  export { createListSettings, useListSettings };
61
60
 
62
61
  //# sourceMappingURL=settings.mjs.map
@@ -1,6 +1,6 @@
1
1
  import { normalizeVNodeProps } from "../lib/propKeys.mjs";
2
2
  import { Fragment, withCtx } from "vue";
3
- //#region src/list/setupComponents.ts
3
+ // src/list/setupComponents.ts
4
4
  /**
5
5
  * A list is configured by the elements inside it, not by one big prop.
6
6
  *
@@ -72,7 +72,6 @@ var findSetups = (children, component) => {
72
72
  return found;
73
73
  };
74
74
  var findSetup = (children, component) => findSetups(children, component)[0];
75
- //#endregion
76
75
  export { ListFilter, ListItem, ListLoaderAsync, ListLoaderComposable, ListSearch, ListSorting, ListStaticData, ListTable, ListTableBody, ListTableCell, ListTableColumn, ListTableHeader, ListTableRow, findSetup, findSetups, isListSetupComponent };
77
76
 
78
77
  //# sourceMappingURL=setupComponents.mjs.map