gemi 0.196.1 → 0.197.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/index.js +2 -2
- package/dist/ai/index.js.map +1 -1
- package/dist/app/index.js +1 -1
- package/dist/bun/plugin.js +1 -1
- package/dist/bun/preload.js +1 -1
- package/dist/{chunk-mgdrf89p.js → chunk-02jze3te.js} +2 -2
- package/dist/{chunk-mgdrf89p.js.map → chunk-02jze3te.js.map} +1 -1
- package/dist/{chunk-nk7nmtng.js → chunk-20y02g4n.js} +2 -2
- package/dist/{chunk-nk7nmtng.js.map → chunk-20y02g4n.js.map} +1 -1
- package/dist/{chunk-9dxp7t3n.js → chunk-2g2cntdm.js} +2 -2
- package/dist/{chunk-9dxp7t3n.js.map → chunk-2g2cntdm.js.map} +1 -1
- package/dist/{chunk-228w21t6.js → chunk-2qbfvb6m.js} +2 -2
- package/dist/{chunk-228w21t6.js.map → chunk-2qbfvb6m.js.map} +1 -1
- package/dist/{chunk-m0dfgmbj.js → chunk-2v83pskm.js} +1 -1
- package/dist/{chunk-652a9mr0.js → chunk-2z160r1b.js} +2 -2
- package/dist/{chunk-652a9mr0.js.map → chunk-2z160r1b.js.map} +1 -1
- package/dist/{chunk-28macaes.js → chunk-3am1e8ya.js} +2 -2
- package/dist/{chunk-28macaes.js.map → chunk-3am1e8ya.js.map} +1 -1
- package/dist/{chunk-rp6ss7v3.js → chunk-3bsw9sra.js} +2 -2
- package/dist/{chunk-rp6ss7v3.js.map → chunk-3bsw9sra.js.map} +1 -1
- package/dist/{chunk-j56zk5a0.js → chunk-4f2xy9ws.js} +3 -3
- package/dist/{chunk-j56zk5a0.js.map → chunk-4f2xy9ws.js.map} +1 -1
- package/dist/{chunk-08m9egzx.js → chunk-4ftk3z34.js} +2 -2
- package/dist/{chunk-08m9egzx.js.map → chunk-4ftk3z34.js.map} +1 -1
- package/dist/{chunk-7t60d5qy.js → chunk-4k62r4hv.js} +1 -1
- package/dist/{chunk-9hjxpdjt.js → chunk-51n7yky9.js} +1 -1
- package/dist/{chunk-wvq3c25z.js → chunk-5qaxde5h.js} +3 -3
- package/dist/{chunk-wvq3c25z.js.map → chunk-5qaxde5h.js.map} +1 -1
- package/dist/{chunk-pmt2jt9b.js → chunk-6nj9xjsm.js} +2 -2
- package/dist/{chunk-pmt2jt9b.js.map → chunk-6nj9xjsm.js.map} +1 -1
- package/dist/{chunk-g7h28xcr.js → chunk-7q42fej6.js} +2 -2
- package/dist/{chunk-g7h28xcr.js.map → chunk-7q42fej6.js.map} +1 -1
- package/dist/{chunk-p4eger3g.js → chunk-7sadg8d7.js} +3 -3
- package/dist/{chunk-p4eger3g.js.map → chunk-7sadg8d7.js.map} +1 -1
- package/dist/chunk-7xy7ebkx.js +117 -0
- package/dist/{chunk-5qcqwcp7.js.map → chunk-7xy7ebkx.js.map} +11 -11
- package/dist/{chunk-2485bwzs.js → chunk-8mmskn4g.js} +3 -3
- package/dist/{chunk-2485bwzs.js.map → chunk-8mmskn4g.js.map} +1 -1
- package/dist/{chunk-hswnqn33.js → chunk-8xckmvea.js} +2 -2
- package/dist/{chunk-hswnqn33.js.map → chunk-8xckmvea.js.map} +1 -1
- package/dist/{chunk-pqr01waj.js → chunk-9dnbf9q8.js} +2 -2
- package/dist/{chunk-pqr01waj.js.map → chunk-9dnbf9q8.js.map} +1 -1
- package/dist/{chunk-ermvtpy9.js → chunk-9ky5d5js.js} +3 -3
- package/dist/{chunk-ermvtpy9.js.map → chunk-9ky5d5js.js.map} +1 -1
- package/dist/{chunk-3fcd8a47.js → chunk-a4kk68xy.js} +2 -2
- package/dist/{chunk-3fcd8a47.js.map → chunk-a4kk68xy.js.map} +1 -1
- package/dist/{chunk-1x23scpn.js → chunk-a77w04sw.js} +2 -2
- package/dist/{chunk-1x23scpn.js.map → chunk-a77w04sw.js.map} +1 -1
- package/dist/{chunk-zkcky8pg.js → chunk-arb0qkrm.js} +2 -2
- package/dist/{chunk-zkcky8pg.js.map → chunk-arb0qkrm.js.map} +1 -1
- package/dist/{chunk-paawtkza.js → chunk-bcydd231.js} +2 -2
- package/dist/{chunk-paawtkza.js.map → chunk-bcydd231.js.map} +1 -1
- package/dist/{chunk-hmn6pa78.js → chunk-c601phyd.js} +2 -2
- package/dist/{chunk-hmn6pa78.js.map → chunk-c601phyd.js.map} +1 -1
- package/dist/{chunk-d03pk1c0.js → chunk-cpgc5q74.js} +2 -2
- package/dist/{chunk-d03pk1c0.js.map → chunk-cpgc5q74.js.map} +1 -1
- package/dist/{chunk-39w89wss.js → chunk-dbe8zgyb.js} +2 -2
- package/dist/{chunk-39w89wss.js.map → chunk-dbe8zgyb.js.map} +1 -1
- package/dist/{chunk-qrn6ch3t.js → chunk-degz94dk.js} +2 -2
- package/dist/{chunk-qrn6ch3t.js.map → chunk-degz94dk.js.map} +1 -1
- package/dist/{chunk-qg9pyxg7.js → chunk-e0d6az7p.js} +2 -2
- package/dist/{chunk-qg9pyxg7.js.map → chunk-e0d6az7p.js.map} +1 -1
- package/dist/{chunk-g02gqhq0.js → chunk-ecyq52t3.js} +3 -3
- package/dist/{chunk-g02gqhq0.js.map → chunk-ecyq52t3.js.map} +1 -1
- package/dist/chunk-es05kqtp.js +15 -0
- package/dist/{chunk-nphb176s.js.map → chunk-es05kqtp.js.map} +6 -5
- package/dist/{chunk-qjwv9xfq.js → chunk-evdca0b9.js} +2 -2
- package/dist/{chunk-qjwv9xfq.js.map → chunk-evdca0b9.js.map} +1 -1
- package/dist/{chunk-0xssrbar.js → chunk-ff16m7gm.js} +2 -2
- package/dist/{chunk-0xssrbar.js.map → chunk-ff16m7gm.js.map} +1 -1
- package/dist/{chunk-dn20caf2.js → chunk-fyk66c5e.js} +2 -2
- package/dist/{chunk-dn20caf2.js.map → chunk-fyk66c5e.js.map} +1 -1
- package/dist/{chunk-vgxkt9vd.js → chunk-fzy1z97a.js} +2 -2
- package/dist/{chunk-q1aaqhnw.js.map → chunk-fzy1z97a.js.map} +1 -1
- package/dist/{chunk-1ghbn9jg.js → chunk-g1th116z.js} +2 -2
- package/dist/{chunk-1ghbn9jg.js.map → chunk-g1th116z.js.map} +1 -1
- package/dist/{chunk-2yzv5v3m.js → chunk-gk0d26zw.js} +2 -2
- package/dist/{chunk-2yzv5v3m.js.map → chunk-gk0d26zw.js.map} +1 -1
- package/dist/{chunk-sqqby94y.js → chunk-gk12v51y.js} +1 -1
- package/dist/{chunk-ftvc1a0k.js → chunk-htnbmbx1.js} +2 -2
- package/dist/{chunk-ftvc1a0k.js.map → chunk-htnbmbx1.js.map} +1 -1
- package/dist/{chunk-pg5hm00s.js → chunk-j84r2j7a.js} +2 -2
- package/dist/{chunk-pg5hm00s.js.map → chunk-j84r2j7a.js.map} +1 -1
- package/dist/{chunk-1705yamg.js → chunk-kjgy7sk0.js} +2 -2
- package/dist/{chunk-1705yamg.js.map → chunk-kjgy7sk0.js.map} +1 -1
- package/dist/{chunk-6m9qrs6d.js → chunk-kjygnj7y.js} +2 -2
- package/dist/{chunk-6m9qrs6d.js.map → chunk-kjygnj7y.js.map} +1 -1
- package/dist/{chunk-n914rs58.js → chunk-kzy4pyqb.js} +3 -3
- package/dist/{chunk-n914rs58.js.map → chunk-kzy4pyqb.js.map} +1 -1
- package/dist/{chunk-07zfrfbg.js → chunk-mk4x0vtp.js} +2 -2
- package/dist/{chunk-07zfrfbg.js.map → chunk-mk4x0vtp.js.map} +1 -1
- package/dist/{chunk-gmcttf0f.js → chunk-mnmz8n5k.js} +2 -2
- package/dist/{chunk-gmcttf0f.js.map → chunk-mnmz8n5k.js.map} +1 -1
- package/dist/{chunk-wgqppqcn.js → chunk-n01mhwkj.js} +3 -3
- package/dist/{chunk-wgqppqcn.js.map → chunk-n01mhwkj.js.map} +1 -1
- package/dist/{chunk-1t264fkn.js → chunk-nbry43s8.js} +2 -2
- package/dist/{chunk-1t264fkn.js.map → chunk-nbry43s8.js.map} +1 -1
- package/dist/{chunk-beckfwe9.js → chunk-ng5qfkgp.js} +2 -2
- package/dist/{chunk-beckfwe9.js.map → chunk-ng5qfkgp.js.map} +1 -1
- package/dist/{chunk-aycfrzh1.js → chunk-nnn2f1ew.js} +2 -2
- package/dist/{chunk-aycfrzh1.js.map → chunk-nnn2f1ew.js.map} +1 -1
- package/dist/{chunk-reaty2mv.js → chunk-pvx66dq2.js} +3 -3
- package/dist/{chunk-reaty2mv.js.map → chunk-pvx66dq2.js.map} +1 -1
- package/dist/{chunk-j49vh5bs.js → chunk-qw6aa9fy.js} +2 -2
- package/dist/{chunk-j49vh5bs.js.map → chunk-qw6aa9fy.js.map} +1 -1
- package/dist/{chunk-28fz99pn.js → chunk-qx1vc11v.js} +2 -2
- package/dist/{chunk-28fz99pn.js.map → chunk-qx1vc11v.js.map} +1 -1
- package/dist/{chunk-a34ec9rq.js → chunk-rk34z2wa.js} +2 -2
- package/dist/{chunk-a34ec9rq.js.map → chunk-rk34z2wa.js.map} +1 -1
- package/dist/{chunk-m08p5mre.js → chunk-rnjjn09d.js} +2 -2
- package/dist/{chunk-m08p5mre.js.map → chunk-rnjjn09d.js.map} +1 -1
- package/dist/{chunk-q1aaqhnw.js → chunk-rqs2s5nh.js} +2 -2
- package/dist/{chunk-vgxkt9vd.js.map → chunk-rqs2s5nh.js.map} +1 -1
- package/dist/{chunk-zzdvdr5a.js → chunk-s57n552b.js} +4 -4
- package/dist/{chunk-zzdvdr5a.js.map → chunk-s57n552b.js.map} +1 -1
- package/dist/{chunk-ejktrxp2.js → chunk-spsheyx9.js} +1 -1
- package/dist/{chunk-7zf8rnsb.js → chunk-sxww1ka5.js} +2 -2
- package/dist/{chunk-7zf8rnsb.js.map → chunk-sxww1ka5.js.map} +1 -1
- package/dist/chunk-tgbky7fc.js +5 -0
- package/dist/{chunk-ggbf1web.js.map → chunk-tgbky7fc.js.map} +1 -1
- package/dist/{chunk-03q4j7wa.js → chunk-tv33103m.js} +1 -1
- package/dist/{chunk-p2vasd1z.js → chunk-tvdmx66x.js} +2 -2
- package/dist/{chunk-p2vasd1z.js.map → chunk-tvdmx66x.js.map} +1 -1
- package/dist/{chunk-f6css3z6.js → chunk-v4ka65g8.js} +2 -2
- package/dist/{chunk-f6css3z6.js.map → chunk-v4ka65g8.js.map} +1 -1
- package/dist/{chunk-a02bmp0q.js → chunk-wprzrnqh.js} +2 -2
- package/dist/{chunk-a02bmp0q.js.map → chunk-wprzrnqh.js.map} +1 -1
- package/dist/{chunk-tj7z65ba.js → chunk-x05mj7ye.js} +2 -2
- package/dist/{chunk-tj7z65ba.js.map → chunk-x05mj7ye.js.map} +1 -1
- package/dist/{chunk-2g2fsr71.js → chunk-xb9zjaes.js} +2 -2
- package/dist/{chunk-2g2fsr71.js.map → chunk-xb9zjaes.js.map} +1 -1
- package/dist/{chunk-b6zqjyn1.js → chunk-y50h3cd6.js} +2 -2
- package/dist/{chunk-b6zqjyn1.js.map → chunk-y50h3cd6.js.map} +1 -1
- package/dist/{chunk-5bfrr8x5.js → chunk-y9pzr1wc.js} +2 -2
- package/dist/{chunk-5bfrr8x5.js.map → chunk-y9pzr1wc.js.map} +1 -1
- package/dist/{chunk-8e17k7ht.js → chunk-yzazktke.js} +3 -3
- package/dist/{chunk-8e17k7ht.js.map → chunk-yzazktke.js.map} +3 -3
- package/dist/{chunk-6efjnt6r.js → chunk-zcmfkb9f.js} +2 -2
- package/dist/{chunk-6efjnt6r.js.map → chunk-zcmfkb9f.js.map} +1 -1
- package/dist/{chunk-trqt1kkd.js → chunk-zehvtpgm.js} +2 -2
- package/dist/{chunk-trqt1kkd.js.map → chunk-zehvtpgm.js.map} +1 -1
- package/dist/{chunk-bc7hr358.js → chunk-zrykhpn9.js} +3 -3
- package/dist/{chunk-bc7hr358.js.map → chunk-zrykhpn9.js.map} +1 -1
- package/dist/{chunk-8fdk8bfd.js → chunk-zryrem89.js} +3 -3
- package/dist/{chunk-8fdk8bfd.js.map → chunk-zryrem89.js.map} +1 -1
- package/dist/{chunk-fhfkcmkc.js → chunk-zv55h4x9.js} +2 -2
- package/dist/{chunk-fhfkcmkc.js.map → chunk-zv55h4x9.js.map} +1 -1
- package/dist/{chunk-dfmxvp8p.js → chunk-zzmgz14a.js} +2 -2
- package/dist/{chunk-dfmxvp8p.js.map → chunk-zzmgz14a.js.map} +1 -1
- package/dist/client/documentTree.d.ts +20 -0
- package/dist/client/documentTree.d.ts.map +1 -0
- package/dist/client/index.js +35 -11
- package/dist/client/index.js.map +1 -1
- package/dist/client/init.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/index.js +2 -2
- package/dist/database/index.js.map +1 -1
- package/dist/email/index.js +2 -2
- package/dist/email/index.js.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 +7 -0
- package/dist/http/ApiRouter.d.ts.map +1 -1
- package/dist/http/BodyLimitMiddleware.d.ts +3 -0
- package/dist/http/BodyLimitMiddleware.d.ts.map +1 -1
- package/dist/http/HttpRequest.d.ts.map +1 -1
- package/dist/http/bodyLimit.d.ts +21 -1
- package/dist/http/bodyLimit.d.ts.map +1 -1
- package/dist/http/index.js +2 -2
- package/dist/http/index.js.map +1 -1
- package/dist/http/middleware-config.d.ts +12 -3
- package/dist/http/middleware-config.d.ts.map +1 -1
- package/dist/http/validate.d.ts +8 -0
- package/dist/http/validate.d.ts.map +1 -1
- package/dist/i18n/Translator.d.ts +5 -0
- package/dist/i18n/Translator.d.ts.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/probe/index.js +2 -2
- package/dist/probe/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/middleware/MiddlewareRegistry.d.ts +16 -5
- package/dist/services/middleware/MiddlewareRegistry.d.ts.map +1 -1
- package/dist/services/queue/work.js +2 -2
- package/dist/services/queue/work.js.map +1 -1
- package/dist/services/router/ApiRouteDispatcher.d.ts.map +1 -1
- package/dist/services/router/ViewRouteDispatcher.d.ts.map +1 -1
- package/dist/services/router/createFlatApiRoutes.d.ts +3 -0
- package/dist/services/router/createFlatApiRoutes.d.ts.map +1 -1
- package/dist/stats/route-table.js +1 -1
- package/dist/support/index.js +2 -2
- package/dist/support/index.js.map +1 -1
- package/dist/vitest/index.js +1 -1
- package/package.json +1 -1
- package/dist/chunk-5qcqwcp7.js +0 -117
- package/dist/chunk-ggbf1web.js +0 -5
- package/dist/chunk-nphb176s.js +0 -15
- /package/dist/{chunk-m0dfgmbj.js.map → chunk-2v83pskm.js.map} +0 -0
- /package/dist/{chunk-7t60d5qy.js.map → chunk-4k62r4hv.js.map} +0 -0
- /package/dist/{chunk-9hjxpdjt.js.map → chunk-51n7yky9.js.map} +0 -0
- /package/dist/{chunk-sqqby94y.js.map → chunk-gk12v51y.js.map} +0 -0
- /package/dist/{chunk-ejktrxp2.js.map → chunk-spsheyx9.js.map} +0 -0
- /package/dist/{chunk-03q4j7wa.js.map → chunk-tv33103m.js.map} +0 -0
|
@@ -5,6 +5,6 @@
|
|
|
5
5
|
"import { existsSync, readdirSync } from \"node:fs\";\nimport { join, relative } from \"node:path\";\n\n/**\n * Finding the classes an application declared and never imported — the walk\n * #322 and #323 both end at.\n *\n * ### Why it has to run the files\n *\n * A job that is written and not listed does not fail; it disappears.\n * `QueueManager.run` looks a dispatched name up in the map its config built and\n * drops what is not there, so the dispatch is simply lost. A cron drifts worse:\n * nothing is waiting on a tick, so a job that never fires reports nothing to\n * anyone. What both come down to is that `app/config/queue.ts` naming every\n * `Job` subclass is the *only* thing putting those classes in the module graph —\n * the list and the directory are two spellings of one set, kept in step by hand.\n *\n * The way out of that is to read the directory, and there is no static read that\n * will do: the class does not exist until its module has run. So **every file\n * walked here is imported**, and a file that *does something* when imported does\n * it here — at boot, in production, on every start. `gemi check models` makes\n * the same trade for the same reason and pays it once per CI run; a caller of\n * this pays it once per process.\n *\n * ### What that asks of a caller\n *\n * **Point it at a directory of class declarations, not at `app/`.** The skip\n * rules on `sourceFiles` drop what certainly is not one — tests, benchmarks,\n * `.d.ts`, vendored packages — and nothing else. Widening the guesses is how a\n * discovery pass ends up quietly covering less than the directory holds, which\n * is the same silence in a new place.\n *\n * **Let a broken file stop the boot.** `discoverClasses` rethrows an import\n * failure naming the file rather than dropping it and carrying on, for the same\n * reason: four classes found out of five looks exactly like five out of five.\n *\n * **Leave a way out.** Discovery is what should happen when an app said\n * nothing. An app that lists its classes explicitly must not reach this file at\n * all — that is the escape hatch for a directory holding something this cannot\n * import, and it is the sentence an error from here should point at.\n *\n * ### One more thing worth knowing\n *\n * This imports by absolute path, while the application imports the same files\n * through the `@/app/*` alias. Bun keys its module registry by the *resolved*\n * path, so those two specifiers land on one module: a job already reached from\n * a controller is not evaluated a second time here, and the class object is the\n * same one. `gemi build` leaves that true in production — `packages: \"external\"`\n * keeps the app's own code out of `dist/server/server.mjs` and resolves it from\n * source at runtime, exactly as `gemi dev` does.\n *\n * Nothing here depends on that holding, and deliberately: `QueueManager` and the\n * `Scheduler`'s cross-reload registry are both keyed by name rather than by\n * class identity, so a build that did inline the app's modules would produce a\n * duplicate class object and still register the right job. Worth knowing before\n * writing a registry keyed the other way.\n */\n\n/**\n * The files under `dir` that could declare a class.\n *\n * Everything underneath it, because apps do group classes into folders, minus\n * what cannot be one. Each of these is going to be *imported*, so the exclusions\n * are about what is certainly not source rather than about what is probably not:\n *\n * - **Declaration files.** `.d.ts` has no runtime module behind it.\n * - **Tests, type tests and benchmarks**, by the suffix a runner already\n * recognises.\n * - **Dot-directories and `node_modules`.**\n * - **Any directory holding a `package.json`.** That is a package that happens\n * to live here — a vendored client, a generated SDK — not this app's source,\n * and importing its entry point runs somebody else's module graph. The\n * template has two under `app/models`.\n *\n * `ignore` is the escape hatch for the rest: a path prefix, relative to `dir`,\n * naming a file or a directory of adjacent code that runs something on import.\n * Nothing is ignored by default.\n *\n * The order is the same on every run over the same tree, which matters because\n * the caller is going to import in it: entries are sorted per directory before\n * recursing, and `readdirSync` order is the filesystem's rather than\n * alphabetical — a tree written `A.ts` then `B.ts` reads back `B.ts` first on\n * the machines this was tested on. Sorting per directory rather than sorting the\n * finished list is deliberate: for a tree holding both `a.ts` and `a/b.ts`, this\n * emits `a/b.ts` first, because the directory sorts before the file.\n *\n * A directory that does not exist yields an empty list rather than throwing.\n * \"The app has no jobs yet\" is an ordinary state and not this function's to\n * complain about — but it is indistinguishable from \"the app's source did not\n * ship\", so a caller that boots on the answer owes the reader a word about which\n * one it got.\n */\nexport function sourceFiles(dir: string, ignore: string[] = []): string[] {\n const out: string[] = [];\n\n const ignored = (path: string) => {\n const rel = relative(dir, path).split(\"\\\\\").join(\"/\");\n return ignore.some(\n (pattern) => rel === pattern || rel.startsWith(`${pattern}/`),\n );\n };\n\n const walk = (current: string) => {\n for (const entry of readdirSync(current, { withFileTypes: true }).sort(\n (a, b) => (a.name < b.name ? -1 : a.name > b.name ? 1 : 0),\n )) {\n const path = join(current, entry.name);\n if (ignored(path)) continue;\n\n if (entry.isDirectory()) {\n if (entry.name.startsWith(\".\") || entry.name === \"node_modules\")\n continue;\n if (existsSync(join(path, \"package.json\"))) continue;\n walk(path);\n continue;\n }\n\n if (!entry.name.endsWith(\".ts\") && !entry.name.endsWith(\".tsx\")) continue;\n if (entry.name.endsWith(\".d.ts\")) continue;\n if (/\\.(test|test-d|spec|bench)\\.tsx?$/.test(entry.name)) continue;\n\n out.push(path);\n }\n };\n\n if (!existsSync(dir)) return out;\n\n walk(dir);\n return out;\n}\n\n/**\n * A class, as much of one as this file can name. `abstract` so that a base an\n * app never instantiates directly is a legal argument.\n */\ntype ClassLike = abstract new (...args: never[]) => unknown;\n\n/**\n * A file that would not import, reported with the file that would not import.\n *\n * Separate from a bare rethrow because the stack of a failed dynamic import\n * names the module that failed to *resolve*, several frames deep, and says\n * nothing about the walk that asked for it — so the reader learns that some\n * `?raw` specifier is unresolvable without learning that discovery is what\n * imported it, or that listing the classes explicitly is how they get their boot\n * back.\n */\nexport class DiscoveryError extends Error {\n constructor(message: string, options?: { cause?: unknown }) {\n super(message, options);\n this.name = \"DiscoveryError\";\n }\n}\n\n/**\n * Every exported class under `dir` whose prototype chain reaches `base`.\n *\n * `base` is a parameter rather than an import so that this file names no\n * service and stays cheap to depend on — `bin/check-models.ts` uses the walker\n * above and is bundled into `dist/bin/gemi.js`, which is not somewhere gemi's\n * service layer should end up. It is also what lets a test hand in a base class\n * of its own instead of standing up a project that can resolve `gemi/services`.\n *\n * `base` itself is never returned. A directory whose files import their base\n * from a sibling — the shape an app reaches for when several jobs share a gate —\n * re-exports it as often as not, and a framework that scheduled the abstract\n * base along with its subclasses would be running a job nobody wrote.\n *\n * A class is returned once no matter how many exports name it. A barrel in the\n * directory re-exporting everything beside it is the ordinary case, and it makes\n * every class reachable twice.\n *\n * The order is the walk's, and within a file the module namespace's, which the\n * language sorts by name. So the answer is the same on every run — worth having\n * where the caller is a scheduler and the alternative is a boot order that\n * depends on the filesystem.\n *\n * `onSkipped` is handed every export that did *not* match, with the file it came\n * from. Discovery's characteristic failure is a thing the author wrote and this\n * walk cannot see, and by the time an export has been discarded here the\n * information about why is gone — the caller is left holding \"four classes\"\n * where the directory holds five. A caller that can recognise its own\n * near-misses, as `discoverCommands` recognises a builder chain that was never\n * finished, uses this to say so by name instead.\n *\n * @throws DiscoveryError if a walked file cannot be imported. Not a skip: a file\n * that will not load is a class the caller was going to be told about and now is\n * not, which is the failure discovery exists to remove.\n */\nexport async function discoverClasses<T extends ClassLike>(\n dir: string,\n base: T,\n ignore: string[] = [],\n onSkipped?: (value: unknown, file: string) => void,\n): Promise<T[]> {\n const found = new Set<T>();\n\n for (const path of sourceFiles(dir, ignore)) {\n let module: Record<string, unknown>;\n\n try {\n module = (await import(path)) as Record<string, unknown>;\n } catch (error) {\n throw new DiscoveryError(\n `${path} could not be imported, so the classes in it could not be ` +\n `discovered:\\n ${(error as Error).message}\\n` +\n `List the classes explicitly in the config slice for this directory ` +\n `to skip the walk.`,\n { cause: error },\n );\n }\n\n for (const value of Object.values(module)) {\n if (\n typeof value === \"function\" &&\n value !== base &&\n Object.prototype.isPrototypeOf.call(base, value)\n ) {\n found.add(value as unknown as T);\n continue;\n }\n\n onSkipped?.(value, path);\n }\n }\n\n return [...found];\n}\n\n/**\n * The directory an app's `app/` sits in, as the running process can know it.\n *\n * `ROOT_DIR` is the obvious answer and is not available: `Server.start` awaits\n * `waitForBoot()` — every provider's `register` and `boot` — and only then\n * imports the http layer that sets it. Anything resolving paths during boot is\n * earlier than the variable it would want.\n *\n * What it can use is the same rule `httpProd` computes `ROOT_DIR` with a moment\n * later, which is why that file now calls this instead of repeating it. `gemi\n * dev` and `gemi start` both spawn the server with no `cwd`, so the process\n * inherits the CLI's, and the CLI takes `process.cwd()` for the project root\n * itself — `bun/preload.ts` reads `gemi.config` from it on the same assumption.\n *\n * `httpDev` computes a bare `process.cwd()`, so it and `httpProd` already\n * disagree whenever `GEMI_PROJECT_DIR` is set. Nothing in this repo sets it and\n * `gemi start` ignores it when locating the built entry point, so the two rules\n * are the same rule for every configuration that runs today; the divergence is\n * older than this function and wants its own fix.\n */\nexport function projectRoot(): string {\n return join(process.cwd(), process.env.GEMI_PROJECT_DIR ?? \"\");\n}\n"
|
|
6
6
|
],
|
|
7
7
|
"mappings": ";AAAA,qBAAS,iBAAY,WACrB,eAAS,cAAM,aA2FR,SAAS,CAAW,CAAC,EAAa,EAAmB,CAAC,EAAa,CACxE,IAAM,EAAgB,CAAC,EAEjB,EAAU,CAAC,IAAiB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,QAAW,KAAS,OAAO,OAAO,CAAM,EAAG,CACzC,GACE,OAAO,IAAU,YACjB,IAAU,GACV,OAAO,UAAU,cAAc,KAAK,EAAM,CAAK,EAC/C,CACA,EAAM,IAAI,CAAqB,EAC/B,SAGF,IAAY,EAAO,CAAI,GAI3B,MAAO,CAAC,GAAG,CAAK,EAuBX,SAAS,CAAW,EAAW,CACpC,OAAO,EAAK,QAAQ,IAAI,EAAG,QAAQ,IAAI,kBAAoB,EAAE",
|
|
8
|
-
"debugId": "
|
|
8
|
+
"debugId": "08CEB91A1A95A55664756E2164756E21",
|
|
9
9
|
"names": []
|
|
10
10
|
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
// @bun
|
|
2
|
-
import{
|
|
3
|
-
export{F as
|
|
2
|
+
import{Yl as P}from"./chunk-fzy1z97a.js";class F{provider="custom";supportsIdempotencyKey=!1;async deliver(j){let x=await this.send(j);return{ok:Boolean(x),id:null}}}class G extends F{apiKey;provider="resend";supportsIdempotencyKey=!0;constructor(j=process.env.RESEND_API_KEY){super();this.apiKey=j}async send(j){return(await this.deliver(j)).ok}async deliver(j){let{Resend:x}=await import("./chunk-zehvtpgm.js"),A=new x(this.apiKey),{idempotencyKey:z,...N}=j,{data:H,error:B}=await A.emails.send(N,z?{idempotencyKey:z}:void 0);if(B)return console.error(B),{ok:!1,id:null,error:B};if(H)return{ok:!0,id:H.id??null};return{ok:!1,id:null}}}function Z(j){return j}function J(){return{driver:new G,headers:{},filterRecipients:(j)=>j}}function Q(j){for(let x=j;x;x=Object.getPrototypeOf(x)){let A=Object.prototype.hasOwnProperty.call(x,"deliver"),z=Object.prototype.hasOwnProperty.call(x,"send");if(A)return!1;if(z)return!0}return!0}async function M(j,x){if(typeof j.deliver==="function"&&!Q(j))return j.deliver(x);return{ok:Boolean(await j.send(x)),id:null}}class U{static token="mail";driver;headers;recipientFilter;constructor(j={}){let x=J();this.driver=j.driver??x.driver,this.headers=j.headers??x.headers,this.recipientFilter=j.filterRecipients??x.filterRecipients}filterRecipients(j){return this.recipientFilter(j)}send(j){return this.driver.send(j)}async deliver(j){return M(this.driver,j)}}
|
|
3
|
+
export{F as il,G as jl,Z as kl,J as ll,M as ml,U as nl};
|
|
4
4
|
|
|
5
|
-
//# debugId=
|
|
5
|
+
//# debugId=068C641282DE14F164756E2164756E21
|
|
@@ -9,6 +9,6 @@
|
|
|
9
9
|
"import { mailConfigDefaults, type MailConfig } from \"./config\";\nimport { deliverThrough } from \"./deliver\";\nimport type { EmailDriver } from \"./drivers/EmailDriver\";\nimport type { EmailDeliveryResult, SendEmailParams } from \"./drivers/types\";\n\nexport class MailManager {\n static token = \"mail\";\n\n readonly driver: EmailDriver;\n readonly headers: Record<string, string>;\n\n private readonly recipientFilter: NonNullable<MailConfig[\"filterRecipients\"]>;\n\n constructor(config: MailConfig = {}) {\n const defaults = mailConfigDefaults();\n\n this.driver = config.driver ?? defaults.driver;\n this.headers = config.headers ?? defaults.headers;\n this.recipientFilter = config.filterRecipients ?? defaults.filterRecipients;\n }\n\n filterRecipients(emails: string[]): Promise<Array<string>> | Array<string> {\n return this.recipientFilter(emails);\n }\n\n send(params: SendEmailParams) {\n return this.driver.send(params);\n }\n\n /** Like `send`, but reports the outcome and the provider's message id. */\n async deliver(params: SendEmailParams): Promise<EmailDeliveryResult> {\n // A driver that doesn't extend `EmailDriver`, or a subclass that only\n // overrides `send`, is called through `send`.\n return deliverThrough(this.driver, params);\n }\n}\n"
|
|
10
10
|
],
|
|
11
11
|
"mappings": ";yCAEO,MAAe,CAAY,CAKvB,SAAmB,SAMnB,uBAAkC,QASrC,QAAO,CAAC,EAAuD,CACnE,IAAM,EAAK,MAAM,KAAK,KAAK,CAAM,EACjC,MAAO,CAAE,GAAI,QAAQ,CAAE,EAAG,GAAI,IAAK,EAEvC,CCvBO,MAAM,UAAqB,CAAY,CAIxB,OAHF,SAAW,SACX,uBAAyB,GAE3C,WAAW,CAAS,EAAS,QAAQ,IAAI,eAAgB,CACvD,MAAM,E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AU,EAAS,OACxC,KAAK,QAAU,EAAO,SAAW,EAAS,QAC1C,KAAK,gBAAkB,EAAO,kBAAoB,EAAS,iBAG7D,gBAAgB,CAAC,EAA0D,CACzE,OAAO,KAAK,gBAAgB,CAAM,EAGpC,IAAI,CAAC,EAAyB,CAC5B,OAAO,KAAK,OAAO,KAAK,CAAM,OAI1B,QAAO,CAAC,EAAuD,CAGnE,OAAO,EAAe,KAAK,OAAQ,CAAM,EAE7C",
|
|
12
|
-
"debugId": "
|
|
12
|
+
"debugId": "068C641282DE14F164756E2164756E21",
|
|
13
13
|
"names": []
|
|
14
14
|
}
|
|
@@ -46,6 +46,6 @@ export { h } from ${JSON.stringify("virtual:gemi-island-runtime")};
|
|
|
46
46
|
import { hydrateRoot } from "react-dom/client";
|
|
47
47
|
export ${z}
|
|
48
48
|
`,Q='const d=document,c=JSON.parse(d.getElementById("gemi-islands").textContent),w=f=>(window.requestIdleCallback||setTimeout)(f),m=(e,o)=>{if(!e.g){e.g=1;import(o.s).then(x=>x.h(e,x.m[o.e])).catch(r=>console.error(r))}};for(const e of d.querySelectorAll("gemi-island")){const o=c.i[e.dataset.island];if(!o)continue;if(o.l=="eager")m(e,o);else if(o.l=="idle"||!window.IntersectionObserver||!e.children.length)w(()=>m(e,o));else{const v=new IntersectionObserver(n=>{if(n.some(x=>x.isIntersecting)){v.disconnect();m(e,o)}});for(const k of e.children)v.observe(k)}}';
|
|
49
|
-
export{B as
|
|
49
|
+
export{B as Al,F as Bl,G as Cl,J as Dl,M as El,Q as Fl};
|
|
50
50
|
|
|
51
|
-
//# debugId=
|
|
51
|
+
//# debugId=470C077E09D8FB9564756E2164756E21
|
|
@@ -5,6 +5,6 @@
|
|
|
5
5
|
"/**\n * The browser side of islands, shared by the Vite plugin (which builds it), the\n * servers (which point the loader at it) and the tests.\n *\n * No imports: the Vite plugin is built on its own and the servers load it at\n * boot, so this file stays plain strings.\n */\n\n/**\n * The module that hydrates islands: React, `react-dom/client` and the small\n * `h(marker, Component)` below. A virtual module of gemi's Vite plugin that\n * every island entry imports, so the islands on a page share one copy of\n * React, in one chunk.\n */\nexport const ISLAND_RUNTIME_ID = \"virtual:gemi-island-runtime\";\n\n/** What `resolveId` turns `ISLAND_RUNTIME_ID` into (Vite's virtual-module convention). */\nexport const RESOLVED_ISLAND_RUNTIME_ID = `\\0${ISLAND_RUNTIME_ID}`;\n\n/**\n * The query that turns a module into its island entry: `Counter.tsx?gemi-island`\n * is a module of the plugin's that re-exports `Counter.tsx` as `m` next to the\n * runtime's `h`. It is what a static page imports for an island, and so it\n * is what the client manifest lists, keyed `app/…/Counter.tsx?gemi-island`,\n * with React and `react-dom/client` among its imports.\n */\nexport const ISLAND_ENTRY_QUERY = \"?gemi-island\";\n\n/** The island entry module for `file` (an absolute path or a root-relative URL). */\nexport function islandEntrySource(file: string) {\n return `import * as m from ${JSON.stringify(file)};\nexport { m };\nexport { h } from ${JSON.stringify(ISLAND_RUNTIME_ID)};\n`;\n}\n\n/**\n * `h(marker, Component)`: hydrates one `<gemi-island>` marker with the island's\n * component and the props the server serialised into `data-props`.\n *\n * The island's static children were rendered on the server into a\n * `<gemi-slot>` (the first one that belongs to this marker, not to an island\n * nested in it). They are handed back to the component as that same element\n * with the server's HTML, so hydration matches and React leaves them alone.\n *\n * `data-uid` is the `identifierPrefix` the server rendered the island with, so\n * `useId` agrees on both sides and two islands never share an id.\n *\n * When the page carries `#gemi-island-i18n` (its islands read the page's\n * locale or dictionaries, #1095), the dictionaries in it are seeded into the\n * dictionary registry through `__GEMI_DICT__` and the island's root gets the\n * locale and zone in `IslandI18nContext` (found on `globalThis`, where\n * `gemi/client` puts it), so `useDictionary` resolves synchronously, with the\n * strings the server rendered, and fetches nothing. An island that does not\n * import `gemi/client` has no such context to read, and is left as it was.\n *\n * The island's root reads queries through the cache the page's islands\n * share (found on `globalThis` under `gemi.islandQueries`, where `gemi/client`\n * puts it, #1155). When the page carries `#gemi-island-queries` (its islands\n * read queries the request prefetched), that `{ path: { variantKey: data } }`\n * payload seeds the cache first, so `useQuery` hydrates with the server's\n * data and does not refetch it.\n *\n * Written as a function body with `createElement` and `hydrateRoot` free, so a\n * test can run it against real React without a bundler.\n */\nexport const ISLAND_HYDRATE_SOURCE = `function h(marker, Component) {\n if (typeof Component !== \"function\" && (typeof Component !== \"object\" || Component === null)) {\n throw new Error(\"gemi: island module has no component export for \" + marker.outerHTML.slice(0, 80));\n }\n const json = marker.getAttribute(\"data-props\");\n const props = json ? JSON.parse(json) : {};\n let slot = null;\n for (const candidate of marker.querySelectorAll(\"gemi-slot\")) {\n if (candidate.closest(\"gemi-island\") === marker) {\n slot = candidate;\n break;\n }\n }\n const children = slot\n ? [createElement(\"gemi-slot\", {\n style: { display: \"contents\" },\n suppressHydrationWarning: true,\n dangerouslySetInnerHTML: { __html: slot.innerHTML },\n })]\n : [];\n let element = createElement(Component, props, ...children);\n const i18n = document.getElementById(\"gemi-island-i18n\");\n const context = globalThis[Symbol.for(\"gemi.islandI18n\")];\n if (i18n && context) {\n const payload = (i18n.p = i18n.p || JSON.parse(i18n.textContent));\n const dictionaries = (self.__GEMI_DICT__ = self.__GEMI_DICT__ || []);\n for (const entry of payload.dictionaries || []) dictionaries.push(entry);\n element = createElement(context.Provider, {\n value: { currentLocale: payload.currentLocale, defaultLocale: payload.defaultLocale, timeZone: payload.timeZone },\n }, element);\n }\n const cache = globalThis[Symbol.for(\"gemi.islandQueries\")];\n if (cache) {\n const queries = document.getElementById(\"gemi-island-queries\");\n if (queries) cache.seed((queries.p = queries.p || JSON.parse(queries.textContent)));\n element = createElement(cache.Provider, null, element);\n }\n return hydrateRoot(marker, element, {\n identifierPrefix: marker.getAttribute(\"data-uid\") || undefined,\n });\n}`;\n\n/** The runtime module's source, as the plugin serves and builds it. */\nexport const ISLAND_RUNTIME_SOURCE = `import { createElement } from \"react\";\nimport { hydrateRoot } from \"react-dom/client\";\nexport ${ISLAND_HYDRATE_SOURCE}\n`;\n\n/**\n * The island loader, inlined into a static document that uses islands.\n *\n * Kept byte-for-byte constant (the per-page island table travels in a\n * separate `<script type=\"application/json\">`, which a Content Security Policy\n * does not treat as script), so a strict policy can allow it by hash:\n * `script-src 'sha256-…'` with `ISLAND_LOADER_CSP_HASH`. Everything it loads\n * is a plain `import()` of a same-origin (or asset-base) file.\n *\n * The table is `{ i: [{ s: entry URL, e: export, l: load }] }` and each\n * marker's `data-island` indexes `i`. Per marker, on its schedule: import the\n * island's entry (the module as `m`, the runtime's `h`), then\n * `h(marker, m[export])`, which calls `hydrateRoot`. A failure is logged and\n * leaves the server-rendered markup in place.\n */\nexport const ISLAND_LOADER_SOURCE =\n 'const d=document,c=JSON.parse(d.getElementById(\"gemi-islands\").textContent),' +\n \"w=f=>(window.requestIdleCallback||setTimeout)(f),\" +\n \"m=(e,o)=>{if(!e.g){e.g=1;import(o.s).then(x=>x.h(e,x.m[o.e])).catch(r=>console.error(r))}};\" +\n 'for(const e of d.querySelectorAll(\"gemi-island\")){const o=c.i[e.dataset.island];if(!o)continue;' +\n 'if(o.l==\"eager\")m(e,o);else if(o.l==\"idle\"||!window.IntersectionObserver||!e.children.length)w(()=>m(e,o));' +\n \"else{const v=new IntersectionObserver(n=>{if(n.some(x=>x.isIntersecting)){v.disconnect();m(e,o)}});for(const k of e.children)v.observe(k)}}\";\n"
|
|
6
6
|
],
|
|
7
7
|
"mappings": ";AAcO,IAAM,EAAoB,8BAGpB,EAA6B,kCAS7B,EAAqB,eAG3B,SAAS,CAAiB,CAAC,EAAc,CAC9C,MAAO,sBAAsB,KAAK,UAAU,CAAI;AAAA;AAAA,oBAE9B,KAAK,UAlBQ,6BAkBmB;AAAA,EAkC7C,IAAM,EAAwB;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,GA2CxB,EAAwB;AAAA;AAAA,SAE5B;AAAA,EAkBI,EACX",
|
|
8
|
-
"debugId": "
|
|
8
|
+
"debugId": "470C077E09D8FB9564756E2164756E21",
|
|
9
9
|
"names": []
|
|
10
10
|
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
// @bun
|
|
2
|
-
import{S as F}from"./chunk-
|
|
2
|
+
import{S as F}from"./chunk-20y02g4n.js";import{V as w}from"./chunk-wprzrnqh.js";import{Vl as h}from"./chunk-fzy1z97a.js";var P=h((p)=>{var t=w(),l=F();function d(e){try{let o=new Set(Array.from(e.match(/([A-Z_]){3,}/g)??[]));return o.delete("CONFIG"),o.delete("CONFIG_PREFIX_SEPARATOR"),o.delete("ENV"),[...o].join(", ")}catch(o){return e}}var u=(e,o)=>async()=>{try{let r=e(process.env,o);if(r===void 0)throw Error();return r}catch(r){throw new t.CredentialsProviderError(r.message||`Not found in ENV: ${d(e.toString())}`,{logger:o?.logger})}},C=(e,{preferredFile:o="config",...r}={})=>async()=>{let n=l.getProfileName(r),{configFile:i,credentialsFile:c}=await l.loadSharedConfigFiles(r),s=c[n]||{},g=i[n]||{},m=o==="config"?{...s,...g}:{...g,...s};try{let f=e(m,o==="config"?i:c);if(f===void 0)throw Error();return f}catch(a){throw new t.CredentialsProviderError(a.message||`Not found in config files w/ profile [${n}]: ${d(e.toString())}`,{logger:r.logger})}},y=(e)=>typeof e==="function",E=(e)=>y(e)?async()=>await e():t.fromStatic(e),N=({environmentVariableSelector:e,configFileSelector:o,default:r},n={})=>{let{signingName:i,logger:c}=n,s={signingName:i,logger:c};return t.memoize(t.chain(u(e,s),C(o,n),E(r)))};p.loadConfig=N});
|
|
3
3
|
export{P as D};
|
|
4
4
|
|
|
5
|
-
//# debugId=
|
|
5
|
+
//# debugId=A477F6C83699456464756E2164756E21
|
|
@@ -5,6 +5,6 @@
|
|
|
5
5
|
"'use strict';\n\nvar propertyProvider = require('@smithy/property-provider');\nvar sharedIniFileLoader = require('@smithy/shared-ini-file-loader');\n\nfunction getSelectorName(functionString) {\n try {\n const constants = new Set(Array.from(functionString.match(/([A-Z_]){3,}/g) ?? []));\n constants.delete(\"CONFIG\");\n constants.delete(\"CONFIG_PREFIX_SEPARATOR\");\n constants.delete(\"ENV\");\n return [...constants].join(\", \");\n }\n catch (e) {\n return functionString;\n }\n}\n\nconst fromEnv = (envVarSelector, options) => async () => {\n try {\n const config = envVarSelector(process.env, options);\n if (config === undefined) {\n throw new Error();\n }\n return config;\n }\n catch (e) {\n throw new propertyProvider.CredentialsProviderError(e.message || `Not found in ENV: ${getSelectorName(envVarSelector.toString())}`, { logger: options?.logger });\n }\n};\n\nconst fromSharedConfigFiles = (configSelector, { preferredFile = \"config\", ...init } = {}) => async () => {\n const profile = sharedIniFileLoader.getProfileName(init);\n const { configFile, credentialsFile } = await sharedIniFileLoader.loadSharedConfigFiles(init);\n const profileFromCredentials = credentialsFile[profile] || {};\n const profileFromConfig = configFile[profile] || {};\n const mergedProfile = preferredFile === \"config\"\n ? { ...profileFromCredentials, ...profileFromConfig }\n : { ...profileFromConfig, ...profileFromCredentials };\n try {\n const cfgFile = preferredFile === \"config\" ? configFile : credentialsFile;\n const configValue = configSelector(mergedProfile, cfgFile);\n if (configValue === undefined) {\n throw new Error();\n }\n return configValue;\n }\n catch (e) {\n throw new propertyProvider.CredentialsProviderError(e.message || `Not found in config files w/ profile [${profile}]: ${getSelectorName(configSelector.toString())}`, { logger: init.logger });\n }\n};\n\nconst isFunction = (func) => typeof func === \"function\";\nconst fromStatic = (defaultValue) => isFunction(defaultValue) ? async () => await defaultValue() : propertyProvider.fromStatic(defaultValue);\n\nconst loadConfig = ({ environmentVariableSelector, configFileSelector, default: defaultValue }, configuration = {}) => {\n const { signingName, logger } = configuration;\n const envOptions = { signingName, logger };\n return propertyProvider.memoize(propertyProvider.chain(fromEnv(environmentVariableSelector, envOptions), fromSharedConfigFiles(configFileSelector, configuration),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S,OAAO,IAAS,WACvC,EAAa,CAAC,IAAiB,EAAW,CAAY,EAAI,SAAY,MAAM,EAAa,EAAI,EAAiB,WAAW,CAAY,EAErI,EAAa,EAAG,8BAA6B,qBAAoB,QAAS,GAAgB,EAAgB,CAAC,IAAM,CACnH,IAAQ,cAAa,UAAW,EAC1B,EAAa,CAAE,cAAa,QAAO,EACzC,OAAO,EAAiB,QAAQ,EAAiB,MAAM,EAAQ,EAA6B,CAAU,EAAG,EAAsB,EAAoB,CAAa,EAAG,EAAW,CAAY,CAAC,CAAC,GAGxL,aAAa",
|
|
8
|
-
"debugId": "
|
|
8
|
+
"debugId": "A477F6C83699456464756E2164756E21",
|
|
9
9
|
"names": []
|
|
10
10
|
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
// @bun
|
|
2
|
-
import{X as p,Y as AJ,Z as DJ,_ as PJ}from"./chunk-
|
|
2
|
+
import{X as p,Y as AJ,Z as DJ,_ as PJ}from"./chunk-arb0qkrm.js";import{pa as b,ta as T,ua as NJ}from"./chunk-bwg7genv.js";import"./chunk-s0z61m9j.js";import{Eg as xJ,Fg as k,Ng as IJ,Og as MJ,Pg as FJ,pe as jJ}from"./chunk-7xy7ebkx.js";import"./chunk-4f2xy9ws.js";import"./chunk-7sadg8d7.js";import{Uh as ZJ,Vh as XJ,Yh as QJ}from"./chunk-es05kqtp.js";import{kj as LJ}from"./chunk-2qbfvb6m.js";import"./chunk-zzmgz14a.js";import"./chunk-kzy4pyqb.js";import"./chunk-ecyq52t3.js";import"./chunk-kjgy7sk0.js";import"./chunk-g1th116z.js";import"./chunk-mnmz8n5k.js";import"./chunk-ng5qfkgp.js";import"./chunk-5qaxde5h.js";import"./chunk-htnbmbx1.js";import"./chunk-rnjjn09d.js";import"./chunk-yzazktke.js";import"./chunk-9ky5d5js.js";import"./chunk-a77w04sw.js";import{Cl as GJ}from"./chunk-qw6aa9fy.js";import"./chunk-y9pzr1wc.js";import{Ql as _J}from"./chunk-nnn2f1ew.js";import{Sl as y}from"./chunk-xb9zjaes.js";import"./chunk-fzy1z97a.js";import{createHash as U2}from"crypto";import{join as d,resolve as TJ,sep as BJ}from"path";import{Duplex as gJ}from"stream";import{constants as E,createBrotliCompress as fJ,createGzip as mJ}from"zlib";var uJ=["br","gzip"],hJ=1024,cJ=5,pJ=19,dJ=6;function lJ(J){if(J===void 0)return 1;if(!/^\d+(\.\d{0,3})?$/.test(J.trim()))return 1;let $=Number(J.trim());return Number.isFinite($)?Math.min($,1):1}function oJ(J){if(J===null||J===void 0)return null;let $=new Map;for(let Z of J.split(",")){let[X,...j]=Z.split(";"),H=X.trim().toLowerCase();if(H==="")continue;let W=1;for(let G of j){let U=G.indexOf("=");if(U===-1)continue;if(G.slice(0,U).trim().toLowerCase()==="q"){W=lJ(G.slice(U+1));break}}$.set(H,W)}return $}function m(J,$=uJ){let Z=oJ(J);if(!Z)return null;let X=Z.get("*"),j=null,H=0;for(let W of $){let G=Z.get(W)??X??0;if(G>H)j=W,H=G}return j}function nJ(J,$){if(!J)return!1;return J.split(",").some((Z)=>Z.trim().toLowerCase().split("=")[0].trim()===$)}function iJ(J,$){if(J==="HEAD")return!1;if($.status<200||$.status===204||$.status===206||$.status===304)return!1;if($.headers.has("Content-Range"))return!1;let Z=$.headers.get("Content-Type");if(!Z||!/^\s*text\/html\s*(;|$)/i.test(Z))return!1;if(!$.body)return!1;let X=$.headers.get("Content-Encoding");if(X&&X.trim().toLowerCase()!=="identity")return!1;if(nJ($.headers.get("Cache-Control"),"no-transform"))return!1;let j=$.headers.get("Content-Length");if(j!==null&&Number(j)<hJ)return!1;return!0}function aJ(J){let $=J==="br"?fJ({params:{[E.BROTLI_PARAM_QUALITY]:cJ,[E.BROTLI_PARAM_LGWIN]:pJ},flush:E.BROTLI_OPERATION_FLUSH}):mJ({level:dJ,flush:E.Z_SYNC_FLUSH});return gJ.toWeb($)}function rJ(J){let $=J.get("Vary");if(!$){J.set("Vary","Accept-Encoding");return}let Z=$.split(",").map((X)=>X.trim().toLowerCase());if(Z.includes("*")||Z.includes("accept-encoding"))return;J.append("Vary","Accept-Encoding")}function s(J,$){if(!iJ(J.method,$))return $;let Z=new Headers($.headers);rJ(Z);let X=m(J.headers.get("Accept-Encoding"));if(!X)return new Response($.body,{status:$.status,statusText:$.statusText,headers:Z});let j;try{j=aJ(X)}catch{return new Response($.body,{status:$.status,statusText:$.statusText,headers:Z})}return Z.set("Content-Encoding",X),Z.delete("Content-Length"),new Response($.body.pipeThrough(j),{status:$.status,statusText:$.statusText,headers:Z})}import{readdir as X2,stat as HJ}from"fs/promises";import{join as Q2}from"path";import{mkdir as F2,readFile as tJ,stat as N2,writeFile as A2}from"fs/promises";import{dirname as P2,join as sJ}from"path";import{promisify as e}from"util";import{brotliCompress as eJ,constants as R2,gzip as J2}from"zlib";var $2=".vite/static-assets.json";var JJ={br:".br",gzip:".gz"},Z2=["br","gzip"],S2=e(eJ),b2=e(J2);async function $J(J){let $;try{$=await tJ(sJ(J,$2),"utf8")}catch{return null}let Z;try{Z=JSON.parse($)?.files}catch{return null}if(!Z||typeof Z!=="object")return null;let X={files:{}};for(let[j,H]of Object.entries(Z)){if(!Array.isArray(H))continue;X.files[j]=Z2.filter((W)=>H.includes(W))}return X}function u(J){let $=J.toString(),Z=new Bun.CryptoHasher("sha1");return Z.update($),Z.digest("hex")}async function WJ(J){let $=new Set;async function Z(X,j){let H;try{H=await X2(X,{withFileTypes:!0})}catch{return}for(let W of H){if(W.name.startsWith("."))continue;if(j&&W.name==="assets")continue;let G=Q2(X,W.name),U=W.isDirectory(),O=W.isFile();if(W.isSymbolicLink())try{let _=await HJ(G);U=_.isDirectory(),O=_.isFile()}catch{continue}if(O)$.add(G);else if(U&&!W.isSymbolicLink())await Z(G,!1)}}return await Z(J,!0),$}var j2="public, max-age=31536000, must-revalidate",H2="public, max-age=31536000, immutable";async function W2(J,$,Z){if(Z.length===0||J.headers.has("Range"))return null;let X=m(J.headers.get("Accept-Encoding"),Z);if(!X)return null;let j=$+JJ[X];try{let H=await HJ(j);return H.isFile()?{encoding:X,path:j,size:H.size}:null}catch{return null}}async function YJ(J,$,Z={}){let X=Bun.file($),j=Z.encodings??[],H={"Content-Type":X.type||"application/octet-stream","Cache-Control":Z.immutable?H2:j2,"Accept-Ranges":"bytes"};if(j.length>0)H.Vary="Accept-Encoding";let W=await W2(J,$,j);if(W){let O=Bun.file(W.path);return new Response(O.stream(),{headers:{...H,"Content-Encoding":W.encoding,"Content-Length":String(W.size),ETag:`${u(O.lastModified)}-${W.encoding}`}})}let G=X.size;H.ETag=u(X.lastModified);let U=ZJ(J.headers.get("Range"));if(U){let O=XJ(U,G);if(!O)return jJ(G);return new Response(X.slice(O.start,O.end+1).stream(),{status:206,headers:{...H,"Content-Range":QJ(O.start,O.end,G),"Content-Length":String(O.length)}})}return new Response(X.stream(),{headers:{...H,"Content-Length":String(G)}})}import{stat as z2}from"fs/promises";var v="app/client.tsx";function OJ(J,$=b){let Z=J[v]?.file;if(!Z)return;return{module:T(Z,$),preload:P(J,v,$)}}function P(J,$,Z=b){let X=[],j=new Set,H=(W)=>{if(j.has(W))return;j.add(W);let G=J[W];if(!G?.file)return;X.push(T(G.file,Z));for(let U of G.imports??[])H(U)};return H($),X}function Y2(J,$,Z=b){let X=new Set(P(J,$,Z)),j=[],H=new Set,W=(U)=>{if(H.has(U))return;H.add(U);let O=J[U];if(!O)return;for(let _ of O.dynamicImports??[])if(!/(^|\/)node_modules\//.test(_)&&!j.includes(_))j.push(_);for(let _ of O.imports??[])W(_)};W($);let G=[];for(let U of j)for(let O of P(J,U,Z))if(!X.has(O))X.add(O),G.push(O);return G}function VJ(J,$){let Z=[],X=new Set,j=new Set,H=(W)=>{if(j.has(W))return;j.add(W);let G=J[W];if(!G)return;for(let U of G.imports??[])H(U);for(let U of G.css??[])if(!X.has(U))X.add(U),Z.push(U)};return H($),Z}function UJ(J,$=b){let Z=new Map;return(X)=>{if(!Z.has(X)){let j=`${X}${GJ}`,H=J[j]?.file;Z.set(X,H?{src:T(H,$),preload:P(J,j,$),dynamicPreload:Y2(J,j,$)}:void 0)}return Z.get(X)}}var zJ="x-gemi-build";function G2(J,$,Z,X){let j=Date.now(),H=function(V){return typeof V==="number"&&j-V>=0&&j-V<Z},W=function(V){try{let z=V?JSON.parse(V):null;return z&&typeof z==="object"&&!Array.isArray(z)?z:{}}catch{return{}}},G=function(V){let z={};for(let I in V)if(H(V[I]))z[I]=V[I];return z},U=function(V){let z=2166136261;for(let I=0;I<V.length;I++)z=Math.imul(z^V.charCodeAt(I),16777619);return(z>>>0).toString(36)},O=null,_={};try{O=window.sessionStorage,_=W(O.getItem(J))}catch{O=null}let F=J+":",N="",A="";try{let V=new URL($,window.location.href);N=U(new URL(window.location.href).origin),A=U(V.origin+V.pathname)}catch{}let C=null;try{let V=window.name;if(!A)C=null;else if(V==="")C={};else if(V.indexOf(F)===0){let z=W(V.slice(F.length)),I=z.m;C=z.o===N&&I&&typeof I==="object"&&!Array.isArray(I)?I:{}}}catch{C=null}if(X==="tidy"){try{let V=window.name;if(C===null||V.indexOf(F)!==0)return"ok";for(let z in C)if(H(C[z]))return"cooldown";window.name=""}catch{}return"ok"}if(H(_[$])||C&&H(C[A]))return"cooldown";if(!O&&!C)return"storage";if(!X)return"ok";if(O)try{let V=G(_);V[$]=j;let z=JSON.stringify(V);if(O.setItem(J,z),O.getItem(J)===z)return"ok"}catch{}if(C)try{let V=G(C);V[A]=j;let z=F+JSON.stringify({o:N,m:V});if(window.name=z,window.name===z)return"ok"}catch{}return"storage"}function KJ(J,$=30000){let Z=JSON.stringify("gemi:chunk-reload"),X=JSON.stringify(`Failed to fetch dynamically imported module: ${J}`);return`var g=${G2.toString()};var r=!1;try{r=navigator.onLine!==!1&&g(${Z},window.location.href,${Number($)},!0)==="ok"}catch(e){}if(r)window.location.reload();else throw new Error(${X});export {}`}var O2=new RegExp(`^${xJ}/.+\\.m?js$`);function h(J){return O2.test(J)}function CJ(J){if(h(J))return new Response(KJ(J),{headers:{"Content-Type":"application/javascript","Cache-Control":"no-store"}});if(k(J))return new Response("Not found",{status:404});return}var V2=`<!DOCTYPE html>
|
|
3
3
|
<html lang="en">
|
|
4
4
|
<head>
|
|
5
5
|
<meta charset="UTF-8" />
|
|
@@ -21,4 +21,4 @@ import{X as p,Y as AJ,Z as DJ,_ as PJ}from"./chunk-zkcky8pg.js";import{pa as b,t
|
|
|
21
21
|
</html>`;function c(J,$,Z){if(!Z)console.error(J);else try{Z(J instanceof Error?J:Error(String(J),{cause:J}))}catch(X){console.error(J),console.error(X)}if(y($))return new Response(JSON.stringify({error:LJ("server_error","Internal Server Error",500)}),{status:500,headers:{"Content-Type":"application/json"}});return new Response(V2,{status:500,headers:{"Content-Type":"text/html; charset=utf-8"}})}var g=_J(),K2=d(g,"app"),M=d(g,"dist"),B=d(M,"client");function x2(J){let $;try{$=decodeURIComponent(J)}catch{return null}let Z=TJ(B,"."+$.replace("/assets/assets","/assets"));return Z.startsWith(B+BJ)?Z:null}async function C2(J){try{return(await z2(J)).isFile()}catch{return!1}}async function x3(J,$){let Z=await import(`${M}/client/.vite/manifest.json`),X=await import(`${M}/server/.vite/manifest.json`),j=await NJ(`${M}/client`);process.env.ROOT_DIR=g,process.env.APP_DIR=K2,process.env.DIST_DIR=M;let H={},W={},G={},U={},O={},_=(Q,Y)=>`"${Q}": () => import("${Y}")`,F=[],N=J.getRequiredViews.call(J);for(let Q of["404",...J.getFlatComponentTree.call(J)]){let Y=X[`app/views/${Q}.tsx`];if(!Y?.file&&N[Q])throw DJ(Q,N[Q]);if(!Y?.file){console.log(`Server file not found for ${Q}`),console.log(Y);let L=Object.keys(X),D=`app/views/${Q}.tsx`;console.log(`${D} not found in server manifest`),console.log(L)}let K=await import(`${process.env.DIST_DIR}/server/${Y?.file}`);H[Q]=K.default,W[Q]=K.OpenGraph,G[Q]=K;let x=Z[`app/views/${Q}.tsx`];if(x?.css&&x?.css.length>0)U[Q]=x?.css;if(x)F.push(_(Q,T(x?.file,j))),O[Q]=P(Z,`app/views/${Q}.tsx`,j)}let A=`{${F.join(",")}}`,C=OJ(Z,j);if(!C)console.error(`Client manifest has no "${v}" entry \u2014 dist/client is incomplete, so documents will render but never hydrate.`);let V=Z["app/client.tsx"]?.css??[],z=(await Promise.all(V.map((Q)=>Bun.file(`${M}/client/${Q}`).text()))).join(`
|
|
22
22
|
`),I=UJ(Z,j),l=U2("sha256").update(await Bun.file(`${M}/client/.vite/manifest.json`).text()).digest("base64url").slice(0,12),o=new Map,RJ=(Q)=>{let Y=o.get(Q);if(!Y)Y=Bun.file(`${M}/client/${Q}`).text(),o.set(Q,Y);return Y},SJ=async(Q,Y)=>{let K=new Set;for(let L of Y?[Y,...Q]:Q)for(let D of VJ(Z,`app/views/${L}.tsx`))K.add(D);let x=await Promise.all([...K].map(async(L)=>({id:L,content:await RJ(L)})));return p(Y?x:[{content:z},...x])},bJ=await WJ(B),n=new Map;for(let[Q,Y]of Object.entries((await $J(B))?.files??{})){let K=TJ(B,Q);if(K.startsWith(B+BJ))n.set(K,{immutable:!0,encodings:Y})}async function qJ(Q){let{pathname:Y}=new URL(Q.url);if(y(Y))return await R(Q,Y);let K=x2(Y),x=k(Y),L=!x&&K!==null&&bJ.has(K),D=x||Y.startsWith("/.well-known")||L;if(L&&!(await i(Q)).publicFiles)return await R(Q,Y);if(D){if(!K||!await C2(K)){if(x&&!h(Y)&&(await i(Q)).assetRoutes)return await R(Q,Y);return CJ(Y)??await R(Q,Y)}try{return await YJ(Q,K,n.get(K))}catch(w){return J.onException?.(w),new Response("Not found",{status:404})}}let q=await R(Q,Y);if(Y.endsWith(".json"))try{q.headers.set(zJ,l)}catch{}return q}async function i(Q){try{return await J.staticFiles?.(Q)??{publicFiles:!0,assetRoutes:!1}}catch{return{publicFiles:!1,assetRoutes:!0}}}async function R(Q,Y){let K=J.fetch.bind(J);try{let x=await K(Q);if(x instanceof Response)return x;else{let L=[];return L.push({content:z}),await x({getStyles:async(q,w)=>{let r=q??["404"];if(w?.static)return SJ(r,w.layout);for(let vJ of r){let kJ=Z[`app/views/${vJ}.tsx`];for(let t of kJ?.css??[]){let yJ=Bun.file(`${process.env.DIST_DIR}/client/${t}`);L.push({id:t,content:await yJ.text()})}}return p(L)},clientEntry:C,modulePreloadManifest:O,loaders:A,viewImportMap:H,viewModules:G,ogMap:W,cssManifest:U,assetBase:j,resolveIsland:I,buildId:l})}}catch(x){return c(x,Y,J.onException)}}let wJ=(process.env.GEMI_COMPRESSION??"auto").toLowerCase()!=="off",a=IJ(process.env.GEMI_TRUST_PROXY),EJ=FJ(process.env),S=J.sockets();if(S&&a.kind==="none"&&!EJ)console.warn("[gemi] Broadcast sockets: GEMI_TRUST_PROXY is not set, so a socket's address is its TCP peer. Behind a proxy or load balancer every client shares the proxy's address, and broadcast.maxConnectionsPerIp caps the whole app per process. Set GEMI_TRUST_PROXY (see forwardedFor) or raise that limit.");let f=Bun.serve({maxRequestBodySize:10737418240,fetch:async(Q,Y)=>{if(MJ(Q.headers,Y.requestIP(Q)?.address??null,a),J.applyTrustedClientIp(Q),S?.matches(Q))return S.upgrade(Q,Y);let K=await $(Q,(x)=>J.withGlobalMiddleware(x,qJ,(L)=>c(L,new URL(x.url).pathname,J.onException)));return wJ?s(Q,K):K},idleTimeout:PJ(),port:process.env.PORT||5173,websocket:S?.websocket});return await S?.start(f),AJ({port:f.port,rootDir:g}),f}export{x3 as httpProd};
|
|
23
23
|
|
|
24
|
-
//# debugId=
|
|
24
|
+
//# debugId=E25C8CD08A084EDD64756E2164756E21
|
|
@@ -13,6 +13,6 @@
|
|
|
13
13
|
"import { stringEraRefusal } from \"../http/Error\";\nimport { isApiPath } from \"../services/router/apiPath\";\n\n// The production server's last resort: an error nothing on the way here turned\n// into a response. Request breakers (auth, 404s, 416s) are answered by the\n// dispatchers before this, so what arrives is a genuine failure — and its\n// message and stack are for the developer, not for whoever triggered it. They\n// can carry absolute paths, dependency versions, SQL fragments and column\n// names. The dev server renders them on purpose (`httpDev.ts`); this does not.\n\nconst GENERIC_500_HTML = `<!DOCTYPE html>\n<html lang=\"en\">\n <head>\n <meta charset=\"UTF-8\" />\n <meta name=\"viewport\" content=\"width=device-width, initial-scale=1.0\" />\n <title>Internal Server Error</title>\n <style>\n body { font-family: system-ui, sans-serif; margin: 0; min-height: 100vh; display: grid; place-items: center; }\n main { text-align: center; padding: 16px; }\n h1 { font-size: 1.5rem; margin: 0 0 0.5rem; }\n p { margin: 0; opacity: 0.7; }\n </style>\n </head>\n <body>\n <main>\n <h1>Something went wrong</h1>\n <p>Please try again later.</p>\n </main>\n </body>\n</html>`;\n\nexport function unhandledErrorResponse(\n err: unknown,\n pathname: string,\n onException?: (error: Error) => void,\n): Response {\n // `onException` is the report, and the default one `App` installs is a\n // `console.error`, so logging here as well printed every failure twice\n // (three times for `/api`, whose dispatcher logs before rethrowing). Only\n // without a reporter does this log itself.\n //\n // Reported for `/api` too: an app's error tracking should see an API failure\n // that got this far, not only a page one. `onRequestFail` is a different\n // hook (route config, called by the dispatchers), so this is not a second\n // report through the same channel.\n if (!onException) {\n console.error(err);\n } else {\n try {\n // The hook is typed to receive an `Error`; a thrown string or object is\n // wrapped so a reporter reading `.stack` or `.name` gets one.\n onException(err instanceof Error ? err : new Error(String(err), { cause: err }));\n } catch (reportError) {\n // A broken reporter must not turn a 500 into a leaked stack either.\n console.error(err);\n console.error(reportError);\n }\n }\n\n if (isApiPath(pathname)) {\n return new Response(\n JSON.stringify({ error: stringEraRefusal(\"server_error\", \"Internal Server Error\", 500) }),\n {\n status: 500,\n headers: { \"Content-Type\": \"application/json\" },\n },\n );\n }\n\n return new Response(GENERIC_500_HTML, {\n status: 500,\n headers: { \"Content-Type\": \"text/html; charset=utf-8\" },\n });\n}\n"
|
|
14
14
|
],
|
|
15
15
|
"mappings": ";ikCAAA,eAAS,UAET,SAAS,OAAM,IAAS,QCgBxB,WAAS,UACT,cAAS,oBAAW,WAAsB,QAW1C,FAAM,HAAuC,LAAC,DAAM,AAAM,JAQpD,HAAyB,DAYzB,HAAi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,SAAU,EAAI,WAAW,CACxE,CACF,EAKA,OAAO,GAAqB,EAAiB,EAAK,CAAG,EAAI,GAE3D,YAAa,GAAkB,EAC/B,KAAM,QAAQ,IAAI,MAAQ,KAC1B,UAAW,GAAS,SACtB,CAAC,EAKD,OAJA,MAAM,GAAS,MAAM,CAAM,EAE3B,GAAmB,CAAE,KAAM,EAAO,KAAM,SAAQ,CAAC,EAE1C",
|
|
16
|
-
"debugId": "
|
|
16
|
+
"debugId": "E25C8CD08A084EDD64756E2164756E21",
|
|
17
17
|
"names": []
|
|
18
18
|
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
// @bun
|
|
2
2
|
var j=globalThis.__GEMI_DICTIONARY_REGISTRY__??={registry:new Map,resolved:new Map,inFlight:new Map,renderThenables:new Map,order:[],warmed:new Map,activeLocale:null},{registry:W,resolved:Z,inFlight:V,renderThenables:I,order:E,warmed:X}=j;function N(q,x){return`${q}\x00${x}`}function D(q){if(W.has(q.id))return;W.set(q.id,q),E.push(q.id)}function H(){return E.length}function P(q,x){return Z.get(q)?.get(x)}function $(q,x,A){let z=Z.get(q);if(!z)z=new Map,Z.set(q,z);z.set(x,A)}function U(q,x){let A=P(q,x);if(A)return A;let z=N(q,x),C=V.get(z);if(C)return C;let B=W.get(q);if(!B)throw Error(`Unknown dictionary "${q}". A dictionary must be created with defineDictionary() and its module must have been evaluated before it is read.`);let J=B.load(x);if(!(J instanceof Promise))return $(q,x,J),J;let O=J.then((Q)=>{return $(q,x,Q),V.delete(z),Q},(Q)=>{throw V.delete(z),Q});return V.set(z,O),O}function K(q,x){let A=N(q,x),z=P(q,x),C=I.get(A);if(C&&!(C.degraded&&z))return C;if(z)return G(A,M(z,!C));let B=U(q,x);if(!(B instanceof Promise))return G(A,M(B,!0));let J=B.then((O)=>O,(O)=>{return console.error(`Failed to load dictionary ${q} for locale ${x}; rendering keys instead.`,O),J.degraded=!0,Y});return G(A,J)}function G(q,x){return I.set(q,x),x}function M(q,x){return Object.assign(Promise.resolve(q),{status:"fulfilled",value:q,inHand:x?q:void 0})}var Y={};async function S(q,x){let A=x??X.get(q)??0,z=E.slice(A);if(z.length===0)return;let C=await Promise.all(z.map(async(B)=>{try{return await U(B,_(B,q)),!0}catch{return!1}}));if(x===void 0){let B=C.indexOf(!1),J=B===-1?z.length:B;X.set(q,Math.max(X.get(q)??0,A+J))}}function _(q,x){if(x)return x;return W.get(q)?.locales[0]??x}function L(q,x){if(!q)return;for(let[A,z]of Object.entries(q))$(A,x,z)}function R(q){if(q)j.activeLocale=q}function w(){return j.activeLocale}if(typeof window<"u"){let q=window,x=([z,C,B])=>{$(z,C,B)},A=Array.isArray(q.__GEMI_DICT__)?q.__GEMI_DICT__:[];q.__GEMI_DICT__={push:x};for(let z of A)x(z)}function F(){W.clear(),Z.clear(),V.clear(),I.clear(),X.clear(),E.length=0,j.activeLocale=null}function f(){let q=new Set,x=[],A=[];return{use(z,C,B){let J=`${z} ${C}`;if(q.has(J))return;q.add(J);let O={id:z,locale:C,strings:B};if(x.length===0){A.push(O);return}for(let Q of x)Q(O)},onUse(z){x.push(z);while(A.length>0)z(A.shift())}}}
|
|
3
|
-
export{D as
|
|
3
|
+
export{D as _k,H as $k,U as al,K as bl,S as cl,L as dl,R as el,w as fl,F as gl,f as hl};
|
|
4
4
|
|
|
5
|
-
//# debugId=
|
|
5
|
+
//# debugId=53C7B37301D158BB64756E2164756E21
|
|
@@ -6,6 +6,6 @@
|
|
|
6
6
|
"import type { LocaleStrings } from \"./dictionaryShape\";\n\n/**\n * Collects the dictionaries one SSR render actually read.\n *\n * Scoped per request by living in React context rather than in module state: a\n * streaming server has several renders in flight at once, so a module-level\n * collector would mix one page's dictionaries into another's payload. Context\n * is per render tree, which is exactly the boundary wanted, and it needs no\n * async-local storage to survive React's internal scheduling.\n *\n * Why stream these rather than put them in `__GEMI_DATA__`: that snapshot is\n * serialized before `renderToReadableStream` is even called, and which\n * dictionaries a page reads is only known once it has rendered. A suspended\n * segment reveals later still, long after the shell has flushed.\n *\n * The sink deliberately emits data, not markup — `streamQueryInjection` owns\n * script formatting and the `</script>`-safe encoding that goes with it.\n */\nexport interface DictionaryUse {\n id: string;\n locale: string;\n strings: LocaleStrings;\n}\n\nexport interface DictionarySink {\n /** Called during render, the first time a dictionary is read. */\n use(id: string, locale: string, strings: LocaleStrings): void;\n /** The response injector subscribes to receive uses as they happen. */\n onUse(cb: (use: DictionaryUse) => void): void;\n}\n\nexport function createDictionarySink(): DictionarySink {\n const seen = new Set<string>();\n const listeners: Array<(use: DictionaryUse) => void> = [];\n // Uses recorded before the injector subscribed — the render begins before the\n // response stream is wrapped.\n const pending: DictionaryUse[] = [];\n\n return {\n use(id, locale, strings) {\n const key = `${id} ${locale}`;\n if (seen.has(key)) return;\n seen.add(key);\n const entry: DictionaryUse = { id, locale, strings };\n if (listeners.length === 0) {\n pending.push(entry);\n return;\n }\n for (const listener of listeners) listener(entry);\n },\n onUse(cb) {\n listeners.push(cb);\n while (pending.length > 0) {\n cb(pending.shift()!);\n }\n },\n };\n}\n"
|
|
7
7
|
],
|
|
8
8
|
"mappings": ";AA6FA,IAAM,EAAyB,WAFZ,+BAE+C,CAChE,SAAU,IAAI,IACd,SAAU,IAAI,IACd,SAAU,IAAI,IACd,gBAAiB,IAAI,IACrB,MAAO,CAAC,EACR,OAAQ,IAAI,IACZ,aAAc,IAChB,GAEQ,WAAU,WAAU,WAAU,kBAAiB,QAAO,UAAW,EAEzE,SAAS,CAAQ,CAAC,EAAY,EAAgB,CAC5C,MAAO,GAAG,QAAO,IAGZ,SAAS,CAAkB,CAAC,EAA6B,CAM9D,GAAI,EAAS,IAAI,EAAM,EAAE,EACvB,OAEF,EAAS,IAAI,EAAM,GAAI,CAAK,EAC5B,EAAM,KAAK,EAAM,EAAE,EAId,SAAS,CAA0B,EAAW,CACnD,OAAO,EAAM,OAGR,SAAS,CAAW,CACzB,EACA,EAC2B,CAC3B,OAAO,EAAS,IAAI,CAAE,GAAG,IAAI,CAAM,EAGrC,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OAGJ,EAAQ,EAAE,EAAI,EAAQ,KAAiC,CAC3D,EAAY,EAAI,EAAQ,CAAO,GAE3B,EAAW,MAAM,QAAQ,EAAE,aAAa,EAAI,EAAE,cAAgB,CAAC,EACrE,EAAE,cAAgB,CAAE,KAAM,CAAM,EAChC,QAAW,KAAS,EAClB,EAAM,CAAK,EAKR,SAAS,CAAyB,EAAG,CAC1C,EAAS,MAAM,EACf,EAAS,MAAM,EACf,EAAS,MAAM,EACf,EAAgB,MAAM,EACtB,EAAO,MAAM,EACb,EAAM,OAAS,EACf,EAAM,aAAe,KC5ZhB,SAAS,CAAoB,EAAmB,CACrD,IAAM,EAAO,IAAI,IACX,EAAiD,CAAC,EAGlD,EAA2B,CAAC,EAElC,MAAO,CACL,GAAG,CAAC,EAAI,EAAQ,EAAS,CACvB,IAAM,EAAM,GAAG,KAAM,IACrB,GAAI,EAAK,IAAI,CAAG,EAAG,OACnB,EAAK,IAAI,CAAG,EACZ,IAAM,EAAuB,CAAE,KAAI,SAAQ,SAAQ,EACnD,GAAI,EAAU,SAAW,EAAG,CAC1B,EAAQ,KAAK,CAAK,EAClB,OAEF,QAAW,KAAY,EAAW,EAAS,CAAK,GAElD,KAAK,CAAC,EAAI,CACR,EAAU,KAAK,CAAE,EACjB,MAAO,EAAQ,OAAS,EACtB,EAAG,EAAQ,MAAM,CAAE,EAGzB",
|
|
9
|
-
"debugId": "
|
|
9
|
+
"debugId": "53C7B37301D158BB64756E2164756E21",
|
|
10
10
|
"names": []
|
|
11
11
|
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
// @bun
|
|
2
|
-
import{
|
|
2
|
+
import{Vl as s}from"./chunk-fzy1z97a.js";var i=s((t,e)=>{e.exports={name:"@aws-sdk/nested-clients",version:"3.996.14",description:"Nested clients for AWS SDK packages.",main:"./dist-cjs/index.js",module:"./dist-es/index.js",types:"./dist-types/index.d.ts",scripts:{build:"yarn lint && concurrently 'yarn:build:types' 'yarn:build:es' && yarn build:cjs","build:cjs":"node ../../scripts/compilation/inline nested-clients","build:es":"tsc -p tsconfig.es.json","build:include:deps":'yarn g:turbo run build -F="$npm_package_name"',"build:types":"tsc -p tsconfig.types.json","build:types:downlevel":"downlevel-dts dist-types dist-types/ts3.4",clean:"premove dist-cjs dist-es dist-types tsconfig.cjs.tsbuildinfo tsconfig.es.tsbuildinfo tsconfig.types.tsbuildinfo",lint:"node ../../scripts/validation/submodules-linter.js --pkg nested-clients",test:"yarn g:vitest run","test:watch":"yarn g:vitest watch"},engines:{node:">=20.0.0"},sideEffects:!1,author:{name:"AWS SDK for JavaScript Team",url:"https://aws.amazon.com/javascript/"},license:"Apache-2.0",dependencies:{"@aws-crypto/sha256-browser":"5.2.0","@aws-crypto/sha256-js":"5.2.0","@aws-sdk/core":"^3.973.24","@aws-sdk/middleware-host-header":"^3.972.8","@aws-sdk/middleware-logger":"^3.972.8","@aws-sdk/middleware-recursion-detection":"^3.972.8","@aws-sdk/middleware-user-agent":"^3.972.25","@aws-sdk/region-config-resolver":"^3.972.9","@aws-sdk/types":"^3.973.6","@aws-sdk/util-endpoints":"^3.996.5","@aws-sdk/util-user-agent-browser":"^3.972.8","@aws-sdk/util-user-agent-node":"^3.973.11","@smithy/config-resolver":"^4.4.13","@smithy/core":"^3.23.12","@smithy/fetch-http-handler":"^5.3.15","@smithy/hash-node":"^4.2.12","@smithy/invalid-dependency":"^4.2.12","@smithy/middleware-content-length":"^4.2.12","@smithy/middleware-endpoint":"^4.4.27","@smithy/middleware-retry":"^4.4.44","@smithy/middleware-serde":"^4.2.15","@smithy/middleware-stack":"^4.2.12","@smithy/node-config-provider":"^4.3.12","@smithy/node-http-handler":"^4.5.0","@smithy/protocol-http":"^5.3.12","@smithy/smithy-client":"^4.12.7","@smithy/types":"^4.13.1","@smithy/url-parser":"^4.2.12","@smithy/util-base64":"^4.3.2","@smithy/util-body-length-browser":"^4.2.2","@smithy/util-body-length-node":"^4.2.3","@smithy/util-defaults-mode-browser":"^4.3.43","@smithy/util-defaults-mode-node":"^4.2.47","@smithy/util-endpoints":"^3.3.3","@smithy/util-middleware":"^4.2.12","@smithy/util-retry":"^4.2.12","@smithy/util-utf8":"^4.2.2",tslib:"^2.6.2"},devDependencies:{concurrently:"7.0.0","downlevel-dts":"0.10.1",premove:"4.0.0",typescript:"~5.8.3"},typesVersions:{"<4.5":{"dist-types/*":["dist-types/ts3.4/*"]}},files:["./cognito-identity.d.ts","./cognito-identity.js","./signin.d.ts","./signin.js","./sso-oidc.d.ts","./sso-oidc.js","./sso.d.ts","./sso.js","./sts.d.ts","./sts.js","dist-*/**"],browser:{"./dist-es/submodules/cognito-identity/runtimeConfig":"./dist-es/submodules/cognito-identity/runtimeConfig.browser","./dist-es/submodules/signin/runtimeConfig":"./dist-es/submodules/signin/runtimeConfig.browser","./dist-es/submodules/sso-oidc/runtimeConfig":"./dist-es/submodules/sso-oidc/runtimeConfig.browser","./dist-es/submodules/sso/runtimeConfig":"./dist-es/submodules/sso/runtimeConfig.browser","./dist-es/submodules/sts/runtimeConfig":"./dist-es/submodules/sts/runtimeConfig.browser"},"react-native":{},homepage:"https://github.com/aws/aws-sdk-js-v3/tree/main/packages/nested-clients",repository:{type:"git",url:"https://github.com/aws/aws-sdk-js-v3.git",directory:"packages/nested-clients"},exports:{"./package.json":"./package.json","./sso-oidc":{types:"./dist-types/submodules/sso-oidc/index.d.ts",module:"./dist-es/submodules/sso-oidc/index.js",node:"./dist-cjs/submodules/sso-oidc/index.js",import:"./dist-es/submodules/sso-oidc/index.js",require:"./dist-cjs/submodules/sso-oidc/index.js"},"./sts":{types:"./dist-types/submodules/sts/index.d.ts",module:"./dist-es/submodules/sts/index.js",node:"./dist-cjs/submodules/sts/index.js",import:"./dist-es/submodules/sts/index.js",require:"./dist-cjs/submodules/sts/index.js"},"./signin":{types:"./dist-types/submodules/signin/index.d.ts",module:"./dist-es/submodules/signin/index.js",node:"./dist-cjs/submodules/signin/index.js",import:"./dist-es/submodules/signin/index.js",require:"./dist-cjs/submodules/signin/index.js"},"./cognito-identity":{types:"./dist-types/submodules/cognito-identity/index.d.ts",module:"./dist-es/submodules/cognito-identity/index.js",node:"./dist-cjs/submodules/cognito-identity/index.js",import:"./dist-es/submodules/cognito-identity/index.js",require:"./dist-cjs/submodules/cognito-identity/index.js"},"./sso":{types:"./dist-types/submodules/sso/index.d.ts",module:"./dist-es/submodules/sso/index.js",node:"./dist-cjs/submodules/sso/index.js",import:"./dist-es/submodules/sso/index.js",require:"./dist-cjs/submodules/sso/index.js"}}}});
|
|
3
3
|
export{i as h};
|
|
4
4
|
|
|
5
|
-
//# debugId=
|
|
5
|
+
//# debugId=0C37E8439003544D64756E2164756E21
|