convex-cms 0.0.7-alpha.0 → 0.0.8

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (134) hide show
  1. package/README.md +22 -17
  2. package/admin/src/components/BreakingChangesWarningDialog.tsx +5 -5
  3. package/admin/src/components/BulkOperationModal.tsx +14 -14
  4. package/admin/src/components/ContentEntryEditor.tsx +6 -6
  5. package/admin/src/components/ContentTypeFormModal.tsx +1 -1
  6. package/admin/src/components/Header.tsx +5 -2
  7. package/admin/src/components/SchemaDriftWarning.tsx +126 -0
  8. package/admin/src/components/TaxonomyEditor.tsx +2 -2
  9. package/admin/src/components/TermTree.tsx +3 -3
  10. package/admin/src/components/UploadDropzone.tsx +7 -7
  11. package/admin/src/components/VersionCompare.tsx +13 -13
  12. package/admin/src/components/VersionHistory.tsx +2 -2
  13. package/admin/src/components/VersionRollbackModal.tsx +5 -5
  14. package/admin/src/components/cmsds/CmsButton.tsx +2 -2
  15. package/admin/src/components/cmsds/CmsDialog.tsx +4 -1
  16. package/admin/src/components/cmsds/CmsStatusBadge.tsx +5 -5
  17. package/admin/src/components/fields/JsonField.tsx +1 -1
  18. package/admin/src/components/fields/TagField.tsx +1 -1
  19. package/admin/src/contexts/SettingsConfigContext.tsx +10 -3
  20. package/admin/src/embed/index.tsx +29 -9
  21. package/admin/src/embed/pages/ContentTypeEntries.tsx +25 -0
  22. package/admin/src/embed/pages/Entry.tsx +114 -0
  23. package/admin/src/embed/pages/Media.tsx +3 -1
  24. package/admin/src/embed/pages/NewEntry.tsx +83 -0
  25. package/admin/src/embed/pages/index.ts +3 -0
  26. package/admin/src/pages/ContentPage.tsx +16 -1
  27. package/admin/src/pages/ContentTypeEntriesPage.tsx +466 -0
  28. package/admin/src/pages/ContentTypesPage.tsx +3 -3
  29. package/admin/src/pages/DashboardPage.tsx +3 -0
  30. package/admin/src/pages/SettingsPage.tsx +4 -4
  31. package/admin/src/pages/index.ts +1 -0
  32. package/admin/src/routes/__root.tsx +10 -10
  33. package/admin/src/styles/globals.css +31 -5
  34. package/admin/src/styles/tailwind-config.css +25 -0
  35. package/admin/src/styles/theme.css +50 -0
  36. package/admin-dist/nitro.json +1 -1
  37. package/admin-dist/public/assets/{CmsEmptyState-CXVkI3FZ.js → CmsEmptyState-6-PLaXtD.js} +1 -1
  38. package/admin-dist/public/assets/{CmsPageHeader-DU9fD34s.js → CmsPageHeader-SoF4Epu9.js} +1 -1
  39. package/admin-dist/public/assets/CmsStatusBadge-D7kYaohx.js +1 -0
  40. package/admin-dist/public/assets/{CmsSurface-DF7OcKg_.js → CmsSurface-BvksBm6W.js} +1 -1
  41. package/admin-dist/public/assets/{CmsToolbar-5S8FQrSx.js → CmsToolbar-DlZPMe2B.js} +1 -1
  42. package/admin-dist/public/assets/ContentEntryEditor-C6n9xLS9.js +4 -0
  43. package/admin-dist/public/assets/{TaxonomyFilter-DEN2Q9Lo.js → TaxonomyFilter-CFX1_g8s.js} +1 -1
  44. package/admin-dist/public/assets/{_contentTypeId-Ba5iowxH.js → _contentTypeId-DTv8UoTp.js} +1 -1
  45. package/admin-dist/public/assets/_entryId-D3lr5Dvy.js +1 -0
  46. package/admin-dist/public/assets/alert-BAHTL6ao.js +1 -0
  47. package/admin-dist/public/assets/badge-oJv4Eai8.js +1 -0
  48. package/admin-dist/public/assets/{circle-check-big-B7eCOM8r.js → circle-check-big-3OHxNDhO.js} +1 -1
  49. package/admin-dist/public/assets/{command-BIjzeKOv.js → command-DwgQs69u.js} +1 -1
  50. package/admin-dist/public/assets/content-CKQ4QwW2.js +1 -0
  51. package/admin-dist/public/assets/content-types-BrttaLpc.js +1 -0
  52. package/admin-dist/public/assets/globals-CoCRjt0K.css +1 -0
  53. package/admin-dist/public/assets/index-DOkgTSx0.js +1 -0
  54. package/admin-dist/public/assets/{main-BZB1uYTH.js → main-DV6oxWnU.js} +5 -5
  55. package/admin-dist/public/assets/media-B2i-mCbx.js +1 -0
  56. package/admin-dist/public/assets/new._contentTypeId-VF63rpic.js +1 -0
  57. package/admin-dist/public/assets/{pencil-BDQ1ZWRw.js → pencil-CX1CiTDD.js} +1 -1
  58. package/admin-dist/public/assets/refresh-cw-Cm-YOeFI.js +1 -0
  59. package/admin-dist/public/assets/{rotate-ccw-BWblSIsl.js → rotate-ccw-B45JsL5f.js} +1 -1
  60. package/admin-dist/public/assets/{scroll-area-BoaB6x8v.js → scroll-area-b3A1HHR7.js} +1 -1
  61. package/admin-dist/public/assets/{search-CYMIpd39.js → search-DKKh_DdH.js} +1 -1
  62. package/admin-dist/public/assets/settings-CGVDEV1r.js +1 -0
  63. package/admin-dist/public/assets/{switch-DN7TOCa5.js → switch-BTMY8Qnk.js} +1 -1
  64. package/admin-dist/public/assets/tabs-DUQwUoIb.js +1 -0
  65. package/admin-dist/public/assets/{tanstack-adapter-DQcKErwf.js → tanstack-adapter-f7AHmQ5L.js} +1 -1
  66. package/admin-dist/public/assets/taxonomies-DvMppdiD.js +1 -0
  67. package/admin-dist/public/assets/{trash-Dp_a2mpb.js → trash-D7e0uKd9.js} +1 -1
  68. package/admin-dist/public/assets/{useBreadcrumbLabel-BQ9dJI6T.js → useBreadcrumbLabel-CF2KYwsw.js} +1 -1
  69. package/admin-dist/public/assets/{usePermissions-WUBNg_Id.js → usePermissions-DWBImEOW.js} +1 -1
  70. package/admin-dist/server/_libs/lucide-react.mjs +50 -43
  71. package/admin-dist/server/_ssr/{CmsEmptyState-DYh_PPQE.mjs → CmsEmptyState-BM8DghTl.mjs} +1 -1
  72. package/admin-dist/server/_ssr/{CmsPageHeader-BcniLh49.mjs → CmsPageHeader-BHUmrIWD.mjs} +1 -1
  73. package/admin-dist/server/_ssr/{CmsStatusBadge-BShWDxwE.mjs → CmsStatusBadge-D0Zb0oRl.mjs} +7 -7
  74. package/admin-dist/server/_ssr/{CmsSurface-CHEv-Kba.mjs → CmsSurface-B2eBr-47.mjs} +1 -1
  75. package/admin-dist/server/_ssr/{CmsToolbar-Dqqb216_.mjs → CmsToolbar-BCrwg7OL.mjs} +1 -1
  76. package/admin-dist/server/_ssr/{ContentEntryEditor-DOIAyWME.mjs → ContentEntryEditor-Cjfm0uhr.mjs} +37 -37
  77. package/admin-dist/server/_ssr/{TaxonomyFilter-BfsPAZ-Y.mjs → TaxonomyFilter-C4pD0kfM.mjs} +3 -3
  78. package/admin-dist/server/_ssr/{_contentTypeId-CPjmri90.mjs → _contentTypeId-CiDiX-p7.mjs} +11 -11
  79. package/admin-dist/server/_ssr/{_entryId-D0yu8HuP.mjs → _entryId-9GxatOkL.mjs} +11 -11
  80. package/admin-dist/server/_ssr/_tanstack-start-manifest_v-CC7UrHKE.mjs +4 -0
  81. package/admin-dist/server/_ssr/{badge-Cp61aQNc.mjs → badge-EI998zba.mjs} +1 -1
  82. package/admin-dist/server/_ssr/{command-BfjE1WJf.mjs → command-BLAWQhUw.mjs} +1 -1
  83. package/admin-dist/server/_ssr/{content-DrODe6sA.mjs → content-BHX39L4D.mjs} +31 -22
  84. package/admin-dist/server/_ssr/{content-types-BPgMwxiT.mjs → content-types-DCzrBhTH.mjs} +9 -9
  85. package/admin-dist/server/_ssr/{index-BTHmIC9W.mjs → index-DwM_5VNP.mjs} +92 -6
  86. package/admin-dist/server/_ssr/index.mjs +2 -2
  87. package/admin-dist/server/_ssr/{media-DkvBfmD9.mjs → media-CbzgTRRQ.mjs} +9 -9
  88. package/admin-dist/server/_ssr/{new._contentTypeId-Co_73sDJ.mjs → new._contentTypeId-6Ph-Gtlw.mjs} +10 -10
  89. package/admin-dist/server/_ssr/{router-CaDgRHfQ.mjs → router-vd1nySeP.mjs} +45 -35
  90. package/admin-dist/server/_ssr/{scroll-area-D3v-O_jk.mjs → scroll-area--B9snFTJ.mjs} +1 -1
  91. package/admin-dist/server/_ssr/{settings-MaEXh2Hz.mjs → settings-DlTO2JSj.mjs} +11 -11
  92. package/admin-dist/server/_ssr/{switch-DmbR03dm.mjs → switch-C05NgNW0.mjs} +1 -1
  93. package/admin-dist/server/_ssr/{tabs-5oFlAGLz.mjs → tabs-DAk2J5xy.mjs} +8 -8
  94. package/admin-dist/server/_ssr/{tanstack-adapter-DNaUioIZ.mjs → tanstack-adapter-DWbaPByn.mjs} +15 -1
  95. package/admin-dist/server/_ssr/{taxonomies-D3xMK23a.mjs → taxonomies-B8nqce6u.mjs} +12 -12
  96. package/admin-dist/server/_ssr/{trash-CNw1mtF1.mjs → trash-zdlZgpTo.mjs} +7 -7
  97. package/admin-dist/server/_ssr/{useBreadcrumbLabel-BQGjOTcy.mjs → useBreadcrumbLabel-DpEKyG1h.mjs} +1 -1
  98. package/admin-dist/server/_ssr/{usePermissions-D0qtvmNi.mjs → usePermissions-olYRd9S9.mjs} +1 -1
  99. package/admin-dist/server/index.mjs +164 -157
  100. package/dist/client/admin/contentTypes.d.ts +25 -0
  101. package/dist/client/admin/contentTypes.d.ts.map +1 -1
  102. package/dist/client/admin/contentTypes.js +212 -6
  103. package/dist/client/admin/contentTypes.js.map +1 -1
  104. package/dist/client/admin/entries.d.ts.map +1 -1
  105. package/dist/client/admin/entries.js +27 -0
  106. package/dist/client/admin/entries.js.map +1 -1
  107. package/dist/client/admin/index.d.ts +4 -0
  108. package/dist/client/admin/index.d.ts.map +1 -1
  109. package/dist/client/admin/index.js +16 -0
  110. package/dist/client/admin/index.js.map +1 -1
  111. package/dist/client/admin/types.d.ts +4 -0
  112. package/dist/client/admin/types.d.ts.map +1 -1
  113. package/dist/client/schema/defineContentType.d.ts.map +1 -1
  114. package/dist/client/schema/defineContentType.js +99 -80
  115. package/dist/client/schema/defineContentType.js.map +1 -1
  116. package/dist/component/contentTypeMutations.d.ts.map +1 -1
  117. package/dist/component/contentTypeMutations.js +5 -4
  118. package/dist/component/contentTypeMutations.js.map +1 -1
  119. package/package.json +2 -2
  120. package/admin-dist/public/assets/CmsStatusBadge-nZ9TeLBL.js +0 -1
  121. package/admin-dist/public/assets/ContentEntryEditor-BDb44eTo.js +0 -4
  122. package/admin-dist/public/assets/_entryId-OY3sLz6O.js +0 -1
  123. package/admin-dist/public/assets/alert-BbW1Q9CR.js +0 -1
  124. package/admin-dist/public/assets/badge-DdM8Eua8.js +0 -1
  125. package/admin-dist/public/assets/content-BV3YeSSW.js +0 -1
  126. package/admin-dist/public/assets/content-types-Bm4b2tf8.js +0 -1
  127. package/admin-dist/public/assets/globals-D41WzvyZ.css +0 -1
  128. package/admin-dist/public/assets/index-DnJ5Twlv.js +0 -1
  129. package/admin-dist/public/assets/media-BIMN5jXt.js +0 -1
  130. package/admin-dist/public/assets/new._contentTypeId-DTWb8ZDl.js +0 -1
  131. package/admin-dist/public/assets/settings-DaNDUtr5.js +0 -1
  132. package/admin-dist/public/assets/tabs-RN__emeJ.js +0 -1
  133. package/admin-dist/public/assets/taxonomies-DylY9HE1.js +0 -1
  134. package/admin-dist/server/_ssr/_tanstack-start-manifest_v-DgCpSt_y.mjs +0 -4
@@ -1,9 +1,9 @@
1
- import { j as jsxRuntimeExports } from "../_chunks/_libs/react.mjs";
2
- import { h as api, f as cn } from "./router-CaDgRHfQ.mjs";
3
- import { C as CmsPageHeader } from "./CmsPageHeader-BcniLh49.mjs";
4
- import { u as useTanStackNavigation } from "./tanstack-adapter-DNaUioIZ.mjs";
5
- import { u as useQuery } from "../_libs/convex.mjs";
6
- import { Q as FileText, O as Image, a as Layers, J as Settings, am as TrendingUp } from "../_libs/lucide-react.mjs";
1
+ import { j as jsxRuntimeExports, r as reactExports } from "../_chunks/_libs/react.mjs";
2
+ import { h as api, B as Button, f as cn } from "./router-vd1nySeP.mjs";
3
+ import { C as CmsPageHeader } from "./CmsPageHeader-BHUmrIWD.mjs";
4
+ import { u as useTanStackNavigation, A as Alert, b as AlertTitle, a as AlertDescription } from "./tanstack-adapter-DWbaPByn.mjs";
5
+ import { u as useQuery, d as useMutation } from "../_libs/convex.mjs";
6
+ import { Q as FileText, O as Image, a as Layers, J as Settings, am as TrendingUp, j as CircleAlert, an as CircleX, a0 as TriangleAlert, ao as RefreshCw } from "../_libs/lucide-react.mjs";
7
7
  import "../_chunks/_libs/@tanstack/react-router.mjs";
8
8
  import "../_libs/tiny-warning.mjs";
9
9
  import "../_chunks/_libs/@tanstack/router-core.mjs";
@@ -138,6 +138,91 @@ function Skeleton({ className, ...props }) {
138
138
  }
139
139
  );
140
140
  }
141
+ function SchemaDriftWarning({ api: api2 }) {
142
+ const driftResults = useQuery(api2.checkSchemaDrift, {});
143
+ const syncMutation = useMutation(api2.syncCodeDefinedTypes);
144
+ const [isSyncing, setIsSyncing] = reactExports.useState(false);
145
+ const [syncResult, setSyncResult] = reactExports.useState(null);
146
+ if (driftResults === void 0) {
147
+ return null;
148
+ }
149
+ if (!driftResults || driftResults.length === 0) {
150
+ if (syncResult && (syncResult.created > 0 || syncResult.updated > 0)) {
151
+ return /* @__PURE__ */ jsxRuntimeExports.jsxs(Alert, { className: "border-success/50 bg-success/10", children: [
152
+ /* @__PURE__ */ jsxRuntimeExports.jsx(CircleAlert, { className: "size-4 text-success" }),
153
+ /* @__PURE__ */ jsxRuntimeExports.jsx(AlertTitle, { className: "text-diff-added-foreground", children: "Sync Complete" }),
154
+ /* @__PURE__ */ jsxRuntimeExports.jsxs(AlertDescription, { className: "text-diff-added-foreground/80", children: [
155
+ syncResult.created > 0 && /* @__PURE__ */ jsxRuntimeExports.jsxs("span", { children: [
156
+ syncResult.created,
157
+ " content type(s) created. "
158
+ ] }),
159
+ syncResult.updated > 0 && /* @__PURE__ */ jsxRuntimeExports.jsxs("span", { children: [
160
+ syncResult.updated,
161
+ " content type(s) updated."
162
+ ] })
163
+ ] })
164
+ ] });
165
+ }
166
+ return null;
167
+ }
168
+ const errors = driftResults.filter((d) => d.severity === "error");
169
+ const warnings = driftResults.filter((d) => d.severity === "warning");
170
+ const handleSync = async () => {
171
+ setIsSyncing(true);
172
+ setSyncResult(null);
173
+ try {
174
+ const result = await syncMutation({});
175
+ setSyncResult(result);
176
+ } catch (error) {
177
+ console.error("Sync failed:", error);
178
+ } finally {
179
+ setIsSyncing(false);
180
+ }
181
+ };
182
+ const variant = errors.length > 0 ? "destructive" : "default";
183
+ const Icon = errors.length > 0 ? CircleX : TriangleAlert;
184
+ const iconColor = errors.length > 0 ? "text-destructive" : "text-warning";
185
+ return /* @__PURE__ */ jsxRuntimeExports.jsxs(Alert, { variant, className: errors.length === 0 ? "border-warning/50 bg-warning/10" : "", children: [
186
+ /* @__PURE__ */ jsxRuntimeExports.jsx(Icon, { className: `size-4 ${iconColor}` }),
187
+ /* @__PURE__ */ jsxRuntimeExports.jsx(AlertTitle, { className: errors.length === 0 ? "text-diff-modified-foreground" : "", children: "Schema Drift Detected" }),
188
+ /* @__PURE__ */ jsxRuntimeExports.jsx(AlertDescription, { className: errors.length === 0 ? "text-diff-modified-foreground/80" : "", children: /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "space-y-2", children: [
189
+ errors.length > 0 && /* @__PURE__ */ jsxRuntimeExports.jsxs("p", { children: [
190
+ /* @__PURE__ */ jsxRuntimeExports.jsxs("strong", { children: [
191
+ errors.length,
192
+ " error(s)"
193
+ ] }),
194
+ ":",
195
+ " ",
196
+ errors.slice(0, 3).map((e) => e.message).join(" "),
197
+ errors.length > 3 && ` ...and ${errors.length - 3} more`
198
+ ] }),
199
+ warnings.length > 0 && /* @__PURE__ */ jsxRuntimeExports.jsxs("p", { children: [
200
+ /* @__PURE__ */ jsxRuntimeExports.jsxs("strong", { children: [
201
+ warnings.length,
202
+ " warning(s)"
203
+ ] }),
204
+ ": Code-defined types may need syncing."
205
+ ] }),
206
+ /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "mt-3 flex items-center gap-2", children: [
207
+ /* @__PURE__ */ jsxRuntimeExports.jsxs(
208
+ Button,
209
+ {
210
+ size: "sm",
211
+ variant: errors.length > 0 ? "destructive" : "outline",
212
+ onClick: handleSync,
213
+ disabled: isSyncing,
214
+ className: errors.length === 0 ? "border-warning/50 text-diff-modified-foreground hover:bg-warning/20" : "",
215
+ children: [
216
+ /* @__PURE__ */ jsxRuntimeExports.jsx(RefreshCw, { className: `mr-1.5 size-3.5 ${isSyncing ? "animate-spin" : ""}` }),
217
+ isSyncing ? "Syncing..." : "Sync Now"
218
+ ]
219
+ }
220
+ ),
221
+ /* @__PURE__ */ jsxRuntimeExports.jsx("span", { className: "text-xs opacity-75", children: "Syncs code-defined types to the database" })
222
+ ] })
223
+ ] }) })
224
+ ] });
225
+ }
141
226
  function DashboardPage({ api: api2, navigation }) {
142
227
  const stats = useQuery(api2.getDashboardStats, {});
143
228
  const isLoading = stats === void 0;
@@ -150,6 +235,7 @@ function DashboardPage({ api: api2, navigation }) {
150
235
  description: "Welcome to Convex CMS Admin. Manage your content, media, and publishing workflows."
151
236
  }
152
237
  ),
238
+ /* @__PURE__ */ jsxRuntimeExports.jsx(SchemaDriftWarning, { api: api2 }),
153
239
  /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "grid gap-4 sm:grid-cols-2 lg:grid-cols-4", children: [
154
240
  /* @__PURE__ */ jsxRuntimeExports.jsx(
155
241
  DashboardCard,
@@ -3837,7 +3837,7 @@ function getResponse() {
3837
3837
  return event.res;
3838
3838
  }
3839
3839
  async function getStartManifest(matchedRoutes) {
3840
- const { tsrStartManifest } = await import("./_tanstack-start-manifest_v-DgCpSt_y.mjs");
3840
+ const { tsrStartManifest } = await import("./_tanstack-start-manifest_v-CC7UrHKE.mjs");
3841
3841
  const startManifest = tsrStartManifest();
3842
3842
  const rootRoute = startManifest.routes[rootRouteId] = startManifest.routes[rootRouteId] || {};
3843
3843
  rootRoute.assets = rootRoute.assets || [];
@@ -4312,7 +4312,7 @@ function getStartResponseHeaders(opts) {
4312
4312
  let entriesPromise;
4313
4313
  let manifestPromise;
4314
4314
  async function loadEntries() {
4315
- const routerEntry = await import("./router-CaDgRHfQ.mjs").then((n2) => n2.M);
4315
+ const routerEntry = await import("./router-vd1nySeP.mjs").then((n2) => n2.M);
4316
4316
  const startEntry = await import("./start-HYkvq4Ni.mjs");
4317
4317
  return { startEntry, routerEntry };
4318
4318
  }
@@ -1,13 +1,13 @@
1
1
  import { j as jsxRuntimeExports, r as reactExports } from "../_chunks/_libs/react.mjs";
2
- import { t as useSettingsConfig, h as api, f as cn, C as CmsButton, I as Input, S as Select, a as SelectTrigger, b as SelectValue, c as SelectContent, d as SelectItem, e as Checkbox, D as Dialog, k as DialogContent, r as DialogHeader, l as DialogTitle, L as Label, s as DialogFooter, g as CmsConfirmDialog, m as DropdownMenu, n as DropdownMenuTrigger, o as DropdownMenuContent, p as DropdownMenuItem, q as DropdownMenuSeparator, i as CmsDialog, T as Textarea, B as Button } from "./router-CaDgRHfQ.mjs";
3
- import { B as Badge } from "./badge-Cp61aQNc.mjs";
4
- import { T as Tabs, a as TabsList, b as TabsTrigger, U as UploadDropzone } from "./tabs-5oFlAGLz.mjs";
5
- import { C as CmsPageHeader } from "./CmsPageHeader-BcniLh49.mjs";
6
- import { C as CmsToolbar } from "./CmsToolbar-Dqqb216_.mjs";
7
- import { C as CmsEmptyState } from "./CmsEmptyState-DYh_PPQE.mjs";
8
- import { T as TaxonomyFilter } from "./TaxonomyFilter-BfsPAZ-Y.mjs";
2
+ import { t as useSettingsConfig, h as api, f as cn, C as CmsButton, I as Input, S as Select, a as SelectTrigger, b as SelectValue, c as SelectContent, d as SelectItem, e as Checkbox, D as Dialog, k as DialogContent, r as DialogHeader, l as DialogTitle, L as Label, s as DialogFooter, g as CmsConfirmDialog, m as DropdownMenu, n as DropdownMenuTrigger, o as DropdownMenuContent, p as DropdownMenuItem, q as DropdownMenuSeparator, i as CmsDialog, T as Textarea, B as Button } from "./router-vd1nySeP.mjs";
3
+ import { B as Badge } from "./badge-EI998zba.mjs";
4
+ import { u as useTanStackNavigation } from "./tanstack-adapter-DWbaPByn.mjs";
5
+ import { T as Tabs, a as TabsList, b as TabsTrigger, U as UploadDropzone } from "./tabs-DAk2J5xy.mjs";
6
+ import { C as CmsPageHeader } from "./CmsPageHeader-BHUmrIWD.mjs";
7
+ import { C as CmsToolbar } from "./CmsToolbar-BCrwg7OL.mjs";
8
+ import { C as CmsEmptyState } from "./CmsEmptyState-BM8DghTl.mjs";
9
+ import { T as TaxonomyFilter } from "./TaxonomyFilter-C4pD0kfM.mjs";
9
10
  import { a as VisuallyHidden } from "../_chunks/_libs/@radix-ui/react-visually-hidden.mjs";
10
- import { u as useTanStackNavigation } from "./tanstack-adapter-DNaUioIZ.mjs";
11
11
  import { u as useQuery, d as useMutation } from "../_libs/convex.mjs";
12
12
  import { O as Image, I as Trash2, H as House, a9 as ChevronLeft, aa as FolderPlus, ab as Upload, a1 as Search, X, s as Folder, a2 as RotateCcw, ac as Ellipsis, a3 as Pencil, ad as FolderInput, ae as EllipsisVertical, k as Eye, af as Download, Z as Link2, ag as File, Q as FileText, ah as Music, ai as Video, aj as Copy, h as ChevronRight, W as Tag, L as LoaderCircle, P as Plus } from "../_libs/lucide-react.mjs";
13
13
  import "../_chunks/_libs/@tanstack/react-router.mjs";
@@ -78,7 +78,7 @@ import "./index.mjs";
78
78
  import "node:async_hooks";
79
79
  import "../_libs/zod.mjs";
80
80
  import "../_chunks/_libs/@radix-ui/react-tabs.mjs";
81
- import "./command-BfjE1WJf.mjs";
81
+ import "./command-BLAWQhUw.mjs";
82
82
  import "../_libs/cmdk.mjs";
83
83
  function CmsField({
84
84
  label,
@@ -1,9 +1,9 @@
1
1
  import { j as jsxRuntimeExports } from "../_chunks/_libs/react.mjs";
2
2
  import { d as useNavigate } from "../_chunks/_libs/@tanstack/react-router.mjs";
3
- import { H as Route, h as api } from "./router-CaDgRHfQ.mjs";
4
- import { C as ContentEntryEditor } from "./ContentEntryEditor-DOIAyWME.mjs";
5
- import { u as useBreadcrumbLabel } from "./useBreadcrumbLabel-BQGjOTcy.mjs";
6
- import { C as CmsEmptyState } from "./CmsEmptyState-DYh_PPQE.mjs";
3
+ import { H as Route, h as api } from "./router-vd1nySeP.mjs";
4
+ import { C as ContentEntryEditor } from "./ContentEntryEditor-Cjfm0uhr.mjs";
5
+ import { u as useBreadcrumbLabel } from "./useBreadcrumbLabel-DpEKyG1h.mjs";
6
+ import { C as CmsEmptyState } from "./CmsEmptyState-BM8DghTl.mjs";
7
7
  import { u as useQuery } from "../_libs/convex.mjs";
8
8
  import { Q as FileText } from "../_libs/lucide-react.mjs";
9
9
  import "../_libs/tiny-warning.mjs";
@@ -73,16 +73,16 @@ import "../_chunks/_libs/@radix-ui/react-popover.mjs";
73
73
  import "./index.mjs";
74
74
  import "node:async_hooks";
75
75
  import "../_libs/zod.mjs";
76
- import "./switch-DmbR03dm.mjs";
76
+ import "./switch-C05NgNW0.mjs";
77
77
  import "../_chunks/_libs/@radix-ui/react-switch.mjs";
78
78
  import "../_chunks/_libs/@radix-ui/react-separator.mjs";
79
- import "./tabs-5oFlAGLz.mjs";
79
+ import "./tabs-DAk2J5xy.mjs";
80
80
  import "../_chunks/_libs/@radix-ui/react-tabs.mjs";
81
- import "./command-BfjE1WJf.mjs";
81
+ import "./command-BLAWQhUw.mjs";
82
82
  import "../_libs/cmdk.mjs";
83
- import "./badge-Cp61aQNc.mjs";
84
- import "./CmsStatusBadge-BShWDxwE.mjs";
85
- import "./scroll-area-D3v-O_jk.mjs";
83
+ import "./badge-EI998zba.mjs";
84
+ import "./CmsStatusBadge-D0Zb0oRl.mjs";
85
+ import "./scroll-area--B9snFTJ.mjs";
86
86
  import "../_chunks/_libs/@radix-ui/react-scroll-area.mjs";
87
87
  import "../_libs/react-day-picker.mjs";
88
88
  import "../_libs/date-fns.mjs";
@@ -13,7 +13,7 @@ import { R as Root2$1, T as Trigger$1, P as Portal2, C as Content2$1, L as Label
13
13
  import { R as Root, I as Image, F as Fallback } from "../_chunks/_libs/@radix-ui/react-avatar.mjs";
14
14
  import { R as Root2, T as Trigger, P as Portal, C as Content2 } from "../_chunks/_libs/@radix-ui/react-popover.mjs";
15
15
  import { c as createServerFn, T as TSS_SERVER_FUNCTION, g as getServerFnById } from "./index.mjs";
16
- import { v, c as componentsGeneric, C as ConvexReactClient, a as ConvexProvider, u as useQuery, b as anyApi, d as useMutation } from "../_libs/convex.mjs";
16
+ import { v, c as componentsGeneric, C as ConvexReactClient, a as ConvexProvider, b as anyApi, u as useQuery, d as useMutation } from "../_libs/convex.mjs";
17
17
  import { L as LoaderCircle, a as Layers, H as House, B as Bell, C as CircleQuestionMark, b as Book, c as Code, M as MessageSquare, E as ExternalLink, d as ChevronDown, U as User, e as LogOut, f as CodeXml, P as Plus, g as ChevronUp, X, h as ChevronRight, i as Check, j as CircleAlert, k as Eye, S as SquarePen, A as Archive, l as Bookmark, F as Flag, m as Heart, n as Star, o as Package, p as Phone, q as Mail, D as DollarSign, r as MapPin, s as Folder, t as Braces, u as SquareCheckBig, T as ToggleLeft, v as Hash, w as Link$1, x as Clock, y as Calendar, G as Globe, z as Lock, I as Trash2, J as Settings, K as FileCode, N as Tags, O as Image$1, Q as FileText, R as LayoutDashboard, V as FolderOpen, W as Tag, Y as List, Z as Link2, _ as FileType, $ as TextAlignStart, a0 as TriangleAlert } from "../_libs/lucide-react.mjs";
18
18
  import { o as object, b as boolean, s as string, _ as _enum, n as number, a as array, r as record } from "../_libs/zod.mjs";
19
19
  import "../_libs/tiny-warning.mjs";
@@ -69,7 +69,7 @@ import "../_chunks/_libs/@radix-ui/react-menu.mjs";
69
69
  import "../_chunks/_libs/@radix-ui/react-roving-focus.mjs";
70
70
  import "../_chunks/_libs/@radix-ui/react-use-is-hydrated.mjs";
71
71
  import "node:async_hooks";
72
- const globalsCss = "/assets/globals-D41WzvyZ.css";
72
+ const globalsCss = "/assets/globals-CoCRjt0K.css";
73
73
  function cn(...inputs) {
74
74
  return twMerge(clsx(inputs));
75
75
  }
@@ -480,9 +480,11 @@ componentsGeneric();
480
480
  const SettingsConfigContext = reactExports.createContext(null);
481
481
  function SettingsConfigProvider({
482
482
  baseConfig,
483
- children
483
+ children,
484
+ api: api$1
484
485
  }) {
485
- const settings = useQuery(api.admin.getSettings);
486
+ const resolvedApi = api$1 ?? api.admin;
487
+ const settings = useQuery(resolvedApi.getSettings);
486
488
  const mergedConfig = reactExports.useMemo(() => {
487
489
  if (!settings) return baseConfig;
488
490
  return {
@@ -757,8 +759,8 @@ const variantMap = {
757
759
  warning: "default"
758
760
  };
759
761
  const customVariantClasses = {
760
- success: "bg-emerald-600 text-white hover:bg-emerald-700 focus-visible:ring-emerald-500",
761
- warning: "bg-amber-500 text-white hover:bg-amber-600 focus-visible:ring-amber-500"
762
+ success: "bg-success text-success-foreground hover:bg-success/90 focus-visible:ring-success",
763
+ warning: "bg-warning text-warning-foreground hover:bg-warning/90 focus-visible:ring-warning"
762
764
  };
763
765
  const LoadingSpinner = () => /* @__PURE__ */ jsxRuntimeExports.jsxs(
764
766
  "svg",
@@ -858,7 +860,14 @@ function CmsDialog({
858
860
  /* @__PURE__ */ jsxRuntimeExports.jsx(DialogTitle, { children: title }),
859
861
  description && /* @__PURE__ */ jsxRuntimeExports.jsx(DialogDescription, { children: description })
860
862
  ] }),
861
- /* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "min-h-0 flex-1 py-4 scrollbar-none", children }),
863
+ /* @__PURE__ */ jsxRuntimeExports.jsx(
864
+ "div",
865
+ {
866
+ className: "min-h-0 flex-1 overflow-y-auto py-4 [&::-webkit-scrollbar]:hidden",
867
+ style: { scrollbarWidth: "none", msOverflowStyle: "none" },
868
+ children
869
+ }
870
+ ),
862
871
  footer && /* @__PURE__ */ jsxRuntimeExports.jsx(DialogFooter, { className: "shrink-0 border-t pt-4", children: footer })
863
872
  ]
864
873
  }
@@ -1141,11 +1150,11 @@ function BreakingChangesWarningDialog({
1141
1150
  /* @__PURE__ */ jsxRuntimeExports.jsx(CmsButton, { variant: "danger", onClick: onForceUpdate, loading: isLoading, children: "Force Update" })
1142
1151
  ] }),
1143
1152
  children: /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "space-y-4", children: [
1144
- /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex items-start gap-3 rounded-lg border border-amber-200 bg-amber-50 p-3", children: [
1145
- /* @__PURE__ */ jsxRuntimeExports.jsx(TriangleAlert, { className: "mt-0.5 size-5 shrink-0 text-amber-600" }),
1153
+ /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "diff-modified flex items-start gap-3 rounded-lg border p-3", children: [
1154
+ /* @__PURE__ */ jsxRuntimeExports.jsx(TriangleAlert, { className: "mt-0.5 size-5 shrink-0 text-diff-modified" }),
1146
1155
  /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "space-y-1", children: [
1147
- /* @__PURE__ */ jsxRuntimeExports.jsx("p", { className: "text-sm font-medium text-amber-800", children: "These changes may affect existing content" }),
1148
- /* @__PURE__ */ jsxRuntimeExports.jsx("p", { className: "text-sm text-amber-700", children: "The following changes could cause data loss or validation errors for existing entries. Review carefully before proceeding." })
1156
+ /* @__PURE__ */ jsxRuntimeExports.jsx("p", { className: "text-sm font-medium text-diff-modified", children: "These changes may affect existing content" }),
1157
+ /* @__PURE__ */ jsxRuntimeExports.jsx("p", { className: "text-sm text-diff-modified-foreground", children: "The following changes could cause data loss or validation errors for existing entries. Review carefully before proceeding." })
1149
1158
  ] })
1150
1159
  ] }),
1151
1160
  /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "space-y-2", children: [
@@ -1160,7 +1169,7 @@ function BreakingChangesWarningDialog({
1160
1169
  {
1161
1170
  className: "flex items-start gap-2 rounded-md border bg-muted/30 px-3 py-2 text-sm",
1162
1171
  children: [
1163
- /* @__PURE__ */ jsxRuntimeExports.jsx("span", { className: "mt-0.5 size-1.5 shrink-0 rounded-full bg-amber-500" }),
1172
+ /* @__PURE__ */ jsxRuntimeExports.jsx("span", { className: "mt-0.5 size-1.5 shrink-0 rounded-full bg-warning" }),
1164
1173
  /* @__PURE__ */ jsxRuntimeExports.jsx("span", { className: "text-muted-foreground", children: change })
1165
1174
  ]
1166
1175
  },
@@ -1912,7 +1921,7 @@ function ContentTypeFormModal({
1912
1921
  submitError && /* @__PURE__ */ jsxRuntimeExports.jsx(
1913
1922
  "div",
1914
1923
  {
1915
- className: "rounded-lg border border-red-200 bg-red-50 px-3 py-2 text-sm text-red-800",
1924
+ className: "diff-removed rounded-lg border px-3 py-2 text-sm",
1916
1925
  role: "alert",
1917
1926
  "data-testid": "submit-error",
1918
1927
  children: submitError
@@ -2399,10 +2408,11 @@ const routeLabels = {
2399
2408
  };
2400
2409
  function getBreadcrumbs(pathname, appName, overrides) {
2401
2410
  const breadcrumbs = [{ label: appName, to: "/" }];
2402
- if (pathname === "/") {
2411
+ const decodedPathname = decodeURIComponent(pathname);
2412
+ if (decodedPathname === "/") {
2403
2413
  return breadcrumbs;
2404
2414
  }
2405
- const segments = pathname.split("/").filter(Boolean);
2415
+ const segments = decodedPathname.split("/").filter(Boolean);
2406
2416
  let currentPath = "";
2407
2417
  segments.forEach((segment, index) => {
2408
2418
  currentPath += `/${segment}`;
@@ -2824,36 +2834,36 @@ function ConvexProviderWrapper({
2824
2834
  return new ConvexReactClient(config.convexUrl);
2825
2835
  }, [config.convexUrl]);
2826
2836
  if (!convex) {
2827
- return /* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "flex min-h-screen items-center justify-center bg-background p-6", children: /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "max-w-lg space-y-4 rounded-lg border border-amber-200 bg-amber-50 p-6 text-center", children: [
2828
- /* @__PURE__ */ jsxRuntimeExports.jsx("h2", { className: "text-xl font-semibold text-amber-900", children: "Convex Configuration Required" }),
2829
- /* @__PURE__ */ jsxRuntimeExports.jsx("p", { className: "text-sm text-amber-800", children: "Please provide a Convex deployment URL to connect to your backend." }),
2830
- /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "space-y-2 text-left text-sm text-amber-700", children: [
2837
+ return /* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "flex min-h-screen items-center justify-center bg-background p-6", children: /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "diff-modified max-w-lg space-y-4 rounded-lg border p-6 text-center", children: [
2838
+ /* @__PURE__ */ jsxRuntimeExports.jsx("h2", { className: "text-xl font-semibold text-diff-modified", children: "Convex Configuration Required" }),
2839
+ /* @__PURE__ */ jsxRuntimeExports.jsx("p", { className: "text-sm text-diff-modified-foreground", children: "Please provide a Convex deployment URL to connect to your backend." }),
2840
+ /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "space-y-2 text-left text-sm text-diff-modified-foreground", children: [
2831
2841
  /* @__PURE__ */ jsxRuntimeExports.jsx("p", { className: "font-medium", children: "Options:" }),
2832
2842
  /* @__PURE__ */ jsxRuntimeExports.jsxs("ul", { className: "list-inside list-disc space-y-1", children: [
2833
2843
  /* @__PURE__ */ jsxRuntimeExports.jsxs("li", { children: [
2834
2844
  "Run with URL:",
2835
2845
  " ",
2836
- /* @__PURE__ */ jsxRuntimeExports.jsx("code", { className: "rounded bg-amber-100 px-1", children: "npx convex-cms admin --url YOUR_URL" })
2846
+ /* @__PURE__ */ jsxRuntimeExports.jsx("code", { className: "rounded bg-diff-modified-bg/50 px-1", children: "npx convex-cms admin --url YOUR_URL" })
2837
2847
  ] }),
2838
2848
  /* @__PURE__ */ jsxRuntimeExports.jsxs("li", { children: [
2839
2849
  "Set environment variable:",
2840
2850
  " ",
2841
- /* @__PURE__ */ jsxRuntimeExports.jsx("code", { className: "rounded bg-amber-100 px-1", children: "CONVEX_URL=YOUR_URL" })
2851
+ /* @__PURE__ */ jsxRuntimeExports.jsx("code", { className: "rounded bg-diff-modified-bg/50 px-1", children: "CONVEX_URL=YOUR_URL" })
2842
2852
  ] }),
2843
2853
  /* @__PURE__ */ jsxRuntimeExports.jsxs("li", { children: [
2844
2854
  "Add to",
2845
2855
  " ",
2846
- /* @__PURE__ */ jsxRuntimeExports.jsx("code", { className: "rounded bg-amber-100 px-1", children: ".env.local" }),
2856
+ /* @__PURE__ */ jsxRuntimeExports.jsx("code", { className: "rounded bg-diff-modified-bg/50 px-1", children: ".env.local" }),
2847
2857
  ":",
2848
2858
  " ",
2849
- /* @__PURE__ */ jsxRuntimeExports.jsx("code", { className: "rounded bg-amber-100 px-1", children: "CONVEX_URL=YOUR_URL" })
2859
+ /* @__PURE__ */ jsxRuntimeExports.jsx("code", { className: "rounded bg-diff-modified-bg/50 px-1", children: "CONVEX_URL=YOUR_URL" })
2850
2860
  ] })
2851
2861
  ] })
2852
2862
  ] }),
2853
- /* @__PURE__ */ jsxRuntimeExports.jsxs("p", { className: "text-sm text-amber-700", children: [
2863
+ /* @__PURE__ */ jsxRuntimeExports.jsxs("p", { className: "text-sm text-diff-modified-foreground", children: [
2854
2864
  "Run",
2855
2865
  " ",
2856
- /* @__PURE__ */ jsxRuntimeExports.jsx("code", { className: "rounded bg-amber-100 px-1", children: "npx convex dev" }),
2866
+ /* @__PURE__ */ jsxRuntimeExports.jsx("code", { className: "rounded bg-diff-modified-bg/50 px-1", children: "npx convex dev" }),
2857
2867
  " to start Convex and get your URL."
2858
2868
  ] })
2859
2869
  ] }) });
@@ -2869,43 +2879,43 @@ function RootDocument({ children }) {
2869
2879
  ] })
2870
2880
  ] });
2871
2881
  }
2872
- const $$splitComponentImporter$9 = () => import("./trash-CNw1mtF1.mjs");
2882
+ const $$splitComponentImporter$9 = () => import("./trash-zdlZgpTo.mjs");
2873
2883
  const Route$9 = createFileRoute("/trash")({
2874
2884
  component: lazyRouteComponent($$splitComponentImporter$9, "component")
2875
2885
  });
2876
- const $$splitComponentImporter$8 = () => import("./taxonomies-D3xMK23a.mjs");
2886
+ const $$splitComponentImporter$8 = () => import("./taxonomies-B8nqce6u.mjs");
2877
2887
  const Route$8 = createFileRoute("/taxonomies")({
2878
2888
  component: lazyRouteComponent($$splitComponentImporter$8, "component")
2879
2889
  });
2880
- const $$splitComponentImporter$7 = () => import("./settings-MaEXh2Hz.mjs");
2890
+ const $$splitComponentImporter$7 = () => import("./settings-DlTO2JSj.mjs");
2881
2891
  const Route$7 = createFileRoute("/settings")({
2882
2892
  component: lazyRouteComponent($$splitComponentImporter$7, "component")
2883
2893
  });
2884
- const $$splitComponentImporter$6 = () => import("./media-DkvBfmD9.mjs");
2894
+ const $$splitComponentImporter$6 = () => import("./media-CbzgTRRQ.mjs");
2885
2895
  const Route$6 = createFileRoute("/media")({
2886
2896
  component: lazyRouteComponent($$splitComponentImporter$6, "component")
2887
2897
  });
2888
- const $$splitComponentImporter$5 = () => import("./content-types-BPgMwxiT.mjs");
2898
+ const $$splitComponentImporter$5 = () => import("./content-types-DCzrBhTH.mjs");
2889
2899
  const Route$5 = createFileRoute("/content-types")({
2890
2900
  component: lazyRouteComponent($$splitComponentImporter$5, "component")
2891
2901
  });
2892
- const $$splitComponentImporter$4 = () => import("./content-DrODe6sA.mjs");
2902
+ const $$splitComponentImporter$4 = () => import("./content-BHX39L4D.mjs");
2893
2903
  const Route$4 = createFileRoute("/content")({
2894
2904
  component: lazyRouteComponent($$splitComponentImporter$4, "component")
2895
2905
  });
2896
- const $$splitComponentImporter$3 = () => import("./index-BTHmIC9W.mjs");
2906
+ const $$splitComponentImporter$3 = () => import("./index-DwM_5VNP.mjs");
2897
2907
  const Route$3 = createFileRoute("/")({
2898
2908
  component: lazyRouteComponent($$splitComponentImporter$3, "component")
2899
2909
  });
2900
- const $$splitComponentImporter$2 = () => import("./_entryId-D0yu8HuP.mjs");
2910
+ const $$splitComponentImporter$2 = () => import("./_entryId-9GxatOkL.mjs");
2901
2911
  const Route$2 = createFileRoute("/entries/$entryId")({
2902
2912
  component: lazyRouteComponent($$splitComponentImporter$2, "component")
2903
2913
  });
2904
- const $$splitComponentImporter$1 = () => import("./_contentTypeId-CPjmri90.mjs");
2914
+ const $$splitComponentImporter$1 = () => import("./_contentTypeId-CiDiX-p7.mjs");
2905
2915
  const Route$1 = createFileRoute("/entries/type/$contentTypeId")({
2906
2916
  component: lazyRouteComponent($$splitComponentImporter$1, "component")
2907
2917
  });
2908
- const $$splitComponentImporter = () => import("./new._contentTypeId-Co_73sDJ.mjs");
2918
+ const $$splitComponentImporter = () => import("./new._contentTypeId-6Ph-Gtlw.mjs");
2909
2919
  const Route = createFileRoute("/entries/new/$contentTypeId")({
2910
2920
  component: lazyRouteComponent($$splitComponentImporter, "component")
2911
2921
  });
@@ -1,6 +1,6 @@
1
1
  import { j as jsxRuntimeExports } from "../_chunks/_libs/react.mjs";
2
2
  import { R as Root, V as Viewport, C as Corner, S as ScrollAreaScrollbar, a as ScrollAreaThumb } from "../_chunks/_libs/@radix-ui/react-scroll-area.mjs";
3
- import { f as cn } from "./router-CaDgRHfQ.mjs";
3
+ import { f as cn } from "./router-vd1nySeP.mjs";
4
4
  function ScrollArea({
5
5
  className,
6
6
  children,
@@ -1,11 +1,11 @@
1
1
  import { j as jsxRuntimeExports, r as reactExports } from "../_chunks/_libs/react.mjs";
2
- import { h as api, u as useAdminConfig, R as RouteGuard, L as Label, C as CmsButton, S as Select, a as SelectTrigger, b as SelectValue, c as SelectContent, d as SelectItem, j as useTheme, f as cn } from "./router-CaDgRHfQ.mjs";
3
- import { B as Badge } from "./badge-Cp61aQNc.mjs";
4
- import { u as usePermissions } from "./usePermissions-D0qtvmNi.mjs";
5
- import { C as CmsPageHeader } from "./CmsPageHeader-BcniLh49.mjs";
6
- import { C as CmsSurface } from "./CmsSurface-CHEv-Kba.mjs";
7
- import { S as Switch } from "./switch-DmbR03dm.mjs";
8
- import { u as useTanStackNavigation, A as Alert, a as AlertDescription } from "./tanstack-adapter-DNaUioIZ.mjs";
2
+ import { h as api, u as useAdminConfig, R as RouteGuard, L as Label, C as CmsButton, S as Select, a as SelectTrigger, b as SelectValue, c as SelectContent, d as SelectItem, j as useTheme, f as cn } from "./router-vd1nySeP.mjs";
3
+ import { B as Badge } from "./badge-EI998zba.mjs";
4
+ import { u as useTanStackNavigation, A as Alert, a as AlertDescription } from "./tanstack-adapter-DWbaPByn.mjs";
5
+ import { u as usePermissions } from "./usePermissions-olYRd9S9.mjs";
6
+ import { C as CmsPageHeader } from "./CmsPageHeader-BHUmrIWD.mjs";
7
+ import { C as CmsSurface } from "./CmsSurface-B2eBr-47.mjs";
8
+ import { S as Switch } from "./switch-C05NgNW0.mjs";
9
9
  import { u as useQuery, d as useMutation } from "../_libs/convex.mjs";
10
10
  import { a5 as Info, z as Lock, i as Check, X, a6 as Sun, a7 as Moon, a8 as Monitor } from "../_libs/lucide-react.mjs";
11
11
  import "../_chunks/_libs/@tanstack/react-router.mjs";
@@ -140,7 +140,7 @@ function SettingsPage({
140
140
  const canEdit = canManageSettings();
141
141
  const adminConfig = useAdminConfig();
142
142
  const isConfigured = reactExports.useMemo(() => {
143
- return typeof api2.getSettings === "function";
143
+ return api2.getSettings != null;
144
144
  }, [api2]);
145
145
  const settings = useQuery(
146
146
  isConfigured ? api2.getSettings : "skip",
@@ -351,7 +351,7 @@ function SettingsPage({
351
351
  Badge,
352
352
  {
353
353
  variant: "secondary",
354
- className: "gap-1 bg-emerald-100 text-emerald-700",
354
+ className: "gap-1 bg-diff-added-bg text-diff-added-foreground",
355
355
  children: [
356
356
  /* @__PURE__ */ jsxRuntimeExports.jsx(Check, { className: "size-3" }),
357
357
  "Settings saved successfully"
@@ -456,9 +456,9 @@ function SettingsPage({
456
456
  CmsSurface,
457
457
  {
458
458
  elevation: "base",
459
- className: "border-red-200 p-6 dark:border-red-900",
459
+ className: "border-destructive/50 p-6",
460
460
  children: [
461
- /* @__PURE__ */ jsxRuntimeExports.jsx("h2", { className: "mb-4 text-lg font-semibold text-red-600", children: "Danger Zone" }),
461
+ /* @__PURE__ */ jsxRuntimeExports.jsx("h2", { className: "mb-4 text-lg font-semibold text-destructive", children: "Danger Zone" }),
462
462
  /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex items-center justify-between", children: [
463
463
  /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { children: [
464
464
  /* @__PURE__ */ jsxRuntimeExports.jsx(Label, { className: "text-sm font-medium", children: "Reset to Defaults" }),
@@ -1,6 +1,6 @@
1
1
  import { j as jsxRuntimeExports } from "../_chunks/_libs/react.mjs";
2
2
  import { R as Root, T as Thumb } from "../_chunks/_libs/@radix-ui/react-switch.mjs";
3
- import { f as cn } from "./router-CaDgRHfQ.mjs";
3
+ import { f as cn } from "./router-vd1nySeP.mjs";
4
4
  function Switch({
5
5
  className,
6
6
  ...props
@@ -1,5 +1,5 @@
1
1
  import { j as jsxRuntimeExports, r as reactExports } from "../_chunks/_libs/react.mjs";
2
- import { f as cn, C as CmsButton } from "./router-CaDgRHfQ.mjs";
2
+ import { f as cn, C as CmsButton } from "./router-vd1nySeP.mjs";
3
3
  import { R as Root2, L as List, T as Trigger, C as Content } from "../_chunks/_libs/@radix-ui/react-tabs.mjs";
4
4
  import { j as CircleAlert, ab as Upload, X, ao as RefreshCw, i as Check } from "../_libs/lucide-react.mjs";
5
5
  import { d as useMutation } from "../_libs/convex.mjs";
@@ -367,10 +367,10 @@ function UploadDropzone({
367
367
  const getStatusIcon = (status) => {
368
368
  switch (status) {
369
369
  case "complete":
370
- return /* @__PURE__ */ jsxRuntimeExports.jsx(Check, { className: "size-4 text-emerald-500" });
370
+ return /* @__PURE__ */ jsxRuntimeExports.jsx(Check, { className: "size-4 text-success" });
371
371
  case "error":
372
372
  case "cancelled":
373
- return /* @__PURE__ */ jsxRuntimeExports.jsx(X, { className: "size-4 text-red-500" });
373
+ return /* @__PURE__ */ jsxRuntimeExports.jsx(X, { className: "size-4 text-destructive" });
374
374
  case "uploading":
375
375
  return /* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "size-4 animate-spin rounded-full border-2 border-muted border-t-primary" });
376
376
  default:
@@ -444,11 +444,11 @@ function UploadDropzone({
444
444
  "% complete"
445
445
  ] }),
446
446
  !queue.isUploading && hasCompletedOrFailed && /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex items-center gap-2", children: [
447
- completedCount > 0 && /* @__PURE__ */ jsxRuntimeExports.jsxs("span", { className: "text-emerald-600", children: [
447
+ completedCount > 0 && /* @__PURE__ */ jsxRuntimeExports.jsxs("span", { className: "text-success", children: [
448
448
  completedCount,
449
449
  " completed"
450
450
  ] }),
451
- errorCount > 0 && /* @__PURE__ */ jsxRuntimeExports.jsxs("span", { className: "text-red-500", children: [
451
+ errorCount > 0 && /* @__PURE__ */ jsxRuntimeExports.jsxs("span", { className: "text-destructive", children: [
452
452
  errorCount,
453
453
  " failed"
454
454
  ] })
@@ -480,8 +480,8 @@ function UploadDropzone({
480
480
  {
481
481
  className: cn(
482
482
  "flex items-center gap-3 rounded-lg border bg-card p-3",
483
- uploadFile.status === "error" && "border-red-200 bg-red-50 dark:border-red-900 dark:bg-red-950/20",
484
- uploadFile.status === "complete" && "border-emerald-200 bg-emerald-50 dark:border-emerald-900 dark:bg-emerald-950/20"
483
+ uploadFile.status === "error" && "border-diff-removed-border bg-diff-removed-bg",
484
+ uploadFile.status === "complete" && "border-diff-added-border bg-diff-added-bg"
485
485
  ),
486
486
  children: [
487
487
  /* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "shrink-0", children: getStatusIcon(uploadFile.status) }),
@@ -496,7 +496,7 @@ function UploadDropzone({
496
496
  ),
497
497
  /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex items-center gap-2", children: [
498
498
  /* @__PURE__ */ jsxRuntimeExports.jsx("span", { className: "text-xs text-muted-foreground", children: formatFileSize(uploadFile.file.size) }),
499
- uploadFile.error && /* @__PURE__ */ jsxRuntimeExports.jsx("span", { className: "text-xs text-red-500", children: uploadFile.error })
499
+ uploadFile.error && /* @__PURE__ */ jsxRuntimeExports.jsx("span", { className: "text-xs text-destructive", children: uploadFile.error })
500
500
  ] })
501
501
  ] }),
502
502
  uploadFile.status === "uploading" && /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex w-20 items-center gap-2", children: [
@@ -1,6 +1,6 @@
1
1
  import { r as reactExports, j as jsxRuntimeExports } from "../_chunks/_libs/react.mjs";
2
2
  import { c as cva } from "../_libs/class-variance-authority.mjs";
3
- import { f as cn } from "./router-CaDgRHfQ.mjs";
3
+ import { f as cn } from "./router-vd1nySeP.mjs";
4
4
  import { d as useNavigate, e as useLocation, f as useParams } from "../_chunks/_libs/@tanstack/react-router.mjs";
5
5
  const alertVariants = cva(
6
6
  "relative w-full rounded-lg border px-4 py-3 text-sm grid has-[>svg]:grid-cols-[calc(var(--spacing)*4)_1fr] grid-cols-[0_1fr] has-[>svg]:gap-x-3 gap-y-0.5 items-start [&>svg]:size-4 [&>svg]:translate-y-0.5 [&>svg]:text-current",
@@ -31,6 +31,19 @@ function Alert({
31
31
  }
32
32
  );
33
33
  }
34
+ function AlertTitle({ className, ...props }) {
35
+ return /* @__PURE__ */ jsxRuntimeExports.jsx(
36
+ "div",
37
+ {
38
+ "data-slot": "alert-title",
39
+ className: cn(
40
+ "col-start-2 line-clamp-1 min-h-4 font-medium tracking-tight",
41
+ className
42
+ ),
43
+ ...props
44
+ }
45
+ );
46
+ }
34
47
  function AlertDescription({
35
48
  className,
36
49
  ...props
@@ -115,5 +128,6 @@ function useTanStackNavigation() {
115
128
  export {
116
129
  Alert as A,
117
130
  AlertDescription as a,
131
+ AlertTitle as b,
118
132
  useTanStackNavigation as u
119
133
  };