elanous 0.2.20 → 0.2.22
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/apps/pwa/out/404/index.html +1 -1
- package/apps/pwa/out/404.html +1 -1
- package/apps/pwa/out/_next/static/aBi6EyMtLsrl7J8eH4kF7/_buildManifest.js +1 -0
- package/apps/pwa/out/_next/static/chunks/088d8e8a.8069543d082bec12.js +160 -0
- package/apps/pwa/out/_next/static/chunks/1109.78a7a3288c0259d9.js +148 -0
- package/apps/pwa/out/_next/static/chunks/115.1c6690b8604f81c4.js +32 -0
- package/apps/pwa/out/_next/static/chunks/119fc678.6f591cdb84ca5791.js +1 -0
- package/apps/pwa/out/_next/static/chunks/1262.76a3f08e67c5f816.js +309 -0
- package/apps/pwa/out/_next/static/chunks/1307-08b716476f1d50af.js +1 -0
- package/apps/pwa/out/_next/static/chunks/1358d292.5c87f12cad6eaa91.js +122 -0
- package/apps/pwa/out/_next/static/chunks/1438.27a1a7b8f2308004.js +149 -0
- package/apps/pwa/out/_next/static/chunks/1442.02d85cd88f4c1eac.js +79 -0
- package/apps/pwa/out/_next/static/chunks/1501-1aad662d82ba43f7.js +1 -0
- package/apps/pwa/out/_next/static/chunks/1584.9e2dd53da6e6d4b1.js +24 -0
- package/apps/pwa/out/_next/static/chunks/1586.b989b0614afb77e6.js +1 -0
- package/apps/pwa/out/_next/static/chunks/1609.2ad355062870151f.js +1 -0
- package/apps/pwa/out/_next/static/chunks/1612-f6df0fc0eed7157b.js +1 -0
- package/apps/pwa/out/_next/static/chunks/1923.37f1d5fe7ebe3860.js +27 -0
- package/apps/pwa/out/_next/static/chunks/1948.5f35b39eef222a94.js +5 -0
- package/apps/pwa/out/_next/static/chunks/1993.3fd074a2a246234e.js +1 -0
- package/apps/pwa/out/_next/static/chunks/2140.d2daf9ee96e295d1.js +1 -0
- package/apps/pwa/out/_next/static/chunks/2212.0359851457473efc.js +1 -0
- package/apps/pwa/out/_next/static/chunks/224.583e562365a52f74.js +1 -0
- package/apps/pwa/out/_next/static/chunks/2328.0f37465646bafa7d.js +36 -0
- package/apps/pwa/out/_next/static/chunks/2372.bf71372184991937.js +286 -0
- package/apps/pwa/out/_next/static/chunks/{2489-ff55a35b202c0f94.js → 2489-d238d3e2eb5b2bf5.js} +1 -1
- package/apps/pwa/out/_next/static/chunks/2549-a8515c86f9e8cb96.js +1 -0
- package/apps/pwa/out/_next/static/chunks/2655.72cc6a97276c5acc.js +1 -0
- package/apps/pwa/out/_next/static/chunks/2743-ef6e8c3ced74cce5.js +1 -0
- package/apps/pwa/out/_next/static/chunks/2840-5458ad50c49cac6a.js +1 -0
- package/apps/pwa/out/_next/static/chunks/2856.f75d5baef7f49b74.js +1 -0
- package/apps/pwa/out/_next/static/chunks/3344.0de4b0ec5a454b7a.js +1 -0
- package/apps/pwa/out/_next/static/chunks/335.a13f339e97893437.js +94 -0
- package/apps/pwa/out/_next/static/chunks/3394.646348f34b2500be.js +1 -0
- package/apps/pwa/out/_next/static/chunks/3443.6276909b53d72d53.js +1 -0
- package/apps/pwa/out/_next/static/chunks/3495.abd4254d808bf2dc.js +1 -0
- package/apps/pwa/out/_next/static/chunks/3522-1de1319d028ac89c.js +25 -0
- package/apps/pwa/out/_next/static/chunks/3721.ba5b82db0d9a5572.js +1 -0
- package/apps/pwa/out/_next/static/chunks/3857-5985236d9307f676.js +1 -0
- package/apps/pwa/out/_next/static/chunks/3919.9ff7dc25afefee33.js +74 -0
- package/apps/pwa/out/_next/static/chunks/3998.bd9a69d9b50e9bd2.js +1 -0
- package/apps/pwa/out/_next/static/chunks/4003.ab6db1dc266576c9.js +1 -0
- package/apps/pwa/out/_next/static/chunks/4216.e8ac94b9fe6b96ab.js +1 -0
- package/apps/pwa/out/_next/static/chunks/4327.c44dc2b55cb43ee5.js +34 -0
- package/apps/pwa/out/_next/static/chunks/4401.94257d497b6d26bc.js +1 -0
- package/apps/pwa/out/_next/static/chunks/4559.17ca2cdbaa8d414f.js +115 -0
- package/apps/pwa/out/_next/static/chunks/4588.ad3364cb7fb97ada.js +86 -0
- package/apps/pwa/out/_next/static/chunks/4706.97e734bd4c9816ca.js +1 -0
- package/apps/pwa/out/_next/static/chunks/4982.6e44352f751b9a1b.js +77 -0
- package/apps/pwa/out/_next/static/chunks/5342.49c5c5a530e62b50.js +1 -0
- package/apps/pwa/out/_next/static/chunks/5360-08a80abdf3a4da99.js +1 -0
- package/apps/pwa/out/_next/static/chunks/5431.66c58ab1327ee0b7.js +1 -0
- package/apps/pwa/out/_next/static/chunks/5633-d6852385000738ef.js +1 -0
- package/apps/pwa/out/_next/static/chunks/5717.bcfcb96e701b82e0.js +90 -0
- package/apps/pwa/out/_next/static/chunks/5755-30d102586789bf7f.js +1 -0
- package/apps/pwa/out/_next/static/chunks/5957.3f1a4012388dd962.js +1 -0
- package/apps/pwa/out/_next/static/chunks/5977-5b9e8a45a5b0c823.js +1 -0
- package/apps/pwa/out/_next/static/chunks/602.9bf02ac8e9502598.js +1 -0
- package/apps/pwa/out/_next/static/chunks/6020.3a1b347e2d2dfacc.js +8 -0
- package/apps/pwa/out/_next/static/chunks/{6158.af2e93b7adff709b.js → 6158.566c890adc06a459.js} +1 -1
- package/apps/pwa/out/_next/static/chunks/6375.fce1d174ba6d0324.js +64 -0
- package/apps/pwa/out/_next/static/chunks/6546.92a828aef441271f.js +1 -0
- package/apps/pwa/out/_next/static/chunks/658.957fdb0a8c6c6c8e.js +287 -0
- package/apps/pwa/out/_next/static/chunks/6706.323590aabb8b1293.js +226 -0
- package/apps/pwa/out/_next/static/chunks/6747.b67947f293a4c02d.js +1 -0
- package/apps/pwa/out/_next/static/chunks/6767.8e6c5f6e744fcd9f.js +38 -0
- package/apps/pwa/out/_next/static/chunks/6868.000b24a3045c5574.js +1 -0
- package/apps/pwa/out/_next/static/chunks/6946.bba74e9c96050f30.js +1 -0
- package/apps/pwa/out/_next/static/chunks/7033.a558f1b2f6912a53.js +1 -0
- package/apps/pwa/out/_next/static/chunks/7065.46029c26c53eac50.js +1 -0
- package/apps/pwa/out/_next/static/chunks/7087.6fae577d09249bc1.js +1 -0
- package/apps/pwa/out/_next/static/chunks/7175-350f4ce2873bc038.js +1 -0
- package/apps/pwa/out/_next/static/chunks/722.de8d9801e0f6d414.js +41 -0
- package/apps/pwa/out/_next/static/chunks/7497.57981e9d7a75a52a.js +24 -0
- package/apps/pwa/out/_next/static/chunks/7630.2b9a68659053ff4e.js +193 -0
- package/apps/pwa/out/_next/static/chunks/7672.4af122ad892117c7.js +1 -0
- package/apps/pwa/out/_next/static/chunks/771.6ab889a233e7dae7.js +1 -0
- package/apps/pwa/out/_next/static/chunks/7899.597af4a9996c907f.js +1 -0
- package/apps/pwa/out/_next/static/chunks/79b78388.663188133449d707.js +1 -0
- package/apps/pwa/out/_next/static/chunks/8096.f7da0776cfde6300.js +1 -0
- package/apps/pwa/out/_next/static/chunks/8194.484f51e273d9abd2.js +217 -0
- package/apps/pwa/out/_next/static/chunks/8769.815ca69879f608b4.js +104 -0
- package/apps/pwa/out/_next/static/chunks/8857-aa1cc4ac90af4d40.js +1 -0
- package/apps/pwa/out/_next/static/chunks/88729267.9c6c000157c83f2f.js +62 -0
- package/apps/pwa/out/_next/static/chunks/8f835b4f.048eeb02299e3e12.js +1 -0
- package/apps/pwa/out/_next/static/chunks/9068.5f2764fccf86c1b2.js +93 -0
- package/apps/pwa/out/_next/static/chunks/9247-55bcfbb0e8057f59.js +1 -0
- package/apps/pwa/out/_next/static/chunks/9451.ebfb0dcc9c02250f.js +23 -0
- package/apps/pwa/out/_next/static/chunks/9559.e648369b1d57cf9a.js +62 -0
- package/apps/pwa/out/_next/static/chunks/9832.2ab2e818013574c7.js +1 -0
- package/apps/pwa/out/_next/static/chunks/a9f2b54d-40c16bd0efdb04b8.js +1 -0
- package/apps/pwa/out/_next/static/chunks/app/approvals/{page-c855c24de7db74fe.js → page-88459e0903da2803.js} +1 -1
- package/apps/pwa/out/_next/static/chunks/app/autopilot/{page-85b316bb4235980b.js → page-d85c43f46f58716b.js} +1 -1
- package/apps/pwa/out/_next/static/chunks/app/board/{page-9b2b26a33cb2cd42.js → page-4e645600579ae952.js} +1 -1
- package/apps/pwa/out/_next/static/chunks/app/botlab/{page-c9955fde67b1bcb5.js → page-87edbfd19117823b.js} +1 -1
- package/apps/pwa/out/_next/static/chunks/app/bots/page-7f0c2b7801ac6a54.js +1 -0
- package/apps/pwa/out/_next/static/chunks/app/ceo/page-bf1f030a9d1adffd.js +1 -0
- package/apps/pwa/out/_next/static/chunks/app/chat/{page-4ba4abe096b6c2a8.js → page-cbaf66b1e1804adf.js} +1 -1
- package/apps/pwa/out/_next/static/chunks/app/consult/{page-575d4a8b4f7becb2.js → page-80ed511e02c81412.js} +1 -1
- package/apps/pwa/out/_next/static/chunks/app/control/{page-f5d56ff5f45ad164.js → page-9f5610caaa06178c.js} +1 -1
- package/apps/pwa/out/_next/static/chunks/app/decisions/{page-2260e9eef0357421.js → page-ec8f3575e339de74.js} +1 -1
- package/apps/pwa/out/_next/static/chunks/app/design-check/page-86d753e460f1a989.js +1 -0
- package/apps/pwa/out/_next/static/chunks/app/editor/page-4166a7d51cf0a57d.js +1 -0
- package/apps/pwa/out/_next/static/chunks/app/exec/{page-466bf0ee16ad1432.js → page-2a19c5cd3b562580.js} +1 -1
- package/apps/pwa/out/_next/static/chunks/app/field/{page-a23bc71713bcc08f.js → page-b6a09cde2e07521a.js} +1 -1
- package/apps/pwa/out/_next/static/chunks/app/inside/page-f7eae1518ca0c353.js +1 -0
- package/apps/pwa/out/_next/static/chunks/app/intake/page-456a8573ad811381.js +1 -0
- package/apps/pwa/out/_next/static/chunks/app/layout-8462d6a543cbb2d9.js +1 -0
- package/apps/pwa/out/_next/static/chunks/app/live/page-2974cdfb87c0f9c9.js +1 -0
- package/apps/pwa/out/_next/static/chunks/app/live-run/page-f927ffa25f3c86d1.js +1 -0
- package/apps/pwa/out/_next/static/chunks/app/loops/{page-35bfec2e631d3eae.js → page-abd86cd832aaa011.js} +1 -1
- package/apps/pwa/out/_next/static/chunks/app/market/page-79daf68f6256adaa.js +1 -0
- package/apps/pwa/out/_next/static/chunks/app/missions/[id]/{page-f9ccb1b1adbea14d.js → page-8c3f168fc3f91939.js} +1 -1
- package/apps/pwa/out/_next/static/chunks/app/morning/{page-ec102c9b8b691e37.js → page-786fb4504d0f2fa9.js} +1 -1
- package/apps/pwa/out/_next/static/chunks/app/not-found-75209f14597dcb8f.js +1 -0
- package/apps/pwa/out/_next/static/chunks/app/observatory/page-bf30affe3a85af7e.js +1 -0
- package/apps/pwa/out/_next/static/chunks/app/ops/checklist/page-1187a44b7515434b.js +1 -0
- package/apps/pwa/out/_next/static/chunks/app/ops/release/page-3d0910185a66ed54.js +1 -0
- package/apps/pwa/out/_next/static/chunks/app/ops/seats/page-f401ee1dd5a26e25.js +1 -0
- package/apps/pwa/out/_next/static/chunks/app/outputs/page-5dfe7604fd842784.js +1 -0
- package/apps/pwa/out/_next/static/chunks/app/page-76cf838050a8d681.js +1 -0
- package/apps/pwa/out/_next/static/chunks/app/reflection/{page-db03ae3589a81c9e.js → page-7ec8e289b4c14df6.js} +1 -1
- package/apps/pwa/out/_next/static/chunks/app/scheduler/{page-4a6463b97f0ad94f.js → page-8c8ac17d52be2a79.js} +1 -1
- package/apps/pwa/out/_next/static/chunks/app/sessions/{page-75bffecc9aa1004e.js → page-d359ab048d63a9d9.js} +1 -1
- package/apps/pwa/out/_next/static/chunks/app/settings/devices/page-b8b345c880bf78d1.js +1 -0
- package/apps/pwa/out/_next/static/chunks/app/settings/{page-31d5b875760bb62d.js → page-f151cc10ad026940.js} +1 -1
- package/apps/pwa/out/_next/static/chunks/app/setup/done/page-9875f103057da433.js +1 -0
- package/apps/pwa/out/_next/static/chunks/app/setup/page-9789328af9a9aa62.js +1 -0
- package/apps/pwa/out/_next/static/chunks/app/share/{page-46d5201d2207a511.js → page-bf495a1e284f4e00.js} +1 -1
- package/apps/pwa/out/_next/static/chunks/app/showroom/page-a263d94bca4be22a.js +1 -0
- package/apps/pwa/out/_next/static/chunks/app/tasks/page-3962eab8ec58d16e.js +1 -0
- package/apps/pwa/out/_next/static/chunks/app/term/{page-cf0a4b4abead71ea.js → page-9abcfac07e02a542.js} +1 -1
- package/apps/pwa/out/_next/static/chunks/app/today/page-bee49f927c333abb.js +1 -0
- package/apps/pwa/out/_next/static/chunks/app/trace/page-bac2d56dcb02d955.js +1 -0
- package/apps/pwa/out/_next/static/chunks/app/vault/page-937cbcc13176295c.js +1 -0
- package/apps/pwa/out/_next/static/chunks/app/workflows/chat-ui/page-d09495594f7f480d.js +1 -0
- package/apps/pwa/out/_next/static/chunks/app/workflows/{page-0acc8e198f7b0dfb.js → page-69cb93d1a2e57e0e.js} +1 -1
- package/apps/pwa/out/_next/static/chunks/app/workspace/{page-34882c84f84021c5.js → page-72ec543928d67c3e.js} +1 -1
- package/apps/pwa/out/_next/static/chunks/app/worktrees/page-82906eeda0186a7b.js +1 -0
- package/apps/pwa/out/_next/static/chunks/d70879db.c66c56a95a91efc6.js +66 -0
- package/apps/pwa/out/_next/static/chunks/f8626309.a4e5d362b1d55e59.js +1 -0
- package/apps/pwa/out/_next/static/chunks/webpack-f2b4016b9b981bc8.js +1 -0
- package/apps/pwa/out/_next/static/css/{d3427996da11e480.css → b9d8151e48998417.css} +1 -1
- package/apps/pwa/out/_next/static/css/f2bd5257e6af88d8.css +1 -0
- package/apps/pwa/out/approvals/index.html +1 -1
- package/apps/pwa/out/approvals/index.txt +14 -14
- package/apps/pwa/out/autopilot/index.html +1 -1
- package/apps/pwa/out/autopilot/index.txt +14 -14
- package/apps/pwa/out/board/index.html +1 -1
- package/apps/pwa/out/board/index.txt +14 -14
- package/apps/pwa/out/botlab/index.html +1 -1
- package/apps/pwa/out/botlab/index.txt +14 -14
- package/apps/pwa/out/bots/index.html +1 -1
- package/apps/pwa/out/bots/index.txt +14 -14
- package/apps/pwa/out/ceo/index.html +1 -1
- package/apps/pwa/out/ceo/index.txt +14 -14
- package/apps/pwa/out/chat/index.html +1 -1
- package/apps/pwa/out/chat/index.txt +14 -14
- package/apps/pwa/out/consult/index.html +1 -1
- package/apps/pwa/out/consult/index.txt +14 -14
- package/apps/pwa/out/control/index.html +1 -1
- package/apps/pwa/out/control/index.txt +14 -14
- package/apps/pwa/out/decisions/index.html +1 -1
- package/apps/pwa/out/decisions/index.txt +14 -14
- package/apps/pwa/out/design-check/index.html +1 -1
- package/apps/pwa/out/design-check/index.txt +14 -14
- package/apps/pwa/out/editor/index.html +1 -1
- package/apps/pwa/out/editor/index.txt +15 -15
- package/apps/pwa/out/exec/index.html +1 -1
- package/apps/pwa/out/exec/index.txt +14 -14
- package/apps/pwa/out/field/index.html +1 -1
- package/apps/pwa/out/field/index.txt +14 -14
- package/apps/pwa/out/healthz +1 -1
- package/apps/pwa/out/index.html +1 -1
- package/apps/pwa/out/index.txt +14 -14
- package/apps/pwa/out/inside/index.html +1 -1
- package/apps/pwa/out/inside/index.txt +15 -15
- package/apps/pwa/out/intake/index.html +1 -1
- package/apps/pwa/out/intake/index.txt +14 -14
- package/apps/pwa/out/live/index.html +1 -1
- package/apps/pwa/out/live/index.txt +14 -14
- package/apps/pwa/out/live-run/index.html +1 -0
- package/apps/pwa/out/live-run/index.txt +35 -0
- package/apps/pwa/out/loops/index.html +1 -1
- package/apps/pwa/out/loops/index.txt +14 -14
- package/apps/pwa/out/market/index.html +1 -1
- package/apps/pwa/out/market/index.txt +14 -14
- package/apps/pwa/out/missions/placeholder/index.html +1 -1
- package/apps/pwa/out/missions/placeholder/index.txt +14 -14
- package/apps/pwa/out/morning/index.html +1 -1
- package/apps/pwa/out/morning/index.txt +14 -14
- package/apps/pwa/out/observatory/index.html +1 -1
- package/apps/pwa/out/observatory/index.txt +14 -14
- package/apps/pwa/out/ops/checklist/index.html +1 -1
- package/apps/pwa/out/ops/checklist/index.txt +14 -14
- package/apps/pwa/out/ops/release/index.html +1 -1
- package/apps/pwa/out/ops/release/index.txt +14 -14
- package/apps/pwa/out/ops/seats/index.html +1 -1
- package/apps/pwa/out/ops/seats/index.txt +14 -14
- package/apps/pwa/out/outputs/index.html +1 -1
- package/apps/pwa/out/outputs/index.txt +14 -14
- package/apps/pwa/out/reflection/index.html +1 -1
- package/apps/pwa/out/reflection/index.txt +15 -15
- package/apps/pwa/out/scheduler/index.html +1 -1
- package/apps/pwa/out/scheduler/index.txt +14 -14
- package/apps/pwa/out/sessions/index.html +1 -1
- package/apps/pwa/out/sessions/index.txt +14 -14
- package/apps/pwa/out/settings/devices/index.html +1 -1
- package/apps/pwa/out/settings/devices/index.txt +14 -14
- package/apps/pwa/out/settings/index.html +1 -1
- package/apps/pwa/out/settings/index.txt +14 -14
- package/apps/pwa/out/setup/done/index.html +1 -1
- package/apps/pwa/out/setup/done/index.txt +14 -14
- package/apps/pwa/out/setup/index.html +1 -1
- package/apps/pwa/out/setup/index.txt +14 -14
- package/apps/pwa/out/share/index.html +1 -1
- package/apps/pwa/out/share/index.txt +14 -14
- package/apps/pwa/out/showroom/index.html +1 -1
- package/apps/pwa/out/showroom/index.txt +14 -14
- package/apps/pwa/out/tasks/index.html +1 -1
- package/apps/pwa/out/tasks/index.txt +14 -14
- package/apps/pwa/out/term/index.html +1 -1
- package/apps/pwa/out/term/index.txt +14 -14
- package/apps/pwa/out/today/index.html +1 -1
- package/apps/pwa/out/today/index.txt +14 -14
- package/apps/pwa/out/trace/index.html +1 -1
- package/apps/pwa/out/trace/index.txt +14 -14
- package/apps/pwa/out/vault/index.html +1 -1
- package/apps/pwa/out/vault/index.txt +14 -14
- package/apps/pwa/out/workflows/chat-ui/index.html +1 -1
- package/apps/pwa/out/workflows/chat-ui/index.txt +14 -14
- package/apps/pwa/out/workflows/index.html +1 -1
- package/apps/pwa/out/workflows/index.txt +14 -14
- package/apps/pwa/out/workspace/index.html +1 -1
- package/apps/pwa/out/workspace/index.txt +14 -14
- package/apps/pwa/out/worktrees/index.html +1 -1
- package/apps/pwa/out/worktrees/index.txt +14 -14
- package/graphs/catalog/catalog.yaml +1 -1
- package/graphs/drafts/recipes.yaml +6 -6
- package/graphs/implement-loop.yaml +277 -5
- package/graphs/test-diet/recipes.yaml +3 -0
- package/graphs/test-diet/test-diet.yaml +3 -1
- package/package.json +1 -1
- package/scripts/coord-channel-watch.sh +31 -4
- package/scripts/docs-lint.ts +4 -1
- package/scripts/f-session-monitor.ts +69 -0
- package/scripts/hq/standby-snapshot.ts +7 -3
- package/scripts/knowledge-compress.ts +11 -0
- package/scripts/marketing/generate-ax-brief.ts +18 -1
- package/scripts/measure-nl-routing-corpus.ts +11 -3
- package/scripts/nightly-docops.ts +90 -3
- package/scripts/release-loop/gate-node.ts +5 -5
- package/scripts/release-loop/shard-plan.ts +50 -5
- package/scripts/research-coo-admin-dates.ts +39 -0
- package/scripts/rhythm/daily.ts +2 -1
- package/scripts/skills/public-check.ts +7 -2
- package/scripts/smart-merge/resync-shadow.ts +5 -3
- package/scripts/test-diet/lib.ts +81 -1
- package/scripts/test-diet/node.ts +48 -2
- package/scripts/verify-coo-admin-evidence.ts +83 -0
- package/src/acp/client.ts +4 -2
- package/src/agent/run-context.ts +4 -0
- package/src/agent-env/profile.ts +25 -5
- package/src/agent-mission/driver.ts +26 -12
- package/src/agent-mission/supervisor-metrics.ts +17 -2
- package/src/agent-substrate/acp-reviewer.ts +12 -5
- package/src/agent-substrate/pr-reviewer.ts +11 -4
- package/src/agent-substrate/review-intent.ts +102 -3
- package/src/autopilot/build/llm-conflict-merge.ts +22 -8
- package/src/autopilot/pr-manager.ts +18 -8
- package/src/away/release-watch.ts +47 -8
- package/src/briefing/brief-items.ts +104 -11
- package/src/browser-cdp/client.ts +10 -5
- package/src/chat/index.ts +1 -0
- package/src/cli/brief-cli.ts +20 -2
- package/src/cli/config-classify.ts +83 -0
- package/src/cli/control-cli.ts +14 -0
- package/src/cli/decisions-cli.ts +26 -16
- package/src/cli/logs-model-input.ts +1 -1
- package/src/cli/ops-cli.ts +11 -0
- package/src/cli/ops-overview-cli.ts +50 -0
- package/src/cli/pod-cli.ts +1 -0
- package/src/cli/pr-cli.ts +65 -8
- package/src/cli/release-cli.ts +21 -4
- package/src/cli/tasks-cli.ts +214 -1
- package/src/connectors/types.ts +6 -6
- package/src/context-bus/context-now-surfaces.ts +18 -0
- package/src/context-bus/coord-events.ts +32 -4
- package/src/context-bus/long-term-memory.ts +23 -6
- package/src/context-bus/nightly-condense.ts +169 -21
- package/src/control/control-status.ts +87 -0
- package/src/control-plane/light-member.ts +5 -3
- package/src/control-plane/member.ts +172 -7
- package/src/core-turn/run-goal-loop.ts +22 -1
- package/src/dashboard/index.ts +40 -4
- package/src/dashboard/slash-runtime/dashboard-handlers.ts +9 -0
- package/src/decisions/decision-cards.ts +20 -1
- package/src/decisions/decision-ledger.ts +11 -8
- package/src/decisions/web-push-decision-cards.ts +19 -3
- package/src/discord-self-message.ts +2 -2
- package/src/domains/coo-admin-dates.evidence.json +876 -0
- package/src/domains/coo-admin-tool.ts +48 -14
- package/src/domains/ops-status.ts +53 -0
- package/src/domains/outbound-alert.ts +24 -1
- package/src/esc-abort-gate.ts +3 -1
- package/src/exec-requests/planner.ts +6 -0
- package/src/graph-kinds/registry.ts +6 -6
- package/src/graph-runner/graph-cli.ts +91 -2
- package/src/graph-runner/graph-run-api.ts +20 -0
- package/src/graph-runner/graph-tick.ts +73 -12
- package/src/graph-runner/runner.ts +43 -11
- package/src/graph-unify/wf-to-graph.ts +79 -0
- package/src/graph-wizard/archetypes.ts +88 -0
- package/src/graph-wizard/generate.ts +577 -0
- package/src/graph-wizard/saved-steps.ts +120 -0
- package/src/graph-wizard/steps.ts +206 -0
- package/src/harness/harness-cli-command.ts +186 -32
- package/src/harness/harness-queue.ts +58 -14
- package/src/harness/launch-advice.ts +23 -0
- package/src/index.ts +43 -11
- package/src/intake-plane/digest.ts +18 -11
- package/src/knowledge/conclusion-compress.ts +93 -0
- package/src/knowledge/know-find.ts +9 -2
- package/src/knowledge/query.ts +20 -0
- package/src/llm.ts +26 -16
- package/src/loops/neighbor-runtime.ts +88 -0
- package/src/loops/orchestrator/author-depth.ts +29 -11
- package/src/loops/orchestrator/overlap.ts +7 -1
- package/src/loops/orchestrator/resync-shadow.ts +1 -1
- package/src/loops/orchestrator/tick.ts +35 -2
- package/src/loops/orchestrator/traffic.ts +2 -0
- package/src/loops/registry.ts +5 -0
- package/src/market/publish.ts +17 -1
- package/src/maturity/feature-maturity.ts +4 -2
- package/src/mss/logging/redaction.ts +17 -0
- package/src/nexus/api/draft-metrics.ts +128 -0
- package/src/nexus/api/graph-peer-edit.ts +77 -0
- package/src/nexus/api/graph-wizard-api.ts +61 -0
- package/src/nexus/api/graphs-api.ts +193 -17
- package/src/nexus/api/harness-traversal.ts +205 -0
- package/src/nexus/api/http-server.ts +122 -6
- package/src/nexus/api/plugins-market.ts +24 -0
- package/src/nexus/index.ts +3 -2
- package/src/nexus/outbound/router.ts +28 -8
- package/src/oauth/claude-pty-maturity.ts +24 -0
- package/src/oauth/fallback-chain.ts +27 -14
- package/src/onboarding/first-run.ts +3 -0
- package/src/ops/overview-collect.ts +345 -0
- package/src/ops/overview-seat-era.ts +90 -0
- package/src/ops/overview.ts +223 -0
- package/src/plugins/maker/market-bundle.ts +9 -0
- package/src/plugins/maker/plugin-maker.ts +9 -3
- package/src/plugins/maker/wizard-generate.ts +73 -9
- package/src/policy/llm-policy.ts +11 -6
- package/src/release-loop/checklist-board.ts +27 -0
- package/src/release-loop/checklist.ts +38 -0
- package/src/release-loop/gate-shards.ts +7 -2
- package/src/seat-address/seat-address.ts +1 -0
- package/src/seat-loop/seat-loop.ts +174 -20
- package/src/seat-loop/seat-report.ts +29 -1
- package/src/self-dev/ask-launch-flow.ts +4 -2
- package/src/self-dev/ask-launch-io.ts +3 -1
- package/src/self-dev/dev-cli.ts +90 -8
- package/src/self-dev/dev-pipeline.ts +20 -1
- package/src/self-dev/draft-sweep.ts +45 -8
- package/src/self-dev/graph-journey-nodes.ts +157 -0
- package/src/self-dev/graph-journey-route.ts +105 -0
- package/src/self-dev/launch-preflight.ts +43 -3
- package/src/self-dev/orchestrate.ts +3 -0
- package/src/self-dev/release-path-guard.ts +7 -4
- package/src/self-dev/review-provider-fallback.ts +83 -0
- package/src/self-dev/run-supervisor.ts +5 -1
- package/src/self-implement/frozen-merges.ts +23 -0
- package/src/self-implement/goal-author.ts +14 -0
- package/src/self-implement/harness-policy-gates.ts +7 -5
- package/src/self-implement/heal-intake.ts +3 -0
- package/src/self-implement/host-regate.ts +28 -14
- package/src/self-implement/l8-merge-queue.ts +80 -8
- package/src/self-implement/orchestrator.ts +84 -28
- package/src/self-implement/seams.ts +8 -3
- package/src/self-implement/self-implement-cli.ts +4 -0
- package/src/self-implement/self-implement-runtime.ts +12 -0
- package/src/session-runtime/index.ts +5 -3
- package/src/shell-env-bootstrap.ts +35 -6
- package/src/steward/triage.ts +25 -8
- package/src/storage/file-lock.ts +33 -4
- package/src/task-agent/card-evidence.ts +6 -0
- package/src/task-agent/completion-evidence.ts +31 -3
- package/src/task-agent/cover.ts +61 -0
- package/src/task-agent/live-moves.ts +126 -3
- package/src/task-agent/parent-host.ts +315 -0
- package/src/task-agent/shadow.ts +19 -4
- package/src/task-agent/task-hand.ts +11 -2
- package/src/task-orchestrator/surfaces/pod-command-job.ts +41 -6
- package/src/task-orchestrator/surfaces/pod-gate-deps.ts +123 -0
- package/src/task-orchestrator/surfaces/pod-pool.ts +138 -15
- package/src/task-orchestrator/surfaces/self-implement-pod.ts +39 -6
- package/src/task-orchestrator/surfaces/self-implement.ts +7 -0
- package/src/telegram-commands.ts +8 -0
- package/src/telegram-project-command.ts +6 -0
- package/src/telegram.ts +2 -2
- package/src/tool-runtime/browser-runtime.ts +87 -3
- package/src/tool-runtime/index.ts +1 -0
- package/src/typecheck-ratchet.ts +2 -1
- package/src/user-config.ts +55 -8
- package/src/version/packed-revision.json +1 -1
- package/src/workflow-runtime/executor.ts +24 -2
- package/src/workflow-runtime/triggers/registry.ts +27 -0
- package/src/workflow-runtime/triggers/schedule-source.ts +30 -3
- package/apps/pwa/out/_next/static/Bam1YziK2iH9bN4K0utGk/_buildManifest.js +0 -1
- package/apps/pwa/out/_next/static/chunks/1307-77fad80cf54477c6.js +0 -1
- package/apps/pwa/out/_next/static/chunks/1612-f60c0c93ec773f81.js +0 -1
- package/apps/pwa/out/_next/static/chunks/1844-9ec4b1d12f6e80eb.js +0 -1
- package/apps/pwa/out/_next/static/chunks/1866-e7a6999f25548b30.js +0 -1
- package/apps/pwa/out/_next/static/chunks/1948.15f356b15a625597.js +0 -5
- package/apps/pwa/out/_next/static/chunks/2116-6429c188eb846ab8.js +0 -1
- package/apps/pwa/out/_next/static/chunks/224-e7be8f762fe74986.js +0 -1
- package/apps/pwa/out/_next/static/chunks/2549-89c518a4c8ed4d00.js +0 -1
- package/apps/pwa/out/_next/static/chunks/2957-96ffab3d521fb08f.js +0 -1
- package/apps/pwa/out/_next/static/chunks/3857-995ea9f5ef33d71e.js +0 -1
- package/apps/pwa/out/_next/static/chunks/5360-be1f1d8f9fcc9755.js +0 -1
- package/apps/pwa/out/_next/static/chunks/5755-ea7ed88eb956f47b.js +0 -1
- package/apps/pwa/out/_next/static/chunks/5977-94ed6f78e9814b2b.js +0 -1
- package/apps/pwa/out/_next/static/chunks/7748-6e51bfe927019f5c.js +0 -25
- package/apps/pwa/out/_next/static/chunks/9247-c1753a059e7bac08.js +0 -1
- package/apps/pwa/out/_next/static/chunks/a9f2b54d-33c0689b70ed8cf3.js +0 -1
- package/apps/pwa/out/_next/static/chunks/app/bots/page-7a852956c74015a3.js +0 -1
- package/apps/pwa/out/_next/static/chunks/app/ceo/page-c5a5c621be0e04ae.js +0 -1
- package/apps/pwa/out/_next/static/chunks/app/design-check/page-7c058069c5e7fa63.js +0 -1
- package/apps/pwa/out/_next/static/chunks/app/editor/page-dc5da0b8a2edb8a4.js +0 -1
- package/apps/pwa/out/_next/static/chunks/app/inside/page-ed4a6f799f005d09.js +0 -1
- package/apps/pwa/out/_next/static/chunks/app/intake/page-9cd565005b93aca6.js +0 -1
- package/apps/pwa/out/_next/static/chunks/app/layout-55f0f40c6db95f15.js +0 -1
- package/apps/pwa/out/_next/static/chunks/app/live/page-474cb5888ea0e8f3.js +0 -1
- package/apps/pwa/out/_next/static/chunks/app/market/page-9ca21f9ad3208a61.js +0 -1
- package/apps/pwa/out/_next/static/chunks/app/not-found-a9c2cfa8dda922a5.js +0 -1
- package/apps/pwa/out/_next/static/chunks/app/observatory/page-6da35144878feb6d.js +0 -1
- package/apps/pwa/out/_next/static/chunks/app/ops/checklist/page-f6055495e9ed7ea8.js +0 -1
- package/apps/pwa/out/_next/static/chunks/app/ops/release/page-25204694fa9984a5.js +0 -1
- package/apps/pwa/out/_next/static/chunks/app/ops/seats/page-a60e035f151d84d3.js +0 -1
- package/apps/pwa/out/_next/static/chunks/app/outputs/page-189c587f36874538.js +0 -1
- package/apps/pwa/out/_next/static/chunks/app/page-c56634bde705a65d.js +0 -1
- package/apps/pwa/out/_next/static/chunks/app/settings/devices/page-a8d2fe0c669e0de4.js +0 -1
- package/apps/pwa/out/_next/static/chunks/app/setup/done/page-c26fa10aac6c21c4.js +0 -1
- package/apps/pwa/out/_next/static/chunks/app/setup/page-68793c6e10331d66.js +0 -1
- package/apps/pwa/out/_next/static/chunks/app/showroom/page-d81c07a7b4f618ae.js +0 -1
- package/apps/pwa/out/_next/static/chunks/app/tasks/page-be1c4e8697f22360.js +0 -1
- package/apps/pwa/out/_next/static/chunks/app/today/page-a4717e2c4bf7a28f.js +0 -1
- package/apps/pwa/out/_next/static/chunks/app/trace/page-0fd895fab9b62c1b.js +0 -1
- package/apps/pwa/out/_next/static/chunks/app/vault/page-8b6c1454a8e8f306.js +0 -1
- package/apps/pwa/out/_next/static/chunks/app/workflows/chat-ui/page-c6e4364d9de8f717.js +0 -1
- package/apps/pwa/out/_next/static/chunks/app/worktrees/page-0506a1e0e4bdb2f5.js +0 -1
- package/apps/pwa/out/_next/static/chunks/webpack-c260571513bf43c2.js +0 -1
- package/apps/pwa/out/_next/static/css/c23d959d3ee15e57.css +0 -1
- /package/apps/pwa/out/_next/static/{Bam1YziK2iH9bN4K0utGk → aBi6EyMtLsrl7J8eH4kF7}/_ssgManifest.js +0 -0
- /package/skills/project-onboarding/{skill.md → SKILL.md} +0 -0
|
@@ -0,0 +1,286 @@
|
|
|
1
|
+
"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[2372],{1394:(t,e,s)=>{s.d(e,{CP:()=>d,Ck:()=>y,HT:()=>p,PB:()=>u,aC:()=>h,lC:()=>l,m:()=>c,tk:()=>o});var i=s(13333),r=s(21201),a=s(56515),n=s(21930),o=(0,r.K)((t,e)=>{let s=t.append("rect");if(s.attr("x",e.x),s.attr("y",e.y),s.attr("fill",e.fill),s.attr("stroke",e.stroke),s.attr("width",e.width),s.attr("height",e.height),e.name&&s.attr("name",e.name),e.rx&&s.attr("rx",e.rx),e.ry&&s.attr("ry",e.ry),void 0!==e.attrs)for(let t in e.attrs)s.attr(t,e.attrs[t]);return e.class&&s.attr("class",e.class),s},"drawRect"),l=(0,r.K)((t,e)=>{o(t,{x:e.startx,y:e.starty,width:e.stopx-e.startx,height:e.stopy-e.starty,fill:e.fill,stroke:e.stroke,class:"rect"}).lower()},"drawBackgroundRect"),c=(0,r.K)((t,e)=>{let s=e.text.replace(i.H1," "),r=t.append("text");r.attr("x",e.x),r.attr("y",e.y),r.attr("class","legend"),r.style("text-anchor",e.anchor),e.class&&r.attr("class",e.class);let a=r.append("tspan");return a.attr("x",e.x+2*e.textMargin),a.text(s),r},"drawText"),h=(0,r.K)((t,e,s,i)=>{let r=t.append("image");r.attr("x",e),r.attr("y",s);let n=(0,a.J)(i);r.attr("xlink:href",n)},"drawImage"),d=(0,r.K)((t,e,s,i)=>{let r=t.append("use");r.attr("x",e),r.attr("y",s);let n=(0,a.J)(i);r.attr("xlink:href",`#${n}`)},"drawEmbeddedImage"),u=(0,r.K)(()=>({x:0,y:0,width:100,height:100,fill:"#EDF2AE",stroke:"#666",anchor:"start",rx:0,ry:0}),"getNoteRect"),p=(0,r.K)(()=>({x:0,y:0,width:100,height:100,"text-anchor":"start",style:"#666",textMargin:0,rx:0,ry:0,tspan:!0}),"getTextObj"),y=(0,r.K)(()=>{let t=(0,n.Ltv)(".mermaidTooltip");return t.empty()&&(t=(0,n.Ltv)("body").append("div").attr("class","mermaidTooltip").style("opacity",0).style("position","absolute").style("text-align","center").style("max-width","200px").style("padding","2px").style("font-size","12px").style("background","#ffffde").style("border","1px solid #333").style("border-radius","2px").style("pointer-events","none").style("z-index","100")),t},"createTooltip")},32372:(t,e,s)=>{s.d(e,{diagram:()=>tc});var i=s(37933),r=s(58578),a=s(17028);s(79033);var n=s(1394);s(57807),s(30778),s(24200),s(3570),s(26613),s(56638),s(10862);var o=s(23807),l=s(54547),c=s(13333),h=s(78143),d=s(21201),u=s(21930),p=s(32358),y=function(){var t=(0,d.K)(function(t,e,s,i){for(s=s||{},i=t.length;i--;s[t[i]]=e);return s},"o"),e=[1,2],s=[1,3],i=[1,4],r=[2,4],a=[1,9],n=[1,11],o=[1,16],l=[1,17],c=[1,18],h=[1,19],u=[1,33],p=[1,20],y=[1,21],g=[1,22],f=[1,23],m=[1,24],S=[1,26],k=[1,27],b=[1,28],T=[1,29],_=[1,30],E=[1,31],x=[1,32],D=[1,35],$=[1,36],C=[1,37],v=[1,38],w=[1,34],I=[1,4,5,16,17,19,21,22,24,25,26,27,28,29,33,35,37,38,41,45,48,51,52,53,54,57],L=[1,4,5,14,15,16,17,19,21,22,24,25,26,27,28,29,33,35,37,38,39,40,41,45,48,51,52,53,54,57],A=[4,5,16,17,19,21,22,24,25,26,27,28,29,33,35,37,38,41,45,48,51,52,53,54,57],R={trace:(0,d.K)(function(){},"trace"),yy:{},symbols_:{error:2,start:3,SPACE:4,NL:5,SD:6,document:7,line:8,statement:9,classDefStatement:10,styleStatement:11,cssClassStatement:12,idStatement:13,DESCR:14,"--\x3e":15,HIDE_EMPTY:16,scale:17,WIDTH:18,COMPOSIT_STATE:19,STRUCT_START:20,STRUCT_STOP:21,STATE_DESCR:22,AS:23,ID:24,FORK:25,JOIN:26,CHOICE:27,CONCURRENT:28,note:29,notePosition:30,NOTE_TEXT:31,direction:32,acc_title:33,acc_title_value:34,acc_descr:35,acc_descr_value:36,acc_descr_multiline_value:37,CLICK:38,STRING:39,HREF:40,classDef:41,CLASSDEF_ID:42,CLASSDEF_STYLEOPTS:43,DEFAULT:44,style:45,STYLE_IDS:46,STYLEDEF_STYLEOPTS:47,class:48,CLASSENTITY_IDS:49,STYLECLASS:50,direction_tb:51,direction_bt:52,direction_rl:53,direction_lr:54,eol:55,";":56,EDGE_STATE:57,STYLE_SEPARATOR:58,left_of:59,right_of:60,$accept:0,$end:1},terminals_:{2:"error",4:"SPACE",5:"NL",6:"SD",14:"DESCR",15:"--\x3e",16:"HIDE_EMPTY",17:"scale",18:"WIDTH",19:"COMPOSIT_STATE",20:"STRUCT_START",21:"STRUCT_STOP",22:"STATE_DESCR",23:"AS",24:"ID",25:"FORK",26:"JOIN",27:"CHOICE",28:"CONCURRENT",29:"note",31:"NOTE_TEXT",33:"acc_title",34:"acc_title_value",35:"acc_descr",36:"acc_descr_value",37:"acc_descr_multiline_value",38:"CLICK",39:"STRING",40:"HREF",41:"classDef",42:"CLASSDEF_ID",43:"CLASSDEF_STYLEOPTS",44:"DEFAULT",45:"style",46:"STYLE_IDS",47:"STYLEDEF_STYLEOPTS",48:"class",49:"CLASSENTITY_IDS",50:"STYLECLASS",51:"direction_tb",52:"direction_bt",53:"direction_rl",54:"direction_lr",56:";",57:"EDGE_STATE",58:"STYLE_SEPARATOR",59:"left_of",60:"right_of"},productions_:[0,[3,2],[3,2],[3,2],[7,0],[7,2],[8,2],[8,1],[8,1],[9,1],[9,1],[9,1],[9,1],[9,2],[9,3],[9,4],[9,1],[9,2],[9,1],[9,4],[9,3],[9,6],[9,1],[9,1],[9,1],[9,1],[9,4],[9,4],[9,1],[9,2],[9,2],[9,1],[9,5],[9,5],[10,3],[10,3],[11,3],[12,3],[32,1],[32,1],[32,1],[32,1],[55,1],[55,1],[13,1],[13,1],[13,3],[13,3],[30,1],[30,1]],performAction:(0,d.K)(function(t,e,s,i,r,a,n){var o=a.length-1;switch(r){case 3:return i.setRootDoc(a[o]),a[o];case 4:this.$=[];break;case 5:"nl"!=a[o]&&(a[o-1].push(a[o]),this.$=a[o-1]);break;case 6:case 7:case 12:this.$=a[o];break;case 8:this.$="nl";break;case 13:let l=a[o-1];l.description=i.trimColon(a[o]),this.$=l;break;case 14:this.$={stmt:"relation",state1:a[o-2],state2:a[o]};break;case 15:let c=i.trimColon(a[o]);this.$={stmt:"relation",state1:a[o-3],state2:a[o-1],description:c};break;case 19:this.$={stmt:"state",id:a[o-3],type:"default",description:"",doc:a[o-1]};break;case 20:var h=a[o],d=a[o-2].trim();if(a[o].match(":")){var u=a[o].split(":");h=u[0],d=[d,u[1]]}this.$={stmt:"state",id:h,type:"default",description:d};break;case 21:this.$={stmt:"state",id:a[o-3],type:"default",description:a[o-5],doc:a[o-1]};break;case 22:this.$={stmt:"state",id:a[o],type:"fork"};break;case 23:this.$={stmt:"state",id:a[o],type:"join"};break;case 24:this.$={stmt:"state",id:a[o],type:"choice"};break;case 25:this.$={stmt:"state",id:i.getDividerId(),type:"divider"};break;case 26:this.$={stmt:"state",id:a[o-1].trim(),note:{position:a[o-2].trim(),text:a[o].trim()}};break;case 29:this.$=a[o].trim(),i.setAccTitle(this.$);break;case 30:case 31:this.$=a[o].trim(),i.setAccDescription(this.$);break;case 32:this.$={stmt:"click",id:a[o-3],url:a[o-2],tooltip:a[o-1]};break;case 33:this.$={stmt:"click",id:a[o-3],url:a[o-1],tooltip:""};break;case 34:case 35:this.$={stmt:"classDef",id:a[o-1].trim(),classes:a[o].trim()};break;case 36:this.$={stmt:"style",id:a[o-1].trim(),styleClass:a[o].trim()};break;case 37:this.$={stmt:"applyClass",id:a[o-1].trim(),styleClass:a[o].trim()};break;case 38:i.setDirection("TB"),this.$={stmt:"dir",value:"TB"};break;case 39:i.setDirection("BT"),this.$={stmt:"dir",value:"BT"};break;case 40:i.setDirection("RL"),this.$={stmt:"dir",value:"RL"};break;case 41:i.setDirection("LR"),this.$={stmt:"dir",value:"LR"};break;case 44:case 45:this.$={stmt:"state",id:a[o].trim(),type:"default",description:""};break;case 46:case 47:this.$={stmt:"state",id:a[o-2].trim(),classes:[a[o].trim()],type:"default",description:""}}},"anonymous"),table:[{3:1,4:e,5:s,6:i},{1:[3]},{3:5,4:e,5:s,6:i},{3:6,4:e,5:s,6:i},t([1,4,5,16,17,19,22,24,25,26,27,28,29,33,35,37,38,41,45,48,51,52,53,54,57],r,{7:7}),{1:[2,1]},{1:[2,2]},{1:[2,3],4:a,5:n,8:8,9:10,10:12,11:13,12:14,13:15,16:o,17:l,19:c,22:h,24:u,25:p,26:y,27:g,28:f,29:m,32:25,33:S,35:k,37:b,38:T,41:_,45:E,48:x,51:D,52:$,53:C,54:v,57:w},t(I,[2,5]),{9:39,10:12,11:13,12:14,13:15,16:o,17:l,19:c,22:h,24:u,25:p,26:y,27:g,28:f,29:m,32:25,33:S,35:k,37:b,38:T,41:_,45:E,48:x,51:D,52:$,53:C,54:v,57:w},t(I,[2,7]),t(I,[2,8]),t(I,[2,9]),t(I,[2,10]),t(I,[2,11]),t(I,[2,12],{14:[1,40],15:[1,41]}),t(I,[2,16]),{18:[1,42]},t(I,[2,18],{20:[1,43]}),{23:[1,44]},t(I,[2,22]),t(I,[2,23]),t(I,[2,24]),t(I,[2,25]),{30:45,31:[1,46],59:[1,47],60:[1,48]},t(I,[2,28]),{34:[1,49]},{36:[1,50]},t(I,[2,31]),{13:51,24:u,57:w},{42:[1,52],44:[1,53]},{46:[1,54]},{49:[1,55]},t(L,[2,44],{58:[1,56]}),t(L,[2,45],{58:[1,57]}),t(I,[2,38]),t(I,[2,39]),t(I,[2,40]),t(I,[2,41]),t(I,[2,6]),t(I,[2,13]),{13:58,24:u,57:w},t(I,[2,17]),t(A,r,{7:59}),{24:[1,60]},{24:[1,61]},{23:[1,62]},{24:[2,48]},{24:[2,49]},t(I,[2,29]),t(I,[2,30]),{39:[1,63],40:[1,64]},{43:[1,65]},{43:[1,66]},{47:[1,67]},{50:[1,68]},{24:[1,69]},{24:[1,70]},t(I,[2,14],{14:[1,71]}),{4:a,5:n,8:8,9:10,10:12,11:13,12:14,13:15,16:o,17:l,19:c,21:[1,72],22:h,24:u,25:p,26:y,27:g,28:f,29:m,32:25,33:S,35:k,37:b,38:T,41:_,45:E,48:x,51:D,52:$,53:C,54:v,57:w},t(I,[2,20],{20:[1,73]}),{31:[1,74]},{24:[1,75]},{39:[1,76]},{39:[1,77]},t(I,[2,34]),t(I,[2,35]),t(I,[2,36]),t(I,[2,37]),t(L,[2,46]),t(L,[2,47]),t(I,[2,15]),t(I,[2,19]),t(A,r,{7:78}),t(I,[2,26]),t(I,[2,27]),{5:[1,79]},{5:[1,80]},{4:a,5:n,8:8,9:10,10:12,11:13,12:14,13:15,16:o,17:l,19:c,21:[1,81],22:h,24:u,25:p,26:y,27:g,28:f,29:m,32:25,33:S,35:k,37:b,38:T,41:_,45:E,48:x,51:D,52:$,53:C,54:v,57:w},t(I,[2,32]),t(I,[2,33]),t(I,[2,21])],defaultActions:{5:[2,1],6:[2,2],47:[2,48],48:[2,49]},parseError:(0,d.K)(function(t,e){if(e.recoverable)this.trace(t);else{var s=Error(t);throw s.hash=e,s}},"parseError"),parse:(0,d.K)(function(t){var e=this,s=[0],i=[],r=[null],a=[],n=this.table,o="",l=0,c=0,h=0,u=a.slice.call(arguments,1),p=Object.create(this.lexer),y={};for(var g in this.yy)Object.prototype.hasOwnProperty.call(this.yy,g)&&(y[g]=this.yy[g]);p.setInput(t,y),y.lexer=p,y.parser=this,void 0===p.yylloc&&(p.yylloc={});var f=p.yylloc;a.push(f);var m=p.options&&p.options.ranges;function S(){var t;return"number"!=typeof(t=i.pop()||p.lex()||1)&&(t instanceof Array&&(t=(i=t).pop()),t=e.symbols_[t]||t),t}"function"==typeof y.parseError?this.parseError=y.parseError:this.parseError=Object.getPrototypeOf(this).parseError,(0,d.K)(function(t){s.length=s.length-2*t,r.length=r.length-t,a.length=a.length-t},"popStack"),(0,d.K)(S,"lex");for(var k,b,T,_,E,x,D,$,C,v={};;){if(T=s[s.length-1],this.defaultActions[T]?_=this.defaultActions[T]:(null==k&&(k=S()),_=n[T]&&n[T][k]),void 0===_||!_.length||!_[0]){var w="";for(x in C=[],n[T])this.terminals_[x]&&x>2&&C.push("'"+this.terminals_[x]+"'");w=p.showPosition?"Parse error on line "+(l+1)+":\n"+p.showPosition()+"\nExpecting "+C.join(", ")+", got '"+(this.terminals_[k]||k)+"'":"Parse error on line "+(l+1)+": Unexpected "+(1==k?"end of input":"'"+(this.terminals_[k]||k)+"'"),this.parseError(w,{text:p.match,token:this.terminals_[k]||k,line:p.yylineno,loc:f,expected:C})}if(_[0]instanceof Array&&_.length>1)throw Error("Parse Error: multiple actions possible at state: "+T+", token: "+k);switch(_[0]){case 1:s.push(k),r.push(p.yytext),a.push(p.yylloc),s.push(_[1]),k=null,b?(k=b,b=null):(c=p.yyleng,o=p.yytext,l=p.yylineno,f=p.yylloc,h>0&&h--);break;case 2:if(D=this.productions_[_[1]][1],v.$=r[r.length-D],v._$={first_line:a[a.length-(D||1)].first_line,last_line:a[a.length-1].last_line,first_column:a[a.length-(D||1)].first_column,last_column:a[a.length-1].last_column},m&&(v._$.range=[a[a.length-(D||1)].range[0],a[a.length-1].range[1]]),void 0!==(E=this.performAction.apply(v,[o,c,l,y,_[1],r,a].concat(u))))return E;D&&(s=s.slice(0,-1*D*2),r=r.slice(0,-1*D),a=a.slice(0,-1*D)),s.push(this.productions_[_[1]][0]),r.push(v.$),a.push(v._$),$=n[s[s.length-2]][s[s.length-1]],s.push($);break;case 3:return!0}}return!0},"parse")};function N(){this.yy={}}return R.lexer={EOF:1,parseError:(0,d.K)(function(t,e){if(this.yy.parser)this.yy.parser.parseError(t,e);else throw Error(t)},"parseError"),setInput:(0,d.K)(function(t,e){return this.yy=e||this.yy||{},this._input=t,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match="",this.conditionStack=["INITIAL"],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this},"setInput"),input:(0,d.K)(function(){var t=this._input[0];return this.yytext+=t,this.yyleng++,this.offset++,this.match+=t,this.matched+=t,t.match(/(?:\r\n?|\n).*/g)?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),t},"input"),unput:(0,d.K)(function(t){var e=t.length,s=t.split(/(?:\r\n?|\n)/g);this._input=t+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-e),this.offset-=e;var i=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),s.length-1&&(this.yylineno-=s.length-1);var r=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:s?(s.length===i.length?this.yylloc.first_column:0)+i[i.length-s.length].length-s[0].length:this.yylloc.first_column-e},this.options.ranges&&(this.yylloc.range=[r[0],r[0]+this.yyleng-e]),this.yyleng=this.yytext.length,this},"unput"),more:(0,d.K)(function(){return this._more=!0,this},"more"),reject:(0,d.K)(function(){return this.options.backtrack_lexer?(this._backtrack=!0,this):this.parseError("Lexical error on line "+(this.yylineno+1)+". You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true).\n"+this.showPosition(),{text:"",token:null,line:this.yylineno})},"reject"),less:(0,d.K)(function(t){this.unput(this.match.slice(t))},"less"),pastInput:(0,d.K)(function(){var t=this.matched.substr(0,this.matched.length-this.match.length);return(t.length>20?"...":"")+t.substr(-20).replace(/\n/g,"")},"pastInput"),upcomingInput:(0,d.K)(function(){var t=this.match;return t.length<20&&(t+=this._input.substr(0,20-t.length)),(t.substr(0,20)+(t.length>20?"...":"")).replace(/\n/g,"")},"upcomingInput"),showPosition:(0,d.K)(function(){var t=this.pastInput(),e=Array(t.length+1).join("-");return t+this.upcomingInput()+"\n"+e+"^"},"showPosition"),test_match:(0,d.K)(function(t,e){var s,i,r;if(this.options.backtrack_lexer&&(r={yylineno:this.yylineno,yylloc:{first_line:this.yylloc.first_line,last_line:this.last_line,first_column:this.yylloc.first_column,last_column:this.yylloc.last_column},yytext:this.yytext,match:this.match,matches:this.matches,matched:this.matched,yyleng:this.yyleng,offset:this.offset,_more:this._more,_input:this._input,yy:this.yy,conditionStack:this.conditionStack.slice(0),done:this.done},this.options.ranges&&(r.yylloc.range=this.yylloc.range.slice(0))),(i=t[0].match(/(?:\r\n?|\n).*/g))&&(this.yylineno+=i.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:i?i[i.length-1].length-i[i.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+t[0].length},this.yytext+=t[0],this.match+=t[0],this.matches=t,this.yyleng=this.yytext.length,this.options.ranges&&(this.yylloc.range=[this.offset,this.offset+=this.yyleng]),this._more=!1,this._backtrack=!1,this._input=this._input.slice(t[0].length),this.matched+=t[0],s=this.performAction.call(this,this.yy,this,e,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),s)return s;if(this._backtrack)for(var a in r)this[a]=r[a];return!1},"test_match"),next:(0,d.K)(function(){if(this.done)return this.EOF;this._input||(this.done=!0),this._more||(this.yytext="",this.match="");for(var t,e,s,i,r=this._currentRules(),a=0;a<r.length;a++)if((s=this._input.match(this.rules[r[a]]))&&(!e||s[0].length>e[0].length)){if(e=s,i=a,this.options.backtrack_lexer){if(!1!==(t=this.test_match(s,r[a])))return t;if(!this._backtrack)return!1;e=!1;continue}if(!this.options.flex)break}return e?!1!==(t=this.test_match(e,r[i]))&&t:""===this._input?this.EOF:this.parseError("Lexical error on line "+(this.yylineno+1)+". Unrecognized text.\n"+this.showPosition(),{text:"",token:null,line:this.yylineno})},"next"),lex:(0,d.K)(function(){var t=this.next();return t||this.lex()},"lex"),begin:(0,d.K)(function(t){this.conditionStack.push(t)},"begin"),popState:(0,d.K)(function(){return this.conditionStack.length-1>0?this.conditionStack.pop():this.conditionStack[0]},"popState"),_currentRules:(0,d.K)(function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules},"_currentRules"),topState:(0,d.K)(function(t){return(t=this.conditionStack.length-1-Math.abs(t||0))>=0?this.conditionStack[t]:"INITIAL"},"topState"),pushState:(0,d.K)(function(t){this.begin(t)},"pushState"),stateStackSize:(0,d.K)(function(){return this.conditionStack.length},"stateStackSize"),options:{"case-insensitive":!0},performAction:(0,d.K)(function(t,e,s,i){function r(){let s=e.yytext.indexOf("%%");if(0===s)return!1;if(s>0){let i=e.yytext.slice(0,s),r=e.yytext.slice(s);r&&t.lexer.unput(r),e.yytext=i}return!0}switch((0,d.K)(r,"processId"),s){case 0:return 38;case 1:return 40;case 2:return 39;case 3:return 44;case 4:case 43:return 51;case 5:case 44:return 52;case 6:case 45:return 53;case 7:case 46:return 54;case 8:case 78:return 5;case 9:case 10:case 11:case 12:case 57:case 63:break;case 13:case 33:return this.pushState("SCALE"),17;case 14:case 34:return 18;case 15:case 21:case 35:case 50:case 54:this.popState();break;case 16:return this.begin("acc_title"),33;case 17:return this.popState(),"acc_title_value";case 18:return this.begin("acc_descr"),35;case 19:return this.popState(),"acc_descr_value";case 20:this.begin("acc_descr_multiline");break;case 22:return"acc_descr_multiline_value";case 23:return this.pushState("CLASSDEF"),41;case 24:return this.popState(),this.pushState("CLASSDEFID"),"DEFAULT_CLASSDEF_ID";case 25:return this.popState(),this.pushState("CLASSDEFID"),42;case 26:return this.popState(),43;case 27:return this.pushState("CLASS"),48;case 28:return this.popState(),this.pushState("CLASS_STYLE"),49;case 29:return this.popState(),50;case 30:return this.pushState("STYLE"),45;case 31:return this.popState(),this.pushState("STYLEDEF_STYLES"),46;case 32:return this.popState(),47;case 36:this.pushState("STATE");break;case 37:case 40:return this.popState(),e.yytext=e.yytext.slice(0,-8).trim(),25;case 38:case 41:return this.popState(),e.yytext=e.yytext.slice(0,-8).trim(),26;case 39:case 42:return this.popState(),e.yytext=e.yytext.slice(0,-10).trim(),27;case 47:this.pushState("STATE_STRING");break;case 48:return this.pushState("STATE_ID"),"AS";case 49:case 65:if(!r())return;return this.popState(),"ID";case 51:return"STATE_DESCR";case 52:throw Error('Error: State name must be a single word. Found: "'+e.yytext.trim()+'"');case 53:return 19;case 55:return this.popState(),this.pushState("struct"),20;case 56:return this.popState(),21;case 58:return this.begin("NOTE"),29;case 59:return this.popState(),this.pushState("NOTE_ID"),59;case 60:return this.popState(),this.pushState("NOTE_ID"),60;case 61:this.popState(),this.pushState("FLOATING_NOTE");break;case 62:return this.popState(),this.pushState("FLOATING_NOTE_ID"),"AS";case 64:return"NOTE_TEXT";case 66:if(!r())return;return this.popState(),this.pushState("NOTE_TEXT"),24;case 67:return this.popState(),e.yytext=e.yytext.substr(2).trim(),31;case 68:return this.popState(),e.yytext=e.yytext.slice(0,-8).trim(),31;case 69:case 70:return 6;case 71:return 16;case 72:return 57;case 73:if(!r())return;return 24;case 74:return e.yytext=e.yytext.trim(),14;case 75:return 15;case 76:return 28;case 77:return 58;case 79:return"INVALID"}},"anonymous"),rules:[/^(?:click\b)/i,/^(?:href\b)/i,/^(?:"[^"]*")/i,/^(?:default\b)/i,/^(?:.*direction\s+TB[^\n]*)/i,/^(?:.*direction\s+BT[^\n]*)/i,/^(?:.*direction\s+RL[^\n]*)/i,/^(?:.*direction\s+LR[^\n]*)/i,/^(?:[\n]+)/i,/^(?:[\s]+)/i,/^(?:((?!\n)\s)+)/i,/^(?:#[^\n]*)/i,/^(?:%%(?!\{)[^\n]*)/i,/^(?:scale\s+)/i,/^(?:\d+)/i,/^(?:\s+width\b)/i,/^(?:accTitle\s*:\s*)/i,/^(?:(?!\n||)*[^\n]*)/i,/^(?:accDescr\s*:\s*)/i,/^(?:(?!\n||)*[^\n]*)/i,/^(?:accDescr\s*\{\s*)/i,/^(?:[\}])/i,/^(?:[^\}]*)/i,/^(?:classDef\s+)/i,/^(?:DEFAULT\s+)/i,/^(?:\w+\s+)/i,/^(?:[^\n]*)/i,/^(?:class\s+)/i,/^(?:(\w+)+((,\s*\w+)*))/i,/^(?:[^\n]*)/i,/^(?:style\s+)/i,/^(?:[\w,]+\s+)/i,/^(?:[^\n]*)/i,/^(?:scale\s+)/i,/^(?:\d+)/i,/^(?:\s+width\b)/i,/^(?:state\s+)/i,/^(?:.*<<fork>>)/i,/^(?:.*<<join>>)/i,/^(?:.*<<choice>>)/i,/^(?:.*\[\[fork\]\])/i,/^(?:.*\[\[join\]\])/i,/^(?:.*\[\[choice\]\])/i,/^(?:.*direction\s+TB[^\n]*)/i,/^(?:.*direction\s+BT[^\n]*)/i,/^(?:.*direction\s+RL[^\n]*)/i,/^(?:.*direction\s+LR[^\n]*)/i,/^(?:["])/i,/^(?:\s*as\s+)/i,/^(?:[^\n\{]*)/i,/^(?:["])/i,/^(?:[^"]*)/i,/^(?:\w+\s+\w+.*?\{)/i,/^(?:[^\n\s\{]+)/i,/^(?:\n)/i,/^(?:\{)/i,/^(?:\})/i,/^(?:[\n])/i,/^(?:note\s+)/i,/^(?:left of\b)/i,/^(?:right of\b)/i,/^(?:")/i,/^(?:\s*as\s*)/i,/^(?:["])/i,/^(?:[^"]*)/i,/^(?:[^\n]*)/i,/^(?:\s*[^:\n\s\-]+)/i,/^(?:\s*:[^:\n;]+)/i,/^(?:[\s\S]*?\n\s*end note\b)/i,/^(?:stateDiagram\s+)/i,/^(?:stateDiagram-v2\s+)/i,/^(?:hide empty description\b)/i,/^(?:\[\*\])/i,/^(?:[^:\n\s\-\{]+)/i,/^(?:\s*:(?:[^:\n;]|:[^:\n;])+)/i,/^(?:-->)/i,/^(?:--)/i,/^(?::::)/i,/^(?:$)/i,/^(?:.)/i],conditions:{LINE:{rules:[10,11,12],inclusive:!1},struct:{rules:[10,11,12,23,27,30,36,43,44,45,46,56,57,58,72,73,74,75,76,77],inclusive:!1},FLOATING_NOTE_ID:{rules:[65],inclusive:!1},FLOATING_NOTE:{rules:[62,63,64],inclusive:!1},NOTE_TEXT:{rules:[67,68],inclusive:!1},NOTE_ID:{rules:[66],inclusive:!1},NOTE:{rules:[59,60,61],inclusive:!1},STYLEDEF_STYLEOPTS:{rules:[],inclusive:!1},STYLEDEF_STYLES:{rules:[32],inclusive:!1},STYLE_IDS:{rules:[],inclusive:!1},STYLE:{rules:[31],inclusive:!1},CLASS_STYLE:{rules:[29],inclusive:!1},CLASS:{rules:[28],inclusive:!1},CLASSDEFID:{rules:[26],inclusive:!1},CLASSDEF:{rules:[24,25],inclusive:!1},acc_descr_multiline:{rules:[21,22],inclusive:!1},acc_descr:{rules:[19],inclusive:!1},acc_title:{rules:[17],inclusive:!1},SCALE:{rules:[14,15,34,35],inclusive:!1},ALIAS:{rules:[],inclusive:!1},STATE_ID:{rules:[49],inclusive:!1},STATE_STRING:{rules:[50,51],inclusive:!1},FORK_STATE:{rules:[],inclusive:!1},STATE:{rules:[10,11,12,37,38,39,40,41,42,47,48,52,53,54,55],inclusive:!1},ID:{rules:[10,11,12],inclusive:!1},INITIAL:{rules:[0,1,2,3,4,5,6,7,8,9,11,12,13,16,18,20,23,27,30,33,36,55,58,69,70,71,72,73,74,75,77,78,79],inclusive:!0}}},(0,d.K)(N,"Parser"),N.prototype=R,R.Parser=N,new N}();y.parser=y;var g="TB",f="state",m="root",S="relation",k="default",b="divider",T="fill:none",_="fill: #333",E="markdown",x="normal",D="rect",$="rectWithTitle",C="divider",v="roundedWithTitle",w="statediagram",I=`${w}-state`,L="transition",A=`${L} note-edge`,R=`${w}-note`,N=`${w}-cluster`,O=`${w}-cluster-alt`,K="parent",B="note",Y="----",F=`${Y}${B}`,P=`${Y}${K}`,G=new Map,W=0,j=0,M=new Map,z=(0,d.K)((t,e,s,i)=>{if(t===C&&s?.id!==void 0&&M.has(s.id)){let t=M.get(s.id);return M.set(e,t),t}let r=j++,a=i?void 0:r;return M.set(e,a),a},"colorSlotFor");function U(t="",e=0,s="",i=Y){let r=null!==s&&s.length>0?`${i}${s}`:"";return`state-${t}${r}-${e}`}(0,d.K)(U,"stateDomId");var H=(0,d.K)((t,e,s,i,r,a,n,o)=>{h.R.trace("items",e),e.forEach(e=>{switch(e.stmt){case f:case k:Q(t,e,s,i,r,a,n,o);break;case S:{Q(t,e.state1,s,i,r,a,n,o),Q(t,e.state2,s,i,r,a,n,o);let l="neo"===n,h={id:"edge"+W,start:e.state1.id,end:e.state2.id,arrowhead:"normal",arrowTypeEnd:l?"arrow_barb_neo":"arrow_barb",style:T,labelStyle:"",label:c.Y2.sanitizeText(e.description??"",(0,c.D7)()),arrowheadStyle:_,labelpos:"c",labelType:E,thickness:x,classes:L,look:n};r.push(h),W++}}})},"setupDoc"),X=(0,d.K)((t,e=g)=>{let s=e;if(t.doc)for(let e of t.doc)"dir"===e.stmt&&(s=e.value);return s},"getDir");function V(t,e,s){if(!e.id||"</join></fork>"===e.id||"</choice>"===e.id)return;e.cssClasses&&(Array.isArray(e.cssCompiledStyles)||(e.cssCompiledStyles=[]),e.cssClasses.split(" ").forEach(t=>{let i=s.get(t);i&&(e.cssCompiledStyles=[...e.cssCompiledStyles??[],...i.styles])}));let i=t.find(t=>t.id===e.id);i?Object.assign(i,e):t.push(e)}function J(t){return t?.classes?.join(" ")??""}function q(t){return t?.styles??[]}(0,d.K)(V,"insertOrUpdateNode"),(0,d.K)(J,"getClassesFromDbInfo"),(0,d.K)(q,"getStylesFromDbInfo");var Q=(0,d.K)((t,e,s,i,r,a,n,o)=>{let l=e.id,d=s.get(l),u=J(d),p=q(d),y=(0,c.D7)(),g=""!==u.trim()||p.length>0;if(h.R.info("dataFetcher parsedItem",e,d,p),"root"!==l){let s=D;!0===e.start?s="stateStart":!1===e.start&&(s="stateEnd"),e.type!==k&&(s=e.type),G.get(l)||G.set(l,{id:l,shape:s,description:c.Y2.sanitizeText(l,y),cssClasses:`${u} ${I}`,cssStyles:p});let d=G.get(l);e.description&&(Array.isArray(d.description)?(d.shape=$,d.description.push(e.description)):d.description?.length&&d.description.length>0?(d.shape=$,d.description===l?d.description=[e.description]:d.description=[d.description,e.description]):(d.shape=D,d.description=e.description),d.description=c.Y2.sanitizeTextOrArray(d.description,y)),d.description?.length===1&&d.shape===$&&("group"===d.type?d.shape=v:d.shape=D),!d.type&&e.doc&&(h.R.info("Setting cluster for XCX",l,X(e)),d.type="group",d.isGroup=!0,d.dir=X(e),d.shape=e.type===b?C:v,d.colorIndex=z(d.shape,l,t,g),d.cssClasses=`${d.cssClasses} ${N} ${a?O:""}`);let f={labelStyle:"",shape:d.shape,label:d.description,cssClasses:d.cssClasses,cssCompiledStyles:[],cssStyles:d.cssStyles,id:l,dir:d.dir,domId:U(l,W),type:d.type,isGroup:"group"===d.type,colorIndex:d.colorIndex,padding:8,rx:10,ry:10,look:n,labelType:"markdown"};if(f.shape===C&&(f.label=""),t&&"root"!==t.id&&(h.R.trace("Setting node ",l," to be child of its parent ",t.id),f.parentId=t.id),f.centerLabel=!0,e.note){let t={labelStyle:"",shape:"note",label:e.note.text,labelType:"markdown",cssClasses:R,cssStyles:[],cssCompiledStyles:[],id:l+F+"-"+W,domId:U(l,W,B),type:"node",isGroup:!1,padding:y.flowchart?.padding,look:n,position:e.note.position},s=l+P,a={labelStyle:"",shape:"noteGroup",label:e.note.text,cssClasses:d.cssClasses,cssStyles:[],id:l+P,domId:U(l,W,K),type:"group",isGroup:!0,padding:16,look:n,position:e.note.position};W++,a.id=s,t.parentId=s,V(i,a,o),V(i,t,o),V(i,f,o);let c=l,h=t.id;"left of"===e.note.position&&(c=t.id,h=l),r.push({id:c+"-"+h,start:c,end:h,arrowhead:"none",arrowTypeEnd:"",style:T,labelStyle:"",classes:A,pattern:"dashed",arrowheadStyle:_,labelpos:"c",labelType:E,thickness:x,look:n})}else V(i,f,o)}e.doc&&(h.R.trace("Adding nodes children "),H(e,e.doc,s,i,r,!a,n,o))},"dataFetcher"),Z=(0,d.K)(()=>{G.clear(),W=0,j=0,M.clear()},"reset"),tt=(0,d.K)((t,e=g)=>{if(!t.doc)return e;let s=e;for(let e of t.doc)"dir"===e.stmt&&(s=e.value);return s},"getDir"),te=(0,d.K)(function(t,e){return e.db.getClasses()},"getClasses"),ts=(0,d.K)(async function(t,e,s,n){h.R.info("REF0:"),h.R.info("Drawing state diagram (v2)",e);let{securityLevel:o,state:d,layout:u}=(0,c.D7)();n.db.extract(n.db.getRootDocV2());let p=n.db.getData(),y=(0,i.A)(e,o);p.type=n.type,p.layoutAlgorithm=(0,a.q7)(u),p.nodeSpacing=d?.nodeSpacing||50,p.rankSpacing=d?.rankSpacing||50,"neo"===(0,c.D7)().look?p.markers=["barbNeo"]:p.markers=["barb"],p.diagramId=e,await (0,a.XX)(p,y);try{("function"==typeof n.db.getLinks?n.db.getLinks():new Map).forEach((t,e)=>{let s,i="string"==typeof e?e:"string"==typeof e?.id?e.id:"",r=p.nodes.find(t=>t.id===i);if(!i)return void h.R.warn("⚠️ Invalid or missing stateId from key:",JSON.stringify(e));let a=y.node()?.querySelectorAll("g.node, g.rough-node");if(a?.forEach(t=>{let e=t.textContent?.trim();(t.id===r?.domId||e===i)&&(s=t)}),!s)return void h.R.warn("⚠️ Could not find node matching text:",i);let n=s.parentNode;if(!n)return void h.R.warn("⚠️ Node has no parent, cannot wrap:",i);let o=document.createElementNS("http://www.w3.org/2000/svg","a"),l=t.url.replace(/^"+|"+$/g,"");if(o.setAttributeNS("http://www.w3.org/1999/xlink","xlink:href",l),o.setAttribute("target","_blank"),t.tooltip){let e=t.tooltip.replace(/^"+|"+$/g,"");o.setAttribute("title",e),s.setAttribute("title",e)}n.replaceChild(o,s),o.appendChild(s),h.R.info("\uD83D\uDD17 Wrapped node in <a> tag for:",i,t.url)})}catch(t){h.R.error("❌ Error injecting clickable links:",t)}l._K.insertTitle(y,"statediagramTitleText",d?.titleTopMargin??25,n.db.getDiagramTitle()),(0,r.P)(y,8,w,d?.useMaxWidth??!0)},"draw"),ti={START_NODE:"[*]",START_TYPE:"start",END_NODE:"[*]",END_TYPE:"end",COLOR_KEYWORD:"color",FILL_KEYWORD:"fill",BG_FILL:"bgFill",STYLECLASS_SEP:","},tr=(0,d.K)(()=>new Map,"newClassesList"),ta=(0,d.K)(()=>({relations:[],states:new Map,documents:{}}),"newDoc"),tn=(0,d.K)(t=>JSON.parse(JSON.stringify(t)),"clone"),to=class{constructor(t){this.version=t,this.nodes=[],this.edges=[],this.rootDoc=[],this.classes=tr(),this.documents={root:ta()},this.currentDocument=this.documents.root,this.startEndCount=0,this.dividerCnt=0,this.links=new Map,this.funs=[],this.getAccTitle=c.iN,this.setAccTitle=c.SV,this.getAccDescription=c.m7,this.setAccDescription=c.EI,this.setDiagramTitle=c.ke,this.getDiagramTitle=c.ab,this.clear(),this.setRootDoc=this.setRootDoc.bind(this),this.getDividerId=this.getDividerId.bind(this),this.setDirection=this.setDirection.bind(this),this.trimColon=this.trimColon.bind(this),this.bindFunctions=this.bindFunctions.bind(this)}static{(0,d.K)(this,"StateDB")}static{this.relationType={AGGREGATION:0,EXTENSION:1,COMPOSITION:2,DEPENDENCY:3}}extract(t){for(let e of(this.clear(!0),Array.isArray(t)?t:t.doc))switch(e.stmt){case f:this.addState(e.id.trim(),e.type,e.doc,e.description,e.note);break;case S:this.addRelation(e.state1,e.state2,e.description);break;case"classDef":this.addStyleClass(e.id.trim(),e.classes);break;case"style":this.handleStyleDef(e);break;case"applyClass":this.setCssClass(e.id.trim(),e.styleClass);break;case"click":this.addLink(e.id,e.url,e.tooltip)}let e=this.getStates(),s=(0,c.D7)();for(let t of(Z(),Q(void 0,this.getRootDocV2(),e,this.nodes,this.edges,!0,s.look,this.classes),this.nodes))if(Array.isArray(t.label)){if(t.description=t.label.slice(1),t.isGroup&&t.description.length>0)throw Error(`Group nodes can only have label. Remove the additional description for node [${t.id}]`);t.label=t.label[0]}}handleStyleDef(t){let e=t.id.trim().split(","),s=t.styleClass.split(",");for(let t of e){let e=this.getState(t);if(!e){let s=t.trim();this.addState(s),e=this.getState(s)}e&&(e.styles=s.map(t=>t.replace(/;/g,"")?.trim()))}}setRootDoc(t){h.R.info("Setting root doc",t),this.rootDoc=t,1===this.version?this.extract(t):this.extract(this.getRootDocV2())}docTranslator(t,e,s){if(e.stmt===S){this.docTranslator(t,e.state1,!0),this.docTranslator(t,e.state2,!1);return}if(e.stmt===f&&(e.id===ti.START_NODE?(e.id=t.id+(s?"_start":"_end"),e.start=s):e.id=e.id.trim()),e.stmt!==m&&e.stmt!==f||!e.doc)return;let i=[],r=[];for(let t of e.doc)if(t.type===b){let e=tn(t);e.doc=tn(r),i.push(e),r=[]}else r.push(t);if(i.length>0&&r.length>0){let t={stmt:f,id:(0,l.$C)(),type:"divider",doc:tn(r)};i.push(tn(t)),e.doc=i}e.doc.forEach(t=>this.docTranslator(e,t,!0))}getRootDocV2(){return this.docTranslator({id:m,stmt:m},{id:m,stmt:m,doc:this.rootDoc},!0),{id:m,doc:this.rootDoc}}addState(t,e=k,s,i,r,a,n,o){let l=t?.trim();if(this.currentDocument.states.has(l)){let t=this.currentDocument.states.get(l);if(!t)throw Error(`State not found: ${l}`);t.doc||(t.doc=s),t.type||(t.type=e)}else h.R.info("Adding state ",l,i),this.currentDocument.states.set(l,{stmt:f,id:l,descriptions:[],type:e,doc:s,note:r,classes:[],styles:[],textStyles:[]});if(i&&(h.R.info("Setting state description",l,i),(Array.isArray(i)?i:[i]).forEach(t=>this.addDescription(l,t.trim()))),r){let t=this.currentDocument.states.get(l);if(!t)throw Error(`State not found: ${l}`);t.note=r,t.note.text=c.Y2.sanitizeText(t.note.text,(0,c.D7)())}a&&(h.R.info("Setting state classes",l,a),(Array.isArray(a)?a:[a]).forEach(t=>this.setCssClass(l,t.trim()))),n&&(h.R.info("Setting state styles",l,n),(Array.isArray(n)?n:[n]).forEach(t=>this.setStyle(l,t.trim()))),o&&(h.R.info("Setting state styles",l,n),(Array.isArray(o)?o:[o]).forEach(t=>this.setTextStyle(l,t.trim())))}clear(t){this.nodes=[],this.edges=[],this.funs=[this.setupToolTips.bind(this)],this.documents={root:ta()},this.currentDocument=this.documents.root,this.startEndCount=0,this.classes=tr(),t||(this.links=new Map,(0,c.IU)())}getState(t){return this.currentDocument.states.get(t)}getStates(){return this.currentDocument.states}logDocuments(){h.R.info("Documents = ",this.documents)}getRelations(){return this.currentDocument.relations}addLink(t,e,s){this.links.set(t,{url:e,tooltip:s}),h.R.warn("Adding link",t,e,s)}getLinks(){return this.links}startIdIfNeeded(t=""){return t===ti.START_NODE?(this.startEndCount++,`${ti.START_TYPE}${this.startEndCount}`):t}startTypeIfNeeded(t="",e=k){return t===ti.START_NODE?ti.START_TYPE:e}endIdIfNeeded(t=""){return t===ti.END_NODE?(this.startEndCount++,`${ti.END_TYPE}${this.startEndCount}`):t}endTypeIfNeeded(t="",e=k){return t===ti.END_NODE?ti.END_TYPE:e}addRelationObjs(t,e,s=""){let i=this.startIdIfNeeded(t.id.trim()),r=this.startTypeIfNeeded(t.id.trim(),t.type),a=this.startIdIfNeeded(e.id.trim()),n=this.startTypeIfNeeded(e.id.trim(),e.type);this.addState(i,r,t.doc,t.description,t.note,t.classes,t.styles,t.textStyles),this.addState(a,n,e.doc,e.description,e.note,e.classes,e.styles,e.textStyles),this.currentDocument.relations.push({id1:i,id2:a,relationTitle:c.Y2.sanitizeText(s,(0,c.D7)())})}addRelation(t,e,s){if("object"==typeof t&&"object"==typeof e)this.addRelationObjs(t,e,s);else if("string"==typeof t&&"string"==typeof e){let i=this.startIdIfNeeded(t.trim()),r=this.startTypeIfNeeded(t),a=this.endIdIfNeeded(e.trim()),n=this.endTypeIfNeeded(e);this.addState(i,r),this.addState(a,n),this.currentDocument.relations.push({id1:i,id2:a,relationTitle:s?c.Y2.sanitizeText(s,(0,c.D7)()):void 0})}}addDescription(t,e){let s=this.currentDocument.states.get(t),i=e.startsWith(":")?e.replace(":","").trim():e;s?.descriptions?.push(c.Y2.sanitizeText(i,(0,c.D7)()))}cleanupLabel(t){return t.startsWith(":")?t.slice(2).trim():t.trim()}getDividerId(){return this.dividerCnt++,`divider-id-${this.dividerCnt}`}addStyleClass(t,e=""){this.classes.has(t)||this.classes.set(t,{id:t,styles:[],textStyles:[]});let s=this.classes.get(t);e&&s&&e.split(ti.STYLECLASS_SEP).forEach(t=>{let e=t.replace(/([^;]*);/,"$1").trim();if(RegExp(ti.COLOR_KEYWORD).exec(t)){let t=e.replace(ti.FILL_KEYWORD,ti.BG_FILL).replace(ti.COLOR_KEYWORD,ti.FILL_KEYWORD);s.textStyles.push(t)}s.styles.push(e)})}getClasses(){return this.classes}setupToolTips(t){let e=(0,n.Ck)();(0,u.Ltv)(t).select("svg").selectAll("g.node, g.rough-node").on("mouseover",t=>{let s=(0,u.Ltv)(t.currentTarget),i=s.attr("title");if(null===i)return;let r=t.currentTarget?.getBoundingClientRect();e.transition().duration(200).style("opacity",".9"),e.style("left",window.scrollX+r.left+(r.right-r.left)/2+"px").style("top",window.scrollY+r.bottom+"px"),e.html(p.A.sanitize(i)),s.classed("hover",!0)}).on("mouseout",t=>{e.transition().duration(500).style("opacity",0),(0,u.Ltv)(t.currentTarget).classed("hover",!1)})}setCssClass(t,e){t.split(",").forEach(t=>{let s=this.getState(t);if(!s){let e=t.trim();this.addState(e),s=this.getState(e)}s?.classes?.push(e)})}setStyle(t,e){this.getState(t)?.styles?.push(e)}setTextStyle(t,e){this.getState(t)?.textStyles?.push(e)}bindFunctions(t){this.funs.forEach(e=>{e(t)})}getDirectionStatement(){return this.rootDoc.find(t=>"dir"===t.stmt)}getDirection(){return this.getDirectionStatement()?.value??"TB"}setDirection(t){let e=this.getDirectionStatement();e?e.value=t:this.rootDoc.unshift({stmt:"dir",value:t})}trimColon(t){return t.startsWith(":")?t.slice(1).trim():t.trim()}getData(){let t=(0,c.D7)();for(let e of this.nodes)e.wrappingWidth??=t.state?.wrappingWidth,e.isGroup||(e.minWidth??=t.state?.minNodeWidth);return{nodes:this.nodes,edges:this.edges,other:{},config:t,direction:tt(this.getRootDocV2())}}getConfig(){return(0,c.D7)().state}},tl=(0,d.K)(t=>{let{theme:e,bkgColorArray:s,borderColorArray:i}=t;if(!(0,o.P1)(e,i))return"";let r=(0,o.rq)(t.look),a=(0,o.Ic)(s),n="";for(let t=0;t<(0,o.Hu)(i);t++){let e=i[t],o=a?`fill: ${s[t%s.length]};`:"",l=`[data-look="${r}"][data-color-id="color-${t}"]`;n+=`
|
|
2
|
+
|
|
3
|
+
/* The title strip: \`rect.outer\` spans the whole composite and \`rect.inner\` covers
|
|
4
|
+
the body, so what stays visible of \`outer\` is the band behind the label. */
|
|
5
|
+
${l}.statediagram-cluster rect.outer {
|
|
6
|
+
stroke: ${e};
|
|
7
|
+
${o}
|
|
8
|
+
}
|
|
9
|
+
|
|
10
|
+
${l}.statediagram-cluster rect.inner {
|
|
11
|
+
stroke: ${e};
|
|
12
|
+
}
|
|
13
|
+
|
|
14
|
+
/* Concurrency regions. Siblings of one composite share a slot, so a divided composite
|
|
15
|
+
reads as one thing split into parts rather than as several composites. */
|
|
16
|
+
${l}.statediagram-cluster rect.divider {
|
|
17
|
+
stroke: ${e};
|
|
18
|
+
${o}
|
|
19
|
+
}
|
|
20
|
+
|
|
21
|
+
/* handDrawn draws the same container as roughjs shapes rather than plain rects, so it
|
|
22
|
+
needs its own rules. \`roundedWithTitle\` and \`divider\` name those groups \`outer\`,
|
|
23
|
+
\`inner\` and \`divider\` to match the classic branch, which is what lets these
|
|
24
|
+
discriminate -- a bare \`.statediagram-cluster path\` rule reached the body as well and
|
|
25
|
+
tinted the whole composite, losing \`compositeBackground\` and diverging from what
|
|
26
|
+
classic and neo do.
|
|
27
|
+
|
|
28
|
+
roughjs emits two paths per shape and marks them: the filled shape carries
|
|
29
|
+
\`stroke="none"\` and the sketched outline carries \`fill="none"\`. Splitting on that is
|
|
30
|
+
what keeps \`fill\` off the outline -- a rough outline is open squiggles, not a closed
|
|
31
|
+
region, so filling it produces smears -- and keeps \`stroke\` off the fill shape, which
|
|
32
|
+
would otherwise gain an edge it was drawn without. */
|
|
33
|
+
${l}.statediagram-cluster .outer path[stroke='none'] {
|
|
34
|
+
${o}
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
${l}.statediagram-cluster .outer path[fill='none'] {
|
|
38
|
+
stroke: ${e};
|
|
39
|
+
}
|
|
40
|
+
|
|
41
|
+
/* No \`.inner\` rule on purpose. The body shape is left entirely alone under handDrawn,
|
|
42
|
+
where a rect's \`inner\` counterpart cannot be recoloured safely: roughjs draws a
|
|
43
|
+
hachure fill as *stroked* lines, so its fill paths carry \`fill="none"\` exactly like
|
|
44
|
+
the outline and no selector separates them. An \`.inner\` stroke rule therefore
|
|
45
|
+
repainted the hatching of every alt composite in the palette colour instead of
|
|
46
|
+
leaving it on \`altBackground\`. The container still reads as palette-coloured: the
|
|
47
|
+
\`outer\` shape spans the whole composite, so its outline already frames the body. */
|
|
48
|
+
|
|
49
|
+
/* Regions split the same way, which is why \`divider\` fills solid rather than taking
|
|
50
|
+
roughjs's default hachure -- see the note on that call. Hatched, both of its paths
|
|
51
|
+
carried \`fill="none"\` and these two rules degenerated: the tint matched nothing and
|
|
52
|
+
the border rule repainted the hatching. */
|
|
53
|
+
${l}.statediagram-cluster .divider path[stroke='none'] {
|
|
54
|
+
${o}
|
|
55
|
+
}
|
|
56
|
+
|
|
57
|
+
${l}.statediagram-cluster .divider path[fill='none'] {
|
|
58
|
+
stroke: ${e};
|
|
59
|
+
}
|
|
60
|
+
`}return n},"genColor"),tc={parser:y,get db(){return new to(2)},renderer:{getClasses:te,draw:ts,getDir:tt},styles:(0,d.K)(t=>`
|
|
61
|
+
${tl(t)}
|
|
62
|
+
defs [id$="-barbEnd"] {
|
|
63
|
+
fill: ${t.transitionColor};
|
|
64
|
+
stroke: ${t.transitionColor};
|
|
65
|
+
}
|
|
66
|
+
g.stateGroup text {
|
|
67
|
+
fill: ${t.nodeBorder};
|
|
68
|
+
stroke: none;
|
|
69
|
+
font-size: 10px;
|
|
70
|
+
}
|
|
71
|
+
g.stateGroup text {
|
|
72
|
+
fill: ${t.textColor};
|
|
73
|
+
stroke: none;
|
|
74
|
+
font-size: 10px;
|
|
75
|
+
|
|
76
|
+
}
|
|
77
|
+
g.stateGroup .state-title {
|
|
78
|
+
font-weight: bolder;
|
|
79
|
+
fill: ${t.stateLabelColor};
|
|
80
|
+
}
|
|
81
|
+
|
|
82
|
+
g.stateGroup rect {
|
|
83
|
+
fill: ${t.mainBkg};
|
|
84
|
+
stroke: ${t.nodeBorder};
|
|
85
|
+
}
|
|
86
|
+
|
|
87
|
+
g.stateGroup line {
|
|
88
|
+
stroke: ${t.lineColor};
|
|
89
|
+
stroke-width: ${t.strokeWidth||1};
|
|
90
|
+
}
|
|
91
|
+
|
|
92
|
+
.transition {
|
|
93
|
+
stroke: ${t.transitionColor};
|
|
94
|
+
stroke-width: ${t.strokeWidth||1};
|
|
95
|
+
fill: none;
|
|
96
|
+
}
|
|
97
|
+
|
|
98
|
+
.stateGroup .composit {
|
|
99
|
+
fill: ${t.background};
|
|
100
|
+
border-bottom: 1px
|
|
101
|
+
}
|
|
102
|
+
|
|
103
|
+
.stateGroup .alt-composit {
|
|
104
|
+
fill: #e0e0e0;
|
|
105
|
+
border-bottom: 1px
|
|
106
|
+
}
|
|
107
|
+
|
|
108
|
+
.state-note {
|
|
109
|
+
stroke: ${t.noteBorderColor};
|
|
110
|
+
fill: ${t.noteBkgColor};
|
|
111
|
+
|
|
112
|
+
text {
|
|
113
|
+
fill: ${t.noteTextColor};
|
|
114
|
+
stroke: none;
|
|
115
|
+
font-size: 10px;
|
|
116
|
+
}
|
|
117
|
+
}
|
|
118
|
+
|
|
119
|
+
.stateLabel .box {
|
|
120
|
+
stroke: none;
|
|
121
|
+
stroke-width: 0;
|
|
122
|
+
fill: ${t.mainBkg};
|
|
123
|
+
opacity: 0.5;
|
|
124
|
+
}
|
|
125
|
+
|
|
126
|
+
.edgeLabel .label rect {
|
|
127
|
+
fill: ${t.labelBackgroundColor};
|
|
128
|
+
opacity: 0.5;
|
|
129
|
+
}
|
|
130
|
+
.edgeLabel {
|
|
131
|
+
background-color: ${t.edgeLabelBackground};
|
|
132
|
+
p {
|
|
133
|
+
background-color: ${t.edgeLabelBackground};
|
|
134
|
+
}
|
|
135
|
+
rect {
|
|
136
|
+
opacity: 0.5;
|
|
137
|
+
background-color: ${t.edgeLabelBackground};
|
|
138
|
+
fill: ${t.edgeLabelBackground};
|
|
139
|
+
}
|
|
140
|
+
text-align: center;
|
|
141
|
+
}
|
|
142
|
+
.edgeLabel .label text {
|
|
143
|
+
fill: ${t.transitionLabelColor||t.tertiaryTextColor};
|
|
144
|
+
}
|
|
145
|
+
.label div .edgeLabel {
|
|
146
|
+
color: ${t.transitionLabelColor||t.tertiaryTextColor};
|
|
147
|
+
}
|
|
148
|
+
|
|
149
|
+
.stateLabel text {
|
|
150
|
+
fill: ${t.stateLabelColor};
|
|
151
|
+
font-size: 10px;
|
|
152
|
+
font-weight: bold;
|
|
153
|
+
}
|
|
154
|
+
|
|
155
|
+
.node circle.state-start {
|
|
156
|
+
fill: ${t.specialStateColor};
|
|
157
|
+
stroke: ${t.specialStateColor};
|
|
158
|
+
}
|
|
159
|
+
|
|
160
|
+
.node .fork-join {
|
|
161
|
+
fill: ${t.specialStateColor};
|
|
162
|
+
stroke: ${t.specialStateColor};
|
|
163
|
+
}
|
|
164
|
+
|
|
165
|
+
.node circle.state-end {
|
|
166
|
+
fill: ${t.innerEndBackground};
|
|
167
|
+
stroke: ${t.background};
|
|
168
|
+
stroke-width: 1.5
|
|
169
|
+
}
|
|
170
|
+
.end-state-inner {
|
|
171
|
+
fill: ${t.compositeBackground||t.background};
|
|
172
|
+
// stroke: ${t.background};
|
|
173
|
+
stroke-width: 1.5
|
|
174
|
+
}
|
|
175
|
+
|
|
176
|
+
.node rect {
|
|
177
|
+
fill: ${t.stateBkg||t.mainBkg};
|
|
178
|
+
stroke: ${t.stateBorder||t.nodeBorder};
|
|
179
|
+
stroke-width: ${t.strokeWidth||1}px;
|
|
180
|
+
}
|
|
181
|
+
.node polygon {
|
|
182
|
+
fill: ${t.mainBkg};
|
|
183
|
+
stroke: ${t.stateBorder||t.nodeBorder};;
|
|
184
|
+
stroke-width: ${t.strokeWidth||1}px;
|
|
185
|
+
}
|
|
186
|
+
[id$="-barbEnd"] {
|
|
187
|
+
fill: ${t.lineColor};
|
|
188
|
+
}
|
|
189
|
+
|
|
190
|
+
.statediagram-cluster rect {
|
|
191
|
+
fill: ${t.compositeTitleBackground};
|
|
192
|
+
stroke: ${t.stateBorder||t.nodeBorder};
|
|
193
|
+
stroke-width: ${t.strokeWidth||1}px;
|
|
194
|
+
}
|
|
195
|
+
|
|
196
|
+
.cluster-label, .nodeLabel {
|
|
197
|
+
color: ${t.stateLabelColor};
|
|
198
|
+
// line-height: 1;
|
|
199
|
+
}
|
|
200
|
+
|
|
201
|
+
.statediagram-cluster rect.outer {
|
|
202
|
+
rx: 5px;
|
|
203
|
+
ry: 5px;
|
|
204
|
+
}
|
|
205
|
+
.statediagram-state .divider {
|
|
206
|
+
stroke: ${t.stateBorder||t.nodeBorder};
|
|
207
|
+
}
|
|
208
|
+
|
|
209
|
+
.statediagram-state .title-state {
|
|
210
|
+
rx: 5px;
|
|
211
|
+
ry: 5px;
|
|
212
|
+
}
|
|
213
|
+
.statediagram-cluster.statediagram-cluster .inner {
|
|
214
|
+
fill: ${t.compositeBackground||t.background};
|
|
215
|
+
}
|
|
216
|
+
.statediagram-cluster.statediagram-cluster-alt .inner {
|
|
217
|
+
fill: ${t.altBackground?t.altBackground:"#efefef"};
|
|
218
|
+
}
|
|
219
|
+
|
|
220
|
+
.statediagram-cluster .inner {
|
|
221
|
+
rx:0;
|
|
222
|
+
ry:0;
|
|
223
|
+
}
|
|
224
|
+
|
|
225
|
+
.statediagram-state rect.basic {
|
|
226
|
+
rx: 5px;
|
|
227
|
+
ry: 5px;
|
|
228
|
+
}
|
|
229
|
+
.statediagram-state rect.divider {
|
|
230
|
+
stroke-dasharray: 10,10;
|
|
231
|
+
fill: ${t.altBackground?t.altBackground:"#efefef"};
|
|
232
|
+
}
|
|
233
|
+
|
|
234
|
+
.note-edge {
|
|
235
|
+
stroke-dasharray: 5;
|
|
236
|
+
}
|
|
237
|
+
|
|
238
|
+
.statediagram-note rect {
|
|
239
|
+
fill: ${t.noteBkgColor};
|
|
240
|
+
stroke: ${t.noteBorderColor};
|
|
241
|
+
stroke-width: 1px;
|
|
242
|
+
rx: 0;
|
|
243
|
+
ry: 0;
|
|
244
|
+
}
|
|
245
|
+
.statediagram-note rect {
|
|
246
|
+
fill: ${t.noteBkgColor};
|
|
247
|
+
stroke: ${t.noteBorderColor};
|
|
248
|
+
stroke-width: 1px;
|
|
249
|
+
rx: 0;
|
|
250
|
+
ry: 0;
|
|
251
|
+
}
|
|
252
|
+
|
|
253
|
+
.statediagram-note text {
|
|
254
|
+
fill: ${t.noteTextColor};
|
|
255
|
+
}
|
|
256
|
+
|
|
257
|
+
.statediagram-note .nodeLabel {
|
|
258
|
+
color: ${t.noteTextColor};
|
|
259
|
+
}
|
|
260
|
+
.statediagram .edgeLabel {
|
|
261
|
+
color: red; // ${t.noteTextColor};
|
|
262
|
+
}
|
|
263
|
+
|
|
264
|
+
[id$="-dependencyStart"], [id$="-dependencyEnd"] {
|
|
265
|
+
fill: ${t.lineColor};
|
|
266
|
+
stroke: ${t.lineColor};
|
|
267
|
+
stroke-width: ${t.strokeWidth||1};
|
|
268
|
+
}
|
|
269
|
+
|
|
270
|
+
.statediagramTitleText {
|
|
271
|
+
text-anchor: middle;
|
|
272
|
+
font-size: 18px;
|
|
273
|
+
fill: ${t.textColor};
|
|
274
|
+
}
|
|
275
|
+
|
|
276
|
+
[data-look="neo"].statediagram-cluster rect {
|
|
277
|
+
fill: ${t.mainBkg};
|
|
278
|
+
stroke: ${t.useGradient?"url("+t.svgId+"-gradient)":t.stateBorder||t.nodeBorder};
|
|
279
|
+
stroke-width: ${t.strokeWidth??1};
|
|
280
|
+
}
|
|
281
|
+
[data-look="neo"].statediagram-cluster rect.outer {
|
|
282
|
+
rx: ${t.radius}px;
|
|
283
|
+
ry: ${t.radius}px;
|
|
284
|
+
filter: ${t.dropShadow?t.dropShadow.replace("url(#drop-shadow)",`url(${t.svgId}-drop-shadow)`):"none"}
|
|
285
|
+
}
|
|
286
|
+
`,"getStyles"),init:(0,d.K)(t=>{t.state||(t.state={}),t.state.arrowMarkerAbsolute=t.arrowMarkerAbsolute},"init")}},37933:(t,e,s)=>{s.d(e,{A:()=>a});var i=s(21201),r=s(21930),a=(0,i.K)((t,e)=>{let s;return"sandbox"===e&&(s=(0,r.Ltv)("#i"+t)),("sandbox"===e?(0,r.Ltv)(s.nodes()[0].contentDocument.body):(0,r.Ltv)("body")).select(`[id="${t}"]`)},"getDiagramElement")},58578:(t,e,s)=>{s.d(e,{P:()=>n});var i=s(13333),r=s(78143),a=s(21201),n=(0,a.K)((t,e,s,a)=>{t.attr("class",s);let{width:n,height:c,x:h,y:d}=o(t,e);(0,i.a$)(t,c,n,a);let u=l(h,d,n,c,e);t.attr("viewBox",u),r.R.debug(`viewBox configured: ${u} with padding: ${e}`)},"setupViewPortForSVG"),o=(0,a.K)((t,e)=>{let s=t.node()?.getBBox()||{width:0,height:0,x:0,y:0};return{width:s.width+2*e,height:s.height+2*e,x:s.x,y:s.y}},"calculateDimensionsWithPadding"),l=(0,a.K)((t,e,s,i,r)=>`${t-r} ${e-r} ${s} ${i}`,"createViewBox")}}]);
|
package/apps/pwa/out/_next/static/chunks/{2489-ff55a35b202c0f94.js → 2489-d238d3e2eb5b2bf5.js}
RENAMED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[2489],{29325:(e,t,l)=>{l.d(t,{u:()=>n});function n(e,t){if(!e.enabled||"off"===e.scheduleState)return"off";if("failed"===e.lastStatus||"error"===e.lastStatus||"failure"===e.lastStatus||"abandoned"===e.lastStatus||"expired"===e.lastStatus)return"failed";if("stale"===e.scheduleState)return"late";let l=null===e.lastRunAt?NaN:Date.parse(e.lastRunAt);if(void 0!==e.secondDueAt){let n=null===e.secondDueAt?NaN:Date.parse(e.secondDueAt);return Number.isFinite(l)&&Number.isFinite(t)&&Number.isFinite(n)&&n>l&&t>n?"late":"alive"}return Number.isFinite(t)&&Number.isFinite(l)&&null!==e.intervalMs&&Number.isFinite(e.intervalMs)&&e.intervalMs>0&&t-l>2*e.intervalMs?"late":"alive"}},40385:(e,t,l)=>{l.d(t,{g:()=>i,q:()=>s});var n=l(81969);let a=[{id:"OP",seat:"COO"},{id:"MK",seat:"CMO"},{id:"TC",seat:"CTO"},{id:"UX",seat:"CXO"}];function r(e){return(0,n.t)(e.replace(/\s+/g," ")).trim()}function s(e){var t;let l=e.split("\n"),n=(e,t)=>{let l=e.trim();return t&&(l=(l=l.replace(/^\*\*\[[^\]]+\]\*\*\s*/,"")).replace(/^(?:📌\S*\s*)?\d{4}-\d{2}-\d{2}\s+\d{1,2}:\d{2}\s*KST\s*/,"")),r(l=(l=(l=(l=(l=(l=l.replace(/^→\s*(?:[A-Z]{1,4}|전원|전체)(?=\s|·|$)(?:\s*·\s*(?:[A-Z]{1,4}|전원|전체)(?=\s|·|$))*\s*(?:·)?\s*/u,"")).replace(/^—\s*/,"")).replace(/^[-*]\s+/,"").replace(/\*\*|`|__/g,"").replace(/^#+\s*/,"").trim()).replace(/^(?:보고|요청|정정|결정|사고|안내)\s*·\s*/,"")).replace(RegExp("^(?:\\p{Extended_Pictographic}\\uFE0F?)+\\s*","u"),"")).replace(/^(?:보고|요청|정정|결정|사고|안내)\s*·\s*/,""))},a=n(null!=(t=l[0])?t:"",!0);if(a)return a;let s=l.slice(1).find(e=>e.trim());return s?n(s,!1):""}function i(e,t){var l;let n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:Date.now();return{seats:a.map(t=>{var l;let{id:n,seat:a}=t,r=null==e?void 0:e.seats.find(e=>e.seat===n);return{seat:a,now:(null==r?void 0:r.now)&&Array.from(s(r.now.text)).slice(0,40).join("")||"못 읽음",landedToday:(null==r?void 0:r.landed)==null?"못 읽음":r.landed.length,blocked:(null==r?void 0:r.blocked)==null?"못 읽음":r.blocked.length,decisionsWaiting:null!=(l=null==r?void 0:r.pendingDecisions)?l:"못 읽음"}}),runs:(null!=(l=null==t?void 0:t.entries)?l:[]).filter(e=>"running"===e.status).sort((e,t)=>{var l,n;return(Date.parse(null!=(l=t.lastActivityTimestamp)?l:"")||0)-(Date.parse(null!=(n=e.lastActivityTimestamp)?n:"")||0)}).slice(0,6).map(e=>{var t;let l=Date.parse(null!=(t=e.lastActivityTimestamp)?t:"");return{id6:function(e){let t=e.replace(/^run-/i,"");return/^[a-z0-9]{6}/i.test(t)&&r(t.slice(0,6))||"못 읽음"}(e.runId),stage:r(e.lastPhase||e.status)||"못 읽음",elapsedSec:Number.isFinite(l)?Math.max(0,Math.floor((n-l)/1e3)):"못 읽음"}})}}},42006:(e,t,l)=>{l.d(t,{QK:()=>s,i6:()=>r,Pz:()=>o,Em:()=>i,Yy:()=>d});var n=l(29325);let a={alive:"살아 있음",late:"늦음",failed:"실패",off:"꺼짐"},r="/v1/schedules?includeOff=1",s="/v1/dashboard/loops";async function i(e,t){var l,i,o,c,u,m,p,f;let[h,b]=await Promise.allSettled([e(r),e(s)]),v="fulfilled"===h.status?null==(l=h.value)?void 0:l.schedules:null,g="fulfilled"===b.status?null==(o=b.value)||null==(i=o.loops)?void 0:i.loops:null;if(!Array.isArray(v)&&!Array.isArray(g))throw Error("loop registries unavailable");if(!Array.isArray(v))throw Error("스케줄 레지스트리 조회 실패");if(!Array.isArray(g))throw Error("루프 레지스트리 조회 실패");let x=d(v,t).map(e=>({...e,id:"schedule:".concat(e.id)}));for(let e of g){let l=e.last?Date.parse(e.last.at):NaN,r=(0,n.u)({enabled:!1!==e.armed,lastRunAt:null!=(m=null==(c=e.last)?void 0:c.at)?m:null,lastStatus:null!=(p=null==(u=e.last)?void 0:u.status.toLowerCase())?p:null,intervalMs:null},t);x.push({id:"loop:".concat(e.name),name:e.label,layer:null!=(f=e.category)?f:"루프",owner:"미지정",mode:null===e.armed?"관측":e.armed?"armed":"off",lastRun:Number.isFinite(l)?e.last.at:null,verdict:"alive"===r?"판정 불가":a[r]})}return x}function o(e,t){let l=arguments.length>2&&void 0!==arguments[2]?arguments[2]:Date.now,n=0,a=!0;return{async refresh(){let r=++n;try{let s=await i(e,l());a&&r===n&&t({rows:s,state:"ready"})}catch(e){a&&r===n&&t({rows:[],state:"error"})}},dispose(){a=!1}}}function d(e,t){return e.map(e=>{var l,r,s,i,o,d,c;let u=e.lastRun?Date.parse(e.lastRun.at):NaN,m=(0,n.u)({enabled:"off"!==e.state,lastRunAt:null!=(d=null==(l=e.lastRun)?void 0:l.at)?d:null,lastStatus:(null==(r=e.lastRun)?void 0:r.exit)!=null&&0!==e.lastRun.exit?"failed":(null==(s=e.lastRun)?void 0:s.status)==null||["ok","success","completed"].includes(e.lastRun.status.toLowerCase())?null!=(c=null==(o=e.lastRun)||null==(i=o.status)?void 0:i.toLowerCase())?c:null:"failed",intervalMs:e.cron?null:e.intervalMs,...e.cron?{scheduleState:e.state}:{}},t),p=!e.cron&&!(e.intervalMs&&e.intervalMs>0),f="alive"===m&&(!Number.isFinite(u)||p)?"판정 불가":a[m];return{id:e.id,name:e.name,layer:e.domain||e.category||e.source,owner:"미지정",mode:e.runVia||e.source,lastRun:Number.isFinite(u)?e.lastRun.at:null,verdict:f}})}},42489:(e,t,l)=>{l.d(t,{p1:()=>B});var n=l(55539),a=l(46124),r=l(58603),s=l(15151),i=l(43537),o=l(79247),d=l(40385),c=l(42006),u=l(88928),m=l(69280);l(71588);var p=l(29325),f=l(81969);let h={alive:"살아 있음",late:"늦음",failed:"실패",off:"꺼짐"};function b(e,t,l){if("launch"!==e.kind||"string"==typeof e.run&&""!==e.run)return!1;let n=Date.parse(e.at);return Number.isFinite(n)&&l-n>=6e5&&!t.some(t=>"run"===t.kind&&t.ref===e.ref)}let v={OP:"COO",MK:"CMO",TC:"CTO",UX:"CXO"},g=["OP","MK","TC","UX"],x=new Set(["request","decision","report","card","run","hand","launch","move"]),y=/^[a-zA-Z0-9_-]{1,128}$/,w="agent:task-agent",k="hub:runs",j=[{id:"loop:orchestrator",label:"조율"},{id:w,label:"TASK-AGENT"},{id:k,label:"런 묶음"},{id:"loop:release-loop",label:"발행 루프"},{id:"loop:guardian",label:"수호자"}];function N(e){return"string"==typeof e&&y.test(e)}function S(e){var t,l;let n=null!=(t=null==e?void 0:e.get("journey"))?t:null;if(N(n))return n;let a=null!=(l=null==e?void 0:e.get("demo"))?l:null;return N(a)&&"0"!==a&&"1"!==a?a:null}function A(e,t,l){let n=e&&"object"==typeof e&&"edges"in e?e.edges:null;if(!Array.isArray(n))throw Error("간선 조회 실패");return n.filter(e=>{if(!e||"object"!=typeof e||!x.has(e.kind)||"string"!=typeof e.at||"string"!=typeof e.from||"string"!=typeof e.to||"string"!=typeof e.ref)return!1;let n=Date.parse(e.at);return Number.isFinite(n)&&n<=t&&(!l||n>=t-36e5)})}function M(e,t){if(t&&("hand"===t.kind||"launch"===t.kind||"move"===t.kind)&&y.test(t.ref))return"/trace?q=".concat(encodeURIComponent(t.ref));if(e.startsWith("pr:")&&/^\d{1,9}$/.test(e.slice(3))&&!t)return"/trace?q=".concat(encodeURIComponent(e.slice(3)));let l=(null==t?void 0:t.kind)==="run"?t.ref:e;if((null==t?void 0:t.kind)==="card"&&y.test(t.ref))return"/trace?q=".concat(encodeURIComponent(t.ref));if(l.startsWith("loop:")&&y.test(l.slice(5))){let e=l.slice(5);return e.startsWith("run-")?"/trace?level=L2&run=".concat(encodeURIComponent(e)):"/trace?q=".concat(encodeURIComponent(e))}return l.startsWith("schedule:")&&y.test(l.slice(9))?"/trace?q=".concat(encodeURIComponent(l.slice(9))):l.startsWith("card:")&&y.test(l.slice(5))?"/trace?q=".concat(encodeURIComponent(l.slice(5))):(null==t?void 0:t.kind)==="run"&&y.test(l)?"/trace?level=L2&run=".concat(encodeURIComponent(l)):"/trace"}function C(e,t){let l=e=>e.startsWith("surface:")?0:e.startsWith("card:")?1:e.startsWith("loop:")?2:3;return e.filter(e=>"card"===e.kind&&e.ref===t).sort((e,t)=>e.at.localeCompare(t.at)||l(e.from)-l(t.from))}function T(e){return JSON.stringify([e.at,e.kind,e.from,e.to,e.ref])}let R=[{key:"tick",label:"틱 \xb7 넘김"},{key:"agent",label:"TASK-AGENT \xb7 발사"},{key:"run",label:"런"},{key:"pr",label:"PR"},{key:"land",label:"착지 \xb7 green 제안"}];function E(e,t){let l=new Set([t]);for(let n of e)"hand"===n.kind&&void 0!==n.cell&&(n.cell===t||n.cell.startsWith("".concat(t,"-")))&&l.add(n.ref);return l}function O(e,t){let l=arguments.length>2&&void 0!==arguments[2]?arguments[2]:new Set([t]),n=e.ref===t||l.has(e.ref);return"hand"===e.kind?n&&"shadow"!==e.mode?"tick":null:"launch"===e.kind?n?"agent":null:"move"===e.kind?n&&"green-proposal"===e.move?"land":null:"run"===e.kind?e.to.startsWith("pr:")?"pr":e.to.startsWith("loop:")?"run":null:"card"===e.kind&&e.to.startsWith("landed:")?"land":null}function I(e,t){let l=E(e,t),n=e=>R.findIndex(n=>n.key===O(e,t,l));return[...C(e,t),...e.filter(e=>"card"!==e.kind||e.ref!==t).filter(e=>null!==O(e,t,l))].sort((e,t)=>e.at.localeCompare(t.at)||n(e)-n(t))}let D={request:"요청",decision:"결정",report:"보고",card:"카드",run:"런",hand:"넘김",launch:"발사",move:"판단"},U={request:"●",decision:"◆",report:"■",hand:"▲",launch:"★",move:"⬟",card:"◇",run:"▶"};var W=l(18993);let F={"살아 있음":"bg-emerald-500/15 text-emerald-300 ring-emerald-500/30",늦음:"bg-red-500/15 text-red-300 ring-red-500/30",실패:"bg-red-500/15 text-red-300 ring-red-500/30",꺼짐:"bg-slate-700 text-slate-300 ring-slate-500","판정 불가":"bg-slate-700 text-slate-300 ring-slate-500"};function P(e){let{detail:t}=e;return(0,n.jsxs)("div",{"data-near-detail":"",className:"w-[180px] space-y-1 rounded-lg border border-slate-600 bg-[#10243b]/95 p-2 text-left text-[10px] font-normal text-slate-200",children:[null!==t.now&&(0,n.jsxs)("p",{className:"break-words",children:[(0,n.jsx)("span",{className:"text-slate-400",children:"지금 "}),t.now]}),(null!==t.running||null!==t.waiting)&&(0,n.jsxs)("p",{className:"flex gap-2",children:[null!==t.running&&(0,n.jsxs)("span",{children:["도는 런 ",t.running]}),null!==t.waiting&&(0,n.jsxs)("span",{children:["대기 ",t.waiting]})]}),t.recent.length>0?(0,n.jsx)("ol",{"aria-label":"최근 행동",className:"space-y-0.5",children:t.recent.map((e,t)=>(0,n.jsx)("li",{className:"break-words",children:e},t))}):(0,n.jsx)("p",{className:"text-slate-400",children:"최근 행동 없음"})]})}let Z={activity:function(e){let{data:t}=e,l="seat"===t.type||"hub"===t.type;return(0,n.jsxs)("div",{className:"relative flex flex-col items-center gap-1 text-center text-white",children:[(0,n.jsx)(u.h7,{type:"target",position:m.yX.Left,className:"!border-sky-400 !bg-sky-400"}),(0,n.jsx)("div",{className:"flex items-center justify-center rounded-full border-2 border-sky-400 bg-[#173556] px-2 font-bold ".concat(l?"h-[90px] w-[90px] text-lg":"h-[64px] w-[64px] text-xs"),children:(0,n.jsx)("span",{className:"line-clamp-2 break-all",children:(0,f.t)(t.label)})}),t.verdict&&(0,n.jsx)("span",{"data-loop-verdict":t.verdict,className:"rounded-full px-2 py-0.5 text-xs font-semibold ring-1 ".concat(F[t.verdict]),children:t.verdict}),t.detail&&(0,n.jsx)(P,{detail:t.detail}),(0,n.jsx)(u.h7,{type:"source",position:m.yX.Right,className:"!border-sky-400 !bg-sky-400"})]})}},L={packet:function(e){var t,l;let{id:r,sourceX:s,sourceY:i,targetX:o,targetY:d,sourcePosition:c,targetPosition:p,style:f,markerEnd:h,label:b,labelStyle:v,interactionWidth:g,data:x}=e,[y,w,k]=(0,m.Fp)({sourceX:s,sourceY:i,targetX:o,targetY:d,sourcePosition:c,targetPosition:p}),j=(0,a.useRef)(null),N=(0,a.useRef)(null),S=null!=(t=null==x?void 0:x.packet)?t:null,A=null!=(l=null==S?void 0:S.key)?l:null;return(0,a.useEffect)(()=>{if(null!==A)try{var e,t,l,n;null==(t=j.current)||null==(e=t.beginElement)||e.call(t),null==(n=N.current)||null==(l=n.beginElement)||l.call(n)}catch(e){}},[A]),(0,n.jsxs)(n.Fragment,{children:[(0,n.jsx)(u.tE,{id:r,path:y,style:f,markerEnd:h,label:b,labelX:w,labelY:k,labelStyle:v,interactionWidth:g}),S&&(0,n.jsxs)("g",{"data-packet":S.word,"aria-hidden":"true",opacity:0,children:[(0,n.jsx)("text",{textAnchor:"middle",dominantBaseline:"central",fontSize:16,fill:"#e0f2fe",stroke:"#10243b",strokeWidth:.6,children:S.shape}),(0,n.jsx)("animateMotion",{ref:j,begin:"indefinite",dur:"".concat(S.roundTrip?2400:1200,"ms"),path:y,fill:"freeze",...S.roundTrip?{keyPoints:"0;1;0",keyTimes:"0;0.5;1",calcMode:"linear"}:{}}),(0,n.jsx)("animate",{ref:N,attributeName:"opacity",begin:"indefinite",dur:"".concat(S.roundTrip?2400:1200,"ms"),values:"1;1;0",keyTimes:"0;0.85;1",fill:"freeze"})]})]})}},K={done:"border-emerald-500/60 bg-emerald-500/15",failed:"border-red-500/60 bg-red-500/15",current:"border-sky-300 bg-sky-500/20",pending:"border-dashed border-slate-500 bg-slate-800/40"};function X(e){return"hand"===e.kind?e.broken?"broken":"shadow"===e.mode?"shadow":"live":null}function q(e,t,l){if(t)return"".concat(D.launch," \xb7 유령 \xb7 런 원장 없음 ").concat(Math.floor((l-Date.parse(e.at))/6e4),"분");let n=X(e);return"broken"===n?"".concat(D.hand," \xb7 끊김 ✕"):"shadow"===n?"".concat(D.hand," \xb7 그림자"):D[e.kind]}function z(e){let{rows:t,edges:l,seenAt:s,now:i,state:o,seatIds:d,details:c}=e,m=(0,r.useSearchParams)(),p=m.get("card"),h=S(m),[x,w]=(0,a.useState)(1),N=x<.8?"far":"near",[A,P]=(0,a.useState)(!1);(0,a.useEffect)(()=>{var e;if(P(function(){try{return"function"==typeof window.matchMedia&&window.matchMedia("(prefers-reduced-motion: reduce)").matches}catch(e){return!1}}()),"function"!=typeof window.matchMedia)return;let t=window.matchMedia("(prefers-reduced-motion: reduce)"),l=()=>P(t.matches);return null==(e=t.addEventListener)||e.call(t,"change",l),()=>{var e;return null==(e=t.removeEventListener)?void 0:e.call(t,"change",l)}},[]);let z=(0,a.useMemo)(()=>null===h?[]:function(e,t){let l=I(e,t),n=E(e,t),a=0===l.length,r=R.reduce((e,a,r)=>l.some(e=>O(e,t,n)===a.key&&!e.broken)?r:e,-1);return R.map((e,s)=>{let i=l.filter(l=>O(l,t,n)===e.key),o=i.find(e=>!e.broken);return o?{key:e.key,label:e.label,state:"done",edge:o}:0===i.length&&s<r?{key:e.key,label:e.label,state:"done"}:i.length>0?(a=!0,{key:e.key,label:e.label,state:"failed",edge:i[0]}):a?{key:e.key,label:e.label,state:"pending"}:(a=!0,{key:e.key,label:e.label,state:"current"})})}(l,h),[l,h]),_=(0,a.useMemo)(()=>new Set(null===h?[]:I(l,h).map(T)),[l,h]),[$,J]=(0,a.useState)(p);(0,a.useEffect)(()=>{J(p)},[p]);let G=(0,a.useMemo)(()=>[...new Set(l.filter(e=>"card"===e.kind).map(e=>e.ref))].sort(),[l]),V=(0,a.useMemo)(()=>null===$?[]:C(l,$),[l,$]),B=new Set(V.map(T)),H=null!==$?B:null!==h?_:null,Q=e=>{J(e);let t=new URL(window.location.href);null===e?t.searchParams.delete("card"):t.searchParams.set("card",e),window.history.replaceState(window.history.state,"",t.toString())},Y=(0,a.useMemo)(()=>(function(e,t){var l,n;let a=arguments.length>2&&void 0!==arguments[2]?arguments[2]:g,r=new Map;for(let e of a)r.set(e,{id:e,type:"seat",label:null!=(l=v[e])?l:(0,f.t)(e)});for(let e of j)r.set(e.id,{id:e.id,type:"hub",label:e.label});let s=new Set(a),i=new Set;for(let t of e){let e=s.has(t.owner)?t.owner:"미지정",l=t.id,n=(0,f.t)(t.name),a=i.has(n)?"".concat(n," \xb7 ").concat((0,f.t)(t.id)):n;i.add(n);let o=r.get(l);r.set(l,(null==o?void 0:o.type)==="hub"?{...o,owner:e,verdict:t.verdict}:{id:l,type:"loop",label:a,owner:e,verdict:t.verdict})}for(let e of t)for(let t of[e.from,e.to]){if(r.has(t))continue;let[e,l]=t.split(":",2);"loop"===e&&l&&y.test(l)?r.set(t,{id:t,type:"other",label:l.startsWith("run-")?"런 \xb7 ".concat((0,f.t)(l)):"칸 \xb7 ".concat((0,f.t)(l))}):"card"===e||"surface"===e?r.set(t,{id:t,type:"other",label:"card"===e?"카드":"입구 \xb7 ".concat((0,f.t)(null!=l?l:""))}):"agent"===e&&l&&y.test(l)?r.set(t,{id:t,type:"other",label:"에이전트 \xb7 ".concat((0,f.t)(l))}):"pr"===e&&l&&/^\d{1,9}$/.test(l)?r.set(t,{id:t,type:"other",label:"PR #".concat(l)}):("release"===e||"landed"===e)&&l&&y.test(l)?r.set(t,{id:t,type:"other",label:"".concat("release"===e?"발행":"착지"," \xb7 ").concat((0,f.t)(l))}):s.has(t)&&r.set(t,{id:t,type:"seat",label:null!=(n=v[t])?n:(0,f.t)(t)})}return[...r.values()]})(t,l,d),[t,l,d]),ee=(0,a.useMemo)(()=>{let e=Y.filter(e=>"seat"===e.type);return[...e.map(e=>e.id),"미지정"].map((t,l)=>({owner:t,column:l,nodes:[..."미지정"===t?[]:e.filter(e=>e.id===t),...Y.filter(e=>"loop"===e.type&&e.owner===t)]})).filter(e=>e.nodes.length>0)},[Y]),et=new Map(Y.map((e,t)=>[e.id,"node-".concat(t)])),el=e=>{var t,l;return null!=(l=null==(t=Y.find(t=>t.id===e))?void 0:t.label)?l:"알 수 없음"},en=new Set(l.filter(e=>"run"===e.kind&&e.to.startsWith("loop:")).map(e=>e.to)).size,ea=e=>{if("near"!==N)return;let t=function(e,t,l,n,a){var r,s;let i=t.filter(t=>t.from===e||t.to===e).sort((e,t)=>t.at.localeCompare(e.at)).slice(0,5).map(l=>"".concat(void 0!==a&&b(l,t,a)?"발사 \xb7 유령":D[l.kind]," ").concat(l.from===e?"→":"←"," ").concat((0,f.t)(n(l.from===e?l.to:l.from))));return{now:(null==l?void 0:l.now)?(0,f.t)(l.now):null,recent:i,running:null!=(r=null==l?void 0:l.running)?r:null,waiting:null!=(s=null==l?void 0:l.waiting)?s:null}}(e,l,e===k?{running:en,...null==c?void 0:c[e]}:null==c?void 0:c[e],el,i);return null===t.now&&null===t.running&&null===t.waiting&&0===t.recent.length?void 0:t},er=ee.map((e,t)=>ee.slice(0,t).reduce((e,t)=>e+Math.ceil(t.nodes.length/8),0)),es=ee.flatMap((e,t)=>{let{nodes:l}=e;return l.map((e,l)=>({id:et.get(e.id),type:"activity",position:{x:(er[t]+Math.floor(l/8))*220,y:l%8*138},data:{label:e.label,type:e.type,verdict:e.verdict,detail:ea(e.id)}}))});j.forEach((e,t)=>{let l=Y.find(t=>t.id===e.id);l&&es.push({id:et.get(l.id),type:"activity",position:{x:220*t,y:-170},data:{label:l.label,type:l.type,verdict:l.verdict,detail:ea(l.id)}})}),Y.filter(e=>"other"===e.type).forEach((e,t)=>es.push({id:et.get(e.id),type:"activity",position:{x:180*Math.floor(t/8),y:138*Math.max(...ee.map(e=>Math.min(e.nodes.length,8)),1)+40+t%8*138},data:{label:e.label,type:e.type,detail:ea(e.id)}}));let ei=l.filter(e=>et.has(e.from)&&et.has(e.to)).map((e,t)=>{var n;let a=T(e),r=i-(null!=(n=s[a])?n:0),o=r<1500,d=null!==H&&H.has(a),c=null!==H&&!d,u=X(e),m=b(e,l,i),p=q(e,m,i),f=m||A||!(r<2600)?null:{key:a,shape:U[e.kind],word:D[e.kind],roundTrip:function(e,t){let l="request"===e.kind?["report","decision"]:"report"===e.kind||"decision"===e.kind?["request"]:[];return l.length>0&&t.some(t=>l.includes(t.kind)&&t.ref===e.ref&&t.from===e.to&&t.to===e.from)}(e,l)};return{id:"edge-".concat(t),type:"packet",source:et.get(e.from),target:et.get(e.to),label:p,data:{edge:e,packet:f,hand:u},animated:!1,focusable:!0,interactionWidth:24,style:{stroke:m||"broken"===u?"#fca5a5":d||!c&&o?"#7dd3fc":"#7492a8",strokeWidth:d||!c&&o?4:2,opacity:c?.16:d||o?1:"shadow"===u?.35:.55,...m||"broken"===u?{strokeDasharray:"2 7"}:"shadow"===u?{strokeDasharray:"6 5"}:{},transition:"stroke 1.5s ease, stroke-width 1.5s ease, opacity 1.5s ease"},labelStyle:{fill:c?"#7492a8":m||"broken"===u?"#fecaca":d||o?"#e0f2fe":"#a8b7c7",fontSize:12,opacity:c?.4:1}}});return(0,n.jsxs)("section",{"aria-label":"루프 활동 지도",className:"min-w-0 space-y-3",children:[(0,n.jsx)("p",{className:"text-sm text-slate-300",children:"자리(큰 원) \xb7 루프(작은 원) \xb7 최근 60분 실제 사건. 노드나 간선을 누르면 Trace로 이동합니다."}),(0,n.jsx)("p",{className:"text-xs text-slate-400",children:"꾸러미 모양 \xb7 요청 ● 결정 ◆ 보고 ■ 넘김 ▲ 발사 ★ 판단 ⬟ \xb7 넘김 실선 = 실발사 \xb7 점선 = 그림자 \xb7 ✕ = 끊김 \xb7 유령 = 발사 뒤 10분간 같은 ref 런 간선 없음 \xb7 확대하면 노드 안 지금 일이 보입니다."}),null!==h&&(0,n.jsxs)("section",{"aria-label":"데모 여정",className:"rounded-xl border border-sky-500/50 bg-[#173556] p-3",children:[(0,n.jsxs)("h3",{className:"font-semibold",children:["여정 \xb7 ",(0,f.t)(h)]}),"ready"===o&&0===_.size&&(0,n.jsx)("p",{role:"status",className:"mt-1 text-sm text-slate-300",children:"아직 사건 없음 — 틱이 이 카드를 집으면 1단계부터 채워집니다"}),(0,n.jsx)("ol",{className:"mt-2 flex min-w-0 flex-wrap items-stretch gap-2 text-sm",children:z.map((e,t)=>(0,n.jsxs)("li",{"data-journey-state":e.state,className:"flex min-w-0 items-center gap-2 rounded-lg border px-3 py-2 ".concat(K[e.state]),children:[(0,n.jsx)("span",{"aria-hidden":"true",children:W.bq[e.state].mark}),(0,n.jsxs)("span",{className:"min-w-0 break-words",children:[t+1,". ",e.label," \xb7 ",W.bq[e.state].word]}),e.edge&&(0,n.jsx)("time",{className:"text-xs text-slate-300",dateTime:e.edge.at,children:new Date(e.edge.at).toLocaleTimeString("ko-KR",{timeZone:"Asia/Seoul"})})]},e.key))})]}),(0,n.jsxs)("div",{role:"group","aria-label":"데모 카드 선택",className:"flex flex-wrap items-center gap-2 text-sm",children:[(0,n.jsx)("span",{children:"카드 경로"}),G.map(e=>(0,n.jsx)("button",{type:"button","aria-pressed":$===e,onClick:()=>Q(e),className:"min-h-11 rounded-lg border border-slate-500 px-3 py-2 aria-pressed:border-sky-300 aria-pressed:bg-sky-800 focus-visible:outline-2 focus-visible:outline-sky-400",children:(0,f.t)(e)},e)),null!==$&&(0,n.jsx)("button",{type:"button",onClick:()=>Q(null),className:"min-h-11 rounded-lg border border-slate-500 px-3 py-2 focus-visible:outline-2 focus-visible:outline-sky-400",children:"전체 보기"})]}),null!==$&&(0,n.jsxs)("section",{"aria-label":"선택 카드 흐름",className:"rounded-xl border border-sky-500/50 bg-[#173556] p-3",children:[(0,n.jsxs)("h3",{className:"font-semibold",children:["요구 한 줄 → 회신 \xb7 카드 ",(0,f.t)($)]}),"ready"===o&&0===V.length&&(0,n.jsx)("p",{role:"status",children:"이 카드는 아직 흐른 사건이 없음"}),V.length>0&&(0,n.jsx)("ol",{className:"mt-2 space-y-2",children:V.map((e,t)=>{var l,a,r,s;return(0,n.jsxs)("li",{className:"break-words text-sm",children:[t+1,". ",(0,f.t)(null!=(r=null==(l=Y.find(t=>t.id===e.from))?void 0:l.label)?r:"출발")," → ",e.to.startsWith("surface:")?"회신 \xb7 ".concat((0,f.t)(e.to.slice(8))):(0,f.t)(null!=(s=null==(a=Y.find(t=>t.id===e.to))?void 0:a.label)?s:"도착")," \xb7 ",(0,n.jsx)("time",{dateTime:e.at,children:new Date(e.at).toLocaleTimeString("ko-KR",{timeZone:"Asia/Seoul"})})]},"".concat(T(e),"-").concat(t))})})]}),"error"===o&&(0,n.jsx)("p",{role:"alert",className:"text-red-300",children:"지도 원천을 읽지 못했습니다. 이전 지도가 보이면 현재 데이터가 아닙니다. 데몬 연결을 확인하세요."}),"loading"===o&&(0,n.jsx)("p",{role:"status",children:"지도를 읽는 중…"}),(0,n.jsx)("div",{className:"h-[440px] min-w-0 w-full overflow-hidden rounded-2xl border border-slate-600 bg-[#10243b]","aria-label":"자리와 루프 관계도",children:(0,n.jsxs)(u.Gc,{nodes:es,edges:ei,nodeTypes:Z,edgeTypes:L,fitView:!0,minZoom:.25,maxZoom:2.5,onInit:e=>w(e.getZoom()),onMove:(e,t)=>w(t.zoom),nodesDraggable:!1,nodesConnectable:!1,edgesReconnectable:!1,deleteKeyCode:null,onNodeClick:(e,t)=>{let l=Y.find(e=>et.get(e.id)===t.id);l&&window.location.assign(M(l.id))},onEdgeClick:(e,t)=>{var l;let n=null==(l=t.data)?void 0:l.edge;n&&window.location.assign(M(n.to,n))},children:[(0,n.jsx)(u.VS,{color:"#355470"}),(0,n.jsx)(u.H2,{showInteractive:!1})]},"loading"===o?"loading":"loaded")}),(0,n.jsx)("div",{"aria-label":"지도 목록",className:"grid gap-4 sm:grid-cols-2 xl:grid-cols-4",children:ee.map(e=>{var t;return(0,n.jsxs)("section",{className:"min-w-0 rounded-xl border border-slate-600 p-3",children:[(0,n.jsx)("h3",{className:"mb-2 font-semibold",children:null!=(t=v[e.owner])?t:(0,f.t)(e.owner)}),(0,n.jsx)("ul",{className:"space-y-2",children:e.nodes.map(e=>(0,n.jsx)("li",{children:(0,n.jsxs)("button",{type:"button",onClick:()=>window.location.assign(M(e.id)),className:"flex w-full min-w-0 items-center gap-2 rounded-lg border border-slate-600 px-2 py-2 text-left text-sm focus-visible:outline-2 focus-visible:outline-sky-400",children:[(0,n.jsx)("span",{"aria-hidden":"true",className:"shrink-0 rounded-full border border-sky-400 bg-[#173556] ".concat("seat"===e.type?"h-8 w-8":"h-5 w-5")}),(0,n.jsx)("span",{className:"min-w-0 break-words",children:(0,f.t)(e.label)}),e.verdict&&(0,n.jsx)("span",{"data-loop-verdict":e.verdict,className:"ml-auto shrink-0 rounded-full px-2 py-0.5 text-xs ring-1 ".concat(F[e.verdict]),children:e.verdict})]})},e.id))})]},e.owner)})}),(0,n.jsx)("ul",{"aria-label":"최근 간선 사건",className:"space-y-2",children:l.map((e,t)=>{var a,r,o,d,c;return(0,n.jsx)("li",{children:(0,n.jsxs)("button",{type:"button",onClick:()=>window.location.assign(M(e.to,e)),className:"block w-full min-w-0 break-words rounded-lg border border-slate-600 px-3 py-2 text-left text-sm focus-visible:outline-2 focus-visible:outline-sky-400 ".concat(null!==$?B.has(T(e))?"border-sky-300 bg-sky-500/30 text-sky-100":"bg-slate-800/30 text-slate-400 opacity-40":i-(null!=(o=s[T(e)])?o:0)<1500?"bg-sky-500/20 text-sky-100 transition-colors duration-[1500ms] motion-reduce:transition-none":"bg-slate-800/50 text-slate-300"),children:[(0,f.t)(null!=(d=null==(a=Y.find(t=>t.id===e.from))?void 0:a.label)?d:"출발")," → ",(0,f.t)(null!=(c=null==(r=Y.find(t=>t.id===e.to))?void 0:r.label)?c:"도착")," \xb7 ",q(e,b(e,l,i),i)," \xb7 ",(0,n.jsx)("time",{dateTime:e.at,children:new Date(e.at).toLocaleTimeString("ko-KR",{timeZone:"Asia/Seoul"})})]})},"edge-".concat(t))})}),"ready"===o&&0===l.length&&(0,n.jsx)("p",{role:"status",className:"text-slate-300",children:"최근 사건이 없습니다."})]})}var _=l(69370);let $=["loop.","task-agent","harness.queue","self-implement.pod"],J={setTimeout:(e,t)=>globalThis.setTimeout(e,t),clearTimeout:e=>globalThis.clearTimeout(e),setInterval:(e,t)=>globalThis.setInterval(e,t),clearInterval:e=>globalThis.clearInterval(e)},G=(0,d.g)(null,null);function V(e){let{view:t,runsUnreadable:l,refreshedAt:a}=e;return(0,n.jsxs)("section",{"aria-label":"루프 에이전트 활동",className:"min-w-0 space-y-6 p-4 text-lg min-[1440px]:text-[22px]",children:[(0,n.jsx)("div",{className:"grid grid-cols-2 gap-3 min-[1440px]:grid-cols-4",children:t.seats.map(e=>(0,n.jsxs)("article",{"aria-label":"".concat(e.seat," 자리"),className:"min-w-0 space-y-3 rounded-2xl border border-border bg-card p-3 min-[1440px]:p-6",children:[(0,n.jsx)("h2",{className:"font-bold",children:e.seat}),(0,n.jsx)("p",{className:"break-words","aria-label":"지금 하는 일",children:e.now}),(0,n.jsxs)("dl",{className:"space-y-1 text-base min-[1440px]:text-[22px]",children:[(0,n.jsxs)("div",{className:"flex flex-wrap justify-between gap-x-2",children:[(0,n.jsx)("dt",{children:"오늘 착지"}),(0,n.jsx)("dd",{children:e.landedToday})]}),(0,n.jsxs)("div",{className:"flex flex-wrap justify-between gap-x-2",children:[(0,n.jsx)("dt",{children:"막힘"}),(0,n.jsx)("dd",{children:e.blocked})]}),(0,n.jsxs)("div",{className:"flex flex-wrap justify-between gap-x-2",children:[(0,n.jsx)("dt",{children:"대표 결정 대기"}),(0,n.jsx)("dd",{children:e.decisionsWaiting})]})]})]},e.seat))}),(0,n.jsxs)("section",{"aria-label":"지금 도는 런",className:"min-w-0 rounded-2xl border border-border bg-card p-4",children:[(0,n.jsx)("h2",{className:"font-semibold",children:"지금 도는 런"}),l?(0,n.jsx)("p",{className:"text-muted-foreground",children:"못 읽음"}):0===t.runs.length?(0,n.jsx)("p",{className:"text-muted-foreground",children:"지금 도는 런이 없습니다"}):(0,n.jsx)("ul",{className:"mt-3 flex flex-wrap gap-3",children:t.runs.map((e,t)=>(0,n.jsxs)("li",{className:"min-w-0 break-words rounded-lg border border-border px-3 py-2",children:["런 ",e.id6," \xb7 ",e.stage," \xb7 경과 ","못 읽음"===e.elapsedSec?e.elapsedSec:"".concat(e.elapsedSec,"초")]},"".concat(e.id6,"-").concat(t)))})]}),(0,n.jsxs)("p",{className:"text-sm text-muted-foreground",children:["마지막 갱신 ",(0,n.jsx)("time",{dateTime:null!=a?a:void 0,children:a?new Date(a).toLocaleString("ko-KR",{timeZone:"Asia/Seoul"}):"못 읽음"})]})]})}function B(){var e,t,l,u,m,b,v,g;let{initialMode:x="activity"}=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},{client:y,config:j}=(0,s.Q)(),[M,C]=(0,a.useState)(null),R=S((0,r.useSearchParams)()),[E,O]=(0,a.useState)(null!==R?"map":x),[I,D]=(0,a.useState)(null),[U,W]=(0,a.useState)(0),F="".concat(j.baseUrl,"\0").concat(j.token),P="".concat(F,"\0").concat(E,"\0").concat(null!=R?R:""),Z=(null==M?void 0:M.source)===F?M:null,L=null!=(t=null==Z||null==(e=Z.seats)?void 0:e.seats.flatMap(e=>{var t,l;return null!=(l=null==(t=e.subSeats)?void 0:t.map(e=>e.id))?l:[]}))?t:[];(0,a.useEffect)(()=>{let e=!0,t=!1,l=(0,o.xX)({baseUrl:j.baseUrl,token:j.token});C({source:F,seats:null,runs:null,runsUnreadable:!0,refreshedAt:null});let n=async()=>{var n;if(!e||t||document.hidden)return;t=!0;let a=new Intl.DateTimeFormat("sv-SE",{timeZone:"Asia/Seoul"}).format(new Date),[r,s]=await Promise.allSettled([(0,i.Nn)(y,a),l.getHarnessRuns()]);if(t=!1,!e)return;let o="fulfilled"===r.status&&"ready"===r.value.kind?r.value.data:null,d="fulfilled"===s.status&&Array.isArray(null==(n=s.value)?void 0:n.entries)?s.value:null;C({source:F,seats:o,runs:d,runsUnreadable:null===d,refreshedAt:o||d?new Date().toISOString():null})};n();let a=window.setInterval(()=>{n()},1e4),r=()=>{document.hidden||n()};return document.addEventListener("visibilitychange",r),()=>{e=!1,window.clearInterval(a),document.removeEventListener("visibilitychange",r)}},[y,j.baseUrl,j.token,F]),(0,a.useEffect)(()=>{if("map"!==E)return;let e=!0,t=!1,l=!1;D(null),W(Date.now());let n=async()=>{if(!e||document.hidden)return;if(t){l=!0;return}t=!0,l=!1;let a=Date.now();try{let[t,l,n]=await Promise.all([(0,c.Em)(e=>y.fetchJson(e),a),y.fetchJson("/v1/schedules?includeOff=1&includeOwners=1"),y.fetchJson(N(R)?"/v1/loops/edges?ref=".concat(encodeURIComponent(R),"&mode=live&limit=500"):"/v1/loops/edges?since=".concat(encodeURIComponent(new Date(a-36e5).toISOString()),"&limit=200"))]),r=l.owners;if(!Array.isArray(r))throw Error("루프 주인 조회 실패");let s=null===R?A(n,a,!0):A(n,a,!1);e&&D(e=>{var l;return{source:P,rows:function(e,t,l){let n=new Map(t.flatMap(e=>e.jobs.map(t=>[t,e.owner]))),a=new Map(t.map(e=>[e.id,e.owner])),r=e.map(e=>{var t;return{...e,owner:null!=(t=e.id.startsWith("schedule:")?n.get(e.id.slice(9)):a.get(e.id.slice(5)))?t:"미지정"}});for(let e of t){var s,i,o,d,c,u,m;if(r.some(t=>t.id==="loop:".concat(e.id)))continue;let t=(0,p.u)({enabled:e.enabled,lastRunAt:null!=(d=null==(s=e.lastRun)?void 0:s.at)?d:null,lastStatus:null!=(c=null==(i=e.lastRun)?void 0:i.status.toLowerCase())?c:null,intervalMs:null},l);r.push({id:"loop:".concat(e.id),name:(0,f.t)(e.title),layer:"그래프",owner:null!=(u=e.owner)?u:"미지정",mode:"등록",lastRun:null!=(m=null==(o=e.lastRun)?void 0:o.at)?m:null,verdict:"alive"!==t||e.lastRun?h[t]:"판정 불가"})}return r}(t,r,a),edges:s,seenAt:(l=(null==e?void 0:e.source)===P?e.seenAt:null,Object.fromEntries(s.map(e=>{var t;let n=T(e);return[n,null!=(t=null==l?void 0:l[n])?t:null===l?a-1500:a]}))),state:"ready"}})}catch(t){e&&D(e=>({source:P,rows:(null==e?void 0:e.source)===P?e.rows:[],edges:(null==e?void 0:e.source)===P?e.edges:[],seenAt:(null==e?void 0:e.source)===P?e.seenAt:{},state:"error"}))}finally{t=!1,l&&e&&n()}};n();let a=function(e,t){var l,n,a,r,s;let i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},o=null!=(l=i.timers)?l:J,d=null!=(n=i.debounceMs)?n:800,c=null!=(a=i.pollMs)?a:5e3,u=!1,m=null,p=null,f=o.setInterval(()=>{u||null!==p||t()},null!=(r=i.safetyMs)?r:3e4),h=()=>{var e;u||null!==p||(p=o.setInterval(()=>{u||t()},c),null==(e=i.onMode)||e.call(i,"poll"))},b=e.logsStreamUrl({category:$.join(",")}),v=()=>{};if(null===b)h();else{let e=!1;v=(0,_.BX)(b,{events:{log:()=>{if(!u){var e;null!==p&&(o.clearInterval(p),p=null,null==(e=i.onMode)||e.call(i,"stream")),null!==m&&o.clearTimeout(m),m=o.setTimeout(()=>{m=null,u||t()},d)}}},onError:h,onConstructError:()=>{e=!0}}),e?h():null==(s=i.onMode)||s.call(i,"stream")}return()=>{u||(u=!0,null!==m&&o.clearTimeout(m),null!==p&&o.clearInterval(p),o.clearInterval(f),m=null,p=null,v())}}(y,()=>{n()}),r=window.setInterval(()=>{document.hidden||W(Date.now())},250),s=()=>{document.hidden||n()};return document.addEventListener("visibilitychange",s),()=>{e=!1,a(),window.clearInterval(r),document.removeEventListener("visibilitychange",s)}},[y,E,P,R]);let K=(null==I?void 0:I.source)===P?I:null;return(0,n.jsxs)("div",{className:"min-w-0",children:[(0,n.jsxs)("div",{role:"group","aria-label":"루프 에이전트 보기",className:"flex gap-2 px-4 pt-4",children:[(0,n.jsx)("button",{type:"button","aria-pressed":"activity"===E,onClick:()=>O("activity"),className:"min-h-11 rounded-lg border border-slate-500 px-4 py-2 aria-pressed:bg-sky-800",children:"현황"}),(0,n.jsx)("button",{type:"button","aria-pressed":"map"===E,onClick:()=>O("map"),className:"min-h-11 rounded-lg border border-slate-500 px-4 py-2 aria-pressed:bg-sky-800",children:"지도"})]}),"activity"===E?(0,n.jsx)(V,{view:Z?(0,d.g)(Z.seats,Z.runs):G,runsUnreadable:null==(l=null==Z?void 0:Z.runsUnreadable)||l,refreshedAt:null!=(u=null==Z?void 0:Z.refreshedAt)?u:null}):(0,n.jsx)("div",{className:"min-w-0 p-4",children:(0,n.jsx)(z,{rows:null!=(m=null==K?void 0:K.rows)?m:[],edges:null!=(b=null==K?void 0:K.edges)?b:[],seatIds:["OP","MK","TC","UX",...L],details:Z?function(e,t){let l={COO:"OP",CMO:"MK",CTO:"TC",CXO:"UX"},n=t?"못 읽음":e.runs.length,a={[w]:{running:n},[k]:{running:n}};for(let t of e.seats)a[l[t.seat]]={now:t.now,waiting:t.decisionsWaiting};return a}((0,d.g)(Z.seats,Z.runs),Z.runsUnreadable):void 0,seenAt:null!=(v=null==K?void 0:K.seenAt)?v:{},now:U,state:null!=(g=null==K?void 0:K.state)?g:"loading"})})]})}},81969:(e,t,l)=>{l.d(t,{t:()=>u});let n=/\brun-([0-9a-f]{8})-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}\b/gi,a=/(?:\/(?:Users|home|private)\/[\w.%@+~/-]+|\b[A-Za-z]:\\(?:[^\\\s,;<>"']+\\)*[^\\\s,;<>"']+)/g,r=/\b[A-Z0-9._%+-]+@[A-Z0-9.-]+\.[A-Z]{2,}\b/gi,s=RegExp("(?<![A-Za-z0-9_-])(?:[A-Za-z0-9_]{40,}|(?:sk|ghp|gho|ghs|github_pat|xox[abpr])[-_][A-Za-z0-9_-]{20,})(?![A-Za-z0-9_-])","g"),i=/\b(?:OP|MK|TC|UX)\b/g,o=/\bmsb(\d+)\b/gi,d=/(?:\u{1F451}|🪑|🅞|🅜|🅣|🅤|🅢|🅕)\uFE0F?/gu,c={OP:"COO",MK:"CMO",TC:"CTO",UX:"CXO"};function u(e){let t,l=e;do t=l,l=l.replace(n,(e,t)=>"run-".concat(t.slice(0,6))).replace(a,"").replace(r,"").replace(d,"").replace(s,"").replace(i,e=>c[e]).replace(o,(e,t)=>"remote-".concat(t));while(l!==t&&function(e){return[n,a,r,s,i,d,o].flatMap(t=>[...e.matchAll(t)].map(e=>e[0]))}(l).length>0);return l}}}]);
|
|
1
|
+
"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[2489],{29325:(e,t,l)=>{l.d(t,{u:()=>n});function n(e,t){if(!e.enabled||"off"===e.scheduleState)return"off";if("failed"===e.lastStatus||"error"===e.lastStatus||"failure"===e.lastStatus||"abandoned"===e.lastStatus||"expired"===e.lastStatus)return"failed";if("stale"===e.scheduleState)return"late";let l=null===e.lastRunAt?NaN:Date.parse(e.lastRunAt);if(void 0!==e.secondDueAt){let n=null===e.secondDueAt?NaN:Date.parse(e.secondDueAt);return Number.isFinite(l)&&Number.isFinite(t)&&Number.isFinite(n)&&n>l&&t>n?"late":"alive"}return Number.isFinite(t)&&Number.isFinite(l)&&null!==e.intervalMs&&Number.isFinite(e.intervalMs)&&e.intervalMs>0&&t-l>2*e.intervalMs?"late":"alive"}},40385:(e,t,l)=>{l.d(t,{g:()=>i,q:()=>s});var n=l(81969);let a=[{id:"OP",seat:"COO"},{id:"MK",seat:"CMO"},{id:"TC",seat:"CTO"},{id:"UX",seat:"CXO"}];function r(e){return(0,n.t)(e.replace(/\s+/g," ")).trim()}function s(e){var t;let l=e.split("\n"),n=(e,t)=>{let l=e.trim();return t&&(l=(l=l.replace(/^\*\*\[[^\]]+\]\*\*\s*/,"")).replace(/^(?:📌\S*\s*)?\d{4}-\d{2}-\d{2}\s+\d{1,2}:\d{2}\s*KST\s*/,"")),r(l=(l=(l=(l=(l=(l=l.replace(/^→\s*(?:[A-Z]{1,4}|전원|전체)(?=\s|·|$)(?:\s*·\s*(?:[A-Z]{1,4}|전원|전체)(?=\s|·|$))*\s*(?:·)?\s*/u,"")).replace(/^—\s*/,"")).replace(/^[-*]\s+/,"").replace(/\*\*|`|__/g,"").replace(/^#+\s*/,"").trim()).replace(/^(?:보고|요청|정정|결정|사고|안내)\s*·\s*/,"")).replace(RegExp("^(?:\\p{Extended_Pictographic}\\uFE0F?)+\\s*","u"),"")).replace(/^(?:보고|요청|정정|결정|사고|안내)\s*·\s*/,""))},a=n(null!=(t=l[0])?t:"",!0);if(a)return a;let s=l.slice(1).find(e=>e.trim());return s?n(s,!1):""}function i(e,t){var l;let n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:Date.now();return{seats:a.map(t=>{var l;let{id:n,seat:a}=t,r=null==e?void 0:e.seats.find(e=>e.seat===n);return{seat:a,now:(null==r?void 0:r.now)&&Array.from(s(r.now.text)).slice(0,40).join("")||"못 읽음",landedToday:(null==r?void 0:r.landed)==null?"못 읽음":r.landed.length,blocked:(null==r?void 0:r.blocked)==null?"못 읽음":r.blocked.length,decisionsWaiting:null!=(l=null==r?void 0:r.pendingDecisions)?l:"못 읽음"}}),runs:(null!=(l=null==t?void 0:t.entries)?l:[]).filter(e=>"running"===e.status).sort((e,t)=>{var l,n;return(Date.parse(null!=(l=t.lastActivityTimestamp)?l:"")||0)-(Date.parse(null!=(n=e.lastActivityTimestamp)?n:"")||0)}).slice(0,6).map(e=>{var t;let l=Date.parse(null!=(t=e.lastActivityTimestamp)?t:"");return{id6:function(e){let t=e.replace(/^run-/i,"");return/^[a-z0-9]{6}/i.test(t)&&r(t.slice(0,6))||"못 읽음"}(e.runId),stage:r(e.lastPhase||e.status)||"못 읽음",elapsedSec:Number.isFinite(l)?Math.max(0,Math.floor((n-l)/1e3)):"못 읽음"}})}}},42006:(e,t,l)=>{l.d(t,{QK:()=>s,i6:()=>r,Pz:()=>o,Em:()=>i,Yy:()=>d});var n=l(29325);let a={alive:"살아 있음",late:"늦음",failed:"실패",off:"꺼짐"},r="/v1/schedules?includeOff=1",s="/v1/dashboard/loops";async function i(e,t){var l,i,o,u,c,m,p,f;let[h,b]=await Promise.allSettled([e(r),e(s)]),v="fulfilled"===h.status?null==(l=h.value)?void 0:l.schedules:null,g="fulfilled"===b.status?null==(o=b.value)||null==(i=o.loops)?void 0:i.loops:null;if(!Array.isArray(v)&&!Array.isArray(g))throw Error("loop registries unavailable");if(!Array.isArray(v))throw Error("스케줄 레지스트리 조회 실패");if(!Array.isArray(g))throw Error("루프 레지스트리 조회 실패");let x=d(v,t).map(e=>({...e,id:"schedule:".concat(e.id)}));for(let e of g){let l=e.last?Date.parse(e.last.at):NaN,r=(0,n.u)({enabled:!1!==e.armed,lastRunAt:null!=(m=null==(u=e.last)?void 0:u.at)?m:null,lastStatus:null!=(p=null==(c=e.last)?void 0:c.status.toLowerCase())?p:null,intervalMs:null},t);x.push({id:"loop:".concat(e.name),name:e.label,layer:null!=(f=e.category)?f:"루프",owner:"미지정",mode:null===e.armed?"관측":e.armed?"armed":"off",lastRun:Number.isFinite(l)?e.last.at:null,verdict:"alive"===r?"판정 불가":a[r]})}return x}function o(e,t){let l=arguments.length>2&&void 0!==arguments[2]?arguments[2]:Date.now,n=0,a=!0;return{async refresh(){let r=++n;try{let s=await i(e,l());a&&r===n&&t({rows:s,state:"ready"})}catch(e){a&&r===n&&t({rows:[],state:"error"})}},dispose(){a=!1}}}function d(e,t){return e.map(e=>{var l,r,s,i,o,d,u;let c=e.lastRun?Date.parse(e.lastRun.at):NaN,m=(0,n.u)({enabled:"off"!==e.state,lastRunAt:null!=(d=null==(l=e.lastRun)?void 0:l.at)?d:null,lastStatus:(null==(r=e.lastRun)?void 0:r.exit)!=null&&0!==e.lastRun.exit?"failed":(null==(s=e.lastRun)?void 0:s.status)==null||["ok","success","completed"].includes(e.lastRun.status.toLowerCase())?null!=(u=null==(o=e.lastRun)||null==(i=o.status)?void 0:i.toLowerCase())?u:null:"failed",intervalMs:e.cron?null:e.intervalMs,...e.cron?{scheduleState:e.state}:{}},t),p=!e.cron&&!(e.intervalMs&&e.intervalMs>0),f="alive"===m&&(!Number.isFinite(c)||p)?"판정 불가":a[m];return{id:e.id,name:e.name,layer:e.domain||e.category||e.source,owner:"미지정",mode:e.runVia||e.source,lastRun:Number.isFinite(c)?e.lastRun.at:null,verdict:f}})}},42489:(e,t,l)=>{l.d(t,{p1:()=>B});var n=l(55539),a=l(46124),r=l(58603),s=l(15151),i=l(43537),o=l(79247),d=l(40385),u=l(42006),c=l(88928),m=l(69280);l(71588);var p=l(29325),f=l(81969);let h={alive:"살아 있음",late:"늦음",failed:"실패",off:"꺼짐"};function b(e,t,l){if("launch"!==e.kind||"string"==typeof e.run&&""!==e.run)return!1;let n=Date.parse(e.at);return Number.isFinite(n)&&l-n>=6e5&&!t.some(t=>"run"===t.kind&&t.ref===e.ref)}let v={OP:"COO",MK:"CMO",TC:"CTO",UX:"CXO"},g=["OP","MK","TC","UX"],x=new Set(["request","decision","report","card","run","hand","launch","move"]),y=/^[a-zA-Z0-9_-]{1,128}$/,w="agent:task-agent",k="hub:runs",j=[{id:"loop:orchestrator",label:"조율"},{id:w,label:"TASK-AGENT"},{id:k,label:"런 묶음"},{id:"loop:release-loop",label:"발행 루프"},{id:"loop:guardian",label:"수호자"}];function N(e){return"string"==typeof e&&y.test(e)}function S(e){var t,l;let n=null!=(t=null==e?void 0:e.get("journey"))?t:null;if(N(n))return n;let a=null!=(l=null==e?void 0:e.get("demo"))?l:null;return N(a)&&"0"!==a&&"1"!==a?a:null}function A(e,t,l){let n=e&&"object"==typeof e&&"edges"in e?e.edges:null;if(!Array.isArray(n))throw Error("간선 조회 실패");return n.filter(e=>{if(!e||"object"!=typeof e||!x.has(e.kind)||"string"!=typeof e.at||"string"!=typeof e.from||"string"!=typeof e.to||"string"!=typeof e.ref)return!1;let n=Date.parse(e.at);return Number.isFinite(n)&&n<=t&&(!l||n>=t-36e5)})}function M(e,t){if(t&&("hand"===t.kind||"launch"===t.kind||"move"===t.kind)&&y.test(t.ref))return"/trace?q=".concat(encodeURIComponent(t.ref));if(e.startsWith("pr:")&&/^\d{1,9}$/.test(e.slice(3))&&!t)return"/trace?q=".concat(encodeURIComponent(e.slice(3)));let l=(null==t?void 0:t.kind)==="run"?t.ref:e;if((null==t?void 0:t.kind)==="card"&&y.test(t.ref))return"/trace?q=".concat(encodeURIComponent(t.ref));if(l.startsWith("loop:")&&y.test(l.slice(5))){let e=l.slice(5);return e.startsWith("run-")?"/trace?level=L2&run=".concat(encodeURIComponent(e)):"/trace?q=".concat(encodeURIComponent(e))}return l.startsWith("schedule:")&&y.test(l.slice(9))?"/trace?q=".concat(encodeURIComponent(l.slice(9))):l.startsWith("card:")&&y.test(l.slice(5))?"/trace?q=".concat(encodeURIComponent(l.slice(5))):(null==t?void 0:t.kind)==="run"&&y.test(l)?"/trace?level=L2&run=".concat(encodeURIComponent(l)):"/trace"}function C(e,t){let l=e=>e.startsWith("surface:")?0:e.startsWith("card:")?1:e.startsWith("loop:")?2:3;return e.filter(e=>"card"===e.kind&&e.ref===t).sort((e,t)=>e.at.localeCompare(t.at)||l(e.from)-l(t.from))}function T(e){return JSON.stringify([e.at,e.kind,e.from,e.to,e.ref])}let R=[{key:"tick",label:"틱 \xb7 넘김"},{key:"agent",label:"TASK-AGENT \xb7 발사"},{key:"run",label:"런"},{key:"pr",label:"PR"},{key:"land",label:"착지 \xb7 green 제안"}];function E(e,t){let l=new Set([t]);for(let n of e)"hand"===n.kind&&void 0!==n.cell&&(n.cell===t||n.cell.startsWith("".concat(t,"-")))&&l.add(n.ref);return l}function O(e,t){let l=arguments.length>2&&void 0!==arguments[2]?arguments[2]:new Set([t]),n=e.ref===t||l.has(e.ref);return"hand"===e.kind?n&&"shadow"!==e.mode?"tick":null:"launch"===e.kind?n?"agent":null:"move"===e.kind?n&&"green-proposal"===e.move?"land":null:"run"===e.kind?e.to.startsWith("pr:")?"pr":e.to.startsWith("loop:")?"run":null:"card"===e.kind&&e.to.startsWith("landed:")?"land":null}function I(e,t){let l=E(e,t),n=e=>R.findIndex(n=>n.key===O(e,t,l));return[...C(e,t),...e.filter(e=>"card"!==e.kind||e.ref!==t).filter(e=>null!==O(e,t,l))].sort((e,t)=>e.at.localeCompare(t.at)||n(e)-n(t))}let D={request:"요청",decision:"결정",report:"보고",card:"카드",run:"런",hand:"넘김",launch:"발사",move:"판단"},U={request:"●",decision:"◆",report:"■",hand:"▲",launch:"★",move:"⬟",card:"◇",run:"▶"};var W=l(18993);let F={"살아 있음":"bg-emerald-500/15 text-emerald-300 ring-emerald-500/30",늦음:"bg-red-500/15 text-red-300 ring-red-500/30",실패:"bg-red-500/15 text-red-300 ring-red-500/30",꺼짐:"bg-slate-700 text-slate-300 ring-slate-500","판정 불가":"bg-slate-700 text-slate-300 ring-slate-500"};function P(e){let{detail:t}=e;return(0,n.jsxs)("div",{"data-near-detail":"",className:"w-[180px] space-y-1 rounded-lg border border-slate-600 bg-[#10243b]/95 p-2 text-left text-[10px] font-normal text-slate-200",children:[null!==t.now&&(0,n.jsxs)("p",{className:"break-words",children:[(0,n.jsx)("span",{className:"text-slate-400",children:"지금 "}),t.now]}),(null!==t.running||null!==t.waiting)&&(0,n.jsxs)("p",{className:"flex gap-2",children:[null!==t.running&&(0,n.jsxs)("span",{children:["도는 런 ",t.running]}),null!==t.waiting&&(0,n.jsxs)("span",{children:["대기 ",t.waiting]})]}),t.recent.length>0?(0,n.jsx)("ol",{"aria-label":"최근 행동",className:"space-y-0.5",children:t.recent.map((e,t)=>(0,n.jsx)("li",{className:"break-words",children:e},t))}):(0,n.jsx)("p",{className:"text-slate-400",children:"최근 행동 없음"})]})}let Z={activity:function(e){let{data:t}=e,l="seat"===t.type||"hub"===t.type;return(0,n.jsxs)("div",{className:"relative flex flex-col items-center gap-1 text-center text-white",children:[(0,n.jsx)(c.h7,{type:"target",position:m.yX.Left,className:"!border-sky-400 !bg-sky-400"}),(0,n.jsx)("div",{className:"flex items-center justify-center rounded-full border-2 border-sky-400 bg-[#173556] px-2 font-bold ".concat(l?"h-[90px] w-[90px] text-lg":"h-[64px] w-[64px] text-xs"),children:(0,n.jsx)("span",{className:"line-clamp-2 break-all",children:(0,f.t)(t.label)})}),t.verdict&&(0,n.jsx)("span",{"data-loop-verdict":t.verdict,className:"rounded-full px-2 py-0.5 text-xs font-semibold ring-1 ".concat(F[t.verdict]),children:t.verdict}),t.detail&&(0,n.jsx)(P,{detail:t.detail}),(0,n.jsx)(c.h7,{type:"source",position:m.yX.Right,className:"!border-sky-400 !bg-sky-400"})]})}},L={packet:function(e){var t,l;let{id:r,sourceX:s,sourceY:i,targetX:o,targetY:d,sourcePosition:u,targetPosition:p,style:f,markerEnd:h,label:b,labelStyle:v,interactionWidth:g,data:x}=e,[y,w,k]=(0,m.Fp)({sourceX:s,sourceY:i,targetX:o,targetY:d,sourcePosition:u,targetPosition:p}),j=(0,a.useRef)(null),N=(0,a.useRef)(null),S=null!=(t=null==x?void 0:x.packet)?t:null,A=null!=(l=null==S?void 0:S.key)?l:null;return(0,a.useEffect)(()=>{if(null!==A)try{var e,t,l,n;null==(t=j.current)||null==(e=t.beginElement)||e.call(t),null==(n=N.current)||null==(l=n.beginElement)||l.call(n)}catch(e){}},[A]),(0,n.jsxs)(n.Fragment,{children:[(0,n.jsx)(c.tE,{id:r,path:y,style:f,markerEnd:h,label:b,labelX:w,labelY:k,labelStyle:v,interactionWidth:g}),S&&(0,n.jsxs)("g",{"data-packet":S.word,"aria-hidden":"true",opacity:0,children:[(0,n.jsx)("text",{textAnchor:"middle",dominantBaseline:"central",fontSize:16,fill:"#e0f2fe",stroke:"#10243b",strokeWidth:.6,children:S.shape}),(0,n.jsx)("animateMotion",{ref:j,begin:"indefinite",dur:"".concat(S.roundTrip?2400:1200,"ms"),path:y,fill:"freeze",...S.roundTrip?{keyPoints:"0;1;0",keyTimes:"0;0.5;1",calcMode:"linear"}:{}}),(0,n.jsx)("animate",{ref:N,attributeName:"opacity",begin:"indefinite",dur:"".concat(S.roundTrip?2400:1200,"ms"),values:"1;1;0",keyTimes:"0;0.85;1",fill:"freeze"})]})]})}},z={done:"border-emerald-500/60 bg-emerald-500/15",failed:"border-red-500/60 bg-red-500/15",current:"border-sky-300 bg-sky-500/20",pending:"border-dashed border-slate-500 bg-slate-800/40"};function K(e){return"hand"===e.kind?e.broken?"broken":"shadow"===e.mode?"shadow":"live":null}function X(e,t,l){if(t)return"".concat(D.launch," \xb7 유령 \xb7 런 원장 없음 ").concat(Math.floor((l-Date.parse(e.at))/6e4),"분");let n=K(e);return"broken"===n?"".concat(D.hand," \xb7 끊김 ✕"):"shadow"===n?"".concat(D.hand," \xb7 그림자"):D[e.kind]}function q(e){let{rows:t,edges:l,seenAt:s,now:i,state:o,seatIds:d,details:u}=e,m=(0,r.useSearchParams)(),p=m.get("card"),h=S(m),[x,w]=(0,a.useState)(1),N=x<.8?"far":"near",[A,P]=(0,a.useState)(!1);(0,a.useEffect)(()=>{var e;if(P(function(){try{return"function"==typeof window.matchMedia&&window.matchMedia("(prefers-reduced-motion: reduce)").matches}catch(e){return!1}}()),"function"!=typeof window.matchMedia)return;let t=window.matchMedia("(prefers-reduced-motion: reduce)"),l=()=>P(t.matches);return null==(e=t.addEventListener)||e.call(t,"change",l),()=>{var e;return null==(e=t.removeEventListener)?void 0:e.call(t,"change",l)}},[]);let q=(0,a.useMemo)(()=>null===h?[]:function(e,t){let l=I(e,t),n=E(e,t),a=0===l.length,r=R.reduce((e,a,r)=>l.some(e=>O(e,t,n)===a.key&&!e.broken)?r:e,-1);return R.map((e,s)=>{let i=l.filter(l=>O(l,t,n)===e.key),o=i.find(e=>!e.broken);return o?{key:e.key,label:e.label,state:"done",edge:o}:0===i.length&&s<r?{key:e.key,label:e.label,state:"done"}:i.length>0?(a=!0,{key:e.key,label:e.label,state:"failed",edge:i[0]}):a?{key:e.key,label:e.label,state:"pending"}:(a=!0,{key:e.key,label:e.label,state:"current"})})}(l,h),[l,h]),_=(0,a.useMemo)(()=>new Set(null===h?[]:I(l,h).map(T)),[l,h]),[$,J]=(0,a.useState)(p);(0,a.useEffect)(()=>{J(p)},[p]);let G=(0,a.useMemo)(()=>[...new Set(l.filter(e=>"card"===e.kind).map(e=>e.ref))].sort(),[l]),V=(0,a.useMemo)(()=>null===$?[]:C(l,$),[l,$]),B=new Set(V.map(T)),H=null!==$?B:null!==h?_:null,Q=e=>{J(e);let t=new URL(window.location.href);null===e?t.searchParams.delete("card"):t.searchParams.set("card",e),window.history.replaceState(window.history.state,"",t.toString())},Y=(0,a.useMemo)(()=>(function(e,t){var l,n;let a=arguments.length>2&&void 0!==arguments[2]?arguments[2]:g,r=new Map;for(let e of a)r.set(e,{id:e,type:"seat",label:null!=(l=v[e])?l:(0,f.t)(e)});for(let e of j)r.set(e.id,{id:e.id,type:"hub",label:e.label});let s=new Set(a),i=new Set;for(let t of e){let e=s.has(t.owner)?t.owner:"미지정",l=t.id,n=(0,f.t)(t.name),a=i.has(n)?"".concat(n," \xb7 ").concat((0,f.t)(t.id)):n;i.add(n);let o=r.get(l);r.set(l,(null==o?void 0:o.type)==="hub"?{...o,owner:e,verdict:t.verdict}:{id:l,type:"loop",label:a,owner:e,verdict:t.verdict})}for(let e of t)for(let t of[e.from,e.to]){if(r.has(t))continue;let[e,l]=t.split(":",2);"loop"===e&&l&&y.test(l)?r.set(t,{id:t,type:"other",label:l.startsWith("run-")?"런 \xb7 ".concat((0,f.t)(l)):"칸 \xb7 ".concat((0,f.t)(l))}):"card"===e||"surface"===e?r.set(t,{id:t,type:"other",label:"card"===e?"카드":"입구 \xb7 ".concat((0,f.t)(null!=l?l:""))}):"agent"===e&&l&&y.test(l)?r.set(t,{id:t,type:"other",label:"에이전트 \xb7 ".concat((0,f.t)(l))}):"pr"===e&&l&&/^\d{1,9}$/.test(l)?r.set(t,{id:t,type:"other",label:"PR #".concat(l)}):("release"===e||"landed"===e)&&l&&y.test(l)?r.set(t,{id:t,type:"other",label:"".concat("release"===e?"발행":"착지"," \xb7 ").concat((0,f.t)(l))}):s.has(t)&&r.set(t,{id:t,type:"seat",label:null!=(n=v[t])?n:(0,f.t)(t)})}return[...r.values()]})(t,l,d),[t,l,d]),ee=(0,a.useMemo)(()=>{let e=Y.filter(e=>"seat"===e.type);return[...e.map(e=>e.id),"미지정"].map((t,l)=>({owner:t,column:l,nodes:[..."미지정"===t?[]:e.filter(e=>e.id===t),...Y.filter(e=>"loop"===e.type&&e.owner===t)]})).filter(e=>e.nodes.length>0)},[Y]),et=new Map(Y.map((e,t)=>[e.id,"node-".concat(t)])),el=e=>{var t,l;return null!=(l=null==(t=Y.find(t=>t.id===e))?void 0:t.label)?l:"알 수 없음"},en=new Set(l.filter(e=>"run"===e.kind&&e.to.startsWith("loop:")).map(e=>e.to)).size,ea=e=>{if("near"!==N)return;let t=function(e,t,l,n,a){var r,s;let i=t.filter(t=>t.from===e||t.to===e).sort((e,t)=>t.at.localeCompare(e.at)).slice(0,5).map(l=>"".concat(void 0!==a&&b(l,t,a)?"발사 \xb7 유령":D[l.kind]," ").concat(l.from===e?"→":"←"," ").concat((0,f.t)(n(l.from===e?l.to:l.from))));return{now:(null==l?void 0:l.now)?(0,f.t)(l.now):null,recent:i,running:null!=(r=null==l?void 0:l.running)?r:null,waiting:null!=(s=null==l?void 0:l.waiting)?s:null}}(e,l,e===k?{running:en,...null==u?void 0:u[e]}:null==u?void 0:u[e],el,i);return null===t.now&&null===t.running&&null===t.waiting&&0===t.recent.length?void 0:t},er=ee.map((e,t)=>ee.slice(0,t).reduce((e,t)=>e+Math.ceil(t.nodes.length/8),0)),es=ee.flatMap((e,t)=>{let{nodes:l}=e;return l.map((e,l)=>({id:et.get(e.id),type:"activity",position:{x:(er[t]+Math.floor(l/8))*220,y:l%8*138},data:{label:e.label,type:e.type,verdict:e.verdict,detail:ea(e.id)}}))});j.forEach((e,t)=>{let l=Y.find(t=>t.id===e.id);l&&es.push({id:et.get(l.id),type:"activity",position:{x:220*t,y:-170},data:{label:l.label,type:l.type,verdict:l.verdict,detail:ea(l.id)}})}),Y.filter(e=>"other"===e.type).forEach((e,t)=>es.push({id:et.get(e.id),type:"activity",position:{x:180*Math.floor(t/8),y:138*Math.max(...ee.map(e=>Math.min(e.nodes.length,8)),1)+40+t%8*138},data:{label:e.label,type:e.type,detail:ea(e.id)}}));let ei=l.filter(e=>et.has(e.from)&&et.has(e.to)).map((e,t)=>{var n;let a=T(e),r=i-(null!=(n=s[a])?n:0),o=r<1500,d=null!==H&&H.has(a),u=null!==H&&!d,c=K(e),m=b(e,l,i),p=X(e,m,i),f=m||A||!(r<2600)?null:{key:a,shape:U[e.kind],word:D[e.kind],roundTrip:function(e,t){let l="request"===e.kind?["report","decision"]:"report"===e.kind||"decision"===e.kind?["request"]:[];return l.length>0&&t.some(t=>l.includes(t.kind)&&t.ref===e.ref&&t.from===e.to&&t.to===e.from)}(e,l)};return{id:"edge-".concat(t),type:"packet",source:et.get(e.from),target:et.get(e.to),label:p,data:{edge:e,packet:f,hand:c},animated:!1,focusable:!0,interactionWidth:24,style:{stroke:m||"broken"===c?"#fca5a5":d||!u&&o?"#7dd3fc":"#7492a8",strokeWidth:d||!u&&o?4:2,opacity:u?.16:d||o?1:"shadow"===c?.35:.55,...m||"broken"===c?{strokeDasharray:"2 7"}:"shadow"===c?{strokeDasharray:"6 5"}:{},transition:"stroke 1.5s ease, stroke-width 1.5s ease, opacity 1.5s ease"},labelStyle:{fill:u?"#7492a8":m||"broken"===c?"#fecaca":d||o?"#e0f2fe":"#a8b7c7",fontSize:12,opacity:u?.4:1}}});return(0,n.jsxs)("section",{"aria-label":"루프 활동 지도",className:"min-w-0 space-y-3",children:[(0,n.jsx)("p",{className:"text-sm text-slate-300",children:"자리(큰 원) \xb7 루프(작은 원) \xb7 최근 60분 실제 사건. 노드나 간선을 누르면 Trace로 이동합니다."}),(0,n.jsx)("p",{className:"text-xs text-slate-400",children:"꾸러미 모양 \xb7 요청 ● 결정 ◆ 보고 ■ 넘김 ▲ 발사 ★ 판단 ⬟ \xb7 넘김 실선 = 실발사 \xb7 점선 = 그림자 \xb7 ✕ = 끊김 \xb7 유령 = 발사 뒤 10분간 같은 ref 런 간선 없음 \xb7 확대하면 노드 안 지금 일이 보입니다."}),null!==h&&(0,n.jsxs)("section",{"aria-label":"데모 여정",className:"rounded-xl border border-sky-500/50 bg-[#173556] p-3",children:[(0,n.jsxs)("h3",{className:"font-semibold",children:["여정 \xb7 ",(0,f.t)(h)]}),"ready"===o&&0===_.size&&(0,n.jsx)("p",{role:"status",className:"mt-1 text-sm text-slate-300",children:"아직 사건 없음 — 틱이 이 카드를 집으면 1단계부터 채워집니다"}),(0,n.jsx)("ol",{className:"mt-2 flex min-w-0 flex-wrap items-stretch gap-2 text-sm",children:q.map((e,t)=>(0,n.jsxs)("li",{"data-journey-state":e.state,className:"flex min-w-0 items-center gap-2 rounded-lg border px-3 py-2 ".concat(z[e.state]),children:[(0,n.jsx)("span",{"aria-hidden":"true",children:W.bq[e.state].mark}),(0,n.jsxs)("span",{className:"min-w-0 break-words",children:[t+1,". ",e.label," \xb7 ",W.bq[e.state].word]}),e.edge&&(0,n.jsx)("time",{className:"text-xs text-slate-300",dateTime:e.edge.at,children:new Date(e.edge.at).toLocaleTimeString("ko-KR",{timeZone:"Asia/Seoul"})})]},e.key))})]}),(0,n.jsxs)("div",{role:"group","aria-label":"데모 카드 선택",className:"flex flex-wrap items-center gap-2 text-sm",children:[(0,n.jsx)("span",{children:"카드 경로"}),G.map(e=>(0,n.jsx)("button",{type:"button","aria-pressed":$===e,onClick:()=>Q(e),className:"min-h-11 rounded-lg border border-slate-500 px-3 py-2 aria-pressed:border-sky-300 aria-pressed:bg-sky-800 focus-visible:outline-2 focus-visible:outline-sky-400",children:(0,f.t)(e)},e)),null!==$&&(0,n.jsx)("button",{type:"button",onClick:()=>Q(null),className:"min-h-11 rounded-lg border border-slate-500 px-3 py-2 focus-visible:outline-2 focus-visible:outline-sky-400",children:"전체 보기"})]}),null!==$&&(0,n.jsxs)("section",{"aria-label":"선택 카드 흐름",className:"rounded-xl border border-sky-500/50 bg-[#173556] p-3",children:[(0,n.jsxs)("h3",{className:"font-semibold",children:["요구 한 줄 → 회신 \xb7 카드 ",(0,f.t)($)]}),"ready"===o&&0===V.length&&(0,n.jsx)("p",{role:"status",children:"이 카드는 아직 흐른 사건이 없음"}),V.length>0&&(0,n.jsx)("ol",{className:"mt-2 space-y-2",children:V.map((e,t)=>{var l,a,r,s;return(0,n.jsxs)("li",{className:"break-words text-sm",children:[t+1,". ",(0,f.t)(null!=(r=null==(l=Y.find(t=>t.id===e.from))?void 0:l.label)?r:"출발")," → ",e.to.startsWith("surface:")?"회신 \xb7 ".concat((0,f.t)(e.to.slice(8))):(0,f.t)(null!=(s=null==(a=Y.find(t=>t.id===e.to))?void 0:a.label)?s:"도착")," \xb7 ",(0,n.jsx)("time",{dateTime:e.at,children:new Date(e.at).toLocaleTimeString("ko-KR",{timeZone:"Asia/Seoul"})})]},"".concat(T(e),"-").concat(t))})})]}),"error"===o&&(0,n.jsx)("p",{role:"alert",className:"text-red-300",children:"지도 원천을 읽지 못했습니다. 이전 지도가 보이면 현재 데이터가 아닙니다. 데몬 연결을 확인하세요."}),"unauthorized"===o&&(0,n.jsx)("p",{role:"alert",className:"text-red-300",children:"지도 원천에 접근 권한이 없습니다 — 토큰으로 다시 붙으세요"}),"loading"===o&&(0,n.jsx)("p",{role:"status",children:"지도를 읽는 중…"}),(0,n.jsx)("div",{className:"h-[440px] min-w-0 w-full overflow-hidden rounded-2xl border border-slate-600 bg-[#10243b]","aria-label":"자리와 루프 관계도",children:(0,n.jsxs)(c.Gc,{nodes:es,edges:ei,nodeTypes:Z,edgeTypes:L,fitView:!0,minZoom:.25,maxZoom:2.5,onInit:e=>w(e.getZoom()),onMove:(e,t)=>w(t.zoom),nodesDraggable:!1,nodesConnectable:!1,edgesReconnectable:!1,deleteKeyCode:null,onNodeClick:(e,t)=>{let l=Y.find(e=>et.get(e.id)===t.id);l&&window.location.assign(M(l.id))},onEdgeClick:(e,t)=>{var l;let n=null==(l=t.data)?void 0:l.edge;n&&window.location.assign(M(n.to,n))},children:[(0,n.jsx)(c.VS,{color:"#355470"}),(0,n.jsx)(c.H2,{showInteractive:!1})]},"loading"===o?"loading":"loaded")}),(0,n.jsx)("div",{"aria-label":"지도 목록",className:"grid gap-4 sm:grid-cols-2 xl:grid-cols-4",children:ee.map(e=>{var t;return(0,n.jsxs)("section",{className:"min-w-0 rounded-xl border border-slate-600 p-3",children:[(0,n.jsx)("h3",{className:"mb-2 font-semibold",children:null!=(t=v[e.owner])?t:(0,f.t)(e.owner)}),(0,n.jsx)("ul",{className:"space-y-2",children:e.nodes.map(e=>(0,n.jsx)("li",{children:(0,n.jsxs)("button",{type:"button",onClick:()=>window.location.assign(M(e.id)),className:"flex w-full min-w-0 items-center gap-2 rounded-lg border border-slate-600 px-2 py-2 text-left text-sm focus-visible:outline-2 focus-visible:outline-sky-400",children:[(0,n.jsx)("span",{"aria-hidden":"true",className:"shrink-0 rounded-full border border-sky-400 bg-[#173556] ".concat("seat"===e.type?"h-8 w-8":"h-5 w-5")}),(0,n.jsx)("span",{className:"min-w-0 break-words",children:(0,f.t)(e.label)}),e.verdict&&(0,n.jsx)("span",{"data-loop-verdict":e.verdict,className:"ml-auto shrink-0 rounded-full px-2 py-0.5 text-xs ring-1 ".concat(F[e.verdict]),children:e.verdict})]})},e.id))})]},e.owner)})}),(0,n.jsx)("ul",{"aria-label":"최근 간선 사건",className:"space-y-2",children:l.map((e,t)=>{var a,r,o,d,u;return(0,n.jsx)("li",{children:(0,n.jsxs)("button",{type:"button",onClick:()=>window.location.assign(M(e.to,e)),className:"block w-full min-w-0 break-words rounded-lg border border-slate-600 px-3 py-2 text-left text-sm focus-visible:outline-2 focus-visible:outline-sky-400 ".concat(null!==$?B.has(T(e))?"border-sky-300 bg-sky-500/30 text-sky-100":"bg-slate-800/30 text-slate-400 opacity-40":i-(null!=(o=s[T(e)])?o:0)<1500?"bg-sky-500/20 text-sky-100 transition-colors duration-[1500ms] motion-reduce:transition-none":"bg-slate-800/50 text-slate-300"),children:[(0,f.t)(null!=(d=null==(a=Y.find(t=>t.id===e.from))?void 0:a.label)?d:"출발")," → ",(0,f.t)(null!=(u=null==(r=Y.find(t=>t.id===e.to))?void 0:r.label)?u:"도착")," \xb7 ",X(e,b(e,l,i),i)," \xb7 ",(0,n.jsx)("time",{dateTime:e.at,children:new Date(e.at).toLocaleTimeString("ko-KR",{timeZone:"Asia/Seoul"})})]})},"edge-".concat(t))})}),"ready"===o&&0===l.length&&(0,n.jsx)("p",{role:"status",className:"text-slate-300",children:"최근 사건이 없습니다."})]})}var _=l(69370);let $=["loop.","task-agent","harness.queue","self-implement.pod"],J={setTimeout:(e,t)=>globalThis.setTimeout(e,t),clearTimeout:e=>globalThis.clearTimeout(e),setInterval:(e,t)=>globalThis.setInterval(e,t),clearInterval:e=>globalThis.clearInterval(e)},G=(0,d.g)(null,null);function V(e){let{view:t,runsUnreadable:l,refreshedAt:a}=e;return(0,n.jsxs)("section",{"aria-label":"루프 에이전트 활동",className:"min-w-0 space-y-6 p-4 text-lg min-[1440px]:text-[22px]",children:[(0,n.jsx)("div",{className:"grid grid-cols-2 gap-3 min-[1440px]:grid-cols-4",children:t.seats.map(e=>(0,n.jsxs)("article",{"aria-label":"".concat(e.seat," 자리"),className:"min-w-0 space-y-3 rounded-2xl border border-border bg-card p-3 min-[1440px]:p-6",children:[(0,n.jsx)("h2",{className:"font-bold",children:e.seat}),(0,n.jsx)("p",{className:"break-words","aria-label":"지금 하는 일",children:e.now}),(0,n.jsxs)("dl",{className:"space-y-1 text-base min-[1440px]:text-[22px]",children:[(0,n.jsxs)("div",{className:"flex flex-wrap justify-between gap-x-2",children:[(0,n.jsx)("dt",{children:"오늘 착지"}),(0,n.jsx)("dd",{children:e.landedToday})]}),(0,n.jsxs)("div",{className:"flex flex-wrap justify-between gap-x-2",children:[(0,n.jsx)("dt",{children:"막힘"}),(0,n.jsx)("dd",{children:e.blocked})]}),(0,n.jsxs)("div",{className:"flex flex-wrap justify-between gap-x-2",children:[(0,n.jsx)("dt",{children:"대표 결정 대기"}),(0,n.jsx)("dd",{children:e.decisionsWaiting})]})]})]},e.seat))}),(0,n.jsxs)("section",{"aria-label":"지금 도는 런",className:"min-w-0 rounded-2xl border border-border bg-card p-4",children:[(0,n.jsx)("h2",{className:"font-semibold",children:"지금 도는 런"}),l?(0,n.jsx)("p",{className:"text-muted-foreground",children:"못 읽음"}):0===t.runs.length?(0,n.jsx)("p",{className:"text-muted-foreground",children:"지금 도는 런이 없습니다"}):(0,n.jsx)("ul",{className:"mt-3 flex flex-wrap gap-3",children:t.runs.map((e,t)=>(0,n.jsxs)("li",{className:"min-w-0 break-words rounded-lg border border-border px-3 py-2",children:["런 ",e.id6," \xb7 ",e.stage," \xb7 경과 ","못 읽음"===e.elapsedSec?e.elapsedSec:"".concat(e.elapsedSec,"초")]},"".concat(e.id6,"-").concat(t)))})]}),(0,n.jsxs)("p",{className:"text-sm text-muted-foreground",children:["마지막 갱신 ",(0,n.jsx)("time",{dateTime:null!=a?a:void 0,children:a?new Date(a).toLocaleString("ko-KR",{timeZone:"Asia/Seoul"}):"못 읽음"})]})]})}function B(){var e,t,l,c,m,b,v,g;let{initialMode:x="activity"}=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},{client:y,config:j}=(0,s.Q)(),[M,C]=(0,a.useState)(null),R=S((0,r.useSearchParams)()),[E,O]=(0,a.useState)(null!==R?"map":x),[I,D]=(0,a.useState)(null),[U,W]=(0,a.useState)(0),F="".concat(j.baseUrl,"\0").concat(j.token),P="".concat(F,"\0").concat(E,"\0").concat(null!=R?R:""),Z=(null==M?void 0:M.source)===F?M:null,L=null!=(t=null==Z||null==(e=Z.seats)?void 0:e.seats.flatMap(e=>{var t,l;return null!=(l=null==(t=e.subSeats)?void 0:t.map(e=>e.id))?l:[]}))?t:[];(0,a.useEffect)(()=>{let e=!0,t=!1,l=(0,o.xX)({baseUrl:j.baseUrl,token:j.token});C({source:F,seats:null,runs:null,runsUnreadable:!0,refreshedAt:null});let n=async()=>{var n;if(!e||t||document.hidden)return;t=!0;let a=new Intl.DateTimeFormat("sv-SE",{timeZone:"Asia/Seoul"}).format(new Date),[r,s]=await Promise.allSettled([(0,i.Nn)(y,a),l.getHarnessRuns()]);if(t=!1,!e)return;let o="fulfilled"===r.status&&"ready"===r.value.kind?r.value.data:null,d="fulfilled"===s.status&&Array.isArray(null==(n=s.value)?void 0:n.entries)?s.value:null;C({source:F,seats:o,runs:d,runsUnreadable:null===d,refreshedAt:o||d?new Date().toISOString():null})};n();let a=window.setInterval(()=>{n()},1e4),r=()=>{document.hidden||n()};return document.addEventListener("visibilitychange",r),()=>{e=!1,window.clearInterval(a),document.removeEventListener("visibilitychange",r)}},[y,j.baseUrl,j.token,F]),(0,a.useEffect)(()=>{if("map"!==E)return;let e=!0,t=!1,l=!1;D(null),W(Date.now());let n=async()=>{if(!e||document.hidden)return;if(t){l=!0;return}t=!0,l=!1;let a=Date.now();try{let[t,l,n]=await Promise.all([(0,u.Em)(e=>y.fetchJson(e),a),y.fetchJson("/v1/schedules?includeOff=1&includeOwners=1"),y.fetchJson(N(R)?"/v1/loops/edges?ref=".concat(encodeURIComponent(R),"&mode=live&limit=500"):"/v1/loops/edges?since=".concat(encodeURIComponent(new Date(a-36e5).toISOString()),"&limit=200"))]),r=l.owners;if(!Array.isArray(r))throw Error("루프 주인 조회 실패");let s=null===R?A(n,a,!0):A(n,a,!1);e&&D(e=>{var l;return{source:P,rows:function(e,t,l){let n=new Map(t.flatMap(e=>e.jobs.map(t=>[t,e.owner]))),a=new Map(t.map(e=>[e.id,e.owner])),r=e.map(e=>{var t;return{...e,owner:null!=(t=e.id.startsWith("schedule:")?n.get(e.id.slice(9)):a.get(e.id.slice(5)))?t:"미지정"}});for(let e of t){var s,i,o,d,u,c,m;if(r.some(t=>t.id==="loop:".concat(e.id)))continue;let t=(0,p.u)({enabled:e.enabled,lastRunAt:null!=(d=null==(s=e.lastRun)?void 0:s.at)?d:null,lastStatus:null!=(u=null==(i=e.lastRun)?void 0:i.status.toLowerCase())?u:null,intervalMs:null},l);r.push({id:"loop:".concat(e.id),name:(0,f.t)(e.title),layer:"그래프",owner:null!=(c=e.owner)?c:"미지정",mode:"등록",lastRun:null!=(m=null==(o=e.lastRun)?void 0:o.at)?m:null,verdict:"alive"!==t||e.lastRun?h[t]:"판정 불가"})}return r}(t,r,a),edges:s,seenAt:(l=(null==e?void 0:e.source)===P?e.seenAt:null,Object.fromEntries(s.map(e=>{var t;let n=T(e);return[n,null!=(t=null==l?void 0:l[n])?t:null===l?a-1500:a]}))),state:"ready"}})}catch(t){if(e){let e=t instanceof o.Iu&&(401===t.status||403===t.status);D(t=>({source:P,rows:e?[]:(null==t?void 0:t.source)===P?t.rows:[],edges:e?[]:(null==t?void 0:t.source)===P?t.edges:[],seenAt:e?{}:(null==t?void 0:t.source)===P?t.seenAt:{},state:e?"unauthorized":"error"}))}}finally{t=!1,l&&e&&n()}};n();let a=function(e,t){var l,n,a,r,s;let i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},o=null!=(l=i.timers)?l:J,d=null!=(n=i.debounceMs)?n:800,u=null!=(a=i.pollMs)?a:5e3,c=!1,m=null,p=null,f=o.setInterval(()=>{c||null!==p||t()},null!=(r=i.safetyMs)?r:3e4),h=()=>{var e;c||null!==p||(p=o.setInterval(()=>{c||t()},u),null==(e=i.onMode)||e.call(i,"poll"))},b=e.logsStreamUrl({category:$.join(",")}),v=()=>{};if(null===b)h();else{let e=!1;v=(0,_.BX)(b,{events:{log:()=>{if(!c){var e;null!==p&&(o.clearInterval(p),p=null,null==(e=i.onMode)||e.call(i,"stream")),null!==m&&o.clearTimeout(m),m=o.setTimeout(()=>{m=null,c||t()},d)}}},onError:h,onConstructError:()=>{e=!0}}),e?h():null==(s=i.onMode)||s.call(i,"stream")}return()=>{c||(c=!0,null!==m&&o.clearTimeout(m),null!==p&&o.clearInterval(p),o.clearInterval(f),m=null,p=null,v())}}(y,()=>{n()}),r=window.setInterval(()=>{document.hidden||W(Date.now())},250),s=()=>{document.hidden||n()};return document.addEventListener("visibilitychange",s),()=>{e=!1,a(),window.clearInterval(r),document.removeEventListener("visibilitychange",s)}},[y,E,P,R]);let z=(null==I?void 0:I.source)===P?I:null;return(0,n.jsxs)("div",{className:"min-w-0",children:[(0,n.jsxs)("div",{role:"group","aria-label":"루프 에이전트 보기",className:"flex gap-2 px-4 pt-4",children:[(0,n.jsx)("button",{type:"button","aria-pressed":"activity"===E,onClick:()=>O("activity"),className:"min-h-11 rounded-lg border border-slate-500 px-4 py-2 aria-pressed:bg-sky-800",children:"현황"}),(0,n.jsx)("button",{type:"button","aria-pressed":"map"===E,onClick:()=>O("map"),className:"min-h-11 rounded-lg border border-slate-500 px-4 py-2 aria-pressed:bg-sky-800",children:"지도"})]}),"activity"===E?(0,n.jsx)(V,{view:Z?(0,d.g)(Z.seats,Z.runs):G,runsUnreadable:null==(l=null==Z?void 0:Z.runsUnreadable)||l,refreshedAt:null!=(c=null==Z?void 0:Z.refreshedAt)?c:null}):(0,n.jsx)("div",{className:"min-w-0 p-4",children:(0,n.jsx)(q,{rows:null!=(m=null==z?void 0:z.rows)?m:[],edges:null!=(b=null==z?void 0:z.edges)?b:[],seatIds:["OP","MK","TC","UX",...L],details:Z?function(e,t){let l={COO:"OP",CMO:"MK",CTO:"TC",CXO:"UX"},n=t?"못 읽음":e.runs.length,a={[w]:{running:n},[k]:{running:n}};for(let t of e.seats)a[l[t.seat]]={now:t.now,waiting:t.decisionsWaiting};return a}((0,d.g)(Z.seats,Z.runs),Z.runsUnreadable):void 0,seenAt:null!=(v=null==z?void 0:z.seenAt)?v:{},now:U,state:null!=(g=null==z?void 0:z.state)?g:"loading"})})]})}},81969:(e,t,l)=>{l.d(t,{t:()=>c});let n=/\brun-([0-9a-f]{8})-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}\b/gi,a=/(?:\/(?:Users|home|private)\/[\w.%@+~/-]+|\b[A-Za-z]:\\(?:[^\\\s,;<>"']+\\)*[^\\\s,;<>"']+)/g,r=/\b[A-Z0-9._%+-]+@[A-Z0-9.-]+\.[A-Z]{2,}\b/gi,s=RegExp("(?<![A-Za-z0-9_-])(?:[A-Za-z0-9_]{40,}|(?:sk|ghp|gho|ghs|github_pat|xox[abpr])[-_][A-Za-z0-9_-]{20,})(?![A-Za-z0-9_-])","g"),i=/\b(?:OP|MK|TC|UX)\b/g,o=/\bmsb(\d+)\b/gi,d=/(?:\u{1F451}|🪑|🅞|🅜|🅣|🅤|🅢|🅕)\uFE0F?/gu,u={OP:"COO",MK:"CMO",TC:"CTO",UX:"CXO"};function c(e){let t,l=e;do t=l,l=l.replace(n,(e,t)=>"run-".concat(t.slice(0,6))).replace(a,"").replace(r,"").replace(d,"").replace(s,"").replace(i,e=>u[e]).replace(o,(e,t)=>"remote-".concat(t));while(l!==t&&function(e){return[n,a,r,s,i,d,o].flatMap(t=>[...e.matchAll(t)].map(e=>e[0]))}(l).length>0);return l}}}]);
|