@kyro-cms/core 0.9.0 → 0.9.2
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 +55 -593
- package/dist/{WebhookService-AefJfqX0.d.cts → WebhookService-BKszZlG0.d.cts} +1 -1
- package/dist/{WebhookService-118ZTFis.d.ts → WebhookService-Ccf1j-IN.d.ts} +1 -1
- package/dist/api-handler-graphql.cjs +44 -0
- package/dist/api-handler-graphql.cjs.map +1 -0
- package/dist/api-handler-graphql.d.cts +6 -0
- package/dist/api-handler-graphql.d.ts +6 -0
- package/dist/api-handler-graphql.js +41 -0
- package/dist/api-handler-graphql.js.map +1 -0
- package/dist/api-handler-trpc.cjs +38 -0
- package/dist/api-handler-trpc.cjs.map +1 -0
- package/dist/api-handler-trpc.d.cts +5 -0
- package/dist/api-handler-trpc.d.ts +5 -0
- package/dist/api-handler-trpc.js +36 -0
- package/dist/api-handler-trpc.js.map +1 -0
- package/dist/api-handler.cjs +33 -99
- package/dist/api-handler.cjs.map +1 -1
- package/dist/api-handler.d.cts +2 -1
- package/dist/api-handler.d.ts +2 -1
- package/dist/api-handler.js +21 -97
- package/dist/api-handler.js.map +1 -1
- package/dist/{tenant-B1YB0Jy8.d.ts → base-CIuXkrH4.d.cts} +7 -15
- package/dist/{tenant-Cpeveji6.d.cts → base-fFo4lqER.d.ts} +7 -15
- package/dist/bootstrap-3PV3GJ3S.js +7 -0
- package/dist/{bootstrap-JCML6NFO.js.map → bootstrap-3PV3GJ3S.js.map} +1 -1
- package/dist/bootstrap-4CELFLJO.cjs +32 -0
- package/dist/{bootstrap-AKAUP6F6.cjs.map → bootstrap-4CELFLJO.cjs.map} +1 -1
- package/dist/{chunk-VJT6P4N6.cjs → chunk-3HR772HI.cjs} +199 -32
- package/dist/chunk-3HR772HI.cjs.map +1 -0
- package/dist/chunk-3KTWGODI.cjs +178 -0
- package/dist/chunk-3KTWGODI.cjs.map +1 -0
- package/dist/{chunk-QXIQWPAP.js → chunk-3UK5XBVJ.js} +4 -134
- package/dist/chunk-3UK5XBVJ.js.map +1 -0
- package/dist/{chunk-FXYP2HA6.js → chunk-4AO3A3JM.js} +48 -4
- package/dist/chunk-4AO3A3JM.js.map +1 -0
- package/dist/{chunk-Z6ZWNWWR.js → chunk-4CV4JOE5.js} +3 -9
- package/dist/{chunk-Z6ZWNWWR.js.map → chunk-4CV4JOE5.js.map} +1 -1
- package/dist/chunk-4M7X5HAB.cjs +173 -0
- package/dist/chunk-4M7X5HAB.cjs.map +1 -0
- package/dist/chunk-53NYVYVX.js +3243 -0
- package/dist/chunk-53NYVYVX.js.map +1 -0
- package/dist/{chunk-35U3FROB.js → chunk-5H3MWQJS.js} +714 -184
- package/dist/chunk-5H3MWQJS.js.map +1 -0
- package/dist/{chunk-YVUJBEXE.cjs → chunk-5PMQQFRE.cjs} +16 -7
- package/dist/chunk-5PMQQFRE.cjs.map +1 -0
- package/dist/{chunk-57P6MJKC.js → chunk-6UNONDW7.js} +94 -10
- package/dist/chunk-6UNONDW7.js.map +1 -0
- package/dist/{chunk-Y3N7UUDO.js → chunk-7OGPN7MP.js} +5 -2
- package/dist/chunk-7OGPN7MP.js.map +1 -0
- package/dist/{chunk-2OL4O2TH.cjs → chunk-7OS7TX2Q.cjs} +68 -62
- package/dist/chunk-7OS7TX2Q.cjs.map +1 -0
- package/dist/{chunk-3TPQ2BU6.js → chunk-BYBMTIMT.js} +2 -6
- package/dist/chunk-BYBMTIMT.js.map +1 -0
- package/dist/{chunk-ES5HNFFT.js → chunk-CF7OL6HR.js} +4 -2
- package/dist/chunk-CF7OL6HR.js.map +1 -0
- package/dist/chunk-CJONKRHJ.js +162 -0
- package/dist/chunk-CJONKRHJ.js.map +1 -0
- package/dist/{chunk-OHVB4AJ7.js → chunk-CJX74IYK.js} +24 -18
- package/dist/chunk-CJX74IYK.js.map +1 -0
- package/dist/{chunk-5KVM3WEY.cjs → chunk-CNKT4PME.cjs} +1592 -868
- package/dist/chunk-CNKT4PME.cjs.map +1 -0
- package/dist/{chunk-G7VZBCD6.cjs → chunk-CZLDE2OZ.cjs} +2 -9
- package/dist/{chunk-G7VZBCD6.cjs.map → chunk-CZLDE2OZ.cjs.map} +1 -1
- package/dist/{chunk-WQBRWOQT.cjs → chunk-DPA3KWPY.cjs} +4 -3
- package/dist/chunk-DPA3KWPY.cjs.map +1 -0
- package/dist/{chunk-LINKCEG4.cjs → chunk-E2763JUP.cjs} +726 -196
- package/dist/chunk-E2763JUP.cjs.map +1 -0
- package/dist/chunk-E5UJBLQ7.js +220 -0
- package/dist/chunk-E5UJBLQ7.js.map +1 -0
- package/dist/{chunk-DVD5P72E.cjs → chunk-EEJUFDMF.cjs} +2 -6
- package/dist/chunk-EEJUFDMF.cjs.map +1 -0
- package/dist/chunk-FSKONGCX.cjs +253 -0
- package/dist/chunk-FSKONGCX.cjs.map +1 -0
- package/dist/{chunk-Y3QQN7PN.js → chunk-GAAHG2Z4.js} +13 -4
- package/dist/chunk-GAAHG2Z4.js.map +1 -0
- package/dist/chunk-GAOXD3XT.js +175 -0
- package/dist/chunk-GAOXD3XT.js.map +1 -0
- package/dist/{chunk-SA7NSSIQ.cjs → chunk-GUUB5EAG.cjs} +13 -187
- package/dist/chunk-GUUB5EAG.cjs.map +1 -0
- package/dist/{chunk-4DA7QPLA.cjs → chunk-GXFOGU7N.cjs} +5 -2
- package/dist/chunk-GXFOGU7N.cjs.map +1 -0
- package/dist/{chunk-I7HHI6QV.cjs → chunk-IDVRRRAK.cjs} +17 -9
- package/dist/chunk-IDVRRRAK.cjs.map +1 -0
- package/dist/{chunk-HXRD4B37.js → chunk-IPTZM3VE.js} +1423 -704
- package/dist/chunk-IPTZM3VE.js.map +1 -0
- package/dist/chunk-KC2GDBLS.cjs +84 -0
- package/dist/chunk-KC2GDBLS.cjs.map +1 -0
- package/dist/{chunk-QUW2RZTM.cjs → chunk-L46ROHUS.cjs} +51 -7
- package/dist/chunk-L46ROHUS.cjs.map +1 -0
- package/dist/chunk-L4EZKIEX.js +185 -0
- package/dist/chunk-L4EZKIEX.js.map +1 -0
- package/dist/{chunk-REK7AYOC.js → chunk-L5UKKZQN.js} +199 -32
- package/dist/chunk-L5UKKZQN.js.map +1 -0
- package/dist/chunk-NKPKR5BW.cjs +188 -0
- package/dist/chunk-NKPKR5BW.cjs.map +1 -0
- package/dist/chunk-NWUEVLQT.cjs +99 -0
- package/dist/chunk-NWUEVLQT.cjs.map +1 -0
- package/dist/{chunk-3AJE4SEG.js → chunk-OHC6UHFY.js} +208 -76
- package/dist/chunk-OHC6UHFY.js.map +1 -0
- package/dist/chunk-PHJRNPHY.cjs +3291 -0
- package/dist/chunk-PHJRNPHY.cjs.map +1 -0
- package/dist/{chunk-DXHRBMGB.js → chunk-PQ72Z6WC.js} +67 -112
- package/dist/chunk-PQ72Z6WC.js.map +1 -0
- package/dist/{chunk-K7JPTH3G.cjs → chunk-PV2I2KMI.cjs} +214 -82
- package/dist/chunk-PV2I2KMI.cjs.map +1 -0
- package/dist/{chunk-PDYFVNUX.cjs → chunk-Q23GAMLE.cjs} +71 -116
- package/dist/chunk-Q23GAMLE.cjs.map +1 -0
- package/dist/{chunk-H727JIG7.js → chunk-Q72BOAPK.js} +16 -8
- package/dist/chunk-Q72BOAPK.js.map +1 -0
- package/dist/{chunk-IBG6V56E.cjs → chunk-QFLB4EIJ.cjs} +2 -139
- package/dist/chunk-QFLB4EIJ.cjs.map +1 -0
- package/dist/{chunk-2KVHZE6O.cjs → chunk-RFFSZSCL.cjs} +282 -190
- package/dist/chunk-RFFSZSCL.cjs.map +1 -0
- package/dist/{chunk-V3LKPM3O.cjs → chunk-SHTTJMLT.cjs} +4 -2
- package/dist/chunk-SHTTJMLT.cjs.map +1 -0
- package/dist/{chunk-WOWUL7ZY.js → chunk-UUDTPZX6.js} +5 -4
- package/dist/chunk-UUDTPZX6.js.map +1 -0
- package/dist/{chunk-QPPDLRNR.js → chunk-V7KZQIZ6.js} +277 -185
- package/dist/chunk-V7KZQIZ6.js.map +1 -0
- package/dist/{chunk-3ZFYL34R.js → chunk-WXVB364T.js} +12 -185
- package/dist/chunk-WXVB364T.js.map +1 -0
- package/dist/chunk-XEB7PH2E.js +81 -0
- package/dist/chunk-XEB7PH2E.js.map +1 -0
- package/dist/{chunk-IA6AU5PI.cjs → chunk-Y7AQK4R4.cjs} +94 -10
- package/dist/chunk-Y7AQK4R4.cjs.map +1 -0
- package/dist/chunk-YFAVQQTU.js +92 -0
- package/dist/chunk-YFAVQQTU.js.map +1 -0
- package/dist/cli/index.cjs +6 -6
- package/dist/cli/index.cjs.map +1 -1
- package/dist/cli/index.js +6 -6
- package/dist/cli/index.js.map +1 -1
- package/dist/client.cjs +4 -4
- package/dist/client.d.cts +3 -3
- package/dist/client.d.ts +3 -3
- package/dist/client.js +2 -2
- package/dist/drizzle/index.cjs +15 -14
- package/dist/drizzle/index.d.cts +10 -14
- package/dist/drizzle/index.d.ts +10 -14
- package/dist/drizzle/index.js +6 -5
- package/dist/fields/index.cjs +22 -38
- package/dist/fields/index.d.cts +2 -22
- package/dist/fields/index.d.ts +2 -22
- package/dist/fields/index.js +2 -2
- package/dist/graphql/index.cjs +6 -5
- package/dist/graphql/index.d.cts +5 -3
- package/dist/graphql/index.d.ts +5 -3
- package/dist/graphql/index.js +4 -3
- package/dist/index-BKta3cBH.d.cts +277 -0
- package/dist/index-ClOqnkTO.d.ts +277 -0
- package/dist/index.cjs +310 -168
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +130 -211
- package/dist/index.d.ts +130 -211
- package/dist/index.js +174 -35
- package/dist/index.js.map +1 -1
- package/dist/integration.cjs +3 -3
- package/dist/integration.js +2 -2
- package/dist/media-7WDX4BDJ.js +4 -0
- package/dist/{media-GPPTZ43E.js.map → media-7WDX4BDJ.js.map} +1 -1
- package/dist/{media-XNTUFJZR.cjs → media-TUSLVRQ6.cjs} +3 -3
- package/dist/{media-XNTUFJZR.cjs.map → media-TUSLVRQ6.cjs.map} +1 -1
- package/dist/mongo-auth-adapter-GT4S7SCU.cjs +17 -0
- package/dist/{mongo-auth-adapter-NHHUJHVH.cjs.map → mongo-auth-adapter-GT4S7SCU.cjs.map} +1 -1
- package/dist/mongo-auth-adapter-M7VV4LNB.js +4 -0
- package/dist/{mongo-auth-adapter-NJQUUCTP.js.map → mongo-auth-adapter-M7VV4LNB.js.map} +1 -1
- package/dist/mongodb/index.cjs +9 -8
- package/dist/mongodb/index.d.cts +6 -13
- package/dist/mongodb/index.d.ts +6 -13
- package/dist/mongodb/index.js +5 -4
- package/dist/postgres-auth-adapter-AFAPISH7.js +5 -0
- package/dist/{postgres-auth-adapter-3T2NKTSE.js.map → postgres-auth-adapter-AFAPISH7.js.map} +1 -1
- package/dist/postgres-auth-adapter-SFDTLONT.cjs +14 -0
- package/dist/{postgres-auth-adapter-7IEENCKQ.cjs.map → postgres-auth-adapter-SFDTLONT.cjs.map} +1 -1
- package/dist/redis-adapter-UQX4EE3B.cjs +13 -0
- package/dist/{redis-adapter-D2E2S3GB.cjs.map → redis-adapter-UQX4EE3B.cjs.map} +1 -1
- package/dist/redis-adapter-XALOGWY3.js +4 -0
- package/dist/{redis-adapter-VQXD7ESY.js.map → redis-adapter-XALOGWY3.js.map} +1 -1
- package/dist/rest/index.cjs +16 -15
- package/dist/rest/index.d.cts +4 -4
- package/dist/rest/index.d.ts +4 -4
- package/dist/rest/index.js +14 -13
- package/dist/{schema-37SE2F4B.cjs → schema-6QL3USNB.cjs} +15 -15
- package/dist/{schema-37SE2F4B.cjs.map → schema-6QL3USNB.cjs.map} +1 -1
- package/dist/{schema-5PHL5IVB.js → schema-FNNWEAAW.js} +4 -4
- package/dist/{schema-5PHL5IVB.js.map → schema-FNNWEAAW.js.map} +1 -1
- package/dist/sqlite-adapter-AQB5TCGV.cjs +13 -0
- package/dist/{sqlite-adapter-LVK5PS4T.cjs.map → sqlite-adapter-AQB5TCGV.cjs.map} +1 -1
- package/dist/sqlite-adapter-N5H6IM2X.js +4 -0
- package/dist/{sqlite-adapter-TR3U3W6Q.js.map → sqlite-adapter-N5H6IM2X.js.map} +1 -1
- package/dist/templates/index.cjs +134 -32
- package/dist/templates/index.d.cts +52 -9
- package/dist/templates/index.d.ts +52 -9
- package/dist/templates/index.js +4 -2
- package/dist/trpc/index.cjs +14 -13
- package/dist/trpc/index.d.cts +55 -49
- package/dist/trpc/index.d.ts +55 -49
- package/dist/trpc/index.js +5 -4
- package/dist/{types-D6ZLRGbH.d.cts → types-CpjuXbe7.d.cts} +2 -0
- package/dist/{types-D6ZLRGbH.d.ts → types-CpjuXbe7.d.ts} +2 -0
- package/dist/{types-VtjUxIMp.d.cts → types-DeSApf9T.d.cts} +36 -14
- package/dist/{types-VtjUxIMp.d.ts → types-DeSApf9T.d.ts} +36 -14
- package/dist/{types-J3R9nVsZ.d.cts → types-Dgzlftb7.d.ts} +32 -28
- package/dist/{types-Bs1up4yP.d.ts → types-Ds0tCA3L.d.cts} +32 -28
- package/dist/ws/index.cjs +6 -6
- package/dist/ws/index.js +2 -2
- package/package.json +22 -4
- package/dist/bootstrap-AKAUP6F6.cjs +0 -32
- package/dist/bootstrap-JCML6NFO.js +0 -7
- package/dist/chunk-2KVHZE6O.cjs.map +0 -1
- package/dist/chunk-2OL4O2TH.cjs.map +0 -1
- package/dist/chunk-35U3FROB.js.map +0 -1
- package/dist/chunk-3AJE4SEG.js.map +0 -1
- package/dist/chunk-3J4MFTI3.js +0 -3872
- package/dist/chunk-3J4MFTI3.js.map +0 -1
- package/dist/chunk-3TPQ2BU6.js.map +0 -1
- package/dist/chunk-3ZFYL34R.js.map +0 -1
- package/dist/chunk-4DA7QPLA.cjs.map +0 -1
- package/dist/chunk-57P6MJKC.js.map +0 -1
- package/dist/chunk-5KVM3WEY.cjs.map +0 -1
- package/dist/chunk-6IMPH6WV.cjs +0 -3897
- package/dist/chunk-6IMPH6WV.cjs.map +0 -1
- package/dist/chunk-ATBOUGQP.cjs +0 -513
- package/dist/chunk-ATBOUGQP.cjs.map +0 -1
- package/dist/chunk-DVD5P72E.cjs.map +0 -1
- package/dist/chunk-DXHRBMGB.js.map +0 -1
- package/dist/chunk-ES5HNFFT.js.map +0 -1
- package/dist/chunk-FXYP2HA6.js.map +0 -1
- package/dist/chunk-H727JIG7.js.map +0 -1
- package/dist/chunk-HXRD4B37.js.map +0 -1
- package/dist/chunk-I7HHI6QV.cjs.map +0 -1
- package/dist/chunk-IA6AU5PI.cjs.map +0 -1
- package/dist/chunk-IBG6V56E.cjs.map +0 -1
- package/dist/chunk-K7JPTH3G.cjs.map +0 -1
- package/dist/chunk-LINKCEG4.cjs.map +0 -1
- package/dist/chunk-OHVB4AJ7.js.map +0 -1
- package/dist/chunk-PDYFVNUX.cjs.map +0 -1
- package/dist/chunk-Q23JB3KL.js +0 -488
- package/dist/chunk-Q23JB3KL.js.map +0 -1
- package/dist/chunk-QPPDLRNR.js.map +0 -1
- package/dist/chunk-QUW2RZTM.cjs.map +0 -1
- package/dist/chunk-QXIQWPAP.js.map +0 -1
- package/dist/chunk-R3XIBBAW.cjs +0 -34
- package/dist/chunk-R3XIBBAW.cjs.map +0 -1
- package/dist/chunk-REK7AYOC.js.map +0 -1
- package/dist/chunk-SA7NSSIQ.cjs.map +0 -1
- package/dist/chunk-SDMNUYVU.js +0 -30
- package/dist/chunk-SDMNUYVU.js.map +0 -1
- package/dist/chunk-V3LKPM3O.cjs.map +0 -1
- package/dist/chunk-VJT6P4N6.cjs.map +0 -1
- package/dist/chunk-WOWUL7ZY.js.map +0 -1
- package/dist/chunk-WQBRWOQT.cjs.map +0 -1
- package/dist/chunk-Y3N7UUDO.js.map +0 -1
- package/dist/chunk-Y3QQN7PN.js.map +0 -1
- package/dist/chunk-YVUJBEXE.cjs.map +0 -1
- package/dist/index-CLp-DRKA.d.ts +0 -64
- package/dist/index-DfO7G4kN.d.cts +0 -64
- package/dist/media-GPPTZ43E.js +0 -4
- package/dist/mongo-auth-adapter-NHHUJHVH.cjs +0 -17
- package/dist/mongo-auth-adapter-NJQUUCTP.js +0 -4
- package/dist/postgres-auth-adapter-3T2NKTSE.js +0 -5
- package/dist/postgres-auth-adapter-7IEENCKQ.cjs +0 -14
- package/dist/redis-adapter-D2E2S3GB.cjs +0 -13
- package/dist/redis-adapter-VQXD7ESY.js +0 -4
- package/dist/sqlite-adapter-LVK5PS4T.cjs +0 -13
- package/dist/sqlite-adapter-TR3U3W6Q.js +0 -4
package/dist/index.js
CHANGED
|
@@ -1,34 +1,37 @@
|
|
|
1
|
-
export { RedisAuthAdapter } from './chunk-
|
|
2
|
-
export { allSettingsGlobals, blogCollections, blogGlobals, coreSettingsGlobals, createTemplateConfig, ecommerceCollections, ecommerceGlobals, kitchenSinkCollections, mediaCollections, minimalCollections } from './chunk-
|
|
3
|
-
export { kyro } from './chunk-
|
|
4
|
-
export { ConfigValidationError, Kyro, LocalAdapter, Registry, collectionToCreateZod, collectionToUpdateZod, collectionToWhereZod, collectionToZod, createKyro, createLocalAdapter, createRegistry, fieldToZod, getRegistry, globalToZod, resetRegistry, validateCollection, validateConfig, validateFields, validateGlobal } from './chunk-
|
|
5
|
-
export { autoBootstrap, bootstrapAdmin, bootstrapWithRetry, getBootstrapFromEnv } from './chunk-
|
|
1
|
+
export { RedisAuthAdapter } from './chunk-CF7OL6HR.js';
|
|
2
|
+
export { allSettingsGlobals, blogCollections, blogGlobals, coreSettingsGlobals, createTemplateConfig, ecommerceCollections, ecommerceGlobals, kitchenSinkCollections, mediaCollections, minimalCollections, templateCollections } from './chunk-53NYVYVX.js';
|
|
3
|
+
export { kyro } from './chunk-4AO3A3JM.js';
|
|
4
|
+
export { ConfigValidationError, Kyro, LocalAdapter, Registry, collectionToCreateZod, collectionToUpdateZod, collectionToWhereZod, collectionToZod, createKyro, createLocalAdapter, createRegistry, fieldToZod, getRegistry, globalToZod, resetRegistry, validateCollection, validateConfig, validateFields, validateGlobal } from './chunk-5H3MWQJS.js';
|
|
5
|
+
export { autoBootstrap, bootstrapAdmin, bootstrapWithRetry, getBootstrapFromEnv } from './chunk-GAAHG2Z4.js';
|
|
6
|
+
import './chunk-GAOXD3XT.js';
|
|
6
7
|
export { CSSGenerator, createAdminStyling, defaultDarkTheme, defaultFieldStyling, defaultLightTheme, ecommerce2026Theme, generateCSSVariables, generateTailwindConfig } from './chunk-2HFJUUFZ.js';
|
|
7
|
-
export { ALL_FIELD_TYPES, COMPLEX_FIELD_TYPES, LAYOUT_FIELD_TYPES, PRIMITIVE_FIELD_TYPES, RELATIONAL_FIELD_TYPES,
|
|
8
|
-
export { createContext, createCountProcedure, createCreateProcedure, createDeleteProcedure, createDynamicRouter, createFindByIDProcedure, createFindProcedure, createKyroServer, createUpdateProcedure } from './chunk-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
8
|
+
export { ALL_FIELD_TYPES, COMPLEX_FIELD_TYPES, LAYOUT_FIELD_TYPES, PRIMITIVE_FIELD_TYPES, RELATIONAL_FIELD_TYPES, isArrayField, isBlocksField, isGroupField, isImageField, isLayoutField, isNumberField, isRelationshipField, isRichTextField, isSelectField, isTextField, isUploadField, normalizeRichTextValue, renderRichText, richTextStyles } from './chunk-E5UJBLQ7.js';
|
|
9
|
+
export { createContext, createCountProcedure, createCreateProcedure, createDeleteProcedure, createDynamicRouter, createFindByIDProcedure, createFindProcedure, createKyroServer, createUpdateProcedure } from './chunk-OHC6UHFY.js';
|
|
10
|
+
export { buildGraphQLSchema, createGraphQLSchema } from './chunk-L5UKKZQN.js';
|
|
11
|
+
import { init_secret, AuditLogger, InMemoryRateLimiter, InMemoryAuditLogger, AuthRoutes } from './chunk-IPTZM3VE.js';
|
|
12
|
+
export { AuditLogger, InMemoryAuditLogger, InMemoryRateLimiter, MediaService, createAuditContext, createHonoApp, createLocalStorage, createRESTAPI, getAppSecret, getEncryptionKey, getSessionConfig, loadSecrets, resolveProvider, setDbAdapter } from './chunk-IPTZM3VE.js';
|
|
13
|
+
import { EmailTransport, PasswordPolicy } from './chunk-6UNONDW7.js';
|
|
14
|
+
export { ConfigService, EmailTransport, PasswordPolicy } from './chunk-6UNONDW7.js';
|
|
13
15
|
import './chunk-YT7HXXVN.js';
|
|
14
|
-
import
|
|
15
|
-
|
|
16
|
+
import './chunk-XEB7PH2E.js';
|
|
17
|
+
import { SQLiteAuthAdapter } from './chunk-Q72BOAPK.js';
|
|
18
|
+
export { SQLiteAuthAdapter } from './chunk-Q72BOAPK.js';
|
|
16
19
|
import './chunk-P2YW545G.js';
|
|
17
|
-
export { ALL_WEBHOOK_EVENTS, WEBHOOK_COLLECTION, WEBHOOK_DELIVERY_COLLECTION, WEBHOOK_EVENTS, WebhookService, buildDeliveryRecord, createTestPayload, createWebhookService, deliverWebhook, deliverWithRetry, generateWebhookSecret, signPayload } from './chunk-
|
|
18
|
-
export {
|
|
19
|
-
export {
|
|
20
|
-
export { KyroPubSub, KyroWSServer, PubSub, createWSServer } from './chunk-3TPQ2BU6.js';
|
|
20
|
+
export { ALL_WEBHOOK_EVENTS, WEBHOOK_COLLECTION, WEBHOOK_DELIVERY_COLLECTION, WEBHOOK_EVENTS, WebhookService, buildDeliveryRecord, createTestPayload, createWebhookService, deliverWebhook, deliverWithRetry, generateWebhookSecret, signPayload } from './chunk-3UK5XBVJ.js';
|
|
21
|
+
export { evaluateAccess, getWhereClause, mergeWhereClauses } from './chunk-CJONKRHJ.js';
|
|
22
|
+
export { KyroPubSub, KyroWSServer, PubSub, createWSServer } from './chunk-BYBMTIMT.js';
|
|
21
23
|
import './chunk-QU2RFFH4.js';
|
|
22
|
-
export { DrizzleAdapter, collectionToDrizzleSchema, createDatabase, createDrizzleAdapter, fieldToDrizzleType, runMigrations, seedDefaultRoles } from './chunk-
|
|
23
|
-
import { PostgresAuthAdapter } from './chunk-
|
|
24
|
-
export { PostgresAuthAdapter } from './chunk-
|
|
25
|
-
import './chunk-
|
|
24
|
+
export { DrizzleAdapter, collectionToDrizzleSchema, createDatabase, createDrizzleAdapter, fieldToDrizzleType, runMigrations, seedDefaultRoles } from './chunk-V7KZQIZ6.js';
|
|
25
|
+
import { PostgresAuthAdapter } from './chunk-CJX74IYK.js';
|
|
26
|
+
export { PostgresAuthAdapter } from './chunk-CJX74IYK.js';
|
|
27
|
+
import './chunk-UUDTPZX6.js';
|
|
26
28
|
import './chunk-GTGRLD4Y.js';
|
|
27
|
-
export { MongoDBAdapter, createMongoDBAdapter } from './chunk-
|
|
28
|
-
import { MongoDBAuthAdapter } from './chunk-
|
|
29
|
-
export { MongoDBAuthAdapter } from './chunk-
|
|
30
|
-
export { AbstractBaseAdapter } from './chunk-
|
|
31
|
-
import './chunk-
|
|
29
|
+
export { MongoDBAdapter, createMongoDBAdapter } from './chunk-PQ72Z6WC.js';
|
|
30
|
+
import { MongoDBAuthAdapter } from './chunk-7OGPN7MP.js';
|
|
31
|
+
export { MongoDBAuthAdapter } from './chunk-7OGPN7MP.js';
|
|
32
|
+
export { AbstractBaseAdapter } from './chunk-WXVB364T.js';
|
|
33
|
+
import './chunk-L4EZKIEX.js';
|
|
34
|
+
import './chunk-4CV4JOE5.js';
|
|
32
35
|
import crypto2, { randomBytes } from 'crypto';
|
|
33
36
|
import { readFileSync } from 'fs';
|
|
34
37
|
import path, { join, resolve } from 'path';
|
|
@@ -1083,11 +1086,11 @@ async function createAuthAdapter(databaseType) {
|
|
|
1083
1086
|
return new InMemoryAuthAdapter();
|
|
1084
1087
|
}
|
|
1085
1088
|
}
|
|
1086
|
-
async function createAuthConfig(databaseType) {
|
|
1089
|
+
async function createAuthConfig(databaseType, db) {
|
|
1087
1090
|
const distributed = getEnvBool("KYRO_DISTRIBUTED", false);
|
|
1088
1091
|
let authAdapter;
|
|
1089
1092
|
if (distributed) {
|
|
1090
|
-
const { RedisAuthAdapter: RedisAuthAdapter2 } = await import('./redis-adapter-
|
|
1093
|
+
const { RedisAuthAdapter: RedisAuthAdapter2 } = await import('./redis-adapter-XALOGWY3.js');
|
|
1091
1094
|
const redisUrl = getEnv("REDIS_URL", "redis://localhost:6379");
|
|
1092
1095
|
const redisTls = getEnvBool("REDIS_TLS", false);
|
|
1093
1096
|
const redisAdapter = new RedisAuthAdapter2({ url: redisUrl, tls: redisTls });
|
|
@@ -1100,7 +1103,7 @@ async function createAuthConfig(databaseType) {
|
|
|
1100
1103
|
await authAdapter.connect();
|
|
1101
1104
|
}
|
|
1102
1105
|
}
|
|
1103
|
-
const email = EmailTransport.fromEnv() || void 0;
|
|
1106
|
+
const email = db ? await EmailTransport.fromConfig(db).catch(() => null) || EmailTransport.fromEnv() || void 0 : EmailTransport.fromEnv() || void 0;
|
|
1104
1107
|
const passwordPolicy = new PasswordPolicy({
|
|
1105
1108
|
minLength: getEnvNum("PASSWORD_MIN_LENGTH", 12),
|
|
1106
1109
|
requireUppercase: getEnvBool("PASSWORD_REQUIRE_UPPERCASE", true),
|
|
@@ -1575,14 +1578,19 @@ function defineConfig(config) {
|
|
|
1575
1578
|
debug: config.debug
|
|
1576
1579
|
};
|
|
1577
1580
|
}
|
|
1581
|
+
var defineKyroConfig = defineConfig;
|
|
1578
1582
|
|
|
1579
1583
|
// src/lib/seo.ts
|
|
1580
1584
|
function generateSeoTags(options) {
|
|
1581
|
-
const { siteSettings, title, description, image, url } = options;
|
|
1585
|
+
const { siteSettings, seoSettings, title, description, image, url } = options;
|
|
1582
1586
|
if (!siteSettings) return "";
|
|
1583
1587
|
const siteName = siteSettings.siteName || "";
|
|
1584
|
-
const
|
|
1585
|
-
const
|
|
1588
|
+
const rawTitle = title || seoSettings?.defaultTitle || siteName;
|
|
1589
|
+
const titleTemplate = seoSettings?.titleTemplate;
|
|
1590
|
+
const separator = seoSettings?.separator || " | ";
|
|
1591
|
+
const siteNameInTitle = seoSettings?.siteNameInTitle !== false;
|
|
1592
|
+
const finalTitle = titleTemplate ? titleTemplate.replace(/\{\{title\}\}/g, rawTitle).replace(/\{\{siteName\}\}/g, siteNameInTitle ? siteName : "").replace(/\{\{separator\}\}/g, separator).replace(/\s+/g, " ").trim() : rawTitle;
|
|
1593
|
+
const finalDesc = description || seoSettings?.defaultDescription || siteSettings.siteDescription || "";
|
|
1586
1594
|
const finalImage = image || siteSettings.siteOgImage?.url || "";
|
|
1587
1595
|
const finalUrl = url || siteSettings.siteUrl || "";
|
|
1588
1596
|
let tags = `
|
|
@@ -1593,8 +1601,19 @@ function generateSeoTags(options) {
|
|
|
1593
1601
|
tags += `
|
|
1594
1602
|
<link rel="icon" type="${siteSettings.siteFavicon.mimeType || "image/x-icon"}" href="${siteSettings.siteFavicon.url}">`;
|
|
1595
1603
|
}
|
|
1604
|
+
const robots = seoSettings?.meta?.robots;
|
|
1605
|
+
if (robots) {
|
|
1606
|
+
tags += `
|
|
1607
|
+
<meta name="robots" content="${robots}">`;
|
|
1608
|
+
}
|
|
1609
|
+
const canonical = seoSettings?.meta?.canonicalUrl || finalUrl;
|
|
1610
|
+
if (canonical) {
|
|
1611
|
+
tags += `
|
|
1612
|
+
<link rel="canonical" href="${canonical}">`;
|
|
1613
|
+
}
|
|
1614
|
+
const ogType = seoSettings?.meta?.ogType || "website";
|
|
1596
1615
|
tags += `
|
|
1597
|
-
<meta property="og:type" content="
|
|
1616
|
+
<meta property="og:type" content="${ogType}">
|
|
1598
1617
|
<meta property="og:title" content="${finalTitle}">
|
|
1599
1618
|
<meta property="og:description" content="${finalDesc}">
|
|
1600
1619
|
<meta property="og:site_name" content="${siteName}">
|
|
@@ -1603,11 +1622,20 @@ function generateSeoTags(options) {
|
|
|
1603
1622
|
<meta property="og:url" content="${finalUrl}">`;
|
|
1604
1623
|
if (finalImage) tags += `
|
|
1605
1624
|
<meta property="og:image" content="${finalImage}">`;
|
|
1625
|
+
if (seoSettings?.social?.fbAppId) {
|
|
1626
|
+
tags += `
|
|
1627
|
+
<meta property="fb:app_id" content="${seoSettings.social.fbAppId}">`;
|
|
1628
|
+
}
|
|
1629
|
+
const twitterCard = seoSettings?.social?.twitterCardType || "summary_large_image";
|
|
1606
1630
|
tags += `
|
|
1607
|
-
<meta name="twitter:card" content="
|
|
1631
|
+
<meta name="twitter:card" content="${twitterCard}">
|
|
1608
1632
|
<meta name="twitter:title" content="${finalTitle}">
|
|
1609
1633
|
<meta name="twitter:description" content="${finalDesc}">
|
|
1610
1634
|
`;
|
|
1635
|
+
if (seoSettings?.social?.twitterHandle) {
|
|
1636
|
+
tags += `
|
|
1637
|
+
<meta name="twitter:site" content="${seoSettings.social.twitterHandle}">`;
|
|
1638
|
+
}
|
|
1611
1639
|
if (finalImage) tags += `
|
|
1612
1640
|
<meta name="twitter:image" content="${finalImage}">`;
|
|
1613
1641
|
if (siteSettings.enableI18n && siteSettings.i18n?.language) {
|
|
@@ -1654,6 +1682,117 @@ function generateAnalyticsTags(siteSettings) {
|
|
|
1654
1682
|
}
|
|
1655
1683
|
return scripts;
|
|
1656
1684
|
}
|
|
1685
|
+
|
|
1686
|
+
// src/lib/social.ts
|
|
1687
|
+
var PLATFORM_META = {
|
|
1688
|
+
facebook: { label: "Facebook" },
|
|
1689
|
+
twitter: { label: "Twitter / X" },
|
|
1690
|
+
instagram: { label: "Instagram" },
|
|
1691
|
+
linkedin: { label: "LinkedIn" },
|
|
1692
|
+
youtube: { label: "YouTube" },
|
|
1693
|
+
tiktok: { label: "TikTok" },
|
|
1694
|
+
pinterest: { label: "Pinterest" },
|
|
1695
|
+
discord: { label: "Discord" },
|
|
1696
|
+
twitch: { label: "Twitch" },
|
|
1697
|
+
github: { label: "GitHub" },
|
|
1698
|
+
mastodon: { label: "Mastodon" }
|
|
1699
|
+
};
|
|
1700
|
+
var ALL_PLATFORMS = [
|
|
1701
|
+
"facebook",
|
|
1702
|
+
"twitter",
|
|
1703
|
+
"instagram",
|
|
1704
|
+
"linkedin",
|
|
1705
|
+
"youtube",
|
|
1706
|
+
"tiktok",
|
|
1707
|
+
"pinterest",
|
|
1708
|
+
"discord",
|
|
1709
|
+
"twitch",
|
|
1710
|
+
"github",
|
|
1711
|
+
"mastodon"
|
|
1712
|
+
];
|
|
1713
|
+
function getSocialLinksFromSettings(socialSettings) {
|
|
1714
|
+
if (!socialSettings) return [];
|
|
1715
|
+
const showAll = socialSettings.showAll === true;
|
|
1716
|
+
const links = [];
|
|
1717
|
+
for (const platform of ALL_PLATFORMS) {
|
|
1718
|
+
const url = socialSettings[platform];
|
|
1719
|
+
if (!url) continue;
|
|
1720
|
+
const isNiche = ["tiktok", "pinterest", "discord", "twitch", "github", "mastodon"].includes(platform);
|
|
1721
|
+
if (isNiche && !showAll) continue;
|
|
1722
|
+
const meta = PLATFORM_META[platform];
|
|
1723
|
+
links.push({
|
|
1724
|
+
platform,
|
|
1725
|
+
url,
|
|
1726
|
+
label: meta?.label || platform
|
|
1727
|
+
});
|
|
1728
|
+
}
|
|
1729
|
+
return links;
|
|
1730
|
+
}
|
|
1731
|
+
async function getSocialLinks(db, options) {
|
|
1732
|
+
try {
|
|
1733
|
+
const doc = await db.findOne({
|
|
1734
|
+
collection: "_globals_social-settings",
|
|
1735
|
+
where: {},
|
|
1736
|
+
draft: options?.draft ?? false
|
|
1737
|
+
});
|
|
1738
|
+
return getSocialLinksFromSettings(doc);
|
|
1739
|
+
} catch {
|
|
1740
|
+
return [];
|
|
1741
|
+
}
|
|
1742
|
+
}
|
|
1743
|
+
|
|
1744
|
+
// src/lib/store.ts
|
|
1745
|
+
function getStoreConfigFromSettings(settings) {
|
|
1746
|
+
if (!settings) return {};
|
|
1747
|
+
return {
|
|
1748
|
+
storeName: settings.storeName,
|
|
1749
|
+
storeEmail: settings.storeEmail,
|
|
1750
|
+
storePhone: settings.storePhone,
|
|
1751
|
+
address: settings.address,
|
|
1752
|
+
currency: settings.currency,
|
|
1753
|
+
tax: settings.tax,
|
|
1754
|
+
shipping: settings.shipping,
|
|
1755
|
+
orders: settings.orders
|
|
1756
|
+
};
|
|
1757
|
+
}
|
|
1758
|
+
async function getStoreConfig(db, options) {
|
|
1759
|
+
try {
|
|
1760
|
+
const doc = await db.findOne({
|
|
1761
|
+
collection: "_globals_store-settings",
|
|
1762
|
+
where: {},
|
|
1763
|
+
draft: options?.draft ?? false
|
|
1764
|
+
});
|
|
1765
|
+
return getStoreConfigFromSettings(doc);
|
|
1766
|
+
} catch {
|
|
1767
|
+
return {};
|
|
1768
|
+
}
|
|
1769
|
+
}
|
|
1770
|
+
|
|
1771
|
+
// src/lib/payment.ts
|
|
1772
|
+
function getPaymentConfigFromSettings(settings) {
|
|
1773
|
+
if (!settings) return {};
|
|
1774
|
+
return {
|
|
1775
|
+
testMode: settings.testMode,
|
|
1776
|
+
provider: settings.provider,
|
|
1777
|
+
stripe: settings.stripe,
|
|
1778
|
+
paypal: settings.paypal,
|
|
1779
|
+
square: settings.square,
|
|
1780
|
+
methods: settings.methods,
|
|
1781
|
+
bankTransfer: settings.bankTransfer
|
|
1782
|
+
};
|
|
1783
|
+
}
|
|
1784
|
+
async function getPaymentConfig(db, options) {
|
|
1785
|
+
try {
|
|
1786
|
+
const doc = await db.findOne({
|
|
1787
|
+
collection: "_globals_payment-settings",
|
|
1788
|
+
where: {},
|
|
1789
|
+
draft: options?.draft ?? false
|
|
1790
|
+
});
|
|
1791
|
+
return getPaymentConfigFromSettings(doc);
|
|
1792
|
+
} catch {
|
|
1793
|
+
return {};
|
|
1794
|
+
}
|
|
1795
|
+
}
|
|
1657
1796
|
async function createBrowserStorage(options = {}) {
|
|
1658
1797
|
const { namespace = "kyro", ttl } = options;
|
|
1659
1798
|
const store = createStorage({
|
|
@@ -1801,6 +1940,6 @@ async function createAuthStorage(config) {
|
|
|
1801
1940
|
// src/index.ts
|
|
1802
1941
|
init_secret();
|
|
1803
1942
|
|
|
1804
|
-
export { AccountLockout, AnalyticsPlugin, Auth, CommentsPlugin, InMemoryAccountLockout, InMemoryAuthAdapter, KyroPlugin, PluginManager, RateLimiter, ReviewsPlugin, SEOPLugin, VersionManager, WishlistPlugin, authConfig, createAuth, createAuthConfig, createAuthStorage, createStorage3 as createStorage, createVersionManager, defineConfig, generateAnalyticsTags, generateSeoTags, getDefaultDraftPublishConfig, isArchived, isDraft, isPublished, presetPlugins, runFieldHooks, runHooks };
|
|
1943
|
+
export { AccountLockout, AnalyticsPlugin, Auth, CommentsPlugin, InMemoryAccountLockout, InMemoryAuthAdapter, KyroPlugin, PluginManager, RateLimiter, ReviewsPlugin, SEOPLugin, VersionManager, WishlistPlugin, authConfig, createAuth, createAuthConfig, createAuthStorage, createStorage3 as createStorage, createVersionManager, defineConfig, defineKyroConfig, generateAnalyticsTags, generateSeoTags, getDefaultDraftPublishConfig, getPaymentConfig, getPaymentConfigFromSettings, getSocialLinks, getSocialLinksFromSettings, getStoreConfig, getStoreConfigFromSettings, isArchived, isDraft, isPublished, presetPlugins, runFieldHooks, runHooks };
|
|
1805
1944
|
//# sourceMappingURL=index.js.map
|
|
1806
1945
|
//# sourceMappingURL=index.js.map
|