agentroam-runtime-darwin-arm64 0.2.0-preview.70 → 0.2.0-preview.71
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/manifest.json +2 -2
- package/package.json +1 -1
- package/runtime/.next/BUILD_ID +1 -1
- package/runtime/.next/app-build-manifest.json +8 -8
- package/runtime/.next/app-path-routes-manifest.json +1 -1
- package/runtime/.next/build-manifest.json +3 -3
- package/runtime/.next/prerender-manifest.json +1 -1
- package/runtime/.next/required-server-files.json +1 -1
- package/runtime/.next/server/app/_not-found/page.js +1 -1
- package/runtime/.next/server/app/_not-found/page_client-reference-manifest.js +1 -1
- package/runtime/.next/server/app/_not-found.html +1 -1
- package/runtime/.next/server/app/_not-found.rsc +1 -1
- package/runtime/.next/server/app/api/agent/abort/route.js +1 -1
- package/runtime/.next/server/app/api/agent/answer/route.js +1 -1
- package/runtime/.next/server/app/api/agent/codex-sharing/route.js +1 -1
- package/runtime/.next/server/app/api/agent/harness/status/route.js +1 -1
- package/runtime/.next/server/app/api/agent/model/route.js +1 -1
- package/runtime/.next/server/app/api/agent/models/route.js +1 -1
- package/runtime/.next/server/app/api/agent/run/route.js +1 -1
- package/runtime/.next/server/app/api/agent/runtime-health/route.js +1 -1
- package/runtime/.next/server/app/api/agent/steer/route.js +1 -1
- package/runtime/.next/server/app/api/agent/stream/route.js +4 -4
- package/runtime/.next/server/app/api/agent-workspaces/[workspaceId]/sessions/route.js +1 -1
- package/runtime/.next/server/app/api/agent-workspaces/route.js +1 -1
- package/runtime/.next/server/app/api/auth/verify/route.js +1 -1
- package/runtime/.next/server/app/api/business/route.js +1 -1
- package/runtime/.next/server/app/api/client-logs/route.js +1 -1
- package/runtime/.next/server/app/api/collaboration/route.js +2 -2
- package/runtime/.next/server/app/api/flow/v1/catalog/route.js +1 -1
- package/runtime/.next/server/app/api/flow/v1/runs/[runId]/cancel/route.js +1 -1
- package/runtime/.next/server/app/api/flow/v1/runs/[runId]/events/route.js +3 -3
- package/runtime/.next/server/app/api/flow/v1/runs/route.js +1 -1
- package/runtime/.next/server/app/api/flow-studio/config/route.js +1 -1
- package/runtime/.next/server/app/api/mcp/connect/route.js +1 -1
- package/runtime/.next/server/app/api/mcp/disconnect/route.js +1 -1
- package/runtime/.next/server/app/api/mcp/servers/route.js +1 -1
- package/runtime/.next/server/app/api/memory/[key]/route.js +1 -1
- package/runtime/.next/server/app/api/memory/route.js +1 -1
- package/runtime/.next/server/app/api/plugins/load/route.js +1 -1
- package/runtime/.next/server/app/api/projects/[id]/route.js +1 -1
- package/runtime/.next/server/app/api/projects/check/route.js +1 -1
- package/runtime/.next/server/app/api/projects/directories/route.js +1 -1
- package/runtime/.next/server/app/api/projects/roots/route.js +1 -1
- package/runtime/.next/server/app/api/projects/route.js +1 -1
- package/runtime/.next/server/app/api/push/subscribe/route.js +2 -2
- package/runtime/.next/server/app/api/push/unsubscribe/route.js +3 -3
- package/runtime/.next/server/app/api/push/vapid/route.js +2 -2
- package/runtime/.next/server/app/api/push/vapid.body +1 -1
- package/runtime/.next/server/app/api/remote-tools/register/route.js +1 -1
- package/runtime/.next/server/app/api/sessions/[id]/background-jobs/[jobId]/route.js +1 -1
- package/runtime/.next/server/app/api/sessions/[id]/background-jobs/[jobId]/stop/route.js +1 -1
- package/runtime/.next/server/app/api/sessions/[id]/background-jobs/route.js +1 -1
- package/runtime/.next/server/app/api/sessions/[id]/changes/route.js +2 -2
- package/runtime/.next/server/app/api/sessions/[id]/fork/route.js +1 -1
- package/runtime/.next/server/app/api/sessions/[id]/fork-at/route.js +1 -1
- package/runtime/.next/server/app/api/sessions/[id]/goals/route.js +1 -1
- package/runtime/.next/server/app/api/sessions/[id]/handoff/route.js +1 -1
- package/runtime/.next/server/app/api/sessions/[id]/native-goal/route.js +1 -1
- package/runtime/.next/server/app/api/sessions/[id]/query-index/route.js +1 -1
- package/runtime/.next/server/app/api/sessions/[id]/release/route.js +1 -1
- package/runtime/.next/server/app/api/sessions/[id]/route.js +1 -1
- package/runtime/.next/server/app/api/sessions/[id]/thread-goal/route.js +1 -1
- package/runtime/.next/server/app/api/sessions/[id]/tool-result/route.js +1 -1
- package/runtime/.next/server/app/api/sessions/route.js +1 -1
- package/runtime/.next/server/app/api/settings/route.js +1 -1
- package/runtime/.next/server/app/api/skills/route.js +1 -1
- package/runtime/.next/server/app/api/tool-policies/[policyId]/route.js +1 -1
- package/runtime/.next/server/app/api/tool-policies/route.js +1 -1
- package/runtime/.next/server/app/api/tools/route.js +1 -1
- package/runtime/.next/server/app/api/update/check/route.js +1 -1
- package/runtime/.next/server/app/api/update/install/route.js +1 -1
- package/runtime/.next/server/app/api/update/status/route.js +1 -1
- package/runtime/.next/server/app/api/web-auth/login/route.js +1 -1
- package/runtime/.next/server/app/api/web-auth/logout/route.js +1 -1
- package/runtime/.next/server/app/api/web-auth/revoke-all/route.js +1 -1
- package/runtime/.next/server/app/api/web-auth/setup/route.js +1 -1
- package/runtime/.next/server/app/api/web-auth/status/route.js +1 -1
- package/runtime/.next/server/app/api/web-console/bootstrap/route.js +1 -1
- package/runtime/.next/server/app/api/web-console/computer-settings/route.js +1 -1
- package/runtime/.next/server/app/api/web-console/computers/route.js +1 -1
- package/runtime/.next/server/app/api/web-console/device-state/route.js +1 -1
- package/runtime/.next/server/app/api/web-console/history/route.js +1 -1
- package/runtime/.next/server/app/api/web-console/preferences/route.js +1 -1
- package/runtime/.next/server/app/web/page.js +4 -4
- package/runtime/.next/server/app/web/page_client-reference-manifest.js +1 -1
- package/runtime/.next/server/app-paths-manifest.json +33 -33
- package/runtime/.next/server/chunks/5303.js +2 -2
- package/runtime/.next/server/middleware-build-manifest.js +1 -1
- package/runtime/.next/server/pages/404.html +1 -1
- package/runtime/.next/server/pages/500.html +1 -1
- package/runtime/.next/server/server-reference-manifest.json +1 -1
- package/runtime/.next/static/chunks/app/web/{error-3acef50d100c88cd.js → error-6470e38a145095eb.js} +1 -1
- package/runtime/.next/static/chunks/app/web/layout-ecfb758d244808a4.js +1 -0
- package/runtime/.next/static/chunks/app/web/{page-cd202c384ebf79be.js → page-27145471bd2171c2.js} +1 -1
- package/runtime/.next/static/chunks/{main-app-1722010a0ff567d7.js → main-app-41078426602904fd.js} +1 -1
- package/runtime/lib/tunnel-control.mjs +32 -0
- package/runtime/native/Support.noindex/AgentRoam Remote Desktop.app/Contents/MacOS/agentroam-remote-desktop +0 -0
- package/runtime/native/Support.noindex/AgentRoam Remote Desktop.app/Contents/Resources/agentroam-component.json +1 -1
- package/runtime/native/Support.noindex/AgentRoam Remote Desktop.app/Contents/_CodeSignature/CodeResources +2 -2
- package/runtime/node_modules/.package-lock.json +20 -20
- package/runtime/node_modules/@agent/core/dist/index.js +13 -3
- package/runtime/node_modules/@anthropic-ai/claude-agent-sdk/bridge.mjs +75 -73
- package/runtime/node_modules/@anthropic-ai/claude-agent-sdk/browser-sdk.js +42 -40
- package/runtime/node_modules/@anthropic-ai/claude-agent-sdk/core-07pvccxf.mjs +43 -0
- package/runtime/node_modules/@anthropic-ai/claude-agent-sdk/{core-kzw924e6.mjs → core-0rjxgk9e.mjs} +3 -3
- package/runtime/node_modules/@anthropic-ai/claude-agent-sdk/core-fpeb751h.mjs +33 -0
- package/runtime/node_modules/@anthropic-ai/claude-agent-sdk/{core-bb8r6h44.mjs → core-jf0rbr11.mjs} +1 -1
- package/runtime/node_modules/@anthropic-ai/claude-agent-sdk/core.mjs +9 -9
- package/runtime/node_modules/@anthropic-ai/claude-agent-sdk/manifest.json +19 -21
- package/runtime/node_modules/@anthropic-ai/claude-agent-sdk/manifest.zst.json +23 -25
- package/runtime/node_modules/@anthropic-ai/claude-agent-sdk/package.json +14 -14
- package/runtime/node_modules/@anthropic-ai/claude-agent-sdk/sdk.mjs +61 -57
- package/runtime/node_modules/mediabunny/dist/bundles/mediabunny.cjs +29701 -29485
- package/runtime/node_modules/mediabunny/dist/bundles/mediabunny.min.cjs +20 -20
- package/runtime/node_modules/mediabunny/dist/bundles/mediabunny.min.mjs +20 -20
- package/runtime/node_modules/mediabunny/dist/bundles/mediabunny.mjs +29701 -29485
- package/runtime/node_modules/mediabunny/dist/bundles/mediabunny.node.cjs +28904 -28688
- package/runtime/node_modules/mediabunny/dist/modules/src/codec-data.js +6 -0
- package/runtime/node_modules/mediabunny/dist/modules/src/codec.js +35 -0
- package/runtime/node_modules/mediabunny/dist/modules/src/conversion.js +90 -13
- package/runtime/node_modules/mediabunny/dist/modules/src/id3.js +6 -0
- package/runtime/node_modules/mediabunny/dist/modules/src/isobmff/isobmff-boxes.js +23 -3
- package/runtime/node_modules/mediabunny/dist/modules/src/isobmff/isobmff-demuxer.js +12 -3
- package/runtime/node_modules/mediabunny/dist/modules/src/isobmff/isobmff-misc.js +1 -0
- package/runtime/node_modules/mediabunny/dist/modules/src/isobmff/isobmff-muxer.js +29 -6
- package/runtime/node_modules/mediabunny/dist/modules/src/matroska/ebml.js +9 -0
- package/runtime/node_modules/mediabunny/dist/modules/src/matroska/matroska-demuxer.js +10 -1
- package/runtime/node_modules/mediabunny/dist/modules/src/matroska/matroska-muxer.js +16 -2
- package/runtime/node_modules/mediabunny/dist/modules/src/media-source.js +59 -36
- package/runtime/node_modules/mediabunny/dist/modules/src/metadata.js +5 -0
- package/runtime/node_modules/mediabunny/dist/modules/src/output-format.js +10 -0
- package/runtime/node_modules/mediabunny/dist/modules/src/sample.js +1 -1
- package/runtime/node_modules/mediabunny/dist/modules/src/tsconfig.tsbuildinfo +1 -1
- package/runtime/node_modules/mediabunny/dist/modules/src/version.js +1 -1
- package/runtime/node_modules/mediabunny/dist/modules/src/wave/wave-muxer.js +1 -0
- package/runtime/node_modules/mediabunny/package.json +1 -1
- package/runtime/node_modules/mediabunny/src/codec-data.ts +4 -0
- package/runtime/node_modules/mediabunny/src/codec.ts +38 -0
- package/runtime/node_modules/mediabunny/src/conversion.ts +128 -16
- package/runtime/node_modules/mediabunny/src/id3.ts +4 -0
- package/runtime/node_modules/mediabunny/src/isobmff/isobmff-boxes.ts +24 -4
- package/runtime/node_modules/mediabunny/src/isobmff/isobmff-demuxer.ts +18 -3
- package/runtime/node_modules/mediabunny/src/isobmff/isobmff-misc.ts +2 -0
- package/runtime/node_modules/mediabunny/src/isobmff/isobmff-muxer.ts +39 -7
- package/runtime/node_modules/mediabunny/src/matroska/ebml.ts +11 -0
- package/runtime/node_modules/mediabunny/src/matroska/matroska-demuxer.ts +11 -0
- package/runtime/node_modules/mediabunny/src/matroska/matroska-muxer.ts +20 -2
- package/runtime/node_modules/mediabunny/src/media-source.ts +77 -52
- package/runtime/node_modules/mediabunny/src/metadata.ts +13 -0
- package/runtime/node_modules/mediabunny/src/output-format.ts +13 -1
- package/runtime/node_modules/mediabunny/src/sample.ts +1 -1
- package/runtime/node_modules/mediabunny/src/version.ts +1 -1
- package/runtime/node_modules/mediabunny/src/wave/wave-muxer.ts +2 -1
- package/runtime/node_modules/tslib/README.md +3 -8
- package/runtime/node_modules/tslib/package.json +1 -1
- package/runtime/node_modules/tslib/tslib.es6.js +10 -1
- package/runtime/node_modules/tslib/tslib.es6.mjs +10 -1
- package/runtime/node_modules/tslib/tslib.js +10 -1
- package/runtime/node_modules/ws/README.md +21 -29
- package/runtime/node_modules/ws/lib/buffer-util.js +13 -2
- package/runtime/node_modules/ws/lib/sender.js +4 -1
- package/runtime/node_modules/ws/lib/websocket.js +8 -3
- package/runtime/node_modules/ws/package.json +1 -1
- package/runtime/package-lock.json +44 -44
- package/runtime/server.js +1 -1
- package/runtime/webapp/dist/assets/{AiHubPane-BQ8CJAQL.js → AiHubPane-Cp_tNJNR.js} +1 -1
- package/runtime/webapp/dist/assets/App-Cs8U1u-X.js +175 -0
- package/runtime/webapp/dist/assets/App-QWoPBMW0.css +1 -0
- package/runtime/webapp/dist/assets/{BrowserLivePanel-DxhSUu4j.js → BrowserLivePanel-B1zYRS_7.js} +1 -1
- package/runtime/webapp/dist/assets/{CollaborationDashboard-c_iNusPf.js → CollaborationDashboard-DIVa26zk.js} +1 -1
- package/runtime/webapp/dist/assets/{CollaborationPage-DRBPK_iH.js → CollaborationPage-Fsvkw8ZM.js} +1 -1
- package/runtime/webapp/dist/assets/{FilePreview-DScFSi_K.js → FilePreview-BjbfWw2s.js} +3 -3
- package/runtime/webapp/dist/assets/{FileTree-BB5xTMg6.js → FileTree-C6gg9p4m.js} +1 -1
- package/runtime/webapp/dist/assets/{FlowStudioPane-BBf0zyw1.js → FlowStudioPane-CCuxZBVJ.js} +1 -1
- package/runtime/webapp/dist/assets/{RemoteDesktopPage-CWW4T1QF.js → RemoteDesktopPage-DpoYuKhA.js} +1 -1
- package/runtime/webapp/dist/assets/SessionDashboard-CAoW5-uN.css +1 -0
- package/runtime/webapp/dist/assets/SessionDashboard-DOWjUIY1.js +26 -0
- package/runtime/webapp/dist/assets/SessionDashboardBridge-DYsMZhuH.js +1 -0
- package/runtime/webapp/dist/assets/{TerminalPane-DkEyD1ge.js → TerminalPane-CPOiBcye.js} +1 -1
- package/runtime/webapp/dist/assets/{abnfDiagram-VCTEODGH-Dlsyu96y.js → abnfDiagram-VCTEODGH-DCFFqJUU.js} +1 -1
- package/runtime/webapp/dist/assets/{arc-D0AvBRtK.js → arc-vjNW9DYV.js} +1 -1
- package/runtime/webapp/dist/assets/{architectureDiagram-5GKGNRK7-BLAHjBcI.js → architectureDiagram-5GKGNRK7-DoK3A_n1.js} +1 -1
- package/runtime/webapp/dist/assets/{arrow-right-B15rGLIR.js → arrow-right-B0uCZ1Pd.js} +1 -1
- package/runtime/webapp/dist/assets/{artifact-links-BkoUldDR.js → artifact-links-nzx7joYs.js} +1 -1
- package/runtime/webapp/dist/assets/{blockDiagram-I7D4REHJ-CqIb0xz-.js → blockDiagram-I7D4REHJ-DgXszyX7.js} +1 -1
- package/runtime/webapp/dist/assets/{c4Diagram-7LVT6UL2-CG98ZTHr.js → c4Diagram-7LVT6UL2-q7KO4v1Q.js} +1 -1
- package/runtime/webapp/dist/assets/channel-CsnhvX8S.js +1 -0
- package/runtime/webapp/dist/assets/{chunk-2Q5K7J3B-DQh8kgcp.js → chunk-2Q5K7J3B-CH8lOKmL.js} +1 -1
- package/runtime/webapp/dist/assets/{chunk-5VM5RSS4-BesfCxeX.js → chunk-5VM5RSS4-DwP7xEWd.js} +1 -1
- package/runtime/webapp/dist/assets/{chunk-F27PBJKO-BCXEjgx-.js → chunk-F27PBJKO-BV3TTaxI.js} +1 -1
- package/runtime/webapp/dist/assets/{chunk-IMKFNOWR-ydMd7mT-.js → chunk-IMKFNOWR-BbaiG4yG.js} +1 -1
- package/runtime/webapp/dist/assets/{chunk-JWPE2WC7-K3_myO-F.js → chunk-JWPE2WC7-Dv9x27hI.js} +1 -1
- package/runtime/webapp/dist/assets/{chunk-POPQ4Y6H-BtqLafwd.js → chunk-POPQ4Y6H-Uk-GiSLP.js} +1 -1
- package/runtime/webapp/dist/assets/{chunk-SVP7TREG-mKZUbHcv.js → chunk-SVP7TREG-lFcKEwyL.js} +1 -1
- package/runtime/webapp/dist/assets/{chunk-TICWLB2K-hDH9_eNh.js → chunk-TICWLB2K-DFZALWPC.js} +1 -1
- package/runtime/webapp/dist/assets/{chunk-XXDRQBXY-B6wXA24N.js → chunk-XXDRQBXY-8jLPZkMb.js} +1 -1
- package/runtime/webapp/dist/assets/classDiagram-ZZMXUADV-Bed40USf.js +1 -0
- package/runtime/webapp/dist/assets/classDiagram-v2-VYDZK3BY-Bed40USf.js +1 -0
- package/runtime/webapp/dist/assets/{clipboard-CrmYgzo8.js → clipboard-BteN9-AC.js} +1 -1
- package/runtime/webapp/dist/assets/{codeSyntax-KyRYSqw_.js → codeSyntax-Dgv0FfoZ.js} +1 -1
- package/runtime/webapp/dist/assets/{collaboration-B7rPFZje.js → collaboration-f29NaKWy.js} +1 -1
- package/runtime/webapp/dist/assets/{cose-bilkent-JH36ORCC-MoeyZZ6x.js → cose-bilkent-JH36ORCC-86P-lxD4.js} +1 -1
- package/runtime/webapp/dist/assets/{crown-BKylWZLt.js → crown-y1qmM0NZ.js} +1 -1
- package/runtime/webapp/dist/assets/{cynefin-OW5HDTMX-BWYtTqVq.js → cynefin-OW5HDTMX-mtRVdchl.js} +1 -1
- package/runtime/webapp/dist/assets/{cynefinDiagram-5FMLGOSQ-CoqnJ7eo.js → cynefinDiagram-5FMLGOSQ-DhqAIoq6.js} +1 -1
- package/runtime/webapp/dist/assets/{dagre-GXQ25YYZ-DMwZ_7F7.js → dagre-GXQ25YYZ-DD9olCTy.js} +1 -1
- package/runtime/webapp/dist/assets/{diagram-S7CK7UJ4-DJ2BAyzP.js → diagram-S7CK7UJ4-CLGKipLp.js} +1 -1
- package/runtime/webapp/dist/assets/{diagram-UQ7AKVKN-ChujnpjG.js → diagram-UQ7AKVKN-Dm7uGpUO.js} +1 -1
- package/runtime/webapp/dist/assets/{diagram-VSXAHHWV-CDSAKYID.js → diagram-VSXAHHWV-OZYfwAth.js} +1 -1
- package/runtime/webapp/dist/assets/{diagram-VX7I27RA-DXvCy8w-.js → diagram-VX7I27RA-BpQqNFxQ.js} +1 -1
- package/runtime/webapp/dist/assets/{diagram-Z3DM3KII-BWrKegI9.js → diagram-Z3DM3KII-BrWsMYCU.js} +1 -1
- package/runtime/webapp/dist/assets/{ebnfDiagram-PWID7BFC-CqDhPmpp.js → ebnfDiagram-PWID7BFC-BRH-K-J7.js} +1 -1
- package/runtime/webapp/dist/assets/{erDiagram-RLTQ6QDP-D5HR9ddP.js → erDiagram-RLTQ6QDP-BDNSVr6H.js} +1 -1
- package/runtime/webapp/dist/assets/{file-types-D_egQYAD.js → file-types-XHMBkbNr.js} +1 -1
- package/runtime/webapp/dist/assets/{flowDiagram-HODETNUW-Bz89eEJ2.js → flowDiagram-HODETNUW-DseLK02Y.js} +1 -1
- package/runtime/webapp/dist/assets/{ganttDiagram-EL5Y4UJY-Bw1lo_RG.js → ganttDiagram-EL5Y4UJY-v_uNZx1g.js} +1 -1
- package/runtime/webapp/dist/assets/{gitGraphDiagram-WWUBYQGX-CMxwIm3p.js → gitGraphDiagram-WWUBYQGX-EdvVYEMk.js} +1 -1
- package/runtime/webapp/dist/assets/{index-CkVSxxim.js → index--zKd3rTs.js} +49 -49
- package/runtime/webapp/dist/assets/{index-6B8SDnzK.css → index-D0gsdpeQ.css} +1 -1
- package/runtime/webapp/dist/assets/{infoDiagram-27XIBGKW-DEWyQUst.js → infoDiagram-27XIBGKW-Ck26xp1i.js} +1 -1
- package/runtime/webapp/dist/assets/{ishikawaDiagram-5VMMS53U-BfJdGhe_.js → ishikawaDiagram-5VMMS53U-DGnOVObq.js} +1 -1
- package/runtime/webapp/dist/assets/{journeyDiagram-3NMN7TZE-C6gh2ejc.js → journeyDiagram-3NMN7TZE-S7oKAQs8.js} +1 -1
- package/runtime/webapp/dist/assets/{kanban-definition-UXKFOSKX-1UHi9Lfv.js → kanban-definition-UXKFOSKX-DcrYA4VY.js} +1 -1
- package/runtime/webapp/dist/assets/{layout-CKq-cSTm.js → layout-CYHINS_I.js} +1 -1
- package/runtime/webapp/dist/assets/{linear-DF4sJk10.js → linear-B-lEfto_.js} +1 -1
- package/runtime/webapp/dist/assets/{loader-circle-Dpjix4wZ.js → loader-circle-DMWQZenY.js} +1 -1
- package/runtime/webapp/dist/assets/{mermaid.core-OAHUFl3p.js → mermaid.core-B3fzlEw9.js} +5 -5
- package/runtime/webapp/dist/assets/{mindmap-definition-YA3MSWOX-JiyyEKeC.js → mindmap-definition-YA3MSWOX-wJkCh55V.js} +1 -1
- package/runtime/webapp/dist/assets/{page-DqgtSgo3.js → page-Cc56wyOt.js} +8 -13
- package/runtime/webapp/dist/assets/{pegDiagram-XKGWAZYB-CpBwPi33.js → pegDiagram-XKGWAZYB-H4uk2OUO.js} +1 -1
- package/runtime/webapp/dist/assets/{pieDiagram-E7YTZNPT-BjM_PcYH.js → pieDiagram-E7YTZNPT-yLnU_MCb.js} +1 -1
- package/runtime/webapp/dist/assets/{quadrantDiagram-AXDQQJYC-Vdz77obz.js → quadrantDiagram-AXDQQJYC-DyD93O4P.js} +1 -1
- package/runtime/webapp/dist/assets/{railroadDiagram-O6MQD6OU-DsQjNf1f.js → railroadDiagram-O6MQD6OU-DZ833xbw.js} +1 -1
- package/runtime/webapp/dist/assets/{requirementDiagram-BXWQKSXE-TpfT8TjT.js → requirementDiagram-BXWQKSXE-DJV4nGui.js} +1 -1
- package/runtime/webapp/dist/assets/{rotate-ccw-wJiVuYlm.js → rotate-ccw-CKqo62Ra.js} +1 -1
- package/runtime/webapp/dist/assets/{rotate-cw-CtpBETpM.js → rotate-cw-D-M3ZDSa.js} +1 -1
- package/runtime/webapp/dist/assets/{sankeyDiagram-P5KCCOFB-Ckh_skQw.js → sankeyDiagram-P5KCCOFB-BeOYMFTR.js} +1 -1
- package/runtime/webapp/dist/assets/{send-DL0qj0xE.js → send-LvtpJMkk.js} +1 -1
- package/runtime/webapp/dist/assets/{sequenceDiagram-WJ2MYXX4-CkKC0JEA.js → sequenceDiagram-WJ2MYXX4-BBcgqG33.js} +1 -1
- package/runtime/webapp/dist/assets/{shield-check-B5q8YhWs.js → shield-check-SeEkz1Nd.js} +1 -1
- package/runtime/webapp/dist/assets/{sizeCapture-INFHLROL-DB_NzdXU.js → sizeCapture-INFHLROL-B0GJZjw0.js} +1 -1
- package/runtime/webapp/dist/assets/{smartphone-DJEfFl42.js → smartphone-D7oS3YTz.js} +11 -6
- package/runtime/webapp/dist/assets/{stateDiagram-D77RDMKH-Ch2r76jY.js → stateDiagram-D77RDMKH-BmSvB3vd.js} +1 -1
- package/runtime/webapp/dist/assets/stateDiagram-v2-MP3YSRHH-CQ9wpJCJ.js +1 -0
- package/runtime/webapp/dist/assets/{swimlanes-42K2YHIH-BBMlDhHH.js → swimlanes-42K2YHIH-BAZdMUD6.js} +1 -1
- package/runtime/webapp/dist/assets/swimlanesDiagram-VR7AAH4N-8XTJp3Fr.js +8 -0
- package/runtime/webapp/dist/assets/{timeline-definition-24CTP7MA-BELJuISI.js → timeline-definition-24CTP7MA-BSgVFMNG.js} +1 -1
- package/runtime/webapp/dist/assets/{trash-2-D4LqA3q5.js → trash-2-CHYPyYDY.js} +1 -1
- package/runtime/webapp/dist/assets/{vennDiagram-4TSXK5OY-NSlXdmyy.js → vennDiagram-4TSXK5OY-C-brvbkB.js} +1 -1
- package/runtime/webapp/dist/assets/{wardleyDiagram-VM6X3IG4-BVbNDhZr.js → wardleyDiagram-VM6X3IG4-CeqqVR1s.js} +1 -1
- package/runtime/webapp/dist/assets/{web-CoxxvfFh.js → web-Dzd7NW_F.js} +1 -1
- package/runtime/webapp/dist/assets/{web-BpA_VIiS.js → web-aLPH3xFw.js} +1 -1
- package/runtime/webapp/dist/assets/{xychartDiagram-S5SC5T6Z-Bt3XghTc.js → xychartDiagram-S5SC5T6Z-mPizwpXM.js} +1 -1
- package/runtime/webapp/dist/index.html +2 -2
- package/runtime/ws-server.mjs +4 -0
- package/runtime/.next/static/chunks/app/web/layout-8ec7c101bbab1dc2.js +0 -1
- package/runtime/node_modules/@anthropic-ai/claude-agent-sdk/core-a9vq6p1m.mjs +0 -31
- package/runtime/node_modules/@anthropic-ai/claude-agent-sdk/core-t4mxrz5y.mjs +0 -43
- package/runtime/webapp/dist/assets/App-CdrKKs1h.css +0 -1
- package/runtime/webapp/dist/assets/App-GXFFBAhW.js +0 -174
- package/runtime/webapp/dist/assets/SessionDashboard-BdGlakPd.js +0 -26
- package/runtime/webapp/dist/assets/SessionDashboard-CUCEDkCI.css +0 -1
- package/runtime/webapp/dist/assets/SessionDashboardBridge-8zrk0Bub.js +0 -1
- package/runtime/webapp/dist/assets/channel-Bw3F6pJc.js +0 -1
- package/runtime/webapp/dist/assets/classDiagram-ZZMXUADV-By2XJYuW.js +0 -1
- package/runtime/webapp/dist/assets/classDiagram-v2-VYDZK3BY-By2XJYuW.js +0 -1
- package/runtime/webapp/dist/assets/stateDiagram-v2-MP3YSRHH-BCjtOHJv.js +0 -1
- package/runtime/webapp/dist/assets/swimlanesDiagram-VR7AAH4N-CYzCynNs.js +0 -8
- /package/runtime/.next/static/{Ow_KjPn75TzR7WqdD4P9x → mGwTFWK2dzlY3HjsjZGzh}/_buildManifest.js +0 -0
- /package/runtime/.next/static/{Ow_KjPn75TzR7WqdD4P9x → mGwTFWK2dzlY3HjsjZGzh}/_ssgManifest.js +0 -0
|
@@ -2020,6 +2020,8 @@ export class EncodedAudioPacketSource extends AudioSource {
|
|
|
2020
2020
|
}
|
|
2021
2021
|
}
|
|
2022
2022
|
|
|
2023
|
+
export const PCM_ENCODER_PACKET_SIZE = 2048; // In frames
|
|
2024
|
+
|
|
2023
2025
|
class AudioEncoderWrapper {
|
|
2024
2026
|
private ensureEncoderPromise: Promise<void> | null = null;
|
|
2025
2027
|
private encoderInitialized = false;
|
|
@@ -2031,6 +2033,12 @@ class AudioEncoderWrapper {
|
|
|
2031
2033
|
private isPcmEncoder = false;
|
|
2032
2034
|
private outputSampleSize: number | null = null;
|
|
2033
2035
|
private writeOutputValue: ((view: DataView, byteOffset: number, value: number) => void) | null = null;
|
|
2036
|
+
private pcmMeta: EncodedAudioChunkMetadata | null = null;
|
|
2037
|
+
private pcmStartTimestamp = 0;
|
|
2038
|
+
private pcmEmittedFrames = 0;
|
|
2039
|
+
private pcmReadBuffer = new ArrayBuffer(0);
|
|
2040
|
+
private pcmScratchView: DataView | null = null;
|
|
2041
|
+
private pcmScratchFrames = 0;
|
|
2034
2042
|
|
|
2035
2043
|
private customEncoder: CustomAudioEncoder | null = null;
|
|
2036
2044
|
private customEncoderCallSerializer = new CallSerializer();
|
|
@@ -2292,74 +2300,87 @@ class AudioEncoderWrapper {
|
|
|
2292
2300
|
// Need to extract data from the audio data before we close it
|
|
2293
2301
|
const { numberOfChannels, numberOfFrames, sampleRate, timestamp } = audioSample;
|
|
2294
2302
|
|
|
2295
|
-
|
|
2296
|
-
|
|
2297
|
-
|
|
2298
|
-
|
|
2299
|
-
|
|
2300
|
-
|
|
2301
|
-
|
|
2302
|
-
|
|
2303
|
-
|
|
2304
|
-
|
|
2305
|
-
const outputBuffer = new ArrayBuffer(outputSize);
|
|
2306
|
-
const outputView = new DataView(outputBuffer);
|
|
2307
|
-
|
|
2308
|
-
outputs.push({ frameCount, view: outputView });
|
|
2303
|
+
if (!this.pcmMeta) {
|
|
2304
|
+
this.pcmMeta = {
|
|
2305
|
+
decoderConfig: {
|
|
2306
|
+
codec: this.encodingConfig.codec,
|
|
2307
|
+
numberOfChannels,
|
|
2308
|
+
sampleRate,
|
|
2309
|
+
},
|
|
2310
|
+
};
|
|
2311
|
+
// Gaps get padded with silence before reaching us, so it's one contiguous run from here on
|
|
2312
|
+
this.pcmStartTimestamp = timestamp;
|
|
2309
2313
|
}
|
|
2310
2314
|
|
|
2315
|
+
// Read the whole sample interleaved into our reusable read buffer, growing it if needed
|
|
2311
2316
|
const isS32 = audioSample.format === 's32' || audioSample.format === 's32-planar';
|
|
2312
|
-
const readFormat = isS32 ? 's32
|
|
2317
|
+
const readFormat = isS32 ? 's32' : 'f32'; // Can't read in f32 due to precision loss
|
|
2313
2318
|
const scale = isS32 ? 1 / 2147483648 : 1;
|
|
2314
2319
|
|
|
2315
|
-
const allocationSize = audioSample.allocationSize(
|
|
2320
|
+
const allocationSize = audioSample.allocationSize({ planeIndex: 0, format: readFormat });
|
|
2321
|
+
if (this.pcmReadBuffer.byteLength < allocationSize) {
|
|
2322
|
+
this.pcmReadBuffer = new ArrayBuffer(allocationSize);
|
|
2323
|
+
}
|
|
2316
2324
|
const values = isS32
|
|
2317
|
-
? new Int32Array(allocationSize / 4)
|
|
2318
|
-
: new Float32Array(allocationSize / 4);
|
|
2325
|
+
? new Int32Array(this.pcmReadBuffer, 0, allocationSize / 4)
|
|
2326
|
+
: new Float32Array(this.pcmReadBuffer, 0, allocationSize / 4);
|
|
2327
|
+
audioSample.copyTo(values, { planeIndex: 0, format: readFormat });
|
|
2319
2328
|
|
|
2320
|
-
|
|
2321
|
-
audioSample.
|
|
2329
|
+
if (shouldClose) {
|
|
2330
|
+
audioSample.close();
|
|
2331
|
+
}
|
|
2322
2332
|
|
|
2323
|
-
|
|
2324
|
-
|
|
2333
|
+
// Fill up the scratch buffer, emitting it as a packet each time it's full
|
|
2334
|
+
let frame = 0;
|
|
2335
|
+
while (frame < numberOfFrames) {
|
|
2336
|
+
this.pcmScratchView ??= new DataView(
|
|
2337
|
+
new ArrayBuffer(PCM_ENCODER_PACKET_SIZE * numberOfChannels * this.outputSampleSize),
|
|
2338
|
+
);
|
|
2325
2339
|
|
|
2326
|
-
|
|
2327
|
-
|
|
2328
|
-
|
|
2329
|
-
|
|
2330
|
-
|
|
2331
|
-
|
|
2332
|
-
|
|
2340
|
+
const frameCount = Math.min(PCM_ENCODER_PACKET_SIZE - this.pcmScratchFrames, numberOfFrames - frame);
|
|
2341
|
+
const valueOffset = this.pcmScratchFrames * numberOfChannels;
|
|
2342
|
+
const readOffset = frame * numberOfChannels;
|
|
2343
|
+
|
|
2344
|
+
for (let i = 0; i < frameCount * numberOfChannels; i++) {
|
|
2345
|
+
this.writeOutputValue(
|
|
2346
|
+
this.pcmScratchView,
|
|
2347
|
+
(valueOffset + i) * this.outputSampleSize,
|
|
2348
|
+
values[readOffset + i]! * scale,
|
|
2349
|
+
);
|
|
2333
2350
|
}
|
|
2334
|
-
}
|
|
2335
2351
|
|
|
2336
|
-
|
|
2337
|
-
|
|
2352
|
+
this.pcmScratchFrames += frameCount;
|
|
2353
|
+
frame += frameCount;
|
|
2354
|
+
|
|
2355
|
+
if (this.pcmScratchFrames === PCM_ENCODER_PACKET_SIZE) {
|
|
2356
|
+
await this.emitPcmScratchPacket();
|
|
2357
|
+
}
|
|
2338
2358
|
}
|
|
2359
|
+
}
|
|
2339
2360
|
|
|
2340
|
-
|
|
2341
|
-
|
|
2342
|
-
|
|
2343
|
-
|
|
2344
|
-
sampleRate,
|
|
2345
|
-
},
|
|
2346
|
-
};
|
|
2361
|
+
private async emitPcmScratchPacket() {
|
|
2362
|
+
assert(this.outputSampleSize);
|
|
2363
|
+
assert(this.pcmScratchView);
|
|
2364
|
+
assert(this.pcmMeta?.decoderConfig);
|
|
2347
2365
|
|
|
2348
|
-
|
|
2349
|
-
|
|
2350
|
-
const outputBuffer = view.buffer;
|
|
2351
|
-
const startFrame = i * CHUNK_SIZE;
|
|
2366
|
+
const { numberOfChannels, sampleRate } = this.pcmMeta.decoderConfig;
|
|
2367
|
+
const byteLength = this.pcmScratchFrames * numberOfChannels * this.outputSampleSize;
|
|
2352
2368
|
|
|
2353
|
-
|
|
2354
|
-
|
|
2355
|
-
|
|
2356
|
-
|
|
2357
|
-
|
|
2358
|
-
|
|
2369
|
+
const packet = new EncodedPacket(
|
|
2370
|
+
new Uint8Array(this.pcmScratchView.buffer, 0, byteLength),
|
|
2371
|
+
'key',
|
|
2372
|
+
this.pcmStartTimestamp + this.pcmEmittedFrames / sampleRate,
|
|
2373
|
+
this.pcmScratchFrames / sampleRate,
|
|
2374
|
+
);
|
|
2375
|
+
this.pcmEmittedFrames += this.pcmScratchFrames;
|
|
2359
2376
|
|
|
2360
|
-
|
|
2361
|
-
|
|
2362
|
-
|
|
2377
|
+
// The packet now owns the buffer
|
|
2378
|
+
this.pcmScratchView = null;
|
|
2379
|
+
this.pcmScratchFrames = 0;
|
|
2380
|
+
|
|
2381
|
+
this.encodingConfig.onEncodedPacket?.(packet, this.pcmMeta);
|
|
2382
|
+
// With backpressure:
|
|
2383
|
+
await this.muxer!.addEncodedAudioPacket(this.source._connectedTrack!, packet, this.pcmMeta);
|
|
2363
2384
|
}
|
|
2364
2385
|
|
|
2365
2386
|
private ensureEncoder(audioSample: AudioSample) {
|
|
@@ -2613,6 +2634,10 @@ class AudioEncoderWrapper {
|
|
|
2613
2634
|
if (this.resampler) {
|
|
2614
2635
|
await this.resampler.finalize();
|
|
2615
2636
|
}
|
|
2637
|
+
|
|
2638
|
+
if (this.pcmScratchFrames > 0) {
|
|
2639
|
+
await this.emitPcmScratchPacket();
|
|
2640
|
+
}
|
|
2616
2641
|
}
|
|
2617
2642
|
|
|
2618
2643
|
this.closed = true;
|
|
@@ -58,6 +58,12 @@ export type MetadataTags = {
|
|
|
58
58
|
comment?: string;
|
|
59
59
|
/** Embedded images such as cover art, booklet scans, artwork or preview frames. */
|
|
60
60
|
images?: AttachedImage[];
|
|
61
|
+
/** The time at which the media file itself was created.
|
|
62
|
+
*
|
|
63
|
+
* When writing, leaving this field undefined will write the current date and time to the formats that support this
|
|
64
|
+
* field. If you don't want to write this info, set this field to `null` instead.
|
|
65
|
+
*/
|
|
66
|
+
creationTime?: Date | null;
|
|
61
67
|
/**
|
|
62
68
|
* The raw, underlying metadata tags.
|
|
63
69
|
*
|
|
@@ -212,6 +218,13 @@ export const validateMetadataTags = (tags: MetadataTags) => {
|
|
|
212
218
|
if (tags.date !== undefined && (!(tags.date instanceof Date) || Number.isNaN(tags.date.getTime()))) {
|
|
213
219
|
throw new TypeError('tags.date, when provided, must be a valid Date.');
|
|
214
220
|
}
|
|
221
|
+
if (
|
|
222
|
+
tags.creationTime !== undefined
|
|
223
|
+
&& tags.creationTime !== null
|
|
224
|
+
&& (!(tags.creationTime instanceof Date) || Number.isNaN(tags.creationTime.getTime()))
|
|
225
|
+
) {
|
|
226
|
+
throw new TypeError('tags.creationTime, when provided, must be a valid Date or null.');
|
|
227
|
+
}
|
|
215
228
|
if (
|
|
216
229
|
tags.beatsPerMinute !== undefined
|
|
217
230
|
&& (!Number.isInteger(tags.beatsPerMinute) || tags.beatsPerMinute <= 0)
|
|
@@ -102,6 +102,14 @@ export abstract class OutputFormat {
|
|
|
102
102
|
*/
|
|
103
103
|
abstract get negativeTimestampSupport(): 'full' | 'prefer-non-negative' | 'none' | null;
|
|
104
104
|
|
|
105
|
+
/**
|
|
106
|
+
* Whether this output format, as configured, requires {@link BaseTrackMetadata.maximumPacketCount} to be set in
|
|
107
|
+
* the metadata of every track added to it.
|
|
108
|
+
*/
|
|
109
|
+
get requiresMaximumPacketCount() {
|
|
110
|
+
return false;
|
|
111
|
+
}
|
|
112
|
+
|
|
105
113
|
/** Returns a list of video codecs that this output format can contain. */
|
|
106
114
|
getSupportedVideoCodecs(): VideoCodec[] {
|
|
107
115
|
return this.getSupportedCodecs()
|
|
@@ -152,7 +160,7 @@ export type IsobmffOutputFormatOptions = {
|
|
|
152
160
|
* Use `'reserve'` to reserve space at the start of the file into which the metadata will be written later. This
|
|
153
161
|
* produces a file with Fast Start but requires knowledge about the expected length of the file beforehand. When
|
|
154
162
|
* using this option, you must set the {@link BaseTrackMetadata.maximumPacketCount} field in the track metadata
|
|
155
|
-
* for all tracks.
|
|
163
|
+
* for all tracks. {@link Conversion} estimates this count automatically if no override is provided.
|
|
156
164
|
*
|
|
157
165
|
* Use `'fragmented'` to place metadata at the start of the file by creating a fragmented file (fMP4). In a
|
|
158
166
|
* fragmented file, chunks of media and their metadata are written to the file in "fragments", eliminating the need
|
|
@@ -298,6 +306,10 @@ export abstract class IsobmffOutputFormat extends OutputFormat {
|
|
|
298
306
|
return 'full' as const;
|
|
299
307
|
}
|
|
300
308
|
|
|
309
|
+
override get requiresMaximumPacketCount() {
|
|
310
|
+
return this._options.fastStart === 'reserve';
|
|
311
|
+
}
|
|
312
|
+
|
|
301
313
|
/** @internal */
|
|
302
314
|
_createMuxer(output: Output) {
|
|
303
315
|
return new IsobmffMuxer(output, this);
|
|
@@ -3084,7 +3084,7 @@ export class AudioSample implements Disposable {
|
|
|
3084
3084
|
numberOfChannels: this.numberOfChannels,
|
|
3085
3085
|
timestamp: this.microsecondTimestamp,
|
|
3086
3086
|
data: this._data.buffer instanceof ArrayBuffer
|
|
3087
|
-
? this._data
|
|
3087
|
+
? this._data as Uint8Array<ArrayBuffer>
|
|
3088
3088
|
: this._data.slice(), // In the case of SharedArrayBuffer, convert to ArrayBuffer
|
|
3089
3089
|
});
|
|
3090
3090
|
}
|
|
@@ -138,14 +138,9 @@ For JSPM users:
|
|
|
138
138
|
|
|
139
139
|
## Deployment
|
|
140
140
|
|
|
141
|
-
-
|
|
142
|
-
-
|
|
143
|
-
-
|
|
144
|
-
- Push the tag: `git push --tags`
|
|
145
|
-
- Create a [release in GitHub](https://github.com/microsoft/tslib/releases)
|
|
146
|
-
- Run the [publish to npm](https://github.com/microsoft/tslib/actions?query=workflow%3A%22Publish+to+NPM%22) workflow
|
|
147
|
-
|
|
148
|
-
Done.
|
|
141
|
+
- Run the **Bump tslib** GitHub workflow and choose patch, minor, or major
|
|
142
|
+
- Review and squash-merge the generated version-bump PR
|
|
143
|
+
- The release runs automatically: tag, build, publish to npm, and create a GitHub release with generated notes
|
|
149
144
|
|
|
150
145
|
# Contribute
|
|
151
146
|
|
|
@@ -357,8 +357,17 @@ export function __disposeResources(env) {
|
|
|
357
357
|
return next();
|
|
358
358
|
}
|
|
359
359
|
|
|
360
|
-
export function __rewriteRelativeImportExtension(path, preserveJsx) {
|
|
360
|
+
export function __rewriteRelativeImportExtension(path, preserveJsx, extraExtensions, ignoreCase) {
|
|
361
361
|
if (typeof path === "string" && /^\.\.?\//.test(path)) {
|
|
362
|
+
if (extraExtensions) {
|
|
363
|
+
for (var extension in extraExtensions) {
|
|
364
|
+
var suffix = path.slice(-extension.length);
|
|
365
|
+
if (suffix === extension || ignoreCase && suffix.toLowerCase() === extension.toLowerCase()) {
|
|
366
|
+
var output = extraExtensions[extension];
|
|
367
|
+
return output === extension ? path : path.slice(0, -extension.length) + output;
|
|
368
|
+
}
|
|
369
|
+
}
|
|
370
|
+
}
|
|
362
371
|
return path.replace(/\.(tsx)$|((?:\.d)?)((?:\.[^./]+?)?)\.([cm]?)ts$/i, function (m, tsx, d, ext, cm) {
|
|
363
372
|
return tsx ? preserveJsx ? ".jsx" : ".js" : d && (!ext || !cm) ? m : (d + ext + "." + cm.toLowerCase() + "js");
|
|
364
373
|
});
|
|
@@ -356,8 +356,17 @@ export function __disposeResources(env) {
|
|
|
356
356
|
return next();
|
|
357
357
|
}
|
|
358
358
|
|
|
359
|
-
export function __rewriteRelativeImportExtension(path, preserveJsx) {
|
|
359
|
+
export function __rewriteRelativeImportExtension(path, preserveJsx, extraExtensions, ignoreCase) {
|
|
360
360
|
if (typeof path === "string" && /^\.\.?\//.test(path)) {
|
|
361
|
+
if (extraExtensions) {
|
|
362
|
+
for (var extension in extraExtensions) {
|
|
363
|
+
var suffix = path.slice(-extension.length);
|
|
364
|
+
if (suffix === extension || ignoreCase && suffix.toLowerCase() === extension.toLowerCase()) {
|
|
365
|
+
var output = extraExtensions[extension];
|
|
366
|
+
return output === extension ? path : path.slice(0, -extension.length) + output;
|
|
367
|
+
}
|
|
368
|
+
}
|
|
369
|
+
}
|
|
361
370
|
return path.replace(/\.(tsx)$|((?:\.d)?)((?:\.[^./]+?)?)\.([cm]?)ts$/i, function (m, tsx, d, ext, cm) {
|
|
362
371
|
return tsx ? preserveJsx ? ".jsx" : ".js" : d && (!ext || !cm) ? m : (d + ext + "." + cm.toLowerCase() + "js");
|
|
363
372
|
});
|
|
@@ -405,8 +405,17 @@ var __rewriteRelativeImportExtension;
|
|
|
405
405
|
return next();
|
|
406
406
|
};
|
|
407
407
|
|
|
408
|
-
__rewriteRelativeImportExtension = function (path, preserveJsx) {
|
|
408
|
+
__rewriteRelativeImportExtension = function (path, preserveJsx, extraExtensions, ignoreCase) {
|
|
409
409
|
if (typeof path === "string" && /^\.\.?\//.test(path)) {
|
|
410
|
+
if (extraExtensions) {
|
|
411
|
+
for (var extension in extraExtensions) {
|
|
412
|
+
var suffix = path.slice(-extension.length);
|
|
413
|
+
if (suffix === extension || ignoreCase && suffix.toLowerCase() === extension.toLowerCase()) {
|
|
414
|
+
var output = extraExtensions[extension];
|
|
415
|
+
return output === extension ? path : path.slice(0, -extension.length) + output;
|
|
416
|
+
}
|
|
417
|
+
}
|
|
418
|
+
}
|
|
410
419
|
return path.replace(/\.(tsx)$|((?:\.d)?)((?:\.[^./]+?)?)\.([cm]?)ts$/i, function (m, tsx, d, ext, cm) {
|
|
411
420
|
return tsx ? preserveJsx ? ".jsx" : ".js" : d && (!ext || !cm) ? m : (d + ext + "." + cm.toLowerCase() + "js");
|
|
412
421
|
});
|
|
@@ -56,39 +56,27 @@ can use one of the many wrappers available on npm, like
|
|
|
56
56
|
npm install ws
|
|
57
57
|
```
|
|
58
58
|
|
|
59
|
-
###
|
|
59
|
+
### Legacy opt-in for performance
|
|
60
60
|
|
|
61
|
-
|
|
62
|
-
|
|
61
|
+
On older Node.js versions, ws can leverage optional binary modules to optimize
|
|
62
|
+
performance.
|
|
63
63
|
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
This is a binary addon that improves the performance of certain operations such
|
|
69
|
-
as masking and unmasking the data payload of the WebSocket frames. Prebuilt
|
|
70
|
-
binaries are available for the most popular platforms, so you don't necessarily
|
|
71
|
-
need to have a C++ compiler installed on your machine.
|
|
72
|
-
|
|
73
|
-
To force ws to not use bufferutil, use the
|
|
74
|
-
[`WS_NO_BUFFER_UTIL`](./doc/ws.md#ws_no_buffer_util) environment variable. This
|
|
75
|
-
can be useful to enhance security in systems where a user can put a package in
|
|
76
|
-
the package search path of an application of another user, due to how the
|
|
77
|
-
Node.js resolver algorithm works.
|
|
78
|
-
|
|
79
|
-
#### Legacy opt-in for performance
|
|
80
|
-
|
|
81
|
-
If you are running on an old version of Node.js (prior to v18.14.0), ws also
|
|
82
|
-
supports the [utf-8-validate][] module:
|
|
83
|
-
|
|
84
|
-
```
|
|
85
|
-
npm install --save-optional utf-8-validate
|
|
86
|
-
```
|
|
64
|
+
- `npm install --save-optional bufferutil`: Provides binary polyfills for
|
|
65
|
+
[`http.websocketMask()`][] and [`http.websocketUnmask()`][].
|
|
66
|
+
- `npm install --save-optional utf-8-validate`: Provides a binary polyfill for
|
|
67
|
+
[`buffer.isUtf8()`][].
|
|
87
68
|
|
|
88
|
-
|
|
69
|
+
On newer Node.js versions (v27.0.0-alpha.0.0.0 or later for bufferutil, and
|
|
70
|
+
v18.14.0 or later for utf-8-validate) that feature built-in alternatives, these
|
|
71
|
+
modules are not loaded even if installed.
|
|
89
72
|
|
|
90
|
-
To force ws not to use utf-8-validate
|
|
91
|
-
|
|
73
|
+
To force ws not to use [bufferutil][] or [utf-8-validate][] on the older Node.js
|
|
74
|
+
versions where they would otherwise be loaded, set the
|
|
75
|
+
[`WS_NO_BUFFER_UTIL`](./doc/ws.md#ws_no_buffer_util) and
|
|
76
|
+
[`WS_NO_UTF_8_VALIDATE`](./doc/ws.md#ws_no_utf_8_validate) environment
|
|
77
|
+
variables. This can be useful to enhance security in systems where a user can
|
|
78
|
+
put a package in the package search path of an application of another user, due
|
|
79
|
+
to how the Node.js resolver algorithm works.
|
|
92
80
|
|
|
93
81
|
## API docs
|
|
94
82
|
|
|
@@ -533,6 +521,10 @@ We're using the GitHub [releases][changelog] for changelog entries.
|
|
|
533
521
|
[MIT](LICENSE)
|
|
534
522
|
|
|
535
523
|
[`buffer.isutf8()`]: https://nodejs.org/api/buffer.html#bufferisutf8input
|
|
524
|
+
[`http.websocketMask()`]:
|
|
525
|
+
https://nodejs.org/api/http.html#httpwebsocketmasksource-mask-output-offset-length
|
|
526
|
+
[`http.websocketUnmask()`]:
|
|
527
|
+
https://nodejs.org/api/http.html#httpwebsocketunmaskbuffer-mask
|
|
536
528
|
[bufferutil]: https://github.com/websockets/bufferutil
|
|
537
529
|
[changelog]: https://github.com/websockets/ws/releases
|
|
538
530
|
[client-report]: http://websockets.github.io/ws/autobahn/clients/
|
|
@@ -1,5 +1,7 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
+
const { websocketMask, websocketUnmask } = require('http');
|
|
4
|
+
|
|
3
5
|
const { EMPTY_BUFFER } = require('./constants');
|
|
4
6
|
|
|
5
7
|
const FastBuffer = Buffer[Symbol.species];
|
|
@@ -111,8 +113,17 @@ module.exports = {
|
|
|
111
113
|
unmask: _unmask
|
|
112
114
|
};
|
|
113
115
|
|
|
114
|
-
|
|
115
|
-
|
|
116
|
+
if (websocketMask) {
|
|
117
|
+
module.exports.mask = function (source, mask, output, offset, length) {
|
|
118
|
+
if (length < 24) _mask(source, mask, output, offset, length);
|
|
119
|
+
else websocketMask(source, mask, output, offset, length);
|
|
120
|
+
};
|
|
121
|
+
|
|
122
|
+
module.exports.unmask = function (buffer, mask) {
|
|
123
|
+
if (buffer.length < 24) _unmask(buffer, mask);
|
|
124
|
+
else websocketUnmask(buffer, mask);
|
|
125
|
+
};
|
|
126
|
+
} /* istanbul ignore else */ else if (!process.env.WS_NO_BUFFER_UTIL) {
|
|
116
127
|
try {
|
|
117
128
|
const bufferUtil = require('bufferutil');
|
|
118
129
|
|
|
@@ -153,7 +153,9 @@ class Sender {
|
|
|
153
153
|
target.writeUIntBE(dataLength, 4, 6);
|
|
154
154
|
}
|
|
155
155
|
|
|
156
|
-
if (!options.mask)
|
|
156
|
+
if (!options.mask) {
|
|
157
|
+
return dataLength ? [target, data] : [target];
|
|
158
|
+
}
|
|
157
159
|
|
|
158
160
|
target[1] |= 0x80;
|
|
159
161
|
target[offset - 4] = mask[0];
|
|
@@ -161,6 +163,7 @@ class Sender {
|
|
|
161
163
|
target[offset - 2] = mask[2];
|
|
162
164
|
target[offset - 1] = mask[3];
|
|
163
165
|
|
|
166
|
+
if (!dataLength) return [target];
|
|
164
167
|
if (skipMasking) return [target, data];
|
|
165
168
|
|
|
166
169
|
if (merge) {
|
|
@@ -819,10 +819,15 @@ function initAsClient(websocket, address, protocols, options) {
|
|
|
819
819
|
}
|
|
820
820
|
|
|
821
821
|
if (isIpcUrl) {
|
|
822
|
-
const
|
|
822
|
+
const i = opts.path.indexOf(':');
|
|
823
823
|
|
|
824
|
-
|
|
825
|
-
|
|
824
|
+
if (i === -1) {
|
|
825
|
+
opts.socketPath = opts.path;
|
|
826
|
+
opts.path = '';
|
|
827
|
+
} else {
|
|
828
|
+
opts.socketPath = opts.path.slice(0, i);
|
|
829
|
+
opts.path = opts.path.slice(i + 1);
|
|
830
|
+
}
|
|
826
831
|
}
|
|
827
832
|
|
|
828
833
|
let req;
|