@sonicjs-cms/core 2.19.0 → 3.0.0-beta.3
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 +4 -3
- package/dist/admin-documents-form.template-KN7JF66Q.cjs +19 -0
- package/dist/{admin-layout-catalyst.template-UMTIN66R.js.map → admin-documents-form.template-KN7JF66Q.cjs.map} +1 -1
- package/dist/admin-documents-form.template-NLSI6Z42.js +6 -0
- package/dist/{admin-layout-catalyst.template-HFD37TY5.cjs.map → admin-documents-form.template-NLSI6Z42.js.map} +1 -1
- package/dist/admin-layout-catalyst.template-WHJGSWWD.js +7 -0
- package/dist/admin-layout-catalyst.template-WHJGSWWD.js.map +1 -0
- package/dist/admin-layout-catalyst.template-ZK5HD545.cjs +17 -0
- package/dist/admin-layout-catalyst.template-ZK5HD545.cjs.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-2JTWQZHG.cjs +276 -0
- package/dist/chunk-2JTWQZHG.cjs.map +1 -0
- package/dist/{chunk-55RDMDOP.js → chunk-3TB6AT6X.js} +148 -55
- package/dist/chunk-3TB6AT6X.js.map +1 -0
- package/dist/{chunk-E4YFJBM2.cjs → chunk-673S7EBY.cjs} +621 -829
- package/dist/chunk-673S7EBY.cjs.map +1 -0
- package/dist/{chunk-ON5ZMSU4.js → chunk-6JQOUUOB.js} +3 -3
- package/dist/chunk-6JQOUUOB.js.map +1 -0
- package/dist/chunk-7LHUVREV.cjs +158 -0
- package/dist/chunk-7LHUVREV.cjs.map +1 -0
- package/dist/chunk-AI663NBO.js +821 -0
- package/dist/chunk-AI663NBO.js.map +1 -0
- package/dist/chunk-BDDABDAB.cjs +1149 -0
- package/dist/chunk-BDDABDAB.cjs.map +1 -0
- package/dist/chunk-BLMTL57B.js +767 -0
- package/dist/chunk-BLMTL57B.js.map +1 -0
- package/dist/{chunk-ABB34XUS.cjs → chunk-CHCBHIBM.cjs} +667 -19
- package/dist/chunk-CHCBHIBM.cjs.map +1 -0
- package/dist/chunk-DNQCEKUK.cjs +327 -0
- package/dist/chunk-DNQCEKUK.cjs.map +1 -0
- package/dist/chunk-EF2NQUIQ.js +323 -0
- package/dist/chunk-EF2NQUIQ.js.map +1 -0
- package/dist/chunk-GCDZZNIN.js +192 -0
- package/dist/chunk-GCDZZNIN.js.map +1 -0
- package/dist/{chunk-XWIA3HVX.js → chunk-HDWE5FRJ.js} +6 -1249
- package/dist/chunk-HDWE5FRJ.js.map +1 -0
- package/dist/chunk-HIKBY7MS.cjs +70 -0
- package/dist/chunk-HIKBY7MS.cjs.map +1 -0
- package/dist/chunk-IESEVHXL.js +66 -0
- package/dist/chunk-IESEVHXL.js.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-7A4CB7T3.cjs → chunk-J5DCX3F6.cjs} +509 -91
- package/dist/chunk-J5DCX3F6.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-K25XHMM3.js +566 -0
- package/dist/chunk-K25XHMM3.js.map +1 -0
- package/dist/{chunk-R4FOLLFB.cjs → chunk-LO6MEPRW.cjs} +8730 -11520
- package/dist/chunk-LO6MEPRW.cjs.map +1 -0
- package/dist/chunk-MHP7HYTT.js +273 -0
- package/dist/chunk-MHP7HYTT.js.map +1 -0
- package/dist/chunk-MP3Q2W76.js +387 -0
- package/dist/chunk-MP3Q2W76.js.map +1 -0
- package/dist/{chunk-OHYBNCVL.cjs → chunk-MVIZJOO5.cjs} +10 -1256
- package/dist/chunk-MVIZJOO5.cjs.map +1 -0
- package/dist/{chunk-UYJ6TJHX.cjs → chunk-NAVPFIG5.cjs} +148 -55
- package/dist/chunk-NAVPFIG5.cjs.map +1 -0
- package/dist/chunk-NUKJ54GA.cjs +245 -0
- package/dist/chunk-NUKJ54GA.cjs.map +1 -0
- package/dist/{chunk-BU7SFHGP.js → chunk-QZGABF2M.js} +3 -149
- package/dist/chunk-QZGABF2M.js.map +1 -0
- package/dist/{chunk-JZV22DEV.js → chunk-RJV6UXLZ.js} +611 -817
- package/dist/chunk-RJV6UXLZ.js.map +1 -0
- package/dist/chunk-RNZFGN4R.js +88 -0
- package/dist/chunk-RNZFGN4R.js.map +1 -0
- package/dist/{chunk-TFNTM3OA.js → chunk-SL6XS6YT.js} +645 -15
- package/dist/chunk-SL6XS6YT.js.map +1 -0
- package/dist/{chunk-OCL3HMEG.js → chunk-SO2T3OXR.js} +7004 -9807
- package/dist/chunk-SO2T3OXR.js.map +1 -0
- package/dist/chunk-VQHAJUZZ.cjs +408 -0
- package/dist/chunk-VQHAJUZZ.cjs.map +1 -0
- package/dist/{chunk-4NPCDK6B.js → chunk-VZ3NHR5Z.js} +505 -90
- package/dist/chunk-VZ3NHR5Z.js.map +1 -0
- package/dist/{chunk-4ZSNJDLS.cjs → chunk-WULONYGB.cjs} +9 -9
- package/dist/chunk-WULONYGB.cjs.map +1 -0
- package/dist/chunk-XFQHK64T.js +154 -0
- package/dist/chunk-XFQHK64T.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/{chunk-QFWHAFEO.js → chunk-ZEZ245PW.js} +148 -858
- package/dist/chunk-ZEZ245PW.js.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 +13734 -4328
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +329 -492
- package/dist/index.d.ts +329 -492
- package/dist/index.js +13385 -3998
- package/dist/index.js.map +1 -1
- package/dist/middleware.cjs +36 -32
- package/dist/middleware.d.cts +50 -7
- package/dist/middleware.d.ts +50 -7
- package/dist/middleware.js +7 -3
- package/dist/migrations-DK2YFPLR.js +4 -0
- package/dist/{migrations-H5IXZNCO.js.map → migrations-DK2YFPLR.js.map} +1 -1
- package/dist/migrations-YHNHTJOO.cjs +13 -0
- package/dist/{migrations-566IIPS2.cjs.map → migrations-YHNHTJOO.cjs.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 +41 -45
- package/dist/routes.d.cts +56 -146
- package/dist/routes.d.ts +56 -146
- package/dist/routes.js +17 -9
- package/dist/services.cjs +39 -72
- package/dist/services.d.cts +79 -54
- package/dist/services.d.ts +79 -54
- package/dist/services.js +6 -3
- package/dist/templates.cjs +17 -29
- package/dist/templates.d.cts +1 -66
- package/dist/templates.d.ts +1 -66
- 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 +1 -1
- package/dist/types.d.ts +1 -1
- package/dist/utils.cjs +18 -17
- package/dist/utils.d.cts +1 -1
- package/dist/utils.d.ts +1 -1
- package/dist/utils.js +2 -1
- 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.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.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,132 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var
|
|
4
|
-
require('./chunk-
|
|
5
|
-
require('./chunk-
|
|
3
|
+
var chunkJ5DCX3F6_cjs = require('./chunk-J5DCX3F6.cjs');
|
|
4
|
+
require('./chunk-2CB4KY7I.cjs');
|
|
5
|
+
require('./chunk-JEQ7FLOD.cjs');
|
|
6
|
+
require('./chunk-673S7EBY.cjs');
|
|
7
|
+
require('./chunk-2JTWQZHG.cjs');
|
|
8
|
+
require('./chunk-J6JTWD2A.cjs');
|
|
6
9
|
require('./chunk-RCQ2HIQD.cjs');
|
|
10
|
+
require('./chunk-MNWKYY5E.cjs');
|
|
7
11
|
require('./chunk-IGJUBJBW.cjs');
|
|
8
12
|
|
|
9
13
|
|
|
10
14
|
|
|
11
15
|
Object.defineProperty(exports, "AuthManager", {
|
|
12
16
|
enumerable: true,
|
|
13
|
-
get: function () { return
|
|
17
|
+
get: function () { return chunkJ5DCX3F6_cjs.AuthManager; }
|
|
14
18
|
});
|
|
15
19
|
Object.defineProperty(exports, "PermissionManager", {
|
|
16
20
|
enumerable: true,
|
|
17
|
-
get: function () { return
|
|
21
|
+
get: function () { return chunkJ5DCX3F6_cjs.PermissionManager; }
|
|
18
22
|
});
|
|
19
23
|
Object.defineProperty(exports, "bootstrapMiddleware", {
|
|
20
24
|
enumerable: true,
|
|
21
|
-
get: function () { return
|
|
25
|
+
get: function () { return chunkJ5DCX3F6_cjs.bootstrapMiddleware; }
|
|
22
26
|
});
|
|
23
27
|
Object.defineProperty(exports, "cacheHeaders", {
|
|
24
28
|
enumerable: true,
|
|
25
|
-
get: function () { return
|
|
29
|
+
get: function () { return chunkJ5DCX3F6_cjs.cacheHeaders; }
|
|
26
30
|
});
|
|
27
31
|
Object.defineProperty(exports, "compressionMiddleware", {
|
|
28
32
|
enumerable: true,
|
|
29
|
-
get: function () { return
|
|
33
|
+
get: function () { return chunkJ5DCX3F6_cjs.compressionMiddleware; }
|
|
30
34
|
});
|
|
31
35
|
Object.defineProperty(exports, "csrfProtection", {
|
|
32
36
|
enumerable: true,
|
|
33
|
-
get: function () { return
|
|
37
|
+
get: function () { return chunkJ5DCX3F6_cjs.csrfProtection; }
|
|
34
38
|
});
|
|
35
39
|
Object.defineProperty(exports, "detailedLoggingMiddleware", {
|
|
36
40
|
enumerable: true,
|
|
37
|
-
get: function () { return
|
|
41
|
+
get: function () { return chunkJ5DCX3F6_cjs.detailedLoggingMiddleware; }
|
|
38
42
|
});
|
|
39
43
|
Object.defineProperty(exports, "generateCsrfToken", {
|
|
40
44
|
enumerable: true,
|
|
41
|
-
get: function () { return
|
|
45
|
+
get: function () { return chunkJ5DCX3F6_cjs.generateCsrfToken; }
|
|
42
46
|
});
|
|
43
47
|
Object.defineProperty(exports, "getActivePlugins", {
|
|
44
48
|
enumerable: true,
|
|
45
|
-
get: function () { return
|
|
49
|
+
get: function () { return chunkJ5DCX3F6_cjs.getActivePlugins; }
|
|
46
50
|
});
|
|
47
51
|
Object.defineProperty(exports, "getJwtExpirySeconds", {
|
|
48
52
|
enumerable: true,
|
|
49
|
-
get: function () { return
|
|
53
|
+
get: function () { return chunkJ5DCX3F6_cjs.getJwtExpirySeconds; }
|
|
50
54
|
});
|
|
51
55
|
Object.defineProperty(exports, "getJwtExpirySecondsFromDb", {
|
|
52
56
|
enumerable: true,
|
|
53
|
-
get: function () { return
|
|
57
|
+
get: function () { return chunkJ5DCX3F6_cjs.getJwtExpirySecondsFromDb; }
|
|
54
58
|
});
|
|
55
59
|
Object.defineProperty(exports, "getJwtRefreshGraceSecondsFromDb", {
|
|
56
60
|
enumerable: true,
|
|
57
|
-
get: function () { return
|
|
61
|
+
get: function () { return chunkJ5DCX3F6_cjs.getJwtRefreshGraceSecondsFromDb; }
|
|
58
62
|
});
|
|
59
63
|
Object.defineProperty(exports, "isPluginActive", {
|
|
60
64
|
enumerable: true,
|
|
61
|
-
get: function () { return
|
|
65
|
+
get: function () { return chunkJ5DCX3F6_cjs.isPluginActive; }
|
|
62
66
|
});
|
|
63
67
|
Object.defineProperty(exports, "logActivity", {
|
|
64
68
|
enumerable: true,
|
|
65
|
-
get: function () { return
|
|
69
|
+
get: function () { return chunkJ5DCX3F6_cjs.logActivity; }
|
|
66
70
|
});
|
|
67
71
|
Object.defineProperty(exports, "loggingMiddleware", {
|
|
68
72
|
enumerable: true,
|
|
69
|
-
get: function () { return
|
|
73
|
+
get: function () { return chunkJ5DCX3F6_cjs.loggingMiddleware; }
|
|
70
74
|
});
|
|
71
75
|
Object.defineProperty(exports, "metricsMiddleware", {
|
|
72
76
|
enumerable: true,
|
|
73
|
-
get: function () { return
|
|
77
|
+
get: function () { return chunkJ5DCX3F6_cjs.metricsMiddleware; }
|
|
74
78
|
});
|
|
75
79
|
Object.defineProperty(exports, "optionalAuth", {
|
|
76
80
|
enumerable: true,
|
|
77
|
-
get: function () { return
|
|
81
|
+
get: function () { return chunkJ5DCX3F6_cjs.optionalAuth; }
|
|
78
82
|
});
|
|
79
83
|
Object.defineProperty(exports, "performanceLoggingMiddleware", {
|
|
80
84
|
enumerable: true,
|
|
81
|
-
get: function () { return
|
|
85
|
+
get: function () { return chunkJ5DCX3F6_cjs.performanceLoggingMiddleware; }
|
|
82
86
|
});
|
|
83
87
|
Object.defineProperty(exports, "rateLimit", {
|
|
84
88
|
enumerable: true,
|
|
85
|
-
get: function () { return
|
|
89
|
+
get: function () { return chunkJ5DCX3F6_cjs.rateLimit; }
|
|
86
90
|
});
|
|
87
91
|
Object.defineProperty(exports, "requireActivePlugin", {
|
|
88
92
|
enumerable: true,
|
|
89
|
-
get: function () { return
|
|
93
|
+
get: function () { return chunkJ5DCX3F6_cjs.requireActivePlugin; }
|
|
90
94
|
});
|
|
91
95
|
Object.defineProperty(exports, "requireActivePlugins", {
|
|
92
96
|
enumerable: true,
|
|
93
|
-
get: function () { return
|
|
97
|
+
get: function () { return chunkJ5DCX3F6_cjs.requireActivePlugins; }
|
|
94
98
|
});
|
|
95
99
|
Object.defineProperty(exports, "requireAnyPermission", {
|
|
96
100
|
enumerable: true,
|
|
97
|
-
get: function () { return
|
|
101
|
+
get: function () { return chunkJ5DCX3F6_cjs.requireAnyPermission; }
|
|
98
102
|
});
|
|
99
103
|
Object.defineProperty(exports, "requireAuth", {
|
|
100
104
|
enumerable: true,
|
|
101
|
-
get: function () { return
|
|
105
|
+
get: function () { return chunkJ5DCX3F6_cjs.requireAuth; }
|
|
102
106
|
});
|
|
103
107
|
Object.defineProperty(exports, "requirePermission", {
|
|
104
108
|
enumerable: true,
|
|
105
|
-
get: function () { return
|
|
109
|
+
get: function () { return chunkJ5DCX3F6_cjs.requirePermission; }
|
|
106
110
|
});
|
|
107
111
|
Object.defineProperty(exports, "requireRole", {
|
|
108
112
|
enumerable: true,
|
|
109
|
-
get: function () { return
|
|
113
|
+
get: function () { return chunkJ5DCX3F6_cjs.requireRole; }
|
|
110
114
|
});
|
|
111
115
|
Object.defineProperty(exports, "securityHeaders", {
|
|
112
116
|
enumerable: true,
|
|
113
|
-
get: function () { return
|
|
117
|
+
get: function () { return chunkJ5DCX3F6_cjs.securityHeadersMiddleware; }
|
|
114
118
|
});
|
|
115
119
|
Object.defineProperty(exports, "securityLoggingMiddleware", {
|
|
116
120
|
enumerable: true,
|
|
117
|
-
get: function () { return
|
|
121
|
+
get: function () { return chunkJ5DCX3F6_cjs.securityLoggingMiddleware; }
|
|
118
122
|
});
|
|
119
123
|
Object.defineProperty(exports, "validateCsrfToken", {
|
|
120
124
|
enumerable: true,
|
|
121
|
-
get: function () { return
|
|
125
|
+
get: function () { return chunkJ5DCX3F6_cjs.validateCsrfToken; }
|
|
122
126
|
});
|
|
123
127
|
Object.defineProperty(exports, "verifySecurityConfig", {
|
|
124
128
|
enumerable: true,
|
|
125
|
-
get: function () { return
|
|
129
|
+
get: function () { return chunkJ5DCX3F6_cjs.verifySecurityConfig; }
|
|
126
130
|
});
|
|
127
131
|
//# sourceMappingURL=middleware.cjs.map
|
|
128
132
|
//# 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,11 @@
|
|
|
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-VZ3NHR5Z.js';
|
|
2
|
+
import './chunk-BLMTL57B.js';
|
|
3
|
+
import './chunk-GCDZZNIN.js';
|
|
4
|
+
import './chunk-RJV6UXLZ.js';
|
|
5
|
+
import './chunk-MHP7HYTT.js';
|
|
6
|
+
import './chunk-RNZFGN4R.js';
|
|
4
7
|
import './chunk-FICTAGD4.js';
|
|
8
|
+
import './chunk-TQABQWOP.js';
|
|
5
9
|
import './chunk-V4OQ3NZ2.js';
|
|
6
10
|
//# sourceMappingURL=middleware.js.map
|
|
7
11
|
//# sourceMappingURL=middleware.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":[],"names":[],"mappings":"","file":"migrations-
|
|
1
|
+
{"version":3,"sources":[],"names":[],"mappings":"","file":"migrations-DK2YFPLR.js"}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
var chunk2JTWQZHG_cjs = require('./chunk-2JTWQZHG.cjs');
|
|
4
|
+
require('./chunk-IGJUBJBW.cjs');
|
|
5
|
+
|
|
6
|
+
|
|
7
|
+
|
|
8
|
+
Object.defineProperty(exports, "MigrationService", {
|
|
9
|
+
enumerable: true,
|
|
10
|
+
get: function () { return chunk2JTWQZHG_cjs.MigrationService; }
|
|
11
|
+
});
|
|
12
|
+
//# sourceMappingURL=migrations-YHNHTJOO.cjs.map
|
|
13
|
+
//# sourceMappingURL=migrations-YHNHTJOO.cjs.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":[],"names":[],"mappings":"","file":"migrations-
|
|
1
|
+
{"version":3,"sources":[],"names":[],"mappings":"","file":"migrations-YHNHTJOO.cjs"}
|