@vendure/dashboard 3.8.1-master-202610230212 → 3.8.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/bundle/chunks/{2SSKDMRQ-CKKK4E4c.js → 2SSKDMRQ-BHHzW1a_.js} +2 -2
- package/dist/bundle/chunks/{AP7HFJJL-nqtKmI7K.js → AP7HFJJL-B5qPACUM.js} +1 -1
- package/dist/bundle/chunks/{WDYDFRGG-CN9zGdUM.js → WDYDFRGG-BfBnFCDT.js} +2 -2
- package/dist/bundle/chunks/{ar-DMK_eFVD.js → ar-ZYyYt3LW.js} +1 -1
- package/dist/bundle/chunks/{bg-_l7rTFuK.js → bg-BgDGBTKB.js} +1 -1
- package/dist/bundle/chunks/{common-operations-DNYmbej0.js → common-operations-DaHPL4es.js} +81 -23
- package/dist/bundle/chunks/{cs-DMrGo78x.js → cs-BYGURbP6.js} +1 -1
- package/dist/bundle/chunks/{de-DEE86yVt.js → de-HdkR3fYi.js} +1 -1
- package/dist/bundle/chunks/{en-Cl1y9IIy.js → en-BAhByZZJ.js} +1 -1
- package/dist/bundle/chunks/{es-BxdaHguU.js → es-Dt0C52Mq.js} +1 -1
- package/dist/bundle/chunks/{fa-DmehFzkF.js → fa-CREXA3HL.js} +1 -1
- package/dist/bundle/chunks/{fr-OT8cvTDq.js → fr-Cz8kKMli.js} +1 -1
- package/dist/bundle/chunks/{he-BKP3NS5j.js → he-9NoIAj8m.js} +1 -1
- package/dist/bundle/chunks/{hr-BYAgAid3.js → hr-BwXcr71B.js} +1 -1
- package/dist/bundle/chunks/{hu-D5RzrlfJ.js → hu-DUz4OEIA.js} +1 -1
- package/dist/bundle/chunks/{it-DjrjGb8J.js → it-CAlaDmH7.js} +1 -1
- package/dist/bundle/chunks/{ja-CHHuYFJd.js → ja-2JxS6pFi.js} +1 -1
- package/dist/bundle/chunks/{ko-CIrLMXet.js → ko-BsFLDX_m.js} +1 -1
- package/dist/bundle/chunks/{locale-DQffIWuP.js → locale-cLfB2IZc.js} +1 -1
- package/dist/bundle/chunks/{main-CrFObvKu.js → main-MGWdQzqd.js} +3 -3
- package/dist/bundle/chunks/{nb-CBS2CxWA.js → nb-Dff7oHih.js} +1 -1
- package/dist/bundle/chunks/{ne-BKFoZX0n.js → ne-ByGdZmfQ.js} +1 -1
- package/dist/bundle/chunks/{nl-CioNp_N5.js → nl-DniFiVio.js} +1 -1
- package/dist/bundle/chunks/{pl-ChqS0pNw.js → pl-B5DHommF.js} +1 -1
- package/dist/bundle/chunks/{pt_BR-8wz_k8Ib.js → pt_BR-BAq7WTWG.js} +1 -1
- package/dist/bundle/chunks/{pt_PT-BsddGCVI.js → pt_PT-DL7eSU8R.js} +1 -1
- package/dist/bundle/chunks/{ro-DLZ4JjP9.js → ro-CGYxDEv8.js} +1 -1
- package/dist/bundle/chunks/{ru-CDB-oX6Y.js → ru-BduayFrD.js} +1 -1
- package/dist/bundle/chunks/{sv-C05330I8.js → sv-E3RLr9cy.js} +1 -1
- package/dist/bundle/chunks/{tr-BmdyAxJM.js → tr-pMuzyLjn.js} +1 -1
- package/dist/bundle/chunks/{uk-UHmyTWD9.js → uk-BFfpHemj.js} +1 -1
- package/dist/bundle/chunks/{uz-BPv1mncF.js → uz-DBzLLOoE.js} +1 -1
- package/dist/bundle/chunks/{zh_Hans-DYtmTSvd.js → zh_Hans-DDD5yH27.js} +1 -1
- package/dist/bundle/chunks/{zh_Hant-CdyREtHJ.js → zh_Hant-B9iOWieA.js} +1 -1
- package/dist/bundle/lib.js +2 -2
- package/dist/bundle/main.js +2 -2
- package/dist/vite/vite-plugin-config.js +28 -1
- package/dist/vite/vite-plugin-dashboard-metadata.js +47 -15
- package/package.json +3 -3
- package/src/i18n/locales/ar.po +4 -0
- package/src/i18n/locales/bg.po +4 -0
- package/src/i18n/locales/cs.po +4 -0
- package/src/i18n/locales/de.po +4 -0
- package/src/i18n/locales/en.po +4 -0
- package/src/i18n/locales/es.po +4 -0
- package/src/i18n/locales/fa.po +4 -0
- package/src/i18n/locales/fr.po +4 -0
- package/src/i18n/locales/he.po +4 -0
- package/src/i18n/locales/hr.po +4 -0
- package/src/i18n/locales/hu.po +4 -0
- package/src/i18n/locales/it.po +4 -0
- package/src/i18n/locales/ja.po +4 -0
- package/src/i18n/locales/ko.po +4 -0
- package/src/i18n/locales/nb.po +4 -0
- package/src/i18n/locales/ne.po +4 -0
- package/src/i18n/locales/nl.po +4 -0
- package/src/i18n/locales/pl.po +4 -0
- package/src/i18n/locales/pt_BR.po +4 -0
- package/src/i18n/locales/pt_PT.po +4 -0
- package/src/i18n/locales/ro.po +4 -0
- package/src/i18n/locales/ru.po +4 -0
- package/src/i18n/locales/sv.po +4 -0
- package/src/i18n/locales/tr.po +4 -0
- package/src/i18n/locales/uk.po +4 -0
- package/src/i18n/locales/uz.po +4 -0
- package/src/i18n/locales/zh_Hans.po +4 -0
- package/src/i18n/locales/zh_Hant.po +4 -0
- package/src/lib/components/shared/error-page.tsx +2 -2
- package/src/lib/components/shared/paginated-list-data-table.spec.tsx +151 -0
- package/src/lib/components/shared/paginated-list-data-table.tsx +11 -2
- package/src/lib/constants.ts +1 -0
- package/src/lib/providers/auth.tsx +75 -7
- package/src/lib/providers/server-config.tsx +3 -2
- package/src/lib/providers/user-settings.spec.tsx +191 -0
- package/src/lib/providers/user-settings.tsx +30 -14
- package/src/lib/storage-keys.ts +3 -1
- package/src/lib/utils/is-forbidden-error.ts +9 -0
|
@@ -4692,12 +4692,17 @@ const LS_KEY_USER_SETTINGS = "vendure-user-settings";
|
|
|
4692
4692
|
const LS_KEY_SELECTED_CHANNEL_TOKEN = "vendure-selected-channel-token";
|
|
4693
4693
|
const LS_KEY_SHIPPING_TEST_ORDER = "vendure-shipping-test-order";
|
|
4694
4694
|
const LS_KEY_SHIPPING_TEST_ADDRESS = "vendure-shipping-test-address";
|
|
4695
|
+
const SETTINGS_STORE_KEY_USER_SETTINGS = "vendure.dashboard.userSettings";
|
|
4695
4696
|
const NEW_ENTITY_PATH = "new";
|
|
4696
4697
|
const AUTHENTICATED_ROUTE_PREFIX = "/_authenticated";
|
|
4697
4698
|
const DEFAULT_CHANNEL_CODE = "__default_channel__";
|
|
4698
4699
|
const SUPER_ADMIN_ROLE_CODE = "__super_admin_role__";
|
|
4699
4700
|
const CUSTOMER_ROLE_CODE = "__customer_role__";
|
|
4700
4701
|
const CurrencyCode = Object.fromEntries(schemaCurrencyCodes.map((code) => [code, code]));
|
|
4702
|
+
function isForbiddenError(error2) {
|
|
4703
|
+
const code = error2?.extensions?.code;
|
|
4704
|
+
return code === "FORBIDDEN" || code === "UNAUTHORIZED";
|
|
4705
|
+
}
|
|
4701
4706
|
var GraphQLRequestError = class extends Error {
|
|
4702
4707
|
query;
|
|
4703
4708
|
variables;
|
|
@@ -9382,7 +9387,6 @@ const defaultSettings = {
|
|
|
9382
9387
|
tableSettings: {}
|
|
9383
9388
|
};
|
|
9384
9389
|
const UserSettingsContext = createContext(void 0);
|
|
9385
|
-
const SETTINGS_STORE_KEY = "vendure.dashboard.userSettings";
|
|
9386
9390
|
const UserSettingsProvider = ({
|
|
9387
9391
|
queryClient,
|
|
9388
9392
|
children
|
|
@@ -9415,16 +9419,16 @@ const UserSettingsProvider = ({
|
|
|
9415
9419
|
isError: serverSettingsErrored,
|
|
9416
9420
|
error: error2
|
|
9417
9421
|
} = useQuery({
|
|
9418
|
-
queryKey: ["user-settings",
|
|
9422
|
+
queryKey: ["user-settings", SETTINGS_STORE_KEY_USER_SETTINGS],
|
|
9419
9423
|
queryFn: () => api.query(getSettingsStoreValueDocument, {
|
|
9420
|
-
key:
|
|
9424
|
+
key: SETTINGS_STORE_KEY_USER_SETTINGS
|
|
9421
9425
|
}),
|
|
9422
9426
|
retry: false,
|
|
9423
9427
|
staleTime: 0,
|
|
9424
9428
|
enabled: settingsStoreIsAvailable
|
|
9425
9429
|
});
|
|
9426
9430
|
useEffect(() => {
|
|
9427
|
-
if (settingsStoreIsAvailable && error2?.message.includes(
|
|
9431
|
+
if (settingsStoreIsAvailable && error2?.message.includes(`Settings store field not registered: ${SETTINGS_STORE_KEY_USER_SETTINGS}`)) {
|
|
9428
9432
|
logSettingsStoreWarning();
|
|
9429
9433
|
setSettingsStoreIsAvailable(false);
|
|
9430
9434
|
}
|
|
@@ -9432,7 +9436,7 @@ const UserSettingsProvider = ({
|
|
|
9432
9436
|
const saveToServerMutation = useMutation({
|
|
9433
9437
|
mutationFn: (settingsToSave) => api.mutate(setSettingsStoreValueDocument, {
|
|
9434
9438
|
input: {
|
|
9435
|
-
key:
|
|
9439
|
+
key: SETTINGS_STORE_KEY_USER_SETTINGS,
|
|
9436
9440
|
value: settingsToSave
|
|
9437
9441
|
}
|
|
9438
9442
|
}),
|
|
@@ -9446,7 +9450,7 @@ const UserSettingsProvider = ({
|
|
|
9446
9450
|
}
|
|
9447
9451
|
});
|
|
9448
9452
|
useEffect(() => {
|
|
9449
|
-
if (
|
|
9453
|
+
if (serverSettings) {
|
|
9450
9454
|
return;
|
|
9451
9455
|
}
|
|
9452
9456
|
if (serverSettingsLoaded) {
|
|
@@ -9469,11 +9473,12 @@ const UserSettingsProvider = ({
|
|
|
9469
9473
|
setServerSettings(settings);
|
|
9470
9474
|
setIsReady(true);
|
|
9471
9475
|
}
|
|
9472
|
-
|
|
9473
|
-
|
|
9476
|
+
return;
|
|
9477
|
+
}
|
|
9478
|
+
if (serverSettingsErrored && !isForbiddenError(error2)) {
|
|
9474
9479
|
setIsReady(true);
|
|
9475
9480
|
}
|
|
9476
|
-
}, [serverSettingsLoaded, serverSettingsErrored, serverSettingsResponse, settings
|
|
9481
|
+
}, [serverSettings, serverSettingsLoaded, serverSettingsErrored, error2, serverSettingsResponse, settings]);
|
|
9477
9482
|
useEffect(() => {
|
|
9478
9483
|
try {
|
|
9479
9484
|
localStorage.setItem(LS_KEY_USER_SETTINGS, JSON.stringify(settings));
|
|
@@ -40822,7 +40827,7 @@ function useDayPickerLocale() {
|
|
|
40822
40827
|
} = useDisplayLocale();
|
|
40823
40828
|
const [calendarLocale, setCalendarLocale] = useState(void 0);
|
|
40824
40829
|
useEffect(() => {
|
|
40825
|
-
import("./locale-
|
|
40830
|
+
import("./locale-cLfB2IZc.js").then((mod) => {
|
|
40826
40831
|
setCalendarLocale(bcpTagToDatePickerLocale(bcp47Tag, mod));
|
|
40827
40832
|
});
|
|
40828
40833
|
}, [bcp47Tag]);
|
|
@@ -41361,6 +41366,9 @@ const CurrentUserQuery = graphql(`
|
|
|
41361
41366
|
}
|
|
41362
41367
|
}
|
|
41363
41368
|
`);
|
|
41369
|
+
function hasDashboardAccess(currentUser) {
|
|
41370
|
+
return !!currentUser?.me?.channels.length;
|
|
41371
|
+
}
|
|
41364
41372
|
const CurrentAdministratorAvatarQuery = `
|
|
41365
41373
|
query CurrentAdministratorAvatar {
|
|
41366
41374
|
activeAdministrator {
|
|
@@ -41385,6 +41393,15 @@ function AuthProvider({
|
|
|
41385
41393
|
setActiveChannelId
|
|
41386
41394
|
} = useUserSettings();
|
|
41387
41395
|
const queryClient = useQueryClient();
|
|
41396
|
+
const {
|
|
41397
|
+
_: _t
|
|
41398
|
+
} = useLingui();
|
|
41399
|
+
const noChannelAccessError = _t(
|
|
41400
|
+
/*i18n*/
|
|
41401
|
+
{
|
|
41402
|
+
id: "z5xMBB"
|
|
41403
|
+
}
|
|
41404
|
+
);
|
|
41388
41405
|
const {
|
|
41389
41406
|
data: currentUserData,
|
|
41390
41407
|
isLoading,
|
|
@@ -41406,7 +41423,7 @@ function AuthProvider({
|
|
|
41406
41423
|
setActiveChannelId(currentUserData.me.channels[0].id);
|
|
41407
41424
|
}
|
|
41408
41425
|
}, [settings.activeChannelId, currentUserData?.me?.channels]);
|
|
41409
|
-
const isAuthenticated =
|
|
41426
|
+
const isAuthenticated = hasDashboardAccess(currentUserData);
|
|
41410
41427
|
const {
|
|
41411
41428
|
data: avatarData
|
|
41412
41429
|
} = useQuery({
|
|
@@ -41416,6 +41433,19 @@ function AuthProvider({
|
|
|
41416
41433
|
enabled: isAuthenticated,
|
|
41417
41434
|
staleTime: Infinity
|
|
41418
41435
|
});
|
|
41436
|
+
const endSessionWithoutChannelAccess = React.useCallback(async () => {
|
|
41437
|
+
setIsLoginLogoutInProgress(true);
|
|
41438
|
+
try {
|
|
41439
|
+
await api.mutate(LogOutMutation)({});
|
|
41440
|
+
} catch {
|
|
41441
|
+
}
|
|
41442
|
+
queryClient.removeQueries({
|
|
41443
|
+
queryKey: ["currentUser"]
|
|
41444
|
+
});
|
|
41445
|
+
setAuthenticationError(noChannelAccessError);
|
|
41446
|
+
setStatus("unauthenticated");
|
|
41447
|
+
setIsLoginLogoutInProgress(false);
|
|
41448
|
+
}, [queryClient, noChannelAccessError]);
|
|
41419
41449
|
const login = React.useCallback((username, password, onLoginSuccess) => {
|
|
41420
41450
|
setIsLoginLogoutInProgress(true);
|
|
41421
41451
|
setStatus("verifying");
|
|
@@ -41426,8 +41456,13 @@ function AuthProvider({
|
|
|
41426
41456
|
if (data.login.__typename === "CurrentUser") {
|
|
41427
41457
|
setAuthenticationError(void 0);
|
|
41428
41458
|
const {
|
|
41429
|
-
data: refetchedData
|
|
41459
|
+
data: refetchedData,
|
|
41460
|
+
error: refetchError
|
|
41430
41461
|
} = await refetchCurrentUser();
|
|
41462
|
+
if (!refetchError && !hasDashboardAccess(refetchedData)) {
|
|
41463
|
+
await endSessionWithoutChannelAccess();
|
|
41464
|
+
return;
|
|
41465
|
+
}
|
|
41431
41466
|
if (refetchedData?.me?.channels?.length) {
|
|
41432
41467
|
const previousChannel = settings.activeChannelId ? refetchedData.me.channels.find((c2) => c2.id === settings.activeChannelId) : void 0;
|
|
41433
41468
|
const channel = previousChannel ?? refetchedData.me.channels[0];
|
|
@@ -41440,6 +41475,17 @@ function AuthProvider({
|
|
|
41440
41475
|
}
|
|
41441
41476
|
await queryClient.cancelQueries();
|
|
41442
41477
|
await queryClient.invalidateQueries();
|
|
41478
|
+
const currentUserState = queryClient.getQueryState(["currentUser"]);
|
|
41479
|
+
if (currentUserState?.status === "success" && !hasDashboardAccess(currentUserState.data)) {
|
|
41480
|
+
await endSessionWithoutChannelAccess();
|
|
41481
|
+
return;
|
|
41482
|
+
}
|
|
41483
|
+
if (!hasDashboardAccess(currentUserState?.data)) {
|
|
41484
|
+
setAuthenticationError(currentUserState?.error?.message);
|
|
41485
|
+
setStatus("unauthenticated");
|
|
41486
|
+
setIsLoginLogoutInProgress(false);
|
|
41487
|
+
return;
|
|
41488
|
+
}
|
|
41443
41489
|
setStatus("authenticated");
|
|
41444
41490
|
setIsLoginLogoutInProgress(false);
|
|
41445
41491
|
onLoginSuccess?.();
|
|
@@ -41453,7 +41499,7 @@ function AuthProvider({
|
|
|
41453
41499
|
setStatus("unauthenticated");
|
|
41454
41500
|
setIsLoginLogoutInProgress(false);
|
|
41455
41501
|
});
|
|
41456
|
-
}, [refetchCurrentUser, queryClient, settings.activeChannelId, setActiveChannelId]);
|
|
41502
|
+
}, [refetchCurrentUser, queryClient, settings.activeChannelId, setActiveChannelId, endSessionWithoutChannelAccess]);
|
|
41457
41503
|
const logout = React.useCallback(async (onLogoutSuccess) => {
|
|
41458
41504
|
setAuthenticationError(void 0);
|
|
41459
41505
|
setIsLoginLogoutInProgress(true);
|
|
@@ -41467,7 +41513,7 @@ function AuthProvider({
|
|
|
41467
41513
|
data: refreshedData,
|
|
41468
41514
|
error: refreshedError
|
|
41469
41515
|
} = await refetchCurrentUser();
|
|
41470
|
-
if (refreshedError || !refreshedData
|
|
41516
|
+
if (refreshedError || !hasDashboardAccess(refreshedData)) {
|
|
41471
41517
|
setStatus("unauthenticated");
|
|
41472
41518
|
} else {
|
|
41473
41519
|
setStatus("authenticated");
|
|
@@ -41498,13 +41544,15 @@ function AuthProvider({
|
|
|
41498
41544
|
return;
|
|
41499
41545
|
}
|
|
41500
41546
|
if (!isLoading && status === "verifying") {
|
|
41501
|
-
if (currentUserError
|
|
41547
|
+
if (!currentUserError && currentUserData?.me?.id && !isAuthenticated) {
|
|
41548
|
+
void endSessionWithoutChannelAccess();
|
|
41549
|
+
} else if (currentUserError || !isAuthenticated) {
|
|
41502
41550
|
setStatus("unauthenticated");
|
|
41503
41551
|
} else {
|
|
41504
41552
|
setStatus("authenticated");
|
|
41505
41553
|
}
|
|
41506
41554
|
}
|
|
41507
|
-
}, [isLoading, currentUserData, currentUserError, status, isLoginLogoutInProgress]);
|
|
41555
|
+
}, [isLoading, currentUserData, currentUserError, isAuthenticated, status, isLoginLogoutInProgress, endSessionWithoutChannelAccess]);
|
|
41508
41556
|
const refreshCurrentUser = () => {
|
|
41509
41557
|
queryClient.invalidateQueries({
|
|
41510
41558
|
queryKey: ["currentUser"]
|
|
@@ -41728,7 +41776,8 @@ const ServerConfigProvider = ({
|
|
|
41728
41776
|
children
|
|
41729
41777
|
}) => {
|
|
41730
41778
|
const {
|
|
41731
|
-
user
|
|
41779
|
+
user,
|
|
41780
|
+
isAuthenticated
|
|
41732
41781
|
} = useAuth();
|
|
41733
41782
|
const queryKey2 = ["getServerConfig", user?.id];
|
|
41734
41783
|
const {
|
|
@@ -41737,7 +41786,8 @@ const ServerConfigProvider = ({
|
|
|
41737
41786
|
queryKey: queryKey2,
|
|
41738
41787
|
queryFn: () => api.query(getServerConfigDocument),
|
|
41739
41788
|
retry: false,
|
|
41740
|
-
|
|
41789
|
+
// Like the Channel queries, the server config needs access to a Channel. See #5617
|
|
41790
|
+
enabled: isAuthenticated,
|
|
41741
41791
|
// The server config rarely changes during a session (it's driven by
|
|
41742
41792
|
// VendureConfig at boot time). Treat it as session-stable so we don't
|
|
41743
41793
|
// re-fetch on every reconnect, which would cause flashes of empty
|
|
@@ -94780,7 +94830,16 @@ function PaginatedListDataTable({
|
|
|
94780
94830
|
includeSelectionColumn
|
|
94781
94831
|
});
|
|
94782
94832
|
const columnVisibility = getColumnVisibility(columns, defaultColumnVisibility, customFieldColumnNames);
|
|
94783
|
-
const
|
|
94833
|
+
const [liveColumnVisibility, setLiveColumnVisibility] = React__default.useState();
|
|
94834
|
+
const handleColumnVisibilityChange = (table, visibility) => {
|
|
94835
|
+
setLiveColumnVisibility(visibility);
|
|
94836
|
+
onColumnVisibilityChange?.(table, visibility);
|
|
94837
|
+
};
|
|
94838
|
+
const effectiveColumnVisibility = {
|
|
94839
|
+
...columnVisibility,
|
|
94840
|
+
...liveColumnVisibility
|
|
94841
|
+
};
|
|
94842
|
+
const visibleColumns = columns.filter((c2) => effectiveColumnVisibility[c2.id] !== false || c2.id === "id").map((c2) => ({
|
|
94784
94843
|
name: c2.id,
|
|
94785
94844
|
isCustomField: c2.meta?.isCustomField ?? false,
|
|
94786
94845
|
dependencies: c2.meta?.dependencies ?? []
|
|
@@ -94840,7 +94899,7 @@ function PaginatedListDataTable({
|
|
|
94840
94899
|
}, children: isError && errorState ? errorState({
|
|
94841
94900
|
error: error2,
|
|
94842
94901
|
retry: () => refetch()
|
|
94843
|
-
}) : /* @__PURE__ */ jsx(DataTable, { columns, data: transformedData, isLoading: isFetching, page, itemsPerPage, sorting, columnFilters, totalItems: listData?.totalItems ?? 0, onPageChange, onSortChange, onFilterChange, onColumnVisibilityChange, onSearchTermChange: onSearchTermChange ? (term) => setSearchTerm(term) : void 0, searchPlaceholder, defaultColumnVisibility: columnVisibility, facetedFilters, disableViewOptions, enableViews, bulkActions, selectedItems, onSelectionChange, setTableOptions, onRefresh: refetchPaginatedList, onReorder, disableDragAndDrop, emptyStateAction, emptyStateIllustration, title, actions, frame: frame2 }) });
|
|
94902
|
+
}) : /* @__PURE__ */ jsx(DataTable, { columns, data: transformedData, isLoading: isFetching, page, itemsPerPage, sorting, columnFilters, totalItems: listData?.totalItems ?? 0, onPageChange, onSortChange, onFilterChange, onColumnVisibilityChange: handleColumnVisibilityChange, onSearchTermChange: onSearchTermChange ? (term) => setSearchTerm(term) : void 0, searchPlaceholder, defaultColumnVisibility: columnVisibility, facetedFilters, disableViewOptions, enableViews, bulkActions, selectedItems, onSelectionChange, setTableOptions, onRefresh: refetchPaginatedList, onReorder, disableDragAndDrop, emptyStateAction, emptyStateIllustration, title, actions, frame: frame2 }) });
|
|
94844
94903
|
}
|
|
94845
94904
|
function Pagination({ className, ...props }) {
|
|
94846
94905
|
return /* @__PURE__ */ jsx(
|
|
@@ -115574,7 +115633,7 @@ function useSortedLanguages(availableLanguages) {
|
|
|
115574
115633
|
label: formatLanguageName(code)
|
|
115575
115634
|
})).sort((a2, b2) => a2.label.localeCompare(b2.label)), [availableLanguages, formatLanguageName]);
|
|
115576
115635
|
}
|
|
115577
|
-
const localeMessages = /* @__PURE__ */ Object.assign({ "../../i18n/locales/ar.po": () => import("./ar-
|
|
115636
|
+
const localeMessages = /* @__PURE__ */ Object.assign({ "../../i18n/locales/ar.po": () => import("./ar-ZYyYt3LW.js"), "../../i18n/locales/bg.po": () => import("./bg-BgDGBTKB.js"), "../../i18n/locales/cs.po": () => import("./cs-BYGURbP6.js"), "../../i18n/locales/de.po": () => import("./de-HdkR3fYi.js"), "../../i18n/locales/en.po": () => import("./en-BAhByZZJ.js"), "../../i18n/locales/es.po": () => import("./es-Dt0C52Mq.js"), "../../i18n/locales/fa.po": () => import("./fa-CREXA3HL.js"), "../../i18n/locales/fr.po": () => import("./fr-Cz8kKMli.js"), "../../i18n/locales/he.po": () => import("./he-9NoIAj8m.js"), "../../i18n/locales/hr.po": () => import("./hr-BwXcr71B.js"), "../../i18n/locales/hu.po": () => import("./hu-DUz4OEIA.js"), "../../i18n/locales/it.po": () => import("./it-CAlaDmH7.js"), "../../i18n/locales/ja.po": () => import("./ja-2JxS6pFi.js"), "../../i18n/locales/ko.po": () => import("./ko-BsFLDX_m.js"), "../../i18n/locales/nb.po": () => import("./nb-Dff7oHih.js"), "../../i18n/locales/ne.po": () => import("./ne-ByGdZmfQ.js"), "../../i18n/locales/nl.po": () => import("./nl-DniFiVio.js"), "../../i18n/locales/pl.po": () => import("./pl-B5DHommF.js"), "../../i18n/locales/pt_BR.po": () => import("./pt_BR-BAq7WTWG.js"), "../../i18n/locales/pt_PT.po": () => import("./pt_PT-DL7eSU8R.js"), "../../i18n/locales/ro.po": () => import("./ro-CGYxDEv8.js"), "../../i18n/locales/ru.po": () => import("./ru-BduayFrD.js"), "../../i18n/locales/sv.po": () => import("./sv-E3RLr9cy.js"), "../../i18n/locales/tr.po": () => import("./tr-pMuzyLjn.js"), "../../i18n/locales/uk.po": () => import("./uk-BFfpHemj.js"), "../../i18n/locales/uz.po": () => import("./uz-DBzLLOoE.js"), "../../i18n/locales/zh_Hans.po": () => import("./zh_Hans-DDD5yH27.js"), "../../i18n/locales/zh_Hant.po": () => import("./zh_Hant-B9iOWieA.js") });
|
|
115578
115637
|
async function loadI18nMessages(locale2) {
|
|
115579
115638
|
const loader = localeMessages[`../../i18n/locales/${locale2}.po`];
|
|
115580
115639
|
if (!loader) {
|
|
@@ -120808,8 +120867,7 @@ function getErrorKind(error2) {
|
|
|
120808
120867
|
if (error2 instanceof NotFoundError) {
|
|
120809
120868
|
return "not-found";
|
|
120810
120869
|
}
|
|
120811
|
-
|
|
120812
|
-
if (code === "FORBIDDEN" || code === "UNAUTHORIZED") {
|
|
120870
|
+
if (isForbiddenError(error2)) {
|
|
120813
120871
|
return "forbidden";
|
|
120814
120872
|
}
|
|
120815
120873
|
const status = error2?.response?.status;
|