@conduction/nextcloud-vue 2.65.0 → 2.66.0
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.
- package/dist/esm/components/CnDashboardPage/CnDashboardPage.vue2.js +99 -2
- package/dist/esm/components/CnDashboardPage/CnDashboardPage.vue2.js.map +1 -1
- package/dist/esm/components/CnDashboardPage/CnDashboardPage.vue3.js +438 -383
- package/dist/esm/components/CnDashboardPage/CnDashboardPage.vue3.js.map +1 -1
- package/dist/esm/components/CnDataTable/CnColumnFilterPopover.vue2.js +9 -3
- package/dist/esm/components/CnDataTable/CnColumnFilterPopover.vue2.js.map +1 -1
- package/dist/esm/components/CnDataTable/CnColumnFilterPopover.vue3.js +1 -1
- package/dist/esm/components/CnDataTable/CnColumnFilterPopover.vue3.js.map +1 -1
- package/dist/esm/components/CnDetailPage/CnDetailPage.vue2.js +78 -21
- package/dist/esm/components/CnDetailPage/CnDetailPage.vue2.js.map +1 -1
- package/dist/esm/components/CnDetailPage/CnDetailPage.vue3.js +129 -96
- package/dist/esm/components/CnDetailPage/CnDetailPage.vue3.js.map +1 -1
- package/dist/esm/components/CnFkResolveCell/CnFkResolveCell.vue2.js +3 -1
- package/dist/esm/components/CnFkResolveCell/CnFkResolveCell.vue2.js.map +1 -1
- package/dist/esm/components/CnFormDialog/CnFormDialog.vue2.js +144 -4
- package/dist/esm/components/CnFormDialog/CnFormDialog.vue2.js.map +1 -1
- package/dist/esm/components/CnFormDialog/CnFormDialog.vue3.js.map +1 -1
- package/dist/esm/components/CnHeaderWidget/CnHeaderWidget.vue2.js +63 -7
- package/dist/esm/components/CnHeaderWidget/CnHeaderWidget.vue2.js.map +1 -1
- package/dist/esm/components/CnHeaderWidget/CnHeaderWidget.vue3.js +2 -1
- package/dist/esm/components/CnHeaderWidget/CnHeaderWidget.vue3.js.map +1 -1
- package/dist/esm/components/CnSegmentedControl/CnSegmentedControl.vue2.js +11 -0
- package/dist/esm/components/CnSegmentedControl/CnSegmentedControl.vue2.js.map +1 -1
- package/dist/esm/components/CnSegmentedControl/CnSegmentedControl.vue3.js +2 -1
- package/dist/esm/components/CnSegmentedControl/CnSegmentedControl.vue3.js.map +1 -1
- package/dist/esm/l10n/en.json.js +3 -0
- package/dist/esm/l10n/en.json.js.map +1 -1
- package/dist/esm/l10n/nl.json.js +3 -0
- package/dist/esm/l10n/nl.json.js.map +1 -1
- package/dist/esm/mixins/pageViews.js +400 -0
- package/dist/esm/mixins/pageViews.js.map +1 -0
- package/dist/esm/nextcloud-vue.css +18 -0
- package/dist/esm/utils/actionsDispatcher.js +11 -2
- package/dist/esm/utils/actionsDispatcher.js.map +1 -1
- package/dist/esm/utils/columnFilters.js +27 -3
- package/dist/esm/utils/columnFilters.js.map +1 -1
- package/dist/esm/utils/schema.js +40 -2
- package/dist/esm/utils/schema.js.map +1 -1
- package/dist/esm/utils/validateManifestV2.compiled.js +2 -2
- package/dist/esm/utils/validateManifestV2.compiled.js.map +1 -1
- package/dist/nextcloud-vue.cjs.js +1521 -596
- package/dist/nextcloud-vue.cjs.js.map +2 -2
- package/dist/nextcloud-vue.css +18 -0
- package/l10n/en.json +3 -0
- package/l10n/nl.json +3 -0
- package/package.json +1 -1
- package/src/components/CnDashboardPage/CnDashboardPage.vue +165 -8
- package/src/components/CnDataTable/CnColumnFilterPopover.vue +11 -5
- package/src/components/CnDetailPage/CnDetailPage.vue +94 -5
- package/src/components/CnFkResolveCell/CnFkResolveCell.vue +3 -1
- package/src/components/CnFormDialog/CnFormDialog.vue +144 -4
- package/src/components/CnHeaderWidget/CnHeaderWidget.vue +67 -8
- package/src/components/CnSegmentedControl/CnSegmentedControl.md +1 -1
- package/src/components/CnSegmentedControl/CnSegmentedControl.vue +12 -0
- package/src/css/detail-page.css +5 -0
- package/src/mixins/pageViews.js +396 -0
- package/src/schemas/app-manifest-v2.schema.json +29 -1
- package/src/utils/actionsDispatcher.js +11 -2
- package/src/utils/columnFilters.js +29 -2
- package/src/utils/schema.js +40 -2
- package/src/utils/validateManifestV2.compiled.js +2 -2
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"pageViews.js","sources":["../../../src/mixins/pageViews.js"],"sourcesContent":["/**\n * SPDX-FileCopyrightText: 2026 Conduction B.V.\n * SPDX-License-Identifier: EUPL-1.2\n *\n * Page views: a few views of one page, each its own widget grid, behind one\n * segmented control (\"My work | My team\").\n *\n * A page that mixes this in accepts `views` (each `{ id, label, icon?,\n * widgets, layout, emptyText? }`), `defaultView` and `viewsLabel`. It keeps\n * the chosen view, writes it to the address (`?view=<id>`) and to the\n * user's preferences (the server, mirrored in the browser), and provides `cnPageViews` so a greeting header widget on\n * the page can draw the switch instead of the page.\n *\n * Which view opens: the address, then the stored view, then `defaultView`,\n * then the first view. An id that names no view is ignored at every step.\n *\n * Used by CnDashboardPage and CnDetailPage. Each renders the chosen view's\n * `layout` with its own grid, so a view looks exactly like the page's own\n * grid.\n *\n * @mixin pageViews\n * @spec openspec/changes/view-switch-containers/specs/view-switch-containers/spec.md#requirement-a-page-declares-views-that-each-hold-a-widget-grid\n */\nimport { translate as t } from '@nextcloud/l10n'\nimport { readUserPreference, USER_PREFERENCE_STORAGE_PREFIX, writeUserPreference } from '../composables/useUserPreferences.js'\n\n/** The query parameter that carries the chosen view. */\nexport const PAGE_VIEW_QUERY_KEY = 'view'\n\n/** Prefix of the user-preference key; the page id follows it. */\nexport const PAGE_VIEW_PREFERENCE_PREFIX = 'cn_page_view:'\n\nlet regionSeq = 0\n\n/**\n * Read the browser mirror of a user preference synchronously, so the stored\n * view is on screen from the first frame. Errors read as nothing stored.\n *\n * @param {string} appId The app id.\n * @param {string} key The preference key.\n * @return {string|null} The stored id, or null.\n * @spec openspec/changes/view-switch-containers/specs/view-switch-containers/spec.md#requirement-the-chosen-view-is-linkable-and-remembered\n */\nfunction readStoredViewMirror(appId, key) {\n\ttry {\n\t\tif (typeof localStorage === 'undefined') {\n\t\t\treturn null\n\t\t}\n\t\tconst raw = localStorage.getItem(`${USER_PREFERENCE_STORAGE_PREFIX}${appId}:${key}`)\n\t\tif (raw === null || raw === undefined) {\n\t\t\treturn null\n\t\t}\n\t\tconst value = JSON.parse(raw)\n\t\treturn typeof value === 'string' && value !== '' ? value : null\n\t} catch {\n\t\treturn null\n\t}\n}\n\nexport const pageViews = {\n\tinject: {\n\t\t/** The host app id, provided by CnAppRoot; keys the stored view. */\n\t\tcnPageViewsAppId: { from: 'cnAppId', default: '' },\n\t},\n\n\tprops: {\n\t\t/**\n\t\t * Views of this page, each its own widget grid behind one segmented\n\t\t * control. Each is `{ id, label, icon?, widgets, layout, emptyText? }`:\n\t\t * `widgets` and `layout` have the same shape as the page's own. The\n\t\t * chosen view renders in a region below the page's own grid. Empty\n\t\t * (the default) draws no switch and no region.\n\t\t *\n\t\t * @type {Array<{id: string, label: string, icon?: string, widgets?: Array<object>, layout?: Array<object>, emptyText?: string}>}\n\t\t */\n\t\tviews: {\n\t\t\ttype: Array,\n\t\t\tdefault: () => [],\n\t\t},\n\n\t\t/**\n\t\t * The id of the view chosen when neither the address nor the browser\n\t\t * store names one. Empty chooses the first view.\n\t\t *\n\t\t * @type {string}\n\t\t */\n\t\tdefaultView: {\n\t\t\ttype: String,\n\t\t\tdefault: '',\n\t\t},\n\n\t\t/**\n\t\t * Accessible name of the view switch (through the host translate\n\t\t * function). Empty reads \"View\".\n\t\t *\n\t\t * @type {string}\n\t\t */\n\t\tviewsLabel: {\n\t\t\ttype: String,\n\t\t\tdefault: '',\n\t\t},\n\t},\n\n\tdata() {\n\t\tregionSeq += 1\n\t\treturn {\n\t\t\t/** The view the user chose in this session, or the stored one. */\n\t\t\tselectedViewId: null,\n\t\t\t/** Whether the user chose a view in this session (a late server read then leaves it alone). */\n\t\t\tviewChosen: false,\n\t\t\t/** Id of the view region, the target of the options' `aria-controls`. */\n\t\t\tviewRegionId: `cn-page-view-region-${regionSeq}`,\n\t\t}\n\t},\n\n\t/**\n\t * Provide the views to descendants, so a greeting header widget in the\n\t * page's grid can draw the switch. Getters keep it reactive.\n\t *\n\t * @return {object} The provided `cnPageViews`.\n\t */\n\tprovide() {\n\t\tconst vm = this\n\t\treturn {\n\t\t\tcnPageViews: {\n\t\t\t\tget views() { return vm.normalizedViews },\n\t\t\t\tget activeId() { return vm.activeViewId },\n\t\t\t\tget regionId() { return vm.viewRegionId },\n\t\t\t\tselect: (id) => vm.selectView(id),\n\t\t\t},\n\t\t}\n\t},\n\n\tcomputed: {\n\t\t/**\n\t\t * The declared views in one shape, labels translated. Entries without\n\t\t * an id or a label are dropped, as are repeated ids.\n\t\t *\n\t\t * @return {Array<{id: string, label: string, icon: string, widgets: Array<object>, layout: Array<object>, emptyText: string}>}\n\t\t * @spec openspec/changes/view-switch-containers/specs/view-switch-containers/spec.md#requirement-a-page-declares-views-that-each-hold-a-widget-grid\n\t\t */\n\t\tnormalizedViews() {\n\t\t\tconst translate = typeof this.cnTranslate === 'function' ? this.cnTranslate : (key) => key\n\t\t\tconst seen = new Set()\n\t\t\treturn (Array.isArray(this.views) ? this.views : [])\n\t\t\t\t.filter((view) => {\n\t\t\t\t\tif (!view || typeof view !== 'object' || view.id === undefined || view.id === null || view.id === '') {\n\t\t\t\t\t\treturn false\n\t\t\t\t\t}\n\t\t\t\t\tif (typeof view.label !== 'string' || view.label === '' || seen.has(String(view.id))) {\n\t\t\t\t\t\treturn false\n\t\t\t\t\t}\n\t\t\t\t\tseen.add(String(view.id))\n\t\t\t\t\treturn true\n\t\t\t\t})\n\t\t\t\t.map((view) => ({\n\t\t\t\t\tid: String(view.id),\n\t\t\t\t\tlabel: translate(view.label),\n\t\t\t\t\ticon: typeof view.icon === 'string' ? view.icon : '',\n\t\t\t\t\twidgets: Array.isArray(view.widgets) ? view.widgets : [],\n\t\t\t\t\tlayout: Array.isArray(view.layout) ? view.layout : [],\n\t\t\t\t\temptyText: typeof view.emptyText === 'string' && view.emptyText !== '' ? translate(view.emptyText) : '',\n\t\t\t\t}))\n\t\t},\n\n\t\t/**\n\t\t * Whether this page has views.\n\t\t *\n\t\t * @return {boolean}\n\t\t */\n\t\thasViews() {\n\t\t\treturn this.normalizedViews.length > 0\n\t\t},\n\n\t\t/**\n\t\t * The chosen view's id: the address, then this session's or the\n\t\t * stored choice, then `defaultView`, then the first view.\n\t\t *\n\t\t * @return {string|null} The id, or null without views.\n\t\t * @spec openspec/changes/view-switch-containers/specs/view-switch-containers/spec.md#requirement-the-chosen-view-is-linkable-and-remembered\n\t\t */\n\t\tactiveViewId() {\n\t\t\tconst views = this.normalizedViews\n\t\t\tif (views.length === 0) {\n\t\t\t\treturn null\n\t\t\t}\n\t\t\tconst known = (id) => id !== null && id !== undefined && views.some((view) => view.id === String(id))\n\t\t\tconst fromAddress = this.$route && this.$route.query ? this.$route.query[PAGE_VIEW_QUERY_KEY] : undefined\n\t\t\tif (known(fromAddress)) {\n\t\t\t\treturn String(fromAddress)\n\t\t\t}\n\t\t\tif (known(this.selectedViewId)) {\n\t\t\t\treturn String(this.selectedViewId)\n\t\t\t}\n\t\t\tif (known(this.defaultView)) {\n\t\t\t\treturn this.defaultView\n\t\t\t}\n\t\t\treturn views[0].id\n\t\t},\n\n\t\t/**\n\t\t * The chosen view, or null without views.\n\t\t *\n\t\t * @return {object|null}\n\t\t */\n\t\tactiveView() {\n\t\t\treturn this.normalizedViews.find((view) => view.id === this.activeViewId) || null\n\t\t},\n\n\t\t/**\n\t\t * The switch's options, for CnSegmentedControl.\n\t\t *\n\t\t * @return {Array<{value: string, label: string}>}\n\t\t */\n\t\tviewSwitchOptions() {\n\t\t\treturn this.normalizedViews.map((view) => ({ value: view.id, label: view.label }))\n\t\t},\n\n\t\t/**\n\t\t * The switch's accessible name: `viewsLabel` translated, else \"View\".\n\t\t *\n\t\t * @return {string}\n\t\t * @spec openspec/changes/view-switch-containers/specs/view-switch-containers/spec.md#requirement-the-view-switch-is-accessible\n\t\t */\n\t\tviewSwitchLabel() {\n\t\t\tconst translate = typeof this.cnTranslate === 'function' ? this.cnTranslate : (key) => key\n\t\t\treturn this.viewsLabel ? translate(this.viewsLabel) : t('nextcloud-vue', 'Views')\n\t\t},\n\n\t\t/**\n\t\t * Whether a greeting header in the page's own widgets draws the\n\t\t * switch (an option with a `view`), so the page draws none.\n\t\t *\n\t\t * @return {boolean}\n\t\t * @spec openspec/changes/view-switch-containers/specs/view-switch-containers/spec.md#requirement-a-greeting-header-can-switch-the-pages-views\n\t\t */\n\t\tviewSwitchInHeaderWidget() {\n\t\t\tconst widgets = Array.isArray(this.widgets) ? this.widgets : []\n\t\t\treturn widgets.some((def) => {\n\t\t\t\tconst options = def && def.content && def.content.views && def.content.views.options\n\t\t\t\treturn Array.isArray(options) && options.some((option) => option && typeof option.view === 'string' && option.view !== '')\n\t\t\t})\n\t\t},\n\n\t\t/**\n\t\t * Whether the page draws the switch itself.\n\t\t *\n\t\t * @return {boolean}\n\t\t */\n\t\tshowsPageViewSwitch() {\n\t\t\treturn this.hasViews && !this.viewSwitchInHeaderWidget\n\t\t},\n\n\t\t/**\n\t\t * The user-preference key for this page's chosen view.\n\t\t *\n\t\t * @return {string}\n\t\t */\n\t\tviewPreferenceKey() {\n\t\t\t// The page id, else the route name: a detail page's fallback id is\n\t\t\t// its record's title, which would remember a view per record.\n\t\t\tconst id = this.pageId || (this.$route && this.$route.name) || this.resolvedPageId || 'page'\n\t\t\treturn `${PAGE_VIEW_PREFERENCE_PREFIX}${id}`\n\t\t},\n\n\t\t/**\n\t\t * The app id the stored view is kept under: the page's `appId` prop\n\t\t * when it has one, else the app root's.\n\t\t *\n\t\t * @return {string}\n\t\t */\n\t\tviewPreferenceAppId() {\n\t\t\tconst own = typeof this.appId === 'string' ? this.appId : ''\n\t\t\treturn own || (typeof this.cnPageViewsAppId === 'string' ? this.cnPageViewsAppId : '')\n\t\t},\n\n\t\t/**\n\t\t * The message of the chosen view's empty state.\n\t\t *\n\t\t * @return {string}\n\t\t * @spec openspec/changes/view-switch-containers/specs/view-switch-containers/spec.md#requirement-a-view-with-nothing-to-draw-says-so\n\t\t */\n\t\tviewEmptyText() {\n\t\t\tif (this.activeView && this.activeView.emptyText) {\n\t\t\t\treturn this.activeView.emptyText\n\t\t\t}\n\t\t\treturn t('nextcloud-vue', 'This view has no widgets yet.')\n\t\t},\n\t},\n\n\tcreated() {\n\t\tthis.loadStoredView()\n\t},\n\n\tmethods: {\n\t\t/**\n\t\t * Read the stored view: the browser mirror at once, then the user\n\t\t * preference on the server, which wins unless the user already chose.\n\t\t *\n\t\t * @return {Promise<void>}\n\t\t * @spec openspec/changes/view-switch-containers/specs/view-switch-containers/spec.md#requirement-the-chosen-view-is-linkable-and-remembered\n\t\t */\n\t\tasync loadStoredView() {\n\t\t\tif (!this.hasViews) {\n\t\t\t\treturn\n\t\t\t}\n\t\t\tconst appId = this.viewPreferenceAppId\n\t\t\tconst key = this.viewPreferenceKey\n\t\t\tthis.selectedViewId = readStoredViewMirror(appId, key)\n\t\t\tif (!appId) {\n\t\t\t\treturn\n\t\t\t}\n\t\t\tconst stored = await readUserPreference(appId, key, null)\n\t\t\tif (!this.viewChosen && typeof stored === 'string' && stored !== '') {\n\t\t\t\tthis.selectedViewId = stored\n\t\t\t}\n\t\t},\n\n\t\t/**\n\t\t * Choose a view: keep it, store it, and write it to the address\n\t\t * (replacing the history entry, keeping the other query keys).\n\t\t *\n\t\t * @param {string} id The view id.\n\t\t * @return {void}\n\t\t * @spec openspec/changes/view-switch-containers/specs/view-switch-containers/spec.md#requirement-the-chosen-view-is-linkable-and-remembered\n\t\t */\n\t\tselectView(id) {\n\t\t\tconst view = this.normalizedViews.find((candidate) => candidate.id === String(id))\n\t\t\tif (!view) {\n\t\t\t\treturn\n\t\t\t}\n\t\t\tthis.selectedViewId = view.id\n\t\t\tthis.viewChosen = true\n\t\t\twriteUserPreference(this.viewPreferenceAppId, this.viewPreferenceKey, view.id)\n\t\t\tif (!this.$router || !this.$route) {\n\t\t\t\treturn\n\t\t\t}\n\t\t\tconst query = this.$route.query || {}\n\t\t\tif (query[PAGE_VIEW_QUERY_KEY] === view.id) {\n\t\t\t\treturn\n\t\t\t}\n\t\t\tconst result = this.$router.replace({ query: { ...query, [PAGE_VIEW_QUERY_KEY]: view.id } })\n\t\t\tif (result && typeof result.catch === 'function') {\n\t\t\t\tresult.catch(() => {})\n\t\t\t}\n\t\t},\n\n\t\t/**\n\t\t * Look a widget definition up in the views, for a layout item of the\n\t\t * chosen view.\n\t\t *\n\t\t * @param {string} widgetId The widget id.\n\t\t * @return {object|null} The definition, or null.\n\t\t */\n\t\tfindViewWidget(widgetId) {\n\t\t\tconst view = this.activeView\n\t\t\tif (!view) {\n\t\t\t\treturn null\n\t\t\t}\n\t\t\treturn view.widgets.find((def) => def && def.id === widgetId) || null\n\t\t},\n\n\t\t/**\n\t\t * Write a drag or resize in the chosen view's grid back onto its\n\t\t * layout items in place, as the page does for its own layout, so the\n\t\t * in-app manifest editor sees it.\n\t\t *\n\t\t * @param {Array<object>} updated The layout from the grid.\n\t\t * @return {void}\n\t\t */\n\t\tonViewLayoutChange(updated) {\n\t\t\tconst view = this.activeView\n\t\t\tif (!view || !Array.isArray(updated)) {\n\t\t\t\treturn\n\t\t\t}\n\t\t\tfor (const u of updated) {\n\t\t\t\tconst item = view.layout.find((l) => String(l.id) === String(u.id))\n\t\t\t\tif (!item) {\n\t\t\t\t\tcontinue\n\t\t\t\t}\n\t\t\t\tfor (const key of ['gridX', 'gridY', 'gridWidth', 'gridHeight']) {\n\t\t\t\t\tif (u[key] !== undefined) {\n\t\t\t\t\t\titem[key] = u[key]\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\t/**\n\t\t\t * Emitted when a widget in a view's grid is dragged or resized.\n\t\t\t *\n\t\t\t * @event view-layout-change\n\t\t\t * @type {{view: string, layout: Array<object>}}\n\t\t\t */\n\t\t\tthis.$emit('view-layout-change', { view: view.id, layout: view.layout })\n\t\t},\n\t},\n}\n"],"names":["translate","t"],"mappings":";;;AAAA;AACA;AACA;AACA;AACA;AACA;AACA;A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AK,MAAM,GAAG,IAAI,CAAC,OAAO,EAAE,OAAO,EAAE,WAAW,EAAE,YAAY,CAAC,EAAE;AACrE,KAAK,IAAI,CAAC,CAAC,GAAG,CAAC,KAAK,SAAS,EAAE;AAC/B,MAAM,IAAI,CAAC,GAAG,CAAC,GAAG,CAAC,CAAC,GAAG,EAAC;AACxB,MAAM;AACN,KAAK;AACL,IAAI;AACJ;AACA;AACA;AACA;AACA;AACA;AACA,GAAG,IAAI,CAAC,KAAK,CAAC,oBAAoB,EAAE,EAAE,IAAI,EAAE,IAAI,CAAC,EAAE,EAAE,MAAM,EAAE,IAAI,CAAC,MAAM,EAAE,EAAC;AAC3E,GAAG;AACH,EAAE;AACF;;;;"}
|
|
@@ -3279,6 +3279,11 @@ a.cn-kpi-card--stacked:focus-visible {
|
|
|
3279
3279
|
font-size: 0.9em;
|
|
3280
3280
|
white-space: nowrap;
|
|
3281
3281
|
}
|
|
3282
|
+
|
|
3283
|
+
/* A page view the switch shows with nothing to draw (view-switch-containers). */
|
|
3284
|
+
.cn-detail-page .cn-page-view-region--empty {
|
|
3285
|
+
padding: 40px 20px;
|
|
3286
|
+
}
|
|
3282
3287
|
/* CnReferencePreview — a reference that shows what it points at. */
|
|
3283
3288
|
|
|
3284
3289
|
.cn-reference-preview {
|
|
@@ -30567,6 +30572,19 @@ to {
|
|
|
30567
30572
|
.cn-dashboard-page__empty[data-v-824052fe] {
|
|
30568
30573
|
padding: 60px 20px;
|
|
30569
30574
|
}
|
|
30575
|
+
|
|
30576
|
+
/* The page's view switch on a page without a header row: at the end of its
|
|
30577
|
+
own row, above the grids, where the header would have put it. */
|
|
30578
|
+
.cn-dashboard-page__view-switch[data-v-824052fe] {
|
|
30579
|
+
display: flex;
|
|
30580
|
+
justify-content: flex-end;
|
|
30581
|
+
margin-bottom: 12px;
|
|
30582
|
+
}
|
|
30583
|
+
|
|
30584
|
+
/* A view the switch shows with nothing to draw. */
|
|
30585
|
+
.cn-page-view-region--empty[data-v-824052fe] {
|
|
30586
|
+
padding: 40px 20px;
|
|
30587
|
+
}
|
|
30570
30588
|
.cn-dashboard-page__page-filters[data-v-824052fe] {
|
|
30571
30589
|
display: flex;
|
|
30572
30590
|
flex-wrap: wrap;
|
|
@@ -94,6 +94,14 @@ function isExternalActionTarget(target) {
|
|
|
94
94
|
* would otherwise register — and fetch — a 404 (defect 7, learniq round
|
|
95
95
|
* 1). Idempotent for a caller that already passes a correct slug.
|
|
96
96
|
*
|
|
97
|
+
* A caller that already holds the schema SLUG (not a `$ref` title) passes
|
|
98
|
+
* `{ exactSchema: true }`: the slug is then used exactly as given. Kebab-casing
|
|
99
|
+
* a real camelCase slug (`productCategory` -> `product-category`) asks the
|
|
100
|
+
* objects API for a schema that does not exist and 404s (pipelinq review,
|
|
101
|
+
* round two).
|
|
102
|
+
*
|
|
103
|
+
* @spec openspec/changes/review-round-two/specs/schema-utilities/spec.md
|
|
104
|
+
*
|
|
97
105
|
* A title is not always registered under its kebab form: learniq holds
|
|
98
106
|
* `LearniqSettings` and `SubjectTeacherAssignment` as written. So a type
|
|
99
107
|
* registered here for a value the kebab rule CHANGED also carries the value
|
|
@@ -104,11 +112,12 @@ function isExternalActionTarget(target) {
|
|
|
104
112
|
* @spec openspec/changes/zuiddrecht-pixel-gaps-2/specs/zuiddrecht-pixel-gaps-2/spec.md#requirement-a-schema-title-falls-back-to-its-written-form
|
|
105
113
|
* @param {object} store The object store instance (useObjectStore shape).
|
|
106
114
|
* @param {{register: (string|number), schema: (string|number)}} source The widget source.
|
|
115
|
+
* @param {{exactSchema: (boolean|undefined)}} [options] `exactSchema: true` skips the title-to-slug step.
|
|
107
116
|
* @return {string} The type slug to use for store CRUD calls.
|
|
108
117
|
*/
|
|
109
|
-
function resolveObjectOpType(store, source) {
|
|
118
|
+
function resolveObjectOpType(store, source, options = {}) {
|
|
110
119
|
const register = String(source.register);
|
|
111
|
-
const schema = String(schemaRefSlug(source.schema));
|
|
120
|
+
const schema = options.exactSchema === true ? String(source.schema) : String(schemaRefSlug(source.schema));
|
|
112
121
|
const written = typeof source.schema === 'string'
|
|
113
122
|
? source.schema.substring(source.schema.lastIndexOf('/') + 1)
|
|
114
123
|
: '';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"actionsDispatcher.js","sources":["../../../src/utils/actionsDispatcher.js"],"sourcesContent":["/**\n * SPDX-FileCopyrightText: 2024 Conduction B.V.\n * SPDX-License-Identifier: EUPL-1.2\n *\n * actionsDispatcher — unified action dispatcher for v2 manifest actions.\n *\n * Dispatches an action object against a context. All dispatch types are\n * handled without throwing — errors surface as console.warn calls.\n * Types: handler | open-modal | open-page | navigate | object-op (the\n * declarative OpenRegister mutation verb added by ADR-049 — dispatched\n * via the shared object store, intent-only, RBAC stays server-side) |\n * export (opens the shared CnMassExportDialog export launcher configured\n * via the action's `entities[]` / `formats[]` — Wave 1 of\n * nextcloud-vue#91; the host page provides `context.openExport`) |\n * open-form (Wave 3 — schema-driven create dialog; the rendering host\n * provides `context.openForm`) | refresh (Wave 3 — bumps the page-level\n * refresh signal on the `cn:page:refresh` event-bus channel) | api-call\n * (Wave 3 — POST/PUT a configured app endpoint with success/error toasts\n * and an automatic page refresh; any `confirm` on the action is INTENT\n * consumed by the rendering surface BEFORE dispatch, like object-op) |\n * agent (run a governed hermiq agent against the page object via\n * POST /apps/hermiq/api/agents/{agent}/run-on-object — hermiq#41; a\n * first-class companion to api-call that resolves the register/schema/\n * objectId context for the author and fail-closes when hermiq is absent) |\n * run-node (manifest-run-node-action — invoke ONE OpenRegister flow node\n * directly against a subject object via\n * POST /api/flows/{flowId}/nodes/{nodeId}/run; the rendering surface\n * provides context.openRunNode, mirroring open-form, and resolves the\n * node's own declared config form before opening a dialog — see or-flow-run-node).\n *\n * `api-call`'s request body prefers `payload` (DEEP @-token resolution at\n * any nesting depth — object/array, e.g. a Filinq-style\n * `{ dataRefs: [{ id: '@objectId' }] }` body) over the legacy `params`\n * (shallow, one-level filter-map resolution, kept for back-compat). Set\n * `download: true` to request a binary blob response and trigger a\n * browser file download instead of a JSON toast+refresh cycle (filename:\n * `Content-Disposition` header, else the token-resolved `filename`, else\n * `'download.pdf'`; no auto-refresh unless `refresh: true` is explicit).\n *\n * `toggle` (Wave 3) is deliberately NOT dispatchable: a toggle is a\n * stateful two-way control (GET state on mount, write on click) rendered\n * by the header-actions surface (CnActionButtons); dispatching it here\n * warns and no-ops.\n *\n * Spec: REQ-MVR-011 (manifest-v2-renderer) — unified actions dispatcher\n * / ADR-036 Decision 7 / ADR-049 Decision 2 / #91 Wave 3\n */\n\nimport { emit } from '@nextcloud/event-bus'\nimport { translate as t } from '@nextcloud/l10n'\nimport { parseDispositionFilename, triggerBlobDownload } from '../components/CnIndexPage/selfModeIO.js'\nimport { interpolateUrlTokens } from '../composables/useEndpointSource.js'\nimport { routeHref } from './actionLink.js'\nimport {\n\tdropOptionalUnresolved,\n\tdropOptionalUnresolvedDeep,\n\thasUnresolvedDeepTokens,\n\thasUnresolvedTokens,\n\tresolveDeepTokens,\n\tresolveFilterTokens,\n} from './resolveFilterTokens.js'\nimport { schemaRefSlug } from './schemaRefSlug.js'\n\n/** Event-bus channel the page-level Refresh signal broadcasts on (Wave 2). */\nconst PAGE_REFRESH_CHANNEL = 'cn:page:refresh'\n\n/**\n * Whether a `navigate` target leaves the app: it is `http(s)://`,\n * protocol-relative (`//`), or a `mailto:` / `tel:` link. Anything else is an\n * in-app path for the router.\n *\n * vue-router happily accepts an absolute URL as a PATH — `router.push` on\n * `https://youtu.be/x?v=1` matches no route and lands on the fallback with the\n * query carried over, which reads as the app ignoring the link.\n *\n * An allowlist, not a generic `<scheme>://` match: manifests are\n * admin-editable app-wide config, and an external target renders into an\n * anchor `href` and a dispatcher `window.open` — a generic scheme match would\n * accept `javascript://` too.\n *\n * @param {unknown} target The action target to test.\n * @return {boolean} True when the target is external.\n */\nexport function isExternalActionTarget(target) {\n\tif (typeof target !== 'string') {\n\t\treturn false\n\t}\n\treturn /^\\/\\//.test(target) || /^(https?|mailto|tel):/i.test(target)\n}\n\n/**\n * Resolve the object-store type slug for a widget `source` register/schema\n * pair. Reuses an already-registered type whose config matches (so an app's\n * own caches stay coherent); otherwise registers a deterministic\n * `<register>/<schema>` slug on the fly.\n *\n * `source.schema` is routed through {@link schemaRefSlug} before it ever\n * reaches the store or the objects API: a caller that passes a `$ref`\n * schema TITLE (`ReportPeriod`) rather than its slug (`report-period`)\n * would otherwise register — and fetch — a 404 (defect 7, learniq round\n * 1). Idempotent for a caller that already passes a correct slug.\n *\n * A title is not always registered under its kebab form: learniq holds\n * `LearniqSettings` and `SubjectTeacherAssignment` as written. So a type\n * registered here for a value the kebab rule CHANGED also carries the value\n * as written as its `schemaFallback`, and the store retries with it once\n * when the kebab form answers 404 (keeping it from then on). The kebab form\n * is still tried first, so a schema registered under it costs nothing.\n *\n * @spec openspec/changes/zuiddrecht-pixel-gaps-2/specs/zuiddrecht-pixel-gaps-2/spec.md#requirement-a-schema-title-falls-back-to-its-written-form\n * @param {object} store The object store instance (useObjectStore shape).\n * @param {{register: (string|number), schema: (string|number)}} source The widget source.\n * @return {string} The type slug to use for store CRUD calls.\n */\nexport function resolveObjectOpType(store, source) {\n\tconst register = String(source.register)\n\tconst schema = String(schemaRefSlug(source.schema))\n\tconst written = typeof source.schema === 'string'\n\t\t? source.schema.substring(source.schema.lastIndexOf('/') + 1)\n\t\t: ''\n\tconst registry = store.objectTypeRegistry || {}\n\tfor (const [slug, config] of Object.entries(registry)) {\n\t\tif (!config) {\n\t\t\tcontinue\n\t\t}\n\t\tif ((String(config.register) === register && String(config.schema) === schema)\n\t\t\t|| (config.registerSlug === register && config.schemaSlug === schema)) {\n\t\t\treturn slug\n\t\t}\n\t}\n\tconst slug = `${register}/${schema}`\n\tif (!registry[slug]) {\n\t\tstore.registerObjectType(slug, schema, register)\n\t\tif (written !== '' && written !== schema && typeof store.setSchemaFallback === 'function') {\n\t\t\tstore.setSchemaFallback(slug, written)\n\t\t}\n\t}\n\treturn slug\n}\n\n/**\n * Extract an OpenRegister object's id from a row (top-level `id` wins,\n * `@self.id` metadata fallback).\n *\n * @param {object} row The row object.\n * @return {string|number|null} The object id, or null when absent.\n */\nfunction rowObjectId(row) {\n\tif (!row || typeof row !== 'object') {\n\t\treturn null\n\t}\n\tif (row.id !== undefined && row.id !== null) {\n\t\treturn row.id\n\t}\n\tconst self = row['@self']\n\tif (self && typeof self === 'object' && self.id !== undefined && self.id !== null) {\n\t\treturn self.id\n\t}\n\treturn null\n}\n\n/**\n * Extract a saved OpenRegister object's id for a post-save deep-link:\n * top-level `id`, then `uuid`, then the `@self.id` metadata fallback.\n *\n * @param {object} saved The saved record returned by the object store.\n * @return {string|number|null} The object id, or null when absent.\n */\nexport function savedObjectId(saved) {\n\tif (!saved || typeof saved !== 'object') {\n\t\treturn null\n\t}\n\tif (saved.id !== undefined && saved.id !== null) {\n\t\treturn saved.id\n\t}\n\tif (saved.uuid !== undefined && saved.uuid !== null) {\n\t\treturn saved.uuid\n\t}\n\tconst self = saved['@self']\n\tif (self && typeof self === 'object' && self.id !== undefined && self.id !== null) {\n\t\treturn self.id\n\t}\n\treturn null\n}\n\n/**\n * Resolve a manifest-named FUNCTION out of the v2 registry, falling back to the\n * legacy customComponents map.\n *\n * A manifest names a behaviour the same way it names a component — by string —\n * so every surface that dispatches one (`actions[].handler`,\n * `bulkActions[].handler`, `headerActions[].handler`, `config.createOverride`)\n * has to agree on where that string is looked up and what counts as a match.\n * Recognised shapes, in order:\n * 1. a registry entry exposing the function as `.handler` / `.fn` (the\n * `kind: 'handler'` and `kind: 'create-override'` entries),\n * 2. a directly function-valued registry entry,\n * 3. a function-valued legacy `customComponents` entry.\n *\n * The legacy map stays last so an app that has not migrated is unchanged, and\n * so an app mid-migration can move its handlers over one at a time.\n *\n * @param {string} name The registered handler name.\n * @param {object} registry The v2 component registry.\n * @param {object} customComponents The legacy customComponents map.\n * @return {?((scope?: object) => unknown)} The handler, or null when nothing of that name is a function.\n */\nexport function resolveRegisteredHandler(name, registry, customComponents) {\n\tif (typeof name !== 'string' || name === '') {\n\t\treturn null\n\t}\n\tconst entry = (registry || {})[name]\n\tif (typeof entry === 'function') {\n\t\treturn entry\n\t}\n\tif (entry && typeof entry === 'object') {\n\t\tif (typeof entry.handler === 'function') {\n\t\t\treturn entry.handler\n\t\t}\n\t\tif (typeof entry.fn === 'function') {\n\t\t\treturn entry.fn\n\t\t}\n\t}\n\tconst legacy = (customComponents || {})[name]\n\treturn typeof legacy === 'function' ? legacy : null\n}\n\n/**\n * Resolve a named create-override handler out of the v2 registry (or the\n * legacy customComponents map) by value shape.\n *\n * A create-override is a plain async function that replaces the default\n * `objectStore.saveObject` persist path — needed whenever a schema requires a\n * field the create form cannot supply on its own (a server-minted foreign key,\n * say).\n *\n * Shared by CnPageRenderer (page-level `config.createOverride` → CnIndexPage's\n * prop) and CnActionButtons (per-action `createOverride` on an `open-form`), so\n * the two surfaces cannot drift on what counts as a valid handler.\n *\n * @param {string} name The registered handler name.\n * @param {object} registry The v2 component registry.\n * @param {object} customComponents The legacy customComponents map.\n * @return {?((props?: object) => Promise<unknown>)} The async create handler, or null when unresolved.\n */\nexport function resolveCreateOverrideHandler(name, registry, customComponents) {\n\treturn resolveRegisteredHandler(name, registry, customComponents)\n}\n\n/**\n * Build the vue-router push location for an `open-form` action's\n * `onSuccessRoute`, merging the saved object's id into the route params so\n * the post-save navigation can deep-link to the created object's detail page\n * (#91).\n *\n * `onSuccessRoute` may be:\n * - a STRING route NAME → `{ name, params: { id } }`. The saved id lands\n * under the default `id` param; a route without an `:id` segment simply\n * ignores the extra param, so a bare-name route keeps working unchanged\n * (backward compatible).\n * - an OBJECT `{ name, paramField?, objectParam? }` → the id is placed\n * under `paramField` (default `id`), and — when `objectParam` is set —\n * the whole saved object is passed under that param key too (so a\n * `props: true` detail route can render the record without a refetch).\n *\n * The id is read via {@link savedObjectId} (`saved.id` → `saved.uuid` →\n * `saved['@self'].id`). Returns `null` when no route name is resolvable, so\n * the caller can skip the navigation.\n *\n * @param {(string|{name: string, paramField?: string, objectParam?: string})} onSuccessRoute The action's onSuccessRoute config.\n * @param {object} saved The saved OpenRegister object.\n * @return {{name: string, params: object}|null} The router push location, or null.\n */\nexport function buildOnSuccessRoute(onSuccessRoute, saved) {\n\tconst spec = typeof onSuccessRoute === 'string'\n\t\t? { name: onSuccessRoute }\n\t\t: (onSuccessRoute && typeof onSuccessRoute === 'object' ? onSuccessRoute : null)\n\tif (!spec || typeof spec.name !== 'string' || spec.name === '') {\n\t\treturn null\n\t}\n\tconst params = {}\n\tconst id = savedObjectId(saved)\n\tif (id !== null && id !== undefined) {\n\t\tparams[spec.paramField || 'id'] = id\n\t}\n\tif (spec.objectParam && saved && typeof saved === 'object') {\n\t\tparams[spec.objectParam] = saved\n\t}\n\treturn { name: spec.name, params }\n}\n\n/**\n * Run a manifest-authored toast message through the host translate function.\n *\n * `successMessage` / `errorMessage` are English source strings authored in the\n * manifest (ADR-007), so they need the SAME translator the rest of the page\n * chrome uses — the consumer's bound `t()`, handed to the dispatcher by the\n * rendering surface as `context.translate` (which itself comes from the\n * `cnTranslate` CnAppRoot provides).\n *\n * A pure pass-through: with no translator, no message, or a catalogue that\n * lacks the key, the message is returned byte-identical. Server-supplied\n * messages are data and are never routed through here.\n *\n * @param {unknown} message The manifest-authored message (may be undefined).\n * @param {object} context The dispatch context (`context.translate` optional).\n * @return {unknown} The translated message, or the input unchanged.\n */\nfunction translateMessage(message, context) {\n\tconst fn = context && context.translate\n\tif (!message || typeof fn !== 'function') {\n\t\treturn message\n\t}\n\treturn fn(message)\n}\n\n/**\n * Interpolate the `api-call` URL/filename token grammar inside a string:\n * the `{objectId}` BRACE convention (a literal placeholder some manifests\n * use for path templates, matching the OpenRegister credential-broker path\n * style) as well as the full `@objectId` / `@object.<field>` /\n * `@workspace.<key>` / `@config.<key>` grammar {@link interpolateUrlTokens}\n * already understands. Unresolved `@`-tokens and an unresolved\n * `{objectId}` both collapse to an empty string (never leak a literal\n * placeholder into a request URL or a downloaded filename).\n *\n * @param {string} str The raw string (an action's `url` or `filename`).\n * @param {{objectId?: (string|number), object?: object, workspace?: object, config?: object}} ctx Token context.\n * @return {string} The interpolated string.\n */\nfunction interpolateActionString(str, ctx) {\n\tif (typeof str !== 'string') {\n\t\treturn str\n\t}\n\tconst braced = str.replace(/\\{objectId\\}/g, () => {\n\t\tconst id = ctx.objectId\n\t\treturn (id === undefined || id === null) ? '' : String(id)\n\t})\n\treturn interpolateUrlTokens(braced, ctx)\n}\n\n/**\n * Interpolate an action's `target` URL — the same grammar `url` runs.\n *\n * Exported because the rendering surface resolves a target BEFORE deciding\n * whether it is an external link, and that decision happens there rather than\n * in the dispatcher.\n *\n * @param {string} target The action's raw `target`.\n * @param {object} ctx Token context (`{ objectId?, object?, workspace?, config? }`).\n *\n * @return {string} The interpolated target.\n */\nexport function interpolateActionTarget(target, ctx) {\n\treturn interpolateActionString(target || '', ctx || {})\n}\n\n// The tokens interpolateActionString resolves; a bare `@` or `{` is not one.\nconst ACTION_TARGET_TOKEN = /@(?:objectId|object\\.|page\\.|workspace\\.|config\\.|range\\.)|\\{objectId\\}/\n\n/**\n * Whether an action target carries a token that interpolation would resolve,\n * so it can only be known once the page context is. A `mailto:` address or a\n * URL with an `@handle` in it has none.\n *\n * @param {string} target The action's raw `target`.\n * @return {boolean}\n */\nexport function hasActionTargetTokens(target) {\n\treturn typeof target === 'string' && ACTION_TARGET_TOKEN.test(target)\n}\n\n/**\n * The link an action renders as when its only job is to navigate to a target\n * known at render time: `navigate` (token-interpolated like the dispatcher)\n * and `open-page`. Anything else, a `confirm: true` action, or an in-app\n * target the router cannot resolve answers null and keeps dispatching.\n *\n * `to` is what a plain click hands the router (null for an external URL,\n * which the browser opens in a new tab like the dispatcher's `window.open`).\n *\n * @param {object} action The manifest action.\n * @param {{router?: object, tokenCtx?: object}} [context] The dispatch context.\n * @return {{href: string, to: (string|object|null), external: boolean}|null} The link, or null.\n */\nexport function actionLink(action, context = {}) {\n\tif (!action || typeof action !== 'object' || action.confirm) {\n\t\treturn null\n\t}\n\tif (action.type === 'navigate') {\n\t\tconst target = interpolateActionString(action.target || '', context.tokenCtx || {})\n\t\tif (!target) {\n\t\t\treturn null\n\t\t}\n\t\tif (isExternalActionTarget(target)) {\n\t\t\treturn { href: target, to: null, external: true }\n\t\t}\n\t\tconst href = routeHref(target, context.router)\n\t\treturn href ? { href, to: target, external: false } : null\n\t}\n\tif (action.type === 'open-page') {\n\t\tif (typeof action.target !== 'string' || action.target.length === 0) {\n\t\t\treturn null\n\t\t}\n\t\tconst to = { name: action.target }\n\t\tconst href = routeHref(to, context.router)\n\t\treturn href ? { href, to, external: false } : null\n\t}\n\treturn null\n}\n\n/**\n * Execute a Wave-3 `api-call` action: POST/PUT the configured app endpoint\n * (URL + body run the SAME @-token grammar endpoint sources use), toast the\n * outcome via @nextcloud/dialogs, then — unless `action.refresh` is `false`\n * (or, for a `download` action, unless `action.refresh` is explicitly\n * `true`) — bump the page-level refresh signal so every endpoint-bound\n * widget refetches. Confirm-gating is the RENDERING SURFACE's job (the\n * `confirm` field is intent, object-op precedent): this runs after any\n * confirmation already happened.\n *\n * The request body prefers `action.payload` (DEEP token resolution, any\n * nesting — {@link resolveDeepTokens}) over the legacy `action.params`\n * (shallow, one-level filter-map resolution — unchanged for back-compat).\n * A required token left unresolved anywhere in the body BLOCKS the call\n * (error toast) rather than sending a literal `@objectId` to the server.\n *\n * `action.download === true` requests the response as a binary blob\n * (`responseType: 'blob'`) and triggers a browser file download — the\n * filename comes from the response's `Content-Disposition` header, else\n * the token-resolved `action.filename`, else `'download.pdf'`.\n *\n * Never throws: a failed call resolves `{ ok: false, error }` after the\n * error toast (so a confirm dialog can await the outcome).\n *\n * @param {object} action The api-call action (`url`, `method?`, `payload?`,\n * `params?`, `download?`, `filename?`, `successMessage?`, `errorMessage?`,\n * `refresh?`).\n * @param {object} context Runtime context; `context.tokenCtx` is the token\n * context (`{ objectId?, object?, workspace?, config? }`) the URL/body\n * resolve against.\n * @return {Promise<{ok: boolean, data?: unknown, error?: unknown}>} The call outcome.\n */\nasync function executeApiCall(action, context) {\n\tconst tokenCtx = context.tokenCtx || {}\n\tconst url = interpolateActionString(action.url || '', tokenCtx)\n\n\tconst hasPayload = action.payload && typeof action.payload === 'object' && !Array.isArray(action.payload)\n\tconst body = hasPayload\n\t\t? dropOptionalUnresolvedDeep(resolveDeepTokens(action.payload, tokenCtx))\n\t\t: dropOptionalUnresolved(resolveFilterTokens(action.params || {}, tokenCtx))\n\tconst bodyBlocked = hasPayload ? hasUnresolvedDeepTokens(body) : hasUnresolvedTokens(body)\n\n\tif (!url || bodyBlocked) {\n\t\t// eslint-disable-next-line no-console\n\t\tconsole.warn('[dispatchAction] api-call is missing its url or a required token is unresolved — skipping.', action)\n\t\treturn { ok: false, error: new Error('api-call blocked') }\n\t}\n\tconst method = String(action.method || 'POST').toUpperCase() === 'PUT' ? 'put' : 'post'\n\tconst isDownload = action.download === true\n\tconst [{ default: axios }, { generateUrl }, dialogs] = await Promise.all([\n\t\timport('@nextcloud/axios'),\n\t\timport('@nextcloud/router'),\n\t\timport('@nextcloud/dialogs'),\n\t])\n\tconst target = /^https?:\\/\\//i.test(url) ? url : generateUrl(url)\n\ttry {\n\t\t// Only pass a third axios config arg for a download call — an\n\t\t// explicit `undefined` third argument would otherwise change the\n\t\t// call shape for every existing (non-download) api-call consumer/test.\n\t\tconst res = isDownload\n\t\t\t? await axios[method](target, body, { responseType: 'blob' })\n\t\t\t: await axios[method](target, body)\n\t\tif (isDownload) {\n\t\t\tconst filename = parseDispositionFilename(\n\t\t\t\tres && res.headers && res.headers['content-disposition'],\n\t\t\t\tinterpolateActionString(action.filename, tokenCtx) || 'download.pdf',\n\t\t\t)\n\t\t\ttriggerBlobDownload(res.data, filename)\n\t\t}\n\t\tif (typeof dialogs.showSuccess === 'function') {\n\t\t\tdialogs.showSuccess(translateMessage(action.successMessage, context) || t('nextcloud-vue', 'Action completed.'))\n\t\t}\n\t\tconst shouldRefresh = isDownload ? action.refresh === true : action.refresh !== false\n\t\tif (shouldRefresh) {\n\t\t\temit(PAGE_REFRESH_CHANNEL, {})\n\t\t}\n\t\treturn { ok: true, data: res && res.data }\n\t} catch (error) {\n\t\tconst serverMessage = error && error.response && error.response.data\n\t\t\t&& (error.response.data.error || error.response.data.message)\n\t\tif (typeof dialogs.showError === 'function') {\n\t\t\tdialogs.showError(translateMessage(action.errorMessage, context) || serverMessage || t('nextcloud-vue', 'Action failed.'))\n\t\t}\n\t\treturn { ok: false, error }\n\t}\n}\n\n/**\n * Resolve an agent-action object reference (`register` / `schema` / `objectId`):\n * an explicitly-declared action value WINS (it may itself be an @-token string,\n * interpolated against the token context), otherwise it falls back to the page\n * object context default (`tokenCtx.register` / `.schema` / `.objectId`). An\n * unresolved token collapses to an empty string (never leaks a literal `@objectId`\n * to the server); a `{ slug | id }` object (a schema holder) is flattened to its\n * slug/id.\n *\n * @param {unknown} actionVal The action's explicit value (may be undefined or an @-token).\n * @param {unknown} ctxDefault The page-context default (`tokenCtx.<field>`).\n * @param {object} tokenCtx The token context the @-tokens resolve against.\n * @return {string} The resolved reference, or '' when unresolved/absent.\n */\nfunction resolveAgentRef(actionVal, ctxDefault, tokenCtx) {\n\tlet v = actionVal\n\tif (v === undefined || v === null || v === '') {\n\t\tv = ctxDefault\n\t} else if (typeof v === 'string') {\n\t\tv = interpolateActionString(v, tokenCtx)\n\t}\n\tif (v && typeof v === 'object') {\n\t\treturn String(v.slug || v.id || '')\n\t}\n\tif (v === undefined || v === null) {\n\t\treturn ''\n\t}\n\treturn String(v)\n}\n\n/**\n * Execute an `agent` action: run a governed hermiq agent against the page's\n * OpenRegister object. Resolves the object context (`register` / `schema` /\n * `objectId` — explicit action fields override, else default to the page's\n * `@register` / `@schema` / `@objectId` context) and POSTs\n * `{ register, schema, objectId, resultField?, skill?, prompt? }` to hermiq's\n * object-RBAC-scoped run endpoint `/apps/hermiq/api/agents/{agent}/run-on-object`\n * (hermiq#41), which dispatches the governed `AgentRunRequestedEvent`.\n *\n * A first-class companion to `type:\"api-call\"` — the author declares \"run agent\n * here\" without hand-wiring the URL/body. `type:\"api-call\"` remains the escape\n * hatch for a bespoke body.\n *\n * Fail-closed. An unresolved REQUIRED `@objectId` (or a missing agent/register/\n * schema) BLOCKS the call (warn) rather than POSTing a literal token. On the\n * server's 202 it toasts `successMessage` (default 'Run queued') and — unless\n * `refresh: false` — bumps the page refresh signal. A 403 / 404 with a structured\n * error body fail-closes with that message; a 404 with NO structured body is read\n * as \"hermiq absent\" and toasts a graceful 'agent runtime unavailable' — the\n * dispatcher NEVER hard-requires hermiq to be installed. Never throws.\n *\n * @param {object} action The agent action (`agent`, `skill?`, `prompt?`,\n * `resultField?`, `register?`, `schema?`, `objectId?`, `successMessage?`,\n * `errorMessage?`, `refresh?`).\n * @param {object} context Runtime context; `context.tokenCtx` is the token\n * context (`{ objectId?, object?, register?, schema?, workspace?, config? }`).\n * @return {Promise<{ok: boolean, data?: unknown, error?: unknown}>} The call outcome.\n */\nasync function executeAgentAction(action, context) {\n\tconst tokenCtx = context.tokenCtx || {}\n\tconst agent = resolveAgentRef(action.agent, undefined, tokenCtx)\n\tconst register = resolveAgentRef(action.register, tokenCtx.register, tokenCtx)\n\tconst schema = resolveAgentRef(action.schema, tokenCtx.schema, tokenCtx)\n\tconst objectId = resolveAgentRef(action.objectId, tokenCtx.objectId, tokenCtx)\n\n\tif (!agent || !register || !schema || !objectId) {\n\t\t// eslint-disable-next-line no-console\n\t\tconsole.warn('[dispatchAction] agent action is missing its agent or a required object-context token (register/schema/objectId) is unresolved — skipping.', action)\n\t\treturn { ok: false, error: new Error('agent action blocked') }\n\t}\n\n\tconst body = { register, schema, objectId }\n\tconst resultField = resolveAgentRef(action.resultField, undefined, tokenCtx)\n\tif (resultField) {\n\t\tbody.resultField = resultField\n\t}\n\tconst skill = resolveAgentRef(action.skill, undefined, tokenCtx)\n\tif (skill) {\n\t\tbody.skill = skill\n\t}\n\tif (typeof action.prompt === 'string' && action.prompt !== '') {\n\t\tbody.prompt = interpolateActionString(action.prompt, tokenCtx)\n\t}\n\n\tconst [{ default: axios }, { generateUrl }, dialogs] = await Promise.all([\n\t\timport('@nextcloud/axios'),\n\t\timport('@nextcloud/router'),\n\t\timport('@nextcloud/dialogs'),\n\t])\n\tconst target = generateUrl(`/apps/hermiq/api/agents/${encodeURIComponent(agent)}/run-on-object`)\n\ttry {\n\t\tconst res = await axios.post(target, body)\n\t\tif (typeof dialogs.showSuccess === 'function') {\n\t\t\tdialogs.showSuccess(translateMessage(action.successMessage, context) || t('nextcloud-vue', 'Run queued'))\n\t\t}\n\t\tif (action.refresh !== false) {\n\t\t\temit(PAGE_REFRESH_CHANNEL, {})\n\t\t}\n\t\treturn { ok: true, data: res && res.data }\n\t} catch (error) {\n\t\tconst response = error && error.response\n\t\tconst status = response && response.status\n\t\tconst serverMessage = response && response.data\n\t\t\t&& (response.data.error || response.data.message)\n\t\t// A 404 with NO structured error body = hermiq is not installed (the app\n\t\t// route 404s at the NC level) — surface a graceful \"runtime unavailable\"\n\t\t// rather than a fail-closed authorization message.\n\t\tconst hermiqAbsent = status === 404 && !serverMessage\n\t\tif (typeof dialogs.showError === 'function') {\n\t\t\tconst msg = hermiqAbsent\n\t\t\t\t? t('nextcloud-vue', 'Agent runtime unavailable')\n\t\t\t\t: (translateMessage(action.errorMessage, context) || serverMessage || t('nextcloud-vue', 'Action failed.'))\n\t\t\tdialogs.showError(msg)\n\t\t}\n\t\treturn { ok: false, error }\n\t}\n}\n\n/**\n * POST the run-node call: `POST /apps/openregister/api/flows/{flowId}/nodes/{nodeId}/run`.\n *\n * This is the SECOND half of `run-node` (manifest-run-node-action / or-flow-run-node) —\n * the first half is `context.openRunNode` in the `dispatchAction` switch below, which\n * only OPENS the config dialog (or decides none is needed) and never itself waits for\n * the person. Once the rendering surface has a `config` object (from the dialog's\n * submit, or `{}` when the node's declared form was empty), it calls this directly —\n * it is not reached through `dispatchAction`'s switch, because by that point there is\n * no further \"type\" dispatch to do, only the call itself, same as `executeAgentAction`\n * is called directly by `case 'api-call'`'s sibling rather than re-entering the switch.\n *\n * Fail-closed exactly like `executeAgentAction`: an unresolved REQUIRED subject\n * (`action.subject`, defaulting to the page's `@objectId`) or a missing\n * `flowId`/`nodeId` BLOCKS the call (warn) rather than POSTing a literal token or an\n * incomplete subject reference. The subject sent is `{ uuid, register, schema }` —\n * OpenRegister's `FlowNodeRunController::resolveAuthorizedSubject()` needs all three\n * to resolve the object and evaluate the caller's object-RBAC permission on it; `register`\n * / `schema` default to the page's own `@register` / `@schema` context, the same\n * defaulting `agent` already uses.\n *\n * A 403 here means the caller holds no update permission on the subject\n * (OpenRegister's object-RBAC, evaluated server-side — RN-1(c)) — this function does not\n * special-case it beyond surfacing the server's message, the same fail-closed handling\n * `api-call` / `agent` already give a rejected call.\n *\n * @param {object} action The run-node action (`flowId`, `nodeId`, `subject?`,\n * `register?`, `schema?`, `successMessage?`, `errorMessage?`, `refresh?`).\n * @param {object} context Runtime context — needs `context.tokenCtx` and, for a\n * localised toast, `context.translate`.\n * @param {object} [config] The node's collected config (from its `configForm()`\n * dialog), or `{}` for a node with no declared fields.\n * @return {Promise<{ok: boolean, data?: object, error?: Error}>} The call outcome —\n * `data` is the created `FlowRun` on success.\n *\n * @spec openspec/changes/manifest-run-node-action/specs/manifest-run-node-action/spec.md#requirement-a-run-node-action-invokes-one-flow-node-against-the-page-object\n */\nexport async function postRunNode(action, context, config = {}) {\n\tconst tokenCtx = context.tokenCtx || {}\n\tconst flowId = resolveAgentRef(action.flowId, undefined, tokenCtx)\n\tconst nodeId = resolveAgentRef(action.nodeId, undefined, tokenCtx)\n\tconst uuid = resolveAgentRef(action.subject, tokenCtx.objectId, tokenCtx)\n\tconst register = resolveAgentRef(action.register, tokenCtx.register, tokenCtx)\n\tconst schema = resolveAgentRef(action.schema, tokenCtx.schema, tokenCtx)\n\n\tif (!flowId || !nodeId || !uuid || !register || !schema) {\n\t\t// eslint-disable-next-line no-console\n\t\tconsole.warn('[dispatchAction] run-node is missing flowId/nodeId or a required subject token (objectId/register/schema) is unresolved — skipping.', action)\n\t\treturn { ok: false, error: new Error('run-node blocked') }\n\t}\n\n\tconst [{ default: axios }, { generateUrl }, dialogs] = await Promise.all([\n\t\timport('@nextcloud/axios'),\n\t\timport('@nextcloud/router'),\n\t\timport('@nextcloud/dialogs'),\n\t])\n\tconst target = generateUrl(`/apps/openregister/api/flows/${encodeURIComponent(flowId)}/nodes/${encodeURIComponent(nodeId)}/run`)\n\ttry {\n\t\tconst res = await axios.post(target, { subject: { uuid, register, schema }, config: config || {} })\n\t\tif (typeof dialogs.showSuccess === 'function') {\n\t\t\tdialogs.showSuccess(translateMessage(action.successMessage, context) || t('nextcloud-vue', 'Run completed.'))\n\t\t}\n\t\tif (action.refresh !== false) {\n\t\t\temit(PAGE_REFRESH_CHANNEL, {})\n\t\t}\n\t\treturn { ok: true, data: res && res.data }\n\t} catch (error) {\n\t\tconst response = error && error.response\n\t\tconst serverMessage = response && response.data\n\t\t\t&& (response.data.error || response.data.message)\n\t\tif (typeof dialogs.showError === 'function') {\n\t\t\tdialogs.showError(translateMessage(action.errorMessage, context) || serverMessage || t('nextcloud-vue', 'Action failed.'))\n\t\t}\n\t\treturn { ok: false, error }\n\t}\n}\n\n/**\n * Dispatch a v2 manifest action.\n *\n * @param {object} action The action object from the manifest.\n * @param {string} [action.type] Dispatch type: \"handler\" | \"open-modal\" | \"open-page\" | \"navigate\" |\n * \"object-op\" | \"export\" | \"open-form\" | \"refresh\" | \"api-call\" | \"agent\".\n * When absent, treated as \"handler\" for v1 backward compatibility.\n * @param {string} [action.handler] Registry key for \"handler\" type. For \"export\": the optional\n * handler invoked by the host with the dialog's confirm payload (`{ format, entity }`).\n * @param {Array} [action.args] Arguments spread to the handler function.\n * @param {string} [action.target] Target for \"open-modal\", \"open-page\", and \"navigate\" types.\n * @param {object} [action.props] Props forwarded to modal for \"open-modal\" type.\n * @param {string} [action.op] \"object-op\" only: mutation verb — \"patch\" | \"delete\" | \"create\".\n * @param {object} [action.values] \"object-op\" only: the verb's payload — the partial object\n * merged over the row for \"patch\", the new object's properties for \"create\"; ignored for \"delete\".\n * @param {boolean} [action.confirm] \"object-op\" only: confirm-gating INTENT consumed by the\n * rendering host (CnWidgetObjectTable routes it through CnConfirmDialog) — the dispatcher\n * itself never gates; it is called after any confirmation already happened.\n * @param {Array<{id: string, label: string}>} [action.entities] \"export\" only: selectable\n * entity types offered by the export launcher (e.g. Leads / Requests). Optional — when\n * absent the dialog shows only the format picker.\n * @param {Array<string|{id: string, label: string}>} [action.formats] \"export\" only: the\n * offered export formats (bare ids like \"csv\" or full `{id, label}` entries). Optional —\n * the dialog's built-in Excel/CSV defaults apply when absent.\n * @param {string} [action.description] \"export\" only: pre-translated description shown\n * above the pickers.\n * @param {string} [action.url] \"api-call\" only: the app endpoint — app-relative (routed\n * through generateUrl) or absolute. May interpolate the shared URL tokens\n * (`@objectId`, `@object.<field>`, `@workspace.<key>`, `@config.<key>`, and the\n * `{objectId}` brace form).\n * @param {string} [action.method] \"api-call\" only: \"POST\" (default) | \"PUT\".\n * @param {object} [action.payload] \"api-call\" only: the JSON body — preferred over `params`.\n * Values resolve the shared `@`-token grammar RECURSIVELY at any nesting depth (objects\n * and arrays of objects, e.g. `{ dataRefs: [{ id: '@objectId' }] }`); optional (`…?`)\n * tokens drop when unresolved anywhere in the tree, an unresolved REQUIRED token blocks\n * the call. When set, `params` is ignored.\n * @param {object} [action.params] \"api-call\" only: legacy JSON body (ignored when `payload`\n * is set). Values pass the shared filter-token grammar ONE level deep; optional (`…?`)\n * tokens drop when unresolved, an unresolved REQUIRED token blocks the call.\n * @param {boolean} [action.download] \"api-call\" only: request the response as a binary blob\n * (`responseType: 'blob'`) and trigger a browser file download instead of a JSON\n * toast+refresh cycle. Default `false`.\n * @param {string} [action.filename] \"api-call\" `download: true` only: fallback filename when\n * the response carries no `Content-Disposition` header (falls back further to\n * `'download.pdf'`). Interpolates the same token grammar as `url`.\n * @param {string} [action.successMessage] \"api-call\" / \"open-form\": pre-translated success\n * toast text (a library default applies when absent).\n * @param {string} [action.errorMessage] \"api-call\" / \"open-form\": pre-translated error toast\n * text (falls back to the server's `error`/`message`, then a library default).\n * @param {boolean} [action.refresh] \"api-call\" / \"agent\" only: bump the `cn:page:refresh` signal\n * after a successful call. Default `true` — EXCEPT for a `download: true` api-call, whose\n * default is `false` (a file download normally shouldn't also force-refetch every widget); set\n * the flag explicitly either way to override.\n * @param {string} [action.agent] \"agent\" only (REQUIRED): the hermiq agent uuid to run against\n * the page object. POSTed to `/apps/hermiq/api/agents/{agent}/run-on-object` (hermiq#41).\n * @param {string} [action.skill] \"agent\" only: optional skill id folded into the governed run.\n * @param {string} [action.prompt] \"agent\" only: optional prompt (interpolates the shared `@`-token\n * grammar inline — `@objectId`, `@object.<field>`, `@workspace.<key>`, `@config.<key>`).\n * @param {string} [action.resultField] \"agent\" only: object field the agent's result is written to.\n * @param {string} [action.register] \"agent\" / \"open-form\": OpenRegister register slug (agent:\n * defaults to the page object context's `@register`).\n * @param {string} [action.schema] \"agent\" / \"open-form\": OpenRegister schema slug (agent: defaults\n * to the page object context's `@schema`).\n * @param {string} [action.objectId] \"agent\" only: the target object id (defaults to the page\n * object context's `@objectId`). An unresolved required token BLOCKS the call (fail-closed).\n *\n * @param {object} context Runtime context.\n * @param {object} [context.router] Vue Router instance. Required for \"open-page\" and \"navigate\".\n * @param {object} [context.registry] Component registry (Record<string, { kind, component }>).\n * Required for \"open-modal\" type.\n * @param {object} [context.handlers] Map of handler name → function. Required for \"handler\" type.\n * @param {(key: string, props?: object) => void} [context.openModal] Opens a modal.\n * Required for \"open-modal\" type.\n * @param {(action: object) => void} [context.openExport] Opens the shared\n * CnMassExportDialog configured from the action. Required for \"export\" type —\n * CnPageRenderer pre-binds it in the `cnDispatchAction` context.\n * @param {(action: object) => void} [context.openForm] Opens the schema-driven\n * create dialog. Required for \"open-form\" type — the rendering surface\n * (CnActionButtons) provides it, mirroring `openExport`. On a successful save the\n * surface navigates to `action.onSuccessRoute` (a route NAME string, or\n * `{name, paramField?, objectParam?}`) via {@link buildOnSuccessRoute}, which merges\n * the saved object's id into the route params so the navigation can deep-link to the\n * created object.\n * @param {(action: object) => void} [context.openRunNode] Opens the\n * node-config dialog (or runs immediately for an empty config form) and\n * POSTs to OpenRegister's direct-invoke endpoint on submit. Required for\n * \"run-node\" type — the rendering surface (CnActionButtons) provides it,\n * mirroring `openForm`.\n * @param {{objectId?: (string|number), object?: object, workspace?: object, config?: object}} [context.tokenCtx]\n * Token context \"api-call\" URLs/params resolve against (the same shape\n * `resolveFilterTokens` / `interpolateUrlTokens` take).\n * @param {(app: string, text: string, vars?: object) => string} [context.translate] The consumer's bound `t()`, the same\n * `cnTranslate` CnAppRoot provides to the page chrome. Applied to the\n * manifest-authored `successMessage` / `errorMessage` of \"api-call\" and\n * \"agent\" so their toasts follow the user's language. Omitted (or a\n * catalogue miss) leaves the message byte-identical.\n * @param {object} [context.objectStore] Object store instance (useObjectStore shape).\n * Required for \"object-op\" type. All mutations go through `saveObject` / `deleteObject`\n * so store caches (and their no-mutation-on-error semantics) apply.\n * @param {{register: (string|number), schema: (string|number)}} [context.source] The widget's\n * declarative source the mutation targets. Required for \"object-op\" type.\n * @param {object} [context.row] The row object a row-scoped \"object-op\" (patch/delete) mutates.\n *\n * @return {Promise<object|boolean|null>|undefined} For \"object-op\": the store call's promise —\n * the saved object (or `null` on a rejected write) for patch/create, `true`/`false` for\n * delete. The store only mutates its local caches on SUCCESS, so a backend (RBAC) rejection\n * surfaces via the store's `errors[type]` without any local state change. For \"api-call\":\n * a promise of `{ ok, data?, error? }` (toasts + refresh already handled). All other types\n * return undefined.\n */\nexport function dispatchAction(action, context = {}) {\n\tif (!action || typeof action !== 'object') {\n\t\t// eslint-disable-next-line no-console\n\t\tconsole.warn('[dispatchAction] Received invalid action:', action)\n\t\treturn\n\t}\n\n\t// Missing type is treated as \"handler\" for v1 backward compatibility\n\tconst type = action.type || 'handler'\n\n\tswitch (type) {\n\t\tcase 'handler': {\n\t\t\tconst handlerName = action.handler\n\t\t\tconst handlers = context.handlers || {}\n\n\t\t\tif (!handlerName || typeof handlers[handlerName] !== 'function') {\n\t\t\t// eslint-disable-next-line no-console\n\t\t\t\tconsole.warn(`[dispatchAction] Handler \"${handlerName}\" not found in context.handlers.`)\n\t\t\t\treturn\n\t\t\t}\n\t\t\thandlers[handlerName](...(action.args ?? []))\n\t\t\tbreak\n\t\t}\n\n\t\tcase 'open-modal': {\n\t\t\tconst target = action.target\n\t\t\tconst registry = context.registry || {}\n\t\t\tconst entry = registry[target]\n\n\t\t\tif (!entry) {\n\t\t\t// eslint-disable-next-line no-console\n\t\t\t\tconsole.warn(`[dispatchAction] open-modal target \"${target}\" not found in registry.`)\n\t\t\t\treturn\n\t\t\t}\n\n\t\t\tif (entry.kind !== 'modal') {\n\t\t\t// eslint-disable-next-line no-console\n\t\t\t\tconsole.warn(`[dispatchAction] open-modal target \"${target}\" has kind \"${entry.kind}\" (expected \"modal\").`)\n\t\t\t\treturn\n\t\t\t}\n\n\t\t\tif (typeof context.openModal !== 'function') {\n\t\t\t// eslint-disable-next-line no-console\n\t\t\t\tconsole.warn('[dispatchAction] open-modal requires context.openModal to be a function.')\n\t\t\t\treturn\n\t\t\t}\n\n\t\t\tcontext.openModal(target, action.props ?? {})\n\t\t\tbreak\n\t\t}\n\n\t\tcase 'open-page': {\n\t\t\tif (!context.router) {\n\t\t\t// eslint-disable-next-line no-console\n\t\t\t\tconsole.warn('[dispatchAction] open-page requires context.router to be a Vue Router instance.')\n\t\t\t\treturn\n\t\t\t}\n\t\t\tcontext.router.push({ name: action.target })\n\t\t\tbreak\n\t\t}\n\n\t\tcase 'navigate': {\n\t\t\t// A target is a URL exactly as `url` is, so it runs the same token\n\t\t\t// grammar. Without this a manifest's `{objectId}` reached the router\n\t\t\t// as those nine literal characters and landed in the address bar.\n\t\t\tconst target = interpolateActionString(action.target || '', context.tokenCtx || {})\n\n\t\t\t// An external target is not a route. Rendering surfaces should give it\n\t\t\t// to the browser as a real link (CnActionButtons does); this is the\n\t\t\t// fallback for a programmatic dispatch, and it must not reach the\n\t\t\t// router — see isExternalActionTarget.\n\t\t\tif (isExternalActionTarget(target)) {\n\t\t\t\twindow.open(target, '_blank', 'noopener,noreferrer')\n\t\t\t\tbreak\n\t\t\t}\n\t\t\tif (!context.router) {\n\t\t\t// eslint-disable-next-line no-console\n\t\t\t\tconsole.warn('[dispatchAction] navigate requires context.router to be a Vue Router instance.')\n\t\t\t\treturn\n\t\t\t}\n\t\t\tcontext.router.push(target)\n\t\t\tbreak\n\t\t}\n\n\t\tcase 'export': {\n\t\t// Export launcher (Wave 1, nextcloud-vue#91): the host page opens the\n\t\t// shared CnMassExportDialog configured via the action's entities[] /\n\t\t// formats[]; the dialog's confirm payload routes to the action's\n\t\t// optional `handler` (the app's export service does the download).\n\t\t\tif (typeof context.openExport !== 'function') {\n\t\t\t// eslint-disable-next-line no-console\n\t\t\t\tconsole.warn('[dispatchAction] export requires context.openExport to be a function.')\n\t\t\t\treturn\n\t\t\t}\n\t\t\tcontext.openExport(action)\n\t\t\tbreak\n\t\t}\n\n\t\tcase 'open-form': {\n\t\t// Schema-driven create dialog (Wave 3, nextcloud-vue#91): the\n\t\t// rendering surface (CnActionButtons) mounts the shared\n\t\t// CnAdvancedFormDialog and handles the save — mirroring how\n\t\t// `export` delegates to the host's CnMassExportDialog.\n\t\t\tif (typeof context.openForm !== 'function') {\n\t\t\t// eslint-disable-next-line no-console\n\t\t\t\tconsole.warn('[dispatchAction] open-form requires context.openForm to be a function.')\n\t\t\t\treturn\n\t\t\t}\n\t\t\tcontext.openForm(action)\n\t\t\tbreak\n\t\t}\n\n\t\tcase 'run-node': {\n\t\t// Direct flow-node invocation (manifest-run-node-action / RN-4):\n\t\t// SAME shape as open-form, deliberately — the rendering surface\n\t\t// (CnActionButtons) resolves the node's own config form, opens a\n\t\t// generic dialog when it has fields (skips it when empty), and\n\t\t// POSTs subject+config to OpenRegister's\n\t\t// /api/flows/{flowId}/nodes/{nodeId}/run on submit. This case\n\t\t// resolves as soon as the dialog OPENS (or the empty-form call\n\t\t// starts) — it does NOT wait for the person to answer, matching\n\t\t// every other consumer's assumption that dispatchAction's Promise\n\t\t// means \"the call happened\", not \"the human decided\" (see design.md\n\t\t// RN-4 for why an awaiting-on-UI shape was rejected).\n\t\t\tif (typeof context.openRunNode !== 'function') {\n\t\t\t// eslint-disable-next-line no-console\n\t\t\t\tconsole.warn('[dispatchAction] run-node requires context.openRunNode to be a function.')\n\t\t\t\treturn\n\t\t\t}\n\t\t\tcontext.openRunNode(action)\n\t\t\tbreak\n\t\t}\n\n\t\tcase 'refresh': {\n\t\t// Page-level refresh (Wave 3, nextcloud-vue#91): bump the SAME\n\t\t// `cn:page:refresh` event-bus signal the page overflow menu's\n\t\t// Refresh item broadcasts — every endpoint-bound / bus-subscribed\n\t\t// widget on the page force-refetches past its shared cache.\n\t\t\temit(PAGE_REFRESH_CHANNEL, {})\n\t\t\tbreak\n\t\t}\n\n\t\tcase 'api-call': {\n\t\t// POST/PUT an app endpoint + toast + refresh (Wave 3). Any\n\t\t// `confirm` on the action is INTENT the rendering surface consumed\n\t\t// BEFORE calling the dispatcher (object-op precedent) — no gating\n\t\t// happens here.\n\t\t\treturn executeApiCall(action, context)\n\t\t}\n\n\t\tcase 'agent': {\n\t\t// Run a governed hermiq agent against the page object (hermiq#41). A\n\t\t// first-class companion to api-call: resolves the object context\n\t\t// (register/schema/objectId) and POSTs run-on-object. Any `confirm`\n\t\t// on the action is INTENT the rendering surface consumed BEFORE\n\t\t// dispatch (api-call / object-op precedent) — no gating here. hermiq\n\t\t// is NOT hard-required: an app-level 404 surfaces a graceful toast.\n\t\t\treturn executeAgentAction(action, context)\n\t\t}\n\n\t\tcase 'toggle': {\n\t\t// A toggle is a stateful two-way control (GET state on mount,\n\t\t// write on click) — it is RENDERED by the header-actions surface\n\t\t// (CnActionButtons), never dispatched as a one-shot action.\n\t\t// eslint-disable-next-line no-console\n\t\t\tconsole.warn('[dispatchAction] \"toggle\" is a stateful header-actions control rendered by CnActionButtons — it cannot be dispatched.')\n\t\t\treturn\n\t\t}\n\n\t\tcase 'object-op': {\n\t\t// Declarative mutation of an OpenRegister object, dispatched via the\n\t\t// shared object store (ADR-049). The manifest declares INTENT only:\n\t\t// authorization-shaped fields on the action (`role`, `allow`, …) are\n\t\t// NEVER consulted here — OpenRegister RBAC is the single authority\n\t\t// (ADR-022 / ADR-023) and a forbidden mutation is rejected server-side.\n\t\t// The store mutates its caches only on success, so a rejected write\n\t\t// surfaces as an error with no local state change.\n\t\t\tconst op = action.op\n\t\t\tif (op !== 'patch' && op !== 'delete' && op !== 'create') {\n\t\t\t// eslint-disable-next-line no-console\n\t\t\t\tconsole.warn(`[dispatchAction] object-op has invalid op \"${op}\" (expected patch | delete | create).`)\n\t\t\t\treturn\n\t\t\t}\n\t\t\tconst store = context.objectStore\n\t\t\tif (!store || typeof store.saveObject !== 'function' || typeof store.deleteObject !== 'function') {\n\t\t\t// eslint-disable-next-line no-console\n\t\t\t\tconsole.warn('[dispatchAction] object-op requires context.objectStore (useObjectStore shape).')\n\t\t\t\treturn\n\t\t\t}\n\t\t\tconst source = context.source\n\t\t\tif (!source || !source.register || !source.schema) {\n\t\t\t// eslint-disable-next-line no-console\n\t\t\t\tconsole.warn('[dispatchAction] object-op requires context.source with register + schema.')\n\t\t\t\treturn\n\t\t\t}\n\t\t\tconst type = resolveObjectOpType(store, source)\n\n\t\t\tif (op === 'create') {\n\t\t\t\treturn store.saveObject(type, { ...(action.values || {}) })\n\t\t\t}\n\n\t\t\tconst row = context.row\n\t\t\tconst id = rowObjectId(row)\n\t\t\tif (id === null) {\n\t\t\t// eslint-disable-next-line no-console\n\t\t\t\tconsole.warn(`[dispatchAction] object-op \"${op}\" is row-scoped and requires context.row with an id.`)\n\t\t\t\treturn\n\t\t\t}\n\t\t\tif (op === 'delete') {\n\t\t\t\treturn store.deleteObject(type, id)\n\t\t\t}\n\t\t\t// patch: the row's object merged with the action's values.\n\t\t\treturn store.saveObject(type, { ...row, ...(action.values || {}), id })\n\t\t}\n\n\t\tdefault:\n\t\t// eslint-disable-next-line no-console\n\t\t\tconsole.warn(`[dispatchAction] Unknown action type \"${type}\".`)\n\t}\n}\n"],"names":["t"],"mappings":";;;;;;;;AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AAeA;AACA;AACA,MAAM,oBAAoB,GAAG,kBAAiB;AAC9C;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACO,SAAS,sBAAsB,CAAC,MAAM,EAAE;AAC/C,CAAC,IAAI,OAAO,MAAM,KAAK,QAAQ,EAAE;AACjC,EAAE,OAAO,KAAK;AACd,EAAE;AACF,CAAC,OAAO,OAAO,CAAC,IAAI,CAAC,MAAM,CAAC,IAAI,wBAAwB,CAAC,IAAI,CAAC,MAAM,CAAC;AACrE,CAAC;AACD;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACO,SAAS,mBAAmB,CAAC,KAAK,EAAE,MAAM,EAAE;AACnD,CAAC,MAAM,QAAQ,GAAG,MAAM,CAAC,MAAM,CAAC,QAAQ,EAAC;AACzC,CAAC,MAAM,MAAM,GAAG,MAAM,CAAC,aAAa,CAAC,MAAM,CAAC,MAAM,CAAC,EAAC;AACpD,CAAC,MAAM,OAAO,GAAG,OAAO,MAAM,CAAC,MAAM,KAAK,QAAQ;AAClD,IAAI,MAAM,CAAC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AAI,CAAC,MAAM,IAAI,CAAC,MAAM,CAAC,QAAQ,IAAI,CAAC,MAAM,CAAC,MAAM,EAAE;AACtD;AACA,IAAI,OAAO,CAAC,IAAI,CAAC,4EAA4E,EAAC;AAC9F,IAAI,MAAM;AACV,IAAI;AACJ,GAAG,MAAM,IAAI,GAAG,mBAAmB,CAAC,KAAK,EAAE,MAAM,EAAC;AAClD;AACA,GAAG,IAAI,EAAE,KAAK,QAAQ,EAAE;AACxB,IAAI,OAAO,KAAK,CAAC,UAAU,CAAC,IAAI,EAAE,EAAE,IAAI,MAAM,CAAC,MAAM,IAAI,EAAE,CAAC,EAAE,CAAC;AAC/D,IAAI;AACJ;AACA,GAAG,MAAM,GAAG,GAAG,OAAO,CAAC,IAAG;AAC1B,GAAG,MAAM,EAAE,GAAG,WAAW,CAAC,GAAG,EAAC;AAC9B,GAAG,IAAI,EAAE,KAAK,IAAI,EAAE;AACpB;AACA,IAAI,OAAO,CAAC,IAAI,CAAC,CAAC,4BAA4B,EAAE,EAAE,CAAC,oDAAoD,CAAC,EAAC;AACzG,IAAI,MAAM;AACV,IAAI;AACJ,GAAG,IAAI,EAAE,KAAK,QAAQ,EAAE;AACxB,IAAI,OAAO,KAAK,CAAC,YAAY,CAAC,IAAI,EAAE,EAAE,CAAC;AACvC,IAAI;AACJ;AACA,GAAG,OAAO,KAAK,CAAC,UAAU,CAAC,IAAI,EAAE,EAAE,GAAG,GAAG,EAAE,IAAI,MAAM,CAAC,MAAM,IAAI,EAAE,CAAC,EAAE,EAAE,EAAE,CAAC;AAC1E,GAAG;AACH;AACA,EAAE;AACF;AACA,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC,sCAAsC,EAAE,IAAI,CAAC,EAAE,CAAC,EAAC;AAClE,EAAE;AACF;;;;"}
|
|
1
|
+
{"version":3,"file":"actionsDispatcher.js","sources":["../../../src/utils/actionsDispatcher.js"],"sourcesContent":["/**\n * SPDX-FileCopyrightText: 2024 Conduction B.V.\n * SPDX-License-Identifier: EUPL-1.2\n *\n * actionsDispatcher — unified action dispatcher for v2 manifest actions.\n *\n * Dispatches an action object against a context. All dispatch types are\n * handled without throwing — errors surface as console.warn calls.\n * Types: handler | open-modal | open-page | navigate | object-op (the\n * declarative OpenRegister mutation verb added by ADR-049 — dispatched\n * via the shared object store, intent-only, RBAC stays server-side) |\n * export (opens the shared CnMassExportDialog export launcher configured\n * via the action's `entities[]` / `formats[]` — Wave 1 of\n * nextcloud-vue#91; the host page provides `context.openExport`) |\n * open-form (Wave 3 — schema-driven create dialog; the rendering host\n * provides `context.openForm`) | refresh (Wave 3 — bumps the page-level\n * refresh signal on the `cn:page:refresh` event-bus channel) | api-call\n * (Wave 3 — POST/PUT a configured app endpoint with success/error toasts\n * and an automatic page refresh; any `confirm` on the action is INTENT\n * consumed by the rendering surface BEFORE dispatch, like object-op) |\n * agent (run a governed hermiq agent against the page object via\n * POST /apps/hermiq/api/agents/{agent}/run-on-object — hermiq#41; a\n * first-class companion to api-call that resolves the register/schema/\n * objectId context for the author and fail-closes when hermiq is absent) |\n * run-node (manifest-run-node-action — invoke ONE OpenRegister flow node\n * directly against a subject object via\n * POST /api/flows/{flowId}/nodes/{nodeId}/run; the rendering surface\n * provides context.openRunNode, mirroring open-form, and resolves the\n * node's own declared config form before opening a dialog — see or-flow-run-node).\n *\n * `api-call`'s request body prefers `payload` (DEEP @-token resolution at\n * any nesting depth — object/array, e.g. a Filinq-style\n * `{ dataRefs: [{ id: '@objectId' }] }` body) over the legacy `params`\n * (shallow, one-level filter-map resolution, kept for back-compat). Set\n * `download: true` to request a binary blob response and trigger a\n * browser file download instead of a JSON toast+refresh cycle (filename:\n * `Content-Disposition` header, else the token-resolved `filename`, else\n * `'download.pdf'`; no auto-refresh unless `refresh: true` is explicit).\n *\n * `toggle` (Wave 3) is deliberately NOT dispatchable: a toggle is a\n * stateful two-way control (GET state on mount, write on click) rendered\n * by the header-actions surface (CnActionButtons); dispatching it here\n * warns and no-ops.\n *\n * Spec: REQ-MVR-011 (manifest-v2-renderer) — unified actions dispatcher\n * / ADR-036 Decision 7 / ADR-049 Decision 2 / #91 Wave 3\n */\n\nimport { emit } from '@nextcloud/event-bus'\nimport { translate as t } from '@nextcloud/l10n'\nimport { parseDispositionFilename, triggerBlobDownload } from '../components/CnIndexPage/selfModeIO.js'\nimport { interpolateUrlTokens } from '../composables/useEndpointSource.js'\nimport { routeHref } from './actionLink.js'\nimport {\n\tdropOptionalUnresolved,\n\tdropOptionalUnresolvedDeep,\n\thasUnresolvedDeepTokens,\n\thasUnresolvedTokens,\n\tresolveDeepTokens,\n\tresolveFilterTokens,\n} from './resolveFilterTokens.js'\nimport { schemaRefSlug } from './schemaRefSlug.js'\n\n/** Event-bus channel the page-level Refresh signal broadcasts on (Wave 2). */\nconst PAGE_REFRESH_CHANNEL = 'cn:page:refresh'\n\n/**\n * Whether a `navigate` target leaves the app: it is `http(s)://`,\n * protocol-relative (`//`), or a `mailto:` / `tel:` link. Anything else is an\n * in-app path for the router.\n *\n * vue-router happily accepts an absolute URL as a PATH — `router.push` on\n * `https://youtu.be/x?v=1` matches no route and lands on the fallback with the\n * query carried over, which reads as the app ignoring the link.\n *\n * An allowlist, not a generic `<scheme>://` match: manifests are\n * admin-editable app-wide config, and an external target renders into an\n * anchor `href` and a dispatcher `window.open` — a generic scheme match would\n * accept `javascript://` too.\n *\n * @param {unknown} target The action target to test.\n * @return {boolean} True when the target is external.\n */\nexport function isExternalActionTarget(target) {\n\tif (typeof target !== 'string') {\n\t\treturn false\n\t}\n\treturn /^\\/\\//.test(target) || /^(https?|mailto|tel):/i.test(target)\n}\n\n/**\n * Resolve the object-store type slug for a widget `source` register/schema\n * pair. Reuses an already-registered type whose config matches (so an app's\n * own caches stay coherent); otherwise registers a deterministic\n * `<register>/<schema>` slug on the fly.\n *\n * `source.schema` is routed through {@link schemaRefSlug} before it ever\n * reaches the store or the objects API: a caller that passes a `$ref`\n * schema TITLE (`ReportPeriod`) rather than its slug (`report-period`)\n * would otherwise register — and fetch — a 404 (defect 7, learniq round\n * 1). Idempotent for a caller that already passes a correct slug.\n *\n * A caller that already holds the schema SLUG (not a `$ref` title) passes\n * `{ exactSchema: true }`: the slug is then used exactly as given. Kebab-casing\n * a real camelCase slug (`productCategory` -> `product-category`) asks the\n * objects API for a schema that does not exist and 404s (pipelinq review,\n * round two).\n *\n * @spec openspec/changes/review-round-two/specs/schema-utilities/spec.md\n *\n * A title is not always registered under its kebab form: learniq holds\n * `LearniqSettings` and `SubjectTeacherAssignment` as written. So a type\n * registered here for a value the kebab rule CHANGED also carries the value\n * as written as its `schemaFallback`, and the store retries with it once\n * when the kebab form answers 404 (keeping it from then on). The kebab form\n * is still tried first, so a schema registered under it costs nothing.\n *\n * @spec openspec/changes/zuiddrecht-pixel-gaps-2/specs/zuiddrecht-pixel-gaps-2/spec.md#requirement-a-schema-title-falls-back-to-its-written-form\n * @param {object} store The object store instance (useObjectStore shape).\n * @param {{register: (string|number), schema: (string|number)}} source The widget source.\n * @param {{exactSchema: (boolean|undefined)}} [options] `exactSchema: true` skips the title-to-slug step.\n * @return {string} The type slug to use for store CRUD calls.\n */\nexport function resolveObjectOpType(store, source, options = {}) {\n\tconst register = String(source.register)\n\tconst schema = options.exactSchema === true ? String(source.schema) : String(schemaRefSlug(source.schema))\n\tconst written = typeof source.schema === 'string'\n\t\t? source.schema.substring(source.schema.lastIndexOf('/') + 1)\n\t\t: ''\n\tconst registry = store.objectTypeRegistry || {}\n\tfor (const [slug, config] of Object.entries(registry)) {\n\t\tif (!config) {\n\t\t\tcontinue\n\t\t}\n\t\tif ((String(config.register) === register && String(config.schema) === schema)\n\t\t\t|| (config.registerSlug === register && config.schemaSlug === schema)) {\n\t\t\treturn slug\n\t\t}\n\t}\n\tconst slug = `${register}/${schema}`\n\tif (!registry[slug]) {\n\t\tstore.registerObjectType(slug, schema, register)\n\t\tif (written !== '' && written !== schema && typeof store.setSchemaFallback === 'function') {\n\t\t\tstore.setSchemaFallback(slug, written)\n\t\t}\n\t}\n\treturn slug\n}\n\n/**\n * Extract an OpenRegister object's id from a row (top-level `id` wins,\n * `@self.id` metadata fallback).\n *\n * @param {object} row The row object.\n * @return {string|number|null} The object id, or null when absent.\n */\nfunction rowObjectId(row) {\n\tif (!row || typeof row !== 'object') {\n\t\treturn null\n\t}\n\tif (row.id !== undefined && row.id !== null) {\n\t\treturn row.id\n\t}\n\tconst self = row['@self']\n\tif (self && typeof self === 'object' && self.id !== undefined && self.id !== null) {\n\t\treturn self.id\n\t}\n\treturn null\n}\n\n/**\n * Extract a saved OpenRegister object's id for a post-save deep-link:\n * top-level `id`, then `uuid`, then the `@self.id` metadata fallback.\n *\n * @param {object} saved The saved record returned by the object store.\n * @return {string|number|null} The object id, or null when absent.\n */\nexport function savedObjectId(saved) {\n\tif (!saved || typeof saved !== 'object') {\n\t\treturn null\n\t}\n\tif (saved.id !== undefined && saved.id !== null) {\n\t\treturn saved.id\n\t}\n\tif (saved.uuid !== undefined && saved.uuid !== null) {\n\t\treturn saved.uuid\n\t}\n\tconst self = saved['@self']\n\tif (self && typeof self === 'object' && self.id !== undefined && self.id !== null) {\n\t\treturn self.id\n\t}\n\treturn null\n}\n\n/**\n * Resolve a manifest-named FUNCTION out of the v2 registry, falling back to the\n * legacy customComponents map.\n *\n * A manifest names a behaviour the same way it names a component — by string —\n * so every surface that dispatches one (`actions[].handler`,\n * `bulkActions[].handler`, `headerActions[].handler`, `config.createOverride`)\n * has to agree on where that string is looked up and what counts as a match.\n * Recognised shapes, in order:\n * 1. a registry entry exposing the function as `.handler` / `.fn` (the\n * `kind: 'handler'` and `kind: 'create-override'` entries),\n * 2. a directly function-valued registry entry,\n * 3. a function-valued legacy `customComponents` entry.\n *\n * The legacy map stays last so an app that has not migrated is unchanged, and\n * so an app mid-migration can move its handlers over one at a time.\n *\n * @param {string} name The registered handler name.\n * @param {object} registry The v2 component registry.\n * @param {object} customComponents The legacy customComponents map.\n * @return {?((scope?: object) => unknown)} The handler, or null when nothing of that name is a function.\n */\nexport function resolveRegisteredHandler(name, registry, customComponents) {\n\tif (typeof name !== 'string' || name === '') {\n\t\treturn null\n\t}\n\tconst entry = (registry || {})[name]\n\tif (typeof entry === 'function') {\n\t\treturn entry\n\t}\n\tif (entry && typeof entry === 'object') {\n\t\tif (typeof entry.handler === 'function') {\n\t\t\treturn entry.handler\n\t\t}\n\t\tif (typeof entry.fn === 'function') {\n\t\t\treturn entry.fn\n\t\t}\n\t}\n\tconst legacy = (customComponents || {})[name]\n\treturn typeof legacy === 'function' ? legacy : null\n}\n\n/**\n * Resolve a named create-override handler out of the v2 registry (or the\n * legacy customComponents map) by value shape.\n *\n * A create-override is a plain async function that replaces the default\n * `objectStore.saveObject` persist path — needed whenever a schema requires a\n * field the create form cannot supply on its own (a server-minted foreign key,\n * say).\n *\n * Shared by CnPageRenderer (page-level `config.createOverride` → CnIndexPage's\n * prop) and CnActionButtons (per-action `createOverride` on an `open-form`), so\n * the two surfaces cannot drift on what counts as a valid handler.\n *\n * @param {string} name The registered handler name.\n * @param {object} registry The v2 component registry.\n * @param {object} customComponents The legacy customComponents map.\n * @return {?((props?: object) => Promise<unknown>)} The async create handler, or null when unresolved.\n */\nexport function resolveCreateOverrideHandler(name, registry, customComponents) {\n\treturn resolveRegisteredHandler(name, registry, customComponents)\n}\n\n/**\n * Build the vue-router push location for an `open-form` action's\n * `onSuccessRoute`, merging the saved object's id into the route params so\n * the post-save navigation can deep-link to the created object's detail page\n * (#91).\n *\n * `onSuccessRoute` may be:\n * - a STRING route NAME → `{ name, params: { id } }`. The saved id lands\n * under the default `id` param; a route without an `:id` segment simply\n * ignores the extra param, so a bare-name route keeps working unchanged\n * (backward compatible).\n * - an OBJECT `{ name, paramField?, objectParam? }` → the id is placed\n * under `paramField` (default `id`), and — when `objectParam` is set —\n * the whole saved object is passed under that param key too (so a\n * `props: true` detail route can render the record without a refetch).\n *\n * The id is read via {@link savedObjectId} (`saved.id` → `saved.uuid` →\n * `saved['@self'].id`). Returns `null` when no route name is resolvable, so\n * the caller can skip the navigation.\n *\n * @param {(string|{name: string, paramField?: string, objectParam?: string})} onSuccessRoute The action's onSuccessRoute config.\n * @param {object} saved The saved OpenRegister object.\n * @return {{name: string, params: object}|null} The router push location, or null.\n */\nexport function buildOnSuccessRoute(onSuccessRoute, saved) {\n\tconst spec = typeof onSuccessRoute === 'string'\n\t\t? { name: onSuccessRoute }\n\t\t: (onSuccessRoute && typeof onSuccessRoute === 'object' ? onSuccessRoute : null)\n\tif (!spec || typeof spec.name !== 'string' || spec.name === '') {\n\t\treturn null\n\t}\n\tconst params = {}\n\tconst id = savedObjectId(saved)\n\tif (id !== null && id !== undefined) {\n\t\tparams[spec.paramField || 'id'] = id\n\t}\n\tif (spec.objectParam && saved && typeof saved === 'object') {\n\t\tparams[spec.objectParam] = saved\n\t}\n\treturn { name: spec.name, params }\n}\n\n/**\n * Run a manifest-authored toast message through the host translate function.\n *\n * `successMessage` / `errorMessage` are English source strings authored in the\n * manifest (ADR-007), so they need the SAME translator the rest of the page\n * chrome uses — the consumer's bound `t()`, handed to the dispatcher by the\n * rendering surface as `context.translate` (which itself comes from the\n * `cnTranslate` CnAppRoot provides).\n *\n * A pure pass-through: with no translator, no message, or a catalogue that\n * lacks the key, the message is returned byte-identical. Server-supplied\n * messages are data and are never routed through here.\n *\n * @param {unknown} message The manifest-authored message (may be undefined).\n * @param {object} context The dispatch context (`context.translate` optional).\n * @return {unknown} The translated message, or the input unchanged.\n */\nfunction translateMessage(message, context) {\n\tconst fn = context && context.translate\n\tif (!message || typeof fn !== 'function') {\n\t\treturn message\n\t}\n\treturn fn(message)\n}\n\n/**\n * Interpolate the `api-call` URL/filename token grammar inside a string:\n * the `{objectId}` BRACE convention (a literal placeholder some manifests\n * use for path templates, matching the OpenRegister credential-broker path\n * style) as well as the full `@objectId` / `@object.<field>` /\n * `@workspace.<key>` / `@config.<key>` grammar {@link interpolateUrlTokens}\n * already understands. Unresolved `@`-tokens and an unresolved\n * `{objectId}` both collapse to an empty string (never leak a literal\n * placeholder into a request URL or a downloaded filename).\n *\n * @param {string} str The raw string (an action's `url` or `filename`).\n * @param {{objectId?: (string|number), object?: object, workspace?: object, config?: object}} ctx Token context.\n * @return {string} The interpolated string.\n */\nfunction interpolateActionString(str, ctx) {\n\tif (typeof str !== 'string') {\n\t\treturn str\n\t}\n\tconst braced = str.replace(/\\{objectId\\}/g, () => {\n\t\tconst id = ctx.objectId\n\t\treturn (id === undefined || id === null) ? '' : String(id)\n\t})\n\treturn interpolateUrlTokens(braced, ctx)\n}\n\n/**\n * Interpolate an action's `target` URL — the same grammar `url` runs.\n *\n * Exported because the rendering surface resolves a target BEFORE deciding\n * whether it is an external link, and that decision happens there rather than\n * in the dispatcher.\n *\n * @param {string} target The action's raw `target`.\n * @param {object} ctx Token context (`{ objectId?, object?, workspace?, config? }`).\n *\n * @return {string} The interpolated target.\n */\nexport function interpolateActionTarget(target, ctx) {\n\treturn interpolateActionString(target || '', ctx || {})\n}\n\n// The tokens interpolateActionString resolves; a bare `@` or `{` is not one.\nconst ACTION_TARGET_TOKEN = /@(?:objectId|object\\.|page\\.|workspace\\.|config\\.|range\\.)|\\{objectId\\}/\n\n/**\n * Whether an action target carries a token that interpolation would resolve,\n * so it can only be known once the page context is. A `mailto:` address or a\n * URL with an `@handle` in it has none.\n *\n * @param {string} target The action's raw `target`.\n * @return {boolean}\n */\nexport function hasActionTargetTokens(target) {\n\treturn typeof target === 'string' && ACTION_TARGET_TOKEN.test(target)\n}\n\n/**\n * The link an action renders as when its only job is to navigate to a target\n * known at render time: `navigate` (token-interpolated like the dispatcher)\n * and `open-page`. Anything else, a `confirm: true` action, or an in-app\n * target the router cannot resolve answers null and keeps dispatching.\n *\n * `to` is what a plain click hands the router (null for an external URL,\n * which the browser opens in a new tab like the dispatcher's `window.open`).\n *\n * @param {object} action The manifest action.\n * @param {{router?: object, tokenCtx?: object}} [context] The dispatch context.\n * @return {{href: string, to: (string|object|null), external: boolean}|null} The link, or null.\n */\nexport function actionLink(action, context = {}) {\n\tif (!action || typeof action !== 'object' || action.confirm) {\n\t\treturn null\n\t}\n\tif (action.type === 'navigate') {\n\t\tconst target = interpolateActionString(action.target || '', context.tokenCtx || {})\n\t\tif (!target) {\n\t\t\treturn null\n\t\t}\n\t\tif (isExternalActionTarget(target)) {\n\t\t\treturn { href: target, to: null, external: true }\n\t\t}\n\t\tconst href = routeHref(target, context.router)\n\t\treturn href ? { href, to: target, external: false } : null\n\t}\n\tif (action.type === 'open-page') {\n\t\tif (typeof action.target !== 'string' || action.target.length === 0) {\n\t\t\treturn null\n\t\t}\n\t\tconst to = { name: action.target }\n\t\tconst href = routeHref(to, context.router)\n\t\treturn href ? { href, to, external: false } : null\n\t}\n\treturn null\n}\n\n/**\n * Execute a Wave-3 `api-call` action: POST/PUT the configured app endpoint\n * (URL + body run the SAME @-token grammar endpoint sources use), toast the\n * outcome via @nextcloud/dialogs, then — unless `action.refresh` is `false`\n * (or, for a `download` action, unless `action.refresh` is explicitly\n * `true`) — bump the page-level refresh signal so every endpoint-bound\n * widget refetches. Confirm-gating is the RENDERING SURFACE's job (the\n * `confirm` field is intent, object-op precedent): this runs after any\n * confirmation already happened.\n *\n * The request body prefers `action.payload` (DEEP token resolution, any\n * nesting — {@link resolveDeepTokens}) over the legacy `action.params`\n * (shallow, one-level filter-map resolution — unchanged for back-compat).\n * A required token left unresolved anywhere in the body BLOCKS the call\n * (error toast) rather than sending a literal `@objectId` to the server.\n *\n * `action.download === true` requests the response as a binary blob\n * (`responseType: 'blob'`) and triggers a browser file download — the\n * filename comes from the response's `Content-Disposition` header, else\n * the token-resolved `action.filename`, else `'download.pdf'`.\n *\n * Never throws: a failed call resolves `{ ok: false, error }` after the\n * error toast (so a confirm dialog can await the outcome).\n *\n * @param {object} action The api-call action (`url`, `method?`, `payload?`,\n * `params?`, `download?`, `filename?`, `successMessage?`, `errorMessage?`,\n * `refresh?`).\n * @param {object} context Runtime context; `context.tokenCtx` is the token\n * context (`{ objectId?, object?, workspace?, config? }`) the URL/body\n * resolve against.\n * @return {Promise<{ok: boolean, data?: unknown, error?: unknown}>} The call outcome.\n */\nasync function executeApiCall(action, context) {\n\tconst tokenCtx = context.tokenCtx || {}\n\tconst url = interpolateActionString(action.url || '', tokenCtx)\n\n\tconst hasPayload = action.payload && typeof action.payload === 'object' && !Array.isArray(action.payload)\n\tconst body = hasPayload\n\t\t? dropOptionalUnresolvedDeep(resolveDeepTokens(action.payload, tokenCtx))\n\t\t: dropOptionalUnresolved(resolveFilterTokens(action.params || {}, tokenCtx))\n\tconst bodyBlocked = hasPayload ? hasUnresolvedDeepTokens(body) : hasUnresolvedTokens(body)\n\n\tif (!url || bodyBlocked) {\n\t\t// eslint-disable-next-line no-console\n\t\tconsole.warn('[dispatchAction] api-call is missing its url or a required token is unresolved — skipping.', action)\n\t\treturn { ok: false, error: new Error('api-call blocked') }\n\t}\n\tconst method = String(action.method || 'POST').toUpperCase() === 'PUT' ? 'put' : 'post'\n\tconst isDownload = action.download === true\n\tconst [{ default: axios }, { generateUrl }, dialogs] = await Promise.all([\n\t\timport('@nextcloud/axios'),\n\t\timport('@nextcloud/router'),\n\t\timport('@nextcloud/dialogs'),\n\t])\n\tconst target = /^https?:\\/\\//i.test(url) ? url : generateUrl(url)\n\ttry {\n\t\t// Only pass a third axios config arg for a download call — an\n\t\t// explicit `undefined` third argument would otherwise change the\n\t\t// call shape for every existing (non-download) api-call consumer/test.\n\t\tconst res = isDownload\n\t\t\t? await axios[method](target, body, { responseType: 'blob' })\n\t\t\t: await axios[method](target, body)\n\t\tif (isDownload) {\n\t\t\tconst filename = parseDispositionFilename(\n\t\t\t\tres && res.headers && res.headers['content-disposition'],\n\t\t\t\tinterpolateActionString(action.filename, tokenCtx) || 'download.pdf',\n\t\t\t)\n\t\t\ttriggerBlobDownload(res.data, filename)\n\t\t}\n\t\tif (typeof dialogs.showSuccess === 'function') {\n\t\t\tdialogs.showSuccess(translateMessage(action.successMessage, context) || t('nextcloud-vue', 'Action completed.'))\n\t\t}\n\t\tconst shouldRefresh = isDownload ? action.refresh === true : action.refresh !== false\n\t\tif (shouldRefresh) {\n\t\t\temit(PAGE_REFRESH_CHANNEL, {})\n\t\t}\n\t\treturn { ok: true, data: res && res.data }\n\t} catch (error) {\n\t\tconst serverMessage = error && error.response && error.response.data\n\t\t\t&& (error.response.data.error || error.response.data.message)\n\t\tif (typeof dialogs.showError === 'function') {\n\t\t\tdialogs.showError(translateMessage(action.errorMessage, context) || serverMessage || t('nextcloud-vue', 'Action failed.'))\n\t\t}\n\t\treturn { ok: false, error }\n\t}\n}\n\n/**\n * Resolve an agent-action object reference (`register` / `schema` / `objectId`):\n * an explicitly-declared action value WINS (it may itself be an @-token string,\n * interpolated against the token context), otherwise it falls back to the page\n * object context default (`tokenCtx.register` / `.schema` / `.objectId`). An\n * unresolved token collapses to an empty string (never leaks a literal `@objectId`\n * to the server); a `{ slug | id }` object (a schema holder) is flattened to its\n * slug/id.\n *\n * @param {unknown} actionVal The action's explicit value (may be undefined or an @-token).\n * @param {unknown} ctxDefault The page-context default (`tokenCtx.<field>`).\n * @param {object} tokenCtx The token context the @-tokens resolve against.\n * @return {string} The resolved reference, or '' when unresolved/absent.\n */\nfunction resolveAgentRef(actionVal, ctxDefault, tokenCtx) {\n\tlet v = actionVal\n\tif (v === undefined || v === null || v === '') {\n\t\tv = ctxDefault\n\t} else if (typeof v === 'string') {\n\t\tv = interpolateActionString(v, tokenCtx)\n\t}\n\tif (v && typeof v === 'object') {\n\t\treturn String(v.slug || v.id || '')\n\t}\n\tif (v === undefined || v === null) {\n\t\treturn ''\n\t}\n\treturn String(v)\n}\n\n/**\n * Execute an `agent` action: run a governed hermiq agent against the page's\n * OpenRegister object. Resolves the object context (`register` / `schema` /\n * `objectId` — explicit action fields override, else default to the page's\n * `@register` / `@schema` / `@objectId` context) and POSTs\n * `{ register, schema, objectId, resultField?, skill?, prompt? }` to hermiq's\n * object-RBAC-scoped run endpoint `/apps/hermiq/api/agents/{agent}/run-on-object`\n * (hermiq#41), which dispatches the governed `AgentRunRequestedEvent`.\n *\n * A first-class companion to `type:\"api-call\"` — the author declares \"run agent\n * here\" without hand-wiring the URL/body. `type:\"api-call\"` remains the escape\n * hatch for a bespoke body.\n *\n * Fail-closed. An unresolved REQUIRED `@objectId` (or a missing agent/register/\n * schema) BLOCKS the call (warn) rather than POSTing a literal token. On the\n * server's 202 it toasts `successMessage` (default 'Run queued') and — unless\n * `refresh: false` — bumps the page refresh signal. A 403 / 404 with a structured\n * error body fail-closes with that message; a 404 with NO structured body is read\n * as \"hermiq absent\" and toasts a graceful 'agent runtime unavailable' — the\n * dispatcher NEVER hard-requires hermiq to be installed. Never throws.\n *\n * @param {object} action The agent action (`agent`, `skill?`, `prompt?`,\n * `resultField?`, `register?`, `schema?`, `objectId?`, `successMessage?`,\n * `errorMessage?`, `refresh?`).\n * @param {object} context Runtime context; `context.tokenCtx` is the token\n * context (`{ objectId?, object?, register?, schema?, workspace?, config? }`).\n * @return {Promise<{ok: boolean, data?: unknown, error?: unknown}>} The call outcome.\n */\nasync function executeAgentAction(action, context) {\n\tconst tokenCtx = context.tokenCtx || {}\n\tconst agent = resolveAgentRef(action.agent, undefined, tokenCtx)\n\tconst register = resolveAgentRef(action.register, tokenCtx.register, tokenCtx)\n\tconst schema = resolveAgentRef(action.schema, tokenCtx.schema, tokenCtx)\n\tconst objectId = resolveAgentRef(action.objectId, tokenCtx.objectId, tokenCtx)\n\n\tif (!agent || !register || !schema || !objectId) {\n\t\t// eslint-disable-next-line no-console\n\t\tconsole.warn('[dispatchAction] agent action is missing its agent or a required object-context token (register/schema/objectId) is unresolved — skipping.', action)\n\t\treturn { ok: false, error: new Error('agent action blocked') }\n\t}\n\n\tconst body = { register, schema, objectId }\n\tconst resultField = resolveAgentRef(action.resultField, undefined, tokenCtx)\n\tif (resultField) {\n\t\tbody.resultField = resultField\n\t}\n\tconst skill = resolveAgentRef(action.skill, undefined, tokenCtx)\n\tif (skill) {\n\t\tbody.skill = skill\n\t}\n\tif (typeof action.prompt === 'string' && action.prompt !== '') {\n\t\tbody.prompt = interpolateActionString(action.prompt, tokenCtx)\n\t}\n\n\tconst [{ default: axios }, { generateUrl }, dialogs] = await Promise.all([\n\t\timport('@nextcloud/axios'),\n\t\timport('@nextcloud/router'),\n\t\timport('@nextcloud/dialogs'),\n\t])\n\tconst target = generateUrl(`/apps/hermiq/api/agents/${encodeURIComponent(agent)}/run-on-object`)\n\ttry {\n\t\tconst res = await axios.post(target, body)\n\t\tif (typeof dialogs.showSuccess === 'function') {\n\t\t\tdialogs.showSuccess(translateMessage(action.successMessage, context) || t('nextcloud-vue', 'Run queued'))\n\t\t}\n\t\tif (action.refresh !== false) {\n\t\t\temit(PAGE_REFRESH_CHANNEL, {})\n\t\t}\n\t\treturn { ok: true, data: res && res.data }\n\t} catch (error) {\n\t\tconst response = error && error.response\n\t\tconst status = response && response.status\n\t\tconst serverMessage = response && response.data\n\t\t\t&& (response.data.error || response.data.message)\n\t\t// A 404 with NO structured error body = hermiq is not installed (the app\n\t\t// route 404s at the NC level) — surface a graceful \"runtime unavailable\"\n\t\t// rather than a fail-closed authorization message.\n\t\tconst hermiqAbsent = status === 404 && !serverMessage\n\t\tif (typeof dialogs.showError === 'function') {\n\t\t\tconst msg = hermiqAbsent\n\t\t\t\t? t('nextcloud-vue', 'Agent runtime unavailable')\n\t\t\t\t: (translateMessage(action.errorMessage, context) || serverMessage || t('nextcloud-vue', 'Action failed.'))\n\t\t\tdialogs.showError(msg)\n\t\t}\n\t\treturn { ok: false, error }\n\t}\n}\n\n/**\n * POST the run-node call: `POST /apps/openregister/api/flows/{flowId}/nodes/{nodeId}/run`.\n *\n * This is the SECOND half of `run-node` (manifest-run-node-action / or-flow-run-node) —\n * the first half is `context.openRunNode` in the `dispatchAction` switch below, which\n * only OPENS the config dialog (or decides none is needed) and never itself waits for\n * the person. Once the rendering surface has a `config` object (from the dialog's\n * submit, or `{}` when the node's declared form was empty), it calls this directly —\n * it is not reached through `dispatchAction`'s switch, because by that point there is\n * no further \"type\" dispatch to do, only the call itself, same as `executeAgentAction`\n * is called directly by `case 'api-call'`'s sibling rather than re-entering the switch.\n *\n * Fail-closed exactly like `executeAgentAction`: an unresolved REQUIRED subject\n * (`action.subject`, defaulting to the page's `@objectId`) or a missing\n * `flowId`/`nodeId` BLOCKS the call (warn) rather than POSTing a literal token or an\n * incomplete subject reference. The subject sent is `{ uuid, register, schema }` —\n * OpenRegister's `FlowNodeRunController::resolveAuthorizedSubject()` needs all three\n * to resolve the object and evaluate the caller's object-RBAC permission on it; `register`\n * / `schema` default to the page's own `@register` / `@schema` context, the same\n * defaulting `agent` already uses.\n *\n * A 403 here means the caller holds no update permission on the subject\n * (OpenRegister's object-RBAC, evaluated server-side — RN-1(c)) — this function does not\n * special-case it beyond surfacing the server's message, the same fail-closed handling\n * `api-call` / `agent` already give a rejected call.\n *\n * @param {object} action The run-node action (`flowId`, `nodeId`, `subject?`,\n * `register?`, `schema?`, `successMessage?`, `errorMessage?`, `refresh?`).\n * @param {object} context Runtime context — needs `context.tokenCtx` and, for a\n * localised toast, `context.translate`.\n * @param {object} [config] The node's collected config (from its `configForm()`\n * dialog), or `{}` for a node with no declared fields.\n * @return {Promise<{ok: boolean, data?: object, error?: Error}>} The call outcome —\n * `data` is the created `FlowRun` on success.\n *\n * @spec openspec/changes/manifest-run-node-action/specs/manifest-run-node-action/spec.md#requirement-a-run-node-action-invokes-one-flow-node-against-the-page-object\n */\nexport async function postRunNode(action, context, config = {}) {\n\tconst tokenCtx = context.tokenCtx || {}\n\tconst flowId = resolveAgentRef(action.flowId, undefined, tokenCtx)\n\tconst nodeId = resolveAgentRef(action.nodeId, undefined, tokenCtx)\n\tconst uuid = resolveAgentRef(action.subject, tokenCtx.objectId, tokenCtx)\n\tconst register = resolveAgentRef(action.register, tokenCtx.register, tokenCtx)\n\tconst schema = resolveAgentRef(action.schema, tokenCtx.schema, tokenCtx)\n\n\tif (!flowId || !nodeId || !uuid || !register || !schema) {\n\t\t// eslint-disable-next-line no-console\n\t\tconsole.warn('[dispatchAction] run-node is missing flowId/nodeId or a required subject token (objectId/register/schema) is unresolved — skipping.', action)\n\t\treturn { ok: false, error: new Error('run-node blocked') }\n\t}\n\n\tconst [{ default: axios }, { generateUrl }, dialogs] = await Promise.all([\n\t\timport('@nextcloud/axios'),\n\t\timport('@nextcloud/router'),\n\t\timport('@nextcloud/dialogs'),\n\t])\n\tconst target = generateUrl(`/apps/openregister/api/flows/${encodeURIComponent(flowId)}/nodes/${encodeURIComponent(nodeId)}/run`)\n\ttry {\n\t\tconst res = await axios.post(target, { subject: { uuid, register, schema }, config: config || {} })\n\t\tif (typeof dialogs.showSuccess === 'function') {\n\t\t\tdialogs.showSuccess(translateMessage(action.successMessage, context) || t('nextcloud-vue', 'Run completed.'))\n\t\t}\n\t\tif (action.refresh !== false) {\n\t\t\temit(PAGE_REFRESH_CHANNEL, {})\n\t\t}\n\t\treturn { ok: true, data: res && res.data }\n\t} catch (error) {\n\t\tconst response = error && error.response\n\t\tconst serverMessage = response && response.data\n\t\t\t&& (response.data.error || response.data.message)\n\t\tif (typeof dialogs.showError === 'function') {\n\t\t\tdialogs.showError(translateMessage(action.errorMessage, context) || serverMessage || t('nextcloud-vue', 'Action failed.'))\n\t\t}\n\t\treturn { ok: false, error }\n\t}\n}\n\n/**\n * Dispatch a v2 manifest action.\n *\n * @param {object} action The action object from the manifest.\n * @param {string} [action.type] Dispatch type: \"handler\" | \"open-modal\" | \"open-page\" | \"navigate\" |\n * \"object-op\" | \"export\" | \"open-form\" | \"refresh\" | \"api-call\" | \"agent\".\n * When absent, treated as \"handler\" for v1 backward compatibility.\n * @param {string} [action.handler] Registry key for \"handler\" type. For \"export\": the optional\n * handler invoked by the host with the dialog's confirm payload (`{ format, entity }`).\n * @param {Array} [action.args] Arguments spread to the handler function.\n * @param {string} [action.target] Target for \"open-modal\", \"open-page\", and \"navigate\" types.\n * @param {object} [action.props] Props forwarded to modal for \"open-modal\" type.\n * @param {string} [action.op] \"object-op\" only: mutation verb — \"patch\" | \"delete\" | \"create\".\n * @param {object} [action.values] \"object-op\" only: the verb's payload — the partial object\n * merged over the row for \"patch\", the new object's properties for \"create\"; ignored for \"delete\".\n * @param {boolean} [action.confirm] \"object-op\" only: confirm-gating INTENT consumed by the\n * rendering host (CnWidgetObjectTable routes it through CnConfirmDialog) — the dispatcher\n * itself never gates; it is called after any confirmation already happened.\n * @param {Array<{id: string, label: string}>} [action.entities] \"export\" only: selectable\n * entity types offered by the export launcher (e.g. Leads / Requests). Optional — when\n * absent the dialog shows only the format picker.\n * @param {Array<string|{id: string, label: string}>} [action.formats] \"export\" only: the\n * offered export formats (bare ids like \"csv\" or full `{id, label}` entries). Optional —\n * the dialog's built-in Excel/CSV defaults apply when absent.\n * @param {string} [action.description] \"export\" only: pre-translated description shown\n * above the pickers.\n * @param {string} [action.url] \"api-call\" only: the app endpoint — app-relative (routed\n * through generateUrl) or absolute. May interpolate the shared URL tokens\n * (`@objectId`, `@object.<field>`, `@workspace.<key>`, `@config.<key>`, and the\n * `{objectId}` brace form).\n * @param {string} [action.method] \"api-call\" only: \"POST\" (default) | \"PUT\".\n * @param {object} [action.payload] \"api-call\" only: the JSON body — preferred over `params`.\n * Values resolve the shared `@`-token grammar RECURSIVELY at any nesting depth (objects\n * and arrays of objects, e.g. `{ dataRefs: [{ id: '@objectId' }] }`); optional (`…?`)\n * tokens drop when unresolved anywhere in the tree, an unresolved REQUIRED token blocks\n * the call. When set, `params` is ignored.\n * @param {object} [action.params] \"api-call\" only: legacy JSON body (ignored when `payload`\n * is set). Values pass the shared filter-token grammar ONE level deep; optional (`…?`)\n * tokens drop when unresolved, an unresolved REQUIRED token blocks the call.\n * @param {boolean} [action.download] \"api-call\" only: request the response as a binary blob\n * (`responseType: 'blob'`) and trigger a browser file download instead of a JSON\n * toast+refresh cycle. Default `false`.\n * @param {string} [action.filename] \"api-call\" `download: true` only: fallback filename when\n * the response carries no `Content-Disposition` header (falls back further to\n * `'download.pdf'`). Interpolates the same token grammar as `url`.\n * @param {string} [action.successMessage] \"api-call\" / \"open-form\": pre-translated success\n * toast text (a library default applies when absent).\n * @param {string} [action.errorMessage] \"api-call\" / \"open-form\": pre-translated error toast\n * text (falls back to the server's `error`/`message`, then a library default).\n * @param {boolean} [action.refresh] \"api-call\" / \"agent\" only: bump the `cn:page:refresh` signal\n * after a successful call. Default `true` — EXCEPT for a `download: true` api-call, whose\n * default is `false` (a file download normally shouldn't also force-refetch every widget); set\n * the flag explicitly either way to override.\n * @param {string} [action.agent] \"agent\" only (REQUIRED): the hermiq agent uuid to run against\n * the page object. POSTed to `/apps/hermiq/api/agents/{agent}/run-on-object` (hermiq#41).\n * @param {string} [action.skill] \"agent\" only: optional skill id folded into the governed run.\n * @param {string} [action.prompt] \"agent\" only: optional prompt (interpolates the shared `@`-token\n * grammar inline — `@objectId`, `@object.<field>`, `@workspace.<key>`, `@config.<key>`).\n * @param {string} [action.resultField] \"agent\" only: object field the agent's result is written to.\n * @param {string} [action.register] \"agent\" / \"open-form\": OpenRegister register slug (agent:\n * defaults to the page object context's `@register`).\n * @param {string} [action.schema] \"agent\" / \"open-form\": OpenRegister schema slug (agent: defaults\n * to the page object context's `@schema`).\n * @param {string} [action.objectId] \"agent\" only: the target object id (defaults to the page\n * object context's `@objectId`). An unresolved required token BLOCKS the call (fail-closed).\n *\n * @param {object} context Runtime context.\n * @param {object} [context.router] Vue Router instance. Required for \"open-page\" and \"navigate\".\n * @param {object} [context.registry] Component registry (Record<string, { kind, component }>).\n * Required for \"open-modal\" type.\n * @param {object} [context.handlers] Map of handler name → function. Required for \"handler\" type.\n * @param {(key: string, props?: object) => void} [context.openModal] Opens a modal.\n * Required for \"open-modal\" type.\n * @param {(action: object) => void} [context.openExport] Opens the shared\n * CnMassExportDialog configured from the action. Required for \"export\" type —\n * CnPageRenderer pre-binds it in the `cnDispatchAction` context.\n * @param {(action: object) => void} [context.openForm] Opens the schema-driven\n * create dialog. Required for \"open-form\" type — the rendering surface\n * (CnActionButtons) provides it, mirroring `openExport`. On a successful save the\n * surface navigates to `action.onSuccessRoute` (a route NAME string, or\n * `{name, paramField?, objectParam?}`) via {@link buildOnSuccessRoute}, which merges\n * the saved object's id into the route params so the navigation can deep-link to the\n * created object.\n * @param {(action: object) => void} [context.openRunNode] Opens the\n * node-config dialog (or runs immediately for an empty config form) and\n * POSTs to OpenRegister's direct-invoke endpoint on submit. Required for\n * \"run-node\" type — the rendering surface (CnActionButtons) provides it,\n * mirroring `openForm`.\n * @param {{objectId?: (string|number), object?: object, workspace?: object, config?: object}} [context.tokenCtx]\n * Token context \"api-call\" URLs/params resolve against (the same shape\n * `resolveFilterTokens` / `interpolateUrlTokens` take).\n * @param {(app: string, text: string, vars?: object) => string} [context.translate] The consumer's bound `t()`, the same\n * `cnTranslate` CnAppRoot provides to the page chrome. Applied to the\n * manifest-authored `successMessage` / `errorMessage` of \"api-call\" and\n * \"agent\" so their toasts follow the user's language. Omitted (or a\n * catalogue miss) leaves the message byte-identical.\n * @param {object} [context.objectStore] Object store instance (useObjectStore shape).\n * Required for \"object-op\" type. All mutations go through `saveObject` / `deleteObject`\n * so store caches (and their no-mutation-on-error semantics) apply.\n * @param {{register: (string|number), schema: (string|number)}} [context.source] The widget's\n * declarative source the mutation targets. Required for \"object-op\" type.\n * @param {object} [context.row] The row object a row-scoped \"object-op\" (patch/delete) mutates.\n *\n * @return {Promise<object|boolean|null>|undefined} For \"object-op\": the store call's promise —\n * the saved object (or `null` on a rejected write) for patch/create, `true`/`false` for\n * delete. The store only mutates its local caches on SUCCESS, so a backend (RBAC) rejection\n * surfaces via the store's `errors[type]` without any local state change. For \"api-call\":\n * a promise of `{ ok, data?, error? }` (toasts + refresh already handled). All other types\n * return undefined.\n */\nexport function dispatchAction(action, context = {}) {\n\tif (!action || typeof action !== 'object') {\n\t\t// eslint-disable-next-line no-console\n\t\tconsole.warn('[dispatchAction] Received invalid action:', action)\n\t\treturn\n\t}\n\n\t// Missing type is treated as \"handler\" for v1 backward compatibility\n\tconst type = action.type || 'handler'\n\n\tswitch (type) {\n\t\tcase 'handler': {\n\t\t\tconst handlerName = action.handler\n\t\t\tconst handlers = context.handlers || {}\n\n\t\t\tif (!handlerName || typeof handlers[handlerName] !== 'function') {\n\t\t\t// eslint-disable-next-line no-console\n\t\t\t\tconsole.warn(`[dispatchAction] Handler \"${handlerName}\" not found in context.handlers.`)\n\t\t\t\treturn\n\t\t\t}\n\t\t\thandlers[handlerName](...(action.args ?? []))\n\t\t\tbreak\n\t\t}\n\n\t\tcase 'open-modal': {\n\t\t\tconst target = action.target\n\t\t\tconst registry = context.registry || {}\n\t\t\tconst entry = registry[target]\n\n\t\t\tif (!entry) {\n\t\t\t// eslint-disable-next-line no-console\n\t\t\t\tconsole.warn(`[dispatchAction] open-modal target \"${target}\" not found in registry.`)\n\t\t\t\treturn\n\t\t\t}\n\n\t\t\tif (entry.kind !== 'modal') {\n\t\t\t// eslint-disable-next-line no-console\n\t\t\t\tconsole.warn(`[dispatchAction] open-modal target \"${target}\" has kind \"${entry.kind}\" (expected \"modal\").`)\n\t\t\t\treturn\n\t\t\t}\n\n\t\t\tif (typeof context.openModal !== 'function') {\n\t\t\t// eslint-disable-next-line no-console\n\t\t\t\tconsole.warn('[dispatchAction] open-modal requires context.openModal to be a function.')\n\t\t\t\treturn\n\t\t\t}\n\n\t\t\tcontext.openModal(target, action.props ?? {})\n\t\t\tbreak\n\t\t}\n\n\t\tcase 'open-page': {\n\t\t\tif (!context.router) {\n\t\t\t// eslint-disable-next-line no-console\n\t\t\t\tconsole.warn('[dispatchAction] open-page requires context.router to be a Vue Router instance.')\n\t\t\t\treturn\n\t\t\t}\n\t\t\tcontext.router.push({ name: action.target })\n\t\t\tbreak\n\t\t}\n\n\t\tcase 'navigate': {\n\t\t\t// A target is a URL exactly as `url` is, so it runs the same token\n\t\t\t// grammar. Without this a manifest's `{objectId}` reached the router\n\t\t\t// as those nine literal characters and landed in the address bar.\n\t\t\tconst target = interpolateActionString(action.target || '', context.tokenCtx || {})\n\n\t\t\t// An external target is not a route. Rendering surfaces should give it\n\t\t\t// to the browser as a real link (CnActionButtons does); this is the\n\t\t\t// fallback for a programmatic dispatch, and it must not reach the\n\t\t\t// router — see isExternalActionTarget.\n\t\t\tif (isExternalActionTarget(target)) {\n\t\t\t\twindow.open(target, '_blank', 'noopener,noreferrer')\n\t\t\t\tbreak\n\t\t\t}\n\t\t\tif (!context.router) {\n\t\t\t// eslint-disable-next-line no-console\n\t\t\t\tconsole.warn('[dispatchAction] navigate requires context.router to be a Vue Router instance.')\n\t\t\t\treturn\n\t\t\t}\n\t\t\tcontext.router.push(target)\n\t\t\tbreak\n\t\t}\n\n\t\tcase 'export': {\n\t\t// Export launcher (Wave 1, nextcloud-vue#91): the host page opens the\n\t\t// shared CnMassExportDialog configured via the action's entities[] /\n\t\t// formats[]; the dialog's confirm payload routes to the action's\n\t\t// optional `handler` (the app's export service does the download).\n\t\t\tif (typeof context.openExport !== 'function') {\n\t\t\t// eslint-disable-next-line no-console\n\t\t\t\tconsole.warn('[dispatchAction] export requires context.openExport to be a function.')\n\t\t\t\treturn\n\t\t\t}\n\t\t\tcontext.openExport(action)\n\t\t\tbreak\n\t\t}\n\n\t\tcase 'open-form': {\n\t\t// Schema-driven create dialog (Wave 3, nextcloud-vue#91): the\n\t\t// rendering surface (CnActionButtons) mounts the shared\n\t\t// CnAdvancedFormDialog and handles the save — mirroring how\n\t\t// `export` delegates to the host's CnMassExportDialog.\n\t\t\tif (typeof context.openForm !== 'function') {\n\t\t\t// eslint-disable-next-line no-console\n\t\t\t\tconsole.warn('[dispatchAction] open-form requires context.openForm to be a function.')\n\t\t\t\treturn\n\t\t\t}\n\t\t\tcontext.openForm(action)\n\t\t\tbreak\n\t\t}\n\n\t\tcase 'run-node': {\n\t\t// Direct flow-node invocation (manifest-run-node-action / RN-4):\n\t\t// SAME shape as open-form, deliberately — the rendering surface\n\t\t// (CnActionButtons) resolves the node's own config form, opens a\n\t\t// generic dialog when it has fields (skips it when empty), and\n\t\t// POSTs subject+config to OpenRegister's\n\t\t// /api/flows/{flowId}/nodes/{nodeId}/run on submit. This case\n\t\t// resolves as soon as the dialog OPENS (or the empty-form call\n\t\t// starts) — it does NOT wait for the person to answer, matching\n\t\t// every other consumer's assumption that dispatchAction's Promise\n\t\t// means \"the call happened\", not \"the human decided\" (see design.md\n\t\t// RN-4 for why an awaiting-on-UI shape was rejected).\n\t\t\tif (typeof context.openRunNode !== 'function') {\n\t\t\t// eslint-disable-next-line no-console\n\t\t\t\tconsole.warn('[dispatchAction] run-node requires context.openRunNode to be a function.')\n\t\t\t\treturn\n\t\t\t}\n\t\t\tcontext.openRunNode(action)\n\t\t\tbreak\n\t\t}\n\n\t\tcase 'refresh': {\n\t\t// Page-level refresh (Wave 3, nextcloud-vue#91): bump the SAME\n\t\t// `cn:page:refresh` event-bus signal the page overflow menu's\n\t\t// Refresh item broadcasts — every endpoint-bound / bus-subscribed\n\t\t// widget on the page force-refetches past its shared cache.\n\t\t\temit(PAGE_REFRESH_CHANNEL, {})\n\t\t\tbreak\n\t\t}\n\n\t\tcase 'api-call': {\n\t\t// POST/PUT an app endpoint + toast + refresh (Wave 3). Any\n\t\t// `confirm` on the action is INTENT the rendering surface consumed\n\t\t// BEFORE calling the dispatcher (object-op precedent) — no gating\n\t\t// happens here.\n\t\t\treturn executeApiCall(action, context)\n\t\t}\n\n\t\tcase 'agent': {\n\t\t// Run a governed hermiq agent against the page object (hermiq#41). A\n\t\t// first-class companion to api-call: resolves the object context\n\t\t// (register/schema/objectId) and POSTs run-on-object. Any `confirm`\n\t\t// on the action is INTENT the rendering surface consumed BEFORE\n\t\t// dispatch (api-call / object-op precedent) — no gating here. hermiq\n\t\t// is NOT hard-required: an app-level 404 surfaces a graceful toast.\n\t\t\treturn executeAgentAction(action, context)\n\t\t}\n\n\t\tcase 'toggle': {\n\t\t// A toggle is a stateful two-way control (GET state on mount,\n\t\t// write on click) — it is RENDERED by the header-actions surface\n\t\t// (CnActionButtons), never dispatched as a one-shot action.\n\t\t// eslint-disable-next-line no-console\n\t\t\tconsole.warn('[dispatchAction] \"toggle\" is a stateful header-actions control rendered by CnActionButtons — it cannot be dispatched.')\n\t\t\treturn\n\t\t}\n\n\t\tcase 'object-op': {\n\t\t// Declarative mutation of an OpenRegister object, dispatched via the\n\t\t// shared object store (ADR-049). The manifest declares INTENT only:\n\t\t// authorization-shaped fields on the action (`role`, `allow`, …) are\n\t\t// NEVER consulted here — OpenRegister RBAC is the single authority\n\t\t// (ADR-022 / ADR-023) and a forbidden mutation is rejected server-side.\n\t\t// The store mutates its caches only on success, so a rejected write\n\t\t// surfaces as an error with no local state change.\n\t\t\tconst op = action.op\n\t\t\tif (op !== 'patch' && op !== 'delete' && op !== 'create') {\n\t\t\t// eslint-disable-next-line no-console\n\t\t\t\tconsole.warn(`[dispatchAction] object-op has invalid op \"${op}\" (expected patch | delete | create).`)\n\t\t\t\treturn\n\t\t\t}\n\t\t\tconst store = context.objectStore\n\t\t\tif (!store || typeof store.saveObject !== 'function' || typeof store.deleteObject !== 'function') {\n\t\t\t// eslint-disable-next-line no-console\n\t\t\t\tconsole.warn('[dispatchAction] object-op requires context.objectStore (useObjectStore shape).')\n\t\t\t\treturn\n\t\t\t}\n\t\t\tconst source = context.source\n\t\t\tif (!source || !source.register || !source.schema) {\n\t\t\t// eslint-disable-next-line no-console\n\t\t\t\tconsole.warn('[dispatchAction] object-op requires context.source with register + schema.')\n\t\t\t\treturn\n\t\t\t}\n\t\t\tconst type = resolveObjectOpType(store, source)\n\n\t\t\tif (op === 'create') {\n\t\t\t\treturn store.saveObject(type, { ...(action.values || {}) })\n\t\t\t}\n\n\t\t\tconst row = context.row\n\t\t\tconst id = rowObjectId(row)\n\t\t\tif (id === null) {\n\t\t\t// eslint-disable-next-line no-console\n\t\t\t\tconsole.warn(`[dispatchAction] object-op \"${op}\" is row-scoped and requires context.row with an id.`)\n\t\t\t\treturn\n\t\t\t}\n\t\t\tif (op === 'delete') {\n\t\t\t\treturn store.deleteObject(type, id)\n\t\t\t}\n\t\t\t// patch: the row's object merged with the action's values.\n\t\t\treturn store.saveObject(type, { ...row, ...(action.values || {}), id })\n\t\t}\n\n\t\tdefault:\n\t\t// eslint-disable-next-line no-console\n\t\t\tconsole.warn(`[dispatchAction] Unknown action type \"${type}\".`)\n\t}\n}\n"],"names":["t"],"mappings":";;;;;;;;AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AAeA;AACA;AACA,MAAM,oBAAoB,GAAG,kBAAiB;AAC9C;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACO,SAAS,sBAAsB,CAAC,MAAM,EAAE;AAC/C,CAAC,IAAI,OAAO,MAAM,KAAK,QAAQ,EAAE;AACjC,EAAE,OAAO,KAAK;AACd,EAAE;AACF,CAAC,OAAO,OAAO,CAAC,IAAI,CAAC,MAAM,CAAC,IAAI,wBAAwB,CAAC,IAAI,CAAC,MAAM,CAAC;AACrE,CAAC;AACD;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACO,SAAS,mBAAmB,CAAC,KAAK,EAAE,MAAM,EAAE,OAAO,GAAG,EAAE,EAAE;AACjE,CAAC,MAAM,QAAQ,GAAG,MAAM,CAAC,MAAM,CAAC,QAAQ,EAAC;AACzC,CAAC,MAAM,MAAM,GAAG,OAAO,CAAC,WAAW,KAAK,IAAI,GAAG,MAAM,CAAC,MAAM,CAAC,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AAE;AACF,CAAC;AACD;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACO,SAAS,cAAc,CAAC,MAAM,EAAE,OAAO,GAAG,EAAE,EAAE;AACrD,CAAC,IAAI,CAAC,MAAM,IAAI,OAAO,MAAM,KAAK,QAAQ,EAAE;AAC5C;AACA,EAAE,OAAO,CAAC,IAAI,CAAC,2CAA2C,EAAE,MAAM,EAAC;AACnE,EAAE,MAAM;AACR,EAAE;AACF;AACA;AACA,CAAC,MAAM,IAAI,GAAG,MAAM,CAAC,IAAI,IAAI,UAAS;AACtC;AACA,CAAC,QAAQ,IAAI;AACb,EAAE,KAAK,SAAS,EAAE;AAClB,GAAG,MAAM,WAAW,GAAG,MAAM,CAAC,QAAO;AACrC,GAAG,MAAM,QAAQ,GAAG,OAAO,CAAC,QAAQ,IAAI,GAAE;AAC1C;AACA,GAAG,IAAI,CAAC,WAAW,IAAI,OAAO,QAAQ,CAAC,WAAW,CAAC,KAAK,UAAU,EAAE;AACpE;AACA,IAAI,OAAO,CAAC,IAAI,CAAC,CAAC,0BAA0B,EAAE,WAAW,CAAC,gCAAgC,CAAC,EAAC;AAC5F,IAAI,MAAM;AACV,IAAI;AACJ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AC,EAAC;AAClE,EAAE;AACF;;;;"}
|
|
@@ -6,6 +6,9 @@ import { schemaRefSlug } from './schemaRefSlug.js';
|
|
|
6
6
|
*/
|
|
7
7
|
|
|
8
8
|
|
|
9
|
+
/** OpenRegister's case-insensitive contains operator, used by the text filter. */
|
|
10
|
+
const CONTAINS_OPERATOR = 'like';
|
|
11
|
+
|
|
9
12
|
/** Column keys that mark a value computed on the client, never stored. */
|
|
10
13
|
const COMPUTED_MARKERS = ['aggregate', 'compute', 'computed', 'virtual'];
|
|
11
14
|
|
|
@@ -144,7 +147,7 @@ function referenceTarget(column, prop) {
|
|
|
144
147
|
*
|
|
145
148
|
* Kinds: `enum` (checkbox list), `boolean` (yes, no, any), `reference`
|
|
146
149
|
* (searchable list of the referenced objects), `number` and `date` (from and
|
|
147
|
-
* to), and `string` (
|
|
150
|
+
* to), and `string` (contains, through OpenRegister's `[like]`). `filterable: false` on the column turns it
|
|
148
151
|
* off. A column with no schema property behind it only filters when it
|
|
149
152
|
* carries an enum hint (`enum`, or a badge widget's colour map), because the
|
|
150
153
|
* server cannot filter on a value it does not store.
|
|
@@ -218,9 +221,25 @@ function columnFilterParamKeys(def) {
|
|
|
218
221
|
if (def.kind === 'number' || def.kind === 'date') {
|
|
219
222
|
return [`${def.key}[gte]`, `${def.key}[lte]`]
|
|
220
223
|
}
|
|
224
|
+
if (def.kind === 'string') {
|
|
225
|
+
return [containsKey(def)]
|
|
226
|
+
}
|
|
221
227
|
return [def.key]
|
|
222
228
|
}
|
|
223
229
|
|
|
230
|
+
/**
|
|
231
|
+
* The parameter a text filter writes: `{key}[like]`. An exact `key=value`
|
|
232
|
+
* from the facet sidebar or a fixed filter is a different key, so the header
|
|
233
|
+
* neither shows nor clears it.
|
|
234
|
+
*
|
|
235
|
+
* @param {object} def A filter definition of kind `string`.
|
|
236
|
+
* @return {string} The parameter key.
|
|
237
|
+
* @spec openspec/changes/header-filter-contains/specs/cn-data-table/spec.md#requirement-a-text-header-filter-matches-on-contains
|
|
238
|
+
*/
|
|
239
|
+
function containsKey(def) {
|
|
240
|
+
return `${def.key}[${CONTAINS_OPERATOR}]`
|
|
241
|
+
}
|
|
242
|
+
|
|
224
243
|
/**
|
|
225
244
|
* A column filter's current state, read from the active-filter map.
|
|
226
245
|
*
|
|
@@ -246,6 +265,9 @@ function columnFilterState(def, activeFilters) {
|
|
|
246
265
|
to: def.kind === 'date' ? to.slice(0, 10) : to,
|
|
247
266
|
}
|
|
248
267
|
}
|
|
268
|
+
if (def.kind === 'string') {
|
|
269
|
+
return { value: asList(filters[containsKey(def)])[0] || '' }
|
|
270
|
+
}
|
|
249
271
|
return { value: asList(filters[def.key])[0] || '' }
|
|
250
272
|
}
|
|
251
273
|
|
|
@@ -293,8 +315,10 @@ function columnFilterParams(def, state) {
|
|
|
293
315
|
if (def.kind === 'boolean') {
|
|
294
316
|
return { [def.key]: (s.value === 'true' || s.value === 'false') ? [s.value] : [] }
|
|
295
317
|
}
|
|
318
|
+
// Text: the raw term under `[like]`. No wildcards: OpenRegister wraps
|
|
319
|
+
// the term itself and escapes `%`, `_` and `\` in it.
|
|
296
320
|
const value = s.value === undefined || s.value === null ? '' : String(s.value).trim();
|
|
297
|
-
return { [def
|
|
321
|
+
return { [containsKey(def)]: value === '' ? [] : [value] }
|
|
298
322
|
}
|
|
299
323
|
|
|
300
324
|
/**
|
|
@@ -307,5 +331,5 @@ function clearedColumnFilterParams(def) {
|
|
|
307
331
|
return Object.fromEntries(columnFilterParamKeys(def).map((key) => [key, []]))
|
|
308
332
|
}
|
|
309
333
|
|
|
310
|
-
export { clearedColumnFilterParams, columnFilterDef, columnFilterParamKeys, columnFilterParams, columnFilterState, columnProperty, isColumnFilterActive, isColumnSortable };
|
|
334
|
+
export { CONTAINS_OPERATOR, clearedColumnFilterParams, columnFilterDef, columnFilterParamKeys, columnFilterParams, columnFilterState, columnProperty, isColumnFilterActive, isColumnSortable };
|
|
311
335
|
//# sourceMappingURL=columnFilters.js.map
|