@emdash-cms/admin 0.35.0 → 0.36.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{LocaleDirectionProvider-CnKC3o_O.js → LocaleDirectionProvider-BjVpQpBl.js} +29 -29
- package/dist/{LocaleDirectionProvider-CnKC3o_O.js.map → LocaleDirectionProvider-BjVpQpBl.js.map} +1 -1
- package/dist/index.d.ts +144 -10
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +6698 -2464
- package/dist/index.js.map +1 -1
- package/dist/locales/ar/messages.mjs +1 -1
- package/dist/locales/ca/messages.mjs +1 -1
- package/dist/locales/cs/messages.mjs +1 -1
- package/dist/locales/de/messages.mjs +1 -1
- package/dist/locales/en/messages.mjs +1 -1
- package/dist/locales/en-GB/messages.mjs +1 -1
- package/dist/locales/es-419/messages.mjs +1 -1
- package/dist/locales/es-ES/messages.mjs +1 -1
- package/dist/locales/eu/messages.mjs +1 -1
- package/dist/locales/fa/messages.mjs +1 -1
- package/dist/locales/fr/messages.mjs +1 -1
- package/dist/locales/hi/messages.mjs +1 -1
- package/dist/locales/hu/messages.mjs +1 -1
- package/dist/locales/id/messages.mjs +1 -1
- package/dist/locales/index.js +1 -1
- package/dist/locales/ja/messages.mjs +1 -1
- package/dist/locales/ko/messages.mjs +1 -1
- package/dist/locales/nb/messages.mjs +1 -1
- package/dist/locales/nl/messages.mjs +1 -1
- package/dist/locales/pl/messages.mjs +1 -1
- package/dist/locales/pseudo/messages.mjs +1 -1
- package/dist/locales/pt-BR/messages.mjs +1 -1
- package/dist/locales/sr-Latn/messages.mjs +1 -1
- package/dist/locales/sv/messages.mjs +1 -1
- package/dist/locales/th/messages.mjs +1 -1
- package/dist/locales/tr/messages.mjs +1 -1
- package/dist/locales/uk/messages.mjs +1 -1
- package/dist/locales/zh-CN/messages.mjs +1 -1
- package/dist/locales/zh-TW/messages.mjs +1 -1
- package/dist/messages-3FU8zCct.js +6 -0
- package/dist/messages-3FU8zCct.js.map +1 -0
- package/dist/messages-9k1iDJF6.js +6 -0
- package/dist/messages-9k1iDJF6.js.map +1 -0
- package/dist/messages-B3Q7NUrK.js +6 -0
- package/dist/messages-B3Q7NUrK.js.map +1 -0
- package/dist/messages-BKjrWDoV.js +6 -0
- package/dist/messages-BKjrWDoV.js.map +1 -0
- package/dist/messages-BLxOqfxi.js +6 -0
- package/dist/messages-BLxOqfxi.js.map +1 -0
- package/dist/messages-BUkvBAQ_.js +6 -0
- package/dist/messages-BUkvBAQ_.js.map +1 -0
- package/dist/messages-BYPUIPvx.js +6 -0
- package/dist/messages-BYPUIPvx.js.map +1 -0
- package/dist/messages-BYaDnRZi.js +6 -0
- package/dist/messages-BYaDnRZi.js.map +1 -0
- package/dist/messages-C-omjoCi.js +6 -0
- package/dist/messages-C-omjoCi.js.map +1 -0
- package/dist/messages-CA8gfGRN.js +6 -0
- package/dist/messages-CA8gfGRN.js.map +1 -0
- package/dist/messages-CKCmO_US.js +6 -0
- package/dist/messages-CKCmO_US.js.map +1 -0
- package/dist/messages-CKtyiPlE.js +6 -0
- package/dist/messages-CKtyiPlE.js.map +1 -0
- package/dist/messages-CMlXT2mo.js +6 -0
- package/dist/messages-CMlXT2mo.js.map +1 -0
- package/dist/messages-CSzVxyoV.js +6 -0
- package/dist/messages-CSzVxyoV.js.map +1 -0
- package/dist/messages-CUVVH-l2.js +6 -0
- package/dist/messages-CUVVH-l2.js.map +1 -0
- package/dist/messages-CXBqJPo6.js +6 -0
- package/dist/messages-CXBqJPo6.js.map +1 -0
- package/dist/messages-Cb_WSNlm.js +6 -0
- package/dist/messages-Cb_WSNlm.js.map +1 -0
- package/dist/messages-CiFlbS-H.js +6 -0
- package/dist/messages-CiFlbS-H.js.map +1 -0
- package/dist/messages-CkVoAW1_.js +6 -0
- package/dist/messages-CkVoAW1_.js.map +1 -0
- package/dist/messages-DKYRxT68.js +6 -0
- package/dist/messages-DKYRxT68.js.map +1 -0
- package/dist/messages-DZiI-npH.js +6 -0
- package/dist/messages-DZiI-npH.js.map +1 -0
- package/dist/messages-DrqeFeSw.js +6 -0
- package/dist/messages-DrqeFeSw.js.map +1 -0
- package/dist/messages-UWbNAre2.js +6 -0
- package/dist/messages-UWbNAre2.js.map +1 -0
- package/dist/messages-_-gK_V4q.js +6 -0
- package/dist/messages-_-gK_V4q.js.map +1 -0
- package/dist/messages-ha2_ySOs.js +6 -0
- package/dist/messages-ha2_ySOs.js.map +1 -0
- package/dist/messages-kFHcdfMU.js +6 -0
- package/dist/messages-kFHcdfMU.js.map +1 -0
- package/dist/messages-sJpTSD2G.js +6 -0
- package/dist/messages-sJpTSD2G.js.map +1 -0
- package/dist/messages-vx3-MYVH.js +6 -0
- package/dist/messages-vx3-MYVH.js.map +1 -0
- package/dist/{plugins-CQAV8Ap0.js → plugins-DJsLy2K-.js} +32 -3
- package/dist/plugins-DJsLy2K-.js.map +1 -0
- package/dist/styles.css +1 -1
- package/package.json +8 -4
- package/dist/messages-1TWaf8a2.js +0 -6
- package/dist/messages-1TWaf8a2.js.map +0 -1
- package/dist/messages-B5sF4YmM.js +0 -6
- package/dist/messages-B5sF4YmM.js.map +0 -1
- package/dist/messages-B9T8Kc4V.js +0 -6
- package/dist/messages-B9T8Kc4V.js.map +0 -1
- package/dist/messages-BOwqz7Dx.js +0 -6
- package/dist/messages-BOwqz7Dx.js.map +0 -1
- package/dist/messages-B_M5MNtr.js +0 -6
- package/dist/messages-B_M5MNtr.js.map +0 -1
- package/dist/messages-Bh-BQAdD.js +0 -6
- package/dist/messages-Bh-BQAdD.js.map +0 -1
- package/dist/messages-ByjvPBKi.js +0 -6
- package/dist/messages-ByjvPBKi.js.map +0 -1
- package/dist/messages-C4xWRT0x.js +0 -6
- package/dist/messages-C4xWRT0x.js.map +0 -1
- package/dist/messages-CAdtKwS0.js +0 -6
- package/dist/messages-CAdtKwS0.js.map +0 -1
- package/dist/messages-CEdjuD3T.js +0 -6
- package/dist/messages-CEdjuD3T.js.map +0 -1
- package/dist/messages-CYCJB96m.js +0 -6
- package/dist/messages-CYCJB96m.js.map +0 -1
- package/dist/messages-C_ry9289.js +0 -6
- package/dist/messages-C_ry9289.js.map +0 -1
- package/dist/messages-CbGBMnfZ.js +0 -6
- package/dist/messages-CbGBMnfZ.js.map +0 -1
- package/dist/messages-Cpt4WQXi.js +0 -6
- package/dist/messages-Cpt4WQXi.js.map +0 -1
- package/dist/messages-D0Q9lbJr.js +0 -6
- package/dist/messages-D0Q9lbJr.js.map +0 -1
- package/dist/messages-D6SjorpS.js +0 -6
- package/dist/messages-D6SjorpS.js.map +0 -1
- package/dist/messages-DACzFKkc.js +0 -6
- package/dist/messages-DACzFKkc.js.map +0 -1
- package/dist/messages-DD7UzBCg.js +0 -6
- package/dist/messages-DD7UzBCg.js.map +0 -1
- package/dist/messages-DQhv3VpQ.js +0 -6
- package/dist/messages-DQhv3VpQ.js.map +0 -1
- package/dist/messages-DkmI0StQ.js +0 -6
- package/dist/messages-DkmI0StQ.js.map +0 -1
- package/dist/messages-DwVVrprv.js +0 -6
- package/dist/messages-DwVVrprv.js.map +0 -1
- package/dist/messages-LPfCWgcA.js +0 -6
- package/dist/messages-LPfCWgcA.js.map +0 -1
- package/dist/messages-NbBfxfDD.js +0 -6
- package/dist/messages-NbBfxfDD.js.map +0 -1
- package/dist/messages-UfXVNVGm.js +0 -6
- package/dist/messages-UfXVNVGm.js.map +0 -1
- package/dist/messages-kV2LI902.js +0 -6
- package/dist/messages-kV2LI902.js.map +0 -1
- package/dist/messages-lZ7KdJCT.js +0 -6
- package/dist/messages-lZ7KdJCT.js.map +0 -1
- package/dist/messages-nYVfh2dw.js +0 -6
- package/dist/messages-nYVfh2dw.js.map +0 -1
- package/dist/messages-ttfIlVd2.js +0 -6
- package/dist/messages-ttfIlVd2.js.map +0 -1
- package/dist/plugins-CQAV8Ap0.js.map +0 -1
|
@@ -253,34 +253,34 @@ function resolveLocale(request) {
|
|
|
253
253
|
//#endregion
|
|
254
254
|
//#region src/locales/loadMessages.ts
|
|
255
255
|
const LOCALE_LOADERS = /* @__PURE__ */ Object.assign({
|
|
256
|
-
"./ar/messages.mjs": () => import("./messages-
|
|
257
|
-
"./ca/messages.mjs": () => import("./messages-
|
|
258
|
-
"./cs/messages.mjs": () => import("./messages-
|
|
259
|
-
"./de/messages.mjs": () => import("./messages-
|
|
260
|
-
"./en/messages.mjs": () => import("./messages-
|
|
261
|
-
"./en-GB/messages.mjs": () => import("./messages-
|
|
262
|
-
"./es-419/messages.mjs": () => import("./messages-
|
|
263
|
-
"./es-ES/messages.mjs": () => import("./messages-
|
|
264
|
-
"./eu/messages.mjs": () => import("./messages-
|
|
265
|
-
"./fa/messages.mjs": () => import("./messages-
|
|
266
|
-
"./fr/messages.mjs": () => import("./messages-
|
|
267
|
-
"./hi/messages.mjs": () => import("./messages-
|
|
268
|
-
"./hu/messages.mjs": () => import("./messages-
|
|
269
|
-
"./id/messages.mjs": () => import("./messages-
|
|
270
|
-
"./ja/messages.mjs": () => import("./messages-
|
|
271
|
-
"./ko/messages.mjs": () => import("./messages-
|
|
272
|
-
"./nb/messages.mjs": () => import("./messages-
|
|
273
|
-
"./nl/messages.mjs": () => import("./messages-
|
|
274
|
-
"./pl/messages.mjs": () => import("./messages-
|
|
275
|
-
"./pseudo/messages.mjs": () => import("./messages-
|
|
276
|
-
"./pt-BR/messages.mjs": () => import("./messages-
|
|
277
|
-
"./sr-Latn/messages.mjs": () => import("./messages-
|
|
278
|
-
"./sv/messages.mjs": () => import("./messages-
|
|
279
|
-
"./th/messages.mjs": () => import("./messages-
|
|
280
|
-
"./tr/messages.mjs": () => import("./messages-
|
|
281
|
-
"./uk/messages.mjs": () => import("./messages-
|
|
282
|
-
"./zh-CN/messages.mjs": () => import("./messages-
|
|
283
|
-
"./zh-TW/messages.mjs": () => import("./messages-
|
|
256
|
+
"./ar/messages.mjs": () => import("./messages-C-omjoCi.js"),
|
|
257
|
+
"./ca/messages.mjs": () => import("./messages-B3Q7NUrK.js"),
|
|
258
|
+
"./cs/messages.mjs": () => import("./messages-DKYRxT68.js"),
|
|
259
|
+
"./de/messages.mjs": () => import("./messages-sJpTSD2G.js"),
|
|
260
|
+
"./en/messages.mjs": () => import("./messages-BLxOqfxi.js"),
|
|
261
|
+
"./en-GB/messages.mjs": () => import("./messages-CA8gfGRN.js"),
|
|
262
|
+
"./es-419/messages.mjs": () => import("./messages-CiFlbS-H.js"),
|
|
263
|
+
"./es-ES/messages.mjs": () => import("./messages-CSzVxyoV.js"),
|
|
264
|
+
"./eu/messages.mjs": () => import("./messages-Cb_WSNlm.js"),
|
|
265
|
+
"./fa/messages.mjs": () => import("./messages-CUVVH-l2.js"),
|
|
266
|
+
"./fr/messages.mjs": () => import("./messages-BKjrWDoV.js"),
|
|
267
|
+
"./hi/messages.mjs": () => import("./messages-CkVoAW1_.js"),
|
|
268
|
+
"./hu/messages.mjs": () => import("./messages-DrqeFeSw.js"),
|
|
269
|
+
"./id/messages.mjs": () => import("./messages-CXBqJPo6.js"),
|
|
270
|
+
"./ja/messages.mjs": () => import("./messages-BUkvBAQ_.js"),
|
|
271
|
+
"./ko/messages.mjs": () => import("./messages-3FU8zCct.js"),
|
|
272
|
+
"./nb/messages.mjs": () => import("./messages-UWbNAre2.js"),
|
|
273
|
+
"./nl/messages.mjs": () => import("./messages-CKCmO_US.js"),
|
|
274
|
+
"./pl/messages.mjs": () => import("./messages-BYPUIPvx.js"),
|
|
275
|
+
"./pseudo/messages.mjs": () => import("./messages-kFHcdfMU.js"),
|
|
276
|
+
"./pt-BR/messages.mjs": () => import("./messages-BYaDnRZi.js"),
|
|
277
|
+
"./sr-Latn/messages.mjs": () => import("./messages-_-gK_V4q.js"),
|
|
278
|
+
"./sv/messages.mjs": () => import("./messages-CKtyiPlE.js"),
|
|
279
|
+
"./th/messages.mjs": () => import("./messages-DZiI-npH.js"),
|
|
280
|
+
"./tr/messages.mjs": () => import("./messages-vx3-MYVH.js"),
|
|
281
|
+
"./uk/messages.mjs": () => import("./messages-ha2_ySOs.js"),
|
|
282
|
+
"./zh-CN/messages.mjs": () => import("./messages-CMlXT2mo.js"),
|
|
283
|
+
"./zh-TW/messages.mjs": () => import("./messages-9k1iDJF6.js")
|
|
284
284
|
});
|
|
285
285
|
async function loadMessages(locale) {
|
|
286
286
|
const key = `./${locale}/messages.mjs`;
|
|
@@ -347,4 +347,4 @@ function LocaleDirectionProvider({ children }) {
|
|
|
347
347
|
|
|
348
348
|
//#endregion
|
|
349
349
|
export { SUPPORTED_LOCALES as a, getLocaleLabel as c, DEFAULT_LOCALE as i, resolveLocale as l, useLocale as n, SUPPORTED_LOCALE_CODES as o, loadMessages as r, getLocaleDir as s, LocaleDirectionProvider as t };
|
|
350
|
-
//# sourceMappingURL=LocaleDirectionProvider-
|
|
350
|
+
//# sourceMappingURL=LocaleDirectionProvider-BjVpQpBl.js.map
|
package/dist/{LocaleDirectionProvider-CnKC3o_O.js.map → LocaleDirectionProvider-BjVpQpBl.js.map}
RENAMED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"LocaleDirectionProvider-CnKC3o_O.js","names":["React"],"sources":["../src/locales/locales.ts","../src/locales/config.ts","../src/locales/loadMessages.ts","../src/locales/useLocale.ts","../src/locales/LocaleDirectionProvider.tsx"],"sourcesContent":["/**\n * Canonical locale definitions -- the single source of truth.\n *\n * This file is intentionally free of Vite/Astro APIs (`import.meta.env` etc.)\n * so it can be imported from CLI tools (Lingui, Lunaria) running in plain Node.\n *\n * To add a new locale:\n * 1. Add an entry here (with `enabled: false`).\n * 2. Run `pnpm locale:extract` to generate the PO file.\n * 3. Translate the strings in the PO file.\n * 4. Set `enabled: true` once coverage is sufficient.\n *\n * Lingui and Lunaria use all locales (for extraction and tracking).\n * The admin runtime only exposes locales with `enabled: true`.\n */\n\nexport interface LocaleDefinition {\n\t/** BCP 47 locale code (e.g. \"en\", \"pt-BR\"). */\n\tcode: string;\n\t/** Human-readable label in the locale's own language. */\n\tlabel: string;\n\t/** Whether this locale is selectable in the admin UI. */\n\tenabled: boolean;\n\t/** Text direction for this locale. Defaults to \"ltr\" if not specified. */\n\tdir?: \"rtl\" | \"ltr\";\n}\n\n/**\n * All locales that have (or should have) a PO catalog.\n * First entry is the source/default locale.\n */\nexport const LOCALES: LocaleDefinition[] = [\n\t// Source locale first, then alphabetical by English name.\n\t{ code: \"en\", label: \"English\", enabled: true },\n\t{ code: \"ar\", label: \"العربية\", enabled: true, dir: \"rtl\" }, // Arabic\n\t{ code: \"eu\", label: \"Euskara\", enabled: true }, // Basque\n\t{ code: \"ca\", label: \"Català\", enabled: true }, // Catalan\n\t{ code: \"zh-CN\", label: \"简体中文\", enabled: true }, // Chinese (Simplified)\n\t{ code: \"zh-TW\", label: \"繁體中文\", enabled: true }, // Chinese (Traditional)\n\t{ code: \"cs\", label: \"Čeština\", enabled: true }, // Czech\n\t{ code: \"nl\", label: \"Nederlands\", enabled: true }, // Dutch\n\t{ code: \"en-GB\", label: \"English (UK)\", enabled: true }, // English (United Kingdom)\n\t{ code: \"fa\", label: \"فارسی\", enabled: true, dir: \"rtl\" }, // Farsi (also known as Persian)\n\t{ code: \"fr\", label: \"Français\", enabled: true }, // French\n\t{ code: \"de\", label: \"Deutsch\", enabled: true }, // German\n\t{ code: \"hi\", label: \"हिन्दी\", enabled: true }, // Hindi\n\t{ code: \"hu\", label: \"Magyar\", enabled: true }, // Hungarian\n\t{ code: \"id\", label: \"Bahasa Indonesia\", enabled: true }, // Indonesian\n\t{ code: \"ja\", label: \"日本語\", enabled: true }, // Japanese\n\t{ code: \"ko\", label: \"한국어\", enabled: false }, // Korean\n\t{ code: \"nb\", label: \"Norsk bokmål\", enabled: true }, // Norwegian Bokmål\n\t{ code: \"pl\", label: \"Polski\", enabled: true }, // Polish\n\t{ code: \"pt-BR\", label: \"Português (Brasil)\", enabled: true }, // Portuguese (Brazil)\n\t{ code: \"sr-Latn\", label: \"Srpski\", enabled: true }, // Serbian (Latin script)\n\t{ code: \"es-419\", label: \"Español (Latinoamérica)\", enabled: true }, // Spanish (Latin America)\n\t{ code: \"es-ES\", label: \"Español (España)\", enabled: true }, // Spanish (Spain) - BCP 47\n\t{ code: \"sv\", label: \"Svenska\", enabled: true }, // Swedish\n\t{ code: \"th\", label: \"ไทย\", enabled: true }, // Thai\n\t{ code: \"tr\", label: \"Türkçe\", enabled: true }, // Turkish\n\t{ code: \"uk\", label: \"Українська\", enabled: true }, // Ukrainian\n\t// Pseudo-locale for i18n testing - never enabled in the admin UI by default.\n\t// Set EMDASH_PSEUDO_LOCALE=1 in .env to expose it in the locale switcher (dev only).\n\t{ code: \"pseudo\", label: \"Pseudo\", enabled: false },\n];\n\n/** The source locale (first entry). */\nexport const SOURCE_LOCALE = LOCALES[0]!;\n\n/** All locale codes (for Lingui extraction / Lunaria tracking). */\nexport const LOCALE_CODES = LOCALES.map((l) => l.code);\n\n/** Target locales -- everything except the source (for Lunaria). */\nexport const TARGET_LOCALES = LOCALES.slice(1);\n\n/** Locales enabled in the admin UI. */\nexport const ENABLED_LOCALES = LOCALES.filter((l) => l.enabled);\n","/**\n * Locale configuration for the admin UI runtime.\n *\n * Locale definitions are in `./locales.ts` -- the single source of truth\n * shared by this file, lingui.config.ts and lunaria.config.ts.\n */\n\nimport { ENABLED_LOCALES, LOCALES, SOURCE_LOCALE } from \"./locales.js\";\n\nexport type { LocaleDefinition as SupportedLocale } from \"./locales.js\";\n\nfunction isValidLocale(code: string): boolean {\n\ttry {\n\t\tconst locale = new Intl.Locale(code);\n\t\treturn locale.baseName !== \"\";\n\t} catch {\n\t\tif (import.meta.env.DEV) {\n\t\t\tthrow new Error(`Invalid locale code: \"${code}\"`);\n\t\t}\n\t\treturn false;\n\t}\n}\n\n// Injected by the EmDash Vite integration from process.env.EMDASH_PSEUDO_LOCALE.\n// Only true in dev when EMDASH_PSEUDO_LOCALE=1 is set.\ndeclare const __EMDASH_PSEUDO_LOCALE__: boolean;\n\n/**\n * The pseudo locale, injected into the supported list only when\n * EMDASH_PSEUDO_LOCALE=1 is set. Never available in production.\n */\nconst PSEUDO_LOCALE =\n\ttypeof __EMDASH_PSEUDO_LOCALE__ !== \"undefined\" && __EMDASH_PSEUDO_LOCALE__\n\t\t? LOCALES.find((l) => l.code === \"pseudo\")\n\t\t: undefined;\n\n/** Available locales at runtime, validated against BCP 47. */\nexport const SUPPORTED_LOCALES = [\n\t...ENABLED_LOCALES.filter((l) => isValidLocale(l.code)),\n\t...(PSEUDO_LOCALE ? [PSEUDO_LOCALE] : []),\n];\n\nexport const SUPPORTED_LOCALE_CODES = new Set(SUPPORTED_LOCALES.map((l) => l.code));\n\nexport const DEFAULT_LOCALE = SOURCE_LOCALE.code;\n\n/** Maps base language codes to supported locales (e.g. \"pt\" -> \"pt-BR\"). */\nconst BASE_LANGUAGE_MAP = new Map<string, string>();\n/** Maps script codes to supported locales (e.g. \"zh-Hant\" -> \"zh-TW\", \"zh-Hans\" -> \"zh-CN\"). */\nconst SCRIPT_LANGUAGE_MAP = new Map<string, string>();\n\nfor (const l of SUPPORTED_LOCALES) {\n\tconst base = l.code.split(\"-\")[0]!.toLowerCase();\n\t// First match wins -- if we have both \"pt\" and \"pt-BR\", exact wins via direct lookup.\n\tif (!BASE_LANGUAGE_MAP.has(base)) {\n\t\tBASE_LANGUAGE_MAP.set(base, l.code);\n\t}\n\n\tconst maximized = new Intl.Locale(l.code).maximize();\n\tif (maximized.script) {\n\t\tconst scriptKey = `${maximized.language}-${maximized.script}`.toLowerCase();\n\t\tif (!SCRIPT_LANGUAGE_MAP.has(scriptKey)) {\n\t\t\tSCRIPT_LANGUAGE_MAP.set(scriptKey, l.code);\n\t\t}\n\t}\n}\n\n/**\n * Find the best matching supported locale for a BCP 47 tag.\n * Canonicalizes via Intl.Locale so case differences (e.g. \"pt-br\" vs \"pt-BR\")\n * don't prevent matching. Supports script codes (zh-Hant -> zh-TW, zh-Hans -> zh-CN)\n * and falls back to base language (pt-PT -> pt-BR).\n */\nfunction matchLocale(tag: string): string | undefined {\n\tconst trimmed = tag.trim();\n\tif (!trimmed) return undefined;\n\tlet canonical: string;\n\ttry {\n\t\tcanonical = new Intl.Locale(trimmed).baseName;\n\t} catch {\n\t\treturn undefined;\n\t}\n\n\t// Exact match (case-insensitive via Intl.Locale)\n\tif (SUPPORTED_LOCALE_CODES.has(canonical)) return canonical;\n\n\t// Try script-based matching (zh-Hant -> zh-TW, zh-Hans -> zh-CN)\n\tconst locale = new Intl.Locale(trimmed);\n\tif (locale.script) {\n\t\tconst scriptKey = `${locale.language}-${locale.script}`.toLowerCase();\n\t\tconst scriptMatch = SCRIPT_LANGUAGE_MAP.get(scriptKey);\n\t\tif (scriptMatch) return scriptMatch;\n\t}\n\n\t// Fallback to base language (pt-PT -> pt-BR)\n\tconst base = canonical.split(\"-\")[0]!.toLowerCase();\n\treturn BASE_LANGUAGE_MAP.get(base);\n}\n\nconst LOCALE_LABELS = new Map(SUPPORTED_LOCALES.map((l) => [l.code, l.label]));\n\n/** Get a display label for a locale code, falling back to uppercase code. */\nexport function getLocaleLabel(code: string): string {\n\treturn LOCALE_LABELS.get(code) ?? code.toUpperCase();\n}\n\nconst LOCALE_DIRS = new Map(SUPPORTED_LOCALES.map((l) => [l.code, l.dir]));\n\n/** Get the text direction for a locale code. Defaults to \"ltr\" if not specified. */\nexport function getLocaleDir(code: string): \"ltr\" | \"rtl\" {\n\treturn LOCALE_DIRS.get(code) ?? \"ltr\";\n}\n\nconst LOCALE_COOKIE_RE = /(?:^|;\\s*)emdash-locale=([^;]+)/;\n\n/**\n * Resolve the admin locale from a Request.\n * Priority: emdash-locale cookie -> Accept-Language -> DEFAULT_LOCALE.\n */\nexport function resolveLocale(request: Request): string {\n\tconst cookieHeader = request.headers.get(\"cookie\") ?? \"\";\n\tconst cookieMatch = cookieHeader.match(LOCALE_COOKIE_RE);\n\tconst cookieLocale = cookieMatch?.[1]?.trim() ?? \"\";\n\n\tif (SUPPORTED_LOCALE_CODES.has(cookieLocale)) return cookieLocale;\n\n\tconst acceptLang = request.headers.get(\"accept-language\") ?? \"\";\n\tfor (const entry of acceptLang.split(\",\")) {\n\t\tconst tag = entry.split(\";\")[0]!.trim();\n\t\tconst matched = matchLocale(tag);\n\t\tif (matched) return matched;\n\t}\n\n\treturn DEFAULT_LOCALE;\n}\n","import type { Messages } from \"@lingui/core\";\n\nimport { DEFAULT_LOCALE } from \"./config.js\";\n\nconst LOCALE_LOADERS = import.meta.glob<{ messages: Messages }>(\"./**/messages.mjs\");\n\nexport async function loadMessages(locale: string): Promise<Messages> {\n\tconst key = `./${locale}/messages.mjs`;\n\tconst fallbackKey = `./${DEFAULT_LOCALE}/messages.mjs`;\n\tconst loader = LOCALE_LOADERS[key] ?? LOCALE_LOADERS[fallbackKey];\n\tif (!loader) {\n\t\tthrow new Error(\n\t\t\t`No locale catalog found for \"${locale}\" or \"${DEFAULT_LOCALE}\". Run \\`pnpm locale:compile\\` to generate catalogs.`,\n\t\t);\n\t}\n\tconst { messages } = await loader();\n\treturn messages;\n}\n","import { useLingui } from \"@lingui/react\";\nimport * as React from \"react\";\n\nimport { SUPPORTED_LOCALE_CODES } from \"./config.js\";\nimport { loadMessages } from \"./loadMessages.js\";\n\nfunction setCookie(code: string) {\n\tconst secure = window.location.protocol === \"https:\" ? \"; Secure\" : \"\";\n\tdocument.cookie = `emdash-locale=${code}; Path=/_emdash; SameSite=Lax; Max-Age=31536000${secure}`;\n}\n\n/**\n * Get the current locale and a function to switch locales.\n * Loads the new catalog dynamically and sets a cookie for server-side persistence.\n */\nexport function useLocale() {\n\tconst { i18n } = useLingui();\n\tconst [locale, setLocaleState] = React.useState(i18n.locale);\n\n\tconst setLocale = React.useCallback(\n\t\t(code: string) => {\n\t\t\tif (code === i18n.locale || !SUPPORTED_LOCALE_CODES.has(code)) return;\n\t\t\tsetCookie(code);\n\t\t\tvoid loadMessages(code)\n\t\t\t\t.then((messages) => i18n.loadAndActivate({ locale: code, messages }))\n\t\t\t\t.catch(() => {\n\t\t\t\t\tsetCookie(i18n.locale);\n\t\t\t\t});\n\t\t},\n\t\t[i18n],\n\t);\n\n\t// Subscribe to i18n change events to trigger re-renders\n\tReact.useEffect(() => {\n\t\tconst unsubscribe = i18n.on(\"change\", () => {\n\t\t\tsetLocaleState(i18n.locale);\n\t\t});\n\t\treturn unsubscribe;\n\t}, [i18n]);\n\n\treturn { locale, setLocale };\n}\n","import { DirectionProvider } from \"@cloudflare/kumo/primitives\";\nimport * as React from \"react\";\n\nimport { getLocaleDir } from \"./config.js\";\nimport { useLocale } from \"./useLocale.js\";\n\ninterface LocaleDirectionProviderProps {\n\tchildren: React.ReactNode;\n}\n\n/**\n * Wraps the app with DirectionProvider and keeps it in sync with the current locale.\n * Automatically updates direction when locale changes via useLocale.\n */\nexport function LocaleDirectionProvider({ children }: LocaleDirectionProviderProps) {\n\tconst { locale } = useLocale();\n\tconst dir = React.useMemo(() => getLocaleDir(locale), [locale]);\n\n\t/** Sync the direction and lang attributes with the current locale. */\n\tReact.useEffect(() => {\n\t\tdocument.documentElement.setAttribute(\"lang\", locale);\n\t\tdocument.documentElement.setAttribute(\"dir\", dir);\n\t}, [dir, locale]);\n\n\treturn <DirectionProvider direction={dir}>{children}</DirectionProvider>;\n}\n"],"mappings":"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"}
|
|
1
|
+
{"version":3,"file":"LocaleDirectionProvider-BjVpQpBl.js","names":["React"],"sources":["../src/locales/locales.ts","../src/locales/config.ts","../src/locales/loadMessages.ts","../src/locales/useLocale.ts","../src/locales/LocaleDirectionProvider.tsx"],"sourcesContent":["/**\n * Canonical locale definitions -- the single source of truth.\n *\n * This file is intentionally free of Vite/Astro APIs (`import.meta.env` etc.)\n * so it can be imported from CLI tools (Lingui, Lunaria) running in plain Node.\n *\n * To add a new locale:\n * 1. Add an entry here (with `enabled: false`).\n * 2. Run `pnpm locale:extract` to generate the PO file.\n * 3. Translate the strings in the PO file.\n * 4. Set `enabled: true` once coverage is sufficient.\n *\n * Lingui and Lunaria use all locales (for extraction and tracking).\n * The admin runtime only exposes locales with `enabled: true`.\n */\n\nexport interface LocaleDefinition {\n\t/** BCP 47 locale code (e.g. \"en\", \"pt-BR\"). */\n\tcode: string;\n\t/** Human-readable label in the locale's own language. */\n\tlabel: string;\n\t/** Whether this locale is selectable in the admin UI. */\n\tenabled: boolean;\n\t/** Text direction for this locale. Defaults to \"ltr\" if not specified. */\n\tdir?: \"rtl\" | \"ltr\";\n}\n\n/**\n * All locales that have (or should have) a PO catalog.\n * First entry is the source/default locale.\n */\nexport const LOCALES: LocaleDefinition[] = [\n\t// Source locale first, then alphabetical by English name.\n\t{ code: \"en\", label: \"English\", enabled: true },\n\t{ code: \"ar\", label: \"العربية\", enabled: true, dir: \"rtl\" }, // Arabic\n\t{ code: \"eu\", label: \"Euskara\", enabled: true }, // Basque\n\t{ code: \"ca\", label: \"Català\", enabled: true }, // Catalan\n\t{ code: \"zh-CN\", label: \"简体中文\", enabled: true }, // Chinese (Simplified)\n\t{ code: \"zh-TW\", label: \"繁體中文\", enabled: true }, // Chinese (Traditional)\n\t{ code: \"cs\", label: \"Čeština\", enabled: true }, // Czech\n\t{ code: \"nl\", label: \"Nederlands\", enabled: true }, // Dutch\n\t{ code: \"en-GB\", label: \"English (UK)\", enabled: true }, // English (United Kingdom)\n\t{ code: \"fa\", label: \"فارسی\", enabled: true, dir: \"rtl\" }, // Farsi (also known as Persian)\n\t{ code: \"fr\", label: \"Français\", enabled: true }, // French\n\t{ code: \"de\", label: \"Deutsch\", enabled: true }, // German\n\t{ code: \"hi\", label: \"हिन्दी\", enabled: true }, // Hindi\n\t{ code: \"hu\", label: \"Magyar\", enabled: true }, // Hungarian\n\t{ code: \"id\", label: \"Bahasa Indonesia\", enabled: true }, // Indonesian\n\t{ code: \"ja\", label: \"日本語\", enabled: true }, // Japanese\n\t{ code: \"ko\", label: \"한국어\", enabled: false }, // Korean\n\t{ code: \"nb\", label: \"Norsk bokmål\", enabled: true }, // Norwegian Bokmål\n\t{ code: \"pl\", label: \"Polski\", enabled: true }, // Polish\n\t{ code: \"pt-BR\", label: \"Português (Brasil)\", enabled: true }, // Portuguese (Brazil)\n\t{ code: \"sr-Latn\", label: \"Srpski\", enabled: true }, // Serbian (Latin script)\n\t{ code: \"es-419\", label: \"Español (Latinoamérica)\", enabled: true }, // Spanish (Latin America)\n\t{ code: \"es-ES\", label: \"Español (España)\", enabled: true }, // Spanish (Spain) - BCP 47\n\t{ code: \"sv\", label: \"Svenska\", enabled: true }, // Swedish\n\t{ code: \"th\", label: \"ไทย\", enabled: true }, // Thai\n\t{ code: \"tr\", label: \"Türkçe\", enabled: true }, // Turkish\n\t{ code: \"uk\", label: \"Українська\", enabled: true }, // Ukrainian\n\t// Pseudo-locale for i18n testing - never enabled in the admin UI by default.\n\t// Set EMDASH_PSEUDO_LOCALE=1 in .env to expose it in the locale switcher (dev only).\n\t{ code: \"pseudo\", label: \"Pseudo\", enabled: false },\n];\n\n/** The source locale (first entry). */\nexport const SOURCE_LOCALE = LOCALES[0]!;\n\n/** All locale codes (for Lingui extraction / Lunaria tracking). */\nexport const LOCALE_CODES = LOCALES.map((l) => l.code);\n\n/** Target locales -- everything except the source (for Lunaria). */\nexport const TARGET_LOCALES = LOCALES.slice(1);\n\n/** Locales enabled in the admin UI. */\nexport const ENABLED_LOCALES = LOCALES.filter((l) => l.enabled);\n","/**\n * Locale configuration for the admin UI runtime.\n *\n * Locale definitions are in `./locales.ts` -- the single source of truth\n * shared by this file, lingui.config.ts and lunaria.config.ts.\n */\n\nimport { ENABLED_LOCALES, LOCALES, SOURCE_LOCALE } from \"./locales.js\";\n\nexport type { LocaleDefinition as SupportedLocale } from \"./locales.js\";\n\nfunction isValidLocale(code: string): boolean {\n\ttry {\n\t\tconst locale = new Intl.Locale(code);\n\t\treturn locale.baseName !== \"\";\n\t} catch {\n\t\tif (import.meta.env.DEV) {\n\t\t\tthrow new Error(`Invalid locale code: \"${code}\"`);\n\t\t}\n\t\treturn false;\n\t}\n}\n\n// Injected by the EmDash Vite integration from process.env.EMDASH_PSEUDO_LOCALE.\n// Only true in dev when EMDASH_PSEUDO_LOCALE=1 is set.\ndeclare const __EMDASH_PSEUDO_LOCALE__: boolean;\n\n/**\n * The pseudo locale, injected into the supported list only when\n * EMDASH_PSEUDO_LOCALE=1 is set. Never available in production.\n */\nconst PSEUDO_LOCALE =\n\ttypeof __EMDASH_PSEUDO_LOCALE__ !== \"undefined\" && __EMDASH_PSEUDO_LOCALE__\n\t\t? LOCALES.find((l) => l.code === \"pseudo\")\n\t\t: undefined;\n\n/** Available locales at runtime, validated against BCP 47. */\nexport const SUPPORTED_LOCALES = [\n\t...ENABLED_LOCALES.filter((l) => isValidLocale(l.code)),\n\t...(PSEUDO_LOCALE ? [PSEUDO_LOCALE] : []),\n];\n\nexport const SUPPORTED_LOCALE_CODES = new Set(SUPPORTED_LOCALES.map((l) => l.code));\n\nexport const DEFAULT_LOCALE = SOURCE_LOCALE.code;\n\n/** Maps base language codes to supported locales (e.g. \"pt\" -> \"pt-BR\"). */\nconst BASE_LANGUAGE_MAP = new Map<string, string>();\n/** Maps script codes to supported locales (e.g. \"zh-Hant\" -> \"zh-TW\", \"zh-Hans\" -> \"zh-CN\"). */\nconst SCRIPT_LANGUAGE_MAP = new Map<string, string>();\n\nfor (const l of SUPPORTED_LOCALES) {\n\tconst base = l.code.split(\"-\")[0]!.toLowerCase();\n\t// First match wins -- if we have both \"pt\" and \"pt-BR\", exact wins via direct lookup.\n\tif (!BASE_LANGUAGE_MAP.has(base)) {\n\t\tBASE_LANGUAGE_MAP.set(base, l.code);\n\t}\n\n\tconst maximized = new Intl.Locale(l.code).maximize();\n\tif (maximized.script) {\n\t\tconst scriptKey = `${maximized.language}-${maximized.script}`.toLowerCase();\n\t\tif (!SCRIPT_LANGUAGE_MAP.has(scriptKey)) {\n\t\t\tSCRIPT_LANGUAGE_MAP.set(scriptKey, l.code);\n\t\t}\n\t}\n}\n\n/**\n * Find the best matching supported locale for a BCP 47 tag.\n * Canonicalizes via Intl.Locale so case differences (e.g. \"pt-br\" vs \"pt-BR\")\n * don't prevent matching. Supports script codes (zh-Hant -> zh-TW, zh-Hans -> zh-CN)\n * and falls back to base language (pt-PT -> pt-BR).\n */\nfunction matchLocale(tag: string): string | undefined {\n\tconst trimmed = tag.trim();\n\tif (!trimmed) return undefined;\n\tlet canonical: string;\n\ttry {\n\t\tcanonical = new Intl.Locale(trimmed).baseName;\n\t} catch {\n\t\treturn undefined;\n\t}\n\n\t// Exact match (case-insensitive via Intl.Locale)\n\tif (SUPPORTED_LOCALE_CODES.has(canonical)) return canonical;\n\n\t// Try script-based matching (zh-Hant -> zh-TW, zh-Hans -> zh-CN)\n\tconst locale = new Intl.Locale(trimmed);\n\tif (locale.script) {\n\t\tconst scriptKey = `${locale.language}-${locale.script}`.toLowerCase();\n\t\tconst scriptMatch = SCRIPT_LANGUAGE_MAP.get(scriptKey);\n\t\tif (scriptMatch) return scriptMatch;\n\t}\n\n\t// Fallback to base language (pt-PT -> pt-BR)\n\tconst base = canonical.split(\"-\")[0]!.toLowerCase();\n\treturn BASE_LANGUAGE_MAP.get(base);\n}\n\nconst LOCALE_LABELS = new Map(SUPPORTED_LOCALES.map((l) => [l.code, l.label]));\n\n/** Get a display label for a locale code, falling back to uppercase code. */\nexport function getLocaleLabel(code: string): string {\n\treturn LOCALE_LABELS.get(code) ?? code.toUpperCase();\n}\n\nconst LOCALE_DIRS = new Map(SUPPORTED_LOCALES.map((l) => [l.code, l.dir]));\n\n/** Get the text direction for a locale code. Defaults to \"ltr\" if not specified. */\nexport function getLocaleDir(code: string): \"ltr\" | \"rtl\" {\n\treturn LOCALE_DIRS.get(code) ?? \"ltr\";\n}\n\nconst LOCALE_COOKIE_RE = /(?:^|;\\s*)emdash-locale=([^;]+)/;\n\n/**\n * Resolve the admin locale from a Request.\n * Priority: emdash-locale cookie -> Accept-Language -> DEFAULT_LOCALE.\n */\nexport function resolveLocale(request: Request): string {\n\tconst cookieHeader = request.headers.get(\"cookie\") ?? \"\";\n\tconst cookieMatch = cookieHeader.match(LOCALE_COOKIE_RE);\n\tconst cookieLocale = cookieMatch?.[1]?.trim() ?? \"\";\n\n\tif (SUPPORTED_LOCALE_CODES.has(cookieLocale)) return cookieLocale;\n\n\tconst acceptLang = request.headers.get(\"accept-language\") ?? \"\";\n\tfor (const entry of acceptLang.split(\",\")) {\n\t\tconst tag = entry.split(\";\")[0]!.trim();\n\t\tconst matched = matchLocale(tag);\n\t\tif (matched) return matched;\n\t}\n\n\treturn DEFAULT_LOCALE;\n}\n","import type { Messages } from \"@lingui/core\";\n\nimport { DEFAULT_LOCALE } from \"./config.js\";\n\nconst LOCALE_LOADERS = import.meta.glob<{ messages: Messages }>(\"./**/messages.mjs\");\n\nexport async function loadMessages(locale: string): Promise<Messages> {\n\tconst key = `./${locale}/messages.mjs`;\n\tconst fallbackKey = `./${DEFAULT_LOCALE}/messages.mjs`;\n\tconst loader = LOCALE_LOADERS[key] ?? LOCALE_LOADERS[fallbackKey];\n\tif (!loader) {\n\t\tthrow new Error(\n\t\t\t`No locale catalog found for \"${locale}\" or \"${DEFAULT_LOCALE}\". Run \\`pnpm locale:compile\\` to generate catalogs.`,\n\t\t);\n\t}\n\tconst { messages } = await loader();\n\treturn messages;\n}\n","import { useLingui } from \"@lingui/react\";\nimport * as React from \"react\";\n\nimport { SUPPORTED_LOCALE_CODES } from \"./config.js\";\nimport { loadMessages } from \"./loadMessages.js\";\n\nfunction setCookie(code: string) {\n\tconst secure = window.location.protocol === \"https:\" ? \"; Secure\" : \"\";\n\tdocument.cookie = `emdash-locale=${code}; Path=/_emdash; SameSite=Lax; Max-Age=31536000${secure}`;\n}\n\n/**\n * Get the current locale and a function to switch locales.\n * Loads the new catalog dynamically and sets a cookie for server-side persistence.\n */\nexport function useLocale() {\n\tconst { i18n } = useLingui();\n\tconst [locale, setLocaleState] = React.useState(i18n.locale);\n\n\tconst setLocale = React.useCallback(\n\t\t(code: string) => {\n\t\t\tif (code === i18n.locale || !SUPPORTED_LOCALE_CODES.has(code)) return;\n\t\t\tsetCookie(code);\n\t\t\tvoid loadMessages(code)\n\t\t\t\t.then((messages) => i18n.loadAndActivate({ locale: code, messages }))\n\t\t\t\t.catch(() => {\n\t\t\t\t\tsetCookie(i18n.locale);\n\t\t\t\t});\n\t\t},\n\t\t[i18n],\n\t);\n\n\t// Subscribe to i18n change events to trigger re-renders\n\tReact.useEffect(() => {\n\t\tconst unsubscribe = i18n.on(\"change\", () => {\n\t\t\tsetLocaleState(i18n.locale);\n\t\t});\n\t\treturn unsubscribe;\n\t}, [i18n]);\n\n\treturn { locale, setLocale };\n}\n","import { DirectionProvider } from \"@cloudflare/kumo/primitives\";\nimport * as React from \"react\";\n\nimport { getLocaleDir } from \"./config.js\";\nimport { useLocale } from \"./useLocale.js\";\n\ninterface LocaleDirectionProviderProps {\n\tchildren: React.ReactNode;\n}\n\n/**\n * Wraps the app with DirectionProvider and keeps it in sync with the current locale.\n * Automatically updates direction when locale changes via useLocale.\n */\nexport function LocaleDirectionProvider({ children }: LocaleDirectionProviderProps) {\n\tconst { locale } = useLocale();\n\tconst dir = React.useMemo(() => getLocaleDir(locale), [locale]);\n\n\t/** Sync the direction and lang attributes with the current locale. */\n\tReact.useEffect(() => {\n\t\tdocument.documentElement.setAttribute(\"lang\", locale);\n\t\tdocument.documentElement.setAttribute(\"dir\", dir);\n\t}, [dir, locale]);\n\n\treturn <DirectionProvider direction={dir}>{children}</DirectionProvider>;\n}\n"],"mappings":"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"}
|
package/dist/index.d.ts
CHANGED
|
@@ -11,6 +11,7 @@ import { ComponentProps } from "react";
|
|
|
11
11
|
import * as react_jsx_runtime0 from "react/jsx-runtime";
|
|
12
12
|
import "@phosphor-icons/react";
|
|
13
13
|
import { ClassValue } from "clsx";
|
|
14
|
+
import * as _dnd_kit_core0 from "@dnd-kit/core";
|
|
14
15
|
import { Editor } from "@tiptap/react";
|
|
15
16
|
import { Node as Node$1 } from "@tiptap/core";
|
|
16
17
|
import * as _emdash_cms_blocks0 from "@emdash-cms/blocks";
|
|
@@ -76,6 +77,14 @@ declare const API_BASE = "/_emdash/api";
|
|
|
76
77
|
* to all requests. All API calls should use this instead of raw fetch().
|
|
77
78
|
*/
|
|
78
79
|
declare function apiFetch(input: string | URL | Request, init?: RequestInit): Promise<Response>;
|
|
80
|
+
declare class ApiResponseError extends Error {
|
|
81
|
+
status: number;
|
|
82
|
+
code: string;
|
|
83
|
+
details?: Record<string, unknown> | undefined;
|
|
84
|
+
constructor(status: number, code: string, message: string, details?: Record<string, unknown> | undefined);
|
|
85
|
+
}
|
|
86
|
+
/** Whether retrying the same request unchanged can never succeed. */
|
|
87
|
+
declare function isTerminalRequestError(error: unknown): boolean;
|
|
79
88
|
/**
|
|
80
89
|
* Throw an error with the message from the API response body if available,
|
|
81
90
|
* falling back to a generic message. All API error responses use the shape
|
|
@@ -391,6 +400,7 @@ interface ContentItem {
|
|
|
391
400
|
byline: BylineSummary;
|
|
392
401
|
sortOrder: number;
|
|
393
402
|
roleLabel: string | null;
|
|
403
|
+
source?: "explicit" | "inferred";
|
|
394
404
|
}>;
|
|
395
405
|
createdAt: string;
|
|
396
406
|
updatedAt: string;
|
|
@@ -624,6 +634,40 @@ interface MediaUploadOptions {
|
|
|
624
634
|
interface UploadMediaOptions extends MediaUploadOptions {
|
|
625
635
|
fieldId?: string;
|
|
626
636
|
}
|
|
637
|
+
type MediaUsageCoverageStatus = "complete" | "never" | "running" | "partial" | "failed" | "stale" | "unknown";
|
|
638
|
+
interface MediaUsageCoverage {
|
|
639
|
+
scope: "all_content_collections";
|
|
640
|
+
status: MediaUsageCoverageStatus;
|
|
641
|
+
}
|
|
642
|
+
interface MediaUsageOccurrenceDetail {
|
|
643
|
+
fieldSlug: string;
|
|
644
|
+
fieldPath: string;
|
|
645
|
+
occurrenceIndex: number;
|
|
646
|
+
referenceType: "image_field" | "file_field" | "portable_text_image" | "unknown";
|
|
647
|
+
}
|
|
648
|
+
interface MediaUsageSourceDetail {
|
|
649
|
+
variant: "columns" | "draft_overlay";
|
|
650
|
+
occurrences: MediaUsageOccurrenceDetail[];
|
|
651
|
+
}
|
|
652
|
+
interface MediaUsageEntryDetail {
|
|
653
|
+
collection: string;
|
|
654
|
+
contentId: string;
|
|
655
|
+
title: string | null;
|
|
656
|
+
slug: string | null;
|
|
657
|
+
locale: string | null;
|
|
658
|
+
status: string | null;
|
|
659
|
+
scheduledAt: string | null;
|
|
660
|
+
deletedAt: string | null;
|
|
661
|
+
sources: MediaUsageSourceDetail[];
|
|
662
|
+
}
|
|
663
|
+
interface MediaUsageDetailsResponse {
|
|
664
|
+
items: MediaUsageEntryDetail[];
|
|
665
|
+
nextCursor?: string;
|
|
666
|
+
coverage: MediaUsageCoverage;
|
|
667
|
+
}
|
|
668
|
+
declare class MediaUsageAccessDeniedError extends Error {
|
|
669
|
+
constructor();
|
|
670
|
+
}
|
|
627
671
|
interface MediaItem {
|
|
628
672
|
id: string;
|
|
629
673
|
filename: string;
|
|
@@ -634,6 +678,8 @@ interface MediaItem {
|
|
|
634
678
|
size: number;
|
|
635
679
|
width?: number;
|
|
636
680
|
height?: number;
|
|
681
|
+
focalX?: number | null;
|
|
682
|
+
focalY?: number | null;
|
|
637
683
|
/** LQIP blurhash placeholder (images only) */
|
|
638
684
|
blurhash?: string;
|
|
639
685
|
/** LQIP dominant-color placeholder, as a CSS color (images only) */
|
|
@@ -646,22 +692,52 @@ interface MediaItem {
|
|
|
646
692
|
/** Provider-specific metadata */
|
|
647
693
|
meta?: Record<string, unknown>;
|
|
648
694
|
}
|
|
695
|
+
interface LocalMediaItem extends MediaItem {
|
|
696
|
+
provider?: undefined;
|
|
697
|
+
storageKey: string;
|
|
698
|
+
authorId: string | null;
|
|
699
|
+
folderId: string | null;
|
|
700
|
+
}
|
|
701
|
+
interface MediaFolder {
|
|
702
|
+
id: string;
|
|
703
|
+
name: string;
|
|
704
|
+
}
|
|
705
|
+
interface MediaListResult extends FindManyResult<LocalMediaItem> {
|
|
706
|
+
totalCount?: number;
|
|
707
|
+
}
|
|
708
|
+
interface MediaFolderListResult extends FindManyResult<MediaFolder> {}
|
|
649
709
|
/**
|
|
650
710
|
* Fetch media list
|
|
651
711
|
*/
|
|
652
712
|
declare function fetchMediaList(options?: {
|
|
653
713
|
cursor?: string;
|
|
714
|
+
page?: number;
|
|
654
715
|
limit?: number;
|
|
655
|
-
mimeType?: string | string[];
|
|
716
|
+
mimeType?: string | string[];
|
|
717
|
+
folderId?: string | null; /** Case-insensitive filename substring search (also matches extensions). */
|
|
656
718
|
search?: string;
|
|
657
|
-
}): Promise<
|
|
719
|
+
}): Promise<MediaListResult>;
|
|
658
720
|
/**
|
|
659
721
|
* Fetch a single media item by id.
|
|
660
722
|
*
|
|
661
723
|
* Used to resolve an id-only reference (e.g. a byline's `avatarMediaId`)
|
|
662
724
|
* back into a full media item for display.
|
|
663
725
|
*/
|
|
664
|
-
declare function fetchMediaItem(id: string, options?: MediaUploadOptions): Promise<
|
|
726
|
+
declare function fetchMediaItem(id: string, options?: MediaUploadOptions): Promise<LocalMediaItem>;
|
|
727
|
+
declare function fetchMediaUsageDetails(mediaId: string, options?: {
|
|
728
|
+
cursor?: string;
|
|
729
|
+
limit?: number;
|
|
730
|
+
signal?: AbortSignal;
|
|
731
|
+
}): Promise<MediaUsageDetailsResponse>;
|
|
732
|
+
declare function fetchMediaFolders(options?: {
|
|
733
|
+
limit?: number;
|
|
734
|
+
cursor?: string;
|
|
735
|
+
search?: string;
|
|
736
|
+
}): Promise<MediaFolderListResult>;
|
|
737
|
+
declare function fetchMediaFolder(id: string): Promise<MediaFolder>;
|
|
738
|
+
declare function createMediaFolder(name: string): Promise<MediaFolder>;
|
|
739
|
+
declare function renameMediaFolder(id: string, name: string): Promise<MediaFolder>;
|
|
740
|
+
declare function deleteMediaFolder(id: string): Promise<void>;
|
|
665
741
|
/**
|
|
666
742
|
* Upload media file
|
|
667
743
|
*
|
|
@@ -676,12 +752,16 @@ declare function deleteMedia(id: string): Promise<void>;
|
|
|
676
752
|
/**
|
|
677
753
|
* Update media metadata (dimensions, alt text, etc.)
|
|
678
754
|
*/
|
|
679
|
-
|
|
755
|
+
interface MediaUpdateInput {
|
|
680
756
|
alt?: string;
|
|
681
757
|
caption?: string;
|
|
682
758
|
width?: number;
|
|
683
759
|
height?: number;
|
|
684
|
-
|
|
760
|
+
folderId?: string | null;
|
|
761
|
+
focalX?: number | null;
|
|
762
|
+
focalY?: number | null;
|
|
763
|
+
}
|
|
764
|
+
declare function updateMedia(id: string, input: MediaUpdateInput): Promise<LocalMediaItem>;
|
|
685
765
|
/** Media provider capabilities */
|
|
686
766
|
interface MediaProviderCapabilities {
|
|
687
767
|
browse: boolean;
|
|
@@ -2704,9 +2784,11 @@ declare function createAdminRouter(queryClient: QueryClient): _tanstack_router_c
|
|
|
2704
2784
|
}, _tanstack_router_core0.ResolveParams<"/content/$collection/new">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.RootRoute<_tanstack_react_router0.Register, undefined, RouterContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/", "/", "_admin", "/_admin", undefined, _tanstack_router_core0.ResolveParams<"/">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/content/$collection/$id", "/content/$collection/$id", string, "/_admin/content/$collection/$id", (search: Record<string, unknown>) => {
|
|
2705
2785
|
locale?: string | undefined;
|
|
2706
2786
|
field?: string | undefined;
|
|
2707
|
-
}, _tanstack_router_core0.ResolveParams<"/content/$collection/$id">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.RootRoute<_tanstack_react_router0.Register, undefined, RouterContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/", "/", "_admin", "/_admin", undefined, _tanstack_router_core0.ResolveParams<"/">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/content-types", "/content-types", string, "/_admin/content-types", undefined, _tanstack_router_core0.ResolveParams<"/content-types">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.RootRoute<_tanstack_react_router0.Register, undefined, RouterContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/", "/", "_admin", "/_admin", undefined, _tanstack_router_core0.ResolveParams<"/">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/content-types/new", "/content-types/new", string, "/_admin/content-types/new", undefined, _tanstack_router_core0.ResolveParams<"/content-types/new">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.RootRoute<_tanstack_react_router0.Register, undefined, RouterContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/", "/", "_admin", "/_admin", undefined, _tanstack_router_core0.ResolveParams<"/">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/content-types/$slug", "/content-types/$slug", string, "/_admin/content-types/$slug", undefined, _tanstack_router_core0.ResolveParams<"/content-types/$slug">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.RootRoute<_tanstack_react_router0.Register, undefined, RouterContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/", "/", "_admin", "/_admin", undefined, _tanstack_router_core0.ResolveParams<"/">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/media", "/media", string, "/_admin/media",
|
|
2787
|
+
}, _tanstack_router_core0.ResolveParams<"/content/$collection/$id">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.RootRoute<_tanstack_react_router0.Register, undefined, RouterContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/", "/", "_admin", "/_admin", undefined, _tanstack_router_core0.ResolveParams<"/">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/content-types", "/content-types", string, "/_admin/content-types", undefined, _tanstack_router_core0.ResolveParams<"/content-types">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.RootRoute<_tanstack_react_router0.Register, undefined, RouterContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/", "/", "_admin", "/_admin", undefined, _tanstack_router_core0.ResolveParams<"/">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/content-types/new", "/content-types/new", string, "/_admin/content-types/new", undefined, _tanstack_router_core0.ResolveParams<"/content-types/new">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.RootRoute<_tanstack_react_router0.Register, undefined, RouterContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/", "/", "_admin", "/_admin", undefined, _tanstack_router_core0.ResolveParams<"/">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/content-types/$slug", "/content-types/$slug", string, "/_admin/content-types/$slug", undefined, _tanstack_router_core0.ResolveParams<"/content-types/$slug">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.RootRoute<_tanstack_react_router0.Register, undefined, RouterContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/", "/", "_admin", "/_admin", undefined, _tanstack_router_core0.ResolveParams<"/">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/media", "/media", string, "/_admin/media", (search: Record<string, unknown>) => {
|
|
2788
|
+
folder: string | undefined;
|
|
2789
|
+
}, _tanstack_router_core0.ResolveParams<"/media">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.RootRoute<_tanstack_react_router0.Register, undefined, RouterContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/", "/", "_admin", "/_admin", undefined, _tanstack_router_core0.ResolveParams<"/">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/comments", "/comments", string, "/_admin/comments", undefined, _tanstack_router_core0.ResolveParams<"/comments">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.RootRoute<_tanstack_react_router0.Register, undefined, RouterContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/", "/", "_admin", "/_admin", undefined, _tanstack_router_core0.ResolveParams<"/">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/menus", "/menus", string, "/_admin/menus", undefined, _tanstack_router_core0.ResolveParams<"/menus">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.RootRoute<_tanstack_react_router0.Register, undefined, RouterContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/", "/", "_admin", "/_admin", undefined, _tanstack_router_core0.ResolveParams<"/">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/menus/$name", "/menus/$name", string, "/_admin/menus/$name", (search: Record<string, unknown>) => {
|
|
2708
2790
|
locale: string | undefined;
|
|
2709
|
-
}, _tanstack_router_core0.ResolveParams<"/menus/$name">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.RootRoute<_tanstack_react_router0.Register, undefined, RouterContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/", "/", "_admin", "/_admin", undefined, _tanstack_router_core0.ResolveParams<"/">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/plugins-manager", "/plugins-manager", string, "/_admin/plugins-manager", undefined, _tanstack_router_core0.ResolveParams<"/plugins-manager">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.RootRoute<_tanstack_react_router0.Register, undefined, RouterContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/", "/", "_admin", "/_admin", undefined, _tanstack_router_core0.ResolveParams<"/">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/plugins-manager/$pluginId/settings", "/plugins-manager/$pluginId/settings", string, "/_admin/plugins-manager/$pluginId/settings", undefined, _tanstack_router_core0.ResolveParams<"/plugins-manager/$pluginId/settings">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.RootRoute<_tanstack_react_router0.Register, undefined, RouterContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/", "/", "_admin", "/_admin", undefined, _tanstack_router_core0.ResolveParams<"/">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/plugins/marketplace/$pluginId", "/plugins/marketplace/$pluginId", string, "/_admin/plugins/marketplace/$pluginId", undefined, _tanstack_router_core0.ResolveParams<"/plugins/marketplace/$pluginId">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.RootRoute<_tanstack_react_router0.Register, undefined, RouterContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/", "/", "_admin", "/_admin", undefined, _tanstack_router_core0.ResolveParams<"/">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/plugins/marketplace", "/plugins/marketplace", string, "/_admin/plugins/marketplace", undefined, _tanstack_router_core0.ResolveParams<"/plugins/marketplace">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.RootRoute<_tanstack_react_router0.Register, undefined, RouterContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/", "/", "_admin", "/_admin", undefined, _tanstack_router_core0.ResolveParams<"/">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/themes/marketplace", "/themes/marketplace", string, "/_admin/themes/marketplace", undefined, _tanstack_router_core0.ResolveParams<"/themes/marketplace">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.RootRoute<_tanstack_react_router0.Register, undefined, RouterContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/", "/", "_admin", "/_admin", undefined, _tanstack_router_core0.ResolveParams<"/">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/themes/marketplace/$themeId", "/themes/marketplace/$themeId", string, "/_admin/themes/marketplace/$themeId", undefined, _tanstack_router_core0.ResolveParams<"/themes/marketplace/$themeId">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.RootRoute<_tanstack_react_router0.Register, undefined, RouterContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/", "/", "_admin", "/_admin", undefined, _tanstack_router_core0.ResolveParams<"/">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/plugins/$pluginId/$", "/plugins/$pluginId/$", string, "/_admin/plugins/$pluginId/$", undefined, _tanstack_router_core0.ResolveParams<"/plugins/$pluginId/$">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.RootRoute<_tanstack_react_router0.Register, undefined, RouterContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/", "/", "_admin", "/_admin", undefined, _tanstack_router_core0.ResolveParams<"/">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/redirects", "/redirects", string, "/_admin/redirects", undefined, _tanstack_router_core0.ResolveParams<"/redirects">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.RootRoute<_tanstack_react_router0.Register, undefined, RouterContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/", "/", "_admin", "/_admin", undefined, _tanstack_router_core0.ResolveParams<"/">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/sections", "/sections", string, "/_admin/sections", undefined, _tanstack_router_core0.ResolveParams<"/sections">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.RootRoute<_tanstack_react_router0.Register, undefined, RouterContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/", "/", "_admin", "/_admin", undefined, _tanstack_router_core0.ResolveParams<"/">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/sections/$slug", "/sections/$slug", string, "/_admin/sections/$slug", undefined, _tanstack_router_core0.ResolveParams<"/sections/$slug">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.RootRoute<_tanstack_react_router0.Register, undefined, RouterContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/", "/", "_admin", "/_admin", undefined, _tanstack_router_core0.ResolveParams<"/">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/taxonomies/$taxonomy", "/taxonomies/$taxonomy", string, "/_admin/taxonomies/$taxonomy", undefined, _tanstack_router_core0.ResolveParams<"/taxonomies/$taxonomy">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.RootRoute<_tanstack_react_router0.Register, undefined, RouterContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/", "/", "_admin", "/_admin", undefined, _tanstack_router_core0.ResolveParams<"/">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/users", "/users", string, "/_admin/users", undefined, _tanstack_router_core0.ResolveParams<"/users">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.RootRoute<_tanstack_react_router0.Register, undefined, RouterContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/", "/", "_admin", "/_admin", undefined, _tanstack_router_core0.ResolveParams<"/">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/bylines", "/bylines", string, "/_admin/bylines", typeof parseBylinesLocaleSearch, _tanstack_router_core0.ResolveParams<"/bylines">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.RootRoute<_tanstack_react_router0.Register, undefined, RouterContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/", "/", "_admin", "/_admin", undefined, _tanstack_router_core0.ResolveParams<"/">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/byline-schema", "/byline-schema", string, "/_admin/byline-schema", undefined, _tanstack_router_core0.ResolveParams<"/byline-schema">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.RootRoute<_tanstack_react_router0.Register, undefined, RouterContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/", "/", "_admin", "/_admin", undefined, _tanstack_router_core0.ResolveParams<"/">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/widgets", "/widgets", string, "/_admin/widgets", undefined, _tanstack_router_core0.ResolveParams<"/widgets">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.RootRoute<_tanstack_react_router0.Register, undefined, RouterContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/", "/", "_admin", "/_admin", undefined, _tanstack_router_core0.ResolveParams<"/">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/settings", "/settings", string, "/_admin/settings", undefined, _tanstack_router_core0.ResolveParams<"/settings">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.RootRoute<_tanstack_react_router0.Register, undefined, RouterContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/", "/", "_admin", "/_admin", undefined, _tanstack_router_core0.ResolveParams<"/">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/settings/general", "/settings/general", string, "/_admin/settings/general", undefined, _tanstack_router_core0.ResolveParams<"/settings/general">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.RootRoute<_tanstack_react_router0.Register, undefined, RouterContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/", "/", "_admin", "/_admin", undefined, _tanstack_router_core0.ResolveParams<"/">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/settings/social", "/settings/social", string, "/_admin/settings/social", undefined, _tanstack_router_core0.ResolveParams<"/settings/social">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.RootRoute<_tanstack_react_router0.Register, undefined, RouterContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/", "/", "_admin", "/_admin", undefined, _tanstack_router_core0.ResolveParams<"/">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/settings/seo", "/settings/seo", string, "/_admin/settings/seo", undefined, _tanstack_router_core0.ResolveParams<"/settings/seo">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.RootRoute<_tanstack_react_router0.Register, undefined, RouterContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/", "/", "_admin", "/_admin", undefined, _tanstack_router_core0.ResolveParams<"/">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/settings/security", "/settings/security", string, "/_admin/settings/security", undefined, _tanstack_router_core0.ResolveParams<"/settings/security">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.RootRoute<_tanstack_react_router0.Register, undefined, RouterContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/", "/", "_admin", "/_admin", undefined, _tanstack_router_core0.ResolveParams<"/">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/settings/allowed-domains", "/settings/allowed-domains", string, "/_admin/settings/allowed-domains", undefined, _tanstack_router_core0.ResolveParams<"/settings/allowed-domains">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.RootRoute<_tanstack_react_router0.Register, undefined, RouterContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/", "/", "_admin", "/_admin", undefined, _tanstack_router_core0.ResolveParams<"/">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/settings/api-tokens", "/settings/api-tokens", string, "/_admin/settings/api-tokens", undefined, _tanstack_router_core0.ResolveParams<"/settings/api-tokens">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.RootRoute<_tanstack_react_router0.Register, undefined, RouterContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/", "/", "_admin", "/_admin", undefined, _tanstack_router_core0.ResolveParams<"/">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/settings/email", "/settings/email", string, "/_admin/settings/email", undefined, _tanstack_router_core0.ResolveParams<"/settings/email">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.RootRoute<_tanstack_react_router0.Register, undefined, RouterContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/", "/", "_admin", "/_admin", undefined, _tanstack_router_core0.ResolveParams<"/">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/settings/backups", "/settings/backups", string, "/_admin/settings/backups", undefined, _tanstack_router_core0.ResolveParams<"/settings/backups">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.RootRoute<_tanstack_react_router0.Register, undefined, RouterContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/", "/", "_admin", "/_admin", undefined, _tanstack_router_core0.ResolveParams<"/">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/import/wordpress", "/import/wordpress", string, "/_admin/import/wordpress", undefined, _tanstack_router_core0.ResolveParams<"/import/wordpress">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.RootRoute<_tanstack_react_router0.Register, undefined, RouterContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/", "/", "_admin", "/_admin", undefined, _tanstack_router_core0.ResolveParams<"/">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "*", "/*", string, "/_admin/*", undefined, _tanstack_router_core0.ResolveParams<"*">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>], unknown, unknown, unknown, undefined>], unknown, unknown, unknown, undefined>, "never", false, _tanstack_history0.RouterHistory, Record<string, any>>;
|
|
2791
|
+
}, _tanstack_router_core0.ResolveParams<"/menus/$name">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.RootRoute<_tanstack_react_router0.Register, undefined, RouterContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/", "/", "_admin", "/_admin", undefined, _tanstack_router_core0.ResolveParams<"/">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/plugins-manager", "/plugins-manager", string, "/_admin/plugins-manager", undefined, _tanstack_router_core0.ResolveParams<"/plugins-manager">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.RootRoute<_tanstack_react_router0.Register, undefined, RouterContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/", "/", "_admin", "/_admin", undefined, _tanstack_router_core0.ResolveParams<"/">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/plugins-manager/$pluginId/settings", "/plugins-manager/$pluginId/settings", string, "/_admin/plugins-manager/$pluginId/settings", undefined, _tanstack_router_core0.ResolveParams<"/plugins-manager/$pluginId/settings">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.RootRoute<_tanstack_react_router0.Register, undefined, RouterContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/", "/", "_admin", "/_admin", undefined, _tanstack_router_core0.ResolveParams<"/">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/plugins/marketplace/$pluginId", "/plugins/marketplace/$pluginId", string, "/_admin/plugins/marketplace/$pluginId", undefined, _tanstack_router_core0.ResolveParams<"/plugins/marketplace/$pluginId">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.RootRoute<_tanstack_react_router0.Register, undefined, RouterContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/", "/", "_admin", "/_admin", undefined, _tanstack_router_core0.ResolveParams<"/">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/plugins/marketplace", "/plugins/marketplace", string, "/_admin/plugins/marketplace", undefined, _tanstack_router_core0.ResolveParams<"/plugins/marketplace">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.RootRoute<_tanstack_react_router0.Register, undefined, RouterContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/", "/", "_admin", "/_admin", undefined, _tanstack_router_core0.ResolveParams<"/">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/themes/marketplace", "/themes/marketplace", string, "/_admin/themes/marketplace", undefined, _tanstack_router_core0.ResolveParams<"/themes/marketplace">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.RootRoute<_tanstack_react_router0.Register, undefined, RouterContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/", "/", "_admin", "/_admin", undefined, _tanstack_router_core0.ResolveParams<"/">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/themes/marketplace/$themeId", "/themes/marketplace/$themeId", string, "/_admin/themes/marketplace/$themeId", undefined, _tanstack_router_core0.ResolveParams<"/themes/marketplace/$themeId">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.RootRoute<_tanstack_react_router0.Register, undefined, RouterContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/", "/", "_admin", "/_admin", undefined, _tanstack_router_core0.ResolveParams<"/">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/plugins/$pluginId/$", "/plugins/$pluginId/$", string, "/_admin/plugins/$pluginId/$", undefined, _tanstack_router_core0.ResolveParams<"/plugins/$pluginId/$">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.RootRoute<_tanstack_react_router0.Register, undefined, RouterContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/", "/", "_admin", "/_admin", undefined, _tanstack_router_core0.ResolveParams<"/">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/redirects", "/redirects", string, "/_admin/redirects", undefined, _tanstack_router_core0.ResolveParams<"/redirects">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.RootRoute<_tanstack_react_router0.Register, undefined, RouterContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/", "/", "_admin", "/_admin", undefined, _tanstack_router_core0.ResolveParams<"/">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/sections", "/sections", string, "/_admin/sections", undefined, _tanstack_router_core0.ResolveParams<"/sections">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.RootRoute<_tanstack_react_router0.Register, undefined, RouterContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/", "/", "_admin", "/_admin", undefined, _tanstack_router_core0.ResolveParams<"/">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/sections/$slug", "/sections/$slug", string, "/_admin/sections/$slug", undefined, _tanstack_router_core0.ResolveParams<"/sections/$slug">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.RootRoute<_tanstack_react_router0.Register, undefined, RouterContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/", "/", "_admin", "/_admin", undefined, _tanstack_router_core0.ResolveParams<"/">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/taxonomies/$taxonomy", "/taxonomies/$taxonomy", string, "/_admin/taxonomies/$taxonomy", undefined, _tanstack_router_core0.ResolveParams<"/taxonomies/$taxonomy">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.RootRoute<_tanstack_react_router0.Register, undefined, RouterContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/", "/", "_admin", "/_admin", undefined, _tanstack_router_core0.ResolveParams<"/">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/users", "/users", string, "/_admin/users", undefined, _tanstack_router_core0.ResolveParams<"/users">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.RootRoute<_tanstack_react_router0.Register, undefined, RouterContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/", "/", "_admin", "/_admin", undefined, _tanstack_router_core0.ResolveParams<"/">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/bylines", "/bylines", string, "/_admin/bylines", typeof parseBylinesLocaleSearch, _tanstack_router_core0.ResolveParams<"/bylines">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.RootRoute<_tanstack_react_router0.Register, undefined, RouterContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/", "/", "_admin", "/_admin", undefined, _tanstack_router_core0.ResolveParams<"/">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/byline-schema", "/byline-schema", string, "/_admin/byline-schema", undefined, _tanstack_router_core0.ResolveParams<"/byline-schema">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.RootRoute<_tanstack_react_router0.Register, undefined, RouterContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/", "/", "_admin", "/_admin", undefined, _tanstack_router_core0.ResolveParams<"/">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/widgets", "/widgets", string, "/_admin/widgets", undefined, _tanstack_router_core0.ResolveParams<"/widgets">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.RootRoute<_tanstack_react_router0.Register, undefined, RouterContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/", "/", "_admin", "/_admin", undefined, _tanstack_router_core0.ResolveParams<"/">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/settings", "/settings", string, "/_admin/settings", undefined, _tanstack_router_core0.ResolveParams<"/settings">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.RootRoute<_tanstack_react_router0.Register, undefined, RouterContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/", "/", "_admin", "/_admin", undefined, _tanstack_router_core0.ResolveParams<"/">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/settings/media-usage", "/settings/media-usage", string, "/_admin/settings/media-usage", undefined, _tanstack_router_core0.ResolveParams<"/settings/media-usage">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.RootRoute<_tanstack_react_router0.Register, undefined, RouterContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/", "/", "_admin", "/_admin", undefined, _tanstack_router_core0.ResolveParams<"/">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/settings/general", "/settings/general", string, "/_admin/settings/general", undefined, _tanstack_router_core0.ResolveParams<"/settings/general">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.RootRoute<_tanstack_react_router0.Register, undefined, RouterContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/", "/", "_admin", "/_admin", undefined, _tanstack_router_core0.ResolveParams<"/">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/settings/social", "/settings/social", string, "/_admin/settings/social", undefined, _tanstack_router_core0.ResolveParams<"/settings/social">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.RootRoute<_tanstack_react_router0.Register, undefined, RouterContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/", "/", "_admin", "/_admin", undefined, _tanstack_router_core0.ResolveParams<"/">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/settings/seo", "/settings/seo", string, "/_admin/settings/seo", undefined, _tanstack_router_core0.ResolveParams<"/settings/seo">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.RootRoute<_tanstack_react_router0.Register, undefined, RouterContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/", "/", "_admin", "/_admin", undefined, _tanstack_router_core0.ResolveParams<"/">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/settings/security", "/settings/security", string, "/_admin/settings/security", undefined, _tanstack_router_core0.ResolveParams<"/settings/security">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.RootRoute<_tanstack_react_router0.Register, undefined, RouterContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/", "/", "_admin", "/_admin", undefined, _tanstack_router_core0.ResolveParams<"/">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/settings/allowed-domains", "/settings/allowed-domains", string, "/_admin/settings/allowed-domains", undefined, _tanstack_router_core0.ResolveParams<"/settings/allowed-domains">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.RootRoute<_tanstack_react_router0.Register, undefined, RouterContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/", "/", "_admin", "/_admin", undefined, _tanstack_router_core0.ResolveParams<"/">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/settings/api-tokens", "/settings/api-tokens", string, "/_admin/settings/api-tokens", undefined, _tanstack_router_core0.ResolveParams<"/settings/api-tokens">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.RootRoute<_tanstack_react_router0.Register, undefined, RouterContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/", "/", "_admin", "/_admin", undefined, _tanstack_router_core0.ResolveParams<"/">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/settings/email", "/settings/email", string, "/_admin/settings/email", undefined, _tanstack_router_core0.ResolveParams<"/settings/email">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.RootRoute<_tanstack_react_router0.Register, undefined, RouterContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/", "/", "_admin", "/_admin", undefined, _tanstack_router_core0.ResolveParams<"/">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/settings/backups", "/settings/backups", string, "/_admin/settings/backups", undefined, _tanstack_router_core0.ResolveParams<"/settings/backups">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.RootRoute<_tanstack_react_router0.Register, undefined, RouterContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/", "/", "_admin", "/_admin", undefined, _tanstack_router_core0.ResolveParams<"/">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/import/wordpress", "/import/wordpress", string, "/_admin/import/wordpress", undefined, _tanstack_router_core0.ResolveParams<"/import/wordpress">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.Route<unknown, _tanstack_react_router0.RootRoute<_tanstack_react_router0.Register, undefined, RouterContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "/", "/", "_admin", "/_admin", undefined, _tanstack_router_core0.ResolveParams<"/">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>, "*", "/*", string, "/_admin/*", undefined, _tanstack_router_core0.ResolveParams<"*">, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, _tanstack_router_core0.AnyContext, {}, undefined, unknown, unknown, unknown, unknown, undefined>], unknown, unknown, unknown, undefined>], unknown, unknown, unknown, undefined>, "never", false, _tanstack_history0.RouterHistory, Record<string, any>>;
|
|
2710
2792
|
declare module "@tanstack/react-router" {
|
|
2711
2793
|
interface Register {
|
|
2712
2794
|
router: ReturnType<typeof createAdminRouter>;
|
|
@@ -3205,6 +3287,8 @@ interface ContentEditorProps {
|
|
|
3205
3287
|
isAutosaveFeedbackActive?: boolean;
|
|
3206
3288
|
/** Entry-scoped token advanced after a successful autosave. */
|
|
3207
3289
|
autosaveCompletionToken?: number;
|
|
3290
|
+
/** Entry-scoped token advanced after the server rejected an autosave payload. */
|
|
3291
|
+
autosaveRejectionToken?: number;
|
|
3208
3292
|
onPublish?: () => void;
|
|
3209
3293
|
onUnpublish?: () => void;
|
|
3210
3294
|
/** Callback to discard draft changes (revert to published version) */
|
|
@@ -3288,6 +3372,7 @@ declare function ContentEditor({
|
|
|
3288
3372
|
isAutosaving,
|
|
3289
3373
|
isAutosaveFeedbackActive,
|
|
3290
3374
|
autosaveCompletionToken,
|
|
3375
|
+
autosaveRejectionToken,
|
|
3291
3376
|
onPublish,
|
|
3292
3377
|
onUnpublish,
|
|
3293
3378
|
onDiscardDraft,
|
|
@@ -3330,10 +3415,39 @@ interface MediaLibraryProps {
|
|
|
3330
3415
|
hasMore?: boolean;
|
|
3331
3416
|
/** Triggered to fetch the next page of local-library items */
|
|
3332
3417
|
onLoadMore?: () => void;
|
|
3418
|
+
pagination?: MediaLibraryPagination;
|
|
3333
3419
|
/** Called (debounced) with the filename search term for the local library. */
|
|
3334
3420
|
onLocalSearchChange?: (q: string) => void;
|
|
3335
3421
|
/** Called with the MIME filter for the local library (undefined = all types). */
|
|
3336
3422
|
onLocalMimeFilterChange?: (mimeType: string | string[] | undefined) => void;
|
|
3423
|
+
/** Bounded folder pages owned by the main local Media route. */
|
|
3424
|
+
folders?: MediaFolder[];
|
|
3425
|
+
foldersLoading?: boolean;
|
|
3426
|
+
foldersError?: Error | null;
|
|
3427
|
+
hasMoreFolders?: boolean;
|
|
3428
|
+
isLoadingMoreFolders?: boolean;
|
|
3429
|
+
onLoadMoreFolders?: () => void;
|
|
3430
|
+
onActiveProviderChange?: (providerId: string) => void;
|
|
3431
|
+
folderId?: string;
|
|
3432
|
+
currentFolder?: MediaFolder | null;
|
|
3433
|
+
currentFolderLoading?: boolean;
|
|
3434
|
+
canManageFolders?: boolean;
|
|
3435
|
+
onOpenFolder?: (folder: MediaFolder) => void;
|
|
3436
|
+
onBackToMain?: () => void;
|
|
3437
|
+
onRetryFolders?: () => void;
|
|
3438
|
+
onCreateFolder?: (name: string) => Promise<MediaFolder>;
|
|
3439
|
+
onRenameFolder?: (folder: MediaFolder, name: string) => Promise<MediaFolder>;
|
|
3440
|
+
onDeleteFolder?: (folder: MediaFolder) => Promise<void>;
|
|
3441
|
+
canMoveMedia?: (item: LocalMediaItem) => boolean;
|
|
3442
|
+
onMoveMedia?: (item: LocalMediaItem, folder: MediaFolder) => Promise<void>;
|
|
3443
|
+
}
|
|
3444
|
+
interface MediaLibraryPagination {
|
|
3445
|
+
page: number;
|
|
3446
|
+
perPage: number;
|
|
3447
|
+
totalCount: number;
|
|
3448
|
+
isPending: boolean;
|
|
3449
|
+
onPageChange: (page: number) => void;
|
|
3450
|
+
onPageSizeChange: (perPage: number) => void;
|
|
3337
3451
|
}
|
|
3338
3452
|
/**
|
|
3339
3453
|
* Media library component with upload, provider tabs, and grid view
|
|
@@ -3345,9 +3459,29 @@ declare function MediaLibrary({
|
|
|
3345
3459
|
onItemUpdated,
|
|
3346
3460
|
hasMore,
|
|
3347
3461
|
onLoadMore,
|
|
3462
|
+
pagination,
|
|
3348
3463
|
onLocalSearchChange,
|
|
3349
|
-
onLocalMimeFilterChange
|
|
3350
|
-
|
|
3464
|
+
onLocalMimeFilterChange,
|
|
3465
|
+
onActiveProviderChange,
|
|
3466
|
+
folders,
|
|
3467
|
+
foldersLoading,
|
|
3468
|
+
foldersError,
|
|
3469
|
+
hasMoreFolders,
|
|
3470
|
+
isLoadingMoreFolders,
|
|
3471
|
+
onLoadMoreFolders,
|
|
3472
|
+
folderId,
|
|
3473
|
+
currentFolder,
|
|
3474
|
+
currentFolderLoading,
|
|
3475
|
+
canManageFolders,
|
|
3476
|
+
onOpenFolder,
|
|
3477
|
+
onBackToMain,
|
|
3478
|
+
onRetryFolders,
|
|
3479
|
+
onCreateFolder,
|
|
3480
|
+
onRenameFolder,
|
|
3481
|
+
onDeleteFolder,
|
|
3482
|
+
canMoveMedia,
|
|
3483
|
+
onMoveMedia
|
|
3484
|
+
}: MediaLibraryProps): React$1.FunctionComponentElement<_dnd_kit_core0.DndContextProps>;
|
|
3351
3485
|
//#endregion
|
|
3352
3486
|
//#region src/components/MediaPickerModal.d.ts
|
|
3353
3487
|
interface MediaPickerModalProps {
|
|
@@ -3584,5 +3718,5 @@ declare function SetupWizard(): react_jsx_runtime0.JSX.Element | null;
|
|
|
3584
3718
|
*/
|
|
3585
3719
|
declare function cn(...inputs: ClassValue[]): string;
|
|
3586
3720
|
//#endregion
|
|
3587
|
-
export { API_BASE, API_TOKEN_SCOPES, AdminApp, AdminApp as App, type AdminBranding, type AdminComment, type AdminManifest, type AllowedDomain, type ApiTokenCreateResult, type ApiTokenInfo, type ApiTokenScopeValue, type AttachmentInfo, type AuthProviderModule, AuthProviderProvider, type AuthProviders, type AuthorMapping, type BulkAction, type BylineCreditInput, type BylineCustomFieldValue, type BylineFieldDefinition, type BylineFieldType, type BylineFieldUsage, type BylineFieldValidation, type BylineInput, type BylineSummary, type BylineTranslationInput, CAPABILITY_LABELS, type CollectionSchemaStatus, type CollectionStats, type CommentCounts, type CommentStatus, type ContentAuthor, type ContentDateField, ContentEditor, type ContentEditorPanelContext, type ContentEditorPanelExtension, type ContentEditorProps, type ContentItem, ContentList, type ContentListColumn, type ContentListColumnCellContext, type ContentListColumnExtension, type ContentListColumnHeaderContext, type ContentListProps, type ContentSeo, type ContentSeoInput, type CreateAllowedDomainInput, type CreateApiTokenInput, type CreateBylineFieldInput, type CreateCollectionInput, type CreateContentInput, type CreateFieldInput, type CreateMenuInput, type CreateMenuItemInput, type CreateRedirectInput, type CreateSectionInput, type CreateTaxonomyInput, type CreateTermInput, type CreateWidgetAreaInput, type CreateWidgetInput, type CurrentUser, type CustomTaxonomy, DEFAULT_LOCALE, Dashboard, type DashboardProps, type DashboardStats, EditorHeader, type EditorHeaderProps, type EmailProvider, type EmailSettings, type FieldCompatibility, type FieldDescriptor, type FieldType, type FindManyResult, type GetSectionsOptions, Header, type ImportConfig, type ImportFieldDef, type ImportResult, type InstallPluginOpts, type InviteVerifyResult, Link, LoginPage, MEDIA_SEARCH_MAX_LENGTH, type MarketplaceAuditSummary, type MarketplaceAuthor, type MarketplaceImageAuditSummary, type MarketplacePluginDetail, type MarketplacePluginSummary, type MarketplaceSearchOpts, type MarketplaceSearchResult, type MarketplaceVersion, type MediaImportProgress, type MediaImportResult, type MediaItem, MediaLibrary, type MediaLibraryProps, MediaPickerModal, type MediaPickerModalProps, type MediaProviderCapabilities, type MediaProviderInfo, type MediaProviderItem, type MediaUploadOptions, type Menu, type MenuItem, type LocaleOptions as MenuLocaleOptions, type MenuTranslation, type MenuTranslationsResponse, type MenuWithItems, type NavMenu, type NotFoundSummary, type OrphanedTable, type PasskeyInfo, PasskeyLogin, type PasskeyLoginProps, PasskeyRegistration, type PasskeyRegistrationProps, type PluginAdminModule, PluginAdminProvider, type PluginAdmins, type PluginInfo, type PluginUpdateInfo, PortableTextEditor, type PortableTextEditorProps, type PostTypeAnalysis, type PrepareRequest, type PrepareResult, type PreviewUrlResponse, type ProbeResult, type RecentItem, type Redirect, type RedirectListOptions, type RedirectListResult, type ReorderMenuItemsInput, type Revision, type RevisionListResponse, type RewriteUrlsResult, SUPPORTED_LOCALES, SUPPORTED_LOCALE_CODES, SaveButton, type SaveButtonProps, type SchemaCollection, type SchemaCollectionWithFields, type SchemaField, type SearchEnableResult, type Section, type SectionSource, type SectionsResult, type SettingField, Settings, SetupWizard, Shell, type ShellProps, KumoSidebar as Sidebar, SidebarNav, type SidebarNavProps, type SignupVerifyResult, type SiteSettings, type SourceAuth, type SourceCapabilities, type SourceProbeResult, type SuggestedAction, type LocaleDefinition as SupportedLocale, type TaxonomyDef, type TaxonomyTerm, type TermTranslation, type TermTranslationsResponse, type ThemeAuthor, type ThemeAuthorDetail, type ThemeDetail, type ThemeSearchOpts, type ThemeSearchResult, type ThemeSummary, type TranslationSummary, type TranslationsResponse, type TrashedContentItem, type UninstallPluginOpts, type UpdateAllowedDomainInput, type UpdateBylineFieldInput, type UpdateCollectionInput, type UpdateContentInput, type UpdateFieldInput, type UpdateMenuInput, type UpdateMenuItemInput, type UpdatePluginOpts, type UpdateRedirectInput, type UpdateSectionInput, type UpdateTermInput, type UpdateUserInput, type UpdateWidgetInput, type UploadMediaOptions, type UserDetail, type UserListItem, type Widget, type WidgetArea, type WidgetComponent, type WpAuthorInfo, type WpImportProgress, type WpPluginAnalysis, type WxrAnalysis, analyzeWpPluginSite, analyzeWxr, apiFetch, bulkCommentAction, checkPluginUpdates, cn, compareRevisions, completeSignup, createAdminRouter, createAllowedDomain, createApiToken, createByline, createBylineField, createBylineTranslation, createCollection, createContent, createField, createMenu, createMenuItem, createMenuTranslation, createRedirect, createSection, createTaxonomy, createTerm, createTermTranslation, createWidget, createWidgetArea, deleteAllowedDomain, deleteByline, deleteBylineField, deleteCollection, deleteComment, deleteContent, deleteField, deleteFromProvider, deleteMedia, deleteMenu, deleteMenuItem, deletePasskey, deleteRedirect, deleteSection, deleteTerm, deleteWidget, deleteWidgetArea, describeCapability, disablePlugin, disableUser, discardDraft, duplicateContent, enablePlugin, enableUser, executeWpPluginImport, executeWxrImport, fetch404Summary, fetchAllowedDomains, fetchApiTokens, fetchAuthMode, fetchByline, fetchBylineTranslations, fetchBylines, fetchCollection, fetchCollections, fetchComment, fetchCommentCounts, fetchComments, fetchContent, fetchContentAuthors, fetchContentList, fetchDashboardStats, fetchEmailSettings, fetchFields, fetchManifest, fetchMarketplacePlugin, fetchMediaItem, fetchMediaList, fetchMediaProviders, fetchMenu, fetchMenuTranslations, fetchMenus, fetchOrphanedTables, fetchPasskeys, fetchPlugin, fetchPluginSettings, fetchPlugins, fetchProviderMedia, fetchRedirects, fetchRevision, fetchRevisions, fetchSection, fetchSections, fetchSettings, fetchTaxonomyDef, fetchTaxonomyDefs, fetchTermTranslations, fetchTerms, fetchTheme, fetchTranslations, fetchTrashedContent, fetchUser, fetchUsers, fetchWidgetArea, fetchWidgetAreas, fetchWidgetComponents, generatePreviewUrl, getBylineFieldUsage, getDraftStatus, getPreviewUrl, hasAllowedDomains, importWxrMedia, importWxrMediaBatched, installMarketplacePlugin, inviteUser, listBylineFields, parseApiResponse, permanentDeleteContent, prepareWxrImport, probeImportUrl, publishContent, registerOrphanedTable, renamePasskey, reorderBylineFields, reorderCollections, reorderFields, reorderMenuItems, reorderWidgets, requestSignup, resolveLocale, restoreContent, restoreRevision, revokeApiToken, rewriteContentUrls, scheduleContent, searchMarketplace, searchThemes, sendRecoveryLink, sendTestEmail, setPluginMcpEnabled, setSearchEnabled, throwResponseError, uninstallMarketplacePlugin, unpublishContent, unscheduleContent, updateAllowedDomain, updateByline, updateBylineField, updateCollection, updateCommentStatus, updateContent, updateField, updateMarketplacePlugin, updateMedia, updateMenu, updateMenuItem, updatePluginSettings, updateRedirect, updateSection, updateSettings, updateTerm, updateUser, updateWidget, uploadMedia, uploadToProvider, useAuthProviderList, useAuthProviders, useCurrentUser, useLocale, useNavigate, useParams, usePluginAdmins, usePluginField, usePluginHasPages, usePluginHasWidgets, usePluginPage, usePluginWidget, validateInviteToken, verifySignupToken };
|
|
3721
|
+
export { API_BASE, API_TOKEN_SCOPES, AdminApp, AdminApp as App, type AdminBranding, type AdminComment, type AdminManifest, type AllowedDomain, ApiResponseError, type ApiTokenCreateResult, type ApiTokenInfo, type ApiTokenScopeValue, type AttachmentInfo, type AuthProviderModule, AuthProviderProvider, type AuthProviders, type AuthorMapping, type BulkAction, type BylineCreditInput, type BylineCustomFieldValue, type BylineFieldDefinition, type BylineFieldType, type BylineFieldUsage, type BylineFieldValidation, type BylineInput, type BylineSummary, type BylineTranslationInput, CAPABILITY_LABELS, type CollectionSchemaStatus, type CollectionStats, type CommentCounts, type CommentStatus, type ContentAuthor, type ContentDateField, ContentEditor, type ContentEditorPanelContext, type ContentEditorPanelExtension, type ContentEditorProps, type ContentItem, ContentList, type ContentListColumn, type ContentListColumnCellContext, type ContentListColumnExtension, type ContentListColumnHeaderContext, type ContentListProps, type ContentSeo, type ContentSeoInput, type CreateAllowedDomainInput, type CreateApiTokenInput, type CreateBylineFieldInput, type CreateCollectionInput, type CreateContentInput, type CreateFieldInput, type CreateMenuInput, type CreateMenuItemInput, type CreateRedirectInput, type CreateSectionInput, type CreateTaxonomyInput, type CreateTermInput, type CreateWidgetAreaInput, type CreateWidgetInput, type CurrentUser, type CustomTaxonomy, DEFAULT_LOCALE, Dashboard, type DashboardProps, type DashboardStats, EditorHeader, type EditorHeaderProps, type EmailProvider, type EmailSettings, type FieldCompatibility, type FieldDescriptor, type FieldType, type FindManyResult, type GetSectionsOptions, Header, type ImportConfig, type ImportFieldDef, type ImportResult, type InstallPluginOpts, type InviteVerifyResult, Link, type LocalMediaItem, LoginPage, MEDIA_SEARCH_MAX_LENGTH, type MarketplaceAuditSummary, type MarketplaceAuthor, type MarketplaceImageAuditSummary, type MarketplacePluginDetail, type MarketplacePluginSummary, type MarketplaceSearchOpts, type MarketplaceSearchResult, type MarketplaceVersion, type MediaFolder, type MediaFolderListResult, type MediaImportProgress, type MediaImportResult, type MediaItem, MediaLibrary, type MediaLibraryProps, MediaPickerModal, type MediaPickerModalProps, type MediaProviderCapabilities, type MediaProviderInfo, type MediaProviderItem, type MediaUpdateInput, type MediaUploadOptions, MediaUsageAccessDeniedError, type MediaUsageCoverage, type MediaUsageCoverageStatus, type MediaUsageDetailsResponse, type MediaUsageEntryDetail, type MediaUsageOccurrenceDetail, type MediaUsageSourceDetail, type Menu, type MenuItem, type LocaleOptions as MenuLocaleOptions, type MenuTranslation, type MenuTranslationsResponse, type MenuWithItems, type NavMenu, type NotFoundSummary, type OrphanedTable, type PasskeyInfo, PasskeyLogin, type PasskeyLoginProps, PasskeyRegistration, type PasskeyRegistrationProps, type PluginAdminModule, PluginAdminProvider, type PluginAdmins, type PluginInfo, type PluginUpdateInfo, PortableTextEditor, type PortableTextEditorProps, type PostTypeAnalysis, type PrepareRequest, type PrepareResult, type PreviewUrlResponse, type ProbeResult, type RecentItem, type Redirect, type RedirectListOptions, type RedirectListResult, type ReorderMenuItemsInput, type Revision, type RevisionListResponse, type RewriteUrlsResult, SUPPORTED_LOCALES, SUPPORTED_LOCALE_CODES, SaveButton, type SaveButtonProps, type SchemaCollection, type SchemaCollectionWithFields, type SchemaField, type SearchEnableResult, type Section, type SectionSource, type SectionsResult, type SettingField, Settings, SetupWizard, Shell, type ShellProps, KumoSidebar as Sidebar, SidebarNav, type SidebarNavProps, type SignupVerifyResult, type SiteSettings, type SourceAuth, type SourceCapabilities, type SourceProbeResult, type SuggestedAction, type LocaleDefinition as SupportedLocale, type TaxonomyDef, type TaxonomyTerm, type TermTranslation, type TermTranslationsResponse, type ThemeAuthor, type ThemeAuthorDetail, type ThemeDetail, type ThemeSearchOpts, type ThemeSearchResult, type ThemeSummary, type TranslationSummary, type TranslationsResponse, type TrashedContentItem, type UninstallPluginOpts, type UpdateAllowedDomainInput, type UpdateBylineFieldInput, type UpdateCollectionInput, type UpdateContentInput, type UpdateFieldInput, type UpdateMenuInput, type UpdateMenuItemInput, type UpdatePluginOpts, type UpdateRedirectInput, type UpdateSectionInput, type UpdateTermInput, type UpdateUserInput, type UpdateWidgetInput, type UploadMediaOptions, type UserDetail, type UserListItem, type Widget, type WidgetArea, type WidgetComponent, type WpAuthorInfo, type WpImportProgress, type WpPluginAnalysis, type WxrAnalysis, analyzeWpPluginSite, analyzeWxr, apiFetch, bulkCommentAction, checkPluginUpdates, cn, compareRevisions, completeSignup, createAdminRouter, createAllowedDomain, createApiToken, createByline, createBylineField, createBylineTranslation, createCollection, createContent, createField, createMediaFolder, createMenu, createMenuItem, createMenuTranslation, createRedirect, createSection, createTaxonomy, createTerm, createTermTranslation, createWidget, createWidgetArea, deleteAllowedDomain, deleteByline, deleteBylineField, deleteCollection, deleteComment, deleteContent, deleteField, deleteFromProvider, deleteMedia, deleteMediaFolder, deleteMenu, deleteMenuItem, deletePasskey, deleteRedirect, deleteSection, deleteTerm, deleteWidget, deleteWidgetArea, describeCapability, disablePlugin, disableUser, discardDraft, duplicateContent, enablePlugin, enableUser, executeWpPluginImport, executeWxrImport, fetch404Summary, fetchAllowedDomains, fetchApiTokens, fetchAuthMode, fetchByline, fetchBylineTranslations, fetchBylines, fetchCollection, fetchCollections, fetchComment, fetchCommentCounts, fetchComments, fetchContent, fetchContentAuthors, fetchContentList, fetchDashboardStats, fetchEmailSettings, fetchFields, fetchManifest, fetchMarketplacePlugin, fetchMediaFolder, fetchMediaFolders, fetchMediaItem, fetchMediaList, fetchMediaProviders, fetchMediaUsageDetails, fetchMenu, fetchMenuTranslations, fetchMenus, fetchOrphanedTables, fetchPasskeys, fetchPlugin, fetchPluginSettings, fetchPlugins, fetchProviderMedia, fetchRedirects, fetchRevision, fetchRevisions, fetchSection, fetchSections, fetchSettings, fetchTaxonomyDef, fetchTaxonomyDefs, fetchTermTranslations, fetchTerms, fetchTheme, fetchTranslations, fetchTrashedContent, fetchUser, fetchUsers, fetchWidgetArea, fetchWidgetAreas, fetchWidgetComponents, generatePreviewUrl, getBylineFieldUsage, getDraftStatus, getPreviewUrl, hasAllowedDomains, importWxrMedia, importWxrMediaBatched, installMarketplacePlugin, inviteUser, isTerminalRequestError, listBylineFields, parseApiResponse, permanentDeleteContent, prepareWxrImport, probeImportUrl, publishContent, registerOrphanedTable, renameMediaFolder, renamePasskey, reorderBylineFields, reorderCollections, reorderFields, reorderMenuItems, reorderWidgets, requestSignup, resolveLocale, restoreContent, restoreRevision, revokeApiToken, rewriteContentUrls, scheduleContent, searchMarketplace, searchThemes, sendRecoveryLink, sendTestEmail, setPluginMcpEnabled, setSearchEnabled, throwResponseError, uninstallMarketplacePlugin, unpublishContent, unscheduleContent, updateAllowedDomain, updateByline, updateBylineField, updateCollection, updateCommentStatus, updateContent, updateField, updateMarketplacePlugin, updateMedia, updateMenu, updateMenuItem, updatePluginSettings, updateRedirect, updateSection, updateSettings, updateTerm, updateUser, updateWidget, uploadMedia, uploadToProvider, useAuthProviderList, useAuthProviders, useCurrentUser, useLocale, useNavigate, useParams, usePluginAdmins, usePluginField, usePluginHasPages, usePluginHasWidgets, usePluginPage, usePluginWidget, validateInviteToken, verifySignupToken };
|
|
3588
3722
|
//# sourceMappingURL=index.d.ts.map
|