@kyro-cms/core 0.13.3 → 0.13.6
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/dist/{WebhookService-BOJMgjBm.d.cts → WebhookService-BJTCP3cU.d.cts} +1 -1
- package/dist/{WebhookService-BLi5Rz2m.d.ts → WebhookService-Bqr_66lK.d.ts} +1 -1
- package/dist/api-handler-graphql.cjs +1 -1
- package/dist/api-handler-graphql.js +2 -2
- package/dist/api-handler-trpc.cjs +1 -1
- package/dist/api-handler-trpc.js +2 -2
- package/dist/api-handler.cjs +1 -1
- package/dist/api-handler.js +1 -1
- package/dist/auth-session-4WJUKESW.js +1 -0
- package/dist/auth-session-VHUHDBCL.cjs +1 -0
- package/dist/{base-A9AJPCG5.d.ts → base-C2DOe8wD.d.ts} +2 -2
- package/dist/{base-C6wyX2nC.d.cts → base-DIpT2Vuz.d.cts} +2 -2
- package/dist/bootstrap-JYAUQ52D.cjs +1 -0
- package/dist/bootstrap-TTMLNQM3.js +1 -0
- package/dist/chunk-23RSKVJP.cjs +1 -0
- package/dist/chunk-24W5I6SJ.cjs +2 -0
- package/dist/{chunk-CH4TZZI5.js → chunk-2I2AXTKY.cjs} +38 -39
- package/dist/chunk-34LCWI5X.cjs +1 -0
- package/dist/chunk-3A5UO6OQ.cjs +114 -0
- package/dist/chunk-3N34WXBS.js +2 -0
- package/dist/chunk-5BUAWCU6.js +91 -0
- package/dist/{chunk-7NKNSRCB.cjs → chunk-5I3BM5TV.js} +33 -32
- package/dist/chunk-5RBGM5N5.js +3 -0
- package/dist/chunk-7EY3GXRA.js +2 -0
- package/dist/chunk-7KTPBTH5.cjs +1 -0
- package/dist/chunk-A4XM33WO.js +109 -0
- package/dist/chunk-A7763NCF.cjs +19 -0
- package/dist/chunk-AQWTJGML.cjs +1 -0
- package/dist/chunk-CIWLQXB2.js +2 -0
- package/dist/chunk-DCFOVCJX.cjs +1 -0
- package/dist/chunk-DCKJT247.cjs +1 -0
- package/dist/chunk-EG4SRTYS.cjs +2 -0
- package/dist/chunk-FAG2645P.js +2 -0
- package/dist/chunk-FIVTKI25.cjs +3 -0
- package/dist/chunk-FU76HURF.cjs +1 -0
- package/dist/chunk-GDLMPZKD.cjs +2 -0
- package/dist/chunk-GS4CMYKS.cjs +1 -0
- package/dist/chunk-GTAKGVUY.js +2 -0
- package/dist/chunk-GWUHIIPO.cjs +132 -0
- package/dist/chunk-H2IJDTA2.cjs +1 -0
- package/dist/chunk-HACW42ZZ.cjs +108 -0
- package/dist/chunk-HCM2G674.cjs +20 -0
- package/dist/chunk-I22MSXGL.js +2 -0
- package/dist/chunk-IIPSXKNV.js +115 -0
- package/dist/{chunk-WNU76M2C.js → chunk-IIVBEZC2.js} +6 -6
- package/dist/chunk-JHFD3IAU.cjs +1 -0
- package/dist/chunk-JJY2F6NL.cjs +3 -0
- package/dist/chunk-JQ4V2MGJ.cjs +2 -0
- package/dist/chunk-JXJTFBHG.js +3 -0
- package/dist/chunk-KOSR7235.cjs +1 -0
- package/dist/chunk-KUY4QDAL.js +2 -0
- package/dist/chunk-LGUHXOEW.js +3 -0
- package/dist/chunk-LXTVMP5F.cjs +6 -0
- package/dist/chunk-N25DOGLQ.js +5 -0
- package/dist/chunk-N2BMGZIX.cjs +90 -0
- package/dist/chunk-N7CDHWQH.cjs +2 -0
- package/dist/chunk-NBBAMC2X.cjs +1 -0
- package/dist/chunk-NGNXOXI5.js +2 -0
- package/dist/chunk-O4PPZOVI.cjs +1 -0
- package/dist/chunk-O4RKZQYQ.js +2 -0
- package/dist/chunk-OJBL4CXK.cjs +2 -0
- package/dist/chunk-OPKZYQV7.js +3 -0
- package/dist/chunk-OXEJCIOA.cjs +1 -0
- package/dist/chunk-OXH6CANN.js +2 -0
- package/dist/{chunk-EQN3HDES.cjs → chunk-PW6Y5MQL.cjs} +5 -5
- package/dist/chunk-RLW6AQF2.js +2 -0
- package/dist/chunk-SBFVITY2.js +7 -0
- package/dist/chunk-SEJ7LMYY.js +4 -0
- package/dist/chunk-SZY25KAE.js +21 -0
- package/dist/chunk-TG5YQ4PB.cjs +4 -0
- package/dist/chunk-TJ6N5ZPZ.js +133 -0
- package/dist/chunk-V2RMDMWN.js +2 -0
- package/dist/chunk-V4SR7DU5.js +3 -0
- package/dist/chunk-VLFM66BZ.js +4 -0
- package/dist/chunk-VPBGZW4P.cjs +1 -0
- package/dist/chunk-VQWOCGJ2.cjs +1 -0
- package/dist/chunk-VWXHW74B.js +3 -0
- package/dist/chunk-W5GDZG64.js +2 -0
- package/dist/chunk-WLSVS3NC.js +2 -0
- package/dist/chunk-YLP3EKTQ.js +2 -0
- package/dist/chunk-YNSKDTFG.js +2 -0
- package/dist/chunk-YOJOVQIH.cjs +1 -0
- package/dist/chunk-ZE2X3FBU.js +20 -0
- package/dist/chunk-ZMH35QYG.js +2 -0
- package/dist/cli/index.cjs +53 -182
- package/dist/cli/index.js +54 -183
- package/dist/drizzle/index.cjs +1 -1
- package/dist/drizzle/index.d.cts +3 -3
- package/dist/drizzle/index.d.ts +3 -3
- package/dist/drizzle/index.js +1 -1
- package/dist/fields/index.cjs +1 -1
- package/dist/fields/index.d.cts +2 -2
- package/dist/fields/index.d.ts +2 -2
- package/dist/fields/index.js +1 -1
- package/dist/graphql/index.cjs +1 -1
- package/dist/graphql/index.d.cts +3 -3
- package/dist/graphql/index.d.ts +3 -3
- package/dist/graphql/index.js +1 -1
- package/dist/{index-BttsFZDa.d.ts → index-C9uBoJtm.d.ts} +2 -2
- package/dist/{index-BMcYFpTv.d.cts → index-Ci7aUrmN.d.cts} +2 -2
- package/dist/index.cjs +30 -30
- package/dist/index.d.cts +10 -10
- package/dist/index.d.ts +10 -10
- package/dist/index.js +31 -31
- package/dist/integration.cjs +1 -1
- package/dist/integration.js +1 -1
- package/dist/local-DKP43BWQ.cjs +1 -0
- package/dist/local-TF5ZMHWW.js +1 -0
- package/dist/media-M3EIZ4QS.cjs +1 -0
- package/dist/media-WYEILC6K.js +1 -0
- package/dist/mongo-auth-adapter-33M5ENM7.cjs +1 -0
- package/dist/mongo-auth-adapter-4ITULS2P.js +1 -0
- package/dist/mongodb/index.cjs +1 -1
- package/dist/mongodb/index.d.cts +3 -3
- package/dist/mongodb/index.d.ts +3 -3
- package/dist/mongodb/index.js +1 -1
- package/dist/nodemailer-transport-7F3VLLBW.js +1 -0
- package/dist/nodemailer-transport-WAPZD3SJ.cjs +1 -0
- package/dist/postgres-auth-adapter-7BCPXNBO.js +1 -0
- package/dist/postgres-auth-adapter-HMXFUM5W.cjs +1 -0
- package/dist/redis-adapter-2E5AWMMA.cjs +1 -0
- package/dist/redis-adapter-GFH74CF4.js +1 -0
- package/dist/rest/index.cjs +1 -1
- package/dist/rest/index.d.cts +4 -4
- package/dist/rest/index.d.ts +4 -4
- package/dist/rest/index.js +1 -1
- package/dist/schema-FNIDQKIJ.cjs +1 -0
- package/dist/schema-KD736QFN.js +1 -0
- package/dist/sqlite-adapter-HL53RLSN.cjs +1 -0
- package/dist/sqlite-adapter-TT6ZASDG.js +1 -0
- package/dist/templates/index.cjs +1 -1
- package/dist/templates/index.d.cts +2 -2
- package/dist/templates/index.d.ts +2 -2
- package/dist/templates/index.js +1 -1
- package/dist/trpc/index.cjs +1 -1
- package/dist/trpc/index.d.cts +3 -3
- package/dist/trpc/index.d.ts +3 -3
- package/dist/trpc/index.js +1 -1
- package/dist/{types-DxaK39ix.d.cts → types-C3QFX0l6.d.cts} +4 -0
- package/dist/{types-DxaK39ix.d.ts → types-C3QFX0l6.d.ts} +4 -0
- package/dist/{types-6ShQp2EM.d.cts → types-CKWnrUAh.d.ts} +23 -2
- package/dist/{types-BCOhfwHC.d.ts → types-CdwfDpyW.d.cts} +23 -2
- package/dist/ws/index.cjs +1 -1
- package/dist/ws/index.js +1 -1
- package/package.json +3 -11
- package/dist/WebhookService-BcuD8tnn.d.cts +0 -143
- package/dist/WebhookService-CFe6Zd0_.d.cts +0 -143
- package/dist/WebhookService-CGxHtw7E.d.cts +0 -143
- package/dist/WebhookService-CNC1lYz7.d.ts +0 -143
- package/dist/WebhookService-CVXmjbtQ.d.cts +0 -143
- package/dist/WebhookService-D5PSI5t6.d.cts +0 -143
- package/dist/WebhookService-DPCCn_12.d.ts +0 -143
- package/dist/WebhookService-Dk1lzSrG.d.cts +0 -143
- package/dist/WebhookService-Dncnbgm9.d.cts +0 -143
- package/dist/WebhookService-I6hdue2Y.d.ts +0 -143
- package/dist/WebhookService-KnQ2UDlW.d.ts +0 -143
- package/dist/WebhookService-UY5p89Bj.d.ts +0 -143
- package/dist/WebhookService-YZXBCRXA.d.ts +0 -143
- package/dist/WebhookService-fk0FGRlk.d.ts +0 -143
- package/dist/WebhookService-vsFnWrOh.d.ts +0 -143
- package/dist/WebhookService-zrDmAx7L.d.cts +0 -143
- package/dist/auth-session-DHVGXHOH.cjs +0 -1
- package/dist/auth-session-O7IIH7EP.js +0 -1
- package/dist/base-B--L0lCn.d.cts +0 -218
- package/dist/base-B-i-tjm1.d.ts +0 -218
- package/dist/base-B-siit_y.d.cts +0 -218
- package/dist/base-B8SyZI4D.d.ts +0 -218
- package/dist/base-BCgFt3Yx.d.ts +0 -218
- package/dist/base-BHRGJ40F.d.cts +0 -218
- package/dist/base-BVoDPNjJ.d.cts +0 -218
- package/dist/base-BaOJ5uWd.d.cts +0 -218
- package/dist/base-BfPaVEAE.d.cts +0 -218
- package/dist/base-BxrX5EPU.d.cts +0 -218
- package/dist/base-CAb9EYQs.d.ts +0 -218
- package/dist/base-CcZIEll-.d.ts +0 -218
- package/dist/base-CyG7aF1e.d.cts +0 -218
- package/dist/base-DOImeJ-F.d.ts +0 -218
- package/dist/base-DbnwE42-.d.cts +0 -218
- package/dist/base-NyiSsD-n.d.ts +0 -218
- package/dist/base-OYfoYPYP.d.ts +0 -218
- package/dist/base-xflndGDO.d.ts +0 -218
- package/dist/bcryptjs-WIQSWJGK.cjs +0 -1
- package/dist/bcryptjs-ZEEHSMAG.js +0 -2
- package/dist/better-sqlite3-5IISPX34.cjs +0 -1
- package/dist/better-sqlite3-B34RIU4C.js +0 -2
- package/dist/bootstrap-E24SGUJP.cjs +0 -1
- package/dist/bootstrap-PG2LGDLB.js +0 -1
- package/dist/bootstrap-QQ6D3OYG.js +0 -1
- package/dist/bootstrap-QVKSKXJF.cjs +0 -1
- package/dist/bootstrap-RILR44UM.cjs +0 -1
- package/dist/bootstrap-YD3GLTWX.cjs +0 -1
- package/dist/bootstrap-YFVE7MRG.js +0 -1
- package/dist/bootstrap-ZRRUPRUR.js +0 -1
- package/dist/bowser-SB3ZUPO4.js +0 -11
- package/dist/bowser-VX6B6ZSE.cjs +0 -10
- package/dist/chokidar-5RVQZVHP.cjs +0 -5
- package/dist/chokidar-BOYGRT4Q.js +0 -6
- package/dist/chunk-22RXJ442.js +0 -57
- package/dist/chunk-262YP5XA.cjs +0 -1
- package/dist/chunk-2FSOHXOU.cjs +0 -56
- package/dist/chunk-2HA6EKXX.js +0 -24
- package/dist/chunk-2OS5Y4LE.cjs +0 -1
- package/dist/chunk-2PXXQKN3.cjs +0 -3
- package/dist/chunk-2SPWRQ5O.js +0 -122
- package/dist/chunk-32QY56XF.js +0 -122
- package/dist/chunk-355R4LS5.cjs +0 -56
- package/dist/chunk-35IVNLMA.js +0 -122
- package/dist/chunk-35PGCW3S.cjs +0 -1
- package/dist/chunk-3GXLOYM3.js +0 -2
- package/dist/chunk-3KZXF4US.js +0 -2
- package/dist/chunk-3LAWUINR.cjs +0 -1
- package/dist/chunk-3NSZZCOJ.js +0 -2
- package/dist/chunk-3O3AVMWM.cjs +0 -1
- package/dist/chunk-3TAUNYEM.js +0 -8
- package/dist/chunk-3U6MKWET.cjs +0 -120
- package/dist/chunk-3VXEK5ZW.cjs +0 -1
- package/dist/chunk-47CXBWMA.js +0 -2
- package/dist/chunk-4BMWWGJN.js +0 -384
- package/dist/chunk-4NTIK6DF.cjs +0 -2
- package/dist/chunk-4YCI3HBD.js +0 -3
- package/dist/chunk-4ZWLNGLS.js +0 -2
- package/dist/chunk-5A7E7N4B.cjs +0 -431
- package/dist/chunk-5ZEYOFAK.js +0 -2
- package/dist/chunk-6DD4J7LI.js +0 -2
- package/dist/chunk-6E44MQQ5.js +0 -115
- package/dist/chunk-6GGPY7U2.js +0 -4
- package/dist/chunk-6LWF5MPL.js +0 -20
- package/dist/chunk-6MNLRAKM.cjs +0 -121
- package/dist/chunk-6NBZDW53.js +0 -133
- package/dist/chunk-6TPICJ2L.js +0 -7
- package/dist/chunk-73D2PNHD.cjs +0 -7
- package/dist/chunk-73Y63IPP.js +0 -57
- package/dist/chunk-7ACHOBWY.cjs +0 -13
- package/dist/chunk-7DUKWHRN.cjs +0 -1
- package/dist/chunk-7GGZA5YU.cjs +0 -2
- package/dist/chunk-7JWQ2PZP.cjs +0 -1
- package/dist/chunk-7K6ZUNJM.js +0 -4
- package/dist/chunk-7KLEANTO.cjs +0 -1
- package/dist/chunk-7LLCXY5O.cjs +0 -19
- package/dist/chunk-7MNDQU6K.js +0 -8
- package/dist/chunk-7NH7H3WA.js +0 -10
- package/dist/chunk-7WMMKGEO.cjs +0 -1
- package/dist/chunk-A35ZP72D.cjs +0 -132
- package/dist/chunk-A3IOQOV6.js +0 -2
- package/dist/chunk-A3XVL6ED.cjs +0 -3
- package/dist/chunk-A7LZ6T42.cjs +0 -1
- package/dist/chunk-APDQ6ZTG.cjs +0 -120
- package/dist/chunk-ATI2UZ7U.js +0 -2
- package/dist/chunk-AWQGDMOE.js +0 -3
- package/dist/chunk-B3BSVEFC.cjs +0 -3
- package/dist/chunk-B4AC23SG.js +0 -122
- package/dist/chunk-BAVN7VDR.cjs +0 -1
- package/dist/chunk-BCEE4NBZ.cjs +0 -2
- package/dist/chunk-BD6XHMMM.cjs +0 -2
- package/dist/chunk-BUNLC3II.cjs +0 -1
- package/dist/chunk-C7QCZX7X.js +0 -2
- package/dist/chunk-CHYVUWZ3.js +0 -2
- package/dist/chunk-CIVA6SKW.js +0 -2
- package/dist/chunk-CNHUCCQJ.js +0 -121
- package/dist/chunk-CRP6PSCE.js +0 -2
- package/dist/chunk-D6SDGHY6.js +0 -2
- package/dist/chunk-DI6TCZSE.js +0 -122
- package/dist/chunk-DORUYZQV.cjs +0 -1
- package/dist/chunk-DSHKQL3R.cjs +0 -121
- package/dist/chunk-DVWYO3KK.cjs +0 -1
- package/dist/chunk-E4H3ZZ7U.js +0 -4
- package/dist/chunk-EFKEVWAD.js +0 -4
- package/dist/chunk-EHWUALGH.cjs +0 -1
- package/dist/chunk-EI7FRSNY.js +0 -57
- package/dist/chunk-ELFQKQLL.js +0 -2
- package/dist/chunk-EML5FDUU.js +0 -2
- package/dist/chunk-EN65ZEK2.cjs +0 -2
- package/dist/chunk-EON4XLKQ.cjs +0 -1
- package/dist/chunk-EUQAOYEO.cjs +0 -121
- package/dist/chunk-EVAUBT7H.js +0 -57
- package/dist/chunk-EW424IBO.cjs +0 -1
- package/dist/chunk-EYHD7HZE.cjs +0 -1
- package/dist/chunk-EYYIPA5N.js +0 -432
- package/dist/chunk-EZIDQBXI.cjs +0 -1
- package/dist/chunk-F2O4QO5N.cjs +0 -383
- package/dist/chunk-F4ITQ6XQ.cjs +0 -3
- package/dist/chunk-FBWLSWZ4.js +0 -122
- package/dist/chunk-FDKU7HJX.js +0 -2
- package/dist/chunk-FG3IFGJP.cjs +0 -1
- package/dist/chunk-FGN6IMPY.cjs +0 -3
- package/dist/chunk-FK2BG4HU.js +0 -3
- package/dist/chunk-FLMUMPDE.js +0 -2
- package/dist/chunk-FLS2FJM6.cjs +0 -431
- package/dist/chunk-FP5UK272.cjs +0 -1
- package/dist/chunk-FSL3NLRT.cjs +0 -2
- package/dist/chunk-FUFS65Q5.js +0 -133
- package/dist/chunk-GIS6X43A.cjs +0 -3
- package/dist/chunk-GNEVCEJU.cjs +0 -3
- package/dist/chunk-GNOSG3PK.cjs +0 -1
- package/dist/chunk-GQGFNTDZ.js +0 -2
- package/dist/chunk-GTR7JAKP.cjs +0 -3
- package/dist/chunk-GV2IB4WQ.cjs +0 -56
- package/dist/chunk-GWIZT2P5.js +0 -57
- package/dist/chunk-H3FJ54KB.cjs +0 -121
- package/dist/chunk-HPIJI7TM.js +0 -3
- package/dist/chunk-HPYH7GTS.cjs +0 -1
- package/dist/chunk-HRAY65XH.js +0 -3
- package/dist/chunk-HTYVI2HK.cjs +0 -9
- package/dist/chunk-HY3EAWB2.js +0 -4
- package/dist/chunk-I6UJVO2P.js +0 -57
- package/dist/chunk-IKGVPXMK.js +0 -3
- package/dist/chunk-IQSF6XRV.js +0 -57
- package/dist/chunk-IXGDTAES.js +0 -4
- package/dist/chunk-J6V573PE.cjs +0 -1
- package/dist/chunk-JA44K75G.js +0 -2
- package/dist/chunk-JB4WG2YJ.cjs +0 -121
- package/dist/chunk-JCEJ4VTN.js +0 -20
- package/dist/chunk-JRUQ5ABB.js +0 -4
- package/dist/chunk-JV4HJBXW.js +0 -14
- package/dist/chunk-JZ7Z6WC2.cjs +0 -3
- package/dist/chunk-K5XGP57D.cjs +0 -19
- package/dist/chunk-K73HOMQY.cjs +0 -56
- package/dist/chunk-KEITOXIP.js +0 -2
- package/dist/chunk-KMFLHGD5.cjs +0 -1
- package/dist/chunk-KZHXYXSH.cjs +0 -10
- package/dist/chunk-L3Q64RUX.js +0 -3
- package/dist/chunk-LBLFU6KI.js +0 -57
- package/dist/chunk-LEBM6ZSZ.cjs +0 -10
- package/dist/chunk-LP3HRZGK.js +0 -57
- package/dist/chunk-LPFRMQFQ.js +0 -121
- package/dist/chunk-LQ3YZTPU.cjs +0 -15
- package/dist/chunk-LVBHOZZF.js +0 -4
- package/dist/chunk-LWM4WABU.js +0 -3
- package/dist/chunk-LY7N3UHH.cjs +0 -23
- package/dist/chunk-LYU44UNN.cjs +0 -56
- package/dist/chunk-M75VGFCI.js +0 -3
- package/dist/chunk-MCIZG4A3.cjs +0 -1
- package/dist/chunk-MDLJTZLV.cjs +0 -1
- package/dist/chunk-MFNN5DYG.cjs +0 -1
- package/dist/chunk-MJAODEFC.cjs +0 -121
- package/dist/chunk-MLCBSEBU.js +0 -2
- package/dist/chunk-MSC4G2HF.cjs +0 -2
- package/dist/chunk-MYHNTJLR.cjs +0 -56
- package/dist/chunk-N2YHO2WI.cjs +0 -3
- package/dist/chunk-N4FXLQE3.cjs +0 -132
- package/dist/chunk-N5POANYV.js +0 -2
- package/dist/chunk-N6MNQIQU.js +0 -123
- package/dist/chunk-NGNJSUGL.cjs +0 -1
- package/dist/chunk-NPBXLPOP.js +0 -3
- package/dist/chunk-NRE6VKL6.cjs +0 -121
- package/dist/chunk-O4YE57OS.cjs +0 -6
- package/dist/chunk-O7CBGP4N.cjs +0 -1
- package/dist/chunk-OBYAIJVU.js +0 -11
- package/dist/chunk-OJ3H4AQ2.cjs +0 -56
- package/dist/chunk-OLRCZ6E3.js +0 -2
- package/dist/chunk-ON5XJEPO.cjs +0 -3
- package/dist/chunk-OOVNTOZC.cjs +0 -56
- package/dist/chunk-OPTVCCQQ.cjs +0 -122
- package/dist/chunk-OT2Z4XBD.cjs +0 -1
- package/dist/chunk-P6JITOFF.js +0 -4
- package/dist/chunk-PFKVHUOT.js +0 -432
- package/dist/chunk-PFTBTWSC.cjs +0 -1
- package/dist/chunk-PITMDQYN.cjs +0 -18
- package/dist/chunk-PTPVFLET.js +0 -20
- package/dist/chunk-PYUWSKKP.js +0 -57
- package/dist/chunk-PZDLPRJF.js +0 -4
- package/dist/chunk-Q5TFO66G.cjs +0 -1
- package/dist/chunk-QC4YXUBT.cjs +0 -383
- package/dist/chunk-QO5ZWQA3.cjs +0 -74
- package/dist/chunk-QUTYCUST.js +0 -4
- package/dist/chunk-QYN6C3FZ.cjs +0 -114
- package/dist/chunk-REKKBAQX.cjs +0 -56
- package/dist/chunk-REQ622YC.js +0 -3
- package/dist/chunk-RPRGGGIW.js +0 -11
- package/dist/chunk-RTNQP6BV.js +0 -2
- package/dist/chunk-RUJW47ZJ.js +0 -2
- package/dist/chunk-RVBSJ4UQ.cjs +0 -7
- package/dist/chunk-RXYCFZJC.cjs +0 -121
- package/dist/chunk-RYHOWZLK.js +0 -2
- package/dist/chunk-RYXLEFS5.js +0 -2
- package/dist/chunk-S2MZNEBQ.cjs +0 -1
- package/dist/chunk-S5HTTLN7.cjs +0 -2
- package/dist/chunk-S73YERS2.js +0 -57
- package/dist/chunk-SBNMXQNO.cjs +0 -2
- package/dist/chunk-SLMIYECU.js +0 -2
- package/dist/chunk-SMQ6736Y.js +0 -57
- package/dist/chunk-SRIXRJHL.js +0 -4
- package/dist/chunk-T3DJ3UTP.cjs +0 -121
- package/dist/chunk-TBHNE4VV.js +0 -2
- package/dist/chunk-TCFL3UWT.cjs +0 -2
- package/dist/chunk-TEY5LZ26.cjs +0 -56
- package/dist/chunk-TJZO7ZSX.cjs +0 -3
- package/dist/chunk-TKUNRCRH.js +0 -4
- package/dist/chunk-TQLCOMKC.js +0 -4
- package/dist/chunk-TRXYDWGE.cjs +0 -1
- package/dist/chunk-TS55CUNJ.js +0 -57
- package/dist/chunk-TYQYKKWJ.js +0 -16
- package/dist/chunk-U6KFONKM.js +0 -2
- package/dist/chunk-UFBJ3WOZ.js +0 -2
- package/dist/chunk-UNYXWPLZ.cjs +0 -2
- package/dist/chunk-UQRVQUVR.js +0 -2
- package/dist/chunk-UW5W35NP.js +0 -122
- package/dist/chunk-UWHWSWDE.js +0 -2
- package/dist/chunk-UWVBFRCW.js +0 -2
- package/dist/chunk-UZWYFEUN.js +0 -122
- package/dist/chunk-V4FAL7AG.js +0 -2
- package/dist/chunk-VI7WCO2J.cjs +0 -3
- package/dist/chunk-VOYPKTID.cjs +0 -1
- package/dist/chunk-VQ53TFYA.cjs +0 -1
- package/dist/chunk-VRZC4TTF.cjs +0 -1
- package/dist/chunk-VTOL3URF.js +0 -4
- package/dist/chunk-VVVCCB6R.js +0 -2
- package/dist/chunk-W2GPP6RB.js +0 -122
- package/dist/chunk-W45TLOOT.js +0 -2
- package/dist/chunk-WAVGRSE6.js +0 -2
- package/dist/chunk-WHOA7YJU.cjs +0 -1
- package/dist/chunk-WNRUPL26.js +0 -2
- package/dist/chunk-WPM6LFCY.js +0 -2
- package/dist/chunk-WXT2XW7T.js +0 -13
- package/dist/chunk-X473JI7Z.js +0 -75
- package/dist/chunk-X6HUA6EF.cjs +0 -20
- package/dist/chunk-XBQ6HV3T.cjs +0 -114
- package/dist/chunk-XDPLVJRO.js +0 -21
- package/dist/chunk-XDQVYCIR.cjs +0 -1
- package/dist/chunk-XFYSADHV.cjs +0 -2
- package/dist/chunk-XIAJQLGS.js +0 -2
- package/dist/chunk-XK6UB77Q.js +0 -4
- package/dist/chunk-XOR64WUQ.cjs +0 -19
- package/dist/chunk-XP7BXFXT.cjs +0 -121
- package/dist/chunk-Y2VHO66Q.cjs +0 -3
- package/dist/chunk-Y2YAKDEQ.js +0 -2
- package/dist/chunk-Y5O2OD7J.cjs +0 -3
- package/dist/chunk-YARB43JG.cjs +0 -56
- package/dist/chunk-YENNL5HG.js +0 -2
- package/dist/chunk-YGI5W4RS.js +0 -2
- package/dist/chunk-YLCEMVYY.cjs +0 -56
- package/dist/chunk-YSOM57GK.cjs +0 -3
- package/dist/chunk-YUUXFD73.js +0 -19
- package/dist/chunk-Z2SN2MYP.js +0 -122
- package/dist/chunk-Z3UVDGYS.cjs +0 -56
- package/dist/chunk-ZAKYTBEN.js +0 -3
- package/dist/chunk-ZHA446FA.cjs +0 -1
- package/dist/chunk-ZO3YB5DK.cjs +0 -1
- package/dist/chunk-ZOVH6QT5.cjs +0 -1
- package/dist/chunk-ZRIBWDYJ.js +0 -384
- package/dist/chunk-ZTLGK6R4.cjs +0 -12
- package/dist/chunk-ZUBJ6RLQ.cjs +0 -1
- package/dist/chunk-ZWDBPEXL.js +0 -115
- package/dist/client.d.cts +0 -1266
- package/dist/client.d.ts +0 -1266
- package/dist/d1-5ZQJOFDX.cjs +0 -1
- package/dist/d1-HPB6B253.js +0 -2
- package/dist/dist-es-3SSNUZST.cjs +0 -1
- package/dist/dist-es-64F22JL2.js +0 -2
- package/dist/dist-es-A5OF2STN.cjs +0 -2
- package/dist/dist-es-BOW5V247.cjs +0 -6
- package/dist/dist-es-CRIMATLL.cjs +0 -2
- package/dist/dist-es-DL3VLVP6.cjs +0 -1
- package/dist/dist-es-F2ZR55UK.js +0 -4
- package/dist/dist-es-IPSSZNFP.js +0 -1
- package/dist/dist-es-M2F7M27Y.js +0 -2
- package/dist/dist-es-M66JKZF5.js +0 -7
- package/dist/dist-es-OKLLRYI3.js +0 -2
- package/dist/dist-es-P25IKLBI.cjs +0 -1
- package/dist/dist-es-SRPWSAF4.cjs +0 -1
- package/dist/dist-es-SVHZDVUF.js +0 -3
- package/dist/dist-es-T2H2W5BX.cjs +0 -3
- package/dist/dist-es-WFI55HKT.js +0 -3
- package/dist/drizzle-orm-47ELDEM6.cjs +0 -1
- package/dist/drizzle-orm-XRTSOQJS.js +0 -1
- package/dist/event-streams-7NAWZW2I.js +0 -1
- package/dist/event-streams-JBMWCI2O.cjs +0 -1
- package/dist/fs-KWBRQ6T6.js +0 -1
- package/dist/fs-ZQYOJOIO.cjs +0 -1
- package/dist/index-8Ino7vKq.d.ts +0 -105
- package/dist/index-B9BFNOHd.d.cts +0 -105
- package/dist/index-ByOM1Y5x.d.ts +0 -105
- package/dist/index-C6xmtRio.d.cts +0 -105
- package/dist/index-CTI3K_uq.d.cts +0 -105
- package/dist/index-CTL4zv_u.d.ts +0 -105
- package/dist/index-CaDbioSg.d.ts +0 -105
- package/dist/index-CxA9uOv0.d.ts +0 -105
- package/dist/index-D6AXbuPI.d.ts +0 -105
- package/dist/index-DF0KDBaM.d.cts +0 -105
- package/dist/index-DG4Xu7gA.d.cts +0 -105
- package/dist/index-DS3DpJli.d.cts +0 -105
- package/dist/index-NGnJpSgf.d.ts +0 -105
- package/dist/index-Zrg3sZ6R.d.cts +0 -105
- package/dist/index-eHex8Iwj.d.ts +0 -105
- package/dist/index-rm7uyOK1.d.cts +0 -105
- package/dist/jsonwebtoken-DFB6ZBZA.cjs +0 -8
- package/dist/jsonwebtoken-OD67R5JS.js +0 -9
- package/dist/lib-5QYYN6ML.cjs +0 -12
- package/dist/lib-A2D63VXD.cjs +0 -1
- package/dist/lib-JQD2JAOO.js +0 -2
- package/dist/lib-XXYYUPMW.js +0 -13
- package/dist/loadSso-JY4WDQPS.cjs +0 -2
- package/dist/loadSso-UQR6545M.js +0 -3
- package/dist/local-6UUGBZ4M.js +0 -1
- package/dist/local-DPLKZQA3.js +0 -1
- package/dist/local-KR3AIGVA.cjs +0 -1
- package/dist/local-S5VA7IXE.cjs +0 -1
- package/dist/local-T7GISZBL.js +0 -1
- package/dist/local-ZYHV3J2K.cjs +0 -1
- package/dist/media-3Z6YW5J4.cjs +0 -1
- package/dist/media-E762GEHL.js +0 -1
- package/dist/mongo-auth-adapter-2H2AXDRH.cjs +0 -1
- package/dist/mongo-auth-adapter-EUHAYWJ6.cjs +0 -1
- package/dist/mongo-auth-adapter-FW7ATYQ6.js +0 -1
- package/dist/mongo-auth-adapter-GR2CFFEA.js +0 -1
- package/dist/mongo-auth-adapter-UOO2LZUJ.cjs +0 -1
- package/dist/mongo-auth-adapter-YWMEOC42.js +0 -1
- package/dist/nodemailer-IDML4L6W.cjs +0 -53
- package/dist/nodemailer-NITB45SS.js +0 -54
- package/dist/nodemailer-transport-3VWVUBM5.cjs +0 -1
- package/dist/nodemailer-transport-7RHATUKL.js +0 -1
- package/dist/nodemailer-transport-CHO2WKIY.js +0 -1
- package/dist/nodemailer-transport-ED2IXNGW.cjs +0 -1
- package/dist/postgres-auth-adapter-QKBNXVPT.js +0 -1
- package/dist/postgres-auth-adapter-SK3N3OSS.js +0 -1
- package/dist/postgres-auth-adapter-WMLM4UUC.cjs +0 -1
- package/dist/postgres-auth-adapter-ZO6HK5AK.cjs +0 -1
- package/dist/postgres-js-7YBZKGXG.cjs +0 -1
- package/dist/postgres-js-JLFIWOBH.js +0 -1
- package/dist/redis-adapter-EGMUN65D.cjs +0 -1
- package/dist/redis-adapter-EVK2SMKH.cjs +0 -1
- package/dist/redis-adapter-LY2NBSAG.js +0 -1
- package/dist/redis-adapter-QPCTMF55.js +0 -1
- package/dist/schema-RT6WSUYC.cjs +0 -1
- package/dist/schema-YFMSJK2P.js +0 -2
- package/dist/signin-N3T2KF5Q.js +0 -3
- package/dist/signin-VFBLX7EL.cjs +0 -2
- package/dist/sqlite-adapter-52PL52VU.js +0 -1
- package/dist/sqlite-adapter-KPSISY6E.cjs +0 -1
- package/dist/sqlite-adapter-MNNZZXGX.cjs +0 -1
- package/dist/sqlite-adapter-PI6SIY7O.js +0 -1
- package/dist/src-6LAUXXDM.cjs +0 -1
- package/dist/src-QBADSZV4.js +0 -1
- package/dist/sso-oidc-54BIRYR6.cjs +0 -2
- package/dist/sso-oidc-UB7G4END.js +0 -3
- package/dist/sts-WAA6I22C.js +0 -3
- package/dist/sts-YLXXIB3X.cjs +0 -2
- package/dist/types-B5Qz1svz.d.cts +0 -822
- package/dist/types-B9oXBEKI.d.cts +0 -330
- package/dist/types-B9oXBEKI.d.ts +0 -330
- package/dist/types-BRDBNacn.d.ts +0 -839
- package/dist/types-Bii0bhUV.d.cts +0 -329
- package/dist/types-Bii0bhUV.d.ts +0 -329
- package/dist/types-Bt2_ycUO.d.ts +0 -811
- package/dist/types-C4wXHImf.d.ts +0 -822
- package/dist/types-C8yIAV6K.d.cts +0 -839
- package/dist/types-CORUQhY-.d.ts +0 -839
- package/dist/types-Cdssrcbz.d.cts +0 -839
- package/dist/types-CjGqxBd3.d.cts +0 -330
- package/dist/types-CjGqxBd3.d.ts +0 -330
- package/dist/types-DBGR-eQl.d.cts +0 -839
- package/dist/types-DCWgPFmi.d.cts +0 -822
- package/dist/types-DROqAsr0.d.cts +0 -330
- package/dist/types-DROqAsr0.d.ts +0 -330
- package/dist/types-DlGSbh7I.d.cts +0 -297
- package/dist/types-DlGSbh7I.d.ts +0 -297
- package/dist/types-DsF64Wrc.d.cts +0 -811
- package/dist/types-IeKFn7Ky.d.ts +0 -839
- package/dist/types-QglJ7PwT.d.cts +0 -839
- package/dist/types-ZrjEVWfi.d.ts +0 -811
- package/dist/types-dEy5JxvN.d.ts +0 -822
- package/dist/types-tVJc9YbX.d.cts +0 -811
- package/dist/types-zt5qIvje.d.ts +0 -839
package/dist/index.d.cts
CHANGED
|
@@ -1,20 +1,20 @@
|
|
|
1
1
|
import * as hono from 'hono';
|
|
2
2
|
import * as hono_types from 'hono/types';
|
|
3
|
-
import { R as Registry } from './index-
|
|
4
|
-
export { c as createRegistry, g as getRegistry, r as resetRegistry } from './index-
|
|
5
|
-
import { a as StorageProvider, C as CollectionConfig, G as GlobalConfig, B as BaseAdapter, P as PluginManager, h as KyroConfig, i as User, R as Request$1, F as FindArgs, b as FindResult, c as FindByIDArgs, d as CreateArgs, U as UpdateArgs, D as DeleteArgs, e as FindOneArgs, f as FindVersionsArgs, V as VersionRecord, g as CreateVersionArgs } from './types-
|
|
6
|
-
export { A as AccessArgs, j as AccessControl, k as AdapterConfig, l as AdminConfig, m as AnalyticsPlugin, n as AuthConfig, o as CollectionAccess, p as CollectionHooks, q as CommentsPlugin, r as ConfigService, s as CreateResult, E as EmailConfig, t as
|
|
3
|
+
import { R as Registry } from './index-Ci7aUrmN.cjs';
|
|
4
|
+
export { c as createRegistry, g as getRegistry, r as resetRegistry } from './index-Ci7aUrmN.cjs';
|
|
5
|
+
import { a as StorageProvider, C as CollectionConfig, G as GlobalConfig, B as BaseAdapter, P as PluginManager, h as KyroConfig, i as User, R as Request$1, F as FindArgs, b as FindResult, c as FindByIDArgs, d as CreateArgs, U as UpdateArgs, D as DeleteArgs, e as FindOneArgs, f as FindVersionsArgs, V as VersionRecord, g as CreateVersionArgs } from './types-CdwfDpyW.cjs';
|
|
6
|
+
export { A as AccessArgs, j as AccessControl, k as AdapterConfig, l as AdminConfig, m as AnalyticsPlugin, n as AuthConfig, o as CollectionAccess, p as CollectionHooks, q as CommentsPlugin, r as ConfigService, s as CreateResult, E as EmailConfig, t as ExperimentalConfig, u as FieldAccess, v as FieldHooks, w as GlobalAccess, x as GlobalHooks, H as HierarchyConfig, y as Hook, z as HookArgs, I as ImageSize, K as KyroPlugin, O as OrganizationConfig, J as PluginAPI, L as PluginHooks, M as ProjectConfig, N as ReviewsPlugin, Q as SEOPlugin, W as SmartViewConfig, S as StorageConfig, X as UploadConfig, Y as VersionConfig, Z as WhereClause, _ as WishlistPlugin, $ as evaluateAccess, a0 as getWhereClause, a1 as mergeWhereClauses, a2 as presetPlugins, a3 as resolveProvider, a4 as runFieldHooks, a5 as runHooks } from './types-CdwfDpyW.cjs';
|
|
7
7
|
import { KyroPubSub, KyroWSServer } from './ws/index.cjs';
|
|
8
8
|
export { PubSub, createWSServer } from './ws/index.cjs';
|
|
9
|
-
import { W as WebhookPayload, D as DeliveryResult, a as WebhookDelivery, b as WebhookConfig, c as DeliveryOptions, d as WebhookService } from './WebhookService-
|
|
10
|
-
export { A as ALL_WEBHOOK_EVENTS, C as CreateWebhookData, U as UpdateWebhookData, e as WEBHOOK_COLLECTION, f as WEBHOOK_DELIVERY_COLLECTION, g as WEBHOOK_EVENTS, h as WebhookEvent, i as WebhookTriggerResult, j as createWebhookService } from './WebhookService-
|
|
11
|
-
import { F as Field } from './types-
|
|
12
|
-
export { A as ALL_FIELD_TYPES, b as ArrayField, B as BaseField, c as Block, f as BlocksField, C as COMPLEX_FIELD_TYPES, h as CheckboxField, i as CodeField, j as CollapsibleField, k as ColorField, D as DateField, E as EmailField, o as FieldAdmin, p as FieldType, G as GroupField, q as ImageField, J as JSONField, L as LAYOUT_FIELD_TYPES, M as MarkdownField, N as NumberField, P as PRIMITIVE_FIELD_TYPES, s as PasswordField, R as RELATIONAL_FIELD_TYPES, t as RadioField, u as RelationshipField, v as RichTextBlock, w as RichTextField, x as RowField, y as SelectField, T as TabsField, z as TextField, O as TextareaField, U as UploadField, V as ValidateOptions, W as isArrayField, X as isBlocksField, Z as isGroupField, $ as isImageField, a0 as isLayoutField, a1 as isNumberField, a2 as isRelationshipField, a3 as isRichTextField, a4 as isSelectField, a5 as isTextField, a6 as isUploadField } from './types-
|
|
9
|
+
import { W as WebhookPayload, D as DeliveryResult, a as WebhookDelivery, b as WebhookConfig, c as DeliveryOptions, d as WebhookService } from './WebhookService-BJTCP3cU.cjs';
|
|
10
|
+
export { A as ALL_WEBHOOK_EVENTS, C as CreateWebhookData, U as UpdateWebhookData, e as WEBHOOK_COLLECTION, f as WEBHOOK_DELIVERY_COLLECTION, g as WEBHOOK_EVENTS, h as WebhookEvent, i as WebhookTriggerResult, j as createWebhookService } from './WebhookService-BJTCP3cU.cjs';
|
|
11
|
+
import { F as Field } from './types-C3QFX0l6.cjs';
|
|
12
|
+
export { A as ALL_FIELD_TYPES, b as ArrayField, B as BaseField, c as Block, f as BlocksField, C as COMPLEX_FIELD_TYPES, h as CheckboxField, i as CodeField, j as CollapsibleField, k as ColorField, D as DateField, E as EmailField, o as FieldAdmin, p as FieldType, G as GroupField, q as ImageField, J as JSONField, L as LAYOUT_FIELD_TYPES, M as MarkdownField, N as NumberField, P as PRIMITIVE_FIELD_TYPES, s as PasswordField, R as RELATIONAL_FIELD_TYPES, t as RadioField, u as RelationshipField, v as RichTextBlock, w as RichTextField, x as RowField, y as SelectField, T as TabsField, z as TextField, O as TextareaField, U as UploadField, V as ValidateOptions, W as isArrayField, X as isBlocksField, Z as isGroupField, $ as isImageField, a0 as isLayoutField, a1 as isNumberField, a2 as isRelationshipField, a3 as isRichTextField, a4 as isSelectField, a5 as isTextField, a6 as isUploadField } from './types-C3QFX0l6.cjs';
|
|
13
13
|
import { ZodTypeAny, z } from 'zod';
|
|
14
14
|
export { z } from 'zod';
|
|
15
15
|
export { n as normalizeRichTextValue, r as renderRichText, a as richTextStyles } from './richtext-DrhORshE.cjs';
|
|
16
|
-
import { A as AuditLog, a as AuditLogFilter, b as AbstractBaseAdapter, c as AuthAdapter, U as UserRole, d as AuthUser, S as Session, e as AuthTokenConfig, R as RegisterData, f as AuthResult, L as LoginCredentials, J as JWTPayload } from './base-
|
|
17
|
-
export { g as AuditAction } from './base-
|
|
16
|
+
import { A as AuditLog, a as AuditLogFilter, b as AbstractBaseAdapter, c as AuthAdapter, U as UserRole, d as AuthUser, S as Session, e as AuthTokenConfig, R as RegisterData, f as AuthResult, L as LoginCredentials, J as JWTPayload } from './base-DIpT2Vuz.cjs';
|
|
17
|
+
export { g as AuditAction } from './base-DIpT2Vuz.cjs';
|
|
18
18
|
import { Dialect } from './drizzle/index.cjs';
|
|
19
19
|
export { DrizzleAdapter, PostgresAuthAdapter, collectionToDrizzleSchema, createDatabase, createDrizzleAdapter, fieldToDrizzleType, runMigrations, seedDefaultRoles } from './drizzle/index.cjs';
|
|
20
20
|
export { MongoDBAdapter, MongoDBAuthAdapter, createMongoDBAdapter } from './mongodb/index.cjs';
|
package/dist/index.d.ts
CHANGED
|
@@ -1,20 +1,20 @@
|
|
|
1
1
|
import * as hono from 'hono';
|
|
2
2
|
import * as hono_types from 'hono/types';
|
|
3
|
-
import { R as Registry } from './index-
|
|
4
|
-
export { c as createRegistry, g as getRegistry, r as resetRegistry } from './index-
|
|
5
|
-
import { a as StorageProvider, C as CollectionConfig, G as GlobalConfig, B as BaseAdapter, P as PluginManager, h as KyroConfig, i as User, R as Request$1, F as FindArgs, b as FindResult, c as FindByIDArgs, d as CreateArgs, U as UpdateArgs, D as DeleteArgs, e as FindOneArgs, f as FindVersionsArgs, V as VersionRecord, g as CreateVersionArgs } from './types-
|
|
6
|
-
export { A as AccessArgs, j as AccessControl, k as AdapterConfig, l as AdminConfig, m as AnalyticsPlugin, n as AuthConfig, o as CollectionAccess, p as CollectionHooks, q as CommentsPlugin, r as ConfigService, s as CreateResult, E as EmailConfig, t as
|
|
3
|
+
import { R as Registry } from './index-C9uBoJtm.js';
|
|
4
|
+
export { c as createRegistry, g as getRegistry, r as resetRegistry } from './index-C9uBoJtm.js';
|
|
5
|
+
import { a as StorageProvider, C as CollectionConfig, G as GlobalConfig, B as BaseAdapter, P as PluginManager, h as KyroConfig, i as User, R as Request$1, F as FindArgs, b as FindResult, c as FindByIDArgs, d as CreateArgs, U as UpdateArgs, D as DeleteArgs, e as FindOneArgs, f as FindVersionsArgs, V as VersionRecord, g as CreateVersionArgs } from './types-CKWnrUAh.js';
|
|
6
|
+
export { A as AccessArgs, j as AccessControl, k as AdapterConfig, l as AdminConfig, m as AnalyticsPlugin, n as AuthConfig, o as CollectionAccess, p as CollectionHooks, q as CommentsPlugin, r as ConfigService, s as CreateResult, E as EmailConfig, t as ExperimentalConfig, u as FieldAccess, v as FieldHooks, w as GlobalAccess, x as GlobalHooks, H as HierarchyConfig, y as Hook, z as HookArgs, I as ImageSize, K as KyroPlugin, O as OrganizationConfig, J as PluginAPI, L as PluginHooks, M as ProjectConfig, N as ReviewsPlugin, Q as SEOPlugin, W as SmartViewConfig, S as StorageConfig, X as UploadConfig, Y as VersionConfig, Z as WhereClause, _ as WishlistPlugin, $ as evaluateAccess, a0 as getWhereClause, a1 as mergeWhereClauses, a2 as presetPlugins, a3 as resolveProvider, a4 as runFieldHooks, a5 as runHooks } from './types-CKWnrUAh.js';
|
|
7
7
|
import { KyroPubSub, KyroWSServer } from './ws/index.js';
|
|
8
8
|
export { PubSub, createWSServer } from './ws/index.js';
|
|
9
|
-
import { W as WebhookPayload, D as DeliveryResult, a as WebhookDelivery, b as WebhookConfig, c as DeliveryOptions, d as WebhookService } from './WebhookService-
|
|
10
|
-
export { A as ALL_WEBHOOK_EVENTS, C as CreateWebhookData, U as UpdateWebhookData, e as WEBHOOK_COLLECTION, f as WEBHOOK_DELIVERY_COLLECTION, g as WEBHOOK_EVENTS, h as WebhookEvent, i as WebhookTriggerResult, j as createWebhookService } from './WebhookService-
|
|
11
|
-
import { F as Field } from './types-
|
|
12
|
-
export { A as ALL_FIELD_TYPES, b as ArrayField, B as BaseField, c as Block, f as BlocksField, C as COMPLEX_FIELD_TYPES, h as CheckboxField, i as CodeField, j as CollapsibleField, k as ColorField, D as DateField, E as EmailField, o as FieldAdmin, p as FieldType, G as GroupField, q as ImageField, J as JSONField, L as LAYOUT_FIELD_TYPES, M as MarkdownField, N as NumberField, P as PRIMITIVE_FIELD_TYPES, s as PasswordField, R as RELATIONAL_FIELD_TYPES, t as RadioField, u as RelationshipField, v as RichTextBlock, w as RichTextField, x as RowField, y as SelectField, T as TabsField, z as TextField, O as TextareaField, U as UploadField, V as ValidateOptions, W as isArrayField, X as isBlocksField, Z as isGroupField, $ as isImageField, a0 as isLayoutField, a1 as isNumberField, a2 as isRelationshipField, a3 as isRichTextField, a4 as isSelectField, a5 as isTextField, a6 as isUploadField } from './types-
|
|
9
|
+
import { W as WebhookPayload, D as DeliveryResult, a as WebhookDelivery, b as WebhookConfig, c as DeliveryOptions, d as WebhookService } from './WebhookService-Bqr_66lK.js';
|
|
10
|
+
export { A as ALL_WEBHOOK_EVENTS, C as CreateWebhookData, U as UpdateWebhookData, e as WEBHOOK_COLLECTION, f as WEBHOOK_DELIVERY_COLLECTION, g as WEBHOOK_EVENTS, h as WebhookEvent, i as WebhookTriggerResult, j as createWebhookService } from './WebhookService-Bqr_66lK.js';
|
|
11
|
+
import { F as Field } from './types-C3QFX0l6.js';
|
|
12
|
+
export { A as ALL_FIELD_TYPES, b as ArrayField, B as BaseField, c as Block, f as BlocksField, C as COMPLEX_FIELD_TYPES, h as CheckboxField, i as CodeField, j as CollapsibleField, k as ColorField, D as DateField, E as EmailField, o as FieldAdmin, p as FieldType, G as GroupField, q as ImageField, J as JSONField, L as LAYOUT_FIELD_TYPES, M as MarkdownField, N as NumberField, P as PRIMITIVE_FIELD_TYPES, s as PasswordField, R as RELATIONAL_FIELD_TYPES, t as RadioField, u as RelationshipField, v as RichTextBlock, w as RichTextField, x as RowField, y as SelectField, T as TabsField, z as TextField, O as TextareaField, U as UploadField, V as ValidateOptions, W as isArrayField, X as isBlocksField, Z as isGroupField, $ as isImageField, a0 as isLayoutField, a1 as isNumberField, a2 as isRelationshipField, a3 as isRichTextField, a4 as isSelectField, a5 as isTextField, a6 as isUploadField } from './types-C3QFX0l6.js';
|
|
13
13
|
import { ZodTypeAny, z } from 'zod';
|
|
14
14
|
export { z } from 'zod';
|
|
15
15
|
export { n as normalizeRichTextValue, r as renderRichText, a as richTextStyles } from './richtext-DrhORshE.js';
|
|
16
|
-
import { A as AuditLog, a as AuditLogFilter, b as AbstractBaseAdapter, c as AuthAdapter, U as UserRole, d as AuthUser, S as Session, e as AuthTokenConfig, R as RegisterData, f as AuthResult, L as LoginCredentials, J as JWTPayload } from './base-
|
|
17
|
-
export { g as AuditAction } from './base-
|
|
16
|
+
import { A as AuditLog, a as AuditLogFilter, b as AbstractBaseAdapter, c as AuthAdapter, U as UserRole, d as AuthUser, S as Session, e as AuthTokenConfig, R as RegisterData, f as AuthResult, L as LoginCredentials, J as JWTPayload } from './base-C2DOe8wD.js';
|
|
17
|
+
export { g as AuditAction } from './base-C2DOe8wD.js';
|
|
18
18
|
import { Dialect } from './drizzle/index.js';
|
|
19
19
|
export { DrizzleAdapter, PostgresAuthAdapter, collectionToDrizzleSchema, createDatabase, createDrizzleAdapter, fieldToDrizzleType, runMigrations, seedDefaultRoles } from './drizzle/index.js';
|
|
20
20
|
export { MongoDBAdapter, MongoDBAuthAdapter, createMongoDBAdapter } from './mongodb/index.js';
|
package/dist/index.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
export{a as LocalAdapter,b as createLocalAdapter}from'./chunk-
|
|
2
|
-
|
|
1
|
+
export{a as LocalAdapter,b as createLocalAdapter}from'./chunk-ZE2X3FBU.js';export{a as RedisAuthAdapter}from'./chunk-V4SR7DU5.js';export{k as allGlobalSettings,q as blogCollections,l as coreGlobalSettings,V as createTemplateConfig,r as ecommerceCollections,s as ecommerceGlobals,t as kitchenSinkCollections,v as mediaCollections,a as minimalCollections,U as templateCollections}from'./chunk-SEJ7LMYY.js';export{r as ALL_FIELD_TYPES,o as COMPLEX_FIELD_TYPES,q as LAYOUT_FIELD_TYPES,n as PRIMITIVE_FIELD_TYPES,p as RELATIONAL_FIELD_TYPES,d as isArrayField,f as isBlocksField,e as isGroupField,h as isImageField,k as isLayoutField,b as isNumberField,c as isRelationshipField,i as isRichTextField,j as isSelectField,a as isTextField,g as isUploadField,u as normalizeRichTextValue,v as renderRichText,t as richTextStyles}from'./chunk-5BUAWCU6.js';export{a as kyro}from'./chunk-SZY25KAE.js';export{s as AnalyticsPlugin,t as CommentsPlugin,a as ConfigValidationError,x as FIELD_DEFINITION_KEYS,F as Kyro,p as KyroPlugin,I as Logger,q as PluginManager,l as Registry,u as ReviewsPlugin,r as SEOPlugin,v as WishlistPlugin,B as applyBlocksOverrides,D as applyCollectionOverrides,E as applyGlobalOverrides,C as applyTabsOverrides,h as collectionToCreateZod,i as collectionToUpdateZod,j as collectionToWhereZod,g as collectionToZod,G as createKyro,H as createKyroHandler,o as createRegistry,f as fieldToZod,z as flattenFieldOverrides,m as getRegistry,k as globalToZod,y as isFieldOverrideDefinition,J as logger,w as presetPlugins,n as resetRegistry,A as updateFieldByPath,b as validateCollection,e as validateConfig,d as validateFields,c as validateGlobal}from'./chunk-N25DOGLQ.js';export{e as autoBootstrap,a as bootstrapAdmin,f as bootstrapWithRetry,d as getBootstrapFromEnv}from'./chunk-KUY4QDAL.js';import'./chunk-LGUHXOEW.js';import'./chunk-ZMH35QYG.js';export{a as createContext,g as createCountProcedure,d as createCreateProcedure,f as createDeleteProcedure,h as createDynamicRouter,c as createFindByIDProcedure,b as createFindProcedure,i as createKyroServer,e as createUpdateProcedure}from'./chunk-GTAKGVUY.js';export{c as buildGraphQLSchema,d as createGraphQLSchema}from'./chunk-5RBGM5N5.js';import {g,f,i,j}from'./chunk-A4XM33WO.js';export{g as AuditLogger,i as InMemoryAuditLogger,f as InMemoryRateLimiter,l as MediaService,h as createAuditContext,n as createKyroApp,d as createLocalStorage,o as createRESTAPI,k as isEdgeRuntime,c as resolveProvider}from'./chunk-A4XM33WO.js';import {a}from'./chunk-FAG2645P.js';export{a as PasswordPolicy}from'./chunk-FAG2645P.js';import {a as a$3}from'./chunk-IIVBEZC2.js';export{a as SQLiteAuthAdapter}from'./chunk-IIVBEZC2.js';import'./chunk-I22MSXGL.js';export{c as getAppSecret,d as getEncryptionKey,e as getSessionConfig,b as loadSecrets,a as setDbAdapter}from'./chunk-SBFVITY2.js';import {q as q$1}from'./chunk-5I3BM5TV.js';export{p as ConfigService,q as EmailTransport,o as getEmailTemplates,n as renderAbandonedCart,g as renderAccountLocked,a as renderBaseLayout,f as renderMagicLink,i as renderNewLogin,j as renderOrderConfirmation,l as renderOrderDelivered,m as renderOrderRefunded,k as renderOrderShipped,e as renderPasswordChanged,c as renderResetPassword,h as renderUserInvite,b as renderVerifyEmail,d as renderWelcome}from'./chunk-5I3BM5TV.js';import'./chunk-W5GDZG64.js';export{d as ALL_WEBHOOK_EVENTS,e as WEBHOOK_COLLECTION,f as WEBHOOK_DELIVERY_COLLECTION,c as WEBHOOK_EVENTS,m as WebhookService,k as buildDeliveryRecord,l as createTestPayload,n as createWebhookService,i as deliverWebhook,j as deliverWithRetry,h as generateWebhookSecret,g as signPayload}from'./chunk-OPKZYQV7.js';export{h as evaluateAccess,j as getWhereClause,i as mergeWhereClauses}from'./chunk-3N34WXBS.js';export{b as KyroPubSub,d as KyroWSServer,a as PubSub,e as createWSServer}from'./chunk-OXH6CANN.js';export{c as DrizzleAdapter,b as collectionToDrizzleSchema,d as createDrizzleAdapter,a as fieldToDrizzleType}from'./chunk-TJ6N5ZPZ.js';export{b as createDatabase,c as runMigrations,d as seedDefaultRoles}from'./chunk-JXJTFBHG.js';import {a as a$4}from'./chunk-IIPSXKNV.js';export{a as PostgresAuthAdapter}from'./chunk-IIPSXKNV.js';import'./chunk-7EY3GXRA.js';import'./chunk-WLSVS3NC.js';export{a as MongoDBAdapter,b as createMongoDBAdapter}from'./chunk-VWXHW74B.js';import {a as a$2}from'./chunk-CIWLQXB2.js';export{a as MongoDBAuthAdapter}from'./chunk-CIWLQXB2.js';import {a as a$5}from'./chunk-YNSKDTFG.js';export{a as AbstractBaseAdapter}from'./chunk-YNSKDTFG.js';import {a as a$1}from'./chunk-VLFM66BZ.js';import'./chunk-NGNXOXI5.js';import'./chunk-O4RKZQYQ.js';import'./chunk-RLW6AQF2.js';import Q,{randomBytes}from'crypto';import {readFileSync}from'fs';import $e,{join,resolve}from'path';import {z as z$1}from'zod';export{z}from'zod';import {createStorage}from'unstorage';import lo from'unstorage/drivers/indexedb';import go from'unstorage/drivers/fs';if (typeof window === "undefined") { const { createRequire } = await import(/* @vite-ignore */ 'module'); createRequire(import.meta.url); }
|
|
2
|
+
async function Le(s,e){let t=e.data;for(let r of s){let o=await r({...e,data:t});o!==void 0&&(t=o);}return t}async function Or(s,e){return Le(s,e)}var L=class extends a$5{connectionString;constructor(e){super(),this.connectionString=e.connectionString;}async connect(){this.connected=true;}async disconnect(){this.connected=false;}async query(e,t=[]){if(!this.connectionString)throw new Error("NeonAdapter: Connection string is required.");try{let r=await fetch(`${this.connectionString}/sql`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({query:e,params:t})});return r.ok?(await r.json()).rows||[]:[]}catch{return []}}async find(e){return {docs:[],totalDocs:0,limit:e.limit||10,totalPages:1,page:e.page||1,hasNextPage:false,hasPrevPage:false}}async findByID(e){return null}async create(e){return e.data}async update(e){return e.data}async delete(e){return {success:true,id:e.id}}async count(e){return 0}async findOne(e){return null}async findVersions(e){return {docs:[],totalDocs:0,limit:10,totalPages:1,page:1,hasNextPage:false,hasPrevPage:false}}async findVersionByID(e){return null}async createVersion(e){return {id:"v1",parentId:e.documentId,version:e.version||1,snapshot:e.snapshot||{},createdAt:new Date().toISOString()}}async updateLatestVersion(e){return {id:"v1",parentId:e.documentId,version:e.version||1,snapshot:e.snapshot||{},createdAt:new Date().toISOString()}}async deleteVersions(e){}};function Ee(s){return new L(s)}var E=class extends a$5{url;authToken;constructor(e){super(),this.url=e.url.replace(/^libsql:\/\//,"https://"),this.authToken=e.authToken;}async connect(){this.connected=true;}async disconnect(){this.connected=false;}async query(e,t=[]){if(!this.url)throw new Error("TursoAdapter: Database URL is required.");try{let r={"Content-Type":"application/json"};this.authToken&&(r.Authorization=`Bearer ${this.authToken}`);let o=await fetch(`${this.url}/v2/pipeline`,{method:"POST",headers:r,body:JSON.stringify({requests:[{type:"execute",stmt:{sql:e,args:t.map(c=>({type:"text",value:String(c)}))}},{type:"close"}]})});if(!o.ok)return [];let i=(await o.json())?.results?.[0]?.response?.result;if(!i||!i.rows)return [];let a=i.cols.map(c=>c.name);return i.rows.map(c=>{let u={};return a.forEach((f,d)=>{u[f]=c[d]?.value??null;}),u})}catch{return []}}async find(e){return {docs:[],totalDocs:0,limit:e.limit||10,totalPages:1,page:e.page||1,hasNextPage:false,hasPrevPage:false}}async findByID(e){return null}async create(e){return e.data}async update(e){return e.data}async delete(e){return {success:true,id:e.id}}async count(e){return 0}async findOne(e){return null}async findVersions(e){return {docs:[],totalDocs:0,limit:10,totalPages:1,page:1,hasNextPage:false,hasPrevPage:false}}async findVersionByID(e){return null}async createVersion(e){return {id:"v1",parentId:e.documentId,version:e.version||1,snapshot:e.snapshot||{},createdAt:new Date().toISOString()}}async updateLatestVersion(e){return {id:"v1",parentId:e.documentId,version:e.version||1,snapshot:e.snapshot||{},createdAt:new Date().toISOString()}}async deleteVersions(e){}};function Oe(s){return new E(s)}var z=class{constructor(e){this.config=e;}config;css=[];addRule(e,t){let r=Object.entries(t).map(([o,n])=>` ${o}: ${n};`).join(`
|
|
3
3
|
`);return this.css.push(`${e} {
|
|
4
4
|
${r}
|
|
5
5
|
}`),this}addMediaQuery(e,t){return this.css.push(`@media (min-width: ${e}) {
|
|
@@ -7,39 +7,39 @@ ${r}
|
|
|
7
7
|
`)}
|
|
8
8
|
}`),this}generate(){return this.css.join(`
|
|
9
9
|
|
|
10
|
-
`)}};function
|
|
10
|
+
`)}};function Ur(s){return {theme:{extend:{colors:s.colors||{},fontFamily:s.fonts||{},spacing:s.spacing||{},borderRadius:s.borderRadius||{},boxShadow:s.shadows||{},screens:s.breakpoints||{}}}}}var O={colors:{primary:"#3b82f6",secondary:"#6366f1",accent:"#ec4899",background:"#ffffff",surface:"#f9fafb",text:"#111827",textMuted:"#6b7280",border:"#e5e7eb",error:"#ef4444",warning:"#f59e0b",success:"#10b981",info:"#3b82f6"},fonts:{sans:"system-ui, -apple-system, sans-serif",serif:"Georgia, serif",mono:"Menlo, monospace"},spacing:{xs:"0.25rem",sm:"0.5rem",md:"1rem",lg:"1.5rem",xl:"2rem","2xl":"3rem","3xl":"4rem"},borderRadius:{sm:"0.125rem",md:"0.375rem",lg:"0.5rem",xl:"0.75rem",full:"9999px"},shadows:{sm:"0 1px 2px 0 rgb(0 0 0 / 0.05)",md:"0 4px 6px -1px rgb(0 0 0 / 0.1)",lg:"0 10px 15px -3px rgb(0 0 0 / 0.1)",xl:"0 20px 25px -5px rgb(0 0 0 / 0.1)"}},Vr={colors:{primary:"#60a5fa",secondary:"#818cf8",accent:"#f472b6",background:"#111827",surface:"#1f2937",text:"#f9fafb",textMuted:"#9ca3af",border:"#374151",error:"#f87171",warning:"#fbbf24",success:"#34d399",info:"#60a5fa"},fonts:O.fonts,spacing:O.spacing,borderRadius:O.borderRadius,shadows:{sm:"0 1px 2px 0 rgb(0 0 0 / 0.3)",md:"0 4px 6px -1px rgb(0 0 0 / 0.4)",lg:"0 10px 15px -3px rgb(0 0 0 / 0.5)",xl:"0 20px 25px -5px rgb(0 0 0 / 0.6)"}},Fr={colors:{primary:"#FF6B35",secondary:"#1A1A2E",accent:"#16C79A",background:"#FFFFFF",surface:"#F8F9FA",text:"#1A1A2E",textMuted:"#6B7280",border:"#E5E7EB",error:"#EF4444",warning:"#F59E0B",success:"#16C79A",info:"#3B82F6"},fonts:{sans:'"Inter", "Satoshi", system-ui, sans-serif',serif:'"Playfair Display", Georgia, serif',mono:'"JetBrains Mono", monospace'},spacing:{xs:"0.125rem",sm:"0.25rem",md:"0.5rem",lg:"1rem",xl:"1.5rem","2xl":"2rem","3xl":"3rem","4xl":"4rem"},borderRadius:{sm:"0",md:"0",lg:"0",xl:"0",full:"9999px"},shadows:{sm:"0 1px 2px rgba(0,0,0,0.05)",md:"0 4px 6px rgba(0,0,0,0.07)",lg:"0 10px 15px rgba(0,0,0,0.1)",xl:"0 20px 25px rgba(0,0,0,0.15)"}};function Ue(s){let e=[];if(s.colors)for(let[t,r]of Object.entries(s.colors))e.push(` --color-${t}: ${r};`);if(s.fonts)for(let[t,r]of Object.entries(s.fonts))e.push(` --font-${t}: ${r};`);if(s.spacing)for(let[t,r]of Object.entries(s.spacing))e.push(` --spacing-${t}: ${r};`);if(s.borderRadius)for(let[t,r]of Object.entries(s.borderRadius))e.push(` --radius-${t}: ${r};`);if(s.shadows)for(let[t,r]of Object.entries(s.shadows))e.push(` --shadow-${t}: ${r};`);return `:root {
|
|
11
11
|
${e.join(`
|
|
12
12
|
`)}
|
|
13
|
-
}`}function
|
|
13
|
+
}`}function Mr(s){let e=Ue(s.theme||O),t=[];if(s.componentOverrides)for(let[r,o]of Object.entries(s.componentOverrides)){let n=Object.entries(o).map(([i,a])=>` ${i}: ${a};`).join(`
|
|
14
14
|
`);t.push(`${r} {
|
|
15
|
-
${
|
|
15
|
+
${n}
|
|
16
16
|
}`);}return `
|
|
17
17
|
${e}
|
|
18
|
-
${
|
|
18
|
+
${s.customStyles||""}
|
|
19
19
|
${t.join(`
|
|
20
20
|
`)}
|
|
21
|
-
`}var Jr={text:{wrapper:{marginBottom:"var(--spacing-md)"},label:{display:"block",marginBottom:"var(--spacing-xs)",fontWeight:"500",color:"var(--color-text)"},input:{width:"100%",padding:"var(--spacing-sm) var(--spacing-md)",border:"1px solid var(--color-border)",borderRadius:"var(--radius-md)",fontSize:"0.875rem"},error:{color:"var(--color-error)",fontSize:"0.75rem",marginTop:"var(--spacing-xs)"}},number:{wrapper:{marginBottom:"var(--spacing-md)"},label:{display:"block",marginBottom:"var(--spacing-xs)",fontWeight:"500"},input:{width:"100%",padding:"var(--spacing-sm) var(--spacing-md)",border:"1px solid var(--color-border)",borderRadius:"var(--radius-md)"}},checkbox:{wrapper:{display:"flex",alignItems:"center",gap:"var(--spacing-sm)"},input:{width:"1rem",height:"1rem"},label:{cursor:"pointer"}},select:{wrapper:{marginBottom:"var(--spacing-md)"},input:{width:"100%",padding:"var(--spacing-sm) var(--spacing-md)",border:"1px solid var(--color-border)",borderRadius:"var(--radius-md)",backgroundColor:"white"}}};g();g();var Xr={maxAttempts:5,lockDuration:9e5,notifyUser:true,notifyAdmin:true,adminNotifyAfter:3},D=class{redis;prefix;config;constructor(e,t={},r="kyro:lockout:"){this.redis=e,this.prefix=r,this.config={...Xr,...t};}lockKey(e){return `${this.prefix}${e}`}historyKey(e){return `${this.prefix}${e}:history`}async checkLockout(e){let t=this.lockKey(e),r=await this.redis.hgetall(t);if(!r||Object.keys(r).length===0)return {locked:false,attemptsRemaining:this.config.maxAttempts,totalAttempts:0};let o=parseInt(r.attempts,10),s=r.lockedUntil?new Date(parseInt(r.lockedUntil,10)):void 0;return s&&s>new Date?{locked:true,attemptsRemaining:0,lockedUntil:s,totalAttempts:o}:s&&s<=new Date?(await this.unlockAccount(e),{locked:false,attemptsRemaining:this.config.maxAttempts,totalAttempts:0}):{locked:false,attemptsRemaining:Math.max(0,this.config.maxAttempts-o),totalAttempts:o}}async recordFailedAttempt(e){let t=this.lockKey(e),r=this.historyKey(e),o=Date.now(),s=await this.redis.hincrby(t,"attempts",1);if(await this.redis.hset(t,"lastAttempt",o.toString()),await this.redis.lpush(r,o.toString()),await this.redis.ltrim(r,0,99),s>=this.config.maxAttempts){let i=new Date(o+this.config.lockDuration);return await this.redis.hset(t,{lockedAt:o.toString(),lockedUntil:i.getTime().toString()}),await this.redis.expire(t,Math.ceil(this.config.lockDuration/1e3)+3600),{locked:true,attemptsRemaining:0,lockedUntil:i,totalAttempts:s}}return {locked:false,attemptsRemaining:Math.max(0,this.config.maxAttempts-s),totalAttempts:s}}async lockAccount(e,t){let r=this.lockKey(e),o=Date.now(),s=t||this.config.lockDuration,i=new Date(o+s),c=this.redis.pipeline();c.hset(r,{attempts:this.config.maxAttempts.toString(),lockedAt:o.toString(),lockedUntil:i.getTime().toString()}),c.expire(r,Math.ceil(s/1e3)+3600),await c.exec();}async unlockAccount(e){let t=this.lockKey(e);await this.redis.del(t);}async resetAttempts(e){let t=this.lockKey(e);(await this.redis.hgetall(t)).lockedAt?await this.redis.hset(t,{attempts:"0",lockedAt:"",lockedUntil:""}):await this.redis.del(t);}async getLockoutHistory(e,t=10){let r=this.historyKey(e);return (await this.redis.lrange(r,0,t-1)).map(s=>new Date(parseInt(s,10)))}async getLockoutStats(e){let t=this.historyKey(e),r=await this.redis.lrange(t,0,-1),o=r.filter((i,c)=>(c+1)%this.config.maxAttempts===0).length,s=await this.redis.hget(this.lockKey(e),"lockedAt");return {totalFailedAttempts:r.length,lockoutCount:o,lastLockout:s?new Date(parseInt(s,10)):null,averageAttemptsBeforeLockout:o>0?this.config.maxAttempts:0}}shouldNotifyAdmin(e){return this.config.notifyAdmin&&e>=this.config.adminNotifyAfter}getConfig(){return {...this.config}}setConfig(e){this.config={...this.config,...e};}};g();var Zr={"auth:login":{window:9e5,max:5},"auth:register":{window:36e5,max:3},"auth:forgot":{window:36e5,max:3},"auth:reset":{window:36e5,max:5},"auth:verify":{window:36e5,max:5},"api:general":{window:6e4,max:100},"api:authenticated":{window:6e4,max:200}},I=class{redis;prefix;limits;userLimits;constructor(e,t,r,o="kyro:ratelimit:"){this.redis=e,this.prefix=o,this.limits={...Zr,...t},this.userLimits=r||{"user:api":{window:6e4,max:500},"user:write":{window:36e5,max:100}};}getKey(e,t){return `${this.prefix}${e}:${t}`}async check(e,t){let r=this.limits[e]||this.limits["api:general"],o=this.getKey(e,t),s=Date.now(),i=s-r.window,c=this.redis.pipeline();c.zremrangebyscore(o,0,i),c.zcard(o),c.zadd(o,s,`${s}:${Math.random()}`),c.expire(o,Math.ceil(r.window/1e3)+1);let f=(await c.exec())?.[1]?.[1]||0;if(f>=r.max){let h=await this.redis.zrange(o,0,0,"WITHSCORES"),u=h.length>1?parseInt(h[1],10)+r.window:s+r.window;return {allowed:false,remaining:0,resetAt:u,retryAfter:Math.ceil((u-s)/1e3)}}return {allowed:true,remaining:r.max-f-1,resetAt:s+r.window}}async checkUser(e,t,r){let o=this.userLimits[e]||this.userLimits["user:api"],s=this.getKey(`user:${e}:${t}`,r),i=Date.now(),c=i-o.window,l=this.redis.pipeline();l.zremrangebyscore(s,0,c),l.zcard(s),l.zadd(s,i,`${i}:${Math.random()}`),l.expire(s,Math.ceil(o.window/1e3)+1);let h=(await l.exec())?.[1]?.[1]||0;if(h>=o.max){let u=await this.redis.zrange(s,0,0,"WITHSCORES"),d=u.length>1?parseInt(u[1],10)+o.window:i+o.window;return {allowed:false,remaining:0,resetAt:d,retryAfter:Math.ceil((d-i)/1e3)}}return {allowed:true,remaining:o.max-h-1,resetAt:i+o.window}}async reset(e,t){let r=this.getKey(e,t);await this.redis.del(r);}async resetUser(e,t,r){let o=this.getKey(`user:${e}:${t}`,r);await this.redis.del(o);}async getStatus(e,t){let r=this.limits[e]||this.limits["api:general"],o=this.getKey(e,t),s=Date.now(),i=s-r.window;await this.redis.zremrangebyscore(o,0,i);let c=await this.redis.zcard(o);return {count:c,limit:r.max,remaining:Math.max(0,r.max-c),resetAt:s+r.window}}setLimit(e,t){this.limits[e]=t;}setUserLimit(e,t){this.userLimits[e]=t;}};g();g();g();var L=class{users=new Map;sessions=new Map;refreshTokens=new Map;emailToUserId=new Map;passwordHistory=new Map;emailVerificationTokens=new Map;passwordResetTokens=new Map;auditLogs=[];externalDb=false;constructor(){}async connect(){}async disconnect(){this.users.clear(),this.sessions.clear(),this.refreshTokens.clear(),this.emailToUserId.clear(),this.passwordHistory.clear();}async createUser(e){let t=randomBytes(16).toString("hex"),r=new Date().toISOString(),o=await this.hashPassword(e.password),s={id:t,name:e.name,email:e.email.toLowerCase(),passwordHash:o,role:e.role||"customer",avatar:e.avatar,tenantId:e.tenantId,metadata:e.metadata,createdAt:r,updatedAt:r};return this.users.set(t,s),this.emailToUserId.set(e.email.toLowerCase(),t),this.passwordHistory.set(t,[]),s}async findUserByEmail(e){let t=this.emailToUserId.get(e.toLowerCase());return t?this.findUserById(t):null}async findUserById(e){return this.users.get(e)||null}async updateUser(e,t){let r=await this.findUserById(e);if(!r)return null;let o={...r,...t,id:e,updatedAt:new Date().toISOString()};return t.email&&t.email!==r.email&&(this.emailToUserId.delete(r.email.toLowerCase()),this.emailToUserId.set(t.email.toLowerCase(),e)),this.users.set(e,o),o}async deleteUser(e){let t=await this.findUserById(e);return t?(this.users.delete(e),this.emailToUserId.delete(t.email.toLowerCase()),this.refreshTokens.forEach((r,o)=>{this.sessions.get(r)?.userId===e&&(this.refreshTokens.delete(o),this.sessions.delete(r));}),this.passwordHistory.delete(e),this.sessions.forEach((r,o)=>{r.userId===e&&this.sessions.delete(o);}),true):false}async hashPassword(e){return (await import('./bcryptjs-ZEEHSMAG.js')).default.hash(e,12)}async verifyPassword(e,t){let r=await this.findUserByEmail(e);return !r||!r.passwordHash?null:await(await import('./bcryptjs-ZEEHSMAG.js')).default.compare(t,r.passwordHash)?r:null}async createSession(e,t={}){let r=randomBytes(32).toString("hex"),o=randomBytes(32).toString("base64url"),s=randomBytes(32).toString("base64url"),i=new Date,c={id:r,userId:e,token:o,refreshToken:s,expiresAt:new Date(i.getTime()+86400*1e3).toISOString(),createdAt:i.toISOString(),ipAddress:t.ipAddress,userAgent:t.userAgent};return this.sessions.set(r,c),this.refreshTokens.set(s,r),c}async findSessionByToken(e){return this.sessions.get(e)||null}async findSessionByRefreshToken(e){let t=this.refreshTokens.get(e);return t&&this.sessions.get(t)||null}async deleteSession(e){let t=this.sessions.get(e);return t?(t.refreshToken&&this.refreshTokens.delete(t.refreshToken),this.sessions.delete(e),true):false}async deleteUserSessions(e){let t=0;return this.sessions.forEach((r,o)=>{r.userId===e&&(r.refreshToken&&this.refreshTokens.delete(r.refreshToken),this.sessions.delete(o),t++);}),t}async addPasswordToHistory(e,t){let r=this.passwordHistory.get(e)||[];r.push(t),r.length>5&&r.splice(0,r.length-5),this.passwordHistory.set(e,r);}async getPasswordHistory(e,t=5){return this.passwordHistory.get(e)||[]}async isPasswordInHistory(e,t,r=5){let o=await this.getPasswordHistory(t,r),s=(await import('./bcryptjs-ZEEHSMAG.js')).default;for(let i of o)if(await s.compare(e,i))return true;return false}async createEmailVerificationToken(e){let t=randomBytes(32).toString("hex"),r=new Date(Date.now()+1440*60*1e3);return this.emailVerificationTokens.set(t,{userId:e,expiresAt:r}),{token:t,expiresAt:r}}async verifyEmailToken(e){let t=this.emailVerificationTokens.get(e);return !t||t.expiresAt<new Date?(this.emailVerificationTokens.delete(e),{success:false,error:"Invalid or expired token"}):(this.emailVerificationTokens.delete(e),{success:true,userId:t.userId})}async createPasswordResetToken(e){let t=await this.findUserByEmail(e);if(!t)return {token:"",expiresAt:new Date,error:"User not found"};let r=randomBytes(32).toString("hex"),o=new Date(Date.now()+3600*1e3);return this.passwordResetTokens.set(r,{userId:t.id,expiresAt:o}),{token:r,expiresAt:o}}async resetPasswordWithToken(e,t){let r=this.passwordResetTokens.get(e);if(!r||r.expiresAt<new Date)return this.passwordResetTokens.delete(e),{success:false,error:"Invalid or expired token"};let o=await this.hashPassword(t);return await this.updateUser(r.userId,{passwordHash:o}),this.passwordResetTokens.delete(e),{success:true}}async hasAnyUsers(){return this.users.size>0}async findAuditLogs(e){let{limit:t=50,offset:r=0}=e,o=this.auditLogs.slice().reverse();return e.userId&&(o=o.filter(s=>s.userId===e.userId)),e.action&&(Array.isArray(e.action)?o=o.filter(s=>e.action.includes(String(s.action))):o=o.filter(s=>s.action===e.action)),e.resource&&(o=o.filter(s=>s.resource===e.resource)),e.success!==void 0&&(o=o.filter(s=>s.success===e.success)),{logs:o.slice(r,r+t),total:o.length}}async createAuditLog(e){let t=randomBytes(16).toString("hex"),o={...e,id:t,timestamp:new Date};return this.auditLogs.push(o),o}};g();var E=class{storage=new Map;history=new Map;config;constructor(e={}){this.config={maxAttempts:5,lockDuration:9e5,notifyUser:true,notifyAdmin:true,adminNotifyAfter:3,...e};}async checkLockout(e){let t=Date.now(),r=this.storage.get(e);if(r&&r.lockedUntil!==null&&r.lockedUntil<=t)return await this.resetAttempts(e),{locked:false,attemptsRemaining:this.config.maxAttempts,totalAttempts:0};if(!r)return {locked:false,attemptsRemaining:this.config.maxAttempts,totalAttempts:0};let{attempts:o,lockedUntil:s}=r;return s!==null&&s>t?{locked:true,attemptsRemaining:0,lockedUntil:new Date(s),totalAttempts:o}:{locked:false,attemptsRemaining:Math.max(0,this.config.maxAttempts-o),totalAttempts:o}}async recordFailedAttempt(e){let t=Date.now(),r=this.storage.get(e)||{attempts:0,lastAttempt:null,lockedAt:null,lockedUntil:null};r.attempts+=1,r.lastAttempt=t;let o=this.history.get(e)||[];if(o.push(t),o.length>100&&o.splice(0,o.length-100),this.history.set(e,o),this.storage.set(e,r),r.attempts>=this.config.maxAttempts){let s=new Date(t+this.config.lockDuration);return r.lockedAt=t,r.lockedUntil=s.getTime(),this.storage.set(e,r),{locked:true,attemptsRemaining:0,lockedUntil:s,totalAttempts:r.attempts}}return {locked:false,attemptsRemaining:Math.max(0,this.config.maxAttempts-r.attempts),totalAttempts:r.attempts}}async lockAccount(e,t){let r=Date.now(),o=t||this.config.lockDuration,s=new Date(r+o),i=this.storage.get(e)||{attempts:0,lastAttempt:null,lockedAt:null,lockedUntil:null};i.attempts=this.config.maxAttempts,i.lockedAt=r,i.lockedUntil=s.getTime(),this.storage.set(e,i);}async unlockAccount(e){await this.resetAttempts(e);}async resetAttempts(e){let t=this.storage.get(e);t&&(t.attempts=0,t.lockedAt=null,t.lockedUntil=null,this.storage.set(e,t)),this.history.delete(e);}async getLockoutHistory(e,t=10){return (this.history.get(e)||[]).slice(-t).reverse().map(o=>new Date(o))}async getLockoutStats(e){let r=(this.history.get(e)||[]).length,o=Math.floor(r/this.config.maxAttempts),s=null,i=this.storage.get(e);i&&i.lockedAt!==null&&(s=new Date(i.lockedAt));let c=o>0?this.config.maxAttempts:0;return {totalFailedAttempts:r,lockoutCount:o,lastLockout:s,averageAttemptsBeforeLockout:c}}shouldNotifyAdmin(e){return this.config.notifyAdmin&&e>=this.config.adminNotifyAfter}getConfig(){return {...this.config}}setConfig(e){this.config={...this.config,...e};}};function x(n,e=""){return process.env[n]||e}function P(n,e=false){let t=process.env[n];return t?t.toLowerCase()==="true":e}function w(n,e=0){let t=process.env[n];return t?parseInt(t,10):e}function je(){let n=process.env.KYRO_AUTH_DATABASE?.toLowerCase();if(n&&["sqlite","postgres","mongodb","memory"].includes(n))return n;try{let e=join(process.cwd(),"kyro.config.ts"),t=readFileSync(e,"utf8");if(t.includes("createLocalAdapter"))return "sqlite";if(t.includes("createDrizzleAdapter"))return t.includes("postgres")||t.includes("postgresql"),"postgres";if(t.includes("createMongoDBAdapter"))return "mongodb"}catch{}return "memory"}async function ro(n){let e=process.cwd(),t=e.endsWith("admin")?join(e,".."):e,r=resolve(t,"data","auth.db");switch(n){case "sqlite":return new a$3({path:x("KYRO_AUTH_DB_PATH",r)});case "postgres":{let o=x("DATABASE_URL","");if(o){let s,i;try{s=(await import('./postgres-js-JLFIWOBH.js')).drizzle,i=await import('./src-QBADSZV4.js');}catch{a$1(["postgres","drizzle-orm"]),s=(await import('./postgres-js-JLFIWOBH.js')).drizzle,i=await import('./src-QBADSZV4.js');}let c=i.default(o,{onnotice:()=>{}}),l=s(c);return new a$4({db:l})}return new a$3({path:x("KYRO_AUTH_DB_PATH",r)})}case "mongodb":{let o=x("MONGODB_URI","");if(o){let s;try{let h=await import('./lib-JQD2JAOO.js');s=h.MongoClient??h.default?.MongoClient;}catch{a$1(["mongodb"]);let u=await import('./lib-JQD2JAOO.js');s=u.MongoClient??u.default?.MongoClient;}let i=new s(o);await i.connect();let l=new URL(o).pathname.replace(/^\//,"")||"kyro_cms",f=i.db(l);return new a$2({db:f})}return new a$3({path:x("KYRO_AUTH_DB_PATH",r)})}default:return new L}}async function J(n,e){let t=P("KYRO_DISTRIBUTED",false),r;if(t){let{RedisAuthAdapter:u}=await import('./redis-adapter-LY2NBSAG.js'),d=x("REDIS_URL","redis://localhost:6379"),A=P("REDIS_TLS",false),p=new u({url:d,tls:A});await p.connect?.(),r=p;}else {let u=n||je();r=await ro(u),r.connect&&await r.connect();}let o=e?await q.fromConfig(e).catch(()=>null)||q.fromEnv()||void 0:q.fromEnv()||void 0,s=new a({minLength:w("PASSWORD_MIN_LENGTH",12),requireUppercase:P("PASSWORD_REQUIRE_UPPERCASE",true),requireLowercase:P("PASSWORD_REQUIRE_LOWERCASE",true),requireNumbers:P("PASSWORD_REQUIRE_NUMBERS",true),requireSpecialChars:P("PASSWORD_REQUIRE_SPECIAL",true),preventReuse:w("PASSWORD_PREVENT_REUSE",5),maxLength:w("PASSWORD_MAX_LENGTH",128)}),i,c,l;if(t){let d=r.redis;i=new D(d,{maxAttempts:w("LOCKOUT_MAX_ATTEMPTS",5),lockDuration:w("LOCKOUT_DURATION_MINUTES",15)*60*1e3}),c=new I(d,{"auth:login":{window:w("RATE_LIMIT_AUTH_WINDOW_MS",9e5),max:w("RATE_LIMIT_AUTH_MAX_REQUESTS",10)},"api:general":{window:w("RATE_LIMIT_WINDOW_MS",6e4),max:w("RATE_LIMIT_MAX_REQUESTS",100)}}),l=new bb(d,w("AUDIT_LOG_RETENTION_DAYS",30));}else i=new E({maxAttempts:w("LOCKOUT_MAX_ATTEMPTS",5),lockDuration:w("LOCKOUT_DURATION_MINUTES",15)*60*1e3}),c=new ab({"auth:login":{window:w("RATE_LIMIT_AUTH_WINDOW_MS",9e5),max:w("RATE_LIMIT_AUTH_MAX_REQUESTS",10)},"api:general":{window:w("RATE_LIMIT_WINDOW_MS",6e4),max:w("RATE_LIMIT_MAX_REQUESTS",100)}}),l=P("AUDIT_LOG_ENABLED",true)?new db(w("AUDIT_LOG_RETENTION_DAYS",30)):void 0;let f=new eb({redis:r,email:o,jwtSecret:x("APP_SECRET","change-me"),jwtExpiresIn:x("JWT_EXPIRES_IN","24h"),jwtIssuer:x("JWT_ISSUER","kyro-cms"),jwtAudience:x("JWT_AUDIENCE","kyro-cms-client"),passwordPolicy:s,lockout:i,rateLimiter:c,auditLogger:l,baseUrl:x("EMAIL_BASE_URL","http://localhost:4321"),emailVerificationRequired:P("EMAIL_VERIFICATION_REQUIRED",true)}),h=t?"distributed":n||je();return {authAdapter:r,databaseType:h,email:o,passwordPolicy:s,lockout:i,rateLimiter:c,auditLogger:l,routes:f}}var We=J().catch(n=>(console.warn("[AuthConfig] Failed to initialize auth config:",n.message),null));var oo=12,no="24h",so="7d",K=class{adapter;config;constructor(e,t){this.adapter=e,this.config={secret:t.secret,expiresIn:t.expiresIn??no,refreshExpiresIn:t.refreshExpiresIn??so,issuer:t.issuer??"kyro-cms",audience:t.audience??[],saltRounds:t.saltRounds??oo};}async register(e){try{if(await this.adapter.findUserByEmail(e.email))return {success:!1,error:"Email already registered"};let r=await this.adapter.createUser({email:e.email,password:e.password,role:e.role??"customer",tenantId:e.tenantId});return this.createSessionForUser(r)}catch(t){return {success:false,error:String(t)}}}async login(e){try{let t=await this.adapter.verifyPassword(e.email,e.password);return t?this.createSessionForUser(t):{success:!1,error:"Invalid credentials"}}catch(t){return {success:false,error:String(t)}}}async logout(e){await this.adapter.deleteSession(e);}async refreshToken(e){try{let t=await this.adapter.findSessionByToken(e);if(!t||new Date(t.expiresAt)<new Date)return {success:!1,error:"Invalid or expired refresh token"};let r=await this.adapter.findUserById(t.userId);return r?(await this.adapter.deleteSession(e),this.createSessionForUser(r)):{success:!1,error:"User not found"}}catch(t){return {success:false,error:String(t)}}}async verifyToken(e){try{let{default:t}=await import('./jsonwebtoken-OD67R5JS.js');return t.verify(e,this.config.secret,{issuer:this.config.issuer,audience:this.config.audience.length>0?this.config.audience[0]:void 0})}catch{return null}}async getUserFromToken(e){let t=await this.verifyToken(e);return t?this.adapter.findUserById(t.sub):null}async changePassword(e,t,r){try{let o=await this.adapter.findUserById(e);return o?await this.adapter.verifyPassword(o.email,t)?(await this.adapter.updateUser(e,{password:r}),await this.adapter.deleteUserSessions(e),{success:!0,user:o}):{success:!1,error:"Current password is incorrect"}:{success:!1,error:"User not found"}}catch(o){return {success:false,error:String(o)}}}async resetPassword(e,t){try{let r=await this.adapter.findUserByEmail(e);return r?(await this.adapter.updateUser(r.id,{password:t}),await this.adapter.deleteUserSessions(r.id),{success:!0,user:r}):{success:!1,error:"User not found"}}catch(r){return {success:false,error:String(r)}}}async sendEmailVerification(e){try{let{token:t,expiresAt:r}=await this.adapter.createEmailVerificationToken(e);return {success:!0}}catch(t){return {success:false,error:String(t)}}}async verifyEmail(e){try{return await this.adapter.verifyEmailToken(e)}catch(t){return {success:false,error:String(t)}}}async requestPasswordReset(e){try{let t=await this.adapter.createPasswordResetToken(e);return t.error?{success:!1,error:t.error}:{success:!0}}catch(t){return {success:false,error:String(t)}}}async resetPasswordWithToken(e,t){try{return await this.adapter.resetPasswordWithToken(e,t)}catch(r){return {success:false,error:String(r)}}}async deleteAccount(e){try{return await this.adapter.findUserById(e)?(await this.adapter.deleteUserSessions(e),await this.adapter.deleteUser(e),{success:!0}):{success:!1,error:"User not found"}}catch(t){return {success:false,error:String(t)}}}async createSessionForUser(e){let t=await this.generateToken(e),r=await this.adapter.createSession(e.id);return {success:true,user:e,session:r,token:t}}async generateToken(e){let{default:t}=await import('./jsonwebtoken-OD67R5JS.js'),r={sub:e.id,email:e.email,role:e.role,tenantId:e.tenantId},o={expiresIn:this.parseExpiresIn(this.config.expiresIn)/1e3,issuer:this.config.issuer};return this.config.audience.length>0&&(o.audience=this.config.audience[0]),t.sign(r,this.config.secret,o)}async hashPassword(e){let{default:t}=await import('./bcryptjs-ZEEHSMAG.js');return t.hash(e,this.config.saltRounds)}parseExpiresIn(e){if(typeof e=="number")return e;let t=e.match(/^(\d+)([smhd])$/);if(!t)return 864e5;let r=parseInt(t[1],10);switch(t[2]){case "s":return r*1e3;case "m":return r*6e4;case "h":return r*36e5;case "d":return r*864e5;default:return 864e5}}};function io(n,e){return new K(n,e)}g();g();function j(){return {enabled:true,draftsEnabled:true,publishEnabled:true,scheduleEnabled:false,versioningEnabled:true,maxVersionsPerDocument:50,autoPublish:false,requirePublishPermission:true}}var z=class{adapter;config;constructor(e,t){this.adapter=e,this.config={...j(),...t};}async createVersion(e){let r=((await this.adapter.getLatestVersion(e.collection,e.documentId))?.version??0)+1,o={...e,version:r},s=await this.adapter.createVersion(o);return this.config.maxVersionsPerDocument>0&&await this.pruneOldVersions(e.collection,e.documentId),s}async publishVersion(e){let t=await this.adapter.getVersion(e.collection,e.versionId);if(!t)throw new Error("Version not found");if(t.status==="published")throw new Error("Version is already published");await this.adapter.publishVersion(e);}async unpublishDocument(e,t){let r=await this.adapter.getVersions({collection:e,documentId:t,limit:1e3});for(let o of r)if(o.status==="published"){await this.createVersion({collection:e,documentId:t,data:o.data,status:"draft",createdBy:"system",changeDescription:"Unpublished document"});break}}async revertToVersion(e,t,r,o){if(!await this.adapter.getVersion(e,r))throw new Error("Version not found");return await this.adapter.revertToVersion({collection:e,documentId:t,versionId:r,userId:o})}async getVersionHistory(e,t,r=20,o=0){return this.adapter.getVersions({collection:e,documentId:t,limit:r,offset:o})}async compareTwoVersions(e,t,r,o){return this.adapter.compareVersions({collection:e,documentId:t,versionA:r,versionB:o})}async getLatestDraft(e,t){return this.adapter.getLatestVersion(e,t)}async getPublishedVersion(e,t){return this.adapter.getPublishedVersion(e,t)}async getVersion(e,t){return this.adapter.getVersion(e,t)}async schedulePublish(e,t,r,o){if(!this.config.scheduleEnabled)throw new Error("Scheduled publishing is not enabled");if(!await this.adapter.getVersion(e,r))throw new Error("Version not found")}async deleteVersionHistory(e,t){await this.adapter.deleteVersions(e,t);}async pruneOldVersions(e,t){let r=await this.adapter.getVersions({collection:e,documentId:t,limit:this.config.maxVersionsPerDocument+100});if(r.length<=this.config.maxVersionsPerDocument)return;r.slice(0,this.config.maxVersionsPerDocument);let s=r.slice(this.config.maxVersionsPerDocument);for(let i of s)if(i.status!=="published"){await this.adapter.deleteVersions(e,t);break}}};function ao(n,e){return new z(n,e)}function co(n){return n==="published"}function lo(n){return n==="draft"}function uo(n){return n==="archived"}g();function po(n){return n?Array.isArray(n)?n:Object.values(n):[]}function go(n){return n?Array.isArray(n)?n:Object.values(n):[]}function qe(n){return {collections:po(n.collections),globals:go(n.globals),adapter:n.adapter,storage:n.storage,plugins:n.plugins,auth:n.auth,cors:n.cors,admin:n.admin,upload:n.upload,graphQL:n.graphQL,typescript:n.typescript,localization:n.localization,rateLimit:n.rateLimit,debug:n.debug}}var mo=qe;g();function fo(n){let{siteSettings:e,seoSettings:t,title:r,description:o,image:s,url:i}=n;if(!e)return "";let c=e.siteName||"",l=r||t?.defaultTitle||c,f=t?.titleTemplate,h=t?.separator||" | ",u=t?.siteNameInTitle!==false,d=f?f.replace(/\{\{title\}\}/g,l).replace(/\{\{siteName\}\}/g,u?c:"").replace(/\{\{separator\}\}/g,h).replace(/\s+/g," ").trim():l,A=o||t?.defaultDescription||e.siteDescription||"",p=s||e.siteOgImage?.url||"",y=i||e.siteUrl||"",b=`
|
|
22
|
-
<title>${
|
|
23
|
-
<meta name="description" content="${
|
|
24
|
-
`;e.siteFavicon?.url&&(
|
|
25
|
-
<link rel="icon" type="${e.siteFavicon.mimeType||"image/x-icon"}" href="${e.siteFavicon.url}">`);let
|
|
26
|
-
<meta name="robots" content="${
|
|
27
|
-
<link rel="canonical" href="${
|
|
28
|
-
<meta property="og:type" content="${
|
|
29
|
-
<meta property="og:title" content="${
|
|
30
|
-
<meta property="og:description" content="${
|
|
31
|
-
<meta property="og:site_name" content="${
|
|
32
|
-
`,
|
|
33
|
-
<meta property="og:url" content="${
|
|
34
|
-
<meta property="og:image" content="${p}">`),t?.social?.fbAppId&&(
|
|
35
|
-
<meta property="fb:app_id" content="${t.social.fbAppId}">`);let
|
|
36
|
-
<meta name="twitter:card" content="${
|
|
37
|
-
<meta name="twitter:title" content="${
|
|
38
|
-
<meta name="twitter:description" content="${
|
|
39
|
-
`,t?.social?.twitterHandle&&(
|
|
40
|
-
<meta name="twitter:site" content="${t.social.twitterHandle}">`),p&&(
|
|
41
|
-
<meta name="twitter:image" content="${p}">`),e.enableI18n&&e.i18n?.language&&(
|
|
42
|
-
<meta http-equiv="content-language" content="${e.i18n.language}">`),
|
|
21
|
+
`}var _r={text:{wrapper:{marginBottom:"var(--spacing-md)"},label:{display:"block",marginBottom:"var(--spacing-xs)",fontWeight:"500",color:"var(--color-text)"},input:{width:"100%",padding:"var(--spacing-sm) var(--spacing-md)",border:"1px solid var(--color-border)",borderRadius:"var(--radius-md)",fontSize:"0.875rem"},error:{color:"var(--color-error)",fontSize:"0.75rem",marginTop:"var(--spacing-xs)"}},number:{wrapper:{marginBottom:"var(--spacing-md)"},label:{display:"block",marginBottom:"var(--spacing-xs)",fontWeight:"500"},input:{width:"100%",padding:"var(--spacing-sm) var(--spacing-md)",border:"1px solid var(--color-border)",borderRadius:"var(--radius-md)"}},checkbox:{wrapper:{display:"flex",alignItems:"center",gap:"var(--spacing-sm)"},input:{width:"1rem",height:"1rem"},label:{cursor:"pointer"}},select:{wrapper:{marginBottom:"var(--spacing-md)"},input:{width:"100%",padding:"var(--spacing-sm) var(--spacing-md)",border:"1px solid var(--color-border)",borderRadius:"var(--radius-md)",backgroundColor:"white"}}};var Hr={maxAttempts:5,lockDuration:9e5,notifyUser:true,notifyAdmin:true,adminNotifyAfter:3},C=class{redis;prefix;config;constructor(e,t={},r="kyro:lockout:"){this.redis=e,this.prefix=r,this.config={...Hr,...t};}lockKey(e){return `${this.prefix}${e}`}historyKey(e){return `${this.prefix}${e}:history`}async checkLockout(e){let t=this.lockKey(e),r=await this.redis.hgetall(t);if(!r||Object.keys(r).length===0)return {locked:false,attemptsRemaining:this.config.maxAttempts,totalAttempts:0};let o=parseInt(r.attempts,10),n=r.lockedUntil?new Date(parseInt(r.lockedUntil,10)):void 0;return n&&n>new Date?{locked:true,attemptsRemaining:0,lockedUntil:n,totalAttempts:o}:n&&n<=new Date?(await this.unlockAccount(e),{locked:false,attemptsRemaining:this.config.maxAttempts,totalAttempts:0}):{locked:false,attemptsRemaining:Math.max(0,this.config.maxAttempts-o),totalAttempts:o}}async recordFailedAttempt(e){let t=this.lockKey(e),r=this.historyKey(e),o=Date.now(),n=await this.redis.hincrby(t,"attempts",1);if(await this.redis.hset(t,"lastAttempt",o.toString()),await this.redis.lpush(r,o.toString()),await this.redis.ltrim(r,0,99),n>=this.config.maxAttempts){let i=new Date(o+this.config.lockDuration);return await this.redis.hset(t,{lockedAt:o.toString(),lockedUntil:i.getTime().toString()}),await this.redis.expire(t,Math.ceil(this.config.lockDuration/1e3)+3600),{locked:true,attemptsRemaining:0,lockedUntil:i,totalAttempts:n}}return {locked:false,attemptsRemaining:Math.max(0,this.config.maxAttempts-n),totalAttempts:n}}async lockAccount(e,t){let r=this.lockKey(e),o=Date.now(),n=t||this.config.lockDuration,i=new Date(o+n),a=this.redis.pipeline();a.hset(r,{attempts:this.config.maxAttempts.toString(),lockedAt:o.toString(),lockedUntil:i.getTime().toString()}),a.expire(r,Math.ceil(n/1e3)+3600),await a.exec();}async unlockAccount(e){let t=this.lockKey(e);await this.redis.del(t);}async resetAttempts(e){let t=this.lockKey(e);(await this.redis.hgetall(t)).lockedAt?await this.redis.hset(t,{attempts:"0",lockedAt:"",lockedUntil:""}):await this.redis.del(t);}async getLockoutHistory(e,t=10){let r=this.historyKey(e);return (await this.redis.lrange(r,0,t-1)).map(n=>new Date(parseInt(n,10)))}async getLockoutStats(e){let t=this.historyKey(e),r=await this.redis.lrange(t,0,-1),o=r.filter((i,a)=>(a+1)%this.config.maxAttempts===0).length,n=await this.redis.hget(this.lockKey(e),"lockedAt");return {totalFailedAttempts:r.length,lockoutCount:o,lastLockout:n?new Date(parseInt(n,10)):null,averageAttemptsBeforeLockout:o>0?this.config.maxAttempts:0}}shouldNotifyAdmin(e){return this.config.notifyAdmin&&e>=this.config.adminNotifyAfter}getConfig(){return {...this.config}}setConfig(e){this.config={...this.config,...e};}};var Br={"auth:login":{window:9e5,max:5},"auth:register":{window:36e5,max:3},"auth:forgot":{window:36e5,max:3},"auth:reset":{window:36e5,max:5},"auth:verify":{window:36e5,max:5},"api:general":{window:6e4,max:100},"api:authenticated":{window:6e4,max:200}},R=class{redis;prefix;limits;userLimits;constructor(e,t,r,o="kyro:ratelimit:"){this.redis=e,this.prefix=o,this.limits={...Br,...t},this.userLimits=r||{"user:api":{window:6e4,max:500},"user:write":{window:36e5,max:100}};}getKey(e,t){return `${this.prefix}${e}:${t}`}async check(e,t){let r=this.limits[e]||this.limits["api:general"],o=this.getKey(e,t),n=Date.now(),i=n-r.window,a=this.redis.pipeline();a.zremrangebyscore(o,0,i),a.zcard(o),a.zadd(o,n,`${n}:${Math.random()}`),a.expire(o,Math.ceil(r.window/1e3)+1);let u=(await a.exec())?.[1]?.[1]||0;if(u>=r.max){let f=await this.redis.zrange(o,0,0,"WITHSCORES"),d=f.length>1?parseInt(f[1],10)+r.window:n+r.window;return {allowed:false,remaining:0,resetAt:d,retryAfter:Math.ceil((d-n)/1e3)}}return {allowed:true,remaining:r.max-u-1,resetAt:n+r.window}}async checkUser(e,t,r){let o=this.userLimits[e]||this.userLimits["user:api"],n=this.getKey(`user:${e}:${t}`,r),i=Date.now(),a=i-o.window,c=this.redis.pipeline();c.zremrangebyscore(n,0,a),c.zcard(n),c.zadd(n,i,`${i}:${Math.random()}`),c.expire(n,Math.ceil(o.window/1e3)+1);let f=(await c.exec())?.[1]?.[1]||0;if(f>=o.max){let d=await this.redis.zrange(n,0,0,"WITHSCORES"),l=d.length>1?parseInt(d[1],10)+o.window:i+o.window;return {allowed:false,remaining:0,resetAt:l,retryAfter:Math.ceil((l-i)/1e3)}}return {allowed:true,remaining:o.max-f-1,resetAt:i+o.window}}async reset(e,t){let r=this.getKey(e,t);await this.redis.del(r);}async resetUser(e,t,r){let o=this.getKey(`user:${e}:${t}`,r);await this.redis.del(o);}async getStatus(e,t){let r=this.limits[e]||this.limits["api:general"],o=this.getKey(e,t),n=Date.now(),i=n-r.window;await this.redis.zremrangebyscore(o,0,i);let a=await this.redis.zcard(o);return {count:a,limit:r.max,remaining:Math.max(0,r.max-a),resetAt:n+r.window}}setLimit(e,t){this.limits[e]=t;}setUserLimit(e,t){this.userLimits[e]=t;}};var v=class{users=new Map;sessions=new Map;refreshTokens=new Map;emailToUserId=new Map;passwordHistory=new Map;emailVerificationTokens=new Map;passwordResetTokens=new Map;auditLogs=[];externalDb=false;constructor(){}async connect(){}async disconnect(){this.users.clear(),this.sessions.clear(),this.refreshTokens.clear(),this.emailToUserId.clear(),this.passwordHistory.clear();}async createUser(e){let t=randomBytes(16).toString("hex"),r=new Date().toISOString(),o=await this.hashPassword(e.password),n={id:t,name:e.name,email:e.email.toLowerCase(),passwordHash:o,role:e.role||"customer",avatar:e.avatar,tenantId:e.tenantId,metadata:e.metadata,createdAt:r,updatedAt:r};return this.users.set(t,n),this.emailToUserId.set(e.email.toLowerCase(),t),this.passwordHistory.set(t,[]),n}async findUserByEmail(e){let t=this.emailToUserId.get(e.toLowerCase());return t?this.findUserById(t):null}async findUserById(e){return this.users.get(e)||null}async updateUser(e,t){let r=await this.findUserById(e);if(!r)return null;let o={...r,...t,id:e,updatedAt:new Date().toISOString()};return t.email&&t.email!==r.email&&(this.emailToUserId.delete(r.email.toLowerCase()),this.emailToUserId.set(t.email.toLowerCase(),e)),this.users.set(e,o),o}async deleteUser(e){let t=await this.findUserById(e);return t?(this.users.delete(e),this.emailToUserId.delete(t.email.toLowerCase()),this.refreshTokens.forEach((r,o)=>{this.sessions.get(r)?.userId===e&&(this.refreshTokens.delete(o),this.sessions.delete(r));}),this.passwordHistory.delete(e),this.sessions.forEach((r,o)=>{r.userId===e&&this.sessions.delete(o);}),true):false}async hashPassword(e){return (await import('bcryptjs')).default.hash(e,12)}async verifyPassword(e,t){let r=await this.findUserByEmail(e);return !r||!r.passwordHash?null:await(await import('bcryptjs')).default.compare(t,r.passwordHash)?r:null}async createSession(e,t={}){let r=randomBytes(32).toString("hex"),o=randomBytes(32).toString("base64url"),n=randomBytes(32).toString("base64url"),i=new Date,a={id:r,userId:e,token:o,refreshToken:n,expiresAt:new Date(i.getTime()+86400*1e3).toISOString(),createdAt:i.toISOString(),ipAddress:t.ipAddress,userAgent:t.userAgent};return this.sessions.set(r,a),this.refreshTokens.set(n,r),a}async findSessionByToken(e){return this.sessions.get(e)||null}async findSessionByRefreshToken(e){let t=this.refreshTokens.get(e);return t&&this.sessions.get(t)||null}async deleteSession(e){let t=this.sessions.get(e);return t?(t.refreshToken&&this.refreshTokens.delete(t.refreshToken),this.sessions.delete(e),true):false}async deleteUserSessions(e){let t=0;return this.sessions.forEach((r,o)=>{r.userId===e&&(r.refreshToken&&this.refreshTokens.delete(r.refreshToken),this.sessions.delete(o),t++);}),t}async addPasswordToHistory(e,t){let r=this.passwordHistory.get(e)||[];r.push(t),r.length>5&&r.splice(0,r.length-5),this.passwordHistory.set(e,r);}async getPasswordHistory(e,t=5){return this.passwordHistory.get(e)||[]}async isPasswordInHistory(e,t,r=5){let o=await this.getPasswordHistory(t,r),n=(await import('bcryptjs')).default;for(let i of o)if(await n.compare(e,i))return true;return false}async createEmailVerificationToken(e){let t=randomBytes(32).toString("hex"),r=new Date(Date.now()+1440*60*1e3);return this.emailVerificationTokens.set(t,{userId:e,expiresAt:r}),{token:t,expiresAt:r}}async verifyEmailToken(e){let t=this.emailVerificationTokens.get(e);return !t||t.expiresAt<new Date?(this.emailVerificationTokens.delete(e),{success:false,error:"Invalid or expired token"}):(this.emailVerificationTokens.delete(e),{success:true,userId:t.userId})}async createPasswordResetToken(e){let t=await this.findUserByEmail(e);if(!t)return {token:"",expiresAt:new Date,error:"User not found"};let r=randomBytes(32).toString("hex"),o=new Date(Date.now()+3600*1e3);return this.passwordResetTokens.set(r,{userId:t.id,expiresAt:o}),{token:r,expiresAt:o}}async resetPasswordWithToken(e,t){let r=this.passwordResetTokens.get(e);if(!r||r.expiresAt<new Date)return this.passwordResetTokens.delete(e),{success:false,error:"Invalid or expired token"};let o=await this.hashPassword(t);return await this.updateUser(r.userId,{passwordHash:o}),this.passwordResetTokens.delete(e),{success:true}}async hasAnyUsers(){return this.users.size>0}async findAuditLogs(e){let{limit:t=50,offset:r=0}=e,o=this.auditLogs.slice().reverse();return e.userId&&(o=o.filter(n=>n.userId===e.userId)),e.action&&(Array.isArray(e.action)?o=o.filter(n=>e.action.includes(String(n.action))):o=o.filter(n=>n.action===e.action)),e.resource&&(o=o.filter(n=>n.resource===e.resource)),e.success!==void 0&&(o=o.filter(n=>n.success===e.success)),{logs:o.slice(r,r+t),total:o.length}}async createAuditLog(e){let t=randomBytes(16).toString("hex"),o={...e,id:t,timestamp:new Date};return this.auditLogs.push(o),o}};var D=class{storage=new Map;history=new Map;config;constructor(e={}){this.config={maxAttempts:5,lockDuration:9e5,notifyUser:true,notifyAdmin:true,adminNotifyAfter:3,...e};}async checkLockout(e){let t=Date.now(),r=this.storage.get(e);if(r&&r.lockedUntil!==null&&r.lockedUntil<=t)return await this.resetAttempts(e),{locked:false,attemptsRemaining:this.config.maxAttempts,totalAttempts:0};if(!r)return {locked:false,attemptsRemaining:this.config.maxAttempts,totalAttempts:0};let{attempts:o,lockedUntil:n}=r;return n!==null&&n>t?{locked:true,attemptsRemaining:0,lockedUntil:new Date(n),totalAttempts:o}:{locked:false,attemptsRemaining:Math.max(0,this.config.maxAttempts-o),totalAttempts:o}}async recordFailedAttempt(e){let t=Date.now(),r=this.storage.get(e)||{attempts:0,lastAttempt:null,lockedAt:null,lockedUntil:null};r.attempts+=1,r.lastAttempt=t;let o=this.history.get(e)||[];if(o.push(t),o.length>100&&o.splice(0,o.length-100),this.history.set(e,o),this.storage.set(e,r),r.attempts>=this.config.maxAttempts){let n=new Date(t+this.config.lockDuration);return r.lockedAt=t,r.lockedUntil=n.getTime(),this.storage.set(e,r),{locked:true,attemptsRemaining:0,lockedUntil:n,totalAttempts:r.attempts}}return {locked:false,attemptsRemaining:Math.max(0,this.config.maxAttempts-r.attempts),totalAttempts:r.attempts}}async lockAccount(e,t){let r=Date.now(),o=t||this.config.lockDuration,n=new Date(r+o),i=this.storage.get(e)||{attempts:0,lastAttempt:null,lockedAt:null,lockedUntil:null};i.attempts=this.config.maxAttempts,i.lockedAt=r,i.lockedUntil=n.getTime(),this.storage.set(e,i);}async unlockAccount(e){await this.resetAttempts(e);}async resetAttempts(e){let t=this.storage.get(e);t&&(t.attempts=0,t.lockedAt=null,t.lockedUntil=null,this.storage.set(e,t)),this.history.delete(e);}async getLockoutHistory(e,t=10){return (this.history.get(e)||[]).slice(-t).reverse().map(o=>new Date(o))}async getLockoutStats(e){let r=(this.history.get(e)||[]).length,o=Math.floor(r/this.config.maxAttempts),n=null,i=this.storage.get(e);i&&i.lockedAt!==null&&(n=new Date(i.lockedAt));let a=o>0?this.config.maxAttempts:0;return {totalFailedAttempts:r,lockoutCount:o,lastLockout:n,averageAttemptsBeforeLockout:a}}shouldNotifyAdmin(e){return this.config.notifyAdmin&&e>=this.config.adminNotifyAfter}getConfig(){return {...this.config}}setConfig(e){this.config={...this.config,...e};}};function w(s,e=""){return process.env[s]||e}function T(s,e=false){let t=process.env[s];return t?t.toLowerCase()==="true":e}function A(s,e=0){let t=process.env[s];return t?parseInt(t,10):e}function Ve(){let s=process.env.KYRO_AUTH_DATABASE?.toLowerCase();if(s&&["sqlite","postgres","mongodb","memory"].includes(s))return s;try{let e=join(process.cwd(),"kyro.config.ts"),t=readFileSync(e,"utf8");if(t.includes("createLocalAdapter"))return "sqlite";if(t.includes("createDrizzleAdapter"))return t.includes("postgres")||t.includes("postgresql"),"postgres";if(t.includes("createMongoDBAdapter"))return "mongodb"}catch{}return "memory"}async function Kr(s){let e=process.cwd(),t=e.endsWith("admin")?join(e,".."):e,r=resolve(t,"data","auth.db");switch(s){case "sqlite":return new a$3({path:w("KYRO_AUTH_DB_PATH",r)});case "postgres":{let o=w("DATABASE_URL","");if(o){let n,i;try{n=(await import('drizzle-orm/postgres-js')).drizzle,i=await import('postgres');}catch{a$1(["postgres","drizzle-orm"]),n=(await import('drizzle-orm/postgres-js')).drizzle,i=await import('postgres');}let a=i.default(o,{onnotice:()=>{}}),c=n(a);return new a$4({db:c})}return new a$3({path:w("KYRO_AUTH_DB_PATH",r)})}case "mongodb":{let o=w("MONGODB_URI","");if(o){let n;try{let f=await import('mongodb');n=f.MongoClient??f.default?.MongoClient;}catch{a$1(["mongodb"]);let d=await import('mongodb');n=d.MongoClient??d.default?.MongoClient;}let i=new n(o);await i.connect();let c=new URL(o).pathname.replace(/^\//,"")||"kyro_cms",u=i.db(c);return new a$2({db:u})}return new a$3({path:w("KYRO_AUTH_DB_PATH",r)})}default:return new v}}async function W(s,e){let t=T("KYRO_DISTRIBUTED",false),r;if(t){let{RedisAuthAdapter:d}=await import('./redis-adapter-GFH74CF4.js'),l=w("REDIS_URL","redis://localhost:6379"),b=T("REDIS_TLS",false),p=new d({url:l,tls:b});await p.connect?.(),r=p;}else {let d=s||Ve();r=await Kr(d),r.connect&&await r.connect();}let o=e?await q$1.fromConfig(e).catch(()=>null)||q$1.fromEnv()||void 0:q$1.fromEnv()||void 0,n=new a({minLength:A("PASSWORD_MIN_LENGTH",12),requireUppercase:T("PASSWORD_REQUIRE_UPPERCASE",true),requireLowercase:T("PASSWORD_REQUIRE_LOWERCASE",true),requireNumbers:T("PASSWORD_REQUIRE_NUMBERS",true),requireSpecialChars:T("PASSWORD_REQUIRE_SPECIAL",true),preventReuse:A("PASSWORD_PREVENT_REUSE",5),maxLength:A("PASSWORD_MAX_LENGTH",128)}),i$1,a$1,c;if(t){let l=r.redis;i$1=new C(l,{maxAttempts:A("LOCKOUT_MAX_ATTEMPTS",5),lockDuration:A("LOCKOUT_DURATION_MINUTES",15)*60*1e3}),a$1=new R(l,{"auth:login":{window:A("RATE_LIMIT_AUTH_WINDOW_MS",9e5),max:A("RATE_LIMIT_AUTH_MAX_REQUESTS",10)},"api:general":{window:A("RATE_LIMIT_WINDOW_MS",6e4),max:A("RATE_LIMIT_MAX_REQUESTS",100)}}),c=new g(l,A("AUDIT_LOG_RETENTION_DAYS",30));}else i$1=new D({maxAttempts:A("LOCKOUT_MAX_ATTEMPTS",5),lockDuration:A("LOCKOUT_DURATION_MINUTES",15)*60*1e3}),a$1=new f({"auth:login":{window:A("RATE_LIMIT_AUTH_WINDOW_MS",9e5),max:A("RATE_LIMIT_AUTH_MAX_REQUESTS",10)},"api:general":{window:A("RATE_LIMIT_WINDOW_MS",6e4),max:A("RATE_LIMIT_MAX_REQUESTS",100)}}),c=T("AUDIT_LOG_ENABLED",true)?new i(A("AUDIT_LOG_RETENTION_DAYS",30)):void 0;let u=new j({redis:r,email:o,jwtSecret:w("APP_SECRET","change-me"),jwtExpiresIn:w("JWT_EXPIRES_IN","24h"),jwtIssuer:w("JWT_ISSUER","kyro-cms"),jwtAudience:w("JWT_AUDIENCE","kyro-cms-client"),passwordPolicy:n,lockout:i$1,rateLimiter:a$1,auditLogger:c,baseUrl:w("EMAIL_BASE_URL","http://localhost:4321"),emailVerificationRequired:T("EMAIL_VERIFICATION_REQUIRED",true)}),f$1=t?"distributed":s||Ve();return {authAdapter:r,databaseType:f$1,email:o,passwordPolicy:n,lockout:i$1,rateLimiter:a$1,auditLogger:c,routes:u}}var Me=W().catch(s=>(console.warn("[AuthConfig] Failed to initialize auth config:",s.message),null));var jr=12,zr="24h",Wr="7d",_=class{adapter;config;constructor(e,t){this.adapter=e,this.config={secret:t.secret,expiresIn:t.expiresIn??zr,refreshExpiresIn:t.refreshExpiresIn??Wr,issuer:t.issuer??"kyro-cms",audience:t.audience??[],saltRounds:t.saltRounds??jr};}async register(e){try{if(await this.adapter.findUserByEmail(e.email))return {success:!1,error:"Email already registered"};let r=await this.adapter.createUser({email:e.email,password:e.password,role:e.role??"customer",tenantId:e.tenantId});return this.createSessionForUser(r)}catch(t){return {success:false,error:String(t)}}}async login(e){try{let t=await this.adapter.verifyPassword(e.email,e.password);return t?this.createSessionForUser(t):{success:!1,error:"Invalid credentials"}}catch(t){return {success:false,error:String(t)}}}async logout(e){await this.adapter.deleteSession(e);}async refreshToken(e){try{let t=await this.adapter.findSessionByToken(e);if(!t||new Date(t.expiresAt)<new Date)return {success:!1,error:"Invalid or expired refresh token"};let r=await this.adapter.findUserById(t.userId);return r?(await this.adapter.deleteSession(e),this.createSessionForUser(r)):{success:!1,error:"User not found"}}catch(t){return {success:false,error:String(t)}}}async verifyToken(e){try{let{default:t}=await import('jsonwebtoken');return t.verify(e,this.config.secret,{issuer:this.config.issuer,audience:this.config.audience.length>0?this.config.audience[0]:void 0})}catch{return null}}async getUserFromToken(e){let t=await this.verifyToken(e);return t?this.adapter.findUserById(t.sub):null}async changePassword(e,t,r){try{let o=await this.adapter.findUserById(e);return o?await this.adapter.verifyPassword(o.email,t)?(await this.adapter.updateUser(e,{password:r}),await this.adapter.deleteUserSessions(e),{success:!0,user:o}):{success:!1,error:"Current password is incorrect"}:{success:!1,error:"User not found"}}catch(o){return {success:false,error:String(o)}}}async resetPassword(e,t){try{let r=await this.adapter.findUserByEmail(e);return r?(await this.adapter.updateUser(r.id,{password:t}),await this.adapter.deleteUserSessions(r.id),{success:!0,user:r}):{success:!1,error:"User not found"}}catch(r){return {success:false,error:String(r)}}}async sendEmailVerification(e){try{let{token:t,expiresAt:r}=await this.adapter.createEmailVerificationToken(e);return {success:!0}}catch(t){return {success:false,error:String(t)}}}async verifyEmail(e){try{return await this.adapter.verifyEmailToken(e)}catch(t){return {success:false,error:String(t)}}}async requestPasswordReset(e){try{let t=await this.adapter.createPasswordResetToken(e);return t.error?{success:!1,error:t.error}:{success:!0}}catch(t){return {success:false,error:String(t)}}}async resetPasswordWithToken(e,t){try{return await this.adapter.resetPasswordWithToken(e,t)}catch(r){return {success:false,error:String(r)}}}async deleteAccount(e){try{return await this.adapter.findUserById(e)?(await this.adapter.deleteUserSessions(e),await this.adapter.deleteUser(e),{success:!0}):{success:!1,error:"User not found"}}catch(t){return {success:false,error:String(t)}}}async createSessionForUser(e){let t=await this.generateToken(e),r=await this.adapter.createSession(e.id);return {success:true,user:e,session:r,token:t}}async generateToken(e){let{default:t}=await import('jsonwebtoken'),r={sub:e.id,email:e.email,role:e.role,tenantId:e.tenantId},o={expiresIn:this.parseExpiresIn(this.config.expiresIn)/1e3,issuer:this.config.issuer};return this.config.audience.length>0&&(o.audience=this.config.audience[0]),t.sign(r,this.config.secret,o)}async hashPassword(e){let{default:t}=await import('bcryptjs');return t.hash(e,this.config.saltRounds)}parseExpiresIn(e){if(typeof e=="number")return e;let t=e.match(/^(\d+)([smhd])$/);if(!t)return 864e5;let r=parseInt(t[1],10);switch(t[2]){case "s":return r*1e3;case "m":return r*6e4;case "h":return r*36e5;case "d":return r*864e5;default:return 864e5}}};function qr(s,e){return new _(s,e)}function H(){return {enabled:true,draftsEnabled:true,publishEnabled:true,scheduleEnabled:false,versioningEnabled:true,maxVersionsPerDocument:50,autoPublish:false,requirePublishPermission:true}}var B=class{adapter;config;constructor(e,t){this.adapter=e,this.config={...H(),...t};}async createVersion(e){let r=((await this.adapter.getLatestVersion(e.collection,e.documentId))?.version??0)+1,o={...e,version:r},n=await this.adapter.createVersion(o);return this.config.maxVersionsPerDocument>0&&await this.pruneOldVersions(e.collection,e.documentId),n}async publishVersion(e){let t=await this.adapter.getVersion(e.collection,e.versionId);if(!t)throw new Error("Version not found");if(t.status==="published")throw new Error("Version is already published");await this.adapter.publishVersion(e);}async unpublishDocument(e,t){let r=await this.adapter.getVersions({collection:e,documentId:t,limit:1e3});for(let o of r)if(o.status==="published"){await this.createVersion({collection:e,documentId:t,data:o.data,status:"draft",createdBy:"system",changeDescription:"Unpublished document"});break}}async revertToVersion(e,t,r,o){if(!await this.adapter.getVersion(e,r))throw new Error("Version not found");return await this.adapter.revertToVersion({collection:e,documentId:t,versionId:r,userId:o})}async getVersionHistory(e,t,r=20,o=0){return this.adapter.getVersions({collection:e,documentId:t,limit:r,offset:o})}async compareTwoVersions(e,t,r,o){return this.adapter.compareVersions({collection:e,documentId:t,versionA:r,versionB:o})}async getLatestDraft(e,t){return this.adapter.getLatestVersion(e,t)}async getPublishedVersion(e,t){return this.adapter.getPublishedVersion(e,t)}async getVersion(e,t){return this.adapter.getVersion(e,t)}async schedulePublish(e,t,r,o){if(!this.config.scheduleEnabled)throw new Error("Scheduled publishing is not enabled");if(!await this.adapter.getVersion(e,r))throw new Error("Version not found")}async deleteVersionHistory(e,t){await this.adapter.deleteVersions(e,t);}async pruneOldVersions(e,t){let r=await this.adapter.getVersions({collection:e,documentId:t,limit:this.config.maxVersionsPerDocument+100});if(r.length<=this.config.maxVersionsPerDocument)return;r.slice(0,this.config.maxVersionsPerDocument);let n=r.slice(this.config.maxVersionsPerDocument);for(let i of n)if(i.status!=="published"){await this.adapter.deleteVersions(e,t);break}}};function Gr(s,e){return new B(s,e)}function Qr(s){return s==="published"}function Yr(s){return s==="draft"}function Jr(s){return s==="archived"}function Xr(s){return s?Array.isArray(s)?s:Object.values(s):[]}function Zr(s){return s?Array.isArray(s)?s:Object.values(s):[]}function _e(s){return {collections:Xr(s.collections),globals:Zr(s.globals),adapter:s.adapter,storage:s.storage,plugins:s.plugins,auth:s.auth,cors:s.cors,admin:s.admin,upload:s.upload,graphQL:s.graphQL,typescript:s.typescript,localization:s.localization,rateLimit:s.rateLimit,debug:s.debug}}var eo=_e;function to(s){let{siteSettings:e,seoSettings:t,title:r,description:o,image:n,url:i}=s;if(!e)return "";let a=e.siteName||"",c=r||t?.defaultTitle||a,u=t?.titleTemplate,f=t?.separator||" | ",d=t?.siteNameInTitle!==false,l=u?u.replace(/\{\{title\}\}/g,c).replace(/\{\{siteName\}\}/g,d?a:"").replace(/\{\{separator\}\}/g,f).replace(/\s+/g," ").trim():c,b=o||t?.defaultDescription||e.siteDescription||"",p=n||e.siteOgImage?.url||"",h=i||e.siteUrl||"",y=`
|
|
22
|
+
<title>${l}</title>
|
|
23
|
+
<meta name="description" content="${b}">
|
|
24
|
+
`;e.siteFavicon?.url&&(y+=`
|
|
25
|
+
<link rel="icon" type="${e.siteFavicon.mimeType||"image/x-icon"}" href="${e.siteFavicon.url}">`);let x=t?.meta?.robots;x&&(y+=`
|
|
26
|
+
<meta name="robots" content="${x}">`);let X=t?.meta?.canonicalUrl||h;X&&(y+=`
|
|
27
|
+
<link rel="canonical" href="${X}">`);let ze=t?.meta?.ogType||"website";y+=`
|
|
28
|
+
<meta property="og:type" content="${ze}">
|
|
29
|
+
<meta property="og:title" content="${l}">
|
|
30
|
+
<meta property="og:description" content="${b}">
|
|
31
|
+
<meta property="og:site_name" content="${a}">
|
|
32
|
+
`,h&&(y+=`
|
|
33
|
+
<meta property="og:url" content="${h}">`),p&&(y+=`
|
|
34
|
+
<meta property="og:image" content="${p}">`),t?.social?.fbAppId&&(y+=`
|
|
35
|
+
<meta property="fb:app_id" content="${t.social.fbAppId}">`);let We=t?.social?.twitterCardType||"summary_large_image";return y+=`
|
|
36
|
+
<meta name="twitter:card" content="${We}">
|
|
37
|
+
<meta name="twitter:title" content="${l}">
|
|
38
|
+
<meta name="twitter:description" content="${b}">
|
|
39
|
+
`,t?.social?.twitterHandle&&(y+=`
|
|
40
|
+
<meta name="twitter:site" content="${t.social.twitterHandle}">`),p&&(y+=`
|
|
41
|
+
<meta name="twitter:image" content="${p}">`),e.enableI18n&&e.i18n?.language&&(y+=`
|
|
42
|
+
<meta http-equiv="content-language" content="${e.i18n.language}">`),y}function ro(s){if(!s||!s.analyticsEnabled||!s.analytics)return "";let{googleAnalyticsId:e,googleTagManagerId:t,plausibleDomain:r}=s.analytics,o="";return e&&(o+=`
|
|
43
43
|
<!-- Google Analytics -->
|
|
44
44
|
<script async src="https://www.googletagmanager.com/gtag/js?id=${e}"></script>
|
|
45
45
|
<script>
|
|
@@ -60,11 +60,11 @@ ${s}
|
|
|
60
60
|
`),r&&(o+=`
|
|
61
61
|
<!-- Plausible Analytics -->
|
|
62
62
|
<script defer data-domain="${r}" src="https://plausible.io/js/script.js"></script>
|
|
63
|
-
`),o}
|
|
63
|
+
`),o}var oo={facebook:{label:"Facebook"},twitter:{label:"Twitter / X"},instagram:{label:"Instagram"},linkedin:{label:"LinkedIn"},youtube:{label:"YouTube"},tiktok:{label:"TikTok"},pinterest:{label:"Pinterest"},discord:{label:"Discord"},twitch:{label:"Twitch"},github:{label:"GitHub"},mastodon:{label:"Mastodon"}},so=["facebook","twitter","instagram","linkedin","youtube","tiktok","pinterest","discord","twitch","github","mastodon"];function He(s){if(!s)return [];let e=s.showAll===true,t=[];for(let r of so){let o=s[r];if(!o||["tiktok","pinterest","discord","twitch","github","mastodon"].includes(r)&&!e)continue;let i=oo[r];t.push({platform:r,url:o,label:i?.label||r});}return t}async function no(s,e){try{let t=await s.findOne({collection:"_globals_social-settings",where:{},draft:e?.draft??!1});return He(t)}catch{return []}}function Be(s){return s?{storeName:s.storeName,storeEmail:s.storeEmail,storePhone:s.storePhone,address:s.address,currency:s.currency,tax:s.tax,shipping:s.shipping,orders:s.orders}:{}}async function io(s,e){try{let t=await s.findOne({collection:"_globals_store-settings",where:{},draft:e?.draft??!1});return Be(t)}catch{return {}}}function Ne(s){return s?{testMode:s.testMode,provider:s.provider,stripe:s.stripe,paypal:s.paypal,square:s.square,methods:s.methods,bankTransfer:s.bankTransfer}:{}}async function ao(s,e){try{let t=await s.findOne({collection:"_globals_payment-settings",where:{},draft:e?.draft??!1});return Ne(t)}catch{return {}}}async function q(s={}){let{namespace:e="kyro",ttl:t}=s,r=createStorage({driver:lo({dbName:"kyro-cms",storeName:e})}),o=e?`${e}:`:"";return {storage:{getItem:async i=>{let a=`${o}${i}`,c=await r.getItem(a);if(c==null)return null;try{let u=JSON.parse(c);return u.expiry&&Date.now()>u.expiry?(await r.removeItem(a),null):u.value}catch{return c}},setItem:async(i,a)=>{let c=`${o}${i}`,u=JSON.stringify(t?{value:a,expiry:Date.now()+t}:{value:a});await r.setItem(c,u);},removeItem:async i=>{await r.removeItem(`${o}${i}`);}},cleanup:async()=>{await r.dispose?.();}}}function G(s){let e=s||process.env.APP_SECRET||process.env.AUTH_SECRET||"development-secret-key";return Q.createHash("sha256").update(e).digest("hex")}function mo(s,e){let t=Q.randomBytes(16),r=Q.createCipheriv("aes-256-gcm",Buffer.from(e,"hex").subarray(0,32),t),o=r.update(s,"utf8","hex");o+=r.final("hex");let n=r.getAuthTag().toString("hex");return `${t.toString("hex")}:${n}:${o}`}function fo(s,e){let[t,r,o]=s.split(":"),n=Buffer.from(t,"hex"),i=Buffer.from(r,"hex"),a=Q.createDecipheriv("aes-256-gcm",Buffer.from(e,"hex").subarray(0,32),n);a.setAuthTag(i);let c=a.update(o,"hex","utf8");return c+=a.final("utf8"),c}async function Y(s={}){let{namespace:e="kyro",ttl:t,encryption:r=true,secret:o,basePath:n}=s,i=n?$e.join(n,".astro","kyro.json"):$e.join(process.cwd(),".astro","kyro.json"),a=createStorage({driver:go({base:i})}),c=r?G(o):null,u=e?`${e}:`:"";return {storage:{getItem:async f=>{let d=`${u}${f}`,l=await a.getItem(d);if(l==null)return null;try{let b=c?fo(l,c):l,p=JSON.parse(b);return p.expiry&&Date.now()>p.expiry?(await a.removeItem(d),null):p.value}catch{return l}},setItem:async(f,d)=>{let l=`${u}${f}`,b=JSON.stringify(t?{value:d,expiry:Date.now()+t}:{value:d});await a.setItem(l,c?mo(b,c):b);},removeItem:async f=>{await a.removeItem(`${u}${f}`);}},cleanup:async()=>{await a.dispose?.();}}}async function J(s){let{environment:e,adapter:t,connectionString:r,encryption:o}=s,n=process.env.APP_SECRET||process.env.AUTH_SECRET,i={enabled:o?.enabled??true,algorithm:o?.algorithm};return e==="browser"?q({namespace:"kyro"}):Y({namespace:"kyro",encryption:i.enabled,secret:n})}async function Ke(s){let e={...s,encryption:{enabled:true,algorithm:s.encryption?.algorithm}};return J(e)}function ho(s){return {name:"kyro-loader",load:async e=>{let{store:t,logger:r,parseData:o}=e;r.info(`Loading Kyro CMS collection: "${s.collection}"`);try{let n=[];t.clear();for(let i of n){let a=String(i.id||i._id),c=await o({id:a,data:i});t.set({id:a,data:c,digest:JSON.stringify(c)});}r.info(`Successfully synced ${n.length} entries for "${s.collection}" into Astro store.`);}catch(n){r.error(`Failed to load Kyro collection "${s.collection}": ${n.message}`);}},schema:z$1.object({id:z$1.string(),createdAt:z$1.string().optional(),updatedAt:z$1.string().optional()}).passthrough()}}function bo(s){return {input:s.schema||z$1.object({}).passthrough(),handler:async(t,r)=>{try{return {success:!0,collection:s.collection,action:s.action,data:t,timestamp:new Date().toISOString()}}catch(o){return {success:false,error:o.message||"CMS Action Execution Failed"}}}}}function Ao(s={}){let e=s.protectedRoutes||[],t=s.loginPath||"/admin/login",r=s.cookieName||"kyro_session";return async(o,n)=>{let{request:i,cookies:a,redirect:c,locals:u}=o,f=new URL(i.url),d=a?.get?.(r)?.value||i.headers.get("authorization")?.replace("Bearer ",""),l=null;return d&&(l={id:"user_1",email:"admin@kyro-cms.com",role:"admin"}),u.kyroUser=l,e.some(p=>new RegExp("^"+p.replace(/\*/g,".*")+"$").test(f.pathname))&&!l?c(`${t}?redirect=${encodeURIComponent(f.pathname)}`):n()}}function wo(s){let e=s?.collections||[],t=`// Auto-generated by Kyro CMS
|
|
64
64
|
declare module 'kyro:collections' {
|
|
65
65
|
export interface KyroCollections {
|
|
66
66
|
`;for(let r of e){let o=r.name||r.slug;t+=` '${o}': Record<string, any>;
|
|
67
67
|
`;}return t+=` }
|
|
68
68
|
}
|
|
69
|
-
`,t}
|
|
70
|
-
export{
|
|
69
|
+
`,t}function xo(s={}){return {APP_SECRET:{context:"server",access:"secret",type:"string",optional:false},DATABASE_URL:{context:"server",access:"secret",type:"string",optional:!s.requireDatabase},PUBLIC_KYRO_URL:{context:"client",access:"public",type:"string",optional:true,default:"http://localhost:4321"}}}function To(s,e={}){let{idField:t="id",parentField:r="parent",slugField:o="slug",slugPrefix:n=true,basePath:i="",maxDepth:a=10}=e,c=new Map,u=[];for(let d of s){let l=d[t];l!=null&&c.set(l,{doc:d,id:l,slug:d[o],depth:0,path:"",fullPath:"",children:[]});}for(let d of s){let l=d[t],b=c.get(l);if(!b)continue;let p=d[r];p&&typeof p=="object"&&(p=p[t]||p.id||p._id),p&&c.has(p)?c.get(p).children.push(b):u.push(b);}function f(d,l,b){if(!(l>a))for(let p of d){p.depth=l;let h=p.slug||String(p.id),y="";n?y=b?`${b}/${h}`:i?`${i.replace(/\/$/,"")}/${h}`:`/${h}`:y=i?`${i.replace(/\/$/,"")}/${h}`:`/${h}`,p.path=y,p.fullPath=y,p.children.length>0&&f(p.children,l+1,p.path);}}return f(u,0,""),u}function je(s,e,t={}){let r,o;Array.isArray(s)?(r=s,o=e):(o=s,r=e);let{idField:n="id",parentField:i="parent",labelField:a="title",slugField:c="slug",basePath:u=""}=t,f=new Map;for(let h of r){let y=h[n];y!=null&&f.set(y,h);}let d=[],l=o,b=new Set;for(;l!==void 0&&f.has(l)&&!b.has(l);){b.add(l);let h=f.get(l),y=h[a]||h.name||h.label||h[c]||String(l);d.unshift({id:l,label:y,slug:h[c]});let x=h[i];x&&typeof x=="object"&&(x=x[n]||x.id||x._id),l=x;}let p=u?u.replace(/\/$/,""):"";return d.map(h=>{let y=h.slug||String(h.id);return p=`${p}/${y}`,{...h,path:p}})}function So(s,e,t={}){let r=je(s,e,t);return r[r.length-1]?.path||(t.basePath?t.basePath:"/")}function Po(s){let e=[];function t(r){for(let o of r)e.push({doc:o.doc,id:o.id,depth:o.depth,path:o.path,fullPath:o.fullPath,hasChildren:o.children.length>0}),o.children.length>0&&t(o.children);}return t(s),e}
|
|
70
|
+
export{C as AccountLockout,_ as Auth,z as CSSGenerator,D as InMemoryAccountLockout,v as InMemoryAuthAdapter,L as NeonAdapter,R as RateLimiter,E as TursoAdapter,B as VersionManager,Me as authConfig,To as buildDocumentTree,Mr as createAdminStyling,qr as createAuth,W as createAuthConfig,Ke as createAuthStorage,Ee as createNeonAdapter,J as createStorage,Oe as createTursoAdapter,Gr as createVersionManager,Vr as defaultDarkTheme,_r as defaultFieldStyling,O as defaultLightTheme,_e as defineConfig,eo as defineKyroConfig,Fr as ecommerce2026Theme,Po as flattenDocumentTree,ro as generateAnalyticsTags,Ue as generateCSSVariables,wo as generateKyroAstroTypes,to as generateSeoTags,Ur as generateTailwindConfig,je as getBreadcrumbs,H as getDefaultDraftPublishConfig,So as getNestedPath,ao as getPaymentConfig,Ne as getPaymentConfigFromSettings,no as getSocialLinks,He as getSocialLinksFromSettings,io as getStoreConfig,Be as getStoreConfigFromSettings,Jr as isArchived,Yr as isDraft,Qr as isPublished,bo as kyroAction,Ao as kyroAuthMiddleware,xo as kyroEnvSchema,ho as kyroLoader,Or as runFieldHooks,Le as runHooks};
|
package/dist/integration.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
'use strict';var
|
|
1
|
+
'use strict';var chunkHCM2G674_cjs=require('./chunk-HCM2G674.cjs');require('./chunk-JHFD3IAU.cjs');module.exports=chunkHCM2G674_cjs.a;
|
package/dist/integration.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export{a as default}from'./chunk-
|
|
1
|
+
export{a as default}from'./chunk-SZY25KAE.js';import'./chunk-RLW6AQF2.js';if (typeof window === "undefined") { const { createRequire } = await import(/* @vite-ignore */ 'module'); createRequire(import.meta.url); }
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
'use strict';var chunkA7763NCF_cjs=require('./chunk-A7763NCF.cjs');require('./chunk-YOJOVQIH.cjs'),require('./chunk-O4PPZOVI.cjs'),require('./chunk-OXEJCIOA.cjs'),require('./chunk-KOSR7235.cjs'),require('./chunk-JHFD3IAU.cjs');Object.defineProperty(exports,"LocalAdapter",{enumerable:true,get:function(){return chunkA7763NCF_cjs.a}});Object.defineProperty(exports,"createLocalAdapter",{enumerable:true,get:function(){return chunkA7763NCF_cjs.b}});
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export{a as LocalAdapter,b as createLocalAdapter}from'./chunk-ZE2X3FBU.js';import'./chunk-WLSVS3NC.js';import'./chunk-YNSKDTFG.js';import'./chunk-NGNXOXI5.js';import'./chunk-O4RKZQYQ.js';import'./chunk-RLW6AQF2.js';if (typeof window === "undefined") { const { createRequire } = await import(/* @vite-ignore */ 'module'); createRequire(import.meta.url); }
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
'use strict';var chunkAQWTJGML_cjs=require('./chunk-AQWTJGML.cjs');require('./chunk-JHFD3IAU.cjs');Object.defineProperty(exports,"media",{enumerable:true,get:function(){return chunkAQWTJGML_cjs.a}});Object.defineProperty(exports,"mediaFolders",{enumerable:true,get:function(){return chunkAQWTJGML_cjs.b}});
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export{a as media,b as mediaFolders}from'./chunk-V2RMDMWN.js';import'./chunk-RLW6AQF2.js';if (typeof window === "undefined") { const { createRequire } = await import(/* @vite-ignore */ 'module'); createRequire(import.meta.url); }
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
'use strict';var chunkNBBAMC2X_cjs=require('./chunk-NBBAMC2X.cjs');require('./chunk-JHFD3IAU.cjs');Object.defineProperty(exports,"MongoDBAuthAdapter",{enumerable:true,get:function(){return chunkNBBAMC2X_cjs.a}});
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export{a as MongoDBAuthAdapter}from'./chunk-CIWLQXB2.js';import'./chunk-RLW6AQF2.js';if (typeof window === "undefined") { const { createRequire } = await import(/* @vite-ignore */ 'module'); createRequire(import.meta.url); }
|
package/dist/mongodb/index.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
'use strict';var
|
|
1
|
+
'use strict';var chunkGDLMPZKD_cjs=require('../chunk-GDLMPZKD.cjs'),chunkNBBAMC2X_cjs=require('../chunk-NBBAMC2X.cjs');require('../chunk-O4PPZOVI.cjs'),require('../chunk-JJY2F6NL.cjs'),require('../chunk-OXEJCIOA.cjs'),require('../chunk-KOSR7235.cjs'),require('../chunk-JHFD3IAU.cjs');Object.defineProperty(exports,"MongoDBAdapter",{enumerable:true,get:function(){return chunkGDLMPZKD_cjs.a}});Object.defineProperty(exports,"createMongoDBAdapter",{enumerable:true,get:function(){return chunkGDLMPZKD_cjs.b}});Object.defineProperty(exports,"MongoDBAuthAdapter",{enumerable:true,get:function(){return chunkNBBAMC2X_cjs.a}});
|
package/dist/mongodb/index.d.cts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { b as AbstractBaseAdapter, c as AuthAdapter, U as UserRole, d as AuthUser, S as Session, a as AuditLogFilter, A as AuditLog } from '../base-
|
|
2
|
-
import { F as FindArgs, b as FindResult, c as FindByIDArgs, d as CreateArgs, U as UpdateArgs, D as DeleteArgs, e as FindOneArgs, f as FindVersionsArgs, V as VersionRecord, g as CreateVersionArgs } from '../types-
|
|
3
|
-
import '../types-
|
|
1
|
+
import { b as AbstractBaseAdapter, c as AuthAdapter, U as UserRole, d as AuthUser, S as Session, a as AuditLogFilter, A as AuditLog } from '../base-DIpT2Vuz.cjs';
|
|
2
|
+
import { F as FindArgs, b as FindResult, c as FindByIDArgs, d as CreateArgs, U as UpdateArgs, D as DeleteArgs, e as FindOneArgs, f as FindVersionsArgs, V as VersionRecord, g as CreateVersionArgs } from '../types-CdwfDpyW.cjs';
|
|
3
|
+
import '../types-C3QFX0l6.cjs';
|
|
4
4
|
|
|
5
5
|
declare class MongoDBAdapter extends AbstractBaseAdapter {
|
|
6
6
|
dialect: "mongodb";
|
package/dist/mongodb/index.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { b as AbstractBaseAdapter, c as AuthAdapter, U as UserRole, d as AuthUser, S as Session, a as AuditLogFilter, A as AuditLog } from '../base-
|
|
2
|
-
import { F as FindArgs, b as FindResult, c as FindByIDArgs, d as CreateArgs, U as UpdateArgs, D as DeleteArgs, e as FindOneArgs, f as FindVersionsArgs, V as VersionRecord, g as CreateVersionArgs } from '../types-
|
|
3
|
-
import '../types-
|
|
1
|
+
import { b as AbstractBaseAdapter, c as AuthAdapter, U as UserRole, d as AuthUser, S as Session, a as AuditLogFilter, A as AuditLog } from '../base-C2DOe8wD.js';
|
|
2
|
+
import { F as FindArgs, b as FindResult, c as FindByIDArgs, d as CreateArgs, U as UpdateArgs, D as DeleteArgs, e as FindOneArgs, f as FindVersionsArgs, V as VersionRecord, g as CreateVersionArgs } from '../types-CKWnrUAh.js';
|
|
3
|
+
import '../types-C3QFX0l6.js';
|
|
4
4
|
|
|
5
5
|
declare class MongoDBAdapter extends AbstractBaseAdapter {
|
|
6
6
|
dialect: "mongodb";
|
package/dist/mongodb/index.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export{a as MongoDBAdapter,b as createMongoDBAdapter}from'../chunk-
|
|
1
|
+
export{a as MongoDBAdapter,b as createMongoDBAdapter}from'../chunk-VWXHW74B.js';export{a as MongoDBAuthAdapter}from'../chunk-CIWLQXB2.js';import'../chunk-YNSKDTFG.js';import'../chunk-VLFM66BZ.js';import'../chunk-NGNXOXI5.js';import'../chunk-O4RKZQYQ.js';import'../chunk-RLW6AQF2.js';if (typeof window === "undefined") { const { createRequire } = await import(/* @vite-ignore */ 'module'); createRequire(import.meta.url); }
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export{q as EmailTransport}from'./chunk-5I3BM5TV.js';import'./chunk-W5GDZG64.js';import'./chunk-RLW6AQF2.js';if (typeof window === "undefined") { const { createRequire } = await import(/* @vite-ignore */ 'module'); createRequire(import.meta.url); }
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
'use strict';var chunk2I2AXTKY_cjs=require('./chunk-2I2AXTKY.cjs');require('./chunk-GS4CMYKS.cjs'),require('./chunk-JHFD3IAU.cjs');Object.defineProperty(exports,"EmailTransport",{enumerable:true,get:function(){return chunk2I2AXTKY_cjs.q}});
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export{a as PostgresAuthAdapter}from'./chunk-IIPSXKNV.js';import'./chunk-7EY3GXRA.js';import'./chunk-RLW6AQF2.js';if (typeof window === "undefined") { const { createRequire } = await import(/* @vite-ignore */ 'module'); createRequire(import.meta.url); }
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
'use strict';var chunk3A5UO6OQ_cjs=require('./chunk-3A5UO6OQ.cjs');require('./chunk-23RSKVJP.cjs'),require('./chunk-JHFD3IAU.cjs');Object.defineProperty(exports,"PostgresAuthAdapter",{enumerable:true,get:function(){return chunk3A5UO6OQ_cjs.a}});
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
'use strict';var chunkJQ4V2MGJ_cjs=require('./chunk-JQ4V2MGJ.cjs');require('./chunk-JJY2F6NL.cjs'),require('./chunk-JHFD3IAU.cjs');Object.defineProperty(exports,"RedisAuthAdapter",{enumerable:true,get:function(){return chunkJQ4V2MGJ_cjs.a}});
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export{a as RedisAuthAdapter}from'./chunk-V4SR7DU5.js';import'./chunk-VLFM66BZ.js';import'./chunk-RLW6AQF2.js';if (typeof window === "undefined") { const { createRequire } = await import(/* @vite-ignore */ 'module'); createRequire(import.meta.url); }
|
package/dist/rest/index.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
'use strict';var
|
|
1
|
+
'use strict';var chunkHACW42ZZ_cjs=require('../chunk-HACW42ZZ.cjs');require('../chunk-H2IJDTA2.cjs'),require('../chunk-PW6Y5MQL.cjs'),require('../chunk-34LCWI5X.cjs'),require('../chunk-LXTVMP5F.cjs'),require('../chunk-2I2AXTKY.cjs'),require('../chunk-GS4CMYKS.cjs'),require('../chunk-OJBL4CXK.cjs'),require('../chunk-DCFOVCJX.cjs'),require('../chunk-EG4SRTYS.cjs'),require('../chunk-3A5UO6OQ.cjs'),require('../chunk-23RSKVJP.cjs'),require('../chunk-YOJOVQIH.cjs'),require('../chunk-NBBAMC2X.cjs'),require('../chunk-OXEJCIOA.cjs'),require('../chunk-KOSR7235.cjs'),require('../chunk-JHFD3IAU.cjs');Object.defineProperty(exports,"createKyroApp",{enumerable:true,get:function(){return chunkHACW42ZZ_cjs.n}});Object.defineProperty(exports,"createRESTAPI",{enumerable:true,get:function(){return chunkHACW42ZZ_cjs.o}});
|
package/dist/rest/index.d.cts
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { Hono } from 'hono';
|
|
2
|
-
import { B as BaseAdapter, i as User } from '../types-
|
|
3
|
-
import { R as Registry } from '../index-
|
|
4
|
-
import { j as createWebhookService } from '../WebhookService-
|
|
5
|
-
import '../types-
|
|
2
|
+
import { B as BaseAdapter, i as User } from '../types-CdwfDpyW.cjs';
|
|
3
|
+
import { R as Registry } from '../index-Ci7aUrmN.cjs';
|
|
4
|
+
import { j as createWebhookService } from '../WebhookService-BJTCP3cU.cjs';
|
|
5
|
+
import '../types-C3QFX0l6.cjs';
|
|
6
6
|
import 'zod';
|
|
7
7
|
|
|
8
8
|
interface KyroAppOptions {
|
package/dist/rest/index.d.ts
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { Hono } from 'hono';
|
|
2
|
-
import { B as BaseAdapter, i as User } from '../types-
|
|
3
|
-
import { R as Registry } from '../index-
|
|
4
|
-
import { j as createWebhookService } from '../WebhookService-
|
|
5
|
-
import '../types-
|
|
2
|
+
import { B as BaseAdapter, i as User } from '../types-CKWnrUAh.js';
|
|
3
|
+
import { R as Registry } from '../index-C9uBoJtm.js';
|
|
4
|
+
import { j as createWebhookService } from '../WebhookService-Bqr_66lK.js';
|
|
5
|
+
import '../types-C3QFX0l6.js';
|
|
6
6
|
import 'zod';
|
|
7
7
|
|
|
8
8
|
interface KyroAppOptions {
|
package/dist/rest/index.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export{
|
|
1
|
+
export{n as createKyroApp,o as createRESTAPI}from'../chunk-A4XM33WO.js';import'../chunk-FAG2645P.js';import'../chunk-IIVBEZC2.js';import'../chunk-I22MSXGL.js';import'../chunk-SBFVITY2.js';import'../chunk-5I3BM5TV.js';import'../chunk-W5GDZG64.js';import'../chunk-OPKZYQV7.js';import'../chunk-3N34WXBS.js';import'../chunk-JXJTFBHG.js';import'../chunk-IIPSXKNV.js';import'../chunk-7EY3GXRA.js';import'../chunk-WLSVS3NC.js';import'../chunk-CIWLQXB2.js';import'../chunk-NGNXOXI5.js';import'../chunk-O4RKZQYQ.js';import'../chunk-RLW6AQF2.js';if (typeof window === "undefined") { const { createRequire } = await import(/* @vite-ignore */ 'module'); createRequire(import.meta.url); }
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
'use strict';var chunkAQWTJGML_cjs=require('./chunk-AQWTJGML.cjs'),chunkGS4CMYKS_cjs=require('./chunk-GS4CMYKS.cjs'),chunk23RSKVJP_cjs=require('./chunk-23RSKVJP.cjs');require('./chunk-JHFD3IAU.cjs');Object.defineProperty(exports,"media",{enumerable:true,get:function(){return chunkAQWTJGML_cjs.a}});Object.defineProperty(exports,"mediaFolders",{enumerable:true,get:function(){return chunkAQWTJGML_cjs.b}});Object.defineProperty(exports,"settings",{enumerable:true,get:function(){return chunkGS4CMYKS_cjs.a}});Object.defineProperty(exports,"apiKeys",{enumerable:true,get:function(){return chunk23RSKVJP_cjs.g}});Object.defineProperty(exports,"auditLogs",{enumerable:true,get:function(){return chunk23RSKVJP_cjs.e}});Object.defineProperty(exports,"emailVerifications",{enumerable:true,get:function(){return chunk23RSKVJP_cjs.h}});Object.defineProperty(exports,"lockouts",{enumerable:true,get:function(){return chunk23RSKVJP_cjs.k}});Object.defineProperty(exports,"passwordHistory",{enumerable:true,get:function(){return chunk23RSKVJP_cjs.j}});Object.defineProperty(exports,"passwordResets",{enumerable:true,get:function(){return chunk23RSKVJP_cjs.i}});Object.defineProperty(exports,"permissions",{enumerable:true,get:function(){return chunk23RSKVJP_cjs.c}});Object.defineProperty(exports,"roles",{enumerable:true,get:function(){return chunk23RSKVJP_cjs.b}});Object.defineProperty(exports,"sessions",{enumerable:true,get:function(){return chunk23RSKVJP_cjs.d}});Object.defineProperty(exports,"tenants",{enumerable:true,get:function(){return chunk23RSKVJP_cjs.f}});Object.defineProperty(exports,"users",{enumerable:true,get:function(){return chunk23RSKVJP_cjs.a}});
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export{a as media,b as mediaFolders}from'./chunk-V2RMDMWN.js';export{a as settings}from'./chunk-W5GDZG64.js';export{g as apiKeys,e as auditLogs,h as emailVerifications,k as lockouts,j as passwordHistory,i as passwordResets,c as permissions,b as roles,d as sessions,f as tenants,a as users}from'./chunk-7EY3GXRA.js';import'./chunk-RLW6AQF2.js';if (typeof window === "undefined") { const { createRequire } = await import(/* @vite-ignore */ 'module'); createRequire(import.meta.url); }
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
'use strict';var chunkPW6Y5MQL_cjs=require('./chunk-PW6Y5MQL.cjs');require('./chunk-JHFD3IAU.cjs');Object.defineProperty(exports,"SQLiteAuthAdapter",{enumerable:true,get:function(){return chunkPW6Y5MQL_cjs.a}});
|