@sonicjs-cms/core 2.19.0 → 3.0.0-beta.10
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +52 -52
- package/dist/admin-documents-form.template-DDSH6ROU.js +6 -0
- package/dist/{admin-layout-catalyst.template-UMTIN66R.js.map → admin-documents-form.template-DDSH6ROU.js.map} +1 -1
- package/dist/admin-documents-form.template-LSZKGA5J.cjs +19 -0
- package/dist/{admin-layout-catalyst.template-HFD37TY5.cjs.map → admin-documents-form.template-LSZKGA5J.cjs.map} +1 -1
- package/dist/{filter-bar.template-DlVYMk-T.d.cts → admin-layout-catalyst.template-DrwDUfsE.d.cts} +25 -1
- package/dist/{filter-bar.template-DlVYMk-T.d.ts → admin-layout-catalyst.template-DrwDUfsE.d.ts} +25 -1
- package/dist/admin-layout-catalyst.template-KDHKVLXR.cjs +21 -0
- package/dist/admin-layout-catalyst.template-KDHKVLXR.cjs.map +1 -0
- package/dist/admin-layout-catalyst.template-YQ4EMF2J.js +7 -0
- package/dist/admin-layout-catalyst.template-YQ4EMF2J.js.map +1 -0
- package/dist/app-Bo0X1OWX.d.ts +1268 -0
- package/dist/app-Do66yCcV.d.cts +1268 -0
- package/dist/cache-DDARE4QE.js +4 -0
- package/dist/cache-DDARE4QE.js.map +1 -0
- package/dist/cache-LVYS4BPL.cjs +33 -0
- package/dist/cache-LVYS4BPL.cjs.map +1 -0
- package/dist/chunk-2CB4KY7I.cjs +771 -0
- package/dist/chunk-2CB4KY7I.cjs.map +1 -0
- package/dist/{chunk-ABB34XUS.cjs → chunk-3KYKEXV7.cjs} +667 -19
- package/dist/chunk-3KYKEXV7.cjs.map +1 -0
- package/dist/chunk-4BTBSXMR.cjs +912 -0
- package/dist/chunk-4BTBSXMR.cjs.map +1 -0
- package/dist/{chunk-55RDMDOP.js → chunk-5V62WT6M.js} +181 -57
- package/dist/chunk-5V62WT6M.js.map +1 -0
- package/dist/{chunk-OCL3HMEG.js → chunk-6OC6MF3C.js} +7004 -9807
- package/dist/chunk-6OC6MF3C.js.map +1 -0
- package/dist/chunk-AI663NBO.js +821 -0
- package/dist/chunk-AI663NBO.js.map +1 -0
- package/dist/chunk-ALDRXTUO.js +273 -0
- package/dist/chunk-ALDRXTUO.js.map +1 -0
- package/dist/{chunk-TFNTM3OA.js → chunk-ATUPB6MN.js} +645 -15
- package/dist/chunk-ATUPB6MN.js.map +1 -0
- package/dist/chunk-BLMTL57B.js +767 -0
- package/dist/chunk-BLMTL57B.js.map +1 -0
- package/dist/{chunk-4ZSNJDLS.cjs → chunk-CRGUD4KC.cjs} +9 -9
- package/dist/chunk-CRGUD4KC.cjs.map +1 -0
- package/dist/chunk-F67UK75A.cjs +158 -0
- package/dist/chunk-F67UK75A.cjs.map +1 -0
- package/dist/chunk-GCDZZNIN.js +192 -0
- package/dist/chunk-GCDZZNIN.js.map +1 -0
- package/dist/chunk-HIKBY7MS.cjs +70 -0
- package/dist/chunk-HIKBY7MS.cjs.map +1 -0
- package/dist/{chunk-4NPCDK6B.js → chunk-IDCZBF35.js} +557 -90
- package/dist/chunk-IDCZBF35.js.map +1 -0
- package/dist/chunk-IESEVHXL.js +66 -0
- package/dist/chunk-IESEVHXL.js.map +1 -0
- package/dist/chunk-IGADDMXH.js +387 -0
- package/dist/chunk-IGADDMXH.js.map +1 -0
- package/dist/chunk-IHTXB7AT.cjs +276 -0
- package/dist/chunk-IHTXB7AT.cjs.map +1 -0
- package/dist/chunk-IVPRUGTY.js +242 -0
- package/dist/chunk-IVPRUGTY.js.map +1 -0
- package/dist/{chunk-JZVHLLSI.cjs → chunk-IXUHXTHW.cjs} +2 -151
- package/dist/chunk-IXUHXTHW.cjs.map +1 -0
- package/dist/chunk-J6JTWD2A.cjs +100 -0
- package/dist/chunk-J6JTWD2A.cjs.map +1 -0
- package/dist/chunk-JEQ7FLOD.cjs +199 -0
- package/dist/chunk-JEQ7FLOD.cjs.map +1 -0
- package/dist/{chunk-ON5ZMSU4.js → chunk-JQISFW6U.js} +3 -3
- package/dist/chunk-JQISFW6U.js.map +1 -0
- package/dist/chunk-K25XHMM3.js +566 -0
- package/dist/chunk-K25XHMM3.js.map +1 -0
- package/dist/{chunk-UYJ6TJHX.cjs → chunk-K623Q6WD.cjs} +181 -56
- package/dist/chunk-K623Q6WD.cjs.map +1 -0
- package/dist/{chunk-7A4CB7T3.cjs → chunk-MUNO67TT.cjs} +561 -91
- package/dist/chunk-MUNO67TT.cjs.map +1 -0
- package/dist/chunk-N32OWET6.cjs +327 -0
- package/dist/chunk-N32OWET6.cjs.map +1 -0
- package/dist/chunk-NUKJ54GA.cjs +245 -0
- package/dist/chunk-NUKJ54GA.cjs.map +1 -0
- package/dist/{chunk-XWIA3HVX.js → chunk-OBA2RYZN.js} +6 -1249
- package/dist/chunk-OBA2RYZN.js.map +1 -0
- package/dist/chunk-PMGOBS6X.cjs +408 -0
- package/dist/chunk-PMGOBS6X.cjs.map +1 -0
- package/dist/{chunk-OHYBNCVL.cjs → chunk-PXNTCCPE.cjs} +10 -1256
- package/dist/chunk-PXNTCCPE.cjs.map +1 -0
- package/dist/chunk-PYVFXCSD.js +1828 -0
- package/dist/chunk-PYVFXCSD.js.map +1 -0
- package/dist/{chunk-BU7SFHGP.js → chunk-QZGABF2M.js} +3 -149
- package/dist/chunk-QZGABF2M.js.map +1 -0
- package/dist/{chunk-E4YFJBM2.cjs → chunk-R4ILO3W6.cjs} +876 -829
- package/dist/chunk-R4ILO3W6.cjs.map +1 -0
- package/dist/chunk-RMRJGMDE.js +323 -0
- package/dist/chunk-RMRJGMDE.js.map +1 -0
- package/dist/chunk-RNZFGN4R.js +88 -0
- package/dist/chunk-RNZFGN4R.js.map +1 -0
- package/dist/chunk-RQ6N3FTV.js +900 -0
- package/dist/chunk-RQ6N3FTV.js.map +1 -0
- package/dist/{chunk-R4FOLLFB.cjs → chunk-TO6EY4P7.cjs} +8730 -11520
- package/dist/chunk-TO6EY4P7.cjs.map +1 -0
- package/dist/chunk-V464XBYS.js +154 -0
- package/dist/chunk-V464XBYS.js.map +1 -0
- package/dist/chunk-YA3TJ65D.cjs +575 -0
- package/dist/chunk-YA3TJ65D.cjs.map +1 -0
- package/dist/chunk-YP7GW2G5.cjs +866 -0
- package/dist/chunk-YP7GW2G5.cjs.map +1 -0
- package/dist/{collection-config-B4PG-AaF.d.cts → collection-config-JgHOpFCG.d.cts} +30 -2
- package/dist/{collection-config-B4PG-AaF.d.ts → collection-config-JgHOpFCG.d.ts} +30 -2
- package/dist/config-HFXANXCC.js +6 -0
- package/dist/config-HFXANXCC.js.map +1 -0
- package/dist/config-ON6FNMYX.cjs +19 -0
- package/dist/config-ON6FNMYX.cjs.map +1 -0
- package/dist/define-plugin-BzNHc1ZI.d.ts +1321 -0
- package/dist/define-plugin-IWDKYaVm.d.cts +1321 -0
- package/dist/document-projection-TDWRJX3Z.cjs +13 -0
- package/dist/document-projection-TDWRJX3Z.cjs.map +1 -0
- package/dist/document-projection-YYMC6I4U.js +4 -0
- package/dist/document-projection-YYMC6I4U.js.map +1 -0
- package/dist/index.cjs +13736 -4326
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +331 -493
- package/dist/index.d.ts +331 -493
- package/dist/index.js +13455 -4067
- package/dist/index.js.map +1 -1
- package/dist/middleware.cjs +38 -32
- package/dist/middleware.d.cts +50 -7
- package/dist/middleware.d.ts +50 -7
- package/dist/middleware.js +9 -3
- package/dist/migrations-2XHQEGOQ.cjs +13 -0
- package/dist/{migrations-566IIPS2.cjs.map → migrations-2XHQEGOQ.cjs.map} +1 -1
- package/dist/migrations-PE3CDVSM.js +4 -0
- package/dist/{migrations-H5IXZNCO.js.map → migrations-PE3CDVSM.js.map} +1 -1
- package/dist/{plugin-bootstrap-DfVerYV4.d.cts → plugin-bootstrap-B8ThJU21.d.cts} +4315 -1661
- package/dist/{plugin-bootstrap-P_ciLp_C.d.ts → plugin-bootstrap-qu8hJgUt.d.ts} +4315 -1661
- package/dist/plugins.cjs +171 -12
- package/dist/plugins.d.cts +36 -2
- package/dist/plugins.d.ts +36 -2
- package/dist/plugins.js +5 -2
- package/dist/rbac-O73MFKDA.js +5 -0
- package/dist/rbac-O73MFKDA.js.map +1 -0
- package/dist/rbac-VONLJJKB.cjs +14 -0
- package/dist/rbac-VONLJJKB.cjs.map +1 -0
- package/dist/routes.cjs +42 -46
- package/dist/routes.d.cts +56 -146
- package/dist/routes.d.ts +56 -146
- package/dist/routes.js +18 -10
- package/dist/services.cjs +43 -76
- package/dist/services.d.cts +93 -55
- package/dist/services.d.ts +93 -55
- package/dist/services.js +6 -3
- package/dist/{telemetry-B9vIV4wh.d.cts → telemetry-Cku1ax74.d.cts} +1 -1
- package/dist/{telemetry-B9vIV4wh.d.ts → telemetry-Cku1ax74.d.ts} +1 -1
- package/dist/templates.cjs +17 -29
- package/dist/templates.d.cts +2 -89
- package/dist/templates.d.ts +2 -89
- package/dist/templates.js +3 -3
- package/dist/types-Dea1eNxU.d.cts +286 -0
- package/dist/types-Dea1eNxU.d.ts +286 -0
- package/dist/types.d.cts +2 -2
- package/dist/types.d.ts +2 -2
- package/dist/utils.cjs +21 -20
- package/dist/utils.d.cts +2 -2
- package/dist/utils.d.ts +2 -2
- package/dist/utils.js +3 -2
- package/migrations/0001_core.sql +184 -0
- package/migrations/0002_documents.sql +163 -0
- package/package.json +12 -7
- package/dist/admin-layout-catalyst.template-HFD37TY5.cjs +0 -17
- package/dist/admin-layout-catalyst.template-UMTIN66R.js +0 -7
- package/dist/app-C9esKLmh.d.cts +0 -112
- package/dist/app-C9esKLmh.d.ts +0 -112
- package/dist/chunk-4NPCDK6B.js.map +0 -1
- package/dist/chunk-4ZSNJDLS.cjs.map +0 -1
- package/dist/chunk-55RDMDOP.js.map +0 -1
- package/dist/chunk-635JAMSE.cjs +0 -653
- package/dist/chunk-635JAMSE.cjs.map +0 -1
- package/dist/chunk-7A4CB7T3.cjs.map +0 -1
- package/dist/chunk-ABB34XUS.cjs.map +0 -1
- package/dist/chunk-BU7SFHGP.js.map +0 -1
- package/dist/chunk-E4YFJBM2.cjs.map +0 -1
- package/dist/chunk-EXNEW5US.js +0 -648
- package/dist/chunk-EXNEW5US.js.map +0 -1
- package/dist/chunk-JZV22DEV.js +0 -1783
- package/dist/chunk-JZV22DEV.js.map +0 -1
- package/dist/chunk-JZVHLLSI.cjs.map +0 -1
- package/dist/chunk-OCL3HMEG.js.map +0 -1
- package/dist/chunk-OHYBNCVL.cjs.map +0 -1
- package/dist/chunk-ON5ZMSU4.js.map +0 -1
- package/dist/chunk-QFWHAFEO.js +0 -1843
- package/dist/chunk-QFWHAFEO.js.map +0 -1
- package/dist/chunk-R4FOLLFB.cjs.map +0 -1
- package/dist/chunk-RLMUFFUD.cjs +0 -2219
- package/dist/chunk-RLMUFFUD.cjs.map +0 -1
- package/dist/chunk-TFNTM3OA.js.map +0 -1
- package/dist/chunk-UYJ6TJHX.cjs.map +0 -1
- package/dist/chunk-WAEQXGCX.cjs +0 -1898
- package/dist/chunk-WAEQXGCX.cjs.map +0 -1
- package/dist/chunk-XWIA3HVX.js.map +0 -1
- package/dist/chunk-ZYAYUIZE.js +0 -2217
- package/dist/chunk-ZYAYUIZE.js.map +0 -1
- package/dist/migrations-566IIPS2.cjs +0 -13
- package/dist/migrations-H5IXZNCO.js +0 -4
- package/dist/plugin-manager-BoM3Q7o7.d.cts +0 -328
- package/dist/plugin-manager-Efx9RyDX.d.ts +0 -328
- package/migrations/001_initial_schema.sql +0 -170
- package/migrations/002_faq_plugin.sql +0 -86
- package/migrations/003_stage5_enhancements.sql +0 -121
- package/migrations/004_stage6_user_management.sql +0 -183
- package/migrations/005_stage7_workflow_automation.sql +0 -294
- package/migrations/006_plugin_system.sql +0 -155
- package/migrations/007_demo_login_plugin.sql +0 -23
- package/migrations/008_fix_slug_validation.sql +0 -22
- package/migrations/009_system_logging.sql +0 -57
- package/migrations/011_config_managed_collections.sql +0 -15
- package/migrations/012_testimonials_plugin.sql +0 -80
- package/migrations/013_code_examples_plugin.sql +0 -177
- package/migrations/014_fix_plugin_registry.sql +0 -88
- package/migrations/015_add_remaining_plugins.sql +0 -89
- package/migrations/016_remove_duplicate_cache_plugin.sql +0 -17
- package/migrations/017_auth_configurable_fields.sql +0 -49
- package/migrations/018_settings_table.sql +0 -23
- package/migrations/019_remove_blog_posts_collection.sql +0 -15
- package/migrations/020_add_email_plugin.sql +0 -22
- package/migrations/021_add_magic_link_auth_plugin.sql +0 -42
- package/migrations/022_add_tinymce_plugin.sql +0 -25
- package/migrations/023_add_easy_mdx_plugin.sql +0 -25
- package/migrations/024_add_quill_editor_plugin.sql +0 -25
- package/migrations/025_add_easymde_plugin.sql +0 -25
- package/migrations/026_add_otp_login.sql +0 -42
- package/migrations/027_fix_slug_field_type.sql +0 -18
- package/migrations/028_fix_slug_field_type_in_schemas.sql +0 -30
- package/migrations/029_add_forms_system.sql +0 -184
- package/migrations/030_add_turnstile_to_forms.sql +0 -14
- package/migrations/031_ai_search_plugin.sql +0 -45
- package/migrations/032_user_profiles.sql +0 -37
- package/migrations/033_form_content_integration.sql +0 -19
- package/migrations/034_security_audit_plugin.sql +0 -27
- package/migrations/035_user_profiles_data_column.sql +0 -16
- package/migrations/036_analytics_events.sql +0 -22
package/dist/middleware.cjs
CHANGED
|
@@ -1,128 +1,134 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var
|
|
4
|
-
require('./chunk-
|
|
5
|
-
require('./chunk-
|
|
3
|
+
var chunkMUNO67TT_cjs = require('./chunk-MUNO67TT.cjs');
|
|
4
|
+
require('./chunk-2CB4KY7I.cjs');
|
|
5
|
+
require('./chunk-JEQ7FLOD.cjs');
|
|
6
|
+
require('./chunk-R4ILO3W6.cjs');
|
|
7
|
+
require('./chunk-IHTXB7AT.cjs');
|
|
8
|
+
require('./chunk-K623Q6WD.cjs');
|
|
9
|
+
require('./chunk-J6JTWD2A.cjs');
|
|
6
10
|
require('./chunk-RCQ2HIQD.cjs');
|
|
11
|
+
require('./chunk-P3XDZL6Q.cjs');
|
|
12
|
+
require('./chunk-MNWKYY5E.cjs');
|
|
7
13
|
require('./chunk-IGJUBJBW.cjs');
|
|
8
14
|
|
|
9
15
|
|
|
10
16
|
|
|
11
17
|
Object.defineProperty(exports, "AuthManager", {
|
|
12
18
|
enumerable: true,
|
|
13
|
-
get: function () { return
|
|
19
|
+
get: function () { return chunkMUNO67TT_cjs.AuthManager; }
|
|
14
20
|
});
|
|
15
21
|
Object.defineProperty(exports, "PermissionManager", {
|
|
16
22
|
enumerable: true,
|
|
17
|
-
get: function () { return
|
|
23
|
+
get: function () { return chunkMUNO67TT_cjs.PermissionManager; }
|
|
18
24
|
});
|
|
19
25
|
Object.defineProperty(exports, "bootstrapMiddleware", {
|
|
20
26
|
enumerable: true,
|
|
21
|
-
get: function () { return
|
|
27
|
+
get: function () { return chunkMUNO67TT_cjs.bootstrapMiddleware; }
|
|
22
28
|
});
|
|
23
29
|
Object.defineProperty(exports, "cacheHeaders", {
|
|
24
30
|
enumerable: true,
|
|
25
|
-
get: function () { return
|
|
31
|
+
get: function () { return chunkMUNO67TT_cjs.cacheHeaders; }
|
|
26
32
|
});
|
|
27
33
|
Object.defineProperty(exports, "compressionMiddleware", {
|
|
28
34
|
enumerable: true,
|
|
29
|
-
get: function () { return
|
|
35
|
+
get: function () { return chunkMUNO67TT_cjs.compressionMiddleware; }
|
|
30
36
|
});
|
|
31
37
|
Object.defineProperty(exports, "csrfProtection", {
|
|
32
38
|
enumerable: true,
|
|
33
|
-
get: function () { return
|
|
39
|
+
get: function () { return chunkMUNO67TT_cjs.csrfProtection; }
|
|
34
40
|
});
|
|
35
41
|
Object.defineProperty(exports, "detailedLoggingMiddleware", {
|
|
36
42
|
enumerable: true,
|
|
37
|
-
get: function () { return
|
|
43
|
+
get: function () { return chunkMUNO67TT_cjs.detailedLoggingMiddleware; }
|
|
38
44
|
});
|
|
39
45
|
Object.defineProperty(exports, "generateCsrfToken", {
|
|
40
46
|
enumerable: true,
|
|
41
|
-
get: function () { return
|
|
47
|
+
get: function () { return chunkMUNO67TT_cjs.generateCsrfToken; }
|
|
42
48
|
});
|
|
43
49
|
Object.defineProperty(exports, "getActivePlugins", {
|
|
44
50
|
enumerable: true,
|
|
45
|
-
get: function () { return
|
|
51
|
+
get: function () { return chunkMUNO67TT_cjs.getActivePlugins; }
|
|
46
52
|
});
|
|
47
53
|
Object.defineProperty(exports, "getJwtExpirySeconds", {
|
|
48
54
|
enumerable: true,
|
|
49
|
-
get: function () { return
|
|
55
|
+
get: function () { return chunkMUNO67TT_cjs.getJwtExpirySeconds; }
|
|
50
56
|
});
|
|
51
57
|
Object.defineProperty(exports, "getJwtExpirySecondsFromDb", {
|
|
52
58
|
enumerable: true,
|
|
53
|
-
get: function () { return
|
|
59
|
+
get: function () { return chunkMUNO67TT_cjs.getJwtExpirySecondsFromDb; }
|
|
54
60
|
});
|
|
55
61
|
Object.defineProperty(exports, "getJwtRefreshGraceSecondsFromDb", {
|
|
56
62
|
enumerable: true,
|
|
57
|
-
get: function () { return
|
|
63
|
+
get: function () { return chunkMUNO67TT_cjs.getJwtRefreshGraceSecondsFromDb; }
|
|
58
64
|
});
|
|
59
65
|
Object.defineProperty(exports, "isPluginActive", {
|
|
60
66
|
enumerable: true,
|
|
61
|
-
get: function () { return
|
|
67
|
+
get: function () { return chunkMUNO67TT_cjs.isPluginActive; }
|
|
62
68
|
});
|
|
63
69
|
Object.defineProperty(exports, "logActivity", {
|
|
64
70
|
enumerable: true,
|
|
65
|
-
get: function () { return
|
|
71
|
+
get: function () { return chunkMUNO67TT_cjs.logActivity; }
|
|
66
72
|
});
|
|
67
73
|
Object.defineProperty(exports, "loggingMiddleware", {
|
|
68
74
|
enumerable: true,
|
|
69
|
-
get: function () { return
|
|
75
|
+
get: function () { return chunkMUNO67TT_cjs.loggingMiddleware; }
|
|
70
76
|
});
|
|
71
77
|
Object.defineProperty(exports, "metricsMiddleware", {
|
|
72
78
|
enumerable: true,
|
|
73
|
-
get: function () { return
|
|
79
|
+
get: function () { return chunkMUNO67TT_cjs.metricsMiddleware; }
|
|
74
80
|
});
|
|
75
81
|
Object.defineProperty(exports, "optionalAuth", {
|
|
76
82
|
enumerable: true,
|
|
77
|
-
get: function () { return
|
|
83
|
+
get: function () { return chunkMUNO67TT_cjs.optionalAuth; }
|
|
78
84
|
});
|
|
79
85
|
Object.defineProperty(exports, "performanceLoggingMiddleware", {
|
|
80
86
|
enumerable: true,
|
|
81
|
-
get: function () { return
|
|
87
|
+
get: function () { return chunkMUNO67TT_cjs.performanceLoggingMiddleware; }
|
|
82
88
|
});
|
|
83
89
|
Object.defineProperty(exports, "rateLimit", {
|
|
84
90
|
enumerable: true,
|
|
85
|
-
get: function () { return
|
|
91
|
+
get: function () { return chunkMUNO67TT_cjs.rateLimit; }
|
|
86
92
|
});
|
|
87
93
|
Object.defineProperty(exports, "requireActivePlugin", {
|
|
88
94
|
enumerable: true,
|
|
89
|
-
get: function () { return
|
|
95
|
+
get: function () { return chunkMUNO67TT_cjs.requireActivePlugin; }
|
|
90
96
|
});
|
|
91
97
|
Object.defineProperty(exports, "requireActivePlugins", {
|
|
92
98
|
enumerable: true,
|
|
93
|
-
get: function () { return
|
|
99
|
+
get: function () { return chunkMUNO67TT_cjs.requireActivePlugins; }
|
|
94
100
|
});
|
|
95
101
|
Object.defineProperty(exports, "requireAnyPermission", {
|
|
96
102
|
enumerable: true,
|
|
97
|
-
get: function () { return
|
|
103
|
+
get: function () { return chunkMUNO67TT_cjs.requireAnyPermission; }
|
|
98
104
|
});
|
|
99
105
|
Object.defineProperty(exports, "requireAuth", {
|
|
100
106
|
enumerable: true,
|
|
101
|
-
get: function () { return
|
|
107
|
+
get: function () { return chunkMUNO67TT_cjs.requireAuth; }
|
|
102
108
|
});
|
|
103
109
|
Object.defineProperty(exports, "requirePermission", {
|
|
104
110
|
enumerable: true,
|
|
105
|
-
get: function () { return
|
|
111
|
+
get: function () { return chunkMUNO67TT_cjs.requirePermission; }
|
|
106
112
|
});
|
|
107
113
|
Object.defineProperty(exports, "requireRole", {
|
|
108
114
|
enumerable: true,
|
|
109
|
-
get: function () { return
|
|
115
|
+
get: function () { return chunkMUNO67TT_cjs.requireRole; }
|
|
110
116
|
});
|
|
111
117
|
Object.defineProperty(exports, "securityHeaders", {
|
|
112
118
|
enumerable: true,
|
|
113
|
-
get: function () { return
|
|
119
|
+
get: function () { return chunkMUNO67TT_cjs.securityHeadersMiddleware; }
|
|
114
120
|
});
|
|
115
121
|
Object.defineProperty(exports, "securityLoggingMiddleware", {
|
|
116
122
|
enumerable: true,
|
|
117
|
-
get: function () { return
|
|
123
|
+
get: function () { return chunkMUNO67TT_cjs.securityLoggingMiddleware; }
|
|
118
124
|
});
|
|
119
125
|
Object.defineProperty(exports, "validateCsrfToken", {
|
|
120
126
|
enumerable: true,
|
|
121
|
-
get: function () { return
|
|
127
|
+
get: function () { return chunkMUNO67TT_cjs.validateCsrfToken; }
|
|
122
128
|
});
|
|
123
129
|
Object.defineProperty(exports, "verifySecurityConfig", {
|
|
124
130
|
enumerable: true,
|
|
125
|
-
get: function () { return
|
|
131
|
+
get: function () { return chunkMUNO67TT_cjs.verifySecurityConfig; }
|
|
126
132
|
});
|
|
127
133
|
//# sourceMappingURL=middleware.cjs.map
|
|
128
134
|
//# sourceMappingURL=middleware.cjs.map
|
package/dist/middleware.d.cts
CHANGED
|
@@ -1,7 +1,15 @@
|
|
|
1
1
|
import * as hono from 'hono';
|
|
2
2
|
import { Context, Next, MiddlewareHandler } from 'hono';
|
|
3
|
-
import { S as SonicJSConfig } from './app-
|
|
4
|
-
import '@cloudflare/workers-types';
|
|
3
|
+
import { S as SonicJSConfig } from './app-Do66yCcV.cjs';
|
|
4
|
+
import { D1Database as D1Database$1 } from '@cloudflare/workers-types';
|
|
5
|
+
import 'better-auth/client';
|
|
6
|
+
import 'better-auth/plugins/email-otp';
|
|
7
|
+
import 'better-auth';
|
|
8
|
+
import 'better-auth/plugins/magic-link';
|
|
9
|
+
import 'better-call';
|
|
10
|
+
import 'zod/v4/core';
|
|
11
|
+
import 'zod';
|
|
12
|
+
import './types-Dea1eNxU.cjs';
|
|
5
13
|
|
|
6
14
|
type Bindings = {
|
|
7
15
|
DB: D1Database;
|
|
@@ -22,6 +30,9 @@ declare function verifySecurityConfig(env: Bindings): void;
|
|
|
22
30
|
*/
|
|
23
31
|
declare function bootstrapMiddleware(config?: SonicJSConfig): (c: Context<{
|
|
24
32
|
Bindings: Bindings;
|
|
33
|
+
Variables: {
|
|
34
|
+
hookSystem?: unknown;
|
|
35
|
+
};
|
|
25
36
|
}>, next: Next) => Promise<void>;
|
|
26
37
|
|
|
27
38
|
type JWTPayload = {
|
|
@@ -112,7 +123,7 @@ declare const requireRole: (requiredRole: string | string[]) => (c: Context, nex
|
|
|
112
123
|
}, 401, "json">) | (Response & hono.TypedResponse<{
|
|
113
124
|
error: string;
|
|
114
125
|
}, 403, "json">)>;
|
|
115
|
-
declare const optionalAuth: () => (
|
|
126
|
+
declare const optionalAuth: () => (_c: Context, next: Next) => Promise<void>;
|
|
116
127
|
|
|
117
128
|
/**
|
|
118
129
|
* Middleware to track all HTTP requests for real-time analytics
|
|
@@ -189,6 +200,42 @@ declare function rateLimit(options: RateLimitOptions): (c: Context, next: Next)
|
|
|
189
200
|
*/
|
|
190
201
|
declare const securityHeadersMiddleware: () => (c: Context, next: Next) => Promise<void>;
|
|
191
202
|
|
|
203
|
+
/**
|
|
204
|
+
* Plugin Middleware
|
|
205
|
+
*
|
|
206
|
+
* Provides middleware functions for checking plugin status and enforcing plugin requirements
|
|
207
|
+
*/
|
|
208
|
+
|
|
209
|
+
/**
|
|
210
|
+
* Check if a plugin is active
|
|
211
|
+
* @param db - The D1 database instance
|
|
212
|
+
* @param pluginId - The plugin ID to check
|
|
213
|
+
* @returns Promise<boolean> - True if the plugin is active, false otherwise
|
|
214
|
+
*/
|
|
215
|
+
declare function isPluginActive(db: D1Database$1, pluginId: string): Promise<boolean>;
|
|
216
|
+
/**
|
|
217
|
+
* Middleware to require a plugin to be active
|
|
218
|
+
* Throws an error if the plugin is not active
|
|
219
|
+
* @param db - The D1 database instance
|
|
220
|
+
* @param pluginId - The plugin ID to check
|
|
221
|
+
* @throws Error if plugin is not active
|
|
222
|
+
*/
|
|
223
|
+
declare function requireActivePlugin(db: D1Database$1, pluginId: string): Promise<void>;
|
|
224
|
+
/**
|
|
225
|
+
* Middleware to require multiple plugins to be active
|
|
226
|
+
* Throws an error if any plugin is not active
|
|
227
|
+
* @param db - The D1 database instance
|
|
228
|
+
* @param pluginIds - Array of plugin IDs to check
|
|
229
|
+
* @throws Error if any plugin is not active
|
|
230
|
+
*/
|
|
231
|
+
declare function requireActivePlugins(db: D1Database$1, pluginIds: string[]): Promise<void>;
|
|
232
|
+
/**
|
|
233
|
+
* Get all active plugins
|
|
234
|
+
* @param db - The D1 database instance
|
|
235
|
+
* @returns Promise<any[]> - Array of active plugin records
|
|
236
|
+
*/
|
|
237
|
+
declare function getActivePlugins(db: D1Database$1): Promise<any[]>;
|
|
238
|
+
|
|
192
239
|
/**
|
|
193
240
|
* Middleware Module Exports
|
|
194
241
|
*
|
|
@@ -214,9 +261,5 @@ declare const PermissionManager: any;
|
|
|
214
261
|
declare const requirePermission: any;
|
|
215
262
|
declare const requireAnyPermission: any;
|
|
216
263
|
declare const logActivity: any;
|
|
217
|
-
declare const requireActivePlugin: any;
|
|
218
|
-
declare const requireActivePlugins: any;
|
|
219
|
-
declare const getActivePlugins: any;
|
|
220
|
-
declare const isPluginActive: any;
|
|
221
264
|
|
|
222
265
|
export { AuthManager, type Permission, PermissionManager, type UserPermissions, bootstrapMiddleware, cacheHeaders, compressionMiddleware, csrfProtection, detailedLoggingMiddleware, generateCsrfToken, getActivePlugins, getJwtExpirySeconds, getJwtExpirySecondsFromDb, getJwtRefreshGraceSecondsFromDb, isPluginActive, logActivity, loggingMiddleware, metricsMiddleware, optionalAuth, performanceLoggingMiddleware, rateLimit, requireActivePlugin, requireActivePlugins, requireAnyPermission, requireAuth, requirePermission, requireRole, securityHeadersMiddleware as securityHeaders, securityLoggingMiddleware, validateCsrfToken, verifySecurityConfig };
|
package/dist/middleware.d.ts
CHANGED
|
@@ -1,7 +1,15 @@
|
|
|
1
1
|
import * as hono from 'hono';
|
|
2
2
|
import { Context, Next, MiddlewareHandler } from 'hono';
|
|
3
|
-
import { S as SonicJSConfig } from './app-
|
|
4
|
-
import '@cloudflare/workers-types';
|
|
3
|
+
import { S as SonicJSConfig } from './app-Bo0X1OWX.js';
|
|
4
|
+
import { D1Database as D1Database$1 } from '@cloudflare/workers-types';
|
|
5
|
+
import 'better-auth/client';
|
|
6
|
+
import 'better-auth/plugins/email-otp';
|
|
7
|
+
import 'better-auth';
|
|
8
|
+
import 'better-auth/plugins/magic-link';
|
|
9
|
+
import 'better-call';
|
|
10
|
+
import 'zod/v4/core';
|
|
11
|
+
import 'zod';
|
|
12
|
+
import './types-Dea1eNxU.js';
|
|
5
13
|
|
|
6
14
|
type Bindings = {
|
|
7
15
|
DB: D1Database;
|
|
@@ -22,6 +30,9 @@ declare function verifySecurityConfig(env: Bindings): void;
|
|
|
22
30
|
*/
|
|
23
31
|
declare function bootstrapMiddleware(config?: SonicJSConfig): (c: Context<{
|
|
24
32
|
Bindings: Bindings;
|
|
33
|
+
Variables: {
|
|
34
|
+
hookSystem?: unknown;
|
|
35
|
+
};
|
|
25
36
|
}>, next: Next) => Promise<void>;
|
|
26
37
|
|
|
27
38
|
type JWTPayload = {
|
|
@@ -112,7 +123,7 @@ declare const requireRole: (requiredRole: string | string[]) => (c: Context, nex
|
|
|
112
123
|
}, 401, "json">) | (Response & hono.TypedResponse<{
|
|
113
124
|
error: string;
|
|
114
125
|
}, 403, "json">)>;
|
|
115
|
-
declare const optionalAuth: () => (
|
|
126
|
+
declare const optionalAuth: () => (_c: Context, next: Next) => Promise<void>;
|
|
116
127
|
|
|
117
128
|
/**
|
|
118
129
|
* Middleware to track all HTTP requests for real-time analytics
|
|
@@ -189,6 +200,42 @@ declare function rateLimit(options: RateLimitOptions): (c: Context, next: Next)
|
|
|
189
200
|
*/
|
|
190
201
|
declare const securityHeadersMiddleware: () => (c: Context, next: Next) => Promise<void>;
|
|
191
202
|
|
|
203
|
+
/**
|
|
204
|
+
* Plugin Middleware
|
|
205
|
+
*
|
|
206
|
+
* Provides middleware functions for checking plugin status and enforcing plugin requirements
|
|
207
|
+
*/
|
|
208
|
+
|
|
209
|
+
/**
|
|
210
|
+
* Check if a plugin is active
|
|
211
|
+
* @param db - The D1 database instance
|
|
212
|
+
* @param pluginId - The plugin ID to check
|
|
213
|
+
* @returns Promise<boolean> - True if the plugin is active, false otherwise
|
|
214
|
+
*/
|
|
215
|
+
declare function isPluginActive(db: D1Database$1, pluginId: string): Promise<boolean>;
|
|
216
|
+
/**
|
|
217
|
+
* Middleware to require a plugin to be active
|
|
218
|
+
* Throws an error if the plugin is not active
|
|
219
|
+
* @param db - The D1 database instance
|
|
220
|
+
* @param pluginId - The plugin ID to check
|
|
221
|
+
* @throws Error if plugin is not active
|
|
222
|
+
*/
|
|
223
|
+
declare function requireActivePlugin(db: D1Database$1, pluginId: string): Promise<void>;
|
|
224
|
+
/**
|
|
225
|
+
* Middleware to require multiple plugins to be active
|
|
226
|
+
* Throws an error if any plugin is not active
|
|
227
|
+
* @param db - The D1 database instance
|
|
228
|
+
* @param pluginIds - Array of plugin IDs to check
|
|
229
|
+
* @throws Error if any plugin is not active
|
|
230
|
+
*/
|
|
231
|
+
declare function requireActivePlugins(db: D1Database$1, pluginIds: string[]): Promise<void>;
|
|
232
|
+
/**
|
|
233
|
+
* Get all active plugins
|
|
234
|
+
* @param db - The D1 database instance
|
|
235
|
+
* @returns Promise<any[]> - Array of active plugin records
|
|
236
|
+
*/
|
|
237
|
+
declare function getActivePlugins(db: D1Database$1): Promise<any[]>;
|
|
238
|
+
|
|
192
239
|
/**
|
|
193
240
|
* Middleware Module Exports
|
|
194
241
|
*
|
|
@@ -214,9 +261,5 @@ declare const PermissionManager: any;
|
|
|
214
261
|
declare const requirePermission: any;
|
|
215
262
|
declare const requireAnyPermission: any;
|
|
216
263
|
declare const logActivity: any;
|
|
217
|
-
declare const requireActivePlugin: any;
|
|
218
|
-
declare const requireActivePlugins: any;
|
|
219
|
-
declare const getActivePlugins: any;
|
|
220
|
-
declare const isPluginActive: any;
|
|
221
264
|
|
|
222
265
|
export { AuthManager, type Permission, PermissionManager, type UserPermissions, bootstrapMiddleware, cacheHeaders, compressionMiddleware, csrfProtection, detailedLoggingMiddleware, generateCsrfToken, getActivePlugins, getJwtExpirySeconds, getJwtExpirySecondsFromDb, getJwtRefreshGraceSecondsFromDb, isPluginActive, logActivity, loggingMiddleware, metricsMiddleware, optionalAuth, performanceLoggingMiddleware, rateLimit, requireActivePlugin, requireActivePlugins, requireAnyPermission, requireAuth, requirePermission, requireRole, securityHeadersMiddleware as securityHeaders, securityLoggingMiddleware, validateCsrfToken, verifySecurityConfig };
|
package/dist/middleware.js
CHANGED
|
@@ -1,7 +1,13 @@
|
|
|
1
|
-
export { AuthManager, PermissionManager, bootstrapMiddleware, cacheHeaders, compressionMiddleware, csrfProtection, detailedLoggingMiddleware, generateCsrfToken, getActivePlugins, getJwtExpirySeconds, getJwtExpirySecondsFromDb, getJwtRefreshGraceSecondsFromDb, isPluginActive, logActivity, loggingMiddleware, metricsMiddleware, optionalAuth, performanceLoggingMiddleware, rateLimit, requireActivePlugin, requireActivePlugins, requireAnyPermission, requireAuth, requirePermission, requireRole, securityHeadersMiddleware as securityHeaders, securityLoggingMiddleware, validateCsrfToken, verifySecurityConfig } from './chunk-
|
|
2
|
-
import './chunk-
|
|
3
|
-
import './chunk-
|
|
1
|
+
export { AuthManager, PermissionManager, bootstrapMiddleware, cacheHeaders, compressionMiddleware, csrfProtection, detailedLoggingMiddleware, generateCsrfToken, getActivePlugins, getJwtExpirySeconds, getJwtExpirySecondsFromDb, getJwtRefreshGraceSecondsFromDb, isPluginActive, logActivity, loggingMiddleware, metricsMiddleware, optionalAuth, performanceLoggingMiddleware, rateLimit, requireActivePlugin, requireActivePlugins, requireAnyPermission, requireAuth, requirePermission, requireRole, securityHeadersMiddleware as securityHeaders, securityLoggingMiddleware, validateCsrfToken, verifySecurityConfig } from './chunk-IDCZBF35.js';
|
|
2
|
+
import './chunk-BLMTL57B.js';
|
|
3
|
+
import './chunk-GCDZZNIN.js';
|
|
4
|
+
import './chunk-PYVFXCSD.js';
|
|
5
|
+
import './chunk-ALDRXTUO.js';
|
|
6
|
+
import './chunk-5V62WT6M.js';
|
|
7
|
+
import './chunk-RNZFGN4R.js';
|
|
4
8
|
import './chunk-FICTAGD4.js';
|
|
9
|
+
import './chunk-X7ZAEI5S.js';
|
|
10
|
+
import './chunk-TQABQWOP.js';
|
|
5
11
|
import './chunk-V4OQ3NZ2.js';
|
|
6
12
|
//# sourceMappingURL=middleware.js.map
|
|
7
13
|
//# sourceMappingURL=middleware.js.map
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
var chunkIHTXB7AT_cjs = require('./chunk-IHTXB7AT.cjs');
|
|
4
|
+
require('./chunk-IGJUBJBW.cjs');
|
|
5
|
+
|
|
6
|
+
|
|
7
|
+
|
|
8
|
+
Object.defineProperty(exports, "MigrationService", {
|
|
9
|
+
enumerable: true,
|
|
10
|
+
get: function () { return chunkIHTXB7AT_cjs.MigrationService; }
|
|
11
|
+
});
|
|
12
|
+
//# sourceMappingURL=migrations-2XHQEGOQ.cjs.map
|
|
13
|
+
//# sourceMappingURL=migrations-2XHQEGOQ.cjs.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":[],"names":[],"mappings":"","file":"migrations-
|
|
1
|
+
{"version":3,"sources":[],"names":[],"mappings":"","file":"migrations-2XHQEGOQ.cjs"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":[],"names":[],"mappings":"","file":"migrations-
|
|
1
|
+
{"version":3,"sources":[],"names":[],"mappings":"","file":"migrations-PE3CDVSM.js"}
|