@questpie/admin 3.4.1 → 3.5.1
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/builder/types/action-types.d.mts +2 -2
- package/dist/client/components/actions/action-dialog.mjs +7 -7
- package/dist/client/components/blocks/block-canvas.mjs +1 -1
- package/dist/client/components/blocks/block-editor-layout.mjs +2 -2
- package/dist/client/components/blocks/block-insert-button.mjs +3 -3
- package/dist/client/components/blocks/block-item-menu.mjs +9 -9
- package/dist/client/components/blocks/block-item.mjs +5 -5
- package/dist/client/components/blocks/block-library-sidebar.mjs +3 -3
- package/dist/client/components/fields/array-field.mjs +2 -2
- package/dist/client/components/fields/date-field.mjs +6 -5
- package/dist/client/components/fields/datetime-field.mjs +6 -1
- package/dist/client/components/fields/object-array-field.mjs +2 -2
- package/dist/client/components/fields/relation/displays/cards-display.mjs +1 -1
- package/dist/client/components/fields/relation/displays/grid-display.mjs +1 -1
- package/dist/client/components/fields/relation/displays/list-display.mjs +3 -3
- package/dist/client/components/fields/relation/displays/table-display.mjs +1 -1
- package/dist/client/components/fields/relation-picker.mjs +3 -3
- package/dist/client/components/fields/relation-select.mjs +2 -2
- package/dist/client/components/filter-builder/filter-builder-sheet.mjs +16 -16
- package/dist/client/components/history-sidebar.mjs +12 -4
- package/dist/client/components/layout/field-layout-renderer.mjs +8 -3
- package/dist/client/components/media/media-grid.mjs +2 -2
- package/dist/client/components/preview/live-preview-mode.mjs +4 -4
- package/dist/client/components/preview/preview-pane.mjs +4 -4
- package/dist/client/components/primitives/asset-preview.mjs +5 -5
- package/dist/client/components/primitives/dropzone.mjs +1 -1
- package/dist/client/components/ui/kbd.mjs +1 -1
- package/dist/client/components/ui/scroll-fade.mjs +4 -4
- package/dist/client/components/ui/sidebar.mjs +1 -1
- package/dist/client/components/ui/skeleton.mjs +1 -1
- package/dist/client/components/ui/table.mjs +1 -1
- package/dist/client/components/widgets/quick-actions-widget.mjs +6 -6
- package/dist/client/components/widgets/timeline-widget.mjs +3 -3
- package/dist/client/components/widgets/value-widget.mjs +1 -1
- package/dist/client/components/widgets/widget-skeletons.mjs +2 -2
- package/dist/client/hooks/typed-hooks.mjs +66 -21
- package/dist/client/hooks/use-collection.mjs +48 -7
- package/dist/client/hooks/use-server-actions.mjs +1 -0
- package/dist/client/i18n/date-locale.mjs +0 -14
- package/dist/client/preview/diff.mjs +4 -1
- package/dist/client/preview/patch.mjs +1 -1
- package/dist/client/preview/paths.mjs +85 -0
- package/dist/client/runtime/translations-provider.mjs +1 -1
- package/dist/client/scope/picker.d.mts +2 -2
- package/dist/client/scope/provider.d.mts +2 -2
- package/dist/client/styles/base.css +51 -1
- package/dist/client/views/auth/accept-invite-form.d.mts +2 -2
- package/dist/client/views/auth/auth-layout.d.mts +3 -3
- package/dist/client/views/auth/reset-password-form.d.mts +2 -2
- package/dist/client/views/auth/setup-form.d.mts +2 -2
- package/dist/client/views/collection/auto-form-fields.mjs +1 -1
- package/dist/client/views/collection/cells/primitive-cells.mjs +2 -2
- package/dist/client/views/collection/cells/upload-cells.mjs +2 -2
- package/dist/client/views/collection/form-view.mjs +45 -26
- package/dist/client/views/collection/table-view.mjs +33 -20
- package/dist/client/views/collection/view-skeletons.mjs +37 -38
- package/dist/client/views/common/global-search.mjs +3 -3
- package/dist/client/views/dashboard/widget-card.mjs +7 -7
- package/dist/client/views/layout/admin-router.mjs +84 -37
- package/dist/client/views/layout/admin-sidebar.mjs +22 -21
- package/dist/client/views/pages/accept-invite-page.d.mts +2 -2
- package/dist/client/views/pages/dashboard-page.d.mts +2 -2
- package/dist/client/views/pages/forgot-password-page.d.mts +2 -2
- package/dist/client/views/pages/invite-page.d.mts +2 -2
- package/dist/client/views/pages/login-page.d.mts +2 -2
- package/dist/components/rich-text/rich-text-renderer.d.mts +2 -2
- package/dist/factories.d.mts +0 -2
- package/dist/server/adapters/nextjs.d.mts +0 -1
- package/dist/server/augmentation/actions.d.mts +2 -0
- package/dist/server/i18n/messages/cs.mjs +2 -0
- package/dist/server/i18n/messages/de.mjs +2 -0
- package/dist/server/i18n/messages/en.mjs +2 -0
- package/dist/server/i18n/messages/es.mjs +2 -0
- package/dist/server/i18n/messages/fr.mjs +2 -0
- package/dist/server/i18n/messages/pl.mjs +2 -0
- package/dist/server/i18n/messages/pt.mjs +2 -0
- package/dist/server/i18n/messages/sk.mjs +2 -0
- package/dist/server/modules/admin/collections/account.d.mts +50 -50
- package/dist/server/modules/admin/collections/admin-locks.d.mts +49 -49
- package/dist/server/modules/admin/collections/admin-preferences.d.mts +39 -39
- package/dist/server/modules/admin/collections/admin-saved-views.d.mts +36 -36
- 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 +14 -14
- package/dist/server/modules/admin/collections/user.mjs +9 -9
- 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/execute-action.mjs +3 -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/widget-data.d.mts +5 -5
- package/dist/server/modules/admin-preferences/collections/saved-views.d.mts +23 -23
- package/dist/server/modules/audit/.generated/module.d.mts +6 -6
- package/dist/server/modules/audit/collections/audit-log.d.mts +37 -37
- package/dist/server.d.mts +0 -2
- package/package.json +3 -3
- package/dist/server/adapters/index.d.mts +0 -2
- package/dist/server/auth-helpers.d.mts +0 -1
|
@@ -16,7 +16,7 @@ import { DashboardGrid } from "../dashboard/dashboard-grid.mjs";
|
|
|
16
16
|
import { Icon } from "@iconify/react";
|
|
17
17
|
import * as React from "react";
|
|
18
18
|
import { useQueryClient } from "@tanstack/react-query";
|
|
19
|
-
import { jsx, jsxs } from "react/jsx-runtime";
|
|
19
|
+
import { Fragment, jsx, jsxs } from "react/jsx-runtime";
|
|
20
20
|
|
|
21
21
|
//#region src/client/views/layout/admin-router.tsx
|
|
22
22
|
/**
|
|
@@ -201,16 +201,30 @@ function UnknownViewState({ viewKind, viewId }) {
|
|
|
201
201
|
*/
|
|
202
202
|
function RouterSkeleton() {
|
|
203
203
|
return /* @__PURE__ */ jsxs("div", {
|
|
204
|
-
className: "qa-router-skeleton
|
|
204
|
+
className: "qa-router-skeleton min-w-0 space-y-4",
|
|
205
|
+
"aria-busy": "true",
|
|
205
206
|
children: [
|
|
206
|
-
/* @__PURE__ */ jsx(
|
|
207
|
-
|
|
207
|
+
/* @__PURE__ */ jsx("span", {
|
|
208
|
+
className: "sr-only",
|
|
209
|
+
children: "Loading admin view"
|
|
210
|
+
}),
|
|
211
|
+
/* @__PURE__ */ jsx(AdminViewHeader, {
|
|
212
|
+
title: /* @__PURE__ */ jsx(Skeleton, {
|
|
213
|
+
variant: "text",
|
|
214
|
+
className: "h-7 w-44 max-w-full"
|
|
215
|
+
}),
|
|
216
|
+
description: /* @__PURE__ */ jsx(Skeleton, {
|
|
217
|
+
variant: "text",
|
|
218
|
+
className: "h-4 w-64 max-w-full"
|
|
219
|
+
}),
|
|
220
|
+
actions: /* @__PURE__ */ jsxs(Fragment, { children: [/* @__PURE__ */ jsx(Skeleton, { className: "size-8" }), /* @__PURE__ */ jsx(Skeleton, { className: "size-8" })] })
|
|
221
|
+
}),
|
|
208
222
|
/* @__PURE__ */ jsxs("div", {
|
|
209
|
-
className: "
|
|
223
|
+
className: "grid gap-3",
|
|
210
224
|
children: [
|
|
211
|
-
/* @__PURE__ */ jsx(Skeleton, { className: "h-
|
|
212
|
-
/* @__PURE__ */ jsx(Skeleton, { className: "h-
|
|
213
|
-
/* @__PURE__ */ jsx(Skeleton, { className: "h-
|
|
225
|
+
/* @__PURE__ */ jsx(Skeleton, { className: "h-24 w-full" }),
|
|
226
|
+
/* @__PURE__ */ jsx(Skeleton, { className: "h-24 w-full" }),
|
|
227
|
+
/* @__PURE__ */ jsx(Skeleton, { className: "h-24 w-full" })
|
|
214
228
|
]
|
|
215
229
|
})
|
|
216
230
|
]
|
|
@@ -363,7 +377,7 @@ function DefaultDashboard() {
|
|
|
363
377
|
children: /* @__PURE__ */ jsxs("div", { children: [
|
|
364
378
|
/* @__PURE__ */ jsxs("div", {
|
|
365
379
|
className: "mb-4 flex items-center gap-3",
|
|
366
|
-
children: [/* @__PURE__ */ jsx("div", { className: "bg-primary
|
|
380
|
+
children: [/* @__PURE__ */ jsx("div", { className: "bg-primary size-2 rounded-full" }), /* @__PURE__ */ jsx("h3", {
|
|
367
381
|
className: "text-muted-foreground font-chrome chrome-meta text-xs font-medium",
|
|
368
382
|
children: t("dashboard.systemStatus")
|
|
369
383
|
})]
|
|
@@ -386,7 +400,7 @@ function DefaultNotFound() {
|
|
|
386
400
|
return /* @__PURE__ */ jsxs("div", {
|
|
387
401
|
className: "qa-not-found container",
|
|
388
402
|
children: [/* @__PURE__ */ jsx("h1", {
|
|
389
|
-
className: "mb-4 text-2xl font-
|
|
403
|
+
className: "mb-4 text-2xl font-semibold",
|
|
390
404
|
children: t("error.pageNotFound")
|
|
391
405
|
}), /* @__PURE__ */ jsx("p", {
|
|
392
406
|
className: "text-muted-foreground",
|
|
@@ -402,10 +416,10 @@ function RestrictedAccess({ type, name, navigate, basePath }) {
|
|
|
402
416
|
className: "mx-auto max-w-lg p-8 text-center",
|
|
403
417
|
children: /* @__PURE__ */ jsxs("div", { children: [
|
|
404
418
|
/* @__PURE__ */ jsx("div", {
|
|
405
|
-
className: "bg-muted mx-auto mb-6 flex
|
|
419
|
+
className: "bg-muted mx-auto mb-6 flex size-16 items-center justify-center rounded-full",
|
|
406
420
|
children: /* @__PURE__ */ jsx(Icon, {
|
|
407
421
|
icon: "ph:lock-simple",
|
|
408
|
-
className: "text-muted-foreground
|
|
422
|
+
className: "text-muted-foreground size-8"
|
|
409
423
|
})
|
|
410
424
|
}),
|
|
411
425
|
/* @__PURE__ */ jsx("h1", {
|
|
@@ -424,7 +438,7 @@ function RestrictedAccess({ type, name, navigate, basePath }) {
|
|
|
424
438
|
onClick: () => navigate(basePath),
|
|
425
439
|
children: [/* @__PURE__ */ jsx(Icon, {
|
|
426
440
|
icon: "ph:arrow-left",
|
|
427
|
-
className: "
|
|
441
|
+
className: "size-4"
|
|
428
442
|
}), t("error.backToDashboard")]
|
|
429
443
|
})
|
|
430
444
|
] })
|
|
@@ -434,26 +448,35 @@ function RestrictedAccess({ type, name, navigate, basePath }) {
|
|
|
434
448
|
function LazyPageRenderer({ config }) {
|
|
435
449
|
const { t } = useTranslation();
|
|
436
450
|
const component = config.component;
|
|
437
|
-
const [
|
|
438
|
-
|
|
439
|
-
|
|
451
|
+
const [pageState, setPageState] = React.useState(() => {
|
|
452
|
+
const Component = getCachedComponent(component) ?? null;
|
|
453
|
+
return {
|
|
454
|
+
source: component,
|
|
455
|
+
Component,
|
|
456
|
+
loading: Component == null,
|
|
457
|
+
error: null
|
|
458
|
+
};
|
|
459
|
+
});
|
|
440
460
|
React.useEffect(() => {
|
|
441
461
|
let mounted = true;
|
|
442
462
|
async function load() {
|
|
443
463
|
try {
|
|
444
464
|
const cachedComponent = getCachedComponent(component);
|
|
445
465
|
if (cachedComponent) {
|
|
446
|
-
if (mounted) {
|
|
447
|
-
|
|
448
|
-
|
|
449
|
-
|
|
450
|
-
|
|
466
|
+
if (mounted) setPageState({
|
|
467
|
+
source: component,
|
|
468
|
+
Component: cachedComponent,
|
|
469
|
+
loading: false,
|
|
470
|
+
error: null
|
|
471
|
+
});
|
|
451
472
|
return;
|
|
452
473
|
}
|
|
453
|
-
if (mounted) {
|
|
454
|
-
|
|
455
|
-
|
|
456
|
-
|
|
474
|
+
if (mounted) setPageState({
|
|
475
|
+
source: component,
|
|
476
|
+
Component: null,
|
|
477
|
+
loading: true,
|
|
478
|
+
error: null
|
|
479
|
+
});
|
|
457
480
|
if (typeof component === "function") {
|
|
458
481
|
const result = component();
|
|
459
482
|
let isThenable = false;
|
|
@@ -467,21 +490,44 @@ function LazyPageRenderer({ config }) {
|
|
|
467
490
|
if (mod.default) resolved = mod.default;
|
|
468
491
|
else resolved = mod;
|
|
469
492
|
cacheComponent(component, resolved);
|
|
470
|
-
|
|
493
|
+
setPageState({
|
|
494
|
+
source: component,
|
|
495
|
+
Component: resolved,
|
|
496
|
+
loading: false,
|
|
497
|
+
error: null
|
|
498
|
+
});
|
|
471
499
|
}
|
|
472
|
-
} else if (mounted)
|
|
500
|
+
} else if (mounted) setPageState({
|
|
501
|
+
source: component,
|
|
502
|
+
Component: component,
|
|
503
|
+
loading: false,
|
|
504
|
+
error: null
|
|
505
|
+
});
|
|
473
506
|
} else if (component) {
|
|
474
|
-
if (mounted)
|
|
475
|
-
|
|
476
|
-
|
|
507
|
+
if (mounted) setPageState({
|
|
508
|
+
source: component,
|
|
509
|
+
Component: component,
|
|
510
|
+
loading: false,
|
|
511
|
+
error: null
|
|
512
|
+
});
|
|
513
|
+
} else if (mounted) setPageState({
|
|
514
|
+
source: component,
|
|
515
|
+
Component: null,
|
|
516
|
+
loading: false,
|
|
517
|
+
error: null
|
|
518
|
+
});
|
|
477
519
|
} catch (err) {
|
|
478
520
|
if (mounted) {
|
|
479
521
|
let resolvedError;
|
|
480
522
|
if (err instanceof Error) resolvedError = err;
|
|
481
523
|
else resolvedError = new Error(t("error.failedToLoad"));
|
|
482
|
-
|
|
524
|
+
setPageState({
|
|
525
|
+
source: component,
|
|
526
|
+
Component: null,
|
|
527
|
+
loading: false,
|
|
528
|
+
error: resolvedError
|
|
529
|
+
});
|
|
483
530
|
}
|
|
484
|
-
if (mounted) setLoading(false);
|
|
485
531
|
}
|
|
486
532
|
}
|
|
487
533
|
load();
|
|
@@ -489,21 +535,22 @@ function LazyPageRenderer({ config }) {
|
|
|
489
535
|
mounted = false;
|
|
490
536
|
};
|
|
491
537
|
}, [component, t]);
|
|
492
|
-
if (loading) {
|
|
538
|
+
if (!(pageState.source === component) || pageState.loading) {
|
|
493
539
|
const path = config.path?.replace(/^\//, "") ?? "";
|
|
494
540
|
return AUTH_ROUTE_SEGMENTS.has(path) ? /* @__PURE__ */ jsx(AuthPageSkeleton, {}) : /* @__PURE__ */ jsx(RouterSkeleton, {});
|
|
495
541
|
}
|
|
496
|
-
if (error) return /* @__PURE__ */ jsxs("div", {
|
|
542
|
+
if (pageState.error) return /* @__PURE__ */ jsxs("div", {
|
|
497
543
|
className: "container",
|
|
498
544
|
children: [/* @__PURE__ */ jsx("h1", {
|
|
499
|
-
className: "text-destructive mb-4 text-2xl font-
|
|
545
|
+
className: "text-destructive mb-4 text-2xl font-semibold",
|
|
500
546
|
children: t("error.unexpectedError")
|
|
501
547
|
}), /* @__PURE__ */ jsx("p", {
|
|
502
548
|
className: "text-muted-foreground",
|
|
503
|
-
children: error.message
|
|
549
|
+
children: pageState.error.message
|
|
504
550
|
})]
|
|
505
551
|
});
|
|
506
|
-
|
|
552
|
+
const PageComponent = pageState.Component;
|
|
553
|
+
return PageComponent ? /* @__PURE__ */ jsx(PageComponent, {}) : /* @__PURE__ */ jsx(DefaultNotFound, {});
|
|
507
554
|
}
|
|
508
555
|
/**
|
|
509
556
|
* AdminRouter Component
|
|
@@ -5,7 +5,7 @@ import { useSafeContentLocales } from "../../runtime/content-locales-provider.mj
|
|
|
5
5
|
import { ComponentRenderer } from "../../components/component-renderer.mjs";
|
|
6
6
|
import { Button } from "../../components/ui/button.mjs";
|
|
7
7
|
import { getFlagUrl } from "../../utils/locale-to-flag.mjs";
|
|
8
|
-
import { DropdownMenu, DropdownMenuContent, DropdownMenuItem, DropdownMenuSeparator, DropdownMenuSub, DropdownMenuSubContent, DropdownMenuSubTrigger, DropdownMenuTrigger } from "../../components/ui/dropdown-menu.mjs";
|
|
8
|
+
import { DropdownMenu, DropdownMenuContent, DropdownMenuItem, DropdownMenuLabel, DropdownMenuRadioGroup, DropdownMenuRadioItem, DropdownMenuSeparator, DropdownMenuSub, DropdownMenuSubContent, DropdownMenuSubTrigger, DropdownMenuTrigger } from "../../components/ui/dropdown-menu.mjs";
|
|
9
9
|
import { Tooltip, TooltipContent, TooltipTrigger } from "../../components/ui/tooltip.mjs";
|
|
10
10
|
import { useAdminConfig } from "../../hooks/use-admin-config.mjs";
|
|
11
11
|
import { useLazyComponent } from "../../utils/use-lazy-component.mjs";
|
|
@@ -222,7 +222,7 @@ function isRouteActive(activeRoute, itemHref, basePath, exact = false) {
|
|
|
222
222
|
/**
|
|
223
223
|
* Menu button styles - QUESTPIE design: clean, technical look
|
|
224
224
|
*/
|
|
225
|
-
const menuButtonStyles = cn("item-surface font-chrome flex w-full items-center gap-2
|
|
225
|
+
const menuButtonStyles = cn("item-surface font-chrome flex w-full items-center gap-2 p-2 text-[13px] font-medium transition-[background-color,color,border-color,transform] duration-[var(--motion-duration-base)] ease-[var(--motion-ease-standard)] active:scale-[0.96] motion-reduce:transition-none motion-reduce:active:scale-100", "text-sidebar-foreground/75 hover:bg-sidebar-accent hover:text-sidebar-foreground", "focus-visible:ring-sidebar-ring focus-visible:ring-1 focus-visible:outline-none", "group-data-[collapsible=icon]:size-8 group-data-[collapsible=icon]:justify-center group-data-[collapsible=icon]:px-2");
|
|
226
226
|
const menuButtonActiveStyles = cn("border-transparent bg-[var(--sidebar-active-background)] text-[var(--sidebar-active-foreground)]");
|
|
227
227
|
function NavItem({ item, isActive, LinkComponent, renderNavItem, useActiveProps, className, depth = 0 }) {
|
|
228
228
|
const { state, isMobile, setOpenMobile } = useSidebar();
|
|
@@ -423,7 +423,7 @@ function UserFooter({ theme = "system", setTheme, showThemeToggle }) {
|
|
|
423
423
|
const setContentLocale = useAdminStore(selectSetContentLocale);
|
|
424
424
|
const hasMultipleContentLocales = (contentLocales?.locales?.length ?? 0) > 1;
|
|
425
425
|
const shouldShowThemeToggle = !!setTheme && showThemeToggle !== false;
|
|
426
|
-
const themeOptions = [
|
|
426
|
+
const themeOptions = React.useMemo(() => [
|
|
427
427
|
{
|
|
428
428
|
value: "light",
|
|
429
429
|
label: t("ui.themeLight"),
|
|
@@ -439,7 +439,10 @@ function UserFooter({ theme = "system", setTheme, showThemeToggle }) {
|
|
|
439
439
|
label: t("ui.themeSystem"),
|
|
440
440
|
icon: "ph:monitor"
|
|
441
441
|
}
|
|
442
|
-
];
|
|
442
|
+
], [t]);
|
|
443
|
+
const handleThemeChange = React.useCallback((value) => {
|
|
444
|
+
setTheme?.(value);
|
|
445
|
+
}, [setTheme]);
|
|
443
446
|
const closeSidebarOnMobile = React.useCallback(() => {
|
|
444
447
|
if (isMobile) setOpenMobile(false);
|
|
445
448
|
}, [isMobile, setOpenMobile]);
|
|
@@ -527,23 +530,21 @@ function UserFooter({ theme = "system", setTheme, showThemeToggle }) {
|
|
|
527
530
|
className: "size-4"
|
|
528
531
|
}), t("auth.myAccount")]
|
|
529
532
|
}),
|
|
530
|
-
shouldShowThemeToggle && /* @__PURE__ */ jsxs(
|
|
531
|
-
|
|
532
|
-
children:
|
|
533
|
-
|
|
534
|
-
|
|
535
|
-
|
|
536
|
-
|
|
537
|
-
|
|
538
|
-
|
|
539
|
-
|
|
540
|
-
|
|
541
|
-
|
|
542
|
-
|
|
543
|
-
|
|
544
|
-
|
|
545
|
-
]
|
|
546
|
-
}, option.value)) })] }),
|
|
533
|
+
shouldShowThemeToggle && /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
534
|
+
/* @__PURE__ */ jsx(DropdownMenuSeparator, {}),
|
|
535
|
+
/* @__PURE__ */ jsx(DropdownMenuLabel, { children: t("ui.toggleTheme") }),
|
|
536
|
+
/* @__PURE__ */ jsx(DropdownMenuRadioGroup, {
|
|
537
|
+
value: theme,
|
|
538
|
+
onValueChange: handleThemeChange,
|
|
539
|
+
children: themeOptions.map((option) => /* @__PURE__ */ jsxs(DropdownMenuRadioItem, {
|
|
540
|
+
value: option.value,
|
|
541
|
+
children: [/* @__PURE__ */ jsx(Icon, {
|
|
542
|
+
icon: option.icon,
|
|
543
|
+
className: "size-4"
|
|
544
|
+
}), /* @__PURE__ */ jsx("span", { children: option.label })]
|
|
545
|
+
}, option.value))
|
|
546
|
+
})
|
|
547
|
+
] }),
|
|
547
548
|
hasMultipleUiLocales && /* @__PURE__ */ jsxs(DropdownMenuSub, { children: [/* @__PURE__ */ jsxs(DropdownMenuSubTrigger, { children: [/* @__PURE__ */ jsx(Icon, { icon: "ph:globe" }), t("locale.uiLanguage")] }), /* @__PURE__ */ jsx(DropdownMenuSubContent, { children: uiLocaleOptions.map((locale) => /* @__PURE__ */ jsxs(DropdownMenuItem, {
|
|
548
549
|
onClick: () => setUiLocale(locale.code),
|
|
549
550
|
children: [
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import * as React from "react";
|
|
2
|
-
import * as
|
|
2
|
+
import * as react_jsx_runtime7 from "react/jsx-runtime";
|
|
3
3
|
|
|
4
4
|
//#region src/client/views/pages/accept-invite-page.d.ts
|
|
5
5
|
|
|
@@ -61,6 +61,6 @@ declare function AcceptInvitePage({
|
|
|
61
61
|
redirectTo,
|
|
62
62
|
loginPath,
|
|
63
63
|
minPasswordLength
|
|
64
|
-
}: AcceptInvitePageProps):
|
|
64
|
+
}: AcceptInvitePageProps): react_jsx_runtime7.JSX.Element;
|
|
65
65
|
//#endregion
|
|
66
66
|
export { AcceptInvitePage };
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import * as
|
|
1
|
+
import * as react_jsx_runtime8 from "react/jsx-runtime";
|
|
2
2
|
|
|
3
3
|
//#region src/client/views/pages/dashboard-page.d.ts
|
|
4
4
|
|
|
@@ -38,6 +38,6 @@ declare function DashboardPage({
|
|
|
38
38
|
title,
|
|
39
39
|
description,
|
|
40
40
|
className
|
|
41
|
-
}: DashboardPageProps):
|
|
41
|
+
}: DashboardPageProps): react_jsx_runtime8.JSX.Element;
|
|
42
42
|
//#endregion
|
|
43
43
|
export { DashboardPage };
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import * as React from "react";
|
|
2
|
-
import * as
|
|
2
|
+
import * as react_jsx_runtime9 from "react/jsx-runtime";
|
|
3
3
|
|
|
4
4
|
//#region src/client/views/pages/forgot-password-page.d.ts
|
|
5
5
|
|
|
@@ -51,6 +51,6 @@ declare function ForgotPasswordPage({
|
|
|
51
51
|
logo,
|
|
52
52
|
loginPath,
|
|
53
53
|
resetPasswordRedirectUrl
|
|
54
|
-
}: ForgotPasswordPageProps):
|
|
54
|
+
}: ForgotPasswordPageProps): react_jsx_runtime9.JSX.Element;
|
|
55
55
|
//#endregion
|
|
56
56
|
export { ForgotPasswordPage };
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import * as React from "react";
|
|
2
|
-
import * as
|
|
2
|
+
import * as react_jsx_runtime10 from "react/jsx-runtime";
|
|
3
3
|
|
|
4
4
|
//#region src/client/views/pages/invite-page.d.ts
|
|
5
5
|
|
|
@@ -65,6 +65,6 @@ declare function InvitePage({
|
|
|
65
65
|
defaultRole,
|
|
66
66
|
showMessage,
|
|
67
67
|
onSuccess
|
|
68
|
-
}: InvitePageProps):
|
|
68
|
+
}: InvitePageProps): react_jsx_runtime10.JSX.Element;
|
|
69
69
|
//#endregion
|
|
70
70
|
export { InvitePage };
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import * as React from "react";
|
|
2
|
-
import * as
|
|
2
|
+
import * as react_jsx_runtime11 from "react/jsx-runtime";
|
|
3
3
|
|
|
4
4
|
//#region src/client/views/pages/login-page.d.ts
|
|
5
5
|
|
|
@@ -64,6 +64,6 @@ declare function LoginPage({
|
|
|
64
64
|
signUpPath,
|
|
65
65
|
showForgotPassword,
|
|
66
66
|
showSignUp
|
|
67
|
-
}: LoginPageProps):
|
|
67
|
+
}: LoginPageProps): react_jsx_runtime11.JSX.Element;
|
|
68
68
|
//#endregion
|
|
69
69
|
export { LoginPage };
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import * as
|
|
1
|
+
import * as react_jsx_runtime17 from "react/jsx-runtime";
|
|
2
2
|
|
|
3
3
|
//#region src/components/rich-text/rich-text-renderer.d.ts
|
|
4
4
|
/**
|
|
@@ -98,6 +98,6 @@ declare function RichTextRenderer({
|
|
|
98
98
|
content,
|
|
99
99
|
styles: customStyles,
|
|
100
100
|
className
|
|
101
|
-
}: RichTextRendererProps):
|
|
101
|
+
}: RichTextRendererProps): react_jsx_runtime17.JSX.Element | null;
|
|
102
102
|
//#endregion
|
|
103
103
|
export { RichTextRenderer, RichTextStyles, TipTapDoc, TipTapNode };
|
package/dist/factories.d.mts
CHANGED
|
@@ -14,8 +14,6 @@ import "./server/block/index.mjs";
|
|
|
14
14
|
import { component, editView, filterViewsByKind, listView, view } from "./server/registry-helpers.mjs";
|
|
15
15
|
import { createActionCallbackProxy, createActionProxy, createComponentCallbackProxy, createComponentProxy, createDashboardCallbackContext, createDashboardContributionProxy, createFieldProxy, createSidebarCallbackContext, createSidebarContributionProxy, createViewCallbackProxy, createViewProxy, resolveDashboardCallback, resolveSidebarCallback } from "./server/proxy-factories.mjs";
|
|
16
16
|
import { AuthSession, GetAdminSessionOptions, RequireAdminAuthOptions, getAdminSession, isAdminUser, requireAdminAuth } from "./server/modules/admin/auth-helpers.mjs";
|
|
17
|
-
import "./server/auth-helpers.mjs";
|
|
18
17
|
import { NextAuthMiddlewareOptions, createNextAuthMiddleware, getNextAdminSession } from "./server/adapters/nextjs.mjs";
|
|
19
18
|
import { BeforeLoadContext, TanStackAuthGuardOptions, createTanStackAuthGuard, createTanStackSessionLoader } from "./server/adapters/tanstack.mjs";
|
|
20
|
-
import "./server/adapters/index.mjs";
|
|
21
19
|
export { type ActionReference, type ActionsConfigContext, type AdminBlockConfig, type AdminCollectionConfig, type AdminConfigContext, type AdminConfigInput, type AdminGlobalConfig, type AdminLocaleConfig, type AdminShellRailPlacement, type AdminShellRouteRules, type AnyBlockBuilder, type AnyBlockDefinition, type AuthSession, BeforeLoadContext, BlockBuilder, type BlockBuilderState, type BlockCategoryConfig, type BlockDefinition, type BlockPrefetchContext, type BlockPrefetchFn, type BlockPrefetchWith, type BlockPrefetchWithOptions, type BlockSchema, type BlocksPrefetchContext, type BuiltinActionType, type ComponentDefinition, type ComponentFactory, type ComponentReference, type ComponentType, type ComponentTypeRegistry, type DashboardActionFactory, type DashboardActionProxy, type DashboardCallback, type DashboardCallbackContext, type DashboardConfigContext, type DashboardContribution, type DashboardItemDef, type DashboardProxy, type DashboardSectionDef, type EditViewDefinition, type EditViewFactory, type ExpandWithResult, type ExpandedRecord, type FieldLayoutItem, type FilterViewsByKind, type FormFieldLayoutItem, type FormReactiveConfig, type FormReactiveContext, type FormSectionLayout, type FormSidebarConfig, type FormTabConfig, type FormTabsLayout, type FormViewConfig, type FormViewConfigContext, type GetAdminSessionOptions, type InferBlockData, type InferBlockValues, type ListViewConfig, type ListViewConfigContext, type ListViewDefinition, type ListViewFactory, NextAuthMiddlewareOptions, type PreviewConfig, type RequireAdminAuthOptions, type ServerActionContext, type ServerActionDefinition, type ServerActionDownload, type ServerActionEffects, type ServerActionError, type ServerActionForm, type ServerActionFormField, type ServerActionHandler, type ServerActionRedirect, type ServerActionResult, type ServerActionSuccess, type ServerActionsConfig, type ServerAdminShellConfig, type ServerAdminShellRailConfig, type ServerBrandingConfig, type ServerChartWidget, type ServerCustomWidget, type ServerDashboardAction, type ServerDashboardConfig, type ServerDashboardItem, type ServerDashboardSection, type ServerDashboardTab, type ServerDashboardTabs, type ServerDashboardWidget, type ServerProgressWidget, type ServerQuickAction, type ServerQuickActionsWidget, type ServerRecentItemsWidget, type ServerSidebarCollectionItem, type ServerSidebarConfig, type ServerSidebarDividerItem, type ServerSidebarGlobalItem, type ServerSidebarItem, type ServerSidebarLinkItem, type ServerSidebarPageItem, type ServerSidebarSection, type ServerStatsWidget, type ServerTableWidget, type ServerTimelineWidget, type ServerValueWidget, type SidebarCallback, type SidebarCallbackContext, type SidebarConfigContext, type SidebarContribution, type SidebarItemDef, type SidebarProxy, type SidebarSectionDef, TanStackAuthGuardOptions, type ViewDefinition, type ViewKind, type ViewKindRegistry, type WidgetAccessRule, type WidgetFetchContext, adminConfig, block, component, createActionCallbackProxy, createActionProxy, createBlocksPrefetchHook, createComponentCallbackProxy, createComponentProxy, createDashboardCallbackContext, createDashboardContributionProxy, createFieldProxy, createNextAuthMiddleware, createSidebarCallbackContext, createSidebarContributionProxy, createTanStackAuthGuard, createTanStackSessionLoader, createViewCallbackProxy, createViewProxy, editView, filterViewsByKind, getAdminSession, getBlocksByCategory, getNextAdminSession, introspectBlock, introspectBlocks, isAdminUser, listView, processBlocksDocument, processDocumentBlocksPrefetch, requireAdminAuth, resolveDashboardCallback, resolveSidebarCallback, view };
|
|
@@ -89,6 +89,8 @@ interface ServerActionContext<TData = Record<string, unknown>> {
|
|
|
89
89
|
session?: unknown;
|
|
90
90
|
/** Current locale */
|
|
91
91
|
locale?: string;
|
|
92
|
+
/** Translation function for admin messages */
|
|
93
|
+
t: (key: string, params?: Record<string, unknown>) => string;
|
|
92
94
|
}
|
|
93
95
|
/**
|
|
94
96
|
* Action handler function type
|
|
@@ -109,6 +109,7 @@ var cs_default = {
|
|
|
109
109
|
"action.itemNotFound": "Položka nebyla nalezena",
|
|
110
110
|
"action.itemDuplicated": "Položka byla úspěšně duplikována",
|
|
111
111
|
"action.itemIdRequired.transition": "Pro akci přechodu je vyžadováno ID položky",
|
|
112
|
+
"action.itemIdRequired.resetPassword": "Pro resetování hesla je vyžadováno ID uživatele",
|
|
112
113
|
"action.targetStageRequired": "Pro akci přechodu je vyžadována cílová fáze",
|
|
113
114
|
"action.workflowUnsupported": "Workflow přechody nejsou pro tuto kolekci podporovány",
|
|
114
115
|
"action.unknownBuiltin": "Neznámá vestavěná akce: {{action}}",
|
|
@@ -301,6 +302,7 @@ var cs_default = {
|
|
|
301
302
|
"toast.error": "Chyba",
|
|
302
303
|
"toast.warning": "Varování",
|
|
303
304
|
"toast.info": "Informace",
|
|
305
|
+
"toast.processing": "Zpracovávám...",
|
|
304
306
|
"toast.saving": "Ukládání...",
|
|
305
307
|
"toast.saveFailed": "Nepodařilo se uložit změny",
|
|
306
308
|
"toast.saveSuccess": "Změny úspěšně uloženy",
|
|
@@ -107,6 +107,7 @@ var de_default = {
|
|
|
107
107
|
"action.itemNotFound": "Element nicht gefunden",
|
|
108
108
|
"action.itemDuplicated": "Element erfolgreich dupliziert",
|
|
109
109
|
"action.itemIdRequired.transition": "Element-ID ist für die Übergangsaktion erforderlich",
|
|
110
|
+
"action.itemIdRequired.resetPassword": "Benutzer-ID ist für das Zurücksetzen des Passworts erforderlich",
|
|
110
111
|
"action.targetStageRequired": "Zielstatus ist für die Übergangsaktion erforderlich",
|
|
111
112
|
"action.workflowUnsupported": "Workflow-Übergänge werden für diese Sammlung nicht unterstützt",
|
|
112
113
|
"action.unknownBuiltin": "Unbekannte integrierte Aktion: {{action}}",
|
|
@@ -299,6 +300,7 @@ var de_default = {
|
|
|
299
300
|
"toast.error": "Fehler",
|
|
300
301
|
"toast.warning": "Warnung",
|
|
301
302
|
"toast.info": "Info",
|
|
303
|
+
"toast.processing": "Wird verarbeitet...",
|
|
302
304
|
"toast.saving": "Wird gespeichert...",
|
|
303
305
|
"toast.saveFailed": "Fehler beim Speichern der Änderungen",
|
|
304
306
|
"toast.saveSuccess": "Änderungen erfolgreich gespeichert",
|
|
@@ -159,6 +159,7 @@ var en_default = {
|
|
|
159
159
|
"action.itemNotFound": "Item not found",
|
|
160
160
|
"action.itemDuplicated": "Item duplicated successfully",
|
|
161
161
|
"action.itemIdRequired.transition": "Item ID is required for transition action",
|
|
162
|
+
"action.itemIdRequired.resetPassword": "User ID is required for password reset",
|
|
162
163
|
"action.targetStageRequired": "Target stage is required for transition action",
|
|
163
164
|
"action.workflowUnsupported": "Workflow transitions are not supported for this collection",
|
|
164
165
|
"action.unknownBuiltin": "Unknown built-in action: {{action}}",
|
|
@@ -472,6 +473,7 @@ var en_default = {
|
|
|
472
473
|
"toast.error": "Error",
|
|
473
474
|
"toast.warning": "Warning",
|
|
474
475
|
"toast.info": "Info",
|
|
476
|
+
"toast.processing": "Processing...",
|
|
475
477
|
"toast.saving": "Saving...",
|
|
476
478
|
"toast.saveFailed": "Failed to save changes",
|
|
477
479
|
"toast.saveSuccess": "Changes saved successfully",
|
|
@@ -107,6 +107,7 @@ var es_default = {
|
|
|
107
107
|
"action.itemNotFound": "Elemento no encontrado",
|
|
108
108
|
"action.itemDuplicated": "Elemento duplicado correctamente",
|
|
109
109
|
"action.itemIdRequired.transition": "Se requiere el ID del elemento para la transición",
|
|
110
|
+
"action.itemIdRequired.resetPassword": "Se requiere el ID del usuario para restablecer la contraseña",
|
|
110
111
|
"action.targetStageRequired": "Se requiere la etapa de destino para la transición",
|
|
111
112
|
"action.workflowUnsupported": "Las transiciones de workflow no son compatibles con esta colección",
|
|
112
113
|
"action.unknownBuiltin": "Acción integrada desconocida: {{action}}",
|
|
@@ -299,6 +300,7 @@ var es_default = {
|
|
|
299
300
|
"toast.error": "Error",
|
|
300
301
|
"toast.warning": "Advertencia",
|
|
301
302
|
"toast.info": "Información",
|
|
303
|
+
"toast.processing": "Procesando...",
|
|
302
304
|
"toast.saving": "Guardando...",
|
|
303
305
|
"toast.saveFailed": "Error al guardar cambios",
|
|
304
306
|
"toast.saveSuccess": "Cambios guardados correctamente",
|
|
@@ -107,6 +107,7 @@ var fr_default = {
|
|
|
107
107
|
"action.itemNotFound": "Élément introuvable",
|
|
108
108
|
"action.itemDuplicated": "Élément dupliqué avec succès",
|
|
109
109
|
"action.itemIdRequired.transition": "L'ID de l'élément est requis pour l'action de transition",
|
|
110
|
+
"action.itemIdRequired.resetPassword": "L'ID de l'utilisateur est requis pour la réinitialisation du mot de passe",
|
|
110
111
|
"action.targetStageRequired": "L'étape cible est requise pour l'action de transition",
|
|
111
112
|
"action.workflowUnsupported": "Les transitions de workflow ne sont pas prises en charge pour cette collection",
|
|
112
113
|
"action.unknownBuiltin": "Action intégrée inconnue : {{action}}",
|
|
@@ -299,6 +300,7 @@ var fr_default = {
|
|
|
299
300
|
"toast.error": "Erreur",
|
|
300
301
|
"toast.warning": "Avertissement",
|
|
301
302
|
"toast.info": "Information",
|
|
303
|
+
"toast.processing": "Traitement...",
|
|
302
304
|
"toast.saving": "Enregistrement...",
|
|
303
305
|
"toast.saveFailed": "Échec de l'enregistrement des modifications",
|
|
304
306
|
"toast.saveSuccess": "Modifications enregistrées avec succès",
|
|
@@ -111,6 +111,7 @@ var pl_default = {
|
|
|
111
111
|
"action.itemNotFound": "Element nie został znaleziony",
|
|
112
112
|
"action.itemDuplicated": "Element został pomyślnie zduplikowany",
|
|
113
113
|
"action.itemIdRequired.transition": "ID elementu jest wymagane dla akcji przejścia",
|
|
114
|
+
"action.itemIdRequired.resetPassword": "ID użytkownika jest wymagane do zresetowania hasła",
|
|
114
115
|
"action.targetStageRequired": "Docelowy etap jest wymagany dla akcji przejścia",
|
|
115
116
|
"action.workflowUnsupported": "Przejścia workflow nie są obsługiwane dla tej kolekcji",
|
|
116
117
|
"action.unknownBuiltin": "Nieznana akcja wbudowana: {{action}}",
|
|
@@ -303,6 +304,7 @@ var pl_default = {
|
|
|
303
304
|
"toast.error": "Błąd",
|
|
304
305
|
"toast.warning": "Ostrzeżenie",
|
|
305
306
|
"toast.info": "Informacja",
|
|
307
|
+
"toast.processing": "Przetwarzanie...",
|
|
306
308
|
"toast.saving": "Zapisywanie...",
|
|
307
309
|
"toast.saveFailed": "Nie udało się zapisać zmian",
|
|
308
310
|
"toast.saveSuccess": "Zmiany zapisane pomyślnie",
|
|
@@ -107,6 +107,7 @@ var pt_default = {
|
|
|
107
107
|
"action.itemNotFound": "Item não encontrado",
|
|
108
108
|
"action.itemDuplicated": "Item duplicado com sucesso",
|
|
109
109
|
"action.itemIdRequired.transition": "O ID do item é obrigatório para a ação de transição",
|
|
110
|
+
"action.itemIdRequired.resetPassword": "O ID do usuário é obrigatório para a redefinição de senha",
|
|
110
111
|
"action.targetStageRequired": "O estágio de destino é obrigatório para a ação de transição",
|
|
111
112
|
"action.workflowUnsupported": "Transições de workflow não são suportadas para esta coleção",
|
|
112
113
|
"action.unknownBuiltin": "Ação integrada desconhecida: {{action}}",
|
|
@@ -299,6 +300,7 @@ var pt_default = {
|
|
|
299
300
|
"toast.error": "Erro",
|
|
300
301
|
"toast.warning": "Aviso",
|
|
301
302
|
"toast.info": "Informação",
|
|
303
|
+
"toast.processing": "Processando...",
|
|
302
304
|
"toast.saving": "Salvando...",
|
|
303
305
|
"toast.saveFailed": "Falha ao salvar alterações",
|
|
304
306
|
"toast.saveSuccess": "Alterações salvas com sucesso",
|
|
@@ -133,6 +133,7 @@ var sk_default = {
|
|
|
133
133
|
"action.itemNotFound": "Položka nebola nájdená",
|
|
134
134
|
"action.itemDuplicated": "Položka bola úspešne zduplikovaná",
|
|
135
135
|
"action.itemIdRequired.transition": "Pre akciu prechodu je povinné ID položky",
|
|
136
|
+
"action.itemIdRequired.resetPassword": "Pre resetovanie hesla je povinné ID používateľa",
|
|
136
137
|
"action.targetStageRequired": "Pre akciu prechodu je povinná cieľová fáza",
|
|
137
138
|
"action.workflowUnsupported": "Workflow prechody nie sú pre túto kolekciu podporované",
|
|
138
139
|
"action.unknownBuiltin": "Neznáma vstavaná akcia: {{action}}",
|
|
@@ -442,6 +443,7 @@ var sk_default = {
|
|
|
442
443
|
"toast.error": "Chyba",
|
|
443
444
|
"toast.warning": "Upozornenie",
|
|
444
445
|
"toast.info": "Informácia",
|
|
446
|
+
"toast.processing": "Spracovávam...",
|
|
445
447
|
"toast.saving": "Ukladám...",
|
|
446
448
|
"toast.saveFailed": "Nepodarilo sa uložiť zmeny",
|
|
447
449
|
"toast.saveSuccess": "Zmeny úspešne uložené",
|