gemi 0.63.0 → 0.65.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/ai/Agent.d.ts +73 -0
- package/dist/ai/Agent.d.ts.map +1 -1
- package/dist/ai/AgentController.d.ts +75 -6
- package/dist/ai/AgentController.d.ts.map +1 -1
- package/dist/ai/AgentProvider.d.ts +5 -1
- package/dist/ai/AgentProvider.d.ts.map +1 -1
- package/dist/ai/Schema.d.ts +62 -0
- package/dist/ai/Schema.d.ts.map +1 -1
- package/dist/ai/client/index.js +10 -4
- package/dist/ai/client/index.js.map +1 -1
- package/dist/ai/client/reducer.d.ts.map +1 -1
- package/dist/ai/index.d.ts +2 -1
- package/dist/ai/index.d.ts.map +1 -1
- package/dist/ai/index.js +12 -12
- package/dist/ai/index.js.map +6 -6
- package/dist/ai/live/harness.d.ts +5 -3
- package/dist/ai/live/harness.d.ts.map +1 -1
- package/dist/ai/types.d.ts +29 -1
- package/dist/ai/types.d.ts.map +1 -1
- package/dist/ai/useChat.d.ts +60 -4
- package/dist/ai/useChat.d.ts.map +1 -1
- package/dist/app/index.js +1 -1
- package/dist/auth/AuthController.d.ts.map +1 -1
- package/dist/auth/AuthManager.d.ts +38 -4
- package/dist/auth/AuthManager.d.ts.map +1 -1
- package/dist/auth/UserProvider.d.ts.map +1 -1
- package/dist/auth/config.d.ts.map +1 -1
- package/dist/auth/sessionToken.d.ts +38 -0
- package/dist/auth/sessionToken.d.ts.map +1 -0
- package/dist/auth/types.d.ts +1 -1
- package/dist/auth/types.d.ts.map +1 -1
- package/dist/bin/gemi.js +9 -1
- package/dist/bin/gemi.js.map +3 -3
- package/dist/broadcasting/index.js +1 -1
- package/dist/bun/plugin.js +1 -1
- package/dist/bun/preload.js +1 -1
- package/dist/{chunk-jv9k1qfr.js → chunk-2bb3rdqq.js} +3 -3
- package/dist/{chunk-jv9k1qfr.js.map → chunk-2bb3rdqq.js.map} +1 -1
- package/dist/{chunk-e785380d.js → chunk-2dvjj3ad.js} +2 -2
- package/dist/{chunk-e785380d.js.map → chunk-2dvjj3ad.js.map} +1 -1
- package/dist/{chunk-rj3fnc4h.js → chunk-2ghpxrw1.js} +1 -1
- package/dist/{chunk-dqbm9vd0.js → chunk-3mp9p38x.js} +2 -2
- package/dist/{chunk-dqbm9vd0.js.map → chunk-3mp9p38x.js.map} +1 -1
- package/dist/{chunk-cdpeh7tt.js → chunk-3pwn2r6s.js} +2 -2
- package/dist/{chunk-cdpeh7tt.js.map → chunk-3pwn2r6s.js.map} +1 -1
- package/dist/{chunk-7qfzrkab.js → chunk-45g3hd0e.js} +2 -2
- package/dist/{chunk-7qfzrkab.js.map → chunk-45g3hd0e.js.map} +1 -1
- package/dist/{chunk-wqmzad46.js → chunk-5g1j29p2.js} +2 -2
- package/dist/{chunk-wqmzad46.js.map → chunk-5g1j29p2.js.map} +1 -1
- package/dist/{chunk-bxtx4y4w.js → chunk-5pm9zvtp.js} +2 -2
- package/dist/{chunk-bxtx4y4w.js.map → chunk-5pm9zvtp.js.map} +1 -1
- package/dist/{chunk-pbx9p6g0.js → chunk-6waph5k8.js} +1 -1
- package/dist/{chunk-nnc40mf3.js → chunk-70y8wajy.js} +2 -2
- package/dist/{chunk-nnc40mf3.js.map → chunk-70y8wajy.js.map} +1 -1
- package/dist/{chunk-71yhw8aw.js → chunk-731etrh2.js} +2 -2
- package/dist/{chunk-71yhw8aw.js.map → chunk-731etrh2.js.map} +1 -1
- package/dist/{chunk-1s1cd1e8.js → chunk-7438nrkm.js} +3 -3
- package/dist/{chunk-1s1cd1e8.js.map → chunk-7438nrkm.js.map} +1 -1
- package/dist/{chunk-ssg20z9s.js → chunk-7wgk7q33.js} +3 -3
- package/dist/{chunk-ssg20z9s.js.map → chunk-7wgk7q33.js.map} +1 -1
- package/dist/chunk-7xc64j6p.js +5 -0
- package/dist/chunk-7xc64j6p.js.map +14 -0
- package/dist/{chunk-jmse5hec.js → chunk-7zg1mt1g.js} +2 -2
- package/dist/{chunk-jmse5hec.js.map → chunk-7zg1mt1g.js.map} +1 -1
- package/dist/{chunk-0qchadp1.js → chunk-87c0cy5v.js} +2 -2
- package/dist/{chunk-0qchadp1.js.map → chunk-87c0cy5v.js.map} +1 -1
- package/dist/{chunk-773qa4av.js → chunk-8bjxk57p.js} +2 -2
- package/dist/{chunk-773qa4av.js.map → chunk-8bjxk57p.js.map} +1 -1
- package/dist/{chunk-81yzec62.js → chunk-8jpvj3cj.js} +2 -2
- package/dist/{chunk-81yzec62.js.map → chunk-8jpvj3cj.js.map} +1 -1
- package/dist/{chunk-9e5c5e15.js → chunk-9ch1q7nd.js} +2 -2
- package/dist/{chunk-9e5c5e15.js.map → chunk-9ch1q7nd.js.map} +1 -1
- package/dist/{chunk-9e5v1t73.js → chunk-9x5eefh0.js} +2 -2
- package/dist/{chunk-9e5v1t73.js.map → chunk-9x5eefh0.js.map} +1 -1
- package/dist/{chunk-62xjrz5e.js → chunk-9zmcz7yq.js} +2 -2
- package/dist/{chunk-62xjrz5e.js.map → chunk-9zmcz7yq.js.map} +1 -1
- package/dist/{chunk-0amv13g6.js → chunk-a85fn4zf.js} +3 -3
- package/dist/{chunk-0amv13g6.js.map → chunk-a85fn4zf.js.map} +1 -1
- package/dist/chunk-adj6dnvj.js +5 -0
- package/dist/{chunk-dq2hgzje.js.map → chunk-adj6dnvj.js.map} +1 -1
- package/dist/{chunk-exwbtfe9.js → chunk-aq09ta7k.js} +2 -2
- package/dist/{chunk-exwbtfe9.js.map → chunk-aq09ta7k.js.map} +1 -1
- package/dist/{chunk-43xw9n4f.js → chunk-dmr7yzyr.js} +2 -2
- package/dist/{chunk-43xw9n4f.js.map → chunk-dmr7yzyr.js.map} +1 -1
- package/dist/{chunk-q4wdg0y3.js → chunk-e0v4byjp.js} +2 -2
- package/dist/{chunk-ptjexzn1.js.map → chunk-e0v4byjp.js.map} +1 -1
- package/dist/{chunk-8wpccvbt.js → chunk-e1fkxt82.js} +2 -2
- package/dist/{chunk-8wpccvbt.js.map → chunk-e1fkxt82.js.map} +1 -1
- package/dist/{chunk-xadk41cs.js → chunk-ex9ns7pf.js} +4 -4
- package/dist/{chunk-xadk41cs.js.map → chunk-ex9ns7pf.js.map} +1 -1
- package/dist/{chunk-95d8jj11.js → chunk-fd7wfcft.js} +2 -2
- package/dist/{chunk-95d8jj11.js.map → chunk-fd7wfcft.js.map} +1 -1
- package/dist/{chunk-maxd55a0.js → chunk-fk127cwf.js} +2 -2
- package/dist/{chunk-maxd55a0.js.map → chunk-fk127cwf.js.map} +2 -2
- package/dist/{chunk-kx7vgcjp.js → chunk-fmcq21hg.js} +3 -3
- package/dist/{chunk-kx7vgcjp.js.map → chunk-fmcq21hg.js.map} +1 -1
- package/dist/{chunk-k1wkvrj0.js → chunk-ftaxfq7p.js} +3 -3
- package/dist/{chunk-k1wkvrj0.js.map → chunk-ftaxfq7p.js.map} +1 -1
- package/dist/{chunk-zdj2wmbj.js → chunk-fxkh2rfd.js} +2 -2
- package/dist/{chunk-zdj2wmbj.js.map → chunk-fxkh2rfd.js.map} +1 -1
- package/dist/{chunk-9k5daets.js → chunk-g2ywq30n.js} +2 -2
- package/dist/{chunk-9k5daets.js.map → chunk-g2ywq30n.js.map} +1 -1
- package/dist/chunk-hq496pa4.js +5 -0
- package/dist/chunk-hq496pa4.js.map +10 -0
- package/dist/{chunk-4sv5zpb4.js → chunk-hrtkjv41.js} +2 -2
- package/dist/{chunk-4sv5zpb4.js.map → chunk-hrtkjv41.js.map} +1 -1
- package/dist/{chunk-tq92xqkk.js → chunk-j3b3qerv.js} +2 -2
- package/dist/{chunk-tq92xqkk.js.map → chunk-j3b3qerv.js.map} +1 -1
- package/dist/{chunk-dhe1hsyz.js → chunk-jkjt3e06.js} +2 -2
- package/dist/{chunk-dhe1hsyz.js.map → chunk-jkjt3e06.js.map} +1 -1
- package/dist/{chunk-5wzyx4ts.js → chunk-ks94h71z.js} +2 -2
- package/dist/{chunk-5wzyx4ts.js.map → chunk-ks94h71z.js.map} +1 -1
- package/dist/{chunk-rhr8qavq.js → chunk-m44ar4he.js} +2 -2
- package/dist/{chunk-rhr8qavq.js.map → chunk-m44ar4he.js.map} +1 -1
- package/dist/{chunk-0081bz9c.js → chunk-nxg51m0q.js} +2 -2
- package/dist/{chunk-0081bz9c.js.map → chunk-nxg51m0q.js.map} +1 -1
- package/dist/{chunk-qrfp7pg2.js → chunk-nxh5a3eb.js} +3 -3
- package/dist/{chunk-qrfp7pg2.js.map → chunk-nxh5a3eb.js.map} +1 -1
- package/dist/{chunk-qcbtr7hm.js → chunk-p0m3qgs5.js} +2 -2
- package/dist/{chunk-qcbtr7hm.js.map → chunk-p0m3qgs5.js.map} +1 -1
- package/dist/{chunk-jk8mn861.js → chunk-p5m0da00.js} +2 -2
- package/dist/{chunk-jk8mn861.js.map → chunk-p5m0da00.js.map} +1 -1
- package/dist/{chunk-fv223805.js → chunk-pb0m0ryf.js} +3 -3
- package/dist/{chunk-fv223805.js.map → chunk-pb0m0ryf.js.map} +1 -1
- package/dist/{chunk-7hbhbht2.js → chunk-pcxxnnad.js} +3 -3
- package/dist/{chunk-7hbhbht2.js.map → chunk-pcxxnnad.js.map} +1 -1
- package/dist/{chunk-2d92pev2.js → chunk-pxc51549.js} +2 -2
- package/dist/{chunk-2d92pev2.js.map → chunk-pxc51549.js.map} +1 -1
- package/dist/{chunk-454c7vn3.js → chunk-q1nq7n6y.js} +2 -2
- package/dist/{chunk-454c7vn3.js.map → chunk-q1nq7n6y.js.map} +1 -1
- package/dist/{chunk-48qybp63.js → chunk-qqchc40s.js} +2 -2
- package/dist/{chunk-48qybp63.js.map → chunk-qqchc40s.js.map} +1 -1
- package/dist/{chunk-feyr4851.js → chunk-r069158p.js} +2 -2
- package/dist/{chunk-feyr4851.js.map → chunk-r069158p.js.map} +1 -1
- package/dist/{chunk-ptjexzn1.js → chunk-r6v21jn6.js} +2 -2
- package/dist/{chunk-q4wdg0y3.js.map → chunk-r6v21jn6.js.map} +1 -1
- package/dist/{chunk-6j129573.js → chunk-r77f1482.js} +2 -2
- package/dist/{chunk-6j129573.js.map → chunk-r77f1482.js.map} +1 -1
- package/dist/{chunk-jmbdr550.js → chunk-rnjbja88.js} +2 -2
- package/dist/{chunk-jmbdr550.js.map → chunk-rnjbja88.js.map} +1 -1
- package/dist/{chunk-q8msf1gf.js → chunk-rq2k9frr.js} +2 -2
- package/dist/{chunk-q8msf1gf.js.map → chunk-rq2k9frr.js.map} +1 -1
- package/dist/chunk-se5ekvgb.js +19 -0
- package/dist/{chunk-anfs5mwm.js.map → chunk-se5ekvgb.js.map} +12 -11
- package/dist/{chunk-v6v03hy7.js → chunk-sqc6fkqt.js} +2 -2
- package/dist/{chunk-v6v03hy7.js.map → chunk-sqc6fkqt.js.map} +1 -1
- package/dist/{chunk-78cvy4je.js → chunk-tn71d46d.js} +2 -2
- package/dist/{chunk-78cvy4je.js.map → chunk-tn71d46d.js.map} +1 -1
- package/dist/{chunk-hkhxkeeb.js → chunk-v6q4990x.js} +3 -3
- package/dist/{chunk-hkhxkeeb.js.map → chunk-v6q4990x.js.map} +1 -1
- package/dist/{chunk-e41vdprh.js → chunk-w34j3cd3.js} +3 -3
- package/dist/{chunk-e41vdprh.js.map → chunk-w34j3cd3.js.map} +1 -1
- package/dist/{chunk-35fbxgjh.js → chunk-wzqxtrpt.js} +2 -2
- package/dist/{chunk-35fbxgjh.js.map → chunk-wzqxtrpt.js.map} +1 -1
- package/dist/{chunk-39p7ge47.js → chunk-x917yccy.js} +2 -2
- package/dist/{chunk-39p7ge47.js.map → chunk-x917yccy.js.map} +1 -1
- package/dist/{chunk-z2fnf49p.js → chunk-xzexftx1.js} +1 -1
- package/dist/{chunk-dfv5eqma.js → chunk-z4k18gnp.js} +2 -2
- package/dist/{chunk-dfv5eqma.js.map → chunk-z4k18gnp.js.map} +1 -1
- package/dist/{chunk-b6948dnh.js → chunk-z6gzasra.js} +2 -2
- package/dist/{chunk-b6948dnh.js.map → chunk-z6gzasra.js.map} +1 -1
- package/dist/{chunk-p57x55qd.js → chunk-zqpskwk9.js} +2 -2
- package/dist/{chunk-p57x55qd.js.map → chunk-zqpskwk9.js.map} +1 -1
- package/dist/chunks/ThemeProvider-Bz-y1g2i.js.map +1 -1
- package/dist/client/ClientRouter.d.ts.map +1 -1
- package/dist/client/Link.d.ts +3 -2
- package/dist/client/Link.d.ts.map +1 -1
- package/dist/client/Redirect.d.ts +3 -3
- package/dist/client/Redirect.d.ts.map +1 -1
- package/dist/client/index.d.ts +2 -2
- package/dist/client/index.d.ts.map +1 -1
- package/dist/client/index.js +5 -7
- package/dist/client/index.js.map +1 -1
- package/dist/client/types.d.ts +72 -2
- package/dist/client/types.d.ts.map +1 -1
- package/dist/client/useNavigate.d.ts +29 -6
- package/dist/client/useNavigate.d.ts.map +1 -1
- package/dist/client/usePrefetch.d.ts +13 -3
- package/dist/client/usePrefetch.d.ts.map +1 -1
- package/dist/config/index.js +1 -1
- package/dist/console/run.js +2 -2
- package/dist/console/run.js.map +1 -1
- package/dist/container/index.js +2 -2
- package/dist/container/index.js.map +1 -1
- package/dist/database/Connection.d.ts.map +1 -1
- package/dist/database/index.d.ts +1 -0
- package/dist/database/index.d.ts.map +1 -1
- package/dist/database/index.js +2 -2
- package/dist/database/index.js.map +1 -1
- package/dist/database/sqlitePath.d.ts +46 -0
- package/dist/database/sqlitePath.d.ts.map +1 -0
- package/dist/email/index.js +2 -2
- package/dist/email/index.js.map +1 -1
- package/dist/facades/Auth.d.ts.map +1 -1
- package/dist/facades/index.js +2 -2
- package/dist/facades/index.js.map +1 -1
- package/dist/foundation/index.js +2 -2
- package/dist/foundation/index.js.map +1 -1
- package/dist/http/ApiRouter.d.ts +1 -1
- package/dist/http/ApiRouter.d.ts.map +1 -1
- package/dist/http/index.js +2 -2
- package/dist/http/index.js.map +1 -1
- package/dist/i18n/dictionaryRuntime.js +2 -2
- package/dist/i18n/dictionaryRuntime.js.map +1 -1
- package/dist/i18n/index.js +2 -2
- package/dist/i18n/index.js.map +1 -1
- package/dist/kernel/index.js +2 -2
- package/dist/kernel/index.js.map +1 -1
- package/dist/orm/index.js +2 -2
- package/dist/orm/index.js.map +1 -1
- package/dist/server/index.js +2 -2
- package/dist/server/index.js.map +1 -1
- package/dist/services/index.js +2 -2
- package/dist/services/index.js.map +1 -1
- package/dist/services/queue/work.js +2 -2
- package/dist/services/queue/work.js.map +1 -1
- package/dist/support/index.js +2 -2
- package/dist/support/index.js.map +1 -1
- package/package.json +1 -1
- package/dist/ai/Agent.test-d.d.ts +0 -2
- package/dist/ai/Agent.test-d.d.ts.map +0 -1
- package/dist/ai/Schema.test-d.d.ts +0 -2
- package/dist/ai/Schema.test-d.d.ts.map +0 -1
- package/dist/ai/client/reducer.test-d.d.ts +0 -2
- package/dist/ai/client/reducer.test-d.d.ts.map +0 -1
- package/dist/ai/example.d.ts +0 -129
- package/dist/ai/example.d.ts.map +0 -1
- package/dist/chunk-4728yrmt.js +0 -5
- package/dist/chunk-4728yrmt.js.map +0 -10
- package/dist/chunk-anfs5mwm.js +0 -19
- package/dist/chunk-dq2hgzje.js +0 -5
- package/dist/chunk-f9ccncar.js +0 -5
- package/dist/chunk-f9ccncar.js.map +0 -13
- package/dist/client/useDictionary.test-d.d.ts +0 -2
- package/dist/client/useDictionary.test-d.d.ts.map +0 -1
- package/dist/console/builder.test-d.d.ts +0 -2
- package/dist/console/builder.test-d.d.ts.map +0 -1
- package/dist/http/ApiRouter.test-d.d.ts +0 -2
- package/dist/http/ApiRouter.test-d.d.ts.map +0 -1
- package/dist/http/McpRouter.test-d.d.ts +0 -2
- package/dist/http/McpRouter.test-d.d.ts.map +0 -1
- package/dist/services/events/FakeEventManager.test-d.d.ts +0 -2
- package/dist/services/events/FakeEventManager.test-d.d.ts.map +0 -1
- package/dist/services/events/Listener.test-d.d.ts +0 -2
- package/dist/services/events/Listener.test-d.d.ts.map +0 -1
- /package/dist/{chunk-rj3fnc4h.js.map → chunk-2ghpxrw1.js.map} +0 -0
- /package/dist/{chunk-pbx9p6g0.js.map → chunk-6waph5k8.js.map} +0 -0
- /package/dist/{chunk-z2fnf49p.js.map → chunk-xzexftx1.js.map} +0 -0
package/dist/http/index.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
// @bun
|
|
2
|
-
import{Ad as
|
|
2
|
+
import{Ad as I,Bd as J,Cd as K,kc as m,lc as n,mc as o,nc as u,oc as v,pc as w,pd as C,qd as D,rc as x,rd as E,sc as y,tc as z,uc as A,vc as B,xd as F,yd as G,zd as H}from"../chunk-se5ekvgb.js";import"../chunk-7438nrkm.js";import"../chunk-r77f1482.js";import{Ce as a,De as b,Fe as c,Ie as d,Je as e,Ke as f,Le as g,Me as h,Ne as i,Re as j,Se as k,Te as l,Ue as p,Ve as q,We as r,Xe as s,Ye as t}from"../chunk-a85fn4zf.js";import"../chunk-g2ywq30n.js";import"../chunk-87c0cy5v.js";import"../chunk-ftaxfq7p.js";import"../chunk-7xc64j6p.js";import"../chunk-70y8wajy.js";import"../chunk-tn71d46d.js";import"../chunk-pcxxnnad.js";import"../chunk-p5m0da00.js";import"../chunk-5g1j29p2.js";import"../chunk-2dvjj3ad.js";import"../chunk-9ch1q7nd.js";import"../chunk-r6v21jn6.js";export{f as toRangeHeaderValue,m as toMiddlewareList,e as resolveRange,d as parseRangeHeader,g as parseContentRange,B as middlewareConfigDefaults,c as getCookies,i as formatUnsatisfiedContentRange,h as formatContentRange,A as defineMiddlewareConfig,n as createUnsatisfiableResponse,o as createStreamResponse,x as createFileResponse,E as clientIp,y as ViewRouter,k as ValidationError,b as ResourceController,j as RequestBreakerError,D as RateLimitMiddleware,C as RateLimitExceededError,r as RangeNotSatisfiableError,J as PoliciesServiceProvider,K as Policies,z as Middleware,w as McpRouter,v as McpRouteDeclaration,q as InsufficientPermissionsError,l as HttpRequest,s as FileNotFoundError,H as CorsMiddleware,a as Controller,G as CacheMiddleware,I as CSRFMiddleware,p as AuthorizationError,F as AuthenticationMiddleware,t as AuthenticationError,u as ApiRouter};
|
|
3
3
|
|
|
4
|
-
//# debugId=
|
|
4
|
+
//# debugId=04E45E874725863164756E2164756E21
|
package/dist/http/index.js.map
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
// @bun
|
|
2
|
-
import{aa as y,ba as p}from"../chunk-
|
|
2
|
+
import{aa as y,ba as p}from"../chunk-q1nq7n6y.js";import{qa as c,ra as d,ta as l}from"../chunk-9a8qz3s7.js";import{Nf as e,Of as i,Qf as t,Rf as r,Sf as o,Tf as n,Uf as a,Vf as s}from"../chunk-70y8wajy.js";import"../chunk-r6v21jn6.js";export{o as setActiveLocale,r as seedDictionaries,t as preloadDictionaries,d as localeStrings,i as loadDictionary,n as getActiveLocale,e as dictionaryRegistrationMark,c as dictionaryLocales,l as dictionaryId,y as defineDictionary,s as createDictionarySink,a as __resetDictionaryRegistry,p as __gemi_dict__};
|
|
3
3
|
|
|
4
|
-
//# debugId=
|
|
4
|
+
//# debugId=2857EAE8A59497EA64756E2164756E21
|
package/dist/i18n/index.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
// @bun
|
|
2
|
-
import{aa as R}from"../chunk-
|
|
2
|
+
import{aa as R}from"../chunk-q1nq7n6y.js";import"../chunk-9a8qz3s7.js";import{Wa as L}from"../chunk-adj6dnvj.js";import{hc as E,ic as V}from"../chunk-p0m3qgs5.js";import"../chunk-z4k18gnp.js";import{Cc as j}from"../chunk-se5ekvgb.js";import"../chunk-7438nrkm.js";import"../chunk-r77f1482.js";import"../chunk-a85fn4zf.js";import"../chunk-g2ywq30n.js";import"../chunk-87c0cy5v.js";import"../chunk-ftaxfq7p.js";import"../chunk-7xc64j6p.js";import"../chunk-70y8wajy.js";import{ag as X}from"../chunk-tn71d46d.js";import"../chunk-pcxxnnad.js";import"../chunk-p5m0da00.js";import"../chunk-5g1j29p2.js";import"../chunk-2dvjj3ad.js";import"../chunk-9ch1q7nd.js";import"../chunk-r6v21jn6.js";import{createElement as J,Fragment as M,isValidElement as U}from"react";function $(q,B){let G=Object.values(B).some((z)=>typeof z==="function"&&U(z(""))),Q=/{{([^{}]+?)(?::([^{}\[\]]+?))?(?:\[(.*?)\])?}}/g;if(!G)return q.replace(Q,(W,O,_,Z)=>{let C=O.includes(":")?O.split(":")[0]:O,H=B[C];if(H===void 0)return W;if(typeof H==="function"){let K=H(Z!==void 0?Z:"");if(U(K))throw Error("JSX returned in string context");return String(K)}if(_)switch(_.toLowerCase()){case"number":return Number(H).toString();case"string":return String(H);case"boolean":return Boolean(H).toString();default:return String(H)}return String(H)});else{let z=[],W=0,O=null;while((O=Q.exec(q))!==null){let[_,Z,C,H]=O,F=O.index,K=Z.includes(":")?Z.split(":")[0]:Z;if(F>W)z.push(q.substring(W,F));let Y=B[K];if(Y===void 0)z.push(_);else if(typeof Y==="function"){let A=Y(H!==void 0?H:"");z.push(A)}else if(C)switch(C.toLowerCase()){case"number":z.push(Number(Y).toString());break;case"string":z.push(String(Y));break;case"boolean":z.push(Boolean(Y).toString());break;default:z.push(String(Y))}else z.push(String(Y));W=F+_.length}if(W<q.length)z.push(q.substring(W));return J(M,{},...z)}}class P{name;dictionary;constructor(q,B){this.name=q;this.dictionary=B}reference(q){if(typeof window<"u")throw Error("Cannot use reference in the browser");if(!this.dictionary?.[q])throw Error(`Translation not found for ${String(q)}`);return this.dictionary[q]}render(q,...B){let{locale:G=j.locale(),params:Q}={params:{},...B[0]};if(typeof window<"u")throw Error("Cannot use render in the browser");if(!this.dictionary?.[q]?.[G])throw Error(`Translation not found for ${String(q)} in ${String(G)}`);return $(this.dictionary[q][G],Q??{})}static create(q,B){return new P(q,B)}static text(q,...B){let{locale:G=j.locale(),params:Q}={params:{},...B?.[0]};if(!q?.[G])throw Error(`Translation not found for ${String(G)}`);return $(q[G],Q??{})}}async function N(q,B,...G){let{locale:Q=j.locale(),params:z}={params:{},...G[0]},O=(await q.load(String(Q)))[B];if(typeof O!=="string")throw Error(`Translation not found for "${B}" in "${String(Q)}" (dictionary ${q.id})`);return $(O,z??{})}export{V as translationConfigDefaults,N as translate,E as defineTranslationConfig,R as defineDictionary,X as Translator,L as TranslationServiceProvider,P as Dictionary};
|
|
3
3
|
|
|
4
|
-
//# debugId=
|
|
4
|
+
//# debugId=05D26B4E06225F6C64756E2164756E21
|
package/dist/i18n/index.js.map
CHANGED
|
@@ -7,6 +7,6 @@
|
|
|
7
7
|
"import { Lang } from \"../facades\";\nimport { parseTranslation } from \"../utils/parseTranslation\";\nimport type { ParseTranslationParamsServer, Prettify } from \"../utils/type\";\nimport type { DictionaryHandle } from \"./defineDictionary\";\nimport type { DictionaryTranslations } from \"./dictionaryShape\";\n\n/**\n * Read one string from a `defineDictionary` dictionary outside React — a\n * controller, a job, an email template.\n *\n * Async because a bundled dictionary loads its locale on demand. Server code\n * does not go through the bundler, so in practice this resolves without ever\n * yielding; the `await` is what makes the same call work either way.\n *\n * Kept out of `defineDictionary.ts` on purpose: that module is imported by\n * components and has to stay free of the server facades this one needs.\n */\nexport async function translate<\n T extends DictionaryTranslations,\n K extends keyof T & string,\n U extends keyof T[K],\n R = Prettify<ParseTranslationParamsServer<T[K][U] & string>>,\n>(\n dictionary: DictionaryHandle<T>,\n key: K,\n ...args: R extends Record<string, never>\n ? [args?: { locale?: U | (string & {}) }]\n : [args: { locale?: U | (string & {}); params: R }]\n): Promise<string> {\n const { locale = Lang.locale(), params } = { params: {}, ...args[0] };\n const strings = await dictionary.load(String(locale));\n const template = strings[key];\n\n if (typeof template !== \"string\") {\n throw new Error(\n `Translation not found for \"${key}\" in \"${String(locale)}\" (dictionary ${dictionary.id})`,\n );\n }\n\n return parseTranslation(template, (params ?? {}) as any) as string;\n}\n"
|
|
8
8
|
],
|
|
9
9
|
"mappings": ";8wBAAA,mBAAS,SAAe,eAAU,SAO3B,IAAS,JAAgB,JAAC,HAAkB,HAAwB,JAEzE,DAAM,HAAS,EAAO,EAAO,JAAM,HAAE,AACnC,JAAC,DACC,EAAO,IAAU,YACjB,EAAgB,EAAkC,EAAE,CAAC,CACzD,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AE9D,GADU,MAAM,EAAW,KAAK,OAAO,CAAM,CAAC,GAC3B,GAEzB,GAAI,OAAO,IAAa,SACtB,MAAU,MACR,8BAA8B,UAAY,OAAO,CAAM,kBAAkB,EAAW,KACtF,EAGF,OAAO,EAAiB,EAAW,GAAU,CAAC,CAAS",
|
|
10
|
-
"debugId": "
|
|
10
|
+
"debugId": "05D26B4E06225F6C64756E2164756E21",
|
|
11
11
|
"names": []
|
|
12
12
|
}
|
package/dist/kernel/index.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
// @bun
|
|
2
|
-
import{ya as D}from"../chunk-
|
|
2
|
+
import{ya as D}from"../chunk-3pwn2r6s.js";import{Va as i}from"../chunk-sqc6fkqt.js";import{Wa as y}from"../chunk-adj6dnvj.js";import{$a as e,Bb as d,Eb as p,Hb as c,Za as U,_a as m,ab as k,bb as A,hb as w,ib as g,kb as P,lb as S,mb as h,nb as R,qb as u,rb as l,ub as v}from"../chunk-nxg51m0q.js";import"../chunk-hq496pa4.js";import"../chunk-fmcq21hg.js";import{cc as r}from"../chunk-7wgk7q33.js";import"../chunk-p0m3qgs5.js";import"../chunk-z4k18gnp.js";import{cd as x,id as B,jd as I,md as L,nd as E,od as s,sd as C,td as K,ud as t,vd as o,yc as Yj,zc as a}from"../chunk-se5ekvgb.js";import{Gd as n}from"../chunk-7438nrkm.js";import{Xd as b}from"../chunk-r77f1482.js";import{Qe as _,Te as V}from"../chunk-a85fn4zf.js";import{hf as F}from"../chunk-g2ywq30n.js";import"../chunk-87c0cy5v.js";import"../chunk-ftaxfq7p.js";import"../chunk-7xc64j6p.js";import"../chunk-70y8wajy.js";import"../chunk-2bb3rdqq.js";import"../chunk-tn71d46d.js";import{cg as H,dg as f}from"../chunk-pcxxnnad.js";import{eg as T}from"../chunk-p5m0da00.js";import"../chunk-5g1j29p2.js";import"../chunk-731etrh2.js";import"../chunk-2dvjj3ad.js";import{rg as q}from"../chunk-9ch1q7nd.js";import"../chunk-r6v21jn6.js";function Jj(j){let W=j.headers.get("Cache-Control")?.toLowerCase()??"";return/(^|[\s,])(public|s-maxage)\b/.test(W)}var Nj=new Set,Wj={refusal:null,apply:(j)=>j,carried:null};async function M(j){let W=f(x);if(W.config.global.length===0)return Wj;let{pathname:X}=new URL(j.url),N=q(X),z=new V(j,{},N?"api":"view","");return await F.run(z,async()=>{let Y=F.getStore(),{headers:Z,cookies:zj}=Y,$=(J)=>{if(!Jj(J))return K(J,Z,zj);let G=new Headers(Z);return G.delete("Set-Cookie"),K(J,G,Nj)};try{return await W.runGlobalMiddleware(),{refusal:null,apply:$,carried:{user:Y.user}}}catch(J){let G=!N&&X.endsWith(".json");if(J?.kind===_){let O=N?C(J.payload.api):G?E(J.payload.viewData??J.payload.api):L(J.payload.view);return{refusal:$(O),apply:$,carried:null}}if(b(J)){console.error(J);let O=N||G?B():L(I());return{refusal:$(O),apply:$,carried:null}}throw J}finally{Y.destroy()}})}var Q=[R,l,D,w,c,k,g,u,S,m,P,p,v,h,y,d,A];class jj{config={};providers=[];services=[];serviceInstances=[];serviceTokens=new Set;servicesBooted=!1;models=[];app=new H;boot(){if(this.models.length>0)i(...this.models);else Xj();this.app.config.merge(this.config),H.setInstance(this.app),this.app.registerMany([...Q,...this.providers]),this.registerServices()}registerServices(){let j=this.serviceTokens;this.serviceInstances=[],this.serviceTokens=new Set,this.servicesBooted=!1;let W=new Map;for(let X of this.services){let N=typeof X==="function"?new X:X,z=N.constructor;if(!z.token)throw Error(`Service [${z.name}] is listed in \`services\` but does not declare a \`static token\`.`);let Y=W.get(z.token);if(Y)throw Error(`Services [${Y}] and [${z.name}] both declare the token "${z.token}". Tokens are the container's keys, so they must be unique.`);W.set(z.token,z.name);let Z=z;if(!j.has(z.token)&&this.app.bound(Z))throw Error(`Service [${z.name}] declares the token "${z.token}", which is already bound in the container by the framework or a provider. Binding it would replace that service everywhere, so pick a token nothing else owns.`);this.app.instance(Z,N),this.serviceInstances.push(N),this.serviceTokens.add(z.token)}}async waitForBoot(){await this.app.boot(),await this.bootServices(),e(this.app)}async bootServices(){if(this.servicesBooted)return;for(let j of this.serviceInstances)await j.boot();this.servicesBooted=!0}shutdown(j){return this.run(()=>this.app.shutdown(j))}run(j){return T.run(this.app,j)}resolve(j){return this.app.make(j)}apiRoutes(){return this.app.make(t)}viewRoutes(){return this.app.make(s)}domains(){return this.app.make(o)}broadcast(){return this.app.make(a)}queue(){return this.app.make(r)}globalMiddleware(j){return M(j)}destroy(){if(this.app.resolved(U))this.app.make(U).stop();if(this.app.flush(),H.getInstance()===this.app)H.setInstance(void 0);T.disable()}}function Xj(){if(Bun.env.NODE_ENV==="production")return;let j=n();if(j.length===0)return;console.warn(`[gemi] ${j.length} model${j.length===1?" is":"s are"} registered, but Kernel.models is empty.
|
|
3
3
|
Nested relation reads resolve a model by name, so a policy on a subclass that does not own its
|
|
4
4
|
`+" name is skipped inside every include \u2014 scoped at the root, "+`unscoped in an include, with nothing
|
|
5
5
|
to notice it. Declaring the modules registers each class under its own name and audits the set:
|
|
@@ -13,4 +13,4 @@ import{ya as D}from"../chunk-cdpeh7tt.js";import{Va as i}from"../chunk-v6v03hy7.
|
|
|
13
13
|
|
|
14
14
|
See docs/orm.md#your-model-class. Development only; this never prints in production.`)}export{Q as frameworkProviders,Yj as UserProvider,jj as Kernel};
|
|
15
15
|
|
|
16
|
-
//# debugId=
|
|
16
|
+
//# debugId=8A73D93DCDC77E0B64756E2164756E21
|
package/dist/kernel/index.js.map
CHANGED
|
@@ -7,6 +7,6 @@
|
|
|
7
7
|
"import { Application } from \"../foundation/Application\";\nimport type { ServiceProviderConstructor, ShutdownReport } from \"../foundation/Application\";\nimport type { ServiceToken } from \"../container/Container\";\nimport type { ConfigItems } from \"../support/Repository\";\nimport type { Service, ServiceConstructor } from \"../support/Service\";\nimport { registerModels } from \"../orm/registration\";\nimport { registeredNames } from \"../orm/registry\";\nimport { Scheduler } from \"../services/cron/Scheduler\";\nimport { BroadcastManager } from \"../services/pubsub/BroadcastManager\";\nimport { QueueManager } from \"../services/queue/QueueManager\";\nimport { startClaimingIfServing } from \"../services/queue/QueueServiceProvider\";\nimport { ApiRouteDispatcher } from \"../services/router/ApiRouteDispatcher\";\nimport { ViewRouteDispatcher } from \"../services/router/ViewRouteDispatcher\";\nimport { DomainRouter } from \"../services/router/DomainRouter\";\nimport { runGlobalMiddleware } from \"../services/router/globalMiddleware\";\nimport { kernelContext } from \"./context\";\nimport { frameworkProviders } from \"./providers\";\n\n/**\n * The app's entry point into the framework. A Kernel subclass declares what the\n * app adds — its `config` slices and any extra `providers` — and everything\n * else lives in the Application container it owns.\n */\nexport class Kernel {\n /**\n * App-level config, merged over the framework defaults. Each key is a config\n * slice: `{ mail: { ... }, route: { ... } }`, normally the modules under\n * `app/config`.\n */\n protected config: ConfigItems = {};\n\n /**\n * App-level providers, registered after the framework's own so they can\n * rebind anything the framework bound.\n */\n protected providers: ServiceProviderConstructor[] = [];\n\n /**\n * The app's own singleton services. Each is constructed during the\n * synchronous boot phase and its `boot()` awaited during the asynchronous\n * one, in the order listed — so a service whose `boot()` depends on another\n * goes after it.\n *\n * An entry is either the class itself or a configured instance from\n * `Service.with({ ... })`. Listing is explicit rather than discovered because\n * the order is load-bearing here, and because a service is always imported by\n * whatever injects it — there is no file the import graph would miss.\n */\n protected services: Array<ServiceConstructor | Service> = [];\n\n private serviceInstances: Service[] = [];\n private serviceTokens = new Set<string>();\n private servicesBooted = false;\n\n /**\n * The modules holding the app's model classes — normally\n * `[generated, models]`, the generated namespace and the barrel of subclasses\n * written over it. Every model class they export is registered under the name\n * its schema carries, later modules winning, and the whole set is audited\n * before anything else boots.\n *\n * ### Why this is a Kernel field and not a line in a file somewhere\n *\n * Registration used to be `register(\"User\", User)` next to each subclass, and\n * the failure mode of forgetting it is an authorization hole that nothing\n * reports: a relation read resolves its target by name, so an unregistered\n * policied subclass leaves the generated base owning the name and every\n * nested `include` of that model comes back unscoped. No error at the root\n * either, because `$exec`'s divergence guard begins `registered !== this` and\n * the base it is running on *is* the registered one. A model only ever read\n * through an include — a membership, a pivot, the kind that carries a tenant\n * scope — never trips anything.\n *\n * Listing the modules here says it once, in the same place the app already\n * declares its config slices and providers, and turns the mistake into a\n * failure to boot rather than a quiet cross-tenant read.\n *\n * It sees the modules it is given, so a model class in a file that no barrel\n * re-exports is still invisible. That is the residual, and it is a smaller\n * one: a barrel is a place to notice an omission, and thirteen `register`\n * lines scattered across thirteen files is not.\n */\n protected models: Array<Record<string, unknown>> = [];\n\n readonly app = new Application();\n\n /**\n * Phase one, synchronous: every provider is constructed and its `register()`\n * runs. Only bindings are recorded here — no service is instantiated, so this\n * is safe to call from a synchronous constructor (`new App({ kernel })`).\n * Phase two is `waitForBoot()`.\n */\n boot() {\n // Before the container, deliberately. This throws on a model whose policies\n // would be skipped, and the useful moment for that is the one where nothing\n // has been constructed and no request can be in flight.\n if (this.models.length > 0) registerModels(...this.models);\n else warnIfModelsAreRegisteredButUndeclared();\n\n this.app.config.merge(this.config);\n Application.setInstance(this.app);\n this.app.registerMany([...frameworkProviders, ...this.providers]);\n this.registerServices();\n }\n\n /**\n * Constructs every listed service and binds it into the container. Runs after\n * the providers have registered, so a provider's `boot()` can `inject()` one;\n * a `Service` constructor does no I/O, so doing this synchronously costs\n * nothing beyond the field initializers.\n */\n private registerServices() {\n // What a previous pass bound, so re-running this on the same kernel is not\n // mistaken for a collision with something else.\n const ours = this.serviceTokens;\n\n this.serviceInstances = [];\n this.serviceTokens = new Set();\n this.servicesBooted = false;\n\n const owners = new Map<string, string>();\n\n for (const declaration of this.services) {\n const instance =\n typeof declaration === \"function\" ? new declaration() : declaration;\n const ctor = instance.constructor as ServiceConstructor;\n\n if (!ctor.token) {\n throw new Error(\n `Service [${ctor.name}] is listed in \\`services\\` but does not declare a \\`static token\\`.`,\n );\n }\n\n // Two services under one token is the failure this refuses to have\n // silently: the second would replace the first in the container, and\n // every `inject()` written against either would hand back whichever was\n // listed last.\n const owner = owners.get(ctor.token);\n if (owner) {\n throw new Error(\n `Services [${owner}] and [${ctor.name}] both declare the token \"${ctor.token}\". Tokens are the container's keys, so they must be unique.`,\n );\n }\n owners.set(ctor.token, ctor.name);\n\n // The same failure one level out. `Container.instance()` writes into\n // `instances`, which `make()` consults before `bindings`, so a token that\n // is already spoken for is not shared with its owner — it replaces it, for\n // every `app()` and `inject()` in the process. An app service that named\n // itself \"mail\" would leave `Mail.send()` resolving to an object with no\n // `send`, and the boot that caused it would report nothing. Providers have\n // all registered by now, so anything bound here belongs to somebody else.\n const token = ctor as unknown as ServiceToken<Service>;\n if (!ours.has(ctor.token) && this.app.bound(token)) {\n throw new Error(\n `Service [${ctor.name}] declares the token \"${ctor.token}\", which is already bound in the container by the framework or a provider. Binding it would replace that service everywhere, so pick a token nothing else owns.`,\n );\n }\n\n this.app.instance(token, instance);\n this.serviceInstances.push(instance);\n this.serviceTokens.add(ctor.token);\n }\n }\n\n /**\n * Phase two, asynchronous: every provider's `boot()` runs, in registration\n * order, after all of them have registered. Idempotent.\n */\n async waitForBoot() {\n await this.app.boot();\n await this.bootServices();\n // Last, once every job — queued listeners included — is registered.\n startClaimingIfServing(this.app);\n }\n\n /**\n * Phase two for services, after every provider's `boot()` — so a service may\n * use the facades and anything else a provider owns. Idempotent, like the\n * provider phase it follows.\n */\n private async bootServices() {\n if (this.servicesBooted) {\n return;\n }\n for (const service of this.serviceInstances) {\n await service.boot();\n }\n this.servicesBooted = true;\n }\n\n /**\n * Every provider's `shutdown()`, in reverse registration order, inside the\n * application context — so a hook may use the facades, as a cron tick or a\n * request would. See `Application.shutdown` for the deadline and the\n * report. Idempotent.\n */\n shutdown(options?: { timeoutMs?: number }): Promise<ShutdownReport> {\n return this.run(() => this.app.shutdown(options));\n }\n\n run<T>(cb: () => T) {\n return kernelContext.run(this.app, cb);\n }\n\n /**\n * Resolve a service by token. Callers outside this module should prefer the\n * named accessors below or `app()`; this exists for tooling that holds a\n * Kernel but no ambient context.\n */\n resolve<T>(token: ServiceToken<T>): T {\n return this.app.make(token);\n }\n\n // Named accessors. `app/App.ts` goes through these rather than importing the\n // service classes itself — see the note in that file about the two copies of\n // gemi that coexist at build time.\n apiRoutes(): ApiRouteDispatcher {\n return this.app.make(ApiRouteDispatcher);\n }\n\n viewRoutes(): ViewRouteDispatcher {\n return this.app.make(ViewRouteDispatcher);\n }\n\n domains(): DomainRouter {\n return this.app.make(DomainRouter);\n }\n\n broadcast(): BroadcastManager {\n return this.app.make(BroadcastManager);\n }\n\n queue(): QueueManager {\n return this.app.make(QueueManager);\n }\n\n /** The `global` middleware list for one request. Call it inside `run`. */\n globalMiddleware(req: Request) {\n return runGlobalMiddleware(req);\n }\n\n destroy() {\n // Only touch services that were actually resolved — resolving one here\n // would construct it purely to tear it down.\n if (this.app.resolved(Scheduler)) {\n this.app.make(Scheduler).stop();\n }\n\n this.app.flush();\n\n if (Application.getInstance() === this.app) {\n Application.setInstance(undefined);\n }\n\n kernelContext.disable();\n }\n}\n\n/**\n * Says something to an application that has models and has not declared them.\n *\n * Without this the fix for #316 defaults to off. `models` is `[]`, `boot()`\n * no-ops, and an app upgrading from 0.48 is in exactly the state the issue\n * describes until somebody edits their Kernel by hand — while the only place\n * that says to is the **Setup** section of `docs/orm.md`, which an existing app\n * read once and will not read again. #316 was filed by an app mid-migration\n * with a 79-model schema, which is precisely the reader who never sees it.\n *\n * The condition is what makes this worth printing. A populated registry with an\n * empty `models` means the generated `index.ts` was imported and its bases are\n * what every nested read resolves to — so if any policy lives on a subclass, it\n * is being skipped inside includes right now. A Kernel with no ORM at all has\n * an empty registry and hears nothing.\n *\n * Development only, and a warning rather than a throw: an app in this state is\n * running today, and turning a working deploy into a failure to start over an\n * arrangement that *might* be fine is not a patch-level thing to do. The\n * failure it points at is silent, so the fix for it has to be noisy somewhere,\n * and the terminal an author is already looking at is the cheapest somewhere\n * there is.\n */\nfunction warnIfModelsAreRegisteredButUndeclared(): void {\n if (process.env.NODE_ENV === \"production\") return;\n\n const registered = registeredNames();\n if (registered.length === 0) return;\n\n console.warn(\n `[gemi] ${registered.length} model${registered.length === 1 ? \" is\" : \"s are\"} ` +\n `registered, but Kernel.models is empty.\\n` +\n ` Nested relation reads resolve a model by name, so a policy on a ` +\n `subclass that does not own its\\n` +\n ` name is skipped inside every include — scoped at the root, ` +\n `unscoped in an include, with nothing\\n` +\n ` to notice it. Declaring the modules registers each class under ` +\n `its own name and audits the set:\\n\\n` +\n ` import * as generated from \"../models/generated\"\\n` +\n ` import * as models from \"../models\"\\n\\n` +\n ` export default class extends Kernel {\\n` +\n ` models = [generated, models]\\n` +\n ` }\\n\\n` +\n ` See docs/orm.md#your-model-class. Development only; this never ` +\n `prints in production.`,\n );\n}\n"
|
|
8
8
|
],
|
|
9
9
|
"mappings": ";myCAoCA,IAAS,HAAe,JAAC,HAAoB,JAC3C,DAAM,HAAe,HAAS,GAAQ,DAAI,UAAe,FAAG,OAAY,FAAK,FAC7E,CAAO,0BAA+B,AAAK,JAAY,HAGzD,DAAM,FAAY,DAAI,DAEhB,FAAuC,JAC3C,QAAS,KACT,MAAO,CAAC,IAAa,EACrB,QAAS,IACX,EA4BA,eAAsB,CAAmB,CAAC,EAAgD,CACxF,IAAM,EAAW,EAAI,CAAkB,EACvC,GAAI,EAAS,OAAO,OAAO,SAAW,EACpC,OAAO,GAGT,IAAQ,YAAa,IAAI,IAAI,EAAI,GAAG,EAC9B,EAAQ,EAAU,CAAQ,EAC1B,EAAc,IAAI,EAAY,EAAK,CAAC,EAAG,EAAQ,MAAQ,OAAQ,EAAE,EAEvE,OAAO,MAAM,EAAe,IAAI,EAAa,SAAY,CACvD,IAAM,EAAM,EAAe,SAAS,GAE5B,UAAS,YAAY,EACvB,EAAQ,CAAC,IAAuB,CACpC,GAAI,CAAC,GAAgB,CAAQ,EAC3B,OAAO,EAAyB,EAAU,EAAS,EAAO,EAE5D,IAAM,EAAiB,IAAI,QAAQ,CAAO,EAE1C,OADA,EAAe,OAAO,YAAY,EAC3B,EAAyB,EAAU,EAAgB,EAAS,GAGrE,GAA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