@questpie/admin 3.2.3 → 3.2.5
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/client/blocks/block-renderer.d.mts +2 -2
- package/dist/client/blocks/block-renderer.mjs +164 -339
- package/dist/client/components/actions/action-button.mjs +9 -9
- package/dist/client/components/actions/action-dialog.mjs +195 -493
- package/dist/client/components/actions/confirmation-dialog.mjs +44 -159
- package/dist/client/components/actions/header-actions.mjs +73 -165
- package/dist/client/components/admin-link.d.mts +2 -2
- package/dist/client/components/admin-link.mjs +40 -126
- package/dist/client/components/auth/auth-loading.mjs +9 -44
- package/dist/client/components/blocks/block-canvas.mjs +31 -95
- package/dist/client/components/blocks/block-editor-context.mjs +13 -57
- package/dist/client/components/blocks/block-editor-layout.mjs +72 -166
- package/dist/client/components/blocks/block-editor-provider.mjs +184 -245
- package/dist/client/components/blocks/block-fields-renderer.mjs +54 -229
- package/dist/client/components/blocks/block-insert-button.mjs +49 -165
- package/dist/client/components/blocks/block-item-menu.mjs +102 -301
- package/dist/client/components/blocks/block-item.mjs +136 -370
- package/dist/client/components/blocks/block-library-sidebar.mjs +106 -220
- package/dist/client/components/blocks/block-tree.mjs +12 -68
- package/dist/client/components/blocks/block-type-icon.mjs +14 -56
- package/dist/client/components/brand-logo.mjs +35 -149
- package/dist/client/components/component-renderer.mjs +42 -118
- package/dist/client/components/error-boundary.mjs +14 -58
- package/dist/client/components/fields/array-field.mjs +209 -521
- package/dist/client/components/fields/asset-preview-field.mjs +41 -141
- package/dist/client/components/fields/blocks-field/blocks-field.mjs +60 -156
- package/dist/client/components/fields/boolean-field.mjs +29 -59
- package/dist/client/components/fields/date-field.mjs +7 -37
- package/dist/client/components/fields/datetime-field.mjs +7 -38
- package/dist/client/components/fields/email-field.mjs +25 -54
- package/dist/client/components/fields/field-wrapper.mjs +30 -105
- package/dist/client/components/fields/json-field.mjs +107 -313
- package/dist/client/components/fields/locale-badge.mjs +6 -15
- package/dist/client/components/fields/number-field.mjs +27 -60
- package/dist/client/components/fields/object-array-field.mjs +283 -659
- package/dist/client/components/fields/object-field.mjs +165 -633
- package/dist/client/components/fields/relation/displays/cards-display.mjs +106 -220
- package/dist/client/components/fields/relation/displays/chips-display.mjs +78 -150
- package/dist/client/components/fields/relation/displays/grid-display.mjs +92 -186
- package/dist/client/components/fields/relation/displays/list-display.mjs +122 -239
- package/dist/client/components/fields/relation/displays/table-display.mjs +70 -244
- package/dist/client/components/fields/relation/relation-items-display.mjs +30 -126
- package/dist/client/components/fields/relation-field.mjs +10 -66
- package/dist/client/components/fields/relation-picker.mjs +18 -18
- package/dist/client/components/fields/relation-select.mjs +12 -12
- package/dist/client/components/fields/rich-text-editor/bubble-menu.mjs +80 -182
- package/dist/client/components/fields/rich-text-editor/image-popover.mjs +8 -19
- package/dist/client/components/fields/rich-text-editor/image-upload.mjs +13 -29
- package/dist/client/components/fields/rich-text-editor/index.mjs +196 -530
- package/dist/client/components/fields/rich-text-editor/slash-commands.mjs +61 -111
- package/dist/client/components/fields/rich-text-editor/table-controls.mjs +105 -415
- package/dist/client/components/fields/rich-text-editor/toolbar.mjs +256 -511
- package/dist/client/components/fields/rich-text-field.mjs +14 -53
- package/dist/client/components/fields/select-field.mjs +39 -74
- package/dist/client/components/fields/text-field.mjs +26 -59
- package/dist/client/components/fields/textarea-field.mjs +26 -58
- package/dist/client/components/fields/time-field.mjs +7 -35
- package/dist/client/components/fields/upload-field.mjs +47 -165
- package/dist/client/components/filter-builder/columns-tab.mjs +80 -280
- package/dist/client/components/filter-builder/filter-builder-sheet.mjs +197 -540
- package/dist/client/components/filter-builder/filters-tab.mjs +96 -386
- package/dist/client/components/filter-builder/saved-views-tab.mjs +133 -351
- package/dist/client/components/history-sidebar.mjs +306 -611
- package/dist/client/components/layout/field-layout-renderer.mjs +106 -254
- package/dist/client/components/locale-switcher.mjs +106 -228
- package/dist/client/components/media/media-grid.mjs +84 -273
- package/dist/client/components/media/media-picker-dialog.mjs +177 -494
- package/dist/client/components/preview/live-preview-mode.mjs +240 -438
- package/dist/client/components/preview/preview-pane.mjs +22 -22
- package/dist/client/components/primitives/asset-preview.mjs +290 -666
- package/dist/client/components/primitives/checkbox-input.mjs +9 -35
- package/dist/client/components/primitives/date-input.mjs +109 -327
- package/dist/client/components/primitives/dropzone.mjs +209 -336
- package/dist/client/components/primitives/field-select-control.mjs +12 -80
- package/dist/client/components/primitives/number-input.mjs +4 -4
- package/dist/client/components/primitives/select-multi.mjs +200 -559
- package/dist/client/components/primitives/select-single.mjs +165 -499
- package/dist/client/components/primitives/time-input.mjs +43 -117
- package/dist/client/components/primitives/toggle-input.mjs +9 -29
- package/dist/client/components/sheets/resource-sheet.mjs +61 -70
- package/dist/client/components/ui/accordion.mjs +35 -155
- package/dist/client/components/ui/alert.mjs +13 -68
- package/dist/client/components/ui/badge.mjs +9 -51
- package/dist/client/components/ui/button.mjs +8 -54
- package/dist/client/components/ui/card.mjs +37 -193
- package/dist/client/components/ui/checkbox.mjs +12 -68
- package/dist/client/components/ui/command.mjs +48 -219
- package/dist/client/components/ui/dialog.mjs +50 -262
- package/dist/client/components/ui/drawer.mjs +55 -259
- package/dist/client/components/ui/dropdown-menu.mjs +86 -427
- package/dist/client/components/ui/empty-state.mjs +28 -98
- package/dist/client/components/ui/field.mjs +73 -309
- package/dist/client/components/ui/input-group.mjs +42 -167
- package/dist/client/components/ui/input.mjs +7 -37
- package/dist/client/components/ui/kbd.mjs +6 -36
- package/dist/client/components/ui/label.mjs +7 -37
- package/dist/client/components/ui/popover.mjs +34 -169
- package/dist/client/components/ui/responsive-dialog.mjs +67 -273
- package/dist/client/components/ui/scroll-fade.mjs +63 -158
- package/dist/client/components/ui/search-input.mjs +33 -100
- package/dist/client/components/ui/select.mjs +72 -393
- package/dist/client/components/ui/separator.mjs +7 -38
- package/dist/client/components/ui/sheet.mjs +49 -269
- package/dist/client/components/ui/sidebar.mjs +171 -690
- package/dist/client/components/ui/skeleton.mjs +7 -38
- package/dist/client/components/ui/sonner.mjs +11 -42
- package/dist/client/components/ui/switch.mjs +9 -45
- package/dist/client/components/ui/table.mjs +48 -266
- package/dist/client/components/ui/tabs.mjs +26 -139
- package/dist/client/components/ui/textarea.mjs +6 -32
- package/dist/client/components/ui/tooltip.mjs +27 -129
- package/dist/client/components/widgets/chart-widget.mjs +174 -522
- package/dist/client/components/widgets/progress-widget.mjs +66 -172
- package/dist/client/components/widgets/quick-actions-widget.mjs +102 -261
- package/dist/client/components/widgets/recent-items-widget.mjs +69 -195
- package/dist/client/components/widgets/stats-widget.mjs +41 -175
- package/dist/client/components/widgets/table-widget.mjs +9 -9
- package/dist/client/components/widgets/timeline-widget.mjs +86 -226
- package/dist/client/components/widgets/value-widget.mjs +74 -381
- package/dist/client/components/widgets/widget-empty-state.mjs +26 -76
- package/dist/client/components/widgets/widget-skeletons.mjs +138 -421
- package/dist/client/contexts/focus-context.d.mts +4 -0
- package/dist/client/contexts/focus-context.mjs +87 -150
- package/dist/client/hooks/typed-hooks.mjs +241 -701
- package/dist/client/hooks/use-action.mjs +62 -198
- package/dist/client/hooks/use-admin-config.mjs +5 -35
- package/dist/client/hooks/use-admin-preferences.mjs +16 -88
- package/dist/client/hooks/use-admin-routes.mjs +22 -56
- package/dist/client/hooks/use-audit-history.mjs +21 -69
- package/dist/client/hooks/use-brand.mjs +1 -9
- package/dist/client/hooks/use-collection-fields.mjs +17 -57
- package/dist/client/hooks/use-collection-meta.mjs +12 -44
- package/dist/client/hooks/use-collection-schema.mjs +10 -33
- package/dist/client/hooks/use-collection-validation.mjs +23 -53
- package/dist/client/hooks/use-collection.mjs +194 -614
- package/dist/client/hooks/use-current-user.mjs +0 -1
- package/dist/client/hooks/use-field-hooks.mjs +10 -10
- package/dist/client/hooks/use-field-options.mjs +61 -202
- package/dist/client/hooks/use-global-fields.mjs +14 -46
- package/dist/client/hooks/use-global-meta.mjs +9 -30
- package/dist/client/hooks/use-global-schema.mjs +9 -30
- package/dist/client/hooks/use-global.mjs +63 -219
- package/dist/client/hooks/use-locks.mjs +117 -325
- package/dist/client/hooks/use-media-query.mjs +16 -36
- package/dist/client/hooks/use-prefill-params.mjs +0 -1
- package/dist/client/hooks/use-questpie-query-options.mjs +12 -29
- package/dist/client/hooks/use-reactive-fields.mjs +1 -1
- package/dist/client/hooks/use-reactive-prop.mjs +65 -223
- package/dist/client/hooks/use-realtime-highlight.mjs +51 -114
- package/dist/client/hooks/use-saved-views.mjs +22 -103
- package/dist/client/hooks/use-search-param-toggle.mjs +28 -79
- package/dist/client/hooks/use-search.mjs +31 -143
- package/dist/client/hooks/use-server-actions.mjs +18 -50
- package/dist/client/hooks/use-server-validation.mjs +72 -166
- package/dist/client/hooks/use-server-widget-data.mjs +7 -33
- package/dist/client/hooks/use-setup-status.mjs +12 -25
- package/dist/client/hooks/use-sidebar-search-param.mjs +33 -78
- package/dist/client/hooks/use-transition-stage.mjs +8 -38
- package/dist/client/hooks/use-upload.mjs +54 -152
- package/dist/client/hooks/use-validation-error-map.mjs +6 -26
- package/dist/client/hooks/use-view-state.mjs +187 -437
- package/dist/client/i18n/hooks.mjs +65 -197
- package/dist/client/lib/render-profiler.mjs +14 -41
- package/dist/client/preview/block-scope-context.d.mts +2 -2
- package/dist/client/preview/block-scope-context.mjs +14 -36
- package/dist/client/preview/diff.mjs +110 -0
- package/dist/client/preview/preview-banner.mjs +42 -108
- package/dist/client/preview/preview-field.d.mts +4 -4
- package/dist/client/preview/preview-field.mjs +166 -409
- package/dist/client/preview/use-collection-preview.mjs +135 -201
- package/dist/client/runtime/content-locales-provider.mjs +31 -83
- package/dist/client/runtime/locale-scope.mjs +22 -63
- package/dist/client/runtime/provider.mjs +100 -255
- package/dist/client/runtime/translations-provider.mjs +41 -107
- package/dist/client/scope/picker.d.mts +2 -2
- package/dist/client/scope/picker.mjs +86 -321
- package/dist/client/scope/provider.d.mts +2 -2
- package/dist/client/scope/provider.mjs +8 -17
- package/dist/client/views/auth/accept-invite-form.d.mts +2 -2
- package/dist/client/views/auth/accept-invite-form.mjs +121 -412
- package/dist/client/views/auth/auth-layout.d.mts +3 -3
- package/dist/client/views/auth/auth-layout.mjs +104 -284
- package/dist/client/views/auth/forgot-password-form.d.mts +2 -2
- package/dist/client/views/auth/forgot-password-form.mjs +94 -325
- package/dist/client/views/auth/invite-form.mjs +107 -442
- package/dist/client/views/auth/login-form.d.mts +2 -2
- package/dist/client/views/auth/login-form.mjs +116 -337
- package/dist/client/views/auth/reset-password-form.mjs +128 -453
- package/dist/client/views/auth/setup-form.mjs +140 -478
- package/dist/client/views/collection/auto-form-fields.mjs +243 -615
- package/dist/client/views/collection/bulk-action-toolbar.mjs +212 -400
- package/dist/client/views/collection/cells/complex-cells.mjs +183 -611
- package/dist/client/views/collection/cells/primitive-cells.mjs +109 -363
- package/dist/client/views/collection/cells/relation-cells.mjs +86 -233
- package/dist/client/views/collection/cells/shared/asset-thumbnail.mjs +142 -371
- package/dist/client/views/collection/cells/shared/relation-chip.mjs +35 -131
- package/dist/client/views/collection/cells/upload-cells.mjs +60 -177
- package/dist/client/views/collection/columns/build-columns.mjs +8 -48
- package/dist/client/views/collection/field-renderer.mjs +11 -24
- package/dist/client/views/collection/form-view.mjs +288 -560
- package/dist/client/views/collection/table-view.mjs +239 -469
- package/dist/client/views/collection/view-skeletons.mjs +112 -237
- package/dist/client/views/common/global-search.mjs +241 -543
- package/dist/client/views/dashboard/dashboard-grid.mjs +256 -775
- package/dist/client/views/dashboard/dashboard-widget.mjs +38 -126
- package/dist/client/views/dashboard/widget-card.mjs +61 -269
- package/dist/client/views/globals/global-form-view.mjs +478 -1298
- package/dist/client/views/layout/admin-layout-provider.mjs +28 -88
- package/dist/client/views/layout/admin-layout.mjs +83 -246
- package/dist/client/views/layout/admin-router.mjs +457 -1289
- package/dist/client/views/layout/admin-sidebar.mjs +510 -1292
- package/dist/client/views/layout/admin-theme.mjs +30 -64
- package/dist/client/views/layout/admin-view-layout.mjs +40 -144
- package/dist/client/views/pages/accept-invite-page.mjs +95 -290
- package/dist/client/views/pages/dashboard-page.mjs +11 -57
- package/dist/client/views/pages/forgot-password-page.mjs +31 -83
- package/dist/client/views/pages/invite-page.mjs +35 -90
- package/dist/client/views/pages/login-page.mjs +41 -121
- package/dist/client/views/pages/reset-password-page.d.mts +2 -2
- package/dist/client/views/pages/reset-password-page.mjs +46 -173
- package/dist/client/views/pages/setup-page.d.mts +2 -2
- package/dist/client/views/pages/setup-page.mjs +33 -95
- package/dist/components/rich-text/rich-text-renderer.d.mts +2 -2
- package/dist/components/rich-text/rich-text-renderer.mjs +9 -33
- package/dist/server/modules/admin/collections/account.d.mts +50 -50
- package/dist/server/modules/admin/collections/admin-locks.d.mts +54 -54
- package/dist/server/modules/admin/collections/admin-preferences.d.mts +39 -39
- package/dist/server/modules/admin/collections/admin-saved-views.d.mts +47 -47
- package/dist/server/modules/admin/collections/apikey.d.mts +68 -68
- package/dist/server/modules/admin/collections/assets.d.mts +34 -34
- package/dist/server/modules/admin/collections/session.d.mts +42 -42
- package/dist/server/modules/admin/collections/user.d.mts +53 -53
- package/dist/server/modules/admin/collections/verification.d.mts +36 -36
- package/dist/server/modules/admin/index.d.mts +21 -20
- package/dist/server/modules/admin/routes/admin-config.d.mts +2 -2
- package/dist/server/modules/admin/routes/execute-action.d.mts +9 -9
- package/dist/server/modules/admin/routes/locales.d.mts +2 -2
- package/dist/server/modules/admin/routes/preview.d.mts +11 -11
- package/dist/server/modules/admin/routes/reactive.d.mts +9 -9
- package/dist/server/modules/admin/routes/setup.d.mts +7 -7
- package/dist/server/modules/admin/routes/translations.d.mts +4 -4
- package/dist/server/modules/admin/routes/widget-data.d.mts +5 -5
- package/dist/server/modules/admin-preferences/collections/saved-views.d.mts +27 -27
- package/package.json +3 -5
|
@@ -5,7 +5,6 @@ import { WidgetCard } from "../../views/dashboard/widget-card.mjs";
|
|
|
5
5
|
import { useServerWidgetData } from "../../hooks/use-server-widget-data.mjs";
|
|
6
6
|
import { WidgetEmptyState } from "./widget-empty-state.mjs";
|
|
7
7
|
import { ProgressWidgetSkeleton } from "./widget-skeletons.mjs";
|
|
8
|
-
import { c } from "react/compiler-runtime";
|
|
9
8
|
import { useQuery } from "@tanstack/react-query";
|
|
10
9
|
import { jsx, jsxs } from "react/jsx-runtime";
|
|
11
10
|
|
|
@@ -38,189 +37,84 @@ import { jsx, jsxs } from "react/jsx-runtime";
|
|
|
38
37
|
* />
|
|
39
38
|
* ```
|
|
40
39
|
*/
|
|
41
|
-
function ProgressWidget(
|
|
42
|
-
const $ = c(48);
|
|
43
|
-
const { config } = t0;
|
|
40
|
+
function ProgressWidget({ config }) {
|
|
44
41
|
const client = useAdminStore(selectClient);
|
|
45
42
|
const resolveText = useResolveText();
|
|
46
43
|
const { t } = useTranslation();
|
|
47
|
-
const { color, showPercentage
|
|
48
|
-
const showPercentage = t1 === void 0 ? true : t1;
|
|
44
|
+
const { color, showPercentage = true } = config;
|
|
49
45
|
const useServerData = !!config.hasLoader;
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
$[0] = config.refreshInterval;
|
|
57
|
-
$[1] = useServerData;
|
|
58
|
-
$[2] = t2;
|
|
59
|
-
} else t2 = $[2];
|
|
60
|
-
const serverQuery = useServerWidgetData(config.id, t2);
|
|
61
|
-
let t3;
|
|
62
|
-
if ($[3] !== config.id) {
|
|
63
|
-
t3 = [
|
|
46
|
+
const serverQuery = useServerWidgetData(config.id, {
|
|
47
|
+
enabled: useServerData,
|
|
48
|
+
refreshInterval: config.refreshInterval
|
|
49
|
+
});
|
|
50
|
+
const clientQuery = useQuery({
|
|
51
|
+
queryKey: [
|
|
64
52
|
"widget",
|
|
65
53
|
"progress",
|
|
66
54
|
config.id
|
|
67
|
-
]
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
if ($[5] !== client || $[6] !== config.loader) {
|
|
73
|
-
t4 = () => config.loader(client);
|
|
74
|
-
$[5] = client;
|
|
75
|
-
$[6] = config.loader;
|
|
76
|
-
$[7] = t4;
|
|
77
|
-
} else t4 = $[7];
|
|
78
|
-
const t5 = !useServerData && !!config.loader;
|
|
79
|
-
let t6;
|
|
80
|
-
if ($[8] !== config.refreshInterval || $[9] !== t3 || $[10] !== t4 || $[11] !== t5) {
|
|
81
|
-
t6 = {
|
|
82
|
-
queryKey: t3,
|
|
83
|
-
queryFn: t4,
|
|
84
|
-
enabled: t5,
|
|
85
|
-
refetchInterval: config.refreshInterval
|
|
86
|
-
};
|
|
87
|
-
$[8] = config.refreshInterval;
|
|
88
|
-
$[9] = t3;
|
|
89
|
-
$[10] = t4;
|
|
90
|
-
$[11] = t5;
|
|
91
|
-
$[12] = t6;
|
|
92
|
-
} else t6 = $[12];
|
|
93
|
-
const clientQuery = useQuery(t6);
|
|
55
|
+
],
|
|
56
|
+
queryFn: () => config.loader(client),
|
|
57
|
+
enabled: !useServerData && !!config.loader,
|
|
58
|
+
refetchInterval: config.refreshInterval
|
|
59
|
+
});
|
|
94
60
|
const { data, isLoading, error, refetch, isFetching } = useServerData ? serverQuery : clientQuery;
|
|
95
|
-
|
|
96
|
-
if ($[13] !== config.title || $[14] !== resolveText) {
|
|
97
|
-
t7 = config.title ? resolveText(config.title) : void 0;
|
|
98
|
-
$[13] = config.title;
|
|
99
|
-
$[14] = resolveText;
|
|
100
|
-
$[15] = t7;
|
|
101
|
-
} else t7 = $[15];
|
|
102
|
-
const title = t7;
|
|
61
|
+
const title = config.title ? resolveText(config.title) : void 0;
|
|
103
62
|
const percentage = data ? Math.min(data.current / data.target * 100, 100) : 0;
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
};
|
|
120
|
-
$[18] = color;
|
|
121
|
-
$[19] = percentage;
|
|
122
|
-
$[20] = t9;
|
|
123
|
-
} else t9 = $[20];
|
|
124
|
-
const getProgressColor = t9;
|
|
125
|
-
let t10;
|
|
126
|
-
if ($[21] !== data || $[22] !== getProgressColor || $[23] !== percentage || $[24] !== percentageFormatted || $[25] !== showPercentage || $[26] !== t) {
|
|
127
|
-
t10 = data ? /* @__PURE__ */ jsxs("div", {
|
|
128
|
-
className: "space-y-3",
|
|
129
|
-
children: [
|
|
130
|
-
/* @__PURE__ */ jsx("div", {
|
|
131
|
-
className: "relative",
|
|
63
|
+
const percentageFormatted = percentage.toFixed(0);
|
|
64
|
+
const getProgressColor = () => {
|
|
65
|
+
if (color) return color;
|
|
66
|
+
if (percentage >= 100) return "bg-success";
|
|
67
|
+
if (percentage >= 75) return "bg-primary";
|
|
68
|
+
if (percentage >= 50) return "bg-warning";
|
|
69
|
+
return "bg-muted-foreground";
|
|
70
|
+
};
|
|
71
|
+
const progressContent = data ? /* @__PURE__ */ jsxs("div", {
|
|
72
|
+
className: "space-y-3",
|
|
73
|
+
children: [
|
|
74
|
+
/* @__PURE__ */ jsx("div", {
|
|
75
|
+
className: "relative",
|
|
76
|
+
children: /* @__PURE__ */ jsx("div", {
|
|
77
|
+
className: "bg-muted h-2 w-full overflow-hidden rounded-full",
|
|
132
78
|
children: /* @__PURE__ */ jsx("div", {
|
|
133
|
-
className: "
|
|
134
|
-
|
|
135
|
-
className: cn("h-full rounded-full transition-[width] duration-500", getProgressColor()),
|
|
136
|
-
style: { width: `${percentage}%` }
|
|
137
|
-
})
|
|
79
|
+
className: cn("h-full rounded-full transition-[width] duration-500", getProgressColor()),
|
|
80
|
+
style: { width: `${percentage}%` }
|
|
138
81
|
})
|
|
139
|
-
}),
|
|
140
|
-
/* @__PURE__ */ jsxs("div", {
|
|
141
|
-
className: "flex items-center justify-between text-sm",
|
|
142
|
-
children: [/* @__PURE__ */ jsx("span", {
|
|
143
|
-
className: "text-muted-foreground tabular-nums",
|
|
144
|
-
children: data.label || `${data.current.toLocaleString()} / ${data.target.toLocaleString()}`
|
|
145
|
-
}), showPercentage && /* @__PURE__ */ jsxs("span", {
|
|
146
|
-
className: "font-medium tabular-nums",
|
|
147
|
-
children: [percentageFormatted, "%"]
|
|
148
|
-
})]
|
|
149
|
-
}),
|
|
150
|
-
data.subtitle && /* @__PURE__ */ jsx("p", {
|
|
151
|
-
className: "text-muted-foreground text-xs",
|
|
152
|
-
children: data.subtitle
|
|
153
82
|
})
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
if ($[34] !== refetch) {
|
|
190
|
-
t15 = () => refetch();
|
|
191
|
-
$[34] = refetch;
|
|
192
|
-
$[35] = t15;
|
|
193
|
-
} else t15 = $[35];
|
|
194
|
-
let t16;
|
|
195
|
-
if ($[36] !== config.actions || $[37] !== config.cardVariant || $[38] !== config.className || $[39] !== config.icon || $[40] !== isLoading || $[41] !== progressContent || $[42] !== t11 || $[43] !== t12 || $[44] !== t14 || $[45] !== t15 || $[46] !== title) {
|
|
196
|
-
t16 = /* @__PURE__ */ jsx(WidgetCard, {
|
|
197
|
-
title,
|
|
198
|
-
description: t11,
|
|
199
|
-
icon: config.icon,
|
|
200
|
-
variant: config.cardVariant,
|
|
201
|
-
isLoading,
|
|
202
|
-
isRefreshing: t12,
|
|
203
|
-
loadingSkeleton: t13,
|
|
204
|
-
error: t14,
|
|
205
|
-
onRefresh: t15,
|
|
206
|
-
actions: config.actions,
|
|
207
|
-
className: config.className,
|
|
208
|
-
children: progressContent
|
|
209
|
-
});
|
|
210
|
-
$[36] = config.actions;
|
|
211
|
-
$[37] = config.cardVariant;
|
|
212
|
-
$[38] = config.className;
|
|
213
|
-
$[39] = config.icon;
|
|
214
|
-
$[40] = isLoading;
|
|
215
|
-
$[41] = progressContent;
|
|
216
|
-
$[42] = t11;
|
|
217
|
-
$[43] = t12;
|
|
218
|
-
$[44] = t14;
|
|
219
|
-
$[45] = t15;
|
|
220
|
-
$[46] = title;
|
|
221
|
-
$[47] = t16;
|
|
222
|
-
} else t16 = $[47];
|
|
223
|
-
return t16;
|
|
83
|
+
}),
|
|
84
|
+
/* @__PURE__ */ jsxs("div", {
|
|
85
|
+
className: "flex items-center justify-between text-sm",
|
|
86
|
+
children: [/* @__PURE__ */ jsx("span", {
|
|
87
|
+
className: "text-muted-foreground tabular-nums",
|
|
88
|
+
children: data.label || `${data.current.toLocaleString()} / ${data.target.toLocaleString()}`
|
|
89
|
+
}), showPercentage && /* @__PURE__ */ jsxs("span", {
|
|
90
|
+
className: "font-medium tabular-nums",
|
|
91
|
+
children: [percentageFormatted, "%"]
|
|
92
|
+
})]
|
|
93
|
+
}),
|
|
94
|
+
data.subtitle && /* @__PURE__ */ jsx("p", {
|
|
95
|
+
className: "text-muted-foreground text-xs",
|
|
96
|
+
children: data.subtitle
|
|
97
|
+
})
|
|
98
|
+
]
|
|
99
|
+
}) : /* @__PURE__ */ jsx(WidgetEmptyState, {
|
|
100
|
+
iconName: "ph:target",
|
|
101
|
+
title: t("widget.progress.emptyTitle"),
|
|
102
|
+
description: t("widget.progress.emptyDescription")
|
|
103
|
+
});
|
|
104
|
+
return /* @__PURE__ */ jsx(WidgetCard, {
|
|
105
|
+
title,
|
|
106
|
+
description: config.description ? resolveText(config.description) : void 0,
|
|
107
|
+
icon: config.icon,
|
|
108
|
+
variant: config.cardVariant,
|
|
109
|
+
isLoading,
|
|
110
|
+
isRefreshing: isFetching && !isLoading,
|
|
111
|
+
loadingSkeleton: /* @__PURE__ */ jsx(ProgressWidgetSkeleton, {}),
|
|
112
|
+
error: error instanceof Error ? error : error ? new Error(String(error)) : null,
|
|
113
|
+
onRefresh: () => refetch(),
|
|
114
|
+
actions: config.actions,
|
|
115
|
+
className: config.className,
|
|
116
|
+
children: progressContent
|
|
117
|
+
});
|
|
224
118
|
}
|
|
225
119
|
|
|
226
120
|
//#endregion
|
|
@@ -3,7 +3,6 @@ import { cn, formatLabel } from "../../lib/utils.mjs";
|
|
|
3
3
|
import { resolveIconElement } from "../component-renderer.mjs";
|
|
4
4
|
import { WidgetCard } from "../../views/dashboard/widget-card.mjs";
|
|
5
5
|
import { WidgetEmptyState } from "./widget-empty-state.mjs";
|
|
6
|
-
import { c } from "react/compiler-runtime";
|
|
7
6
|
import { Icon } from "@iconify/react";
|
|
8
7
|
import { jsx, jsxs } from "react/jsx-runtime";
|
|
9
8
|
|
|
@@ -20,281 +19,123 @@ import { jsx, jsxs } from "react/jsx-runtime";
|
|
|
20
19
|
* Displays a list of action items with icons, matching the style
|
|
21
20
|
* of other dashboard widgets like recent-items.
|
|
22
21
|
*/
|
|
23
|
-
function QuickActionsWidget(
|
|
24
|
-
const $ = c(66);
|
|
25
|
-
const { config, basePath: t1, navigate } = t0;
|
|
26
|
-
const basePath = t1 === void 0 ? "/admin" : t1;
|
|
22
|
+
function QuickActionsWidget({ config, basePath = "/admin", navigate }) {
|
|
27
23
|
const resolveText = useResolveText();
|
|
28
24
|
const { t } = useTranslation();
|
|
29
|
-
const { layout
|
|
30
|
-
const
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
$[21] = config.title;
|
|
48
|
-
$[22] = resolveText;
|
|
49
|
-
$[23] = t;
|
|
50
|
-
$[24] = t10$1;
|
|
51
|
-
} else t10$1 = $[24];
|
|
52
|
-
const title = t10$1;
|
|
53
|
-
let t11$1;
|
|
54
|
-
if ($[25] !== basePath) {
|
|
55
|
-
t11$1 = (action, fallback) => {
|
|
56
|
-
if (!action) return fallback;
|
|
57
|
-
if (action.type === "create") return `${basePath}/collections/${action.collection}/create`;
|
|
58
|
-
if (action.type === "page") return `${basePath}/${action.pageId}`;
|
|
59
|
-
return action.href;
|
|
60
|
-
};
|
|
61
|
-
$[25] = basePath;
|
|
62
|
-
$[26] = t11$1;
|
|
63
|
-
} else t11$1 = $[26];
|
|
64
|
-
const resolveActionHref = t11$1;
|
|
65
|
-
let t12;
|
|
66
|
-
if ($[27] !== basePath || $[28] !== resolveActionHref || $[29] !== resolveText || $[30] !== t) {
|
|
67
|
-
t12 = (action_0, index) => {
|
|
68
|
-
if (typeof action_0 === "string") {
|
|
69
|
-
const [collection, actionType] = action_0.split(".");
|
|
70
|
-
return {
|
|
71
|
-
id: `${action_0}-${index}`,
|
|
72
|
-
label: actionType === "create" ? t("collection.new", { name: formatLabel(collection) }) : `${actionType} ${formatLabel(collection)}`,
|
|
73
|
-
href: `${basePath}/collections/${collection}/${actionType === "create" ? "create" : ""}`,
|
|
74
|
-
icon: void 0,
|
|
75
|
-
variant: "default"
|
|
76
|
-
};
|
|
77
|
-
}
|
|
78
|
-
const serverAction = "action" in action_0 ? action_0.action : void 0;
|
|
79
|
-
return {
|
|
80
|
-
id: `action-${index}`,
|
|
81
|
-
label: resolveText(action_0.label),
|
|
82
|
-
href: resolveActionHref(serverAction, action_0.href),
|
|
83
|
-
external: serverAction?.type === "link" ? serverAction.external : false,
|
|
84
|
-
onClick: action_0.onClick,
|
|
85
|
-
icon: action_0.icon,
|
|
86
|
-
variant: action_0.variant || "default"
|
|
87
|
-
};
|
|
88
|
-
};
|
|
89
|
-
$[27] = basePath;
|
|
90
|
-
$[28] = resolveActionHref;
|
|
91
|
-
$[29] = resolveText;
|
|
92
|
-
$[30] = t;
|
|
93
|
-
$[31] = t12;
|
|
94
|
-
} else t12 = $[31];
|
|
95
|
-
const parsedActions = quickActions.map(t12);
|
|
96
|
-
let t13;
|
|
97
|
-
if ($[32] !== navigate) {
|
|
98
|
-
t13 = (action_1) => {
|
|
99
|
-
if (action_1.onClick) action_1.onClick();
|
|
100
|
-
else if (action_1.href && action_1.external) window.open(action_1.href, "_blank", "noopener,noreferrer");
|
|
101
|
-
else if (action_1.href && navigate) navigate(action_1.href);
|
|
102
|
-
};
|
|
103
|
-
$[32] = navigate;
|
|
104
|
-
$[33] = t13;
|
|
105
|
-
} else t13 = $[33];
|
|
106
|
-
const handleClick = t13;
|
|
107
|
-
const variantStyles = {
|
|
108
|
-
default: "border-border-subtle bg-surface-low/60 hover:border-border hover:bg-surface-high cursor-pointer",
|
|
109
|
-
primary: "border-primary/30 bg-primary/10 text-foreground hover:border-primary/45 hover:bg-primary/15 [&_svg]:text-primary cursor-pointer",
|
|
110
|
-
secondary: "border-border-subtle bg-secondary/60 hover:bg-secondary cursor-pointer",
|
|
111
|
-
outline: "border-border bg-background hover:bg-muted cursor-pointer"
|
|
25
|
+
const { layout = "list" } = config;
|
|
26
|
+
const quickActions = config.quickActions ?? config.actions ?? [];
|
|
27
|
+
const title = config.title ? resolveText(config.title) : config.label ? resolveText(config.label) : t("dashboard.quickActions");
|
|
28
|
+
const resolveActionHref = (action, fallback) => {
|
|
29
|
+
if (!action) return fallback;
|
|
30
|
+
if (action.type === "create") return `${basePath}/collections/${action.collection}/create`;
|
|
31
|
+
if (action.type === "page") return `${basePath}/${action.pageId}`;
|
|
32
|
+
return action.href;
|
|
33
|
+
};
|
|
34
|
+
const parsedActions = quickActions.map((action, index) => {
|
|
35
|
+
if (typeof action === "string") {
|
|
36
|
+
const [collection, actionType] = action.split(".");
|
|
37
|
+
return {
|
|
38
|
+
id: `${action}-${index}`,
|
|
39
|
+
label: actionType === "create" ? t("collection.new", { name: formatLabel(collection) }) : `${actionType} ${formatLabel(collection)}`,
|
|
40
|
+
href: `${basePath}/collections/${collection}/${actionType === "create" ? "create" : ""}`,
|
|
41
|
+
icon: void 0,
|
|
42
|
+
variant: "default"
|
|
112
43
|
};
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
$[45] = config.className;
|
|
163
|
-
$[46] = t14;
|
|
164
|
-
$[47] = t19;
|
|
165
|
-
$[48] = title;
|
|
166
|
-
$[49] = t20;
|
|
167
|
-
} else t20 = $[49];
|
|
168
|
-
t9 = t20;
|
|
169
|
-
break bb0;
|
|
170
|
-
}
|
|
171
|
-
if (layout === "grid") {
|
|
172
|
-
let t14;
|
|
173
|
-
if ($[50] !== config.description || $[51] !== resolveText) {
|
|
174
|
-
t14 = config.description ? resolveText(config.description) : void 0;
|
|
175
|
-
$[50] = config.description;
|
|
176
|
-
$[51] = resolveText;
|
|
177
|
-
$[52] = t14;
|
|
178
|
-
} else t14 = $[52];
|
|
179
|
-
t9 = /* @__PURE__ */ jsx(WidgetCard, {
|
|
180
|
-
title,
|
|
181
|
-
description: t14,
|
|
182
|
-
variant: config.cardVariant,
|
|
183
|
-
className: config.className,
|
|
184
|
-
children: /* @__PURE__ */ jsx("div", {
|
|
185
|
-
className: "grid h-full grid-cols-2 gap-3",
|
|
186
|
-
children: parsedActions.map((action_2) => {
|
|
187
|
-
const iconElement = resolveIconElement(action_2.icon, { className: "h-4 w-4" });
|
|
188
|
-
return /* @__PURE__ */ jsxs("button", {
|
|
189
|
-
type: "button",
|
|
190
|
-
onClick: () => handleClick(action_2),
|
|
191
|
-
className: cn("flex min-h-24 flex-col items-center justify-center gap-2 rounded-md border p-3 text-center", "transition-[background-color,border-color,transform] active:scale-[0.96]", variantStyles[action_2.variant]),
|
|
192
|
-
children: [iconElement && /* @__PURE__ */ jsx("div", {
|
|
193
|
-
className: cn("flex h-9 w-9 items-center justify-center rounded-md", iconVariantStyles[action_2.variant]),
|
|
194
|
-
children: iconElement
|
|
195
|
-
}), /* @__PURE__ */ jsx("span", {
|
|
196
|
-
className: "text-xs leading-tight font-medium text-balance",
|
|
197
|
-
children: action_2.label
|
|
198
|
-
})]
|
|
199
|
-
}, action_2.id);
|
|
200
|
-
})
|
|
201
|
-
})
|
|
202
|
-
});
|
|
203
|
-
break bb0;
|
|
204
|
-
}
|
|
205
|
-
T0 = WidgetCard;
|
|
206
|
-
t5 = title;
|
|
207
|
-
if ($[53] !== config.description || $[54] !== resolveText) {
|
|
208
|
-
t6 = config.description ? resolveText(config.description) : void 0;
|
|
209
|
-
$[53] = config.description;
|
|
210
|
-
$[54] = resolveText;
|
|
211
|
-
$[55] = t6;
|
|
212
|
-
} else t6 = $[55];
|
|
213
|
-
t7 = config.cardVariant;
|
|
214
|
-
t8 = config.className;
|
|
215
|
-
t3 = "-mx-1 space-y-1";
|
|
216
|
-
t4 = parsedActions.map((action_3) => {
|
|
217
|
-
const iconElement_0 = resolveIconElement(action_3.icon, { className: "h-4 w-4" });
|
|
44
|
+
}
|
|
45
|
+
const serverAction = "action" in action ? action.action : void 0;
|
|
46
|
+
return {
|
|
47
|
+
id: `action-${index}`,
|
|
48
|
+
label: resolveText(action.label),
|
|
49
|
+
href: resolveActionHref(serverAction, action.href),
|
|
50
|
+
external: serverAction?.type === "link" ? serverAction.external : false,
|
|
51
|
+
onClick: action.onClick,
|
|
52
|
+
icon: action.icon,
|
|
53
|
+
variant: action.variant || "default"
|
|
54
|
+
};
|
|
55
|
+
});
|
|
56
|
+
const handleClick = (action) => {
|
|
57
|
+
if (action.onClick) action.onClick();
|
|
58
|
+
else if (action.href && action.external) window.open(action.href, "_blank", "noopener,noreferrer");
|
|
59
|
+
else if (action.href && navigate) navigate(action.href);
|
|
60
|
+
};
|
|
61
|
+
const variantStyles = {
|
|
62
|
+
default: "border-border-subtle bg-surface-low/60 hover:border-border hover:bg-surface-high cursor-pointer",
|
|
63
|
+
primary: "border-primary/30 bg-primary/10 text-foreground hover:border-primary/45 hover:bg-primary/15 [&_svg]:text-primary cursor-pointer",
|
|
64
|
+
secondary: "border-border-subtle bg-secondary/60 hover:bg-secondary cursor-pointer",
|
|
65
|
+
outline: "border-border bg-background hover:bg-muted cursor-pointer"
|
|
66
|
+
};
|
|
67
|
+
const iconVariantStyles = {
|
|
68
|
+
default: "bg-muted text-muted-foreground",
|
|
69
|
+
primary: "bg-primary/15 text-primary",
|
|
70
|
+
secondary: "bg-secondary text-secondary-foreground",
|
|
71
|
+
outline: "bg-background text-muted-foreground"
|
|
72
|
+
};
|
|
73
|
+
if (parsedActions.length === 0) return /* @__PURE__ */ jsx(WidgetCard, {
|
|
74
|
+
title,
|
|
75
|
+
description: config.description ? resolveText(config.description) : void 0,
|
|
76
|
+
variant: config.cardVariant,
|
|
77
|
+
className: config.className,
|
|
78
|
+
children: /* @__PURE__ */ jsx(WidgetEmptyState, {
|
|
79
|
+
iconName: "ph:lightning",
|
|
80
|
+
title: t("widget.quickActions.emptyTitle"),
|
|
81
|
+
description: t("widget.quickActions.emptyDescription")
|
|
82
|
+
})
|
|
83
|
+
});
|
|
84
|
+
if (layout === "grid") return /* @__PURE__ */ jsx(WidgetCard, {
|
|
85
|
+
title,
|
|
86
|
+
description: config.description ? resolveText(config.description) : void 0,
|
|
87
|
+
variant: config.cardVariant,
|
|
88
|
+
className: config.className,
|
|
89
|
+
children: /* @__PURE__ */ jsx("div", {
|
|
90
|
+
className: "grid h-full grid-cols-2 gap-3",
|
|
91
|
+
children: parsedActions.map((action) => {
|
|
92
|
+
const iconElement = resolveIconElement(action.icon, { className: "h-4 w-4" });
|
|
218
93
|
return /* @__PURE__ */ jsxs("button", {
|
|
219
94
|
type: "button",
|
|
220
|
-
onClick: () => handleClick(
|
|
221
|
-
className: cn("
|
|
95
|
+
onClick: () => handleClick(action),
|
|
96
|
+
className: cn("flex min-h-24 flex-col items-center justify-center gap-2 rounded-md border p-3 text-center", "transition-[background-color,border-color,transform] active:scale-[0.96]", variantStyles[action.variant]),
|
|
97
|
+
children: [iconElement && /* @__PURE__ */ jsx("div", {
|
|
98
|
+
className: cn("flex h-9 w-9 items-center justify-center rounded-md", iconVariantStyles[action.variant]),
|
|
99
|
+
children: iconElement
|
|
100
|
+
}), /* @__PURE__ */ jsx("span", {
|
|
101
|
+
className: "text-xs leading-tight font-medium text-balance",
|
|
102
|
+
children: action.label
|
|
103
|
+
})]
|
|
104
|
+
}, action.id);
|
|
105
|
+
})
|
|
106
|
+
})
|
|
107
|
+
});
|
|
108
|
+
return /* @__PURE__ */ jsx(WidgetCard, {
|
|
109
|
+
title,
|
|
110
|
+
description: config.description ? resolveText(config.description) : void 0,
|
|
111
|
+
variant: config.cardVariant,
|
|
112
|
+
className: config.className,
|
|
113
|
+
children: /* @__PURE__ */ jsx("div", {
|
|
114
|
+
className: "-mx-1 space-y-1",
|
|
115
|
+
children: parsedActions.map((action) => {
|
|
116
|
+
const iconElement = resolveIconElement(action.icon, { className: "h-4 w-4" });
|
|
117
|
+
return /* @__PURE__ */ jsxs("button", {
|
|
118
|
+
type: "button",
|
|
119
|
+
onClick: () => handleClick(action),
|
|
120
|
+
className: cn("group flex min-h-10 w-full items-center gap-3 rounded-md px-2 py-2 text-left transition-[background-color,transform] active:scale-[0.96]", variantStyles[action.variant]),
|
|
222
121
|
children: [
|
|
223
|
-
|
|
224
|
-
className: cn("flex h-8 w-8 shrink-0 items-center justify-center rounded-md", iconVariantStyles[
|
|
225
|
-
children:
|
|
122
|
+
iconElement && /* @__PURE__ */ jsx("div", {
|
|
123
|
+
className: cn("flex h-8 w-8 shrink-0 items-center justify-center rounded-md", iconVariantStyles[action.variant]),
|
|
124
|
+
children: iconElement
|
|
226
125
|
}),
|
|
227
126
|
/* @__PURE__ */ jsx("span", {
|
|
228
127
|
className: "flex-1 truncate text-sm font-medium",
|
|
229
|
-
children:
|
|
128
|
+
children: action.label
|
|
230
129
|
}),
|
|
231
130
|
/* @__PURE__ */ jsx(Icon, {
|
|
232
131
|
icon: "ph:arrow-right",
|
|
233
132
|
className: "text-muted-foreground h-4 w-4 opacity-0 transition-opacity group-hover:opacity-100"
|
|
234
133
|
})
|
|
235
134
|
]
|
|
236
|
-
},
|
|
237
|
-
})
|
|
238
|
-
}
|
|
239
|
-
|
|
240
|
-
$[1] = config.actions;
|
|
241
|
-
$[2] = config.cardVariant;
|
|
242
|
-
$[3] = config.className;
|
|
243
|
-
$[4] = config.description;
|
|
244
|
-
$[5] = config.label;
|
|
245
|
-
$[6] = config.quickActions;
|
|
246
|
-
$[7] = config.title;
|
|
247
|
-
$[8] = layout;
|
|
248
|
-
$[9] = navigate;
|
|
249
|
-
$[10] = resolveText;
|
|
250
|
-
$[11] = t;
|
|
251
|
-
$[12] = T0;
|
|
252
|
-
$[13] = t3;
|
|
253
|
-
$[14] = t4;
|
|
254
|
-
$[15] = t5;
|
|
255
|
-
$[16] = t6;
|
|
256
|
-
$[17] = t7;
|
|
257
|
-
$[18] = t8;
|
|
258
|
-
$[19] = t9;
|
|
259
|
-
} else {
|
|
260
|
-
T0 = $[12];
|
|
261
|
-
t3 = $[13];
|
|
262
|
-
t4 = $[14];
|
|
263
|
-
t5 = $[15];
|
|
264
|
-
t6 = $[16];
|
|
265
|
-
t7 = $[17];
|
|
266
|
-
t8 = $[18];
|
|
267
|
-
t9 = $[19];
|
|
268
|
-
}
|
|
269
|
-
if (t9 !== Symbol.for("react.early_return_sentinel")) return t9;
|
|
270
|
-
let t10;
|
|
271
|
-
if ($[56] !== t3 || $[57] !== t4) {
|
|
272
|
-
t10 = /* @__PURE__ */ jsx("div", {
|
|
273
|
-
className: t3,
|
|
274
|
-
children: t4
|
|
275
|
-
});
|
|
276
|
-
$[56] = t3;
|
|
277
|
-
$[57] = t4;
|
|
278
|
-
$[58] = t10;
|
|
279
|
-
} else t10 = $[58];
|
|
280
|
-
let t11;
|
|
281
|
-
if ($[59] !== T0 || $[60] !== t10 || $[61] !== t5 || $[62] !== t6 || $[63] !== t7 || $[64] !== t8) {
|
|
282
|
-
t11 = /* @__PURE__ */ jsx(T0, {
|
|
283
|
-
title: t5,
|
|
284
|
-
description: t6,
|
|
285
|
-
variant: t7,
|
|
286
|
-
className: t8,
|
|
287
|
-
children: t10
|
|
288
|
-
});
|
|
289
|
-
$[59] = T0;
|
|
290
|
-
$[60] = t10;
|
|
291
|
-
$[61] = t5;
|
|
292
|
-
$[62] = t6;
|
|
293
|
-
$[63] = t7;
|
|
294
|
-
$[64] = t8;
|
|
295
|
-
$[65] = t11;
|
|
296
|
-
} else t11 = $[65];
|
|
297
|
-
return t11;
|
|
135
|
+
}, action.id);
|
|
136
|
+
})
|
|
137
|
+
})
|
|
138
|
+
});
|
|
298
139
|
}
|
|
299
140
|
|
|
300
141
|
//#endregion
|