@mittwald/flow-remote-vue-components 1.5.31 → 1.5.33

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.
@@ -185,6 +185,7 @@ var Header = defineComponent({
185
185
  viewModes: modes
186
186
  }),
187
187
  list.search ? h(SearchField, {
188
+ key: isDisabled ? "disabled" : "enabled",
188
189
  class: listStyles.searchField,
189
190
  isDisabled,
190
191
  autoFocus: searchShape?.autoFocus,
@@ -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,UACA;EAAE,KAAK;EAAM,IAAI;EAAM,gBAAgB,KAAK,SAAS,IAAI,IAAI;CAAE,SACzD,MAAM,qBAAqB,MAAM,CACzC,CACF,CACF,CACF,CAAC;AACH;AAEA,IAAM,qBACJ,MACA,OACA,eACe;CACf,MAAM,WAAW,KAAK;CAEtB,IAAI,SAAS,WAAW,GACtB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,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 { 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 /* 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":";;;;;;;;;;;;;;;;;;;;;;;;;;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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,WAAW,cAAc,SAAS,OAAO,IACzD,IACN,CAAC,GACD,EAAE,eAAe,EAAE,WAAW,CAAC,CACjC,CACF;EACF;CACF;AACF,CAAC;AAED,YAAY,MAAM"}
@@ -1,7 +1,7 @@
1
1
  import { Version } from "@mittwald/flow-remote-core";
2
2
  //#region src/version.ts
3
3
  var communicationVersion = Version.v5;
4
- var packageVersion = "1.5.31";
4
+ var packageVersion = "1.5.33";
5
5
  var version = communicationVersion;
6
6
  //#endregion
7
7
  export { communicationVersion, packageVersion, version };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@mittwald/flow-remote-vue-components",
3
- "version": "1.5.31",
3
+ "version": "1.5.33",
4
4
  "type": "module",
5
5
  "description": "Vue components that can be used in a remote environment",
6
6
  "homepage": "https://flow.mittwald.de",
@@ -41,8 +41,8 @@
41
41
  },
42
42
  "dependencies": {
43
43
  "@internationalized/date": "^3.12.3",
44
- "@mittwald/flow-remote-core": "1.5.31",
45
- "@mittwald/flow-remote-elements": "1.5.31",
44
+ "@mittwald/flow-remote-core": "1.5.33",
45
+ "@mittwald/flow-remote-elements": "1.5.33",
46
46
  "@tanstack/table-core": "^8.21.3",
47
47
  "country-codes-list": "^2.0.0",
48
48
  "dot-prop": "^10.2.0",
@@ -52,14 +52,14 @@
52
52
  "remeda": "^2.43.0"
53
53
  },
54
54
  "devDependencies": {
55
- "@mittwald/ext-bridge": "1.5.31",
56
- "@mittwald/flow-components-base": "1.5.31",
57
- "@mittwald/flow-core": "1.5.31",
58
- "@mittwald/flow-icons-base": "1.5.31",
59
- "@mittwald/flow-react-components": "1.5.31",
60
- "@mittwald/flow-remote-react-components": "1.5.31",
61
- "@mittwald/flow-remote-react-renderer": "1.5.31",
62
- "@mittwald/typescript-config": "1.5.31",
55
+ "@mittwald/ext-bridge": "1.5.33",
56
+ "@mittwald/flow-components-base": "1.5.33",
57
+ "@mittwald/flow-core": "1.5.33",
58
+ "@mittwald/flow-icons-base": "1.5.33",
59
+ "@mittwald/flow-react-components": "1.5.33",
60
+ "@mittwald/flow-remote-react-components": "1.5.33",
61
+ "@mittwald/flow-remote-react-renderer": "1.5.33",
62
+ "@mittwald/typescript-config": "1.5.33",
63
63
  "@quilted/threads": "^3.3.1",
64
64
  "@types/node": "^25.9.3",
65
65
  "@types/react": "^19.2",
@@ -79,10 +79,10 @@
79
79
  "vue": "~3.5.38"
80
80
  },
81
81
  "peerDependencies": {
82
- "@mittwald/ext-bridge": "1.5.31",
83
- "@mittwald/flow-react-components": "1.5.31",
82
+ "@mittwald/ext-bridge": "1.5.33",
83
+ "@mittwald/flow-react-components": "1.5.33",
84
84
  "vue": "^3.5.0"
85
85
  },
86
86
  "flowStatus": "beta",
87
- "gitHead": "750a8297f6ebc782e1f4f99534b7bb64ab14f9aa"
87
+ "gitHead": "0ebbfd23c0c3b7983979e5098dbcc1218d7eeaf5"
88
88
  }