@sonicjs-cms/core 2.7.0 → 2.8.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.
Files changed (96) hide show
  1. package/dist/{app-DV27cjPy.d.cts → app-CYEm1ytG.d.cts} +1 -0
  2. package/dist/{app-DV27cjPy.d.ts → app-CYEm1ytG.d.ts} +1 -0
  3. package/dist/{chunk-DNHJS6RN.js → chunk-34QIAULP.js} +4 -4
  4. package/dist/{chunk-DNHJS6RN.js.map → chunk-34QIAULP.js.map} +1 -1
  5. package/dist/{chunk-Y3EWJQ4D.js → chunk-3E76TKR5.js} +3 -3
  6. package/dist/{chunk-Y3EWJQ4D.js.map → chunk-3E76TKR5.js.map} +1 -1
  7. package/dist/{chunk-YRFAQ6MI.cjs → chunk-5CENPGR2.cjs} +219 -14
  8. package/dist/chunk-5CENPGR2.cjs.map +1 -0
  9. package/dist/{chunk-MYB5RY7H.cjs → chunk-5HMR2SJW.cjs} +4 -4
  10. package/dist/{chunk-MYB5RY7H.cjs.map → chunk-5HMR2SJW.cjs.map} +1 -1
  11. package/dist/{chunk-YHW27CBV.cjs → chunk-6FHNRRJ3.cjs} +190 -2
  12. package/dist/chunk-6FHNRRJ3.cjs.map +1 -0
  13. package/dist/{chunk-UISZ2MBW.js → chunk-BAWMAS5S.js} +5438 -1443
  14. package/dist/chunk-BAWMAS5S.js.map +1 -0
  15. package/dist/{chunk-F332TENF.js → chunk-CJYFSKH7.js} +4 -190
  16. package/dist/chunk-CJYFSKH7.js.map +1 -0
  17. package/dist/{chunk-3YNNVSMC.js → chunk-G44QUVNM.js} +90 -2
  18. package/dist/chunk-G44QUVNM.js.map +1 -0
  19. package/dist/{chunk-E2BXLXPW.cjs → chunk-GPTMGUFN.cjs} +4 -4
  20. package/dist/{chunk-E2BXLXPW.cjs.map → chunk-GPTMGUFN.cjs.map} +1 -1
  21. package/dist/chunk-H7AMQWVI.js +2466 -0
  22. package/dist/chunk-H7AMQWVI.js.map +1 -0
  23. package/dist/{chunk-CLIH2T74.js → chunk-J5WGMRSU.js} +189 -3
  24. package/dist/chunk-J5WGMRSU.js.map +1 -0
  25. package/dist/{chunk-L2IDZI7F.js → chunk-JDFPB6UW.js} +219 -14
  26. package/dist/chunk-JDFPB6UW.js.map +1 -0
  27. package/dist/{chunk-Y72M3MVX.cjs → chunk-MNFY6DWY.cjs} +13 -200
  28. package/dist/chunk-MNFY6DWY.cjs.map +1 -0
  29. package/dist/chunk-S6K2H2TS.cjs +2470 -0
  30. package/dist/chunk-S6K2H2TS.cjs.map +1 -0
  31. package/dist/{chunk-EHSZ6TAN.cjs → chunk-SHCYIZAN.cjs} +9 -2
  32. package/dist/chunk-SHCYIZAN.cjs.map +1 -0
  33. package/dist/{chunk-GRN3GHUG.js → chunk-VCH6HXVP.js} +9 -2
  34. package/dist/chunk-VCH6HXVP.js.map +1 -0
  35. package/dist/{chunk-7FOAMNTI.cjs → chunk-VNLR35GO.cjs} +90 -2
  36. package/dist/chunk-VNLR35GO.cjs.map +1 -0
  37. package/dist/{chunk-J7F3NPAP.cjs → chunk-YE2MU7CN.cjs} +5192 -1194
  38. package/dist/chunk-YE2MU7CN.cjs.map +1 -0
  39. package/dist/index.cjs +201 -607
  40. package/dist/index.cjs.map +1 -1
  41. package/dist/index.d.cts +3 -3
  42. package/dist/index.d.ts +3 -3
  43. package/dist/index.js +67 -473
  44. package/dist/index.js.map +1 -1
  45. package/dist/middleware.cjs +23 -23
  46. package/dist/middleware.d.cts +1 -1
  47. package/dist/middleware.d.ts +1 -1
  48. package/dist/middleware.js +2 -2
  49. package/dist/migrations-7JGSFOCM.cjs +13 -0
  50. package/dist/{migrations-LEMFV2ND.cjs.map → migrations-7JGSFOCM.cjs.map} +1 -1
  51. package/dist/migrations-YB77VTVF.js +4 -0
  52. package/dist/{migrations-RKQES6XY.js.map → migrations-YB77VTVF.js.map} +1 -1
  53. package/dist/{plugin-bootstrap-CB-xaBfK.d.ts → plugin-bootstrap-C7Mj00Ud.d.ts} +2455 -1
  54. package/dist/{plugin-bootstrap-U-cw9jn3.d.cts → plugin-bootstrap-DKB5f8-E.d.cts} +2455 -1
  55. package/dist/plugins.cjs +14 -14
  56. package/dist/plugins.js +2 -2
  57. package/dist/routes.cjs +39 -27
  58. package/dist/routes.d.cts +126 -53
  59. package/dist/routes.d.ts +126 -53
  60. package/dist/routes.js +7 -7
  61. package/dist/services.cjs +14 -14
  62. package/dist/services.d.cts +1 -1
  63. package/dist/services.d.ts +1 -1
  64. package/dist/services.js +2 -2
  65. package/dist/templates.cjs +25 -17
  66. package/dist/templates.d.cts +21 -1
  67. package/dist/templates.d.ts +21 -1
  68. package/dist/templates.js +2 -2
  69. package/dist/utils.cjs +14 -14
  70. package/dist/utils.js +1 -1
  71. package/migrations/014_fix_plugin_registry.sql +1 -1
  72. package/migrations/020_add_email_plugin.sql +1 -1
  73. package/migrations/026_add_otp_login.sql +1 -1
  74. package/migrations/029_add_forms_system.sql +184 -0
  75. package/migrations/030_add_turnstile_to_forms.sql +14 -0
  76. package/package.json +2 -2
  77. package/dist/chunk-3YNNVSMC.js.map +0 -1
  78. package/dist/chunk-7FOAMNTI.cjs.map +0 -1
  79. package/dist/chunk-AYPF6C4D.cjs +0 -76
  80. package/dist/chunk-AYPF6C4D.cjs.map +0 -1
  81. package/dist/chunk-CLIH2T74.js.map +0 -1
  82. package/dist/chunk-EHSZ6TAN.cjs.map +0 -1
  83. package/dist/chunk-F332TENF.js.map +0 -1
  84. package/dist/chunk-GRN3GHUG.js.map +0 -1
  85. package/dist/chunk-J7F3NPAP.cjs.map +0 -1
  86. package/dist/chunk-L2IDZI7F.js.map +0 -1
  87. package/dist/chunk-UISZ2MBW.js.map +0 -1
  88. package/dist/chunk-V3KVSEG6.js +0 -74
  89. package/dist/chunk-V3KVSEG6.js.map +0 -1
  90. package/dist/chunk-Y72M3MVX.cjs.map +0 -1
  91. package/dist/chunk-YHW27CBV.cjs.map +0 -1
  92. package/dist/chunk-YRFAQ6MI.cjs.map +0 -1
  93. package/dist/migrations-LEMFV2ND.cjs +0 -13
  94. package/dist/migrations-RKQES6XY.js +0 -4
  95. package/migrations/025_rename_mdxeditor_to_easy_mdx.sql +0 -22
  96. /package/migrations/{029_ai_search_plugin.sql → 031_ai_search_plugin.sql} +0 -0
package/dist/index.cjs CHANGED
@@ -1,21 +1,20 @@
1
1
  'use strict';
2
2
 
3
- var chunkJ7F3NPAP_cjs = require('./chunk-J7F3NPAP.cjs');
4
- var chunk7FOAMNTI_cjs = require('./chunk-7FOAMNTI.cjs');
5
- var chunkE2BXLXPW_cjs = require('./chunk-E2BXLXPW.cjs');
3
+ var chunkYE2MU7CN_cjs = require('./chunk-YE2MU7CN.cjs');
4
+ var chunkVNLR35GO_cjs = require('./chunk-VNLR35GO.cjs');
5
+ var chunkGPTMGUFN_cjs = require('./chunk-GPTMGUFN.cjs');
6
6
  var chunkMPT5PA6U_cjs = require('./chunk-MPT5PA6U.cjs');
7
- var chunkYRFAQ6MI_cjs = require('./chunk-YRFAQ6MI.cjs');
8
- var chunkAYPF6C4D_cjs = require('./chunk-AYPF6C4D.cjs');
9
- var chunkEHSZ6TAN_cjs = require('./chunk-EHSZ6TAN.cjs');
10
- var chunkY72M3MVX_cjs = require('./chunk-Y72M3MVX.cjs');
11
- var chunkYHW27CBV_cjs = require('./chunk-YHW27CBV.cjs');
12
- var chunkMYB5RY7H_cjs = require('./chunk-MYB5RY7H.cjs');
7
+ var chunk5CENPGR2_cjs = require('./chunk-5CENPGR2.cjs');
8
+ var chunkS6K2H2TS_cjs = require('./chunk-S6K2H2TS.cjs');
9
+ var chunkSHCYIZAN_cjs = require('./chunk-SHCYIZAN.cjs');
10
+ var chunkMNFY6DWY_cjs = require('./chunk-MNFY6DWY.cjs');
11
+ var chunk6FHNRRJ3_cjs = require('./chunk-6FHNRRJ3.cjs');
12
+ var chunk5HMR2SJW_cjs = require('./chunk-5HMR2SJW.cjs');
13
13
  require('./chunk-P3XDZL6Q.cjs');
14
14
  var chunkRCQ2HIQD_cjs = require('./chunk-RCQ2HIQD.cjs');
15
15
  var chunkKYGRJCZM_cjs = require('./chunk-KYGRJCZM.cjs');
16
16
  require('./chunk-IGJUBJBW.cjs');
17
17
  var hono = require('hono');
18
- var html = require('hono/html');
19
18
  var cookie = require('hono/cookie');
20
19
  var zod = require('zod');
21
20
  var d1 = require('drizzle-orm/d1');
@@ -235,7 +234,7 @@ var DatabaseToolsService = class {
235
234
  };
236
235
 
237
236
  // src/templates/pages/admin-database-table.template.ts
238
- chunkEHSZ6TAN_cjs.init_admin_layout_catalyst_template();
237
+ chunkSHCYIZAN_cjs.init_admin_layout_catalyst_template();
239
238
  function renderDatabaseTablePage(data) {
240
239
  const totalPages = Math.ceil(data.totalRows / data.pageSize);
241
240
  const startRow = (data.currentPage - 1) * data.pageSize + 1;
@@ -484,7 +483,7 @@ function renderDatabaseTablePage(data) {
484
483
  user: data.user,
485
484
  content: pageContent
486
485
  };
487
- return chunkEHSZ6TAN_cjs.renderAdminLayoutCatalyst(layoutData);
486
+ return chunkSHCYIZAN_cjs.renderAdminLayoutCatalyst(layoutData);
488
487
  }
489
488
  function generatePageNumbers(currentPage, totalPages) {
490
489
  const pages = [];
@@ -558,9 +557,9 @@ function formatCellValue(value) {
558
557
 
559
558
  // src/plugins/core-plugins/database-tools-plugin/admin-routes.ts
560
559
  function createDatabaseToolsAdminRoutes() {
561
- const router2 = new hono.Hono();
562
- router2.use("*", chunkE2BXLXPW_cjs.requireAuth());
563
- router2.get("/api/stats", async (c) => {
560
+ const router3 = new hono.Hono();
561
+ router3.use("*", chunkGPTMGUFN_cjs.requireAuth());
562
+ router3.get("/api/stats", async (c) => {
564
563
  try {
565
564
  const user = c.get("user");
566
565
  if (!user || user.role !== "admin") {
@@ -584,7 +583,7 @@ function createDatabaseToolsAdminRoutes() {
584
583
  }, 500);
585
584
  }
586
585
  });
587
- router2.post("/api/truncate", async (c) => {
586
+ router3.post("/api/truncate", async (c) => {
588
587
  try {
589
588
  const user = c.get("user");
590
589
  if (!user || user.role !== "admin") {
@@ -621,7 +620,7 @@ function createDatabaseToolsAdminRoutes() {
621
620
  }, 500);
622
621
  }
623
622
  });
624
- router2.post("/api/backup", async (c) => {
623
+ router3.post("/api/backup", async (c) => {
625
624
  try {
626
625
  const user = c.get("user");
627
626
  if (!user || user.role !== "admin") {
@@ -648,7 +647,7 @@ function createDatabaseToolsAdminRoutes() {
648
647
  }, 500);
649
648
  }
650
649
  });
651
- router2.get("/api/validate", async (c) => {
650
+ router3.get("/api/validate", async (c) => {
652
651
  try {
653
652
  const user = c.get("user");
654
653
  if (!user || user.role !== "admin") {
@@ -672,7 +671,7 @@ function createDatabaseToolsAdminRoutes() {
672
671
  }, 500);
673
672
  }
674
673
  });
675
- router2.get("/api/tables/:tableName", async (c) => {
674
+ router3.get("/api/tables/:tableName", async (c) => {
676
675
  try {
677
676
  const user = c.get("user");
678
677
  if (!user || user.role !== "admin") {
@@ -701,7 +700,7 @@ function createDatabaseToolsAdminRoutes() {
701
700
  }, 500);
702
701
  }
703
702
  });
704
- router2.get("/tables/:tableName", async (c) => {
703
+ router3.get("/tables/:tableName", async (c) => {
705
704
  try {
706
705
  const user = c.get("user");
707
706
  if (!user || user.role !== "admin") {
@@ -737,7 +736,7 @@ function createDatabaseToolsAdminRoutes() {
737
736
  return c.text(`Error: ${error}`, 500);
738
737
  }
739
738
  });
740
- return router2;
739
+ return router3;
741
740
  }
742
741
 
743
742
  // src/plugins/core-plugins/seed-data-plugin/services/seed-data-service.ts
@@ -1027,7 +1026,7 @@ var SeedDataService = class {
1027
1026
  function createSeedDataAdminRoutes() {
1028
1027
  const routes = new hono.Hono();
1029
1028
  routes.get("/", async (c) => {
1030
- const html3 = `
1029
+ const html = `
1031
1030
  <!DOCTYPE html>
1032
1031
  <html>
1033
1032
  <head>
@@ -1270,7 +1269,7 @@ function createSeedDataAdminRoutes() {
1270
1269
  </body>
1271
1270
  </html>
1272
1271
  `;
1273
- return c.html(html3);
1272
+ return c.html(html);
1274
1273
  });
1275
1274
  routes.post("/generate", async (c) => {
1276
1275
  try {
@@ -1307,7 +1306,7 @@ function createSeedDataAdminRoutes() {
1307
1306
  return routes;
1308
1307
  }
1309
1308
  function createEmailPlugin() {
1310
- const builder = chunkYHW27CBV_cjs.PluginBuilder.create({
1309
+ const builder = chunk6FHNRRJ3_cjs.PluginBuilder.create({
1311
1310
  name: "email",
1312
1311
  version: "1.0.0-beta.1",
1313
1312
  description: "Send transactional emails using Resend"
@@ -1321,253 +1320,6 @@ function createEmailPlugin() {
1321
1320
  compatibility: "^2.0.0"
1322
1321
  });
1323
1322
  const emailRoutes = new hono.Hono();
1324
- emailRoutes.get("/settings", async (c) => {
1325
- const user = c.get("user");
1326
- const db = c.env.DB;
1327
- const plugin2 = await db.prepare(`
1328
- SELECT settings FROM plugins WHERE id = 'email'
1329
- `).first();
1330
- const settings = plugin2?.settings ? JSON.parse(plugin2.settings) : {};
1331
- const contentHTML = await html.html`
1332
- <div class="p-8">
1333
- <!-- Header -->
1334
- <div class="mb-8">
1335
- <h1 class="text-3xl font-bold text-zinc-950 dark:text-white mb-2">Email Settings</h1>
1336
- <p class="text-zinc-600 dark:text-zinc-400">Configure Resend API for sending transactional emails</p>
1337
- </div>
1338
-
1339
- <!-- Settings Form -->
1340
- <div class="max-w-3xl">
1341
- <!-- Main Settings Card -->
1342
- <div class="rounded-xl bg-white dark:bg-zinc-900 shadow-sm ring-1 ring-zinc-950/5 dark:ring-white/10 p-6 mb-6">
1343
- <h2 class="text-xl font-semibold text-zinc-950 dark:text-white mb-4">Resend Configuration</h2>
1344
-
1345
- <form id="emailSettingsForm" class="space-y-6">
1346
- <!-- API Key -->
1347
- <div>
1348
- <label for="apiKey" class="block text-sm font-medium text-zinc-950 dark:text-white mb-2">
1349
- Resend API Key <span class="text-red-500">*</span>
1350
- </label>
1351
- <input
1352
- type="password"
1353
- id="apiKey"
1354
- name="apiKey"
1355
- value="${settings.apiKey || ""}"
1356
- class="w-full rounded-lg bg-white dark:bg-white/5 px-3 py-2 text-sm text-zinc-950 dark:text-white ring-1 ring-inset ring-zinc-950/10 dark:ring-white/10 placeholder:text-zinc-500 dark:placeholder:text-zinc-400 focus:ring-2 focus:ring-inset focus:ring-indigo-500 dark:focus:ring-indigo-400"
1357
- placeholder="re_..."
1358
- required
1359
- />
1360
- <p class="text-xs text-zinc-500 dark:text-zinc-400 mt-1">
1361
- Get your API key from <a href="https://resend.com/api-keys" target="_blank" class="text-indigo-600 dark:text-indigo-400 hover:underline">resend.com/api-keys</a>
1362
- </p>
1363
- </div>
1364
-
1365
- <!-- From Email -->
1366
- <div>
1367
- <label for="fromEmail" class="block text-sm font-medium text-zinc-950 dark:text-white mb-2">
1368
- From Email <span class="text-red-500">*</span>
1369
- </label>
1370
- <input
1371
- type="email"
1372
- id="fromEmail"
1373
- name="fromEmail"
1374
- value="${settings.fromEmail || ""}"
1375
- class="w-full rounded-lg bg-white dark:bg-white/5 px-3 py-2 text-sm text-zinc-950 dark:text-white ring-1 ring-inset ring-zinc-950/10 dark:ring-white/10 placeholder:text-zinc-500 dark:placeholder:text-zinc-400 focus:ring-2 focus:ring-inset focus:ring-indigo-500 dark:focus:ring-indigo-400"
1376
- placeholder="noreply@yourdomain.com"
1377
- required
1378
- />
1379
- <p class="text-xs text-zinc-500 dark:text-zinc-400 mt-1">
1380
- Must be a verified domain in Resend
1381
- </p>
1382
- </div>
1383
-
1384
- <!-- From Name -->
1385
- <div>
1386
- <label for="fromName" class="block text-sm font-medium text-zinc-950 dark:text-white mb-2">
1387
- From Name <span class="text-red-500">*</span>
1388
- </label>
1389
- <input
1390
- type="text"
1391
- id="fromName"
1392
- name="fromName"
1393
- value="${settings.fromName || ""}"
1394
- class="w-full rounded-lg bg-white dark:bg-white/5 px-3 py-2 text-sm text-zinc-950 dark:text-white ring-1 ring-inset ring-zinc-950/10 dark:ring-white/10 placeholder:text-zinc-500 dark:placeholder:text-zinc-400 focus:ring-2 focus:ring-inset focus:ring-indigo-500 dark:focus:ring-indigo-400"
1395
- placeholder="Your App Name"
1396
- required
1397
- />
1398
- </div>
1399
-
1400
- <!-- Reply To -->
1401
- <div>
1402
- <label for="replyTo" class="block text-sm font-medium text-zinc-950 dark:text-white mb-2">
1403
- Reply-To Email
1404
- </label>
1405
- <input
1406
- type="email"
1407
- id="replyTo"
1408
- name="replyTo"
1409
- value="${settings.replyTo || ""}"
1410
- class="w-full rounded-lg bg-white dark:bg-white/5 px-3 py-2 text-sm text-zinc-950 dark:text-white ring-1 ring-inset ring-zinc-950/10 dark:ring-white/10 placeholder:text-zinc-500 dark:placeholder:text-zinc-400 focus:ring-2 focus:ring-inset focus:ring-indigo-500 dark:focus:ring-indigo-400"
1411
- placeholder="support@yourdomain.com"
1412
- />
1413
- </div>
1414
-
1415
- <!-- Logo URL -->
1416
- <div>
1417
- <label for="logoUrl" class="block text-sm font-medium text-zinc-950 dark:text-white mb-2">
1418
- Logo URL
1419
- </label>
1420
- <input
1421
- type="url"
1422
- id="logoUrl"
1423
- name="logoUrl"
1424
- value="${settings.logoUrl || ""}"
1425
- class="w-full rounded-lg bg-white dark:bg-white/5 px-3 py-2 text-sm text-zinc-950 dark:text-white ring-1 ring-inset ring-zinc-950/10 dark:ring-white/10 placeholder:text-zinc-500 dark:placeholder:text-zinc-400 focus:ring-2 focus:ring-inset focus:ring-indigo-500 dark:focus:ring-indigo-400"
1426
- placeholder="https://yourdomain.com/logo.png"
1427
- />
1428
- <p class="text-xs text-zinc-500 dark:text-zinc-400 mt-1">
1429
- Logo to display in email templates
1430
- </p>
1431
- </div>
1432
-
1433
- <!-- Action Buttons -->
1434
- <div class="flex gap-3 pt-4">
1435
- <button
1436
- type="submit"
1437
- class="inline-flex items-center justify-center rounded-lg bg-zinc-950 dark:bg-white px-3.5 py-2.5 text-sm font-semibold text-white dark:text-zinc-950 hover:bg-zinc-800 dark:hover:bg-zinc-100 transition-colors shadow-sm"
1438
- >
1439
- Save Settings
1440
- </button>
1441
- <button
1442
- type="button"
1443
- id="testEmailBtn"
1444
- class="inline-flex items-center justify-center rounded-lg bg-white dark:bg-zinc-800 px-3.5 py-2.5 text-sm font-semibold text-zinc-950 dark:text-white ring-1 ring-inset ring-zinc-950/10 dark:ring-white/10 hover:bg-zinc-50 dark:hover:bg-zinc-700 transition-colors shadow-sm"
1445
- >
1446
- Send Test Email
1447
- </button>
1448
- <button
1449
- type="button"
1450
- id="resetBtn"
1451
- class="inline-flex items-center justify-center rounded-lg bg-white dark:bg-zinc-800 px-3.5 py-2.5 text-sm font-semibold text-zinc-950 dark:text-white ring-1 ring-inset ring-zinc-950/10 dark:ring-white/10 hover:bg-zinc-50 dark:hover:bg-zinc-700 transition-colors shadow-sm"
1452
- >
1453
- Reset
1454
- </button>
1455
- </div>
1456
- </form>
1457
- </div>
1458
-
1459
- <!-- Status Message -->
1460
- <div id="statusMessage" class="hidden rounded-xl p-4 mb-6"></div>
1461
-
1462
- <!-- Info Card -->
1463
- <div class="rounded-xl bg-indigo-50 dark:bg-indigo-950/30 ring-1 ring-indigo-100 dark:ring-indigo-900/50 p-6">
1464
- <h3 class="font-semibold text-indigo-900 dark:text-indigo-300 mb-3">
1465
- 📧 Email Templates Included
1466
- </h3>
1467
- <ul class="text-sm text-indigo-800 dark:text-indigo-200 space-y-2">
1468
- <li>✓ Registration confirmation</li>
1469
- <li>✓ Email verification</li>
1470
- <li>✓ Password reset</li>
1471
- <li>✓ One-time code (2FA)</li>
1472
- </ul>
1473
- <p class="text-xs text-indigo-700 dark:text-indigo-300 mt-4">
1474
- Templates are code-based and can be customized by editing the plugin files.
1475
- </p>
1476
- </div>
1477
- </div>
1478
- </div>
1479
-
1480
- <script>
1481
- // Form submission handler
1482
- document.getElementById('emailSettingsForm').addEventListener('submit', async (e) => {
1483
- e.preventDefault()
1484
- const formData = new FormData(e.target)
1485
- const data = Object.fromEntries(formData.entries())
1486
-
1487
- const statusEl = document.getElementById('statusMessage')
1488
-
1489
- try {
1490
- const response = await fetch('/admin/plugins/email/settings', {
1491
- method: 'POST',
1492
- headers: { 'Content-Type': 'application/json' },
1493
- body: JSON.stringify(data)
1494
- })
1495
-
1496
- if (response.ok) {
1497
- statusEl.className = 'rounded-xl bg-green-50 dark:bg-green-950/30 ring-1 ring-green-100 dark:ring-green-900/50 p-4 mb-6 text-green-900 dark:text-green-200'
1498
- statusEl.innerHTML = '✅ Settings saved successfully!'
1499
- statusEl.classList.remove('hidden')
1500
- setTimeout(() => statusEl.classList.add('hidden'), 3000)
1501
- } else {
1502
- throw new Error('Failed to save settings')
1503
- }
1504
- } catch (error) {
1505
- statusEl.className = 'rounded-xl bg-red-50 dark:bg-red-950/30 ring-1 ring-red-100 dark:ring-red-900/50 p-4 mb-6 text-red-900 dark:text-red-200'
1506
- statusEl.innerHTML = '❌ Failed to save settings. Please try again.'
1507
- statusEl.classList.remove('hidden')
1508
- }
1509
- })
1510
-
1511
- // Test email handler
1512
- document.getElementById('testEmailBtn').addEventListener('click', async () => {
1513
- // Prompt for destination email
1514
- const toEmail = prompt('Enter destination email address for test:')
1515
- if (!toEmail) return
1516
-
1517
- // Basic email validation
1518
- if (!toEmail.match(/^[^\\s@]+@[^\\s@]+\\.[^\\s@]+$/)) {
1519
- alert('Please enter a valid email address')
1520
- return
1521
- }
1522
-
1523
- const statusEl = document.getElementById('statusMessage')
1524
-
1525
- statusEl.className = 'rounded-xl bg-indigo-50 dark:bg-indigo-950/30 ring-1 ring-indigo-100 dark:ring-indigo-900/50 p-4 mb-6 text-indigo-900 dark:text-indigo-200'
1526
- statusEl.innerHTML = \`📧 Sending test email to \${toEmail}...\`
1527
- statusEl.classList.remove('hidden')
1528
-
1529
- try {
1530
- const response = await fetch('/admin/plugins/email/test', {
1531
- method: 'POST',
1532
- headers: { 'Content-Type': 'application/json' },
1533
- body: JSON.stringify({ toEmail })
1534
- })
1535
-
1536
- const data = await response.json()
1537
-
1538
- if (response.ok) {
1539
- statusEl.className = 'rounded-xl bg-green-50 dark:bg-green-950/30 ring-1 ring-green-100 dark:ring-green-900/50 p-4 mb-6 text-green-900 dark:text-green-200'
1540
- statusEl.innerHTML = \`✅ \${data.message || 'Test email sent! Check your inbox.'}\`
1541
- } else {
1542
- statusEl.className = 'rounded-xl bg-red-50 dark:bg-red-950/30 ring-1 ring-red-100 dark:ring-red-900/50 p-4 mb-6 text-red-900 dark:text-red-200'
1543
- statusEl.innerHTML = \`❌ \${data.error || 'Failed to send test email. Check your settings.'}\`
1544
- }
1545
- } catch (error) {
1546
- statusEl.className = 'rounded-xl bg-red-50 dark:bg-red-950/30 ring-1 ring-red-100 dark:ring-red-900/50 p-4 mb-6 text-red-900 dark:text-red-200'
1547
- statusEl.innerHTML = '❌ Network error. Please try again.'
1548
- }
1549
- })
1550
-
1551
- // Reset button handler
1552
- document.getElementById('resetBtn').addEventListener('click', () => {
1553
- document.getElementById('emailSettingsForm').reset()
1554
- })
1555
- </script>
1556
- `;
1557
- const templateUser = user ? {
1558
- name: user.name ?? user.email ?? "Admin",
1559
- email: user.email ?? "admin@sonicjs.com",
1560
- role: user.role ?? "admin"
1561
- } : void 0;
1562
- return c.html(
1563
- chunkEHSZ6TAN_cjs.renderAdminLayout({
1564
- title: "Email Settings",
1565
- content: contentHTML,
1566
- user: templateUser,
1567
- currentPath: "/admin/plugins/email/settings"
1568
- })
1569
- );
1570
- });
1571
1323
  emailRoutes.post("/settings", async (c) => {
1572
1324
  try {
1573
1325
  const body = await c.req.json();
@@ -1663,7 +1415,7 @@ function createEmailPlugin() {
1663
1415
  requiresAuth: true,
1664
1416
  priority: 80
1665
1417
  });
1666
- builder.addMenuItem("Email", "/admin/plugins/email/settings", {
1418
+ builder.addMenuItem("Email", "/admin/plugins/email", {
1667
1419
  icon: "envelope",
1668
1420
  order: 80,
1669
1421
  permissions: ["email:manage"]
@@ -1980,11 +1732,10 @@ var DEFAULT_SETTINGS = {
1980
1732
  codeExpiryMinutes: 10,
1981
1733
  maxAttempts: 3,
1982
1734
  rateLimitPerHour: 5,
1983
- allowNewUserRegistration: false,
1984
- appName: "SonicJS"
1735
+ allowNewUserRegistration: false
1985
1736
  };
1986
1737
  function createOTPLoginPlugin() {
1987
- const builder = chunkYHW27CBV_cjs.PluginBuilder.create({
1738
+ const builder = chunk6FHNRRJ3_cjs.PluginBuilder.create({
1988
1739
  name: "otp-login",
1989
1740
  version: "1.0.0-beta.1",
1990
1741
  description: "Passwordless authentication via email one-time codes"
@@ -2012,7 +1763,21 @@ function createOTPLoginPlugin() {
2012
1763
  const normalizedEmail = email.toLowerCase();
2013
1764
  const db = c.env.DB;
2014
1765
  const otpService = new OTPService(db);
2015
- const settings = { ...DEFAULT_SETTINGS };
1766
+ let settings = { ...DEFAULT_SETTINGS };
1767
+ const pluginRow = await db.prepare(`
1768
+ SELECT settings FROM plugins WHERE id = 'otp-login'
1769
+ `).first();
1770
+ if (pluginRow?.settings) {
1771
+ try {
1772
+ const savedSettings = JSON.parse(pluginRow.settings);
1773
+ settings = { ...DEFAULT_SETTINGS, ...savedSettings };
1774
+ } catch (e) {
1775
+ console.warn("Failed to parse OTP plugin settings, using defaults");
1776
+ }
1777
+ }
1778
+ const settingsService = new chunkVNLR35GO_cjs.SettingsService(db);
1779
+ const generalSettings = await settingsService.getGeneralSettings();
1780
+ const siteName = generalSettings.siteName;
2016
1781
  const canRequest = await otpService.checkRateLimit(normalizedEmail, settings);
2017
1782
  if (!canRequest) {
2018
1783
  return c.json({
@@ -2056,7 +1821,7 @@ function createOTPLoginPlugin() {
2056
1821
  email: normalizedEmail,
2057
1822
  ipAddress,
2058
1823
  timestamp: (/* @__PURE__ */ new Date()).toISOString(),
2059
- appName: settings.appName
1824
+ appName: siteName
2060
1825
  });
2061
1826
  const emailPlugin2 = await db.prepare(`
2062
1827
  SELECT settings FROM plugins WHERE id = 'email'
@@ -2073,7 +1838,7 @@ function createOTPLoginPlugin() {
2073
1838
  body: JSON.stringify({
2074
1839
  from: `${emailSettings.fromName} <${emailSettings.fromEmail}>`,
2075
1840
  to: [normalizedEmail],
2076
- subject: `Your login code for ${settings.appName}`,
1841
+ subject: `Your login code for ${siteName}`,
2077
1842
  html: emailContent.html,
2078
1843
  text: emailContent.text,
2079
1844
  reply_to: emailSettings.replyTo || emailSettings.fromEmail
@@ -2124,7 +1889,18 @@ function createOTPLoginPlugin() {
2124
1889
  const normalizedEmail = email.toLowerCase();
2125
1890
  const db = c.env.DB;
2126
1891
  const otpService = new OTPService(db);
2127
- const settings = { ...DEFAULT_SETTINGS };
1892
+ let settings = { ...DEFAULT_SETTINGS };
1893
+ const pluginRow = await db.prepare(`
1894
+ SELECT settings FROM plugins WHERE id = 'otp-login'
1895
+ `).first();
1896
+ if (pluginRow?.settings) {
1897
+ try {
1898
+ const savedSettings = JSON.parse(pluginRow.settings);
1899
+ settings = { ...DEFAULT_SETTINGS, ...savedSettings };
1900
+ } catch (e) {
1901
+ console.warn("Failed to parse OTP plugin settings, using defaults");
1902
+ }
1903
+ }
2128
1904
  const verification = await otpService.verifyCode(normalizedEmail, code, settings);
2129
1905
  if (!verification.valid) {
2130
1906
  await otpService.incrementAttempts(normalizedEmail, code);
@@ -2148,7 +1924,7 @@ function createOTPLoginPlugin() {
2148
1924
  error: "Account is deactivated"
2149
1925
  }, 403);
2150
1926
  }
2151
- const token = await chunkE2BXLXPW_cjs.AuthManager.generateToken(user.id, user.email, user.role);
1927
+ const token = await chunkGPTMGUFN_cjs.AuthManager.generateToken(user.id, user.email, user.role);
2152
1928
  cookie.setCookie(c, "auth_token", token, {
2153
1929
  httpOnly: true,
2154
1930
  secure: true,
@@ -2203,193 +1979,7 @@ function createOTPLoginPlugin() {
2203
1979
  requiresAuth: false,
2204
1980
  priority: 100
2205
1981
  });
2206
- const adminRoutes2 = new hono.Hono();
2207
- adminRoutes2.get("/settings", async (c) => {
2208
- const user = c.get("user");
2209
- const contentHTML = await html.html`
2210
- <div class="p-8">
2211
- <div class="mb-8">
2212
- <h1 class="text-3xl font-bold mb-2">OTP Login Settings</h1>
2213
- <p class="text-zinc-600 dark:text-zinc-400">Configure passwordless authentication via email codes</p>
2214
- </div>
2215
-
2216
- <div class="max-w-3xl">
2217
- <div class="backdrop-blur-md bg-black/20 border border-white/10 shadow-xl rounded-xl p-6 mb-6">
2218
- <h2 class="text-xl font-semibold mb-4">Code Settings</h2>
2219
-
2220
- <form id="otpSettingsForm" class="space-y-6">
2221
- <div>
2222
- <label for="codeLength" class="block text-sm font-medium mb-2">
2223
- Code Length
2224
- </label>
2225
- <input
2226
- type="number"
2227
- id="codeLength"
2228
- name="codeLength"
2229
- min="4"
2230
- max="8"
2231
- value="6"
2232
- class="w-full px-4 py-2 rounded-lg bg-white/5 border border-white/10 focus:border-blue-500 focus:outline-none"
2233
- />
2234
- <p class="text-xs text-zinc-500 mt-1">Number of digits in OTP code (4-8)</p>
2235
- </div>
2236
-
2237
- <div>
2238
- <label for="codeExpiryMinutes" class="block text-sm font-medium mb-2">
2239
- Code Expiry (minutes)
2240
- </label>
2241
- <input
2242
- type="number"
2243
- id="codeExpiryMinutes"
2244
- name="codeExpiryMinutes"
2245
- min="5"
2246
- max="60"
2247
- value="10"
2248
- class="w-full px-4 py-2 rounded-lg bg-white/5 border border-white/10 focus:border-blue-500 focus:outline-none"
2249
- />
2250
- <p class="text-xs text-zinc-500 mt-1">How long codes remain valid (5-60 minutes)</p>
2251
- </div>
2252
-
2253
- <div>
2254
- <label for="maxAttempts" class="block text-sm font-medium mb-2">
2255
- Maximum Attempts
2256
- </label>
2257
- <input
2258
- type="number"
2259
- id="maxAttempts"
2260
- name="maxAttempts"
2261
- min="3"
2262
- max="10"
2263
- value="3"
2264
- class="w-full px-4 py-2 rounded-lg bg-white/5 border border-white/10 focus:border-blue-500 focus:outline-none"
2265
- />
2266
- <p class="text-xs text-zinc-500 mt-1">Max verification attempts before invalidation</p>
2267
- </div>
2268
-
2269
- <div>
2270
- <label for="rateLimitPerHour" class="block text-sm font-medium mb-2">
2271
- Rate Limit (per hour)
2272
- </label>
2273
- <input
2274
- type="number"
2275
- id="rateLimitPerHour"
2276
- name="rateLimitPerHour"
2277
- min="3"
2278
- max="20"
2279
- value="5"
2280
- class="w-full px-4 py-2 rounded-lg bg-white/5 border border-white/10 focus:border-blue-500 focus:outline-none"
2281
- />
2282
- <p class="text-xs text-zinc-500 mt-1">Max code requests per email per hour</p>
2283
- </div>
2284
-
2285
- <div class="flex items-center">
2286
- <input
2287
- type="checkbox"
2288
- id="allowNewUserRegistration"
2289
- name="allowNewUserRegistration"
2290
- class="w-4 h-4 rounded border-white/10"
2291
- />
2292
- <label for="allowNewUserRegistration" class="ml-2 text-sm">
2293
- Allow new user registration via OTP
2294
- </label>
2295
- </div>
2296
-
2297
- <div class="flex gap-3 pt-4">
2298
- <button
2299
- type="submit"
2300
- class="px-6 py-2 bg-gradient-to-r from-blue-500 to-purple-600 text-white rounded-lg font-medium hover:from-blue-600 hover:to-purple-700 transition-all"
2301
- >
2302
- Save Settings
2303
- </button>
2304
- <button
2305
- type="button"
2306
- id="testOTPBtn"
2307
- class="px-6 py-2 bg-white/10 hover:bg-white/20 text-white rounded-lg font-medium transition-all"
2308
- >
2309
- Send Test Code
2310
- </button>
2311
- </div>
2312
- </form>
2313
- </div>
2314
-
2315
- <div id="statusMessage" class="hidden backdrop-blur-md bg-black/20 border border-white/10 rounded-xl p-4 mb-6"></div>
2316
-
2317
- <div class="backdrop-blur-md bg-blue-500/10 border border-blue-500/20 rounded-xl p-6">
2318
- <h3 class="font-semibold text-blue-400 mb-3">
2319
- 🔢 Features
2320
- </h3>
2321
- <ul class="text-sm text-blue-200 space-y-2">
2322
- <li>✓ Passwordless authentication</li>
2323
- <li>✓ Secure random code generation</li>
2324
- <li>✓ Rate limiting protection</li>
2325
- <li>✓ Brute force prevention</li>
2326
- <li>✓ Mobile-friendly UX</li>
2327
- </ul>
2328
- </div>
2329
- </div>
2330
- </div>
2331
-
2332
- <script>
2333
- document.getElementById('otpSettingsForm').addEventListener('submit', async (e) => {
2334
- e.preventDefault()
2335
- const statusEl = document.getElementById('statusMessage')
2336
- statusEl.className = 'backdrop-blur-md bg-green-500/20 border border-green-500/30 rounded-xl p-4 mb-6'
2337
- statusEl.innerHTML = '✅ Settings saved successfully!'
2338
- statusEl.classList.remove('hidden')
2339
- setTimeout(() => statusEl.classList.add('hidden'), 3000)
2340
- })
2341
-
2342
- document.getElementById('testOTPBtn').addEventListener('click', async () => {
2343
- const email = prompt('Enter email address for test:')
2344
- if (!email) return
2345
-
2346
- const statusEl = document.getElementById('statusMessage')
2347
- statusEl.className = 'backdrop-blur-md bg-blue-500/20 border border-blue-500/30 rounded-xl p-4 mb-6'
2348
- statusEl.innerHTML = '📧 Sending test code...'
2349
- statusEl.classList.remove('hidden')
2350
-
2351
- try {
2352
- const response = await fetch('/auth/otp/request', {
2353
- method: 'POST',
2354
- headers: { 'Content-Type': 'application/json' },
2355
- body: JSON.stringify({ email })
2356
- })
2357
-
2358
- const data = await response.json()
2359
-
2360
- if (response.ok) {
2361
- statusEl.className = 'backdrop-blur-md bg-green-500/20 border border-green-500/30 rounded-xl p-4 mb-6'
2362
- statusEl.innerHTML = '✅ Test code sent!' + (data.dev_code ? \` Code: <strong>\${data.dev_code}</strong>\` : '')
2363
- } else {
2364
- throw new Error(data.error || 'Failed')
2365
- }
2366
- } catch (error) {
2367
- statusEl.className = 'backdrop-blur-md bg-red-500/20 border border-red-500/30 rounded-xl p-4 mb-6'
2368
- statusEl.innerHTML = '❌ Failed to send test code'
2369
- }
2370
- })
2371
- </script>
2372
- `;
2373
- const templateUser = user ? {
2374
- name: user.name ?? user.email ?? "Admin",
2375
- email: user.email ?? "admin@sonicjs.com",
2376
- role: user.role ?? "admin"
2377
- } : void 0;
2378
- return c.html(
2379
- chunkEHSZ6TAN_cjs.adminLayoutV2({
2380
- title: "OTP Login Settings",
2381
- content: contentHTML,
2382
- user: templateUser,
2383
- currentPath: "/admin/plugins/otp-login/settings"
2384
- })
2385
- );
2386
- });
2387
- builder.addRoute("/admin/plugins/otp-login", adminRoutes2, {
2388
- description: "OTP login admin interface",
2389
- requiresAuth: true,
2390
- priority: 85
2391
- });
2392
- builder.addMenuItem("OTP Login", "/admin/plugins/otp-login/settings", {
1982
+ builder.addMenuItem("OTP Login", "/admin/plugins/otp-login", {
2393
1983
  icon: "key",
2394
1984
  order: 85,
2395
1985
  permissions: ["otp:manage"]
@@ -3973,7 +3563,7 @@ function renderSettingsPage(data) {
3973
3563
  }, 30000);
3974
3564
  </script>
3975
3565
  `;
3976
- return chunkEHSZ6TAN_cjs.renderAdminLayout({
3566
+ return chunkSHCYIZAN_cjs.renderAdminLayout({
3977
3567
  title: "AI Search Settings",
3978
3568
  pageTitle: "AI Search Settings",
3979
3569
  currentPath: "/admin/plugins/ai-search/settings",
@@ -3984,7 +3574,7 @@ function renderSettingsPage(data) {
3984
3574
 
3985
3575
  // src/plugins/core-plugins/ai-search-plugin/routes/admin.ts
3986
3576
  var adminRoutes = new hono.Hono();
3987
- adminRoutes.use("*", chunkE2BXLXPW_cjs.requireAuth());
3577
+ adminRoutes.use("*", chunkGPTMGUFN_cjs.requireAuth());
3988
3578
  adminRoutes.get("/", async (c) => {
3989
3579
  try {
3990
3580
  const user = c.get("user");
@@ -4230,7 +3820,7 @@ var manifest_default = {
4230
3820
  author: "SonicJS"};
4231
3821
 
4232
3822
  // src/plugins/core-plugins/ai-search-plugin/index.ts
4233
- var aiSearchPlugin = new chunkYHW27CBV_cjs.PluginBuilder({
3823
+ var aiSearchPlugin = new chunk6FHNRRJ3_cjs.PluginBuilder({
4234
3824
  name: manifest_default.name,
4235
3825
  version: manifest_default.version,
4236
3826
  description: manifest_default.description,
@@ -4385,12 +3975,12 @@ function createMagicLinkAuthPlugin() {
4385
3975
  SET used = 1, used_at = ?
4386
3976
  WHERE id = ?
4387
3977
  `).bind(Date.now(), magicLink.id).run();
4388
- const jwtToken = await chunkE2BXLXPW_cjs.AuthManager.generateToken(
3978
+ const jwtToken = await chunkGPTMGUFN_cjs.AuthManager.generateToken(
4389
3979
  user.id,
4390
3980
  user.email,
4391
3981
  user.role
4392
3982
  );
4393
- chunkE2BXLXPW_cjs.AuthManager.setAuthCookie(c, jwtToken);
3983
+ chunkGPTMGUFN_cjs.AuthManager.setAuthCookie(c, jwtToken);
4394
3984
  await db.prepare(`
4395
3985
  UPDATE users SET last_login_at = ? WHERE id = ?
4396
3986
  `).bind(Date.now(), user.id).run();
@@ -5497,7 +5087,7 @@ async function warmNamespace(namespace, entries) {
5497
5087
  }
5498
5088
 
5499
5089
  // src/templates/pages/admin-cache.template.ts
5500
- chunkEHSZ6TAN_cjs.init_admin_layout_catalyst_template();
5090
+ chunkSHCYIZAN_cjs.init_admin_layout_catalyst_template();
5501
5091
  function renderCacheDashboard(data) {
5502
5092
  const pageContent = `
5503
5093
  <div class="space-y-6">
@@ -5676,7 +5266,7 @@ function renderCacheDashboard(data) {
5676
5266
  </script>
5677
5267
 
5678
5268
  <!-- Confirmation Dialogs -->
5679
- ${chunkJ7F3NPAP_cjs.renderConfirmationDialog({
5269
+ ${chunkYE2MU7CN_cjs.renderConfirmationDialog({
5680
5270
  id: "clear-all-cache-confirm",
5681
5271
  title: "Clear All Cache",
5682
5272
  message: "Are you sure you want to clear all cache entries? This cannot be undone.",
@@ -5687,7 +5277,7 @@ function renderCacheDashboard(data) {
5687
5277
  onConfirm: "performClearAllCaches()"
5688
5278
  })}
5689
5279
 
5690
- ${chunkJ7F3NPAP_cjs.renderConfirmationDialog({
5280
+ ${chunkYE2MU7CN_cjs.renderConfirmationDialog({
5691
5281
  id: "clear-namespace-cache-confirm",
5692
5282
  title: "Clear Namespace Cache",
5693
5283
  message: "Clear cache for this namespace?",
@@ -5698,7 +5288,7 @@ function renderCacheDashboard(data) {
5698
5288
  onConfirm: "performClearNamespaceCache()"
5699
5289
  })}
5700
5290
 
5701
- ${chunkJ7F3NPAP_cjs.getConfirmationDialogScript()}
5291
+ ${chunkYE2MU7CN_cjs.getConfirmationDialogScript()}
5702
5292
  `;
5703
5293
  const layoutData = {
5704
5294
  title: "Cache System",
@@ -5708,7 +5298,7 @@ function renderCacheDashboard(data) {
5708
5298
  version: data.version,
5709
5299
  content: pageContent
5710
5300
  };
5711
- return chunkEHSZ6TAN_cjs.renderAdminLayoutCatalyst(layoutData);
5301
+ return chunkSHCYIZAN_cjs.renderAdminLayoutCatalyst(layoutData);
5712
5302
  }
5713
5303
  function renderStatCard(label, value, color, icon, colorOverride) {
5714
5304
  const finalColor = colorOverride || color;
@@ -6384,14 +5974,14 @@ var faviconSvg = `<?xml version="1.0" encoding="UTF-8" standalone="no"?>
6384
5974
  // src/app.ts
6385
5975
  function createSonicJSApp(config = {}) {
6386
5976
  const app2 = new hono.Hono();
6387
- const appVersion = config.version || chunkMYB5RY7H_cjs.getCoreVersion();
5977
+ const appVersion = config.version || chunk5HMR2SJW_cjs.getCoreVersion();
6388
5978
  const appName = config.name || "SonicJS AI";
6389
5979
  app2.use("*", async (c, next) => {
6390
5980
  c.set("appVersion", appVersion);
6391
5981
  await next();
6392
5982
  });
6393
- app2.use("*", chunkE2BXLXPW_cjs.metricsMiddleware());
6394
- app2.use("*", chunkE2BXLXPW_cjs.bootstrapMiddleware(config));
5983
+ app2.use("*", chunkGPTMGUFN_cjs.metricsMiddleware());
5984
+ app2.use("*", chunkGPTMGUFN_cjs.bootstrapMiddleware(config));
6395
5985
  if (config.middleware?.beforeAuth) {
6396
5986
  for (const middleware of config.middleware.beforeAuth) {
6397
5987
  app2.use("*", middleware);
@@ -6408,35 +5998,39 @@ function createSonicJSApp(config = {}) {
6408
5998
  app2.use("*", middleware);
6409
5999
  }
6410
6000
  }
6411
- app2.route("/api", chunkJ7F3NPAP_cjs.api_default);
6412
- app2.route("/api/media", chunkJ7F3NPAP_cjs.api_media_default);
6413
- app2.route("/api/system", chunkJ7F3NPAP_cjs.api_system_default);
6414
- app2.route("/admin/api", chunkJ7F3NPAP_cjs.admin_api_default);
6415
- app2.route("/admin/dashboard", chunkJ7F3NPAP_cjs.router);
6416
- app2.route("/admin/collections", chunkJ7F3NPAP_cjs.adminCollectionsRoutes);
6417
- app2.route("/admin/settings", chunkJ7F3NPAP_cjs.adminSettingsRoutes);
6001
+ app2.route("/api", chunkYE2MU7CN_cjs.api_default);
6002
+ app2.route("/api/media", chunkYE2MU7CN_cjs.api_media_default);
6003
+ app2.route("/api/system", chunkYE2MU7CN_cjs.api_system_default);
6004
+ app2.route("/admin/api", chunkYE2MU7CN_cjs.admin_api_default);
6005
+ app2.route("/admin/dashboard", chunkYE2MU7CN_cjs.router);
6006
+ app2.route("/admin/collections", chunkYE2MU7CN_cjs.adminCollectionsRoutes);
6007
+ app2.route("/admin/forms", chunkYE2MU7CN_cjs.adminFormsRoutes);
6008
+ app2.route("/admin/settings", chunkYE2MU7CN_cjs.adminSettingsRoutes);
6009
+ app2.route("/forms", chunkYE2MU7CN_cjs.public_forms_default);
6010
+ app2.route("/api/forms", chunkYE2MU7CN_cjs.public_forms_default);
6011
+ app2.route("/admin/api-reference", chunkYE2MU7CN_cjs.router2);
6418
6012
  app2.route("/admin/database-tools", createDatabaseToolsAdminRoutes());
6419
6013
  app2.route("/admin/seed-data", createSeedDataAdminRoutes());
6420
- app2.route("/admin/content", chunkJ7F3NPAP_cjs.admin_content_default);
6421
- app2.route("/admin/media", chunkJ7F3NPAP_cjs.adminMediaRoutes);
6014
+ app2.route("/admin/content", chunkYE2MU7CN_cjs.admin_content_default);
6015
+ app2.route("/admin/media", chunkYE2MU7CN_cjs.adminMediaRoutes);
6422
6016
  if (aiSearchPlugin.routes && aiSearchPlugin.routes.length > 0) {
6423
6017
  for (const route of aiSearchPlugin.routes) {
6424
6018
  app2.route(route.path, route.handler);
6425
6019
  }
6426
6020
  }
6427
6021
  app2.route("/admin/cache", cache_default.getRoutes());
6428
- app2.route("/admin/plugins", chunkJ7F3NPAP_cjs.adminPluginRoutes);
6429
- app2.route("/admin/logs", chunkJ7F3NPAP_cjs.adminLogsRoutes);
6430
- app2.route("/admin", chunkJ7F3NPAP_cjs.userRoutes);
6431
- app2.route("/auth", chunkJ7F3NPAP_cjs.auth_default);
6432
- app2.route("/", chunkJ7F3NPAP_cjs.test_cleanup_default);
6433
- if (emailPlugin.routes && emailPlugin.routes.length > 0) {
6434
- for (const route of emailPlugin.routes) {
6022
+ if (otpLoginPlugin.routes && otpLoginPlugin.routes.length > 0) {
6023
+ for (const route of otpLoginPlugin.routes) {
6435
6024
  app2.route(route.path, route.handler);
6436
6025
  }
6437
6026
  }
6438
- if (otpLoginPlugin.routes && otpLoginPlugin.routes.length > 0) {
6439
- for (const route of otpLoginPlugin.routes) {
6027
+ app2.route("/admin/plugins", chunkYE2MU7CN_cjs.adminPluginRoutes);
6028
+ app2.route("/admin/logs", chunkYE2MU7CN_cjs.adminLogsRoutes);
6029
+ app2.route("/admin", chunkYE2MU7CN_cjs.userRoutes);
6030
+ app2.route("/auth", chunkYE2MU7CN_cjs.auth_default);
6031
+ app2.route("/", chunkYE2MU7CN_cjs.test_cleanup_default);
6032
+ if (emailPlugin.routes && emailPlugin.routes.length > 0) {
6033
+ for (const route of emailPlugin.routes) {
6440
6034
  app2.route(route.path, route.handler);
6441
6035
  }
6442
6036
  }
@@ -6513,331 +6107,331 @@ function setupCoreRoutes(_app) {
6513
6107
  console.warn("setupCoreRoutes is deprecated. Use createSonicJSApp() instead.");
6514
6108
  }
6515
6109
  function createDb(d1$1) {
6516
- return d1.drizzle(d1$1, { schema: chunk7FOAMNTI_cjs.schema_exports });
6110
+ return d1.drizzle(d1$1, { schema: chunkVNLR35GO_cjs.schema_exports });
6517
6111
  }
6518
6112
 
6519
6113
  // src/index.ts
6520
- var VERSION = chunkMYB5RY7H_cjs.package_default.version;
6114
+ var VERSION = chunk5HMR2SJW_cjs.package_default.version;
6521
6115
 
6522
6116
  Object.defineProperty(exports, "ROUTES_INFO", {
6523
6117
  enumerable: true,
6524
- get: function () { return chunkJ7F3NPAP_cjs.ROUTES_INFO; }
6118
+ get: function () { return chunkYE2MU7CN_cjs.ROUTES_INFO; }
6525
6119
  });
6526
6120
  Object.defineProperty(exports, "adminApiRoutes", {
6527
6121
  enumerable: true,
6528
- get: function () { return chunkJ7F3NPAP_cjs.admin_api_default; }
6122
+ get: function () { return chunkYE2MU7CN_cjs.admin_api_default; }
6529
6123
  });
6530
6124
  Object.defineProperty(exports, "adminCheckboxRoutes", {
6531
6125
  enumerable: true,
6532
- get: function () { return chunkJ7F3NPAP_cjs.adminCheckboxRoutes; }
6126
+ get: function () { return chunkYE2MU7CN_cjs.adminCheckboxRoutes; }
6533
6127
  });
6534
6128
  Object.defineProperty(exports, "adminCodeExamplesRoutes", {
6535
6129
  enumerable: true,
6536
- get: function () { return chunkJ7F3NPAP_cjs.admin_code_examples_default; }
6130
+ get: function () { return chunkYE2MU7CN_cjs.admin_code_examples_default; }
6537
6131
  });
6538
6132
  Object.defineProperty(exports, "adminCollectionsRoutes", {
6539
6133
  enumerable: true,
6540
- get: function () { return chunkJ7F3NPAP_cjs.adminCollectionsRoutes; }
6134
+ get: function () { return chunkYE2MU7CN_cjs.adminCollectionsRoutes; }
6541
6135
  });
6542
6136
  Object.defineProperty(exports, "adminContentRoutes", {
6543
6137
  enumerable: true,
6544
- get: function () { return chunkJ7F3NPAP_cjs.admin_content_default; }
6138
+ get: function () { return chunkYE2MU7CN_cjs.admin_content_default; }
6545
6139
  });
6546
6140
  Object.defineProperty(exports, "adminDashboardRoutes", {
6547
6141
  enumerable: true,
6548
- get: function () { return chunkJ7F3NPAP_cjs.router; }
6142
+ get: function () { return chunkYE2MU7CN_cjs.router; }
6549
6143
  });
6550
6144
  Object.defineProperty(exports, "adminDesignRoutes", {
6551
6145
  enumerable: true,
6552
- get: function () { return chunkJ7F3NPAP_cjs.adminDesignRoutes; }
6146
+ get: function () { return chunkYE2MU7CN_cjs.adminDesignRoutes; }
6553
6147
  });
6554
6148
  Object.defineProperty(exports, "adminLogsRoutes", {
6555
6149
  enumerable: true,
6556
- get: function () { return chunkJ7F3NPAP_cjs.adminLogsRoutes; }
6150
+ get: function () { return chunkYE2MU7CN_cjs.adminLogsRoutes; }
6557
6151
  });
6558
6152
  Object.defineProperty(exports, "adminMediaRoutes", {
6559
6153
  enumerable: true,
6560
- get: function () { return chunkJ7F3NPAP_cjs.adminMediaRoutes; }
6154
+ get: function () { return chunkYE2MU7CN_cjs.adminMediaRoutes; }
6561
6155
  });
6562
6156
  Object.defineProperty(exports, "adminPluginRoutes", {
6563
6157
  enumerable: true,
6564
- get: function () { return chunkJ7F3NPAP_cjs.adminPluginRoutes; }
6158
+ get: function () { return chunkYE2MU7CN_cjs.adminPluginRoutes; }
6565
6159
  });
6566
6160
  Object.defineProperty(exports, "adminSettingsRoutes", {
6567
6161
  enumerable: true,
6568
- get: function () { return chunkJ7F3NPAP_cjs.adminSettingsRoutes; }
6162
+ get: function () { return chunkYE2MU7CN_cjs.adminSettingsRoutes; }
6569
6163
  });
6570
6164
  Object.defineProperty(exports, "adminTestimonialsRoutes", {
6571
6165
  enumerable: true,
6572
- get: function () { return chunkJ7F3NPAP_cjs.admin_testimonials_default; }
6166
+ get: function () { return chunkYE2MU7CN_cjs.admin_testimonials_default; }
6573
6167
  });
6574
6168
  Object.defineProperty(exports, "adminUsersRoutes", {
6575
6169
  enumerable: true,
6576
- get: function () { return chunkJ7F3NPAP_cjs.userRoutes; }
6170
+ get: function () { return chunkYE2MU7CN_cjs.userRoutes; }
6577
6171
  });
6578
6172
  Object.defineProperty(exports, "apiContentCrudRoutes", {
6579
6173
  enumerable: true,
6580
- get: function () { return chunkJ7F3NPAP_cjs.api_content_crud_default; }
6174
+ get: function () { return chunkYE2MU7CN_cjs.api_content_crud_default; }
6581
6175
  });
6582
6176
  Object.defineProperty(exports, "apiMediaRoutes", {
6583
6177
  enumerable: true,
6584
- get: function () { return chunkJ7F3NPAP_cjs.api_media_default; }
6178
+ get: function () { return chunkYE2MU7CN_cjs.api_media_default; }
6585
6179
  });
6586
6180
  Object.defineProperty(exports, "apiRoutes", {
6587
6181
  enumerable: true,
6588
- get: function () { return chunkJ7F3NPAP_cjs.api_default; }
6182
+ get: function () { return chunkYE2MU7CN_cjs.api_default; }
6589
6183
  });
6590
6184
  Object.defineProperty(exports, "apiSystemRoutes", {
6591
6185
  enumerable: true,
6592
- get: function () { return chunkJ7F3NPAP_cjs.api_system_default; }
6186
+ get: function () { return chunkYE2MU7CN_cjs.api_system_default; }
6593
6187
  });
6594
6188
  Object.defineProperty(exports, "authRoutes", {
6595
6189
  enumerable: true,
6596
- get: function () { return chunkJ7F3NPAP_cjs.auth_default; }
6190
+ get: function () { return chunkYE2MU7CN_cjs.auth_default; }
6597
6191
  });
6598
6192
  Object.defineProperty(exports, "Logger", {
6599
6193
  enumerable: true,
6600
- get: function () { return chunk7FOAMNTI_cjs.Logger; }
6194
+ get: function () { return chunkVNLR35GO_cjs.Logger; }
6601
6195
  });
6602
6196
  Object.defineProperty(exports, "apiTokens", {
6603
6197
  enumerable: true,
6604
- get: function () { return chunk7FOAMNTI_cjs.apiTokens; }
6198
+ get: function () { return chunkVNLR35GO_cjs.apiTokens; }
6605
6199
  });
6606
6200
  Object.defineProperty(exports, "collections", {
6607
6201
  enumerable: true,
6608
- get: function () { return chunk7FOAMNTI_cjs.collections; }
6202
+ get: function () { return chunkVNLR35GO_cjs.collections; }
6609
6203
  });
6610
6204
  Object.defineProperty(exports, "content", {
6611
6205
  enumerable: true,
6612
- get: function () { return chunk7FOAMNTI_cjs.content; }
6206
+ get: function () { return chunkVNLR35GO_cjs.content; }
6613
6207
  });
6614
6208
  Object.defineProperty(exports, "contentVersions", {
6615
6209
  enumerable: true,
6616
- get: function () { return chunk7FOAMNTI_cjs.contentVersions; }
6210
+ get: function () { return chunkVNLR35GO_cjs.contentVersions; }
6617
6211
  });
6618
6212
  Object.defineProperty(exports, "getLogger", {
6619
6213
  enumerable: true,
6620
- get: function () { return chunk7FOAMNTI_cjs.getLogger; }
6214
+ get: function () { return chunkVNLR35GO_cjs.getLogger; }
6621
6215
  });
6622
6216
  Object.defineProperty(exports, "initLogger", {
6623
6217
  enumerable: true,
6624
- get: function () { return chunk7FOAMNTI_cjs.initLogger; }
6218
+ get: function () { return chunkVNLR35GO_cjs.initLogger; }
6625
6219
  });
6626
6220
  Object.defineProperty(exports, "insertCollectionSchema", {
6627
6221
  enumerable: true,
6628
- get: function () { return chunk7FOAMNTI_cjs.insertCollectionSchema; }
6222
+ get: function () { return chunkVNLR35GO_cjs.insertCollectionSchema; }
6629
6223
  });
6630
6224
  Object.defineProperty(exports, "insertContentSchema", {
6631
6225
  enumerable: true,
6632
- get: function () { return chunk7FOAMNTI_cjs.insertContentSchema; }
6226
+ get: function () { return chunkVNLR35GO_cjs.insertContentSchema; }
6633
6227
  });
6634
6228
  Object.defineProperty(exports, "insertLogConfigSchema", {
6635
6229
  enumerable: true,
6636
- get: function () { return chunk7FOAMNTI_cjs.insertLogConfigSchema; }
6230
+ get: function () { return chunkVNLR35GO_cjs.insertLogConfigSchema; }
6637
6231
  });
6638
6232
  Object.defineProperty(exports, "insertMediaSchema", {
6639
6233
  enumerable: true,
6640
- get: function () { return chunk7FOAMNTI_cjs.insertMediaSchema; }
6234
+ get: function () { return chunkVNLR35GO_cjs.insertMediaSchema; }
6641
6235
  });
6642
6236
  Object.defineProperty(exports, "insertPluginActivityLogSchema", {
6643
6237
  enumerable: true,
6644
- get: function () { return chunk7FOAMNTI_cjs.insertPluginActivityLogSchema; }
6238
+ get: function () { return chunkVNLR35GO_cjs.insertPluginActivityLogSchema; }
6645
6239
  });
6646
6240
  Object.defineProperty(exports, "insertPluginAssetSchema", {
6647
6241
  enumerable: true,
6648
- get: function () { return chunk7FOAMNTI_cjs.insertPluginAssetSchema; }
6242
+ get: function () { return chunkVNLR35GO_cjs.insertPluginAssetSchema; }
6649
6243
  });
6650
6244
  Object.defineProperty(exports, "insertPluginHookSchema", {
6651
6245
  enumerable: true,
6652
- get: function () { return chunk7FOAMNTI_cjs.insertPluginHookSchema; }
6246
+ get: function () { return chunkVNLR35GO_cjs.insertPluginHookSchema; }
6653
6247
  });
6654
6248
  Object.defineProperty(exports, "insertPluginRouteSchema", {
6655
6249
  enumerable: true,
6656
- get: function () { return chunk7FOAMNTI_cjs.insertPluginRouteSchema; }
6250
+ get: function () { return chunkVNLR35GO_cjs.insertPluginRouteSchema; }
6657
6251
  });
6658
6252
  Object.defineProperty(exports, "insertPluginSchema", {
6659
6253
  enumerable: true,
6660
- get: function () { return chunk7FOAMNTI_cjs.insertPluginSchema; }
6254
+ get: function () { return chunkVNLR35GO_cjs.insertPluginSchema; }
6661
6255
  });
6662
6256
  Object.defineProperty(exports, "insertSystemLogSchema", {
6663
6257
  enumerable: true,
6664
- get: function () { return chunk7FOAMNTI_cjs.insertSystemLogSchema; }
6258
+ get: function () { return chunkVNLR35GO_cjs.insertSystemLogSchema; }
6665
6259
  });
6666
6260
  Object.defineProperty(exports, "insertUserSchema", {
6667
6261
  enumerable: true,
6668
- get: function () { return chunk7FOAMNTI_cjs.insertUserSchema; }
6262
+ get: function () { return chunkVNLR35GO_cjs.insertUserSchema; }
6669
6263
  });
6670
6264
  Object.defineProperty(exports, "insertWorkflowHistorySchema", {
6671
6265
  enumerable: true,
6672
- get: function () { return chunk7FOAMNTI_cjs.insertWorkflowHistorySchema; }
6266
+ get: function () { return chunkVNLR35GO_cjs.insertWorkflowHistorySchema; }
6673
6267
  });
6674
6268
  Object.defineProperty(exports, "logConfig", {
6675
6269
  enumerable: true,
6676
- get: function () { return chunk7FOAMNTI_cjs.logConfig; }
6270
+ get: function () { return chunkVNLR35GO_cjs.logConfig; }
6677
6271
  });
6678
6272
  Object.defineProperty(exports, "media", {
6679
6273
  enumerable: true,
6680
- get: function () { return chunk7FOAMNTI_cjs.media; }
6274
+ get: function () { return chunkVNLR35GO_cjs.media; }
6681
6275
  });
6682
6276
  Object.defineProperty(exports, "pluginActivityLog", {
6683
6277
  enumerable: true,
6684
- get: function () { return chunk7FOAMNTI_cjs.pluginActivityLog; }
6278
+ get: function () { return chunkVNLR35GO_cjs.pluginActivityLog; }
6685
6279
  });
6686
6280
  Object.defineProperty(exports, "pluginAssets", {
6687
6281
  enumerable: true,
6688
- get: function () { return chunk7FOAMNTI_cjs.pluginAssets; }
6282
+ get: function () { return chunkVNLR35GO_cjs.pluginAssets; }
6689
6283
  });
6690
6284
  Object.defineProperty(exports, "pluginHooks", {
6691
6285
  enumerable: true,
6692
- get: function () { return chunk7FOAMNTI_cjs.pluginHooks; }
6286
+ get: function () { return chunkVNLR35GO_cjs.pluginHooks; }
6693
6287
  });
6694
6288
  Object.defineProperty(exports, "pluginRoutes", {
6695
6289
  enumerable: true,
6696
- get: function () { return chunk7FOAMNTI_cjs.pluginRoutes; }
6290
+ get: function () { return chunkVNLR35GO_cjs.pluginRoutes; }
6697
6291
  });
6698
6292
  Object.defineProperty(exports, "plugins", {
6699
6293
  enumerable: true,
6700
- get: function () { return chunk7FOAMNTI_cjs.plugins; }
6294
+ get: function () { return chunkVNLR35GO_cjs.plugins; }
6701
6295
  });
6702
6296
  Object.defineProperty(exports, "selectCollectionSchema", {
6703
6297
  enumerable: true,
6704
- get: function () { return chunk7FOAMNTI_cjs.selectCollectionSchema; }
6298
+ get: function () { return chunkVNLR35GO_cjs.selectCollectionSchema; }
6705
6299
  });
6706
6300
  Object.defineProperty(exports, "selectContentSchema", {
6707
6301
  enumerable: true,
6708
- get: function () { return chunk7FOAMNTI_cjs.selectContentSchema; }
6302
+ get: function () { return chunkVNLR35GO_cjs.selectContentSchema; }
6709
6303
  });
6710
6304
  Object.defineProperty(exports, "selectLogConfigSchema", {
6711
6305
  enumerable: true,
6712
- get: function () { return chunk7FOAMNTI_cjs.selectLogConfigSchema; }
6306
+ get: function () { return chunkVNLR35GO_cjs.selectLogConfigSchema; }
6713
6307
  });
6714
6308
  Object.defineProperty(exports, "selectMediaSchema", {
6715
6309
  enumerable: true,
6716
- get: function () { return chunk7FOAMNTI_cjs.selectMediaSchema; }
6310
+ get: function () { return chunkVNLR35GO_cjs.selectMediaSchema; }
6717
6311
  });
6718
6312
  Object.defineProperty(exports, "selectPluginActivityLogSchema", {
6719
6313
  enumerable: true,
6720
- get: function () { return chunk7FOAMNTI_cjs.selectPluginActivityLogSchema; }
6314
+ get: function () { return chunkVNLR35GO_cjs.selectPluginActivityLogSchema; }
6721
6315
  });
6722
6316
  Object.defineProperty(exports, "selectPluginAssetSchema", {
6723
6317
  enumerable: true,
6724
- get: function () { return chunk7FOAMNTI_cjs.selectPluginAssetSchema; }
6318
+ get: function () { return chunkVNLR35GO_cjs.selectPluginAssetSchema; }
6725
6319
  });
6726
6320
  Object.defineProperty(exports, "selectPluginHookSchema", {
6727
6321
  enumerable: true,
6728
- get: function () { return chunk7FOAMNTI_cjs.selectPluginHookSchema; }
6322
+ get: function () { return chunkVNLR35GO_cjs.selectPluginHookSchema; }
6729
6323
  });
6730
6324
  Object.defineProperty(exports, "selectPluginRouteSchema", {
6731
6325
  enumerable: true,
6732
- get: function () { return chunk7FOAMNTI_cjs.selectPluginRouteSchema; }
6326
+ get: function () { return chunkVNLR35GO_cjs.selectPluginRouteSchema; }
6733
6327
  });
6734
6328
  Object.defineProperty(exports, "selectPluginSchema", {
6735
6329
  enumerable: true,
6736
- get: function () { return chunk7FOAMNTI_cjs.selectPluginSchema; }
6330
+ get: function () { return chunkVNLR35GO_cjs.selectPluginSchema; }
6737
6331
  });
6738
6332
  Object.defineProperty(exports, "selectSystemLogSchema", {
6739
6333
  enumerable: true,
6740
- get: function () { return chunk7FOAMNTI_cjs.selectSystemLogSchema; }
6334
+ get: function () { return chunkVNLR35GO_cjs.selectSystemLogSchema; }
6741
6335
  });
6742
6336
  Object.defineProperty(exports, "selectUserSchema", {
6743
6337
  enumerable: true,
6744
- get: function () { return chunk7FOAMNTI_cjs.selectUserSchema; }
6338
+ get: function () { return chunkVNLR35GO_cjs.selectUserSchema; }
6745
6339
  });
6746
6340
  Object.defineProperty(exports, "selectWorkflowHistorySchema", {
6747
6341
  enumerable: true,
6748
- get: function () { return chunk7FOAMNTI_cjs.selectWorkflowHistorySchema; }
6342
+ get: function () { return chunkVNLR35GO_cjs.selectWorkflowHistorySchema; }
6749
6343
  });
6750
6344
  Object.defineProperty(exports, "systemLogs", {
6751
6345
  enumerable: true,
6752
- get: function () { return chunk7FOAMNTI_cjs.systemLogs; }
6346
+ get: function () { return chunkVNLR35GO_cjs.systemLogs; }
6753
6347
  });
6754
6348
  Object.defineProperty(exports, "users", {
6755
6349
  enumerable: true,
6756
- get: function () { return chunk7FOAMNTI_cjs.users; }
6350
+ get: function () { return chunkVNLR35GO_cjs.users; }
6757
6351
  });
6758
6352
  Object.defineProperty(exports, "workflowHistory", {
6759
6353
  enumerable: true,
6760
- get: function () { return chunk7FOAMNTI_cjs.workflowHistory; }
6354
+ get: function () { return chunkVNLR35GO_cjs.workflowHistory; }
6761
6355
  });
6762
6356
  Object.defineProperty(exports, "AuthManager", {
6763
6357
  enumerable: true,
6764
- get: function () { return chunkE2BXLXPW_cjs.AuthManager; }
6358
+ get: function () { return chunkGPTMGUFN_cjs.AuthManager; }
6765
6359
  });
6766
6360
  Object.defineProperty(exports, "PermissionManager", {
6767
6361
  enumerable: true,
6768
- get: function () { return chunkE2BXLXPW_cjs.PermissionManager; }
6362
+ get: function () { return chunkGPTMGUFN_cjs.PermissionManager; }
6769
6363
  });
6770
6364
  Object.defineProperty(exports, "bootstrapMiddleware", {
6771
6365
  enumerable: true,
6772
- get: function () { return chunkE2BXLXPW_cjs.bootstrapMiddleware; }
6366
+ get: function () { return chunkGPTMGUFN_cjs.bootstrapMiddleware; }
6773
6367
  });
6774
6368
  Object.defineProperty(exports, "cacheHeaders", {
6775
6369
  enumerable: true,
6776
- get: function () { return chunkE2BXLXPW_cjs.cacheHeaders; }
6370
+ get: function () { return chunkGPTMGUFN_cjs.cacheHeaders; }
6777
6371
  });
6778
6372
  Object.defineProperty(exports, "compressionMiddleware", {
6779
6373
  enumerable: true,
6780
- get: function () { return chunkE2BXLXPW_cjs.compressionMiddleware; }
6374
+ get: function () { return chunkGPTMGUFN_cjs.compressionMiddleware; }
6781
6375
  });
6782
6376
  Object.defineProperty(exports, "detailedLoggingMiddleware", {
6783
6377
  enumerable: true,
6784
- get: function () { return chunkE2BXLXPW_cjs.detailedLoggingMiddleware; }
6378
+ get: function () { return chunkGPTMGUFN_cjs.detailedLoggingMiddleware; }
6785
6379
  });
6786
6380
  Object.defineProperty(exports, "getActivePlugins", {
6787
6381
  enumerable: true,
6788
- get: function () { return chunkE2BXLXPW_cjs.getActivePlugins; }
6382
+ get: function () { return chunkGPTMGUFN_cjs.getActivePlugins; }
6789
6383
  });
6790
6384
  Object.defineProperty(exports, "isPluginActive", {
6791
6385
  enumerable: true,
6792
- get: function () { return chunkE2BXLXPW_cjs.isPluginActive; }
6386
+ get: function () { return chunkGPTMGUFN_cjs.isPluginActive; }
6793
6387
  });
6794
6388
  Object.defineProperty(exports, "logActivity", {
6795
6389
  enumerable: true,
6796
- get: function () { return chunkE2BXLXPW_cjs.logActivity; }
6390
+ get: function () { return chunkGPTMGUFN_cjs.logActivity; }
6797
6391
  });
6798
6392
  Object.defineProperty(exports, "loggingMiddleware", {
6799
6393
  enumerable: true,
6800
- get: function () { return chunkE2BXLXPW_cjs.loggingMiddleware; }
6394
+ get: function () { return chunkGPTMGUFN_cjs.loggingMiddleware; }
6801
6395
  });
6802
6396
  Object.defineProperty(exports, "optionalAuth", {
6803
6397
  enumerable: true,
6804
- get: function () { return chunkE2BXLXPW_cjs.optionalAuth; }
6398
+ get: function () { return chunkGPTMGUFN_cjs.optionalAuth; }
6805
6399
  });
6806
6400
  Object.defineProperty(exports, "performanceLoggingMiddleware", {
6807
6401
  enumerable: true,
6808
- get: function () { return chunkE2BXLXPW_cjs.performanceLoggingMiddleware; }
6402
+ get: function () { return chunkGPTMGUFN_cjs.performanceLoggingMiddleware; }
6809
6403
  });
6810
6404
  Object.defineProperty(exports, "requireActivePlugin", {
6811
6405
  enumerable: true,
6812
- get: function () { return chunkE2BXLXPW_cjs.requireActivePlugin; }
6406
+ get: function () { return chunkGPTMGUFN_cjs.requireActivePlugin; }
6813
6407
  });
6814
6408
  Object.defineProperty(exports, "requireActivePlugins", {
6815
6409
  enumerable: true,
6816
- get: function () { return chunkE2BXLXPW_cjs.requireActivePlugins; }
6410
+ get: function () { return chunkGPTMGUFN_cjs.requireActivePlugins; }
6817
6411
  });
6818
6412
  Object.defineProperty(exports, "requireAnyPermission", {
6819
6413
  enumerable: true,
6820
- get: function () { return chunkE2BXLXPW_cjs.requireAnyPermission; }
6414
+ get: function () { return chunkGPTMGUFN_cjs.requireAnyPermission; }
6821
6415
  });
6822
6416
  Object.defineProperty(exports, "requireAuth", {
6823
6417
  enumerable: true,
6824
- get: function () { return chunkE2BXLXPW_cjs.requireAuth; }
6418
+ get: function () { return chunkGPTMGUFN_cjs.requireAuth; }
6825
6419
  });
6826
6420
  Object.defineProperty(exports, "requirePermission", {
6827
6421
  enumerable: true,
6828
- get: function () { return chunkE2BXLXPW_cjs.requirePermission; }
6422
+ get: function () { return chunkGPTMGUFN_cjs.requirePermission; }
6829
6423
  });
6830
6424
  Object.defineProperty(exports, "requireRole", {
6831
6425
  enumerable: true,
6832
- get: function () { return chunkE2BXLXPW_cjs.requireRole; }
6426
+ get: function () { return chunkGPTMGUFN_cjs.requireRole; }
6833
6427
  });
6834
6428
  Object.defineProperty(exports, "securityHeaders", {
6835
6429
  enumerable: true,
6836
- get: function () { return chunkE2BXLXPW_cjs.securityHeaders; }
6430
+ get: function () { return chunkGPTMGUFN_cjs.securityHeaders; }
6837
6431
  });
6838
6432
  Object.defineProperty(exports, "securityLoggingMiddleware", {
6839
6433
  enumerable: true,
6840
- get: function () { return chunkE2BXLXPW_cjs.securityLoggingMiddleware; }
6434
+ get: function () { return chunkGPTMGUFN_cjs.securityLoggingMiddleware; }
6841
6435
  });
6842
6436
  Object.defineProperty(exports, "PluginBootstrapService", {
6843
6437
  enumerable: true,
@@ -6893,111 +6487,111 @@ Object.defineProperty(exports, "validateCollectionConfig", {
6893
6487
  });
6894
6488
  Object.defineProperty(exports, "MigrationService", {
6895
6489
  enumerable: true,
6896
- get: function () { return chunkYRFAQ6MI_cjs.MigrationService; }
6490
+ get: function () { return chunk5CENPGR2_cjs.MigrationService; }
6897
6491
  });
6898
6492
  Object.defineProperty(exports, "renderFilterBar", {
6899
6493
  enumerable: true,
6900
- get: function () { return chunkAYPF6C4D_cjs.renderFilterBar; }
6494
+ get: function () { return chunkS6K2H2TS_cjs.renderFilterBar; }
6901
6495
  });
6902
6496
  Object.defineProperty(exports, "getConfirmationDialogScript", {
6903
6497
  enumerable: true,
6904
- get: function () { return chunkEHSZ6TAN_cjs.getConfirmationDialogScript; }
6498
+ get: function () { return chunkSHCYIZAN_cjs.getConfirmationDialogScript; }
6905
6499
  });
6906
6500
  Object.defineProperty(exports, "renderAlert", {
6907
6501
  enumerable: true,
6908
- get: function () { return chunkEHSZ6TAN_cjs.renderAlert; }
6502
+ get: function () { return chunkSHCYIZAN_cjs.renderAlert; }
6909
6503
  });
6910
6504
  Object.defineProperty(exports, "renderConfirmationDialog", {
6911
6505
  enumerable: true,
6912
- get: function () { return chunkEHSZ6TAN_cjs.renderConfirmationDialog; }
6506
+ get: function () { return chunkSHCYIZAN_cjs.renderConfirmationDialog; }
6913
6507
  });
6914
6508
  Object.defineProperty(exports, "renderForm", {
6915
6509
  enumerable: true,
6916
- get: function () { return chunkEHSZ6TAN_cjs.renderForm; }
6510
+ get: function () { return chunkSHCYIZAN_cjs.renderForm; }
6917
6511
  });
6918
6512
  Object.defineProperty(exports, "renderFormField", {
6919
6513
  enumerable: true,
6920
- get: function () { return chunkEHSZ6TAN_cjs.renderFormField; }
6514
+ get: function () { return chunkSHCYIZAN_cjs.renderFormField; }
6921
6515
  });
6922
6516
  Object.defineProperty(exports, "renderPagination", {
6923
6517
  enumerable: true,
6924
- get: function () { return chunkEHSZ6TAN_cjs.renderPagination; }
6518
+ get: function () { return chunkSHCYIZAN_cjs.renderPagination; }
6925
6519
  });
6926
6520
  Object.defineProperty(exports, "renderTable", {
6927
6521
  enumerable: true,
6928
- get: function () { return chunkEHSZ6TAN_cjs.renderTable; }
6522
+ get: function () { return chunkSHCYIZAN_cjs.renderTable; }
6929
6523
  });
6930
6524
  Object.defineProperty(exports, "HookSystemImpl", {
6931
6525
  enumerable: true,
6932
- get: function () { return chunkY72M3MVX_cjs.HookSystemImpl; }
6526
+ get: function () { return chunkMNFY6DWY_cjs.HookSystemImpl; }
6933
6527
  });
6934
6528
  Object.defineProperty(exports, "HookUtils", {
6935
6529
  enumerable: true,
6936
- get: function () { return chunkY72M3MVX_cjs.HookUtils; }
6530
+ get: function () { return chunkMNFY6DWY_cjs.HookUtils; }
6937
6531
  });
6938
6532
  Object.defineProperty(exports, "PluginManagerClass", {
6939
6533
  enumerable: true,
6940
- get: function () { return chunkY72M3MVX_cjs.PluginManager; }
6534
+ get: function () { return chunkMNFY6DWY_cjs.PluginManager; }
6941
6535
  });
6942
6536
  Object.defineProperty(exports, "PluginRegistryImpl", {
6943
6537
  enumerable: true,
6944
- get: function () { return chunkY72M3MVX_cjs.PluginRegistryImpl; }
6538
+ get: function () { return chunkMNFY6DWY_cjs.PluginRegistryImpl; }
6945
6539
  });
6946
6540
  Object.defineProperty(exports, "PluginValidatorClass", {
6947
6541
  enumerable: true,
6948
- get: function () { return chunkY72M3MVX_cjs.PluginValidator; }
6542
+ get: function () { return chunkMNFY6DWY_cjs.PluginValidator; }
6949
6543
  });
6950
6544
  Object.defineProperty(exports, "ScopedHookSystemClass", {
6951
6545
  enumerable: true,
6952
- get: function () { return chunkY72M3MVX_cjs.ScopedHookSystem; }
6546
+ get: function () { return chunkMNFY6DWY_cjs.ScopedHookSystem; }
6953
6547
  });
6954
6548
  Object.defineProperty(exports, "PluginBuilder", {
6955
6549
  enumerable: true,
6956
- get: function () { return chunkYHW27CBV_cjs.PluginBuilder; }
6550
+ get: function () { return chunk6FHNRRJ3_cjs.PluginBuilder; }
6957
6551
  });
6958
6552
  Object.defineProperty(exports, "PluginHelpers", {
6959
6553
  enumerable: true,
6960
- get: function () { return chunkYHW27CBV_cjs.PluginHelpers; }
6554
+ get: function () { return chunk6FHNRRJ3_cjs.PluginHelpers; }
6961
6555
  });
6962
6556
  Object.defineProperty(exports, "QueryFilterBuilder", {
6963
6557
  enumerable: true,
6964
- get: function () { return chunkMYB5RY7H_cjs.QueryFilterBuilder; }
6558
+ get: function () { return chunk5HMR2SJW_cjs.QueryFilterBuilder; }
6965
6559
  });
6966
6560
  Object.defineProperty(exports, "SONICJS_VERSION", {
6967
6561
  enumerable: true,
6968
- get: function () { return chunkMYB5RY7H_cjs.SONICJS_VERSION; }
6562
+ get: function () { return chunk5HMR2SJW_cjs.SONICJS_VERSION; }
6969
6563
  });
6970
6564
  Object.defineProperty(exports, "TemplateRenderer", {
6971
6565
  enumerable: true,
6972
- get: function () { return chunkMYB5RY7H_cjs.TemplateRenderer; }
6566
+ get: function () { return chunk5HMR2SJW_cjs.TemplateRenderer; }
6973
6567
  });
6974
6568
  Object.defineProperty(exports, "buildQuery", {
6975
6569
  enumerable: true,
6976
- get: function () { return chunkMYB5RY7H_cjs.buildQuery; }
6570
+ get: function () { return chunk5HMR2SJW_cjs.buildQuery; }
6977
6571
  });
6978
6572
  Object.defineProperty(exports, "escapeHtml", {
6979
6573
  enumerable: true,
6980
- get: function () { return chunkMYB5RY7H_cjs.escapeHtml; }
6574
+ get: function () { return chunk5HMR2SJW_cjs.escapeHtml; }
6981
6575
  });
6982
6576
  Object.defineProperty(exports, "getCoreVersion", {
6983
6577
  enumerable: true,
6984
- get: function () { return chunkMYB5RY7H_cjs.getCoreVersion; }
6578
+ get: function () { return chunk5HMR2SJW_cjs.getCoreVersion; }
6985
6579
  });
6986
6580
  Object.defineProperty(exports, "renderTemplate", {
6987
6581
  enumerable: true,
6988
- get: function () { return chunkMYB5RY7H_cjs.renderTemplate; }
6582
+ get: function () { return chunk5HMR2SJW_cjs.renderTemplate; }
6989
6583
  });
6990
6584
  Object.defineProperty(exports, "sanitizeInput", {
6991
6585
  enumerable: true,
6992
- get: function () { return chunkMYB5RY7H_cjs.sanitizeInput; }
6586
+ get: function () { return chunk5HMR2SJW_cjs.sanitizeInput; }
6993
6587
  });
6994
6588
  Object.defineProperty(exports, "sanitizeObject", {
6995
6589
  enumerable: true,
6996
- get: function () { return chunkMYB5RY7H_cjs.sanitizeObject; }
6590
+ get: function () { return chunk5HMR2SJW_cjs.sanitizeObject; }
6997
6591
  });
6998
6592
  Object.defineProperty(exports, "templateRenderer", {
6999
6593
  enumerable: true,
7000
- get: function () { return chunkMYB5RY7H_cjs.templateRenderer; }
6594
+ get: function () { return chunk5HMR2SJW_cjs.templateRenderer; }
7001
6595
  });
7002
6596
  Object.defineProperty(exports, "metricsTracker", {
7003
6597
  enumerable: true,