@conduction/nextcloud-vue 2.56.0-beta.11 → 2.56.0-beta.13

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (138) hide show
  1. package/dist/esm/components/CnAppNav/CnAppNav.vue2.js +253 -10
  2. package/dist/esm/components/CnAppNav/CnAppNav.vue2.js.map +1 -1
  3. package/dist/esm/components/CnAppNav/CnAppNav.vue3.js +139 -46
  4. package/dist/esm/components/CnAppNav/CnAppNav.vue3.js.map +1 -1
  5. package/dist/esm/components/CnAppRoot/CnAppRoot.vue2.js +87 -0
  6. package/dist/esm/components/CnAppRoot/CnAppRoot.vue2.js.map +1 -1
  7. package/dist/esm/components/CnAppRoot/CnAppRoot.vue3.js +26 -24
  8. package/dist/esm/components/CnAppRoot/CnAppRoot.vue3.js.map +1 -1
  9. package/dist/esm/components/CnAuditTrailCard/CnAuditTrailCard.vue2.js +61 -16
  10. package/dist/esm/components/CnAuditTrailCard/CnAuditTrailCard.vue2.js.map +1 -1
  11. package/dist/esm/components/CnAuditTrailCard/CnAuditTrailCard.vue3.js.map +1 -1
  12. package/dist/esm/components/CnAuditTrailWidget/CnAuditTrailWidget.vue2.js +20 -0
  13. package/dist/esm/components/CnAuditTrailWidget/CnAuditTrailWidget.vue2.js.map +1 -1
  14. package/dist/esm/components/CnAuditTrailWidget/CnAuditTrailWidget.vue3.js +3 -2
  15. package/dist/esm/components/CnAuditTrailWidget/CnAuditTrailWidget.vue3.js.map +1 -1
  16. package/dist/esm/components/CnBreadcrumbs/CnBreadcrumbs.vue2.js +13 -0
  17. package/dist/esm/components/CnBreadcrumbs/CnBreadcrumbs.vue2.js.map +1 -1
  18. package/dist/esm/components/CnBreadcrumbs/CnBreadcrumbs.vue3.js +2 -1
  19. package/dist/esm/components/CnBreadcrumbs/CnBreadcrumbs.vue3.js.map +1 -1
  20. package/dist/esm/components/CnCellRenderer/CnCellRenderer.vue2.js +33 -2
  21. package/dist/esm/components/CnCellRenderer/CnCellRenderer.vue2.js.map +1 -1
  22. package/dist/esm/components/CnCellRenderer/CnCellRenderer.vue3.js.map +1 -1
  23. package/dist/esm/components/CnDashboardPage/CnDashboardPage.vue2.js +154 -4
  24. package/dist/esm/components/CnDashboardPage/CnDashboardPage.vue2.js.map +1 -1
  25. package/dist/esm/components/CnDashboardPage/CnDashboardPage.vue3.js +555 -480
  26. package/dist/esm/components/CnDashboardPage/CnDashboardPage.vue3.js.map +1 -1
  27. package/dist/esm/components/CnDataTable/CnColumnFilterPopover.vue2.js +9 -3
  28. package/dist/esm/components/CnDataTable/CnColumnFilterPopover.vue2.js.map +1 -1
  29. package/dist/esm/components/CnDataTable/CnColumnFilterPopover.vue3.js +1 -1
  30. package/dist/esm/components/CnDataTable/CnColumnFilterPopover.vue3.js.map +1 -1
  31. package/dist/esm/components/CnDataTable/CnDataTable.vue2.js +37 -1
  32. package/dist/esm/components/CnDataTable/CnDataTable.vue2.js.map +1 -1
  33. package/dist/esm/components/CnDataTable/CnDataTable.vue3.js +12 -4
  34. package/dist/esm/components/CnDataTable/CnDataTable.vue3.js.map +1 -1
  35. package/dist/esm/components/CnDetailPage/CnDetailPage.vue2.js +187 -19
  36. package/dist/esm/components/CnDetailPage/CnDetailPage.vue2.js.map +1 -1
  37. package/dist/esm/components/CnDetailPage/CnDetailPage.vue3.js +215 -135
  38. package/dist/esm/components/CnDetailPage/CnDetailPage.vue3.js.map +1 -1
  39. package/dist/esm/components/CnFkResolveCell/CnFkResolveCell.vue2.js +3 -1
  40. package/dist/esm/components/CnFkResolveCell/CnFkResolveCell.vue2.js.map +1 -1
  41. package/dist/esm/components/CnFormDialog/CnFormDialog.vue2.js +144 -4
  42. package/dist/esm/components/CnFormDialog/CnFormDialog.vue2.js.map +1 -1
  43. package/dist/esm/components/CnFormDialog/CnFormDialog.vue3.js.map +1 -1
  44. package/dist/esm/components/CnHeaderWidget/CnHeaderWidget.vue2.js +157 -7
  45. package/dist/esm/components/CnHeaderWidget/CnHeaderWidget.vue2.js.map +1 -1
  46. package/dist/esm/components/CnHeaderWidget/CnHeaderWidget.vue3.js +23 -5
  47. package/dist/esm/components/CnHeaderWidget/CnHeaderWidget.vue3.js.map +1 -1
  48. package/dist/esm/components/CnIndexPage/CnIndexPage.vue2.js +30 -0
  49. package/dist/esm/components/CnIndexPage/CnIndexPage.vue2.js.map +1 -1
  50. package/dist/esm/components/CnIndexPage/CnIndexPage.vue3.js +2 -2
  51. package/dist/esm/components/CnIndexPage/CnIndexPage.vue3.js.map +1 -1
  52. package/dist/esm/components/CnObjectListWidget/CnObjectListWidget.vue2.js +5 -1
  53. package/dist/esm/components/CnObjectListWidget/CnObjectListWidget.vue2.js.map +1 -1
  54. package/dist/esm/components/CnObjectListWidget/CnObjectListWidget.vue3.js +4 -2
  55. package/dist/esm/components/CnObjectListWidget/CnObjectListWidget.vue3.js.map +1 -1
  56. package/dist/esm/components/CnSegmentedControl/CnSegmentedControl.vue2.js +11 -0
  57. package/dist/esm/components/CnSegmentedControl/CnSegmentedControl.vue2.js.map +1 -1
  58. package/dist/esm/components/CnSegmentedControl/CnSegmentedControl.vue3.js +2 -1
  59. package/dist/esm/components/CnSegmentedControl/CnSegmentedControl.vue3.js.map +1 -1
  60. package/dist/esm/components/CnStagesWidget/CnStagesWidget.vue2.js +63 -2
  61. package/dist/esm/components/CnStagesWidget/CnStagesWidget.vue2.js.map +1 -1
  62. package/dist/esm/components/CnStagesWidget/CnStagesWidget.vue3.js +96 -37
  63. package/dist/esm/components/CnStagesWidget/CnStagesWidget.vue3.js.map +1 -1
  64. package/dist/esm/components/CnStagesWidget/stagesModel.js +5 -2
  65. package/dist/esm/components/CnStagesWidget/stagesModel.js.map +1 -1
  66. package/dist/esm/components/CnStatWidget/CnStatWidget.vue2.js +74 -5
  67. package/dist/esm/components/CnStatWidget/CnStatWidget.vue2.js.map +1 -1
  68. package/dist/esm/components/CnStatWidget/CnStatWidget.vue3.js +15 -8
  69. package/dist/esm/components/CnStatWidget/CnStatWidget.vue3.js.map +1 -1
  70. package/dist/esm/components/CnTabsWidget/CnTabsWidget.vue2.js +14 -2
  71. package/dist/esm/components/CnTabsWidget/CnTabsWidget.vue2.js.map +1 -1
  72. package/dist/esm/components/CnTabsWidget/CnTabsWidget.vue3.js +2 -1
  73. package/dist/esm/components/CnTabsWidget/CnTabsWidget.vue3.js.map +1 -1
  74. package/dist/esm/components/CnWidgetWrapper/CnWidgetWrapper.vue2.js +73 -1
  75. package/dist/esm/components/CnWidgetWrapper/CnWidgetWrapper.vue2.js.map +1 -1
  76. package/dist/esm/components/CnWidgetWrapper/CnWidgetWrapper.vue3.js +14 -2
  77. package/dist/esm/components/CnWidgetWrapper/CnWidgetWrapper.vue3.js.map +1 -1
  78. package/dist/esm/l10n/en.json.js +5 -1
  79. package/dist/esm/l10n/en.json.js.map +1 -1
  80. package/dist/esm/l10n/nl.json.js +5 -1
  81. package/dist/esm/l10n/nl.json.js.map +1 -1
  82. package/dist/esm/mixins/pageViews.js +400 -0
  83. package/dist/esm/mixins/pageViews.js.map +1 -0
  84. package/dist/esm/nextcloud-vue.css +513 -81
  85. package/dist/esm/store/useObjectStore.js +118 -33
  86. package/dist/esm/store/useObjectStore.js.map +1 -1
  87. package/dist/esm/utils/actionsDispatcher.js +25 -2
  88. package/dist/esm/utils/actionsDispatcher.js.map +1 -1
  89. package/dist/esm/utils/columnFilters.js +27 -3
  90. package/dist/esm/utils/columnFilters.js.map +1 -1
  91. package/dist/esm/utils/schema.js +40 -2
  92. package/dist/esm/utils/schema.js.map +1 -1
  93. package/dist/esm/utils/schemaRefSlug.js +19 -3
  94. package/dist/esm/utils/schemaRefSlug.js.map +1 -1
  95. package/dist/esm/utils/validateManifestV2.compiled.js +2 -2
  96. package/dist/esm/utils/validateManifestV2.compiled.js.map +1 -1
  97. package/dist/nextcloud-vue.cjs.js +8858 -6566
  98. package/dist/nextcloud-vue.cjs.js.map +2 -2
  99. package/dist/nextcloud-vue.css +513 -81
  100. package/l10n/en.json +5 -0
  101. package/l10n/nl.json +5 -0
  102. package/package.json +1 -1
  103. package/src/components/CnAppNav/CnAppNav.vue +441 -14
  104. package/src/components/CnAppRoot/CnAppRoot.md +4 -0
  105. package/src/components/CnAppRoot/CnAppRoot.vue +94 -1
  106. package/src/components/CnAuditTrailCard/CnAuditTrailCard.vue +61 -16
  107. package/src/components/CnAuditTrailWidget/CnAuditTrailWidget.vue +22 -1
  108. package/src/components/CnBreadcrumbs/CnBreadcrumbs.vue +14 -0
  109. package/src/components/CnCellRenderer/CnCellRenderer.vue +33 -2
  110. package/src/components/CnDashboardPage/CnDashboardPage.vue +237 -12
  111. package/src/components/CnDataTable/CnColumnFilterPopover.vue +11 -5
  112. package/src/components/CnDataTable/CnDataTable.vue +45 -1
  113. package/src/components/CnDetailPage/CnDetailPage.md +8 -0
  114. package/src/components/CnDetailPage/CnDetailPage.vue +263 -7
  115. package/src/components/CnFkResolveCell/CnFkResolveCell.vue +3 -1
  116. package/src/components/CnFormDialog/CnFormDialog.vue +144 -4
  117. package/src/components/CnHeaderWidget/CnHeaderWidget.vue +206 -9
  118. package/src/components/CnIndexPage/CnIndexPage.vue +32 -2
  119. package/src/components/CnObjectListWidget/CnObjectListWidget.vue +7 -1
  120. package/src/components/CnSegmentedControl/CnSegmentedControl.md +1 -1
  121. package/src/components/CnSegmentedControl/CnSegmentedControl.vue +12 -0
  122. package/src/components/CnStagesWidget/CnStagesWidget.vue +189 -2
  123. package/src/components/CnStagesWidget/stagesModel.js +5 -2
  124. package/src/components/CnStatWidget/CnStatWidget.vue +89 -7
  125. package/src/components/CnTabsWidget/CnTabsWidget.vue +15 -2
  126. package/src/components/CnWidgetWrapper/CnWidgetWrapper.md +4 -0
  127. package/src/components/CnWidgetWrapper/CnWidgetWrapper.vue +107 -1
  128. package/src/css/detail-page.css +37 -4
  129. package/src/css/kpi-card.css +71 -1
  130. package/src/css/table.css +18 -6
  131. package/src/mixins/pageViews.js +396 -0
  132. package/src/schemas/app-manifest-v2.schema.json +162 -3
  133. package/src/store/useObjectStore.js +118 -33
  134. package/src/utils/actionsDispatcher.js +25 -2
  135. package/src/utils/columnFilters.js +29 -2
  136. package/src/utils/schema.js +40 -2
  137. package/src/utils/schemaRefSlug.js +19 -3
  138. package/src/utils/validateManifestV2.compiled.js +2 -2
@@ -1,72 +1,84 @@
1
- import { resolveComponent, openBlock, createElementBlock, createElementVNode, toDisplayString, createCommentVNode, renderSlot, createBlock, withCtx, createTextVNode, createVNode, createSlots, normalizeClass, Fragment, renderList, mergeProps, resolveDynamicComponent, normalizeProps } from 'vue';
1
+ import { resolveComponent, openBlock, createElementBlock, toDisplayString, createCommentVNode, createElementVNode, renderSlot, createBlock, withCtx, createTextVNode, createVNode, createSlots, normalizeClass, Fragment, renderList, mergeProps, resolveDynamicComponent } from 'vue';
2
2
 
3
3
  const _hoisted_1 = {
4
4
  class: "cn-dashboard-page",
5
5
  "data-testid": "cn-dashboard-page"
6
6
  };
7
7
  const _hoisted_2 = {
8
+ key: 0,
9
+ class: "hidden-visually",
10
+ "data-testid": "cn-dashboard-page-hidden-title"
11
+ };
12
+ const _hoisted_3 = {
13
+ key: 1,
8
14
  class: "cn-dashboard-page__header",
9
15
  "data-testid": "cn-dashboard-page-header"
10
16
  };
11
- const _hoisted_3 = { class: "cn-dashboard-page__header-left" };
12
- const _hoisted_4 = {
17
+ const _hoisted_4 = { class: "cn-dashboard-page__header-left" };
18
+ const _hoisted_5 = {
13
19
  key: 0,
14
20
  class: "cn-dashboard-page__title-row"
15
21
  };
16
- const _hoisted_5 = {
22
+ const _hoisted_6 = {
17
23
  key: 0,
18
24
  class: "cn-dashboard-page__title"
19
25
  };
20
- const _hoisted_6 = {
26
+ const _hoisted_7 = {
21
27
  key: 1,
22
28
  class: "cn-dashboard-page__description"
23
29
  };
24
- const _hoisted_7 = { class: "cn-dashboard-page__header-actions" };
25
- const _hoisted_8 = ["aria-label"];
26
- const _hoisted_9 = ["aria-pressed", "data-testid", "onClick"];
27
- const _hoisted_10 = {
28
- key: 1,
30
+ const _hoisted_8 = { class: "cn-dashboard-page__header-actions" };
31
+ const _hoisted_9 = ["aria-label"];
32
+ const _hoisted_10 = ["aria-pressed", "data-testid", "onClick"];
33
+ const _hoisted_11 = {
34
+ key: 3,
29
35
  class: "cn-dashboard-page__page-filters",
30
36
  "data-testid": "cn-dashboard-page-page-filters"
31
37
  };
32
- const _hoisted_11 = {
38
+ const _hoisted_12 = {
33
39
  key: 0,
34
40
  class: "cn-dashboard-page__page-filter-label"
35
41
  };
36
- const _hoisted_12 = {
37
- key: 5,
42
+ const _hoisted_13 = {
43
+ key: 7,
38
44
  class: "cn-dashboard-page__empty"
39
45
  };
40
- const _hoisted_13 = {
41
- key: 6,
46
+ const _hoisted_14 = {
47
+ key: 8,
42
48
  class: "cn-dashboard-page__content"
43
49
  };
44
- const _hoisted_14 = {
50
+ const _hoisted_15 = {
51
+ key: 9,
52
+ class: "cn-dashboard-page__view-switch"
53
+ };
54
+ const _hoisted_16 = {
45
55
  key: 0,
46
56
  class: "cn-dashboard-page__widget-edit"
47
57
  };
48
- const _hoisted_15 = ["title"];
49
- const _hoisted_16 = {
58
+ const _hoisted_17 = ["title"];
59
+ const _hoisted_18 = {
50
60
  key: 1,
51
61
  class: "cn-dashboard-page__date-chip-preset-spacer"
52
62
  };
53
- const _hoisted_17 = ["title"];
54
- const _hoisted_18 = {
63
+ const _hoisted_19 = ["title"];
64
+ const _hoisted_20 = {
55
65
  key: 1,
56
66
  class: "cn-dashboard-page__date-chip-preset-spacer"
57
67
  };
58
- const _hoisted_19 = {
68
+ const _hoisted_21 = {
59
69
  key: 2,
60
70
  class: "cn-dashboard-page__unknown"
61
71
  };
62
- const _hoisted_20 = ["title"];
63
- const _hoisted_21 = {
72
+ const _hoisted_22 = ["title"];
73
+ const _hoisted_23 = {
64
74
  key: 1,
65
75
  class: "cn-dashboard-page__date-chip-preset-spacer"
66
76
  };
67
- const _hoisted_22 = { class: "cn-dashboard-page__unknown" };
77
+ const _hoisted_24 = { class: "cn-dashboard-page__unknown" };
78
+ const _hoisted_25 = ["id", "aria-label"];
68
79
 
69
80
  function render(_ctx, _cache, $props, $setup, $data, $options) {
81
+ const _component_CnSegmentedControl = resolveComponent("CnSegmentedControl");
70
82
  const _component_CnActionButtons = resolveComponent("CnActionButtons");
71
83
  const _component_Pencil = resolveComponent("Pencil");
72
84
  const _component_Check = resolveComponent("Check");
@@ -97,90 +109,107 @@ function render(_ctx, _cache, $props, $setup, $data, $options) {
97
109
  const _component_CnWidgetStyleEditorModal = resolveComponent("CnWidgetStyleEditorModal");
98
110
 
99
111
  return (openBlock(), createElementBlock("div", _hoisted_1, [
100
- createElementVNode("div", _hoisted_2, [
101
- createElementVNode("div", _hoisted_3, [
102
- ($props.title || _ctx.$slots['title-meta'])
103
- ? (openBlock(), createElementBlock("div", _hoisted_4, [
104
- ($props.title)
105
- ? (openBlock(), createElementBlock("h2", _hoisted_5, toDisplayString($options.resolvedTitle), 1 /* TEXT */))
106
- : createCommentVNode("v-if", true),
107
- renderSlot(_ctx.$slots, "title-meta")
108
- ]))
109
- : createCommentVNode("v-if", true),
110
- ($props.description)
111
- ? (openBlock(), createElementBlock("p", _hoisted_6, toDisplayString($options.resolvedDescription), 1 /* TEXT */))
112
- : createCommentVNode("v-if", true)
113
- ]),
114
- createElementVNode("div", _hoisted_7, [
115
- ($props.headerActions && $props.headerActions.length)
116
- ? (openBlock(), createBlock(_component_CnActionButtons, {
117
- key: 0,
118
- actions: $props.headerActions,
119
- "data-testid": "cn-dashboard-page-header-actions"
120
- }, null, 8 /* PROPS */, ["actions"]))
121
- : createCommentVNode("v-if", true),
122
- renderSlot(_ctx.$slots, "header-actions"),
123
- renderSlot(_ctx.$slots, "actions"),
124
- ($props.allowEdit)
125
- ? (openBlock(), createBlock(_component_NcButton, {
126
- key: 1,
127
- variant: $data.isEditing ? 'primary' : 'secondary',
128
- onClick: $options.toggleEdit
129
- }, {
130
- icon: withCtx(() => [
131
- (!$data.isEditing)
132
- ? (openBlock(), createBlock(_component_Pencil, {
133
- key: 0,
134
- size: 20
135
- }))
136
- : (openBlock(), createBlock(_component_Check, {
137
- key: 1,
138
- size: 20
139
- }))
140
- ]),
141
- default: withCtx(() => [
142
- createTextVNode(" " + toDisplayString($data.isEditing ? $props.doneLabel : $props.editLabel), 1 /* TEXT */)
143
- ]),
144
- _: 1 /* STABLE */
145
- }, 8 /* PROPS */, ["variant", "onClick"]))
146
- : createCommentVNode("v-if", true),
147
- createVNode(_component_CnBuildiqEditButton),
148
- createVNode(_component_CnActionsMenu, {
149
- showRefresh: $props.showRefresh,
150
- showRequestFeature: $props.showRequestFeature,
151
- showReportBug: $props.showReportBug,
152
- showDocumentation: $props.showDocumentation,
153
- documentationUrl: $props.documentationUrl,
154
- docsAnchor: $options.resolvedPageId,
155
- documentationLabel: $props.documentationLabel,
156
- refreshLabel: $props.refreshLabel,
157
- requestFeatureLabel: $props.requestFeatureLabel,
158
- actionsMenuLabel: $props.actionsMenuLabel,
159
- refreshing: $props.refreshing,
160
- widgetId: $options.resolvedPageId,
161
- title: $props.title,
162
- surface: `dashboard:${$options.resolvedPageId}`,
163
- specRef: $props.specRef,
164
- refreshChannel: "cn:page:refresh",
165
- testidBase: "cn-dashboard-page",
166
- onRefresh: $options.onActionsRefresh,
167
- onRequestFeature: $options.onActionsRequestFeature
168
- }, createSlots({ _: 2 /* DYNAMIC */ }, [
169
- ($options.hasActionItemsSlot)
170
- ? {
171
- name: "action-items",
172
- fn: withCtx(() => [
173
- renderSlot(_ctx.$slots, "action-items")
174
- ]),
175
- key: "0"
176
- }
177
- : undefined
178
- ]), 1032 /* PROPS, DYNAMIC_SLOTS */, ["showRefresh", "showRequestFeature", "showReportBug", "showDocumentation", "documentationUrl", "docsAnchor", "documentationLabel", "refreshLabel", "requestFeatureLabel", "actionsMenuLabel", "refreshing", "widgetId", "title", "surface", "specRef", "onRefresh", "onRequestFeature"])
179
- ])
180
- ]),
112
+ (!$props.showHeader && $props.title)
113
+ ? (openBlock(), createElementBlock("h2", _hoisted_2, toDisplayString($options.resolvedTitle), 1 /* TEXT */))
114
+ : createCommentVNode("v-if", true),
115
+ ($props.showHeader)
116
+ ? (openBlock(), createElementBlock("div", _hoisted_3, [
117
+ createElementVNode("div", _hoisted_4, [
118
+ ($props.title || _ctx.$slots['title-meta'])
119
+ ? (openBlock(), createElementBlock("div", _hoisted_5, [
120
+ ($props.title)
121
+ ? (openBlock(), createElementBlock("h2", _hoisted_6, toDisplayString($options.resolvedTitle), 1 /* TEXT */))
122
+ : createCommentVNode("v-if", true),
123
+ renderSlot(_ctx.$slots, "title-meta")
124
+ ]))
125
+ : createCommentVNode("v-if", true),
126
+ ($props.description)
127
+ ? (openBlock(), createElementBlock("p", _hoisted_7, toDisplayString($options.resolvedDescription), 1 /* TEXT */))
128
+ : createCommentVNode("v-if", true)
129
+ ]),
130
+ createElementVNode("div", _hoisted_8, [
131
+ (_ctx.showsPageViewSwitch)
132
+ ? (openBlock(), createBlock(_component_CnSegmentedControl, {
133
+ key: 0,
134
+ class: "cn-page-view-switch",
135
+ options: _ctx.viewSwitchOptions,
136
+ modelValue: _ctx.activeViewId,
137
+ ariaLabel: _ctx.viewSwitchLabel,
138
+ controls: _ctx.viewRegionId,
139
+ "data-testid": "cn-dashboard-page-view-switch",
140
+ "onUpdate:modelValue": _ctx.selectView
141
+ }, null, 8 /* PROPS */, ["options", "modelValue", "ariaLabel", "controls", "onUpdate:modelValue"]))
142
+ : createCommentVNode("v-if", true),
143
+ ($props.headerActions && $props.headerActions.length)
144
+ ? (openBlock(), createBlock(_component_CnActionButtons, {
145
+ key: 1,
146
+ actions: $props.headerActions,
147
+ "data-testid": "cn-dashboard-page-header-actions"
148
+ }, null, 8 /* PROPS */, ["actions"]))
149
+ : createCommentVNode("v-if", true),
150
+ renderSlot(_ctx.$slots, "header-actions"),
151
+ renderSlot(_ctx.$slots, "actions"),
152
+ ($props.allowEdit)
153
+ ? (openBlock(), createBlock(_component_NcButton, {
154
+ key: 2,
155
+ variant: $data.isEditing ? 'primary' : 'secondary',
156
+ onClick: $options.toggleEdit
157
+ }, {
158
+ icon: withCtx(() => [
159
+ (!$data.isEditing)
160
+ ? (openBlock(), createBlock(_component_Pencil, {
161
+ key: 0,
162
+ size: 20
163
+ }))
164
+ : (openBlock(), createBlock(_component_Check, {
165
+ key: 1,
166
+ size: 20
167
+ }))
168
+ ]),
169
+ default: withCtx(() => [
170
+ createTextVNode(" " + toDisplayString($data.isEditing ? $props.doneLabel : $props.editLabel), 1 /* TEXT */)
171
+ ]),
172
+ _: 1 /* STABLE */
173
+ }, 8 /* PROPS */, ["variant", "onClick"]))
174
+ : createCommentVNode("v-if", true),
175
+ createVNode(_component_CnBuildiqEditButton),
176
+ createVNode(_component_CnActionsMenu, {
177
+ showRefresh: $props.showRefresh,
178
+ showRequestFeature: $props.showRequestFeature,
179
+ showReportBug: $props.showReportBug,
180
+ showDocumentation: $props.showDocumentation,
181
+ documentationUrl: $props.documentationUrl,
182
+ docsAnchor: $options.resolvedPageId,
183
+ documentationLabel: $props.documentationLabel,
184
+ refreshLabel: $props.refreshLabel,
185
+ requestFeatureLabel: $props.requestFeatureLabel,
186
+ actionsMenuLabel: $props.actionsMenuLabel,
187
+ refreshing: $props.refreshing,
188
+ widgetId: $options.resolvedPageId,
189
+ title: $props.title,
190
+ surface: `dashboard:${$options.resolvedPageId}`,
191
+ specRef: $props.specRef,
192
+ refreshChannel: "cn:page:refresh",
193
+ testidBase: "cn-dashboard-page",
194
+ onRefresh: $options.onActionsRefresh,
195
+ onRequestFeature: $options.onActionsRequestFeature
196
+ }, createSlots({ _: 2 /* DYNAMIC */ }, [
197
+ ($options.hasActionItemsSlot)
198
+ ? {
199
+ name: "action-items",
200
+ fn: withCtx(() => [
201
+ renderSlot(_ctx.$slots, "action-items")
202
+ ]),
203
+ key: "0"
204
+ }
205
+ : undefined
206
+ ]), 1032 /* PROPS, DYNAMIC_SLOTS */, ["showRefresh", "showRequestFeature", "showReportBug", "showDocumentation", "documentationUrl", "docsAnchor", "documentationLabel", "refreshLabel", "requestFeatureLabel", "actionsMenuLabel", "refreshing", "widgetId", "title", "surface", "specRef", "onRefresh", "onRequestFeature"])
207
+ ])
208
+ ]))
209
+ : createCommentVNode("v-if", true),
181
210
  ($options.showHeaderDateRange)
182
211
  ? (openBlock(), createElementBlock("div", {
183
- key: 0,
212
+ key: 2,
184
213
  class: normalizeClass(["cn-dashboard-page__date-range", { 'cn-dashboard-page__date-range--pills': $options.dateRangeControl === 'pills' }]),
185
214
  "data-testid": "cn-dashboard-page-date-range"
186
215
  }, [
@@ -200,7 +229,7 @@ function render(_ctx, _cache, $props, $setup, $data, $options) {
200
229
  "aria-pressed": String(Boolean($data.currentRange && $data.currentRange.preset === preset.id)),
201
230
  "data-testid": `cn-dashboard-page-date-pill-${preset.id}`,
202
231
  onClick: $event => ($options.onPillPick(preset))
203
- }, toDisplayString(preset.label), 11 /* TEXT, CLASS, PROPS */, _hoisted_9))
232
+ }, toDisplayString(preset.label), 11 /* TEXT, CLASS, PROPS */, _hoisted_10))
204
233
  }), 128 /* KEYED_FRAGMENT */)),
205
234
  ($options.hasCustomPreset)
206
235
  ? (openBlock(), createBlock(_component_NcActions, {
@@ -234,7 +263,7 @@ function render(_ctx, _cache, $props, $setup, $data, $options) {
234
263
  _: 1 /* STABLE */
235
264
  }))
236
265
  : createCommentVNode("v-if", true)
237
- ], 8 /* PROPS */, _hoisted_8))
266
+ ], 8 /* PROPS */, _hoisted_9))
238
267
  : (openBlock(), createBlock(_component_CnDateRangePicker, {
239
268
  key: 1,
240
269
  value: $data.currentRange,
@@ -244,14 +273,14 @@ function render(_ctx, _cache, $props, $setup, $data, $options) {
244
273
  ], 2 /* CLASS */))
245
274
  : createCommentVNode("v-if", true),
246
275
  ($props.pageFilters && $props.pageFilters.length)
247
- ? (openBlock(), createElementBlock("div", _hoisted_10, [
276
+ ? (openBlock(), createElementBlock("div", _hoisted_11, [
248
277
  (openBlock(true), createElementBlock(Fragment, null, renderList($props.pageFilters, (pf) => {
249
278
  return (openBlock(), createElementBlock("label", {
250
279
  key: pf.key,
251
280
  class: "cn-dashboard-page__page-filter"
252
281
  }, [
253
282
  (pf.label)
254
- ? (openBlock(), createElementBlock("span", _hoisted_11, toDisplayString(pf.label), 1 /* TEXT */))
283
+ ? (openBlock(), createElementBlock("span", _hoisted_12, toDisplayString(pf.label), 1 /* TEXT */))
255
284
  : createCommentVNode("v-if", true),
256
285
  createVNode(_component_NcSelect, {
257
286
  modelValue: $options.selectedPageFilterOption(pf),
@@ -268,7 +297,7 @@ function render(_ctx, _cache, $props, $setup, $data, $options) {
268
297
  : createCommentVNode("v-if", true),
269
298
  ($options.hasBodyWidgets)
270
299
  ? (openBlock(), createBlock(_component_CnBodySections, {
271
- key: 2,
300
+ key: 4,
272
301
  sections: $props.bodyWidgets,
273
302
  context: $options.sectionContext,
274
303
  placement: "before-grid",
@@ -276,11 +305,11 @@ function render(_ctx, _cache, $props, $setup, $data, $options) {
276
305
  }, null, 8 /* PROPS */, ["sections", "context"]))
277
306
  : createCommentVNode("v-if", true),
278
307
  ($props.loading)
279
- ? (openBlock(), createBlock(_component_NcLoadingIcon, { key: 3 }))
308
+ ? (openBlock(), createBlock(_component_NcLoadingIcon, { key: 5 }))
280
309
  : (!$data.widgetConditionsSettled && !$options.gridEditable)
281
- ? (openBlock(), createBlock(_component_NcLoadingIcon, { key: 4 }))
282
- : (!$options.hasWidgets && !$options.hasBodyWidgets)
283
- ? (openBlock(), createElementBlock("div", _hoisted_12, [
310
+ ? (openBlock(), createBlock(_component_NcLoadingIcon, { key: 6 }))
311
+ : (!$options.hasWidgets && !$options.hasBodyWidgets && !_ctx.hasViews)
312
+ ? (openBlock(), createElementBlock("div", _hoisted_13, [
284
313
  renderSlot(_ctx.$slots, "empty", {}, () => [
285
314
  createVNode(_component_NcEmptyContent, { description: $props.emptyLabel }, {
286
315
  icon: withCtx(() => [
@@ -291,7 +320,7 @@ function render(_ctx, _cache, $props, $setup, $data, $options) {
291
320
  ])
292
321
  ]))
293
322
  : ($options.widgetRefItems.length > 0)
294
- ? (openBlock(), createElementBlock("div", _hoisted_13, [
323
+ ? (openBlock(), createElementBlock("div", _hoisted_14, [
295
324
  (openBlock(true), createElementBlock(Fragment, null, renderList($options.widgetRefItems, (item, idx) => {
296
325
  return (openBlock(), createBlock(_component_CnWidgetRefItem, {
297
326
  key: item.ref + '-' + idx,
@@ -300,216 +329,420 @@ function render(_ctx, _cache, $props, $setup, $data, $options) {
300
329
  }, null, 8 /* PROPS */, ["refUri"]))
301
330
  }), 128 /* KEYED_FRAGMENT */))
302
331
  ]))
303
- : (openBlock(), createBlock(_component_CnDashboardGrid, {
304
- key: `cn-dashboard-grid-${$options.gridEditable ? 'editing' : 'live'}`,
305
- layout: $options.displayLayout,
306
- editable: $options.gridEditable,
307
- columns: $props.columns,
308
- cellHeight: $props.cellHeight,
309
- margin: $props.gridMargin,
310
- onLayoutChange: $options.onLayoutChange
332
+ : createCommentVNode("v-if", true),
333
+ ($options.gridSectionsShown && !$props.showHeader && _ctx.showsPageViewSwitch)
334
+ ? (openBlock(), createElementBlock("div", _hoisted_15, [
335
+ createVNode(_component_CnSegmentedControl, {
336
+ class: "cn-page-view-switch",
337
+ options: _ctx.viewSwitchOptions,
338
+ modelValue: _ctx.activeViewId,
339
+ ariaLabel: _ctx.viewSwitchLabel,
340
+ controls: _ctx.viewRegionId,
341
+ "data-testid": "cn-dashboard-page-view-switch",
342
+ "onUpdate:modelValue": _ctx.selectView
343
+ }, null, 8 /* PROPS */, ["options", "modelValue", "ariaLabel", "controls", "onUpdate:modelValue"])
344
+ ]))
345
+ : createCommentVNode("v-if", true),
346
+ (openBlock(true), createElementBlock(Fragment, null, renderList($options.gridSections, (section) => {
347
+ return (openBlock(), createBlock(_component_CnDashboardGrid, mergeProps({
348
+ key: `cn-dashboard-grid-${section.key}-${$options.gridEditable ? 'editing' : 'live'}`
349
+ }, { ref_for: true }, section.attrs, {
350
+ layout: section.layout,
351
+ editable: section.editable,
352
+ columns: $props.columns,
353
+ cellHeight: $props.cellHeight,
354
+ margin: $props.gridMargin,
355
+ onLayoutChange: $event => (section.view ? _ctx.onViewLayoutChange($event) : $options.onLayoutChange($event))
356
+ }), {
357
+ widget: withCtx(({ item }) => [
358
+ ($options.gridEditable)
359
+ ? (openBlock(), createElementBlock("div", _hoisted_16, [
360
+ createVNode(_component_NcButton, {
361
+ variant: "tertiary",
362
+ "aria-label": _ctx.t('nextcloud-vue', 'Configure widget'),
363
+ onClick: $event => ($options.configureWidget(item))
364
+ }, {
365
+ icon: withCtx(() => [
366
+ createVNode(_component_Cog, { size: 18 })
367
+ ]),
368
+ _: 1 /* STABLE */
369
+ }, 8 /* PROPS */, ["aria-label", "onClick"])
370
+ ]))
371
+ : createCommentVNode("v-if", true),
372
+ ($options.missingRequiredApp(item))
373
+ ? (openBlock(), createBlock(_component_CnWidgetWrapper, {
374
+ key: 1,
375
+ title: $options.getWidgetTitle(item),
376
+ showTitle: $options.widgetShowTitle(item)
311
377
  }, {
312
- widget: withCtx(({ item }) => [
313
- ($options.gridEditable)
314
- ? (openBlock(), createElementBlock("div", _hoisted_14, [
315
- createVNode(_component_NcButton, {
316
- variant: "tertiary",
317
- "aria-label": _ctx.t('nextcloud-vue', 'Configure widget'),
318
- onClick: $event => ($options.configureWidget(item))
319
- }, {
320
- icon: withCtx(() => [
321
- createVNode(_component_Cog, { size: 18 })
322
- ]),
323
- _: 1 /* STABLE */
324
- }, 8 /* PROPS */, ["aria-label", "onClick"])
325
- ]))
326
- : createCommentVNode("v-if", true),
327
- ($options.missingRequiredApp(item))
328
- ? (openBlock(), createBlock(_component_CnWidgetWrapper, {
329
- key: 1,
330
- title: $options.getWidgetTitle(item),
331
- showTitle: $options.widgetShowTitle(item)
378
+ default: withCtx(() => [
379
+ createVNode(_component_NcEmptyContent, {
380
+ name: $options.installAppLabel($options.missingRequiredApp(item)),
381
+ description: _ctx.t('nextcloud-vue', 'This widget shows data from another app that isn\'t installed yet.'),
382
+ class: "cn-dashboard-page__requires-app cn-requires-app"
383
+ }, {
384
+ icon: withCtx(() => [
385
+ createVNode(_component_Download, { size: 24 })
386
+ ]),
387
+ action: withCtx(() => [
388
+ createVNode(_component_NcButton, {
389
+ variant: "primary",
390
+ href: $options.appInstallUrl($options.missingRequiredApp(item))
332
391
  }, {
392
+ icon: withCtx(() => [
393
+ createVNode(_component_Download, { size: 18 })
394
+ ]),
333
395
  default: withCtx(() => [
334
- createVNode(_component_NcEmptyContent, {
335
- name: $options.installAppLabel($options.missingRequiredApp(item)),
336
- description: _ctx.t('nextcloud-vue', 'This widget shows data from another app that isn\'t installed yet.'),
337
- class: "cn-dashboard-page__requires-app cn-requires-app"
338
- }, {
339
- icon: withCtx(() => [
340
- createVNode(_component_Download, { size: 24 })
341
- ]),
342
- action: withCtx(() => [
343
- createVNode(_component_NcButton, {
344
- variant: "primary",
345
- href: $options.appInstallUrl($options.missingRequiredApp(item))
396
+ createTextVNode(" " + toDisplayString($options.installAppLabel($options.missingRequiredApp(item))), 1 /* TEXT */)
397
+ ]),
398
+ _: 2 /* DYNAMIC */
399
+ }, 1032 /* PROPS, DYNAMIC_SLOTS */, ["href"])
400
+ ]),
401
+ _: 2 /* DYNAMIC */
402
+ }, 1032 /* PROPS, DYNAMIC_SLOTS */, ["name", "description"])
403
+ ]),
404
+ _: 2 /* DYNAMIC */
405
+ }, 1032 /* PROPS, DYNAMIC_SLOTS */, ["title", "showTitle"]))
406
+ : ($options.isTile(item))
407
+ ? (openBlock(), createBlock(_component_CnTileWidget, {
408
+ key: 2,
409
+ tile: $options.getTileConfig(item)
410
+ }, null, 8 /* PROPS */, ["tile"]))
411
+ : ($options.hasWidgetSlot(item.widgetId))
412
+ ? (openBlock(), createBlock(_component_CnWidgetWrapper, {
413
+ key: 3,
414
+ widgetId: item.widgetId,
415
+ title: $options.getWidgetTitle(item),
416
+ iconUrl: $options.getWidgetIconUrl(item),
417
+ iconClass: $options.getWidgetIconClass(item),
418
+ showTitle: $options.widgetShowTitle(item),
419
+ borderless: $options.widgetBorderless(item),
420
+ flush: item.flush !== false,
421
+ buttons: $options.getWidgetButtons(item),
422
+ headerLink: $options.getWidgetHeaderLink(item),
423
+ styleConfig: item.styleConfig || {},
424
+ titleIconPosition: $options.getWidgetTitleIconPosition(item),
425
+ titleIconColor: $options.getWidgetTitleIconColor(item),
426
+ titleIconVariant: $options.getWidgetTitleIconVariant(item),
427
+ showRefresh: $options.getWidgetShowRefresh(item),
428
+ showActions: $options.widgetShowActions(item),
429
+ documentationUrl: $options.getWidgetDocumentationUrl(item),
430
+ docsAnchor: $options.getWidgetDocsAnchor(item),
431
+ onRefresh: $event => ($options.onWidgetRefresh(item)),
432
+ onRequestFeature: $event => ($options.onWidgetRequestFeature(item))
433
+ }, createSlots({
434
+ default: withCtx(() => [
435
+ renderSlot(_ctx.$slots, 'widget-' + item.widgetId, {
436
+ item: item,
437
+ widget: $options.getWidgetDef(item.widgetId)
438
+ })
439
+ ]),
440
+ _: 2 /* DYNAMIC */
441
+ }, [
442
+ (_ctx.$slots['widget-' + item.widgetId + '-title-icon'])
443
+ ? {
444
+ name: "title-icon",
445
+ fn: withCtx(() => [
446
+ renderSlot(_ctx.$slots, 'widget-' + item.widgetId + '-title-icon', {
447
+ item: item,
448
+ widget: $options.getWidgetDef(item.widgetId)
449
+ })
450
+ ]),
451
+ key: "0"
452
+ }
453
+ : undefined,
454
+ (_ctx.$slots['widget-' + item.widgetId + '-actions'])
455
+ ? {
456
+ name: "actions",
457
+ fn: withCtx(() => [
458
+ renderSlot(_ctx.$slots, 'widget-' + item.widgetId + '-actions', {
459
+ item: item,
460
+ widget: $options.getWidgetDef(item.widgetId)
461
+ })
462
+ ]),
463
+ key: "1"
464
+ }
465
+ : undefined,
466
+ ($options.dateRangeEnabled && item.dateChip === true)
467
+ ? {
468
+ name: "title-meta",
469
+ fn: withCtx(() => [
470
+ createVNode(_component_NcActions, {
471
+ open: $data.openChipPicker[item.widgetId],
472
+ "onUpdate:open": $event => (($data.openChipPicker[item.widgetId]) = $event),
473
+ forceMenu: true,
474
+ container: "body",
475
+ "data-testid": `cn-dashboard-page-date-chip-${item.widgetId}`,
476
+ class: "cn-dashboard-page__date-chip-trigger"
477
+ }, {
478
+ icon: withCtx(() => [
479
+ createElementVNode("span", {
480
+ class: "cn-dashboard-page__date-chip",
481
+ title: $data.dateChipTitle
482
+ }, toDisplayString($options.dashboardRangeChipLabel), 9 /* TEXT, PROPS */, _hoisted_17)
483
+ ]),
484
+ default: withCtx(() => [
485
+ (openBlock(true), createElementBlock(Fragment, null, renderList($options.effectivePresets, (preset) => {
486
+ return (openBlock(), createBlock(_component_NcActionButton, {
487
+ key: preset.id,
488
+ closeAfterClick: true,
489
+ onClick: $event => ($options.onChipPresetPick(preset, item))
490
+ }, {
491
+ icon: withCtx(() => [
492
+ ($data.currentRange.preset === preset.id)
493
+ ? (openBlock(), createBlock(_component_CalendarRange, {
494
+ key: 0,
495
+ size: 16
496
+ }))
497
+ : (openBlock(), createElementBlock("span", _hoisted_18))
498
+ ]),
499
+ default: withCtx(() => [
500
+ createTextVNode(" " + toDisplayString(preset.label), 1 /* TEXT */)
501
+ ]),
502
+ _: 2 /* DYNAMIC */
503
+ }, 1032 /* PROPS, DYNAMIC_SLOTS */, ["onClick"]))
504
+ }), 128 /* KEYED_FRAGMENT */)),
505
+ createVNode(_component_NcActionSeparator),
506
+ createVNode(_component_NcActionInput, {
507
+ type: "datetime-local",
508
+ isNativePicker: "",
509
+ modelValue: $options.toPickerDate($data.currentRange.from),
510
+ label: _ctx.t('nextcloud-vue', 'From'),
511
+ "onUpdate:modelValue": _cache[2] || (_cache[2] = $event => ($options.onChipDateInput('from', $event)))
512
+ }, null, 8 /* PROPS */, ["modelValue", "label"]),
513
+ createVNode(_component_NcActionInput, {
514
+ type: "datetime-local",
515
+ isNativePicker: "",
516
+ modelValue: $options.toPickerDate($data.currentRange.to),
517
+ label: _ctx.t('nextcloud-vue', 'To'),
518
+ "onUpdate:modelValue": _cache[3] || (_cache[3] = $event => ($options.onChipDateInput('to', $event)))
519
+ }, null, 8 /* PROPS */, ["modelValue", "label"])
520
+ ]),
521
+ _: 2 /* DYNAMIC */
522
+ }, 1032 /* PROPS, DYNAMIC_SLOTS */, ["open", "onUpdate:open", "data-testid"])
523
+ ]),
524
+ key: "2"
525
+ }
526
+ : undefined
527
+ ]), 1032 /* PROPS, DYNAMIC_SLOTS */, ["widgetId", "title", "iconUrl", "iconClass", "showTitle", "borderless", "flush", "buttons", "headerLink", "styleConfig", "titleIconPosition", "titleIconColor", "titleIconVariant", "showRefresh", "showActions", "documentationUrl", "docsAnchor", "onRefresh", "onRequestFeature"]))
528
+ : ($options.isChart(item))
529
+ ? (openBlock(), createBlock(_component_CnWidgetWrapper, {
530
+ key: 4,
531
+ widgetId: item.widgetId,
532
+ class: normalizeClass({ 'cn-dashboard-page__chart-fit': $options.isChartFitted(item) }),
533
+ title: $options.getWidgetTitle(item),
534
+ iconUrl: $options.getWidgetIconUrl(item),
535
+ iconClass: $options.getWidgetIconClass(item),
536
+ showTitle: $options.widgetShowTitle(item),
537
+ showActions: $options.widgetShowActions(item),
538
+ borderless: $options.widgetBorderless(item),
539
+ flush: item.flush !== false,
540
+ buttons: $options.getWidgetButtons(item),
541
+ headerLink: $options.getWidgetHeaderLink(item),
542
+ styleConfig: item.styleConfig || {},
543
+ titleIconPosition: $options.getWidgetTitleIconPosition(item),
544
+ titleIconColor: $options.getWidgetTitleIconColor(item),
545
+ titleIconVariant: $options.getWidgetTitleIconVariant(item),
546
+ showRefresh: $options.getWidgetShowRefresh(item),
547
+ documentationUrl: $options.getWidgetDocumentationUrl(item),
548
+ docsAnchor: $options.getWidgetDocsAnchor(item),
549
+ onRefresh: $event => ($options.onWidgetRefresh(item)),
550
+ onRequestFeature: $event => ($options.onWidgetRequestFeature(item))
551
+ }, createSlots({
552
+ default: withCtx(() => [
553
+ createVNode(_component_CnChartWidget, mergeProps({ ref_for: true }, $options.getChartProps(item), {
554
+ widgetId: item.widgetId,
555
+ "data-source": $options.getWidgetDataSource(item)
556
+ }), null, 16 /* FULL_PROPS */, ["widgetId", "data-source"])
557
+ ]),
558
+ _: 2 /* DYNAMIC */
559
+ }, [
560
+ ($options.dateRangeEnabled && (item.dateChip === true || $options.formatChartDateRange(item)))
561
+ ? {
562
+ name: "title-meta",
563
+ fn: withCtx(() => [
564
+ createVNode(_component_NcActions, {
565
+ open: $data.openChipPicker[item.widgetId],
566
+ "onUpdate:open": $event => (($data.openChipPicker[item.widgetId]) = $event),
567
+ forceMenu: true,
568
+ container: "body",
569
+ "data-testid": `cn-dashboard-page-date-chip-${item.widgetId}`,
570
+ class: "cn-dashboard-page__date-chip-trigger"
346
571
  }, {
347
572
  icon: withCtx(() => [
348
- createVNode(_component_Download, { size: 18 })
573
+ createElementVNode("span", {
574
+ class: "cn-dashboard-page__date-chip",
575
+ title: $data.dateChipTitle
576
+ }, toDisplayString($options.formatChartDateRange(item) || $options.dashboardRangeChipLabel), 9 /* TEXT, PROPS */, _hoisted_19)
349
577
  ]),
350
578
  default: withCtx(() => [
351
- createTextVNode(" " + toDisplayString($options.installAppLabel($options.missingRequiredApp(item))), 1 /* TEXT */)
579
+ (openBlock(true), createElementBlock(Fragment, null, renderList($options.effectivePresets, (preset) => {
580
+ return (openBlock(), createBlock(_component_NcActionButton, {
581
+ key: preset.id,
582
+ closeAfterClick: true,
583
+ onClick: $event => ($options.onChipPresetPick(preset, item))
584
+ }, {
585
+ icon: withCtx(() => [
586
+ ($data.currentRange.preset === preset.id)
587
+ ? (openBlock(), createBlock(_component_CalendarRange, {
588
+ key: 0,
589
+ size: 16
590
+ }))
591
+ : (openBlock(), createElementBlock("span", _hoisted_20))
592
+ ]),
593
+ default: withCtx(() => [
594
+ createTextVNode(" " + toDisplayString(preset.label), 1 /* TEXT */)
595
+ ]),
596
+ _: 2 /* DYNAMIC */
597
+ }, 1032 /* PROPS, DYNAMIC_SLOTS */, ["onClick"]))
598
+ }), 128 /* KEYED_FRAGMENT */)),
599
+ createVNode(_component_NcActionSeparator),
600
+ createVNode(_component_NcActionInput, {
601
+ type: "datetime-local",
602
+ isNativePicker: "",
603
+ modelValue: $options.toPickerDate($data.currentRange.from),
604
+ label: _ctx.t('nextcloud-vue', 'From'),
605
+ "onUpdate:modelValue": _cache[4] || (_cache[4] = $event => ($options.onChipDateInput('from', $event)))
606
+ }, null, 8 /* PROPS */, ["modelValue", "label"]),
607
+ createVNode(_component_NcActionInput, {
608
+ type: "datetime-local",
609
+ isNativePicker: "",
610
+ modelValue: $options.toPickerDate($data.currentRange.to),
611
+ label: _ctx.t('nextcloud-vue', 'To'),
612
+ "onUpdate:modelValue": _cache[5] || (_cache[5] = $event => ($options.onChipDateInput('to', $event)))
613
+ }, null, 8 /* PROPS */, ["modelValue", "label"])
352
614
  ]),
353
615
  _: 2 /* DYNAMIC */
354
- }, 1032 /* PROPS, DYNAMIC_SLOTS */, ["href"])
616
+ }, 1032 /* PROPS, DYNAMIC_SLOTS */, ["open", "onUpdate:open", "data-testid"])
355
617
  ]),
356
- _: 2 /* DYNAMIC */
357
- }, 1032 /* PROPS, DYNAMIC_SLOTS */, ["name", "description"])
618
+ key: "0"
619
+ }
620
+ : undefined
621
+ ]), 1032 /* PROPS, DYNAMIC_SLOTS */, ["widgetId", "class", "title", "iconUrl", "iconClass", "showTitle", "showActions", "borderless", "flush", "buttons", "headerLink", "styleConfig", "titleIconPosition", "titleIconColor", "titleIconVariant", "showRefresh", "documentationUrl", "docsAnchor", "onRefresh", "onRequestFeature"]))
622
+ : ($options.isStatsBlock(item))
623
+ ? (openBlock(), createBlock(_component_CnWidgetWrapper, {
624
+ key: 5,
625
+ widgetId: item.widgetId,
626
+ title: $options.getWidgetTitle(item),
627
+ iconUrl: $options.getWidgetIconUrl(item),
628
+ iconClass: $options.getWidgetIconClass(item),
629
+ showTitle: $options.widgetShowTitle(item),
630
+ showActions: $options.widgetShowActions(item),
631
+ borderless: $options.widgetBorderless(item),
632
+ flush: item.flush !== false,
633
+ class: normalizeClass({ 'cn-dashboard-page__card-fit': $options.isCardWidget(item) }),
634
+ buttons: $options.getWidgetButtons(item),
635
+ headerLink: $options.getWidgetHeaderLink(item),
636
+ styleConfig: item.styleConfig || {},
637
+ documentationUrl: $options.getWidgetDocumentationUrl(item),
638
+ docsAnchor: $options.getWidgetDocsAnchor(item),
639
+ onRefresh: $event => ($options.onWidgetRefresh(item)),
640
+ onRequestFeature: $event => ($options.onWidgetRequestFeature(item))
641
+ }, {
642
+ default: withCtx(() => [
643
+ createVNode(_component_CnStatsBlockWidget, mergeProps({ ref_for: true }, $options.getStatsBlockProps(item), {
644
+ title: $options.getWidgetTitle(item),
645
+ "data-source": $options.getWidgetDataSource(item)
646
+ }), null, 16 /* FULL_PROPS */, ["title", "data-source"])
358
647
  ]),
359
648
  _: 2 /* DYNAMIC */
360
- }, 1032 /* PROPS, DYNAMIC_SLOTS */, ["title", "showTitle"]))
361
- : ($options.isTile(item))
362
- ? (openBlock(), createBlock(_component_CnTileWidget, {
363
- key: 2,
364
- tile: $options.getTileConfig(item)
365
- }, null, 8 /* PROPS */, ["tile"]))
366
- : ($options.hasWidgetSlot(item.widgetId))
649
+ }, 1032 /* PROPS, DYNAMIC_SLOTS */, ["widgetId", "title", "iconUrl", "iconClass", "showTitle", "showActions", "borderless", "flush", "class", "buttons", "headerLink", "styleConfig", "documentationUrl", "docsAnchor", "onRefresh", "onRequestFeature"]))
650
+ : ($options.isIntegration(item))
651
+ ? (openBlock(), createBlock(_component_CnWidgetWrapper, {
652
+ key: 6,
653
+ widgetId: item.widgetId,
654
+ title: $options.getWidgetTitle(item),
655
+ iconUrl: $options.getWidgetIconUrl(item),
656
+ iconClass: $options.getWidgetIconClass(item),
657
+ showTitle: $options.widgetShowTitle(item),
658
+ showActions: $options.widgetShowActions(item),
659
+ borderless: $options.widgetBorderless(item),
660
+ flush: item.flush !== false,
661
+ buttons: $options.getWidgetButtons(item),
662
+ headerLink: $options.getWidgetHeaderLink(item),
663
+ styleConfig: item.styleConfig || {},
664
+ titleIconPosition: $options.getWidgetTitleIconPosition(item),
665
+ titleIconColor: $options.getWidgetTitleIconColor(item),
666
+ titleIconVariant: $options.getWidgetTitleIconVariant(item),
667
+ showRefresh: $options.getWidgetShowRefresh(item),
668
+ documentationUrl: $options.getWidgetDocumentationUrl(item),
669
+ docsAnchor: $options.getWidgetDocsAnchor(item),
670
+ onRefresh: $event => ($options.onWidgetRefresh(item)),
671
+ onRequestFeature: $event => ($options.onWidgetRequestFeature(item))
672
+ }, {
673
+ default: withCtx(() => [
674
+ ($options.isMountIntegration(item))
675
+ ? (openBlock(), createBlock(_component_CnLeafMountHost, {
676
+ key: 0,
677
+ provider: $options.integrationProviderFor(item),
678
+ mountProps: $options.getIntegrationMountProps(item)
679
+ }, null, 8 /* PROPS */, ["provider", "mountProps"]))
680
+ : ($options.resolveIntegrationWidget(item))
681
+ ? (openBlock(), createBlock(resolveDynamicComponent($options.resolveIntegrationWidget(item)), mergeProps({
682
+ key: 1,
683
+ ref_for: true
684
+ }, $options.getIntegrationProps(item)), null, 16 /* FULL_PROPS */))
685
+ : (openBlock(), createElementBlock("div", _hoisted_21, toDisplayString($props.unavailableLabel), 1 /* TEXT */))
686
+ ]),
687
+ _: 2 /* DYNAMIC */
688
+ }, 1032 /* PROPS, DYNAMIC_SLOTS */, ["widgetId", "title", "iconUrl", "iconClass", "showTitle", "showActions", "borderless", "flush", "buttons", "headerLink", "styleConfig", "titleIconPosition", "titleIconColor", "titleIconVariant", "showRefresh", "documentationUrl", "docsAnchor", "onRefresh", "onRequestFeature"]))
689
+ : ($options.isNcWidget(item))
367
690
  ? (openBlock(), createBlock(_component_CnWidgetWrapper, {
368
- key: 3,
691
+ key: 7,
369
692
  widgetId: item.widgetId,
370
693
  title: $options.getWidgetTitle(item),
371
694
  iconUrl: $options.getWidgetIconUrl(item),
372
695
  iconClass: $options.getWidgetIconClass(item),
373
696
  showTitle: $options.widgetShowTitle(item),
374
- borderless: $options.widgetBorderless(item),
375
- flush: item.flush !== false,
697
+ showActions: $options.widgetShowActions(item),
376
698
  buttons: $options.getWidgetButtons(item),
699
+ headerLink: $options.getWidgetHeaderLink(item),
377
700
  styleConfig: item.styleConfig || {},
378
- titleIconPosition: $options.getWidgetTitleIconPosition(item),
379
- titleIconColor: $options.getWidgetTitleIconColor(item),
380
- titleIconVariant: $options.getWidgetTitleIconVariant(item),
381
701
  showRefresh: $options.getWidgetShowRefresh(item),
382
- showActions: $options.widgetShowActions(item),
383
702
  documentationUrl: $options.getWidgetDocumentationUrl(item),
384
703
  docsAnchor: $options.getWidgetDocsAnchor(item),
385
704
  onRefresh: $event => ($options.onWidgetRefresh(item)),
386
705
  onRequestFeature: $event => ($options.onWidgetRequestFeature(item))
387
- }, createSlots({
706
+ }, {
388
707
  default: withCtx(() => [
389
- renderSlot(_ctx.$slots, 'widget-' + item.widgetId, {
390
- item: item,
391
- widget: $options.getWidgetDef(item.widgetId)
392
- })
708
+ createVNode(_component_CnWidgetRenderer, {
709
+ widget: $options.getWidgetDef(item.widgetId),
710
+ unavailableText: $props.unavailableLabel
711
+ }, null, 8 /* PROPS */, ["widget", "unavailableText"])
393
712
  ]),
394
713
  _: 2 /* DYNAMIC */
395
- }, [
396
- (_ctx.$slots['widget-' + item.widgetId + '-title-icon'])
397
- ? {
398
- name: "title-icon",
399
- fn: withCtx(() => [
400
- renderSlot(_ctx.$slots, 'widget-' + item.widgetId + '-title-icon', {
401
- item: item,
402
- widget: $options.getWidgetDef(item.widgetId)
403
- })
404
- ]),
405
- key: "0"
406
- }
407
- : undefined,
408
- (_ctx.$slots['widget-' + item.widgetId + '-actions'])
409
- ? {
410
- name: "actions",
411
- fn: withCtx(() => [
412
- renderSlot(_ctx.$slots, 'widget-' + item.widgetId + '-actions', {
413
- item: item,
414
- widget: $options.getWidgetDef(item.widgetId)
415
- })
416
- ]),
417
- key: "1"
418
- }
419
- : undefined,
420
- ($options.dateRangeEnabled && item.dateChip === true)
421
- ? {
422
- name: "title-meta",
423
- fn: withCtx(() => [
424
- createVNode(_component_NcActions, {
425
- open: $data.openChipPicker[item.widgetId],
426
- "onUpdate:open": $event => (($data.openChipPicker[item.widgetId]) = $event),
427
- forceMenu: true,
428
- container: "body",
429
- "data-testid": `cn-dashboard-page-date-chip-${item.widgetId}`,
430
- class: "cn-dashboard-page__date-chip-trigger"
431
- }, {
432
- icon: withCtx(() => [
433
- createElementVNode("span", {
434
- class: "cn-dashboard-page__date-chip",
435
- title: $data.dateChipTitle
436
- }, toDisplayString($options.dashboardRangeChipLabel), 9 /* TEXT, PROPS */, _hoisted_15)
437
- ]),
438
- default: withCtx(() => [
439
- (openBlock(true), createElementBlock(Fragment, null, renderList($options.effectivePresets, (preset) => {
440
- return (openBlock(), createBlock(_component_NcActionButton, {
441
- key: preset.id,
442
- closeAfterClick: true,
443
- onClick: $event => ($options.onChipPresetPick(preset, item))
444
- }, {
445
- icon: withCtx(() => [
446
- ($data.currentRange.preset === preset.id)
447
- ? (openBlock(), createBlock(_component_CalendarRange, {
448
- key: 0,
449
- size: 16
450
- }))
451
- : (openBlock(), createElementBlock("span", _hoisted_16))
452
- ]),
453
- default: withCtx(() => [
454
- createTextVNode(" " + toDisplayString(preset.label), 1 /* TEXT */)
455
- ]),
456
- _: 2 /* DYNAMIC */
457
- }, 1032 /* PROPS, DYNAMIC_SLOTS */, ["onClick"]))
458
- }), 128 /* KEYED_FRAGMENT */)),
459
- createVNode(_component_NcActionSeparator),
460
- createVNode(_component_NcActionInput, {
461
- type: "datetime-local",
462
- isNativePicker: "",
463
- modelValue: $options.toPickerDate($data.currentRange.from),
464
- label: _ctx.t('nextcloud-vue', 'From'),
465
- "onUpdate:modelValue": _cache[2] || (_cache[2] = $event => ($options.onChipDateInput('from', $event)))
466
- }, null, 8 /* PROPS */, ["modelValue", "label"]),
467
- createVNode(_component_NcActionInput, {
468
- type: "datetime-local",
469
- isNativePicker: "",
470
- modelValue: $options.toPickerDate($data.currentRange.to),
471
- label: _ctx.t('nextcloud-vue', 'To'),
472
- "onUpdate:modelValue": _cache[3] || (_cache[3] = $event => ($options.onChipDateInput('to', $event)))
473
- }, null, 8 /* PROPS */, ["modelValue", "label"])
474
- ]),
475
- _: 2 /* DYNAMIC */
476
- }, 1032 /* PROPS, DYNAMIC_SLOTS */, ["open", "onUpdate:open", "data-testid"])
477
- ]),
478
- key: "2"
479
- }
480
- : undefined
481
- ]), 1032 /* PROPS, DYNAMIC_SLOTS */, ["widgetId", "title", "iconUrl", "iconClass", "showTitle", "borderless", "flush", "buttons", "styleConfig", "titleIconPosition", "titleIconColor", "titleIconVariant", "showRefresh", "showActions", "documentationUrl", "docsAnchor", "onRefresh", "onRequestFeature"]))
482
- : ($options.isChart(item))
714
+ }, 1032 /* PROPS, DYNAMIC_SLOTS */, ["widgetId", "title", "iconUrl", "iconClass", "showTitle", "showActions", "buttons", "headerLink", "styleConfig", "showRefresh", "documentationUrl", "docsAnchor", "onRefresh", "onRequestFeature"]))
715
+ : ($options.registryRenderer(item))
483
716
  ? (openBlock(), createBlock(_component_CnWidgetWrapper, {
484
- key: 4,
717
+ key: 8,
485
718
  widgetId: item.widgetId,
486
- class: normalizeClass({ 'cn-dashboard-page__chart-fit': $options.isChartFitted(item) }),
487
719
  title: $options.getWidgetTitle(item),
488
- iconUrl: $options.getWidgetIconUrl(item),
489
- iconClass: $options.getWidgetIconClass(item),
490
720
  showTitle: $options.widgetShowTitle(item),
721
+ showActions: $options.widgetShowActions(item),
722
+ showRefresh: $options.getWidgetShowRefresh(item),
491
723
  borderless: $options.widgetBorderless(item),
492
724
  flush: item.flush !== false,
493
- buttons: $options.getWidgetButtons(item),
494
- styleConfig: item.styleConfig || {},
495
725
  titleIconPosition: $options.getWidgetTitleIconPosition(item),
496
726
  titleIconColor: $options.getWidgetTitleIconColor(item),
497
727
  titleIconVariant: $options.getWidgetTitleIconVariant(item),
498
- showRefresh: $options.getWidgetShowRefresh(item),
728
+ class: normalizeClass({ 'cn-dashboard-page__card-fit': $options.isCardWidget(item) }),
729
+ buttons: $options.getWidgetButtons(item),
730
+ headerLink: $options.getWidgetHeaderLink(item),
731
+ styleConfig: item.styleConfig || {},
499
732
  documentationUrl: $options.getWidgetDocumentationUrl(item),
500
733
  docsAnchor: $options.getWidgetDocsAnchor(item),
501
734
  onRefresh: $event => ($options.onWidgetRefresh(item)),
502
735
  onRequestFeature: $event => ($options.onWidgetRequestFeature(item))
503
736
  }, createSlots({
504
737
  default: withCtx(() => [
505
- createVNode(_component_CnChartWidget, mergeProps($options.getChartProps(item), {
738
+ (openBlock(), createBlock(resolveDynamicComponent($options.registryRenderer(item)), mergeProps({
506
739
  widgetId: item.widgetId,
507
- "data-source": $options.getWidgetDataSource(item)
508
- }), null, 16 /* FULL_PROPS */, ["widgetId", "data-source"])
740
+ content: $options.registryWidgetBindings(item)
741
+ }, { ref_for: true }, $options.registryWidgetBindings(item)), null, 16 /* FULL_PROPS */, ["widgetId", "content"]))
509
742
  ]),
510
743
  _: 2 /* DYNAMIC */
511
744
  }, [
512
- ($options.dateRangeEnabled && (item.dateChip === true || $options.formatChartDateRange(item)))
745
+ ($options.dateRangeEnabled && item.dateChip === true)
513
746
  ? {
514
747
  name: "title-meta",
515
748
  fn: withCtx(() => [
@@ -525,7 +758,7 @@ function render(_ctx, _cache, $props, $setup, $data, $options) {
525
758
  createElementVNode("span", {
526
759
  class: "cn-dashboard-page__date-chip",
527
760
  title: $data.dateChipTitle
528
- }, toDisplayString($options.formatChartDateRange(item) || $options.dashboardRangeChipLabel), 9 /* TEXT, PROPS */, _hoisted_17)
761
+ }, toDisplayString($options.dashboardRangeChipLabel), 9 /* TEXT, PROPS */, _hoisted_22)
529
762
  ]),
530
763
  default: withCtx(() => [
531
764
  (openBlock(true), createElementBlock(Fragment, null, renderList($options.effectivePresets, (preset) => {
@@ -535,12 +768,12 @@ function render(_ctx, _cache, $props, $setup, $data, $options) {
535
768
  onClick: $event => ($options.onChipPresetPick(preset, item))
536
769
  }, {
537
770
  icon: withCtx(() => [
538
- ($data.currentRange.preset === preset.id)
771
+ ($data.currentRange && $data.currentRange.preset === preset.id)
539
772
  ? (openBlock(), createBlock(_component_CalendarRange, {
540
773
  key: 0,
541
774
  size: 16
542
775
  }))
543
- : (openBlock(), createElementBlock("span", _hoisted_18))
776
+ : (openBlock(), createElementBlock("span", _hoisted_23))
544
777
  ]),
545
778
  default: withCtx(() => [
546
779
  createTextVNode(" " + toDisplayString(preset.label), 1 /* TEXT */)
@@ -552,16 +785,16 @@ function render(_ctx, _cache, $props, $setup, $data, $options) {
552
785
  createVNode(_component_NcActionInput, {
553
786
  type: "datetime-local",
554
787
  isNativePicker: "",
555
- modelValue: $options.toPickerDate($data.currentRange.from),
788
+ modelValue: $options.toPickerDate($data.currentRange && $data.currentRange.from),
556
789
  label: _ctx.t('nextcloud-vue', 'From'),
557
- "onUpdate:modelValue": _cache[4] || (_cache[4] = $event => ($options.onChipDateInput('from', $event)))
790
+ "onUpdate:modelValue": _cache[6] || (_cache[6] = $event => ($options.onChipDateInput('from', $event)))
558
791
  }, null, 8 /* PROPS */, ["modelValue", "label"]),
559
792
  createVNode(_component_NcActionInput, {
560
793
  type: "datetime-local",
561
794
  isNativePicker: "",
562
- modelValue: $options.toPickerDate($data.currentRange.to),
795
+ modelValue: $options.toPickerDate($data.currentRange && $data.currentRange.to),
563
796
  label: _ctx.t('nextcloud-vue', 'To'),
564
- "onUpdate:modelValue": _cache[5] || (_cache[5] = $event => ($options.onChipDateInput('to', $event)))
797
+ "onUpdate:modelValue": _cache[7] || (_cache[7] = $event => ($options.onChipDateInput('to', $event)))
565
798
  }, null, 8 /* PROPS */, ["modelValue", "label"])
566
799
  ]),
567
800
  _: 2 /* DYNAMIC */
@@ -570,200 +803,42 @@ function render(_ctx, _cache, $props, $setup, $data, $options) {
570
803
  key: "0"
571
804
  }
572
805
  : undefined
573
- ]), 1032 /* PROPS, DYNAMIC_SLOTS */, ["widgetId", "class", "title", "iconUrl", "iconClass", "showTitle", "borderless", "flush", "buttons", "styleConfig", "titleIconPosition", "titleIconColor", "titleIconVariant", "showRefresh", "documentationUrl", "docsAnchor", "onRefresh", "onRequestFeature"]))
574
- : ($options.isStatsBlock(item))
575
- ? (openBlock(), createBlock(_component_CnWidgetWrapper, {
576
- key: 5,
577
- widgetId: item.widgetId,
578
- title: $options.getWidgetTitle(item),
579
- iconUrl: $options.getWidgetIconUrl(item),
580
- iconClass: $options.getWidgetIconClass(item),
581
- showTitle: $options.widgetShowTitle(item),
582
- showActions: $options.widgetShowActions(item),
583
- borderless: $options.widgetBorderless(item),
584
- flush: item.flush !== false,
585
- class: normalizeClass({ 'cn-dashboard-page__card-fit': $options.isCardWidget(item) }),
586
- buttons: $options.getWidgetButtons(item),
587
- styleConfig: item.styleConfig || {},
588
- documentationUrl: $options.getWidgetDocumentationUrl(item),
589
- docsAnchor: $options.getWidgetDocsAnchor(item),
590
- onRefresh: $event => ($options.onWidgetRefresh(item)),
591
- onRequestFeature: $event => ($options.onWidgetRequestFeature(item))
592
- }, {
593
- default: withCtx(() => [
594
- createVNode(_component_CnStatsBlockWidget, mergeProps($options.getStatsBlockProps(item), {
595
- title: $options.getWidgetTitle(item),
596
- "data-source": $options.getWidgetDataSource(item)
597
- }), null, 16 /* FULL_PROPS */, ["title", "data-source"])
598
- ]),
599
- _: 2 /* DYNAMIC */
600
- }, 1032 /* PROPS, DYNAMIC_SLOTS */, ["widgetId", "title", "iconUrl", "iconClass", "showTitle", "showActions", "borderless", "flush", "class", "buttons", "styleConfig", "documentationUrl", "docsAnchor", "onRefresh", "onRequestFeature"]))
601
- : ($options.isIntegration(item))
602
- ? (openBlock(), createBlock(_component_CnWidgetWrapper, {
603
- key: 6,
604
- widgetId: item.widgetId,
605
- title: $options.getWidgetTitle(item),
606
- iconUrl: $options.getWidgetIconUrl(item),
607
- iconClass: $options.getWidgetIconClass(item),
608
- showTitle: $options.widgetShowTitle(item),
609
- borderless: $options.widgetBorderless(item),
610
- flush: item.flush !== false,
611
- buttons: $options.getWidgetButtons(item),
612
- styleConfig: item.styleConfig || {},
613
- titleIconPosition: $options.getWidgetTitleIconPosition(item),
614
- titleIconColor: $options.getWidgetTitleIconColor(item),
615
- titleIconVariant: $options.getWidgetTitleIconVariant(item),
616
- showRefresh: $options.getWidgetShowRefresh(item),
617
- documentationUrl: $options.getWidgetDocumentationUrl(item),
618
- docsAnchor: $options.getWidgetDocsAnchor(item),
619
- onRefresh: $event => ($options.onWidgetRefresh(item)),
620
- onRequestFeature: $event => ($options.onWidgetRequestFeature(item))
621
- }, {
622
- default: withCtx(() => [
623
- ($options.isMountIntegration(item))
624
- ? (openBlock(), createBlock(_component_CnLeafMountHost, {
625
- key: 0,
626
- provider: $options.integrationProviderFor(item),
627
- mountProps: $options.getIntegrationMountProps(item)
628
- }, null, 8 /* PROPS */, ["provider", "mountProps"]))
629
- : ($options.resolveIntegrationWidget(item))
630
- ? (openBlock(), createBlock(resolveDynamicComponent($options.resolveIntegrationWidget(item)), normalizeProps(mergeProps({ key: 1 }, $options.getIntegrationProps(item))), null, 16 /* FULL_PROPS */))
631
- : (openBlock(), createElementBlock("div", _hoisted_19, toDisplayString($props.unavailableLabel), 1 /* TEXT */))
632
- ]),
633
- _: 2 /* DYNAMIC */
634
- }, 1032 /* PROPS, DYNAMIC_SLOTS */, ["widgetId", "title", "iconUrl", "iconClass", "showTitle", "borderless", "flush", "buttons", "styleConfig", "titleIconPosition", "titleIconColor", "titleIconVariant", "showRefresh", "documentationUrl", "docsAnchor", "onRefresh", "onRequestFeature"]))
635
- : ($options.isNcWidget(item))
636
- ? (openBlock(), createBlock(_component_CnWidgetWrapper, {
637
- key: 7,
638
- widgetId: item.widgetId,
639
- title: $options.getWidgetTitle(item),
640
- iconUrl: $options.getWidgetIconUrl(item),
641
- iconClass: $options.getWidgetIconClass(item),
642
- showTitle: $options.widgetShowTitle(item),
643
- buttons: $options.getWidgetButtons(item),
644
- styleConfig: item.styleConfig || {},
645
- showRefresh: $options.getWidgetShowRefresh(item),
646
- documentationUrl: $options.getWidgetDocumentationUrl(item),
647
- docsAnchor: $options.getWidgetDocsAnchor(item),
648
- onRefresh: $event => ($options.onWidgetRefresh(item)),
649
- onRequestFeature: $event => ($options.onWidgetRequestFeature(item))
650
- }, {
651
- default: withCtx(() => [
652
- createVNode(_component_CnWidgetRenderer, {
653
- widget: $options.getWidgetDef(item.widgetId),
654
- unavailableText: $props.unavailableLabel
655
- }, null, 8 /* PROPS */, ["widget", "unavailableText"])
656
- ]),
657
- _: 2 /* DYNAMIC */
658
- }, 1032 /* PROPS, DYNAMIC_SLOTS */, ["widgetId", "title", "iconUrl", "iconClass", "showTitle", "buttons", "styleConfig", "showRefresh", "documentationUrl", "docsAnchor", "onRefresh", "onRequestFeature"]))
659
- : ($options.registryRenderer(item))
660
- ? (openBlock(), createBlock(_component_CnWidgetWrapper, {
661
- key: 8,
662
- widgetId: item.widgetId,
663
- title: $options.getWidgetTitle(item),
664
- showTitle: $options.widgetShowTitle(item),
665
- showActions: $options.widgetShowActions(item),
666
- showRefresh: $options.getWidgetShowRefresh(item),
667
- borderless: $options.widgetBorderless(item),
668
- flush: item.flush !== false,
669
- titleIconPosition: $options.getWidgetTitleIconPosition(item),
670
- titleIconColor: $options.getWidgetTitleIconColor(item),
671
- titleIconVariant: $options.getWidgetTitleIconVariant(item),
672
- class: normalizeClass({ 'cn-dashboard-page__card-fit': $options.isCardWidget(item) }),
673
- buttons: $options.getWidgetButtons(item),
674
- styleConfig: item.styleConfig || {},
675
- documentationUrl: $options.getWidgetDocumentationUrl(item),
676
- docsAnchor: $options.getWidgetDocsAnchor(item),
677
- onRefresh: $event => ($options.onWidgetRefresh(item)),
678
- onRequestFeature: $event => ($options.onWidgetRequestFeature(item))
679
- }, createSlots({
680
- default: withCtx(() => [
681
- (openBlock(), createBlock(resolveDynamicComponent($options.registryRenderer(item)), mergeProps({
682
- widgetId: item.widgetId,
683
- content: $options.registryWidgetBindings(item)
684
- }, $options.registryWidgetBindings(item)), null, 16 /* FULL_PROPS */, ["widgetId", "content"]))
685
- ]),
686
- _: 2 /* DYNAMIC */
687
- }, [
688
- ($options.dateRangeEnabled && item.dateChip === true)
689
- ? {
690
- name: "title-meta",
691
- fn: withCtx(() => [
692
- createVNode(_component_NcActions, {
693
- open: $data.openChipPicker[item.widgetId],
694
- "onUpdate:open": $event => (($data.openChipPicker[item.widgetId]) = $event),
695
- forceMenu: true,
696
- container: "body",
697
- "data-testid": `cn-dashboard-page-date-chip-${item.widgetId}`,
698
- class: "cn-dashboard-page__date-chip-trigger"
699
- }, {
700
- icon: withCtx(() => [
701
- createElementVNode("span", {
702
- class: "cn-dashboard-page__date-chip",
703
- title: $data.dateChipTitle
704
- }, toDisplayString($options.dashboardRangeChipLabel), 9 /* TEXT, PROPS */, _hoisted_20)
705
- ]),
706
- default: withCtx(() => [
707
- (openBlock(true), createElementBlock(Fragment, null, renderList($options.effectivePresets, (preset) => {
708
- return (openBlock(), createBlock(_component_NcActionButton, {
709
- key: preset.id,
710
- closeAfterClick: true,
711
- onClick: $event => ($options.onChipPresetPick(preset, item))
712
- }, {
713
- icon: withCtx(() => [
714
- ($data.currentRange && $data.currentRange.preset === preset.id)
715
- ? (openBlock(), createBlock(_component_CalendarRange, {
716
- key: 0,
717
- size: 16
718
- }))
719
- : (openBlock(), createElementBlock("span", _hoisted_21))
720
- ]),
721
- default: withCtx(() => [
722
- createTextVNode(" " + toDisplayString(preset.label), 1 /* TEXT */)
723
- ]),
724
- _: 2 /* DYNAMIC */
725
- }, 1032 /* PROPS, DYNAMIC_SLOTS */, ["onClick"]))
726
- }), 128 /* KEYED_FRAGMENT */)),
727
- createVNode(_component_NcActionSeparator),
728
- createVNode(_component_NcActionInput, {
729
- type: "datetime-local",
730
- isNativePicker: "",
731
- modelValue: $options.toPickerDate($data.currentRange && $data.currentRange.from),
732
- label: _ctx.t('nextcloud-vue', 'From'),
733
- "onUpdate:modelValue": _cache[6] || (_cache[6] = $event => ($options.onChipDateInput('from', $event)))
734
- }, null, 8 /* PROPS */, ["modelValue", "label"]),
735
- createVNode(_component_NcActionInput, {
736
- type: "datetime-local",
737
- isNativePicker: "",
738
- modelValue: $options.toPickerDate($data.currentRange && $data.currentRange.to),
739
- label: _ctx.t('nextcloud-vue', 'To'),
740
- "onUpdate:modelValue": _cache[7] || (_cache[7] = $event => ($options.onChipDateInput('to', $event)))
741
- }, null, 8 /* PROPS */, ["modelValue", "label"])
742
- ]),
743
- _: 2 /* DYNAMIC */
744
- }, 1032 /* PROPS, DYNAMIC_SLOTS */, ["open", "onUpdate:open", "data-testid"])
745
- ]),
746
- key: "0"
747
- }
748
- : undefined
749
- ]), 1032 /* PROPS, DYNAMIC_SLOTS */, ["widgetId", "title", "showTitle", "showActions", "showRefresh", "borderless", "flush", "titleIconPosition", "titleIconColor", "titleIconVariant", "class", "buttons", "styleConfig", "documentationUrl", "docsAnchor", "onRefresh", "onRequestFeature"]))
750
- : (openBlock(), createBlock(_component_CnWidgetWrapper, {
751
- key: 9,
752
- title: $options.getWidgetTitle(item),
753
- showTitle: $options.widgetShowTitle(item),
754
- showRefresh: false
755
- }, {
756
- default: withCtx(() => [
757
- createElementVNode("div", _hoisted_22, toDisplayString($props.unavailableLabel), 1 /* TEXT */)
758
- ]),
759
- _: 1 /* STABLE */
760
- }, 8 /* PROPS */, ["title", "showTitle"]))
761
- ]),
762
- _: 3 /* FORWARDED */
763
- }, 8 /* PROPS */, ["layout", "editable", "columns", "cellHeight", "margin", "onLayoutChange"])),
806
+ ]), 1032 /* PROPS, DYNAMIC_SLOTS */, ["widgetId", "title", "showTitle", "showActions", "showRefresh", "borderless", "flush", "titleIconPosition", "titleIconColor", "titleIconVariant", "class", "buttons", "headerLink", "styleConfig", "documentationUrl", "docsAnchor", "onRefresh", "onRequestFeature"]))
807
+ : (openBlock(), createBlock(_component_CnWidgetWrapper, {
808
+ key: 9,
809
+ title: $options.getWidgetTitle(item),
810
+ showTitle: $options.widgetShowTitle(item),
811
+ showRefresh: false
812
+ }, {
813
+ default: withCtx(() => [
814
+ createElementVNode("div", _hoisted_24, toDisplayString($props.unavailableLabel), 1 /* TEXT */)
815
+ ]),
816
+ _: 1 /* STABLE */
817
+ }, 8 /* PROPS */, ["title", "showTitle"]))
818
+ ]),
819
+ _: 3 /* FORWARDED */
820
+ }, 16 /* FULL_PROPS */, ["layout", "editable", "columns", "cellHeight", "margin", "onLayoutChange"]))
821
+ }), 128 /* KEYED_FRAGMENT */)),
822
+ ($options.gridSectionsShown && $options.viewIsEmpty)
823
+ ? (openBlock(), createElementBlock("div", {
824
+ key: 10,
825
+ id: _ctx.viewRegionId,
826
+ role: "region",
827
+ "aria-label": _ctx.activeView ? _ctx.activeView.label : null,
828
+ class: "cn-page-view-region cn-page-view-region--empty",
829
+ "data-testid": "cn-dashboard-page-view-empty"
830
+ }, [
831
+ createVNode(_component_NcEmptyContent, { description: _ctx.viewEmptyText }, {
832
+ icon: withCtx(() => [
833
+ createVNode(_component_ViewDashboardOutline, { size: 48 })
834
+ ]),
835
+ _: 1 /* STABLE */
836
+ }, 8 /* PROPS */, ["description"])
837
+ ], 8 /* PROPS */, _hoisted_25))
838
+ : createCommentVNode("v-if", true),
764
839
  ($options.hasBodyWidgets)
765
840
  ? (openBlock(), createBlock(_component_CnBodySections, {
766
- key: 8,
841
+ key: 11,
767
842
  sections: $props.bodyWidgets,
768
843
  context: $options.sectionContext,
769
844
  placement: "after-grid",
@@ -772,7 +847,7 @@ function render(_ctx, _cache, $props, $setup, $data, $options) {
772
847
  : createCommentVNode("v-if", true),
773
848
  ($options.hasBodyWidgets)
774
849
  ? (openBlock(), createBlock(_component_CnBodySections, {
775
- key: 9,
850
+ key: 12,
776
851
  sections: $options.endPlacementSections,
777
852
  context: $options.sectionContext,
778
853
  placement: null,
@@ -781,7 +856,7 @@ function render(_ctx, _cache, $props, $setup, $data, $options) {
781
856
  : createCommentVNode("v-if", true),
782
857
  ($data.showWidgetConfig)
783
858
  ? (openBlock(), createBlock(_component_CnWidgetStyleEditorModal, {
784
- key: 10,
859
+ key: 13,
785
860
  show: $data.showWidgetConfig,
786
861
  widget: $options.configWidget,
787
862
  deletable: true,