@baique/pi-web-sky 0.1.39 → 0.1.40
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/.next/BUILD_ID +1 -1
- package/.next/app-path-routes-manifest.json +9 -14
- package/.next/build-manifest.json +3 -3
- package/.next/prerender-manifest.json +3 -3
- package/.next/react-loadable-manifest.json +51 -51
- package/.next/required-server-files.js +1 -1
- package/.next/required-server-files.json +1 -1
- package/.next/routes-manifest.json +3 -45
- package/.next/server/app/_global-error/page.js +2 -2
- package/.next/server/app/_global-error/page_client-reference-manifest.js +1 -1
- package/.next/server/app/_global-error.html +1 -1
- package/.next/server/app/_global-error.rsc +1 -1
- package/.next/server/app/_global-error.segments/_full.segment.rsc +1 -1
- package/.next/server/app/_global-error.segments/_global-error/__PAGE__.segment.rsc +1 -1
- package/.next/server/app/_global-error.segments/_tree.segment.rsc +1 -1
- package/.next/server/app/_not-found/page.js +1 -1
- package/.next/server/app/_not-found/page_client-reference-manifest.js +1 -1
- package/.next/server/app/_not-found.html +1 -1
- package/.next/server/app/_not-found.rsc +3 -3
- package/.next/server/app/_not-found.segments/_full.segment.rsc +3 -3
- package/.next/server/app/_not-found.segments/_not-found/__PAGE__.segment.rsc +3 -3
- package/.next/server/app/_not-found.segments/_tree.segment.rsc +2 -2
- package/.next/server/app/api/agent/[id]/bash-output/route.js +2 -2
- package/.next/server/app/api/agent/[id]/events/route.js +2 -2
- package/.next/server/app/api/agent/[id]/route.js +2 -2
- package/.next/server/app/api/agent/new/route.js +1 -1
- package/.next/server/app/api/agent/new/route.js.nft.json +1 -1
- package/.next/server/app/api/agent/running/route.js +1 -1
- package/.next/server/app/api/app-update/route.js +1 -1
- package/.next/server/app/api/auth/all-providers/route.js +1 -1
- package/.next/server/app/api/auth/api-key/[provider]/route.js +1 -1
- package/.next/server/app/api/auth/login/[provider]/route.js +1 -1
- package/.next/server/app/api/auth/logout/[provider]/route.js +1 -1
- package/.next/server/app/api/auth/providers/route.js +1 -1
- package/.next/server/app/api/boards/[id]/reconcile/route.js +1 -0
- package/.next/server/app/api/boards/[id]/reconcile/route_client-reference-manifest.js +1 -0
- package/.next/server/app/api/boards/[id]/route.js +1 -1
- package/.next/server/app/api/boards/purge-orphans/route.js +1 -1
- package/.next/server/app/api/boards/reorder/route.js +1 -1
- package/.next/server/app/api/boards/route.js +1 -1
- package/.next/server/app/api/cwd/browse/route.js +1 -1
- package/.next/server/app/api/cwd/validate/route.js +2 -2
- package/.next/server/app/api/default-cwd/route.js +2 -2
- package/.next/server/app/api/file-index/route.js +2 -2
- package/.next/server/app/api/files/[...path]/route.js +3 -3
- package/.next/server/app/api/files/[...path]/route.js.nft.json +1 -1
- package/.next/server/app/api/git/diff/route.js +1 -1
- package/.next/server/app/api/git/status/route.js +1 -1
- package/.next/server/app/api/home/route.js +1 -1
- package/.next/server/app/api/mcp/route.js +1 -1
- package/.next/server/app/api/models/route.js +2 -2
- package/.next/server/app/api/models-config/catalog/route.js +1 -1
- package/.next/server/app/api/models-config/discover/route.js +1 -1
- package/.next/server/app/api/models-config/route.js +1 -1
- package/.next/server/app/api/models-config/test/route.js +1 -1
- package/.next/server/app/api/plugins/route.js +2 -2
- package/.next/server/app/api/project-trust/route.js +2 -2
- package/.next/server/app/api/quota/route.js +1 -1
- package/.next/server/app/api/search/route.js +2 -2
- package/.next/server/app/api/sessions/[id]/auto-name/route.js +3 -3
- package/.next/server/app/api/sessions/[id]/context/route.js +2 -2
- package/.next/server/app/api/sessions/[id]/entries/[entryId]/thinking/route.js +2 -2
- package/.next/server/app/api/sessions/[id]/export/route.js +2 -2
- package/.next/server/app/api/sessions/[id]/route.js +1 -1
- package/.next/server/app/api/sessions/[id]/state/route.js +2 -2
- package/.next/server/app/api/sessions/[id]/todos/route.js +2 -2
- package/.next/server/app/api/sessions/route.js +2 -2
- package/.next/server/app/api/skills/check/route.js +1 -1
- package/.next/server/app/api/skills/install/route.js +2 -2
- package/.next/server/app/api/skills/route.js +1 -1
- package/.next/server/app/api/skills/search/route.js +1 -1
- package/.next/server/app/api/skills/update/route.js +1 -1
- package/.next/server/app/api/task-card-questions/[id]/answer/route.js +1 -1
- package/.next/server/app/api/task-card-questions/route.js +1 -1
- package/.next/server/app/api/task-cards/[id]/route.js +1 -1
- package/.next/server/app/api/task-cards/route.js +1 -1
- package/.next/server/app/api/task-scheduler/status/route.js +1 -1
- package/.next/server/app/api/tasks/[id]/board/route.js +1 -1
- package/.next/server/app/api/tasks/[id]/route.js +1 -1
- package/.next/server/app/api/tasks/reorder/route.js +1 -1
- package/.next/server/app/api/tasks/route.js +1 -1
- package/.next/server/app/api/terminal/[id]/events/route.js +2 -2
- package/.next/server/app/api/terminal/[id]/route.js +2 -2
- package/.next/server/app/api/terminal/route.js +2 -2
- package/.next/server/app/api/worktrees/route.js +2 -2
- package/.next/server/app/favicon.ico/route.js +1 -1
- package/.next/server/app/index.html +1 -1
- package/.next/server/app/index.rsc +5 -5
- package/.next/server/app/index.segments/__PAGE__.segment.rsc +5 -5
- package/.next/server/app/index.segments/_full.segment.rsc +5 -5
- package/.next/server/app/index.segments/_tree.segment.rsc +2 -2
- package/.next/server/app/manifest.webmanifest/route.js +2 -2
- package/.next/server/app/page.js +7 -7
- package/.next/server/app/page_client-reference-manifest.js +1 -1
- package/.next/server/app-paths-manifest.json +9 -14
- package/.next/server/chunks/1094.js +2 -2
- package/.next/server/chunks/1601.js +1 -1
- package/.next/server/chunks/1860.js +1 -1
- package/.next/server/chunks/2075.js +1 -1
- package/.next/server/chunks/2169.js +1 -1
- package/.next/server/chunks/2404.js +1 -1
- package/.next/server/chunks/2524.js +1 -0
- package/.next/server/chunks/3012.js +1 -1
- package/.next/server/chunks/{5760.js → 3379.js} +1 -1
- package/.next/server/chunks/3500.js +1 -1
- package/.next/server/chunks/4226.js +5 -2
- package/.next/server/chunks/4267.js +1 -1
- package/.next/server/chunks/4563.js +1 -1
- package/.next/server/chunks/5318.js +1 -1
- package/.next/server/chunks/542.js +3 -44
- package/.next/server/chunks/5794.js +1 -1
- package/.next/server/chunks/6052.js +1 -1
- package/.next/server/chunks/6253.js +1 -1
- package/.next/server/chunks/6288.js +1 -1
- package/.next/server/chunks/6366.js +1 -1
- package/.next/server/chunks/673.js +1 -1
- package/.next/server/chunks/6916.js +2 -2
- package/.next/server/chunks/7128.js +43 -0
- package/.next/server/chunks/7265.js +2 -2
- package/.next/server/chunks/7799.js +1 -1
- package/.next/server/chunks/8106.js +1 -1
- package/.next/server/chunks/8333.js +1 -1
- package/.next/server/chunks/8604.js +1 -1
- package/.next/server/chunks/861.js +1 -0
- package/.next/server/chunks/8713.js +1 -1
- package/.next/server/chunks/8782.js +2 -2
- package/.next/server/chunks/898.js +1 -1
- package/.next/server/chunks/922.js +2 -2
- package/.next/server/chunks/9280.js +6 -6
- package/.next/server/chunks/9510.js +1 -1
- package/.next/server/instrumentation.js +1 -1
- package/.next/server/instrumentation.js.nft.json +1 -1
- package/.next/server/middleware-build-manifest.js +1 -1
- package/.next/server/middleware-react-loadable-manifest.js +1 -1
- package/.next/server/pages/404.html +1 -1
- package/.next/server/pages/500.html +1 -1
- package/.next/server/server-reference-manifest.json +1 -1
- package/.next/static/chunks/{103.23142a67b02246a8.js → 103.6c91a059aa01d92c.js} +2 -2
- package/.next/static/chunks/{1032.12b382a9096ab2a4.js → 1032.9e8f793d46f463f8.js} +1 -1
- package/.next/static/chunks/{1063.775c442bdbeef08b.js → 1063.470df8a037dc8409.js} +1 -1
- package/.next/static/chunks/1a258343.f4fc2c133917ded8.js +2 -0
- package/.next/static/chunks/{1ba63609.b2ae90f43319a29e.js → 1ba63609.569928c7234f832c.js} +1 -1
- package/.next/static/chunks/{2181.ba21239d3ac39f81.js → 2181.b8dda21843ef5e74.js} +1 -1
- package/.next/static/chunks/{2325.23caf22075e51aa5.js → 2325.23e538886331cf64.js} +1 -1
- package/.next/static/chunks/{2356.523277bb8c6bf72a.js → 2356.b7312589c345edec.js} +1 -1
- package/.next/static/chunks/{268.72794ee2773c2060.js → 268.a1d90aca268be18a.js} +1 -1
- package/.next/static/chunks/{2695.6f49435bae1e6f33.js → 2695.5624aa3aae540e87.js} +1 -1
- package/.next/static/chunks/{2703.495a65ed14b2f094.js → 2703.097bc88286733740.js} +1 -1
- package/.next/static/chunks/{2821.934bcf60fbdc28c6.js → 2821.d2392a93d192fe92.js} +1 -1
- package/.next/static/chunks/3308.2cd6f20e6c0f4e92.js +73 -0
- package/.next/static/chunks/{3336.a76f9485fe7cb762.js → 3336.9b1dc9ec3507d64f.js} +1 -1
- package/.next/static/chunks/3546.779d2c7646aa77cc.js +1 -0
- package/.next/static/chunks/{370.8e8f3cf8eb0e29dd.js → 370.cde2a84caa84054f.js} +1 -1
- package/.next/static/chunks/{3716.72bf4c9d7325debd.js → 3716.5bac496cea32ca8f.js} +1 -1
- package/.next/static/chunks/{3995.eca0f5bef1fc3ae5.js → 3995.cd112debcd64c610.js} +1 -1
- package/.next/static/chunks/{4004.74b9bcf5478b1663.js → 4004.a8f79ef62f32aa30.js} +2 -2
- package/.next/static/chunks/{4202.8440832386f023c7.js → 4202.96f5b1beb8b3e3f5.js} +1 -1
- package/.next/static/chunks/{4238.6f102dcbcf2ae339.js → 4238.28efbf9aa0c82d90.js} +1 -1
- package/.next/static/chunks/{4405.7a19458960a1058e.js → 4405.cda46a596a02aef7.js} +1 -1
- package/.next/static/chunks/54a60aa6.5e4421e7afde4de8.js +78 -0
- package/.next/static/chunks/{6121.eb9023b1cbc78ee2.js → 6121.5e650e714b402b6f.js} +1 -1
- package/.next/static/chunks/{6195.1153369f5f8b13a2.js → 6195.1b7f9dc127381bbc.js} +1 -1
- package/.next/static/chunks/6380.d148a8e2c701ad78.js +68 -0
- package/.next/static/chunks/6582.efef0ed269bacae2.js +1 -0
- package/.next/static/chunks/6be7e44c.00d0163f409986f0.js +1 -0
- package/.next/static/chunks/{7331.2add3c4e125a2dba.js → 7331.4afa66d6353c8e07.js} +1 -1
- package/.next/static/chunks/752.f41a9dcb0e6548eb.js +1 -0
- package/.next/static/chunks/{8200.a36b9f8c983c6b9e.js → 8200.350d650649b977eb.js} +1 -1
- package/.next/static/chunks/{8885.cf60cac98bf8b70c.js → 8885.2c060cb45c85547b.js} +1 -1
- package/.next/static/chunks/{918.6a9bbe564e4a2d0f.js → 918.593eb466d35cb8ad.js} +1 -1
- package/.next/static/chunks/{9698.4d09a99b9d99f3e5.js → 9698.758755d0387e0e22.js} +2 -2
- package/.next/static/chunks/97.fb73c551e14b3612.js +2 -0
- package/.next/static/chunks/{993e5495.8797001fcfcf2889.js → 993e5495.12cdfbc3af5c79e9.js} +1 -1
- package/.next/static/chunks/{9974.9a0f79beca65e8c4.js → 9974.5ee982e074ad047e.js} +1 -1
- package/.next/static/chunks/app/_global-error/page-bb8f79f321e26750.js +1 -0
- package/.next/static/chunks/app/api/agent/[id]/bash-output/route-bb8f79f321e26750.js +1 -0
- package/.next/static/chunks/app/api/agent/[id]/events/route-bb8f79f321e26750.js +1 -0
- package/.next/static/chunks/app/api/agent/[id]/route-bb8f79f321e26750.js +1 -0
- package/.next/static/chunks/app/api/agent/new/route-bb8f79f321e26750.js +1 -0
- package/.next/static/chunks/app/api/agent/running/route-bb8f79f321e26750.js +1 -0
- package/.next/static/chunks/app/api/app-update/route-bb8f79f321e26750.js +1 -0
- package/.next/static/chunks/app/api/auth/all-providers/route-bb8f79f321e26750.js +1 -0
- package/.next/static/chunks/app/api/auth/api-key/[provider]/route-bb8f79f321e26750.js +1 -0
- package/.next/static/chunks/app/api/auth/login/[provider]/route-bb8f79f321e26750.js +1 -0
- package/.next/static/chunks/app/api/auth/logout/[provider]/route-bb8f79f321e26750.js +1 -0
- package/.next/static/chunks/app/api/auth/providers/route-bb8f79f321e26750.js +1 -0
- package/.next/static/chunks/app/api/boards/[id]/reconcile/route-bb8f79f321e26750.js +1 -0
- package/.next/static/chunks/app/api/boards/[id]/route-bb8f79f321e26750.js +1 -0
- package/.next/static/chunks/app/api/boards/purge-orphans/route-bb8f79f321e26750.js +1 -0
- package/.next/static/chunks/app/api/boards/reorder/route-bb8f79f321e26750.js +1 -0
- package/.next/static/chunks/app/api/boards/route-bb8f79f321e26750.js +1 -0
- package/.next/static/chunks/app/api/cwd/browse/route-bb8f79f321e26750.js +1 -0
- package/.next/static/chunks/app/api/cwd/validate/route-bb8f79f321e26750.js +1 -0
- package/.next/static/chunks/app/api/default-cwd/route-bb8f79f321e26750.js +1 -0
- package/.next/static/chunks/app/api/file-index/route-bb8f79f321e26750.js +1 -0
- package/.next/static/chunks/app/api/files/[...path]/route-bb8f79f321e26750.js +1 -0
- package/.next/static/chunks/app/api/git/diff/route-bb8f79f321e26750.js +1 -0
- package/.next/static/chunks/app/api/git/status/route-bb8f79f321e26750.js +1 -0
- package/.next/static/chunks/app/api/home/route-bb8f79f321e26750.js +1 -0
- package/.next/static/chunks/app/api/mcp/route-bb8f79f321e26750.js +1 -0
- package/.next/static/chunks/app/api/models/route-bb8f79f321e26750.js +1 -0
- package/.next/static/chunks/app/api/models-config/catalog/route-bb8f79f321e26750.js +1 -0
- package/.next/static/chunks/app/api/models-config/discover/route-bb8f79f321e26750.js +1 -0
- package/.next/static/chunks/app/api/models-config/route-bb8f79f321e26750.js +1 -0
- package/.next/static/chunks/app/api/models-config/test/route-bb8f79f321e26750.js +1 -0
- package/.next/static/chunks/app/api/plugins/route-bb8f79f321e26750.js +1 -0
- package/.next/static/chunks/app/api/project-trust/route-bb8f79f321e26750.js +1 -0
- package/.next/static/chunks/app/api/quota/route-bb8f79f321e26750.js +1 -0
- package/.next/static/chunks/app/api/search/route-bb8f79f321e26750.js +1 -0
- package/.next/static/chunks/app/api/sessions/[id]/auto-name/route-bb8f79f321e26750.js +1 -0
- package/.next/static/chunks/app/api/sessions/[id]/context/route-bb8f79f321e26750.js +1 -0
- package/.next/static/chunks/app/api/sessions/[id]/entries/[entryId]/thinking/route-bb8f79f321e26750.js +1 -0
- package/.next/static/chunks/app/api/sessions/[id]/export/route-bb8f79f321e26750.js +1 -0
- package/.next/static/chunks/app/api/sessions/[id]/route-bb8f79f321e26750.js +1 -0
- package/.next/static/chunks/app/api/sessions/[id]/state/route-bb8f79f321e26750.js +1 -0
- package/.next/static/chunks/app/api/sessions/[id]/todos/route-bb8f79f321e26750.js +1 -0
- package/.next/static/chunks/app/api/sessions/route-bb8f79f321e26750.js +1 -0
- package/.next/static/chunks/app/api/skills/check/route-bb8f79f321e26750.js +1 -0
- package/.next/static/chunks/app/api/skills/install/route-bb8f79f321e26750.js +1 -0
- package/.next/static/chunks/app/api/skills/route-bb8f79f321e26750.js +1 -0
- package/.next/static/chunks/app/api/skills/search/route-bb8f79f321e26750.js +1 -0
- package/.next/static/chunks/app/api/skills/update/route-bb8f79f321e26750.js +1 -0
- package/.next/static/chunks/app/api/task-card-questions/[id]/answer/route-bb8f79f321e26750.js +1 -0
- package/.next/static/chunks/app/api/task-card-questions/route-bb8f79f321e26750.js +1 -0
- package/.next/static/chunks/app/api/task-cards/[id]/route-bb8f79f321e26750.js +1 -0
- package/.next/static/chunks/app/api/task-cards/route-bb8f79f321e26750.js +1 -0
- package/.next/static/chunks/app/api/task-scheduler/status/route-bb8f79f321e26750.js +1 -0
- package/.next/static/chunks/app/api/tasks/[id]/board/route-bb8f79f321e26750.js +1 -0
- package/.next/static/chunks/app/api/tasks/[id]/route-bb8f79f321e26750.js +1 -0
- package/.next/static/chunks/app/api/tasks/reorder/route-bb8f79f321e26750.js +1 -0
- package/.next/static/chunks/app/api/tasks/route-bb8f79f321e26750.js +1 -0
- package/.next/static/chunks/app/api/terminal/[id]/events/route-bb8f79f321e26750.js +1 -0
- package/.next/static/chunks/app/api/terminal/[id]/route-bb8f79f321e26750.js +1 -0
- package/.next/static/chunks/app/api/terminal/route-bb8f79f321e26750.js +1 -0
- package/.next/static/chunks/app/api/worktrees/route-bb8f79f321e26750.js +1 -0
- package/.next/static/chunks/app/{layout-7761e430ed68b347.js → layout-702d3c97d297c42d.js} +1 -1
- package/.next/static/chunks/app/manifest.webmanifest/route-bb8f79f321e26750.js +1 -0
- package/.next/static/chunks/app/page-fd18462c3c937a50.js +89 -0
- package/.next/static/chunks/next/dist/client/components/builtin/app-error-bb8f79f321e26750.js +1 -0
- package/.next/static/chunks/next/dist/client/components/builtin/forbidden-bb8f79f321e26750.js +1 -0
- package/.next/static/chunks/next/dist/client/components/builtin/not-found-bb8f79f321e26750.js +1 -0
- package/.next/static/chunks/next/dist/client/components/builtin/unauthorized-bb8f79f321e26750.js +1 -0
- package/.next/static/chunks/webpack-d17b4dde91b96c63.js +1 -0
- package/.next/static/css/0c7244f7214af81f.css +1 -0
- package/.next/static/css/12456255969ac8de.css +31 -0
- package/.next/trace +43 -49
- package/.next/trace-build +1 -1
- package/.next/types/app/api/boards/[id]/{reconcile-task-edges → reconcile}/route.ts +3 -3
- package/.next/types/routes.d.ts +2 -7
- package/.next/types/validator.ts +3 -48
- package/README.md +6 -9
- package/THIRD_PARTY_NOTICES.md +10 -82
- package/bin/pi-web-sky.js +3 -3
- package/lib/board-reconcile-scheduler.ts +56 -0
- package/lib/board-reconcile.test.mjs +252 -0
- package/lib/board-reconcile.ts +422 -0
- package/lib/board-store.test.mjs +26 -4
- package/lib/board-store.ts +44 -6
- package/lib/i18n/messages/en.ts +1 -1
- package/lib/i18n/messages/zh-CN.ts +1 -1
- package/lib/session-delete.ts +5 -0
- package/lib/sqlite-db.ts +13 -1
- package/lib/task-card-store.ts +26 -1
- package/lib/task-scheduler.test.mjs +79 -0
- package/lib/task-scheduler.ts +195 -21
- package/lib/yjs-room-server.mjs +139 -0
- package/package.json +12 -9
- package/server.mjs +7 -7
- package/.next/server/app/api/boards/[id]/canvas/route.js +0 -1
- package/.next/server/app/api/boards/[id]/canvas/route_client-reference-manifest.js +0 -1
- package/.next/server/app/api/boards/[id]/edges/[eid]/route.js +0 -1
- package/.next/server/app/api/boards/[id]/edges/[eid]/route.js.nft.json +0 -1
- package/.next/server/app/api/boards/[id]/edges/[eid]/route_client-reference-manifest.js +0 -1
- package/.next/server/app/api/boards/[id]/edges/route.js +0 -1
- package/.next/server/app/api/boards/[id]/edges/route.js.nft.json +0 -1
- package/.next/server/app/api/boards/[id]/edges/route_client-reference-manifest.js +0 -1
- package/.next/server/app/api/boards/[id]/nodes/[nid]/route.js +0 -1
- package/.next/server/app/api/boards/[id]/nodes/[nid]/route.js.nft.json +0 -1
- package/.next/server/app/api/boards/[id]/nodes/[nid]/route_client-reference-manifest.js +0 -1
- package/.next/server/app/api/boards/[id]/nodes/route.js +0 -1
- package/.next/server/app/api/boards/[id]/nodes/route.js.nft.json +0 -1
- package/.next/server/app/api/boards/[id]/nodes/route_client-reference-manifest.js +0 -1
- package/.next/server/app/api/boards/[id]/reconcile-task-edges/route.js +0 -1
- package/.next/server/app/api/boards/[id]/reconcile-task-edges/route.js.nft.json +0 -1
- package/.next/server/app/api/boards/[id]/reconcile-task-edges/route_client-reference-manifest.js +0 -1
- package/.next/static/chunks/3308.857c554428b3294e.js +0 -73
- package/.next/static/chunks/333.bf0651c789b2eb33.js +0 -1
- package/.next/static/chunks/5315.dba7515ae6e139ae.js +0 -4
- package/.next/static/chunks/54a60aa6.0e43cde7298ebcb7.js +0 -78
- package/.next/static/chunks/7999.879d5a20e8641752.js +0 -259
- package/.next/static/chunks/app/_global-error/page-d6f52627eddf9119.js +0 -1
- package/.next/static/chunks/app/api/agent/[id]/bash-output/route-d6f52627eddf9119.js +0 -1
- package/.next/static/chunks/app/api/agent/[id]/events/route-d6f52627eddf9119.js +0 -1
- package/.next/static/chunks/app/api/agent/[id]/route-d6f52627eddf9119.js +0 -1
- package/.next/static/chunks/app/api/agent/new/route-d6f52627eddf9119.js +0 -1
- package/.next/static/chunks/app/api/agent/running/route-d6f52627eddf9119.js +0 -1
- package/.next/static/chunks/app/api/app-update/route-d6f52627eddf9119.js +0 -1
- package/.next/static/chunks/app/api/auth/all-providers/route-d6f52627eddf9119.js +0 -1
- package/.next/static/chunks/app/api/auth/api-key/[provider]/route-d6f52627eddf9119.js +0 -1
- package/.next/static/chunks/app/api/auth/login/[provider]/route-d6f52627eddf9119.js +0 -1
- package/.next/static/chunks/app/api/auth/logout/[provider]/route-d6f52627eddf9119.js +0 -1
- package/.next/static/chunks/app/api/auth/providers/route-d6f52627eddf9119.js +0 -1
- package/.next/static/chunks/app/api/boards/[id]/canvas/route-d6f52627eddf9119.js +0 -1
- package/.next/static/chunks/app/api/boards/[id]/edges/[eid]/route-d6f52627eddf9119.js +0 -1
- package/.next/static/chunks/app/api/boards/[id]/edges/route-d6f52627eddf9119.js +0 -1
- package/.next/static/chunks/app/api/boards/[id]/nodes/[nid]/route-d6f52627eddf9119.js +0 -1
- package/.next/static/chunks/app/api/boards/[id]/nodes/route-d6f52627eddf9119.js +0 -1
- package/.next/static/chunks/app/api/boards/[id]/reconcile-task-edges/route-d6f52627eddf9119.js +0 -1
- package/.next/static/chunks/app/api/boards/[id]/route-d6f52627eddf9119.js +0 -1
- package/.next/static/chunks/app/api/boards/purge-orphans/route-d6f52627eddf9119.js +0 -1
- package/.next/static/chunks/app/api/boards/reorder/route-d6f52627eddf9119.js +0 -1
- package/.next/static/chunks/app/api/boards/route-d6f52627eddf9119.js +0 -1
- package/.next/static/chunks/app/api/cwd/browse/route-d6f52627eddf9119.js +0 -1
- package/.next/static/chunks/app/api/cwd/validate/route-d6f52627eddf9119.js +0 -1
- package/.next/static/chunks/app/api/default-cwd/route-d6f52627eddf9119.js +0 -1
- package/.next/static/chunks/app/api/file-index/route-d6f52627eddf9119.js +0 -1
- package/.next/static/chunks/app/api/files/[...path]/route-d6f52627eddf9119.js +0 -1
- package/.next/static/chunks/app/api/git/diff/route-d6f52627eddf9119.js +0 -1
- package/.next/static/chunks/app/api/git/status/route-d6f52627eddf9119.js +0 -1
- package/.next/static/chunks/app/api/home/route-d6f52627eddf9119.js +0 -1
- package/.next/static/chunks/app/api/mcp/route-d6f52627eddf9119.js +0 -1
- package/.next/static/chunks/app/api/models/route-d6f52627eddf9119.js +0 -1
- package/.next/static/chunks/app/api/models-config/catalog/route-d6f52627eddf9119.js +0 -1
- package/.next/static/chunks/app/api/models-config/discover/route-d6f52627eddf9119.js +0 -1
- package/.next/static/chunks/app/api/models-config/route-d6f52627eddf9119.js +0 -1
- package/.next/static/chunks/app/api/models-config/test/route-d6f52627eddf9119.js +0 -1
- package/.next/static/chunks/app/api/plugins/route-d6f52627eddf9119.js +0 -1
- package/.next/static/chunks/app/api/project-trust/route-d6f52627eddf9119.js +0 -1
- package/.next/static/chunks/app/api/quota/route-d6f52627eddf9119.js +0 -1
- package/.next/static/chunks/app/api/search/route-d6f52627eddf9119.js +0 -1
- package/.next/static/chunks/app/api/sessions/[id]/auto-name/route-d6f52627eddf9119.js +0 -1
- package/.next/static/chunks/app/api/sessions/[id]/context/route-d6f52627eddf9119.js +0 -1
- package/.next/static/chunks/app/api/sessions/[id]/entries/[entryId]/thinking/route-d6f52627eddf9119.js +0 -1
- package/.next/static/chunks/app/api/sessions/[id]/export/route-d6f52627eddf9119.js +0 -1
- package/.next/static/chunks/app/api/sessions/[id]/route-d6f52627eddf9119.js +0 -1
- package/.next/static/chunks/app/api/sessions/[id]/state/route-d6f52627eddf9119.js +0 -1
- package/.next/static/chunks/app/api/sessions/[id]/todos/route-d6f52627eddf9119.js +0 -1
- package/.next/static/chunks/app/api/sessions/route-d6f52627eddf9119.js +0 -1
- package/.next/static/chunks/app/api/skills/check/route-d6f52627eddf9119.js +0 -1
- package/.next/static/chunks/app/api/skills/install/route-d6f52627eddf9119.js +0 -1
- package/.next/static/chunks/app/api/skills/route-d6f52627eddf9119.js +0 -1
- package/.next/static/chunks/app/api/skills/search/route-d6f52627eddf9119.js +0 -1
- package/.next/static/chunks/app/api/skills/update/route-d6f52627eddf9119.js +0 -1
- package/.next/static/chunks/app/api/task-card-questions/[id]/answer/route-d6f52627eddf9119.js +0 -1
- package/.next/static/chunks/app/api/task-card-questions/route-d6f52627eddf9119.js +0 -1
- package/.next/static/chunks/app/api/task-cards/[id]/route-d6f52627eddf9119.js +0 -1
- package/.next/static/chunks/app/api/task-cards/route-d6f52627eddf9119.js +0 -1
- package/.next/static/chunks/app/api/task-scheduler/status/route-d6f52627eddf9119.js +0 -1
- package/.next/static/chunks/app/api/tasks/[id]/board/route-d6f52627eddf9119.js +0 -1
- package/.next/static/chunks/app/api/tasks/[id]/route-d6f52627eddf9119.js +0 -1
- package/.next/static/chunks/app/api/tasks/reorder/route-d6f52627eddf9119.js +0 -1
- package/.next/static/chunks/app/api/tasks/route-d6f52627eddf9119.js +0 -1
- package/.next/static/chunks/app/api/terminal/[id]/events/route-d6f52627eddf9119.js +0 -1
- package/.next/static/chunks/app/api/terminal/[id]/route-d6f52627eddf9119.js +0 -1
- package/.next/static/chunks/app/api/terminal/route-d6f52627eddf9119.js +0 -1
- package/.next/static/chunks/app/api/worktrees/route-d6f52627eddf9119.js +0 -1
- package/.next/static/chunks/app/manifest.webmanifest/route-d6f52627eddf9119.js +0 -1
- package/.next/static/chunks/app/page-2c87c41e7f848f45.js +0 -89
- package/.next/static/chunks/e3e7ddb2.a35db430b3564999.js +0 -1
- package/.next/static/chunks/next/dist/client/components/builtin/app-error-d6f52627eddf9119.js +0 -1
- package/.next/static/chunks/next/dist/client/components/builtin/forbidden-d6f52627eddf9119.js +0 -1
- package/.next/static/chunks/next/dist/client/components/builtin/not-found-d6f52627eddf9119.js +0 -1
- package/.next/static/chunks/next/dist/client/components/builtin/unauthorized-d6f52627eddf9119.js +0 -1
- package/.next/static/chunks/webpack-4bbf04891e910713.js +0 -1
- package/.next/static/css/80c818c5781fbadc.css +0 -4
- package/.next/static/css/d3a2b5077b52c727.css +0 -1
- package/.next/types/app/api/boards/[id]/canvas/route.ts +0 -353
- package/.next/types/app/api/boards/[id]/edges/[eid]/route.ts +0 -353
- package/.next/types/app/api/boards/[id]/edges/route.ts +0 -353
- package/.next/types/app/api/boards/[id]/nodes/[nid]/route.ts +0 -353
- package/.next/types/app/api/boards/[id]/nodes/route.ts +0 -353
- package/lib/board-search.test.mjs +0 -110
- package/lib/board-search.ts +0 -63
- package/lib/file-explorer-state.test.mjs +0 -63
- package/lib/file-explorer-state.ts +0 -36
- package/lib/sync-room-server.mjs +0 -137
- /package/.next/server/app/api/boards/[id]/{canvas → reconcile}/route.js.nft.json +0 -0
- /package/.next/static/{IzmOG04jJst1VpUvr_fr5 → 12RFLqhiUZG8Sj49T1KKQ}/_buildManifest.js +0 -0
- /package/.next/static/{IzmOG04jJst1VpUvr_fr5 → 12RFLqhiUZG8Sj49T1KKQ}/_ssgManifest.js +0 -0
|
@@ -32,4 +32,4 @@ ${e}${f}`}async function w(a,b,c){try{return await n(a,["diff","--no-color","--n
|
|
|
32
32
|
body,
|
|
33
33
|
tokenize = 'trigram'
|
|
34
34
|
);
|
|
35
|
-
`),function(a){let b=a.prepare("PRAGMA user_version").get().user_version;for(let c of h)if(!(c.version<=b)){a.exec("BEGIN");try{for(let b of c.statements)try{a.exec(b)}catch(b){let a=b instanceof Error?b.message:String(b);if(!/duplicate column name/i.test(a))throw b}a.exec(`PRAGMA user_version = ${c.version}`),a.exec("COMMIT"),b=c.version}catch(b){throw a.exec("ROLLBACK"),b}}}(a),globalThis.__piWebDb=b,b}let h=[{version:1,name:"pinned columns",statements:["ALTER TABLE tasks ADD COLUMN pinned INTEGER NOT NULL DEFAULT 0;","ALTER TABLE session_meta ADD COLUMN pinned INTEGER NOT NULL DEFAULT 0;"]},{version:2,name:"tasks.sort_order",statements:["ALTER TABLE tasks ADD COLUMN sort_order INTEGER NOT NULL DEFAULT 0;"]},{version:3,name:"session boards",statements:["CREATE TABLE IF NOT EXISTS boards (\n id TEXT PRIMARY KEY,\n project_key TEXT NOT NULL,\n name TEXT NOT NULL,\n is_system INTEGER NOT NULL DEFAULT 0,\n created INTEGER NOT NULL,\n updated INTEGER NOT NULL\n);","CREATE INDEX IF NOT EXISTS idx_boards_project ON boards(project_key);","CREATE TABLE IF NOT EXISTS board_nodes (\n id TEXT PRIMARY KEY,\n board_id TEXT NOT NULL,\n kind TEXT NOT NULL,\n ref_id TEXT,\n x REAL NOT NULL,\n y REAL NOT NULL,\n w REAL NOT NULL DEFAULT 0,\n h REAL NOT NULL DEFAULT 0,\n expanded INTEGER NOT NULL DEFAULT 0,\n props TEXT NOT NULL DEFAULT '{}',\n created INTEGER NOT NULL,\n updated INTEGER NOT NULL\n);","CREATE INDEX IF NOT EXISTS idx_board_nodes_board ON board_nodes(board_id);","CREATE TABLE IF NOT EXISTS board_edges (\n id TEXT PRIMARY KEY,\n board_id TEXT NOT NULL,\n from_id TEXT NOT NULL,\n to_id TEXT NOT NULL,\n label TEXT,\n color TEXT,\n dashed INTEGER NOT NULL DEFAULT 0,\n created INTEGER NOT NULL,\n updated INTEGER NOT NULL\n);","CREATE INDEX IF NOT EXISTS idx_board_edges_board ON board_edges(board_id);","CREATE TABLE IF NOT EXISTS board_view (\n board_id TEXT PRIMARY KEY,\n camera_x REAL NOT NULL DEFAULT 0,\n camera_y REAL NOT NULL DEFAULT 0,\n camera_z REAL NOT NULL DEFAULT 1,\n updated INTEGER NOT NULL\n);"]},{version:4,name:"boards.sort_order",statements:["ALTER TABLE boards ADD COLUMN sort_order INTEGER NOT NULL DEFAULT 0;"]},{version:5,name:"boards.task_id",statements:["ALTER TABLE boards ADD COLUMN task_id TEXT NULL;","CREATE INDEX IF NOT EXISTS idx_boards_task ON boards(task_id);"]},{version:6,name:"boards.task_id unique (防并发重复创建任务看板)",statements:["CREATE UNIQUE INDEX IF NOT EXISTS idx_boards_task_unique ON boards(task_id);"]},{version:7,name:"task cards",statements:["CREATE TABLE IF NOT EXISTS task_cards (\n id TEXT PRIMARY KEY,\n board_id TEXT NOT NULL,\n project_key TEXT NOT NULL,\n number INTEGER NOT NULL,\n name TEXT NOT NULL,\n description TEXT NOT NULL DEFAULT '',\n ready_status TEXT NOT NULL DEFAULT 'draft',\n exec_status TEXT NOT NULL DEFAULT 'not_started',\n priority INTEGER NOT NULL DEFAULT 0,\n due INTEGER,\n attachments TEXT NOT NULL DEFAULT '[]',\n cwd TEXT,\n use_worktree INTEGER NOT NULL DEFAULT 0,\n max_retries INTEGER NOT NULL DEFAULT 3,\n retry_count INTEGER NOT NULL DEFAULT 0,\n session_id TEXT,\n created INTEGER NOT NULL,\n updated INTEGER NOT NULL\n);","CREATE INDEX IF NOT EXISTS idx_task_cards_board ON task_cards(board_id);","CREATE INDEX IF NOT EXISTS idx_task_cards_project ON task_cards(project_key);","CREATE UNIQUE INDEX IF NOT EXISTS idx_task_cards_number ON task_cards(project_key, number);","CREATE INDEX IF NOT EXISTS idx_task_cards_status ON task_cards(ready_status, exec_status);","CREATE TABLE IF NOT EXISTS task_card_links (\n id TEXT PRIMARY KEY,\n card_id TEXT NOT NULL,\n target_card_id TEXT NOT NULL,\n kind TEXT NOT NULL,\n created INTEGER NOT NULL,\n UNIQUE(card_id, target_card_id, kind)\n);","CREATE INDEX IF NOT EXISTS idx_task_links_card ON task_card_links(card_id);","CREATE TABLE IF NOT EXISTS task_card_questions (\n id TEXT PRIMARY KEY,\n card_id TEXT NOT NULL,\n session_id TEXT NOT NULL,\n question TEXT NOT NULL,\n status TEXT NOT NULL DEFAULT 'pending',\n answer TEXT,\n created INTEGER NOT NULL,\n answered INTEGER\n);","CREATE INDEX IF NOT EXISTS idx_task_questions_status ON task_card_questions(status);"]},{version:8,name:"task_cards.dispatch_token (跨进程派发互斥锁)",statements:["ALTER TABLE task_cards ADD COLUMN dispatch_token TEXT NULL;"]}]},78335:()=>{},80547:(a,b,c)=>{"use strict";c.a(a,async(a,d)=>{try{c.d(b,{A$:()=>o,B7:()=>p,Nw:()=>i.Nw,mc:()=>n,uK:()=>l.uK,wz:()=>i.wz});var e=c(29021),f=c(21820),g=c(33873),h=c.n(g),i=c(25252),j=c(82536),k=c(40402),l=c(58864),m=a([k]);async function n(){let a=Date.now(),b=globalThis.__piAllowedRootsCache;if(b&&b.expiresAt>a)return b.roots;let c=await (0,k.listAllSessions)(),d=new Set;for(let a of c)a.cwd&&d.add((0,i.Nw)(a.cwd)),a.projectRoot&&d.add((0,i.Nw)(a.projectRoot));try{for(let a of(0,e.readdirSync)((0,f.homedir)()))/^pi-cwd-\d{8}$/.test(a)&&d.add((0,i.Nw)(h().join((0,f.homedir)(),a)))}catch{}for(let a of(0,i.HM)())d.add(a);return globalThis.__piAllowedRootsCache={roots:d,expiresAt:a+5e3},d}function o(a,b){return(0,j.o)(a,b)}function p(a,b){return(0,j.x)(a,b)}k=(m.then?(await m)():m)[0],d()}catch(a){d(a)}})},82536:(a,b,c)=>{"use strict";c.d(b,{o:()=>h,x:()=>i});var d=c(29021),e=c(33873),f=c.n(e),g=c(58864);function h(a,b){for(let c of b){let b=(0,g.uK)(a)||(0,g.uK)(c),d=b?f().win32:f(),e=b?"\\":f().sep,h=d.resolve(a),i=d.resolve(c),j=b?h.toLowerCase():h,k=b?i.toLowerCase():i,l=k.endsWith(e)?k:k+e;if(j===k||j.startsWith(l))return!0}return!1}function i(a,b){let c;try{c=(0,d.realpathSync)(a)}catch{return!1}let e=new Set;for(let a of b)try{e.add((0,d.realpathSync)(a))}catch{}return h(c,e)}},96487:()=>{}};
|
|
35
|
+
`),function(a){let b=a.prepare("PRAGMA user_version").get().user_version;for(let c of h)if(!(c.version<=b)){a.exec("BEGIN");try{for(let b of c.statements)try{a.exec(b)}catch(b){let a=b instanceof Error?b.message:String(b);if(!/duplicate column name/i.test(a))throw b}a.exec(`PRAGMA user_version = ${c.version}`),a.exec("COMMIT"),b=c.version}catch(b){throw a.exec("ROLLBACK"),b}}}(a),globalThis.__piWebDb=b,b}let h=[{version:1,name:"pinned columns",statements:["ALTER TABLE tasks ADD COLUMN pinned INTEGER NOT NULL DEFAULT 0;","ALTER TABLE session_meta ADD COLUMN pinned INTEGER NOT NULL DEFAULT 0;"]},{version:2,name:"tasks.sort_order",statements:["ALTER TABLE tasks ADD COLUMN sort_order INTEGER NOT NULL DEFAULT 0;"]},{version:3,name:"session boards",statements:["CREATE TABLE IF NOT EXISTS boards (\n id TEXT PRIMARY KEY,\n project_key TEXT NOT NULL,\n name TEXT NOT NULL,\n is_system INTEGER NOT NULL DEFAULT 0,\n created INTEGER NOT NULL,\n updated INTEGER NOT NULL\n);","CREATE INDEX IF NOT EXISTS idx_boards_project ON boards(project_key);","CREATE TABLE IF NOT EXISTS board_nodes (\n id TEXT PRIMARY KEY,\n board_id TEXT NOT NULL,\n kind TEXT NOT NULL,\n ref_id TEXT,\n x REAL NOT NULL,\n y REAL NOT NULL,\n w REAL NOT NULL DEFAULT 0,\n h REAL NOT NULL DEFAULT 0,\n expanded INTEGER NOT NULL DEFAULT 0,\n props TEXT NOT NULL DEFAULT '{}',\n created INTEGER NOT NULL,\n updated INTEGER NOT NULL\n);","CREATE INDEX IF NOT EXISTS idx_board_nodes_board ON board_nodes(board_id);","CREATE TABLE IF NOT EXISTS board_edges (\n id TEXT PRIMARY KEY,\n board_id TEXT NOT NULL,\n from_id TEXT NOT NULL,\n to_id TEXT NOT NULL,\n label TEXT,\n color TEXT,\n dashed INTEGER NOT NULL DEFAULT 0,\n created INTEGER NOT NULL,\n updated INTEGER NOT NULL\n);","CREATE INDEX IF NOT EXISTS idx_board_edges_board ON board_edges(board_id);","CREATE TABLE IF NOT EXISTS board_view (\n board_id TEXT PRIMARY KEY,\n camera_x REAL NOT NULL DEFAULT 0,\n camera_y REAL NOT NULL DEFAULT 0,\n camera_z REAL NOT NULL DEFAULT 1,\n updated INTEGER NOT NULL\n);"]},{version:4,name:"boards.sort_order",statements:["ALTER TABLE boards ADD COLUMN sort_order INTEGER NOT NULL DEFAULT 0;"]},{version:5,name:"boards.task_id",statements:["ALTER TABLE boards ADD COLUMN task_id TEXT NULL;","CREATE INDEX IF NOT EXISTS idx_boards_task ON boards(task_id);"]},{version:6,name:"boards.task_id unique (防并发重复创建任务看板)",statements:["CREATE UNIQUE INDEX IF NOT EXISTS idx_boards_task_unique ON boards(task_id);"]},{version:7,name:"task cards",statements:["CREATE TABLE IF NOT EXISTS task_cards (\n id TEXT PRIMARY KEY,\n board_id TEXT NOT NULL,\n project_key TEXT NOT NULL,\n number INTEGER NOT NULL,\n name TEXT NOT NULL,\n description TEXT NOT NULL DEFAULT '',\n ready_status TEXT NOT NULL DEFAULT 'draft',\n exec_status TEXT NOT NULL DEFAULT 'not_started',\n priority INTEGER NOT NULL DEFAULT 0,\n due INTEGER,\n attachments TEXT NOT NULL DEFAULT '[]',\n cwd TEXT,\n use_worktree INTEGER NOT NULL DEFAULT 0,\n max_retries INTEGER NOT NULL DEFAULT 3,\n retry_count INTEGER NOT NULL DEFAULT 0,\n session_id TEXT,\n created INTEGER NOT NULL,\n updated INTEGER NOT NULL\n);","CREATE INDEX IF NOT EXISTS idx_task_cards_board ON task_cards(board_id);","CREATE INDEX IF NOT EXISTS idx_task_cards_project ON task_cards(project_key);","CREATE UNIQUE INDEX IF NOT EXISTS idx_task_cards_number ON task_cards(project_key, number);","CREATE INDEX IF NOT EXISTS idx_task_cards_status ON task_cards(ready_status, exec_status);","CREATE TABLE IF NOT EXISTS task_card_links (\n id TEXT PRIMARY KEY,\n card_id TEXT NOT NULL,\n target_card_id TEXT NOT NULL,\n kind TEXT NOT NULL,\n created INTEGER NOT NULL,\n UNIQUE(card_id, target_card_id, kind)\n);","CREATE INDEX IF NOT EXISTS idx_task_links_card ON task_card_links(card_id);","CREATE TABLE IF NOT EXISTS task_card_questions (\n id TEXT PRIMARY KEY,\n card_id TEXT NOT NULL,\n session_id TEXT NOT NULL,\n question TEXT NOT NULL,\n status TEXT NOT NULL DEFAULT 'pending',\n answer TEXT,\n created INTEGER NOT NULL,\n answered INTEGER\n);","CREATE INDEX IF NOT EXISTS idx_task_questions_status ON task_card_questions(status);"]},{version:8,name:"task_cards.dispatch_token (跨进程派发互斥锁)",statements:["ALTER TABLE task_cards ADD COLUMN dispatch_token TEXT NULL;"]},{version:9,name:"task_cards.owner + heartbeat (状态判定实例归属)",statements:["ALTER TABLE task_cards ADD COLUMN owner TEXT NULL;","ALTER TABLE task_cards ADD COLUMN heartbeat INTEGER NOT NULL DEFAULT 0;"]}]},78335:()=>{},80547:(a,b,c)=>{"use strict";c.a(a,async(a,d)=>{try{c.d(b,{A$:()=>o,B7:()=>p,Nw:()=>i.Nw,mc:()=>n,uK:()=>l.uK,wz:()=>i.wz});var e=c(29021),f=c(21820),g=c(33873),h=c.n(g),i=c(25252),j=c(82536),k=c(40402),l=c(58864),m=a([k]);async function n(){let a=Date.now(),b=globalThis.__piAllowedRootsCache;if(b&&b.expiresAt>a)return b.roots;let c=await (0,k.listAllSessions)(),d=new Set;for(let a of c)a.cwd&&d.add((0,i.Nw)(a.cwd)),a.projectRoot&&d.add((0,i.Nw)(a.projectRoot));try{for(let a of(0,e.readdirSync)((0,f.homedir)()))/^pi-cwd-\d{8}$/.test(a)&&d.add((0,i.Nw)(h().join((0,f.homedir)(),a)))}catch{}for(let a of(0,i.HM)())d.add(a);return globalThis.__piAllowedRootsCache={roots:d,expiresAt:a+5e3},d}function o(a,b){return(0,j.o)(a,b)}function p(a,b){return(0,j.x)(a,b)}k=(m.then?(await m)():m)[0],d()}catch(a){d(a)}})},82536:(a,b,c)=>{"use strict";c.d(b,{o:()=>h,x:()=>i});var d=c(29021),e=c(33873),f=c.n(e),g=c(58864);function h(a,b){for(let c of b){let b=(0,g.uK)(a)||(0,g.uK)(c),d=b?f().win32:f(),e=b?"\\":f().sep,h=d.resolve(a),i=d.resolve(c),j=b?h.toLowerCase():h,k=b?i.toLowerCase():i,l=k.endsWith(e)?k:k+e;if(j===k||j.startsWith(l))return!0}return!1}function i(a,b){let c;try{c=(0,d.realpathSync)(a)}catch{return!1}let e=new Set;for(let a of b)try{e.add((0,d.realpathSync)(a))}catch{}return h(c,e)}},96487:()=>{}};
|
|
@@ -12,7 +12,7 @@
|
|
|
12
12
|
stroke: revert;
|
|
13
13
|
stroke-width: revert;
|
|
14
14
|
}
|
|
15
|
-
`,"getIconStyles")},36052:(a,b,c)=>{c.d(b,{diagram:()=>bq});var d=c(23464),e=c(7423),f=c(69819),g=c(59343);c(73669);var h=c(64922),i=c(45313),j=c(58715),k=c(95097),l=c(11732),m=c(18847),n=c(32112),o=c(22729);function p(a,b){for(let c in b)Object.hasOwn(b,c)&&(a[c]=b[c])}var q=c(75899),r=c(14120),s=c(69085),t=c(74367),u=function(){var a=(0,k.K)(function(a,b,c,d){for(c=c||{},d=a.length;d--;c[a[d]]=b);return c},"o"),b=[1,15],c=[1,7],d=[1,13],e=[1,14],f=[1,19],g=[1,16],h=[1,17],i=[1,18],j=[8,30],l=[8,10,21,28,29,30,31,39,43,46],m=[1,23],n=[1,24],o=[8,10,15,16,21,28,29,30,31,39,43,46],p=[8,10,15,16,21,27,28,29,30,31,39,43,46],q=[1,49],r={trace:(0,k.K)(function(){},"trace"),yy:{},symbols_:{error:2,spaceLines:3,SPACELINE:4,NL:5,separator:6,SPACE:7,EOF:8,start:9,BLOCK_DIAGRAM_KEY:10,document:11,stop:12,statement:13,link:14,LINK:15,START_LINK:16,LINK_LABEL:17,STR:18,nodeStatement:19,columnsStatement:20,SPACE_BLOCK:21,blockStatement:22,classDefStatement:23,cssClassStatement:24,styleStatement:25,node:26,SIZE:27,COLUMNS:28,"id-block":29,end:30,NODE_ID:31,nodeShapeNLabel:32,dirList:33,DIR:34,NODE_DSTART:35,NODE_DEND:36,BLOCK_ARROW_START:37,BLOCK_ARROW_END:38,classDef:39,CLASSDEF_ID:40,CLASSDEF_STYLEOPTS:41,DEFAULT:42,class:43,CLASSENTITY_IDS:44,STYLECLASS:45,style:46,STYLE_ENTITY_IDS:47,STYLE_DEFINITION_DATA:48,$accept:0,$end:1},terminals_:{2:"error",4:"SPACELINE",5:"NL",7:"SPACE",8:"EOF",10:"BLOCK_DIAGRAM_KEY",15:"LINK",16:"START_LINK",17:"LINK_LABEL",18:"STR",21:"SPACE_BLOCK",27:"SIZE",28:"COLUMNS",29:"id-block",30:"end",31:"NODE_ID",34:"DIR",35:"NODE_DSTART",36:"NODE_DEND",37:"BLOCK_ARROW_START",38:"BLOCK_ARROW_END",39:"classDef",40:"CLASSDEF_ID",41:"CLASSDEF_STYLEOPTS",42:"DEFAULT",43:"class",44:"CLASSENTITY_IDS",45:"STYLECLASS",46:"style",47:"STYLE_ENTITY_IDS",48:"STYLE_DEFINITION_DATA"},productions_:[0,[3,1],[3,2],[3,2],[6,1],[6,1],[6,1],[9,3],[12,1],[12,1],[12,2],[12,2],[11,1],[11,2],[14,1],[14,4],[13,1],[13,1],[13,1],[13,1],[13,1],[13,1],[13,1],[19,3],[19,2],[19,1],[20,1],[22,4],[22,3],[26,1],[26,2],[33,1],[33,2],[32,3],[32,4],[23,3],[23,3],[24,3],[25,3]],performAction:(0,k.K)(function(a,b,c,d,e,f,g){var h=f.length-1;switch(e){case 4:d.getLogger().debug("Rule: separator (NL) ");break;case 5:d.getLogger().debug("Rule: separator (Space) ");break;case 6:d.getLogger().debug("Rule: separator (EOF) ");break;case 7:d.getLogger().debug("Rule: hierarchy: ",f[h-1]),d.setHierarchy(f[h-1]);break;case 8:d.getLogger().debug("Stop NL ");break;case 9:d.getLogger().debug("Stop EOF ");break;case 10:d.getLogger().debug("Stop NL2 ");break;case 11:d.getLogger().debug("Stop EOF2 ");break;case 12:d.getLogger().debug("Rule: statement: ",f[h]),"number"==typeof f[h].length?this.$=f[h]:this.$=[f[h]];break;case 13:d.getLogger().debug("Rule: statement #2: ",f[h-1]),this.$=[f[h-1]].concat(f[h]);break;case 14:d.getLogger().debug("Rule: link: ",f[h],a),this.$={edgeTypeStr:f[h],label:""};break;case 15:d.getLogger().debug("Rule: LABEL link: ",f[h-3],f[h-1],f[h]),this.$={edgeTypeStr:f[h],label:f[h-1]};break;case 18:let i=parseInt(f[h]),j=d.generateId();this.$={id:j,type:"space",label:"",width:i,children:[]};break;case 23:d.getLogger().debug("Rule: (nodeStatement link node) ",f[h-2],f[h-1],f[h]," typestr: ",f[h-1].edgeTypeStr);let k=d.edgeStrToEdgeData(f[h-1].edgeTypeStr),l=d.edgeStrToEdgeStartData(f[h-1].edgeTypeStr),m=d.edgeStrToThickness(f[h-1].edgeTypeStr),n=d.edgeStrToPattern(f[h-1].edgeTypeStr);this.$=[{id:f[h-2].id,label:f[h-2].label,type:f[h-2].type,directions:f[h-2].directions},{id:f[h-2].id+"-"+f[h].id,start:f[h-2].id,end:f[h].id,label:f[h-1].label,type:"edge",thickness:m,pattern:n,directions:f[h].directions,arrowTypeEnd:k,arrowTypeStart:l},{id:f[h].id,label:f[h].label,type:d.typeStr2Type(f[h].typeStr),directions:f[h].directions}];break;case 24:d.getLogger().debug("Rule: nodeStatement (abc88 node size) ",f[h-1],f[h]),this.$={id:f[h-1].id,label:f[h-1].label,type:d.typeStr2Type(f[h-1].typeStr),directions:f[h-1].directions,widthInColumns:parseInt(f[h],10)};break;case 25:d.getLogger().debug("Rule: nodeStatement (node) ",f[h]),this.$={id:f[h].id,label:f[h].label,type:d.typeStr2Type(f[h].typeStr),directions:f[h].directions,widthInColumns:1};break;case 26:d.getLogger().debug("APA123",this?this:"na"),d.getLogger().debug("COLUMNS: ",f[h]),this.$={type:"column-setting",columns:"auto"===f[h]?-1:parseInt(f[h])};break;case 27:d.getLogger().debug("Rule: id-block statement : ",f[h-2],f[h-1]),d.generateId(),this.$={...f[h-2],type:"composite",children:f[h-1]};break;case 28:d.getLogger().debug("Rule: blockStatement : ",f[h-2],f[h-1],f[h]);let o=d.generateId();this.$={id:o,type:"composite",label:"",children:f[h-1]};break;case 29:d.getLogger().debug("Rule: node (NODE_ID separator): ",f[h]),this.$={id:f[h]};break;case 30:d.getLogger().debug("Rule: node (NODE_ID nodeShapeNLabel separator): ",f[h-1],f[h]),this.$={id:f[h-1],label:f[h].label,typeStr:f[h].typeStr,directions:f[h].directions};break;case 31:d.getLogger().debug("Rule: dirList: ",f[h]),this.$=[f[h]];break;case 32:d.getLogger().debug("Rule: dirList: ",f[h-1],f[h]),this.$=[f[h-1]].concat(f[h]);break;case 33:d.getLogger().debug("Rule: nodeShapeNLabel: ",f[h-2],f[h-1],f[h]),this.$={typeStr:f[h-2]+f[h],label:f[h-1]};break;case 34:d.getLogger().debug("Rule: BLOCK_ARROW nodeShapeNLabel: ",f[h-3],f[h-2]," #3:",f[h-1],f[h]),this.$={typeStr:f[h-3]+f[h],label:f[h-2],directions:f[h-1]};break;case 35:case 36:this.$={type:"classDef",id:f[h-1].trim(),css:f[h].trim()};break;case 37:this.$={type:"applyClass",id:f[h-1].trim(),styleClass:f[h].trim()};break;case 38:this.$={type:"applyStyles",id:f[h-1].trim(),stylesStr:f[h].trim()}}},"anonymous"),table:[{9:1,10:[1,2]},{1:[3]},{10:b,11:3,13:4,19:5,20:6,21:c,22:8,23:9,24:10,25:11,26:12,28:d,29:e,31:f,39:g,43:h,46:i},{8:[1,20]},a(j,[2,12],{13:4,19:5,20:6,22:8,23:9,24:10,25:11,26:12,11:21,10:b,21:c,28:d,29:e,31:f,39:g,43:h,46:i}),a(l,[2,16],{14:22,15:m,16:n}),a(l,[2,17]),a(l,[2,18]),a(l,[2,19]),a(l,[2,20]),a(l,[2,21]),a(l,[2,22]),a(o,[2,25],{27:[1,25]}),a(l,[2,26]),{19:26,26:12,31:f},{10:b,11:27,13:4,19:5,20:6,21:c,22:8,23:9,24:10,25:11,26:12,28:d,29:e,31:f,39:g,43:h,46:i},{40:[1,28],42:[1,29]},{44:[1,30]},{47:[1,31]},a(p,[2,29],{32:32,35:[1,33],37:[1,34]}),{1:[2,7]},a(j,[2,13]),{26:35,31:f},{31:[2,14]},{17:[1,36]},a(o,[2,24]),{10:b,11:37,13:4,14:22,15:m,16:n,19:5,20:6,21:c,22:8,23:9,24:10,25:11,26:12,28:d,29:e,31:f,39:g,43:h,46:i},{30:[1,38]},{41:[1,39]},{41:[1,40]},{45:[1,41]},{48:[1,42]},a(p,[2,30]),{18:[1,43]},{18:[1,44]},a(o,[2,23]),{18:[1,45]},{30:[1,46]},a(l,[2,28]),a(l,[2,35]),a(l,[2,36]),a(l,[2,37]),a(l,[2,38]),{36:[1,47]},{33:48,34:q},{15:[1,50]},a(l,[2,27]),a(p,[2,33]),{38:[1,51]},{33:52,34:q,38:[2,31]},{31:[2,15]},a(p,[2,34]),{38:[2,32]}],defaultActions:{20:[2,7],23:[2,14],50:[2,15],52:[2,32]},parseError:(0,k.K)(function(a,b){if(b.recoverable)this.trace(a);else{var c=Error(a);throw c.hash=b,c}},"parseError"),parse:(0,k.K)(function(a){var b=this,c=[0],d=[],e=[null],f=[],g=this.table,h="",i=0,j=0,l=0,m=f.slice.call(arguments,1),n=Object.create(this.lexer),o={};for(var p in this.yy)Object.prototype.hasOwnProperty.call(this.yy,p)&&(o[p]=this.yy[p]);n.setInput(a,o),o.lexer=n,o.parser=this,void 0===n.yylloc&&(n.yylloc={});var q=n.yylloc;f.push(q);var r=n.options&&n.options.ranges;function s(){var a;return"number"!=typeof(a=d.pop()||n.lex()||1)&&(a instanceof Array&&(a=(d=a).pop()),a=b.symbols_[a]||a),a}"function"==typeof o.parseError?this.parseError=o.parseError:this.parseError=Object.getPrototypeOf(this).parseError,(0,k.K)(function(a){c.length=c.length-2*a,e.length=e.length-a,f.length=f.length-a},"popStack"),(0,k.K)(s,"lex");for(var t,u,v,w,x,y,z,A,B,C={};;){if(v=c[c.length-1],this.defaultActions[v]?w=this.defaultActions[v]:(null==t&&(t=s()),w=g[v]&&g[v][t]),void 0===w||!w.length||!w[0]){var D="";for(y in B=[],g[v])this.terminals_[y]&&y>2&&B.push("'"+this.terminals_[y]+"'");D=n.showPosition?"Parse error on line "+(i+1)+":\n"+n.showPosition()+"\nExpecting "+B.join(", ")+", got '"+(this.terminals_[t]||t)+"'":"Parse error on line "+(i+1)+": Unexpected "+(1==t?"end of input":"'"+(this.terminals_[t]||t)+"'"),this.parseError(D,{text:n.match,token:this.terminals_[t]||t,line:n.yylineno,loc:q,expected:B})}if(w[0]instanceof Array&&w.length>1)throw Error("Parse Error: multiple actions possible at state: "+v+", token: "+t);switch(w[0]){case 1:c.push(t),e.push(n.yytext),f.push(n.yylloc),c.push(w[1]),t=null,u?(t=u,u=null):(j=n.yyleng,h=n.yytext,i=n.yylineno,q=n.yylloc,l>0&&l--);break;case 2:if(z=this.productions_[w[1]][1],C.$=e[e.length-z],C._$={first_line:f[f.length-(z||1)].first_line,last_line:f[f.length-1].last_line,first_column:f[f.length-(z||1)].first_column,last_column:f[f.length-1].last_column},r&&(C._$.range=[f[f.length-(z||1)].range[0],f[f.length-1].range[1]]),void 0!==(x=this.performAction.apply(C,[h,j,i,o,w[1],e,f].concat(m))))return x;z&&(c=c.slice(0,-1*z*2),e=e.slice(0,-1*z),f=f.slice(0,-1*z)),c.push(this.productions_[w[1]][0]),e.push(C.$),f.push(C._$),A=g[c[c.length-2]][c[c.length-1]],c.push(A);break;case 3:return!0}}return!0},"parse")};function s(){this.yy={}}return r.lexer={EOF:1,parseError:(0,k.K)(function(a,b){if(this.yy.parser)this.yy.parser.parseError(a,b);else throw Error(a)},"parseError"),setInput:(0,k.K)(function(a,b){return this.yy=b||this.yy||{},this._input=a,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,k.K)(function(){var a=this._input[0];return this.yytext+=a,this.yyleng++,this.offset++,this.match+=a,this.matched+=a,a.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),a},"input"),unput:(0,k.K)(function(a){var b=a.length,c=a.split(/(?:\r\n?|\n)/g);this._input=a+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-b),this.offset-=b;var d=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),c.length-1&&(this.yylineno-=c.length-1);var e=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:c?(c.length===d.length?this.yylloc.first_column:0)+d[d.length-c.length].length-c[0].length:this.yylloc.first_column-b},this.options.ranges&&(this.yylloc.range=[e[0],e[0]+this.yyleng-b]),this.yyleng=this.yytext.length,this},"unput"),more:(0,k.K)(function(){return this._more=!0,this},"more"),reject:(0,k.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,k.K)(function(a){this.unput(this.match.slice(a))},"less"),pastInput:(0,k.K)(function(){var a=this.matched.substr(0,this.matched.length-this.match.length);return(a.length>20?"...":"")+a.substr(-20).replace(/\n/g,"")},"pastInput"),upcomingInput:(0,k.K)(function(){var a=this.match;return a.length<20&&(a+=this._input.substr(0,20-a.length)),(a.substr(0,20)+(a.length>20?"...":"")).replace(/\n/g,"")},"upcomingInput"),showPosition:(0,k.K)(function(){var a=this.pastInput(),b=Array(a.length+1).join("-");return a+this.upcomingInput()+"\n"+b+"^"},"showPosition"),test_match:(0,k.K)(function(a,b){var c,d,e;if(this.options.backtrack_lexer&&(e={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&&(e.yylloc.range=this.yylloc.range.slice(0))),(d=a[0].match(/(?:\r\n?|\n).*/g))&&(this.yylineno+=d.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:d?d[d.length-1].length-d[d.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+a[0].length},this.yytext+=a[0],this.match+=a[0],this.matches=a,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(a[0].length),this.matched+=a[0],c=this.performAction.call(this,this.yy,this,b,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),c)return c;if(this._backtrack)for(var f in e)this[f]=e[f];return!1},"test_match"),next:(0,k.K)(function(){if(this.done)return this.EOF;this._input||(this.done=!0),this._more||(this.yytext="",this.match="");for(var a,b,c,d,e=this._currentRules(),f=0;f<e.length;f++)if((c=this._input.match(this.rules[e[f]]))&&(!b||c[0].length>b[0].length)){if(b=c,d=f,this.options.backtrack_lexer){if(!1!==(a=this.test_match(c,e[f])))return a;if(!this._backtrack)return!1;b=!1;continue}if(!this.options.flex)break}return b?!1!==(a=this.test_match(b,e[d]))&&a:""===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,k.K)(function(){var a=this.next();return a||this.lex()},"lex"),begin:(0,k.K)(function(a){this.conditionStack.push(a)},"begin"),popState:(0,k.K)(function(){return this.conditionStack.length-1>0?this.conditionStack.pop():this.conditionStack[0]},"popState"),_currentRules:(0,k.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,k.K)(function(a){return(a=this.conditionStack.length-1-Math.abs(a||0))>=0?this.conditionStack[a]:"INITIAL"},"topState"),pushState:(0,k.K)(function(a){this.begin(a)},"pushState"),stateStackSize:(0,k.K)(function(){return this.conditionStack.length},"stateStackSize"),options:{},performAction:(0,k.K)(function(a,b,c,d){switch(c){case 0:return a.getLogger().debug("Found block-beta"),10;case 1:return a.getLogger().debug("Found id-block"),29;case 2:return a.getLogger().debug("Found block"),10;case 3:a.getLogger().debug(".",b.yytext);break;case 4:a.getLogger().debug("_",b.yytext);break;case 5:return 5;case 6:return b.yytext=-1,28;case 7:return b.yytext=b.yytext.replace(/columns\s+/,""),a.getLogger().debug("COLUMNS (LEX)",b.yytext),28;case 8:case 76:case 77:case 99:this.pushState("md_string");break;case 9:return"MD_STR";case 10:case 34:case 79:this.popState();break;case 11:this.pushState("string");break;case 12:a.getLogger().debug("LEX: POPPING STR:",b.yytext),this.popState();break;case 13:return a.getLogger().debug("LEX: STR end:",b.yytext),"STR";case 14:return b.yytext=b.yytext.replace(/space\:/,""),a.getLogger().debug("SPACE NUM (LEX)",b.yytext),21;case 15:return b.yytext="1",a.getLogger().debug("COLUMNS (LEX)",b.yytext),21;case 16:return 42;case 17:return"LINKSTYLE";case 18:return"INTERPOLATE";case 19:return this.pushState("CLASSDEF"),39;case 20:return this.popState(),this.pushState("CLASSDEFID"),"DEFAULT_CLASSDEF_ID";case 21:return this.popState(),this.pushState("CLASSDEFID"),40;case 22:return this.popState(),41;case 23:return this.pushState("CLASS"),43;case 24:return this.popState(),this.pushState("CLASS_STYLE"),44;case 25:return this.popState(),45;case 26:return this.pushState("STYLE_STMNT"),46;case 27:return this.popState(),this.pushState("STYLE_DEFINITION"),47;case 28:return this.popState(),48;case 29:return this.pushState("acc_title"),"acc_title";case 30:return this.popState(),"acc_title_value";case 31:return this.pushState("acc_descr"),"acc_descr";case 32:return this.popState(),"acc_descr_value";case 33:this.pushState("acc_descr_multiline");break;case 35:return"acc_descr_multiline_value";case 36:return 30;case 37:case 38:case 40:case 41:case 44:return this.popState(),a.getLogger().debug("Lex: (("),"NODE_DEND";case 39:return this.popState(),a.getLogger().debug("Lex: ))"),"NODE_DEND";case 42:return this.popState(),a.getLogger().debug("Lex: (-"),"NODE_DEND";case 43:return this.popState(),a.getLogger().debug("Lex: -)"),"NODE_DEND";case 45:return this.popState(),a.getLogger().debug("Lex: ]]"),"NODE_DEND";case 46:return this.popState(),a.getLogger().debug("Lex: ("),"NODE_DEND";case 47:return this.popState(),a.getLogger().debug("Lex: ])"),"NODE_DEND";case 48:case 49:return this.popState(),a.getLogger().debug("Lex: /]"),"NODE_DEND";case 50:return this.popState(),a.getLogger().debug("Lex: )]"),"NODE_DEND";case 51:return this.popState(),a.getLogger().debug("Lex: )"),"NODE_DEND";case 52:return this.popState(),a.getLogger().debug("Lex: ]>"),"NODE_DEND";case 53:return this.popState(),a.getLogger().debug("Lex: ]"),"NODE_DEND";case 54:return a.getLogger().debug("Lexa: -)"),this.pushState("NODE"),35;case 55:return a.getLogger().debug("Lexa: (-"),this.pushState("NODE"),35;case 56:return a.getLogger().debug("Lexa: ))"),this.pushState("NODE"),35;case 57:case 59:case 60:case 61:case 64:return a.getLogger().debug("Lexa: )"),this.pushState("NODE"),35;case 58:return a.getLogger().debug("Lex: ((("),this.pushState("NODE"),35;case 62:return a.getLogger().debug("Lexc: >"),this.pushState("NODE"),35;case 63:return a.getLogger().debug("Lexa: (["),this.pushState("NODE"),35;case 65:case 66:case 67:case 68:case 69:case 70:case 71:return this.pushState("NODE"),35;case 72:return a.getLogger().debug("Lexa: ["),this.pushState("NODE"),35;case 73:return this.pushState("BLOCK_ARROW"),a.getLogger().debug("LEX ARR START"),37;case 74:return a.getLogger().debug("Lex: NODE_ID",b.yytext),31;case 75:return a.getLogger().debug("Lex: EOF",b.yytext),8;case 78:return"NODE_DESCR";case 80:a.getLogger().debug("Lex: Starting string"),this.pushState("string");break;case 81:a.getLogger().debug("LEX ARR: Starting string"),this.pushState("string");break;case 82:return a.getLogger().debug("LEX: NODE_DESCR:",b.yytext),"NODE_DESCR";case 83:a.getLogger().debug("LEX POPPING"),this.popState();break;case 84:a.getLogger().debug("Lex: =>BAE"),this.pushState("ARROW_DIR");break;case 85:return b.yytext=b.yytext.replace(/^,\s*/,""),a.getLogger().debug("Lex (right): dir:",b.yytext),"DIR";case 86:return b.yytext=b.yytext.replace(/^,\s*/,""),a.getLogger().debug("Lex (left):",b.yytext),"DIR";case 87:return b.yytext=b.yytext.replace(/^,\s*/,""),a.getLogger().debug("Lex (x):",b.yytext),"DIR";case 88:return b.yytext=b.yytext.replace(/^,\s*/,""),a.getLogger().debug("Lex (y):",b.yytext),"DIR";case 89:return b.yytext=b.yytext.replace(/^,\s*/,""),a.getLogger().debug("Lex (up):",b.yytext),"DIR";case 90:return b.yytext=b.yytext.replace(/^,\s*/,""),a.getLogger().debug("Lex (down):",b.yytext),"DIR";case 91:return b.yytext="]>",a.getLogger().debug("Lex (ARROW_DIR end):",b.yytext),this.popState(),this.popState(),"BLOCK_ARROW_END";case 92:return a.getLogger().debug("Lex: LINK","#"+b.yytext+"#"),15;case 93:case 94:case 95:return a.getLogger().debug("Lex: LINK",b.yytext),15;case 96:case 97:case 98:return a.getLogger().debug("Lex: START_LINK",b.yytext),this.pushState("LLABEL"),16;case 100:return a.getLogger().debug("Lex: Starting string"),this.pushState("string"),"LINK_LABEL";case 101:return this.popState(),a.getLogger().debug("Lex: LINK","#"+b.yytext+"#"),15;case 102:case 103:return this.popState(),a.getLogger().debug("Lex: LINK",b.yytext),15;case 104:return a.getLogger().debug("Lex: COLON",b.yytext),b.yytext=b.yytext.slice(1),27}},"anonymous"),rules:[/^(?:block-beta\b)/,/^(?:block:)/,/^(?:block\b)/,/^(?:[\s]+)/,/^(?:[\n]+)/,/^(?:((\u000D\u000A)|(\u000A)))/,/^(?:columns\s+auto\b)/,/^(?:columns\s+[\d]+)/,/^(?:["][`])/,/^(?:[^`"]+)/,/^(?:[`]["])/,/^(?:["])/,/^(?:["])/,/^(?:[^"]*)/,/^(?:space[:]\d+)/,/^(?:space\b)/,/^(?:default\b)/,/^(?:linkStyle\b)/,/^(?:interpolate\b)/,/^(?:classDef\s+)/,/^(?:DEFAULT\s+)/,/^(?:\w+\s+)/,/^(?:[^\n]*)/,/^(?:class\s+)/,/^(?:(\w+)+((,\s*\w+)*))/,/^(?:[^\n]*)/,/^(?:style\s+)/,/^(?:(\w+)+((,\s*\w+)*))/,/^(?:[^\n]*)/,/^(?:accTitle\s*:\s*)/,/^(?:(?!\n||)*[^\n]*)/,/^(?:accDescr\s*:\s*)/,/^(?:(?!\n||)*[^\n]*)/,/^(?:accDescr\s*\{\s*)/,/^(?:[\}])/,/^(?:[^\}]*)/,/^(?:end\b\s*)/,/^(?:\(\(\()/,/^(?:\)\)\))/,/^(?:[\)]\))/,/^(?:\}\})/,/^(?:\})/,/^(?:\(-)/,/^(?:-\))/,/^(?:\(\()/,/^(?:\]\])/,/^(?:\()/,/^(?:\]\))/,/^(?:\\\])/,/^(?:\/\])/,/^(?:\)\])/,/^(?:[\)])/,/^(?:\]>)/,/^(?:[\]])/,/^(?:-\))/,/^(?:\(-)/,/^(?:\)\))/,/^(?:\))/,/^(?:\(\(\()/,/^(?:\(\()/,/^(?:\{\{)/,/^(?:\{)/,/^(?:>)/,/^(?:\(\[)/,/^(?:\()/,/^(?:\[\[)/,/^(?:\[\|)/,/^(?:\[\()/,/^(?:\)\)\))/,/^(?:\[\\)/,/^(?:\[\/)/,/^(?:\[\\)/,/^(?:\[)/,/^(?:<\[)/,/^(?:[^\(\[\n\-\)\{\}\s\<\>:=]+)/,/^(?:$)/,/^(?:["][`])/,/^(?:["][`])/,/^(?:[^`"]+)/,/^(?:[`]["])/,/^(?:["])/,/^(?:["])/,/^(?:[^"]+)/,/^(?:["])/,/^(?:\]>\s*\()/,/^(?:,?\s*right\s*)/,/^(?:,?\s*left\s*)/,/^(?:,?\s*x\s*)/,/^(?:,?\s*y\s*)/,/^(?:,?\s*up\s*)/,/^(?:,?\s*down\s*)/,/^(?:\)\s*)/,/^(?:\s*[xo<]?--+[-xo>]\s*)/,/^(?:\s*[xo<]?==+[=xo>]\s*)/,/^(?:\s*[xo<]?-?\.+-[xo>]?\s*)/,/^(?:\s*~~[\~]+\s*)/,/^(?:\s*[xo<]?--\s*)/,/^(?:\s*[xo<]?==\s*)/,/^(?:\s*[xo<]?-\.\s*)/,/^(?:["][`])/,/^(?:["])/,/^(?:\s*[xo<]?--+[-xo>]\s*)/,/^(?:\s*[xo<]?==+[=xo>]\s*)/,/^(?:\s*[xo<]?-?\.+-[xo>]?\s*)/,/^(?::\d+)/],conditions:{STYLE_DEFINITION:{rules:[28],inclusive:!1},STYLE_STMNT:{rules:[27],inclusive:!1},CLASSDEFID:{rules:[22],inclusive:!1},CLASSDEF:{rules:[20,21],inclusive:!1},CLASS_STYLE:{rules:[25],inclusive:!1},CLASS:{rules:[24],inclusive:!1},LLABEL:{rules:[99,100,101,102,103],inclusive:!1},ARROW_DIR:{rules:[85,86,87,88,89,90,91],inclusive:!1},BLOCK_ARROW:{rules:[76,81,84],inclusive:!1},NODE:{rules:[37,38,39,40,41,42,43,44,45,46,47,48,49,50,51,52,53,77,80],inclusive:!1},md_string:{rules:[9,10,78,79],inclusive:!1},space:{rules:[],inclusive:!1},string:{rules:[12,13,82,83],inclusive:!1},acc_descr_multiline:{rules:[34,35],inclusive:!1},acc_descr:{rules:[32],inclusive:!1},acc_title:{rules:[30],inclusive:!1},INITIAL:{rules:[0,1,2,3,4,5,6,7,8,11,14,15,16,17,18,19,23,26,29,31,33,36,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,92,93,94,95,96,97,98,104],inclusive:!0}}},(0,k.K)(s,"Parser"),s.prototype=r,r.Parser=s,new s}();u.parser=u;var v=new Map,w=[],x=new Map,y="color",z="fill",A=new Map,B="",C=(0,k.K)(a=>i.Y2.sanitizeText(a,(0,i.D7)()),"sanitizeText"),D=(0,k.K)(function(a,b=""){let c=A.get(a);c||(c={id:a,styles:[],textStyles:[]},A.set(a,c)),null!=b&&b.split(",").forEach(a=>{let b=a.replace(/([^;]*);/,"$1").trim();if(RegExp(y).exec(a)){let a=b.replace(z,"bgFill").replace(y,z);c.textStyles.push(a)}c.styles.push(b)})},"addStyleClass"),E=(0,k.K)(function(a,b=""){let c=v.get(a);null!=b&&(c.styles=b.split(","))},"addStyle2Node"),F=(0,k.K)(function(a,b){a.split(",").forEach(function(a){let c=v.get(a);if(void 0===c){let b=a.trim();c={id:b,type:"na",children:[]},v.set(b,c)}c.classes||(c.classes=[]),c.classes.push(b)})},"setCssClass"),G=(0,k.K)((a,b)=>{let c=a.flat(),d=[],e=c.find(a=>a?.type==="column-setting"),f=e?.columns??-1;for(let a of c){if("number"==typeof f&&f>0&&"column-setting"!==a.type&&"number"==typeof a.widthInColumns&&a.widthInColumns>f&&j.R.warn(`Block ${a.id} width ${a.widthInColumns} exceeds configured column width ${f}`),a.label&&(a.label=C(a.label)),"classDef"===a.type){D(a.id,a.css);continue}if("applyClass"===a.type){F(a.id,a?.styleClass??"");continue}if("applyStyles"===a.type){a?.stylesStr&&E(a.id,a?.stylesStr);continue}if("column-setting"===a.type)b.columns=a.columns??-1;else if("edge"===a.type){let b=(x.get(a.id)??0)+1;x.set(a.id,b),a.id=b+"-"+a.id,w.push(a)}else{a.label||("composite"===a.type?a.label="":a.label=a.id);let b=v.get(a.id);if(void 0===b?v.set(a.id,a):("na"!==a.type&&(b.type=a.type),a.label!==a.id&&(b.label=a.label)),a.children&&G(a.children,a),"space"===a.type){let b=a.width??1;for(let c=0;c<b;c++){let b=function(a){if((0,l.s)(a))return a;let b=(0,m.b)(a);if(!function(a){switch((0,m.b)(a)){case n.R_:case n.Uw:case n.cT:case n.iq:case n.$V:case n.vC:case n.ri:case n.ML:case n.XZ:case n.i1:case n._u:case n.pj:case n.kj:case n.GX:case n.Av:case n.NA:case n.OG:case n.VP:case n.Qb:case n.q:case n.x6:case n.ZR:return!0;default:return!1}}(a))return{};if(Array.isArray(a)){let b=Array.from(a);return a.length>0&&"string"==typeof a[0]&&Object.hasOwn(a,"index")&&(b.index=a.index,b.input=a.input),b}if((0,o.i)(a))return new a.constructor(a.buffer,a.byteOffset,a.length);if(b===n.cT)return new ArrayBuffer(a.byteLength);if(b===n.iq){let b=a.buffer,c=a.byteOffset,d=a.byteLength,e=new ArrayBuffer(d),f=new Uint8Array(b,c,d);return new Uint8Array(e).set(f),new DataView(e)}if(b===n.$V||b===n.kj||b===n.OG){let c=new a.constructor(a.valueOf());return b===n.OG?function(a,b){let c=b.valueOf().length;for(let d in b)Object.hasOwn(b,d)&&(Number.isNaN(Number(d))||Number(d)>=c)&&(a[d]=b[d])}(c,a):p(c,a),c}if(b===n.vC)return new Date(Number(a));if(b===n.Av){let b=new RegExp(a.source,a.flags);return b.lastIndex=a.lastIndex,b}if(b===n.VP)return Object(Symbol.prototype.valueOf.call(a));if(b===n.pj){let b=new Map;return a.forEach((a,c)=>{b.set(c,a)}),b}if(b===n.NA){let b=new Set;return a.forEach(a=>{b.add(a)}),b}if(b===n.R_){let b={};return p(b,a),b.length=a.length,b[Symbol.iterator]=a[Symbol.iterator],b}let c={};return function(a,b){let c=Object.getPrototypeOf(b);null!==c&&"function"==typeof b.constructor&&Object.setPrototypeOf(a,c)}(c,a),p(c,a),function(a,b){let c=Object.getOwnPropertySymbols(b);for(let d=0;d<c.length;d++){let e=c[d];Object.prototype.propertyIsEnumerable.call(b,e)&&(a[e]=b[e])}}(c,a),c}(a);b.id=b.id+"-"+c,v.set(b.id,b),d.push(b)}}else void 0===b&&d.push(a)}}b.children=d},"populateBlockDatabase"),H=[],I={id:"root",type:"composite",children:[],columns:-1},J=(0,k.K)(()=>{j.R.debug("Clear called"),(0,i.IU)(),v=new Map([["root",I={id:"root",type:"composite",children:[],columns:-1}]]),H=[],A=new Map,w=[],x=new Map,B=""},"clear");function K(a){switch(j.R.debug("typeStr2Type",a),a){case"[]":return"square";case"()":return j.R.debug("we have a round"),"round";case"(())":return"circle";case">]":return"rect_left_inv_arrow";case"{}":return"diamond";case"{{}}":return"hexagon";case"([])":return"stadium";case"[[]]":return"subroutine";case"[()]":return"cylinder";case"((()))":return"doublecircle";case"[//]":return"lean_right";case"[\\\\]":return"lean_left";case"[/\\]":return"trapezoid";case"[\\/]":return"inv_trapezoid";case"<[]>":return"block_arrow";default:return"na"}}function L(a){return(j.R.debug("typeStr2Type",a),"=="===a)?"thick":"normal"}function M(a){switch(a.trim().slice(-1)){case"x":return"arrow_cross";case"o":return"arrow_circle";case">":return"arrow_point";default:return""}}function N(a){switch(a.trim().charAt(0)){case"x":return"arrow_cross";case"o":return"arrow_circle";case"<":return"arrow_point";default:return"arrow_open"}}function O(a){return a.includes("==")?"thick":"normal"}function P(a){return a.includes(".-")?"dotted":"solid"}(0,k.K)(K,"typeStr2Type"),(0,k.K)(L,"edgeTypeStr2Type"),(0,k.K)(M,"edgeStrToEdgeData"),(0,k.K)(N,"edgeStrToEdgeStartData"),(0,k.K)(O,"edgeStrToThickness"),(0,k.K)(P,"edgeStrToPattern");var Q=0,R=(0,k.K)(()=>(Q++,"id-"+Math.random().toString(36).substr(2,12)+"-"+Q),"generateId"),S=(0,k.K)(a=>{I.children=a,G(a,I),H=I.children},"setHierarchy"),T=(0,k.K)(a=>{let b=v.get(a);return b?b.columns?b.columns:b.children?b.children.length:-1:-1},"getColumns"),U=(0,k.K)(()=>[...v.values()],"getBlocksFlat"),V=(0,k.K)(()=>H||[],"getBlocks"),W=(0,k.K)(()=>w,"getEdges"),X=(0,k.K)(a=>v.get(a),"getBlock"),Y=(0,k.K)(a=>{v.set(a.id,a)},"setBlock"),Z=(0,k.K)(a=>{B=a},"setDiagramId"),$=(0,k.K)(()=>B,"getDiagramId"),_=(0,k.K)(()=>j.R,"getLogger"),aa=(0,k.K)(function(){return A},"getClasses"),ab={getConfig:(0,k.K)(()=>(0,i.zj)().block,"getConfig"),typeStr2Type:K,edgeTypeStr2Type:L,edgeStrToEdgeData:M,edgeStrToEdgeStartData:N,edgeStrToThickness:O,edgeStrToPattern:P,getLogger:_,getBlocksFlat:U,getBlocks:V,getEdges:W,setHierarchy:S,getBlock:X,setBlock:Y,getColumns:T,getClasses:aa,clear:J,generateId:R,setDiagramId:Z,getDiagramId:$},ac=(0,k.K)((a,b)=>{let c=q.A,d=c(a,"r"),e=c(a,"g"),f=c(a,"b");return r.A(d,e,f,b)},"fade"),ad=(0,k.K)(a=>`.label {
|
|
15
|
+
`,"getIconStyles")},36052:(a,b,c)=>{c.d(b,{diagram:()=>bq});var d=c(23464),e=c(7423),f=c(69819),g=c(59343);c(73669);var h=c(64922),i=c(45313),j=c(58715),k=c(95097),l=c(11732),m=c(18847),n=c(32112),o=c(22729);function p(a,b){for(let c in b)Object.hasOwn(b,c)&&(a[c]=b[c])}var q=c(75899),r=c(14120),s=c(92718),t=c(74367),u=function(){var a=(0,k.K)(function(a,b,c,d){for(c=c||{},d=a.length;d--;c[a[d]]=b);return c},"o"),b=[1,15],c=[1,7],d=[1,13],e=[1,14],f=[1,19],g=[1,16],h=[1,17],i=[1,18],j=[8,30],l=[8,10,21,28,29,30,31,39,43,46],m=[1,23],n=[1,24],o=[8,10,15,16,21,28,29,30,31,39,43,46],p=[8,10,15,16,21,27,28,29,30,31,39,43,46],q=[1,49],r={trace:(0,k.K)(function(){},"trace"),yy:{},symbols_:{error:2,spaceLines:3,SPACELINE:4,NL:5,separator:6,SPACE:7,EOF:8,start:9,BLOCK_DIAGRAM_KEY:10,document:11,stop:12,statement:13,link:14,LINK:15,START_LINK:16,LINK_LABEL:17,STR:18,nodeStatement:19,columnsStatement:20,SPACE_BLOCK:21,blockStatement:22,classDefStatement:23,cssClassStatement:24,styleStatement:25,node:26,SIZE:27,COLUMNS:28,"id-block":29,end:30,NODE_ID:31,nodeShapeNLabel:32,dirList:33,DIR:34,NODE_DSTART:35,NODE_DEND:36,BLOCK_ARROW_START:37,BLOCK_ARROW_END:38,classDef:39,CLASSDEF_ID:40,CLASSDEF_STYLEOPTS:41,DEFAULT:42,class:43,CLASSENTITY_IDS:44,STYLECLASS:45,style:46,STYLE_ENTITY_IDS:47,STYLE_DEFINITION_DATA:48,$accept:0,$end:1},terminals_:{2:"error",4:"SPACELINE",5:"NL",7:"SPACE",8:"EOF",10:"BLOCK_DIAGRAM_KEY",15:"LINK",16:"START_LINK",17:"LINK_LABEL",18:"STR",21:"SPACE_BLOCK",27:"SIZE",28:"COLUMNS",29:"id-block",30:"end",31:"NODE_ID",34:"DIR",35:"NODE_DSTART",36:"NODE_DEND",37:"BLOCK_ARROW_START",38:"BLOCK_ARROW_END",39:"classDef",40:"CLASSDEF_ID",41:"CLASSDEF_STYLEOPTS",42:"DEFAULT",43:"class",44:"CLASSENTITY_IDS",45:"STYLECLASS",46:"style",47:"STYLE_ENTITY_IDS",48:"STYLE_DEFINITION_DATA"},productions_:[0,[3,1],[3,2],[3,2],[6,1],[6,1],[6,1],[9,3],[12,1],[12,1],[12,2],[12,2],[11,1],[11,2],[14,1],[14,4],[13,1],[13,1],[13,1],[13,1],[13,1],[13,1],[13,1],[19,3],[19,2],[19,1],[20,1],[22,4],[22,3],[26,1],[26,2],[33,1],[33,2],[32,3],[32,4],[23,3],[23,3],[24,3],[25,3]],performAction:(0,k.K)(function(a,b,c,d,e,f,g){var h=f.length-1;switch(e){case 4:d.getLogger().debug("Rule: separator (NL) ");break;case 5:d.getLogger().debug("Rule: separator (Space) ");break;case 6:d.getLogger().debug("Rule: separator (EOF) ");break;case 7:d.getLogger().debug("Rule: hierarchy: ",f[h-1]),d.setHierarchy(f[h-1]);break;case 8:d.getLogger().debug("Stop NL ");break;case 9:d.getLogger().debug("Stop EOF ");break;case 10:d.getLogger().debug("Stop NL2 ");break;case 11:d.getLogger().debug("Stop EOF2 ");break;case 12:d.getLogger().debug("Rule: statement: ",f[h]),"number"==typeof f[h].length?this.$=f[h]:this.$=[f[h]];break;case 13:d.getLogger().debug("Rule: statement #2: ",f[h-1]),this.$=[f[h-1]].concat(f[h]);break;case 14:d.getLogger().debug("Rule: link: ",f[h],a),this.$={edgeTypeStr:f[h],label:""};break;case 15:d.getLogger().debug("Rule: LABEL link: ",f[h-3],f[h-1],f[h]),this.$={edgeTypeStr:f[h],label:f[h-1]};break;case 18:let i=parseInt(f[h]),j=d.generateId();this.$={id:j,type:"space",label:"",width:i,children:[]};break;case 23:d.getLogger().debug("Rule: (nodeStatement link node) ",f[h-2],f[h-1],f[h]," typestr: ",f[h-1].edgeTypeStr);let k=d.edgeStrToEdgeData(f[h-1].edgeTypeStr),l=d.edgeStrToEdgeStartData(f[h-1].edgeTypeStr),m=d.edgeStrToThickness(f[h-1].edgeTypeStr),n=d.edgeStrToPattern(f[h-1].edgeTypeStr);this.$=[{id:f[h-2].id,label:f[h-2].label,type:f[h-2].type,directions:f[h-2].directions},{id:f[h-2].id+"-"+f[h].id,start:f[h-2].id,end:f[h].id,label:f[h-1].label,type:"edge",thickness:m,pattern:n,directions:f[h].directions,arrowTypeEnd:k,arrowTypeStart:l},{id:f[h].id,label:f[h].label,type:d.typeStr2Type(f[h].typeStr),directions:f[h].directions}];break;case 24:d.getLogger().debug("Rule: nodeStatement (abc88 node size) ",f[h-1],f[h]),this.$={id:f[h-1].id,label:f[h-1].label,type:d.typeStr2Type(f[h-1].typeStr),directions:f[h-1].directions,widthInColumns:parseInt(f[h],10)};break;case 25:d.getLogger().debug("Rule: nodeStatement (node) ",f[h]),this.$={id:f[h].id,label:f[h].label,type:d.typeStr2Type(f[h].typeStr),directions:f[h].directions,widthInColumns:1};break;case 26:d.getLogger().debug("APA123",this?this:"na"),d.getLogger().debug("COLUMNS: ",f[h]),this.$={type:"column-setting",columns:"auto"===f[h]?-1:parseInt(f[h])};break;case 27:d.getLogger().debug("Rule: id-block statement : ",f[h-2],f[h-1]),d.generateId(),this.$={...f[h-2],type:"composite",children:f[h-1]};break;case 28:d.getLogger().debug("Rule: blockStatement : ",f[h-2],f[h-1],f[h]);let o=d.generateId();this.$={id:o,type:"composite",label:"",children:f[h-1]};break;case 29:d.getLogger().debug("Rule: node (NODE_ID separator): ",f[h]),this.$={id:f[h]};break;case 30:d.getLogger().debug("Rule: node (NODE_ID nodeShapeNLabel separator): ",f[h-1],f[h]),this.$={id:f[h-1],label:f[h].label,typeStr:f[h].typeStr,directions:f[h].directions};break;case 31:d.getLogger().debug("Rule: dirList: ",f[h]),this.$=[f[h]];break;case 32:d.getLogger().debug("Rule: dirList: ",f[h-1],f[h]),this.$=[f[h-1]].concat(f[h]);break;case 33:d.getLogger().debug("Rule: nodeShapeNLabel: ",f[h-2],f[h-1],f[h]),this.$={typeStr:f[h-2]+f[h],label:f[h-1]};break;case 34:d.getLogger().debug("Rule: BLOCK_ARROW nodeShapeNLabel: ",f[h-3],f[h-2]," #3:",f[h-1],f[h]),this.$={typeStr:f[h-3]+f[h],label:f[h-2],directions:f[h-1]};break;case 35:case 36:this.$={type:"classDef",id:f[h-1].trim(),css:f[h].trim()};break;case 37:this.$={type:"applyClass",id:f[h-1].trim(),styleClass:f[h].trim()};break;case 38:this.$={type:"applyStyles",id:f[h-1].trim(),stylesStr:f[h].trim()}}},"anonymous"),table:[{9:1,10:[1,2]},{1:[3]},{10:b,11:3,13:4,19:5,20:6,21:c,22:8,23:9,24:10,25:11,26:12,28:d,29:e,31:f,39:g,43:h,46:i},{8:[1,20]},a(j,[2,12],{13:4,19:5,20:6,22:8,23:9,24:10,25:11,26:12,11:21,10:b,21:c,28:d,29:e,31:f,39:g,43:h,46:i}),a(l,[2,16],{14:22,15:m,16:n}),a(l,[2,17]),a(l,[2,18]),a(l,[2,19]),a(l,[2,20]),a(l,[2,21]),a(l,[2,22]),a(o,[2,25],{27:[1,25]}),a(l,[2,26]),{19:26,26:12,31:f},{10:b,11:27,13:4,19:5,20:6,21:c,22:8,23:9,24:10,25:11,26:12,28:d,29:e,31:f,39:g,43:h,46:i},{40:[1,28],42:[1,29]},{44:[1,30]},{47:[1,31]},a(p,[2,29],{32:32,35:[1,33],37:[1,34]}),{1:[2,7]},a(j,[2,13]),{26:35,31:f},{31:[2,14]},{17:[1,36]},a(o,[2,24]),{10:b,11:37,13:4,14:22,15:m,16:n,19:5,20:6,21:c,22:8,23:9,24:10,25:11,26:12,28:d,29:e,31:f,39:g,43:h,46:i},{30:[1,38]},{41:[1,39]},{41:[1,40]},{45:[1,41]},{48:[1,42]},a(p,[2,30]),{18:[1,43]},{18:[1,44]},a(o,[2,23]),{18:[1,45]},{30:[1,46]},a(l,[2,28]),a(l,[2,35]),a(l,[2,36]),a(l,[2,37]),a(l,[2,38]),{36:[1,47]},{33:48,34:q},{15:[1,50]},a(l,[2,27]),a(p,[2,33]),{38:[1,51]},{33:52,34:q,38:[2,31]},{31:[2,15]},a(p,[2,34]),{38:[2,32]}],defaultActions:{20:[2,7],23:[2,14],50:[2,15],52:[2,32]},parseError:(0,k.K)(function(a,b){if(b.recoverable)this.trace(a);else{var c=Error(a);throw c.hash=b,c}},"parseError"),parse:(0,k.K)(function(a){var b=this,c=[0],d=[],e=[null],f=[],g=this.table,h="",i=0,j=0,l=0,m=f.slice.call(arguments,1),n=Object.create(this.lexer),o={};for(var p in this.yy)Object.prototype.hasOwnProperty.call(this.yy,p)&&(o[p]=this.yy[p]);n.setInput(a,o),o.lexer=n,o.parser=this,void 0===n.yylloc&&(n.yylloc={});var q=n.yylloc;f.push(q);var r=n.options&&n.options.ranges;function s(){var a;return"number"!=typeof(a=d.pop()||n.lex()||1)&&(a instanceof Array&&(a=(d=a).pop()),a=b.symbols_[a]||a),a}"function"==typeof o.parseError?this.parseError=o.parseError:this.parseError=Object.getPrototypeOf(this).parseError,(0,k.K)(function(a){c.length=c.length-2*a,e.length=e.length-a,f.length=f.length-a},"popStack"),(0,k.K)(s,"lex");for(var t,u,v,w,x,y,z,A,B,C={};;){if(v=c[c.length-1],this.defaultActions[v]?w=this.defaultActions[v]:(null==t&&(t=s()),w=g[v]&&g[v][t]),void 0===w||!w.length||!w[0]){var D="";for(y in B=[],g[v])this.terminals_[y]&&y>2&&B.push("'"+this.terminals_[y]+"'");D=n.showPosition?"Parse error on line "+(i+1)+":\n"+n.showPosition()+"\nExpecting "+B.join(", ")+", got '"+(this.terminals_[t]||t)+"'":"Parse error on line "+(i+1)+": Unexpected "+(1==t?"end of input":"'"+(this.terminals_[t]||t)+"'"),this.parseError(D,{text:n.match,token:this.terminals_[t]||t,line:n.yylineno,loc:q,expected:B})}if(w[0]instanceof Array&&w.length>1)throw Error("Parse Error: multiple actions possible at state: "+v+", token: "+t);switch(w[0]){case 1:c.push(t),e.push(n.yytext),f.push(n.yylloc),c.push(w[1]),t=null,u?(t=u,u=null):(j=n.yyleng,h=n.yytext,i=n.yylineno,q=n.yylloc,l>0&&l--);break;case 2:if(z=this.productions_[w[1]][1],C.$=e[e.length-z],C._$={first_line:f[f.length-(z||1)].first_line,last_line:f[f.length-1].last_line,first_column:f[f.length-(z||1)].first_column,last_column:f[f.length-1].last_column},r&&(C._$.range=[f[f.length-(z||1)].range[0],f[f.length-1].range[1]]),void 0!==(x=this.performAction.apply(C,[h,j,i,o,w[1],e,f].concat(m))))return x;z&&(c=c.slice(0,-1*z*2),e=e.slice(0,-1*z),f=f.slice(0,-1*z)),c.push(this.productions_[w[1]][0]),e.push(C.$),f.push(C._$),A=g[c[c.length-2]][c[c.length-1]],c.push(A);break;case 3:return!0}}return!0},"parse")};function s(){this.yy={}}return r.lexer={EOF:1,parseError:(0,k.K)(function(a,b){if(this.yy.parser)this.yy.parser.parseError(a,b);else throw Error(a)},"parseError"),setInput:(0,k.K)(function(a,b){return this.yy=b||this.yy||{},this._input=a,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,k.K)(function(){var a=this._input[0];return this.yytext+=a,this.yyleng++,this.offset++,this.match+=a,this.matched+=a,a.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),a},"input"),unput:(0,k.K)(function(a){var b=a.length,c=a.split(/(?:\r\n?|\n)/g);this._input=a+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-b),this.offset-=b;var d=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),c.length-1&&(this.yylineno-=c.length-1);var e=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:c?(c.length===d.length?this.yylloc.first_column:0)+d[d.length-c.length].length-c[0].length:this.yylloc.first_column-b},this.options.ranges&&(this.yylloc.range=[e[0],e[0]+this.yyleng-b]),this.yyleng=this.yytext.length,this},"unput"),more:(0,k.K)(function(){return this._more=!0,this},"more"),reject:(0,k.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,k.K)(function(a){this.unput(this.match.slice(a))},"less"),pastInput:(0,k.K)(function(){var a=this.matched.substr(0,this.matched.length-this.match.length);return(a.length>20?"...":"")+a.substr(-20).replace(/\n/g,"")},"pastInput"),upcomingInput:(0,k.K)(function(){var a=this.match;return a.length<20&&(a+=this._input.substr(0,20-a.length)),(a.substr(0,20)+(a.length>20?"...":"")).replace(/\n/g,"")},"upcomingInput"),showPosition:(0,k.K)(function(){var a=this.pastInput(),b=Array(a.length+1).join("-");return a+this.upcomingInput()+"\n"+b+"^"},"showPosition"),test_match:(0,k.K)(function(a,b){var c,d,e;if(this.options.backtrack_lexer&&(e={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&&(e.yylloc.range=this.yylloc.range.slice(0))),(d=a[0].match(/(?:\r\n?|\n).*/g))&&(this.yylineno+=d.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:d?d[d.length-1].length-d[d.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+a[0].length},this.yytext+=a[0],this.match+=a[0],this.matches=a,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(a[0].length),this.matched+=a[0],c=this.performAction.call(this,this.yy,this,b,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),c)return c;if(this._backtrack)for(var f in e)this[f]=e[f];return!1},"test_match"),next:(0,k.K)(function(){if(this.done)return this.EOF;this._input||(this.done=!0),this._more||(this.yytext="",this.match="");for(var a,b,c,d,e=this._currentRules(),f=0;f<e.length;f++)if((c=this._input.match(this.rules[e[f]]))&&(!b||c[0].length>b[0].length)){if(b=c,d=f,this.options.backtrack_lexer){if(!1!==(a=this.test_match(c,e[f])))return a;if(!this._backtrack)return!1;b=!1;continue}if(!this.options.flex)break}return b?!1!==(a=this.test_match(b,e[d]))&&a:""===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,k.K)(function(){var a=this.next();return a||this.lex()},"lex"),begin:(0,k.K)(function(a){this.conditionStack.push(a)},"begin"),popState:(0,k.K)(function(){return this.conditionStack.length-1>0?this.conditionStack.pop():this.conditionStack[0]},"popState"),_currentRules:(0,k.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,k.K)(function(a){return(a=this.conditionStack.length-1-Math.abs(a||0))>=0?this.conditionStack[a]:"INITIAL"},"topState"),pushState:(0,k.K)(function(a){this.begin(a)},"pushState"),stateStackSize:(0,k.K)(function(){return this.conditionStack.length},"stateStackSize"),options:{},performAction:(0,k.K)(function(a,b,c,d){switch(c){case 0:return a.getLogger().debug("Found block-beta"),10;case 1:return a.getLogger().debug("Found id-block"),29;case 2:return a.getLogger().debug("Found block"),10;case 3:a.getLogger().debug(".",b.yytext);break;case 4:a.getLogger().debug("_",b.yytext);break;case 5:return 5;case 6:return b.yytext=-1,28;case 7:return b.yytext=b.yytext.replace(/columns\s+/,""),a.getLogger().debug("COLUMNS (LEX)",b.yytext),28;case 8:case 76:case 77:case 99:this.pushState("md_string");break;case 9:return"MD_STR";case 10:case 34:case 79:this.popState();break;case 11:this.pushState("string");break;case 12:a.getLogger().debug("LEX: POPPING STR:",b.yytext),this.popState();break;case 13:return a.getLogger().debug("LEX: STR end:",b.yytext),"STR";case 14:return b.yytext=b.yytext.replace(/space\:/,""),a.getLogger().debug("SPACE NUM (LEX)",b.yytext),21;case 15:return b.yytext="1",a.getLogger().debug("COLUMNS (LEX)",b.yytext),21;case 16:return 42;case 17:return"LINKSTYLE";case 18:return"INTERPOLATE";case 19:return this.pushState("CLASSDEF"),39;case 20:return this.popState(),this.pushState("CLASSDEFID"),"DEFAULT_CLASSDEF_ID";case 21:return this.popState(),this.pushState("CLASSDEFID"),40;case 22:return this.popState(),41;case 23:return this.pushState("CLASS"),43;case 24:return this.popState(),this.pushState("CLASS_STYLE"),44;case 25:return this.popState(),45;case 26:return this.pushState("STYLE_STMNT"),46;case 27:return this.popState(),this.pushState("STYLE_DEFINITION"),47;case 28:return this.popState(),48;case 29:return this.pushState("acc_title"),"acc_title";case 30:return this.popState(),"acc_title_value";case 31:return this.pushState("acc_descr"),"acc_descr";case 32:return this.popState(),"acc_descr_value";case 33:this.pushState("acc_descr_multiline");break;case 35:return"acc_descr_multiline_value";case 36:return 30;case 37:case 38:case 40:case 41:case 44:return this.popState(),a.getLogger().debug("Lex: (("),"NODE_DEND";case 39:return this.popState(),a.getLogger().debug("Lex: ))"),"NODE_DEND";case 42:return this.popState(),a.getLogger().debug("Lex: (-"),"NODE_DEND";case 43:return this.popState(),a.getLogger().debug("Lex: -)"),"NODE_DEND";case 45:return this.popState(),a.getLogger().debug("Lex: ]]"),"NODE_DEND";case 46:return this.popState(),a.getLogger().debug("Lex: ("),"NODE_DEND";case 47:return this.popState(),a.getLogger().debug("Lex: ])"),"NODE_DEND";case 48:case 49:return this.popState(),a.getLogger().debug("Lex: /]"),"NODE_DEND";case 50:return this.popState(),a.getLogger().debug("Lex: )]"),"NODE_DEND";case 51:return this.popState(),a.getLogger().debug("Lex: )"),"NODE_DEND";case 52:return this.popState(),a.getLogger().debug("Lex: ]>"),"NODE_DEND";case 53:return this.popState(),a.getLogger().debug("Lex: ]"),"NODE_DEND";case 54:return a.getLogger().debug("Lexa: -)"),this.pushState("NODE"),35;case 55:return a.getLogger().debug("Lexa: (-"),this.pushState("NODE"),35;case 56:return a.getLogger().debug("Lexa: ))"),this.pushState("NODE"),35;case 57:case 59:case 60:case 61:case 64:return a.getLogger().debug("Lexa: )"),this.pushState("NODE"),35;case 58:return a.getLogger().debug("Lex: ((("),this.pushState("NODE"),35;case 62:return a.getLogger().debug("Lexc: >"),this.pushState("NODE"),35;case 63:return a.getLogger().debug("Lexa: (["),this.pushState("NODE"),35;case 65:case 66:case 67:case 68:case 69:case 70:case 71:return this.pushState("NODE"),35;case 72:return a.getLogger().debug("Lexa: ["),this.pushState("NODE"),35;case 73:return this.pushState("BLOCK_ARROW"),a.getLogger().debug("LEX ARR START"),37;case 74:return a.getLogger().debug("Lex: NODE_ID",b.yytext),31;case 75:return a.getLogger().debug("Lex: EOF",b.yytext),8;case 78:return"NODE_DESCR";case 80:a.getLogger().debug("Lex: Starting string"),this.pushState("string");break;case 81:a.getLogger().debug("LEX ARR: Starting string"),this.pushState("string");break;case 82:return a.getLogger().debug("LEX: NODE_DESCR:",b.yytext),"NODE_DESCR";case 83:a.getLogger().debug("LEX POPPING"),this.popState();break;case 84:a.getLogger().debug("Lex: =>BAE"),this.pushState("ARROW_DIR");break;case 85:return b.yytext=b.yytext.replace(/^,\s*/,""),a.getLogger().debug("Lex (right): dir:",b.yytext),"DIR";case 86:return b.yytext=b.yytext.replace(/^,\s*/,""),a.getLogger().debug("Lex (left):",b.yytext),"DIR";case 87:return b.yytext=b.yytext.replace(/^,\s*/,""),a.getLogger().debug("Lex (x):",b.yytext),"DIR";case 88:return b.yytext=b.yytext.replace(/^,\s*/,""),a.getLogger().debug("Lex (y):",b.yytext),"DIR";case 89:return b.yytext=b.yytext.replace(/^,\s*/,""),a.getLogger().debug("Lex (up):",b.yytext),"DIR";case 90:return b.yytext=b.yytext.replace(/^,\s*/,""),a.getLogger().debug("Lex (down):",b.yytext),"DIR";case 91:return b.yytext="]>",a.getLogger().debug("Lex (ARROW_DIR end):",b.yytext),this.popState(),this.popState(),"BLOCK_ARROW_END";case 92:return a.getLogger().debug("Lex: LINK","#"+b.yytext+"#"),15;case 93:case 94:case 95:return a.getLogger().debug("Lex: LINK",b.yytext),15;case 96:case 97:case 98:return a.getLogger().debug("Lex: START_LINK",b.yytext),this.pushState("LLABEL"),16;case 100:return a.getLogger().debug("Lex: Starting string"),this.pushState("string"),"LINK_LABEL";case 101:return this.popState(),a.getLogger().debug("Lex: LINK","#"+b.yytext+"#"),15;case 102:case 103:return this.popState(),a.getLogger().debug("Lex: LINK",b.yytext),15;case 104:return a.getLogger().debug("Lex: COLON",b.yytext),b.yytext=b.yytext.slice(1),27}},"anonymous"),rules:[/^(?:block-beta\b)/,/^(?:block:)/,/^(?:block\b)/,/^(?:[\s]+)/,/^(?:[\n]+)/,/^(?:((\u000D\u000A)|(\u000A)))/,/^(?:columns\s+auto\b)/,/^(?:columns\s+[\d]+)/,/^(?:["][`])/,/^(?:[^`"]+)/,/^(?:[`]["])/,/^(?:["])/,/^(?:["])/,/^(?:[^"]*)/,/^(?:space[:]\d+)/,/^(?:space\b)/,/^(?:default\b)/,/^(?:linkStyle\b)/,/^(?:interpolate\b)/,/^(?:classDef\s+)/,/^(?:DEFAULT\s+)/,/^(?:\w+\s+)/,/^(?:[^\n]*)/,/^(?:class\s+)/,/^(?:(\w+)+((,\s*\w+)*))/,/^(?:[^\n]*)/,/^(?:style\s+)/,/^(?:(\w+)+((,\s*\w+)*))/,/^(?:[^\n]*)/,/^(?:accTitle\s*:\s*)/,/^(?:(?!\n||)*[^\n]*)/,/^(?:accDescr\s*:\s*)/,/^(?:(?!\n||)*[^\n]*)/,/^(?:accDescr\s*\{\s*)/,/^(?:[\}])/,/^(?:[^\}]*)/,/^(?:end\b\s*)/,/^(?:\(\(\()/,/^(?:\)\)\))/,/^(?:[\)]\))/,/^(?:\}\})/,/^(?:\})/,/^(?:\(-)/,/^(?:-\))/,/^(?:\(\()/,/^(?:\]\])/,/^(?:\()/,/^(?:\]\))/,/^(?:\\\])/,/^(?:\/\])/,/^(?:\)\])/,/^(?:[\)])/,/^(?:\]>)/,/^(?:[\]])/,/^(?:-\))/,/^(?:\(-)/,/^(?:\)\))/,/^(?:\))/,/^(?:\(\(\()/,/^(?:\(\()/,/^(?:\{\{)/,/^(?:\{)/,/^(?:>)/,/^(?:\(\[)/,/^(?:\()/,/^(?:\[\[)/,/^(?:\[\|)/,/^(?:\[\()/,/^(?:\)\)\))/,/^(?:\[\\)/,/^(?:\[\/)/,/^(?:\[\\)/,/^(?:\[)/,/^(?:<\[)/,/^(?:[^\(\[\n\-\)\{\}\s\<\>:=]+)/,/^(?:$)/,/^(?:["][`])/,/^(?:["][`])/,/^(?:[^`"]+)/,/^(?:[`]["])/,/^(?:["])/,/^(?:["])/,/^(?:[^"]+)/,/^(?:["])/,/^(?:\]>\s*\()/,/^(?:,?\s*right\s*)/,/^(?:,?\s*left\s*)/,/^(?:,?\s*x\s*)/,/^(?:,?\s*y\s*)/,/^(?:,?\s*up\s*)/,/^(?:,?\s*down\s*)/,/^(?:\)\s*)/,/^(?:\s*[xo<]?--+[-xo>]\s*)/,/^(?:\s*[xo<]?==+[=xo>]\s*)/,/^(?:\s*[xo<]?-?\.+-[xo>]?\s*)/,/^(?:\s*~~[\~]+\s*)/,/^(?:\s*[xo<]?--\s*)/,/^(?:\s*[xo<]?==\s*)/,/^(?:\s*[xo<]?-\.\s*)/,/^(?:["][`])/,/^(?:["])/,/^(?:\s*[xo<]?--+[-xo>]\s*)/,/^(?:\s*[xo<]?==+[=xo>]\s*)/,/^(?:\s*[xo<]?-?\.+-[xo>]?\s*)/,/^(?::\d+)/],conditions:{STYLE_DEFINITION:{rules:[28],inclusive:!1},STYLE_STMNT:{rules:[27],inclusive:!1},CLASSDEFID:{rules:[22],inclusive:!1},CLASSDEF:{rules:[20,21],inclusive:!1},CLASS_STYLE:{rules:[25],inclusive:!1},CLASS:{rules:[24],inclusive:!1},LLABEL:{rules:[99,100,101,102,103],inclusive:!1},ARROW_DIR:{rules:[85,86,87,88,89,90,91],inclusive:!1},BLOCK_ARROW:{rules:[76,81,84],inclusive:!1},NODE:{rules:[37,38,39,40,41,42,43,44,45,46,47,48,49,50,51,52,53,77,80],inclusive:!1},md_string:{rules:[9,10,78,79],inclusive:!1},space:{rules:[],inclusive:!1},string:{rules:[12,13,82,83],inclusive:!1},acc_descr_multiline:{rules:[34,35],inclusive:!1},acc_descr:{rules:[32],inclusive:!1},acc_title:{rules:[30],inclusive:!1},INITIAL:{rules:[0,1,2,3,4,5,6,7,8,11,14,15,16,17,18,19,23,26,29,31,33,36,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,92,93,94,95,96,97,98,104],inclusive:!0}}},(0,k.K)(s,"Parser"),s.prototype=r,r.Parser=s,new s}();u.parser=u;var v=new Map,w=[],x=new Map,y="color",z="fill",A=new Map,B="",C=(0,k.K)(a=>i.Y2.sanitizeText(a,(0,i.D7)()),"sanitizeText"),D=(0,k.K)(function(a,b=""){let c=A.get(a);c||(c={id:a,styles:[],textStyles:[]},A.set(a,c)),null!=b&&b.split(",").forEach(a=>{let b=a.replace(/([^;]*);/,"$1").trim();if(RegExp(y).exec(a)){let a=b.replace(z,"bgFill").replace(y,z);c.textStyles.push(a)}c.styles.push(b)})},"addStyleClass"),E=(0,k.K)(function(a,b=""){let c=v.get(a);null!=b&&(c.styles=b.split(","))},"addStyle2Node"),F=(0,k.K)(function(a,b){a.split(",").forEach(function(a){let c=v.get(a);if(void 0===c){let b=a.trim();c={id:b,type:"na",children:[]},v.set(b,c)}c.classes||(c.classes=[]),c.classes.push(b)})},"setCssClass"),G=(0,k.K)((a,b)=>{let c=a.flat(),d=[],e=c.find(a=>a?.type==="column-setting"),f=e?.columns??-1;for(let a of c){if("number"==typeof f&&f>0&&"column-setting"!==a.type&&"number"==typeof a.widthInColumns&&a.widthInColumns>f&&j.R.warn(`Block ${a.id} width ${a.widthInColumns} exceeds configured column width ${f}`),a.label&&(a.label=C(a.label)),"classDef"===a.type){D(a.id,a.css);continue}if("applyClass"===a.type){F(a.id,a?.styleClass??"");continue}if("applyStyles"===a.type){a?.stylesStr&&E(a.id,a?.stylesStr);continue}if("column-setting"===a.type)b.columns=a.columns??-1;else if("edge"===a.type){let b=(x.get(a.id)??0)+1;x.set(a.id,b),a.id=b+"-"+a.id,w.push(a)}else{a.label||("composite"===a.type?a.label="":a.label=a.id);let b=v.get(a.id);if(void 0===b?v.set(a.id,a):("na"!==a.type&&(b.type=a.type),a.label!==a.id&&(b.label=a.label)),a.children&&G(a.children,a),"space"===a.type){let b=a.width??1;for(let c=0;c<b;c++){let b=function(a){if((0,l.s)(a))return a;let b=(0,m.b)(a);if(!function(a){switch((0,m.b)(a)){case n.R_:case n.Uw:case n.cT:case n.iq:case n.$V:case n.vC:case n.ri:case n.ML:case n.XZ:case n.i1:case n._u:case n.pj:case n.kj:case n.GX:case n.Av:case n.NA:case n.OG:case n.VP:case n.Qb:case n.q:case n.x6:case n.ZR:return!0;default:return!1}}(a))return{};if(Array.isArray(a)){let b=Array.from(a);return a.length>0&&"string"==typeof a[0]&&Object.hasOwn(a,"index")&&(b.index=a.index,b.input=a.input),b}if((0,o.i)(a))return new a.constructor(a.buffer,a.byteOffset,a.length);if(b===n.cT)return new ArrayBuffer(a.byteLength);if(b===n.iq){let b=a.buffer,c=a.byteOffset,d=a.byteLength,e=new ArrayBuffer(d),f=new Uint8Array(b,c,d);return new Uint8Array(e).set(f),new DataView(e)}if(b===n.$V||b===n.kj||b===n.OG){let c=new a.constructor(a.valueOf());return b===n.OG?function(a,b){let c=b.valueOf().length;for(let d in b)Object.hasOwn(b,d)&&(Number.isNaN(Number(d))||Number(d)>=c)&&(a[d]=b[d])}(c,a):p(c,a),c}if(b===n.vC)return new Date(Number(a));if(b===n.Av){let b=new RegExp(a.source,a.flags);return b.lastIndex=a.lastIndex,b}if(b===n.VP)return Object(Symbol.prototype.valueOf.call(a));if(b===n.pj){let b=new Map;return a.forEach((a,c)=>{b.set(c,a)}),b}if(b===n.NA){let b=new Set;return a.forEach(a=>{b.add(a)}),b}if(b===n.R_){let b={};return p(b,a),b.length=a.length,b[Symbol.iterator]=a[Symbol.iterator],b}let c={};return function(a,b){let c=Object.getPrototypeOf(b);null!==c&&"function"==typeof b.constructor&&Object.setPrototypeOf(a,c)}(c,a),p(c,a),function(a,b){let c=Object.getOwnPropertySymbols(b);for(let d=0;d<c.length;d++){let e=c[d];Object.prototype.propertyIsEnumerable.call(b,e)&&(a[e]=b[e])}}(c,a),c}(a);b.id=b.id+"-"+c,v.set(b.id,b),d.push(b)}}else void 0===b&&d.push(a)}}b.children=d},"populateBlockDatabase"),H=[],I={id:"root",type:"composite",children:[],columns:-1},J=(0,k.K)(()=>{j.R.debug("Clear called"),(0,i.IU)(),v=new Map([["root",I={id:"root",type:"composite",children:[],columns:-1}]]),H=[],A=new Map,w=[],x=new Map,B=""},"clear");function K(a){switch(j.R.debug("typeStr2Type",a),a){case"[]":return"square";case"()":return j.R.debug("we have a round"),"round";case"(())":return"circle";case">]":return"rect_left_inv_arrow";case"{}":return"diamond";case"{{}}":return"hexagon";case"([])":return"stadium";case"[[]]":return"subroutine";case"[()]":return"cylinder";case"((()))":return"doublecircle";case"[//]":return"lean_right";case"[\\\\]":return"lean_left";case"[/\\]":return"trapezoid";case"[\\/]":return"inv_trapezoid";case"<[]>":return"block_arrow";default:return"na"}}function L(a){return(j.R.debug("typeStr2Type",a),"=="===a)?"thick":"normal"}function M(a){switch(a.trim().slice(-1)){case"x":return"arrow_cross";case"o":return"arrow_circle";case">":return"arrow_point";default:return""}}function N(a){switch(a.trim().charAt(0)){case"x":return"arrow_cross";case"o":return"arrow_circle";case"<":return"arrow_point";default:return"arrow_open"}}function O(a){return a.includes("==")?"thick":"normal"}function P(a){return a.includes(".-")?"dotted":"solid"}(0,k.K)(K,"typeStr2Type"),(0,k.K)(L,"edgeTypeStr2Type"),(0,k.K)(M,"edgeStrToEdgeData"),(0,k.K)(N,"edgeStrToEdgeStartData"),(0,k.K)(O,"edgeStrToThickness"),(0,k.K)(P,"edgeStrToPattern");var Q=0,R=(0,k.K)(()=>(Q++,"id-"+Math.random().toString(36).substr(2,12)+"-"+Q),"generateId"),S=(0,k.K)(a=>{I.children=a,G(a,I),H=I.children},"setHierarchy"),T=(0,k.K)(a=>{let b=v.get(a);return b?b.columns?b.columns:b.children?b.children.length:-1:-1},"getColumns"),U=(0,k.K)(()=>[...v.values()],"getBlocksFlat"),V=(0,k.K)(()=>H||[],"getBlocks"),W=(0,k.K)(()=>w,"getEdges"),X=(0,k.K)(a=>v.get(a),"getBlock"),Y=(0,k.K)(a=>{v.set(a.id,a)},"setBlock"),Z=(0,k.K)(a=>{B=a},"setDiagramId"),$=(0,k.K)(()=>B,"getDiagramId"),_=(0,k.K)(()=>j.R,"getLogger"),aa=(0,k.K)(function(){return A},"getClasses"),ab={getConfig:(0,k.K)(()=>(0,i.zj)().block,"getConfig"),typeStr2Type:K,edgeTypeStr2Type:L,edgeStrToEdgeData:M,edgeStrToEdgeStartData:N,edgeStrToThickness:O,edgeStrToPattern:P,getLogger:_,getBlocksFlat:U,getBlocks:V,getEdges:W,setHierarchy:S,getBlock:X,setBlock:Y,getColumns:T,getClasses:aa,clear:J,generateId:R,setDiagramId:Z,getDiagramId:$},ac=(0,k.K)((a,b)=>{let c=q.A,d=c(a,"r"),e=c(a,"g"),f=c(a,"b");return r.A(d,e,f,b)},"fade"),ad=(0,k.K)(a=>`.label {
|
|
16
16
|
font-family: ${a.fontFamily};
|
|
17
17
|
color: ${a.nodeTextColor||a.textColor};
|
|
18
18
|
}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
"use strict";exports.id=6253,exports.ids=[6253],exports.modules={4328:(a,b,c)=>{function d(a,b){a.accDescr&&b.setAccDescription?.(a.accDescr),a.accTitle&&b.setAccTitle?.(a.accTitle),a.title&&b.setDiagramTitle?.(a.title)}c.d(b,{S:()=>d}),(0,c(95097).K)(d,"populateCommonDb")},36253:(a,b,c)=>{c.d(b,{diagram:()=>aD});var d=c(80336),e=c(4328),f=c(64922),g=c(45313),h=c(58715),i=c(95097),j=c(92325),k=c(69085),l={NORMAL:0,REVERSE:1,HIGHLIGHT:2,MERGE:3,CHERRY_PICK:4},m=g.UI.gitGraph,n=(0,i.K)(()=>(0,f.$t)({...m,...(0,g.zj)().gitGraph}),"getConfig"),o=new d.m(()=>{let a=n(),b=a.mainBranchName,c=a.mainBranchOrder;return{mainBranchName:b,commits:new Map,head:null,branchConfig:new Map([[b,{name:b,order:c}]]),branches:new Map([[b,null]]),currBranch:b,direction:"LR",seq:0,options:{}}});function p(){return(0,f.yT)({length:7})}function q(a,b){let c=Object.create(null);return a.reduce((a,d)=>{let e=b(d);return c[e]||(c[e]=!0,a.push(d)),a},[])}(0,i.K)(p,"getID"),(0,i.K)(q,"uniqBy");var r=(0,i.K)(function(a){o.records.direction=a},"setDirection"),s=(0,i.K)(function(a){h.R.debug("options str",a),a=(a=a?.trim())||"{}";try{o.records.options=JSON.parse(a)}catch(a){h.R.error("error while parsing gitGraph options",a.message)}},"setOptions"),t=(0,i.K)(function(){return o.records.options},"getOptions"),u=(0,i.K)(function(a){let b=a.msg,c=a.id,d=a.type,e=a.tags;h.R.info("commit",b,c,d,e),h.R.debug("Entering commit:",b,c,d,e);let f=n();c=g.Y2.sanitizeText(c,f),b=g.Y2.sanitizeText(b,f),e=e?.map(a=>g.Y2.sanitizeText(a,f));let i={id:c||o.records.seq+"-"+p(),message:b,seq:o.records.seq++,type:d??l.NORMAL,tags:e??[],parents:null==o.records.head?[]:[o.records.head.id],branch:o.records.currBranch};o.records.head=i,h.R.info("main branch",f.mainBranchName),o.records.commits.has(i.id)&&h.R.warn(`Commit ID ${i.id} already exists`),o.records.commits.set(i.id,i),o.records.branches.set(o.records.currBranch,i.id),h.R.debug("in pushCommit "+i.id)},"commit"),v=(0,i.K)(function(a){let b=a.name,c=a.order;if(b=g.Y2.sanitizeText(b,n()),o.records.branches.has(b))throw Error(`Trying to create an existing branch. (Help: Either use a new name if you want create a new branch or try using "checkout ${b}")`);o.records.branches.set(b,null!=o.records.head?o.records.head.id:null),o.records.branchConfig.set(b,{name:b,order:c}),y(b),h.R.debug("in createBranch")},"branch"),w=(0,i.K)(a=>{let b=a.branch,c=a.id,d=a.type,e=a.tags,f=n();b=g.Y2.sanitizeText(b,f),c&&(c=g.Y2.sanitizeText(c,f));let i=o.records.branches.get(o.records.currBranch),j=o.records.branches.get(b),k=i?o.records.commits.get(i):void 0,m=j?o.records.commits.get(j):void 0;if(k&&m&&k.branch===b)throw Error(`Cannot merge branch '${b}' into itself.`);if(o.records.currBranch===b){let a=Error('Incorrect usage of "merge". Cannot merge a branch to itself');throw a.hash={text:`merge ${b}`,token:`merge ${b}`,expected:["branch abc"]},a}if(void 0===k||!k){let a=Error(`Incorrect usage of "merge". Current branch (${o.records.currBranch})has no commits`);throw a.hash={text:`merge ${b}`,token:`merge ${b}`,expected:["commit"]},a}if(!o.records.branches.has(b)){let a=Error('Incorrect usage of "merge". Branch to be merged ('+b+") does not exist");throw a.hash={text:`merge ${b}`,token:`merge ${b}`,expected:[`branch ${b}`]},a}if(void 0===m||!m){let a=Error('Incorrect usage of "merge". Branch to be merged ('+b+") has no commits");throw a.hash={text:`merge ${b}`,token:`merge ${b}`,expected:['"commit"']},a}if(k===m){let a=Error('Incorrect usage of "merge". Both branches have same head');throw a.hash={text:`merge ${b}`,token:`merge ${b}`,expected:["branch abc"]},a}if(c&&o.records.commits.has(c)){let a=Error('Incorrect usage of "merge". Commit with id:'+c+" already exists, use different custom id");throw a.hash={text:`merge ${b} ${c} ${d} ${e?.join(" ")}`,token:`merge ${b} ${c} ${d} ${e?.join(" ")}`,expected:[`merge ${b} ${c}_UNIQUE ${d} ${e?.join(" ")}`]},a}let q={id:c||`${o.records.seq}-${p()}`,message:`merged branch ${b} into ${o.records.currBranch}`,seq:o.records.seq++,parents:null==o.records.head?[]:[o.records.head.id,j||""],branch:o.records.currBranch,type:l.MERGE,customType:d,customId:!!c,tags:e??[]};o.records.head=q,o.records.commits.set(q.id,q),o.records.branches.set(o.records.currBranch,q.id),h.R.debug(o.records.branches),h.R.debug("in mergeBranch")},"merge"),x=(0,i.K)(function(a){let b=a.id,c=a.targetId,d=a.tags,e=a.parent;h.R.debug("Entering cherryPick:",b,c,d);let f=n();if(b=g.Y2.sanitizeText(b,f),c=g.Y2.sanitizeText(c,f),d=d?.map(a=>g.Y2.sanitizeText(a,f)),e=g.Y2.sanitizeText(e,f),!b||!o.records.commits.has(b)){let a=Error('Incorrect usage of "cherryPick". Source commit id should exist and provided');throw a.hash={text:`cherryPick ${b} ${c}`,token:`cherryPick ${b} ${c}`,expected:["cherry-pick abc"]},a}let i=o.records.commits.get(b);if(void 0===i||!i)throw Error('Incorrect usage of "cherryPick". Source commit id should exist and provided');if(e&&!(Array.isArray(i.parents)&&i.parents.includes(e)))throw Error("Invalid operation: The specified parent commit is not an immediate parent of the cherry-picked commit.");let j=i.branch;if(i.type===l.MERGE&&!e)throw Error("Incorrect usage of cherry-pick: If the source commit is a merge commit, an immediate parent commit must be specified.");if(!c||!o.records.commits.has(c)){if(j===o.records.currBranch){let a=Error('Incorrect usage of "cherryPick". Source commit is already on current branch');throw a.hash={text:`cherryPick ${b} ${c}`,token:`cherryPick ${b} ${c}`,expected:["cherry-pick abc"]},a}let a=o.records.branches.get(o.records.currBranch);if(void 0===a||!a){let a=Error(`Incorrect usage of "cherry-pick". Current branch (${o.records.currBranch})has no commits`);throw a.hash={text:`cherryPick ${b} ${c}`,token:`cherryPick ${b} ${c}`,expected:["cherry-pick abc"]},a}let f=o.records.commits.get(a);if(void 0===f||!f){let a=Error(`Incorrect usage of "cherry-pick". Current branch (${o.records.currBranch})has no commits`);throw a.hash={text:`cherryPick ${b} ${c}`,token:`cherryPick ${b} ${c}`,expected:["cherry-pick abc"]},a}let g={id:o.records.seq+"-"+p(),message:`cherry-picked ${i?.message} into ${o.records.currBranch}`,seq:o.records.seq++,parents:null==o.records.head?[]:[o.records.head.id,i.id],branch:o.records.currBranch,type:l.CHERRY_PICK,tags:d?d.filter(Boolean):[`cherry-pick:${i.id}${i.type===l.MERGE?`|parent:${e}`:""}`]};o.records.head=g,o.records.commits.set(g.id,g),o.records.branches.set(o.records.currBranch,g.id),h.R.debug(o.records.branches),h.R.debug("in cherryPick")}},"cherryPick"),y=(0,i.K)(function(a){if(a=g.Y2.sanitizeText(a,n()),o.records.branches.has(a)){o.records.currBranch=a;let b=o.records.branches.get(o.records.currBranch);void 0!==b&&b?o.records.head=o.records.commits.get(b)??null:o.records.head=null}else{let b=Error(`Trying to checkout branch which is not yet created. (Help try using "branch ${a}")`);throw b.hash={text:`checkout ${a}`,token:`checkout ${a}`,expected:[`branch ${a}`]},b}},"checkout");function z(a,b,c){let d=a.indexOf(b);-1===d?a.push(c):a.splice(d,1,c)}function A(a){let b=a.reduce((a,b)=>a.seq>b.seq?a:b,a[0]),c="";a.forEach(function(a){a===b?c+=" *":c+=" |"});let d=[c,b.id,b.seq];for(let a in o.records.branches)o.records.branches.get(a)===b.id&&d.push(a);if(h.R.debug(d.join(" ")),b.parents&&2==b.parents.length&&b.parents[0]&&b.parents[1]){let c=o.records.commits.get(b.parents[0]);z(a,b,c),b.parents[1]&&a.push(o.records.commits.get(b.parents[1]))}else if(0==b.parents.length)return;else if(b.parents[0]){let c=o.records.commits.get(b.parents[0]);z(a,b,c)}A(a=q(a,a=>a.id))}(0,i.K)(z,"upsert"),(0,i.K)(A,"prettyPrintCommitHistory");var B=(0,i.K)(function(){h.R.debug(o.records.commits),A([G()[0]])},"prettyPrint"),C=(0,i.K)(function(){o.reset(),(0,g.IU)()},"clear"),D=(0,i.K)(function(){return[...o.records.branchConfig.values()].map((a,b)=>null!==a.order&&void 0!==a.order?a:{...a,order:parseFloat(`0.${b}`)}).sort((a,b)=>(a.order??0)-(b.order??0)).map(({name:a})=>({name:a}))},"getBranchesAsObjArray"),E=(0,i.K)(function(){return o.records.branches},"getBranches"),F=(0,i.K)(function(){return o.records.commits},"getCommits"),G=(0,i.K)(function(){let a=[...o.records.commits.values()];return a.forEach(function(a){h.R.debug(a.id)}),a.sort((a,b)=>a.seq-b.seq),a},"getCommitsArray"),H={commitType:l,getConfig:n,setDirection:r,setOptions:s,getOptions:t,commit:u,branch:v,merge:w,cherryPick:x,checkout:y,prettyPrint:B,clear:C,getBranchesAsObjArray:D,getBranches:E,getCommits:F,getCommitsArray:G,getCurrentBranch:(0,i.K)(function(){return o.records.currBranch},"getCurrentBranch"),getDirection:(0,i.K)(function(){return o.records.direction},"getDirection"),getHead:(0,i.K)(function(){return o.records.head},"getHead"),setAccTitle:g.SV,getAccTitle:g.iN,getAccDescription:g.m7,setAccDescription:g.EI,setDiagramTitle:g.ke,getDiagramTitle:g.ab},I=(0,i.K)((a,b)=>{for(let c of((0,e.S)(a,b),a.dir&&b.setDirection(a.dir),a.statements))J(c,b)},"populate"),J=(0,i.K)((a,b)=>{let c={Commit:(0,i.K)(a=>b.commit(K(a)),"Commit"),Branch:(0,i.K)(a=>b.branch(L(a)),"Branch"),Merge:(0,i.K)(a=>b.merge(M(a)),"Merge"),Checkout:(0,i.K)(a=>b.checkout(N(a)),"Checkout"),CherryPicking:(0,i.K)(a=>b.cherryPick(O(a)),"CherryPicking")}[a.$type];c?c(a):h.R.error(`Unknown statement type: ${a.$type}`)},"parseStatement"),K=(0,i.K)(a=>({id:a.id,msg:a.message??"",type:void 0!==a.type?l[a.type]:l.NORMAL,tags:a.tags??void 0}),"parseCommit"),L=(0,i.K)(a=>({name:a.name,order:a.order??0}),"parseBranch"),M=(0,i.K)(a=>({branch:a.branch,id:a.id??"",type:void 0!==a.type?l[a.type]:void 0,tags:a.tags??void 0}),"parseMerge"),N=(0,i.K)(a=>a.branch,"parseCheckout"),O=(0,i.K)(a=>({id:a.id,targetId:"",tags:a.tags?.length===0?void 0:a.tags,parent:a.parent}),"parseCherryPicking"),P={parse:(0,i.K)(async a=>{let b=await (0,j.qg)("gitGraph",a);h.R.debug(b),I(b,H)},"parse")},Q=new Set(["redux","redux-dark","redux-color","redux-dark-color"]),R=new Set(["redux-color","redux-dark-color"]),S=new Set(["dark","redux-dark","redux-dark-color","neo-dark"]),T=(0,i.K)((a,b,c=!1)=>c&&a>0?(a-1)%(b-1)+1:a%b,"calcColorIndex"),U=new Map,V=new Map,W=new Map,X=[],Y=0,Z="LR",$=(0,i.K)(()=>{U.clear(),V.clear(),W.clear(),Y=0,X=[],Z="LR"},"clear"),_=(0,i.K)(a=>{let b=document.createElementNS("http://www.w3.org/2000/svg","text");return("string"==typeof a?a.split(/\\n|\n|<br\s*\/?>/gi):a).forEach(a=>{let c=document.createElementNS("http://www.w3.org/2000/svg","tspan");c.setAttributeNS("http://www.w3.org/XML/1998/namespace","xml:space","preserve"),c.setAttribute("dy","1em"),c.setAttribute("x","0"),c.setAttribute("class","row"),c.textContent=a.trim(),b.appendChild(c)}),b},"drawText"),aa=(0,i.K)(a=>{let b,c,d;return"BT"===Z?(c=(0,i.K)((a,b)=>a<=b,"comparisonFunc"),d=1/0):(c=(0,i.K)((a,b)=>a>=b,"comparisonFunc"),d=0),a.forEach(a=>{let e="TB"===Z||"BT"==Z?V.get(a)?.y:V.get(a)?.x;void 0!==e&&c(e,d)&&(b=a,d=e)}),b},"findClosestParent"),ab=(0,i.K)(a=>{let b="",c=1/0;return a.forEach(a=>{let d=V.get(a).y;d<=c&&(b=a,c=d)}),b||void 0},"findClosestParentBT"),ac=(0,i.K)((a,b,c)=>{let d=c,e=c,f=[];a.forEach(a=>{let c=b.get(a);if(!c)throw Error(`Commit not found for key ${a}`);c.parents.length?e=Math.max(d=ae(c),e):f.push(c),af(c,d)}),d=e,f.forEach(a=>{ag(a,d,c)}),a.forEach(a=>{let c=b.get(a);if(c?.parents.length){let a=ab(c.parents);(d=V.get(a).y-40)<=e&&(e=d);let b=U.get(c.branch).pos,f=d-10;V.set(c.id,{x:b,y:f})}})},"setParallelBTPos"),ad=(0,i.K)(a=>{let b=aa(a.parents.filter(a=>null!==a));if(!b)throw Error(`Closest parent not found for commit ${a.id}`);let c=V.get(b)?.y;if(void 0===c)throw Error(`Closest parent position not found for commit ${a.id}`);return c},"findClosestParentPos"),ae=(0,i.K)(a=>ad(a)+40,"calculateCommitPosition"),af=(0,i.K)((a,b)=>{let c=U.get(a.branch);if(!c)throw Error(`Branch not found for commit ${a.id}`);let d=c.pos,e=b+10;return V.set(a.id,{x:d,y:e}),{x:d,y:e}},"setCommitPosition"),ag=(0,i.K)((a,b,c)=>{let d=U.get(a.branch);if(!d)throw Error(`Branch not found for commit ${a.id}`);let e=d.pos;V.set(a.id,{x:e,y:b+c})},"setRootPosition"),ah=(0,i.K)((a,b,c,d,e,f)=>{let{theme:h}=(0,g.D7)(),i=Q.has(h??""),j=R.has(h??""),k=S.has(h??"");if(f===l.HIGHLIGHT)a.append("rect").attr("x",c.x-10+3*!!i).attr("y",c.y-10+3*!!i).attr("width",i?14:20).attr("height",i?14:20).attr("class",`commit ${b.id} commit-highlight${T(e,8,j)} ${d}-outer`),a.append("rect").attr("x",c.x-6+2*!!i).attr("y",c.y-6+2*!!i).attr("width",i?8:12).attr("height",i?8:12).attr("class",`commit ${b.id} commit${T(e,8,j)} ${d}-inner`);else if(f===l.CHERRY_PICK)a.append("circle").attr("cx",c.x).attr("cy",c.y).attr("r",i?7:10).attr("class",`commit ${b.id} ${d}`),a.append("circle").attr("cx",c.x-3).attr("cy",c.y+2).attr("r",i?2.5:2.75).attr("fill",k?"#000000":"#fff").attr("class",`commit ${b.id} ${d}`),a.append("circle").attr("cx",c.x+3).attr("cy",c.y+2).attr("r",i?2.5:2.75).attr("fill",k?"#000000":"#fff").attr("class",`commit ${b.id} ${d}`),a.append("line").attr("x1",c.x+3).attr("y1",c.y+1).attr("x2",c.x).attr("y2",c.y-5).attr("stroke",k?"#000000":"#fff").attr("class",`commit ${b.id} ${d}`),a.append("line").attr("x1",c.x-3).attr("y1",c.y+1).attr("x2",c.x).attr("y2",c.y-5).attr("stroke",k?"#000000":"#fff").attr("class",`commit ${b.id} ${d}`);else{let g=a.append("circle");if(g.attr("cx",c.x),g.attr("cy",c.y),g.attr("r",i?7:10),g.attr("class",`commit ${b.id} commit${T(e,8,j)}`),f===l.MERGE){let f=a.append("circle");f.attr("cx",c.x),f.attr("cy",c.y),f.attr("r",i?5:6),f.attr("class",`commit ${d} ${b.id} commit${T(e,8,j)}`)}if(f===l.REVERSE){let f=a.append("path"),g=i?4:5;f.attr("d",`M ${c.x-g},${c.y-g}L${c.x+g},${c.y+g}M${c.x-g},${c.y+g}L${c.x+g},${c.y-g}`).attr("class",`commit ${d} ${b.id} commit${T(e,8,j)}`)}}},"drawCommitBullet"),ai=(0,i.K)((a,b,c,d,e)=>{if(b.type!==l.CHERRY_PICK&&(b.customId&&b.type===l.MERGE||b.type!==l.MERGE)&&e.showCommitLabel){let f=a.append("g"),g=f.insert("rect").attr("class","commit-label-bkg"),h=f.append("text").attr("x",d).attr("y",c.y+25).attr("class","commit-label").text(b.id),i=h.node()?.getBBox();if(i&&(g.attr("x",c.posWithOffset-i.width/2-2).attr("y",c.y+13.5).attr("width",i.width+4).attr("height",i.height+4),"TB"===Z||"BT"===Z?(g.attr("x",c.x-(i.width+16+5)).attr("y",c.y-12),h.attr("x",c.x-(i.width+16)).attr("y",c.y+i.height-12)):h.attr("x",c.posWithOffset-i.width/2),e.rotateCommitLabel))if("TB"===Z||"BT"===Z)h.attr("transform","rotate(-45, "+c.x+", "+c.y+")"),g.attr("transform","rotate(-45, "+c.x+", "+c.y+")");else{let a=-7.5-(i.width+10)/25*9.5,b=10+i.width/25*8.5;f.attr("transform","translate("+a+", "+b+") rotate(-45, "+d+", "+c.y+")")}}},"drawCommitLabel"),aj=(0,i.K)((a,b,c,d)=>{if(b.tags.length>0){let e=0,f=0,g=0,h=[];for(let d of b.tags.reverse()){let b=a.insert("polygon"),i=a.append("circle"),j=a.append("text").attr("y",c.y-16-e).attr("class","tag-label").text(d),k=j.node()?.getBBox();if(!k)throw Error("Tag bbox not found");f=Math.max(f,k.width),g=Math.max(g,k.height),j.attr("x",c.posWithOffset-k.width/2),h.push({tag:j,hole:i,rect:b,yOffset:e}),e+=20}for(let{tag:a,hole:b,rect:e,yOffset:i}of h){let h=g/2,j=c.y-19.2-i;if(e.attr("class","tag-label-bkg").attr("points",`
|
|
1
|
+
"use strict";exports.id=6253,exports.ids=[6253],exports.modules={4328:(a,b,c)=>{function d(a,b){a.accDescr&&b.setAccDescription?.(a.accDescr),a.accTitle&&b.setAccTitle?.(a.accTitle),a.title&&b.setDiagramTitle?.(a.title)}c.d(b,{S:()=>d}),(0,c(95097).K)(d,"populateCommonDb")},36253:(a,b,c)=>{c.d(b,{diagram:()=>aD});var d=c(80336),e=c(4328),f=c(64922),g=c(45313),h=c(58715),i=c(95097),j=c(92325),k=c(92718),l={NORMAL:0,REVERSE:1,HIGHLIGHT:2,MERGE:3,CHERRY_PICK:4},m=g.UI.gitGraph,n=(0,i.K)(()=>(0,f.$t)({...m,...(0,g.zj)().gitGraph}),"getConfig"),o=new d.m(()=>{let a=n(),b=a.mainBranchName,c=a.mainBranchOrder;return{mainBranchName:b,commits:new Map,head:null,branchConfig:new Map([[b,{name:b,order:c}]]),branches:new Map([[b,null]]),currBranch:b,direction:"LR",seq:0,options:{}}});function p(){return(0,f.yT)({length:7})}function q(a,b){let c=Object.create(null);return a.reduce((a,d)=>{let e=b(d);return c[e]||(c[e]=!0,a.push(d)),a},[])}(0,i.K)(p,"getID"),(0,i.K)(q,"uniqBy");var r=(0,i.K)(function(a){o.records.direction=a},"setDirection"),s=(0,i.K)(function(a){h.R.debug("options str",a),a=(a=a?.trim())||"{}";try{o.records.options=JSON.parse(a)}catch(a){h.R.error("error while parsing gitGraph options",a.message)}},"setOptions"),t=(0,i.K)(function(){return o.records.options},"getOptions"),u=(0,i.K)(function(a){let b=a.msg,c=a.id,d=a.type,e=a.tags;h.R.info("commit",b,c,d,e),h.R.debug("Entering commit:",b,c,d,e);let f=n();c=g.Y2.sanitizeText(c,f),b=g.Y2.sanitizeText(b,f),e=e?.map(a=>g.Y2.sanitizeText(a,f));let i={id:c||o.records.seq+"-"+p(),message:b,seq:o.records.seq++,type:d??l.NORMAL,tags:e??[],parents:null==o.records.head?[]:[o.records.head.id],branch:o.records.currBranch};o.records.head=i,h.R.info("main branch",f.mainBranchName),o.records.commits.has(i.id)&&h.R.warn(`Commit ID ${i.id} already exists`),o.records.commits.set(i.id,i),o.records.branches.set(o.records.currBranch,i.id),h.R.debug("in pushCommit "+i.id)},"commit"),v=(0,i.K)(function(a){let b=a.name,c=a.order;if(b=g.Y2.sanitizeText(b,n()),o.records.branches.has(b))throw Error(`Trying to create an existing branch. (Help: Either use a new name if you want create a new branch or try using "checkout ${b}")`);o.records.branches.set(b,null!=o.records.head?o.records.head.id:null),o.records.branchConfig.set(b,{name:b,order:c}),y(b),h.R.debug("in createBranch")},"branch"),w=(0,i.K)(a=>{let b=a.branch,c=a.id,d=a.type,e=a.tags,f=n();b=g.Y2.sanitizeText(b,f),c&&(c=g.Y2.sanitizeText(c,f));let i=o.records.branches.get(o.records.currBranch),j=o.records.branches.get(b),k=i?o.records.commits.get(i):void 0,m=j?o.records.commits.get(j):void 0;if(k&&m&&k.branch===b)throw Error(`Cannot merge branch '${b}' into itself.`);if(o.records.currBranch===b){let a=Error('Incorrect usage of "merge". Cannot merge a branch to itself');throw a.hash={text:`merge ${b}`,token:`merge ${b}`,expected:["branch abc"]},a}if(void 0===k||!k){let a=Error(`Incorrect usage of "merge". Current branch (${o.records.currBranch})has no commits`);throw a.hash={text:`merge ${b}`,token:`merge ${b}`,expected:["commit"]},a}if(!o.records.branches.has(b)){let a=Error('Incorrect usage of "merge". Branch to be merged ('+b+") does not exist");throw a.hash={text:`merge ${b}`,token:`merge ${b}`,expected:[`branch ${b}`]},a}if(void 0===m||!m){let a=Error('Incorrect usage of "merge". Branch to be merged ('+b+") has no commits");throw a.hash={text:`merge ${b}`,token:`merge ${b}`,expected:['"commit"']},a}if(k===m){let a=Error('Incorrect usage of "merge". Both branches have same head');throw a.hash={text:`merge ${b}`,token:`merge ${b}`,expected:["branch abc"]},a}if(c&&o.records.commits.has(c)){let a=Error('Incorrect usage of "merge". Commit with id:'+c+" already exists, use different custom id");throw a.hash={text:`merge ${b} ${c} ${d} ${e?.join(" ")}`,token:`merge ${b} ${c} ${d} ${e?.join(" ")}`,expected:[`merge ${b} ${c}_UNIQUE ${d} ${e?.join(" ")}`]},a}let q={id:c||`${o.records.seq}-${p()}`,message:`merged branch ${b} into ${o.records.currBranch}`,seq:o.records.seq++,parents:null==o.records.head?[]:[o.records.head.id,j||""],branch:o.records.currBranch,type:l.MERGE,customType:d,customId:!!c,tags:e??[]};o.records.head=q,o.records.commits.set(q.id,q),o.records.branches.set(o.records.currBranch,q.id),h.R.debug(o.records.branches),h.R.debug("in mergeBranch")},"merge"),x=(0,i.K)(function(a){let b=a.id,c=a.targetId,d=a.tags,e=a.parent;h.R.debug("Entering cherryPick:",b,c,d);let f=n();if(b=g.Y2.sanitizeText(b,f),c=g.Y2.sanitizeText(c,f),d=d?.map(a=>g.Y2.sanitizeText(a,f)),e=g.Y2.sanitizeText(e,f),!b||!o.records.commits.has(b)){let a=Error('Incorrect usage of "cherryPick". Source commit id should exist and provided');throw a.hash={text:`cherryPick ${b} ${c}`,token:`cherryPick ${b} ${c}`,expected:["cherry-pick abc"]},a}let i=o.records.commits.get(b);if(void 0===i||!i)throw Error('Incorrect usage of "cherryPick". Source commit id should exist and provided');if(e&&!(Array.isArray(i.parents)&&i.parents.includes(e)))throw Error("Invalid operation: The specified parent commit is not an immediate parent of the cherry-picked commit.");let j=i.branch;if(i.type===l.MERGE&&!e)throw Error("Incorrect usage of cherry-pick: If the source commit is a merge commit, an immediate parent commit must be specified.");if(!c||!o.records.commits.has(c)){if(j===o.records.currBranch){let a=Error('Incorrect usage of "cherryPick". Source commit is already on current branch');throw a.hash={text:`cherryPick ${b} ${c}`,token:`cherryPick ${b} ${c}`,expected:["cherry-pick abc"]},a}let a=o.records.branches.get(o.records.currBranch);if(void 0===a||!a){let a=Error(`Incorrect usage of "cherry-pick". Current branch (${o.records.currBranch})has no commits`);throw a.hash={text:`cherryPick ${b} ${c}`,token:`cherryPick ${b} ${c}`,expected:["cherry-pick abc"]},a}let f=o.records.commits.get(a);if(void 0===f||!f){let a=Error(`Incorrect usage of "cherry-pick". Current branch (${o.records.currBranch})has no commits`);throw a.hash={text:`cherryPick ${b} ${c}`,token:`cherryPick ${b} ${c}`,expected:["cherry-pick abc"]},a}let g={id:o.records.seq+"-"+p(),message:`cherry-picked ${i?.message} into ${o.records.currBranch}`,seq:o.records.seq++,parents:null==o.records.head?[]:[o.records.head.id,i.id],branch:o.records.currBranch,type:l.CHERRY_PICK,tags:d?d.filter(Boolean):[`cherry-pick:${i.id}${i.type===l.MERGE?`|parent:${e}`:""}`]};o.records.head=g,o.records.commits.set(g.id,g),o.records.branches.set(o.records.currBranch,g.id),h.R.debug(o.records.branches),h.R.debug("in cherryPick")}},"cherryPick"),y=(0,i.K)(function(a){if(a=g.Y2.sanitizeText(a,n()),o.records.branches.has(a)){o.records.currBranch=a;let b=o.records.branches.get(o.records.currBranch);void 0!==b&&b?o.records.head=o.records.commits.get(b)??null:o.records.head=null}else{let b=Error(`Trying to checkout branch which is not yet created. (Help try using "branch ${a}")`);throw b.hash={text:`checkout ${a}`,token:`checkout ${a}`,expected:[`branch ${a}`]},b}},"checkout");function z(a,b,c){let d=a.indexOf(b);-1===d?a.push(c):a.splice(d,1,c)}function A(a){let b=a.reduce((a,b)=>a.seq>b.seq?a:b,a[0]),c="";a.forEach(function(a){a===b?c+=" *":c+=" |"});let d=[c,b.id,b.seq];for(let a in o.records.branches)o.records.branches.get(a)===b.id&&d.push(a);if(h.R.debug(d.join(" ")),b.parents&&2==b.parents.length&&b.parents[0]&&b.parents[1]){let c=o.records.commits.get(b.parents[0]);z(a,b,c),b.parents[1]&&a.push(o.records.commits.get(b.parents[1]))}else if(0==b.parents.length)return;else if(b.parents[0]){let c=o.records.commits.get(b.parents[0]);z(a,b,c)}A(a=q(a,a=>a.id))}(0,i.K)(z,"upsert"),(0,i.K)(A,"prettyPrintCommitHistory");var B=(0,i.K)(function(){h.R.debug(o.records.commits),A([G()[0]])},"prettyPrint"),C=(0,i.K)(function(){o.reset(),(0,g.IU)()},"clear"),D=(0,i.K)(function(){return[...o.records.branchConfig.values()].map((a,b)=>null!==a.order&&void 0!==a.order?a:{...a,order:parseFloat(`0.${b}`)}).sort((a,b)=>(a.order??0)-(b.order??0)).map(({name:a})=>({name:a}))},"getBranchesAsObjArray"),E=(0,i.K)(function(){return o.records.branches},"getBranches"),F=(0,i.K)(function(){return o.records.commits},"getCommits"),G=(0,i.K)(function(){let a=[...o.records.commits.values()];return a.forEach(function(a){h.R.debug(a.id)}),a.sort((a,b)=>a.seq-b.seq),a},"getCommitsArray"),H={commitType:l,getConfig:n,setDirection:r,setOptions:s,getOptions:t,commit:u,branch:v,merge:w,cherryPick:x,checkout:y,prettyPrint:B,clear:C,getBranchesAsObjArray:D,getBranches:E,getCommits:F,getCommitsArray:G,getCurrentBranch:(0,i.K)(function(){return o.records.currBranch},"getCurrentBranch"),getDirection:(0,i.K)(function(){return o.records.direction},"getDirection"),getHead:(0,i.K)(function(){return o.records.head},"getHead"),setAccTitle:g.SV,getAccTitle:g.iN,getAccDescription:g.m7,setAccDescription:g.EI,setDiagramTitle:g.ke,getDiagramTitle:g.ab},I=(0,i.K)((a,b)=>{for(let c of((0,e.S)(a,b),a.dir&&b.setDirection(a.dir),a.statements))J(c,b)},"populate"),J=(0,i.K)((a,b)=>{let c={Commit:(0,i.K)(a=>b.commit(K(a)),"Commit"),Branch:(0,i.K)(a=>b.branch(L(a)),"Branch"),Merge:(0,i.K)(a=>b.merge(M(a)),"Merge"),Checkout:(0,i.K)(a=>b.checkout(N(a)),"Checkout"),CherryPicking:(0,i.K)(a=>b.cherryPick(O(a)),"CherryPicking")}[a.$type];c?c(a):h.R.error(`Unknown statement type: ${a.$type}`)},"parseStatement"),K=(0,i.K)(a=>({id:a.id,msg:a.message??"",type:void 0!==a.type?l[a.type]:l.NORMAL,tags:a.tags??void 0}),"parseCommit"),L=(0,i.K)(a=>({name:a.name,order:a.order??0}),"parseBranch"),M=(0,i.K)(a=>({branch:a.branch,id:a.id??"",type:void 0!==a.type?l[a.type]:void 0,tags:a.tags??void 0}),"parseMerge"),N=(0,i.K)(a=>a.branch,"parseCheckout"),O=(0,i.K)(a=>({id:a.id,targetId:"",tags:a.tags?.length===0?void 0:a.tags,parent:a.parent}),"parseCherryPicking"),P={parse:(0,i.K)(async a=>{let b=await (0,j.qg)("gitGraph",a);h.R.debug(b),I(b,H)},"parse")},Q=new Set(["redux","redux-dark","redux-color","redux-dark-color"]),R=new Set(["redux-color","redux-dark-color"]),S=new Set(["dark","redux-dark","redux-dark-color","neo-dark"]),T=(0,i.K)((a,b,c=!1)=>c&&a>0?(a-1)%(b-1)+1:a%b,"calcColorIndex"),U=new Map,V=new Map,W=new Map,X=[],Y=0,Z="LR",$=(0,i.K)(()=>{U.clear(),V.clear(),W.clear(),Y=0,X=[],Z="LR"},"clear"),_=(0,i.K)(a=>{let b=document.createElementNS("http://www.w3.org/2000/svg","text");return("string"==typeof a?a.split(/\\n|\n|<br\s*\/?>/gi):a).forEach(a=>{let c=document.createElementNS("http://www.w3.org/2000/svg","tspan");c.setAttributeNS("http://www.w3.org/XML/1998/namespace","xml:space","preserve"),c.setAttribute("dy","1em"),c.setAttribute("x","0"),c.setAttribute("class","row"),c.textContent=a.trim(),b.appendChild(c)}),b},"drawText"),aa=(0,i.K)(a=>{let b,c,d;return"BT"===Z?(c=(0,i.K)((a,b)=>a<=b,"comparisonFunc"),d=1/0):(c=(0,i.K)((a,b)=>a>=b,"comparisonFunc"),d=0),a.forEach(a=>{let e="TB"===Z||"BT"==Z?V.get(a)?.y:V.get(a)?.x;void 0!==e&&c(e,d)&&(b=a,d=e)}),b},"findClosestParent"),ab=(0,i.K)(a=>{let b="",c=1/0;return a.forEach(a=>{let d=V.get(a).y;d<=c&&(b=a,c=d)}),b||void 0},"findClosestParentBT"),ac=(0,i.K)((a,b,c)=>{let d=c,e=c,f=[];a.forEach(a=>{let c=b.get(a);if(!c)throw Error(`Commit not found for key ${a}`);c.parents.length?e=Math.max(d=ae(c),e):f.push(c),af(c,d)}),d=e,f.forEach(a=>{ag(a,d,c)}),a.forEach(a=>{let c=b.get(a);if(c?.parents.length){let a=ab(c.parents);(d=V.get(a).y-40)<=e&&(e=d);let b=U.get(c.branch).pos,f=d-10;V.set(c.id,{x:b,y:f})}})},"setParallelBTPos"),ad=(0,i.K)(a=>{let b=aa(a.parents.filter(a=>null!==a));if(!b)throw Error(`Closest parent not found for commit ${a.id}`);let c=V.get(b)?.y;if(void 0===c)throw Error(`Closest parent position not found for commit ${a.id}`);return c},"findClosestParentPos"),ae=(0,i.K)(a=>ad(a)+40,"calculateCommitPosition"),af=(0,i.K)((a,b)=>{let c=U.get(a.branch);if(!c)throw Error(`Branch not found for commit ${a.id}`);let d=c.pos,e=b+10;return V.set(a.id,{x:d,y:e}),{x:d,y:e}},"setCommitPosition"),ag=(0,i.K)((a,b,c)=>{let d=U.get(a.branch);if(!d)throw Error(`Branch not found for commit ${a.id}`);let e=d.pos;V.set(a.id,{x:e,y:b+c})},"setRootPosition"),ah=(0,i.K)((a,b,c,d,e,f)=>{let{theme:h}=(0,g.D7)(),i=Q.has(h??""),j=R.has(h??""),k=S.has(h??"");if(f===l.HIGHLIGHT)a.append("rect").attr("x",c.x-10+3*!!i).attr("y",c.y-10+3*!!i).attr("width",i?14:20).attr("height",i?14:20).attr("class",`commit ${b.id} commit-highlight${T(e,8,j)} ${d}-outer`),a.append("rect").attr("x",c.x-6+2*!!i).attr("y",c.y-6+2*!!i).attr("width",i?8:12).attr("height",i?8:12).attr("class",`commit ${b.id} commit${T(e,8,j)} ${d}-inner`);else if(f===l.CHERRY_PICK)a.append("circle").attr("cx",c.x).attr("cy",c.y).attr("r",i?7:10).attr("class",`commit ${b.id} ${d}`),a.append("circle").attr("cx",c.x-3).attr("cy",c.y+2).attr("r",i?2.5:2.75).attr("fill",k?"#000000":"#fff").attr("class",`commit ${b.id} ${d}`),a.append("circle").attr("cx",c.x+3).attr("cy",c.y+2).attr("r",i?2.5:2.75).attr("fill",k?"#000000":"#fff").attr("class",`commit ${b.id} ${d}`),a.append("line").attr("x1",c.x+3).attr("y1",c.y+1).attr("x2",c.x).attr("y2",c.y-5).attr("stroke",k?"#000000":"#fff").attr("class",`commit ${b.id} ${d}`),a.append("line").attr("x1",c.x-3).attr("y1",c.y+1).attr("x2",c.x).attr("y2",c.y-5).attr("stroke",k?"#000000":"#fff").attr("class",`commit ${b.id} ${d}`);else{let g=a.append("circle");if(g.attr("cx",c.x),g.attr("cy",c.y),g.attr("r",i?7:10),g.attr("class",`commit ${b.id} commit${T(e,8,j)}`),f===l.MERGE){let f=a.append("circle");f.attr("cx",c.x),f.attr("cy",c.y),f.attr("r",i?5:6),f.attr("class",`commit ${d} ${b.id} commit${T(e,8,j)}`)}if(f===l.REVERSE){let f=a.append("path"),g=i?4:5;f.attr("d",`M ${c.x-g},${c.y-g}L${c.x+g},${c.y+g}M${c.x-g},${c.y+g}L${c.x+g},${c.y-g}`).attr("class",`commit ${d} ${b.id} commit${T(e,8,j)}`)}}},"drawCommitBullet"),ai=(0,i.K)((a,b,c,d,e)=>{if(b.type!==l.CHERRY_PICK&&(b.customId&&b.type===l.MERGE||b.type!==l.MERGE)&&e.showCommitLabel){let f=a.append("g"),g=f.insert("rect").attr("class","commit-label-bkg"),h=f.append("text").attr("x",d).attr("y",c.y+25).attr("class","commit-label").text(b.id),i=h.node()?.getBBox();if(i&&(g.attr("x",c.posWithOffset-i.width/2-2).attr("y",c.y+13.5).attr("width",i.width+4).attr("height",i.height+4),"TB"===Z||"BT"===Z?(g.attr("x",c.x-(i.width+16+5)).attr("y",c.y-12),h.attr("x",c.x-(i.width+16)).attr("y",c.y+i.height-12)):h.attr("x",c.posWithOffset-i.width/2),e.rotateCommitLabel))if("TB"===Z||"BT"===Z)h.attr("transform","rotate(-45, "+c.x+", "+c.y+")"),g.attr("transform","rotate(-45, "+c.x+", "+c.y+")");else{let a=-7.5-(i.width+10)/25*9.5,b=10+i.width/25*8.5;f.attr("transform","translate("+a+", "+b+") rotate(-45, "+d+", "+c.y+")")}}},"drawCommitLabel"),aj=(0,i.K)((a,b,c,d)=>{if(b.tags.length>0){let e=0,f=0,g=0,h=[];for(let d of b.tags.reverse()){let b=a.insert("polygon"),i=a.append("circle"),j=a.append("text").attr("y",c.y-16-e).attr("class","tag-label").text(d),k=j.node()?.getBBox();if(!k)throw Error("Tag bbox not found");f=Math.max(f,k.width),g=Math.max(g,k.height),j.attr("x",c.posWithOffset-k.width/2),h.push({tag:j,hole:i,rect:b,yOffset:e}),e+=20}for(let{tag:a,hole:b,rect:e,yOffset:i}of h){let h=g/2,j=c.y-19.2-i;if(e.attr("class","tag-label-bkg").attr("points",`
|
|
2
2
|
${d-f/2-2},${j+2}
|
|
3
3
|
${d-f/2-2},${j-2}
|
|
4
4
|
${c.posWithOffset-f/2-4},${j-h-2}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";exports.id=6288,exports.ids=[6288],exports.modules={6288:(a,b,c)=>{c.d(b,{AC:()=>D,B_:()=>r,Ef:()=>o,Es:()=>I,FZ:()=>m,Kf:()=>J,Lf:()=>C,NJ:()=>q,Nt:()=>H,Ok:()=>E,PB:()=>s,R0:()=>w,WD:()=>u,bJ:()=>p,cV:()=>t,iu:()=>y,rN:()=>F,ss:()=>x,v$:()=>n,y1:()=>v,yi:()=>A});var d=c(55511),e=c(66737),f=c(29742),g=c(71856);function h(a,b){return{id:a.id,projectKey:a.projectKey,name:a.name,isSystem:1===a.isSystem,taskId:a.taskId,sortOrder:a.sortOrder,created:a.created,updated:a.updated,nodeCount:b}}function i(a){return{id:a.id,boardId:a.boardId,kind:a.kind,refId:a.refId,x:a.x,y:a.y,w:a.w,h:a.h,expanded:1===a.expanded,props:function(a){try{let b=JSON.parse(a);return b&&"object"==typeof b&&!Array.isArray(b)?b:{}}catch{return{}}}(a.props),created:a.created,updated:a.updated}}function j(a){return{id:a.id,boardId:a.boardId,fromId:a.fromId,toId:a.toId,label:a.label,color:a.color,dashed:1===a.dashed,created:a.created,updated:a.updated}}function k(a){return(0,e.Lf)().prepare("SELECT COUNT(*) AS n FROM board_nodes WHERE board_id = ?").get(a).n}function l(a){return(0,e.Lf)().prepare("SELECT id, project_key AS projectKey, name, is_system AS isSystem, task_id AS taskId, sort_order AS sortOrder, created, updated FROM boards WHERE id = ?").get(a)}function m(){return{id:g.p,projectKey:"",name:"running",isSystem:!0,taskId:null,sortOrder:0,created:0,updated:0,nodeCount:0}}function n(a){if(a===g.p)return m();let b=l(a);return b?h(b,k(b.id)):void 0}function o(a){return(0,e.Lf)().prepare("SELECT id, project_key AS projectKey, name, is_system AS isSystem, task_id AS taskId, sort_order AS sortOrder, created, updated FROM boards WHERE project_key = ? ORDER BY sort_order, created, rowid").all(a).map(a=>h(a,k(a.id)))}function p(a,b){let c=(0,e.Lf)();if(0===b.length)return o(a);c.exec("BEGIN");try{let d=c.prepare("UPDATE boards SET sort_order = ?, updated = ? WHERE id = ? AND project_key = ?");b.forEach((b,c)=>{let e=d.run(c,Date.now(),b,a);if(0===e.changes)throw Error(`board ${b} does not belong to project ${a}`)}),c.exec("COMMIT")}catch(a){throw c.exec("ROLLBACK"),a}return o(a)}function q(a,b,c){let f=b.trim();if(!a)throw Error("projectKey is required");if(!f)throw Error("name must not be empty");let g=c??(0,d.randomUUID)(),h=Date.now(),i=(0,e.Lf)().prepare("SELECT MIN(sort_order) AS minOrder FROM boards WHERE project_key = ?").get(a),j=null===i.minOrder?0:i.minOrder-1;return(0,e.Lf)().prepare("INSERT INTO boards (id, project_key, name, is_system, task_id, sort_order, created, updated) VALUES (?, ?, ?, 0, ?, ?, ?, ?)").run(g,a,f,c??null,j,h,h),{id:g,projectKey:a,name:f,isSystem:!1,taskId:c??null,sortOrder:j,created:h,updated:h,nodeCount:0}}function r(a,b,c){let d=(0,e.Lf)(),f="SELECT id, project_key AS projectKey, name, is_system AS isSystem, task_id AS taskId, sort_order AS sortOrder, created, updated FROM boards WHERE task_id = ?",g=d.prepare(f).get(a);if(g)return h(g,k(g.id));let i=c.trim(),j=Date.now(),l=d.prepare("SELECT MIN(sort_order) AS minOrder FROM boards WHERE project_key = ?").get(b),m=null===l.minOrder?0:l.minOrder-1;d.prepare("INSERT OR IGNORE INTO boards (id, project_key, name, is_system, task_id, sort_order, created, updated) VALUES (?, ?, ?, 0, ?, ?, ?, ?)").run(a,b,i,a,m,j,j);let n=d.prepare(f).get(a);if(!n)throw Error(`Failed to create task board for task ${a}`);return h(n,k(n.id))}function s(a,b){if(a===g.p)return null;let c=b.trim();if(!c)throw Error("name must not be empty");let d=(0,e.Lf)(),f=l(a);if(!f)return null;let i=Date.now();return d.prepare("UPDATE boards SET name = ?, updated = ? WHERE id = ?").run(c,i,a),h({...f,name:c,updated:i},k(a))}function t(a){(0,e.Lf)().prepare("DELETE FROM board_nodes WHERE board_id = ?").run(a),(0,e.Lf)().prepare("DELETE FROM board_edges WHERE board_id = ?").run(a),(0,e.Lf)().prepare("DELETE FROM board_view WHERE board_id = ?").run(a),(0,e.Lf)().prepare("DELETE FROM boards WHERE id = ?").run(a)}function u(a){if(a===g.p)return!1;let b=(0,e.Lf)();if(!l(a))return!1;b.exec("BEGIN");try{t(a),b.exec("COMMIT")}catch(a){throw b.exec("ROLLBACK"),a}return!0}function v(a,b){(0,e.Lf)().prepare("UPDATE boards SET name = ?, updated = ? WHERE task_id = ?").run(b,Date.now(),a)}function w(a){let b=n(a);if(!b)return null;let c=(0,e.Lf)().prepare("SELECT id, board_id AS boardId, kind, ref_id AS refId, x, y, w, h, expanded, props, created, updated FROM board_nodes WHERE board_id = ? ORDER BY created, rowid").all(a),d=(0,e.Lf)().prepare("SELECT id, board_id AS boardId, from_id AS fromId, to_id AS toId, label, color, dashed, created, updated FROM board_edges WHERE board_id = ? ORDER BY created, rowid").all(a),f=(0,e.Lf)().prepare("SELECT board_id AS boardId, camera_x AS cameraX, camera_y AS cameraY, camera_z AS cameraZ, updated FROM board_view WHERE board_id = ?").get(a);return{board:b,nodes:c.map(i),edges:d.map(j),view:f?{boardId:f.boardId,cameraX:f.cameraX,cameraY:f.cameraY,cameraZ:f.cameraZ,updated:f.updated}:null}}function x(a,b,c){if(a===g.p)return!1;let d=(0,e.Lf)(),f=l(a);if(!f)return!1;if(c?.baseUpdated!==void 0&&c.baseUpdated!==f.updated)return"conflict";if(!c?.allowEmpty&&void 0!==b.nodes&&0===b.nodes.length&&d.prepare("SELECT COUNT(*) c FROM board_nodes WHERE board_id = ?").get(a).c>0)return"empty-overwrite";let h=Date.now();d.exec("BEGIN");try{if(b.nodes){d.prepare("DELETE FROM board_nodes WHERE board_id = ?").run(a);let c=d.prepare("INSERT INTO board_nodes (id, board_id, kind, ref_id, x, y, w, h, expanded, props, created, updated) VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?)");for(let d of b.nodes)c.run(d.id,a,d.kind,d.refId,d.x,d.y,d.w,d.h,+!!d.expanded,JSON.stringify(d.props??{}),d.created||h,h)}if(b.edges){d.prepare("DELETE FROM board_edges WHERE board_id = ?").run(a);let c=d.prepare("INSERT INTO board_edges (id, board_id, from_id, to_id, label, color, dashed, created, updated) VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?)");for(let d of b.edges)c.run(d.id,a,d.fromId,d.toId,d.label??null,d.color??null,+!!d.dashed,d.created||h,h)}void 0!==b.view&&(d.prepare("DELETE FROM board_view WHERE board_id = ?").run(a),b.view&&d.prepare("INSERT INTO board_view (board_id, camera_x, camera_y, camera_z, updated) VALUES (?, ?, ?, ?, ?)").run(a,b.view.cameraX??0,b.view.cameraY??0,b.view.cameraZ??1,h)),d.prepare("UPDATE boards SET updated = ? WHERE id = ?").run(h,a),d.exec("COMMIT")}catch(a){throw d.exec("ROLLBACK"),a}return!0}function y(a,b){if(a===g.p||!l(a))return null;let c=(0,d.randomUUID)(),f=Date.now();return(0,e.Lf)().prepare("INSERT INTO board_nodes (id, board_id, kind, ref_id, x, y, w, h, expanded, props, created, updated) VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?)").run(c,a,b.kind??"session",b.refId??null,b.x,b.y,b.w??0,b.h??0,+!!b.expanded,JSON.stringify(b.props??{}),f,f),(0,e.Lf)().prepare("UPDATE boards SET updated = ? WHERE id = ?").run(f,a),z(a,c)??null}function z(a,b){let c=(0,e.Lf)().prepare("SELECT id, board_id AS boardId, kind, ref_id AS refId, x, y, w, h, expanded, props, created, updated FROM board_nodes WHERE board_id = ? AND id = ?").get(a,b);return c?i(c):void 0}function A(a){let b=(0,e.Lf)().prepare("SELECT id, board_id AS boardId, kind, ref_id AS refId, x, y, w, h, expanded, props, created, updated FROM board_nodes WHERE id = ?").get(a);return b?i(b):void 0}function B(a,b,c){let d="SELECT id, board_id AS boardId, kind, ref_id AS refId, x, y, w, h, expanded, props, created, updated FROM board_nodes "+(c?"WHERE board_id = ? AND ref_id = ? AND kind = ?":"WHERE board_id = ? AND ref_id = ?"),f=c?(0,e.Lf)().prepare(d).get(a,b,c):(0,e.Lf)().prepare(d).get(a,b);return f?i(f):void 0}function C(a,b,c){if(a===g.p)return null;let d=(0,e.Lf)(),f=z(a,b);if(!f)return null;let h=Date.now(),i={refId:void 0!==c.refId?c.refId:f.refId,x:c.x??f.x,y:c.y??f.y,w:c.w??f.w,h:c.h??f.h,expanded:c.expanded??f.expanded,props:void 0!==c.props?{...f.props,...c.props}:f.props};return d.prepare("UPDATE board_nodes SET ref_id = ?, x = ?, y = ?, w = ?, h = ?, expanded = ?, props = ?, updated = ? WHERE board_id = ? AND id = ?").run(i.refId,i.x,i.y,i.w,i.h,+!!i.expanded,JSON.stringify(i.props),h,a,b),d.prepare("UPDATE boards SET updated = ? WHERE id = ?").run(h,a),z(a,b)}function D(a,b){if(a===g.p)return!1;let c=(0,e.Lf)();if(!z(a,b))return!1;let d=Date.now();c.exec("BEGIN");try{c.prepare("DELETE FROM board_edges WHERE board_id = ? AND (from_id = ? OR to_id = ?)").run(a,b,b),c.prepare("DELETE FROM board_nodes WHERE board_id = ? AND id = ?").run(a,b),c.prepare("UPDATE boards SET updated = ? WHERE id = ?").run(d,a),c.exec("COMMIT")}catch(a){throw c.exec("ROLLBACK"),a}return!0}function E(a){if(0===a.length)return{deletedNodes:0,deletedEdges:0,boards:[]};let b=(0,e.Lf)(),c=a.map(()=>"?").join(","),d=b.prepare(`SELECT id, board_id AS boardId FROM board_nodes WHERE id IN (${c}) AND board_id != ?`).all(...a,g.p);if(0===d.length)return{deletedNodes:0,deletedEdges:0,boards:[]};let f=d.map(a=>a.id),h=f.map(()=>"?").join(","),i=[...new Set(d.map(a=>a.boardId))],j=Date.now();b.exec("BEGIN");try{let a=b.prepare(`DELETE FROM board_edges WHERE from_id IN (${h}) OR to_id IN (${h})`).run(...f,...f),c=b.prepare(`DELETE FROM board_nodes WHERE id IN (${h})`).run(...f);for(let a of i)b.prepare("UPDATE boards SET updated = ? WHERE id = ?").run(j,a);return b.exec("COMMIT"),{deletedNodes:Number(c.changes),deletedEdges:Number(a.changes),boards:i}}catch(a){throw b.exec("ROLLBACK"),a}}function F(a,b){if(a===g.p||!l(a))return null;let c=(0,e.Lf)(),f=z(a,b.fromId),h=z(a,b.toId);if(!f||!h||b.fromId===b.toId)return null;let i=(0,d.randomUUID)(),j=Date.now();return c.prepare("INSERT INTO board_edges (id, board_id, from_id, to_id, label, color, dashed, created, updated) VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?)").run(i,a,b.fromId,b.toId,b.label??null,b.color??null,+!!b.dashed,j,j),c.prepare("UPDATE boards SET updated = ? WHERE id = ?").run(j,a),G(a,i)??null}function G(a,b){let c=(0,e.Lf)().prepare("SELECT id, board_id AS boardId, from_id AS fromId, to_id AS toId, label, color, dashed, created, updated FROM board_edges WHERE board_id = ? AND id = ?").get(a,b);return c?j(c):void 0}function H(a,b){if(a===g.p)return!1;let c=(0,e.Lf)();if(!G(a,b))return!1;let d=Date.now();return c.prepare("DELETE FROM board_edges WHERE board_id = ? AND id = ?").run(a,b),c.prepare("UPDATE boards SET updated = ? WHERE id = ?").run(d,a),!0}function I(a){let b=(0,e.Lf)(),c=b.prepare("SELECT id, board_id AS boardId FROM board_nodes WHERE kind = 'session' AND ref_id = ?").all(a);if(0===c.length)return{removedNodes:0,boards:[]};let d=Date.now(),f=new Map;b.exec("BEGIN");try{for(let e of(b.prepare("UPDATE task_cards SET session_id = NULL, updated = ? WHERE session_id = ?").run(d,a),c))b.prepare("DELETE FROM board_edges WHERE board_id = ? AND to_id = ? AND label = 'exec'").run(e.boardId,e.id),b.prepare("DELETE FROM board_edges WHERE board_id = ? AND (from_id = ? OR to_id = ?)").run(e.boardId,e.id,e.id),b.prepare("DELETE FROM board_nodes WHERE board_id = ? AND id = ?").run(e.boardId,e.id),b.prepare("UPDATE boards SET updated = ? WHERE id = ?").run(d,e.boardId),f.set(e.boardId,d);return b.exec("COMMIT"),{removedNodes:c.length,boards:[...f.entries()].map(([a,b])=>({boardId:a,updated:b}))}}catch(a){throw b.exec("ROLLBACK"),a}}function J(a){for(let b of(0,e.Lf)().prepare("SELECT id FROM task_cards WHERE board_id = ?").all(a))!function(a){let b=(0,f.XJ)(a);if(!b)return;let c=(0,e.Lf)(),d=B(b.boardId,a,"taskcard");if(!d)return;let g=c.prepare("SELECT id, from_id AS fromId, to_id AS toId, label FROM board_edges WHERE board_id = ? AND from_id = ? AND label IN ('prerequisite', 'related')").all(b.boardId,d.id),h=(0,f.QA)(a).map(a=>{let c=B(b.boardId,a.targetCardId,"taskcard");return c?{toId:c.id,label:a.kind}:null}).filter(a=>null!==a),i=(a,b)=>`${a}:${b}`,j=new Set(h.map(a=>i(a.toId,a.label))),k=new Set(g.map(a=>i(a.toId,a.label??"")));for(let a of g)j.has(i(a.toId,a.label??""))||H(b.boardId,a.id);for(let a of h)k.has(i(a.toId,a.label))||F(b.boardId,{fromId:d.id,toId:a.toId,label:a.label})}(b.id),function(a){let b=(0,f.XJ)(a);if(!b)return;let c=(0,e.Lf)(),d=B(b.boardId,a,"taskcard");if(!d)return;let g=c.prepare("SELECT id, to_id AS toId FROM board_edges WHERE board_id = ? AND from_id = ? AND label = 'exec'").all(b.boardId,d.id),h=null;if(b.sessionId){let a=B(b.boardId,b.sessionId,"session");a&&(h=a.id)}for(let a of g)a.toId!==h&&H(b.boardId,a.id);h&&!g.some(a=>a.toId===h)&&F(b.boardId,{fromId:d.id,toId:h,label:"exec",dashed:!0})}(b.id)}}};
|
|
1
|
+
"use strict";exports.id=6288,exports.ids=[6288],exports.modules={6288:(a,b,c)=>{c.d(b,{B_:()=>q,Ef:()=>l,Es:()=>w,FZ:()=>j,NJ:()=>p,Ok:()=>v,PB:()=>r,PV:()=>m,WD:()=>t,bJ:()=>n,cV:()=>s,getBoard:()=>k,y1:()=>u,yx:()=>o});var d=c(55511),e=c(66737);c(29742);var f=c(71856);function g(a,b){return{id:a.id,projectKey:a.projectKey,name:a.name,isSystem:1===a.isSystem,taskId:a.taskId,sortOrder:a.sortOrder,created:a.created,updated:a.updated,nodeCount:b}}function h(a){return(0,e.Lf)().prepare("SELECT COUNT(*) AS n FROM board_nodes WHERE board_id = ?").get(a).n}function i(a){return(0,e.Lf)().prepare("SELECT id, project_key AS projectKey, name, is_system AS isSystem, task_id AS taskId, sort_order AS sortOrder, created, updated FROM boards WHERE id = ?").get(a)}function j(){return{id:f.p,projectKey:"",name:"running",isSystem:!0,taskId:null,sortOrder:0,created:0,updated:0,nodeCount:0}}function k(a){if(a===f.p)return j();let b=i(a);return b?g(b,h(b.id)):void 0}function l(a){return(0,e.Lf)().prepare("SELECT id, project_key AS projectKey, name, is_system AS isSystem, task_id AS taskId, sort_order AS sortOrder, created, updated FROM boards WHERE project_key = ? ORDER BY sort_order, created, rowid").all(a).map(a=>g(a,h(a.id)))}function m(){return(0,e.Lf)().prepare("SELECT id, project_key AS projectKey, name, is_system AS isSystem, task_id AS taskId, sort_order AS sortOrder, created, updated FROM boards WHERE is_system = 0 ORDER BY sort_order, created, rowid").all().map(a=>g(a,h(a.id)))}function n(a,b){let c=(0,e.Lf)();if(0===b.length)return l(a);c.exec("BEGIN");try{let d=c.prepare("UPDATE boards SET sort_order = ?, updated = ? WHERE id = ? AND project_key = ?");b.forEach((b,c)=>{let e=d.run(c,Date.now(),b,a);if(0===e.changes)throw Error(`board ${b} does not belong to project ${a}`)}),c.exec("COMMIT")}catch(a){throw c.exec("ROLLBACK"),a}return l(a)}function o(a){let b=(0,e.Lf)();if(0===a.length)return m();b.exec("BEGIN");try{let c=b.prepare("UPDATE boards SET sort_order = ?, updated = ? WHERE id = ? AND is_system = 0 AND task_id IS NULL");a.forEach((a,b)=>{let d=c.run(b,Date.now(),a);if(0===d.changes)throw Error(`board ${a} does not belong to global manual scope`)}),b.exec("COMMIT")}catch(a){throw b.exec("ROLLBACK"),a}return m()}function p(a,b,c){let f=b.trim();if(!f)throw Error("name must not be empty");let g=c??(0,d.randomUUID)(),h=Date.now(),i=a?(0,e.Lf)().prepare("SELECT MIN(sort_order) AS minOrder FROM boards WHERE project_key = ?").get(a):(0,e.Lf)().prepare("SELECT MIN(sort_order) AS minOrder FROM boards WHERE is_system = 0 AND task_id IS NULL").get(),j=null===i.minOrder?0:i.minOrder-1;return(0,e.Lf)().prepare("INSERT INTO boards (id, project_key, name, is_system, task_id, sort_order, created, updated) VALUES (?, ?, ?, 0, ?, ?, ?, ?)").run(g,a,f,c??null,j,h,h),{id:g,projectKey:a,name:f,isSystem:!1,taskId:c??null,sortOrder:j,created:h,updated:h,nodeCount:0}}function q(a,b,c){let d=(0,e.Lf)(),f="SELECT id, project_key AS projectKey, name, is_system AS isSystem, task_id AS taskId, sort_order AS sortOrder, created, updated FROM boards WHERE task_id = ?",i=d.prepare(f).get(a);if(i)return g(i,h(i.id));let j=c.trim(),k=Date.now(),l=d.prepare("SELECT MIN(sort_order) AS minOrder FROM boards WHERE project_key = ?").get(b),m=null===l.minOrder?0:l.minOrder-1;d.prepare("INSERT OR IGNORE INTO boards (id, project_key, name, is_system, task_id, sort_order, created, updated) VALUES (?, ?, ?, 0, ?, ?, ?, ?)").run(a,b,j,a,m,k,k);let n=d.prepare(f).get(a);if(!n)throw Error(`Failed to create task board for task ${a}`);return g(n,h(n.id))}function r(a,b){if(a===f.p)return null;let c=b.trim();if(!c)throw Error("name must not be empty");let d=(0,e.Lf)(),j=i(a);if(!j)return null;let k=Date.now();return d.prepare("UPDATE boards SET name = ?, updated = ? WHERE id = ?").run(c,k,a),g({...j,name:c,updated:k},h(a))}function s(a){(0,e.Lf)().prepare("DELETE FROM board_nodes WHERE board_id = ?").run(a),(0,e.Lf)().prepare("DELETE FROM board_edges WHERE board_id = ?").run(a),(0,e.Lf)().prepare("DELETE FROM board_view WHERE board_id = ?").run(a),(0,e.Lf)().prepare("DELETE FROM boards WHERE id = ?").run(a)}function t(a){if(a===f.p)return!1;let b=(0,e.Lf)();if(!i(a))return!1;b.exec("BEGIN");try{s(a),b.exec("COMMIT")}catch(a){throw b.exec("ROLLBACK"),a}return!0}function u(a,b){(0,e.Lf)().prepare("UPDATE boards SET name = ?, updated = ? WHERE task_id = ?").run(b,Date.now(),a)}function v(a){if(0===a.length)return{deletedNodes:0,deletedEdges:0,boards:[]};let b=(0,e.Lf)(),c=a.map(()=>"?").join(","),d=b.prepare(`SELECT id, board_id AS boardId FROM board_nodes WHERE id IN (${c}) AND board_id != ?`).all(...a,f.p);if(0===d.length)return{deletedNodes:0,deletedEdges:0,boards:[]};let g=d.map(a=>a.id),h=g.map(()=>"?").join(","),i=[...new Set(d.map(a=>a.boardId))],j=Date.now();b.exec("BEGIN");try{let a=b.prepare(`DELETE FROM board_edges WHERE from_id IN (${h}) OR to_id IN (${h})`).run(...g,...g),c=b.prepare(`DELETE FROM board_nodes WHERE id IN (${h})`).run(...g);for(let a of i)b.prepare("UPDATE boards SET updated = ? WHERE id = ?").run(j,a);return b.exec("COMMIT"),{deletedNodes:Number(c.changes),deletedEdges:Number(a.changes),boards:i}}catch(a){throw b.exec("ROLLBACK"),a}}function w(a){let b=(0,e.Lf)(),c=b.prepare("SELECT id, board_id AS boardId FROM board_nodes WHERE kind = 'session' AND ref_id = ?").all(a);if(0===c.length)return{removedNodes:0,boards:[]};let d=Date.now(),f=new Map;b.exec("BEGIN");try{for(let e of(b.prepare("UPDATE task_cards SET session_id = NULL, updated = ? WHERE session_id = ?").run(d,a),c))b.prepare("DELETE FROM board_edges WHERE board_id = ? AND to_id = ? AND label = 'exec'").run(e.boardId,e.id),b.prepare("DELETE FROM board_edges WHERE board_id = ? AND (from_id = ? OR to_id = ?)").run(e.boardId,e.id,e.id),b.prepare("DELETE FROM board_nodes WHERE board_id = ? AND id = ?").run(e.boardId,e.id),b.prepare("UPDATE boards SET updated = ? WHERE id = ?").run(d,e.boardId),f.set(e.boardId,d);return b.exec("COMMIT"),{removedNodes:c.length,boards:[...f.entries()].map(([a,b])=>({boardId:a,updated:b}))}}catch(a){throw b.exec("ROLLBACK"),a}}}};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
"use strict";exports.id=6366,exports.ids=[6366],exports.modules={1487:(a,b,c)=>{c.d(b,{P:()=>g});var d=c(45313),e=c(58715),f=c(95097),g=(0,f.K)((a,b,c,f)=>{a.attr("class",c);let{width:g,height:j,x:k,y:l}=h(a,b);(0,d.a$)(a,j,g,f);let m=i(k,l,g,j,b);a.attr("viewBox",m),e.R.debug(`viewBox configured: ${m} with padding: ${b}`)},"setupViewPortForSVG"),h=(0,f.K)((a,b)=>{let c=a.node()?.getBBox()||{width:0,height:0,x:0,y:0};return{width:c.width+2*b,height:c.height+2*b,x:c.x,y:c.y}},"calculateDimensionsWithPadding"),i=(0,f.K)((a,b,c,d,e)=>`${a-e} ${b-e} ${c} ${d}`,"createViewBox")},30917:(a,b,c)=>{c.d(b,{A:()=>f});var d=c(95097),e=c(69085),f=(0,d.K)((a,b)=>{let c;return"sandbox"===b&&(c=(0,e.Ltv)("#i"+a)),("sandbox"===b?(0,e.Ltv)(c.nodes()[0].contentDocument.body):(0,e.Ltv)("body")).select(`[id="${a}"]`)},"getDiagramElement")},56366:(a,b,c)=>{c.d(b,{diagram:()=>u});var d=c(30917),e=c(1487),f=c(78832);c(32844),c(11878),c(8312),c(7423),c(69819),c(59343),c(73669);var g=c(64922),h=c(45313),i=c(58715),j=c(95097),k=c(69085),l=c(75899),m=c(14120),n=function(){var a=(0,j.K)(function(a,b,c,d){for(c=c||{},d=a.length;d--;c[a[d]]=b);return c},"o"),b=[6,8,10,22,24,26,28,33,34,35,36,37,40,43,44,48,50,51,52],c=[1,10],d=[1,11],e=[1,12],f=[1,13],g=[1,23],h=[1,24],i=[1,25],k=[1,26],l=[1,27],m=[1,19],n=[1,28],o=[1,29],p=[1,20],q=[1,18],r=[1,21],s=[1,22],t=[1,36],u=[1,37],v=[1,38],w=[1,39],x=[1,40],y=[6,8,10,13,15,17,20,21,22,24,26,28,33,34,35,36,37,40,43,44,48,50,51,52,66,67,68,69,70],z=[1,45],A=[1,46],B=[1,55],C=[40,48,50,51,52,71,72],D=[1,66],E=[1,64],F=[1,61],G=[1,65],H=[1,67],I=[6,8,10,13,17,22,24,26,28,33,34,35,36,37,40,41,42,43,44,48,49,50,51,52,66,67,68,69,70],J=[66,67,68,69,70],K=[1,85],L=[1,84],M=[1,82],N=[1,83],O=[6,10,42,47],P=[6,10,13,41,42,47,48,49],Q=[1,93],R=[1,92],S=[1,91],T=[19,58],U=[1,102],V=[1,101],W=[19,58,61,63],X={trace:(0,j.K)(function(){},"trace"),yy:{},symbols_:{error:2,start:3,ER_DIAGRAM:4,document:5,EOF:6,line:7,SPACE:8,statement:9,NEWLINE:10,entityName:11,relSpec:12,COLON:13,role:14,STYLE_SEPARATOR:15,idList:16,BLOCK_START:17,attributes:18,BLOCK_STOP:19,SQS:20,SQE:21,title:22,title_value:23,acc_title:24,acc_title_value:25,acc_descr:26,acc_descr_value:27,acc_descr_multiline_value:28,direction:29,classDefStatement:30,classStatement:31,styleStatement:32,direction_tb:33,direction_bt:34,direction_rl:35,direction_lr:36,CLASSDEF:37,stylesOpt:38,separator:39,UNICODE_TEXT:40,STYLE_TEXT:41,COMMA:42,CLASS:43,STYLE:44,style:45,styleComponent:46,SEMI:47,NUM:48,BRKT:49,ENTITY_NAME:50,DECIMAL_NUM:51,ENTITY_ONE:52,attribute:53,attributeType:54,attributeName:55,attributeKeyTypeList:56,attributeComment:57,ATTRIBUTE_WORD:58,"?":59,attributeKeyType:60,",":61,ATTRIBUTE_KEY:62,COMMENT:63,cardinality:64,relType:65,ZERO_OR_ONE:66,ZERO_OR_MORE:67,ONE_OR_MORE:68,ONLY_ONE:69,MD_PARENT:70,NON_IDENTIFYING:71,IDENTIFYING:72,WORD:73,$accept:0,$end:1},terminals_:{2:"error",4:"ER_DIAGRAM",6:"EOF",8:"SPACE",10:"NEWLINE",13:"COLON",15:"STYLE_SEPARATOR",17:"BLOCK_START",19:"BLOCK_STOP",20:"SQS",21:"SQE",22:"title",23:"title_value",24:"acc_title",25:"acc_title_value",26:"acc_descr",27:"acc_descr_value",28:"acc_descr_multiline_value",33:"direction_tb",34:"direction_bt",35:"direction_rl",36:"direction_lr",37:"CLASSDEF",40:"UNICODE_TEXT",41:"STYLE_TEXT",42:"COMMA",43:"CLASS",44:"STYLE",47:"SEMI",48:"NUM",49:"BRKT",50:"ENTITY_NAME",51:"DECIMAL_NUM",52:"ENTITY_ONE",58:"ATTRIBUTE_WORD",59:"?",61:",",62:"ATTRIBUTE_KEY",63:"COMMENT",66:"ZERO_OR_ONE",67:"ZERO_OR_MORE",68:"ONE_OR_MORE",69:"ONLY_ONE",70:"MD_PARENT",71:"NON_IDENTIFYING",72:"IDENTIFYING",73:"WORD"},productions_:[0,[3,3],[5,0],[5,2],[7,2],[7,1],[7,1],[7,1],[9,5],[9,9],[9,7],[9,7],[9,4],[9,6],[9,3],[9,5],[9,1],[9,3],[9,7],[9,9],[9,6],[9,8],[9,4],[9,6],[9,2],[9,2],[9,2],[9,1],[9,1],[9,1],[9,1],[9,1],[29,1],[29,1],[29,1],[29,1],[30,4],[16,1],[16,1],[16,3],[16,3],[31,3],[32,4],[38,1],[38,3],[45,1],[45,2],[39,1],[39,1],[39,1],[46,1],[46,1],[46,1],[46,1],[11,1],[11,1],[11,1],[11,1],[11,1],[18,1],[18,2],[53,2],[53,3],[53,3],[53,4],[54,1],[54,2],[55,1],[56,1],[56,3],[60,1],[57,1],[12,3],[64,1],[64,1],[64,1],[64,1],[64,1],[65,1],[65,1],[14,1],[14,1],[14,1]],performAction:(0,j.K)(function(a,b,c,d,e,f,g){var h=f.length-1;switch(e){case 1:break;case 2:case 6:case 7:this.$=[];break;case 3:f[h-1].push(f[h]),this.$=f[h-1];break;case 4:case 5:case 55:case 56:case 57:case 58:case 82:case 65:case 67:case 70:this.$=f[h];break;case 8:d.addEntity(f[h-4]),d.addEntity(f[h-2]),d.addRelationship(f[h-4],f[h],f[h-2],f[h-3]);break;case 9:d.addEntity(f[h-8]),d.addEntity(f[h-4]),d.addRelationship(f[h-8],f[h],f[h-4],f[h-5]),d.setClass([f[h-8]],f[h-6]),d.setClass([f[h-4]],f[h-2]);break;case 10:d.addEntity(f[h-6]),d.addEntity(f[h-2]),d.addRelationship(f[h-6],f[h],f[h-2],f[h-3]),d.setClass([f[h-6]],f[h-4]);break;case 11:d.addEntity(f[h-6]),d.addEntity(f[h-4]),d.addRelationship(f[h-6],f[h],f[h-4],f[h-5]),d.setClass([f[h-4]],f[h-2]);break;case 12:d.addEntity(f[h-3]),d.addAttributes(f[h-3],f[h-1]);break;case 13:d.addEntity(f[h-5]),d.addAttributes(f[h-5],f[h-1]),d.setClass([f[h-5]],f[h-3]);break;case 14:d.addEntity(f[h-2]);break;case 15:d.addEntity(f[h-4]),d.setClass([f[h-4]],f[h-2]);break;case 16:d.addEntity(f[h]);break;case 17:d.addEntity(f[h-2]),d.setClass([f[h-2]],f[h]);break;case 18:d.addEntity(f[h-6],f[h-4]),d.addAttributes(f[h-6],f[h-1]);break;case 19:d.addEntity(f[h-8],f[h-6]),d.addAttributes(f[h-8],f[h-1]),d.setClass([f[h-8]],f[h-3]);break;case 20:d.addEntity(f[h-5],f[h-3]);break;case 21:d.addEntity(f[h-7],f[h-5]),d.setClass([f[h-7]],f[h-2]);break;case 22:d.addEntity(f[h-3],f[h-1]);break;case 23:d.addEntity(f[h-5],f[h-3]),d.setClass([f[h-5]],f[h]);break;case 24:case 25:this.$=f[h].trim(),d.setAccTitle(this.$);break;case 26:case 27:this.$=f[h].trim(),d.setAccDescription(this.$);break;case 32:d.setDirection("TB");break;case 33:d.setDirection("BT");break;case 34:d.setDirection("RL");break;case 35:d.setDirection("LR");break;case 36:this.$=f[h-3],d.addClass(f[h-2],f[h-1]);break;case 37:case 38:case 59:case 68:case 43:this.$=[f[h]];break;case 39:case 40:this.$=f[h-2].concat([f[h]]);break;case 41:this.$=f[h-2],d.setClass(f[h-1],f[h]);break;case 42:this.$=f[h-3],d.addCssStyles(f[h-2],f[h-1]);break;case 44:case 69:f[h-2].push(f[h]),this.$=f[h-2];break;case 46:case 66:this.$=f[h-1]+f[h];break;case 54:case 80:case 81:case 71:this.$=f[h].replace(/"/g,"");break;case 60:f[h].push(f[h-1]),this.$=f[h];break;case 61:this.$={type:f[h-1],name:f[h]};break;case 62:this.$={type:f[h-2],name:f[h-1],keys:f[h]};break;case 63:this.$={type:f[h-2],name:f[h-1],comment:f[h]};break;case 64:this.$={type:f[h-3],name:f[h-2],keys:f[h-1],comment:f[h]};break;case 72:this.$={cardA:f[h],relType:f[h-1],cardB:f[h-2]};break;case 73:this.$=d.Cardinality.ZERO_OR_ONE;break;case 74:this.$=d.Cardinality.ZERO_OR_MORE;break;case 75:this.$=d.Cardinality.ONE_OR_MORE;break;case 76:this.$=d.Cardinality.ONLY_ONE;break;case 77:this.$=d.Cardinality.MD_PARENT;break;case 78:this.$=d.Identification.NON_IDENTIFYING;break;case 79:this.$=d.Identification.IDENTIFYING}},"anonymous"),table:[{3:1,4:[1,2]},{1:[3]},a(b,[2,2],{5:3}),{6:[1,4],7:5,8:[1,6],9:7,10:[1,8],11:9,22:c,24:d,26:e,28:f,29:14,30:15,31:16,32:17,33:g,34:h,35:i,36:k,37:l,40:m,43:n,44:o,48:p,50:q,51:r,52:s},a(b,[2,7],{1:[2,1]}),a(b,[2,3]),{9:30,11:9,22:c,24:d,26:e,28:f,29:14,30:15,31:16,32:17,33:g,34:h,35:i,36:k,37:l,40:m,43:n,44:o,48:p,50:q,51:r,52:s},a(b,[2,5]),a(b,[2,6]),a(b,[2,16],{12:31,64:35,15:[1,32],17:[1,33],20:[1,34],66:t,67:u,68:v,69:w,70:x}),{23:[1,41]},{25:[1,42]},{27:[1,43]},a(b,[2,27]),a(b,[2,28]),a(b,[2,29]),a(b,[2,30]),a(b,[2,31]),a(y,[2,54]),a(y,[2,55]),a(y,[2,56]),a(y,[2,57]),a(y,[2,58]),a(b,[2,32]),a(b,[2,33]),a(b,[2,34]),a(b,[2,35]),{16:44,40:z,41:A},{16:47,40:z,41:A},{16:48,40:z,41:A},a(b,[2,4]),{11:49,40:m,48:p,50:q,51:r,52:s},{16:50,40:z,41:A},{18:51,19:[1,52],53:53,54:54,58:B},{11:56,40:m,48:p,50:q,51:r,52:s},{65:57,71:[1,58],72:[1,59]},a(C,[2,73]),a(C,[2,74]),a(C,[2,75]),a(C,[2,76]),a(C,[2,77]),a(b,[2,24]),a(b,[2,25]),a(b,[2,26]),{13:D,38:60,41:E,42:F,45:62,46:63,48:G,49:H},a(I,[2,37]),a(I,[2,38]),{16:68,40:z,41:A,42:F},{13:D,38:69,41:E,42:F,45:62,46:63,48:G,49:H},{13:[1,70],15:[1,71]},a(b,[2,17],{64:35,12:72,17:[1,73],42:F,66:t,67:u,68:v,69:w,70:x}),{19:[1,74]},a(b,[2,14]),{18:75,19:[2,59],53:53,54:54,58:B},{55:76,58:[1,77]},{58:[2,65],59:[1,78]},{21:[1,79]},{64:80,66:t,67:u,68:v,69:w,70:x},a(J,[2,78]),a(J,[2,79]),{6:K,10:L,39:81,42:M,47:N},{40:[1,86],41:[1,87]},a(O,[2,43],{46:88,13:D,41:E,48:G,49:H}),a(P,[2,45]),a(P,[2,50]),a(P,[2,51]),a(P,[2,52]),a(P,[2,53]),a(b,[2,41],{42:F}),{6:K,10:L,39:89,42:M,47:N},{14:90,40:Q,50:R,73:S},{16:94,40:z,41:A},{11:95,40:m,48:p,50:q,51:r,52:s},{18:96,19:[1,97],53:53,54:54,58:B},a(b,[2,12]),{19:[2,60]},a(T,[2,61],{56:98,57:99,60:100,62:U,63:V}),a([19,58,62,63],[2,67]),{58:[2,66]},a(b,[2,22],{15:[1,104],17:[1,103]}),a([40,48,50,51,52],[2,72]),a(b,[2,36]),{13:D,41:E,45:105,46:63,48:G,49:H},a(b,[2,47]),a(b,[2,48]),a(b,[2,49]),a(I,[2,39]),a(I,[2,40]),a(P,[2,46]),a(b,[2,42]),a(b,[2,8]),a(b,[2,80]),a(b,[2,81]),a(b,[2,82]),{13:[1,106],42:F},{13:[1,108],15:[1,107]},{19:[1,109]},a(b,[2,15]),a(T,[2,62],{57:110,61:[1,111],63:V}),a(T,[2,63]),a(W,[2,68]),a(T,[2,71]),a(W,[2,70]),{18:112,19:[1,113],53:53,54:54,58:B},{16:114,40:z,41:A},a(O,[2,44],{46:88,13:D,41:E,48:G,49:H}),{14:115,40:Q,50:R,73:S},{16:116,40:z,41:A},{14:117,40:Q,50:R,73:S},a(b,[2,13]),a(T,[2,64]),{60:118,62:U},{19:[1,119]},a(b,[2,20]),a(b,[2,23],{17:[1,120],42:F}),a(b,[2,11]),{13:[1,121],42:F},a(b,[2,10]),a(W,[2,69]),a(b,[2,18]),{18:122,19:[1,123],53:53,54:54,58:B},{14:124,40:Q,50:R,73:S},{19:[1,125]},a(b,[2,21]),a(b,[2,9]),a(b,[2,19])],defaultActions:{75:[2,60],78:[2,66]},parseError:(0,j.K)(function(a,b){if(b.recoverable)this.trace(a);else{var c=Error(a);throw c.hash=b,c}},"parseError"),parse:(0,j.K)(function(a){var b=this,c=[0],d=[],e=[null],f=[],g=this.table,h="",i=0,k=0,l=0,m=f.slice.call(arguments,1),n=Object.create(this.lexer),o={};for(var p in this.yy)Object.prototype.hasOwnProperty.call(this.yy,p)&&(o[p]=this.yy[p]);n.setInput(a,o),o.lexer=n,o.parser=this,void 0===n.yylloc&&(n.yylloc={});var q=n.yylloc;f.push(q);var r=n.options&&n.options.ranges;function s(){var a;return"number"!=typeof(a=d.pop()||n.lex()||1)&&(a instanceof Array&&(a=(d=a).pop()),a=b.symbols_[a]||a),a}"function"==typeof o.parseError?this.parseError=o.parseError:this.parseError=Object.getPrototypeOf(this).parseError,(0,j.K)(function(a){c.length=c.length-2*a,e.length=e.length-a,f.length=f.length-a},"popStack"),(0,j.K)(s,"lex");for(var t,u,v,w,x,y,z,A,B,C={};;){if(v=c[c.length-1],this.defaultActions[v]?w=this.defaultActions[v]:(null==t&&(t=s()),w=g[v]&&g[v][t]),void 0===w||!w.length||!w[0]){var D="";for(y in B=[],g[v])this.terminals_[y]&&y>2&&B.push("'"+this.terminals_[y]+"'");D=n.showPosition?"Parse error on line "+(i+1)+":\n"+n.showPosition()+"\nExpecting "+B.join(", ")+", got '"+(this.terminals_[t]||t)+"'":"Parse error on line "+(i+1)+": Unexpected "+(1==t?"end of input":"'"+(this.terminals_[t]||t)+"'"),this.parseError(D,{text:n.match,token:this.terminals_[t]||t,line:n.yylineno,loc:q,expected:B})}if(w[0]instanceof Array&&w.length>1)throw Error("Parse Error: multiple actions possible at state: "+v+", token: "+t);switch(w[0]){case 1:c.push(t),e.push(n.yytext),f.push(n.yylloc),c.push(w[1]),t=null,u?(t=u,u=null):(k=n.yyleng,h=n.yytext,i=n.yylineno,q=n.yylloc,l>0&&l--);break;case 2:if(z=this.productions_[w[1]][1],C.$=e[e.length-z],C._$={first_line:f[f.length-(z||1)].first_line,last_line:f[f.length-1].last_line,first_column:f[f.length-(z||1)].first_column,last_column:f[f.length-1].last_column},r&&(C._$.range=[f[f.length-(z||1)].range[0],f[f.length-1].range[1]]),void 0!==(x=this.performAction.apply(C,[h,k,i,o,w[1],e,f].concat(m))))return x;z&&(c=c.slice(0,-1*z*2),e=e.slice(0,-1*z),f=f.slice(0,-1*z)),c.push(this.productions_[w[1]][0]),e.push(C.$),f.push(C._$),A=g[c[c.length-2]][c[c.length-1]],c.push(A);break;case 3:return!0}}return!0},"parse")};function Y(){this.yy={}}return X.lexer={EOF:1,parseError:(0,j.K)(function(a,b){if(this.yy.parser)this.yy.parser.parseError(a,b);else throw Error(a)},"parseError"),setInput:(0,j.K)(function(a,b){return this.yy=b||this.yy||{},this._input=a,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,j.K)(function(){var a=this._input[0];return this.yytext+=a,this.yyleng++,this.offset++,this.match+=a,this.matched+=a,a.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),a},"input"),unput:(0,j.K)(function(a){var b=a.length,c=a.split(/(?:\r\n?|\n)/g);this._input=a+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-b),this.offset-=b;var d=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),c.length-1&&(this.yylineno-=c.length-1);var e=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:c?(c.length===d.length?this.yylloc.first_column:0)+d[d.length-c.length].length-c[0].length:this.yylloc.first_column-b},this.options.ranges&&(this.yylloc.range=[e[0],e[0]+this.yyleng-b]),this.yyleng=this.yytext.length,this},"unput"),more:(0,j.K)(function(){return this._more=!0,this},"more"),reject:(0,j.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,j.K)(function(a){this.unput(this.match.slice(a))},"less"),pastInput:(0,j.K)(function(){var a=this.matched.substr(0,this.matched.length-this.match.length);return(a.length>20?"...":"")+a.substr(-20).replace(/\n/g,"")},"pastInput"),upcomingInput:(0,j.K)(function(){var a=this.match;return a.length<20&&(a+=this._input.substr(0,20-a.length)),(a.substr(0,20)+(a.length>20?"...":"")).replace(/\n/g,"")},"upcomingInput"),showPosition:(0,j.K)(function(){var a=this.pastInput(),b=Array(a.length+1).join("-");return a+this.upcomingInput()+"\n"+b+"^"},"showPosition"),test_match:(0,j.K)(function(a,b){var c,d,e;if(this.options.backtrack_lexer&&(e={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&&(e.yylloc.range=this.yylloc.range.slice(0))),(d=a[0].match(/(?:\r\n?|\n).*/g))&&(this.yylineno+=d.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:d?d[d.length-1].length-d[d.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+a[0].length},this.yytext+=a[0],this.match+=a[0],this.matches=a,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(a[0].length),this.matched+=a[0],c=this.performAction.call(this,this.yy,this,b,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),c)return c;if(this._backtrack)for(var f in e)this[f]=e[f];return!1},"test_match"),next:(0,j.K)(function(){if(this.done)return this.EOF;this._input||(this.done=!0),this._more||(this.yytext="",this.match="");for(var a,b,c,d,e=this._currentRules(),f=0;f<e.length;f++)if((c=this._input.match(this.rules[e[f]]))&&(!b||c[0].length>b[0].length)){if(b=c,d=f,this.options.backtrack_lexer){if(!1!==(a=this.test_match(c,e[f])))return a;if(!this._backtrack)return!1;b=!1;continue}if(!this.options.flex)break}return b?!1!==(a=this.test_match(b,e[d]))&&a:""===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,j.K)(function(){var a=this.next();return a||this.lex()},"lex"),begin:(0,j.K)(function(a){this.conditionStack.push(a)},"begin"),popState:(0,j.K)(function(){return this.conditionStack.length-1>0?this.conditionStack.pop():this.conditionStack[0]},"popState"),_currentRules:(0,j.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,j.K)(function(a){return(a=this.conditionStack.length-1-Math.abs(a||0))>=0?this.conditionStack[a]:"INITIAL"},"topState"),pushState:(0,j.K)(function(a){this.begin(a)},"pushState"),stateStackSize:(0,j.K)(function(){return this.conditionStack.length},"stateStackSize"),options:{"case-insensitive":!0},performAction:(0,j.K)(function(a,b,c,d){switch(c){case 0:return this.begin("acc_title"),24;case 1:return this.popState(),"acc_title_value";case 2:return this.begin("acc_descr"),26;case 3:return this.popState(),"acc_descr_value";case 4:this.begin("acc_descr_multiline");break;case 5:case 29:this.popState();break;case 6:return"acc_descr_multiline_value";case 7:return 33;case 8:return 34;case 9:return 35;case 10:return 36;case 11:return 10;case 12:case 23:case 31:case 38:break;case 13:return 8;case 14:return 50;case 15:return 73;case 16:return 4;case 17:return this.begin("block"),17;case 18:case 19:case 41:return 49;case 20:case 40:return 42;case 21:return 15;case 22:case 39:return 13;case 24:return 62;case 25:case 26:case 28:return 58;case 27:this.begin("block_bq");break;case 30:return 63;case 32:return this.popState(),19;case 33:case 80:return b.yytext[0];case 34:return 20;case 35:return 21;case 36:return this.begin("style"),44;case 37:return this.popState(),10;case 42:return this.begin("style"),37;case 43:return 43;case 44:case 48:case 49:case 67:return 66;case 45:case 46:case 47:case 55:case 57:case 69:return 68;case 50:case 51:case 52:case 53:case 54:case 56:case 68:return 67;case 58:case 59:case 61:case 62:case 63:case 66:return 69;case 60:return 51;case 64:return 52;case 65:return 48;case 70:return 70;case 71:case 74:case 75:case 76:return 71;case 72:case 73:return 72;case 77:return 41;case 78:return 47;case 79:return 40;case 81:return 6}},"anonymous"),rules:[/^(?:accTitle\s*:\s*)/i,/^(?:(?!\n||)*[^\n]*)/i,/^(?:accDescr\s*:\s*)/i,/^(?:(?!\n||)*[^\n]*)/i,/^(?:accDescr\s*\{\s*)/i,/^(?:[\}])/i,/^(?:[^\}]*)/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,/^(?:[\s]+)/i,/^(?:"[^"%\r\n\v\b\\]+")/i,/^(?:"[^"]*")/i,/^(?:erDiagram\b)/i,/^(?:\{)/i,/^(?:#)/i,/^(?:#)/i,/^(?:,)/i,/^(?::::)/i,/^(?::)/i,/^(?:\s+)/i,/^(?:\b((?:PK)|(?:FK)|(?:UK))\b)/i,/^(?:([^\s]*)[~].*[~]([^\s]*))/i,/^(?:([\*A-Za-z_\u00C0-\uFFFF][A-Za-z0-9\-\_\[\]\(\)\.,\u00C0-\uFFFF\*]*))/i,/^(?:[`])/i,/^(?:[^`]+)/i,/^(?:[`])/i,/^(?:"[^"]*")/i,/^(?:[\n]+)/i,/^(?:\})/i,/^(?:.)/i,/^(?:\[)/i,/^(?:\])/i,/^(?:style\b)/i,/^(?:[\n]+)/i,/^(?:\s+)/i,/^(?::)/i,/^(?:,)/i,/^(?:#)/i,/^(?:classDef\b)/i,/^(?:class\b)/i,/^(?:one or zero\b)/i,/^(?:one or more\b)/i,/^(?:one or many\b)/i,/^(?:1\+)/i,/^(?:\|o\b)/i,/^(?:zero or one\b)/i,/^(?:zero or more\b)/i,/^(?:zero or many\b)/i,/^(?:0\+)/i,/^(?:\}o\b)/i,/^(?:many\(0\))/i,/^(?:many\(1\))/i,/^(?:many\b)/i,/^(?:\}\|)/i,/^(?:one\b)/i,/^(?:only one\b)/i,/^(?:[0-9]+\.[0-9]+)/i,/^(?:1(?=\s+[A-Za-z_"']))/i,/^(?:1(?=\s+[0-9]))/i,/^(?:1(?=(--|\.\.|\.-|-\.)))/i,/^(?:1\b)/i,/^(?:[0-9]+)/i,/^(?:\|\|)/i,/^(?:o\|)/i,/^(?:o\{)/i,/^(?:\|\{)/i,/^(?:u(?=[\.\-\|]))/i,/^(?:\.\.)/i,/^(?:--)/i,/^(?:to\b)/i,/^(?:optionally to\b)/i,/^(?:\.-)/i,/^(?:-\.)/i,/^(?:([^\x00-\x7F]|\w|-|\*)+)/i,/^(?:;)/i,/^(?:([^\x00-\x7F]|\w|-|\*|\.)+)/i,/^(?:.)/i,/^(?:$)/i],conditions:{style:{rules:[37,38,39,40,41,77,78],inclusive:!1},acc_descr_multiline:{rules:[5,6],inclusive:!1},acc_descr:{rules:[3],inclusive:!1},acc_title:{rules:[1],inclusive:!1},block_bq:{rules:[28,29],inclusive:!1},block:{rules:[23,24,25,26,27,30,31,32,33],inclusive:!1},INITIAL:{rules:[0,2,4,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,34,35,36,42,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,79,80,81],inclusive:!0}}},(0,j.K)(Y,"Parser"),Y.prototype=X,X.Parser=Y,new Y}();n.parser=n;var o=class{constructor(){this.entities=new Map,this.relationships=[],this.classes=new Map,this.direction="TB",this.Cardinality={ZERO_OR_ONE:"ZERO_OR_ONE",ZERO_OR_MORE:"ZERO_OR_MORE",ONE_OR_MORE:"ONE_OR_MORE",ONLY_ONE:"ONLY_ONE",MD_PARENT:"MD_PARENT"},this.Identification={NON_IDENTIFYING:"NON_IDENTIFYING",IDENTIFYING:"IDENTIFYING"},this.setAccTitle=h.SV,this.getAccTitle=h.iN,this.setAccDescription=h.EI,this.getAccDescription=h.m7,this.setDiagramTitle=h.ke,this.getDiagramTitle=h.ab,this.getConfig=(0,j.K)(()=>(0,h.D7)().er,"getConfig"),this.clear(),this.addEntity=this.addEntity.bind(this),this.addAttributes=this.addAttributes.bind(this),this.addRelationship=this.addRelationship.bind(this),this.setDirection=this.setDirection.bind(this),this.addCssStyles=this.addCssStyles.bind(this),this.addClass=this.addClass.bind(this),this.setClass=this.setClass.bind(this),this.setAccTitle=this.setAccTitle.bind(this),this.setAccDescription=this.setAccDescription.bind(this)}static{(0,j.K)(this,"ErDB")}addEntity(a,b=""){return this.entities.has(a)?!this.entities.get(a)?.alias&&b&&(this.entities.get(a).alias=b,i.R.info(`Add alias '${b}' to entity '${a}'`)):(this.entities.set(a,{id:`entity-${a}-${this.entities.size}`,label:a,attributes:[],alias:b,shape:"erBox",look:(0,h.D7)().look??"default",cssClasses:"default",cssStyles:[],labelType:"markdown"}),i.R.info("Added new entity :",a)),this.entities.get(a)}getEntity(a){return this.entities.get(a)}getEntities(){return this.entities}getClasses(){return this.classes}addAttributes(a,b){let c,d=this.addEntity(a);for(c=b.length-1;c>=0;c--)b[c].keys||(b[c].keys=[]),b[c].comment||(b[c].comment=""),d.attributes.push(b[c]),i.R.debug("Added attribute ",b[c].name)}addRelationship(a,b,c,d){let e=this.entities.get(a),f=this.entities.get(c);if(!e||!f)return;let g={entityA:e.id,roleA:b,entityB:f.id,relSpec:d};this.relationships.push(g),i.R.debug("Added new relationship :",g)}getRelationships(){return this.relationships}getDirection(){return this.direction}setDirection(a){this.direction=a}getCompiledStyles(a){let b=[];for(let c of a){let a=this.classes.get(c);a?.styles&&(b=[...b,...a.styles??[]].map(a=>a.trim())),a?.textStyles&&(b=[...b,...a.textStyles??[]].map(a=>a.trim()))}return b}addCssStyles(a,b){for(let c of a){let a=this.entities.get(c);if(!b||!a)return;for(let c of b)a.cssStyles.push(c)}}addClass(a,b){a.forEach(a=>{let c=this.classes.get(a);void 0===c&&(c={id:a,styles:[],textStyles:[]},this.classes.set(a,c)),b&&b.forEach(function(a){if(/color/.exec(a)){let b=a.replace("fill","bgFill");c.textStyles.push(b)}c.styles.push(a)})})}setClass(a,b){for(let c of a){let a=this.entities.get(c);if(a)for(let c of b)a.cssClasses+=" "+c}}clear(){this.entities=new Map,this.classes=new Map,this.relationships=[],(0,h.IU)()}getData(){let a=[],b=[],c=(0,h.D7)(),d=0;for(let b of this.entities.keys()){let c=this.entities.get(b);c&&(c.cssCompiledStyles=this.getCompiledStyles(c.cssClasses.split(" ")),c.colorIndex=d++,a.push(c))}let e=0;for(let a of this.relationships){let d={id:(0,g.rY)(a.entityA,a.entityB,{prefix:"id",counter:e++}),type:"normal",curve:"basis",start:a.entityA,end:a.entityB,label:a.roleA,labelpos:"c",thickness:"normal",classes:"relationshipLine",arrowTypeStart:a.relSpec.cardB.toLowerCase(),arrowTypeEnd:a.relSpec.cardA.toLowerCase(),pattern:"IDENTIFYING"==a.relSpec.relType?"solid":"dashed",look:c.look,labelType:"markdown"};b.push(d)}return{nodes:a,edges:b,other:{},config:c,direction:"TB"}}},p={};(0,j.V)(p,{draw:()=>q});var q=(0,j.K)(async function(a,b,c,j){i.R.info("REF0:"),i.R.info("Drawing er diagram (unified)",b);let{securityLevel:l,er:m,layout:n}=(0,h.D7)(),o=j.db.getData(),p=(0,d.A)(b,l);o.type=j.type,o.layoutAlgorithm=(0,f.q7)(n),o.config.flowchart.nodeSpacing=m?.nodeSpacing||140,o.config.flowchart.rankSpacing=m?.rankSpacing||80,o.direction=j.db.getDirection();let{config:q}=o,{look:r}=q;"neo"===r?o.markers=["only_one_neo","zero_or_one_neo","one_or_more_neo","zero_or_more_neo"]:o.markers=["only_one","zero_or_one","one_or_more","zero_or_more"],o.diagramId=b,await (0,f.XX)(o,p),"elk"===o.layoutAlgorithm&&p.select(".edges").lower();let s=p.selectAll('[id*="-background"]');Array.from(s).length>0&&s.each(function(){let a=(0,k.Ltv)(this),b=a.attr("id").replace("-background",""),c=p.select(`#${CSS.escape(b)}`);if(!c.empty()){let b=c.attr("transform");a.attr("transform",b)}}),g._K.insertTitle(p,"erDiagramTitleText",m?.titleTopMargin??25,j.db.getDiagramTitle()),(0,e.P)(p,8,"erDiagram",m?.useMaxWidth??!0)},"draw"),r=(0,j.K)((a,b)=>{let c=l.A,d=c(a,"r"),e=c(a,"g"),f=c(a,"b");return m.A(d,e,f,b)},"fade"),s=new Set(["redux-color","redux-dark-color"]),t=(0,j.K)(a=>{let{theme:b,look:c,bkgColorArray:d,borderColorArray:e}=a;if(!s.has(b))return"";let f=d?.length>0,g="";for(let b=0;b<a.THEME_COLOR_LIMIT;b++)g+=`
|
|
1
|
+
"use strict";exports.id=6366,exports.ids=[6366],exports.modules={1487:(a,b,c)=>{c.d(b,{P:()=>g});var d=c(45313),e=c(58715),f=c(95097),g=(0,f.K)((a,b,c,f)=>{a.attr("class",c);let{width:g,height:j,x:k,y:l}=h(a,b);(0,d.a$)(a,j,g,f);let m=i(k,l,g,j,b);a.attr("viewBox",m),e.R.debug(`viewBox configured: ${m} with padding: ${b}`)},"setupViewPortForSVG"),h=(0,f.K)((a,b)=>{let c=a.node()?.getBBox()||{width:0,height:0,x:0,y:0};return{width:c.width+2*b,height:c.height+2*b,x:c.x,y:c.y}},"calculateDimensionsWithPadding"),i=(0,f.K)((a,b,c,d,e)=>`${a-e} ${b-e} ${c} ${d}`,"createViewBox")},30917:(a,b,c)=>{c.d(b,{A:()=>f});var d=c(95097),e=c(92718),f=(0,d.K)((a,b)=>{let c;return"sandbox"===b&&(c=(0,e.Ltv)("#i"+a)),("sandbox"===b?(0,e.Ltv)(c.nodes()[0].contentDocument.body):(0,e.Ltv)("body")).select(`[id="${a}"]`)},"getDiagramElement")},56366:(a,b,c)=>{c.d(b,{diagram:()=>u});var d=c(30917),e=c(1487),f=c(78832);c(32844),c(11878),c(8312),c(7423),c(69819),c(59343),c(73669);var g=c(64922),h=c(45313),i=c(58715),j=c(95097),k=c(92718),l=c(75899),m=c(14120),n=function(){var a=(0,j.K)(function(a,b,c,d){for(c=c||{},d=a.length;d--;c[a[d]]=b);return c},"o"),b=[6,8,10,22,24,26,28,33,34,35,36,37,40,43,44,48,50,51,52],c=[1,10],d=[1,11],e=[1,12],f=[1,13],g=[1,23],h=[1,24],i=[1,25],k=[1,26],l=[1,27],m=[1,19],n=[1,28],o=[1,29],p=[1,20],q=[1,18],r=[1,21],s=[1,22],t=[1,36],u=[1,37],v=[1,38],w=[1,39],x=[1,40],y=[6,8,10,13,15,17,20,21,22,24,26,28,33,34,35,36,37,40,43,44,48,50,51,52,66,67,68,69,70],z=[1,45],A=[1,46],B=[1,55],C=[40,48,50,51,52,71,72],D=[1,66],E=[1,64],F=[1,61],G=[1,65],H=[1,67],I=[6,8,10,13,17,22,24,26,28,33,34,35,36,37,40,41,42,43,44,48,49,50,51,52,66,67,68,69,70],J=[66,67,68,69,70],K=[1,85],L=[1,84],M=[1,82],N=[1,83],O=[6,10,42,47],P=[6,10,13,41,42,47,48,49],Q=[1,93],R=[1,92],S=[1,91],T=[19,58],U=[1,102],V=[1,101],W=[19,58,61,63],X={trace:(0,j.K)(function(){},"trace"),yy:{},symbols_:{error:2,start:3,ER_DIAGRAM:4,document:5,EOF:6,line:7,SPACE:8,statement:9,NEWLINE:10,entityName:11,relSpec:12,COLON:13,role:14,STYLE_SEPARATOR:15,idList:16,BLOCK_START:17,attributes:18,BLOCK_STOP:19,SQS:20,SQE:21,title:22,title_value:23,acc_title:24,acc_title_value:25,acc_descr:26,acc_descr_value:27,acc_descr_multiline_value:28,direction:29,classDefStatement:30,classStatement:31,styleStatement:32,direction_tb:33,direction_bt:34,direction_rl:35,direction_lr:36,CLASSDEF:37,stylesOpt:38,separator:39,UNICODE_TEXT:40,STYLE_TEXT:41,COMMA:42,CLASS:43,STYLE:44,style:45,styleComponent:46,SEMI:47,NUM:48,BRKT:49,ENTITY_NAME:50,DECIMAL_NUM:51,ENTITY_ONE:52,attribute:53,attributeType:54,attributeName:55,attributeKeyTypeList:56,attributeComment:57,ATTRIBUTE_WORD:58,"?":59,attributeKeyType:60,",":61,ATTRIBUTE_KEY:62,COMMENT:63,cardinality:64,relType:65,ZERO_OR_ONE:66,ZERO_OR_MORE:67,ONE_OR_MORE:68,ONLY_ONE:69,MD_PARENT:70,NON_IDENTIFYING:71,IDENTIFYING:72,WORD:73,$accept:0,$end:1},terminals_:{2:"error",4:"ER_DIAGRAM",6:"EOF",8:"SPACE",10:"NEWLINE",13:"COLON",15:"STYLE_SEPARATOR",17:"BLOCK_START",19:"BLOCK_STOP",20:"SQS",21:"SQE",22:"title",23:"title_value",24:"acc_title",25:"acc_title_value",26:"acc_descr",27:"acc_descr_value",28:"acc_descr_multiline_value",33:"direction_tb",34:"direction_bt",35:"direction_rl",36:"direction_lr",37:"CLASSDEF",40:"UNICODE_TEXT",41:"STYLE_TEXT",42:"COMMA",43:"CLASS",44:"STYLE",47:"SEMI",48:"NUM",49:"BRKT",50:"ENTITY_NAME",51:"DECIMAL_NUM",52:"ENTITY_ONE",58:"ATTRIBUTE_WORD",59:"?",61:",",62:"ATTRIBUTE_KEY",63:"COMMENT",66:"ZERO_OR_ONE",67:"ZERO_OR_MORE",68:"ONE_OR_MORE",69:"ONLY_ONE",70:"MD_PARENT",71:"NON_IDENTIFYING",72:"IDENTIFYING",73:"WORD"},productions_:[0,[3,3],[5,0],[5,2],[7,2],[7,1],[7,1],[7,1],[9,5],[9,9],[9,7],[9,7],[9,4],[9,6],[9,3],[9,5],[9,1],[9,3],[9,7],[9,9],[9,6],[9,8],[9,4],[9,6],[9,2],[9,2],[9,2],[9,1],[9,1],[9,1],[9,1],[9,1],[29,1],[29,1],[29,1],[29,1],[30,4],[16,1],[16,1],[16,3],[16,3],[31,3],[32,4],[38,1],[38,3],[45,1],[45,2],[39,1],[39,1],[39,1],[46,1],[46,1],[46,1],[46,1],[11,1],[11,1],[11,1],[11,1],[11,1],[18,1],[18,2],[53,2],[53,3],[53,3],[53,4],[54,1],[54,2],[55,1],[56,1],[56,3],[60,1],[57,1],[12,3],[64,1],[64,1],[64,1],[64,1],[64,1],[65,1],[65,1],[14,1],[14,1],[14,1]],performAction:(0,j.K)(function(a,b,c,d,e,f,g){var h=f.length-1;switch(e){case 1:break;case 2:case 6:case 7:this.$=[];break;case 3:f[h-1].push(f[h]),this.$=f[h-1];break;case 4:case 5:case 55:case 56:case 57:case 58:case 82:case 65:case 67:case 70:this.$=f[h];break;case 8:d.addEntity(f[h-4]),d.addEntity(f[h-2]),d.addRelationship(f[h-4],f[h],f[h-2],f[h-3]);break;case 9:d.addEntity(f[h-8]),d.addEntity(f[h-4]),d.addRelationship(f[h-8],f[h],f[h-4],f[h-5]),d.setClass([f[h-8]],f[h-6]),d.setClass([f[h-4]],f[h-2]);break;case 10:d.addEntity(f[h-6]),d.addEntity(f[h-2]),d.addRelationship(f[h-6],f[h],f[h-2],f[h-3]),d.setClass([f[h-6]],f[h-4]);break;case 11:d.addEntity(f[h-6]),d.addEntity(f[h-4]),d.addRelationship(f[h-6],f[h],f[h-4],f[h-5]),d.setClass([f[h-4]],f[h-2]);break;case 12:d.addEntity(f[h-3]),d.addAttributes(f[h-3],f[h-1]);break;case 13:d.addEntity(f[h-5]),d.addAttributes(f[h-5],f[h-1]),d.setClass([f[h-5]],f[h-3]);break;case 14:d.addEntity(f[h-2]);break;case 15:d.addEntity(f[h-4]),d.setClass([f[h-4]],f[h-2]);break;case 16:d.addEntity(f[h]);break;case 17:d.addEntity(f[h-2]),d.setClass([f[h-2]],f[h]);break;case 18:d.addEntity(f[h-6],f[h-4]),d.addAttributes(f[h-6],f[h-1]);break;case 19:d.addEntity(f[h-8],f[h-6]),d.addAttributes(f[h-8],f[h-1]),d.setClass([f[h-8]],f[h-3]);break;case 20:d.addEntity(f[h-5],f[h-3]);break;case 21:d.addEntity(f[h-7],f[h-5]),d.setClass([f[h-7]],f[h-2]);break;case 22:d.addEntity(f[h-3],f[h-1]);break;case 23:d.addEntity(f[h-5],f[h-3]),d.setClass([f[h-5]],f[h]);break;case 24:case 25:this.$=f[h].trim(),d.setAccTitle(this.$);break;case 26:case 27:this.$=f[h].trim(),d.setAccDescription(this.$);break;case 32:d.setDirection("TB");break;case 33:d.setDirection("BT");break;case 34:d.setDirection("RL");break;case 35:d.setDirection("LR");break;case 36:this.$=f[h-3],d.addClass(f[h-2],f[h-1]);break;case 37:case 38:case 59:case 68:case 43:this.$=[f[h]];break;case 39:case 40:this.$=f[h-2].concat([f[h]]);break;case 41:this.$=f[h-2],d.setClass(f[h-1],f[h]);break;case 42:this.$=f[h-3],d.addCssStyles(f[h-2],f[h-1]);break;case 44:case 69:f[h-2].push(f[h]),this.$=f[h-2];break;case 46:case 66:this.$=f[h-1]+f[h];break;case 54:case 80:case 81:case 71:this.$=f[h].replace(/"/g,"");break;case 60:f[h].push(f[h-1]),this.$=f[h];break;case 61:this.$={type:f[h-1],name:f[h]};break;case 62:this.$={type:f[h-2],name:f[h-1],keys:f[h]};break;case 63:this.$={type:f[h-2],name:f[h-1],comment:f[h]};break;case 64:this.$={type:f[h-3],name:f[h-2],keys:f[h-1],comment:f[h]};break;case 72:this.$={cardA:f[h],relType:f[h-1],cardB:f[h-2]};break;case 73:this.$=d.Cardinality.ZERO_OR_ONE;break;case 74:this.$=d.Cardinality.ZERO_OR_MORE;break;case 75:this.$=d.Cardinality.ONE_OR_MORE;break;case 76:this.$=d.Cardinality.ONLY_ONE;break;case 77:this.$=d.Cardinality.MD_PARENT;break;case 78:this.$=d.Identification.NON_IDENTIFYING;break;case 79:this.$=d.Identification.IDENTIFYING}},"anonymous"),table:[{3:1,4:[1,2]},{1:[3]},a(b,[2,2],{5:3}),{6:[1,4],7:5,8:[1,6],9:7,10:[1,8],11:9,22:c,24:d,26:e,28:f,29:14,30:15,31:16,32:17,33:g,34:h,35:i,36:k,37:l,40:m,43:n,44:o,48:p,50:q,51:r,52:s},a(b,[2,7],{1:[2,1]}),a(b,[2,3]),{9:30,11:9,22:c,24:d,26:e,28:f,29:14,30:15,31:16,32:17,33:g,34:h,35:i,36:k,37:l,40:m,43:n,44:o,48:p,50:q,51:r,52:s},a(b,[2,5]),a(b,[2,6]),a(b,[2,16],{12:31,64:35,15:[1,32],17:[1,33],20:[1,34],66:t,67:u,68:v,69:w,70:x}),{23:[1,41]},{25:[1,42]},{27:[1,43]},a(b,[2,27]),a(b,[2,28]),a(b,[2,29]),a(b,[2,30]),a(b,[2,31]),a(y,[2,54]),a(y,[2,55]),a(y,[2,56]),a(y,[2,57]),a(y,[2,58]),a(b,[2,32]),a(b,[2,33]),a(b,[2,34]),a(b,[2,35]),{16:44,40:z,41:A},{16:47,40:z,41:A},{16:48,40:z,41:A},a(b,[2,4]),{11:49,40:m,48:p,50:q,51:r,52:s},{16:50,40:z,41:A},{18:51,19:[1,52],53:53,54:54,58:B},{11:56,40:m,48:p,50:q,51:r,52:s},{65:57,71:[1,58],72:[1,59]},a(C,[2,73]),a(C,[2,74]),a(C,[2,75]),a(C,[2,76]),a(C,[2,77]),a(b,[2,24]),a(b,[2,25]),a(b,[2,26]),{13:D,38:60,41:E,42:F,45:62,46:63,48:G,49:H},a(I,[2,37]),a(I,[2,38]),{16:68,40:z,41:A,42:F},{13:D,38:69,41:E,42:F,45:62,46:63,48:G,49:H},{13:[1,70],15:[1,71]},a(b,[2,17],{64:35,12:72,17:[1,73],42:F,66:t,67:u,68:v,69:w,70:x}),{19:[1,74]},a(b,[2,14]),{18:75,19:[2,59],53:53,54:54,58:B},{55:76,58:[1,77]},{58:[2,65],59:[1,78]},{21:[1,79]},{64:80,66:t,67:u,68:v,69:w,70:x},a(J,[2,78]),a(J,[2,79]),{6:K,10:L,39:81,42:M,47:N},{40:[1,86],41:[1,87]},a(O,[2,43],{46:88,13:D,41:E,48:G,49:H}),a(P,[2,45]),a(P,[2,50]),a(P,[2,51]),a(P,[2,52]),a(P,[2,53]),a(b,[2,41],{42:F}),{6:K,10:L,39:89,42:M,47:N},{14:90,40:Q,50:R,73:S},{16:94,40:z,41:A},{11:95,40:m,48:p,50:q,51:r,52:s},{18:96,19:[1,97],53:53,54:54,58:B},a(b,[2,12]),{19:[2,60]},a(T,[2,61],{56:98,57:99,60:100,62:U,63:V}),a([19,58,62,63],[2,67]),{58:[2,66]},a(b,[2,22],{15:[1,104],17:[1,103]}),a([40,48,50,51,52],[2,72]),a(b,[2,36]),{13:D,41:E,45:105,46:63,48:G,49:H},a(b,[2,47]),a(b,[2,48]),a(b,[2,49]),a(I,[2,39]),a(I,[2,40]),a(P,[2,46]),a(b,[2,42]),a(b,[2,8]),a(b,[2,80]),a(b,[2,81]),a(b,[2,82]),{13:[1,106],42:F},{13:[1,108],15:[1,107]},{19:[1,109]},a(b,[2,15]),a(T,[2,62],{57:110,61:[1,111],63:V}),a(T,[2,63]),a(W,[2,68]),a(T,[2,71]),a(W,[2,70]),{18:112,19:[1,113],53:53,54:54,58:B},{16:114,40:z,41:A},a(O,[2,44],{46:88,13:D,41:E,48:G,49:H}),{14:115,40:Q,50:R,73:S},{16:116,40:z,41:A},{14:117,40:Q,50:R,73:S},a(b,[2,13]),a(T,[2,64]),{60:118,62:U},{19:[1,119]},a(b,[2,20]),a(b,[2,23],{17:[1,120],42:F}),a(b,[2,11]),{13:[1,121],42:F},a(b,[2,10]),a(W,[2,69]),a(b,[2,18]),{18:122,19:[1,123],53:53,54:54,58:B},{14:124,40:Q,50:R,73:S},{19:[1,125]},a(b,[2,21]),a(b,[2,9]),a(b,[2,19])],defaultActions:{75:[2,60],78:[2,66]},parseError:(0,j.K)(function(a,b){if(b.recoverable)this.trace(a);else{var c=Error(a);throw c.hash=b,c}},"parseError"),parse:(0,j.K)(function(a){var b=this,c=[0],d=[],e=[null],f=[],g=this.table,h="",i=0,k=0,l=0,m=f.slice.call(arguments,1),n=Object.create(this.lexer),o={};for(var p in this.yy)Object.prototype.hasOwnProperty.call(this.yy,p)&&(o[p]=this.yy[p]);n.setInput(a,o),o.lexer=n,o.parser=this,void 0===n.yylloc&&(n.yylloc={});var q=n.yylloc;f.push(q);var r=n.options&&n.options.ranges;function s(){var a;return"number"!=typeof(a=d.pop()||n.lex()||1)&&(a instanceof Array&&(a=(d=a).pop()),a=b.symbols_[a]||a),a}"function"==typeof o.parseError?this.parseError=o.parseError:this.parseError=Object.getPrototypeOf(this).parseError,(0,j.K)(function(a){c.length=c.length-2*a,e.length=e.length-a,f.length=f.length-a},"popStack"),(0,j.K)(s,"lex");for(var t,u,v,w,x,y,z,A,B,C={};;){if(v=c[c.length-1],this.defaultActions[v]?w=this.defaultActions[v]:(null==t&&(t=s()),w=g[v]&&g[v][t]),void 0===w||!w.length||!w[0]){var D="";for(y in B=[],g[v])this.terminals_[y]&&y>2&&B.push("'"+this.terminals_[y]+"'");D=n.showPosition?"Parse error on line "+(i+1)+":\n"+n.showPosition()+"\nExpecting "+B.join(", ")+", got '"+(this.terminals_[t]||t)+"'":"Parse error on line "+(i+1)+": Unexpected "+(1==t?"end of input":"'"+(this.terminals_[t]||t)+"'"),this.parseError(D,{text:n.match,token:this.terminals_[t]||t,line:n.yylineno,loc:q,expected:B})}if(w[0]instanceof Array&&w.length>1)throw Error("Parse Error: multiple actions possible at state: "+v+", token: "+t);switch(w[0]){case 1:c.push(t),e.push(n.yytext),f.push(n.yylloc),c.push(w[1]),t=null,u?(t=u,u=null):(k=n.yyleng,h=n.yytext,i=n.yylineno,q=n.yylloc,l>0&&l--);break;case 2:if(z=this.productions_[w[1]][1],C.$=e[e.length-z],C._$={first_line:f[f.length-(z||1)].first_line,last_line:f[f.length-1].last_line,first_column:f[f.length-(z||1)].first_column,last_column:f[f.length-1].last_column},r&&(C._$.range=[f[f.length-(z||1)].range[0],f[f.length-1].range[1]]),void 0!==(x=this.performAction.apply(C,[h,k,i,o,w[1],e,f].concat(m))))return x;z&&(c=c.slice(0,-1*z*2),e=e.slice(0,-1*z),f=f.slice(0,-1*z)),c.push(this.productions_[w[1]][0]),e.push(C.$),f.push(C._$),A=g[c[c.length-2]][c[c.length-1]],c.push(A);break;case 3:return!0}}return!0},"parse")};function Y(){this.yy={}}return X.lexer={EOF:1,parseError:(0,j.K)(function(a,b){if(this.yy.parser)this.yy.parser.parseError(a,b);else throw Error(a)},"parseError"),setInput:(0,j.K)(function(a,b){return this.yy=b||this.yy||{},this._input=a,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,j.K)(function(){var a=this._input[0];return this.yytext+=a,this.yyleng++,this.offset++,this.match+=a,this.matched+=a,a.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),a},"input"),unput:(0,j.K)(function(a){var b=a.length,c=a.split(/(?:\r\n?|\n)/g);this._input=a+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-b),this.offset-=b;var d=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),c.length-1&&(this.yylineno-=c.length-1);var e=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:c?(c.length===d.length?this.yylloc.first_column:0)+d[d.length-c.length].length-c[0].length:this.yylloc.first_column-b},this.options.ranges&&(this.yylloc.range=[e[0],e[0]+this.yyleng-b]),this.yyleng=this.yytext.length,this},"unput"),more:(0,j.K)(function(){return this._more=!0,this},"more"),reject:(0,j.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,j.K)(function(a){this.unput(this.match.slice(a))},"less"),pastInput:(0,j.K)(function(){var a=this.matched.substr(0,this.matched.length-this.match.length);return(a.length>20?"...":"")+a.substr(-20).replace(/\n/g,"")},"pastInput"),upcomingInput:(0,j.K)(function(){var a=this.match;return a.length<20&&(a+=this._input.substr(0,20-a.length)),(a.substr(0,20)+(a.length>20?"...":"")).replace(/\n/g,"")},"upcomingInput"),showPosition:(0,j.K)(function(){var a=this.pastInput(),b=Array(a.length+1).join("-");return a+this.upcomingInput()+"\n"+b+"^"},"showPosition"),test_match:(0,j.K)(function(a,b){var c,d,e;if(this.options.backtrack_lexer&&(e={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&&(e.yylloc.range=this.yylloc.range.slice(0))),(d=a[0].match(/(?:\r\n?|\n).*/g))&&(this.yylineno+=d.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:d?d[d.length-1].length-d[d.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+a[0].length},this.yytext+=a[0],this.match+=a[0],this.matches=a,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(a[0].length),this.matched+=a[0],c=this.performAction.call(this,this.yy,this,b,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),c)return c;if(this._backtrack)for(var f in e)this[f]=e[f];return!1},"test_match"),next:(0,j.K)(function(){if(this.done)return this.EOF;this._input||(this.done=!0),this._more||(this.yytext="",this.match="");for(var a,b,c,d,e=this._currentRules(),f=0;f<e.length;f++)if((c=this._input.match(this.rules[e[f]]))&&(!b||c[0].length>b[0].length)){if(b=c,d=f,this.options.backtrack_lexer){if(!1!==(a=this.test_match(c,e[f])))return a;if(!this._backtrack)return!1;b=!1;continue}if(!this.options.flex)break}return b?!1!==(a=this.test_match(b,e[d]))&&a:""===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,j.K)(function(){var a=this.next();return a||this.lex()},"lex"),begin:(0,j.K)(function(a){this.conditionStack.push(a)},"begin"),popState:(0,j.K)(function(){return this.conditionStack.length-1>0?this.conditionStack.pop():this.conditionStack[0]},"popState"),_currentRules:(0,j.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,j.K)(function(a){return(a=this.conditionStack.length-1-Math.abs(a||0))>=0?this.conditionStack[a]:"INITIAL"},"topState"),pushState:(0,j.K)(function(a){this.begin(a)},"pushState"),stateStackSize:(0,j.K)(function(){return this.conditionStack.length},"stateStackSize"),options:{"case-insensitive":!0},performAction:(0,j.K)(function(a,b,c,d){switch(c){case 0:return this.begin("acc_title"),24;case 1:return this.popState(),"acc_title_value";case 2:return this.begin("acc_descr"),26;case 3:return this.popState(),"acc_descr_value";case 4:this.begin("acc_descr_multiline");break;case 5:case 29:this.popState();break;case 6:return"acc_descr_multiline_value";case 7:return 33;case 8:return 34;case 9:return 35;case 10:return 36;case 11:return 10;case 12:case 23:case 31:case 38:break;case 13:return 8;case 14:return 50;case 15:return 73;case 16:return 4;case 17:return this.begin("block"),17;case 18:case 19:case 41:return 49;case 20:case 40:return 42;case 21:return 15;case 22:case 39:return 13;case 24:return 62;case 25:case 26:case 28:return 58;case 27:this.begin("block_bq");break;case 30:return 63;case 32:return this.popState(),19;case 33:case 80:return b.yytext[0];case 34:return 20;case 35:return 21;case 36:return this.begin("style"),44;case 37:return this.popState(),10;case 42:return this.begin("style"),37;case 43:return 43;case 44:case 48:case 49:case 67:return 66;case 45:case 46:case 47:case 55:case 57:case 69:return 68;case 50:case 51:case 52:case 53:case 54:case 56:case 68:return 67;case 58:case 59:case 61:case 62:case 63:case 66:return 69;case 60:return 51;case 64:return 52;case 65:return 48;case 70:return 70;case 71:case 74:case 75:case 76:return 71;case 72:case 73:return 72;case 77:return 41;case 78:return 47;case 79:return 40;case 81:return 6}},"anonymous"),rules:[/^(?:accTitle\s*:\s*)/i,/^(?:(?!\n||)*[^\n]*)/i,/^(?:accDescr\s*:\s*)/i,/^(?:(?!\n||)*[^\n]*)/i,/^(?:accDescr\s*\{\s*)/i,/^(?:[\}])/i,/^(?:[^\}]*)/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,/^(?:[\s]+)/i,/^(?:"[^"%\r\n\v\b\\]+")/i,/^(?:"[^"]*")/i,/^(?:erDiagram\b)/i,/^(?:\{)/i,/^(?:#)/i,/^(?:#)/i,/^(?:,)/i,/^(?::::)/i,/^(?::)/i,/^(?:\s+)/i,/^(?:\b((?:PK)|(?:FK)|(?:UK))\b)/i,/^(?:([^\s]*)[~].*[~]([^\s]*))/i,/^(?:([\*A-Za-z_\u00C0-\uFFFF][A-Za-z0-9\-\_\[\]\(\)\.,\u00C0-\uFFFF\*]*))/i,/^(?:[`])/i,/^(?:[^`]+)/i,/^(?:[`])/i,/^(?:"[^"]*")/i,/^(?:[\n]+)/i,/^(?:\})/i,/^(?:.)/i,/^(?:\[)/i,/^(?:\])/i,/^(?:style\b)/i,/^(?:[\n]+)/i,/^(?:\s+)/i,/^(?::)/i,/^(?:,)/i,/^(?:#)/i,/^(?:classDef\b)/i,/^(?:class\b)/i,/^(?:one or zero\b)/i,/^(?:one or more\b)/i,/^(?:one or many\b)/i,/^(?:1\+)/i,/^(?:\|o\b)/i,/^(?:zero or one\b)/i,/^(?:zero or more\b)/i,/^(?:zero or many\b)/i,/^(?:0\+)/i,/^(?:\}o\b)/i,/^(?:many\(0\))/i,/^(?:many\(1\))/i,/^(?:many\b)/i,/^(?:\}\|)/i,/^(?:one\b)/i,/^(?:only one\b)/i,/^(?:[0-9]+\.[0-9]+)/i,/^(?:1(?=\s+[A-Za-z_"']))/i,/^(?:1(?=\s+[0-9]))/i,/^(?:1(?=(--|\.\.|\.-|-\.)))/i,/^(?:1\b)/i,/^(?:[0-9]+)/i,/^(?:\|\|)/i,/^(?:o\|)/i,/^(?:o\{)/i,/^(?:\|\{)/i,/^(?:u(?=[\.\-\|]))/i,/^(?:\.\.)/i,/^(?:--)/i,/^(?:to\b)/i,/^(?:optionally to\b)/i,/^(?:\.-)/i,/^(?:-\.)/i,/^(?:([^\x00-\x7F]|\w|-|\*)+)/i,/^(?:;)/i,/^(?:([^\x00-\x7F]|\w|-|\*|\.)+)/i,/^(?:.)/i,/^(?:$)/i],conditions:{style:{rules:[37,38,39,40,41,77,78],inclusive:!1},acc_descr_multiline:{rules:[5,6],inclusive:!1},acc_descr:{rules:[3],inclusive:!1},acc_title:{rules:[1],inclusive:!1},block_bq:{rules:[28,29],inclusive:!1},block:{rules:[23,24,25,26,27,30,31,32,33],inclusive:!1},INITIAL:{rules:[0,2,4,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,34,35,36,42,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,79,80,81],inclusive:!0}}},(0,j.K)(Y,"Parser"),Y.prototype=X,X.Parser=Y,new Y}();n.parser=n;var o=class{constructor(){this.entities=new Map,this.relationships=[],this.classes=new Map,this.direction="TB",this.Cardinality={ZERO_OR_ONE:"ZERO_OR_ONE",ZERO_OR_MORE:"ZERO_OR_MORE",ONE_OR_MORE:"ONE_OR_MORE",ONLY_ONE:"ONLY_ONE",MD_PARENT:"MD_PARENT"},this.Identification={NON_IDENTIFYING:"NON_IDENTIFYING",IDENTIFYING:"IDENTIFYING"},this.setAccTitle=h.SV,this.getAccTitle=h.iN,this.setAccDescription=h.EI,this.getAccDescription=h.m7,this.setDiagramTitle=h.ke,this.getDiagramTitle=h.ab,this.getConfig=(0,j.K)(()=>(0,h.D7)().er,"getConfig"),this.clear(),this.addEntity=this.addEntity.bind(this),this.addAttributes=this.addAttributes.bind(this),this.addRelationship=this.addRelationship.bind(this),this.setDirection=this.setDirection.bind(this),this.addCssStyles=this.addCssStyles.bind(this),this.addClass=this.addClass.bind(this),this.setClass=this.setClass.bind(this),this.setAccTitle=this.setAccTitle.bind(this),this.setAccDescription=this.setAccDescription.bind(this)}static{(0,j.K)(this,"ErDB")}addEntity(a,b=""){return this.entities.has(a)?!this.entities.get(a)?.alias&&b&&(this.entities.get(a).alias=b,i.R.info(`Add alias '${b}' to entity '${a}'`)):(this.entities.set(a,{id:`entity-${a}-${this.entities.size}`,label:a,attributes:[],alias:b,shape:"erBox",look:(0,h.D7)().look??"default",cssClasses:"default",cssStyles:[],labelType:"markdown"}),i.R.info("Added new entity :",a)),this.entities.get(a)}getEntity(a){return this.entities.get(a)}getEntities(){return this.entities}getClasses(){return this.classes}addAttributes(a,b){let c,d=this.addEntity(a);for(c=b.length-1;c>=0;c--)b[c].keys||(b[c].keys=[]),b[c].comment||(b[c].comment=""),d.attributes.push(b[c]),i.R.debug("Added attribute ",b[c].name)}addRelationship(a,b,c,d){let e=this.entities.get(a),f=this.entities.get(c);if(!e||!f)return;let g={entityA:e.id,roleA:b,entityB:f.id,relSpec:d};this.relationships.push(g),i.R.debug("Added new relationship :",g)}getRelationships(){return this.relationships}getDirection(){return this.direction}setDirection(a){this.direction=a}getCompiledStyles(a){let b=[];for(let c of a){let a=this.classes.get(c);a?.styles&&(b=[...b,...a.styles??[]].map(a=>a.trim())),a?.textStyles&&(b=[...b,...a.textStyles??[]].map(a=>a.trim()))}return b}addCssStyles(a,b){for(let c of a){let a=this.entities.get(c);if(!b||!a)return;for(let c of b)a.cssStyles.push(c)}}addClass(a,b){a.forEach(a=>{let c=this.classes.get(a);void 0===c&&(c={id:a,styles:[],textStyles:[]},this.classes.set(a,c)),b&&b.forEach(function(a){if(/color/.exec(a)){let b=a.replace("fill","bgFill");c.textStyles.push(b)}c.styles.push(a)})})}setClass(a,b){for(let c of a){let a=this.entities.get(c);if(a)for(let c of b)a.cssClasses+=" "+c}}clear(){this.entities=new Map,this.classes=new Map,this.relationships=[],(0,h.IU)()}getData(){let a=[],b=[],c=(0,h.D7)(),d=0;for(let b of this.entities.keys()){let c=this.entities.get(b);c&&(c.cssCompiledStyles=this.getCompiledStyles(c.cssClasses.split(" ")),c.colorIndex=d++,a.push(c))}let e=0;for(let a of this.relationships){let d={id:(0,g.rY)(a.entityA,a.entityB,{prefix:"id",counter:e++}),type:"normal",curve:"basis",start:a.entityA,end:a.entityB,label:a.roleA,labelpos:"c",thickness:"normal",classes:"relationshipLine",arrowTypeStart:a.relSpec.cardB.toLowerCase(),arrowTypeEnd:a.relSpec.cardA.toLowerCase(),pattern:"IDENTIFYING"==a.relSpec.relType?"solid":"dashed",look:c.look,labelType:"markdown"};b.push(d)}return{nodes:a,edges:b,other:{},config:c,direction:"TB"}}},p={};(0,j.V)(p,{draw:()=>q});var q=(0,j.K)(async function(a,b,c,j){i.R.info("REF0:"),i.R.info("Drawing er diagram (unified)",b);let{securityLevel:l,er:m,layout:n}=(0,h.D7)(),o=j.db.getData(),p=(0,d.A)(b,l);o.type=j.type,o.layoutAlgorithm=(0,f.q7)(n),o.config.flowchart.nodeSpacing=m?.nodeSpacing||140,o.config.flowchart.rankSpacing=m?.rankSpacing||80,o.direction=j.db.getDirection();let{config:q}=o,{look:r}=q;"neo"===r?o.markers=["only_one_neo","zero_or_one_neo","one_or_more_neo","zero_or_more_neo"]:o.markers=["only_one","zero_or_one","one_or_more","zero_or_more"],o.diagramId=b,await (0,f.XX)(o,p),"elk"===o.layoutAlgorithm&&p.select(".edges").lower();let s=p.selectAll('[id*="-background"]');Array.from(s).length>0&&s.each(function(){let a=(0,k.Ltv)(this),b=a.attr("id").replace("-background",""),c=p.select(`#${CSS.escape(b)}`);if(!c.empty()){let b=c.attr("transform");a.attr("transform",b)}}),g._K.insertTitle(p,"erDiagramTitleText",m?.titleTopMargin??25,j.db.getDiagramTitle()),(0,e.P)(p,8,"erDiagram",m?.useMaxWidth??!0)},"draw"),r=(0,j.K)((a,b)=>{let c=l.A,d=c(a,"r"),e=c(a,"g"),f=c(a,"b");return m.A(d,e,f,b)},"fade"),s=new Set(["redux-color","redux-dark-color"]),t=(0,j.K)(a=>{let{theme:b,look:c,bkgColorArray:d,borderColorArray:e}=a;if(!s.has(b))return"";let f=d?.length>0,g="";for(let b=0;b<a.THEME_COLOR_LIMIT;b++)g+=`
|
|
2
2
|
|
|
3
3
|
[data-look="${c}"][data-color-id="color-${b}"].node path {
|
|
4
4
|
stroke: ${e[b]};
|