@marimo-team/islands 0.19.8-dev4 → 0.19.8-dev40
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{Combination-Bg-xN8JV.js → Combination-BTMrlhzT.js} +11 -10
- package/dist/{ConnectedDataExplorerComponent-DewsKLl2.js → ConnectedDataExplorerComponent-BAeQ8DWw.js} +11 -11
- package/dist/{ImageComparisonComponent-Bijp8beW.js → ImageComparisonComponent-DkEXPki_.js} +2 -2
- package/dist/{any-language-editor-DZc6NCTp.js → any-language-editor-D0UQItkS.js} +6 -6
- package/dist/{architectureDiagram-VXUJARFQ--NkyBn9Y.js → architectureDiagram-VXUJARFQ-DPPYVq8H.js} +4 -4
- package/dist/assets/__vite-browser-external-6-UwTyQC.js +1 -0
- package/dist/assets/{worker-SqntmiwV.js → worker-D3e5wDxM.js} +4 -4
- package/dist/{blockDiagram-VD42YOAC-DEZZaTW0.js → blockDiagram-VD42YOAC-BA5N05Y9.js} +4 -4
- package/dist/{button-BWvsJ2Wr.js → button-Cy0ElmIm.js} +2 -2
- package/dist/{c4Diagram-YG6GDRKO-Bj7hwWCO.js → c4Diagram-YG6GDRKO-DJLzuGJJ.js} +3 -3
- package/dist/{channel-B_QrFrGg.js → channel-Dob5kWXR.js} +1 -1
- package/dist/{check-CM_kewwn.js → check-DkNR52Mm.js} +1 -1
- package/dist/{chunk-5FQGJX7Z-D5VFKHmt.js → chunk-5FQGJX7Z-BEb20Lzt.js} +3 -3
- package/dist/{chunk-ABZYJK2D-SZPYmRzN.js → chunk-ABZYJK2D-BXTC53mt.js} +1 -1
- package/dist/{chunk-ATLVNIR6-BI_WwH1o.js → chunk-ATLVNIR6-BJDjUR_c.js} +1 -1
- package/dist/{chunk-B4BG7PRW-BlI9Gm1l.js → chunk-B4BG7PRW-DzmUUpfH.js} +4 -4
- package/dist/{chunk-DI55MBZ5-BXxemMn5.js → chunk-DI55MBZ5-gTd3J8Tu.js} +4 -4
- package/dist/{chunk-EXTU4WIE-CzWtDV99.js → chunk-EXTU4WIE-DyoOs5QX.js} +1 -1
- package/dist/{chunk-JA3XYJ7Z-DQ-2ARfa.js → chunk-JA3XYJ7Z-BGnAIbOP.js} +2 -2
- package/dist/{chunk-JZLCHNYA-CVfjf2vv.js → chunk-JZLCHNYA-CIRgweVQ.js} +4 -4
- package/dist/{chunk-N4CR4FBY-BCZvQ7Jq.js → chunk-N4CR4FBY-DKSvXAIS.js} +5 -5
- package/dist/{chunk-QN33PNHL-DY_2Q2zl.js → chunk-QN33PNHL-B6zC8BTi.js} +1 -1
- package/dist/{chunk-QXUST7PY-BMCjAVR_.js → chunk-QXUST7PY-C7750n_u.js} +5 -5
- package/dist/{chunk-S3R3BYOJ-Ddu0H4Qa.js → chunk-S3R3BYOJ-CBkH6JZZ.js} +1 -1
- package/dist/{chunk-TZMSLE5B-C2wVlbMl.js → chunk-TZMSLE5B-DObGL7xi.js} +1 -1
- package/dist/{classDiagram-2ON5EDUG-D-g7zbyO.js → classDiagram-2ON5EDUG-B9pkKjjc.js} +9 -9
- package/dist/{classDiagram-v2-WZHVMYZB-C7v5zNRD.js → classDiagram-v2-WZHVMYZB-CRhhA0tV.js} +9 -9
- package/dist/{click-outside-container-BCN5BtVO.js → click-outside-container-DNfggvIW.js} +1 -1
- package/dist/{code-block-37QAKDTI-eUgXqGNG.js → code-block-37QAKDTI-u5kgjqmr.js} +2 -2
- package/dist/{compiler-runtime-DHFVbq0b.js → compiler-runtime-B_OLMU9S.js} +1 -1
- package/dist/{copy-B59Bw3-w.js → copy-DRaXIb_a.js} +3 -3
- package/dist/{dagre-6UL2VRFP-DKIPL74O.js → dagre-6UL2VRFP-C2C2XxsB.js} +6 -6
- package/dist/{data-grid-overlay-editor-COyFwFmE.js → data-grid-overlay-editor-BXqtz1ia.js} +4 -4
- package/dist/{diagram-PSM6KHXK-CVTrAZaP.js → diagram-PSM6KHXK-DHBY-94p.js} +5 -5
- package/dist/{diagram-QEK2KX5R-BqHBzu3x.js → diagram-QEK2KX5R-CgMshOwn.js} +3 -3
- package/dist/{diagram-S2PKOQOG-CJD6owcg.js → diagram-S2PKOQOG-F1KPva3Y.js} +3 -3
- package/dist/{dist-Co5PD8Fb.js → dist-BBYTEAvO.js} +1 -1
- package/dist/{erDiagram-Q2GNP2WA-CqOceSf9.js → erDiagram-Q2GNP2WA-18gGng8V.js} +9 -9
- package/dist/{error-banner-C7KLpECd.js → error-banner-D2zjeN_a.js} +5 -5
- package/dist/{esm-D4WO8J3G.js → esm-CgRNPmz8.js} +6 -6
- package/dist/{flowDiagram-NV44I4VS-K7-DUifo.js → flowDiagram-NV44I4VS-iHFiHYe0.js} +9 -9
- package/dist/{ganttDiagram-JELNMOA3-BwUFY9Nu.js → ganttDiagram-JELNMOA3-D7GixxiF.js} +2 -2
- package/dist/{gitGraphDiagram-NY62KEGX-CjGRtLb1.js → gitGraphDiagram-NY62KEGX-CJFHytRK.js} +2 -2
- package/dist/{glide-data-editor-C3T7HsLi.js → glide-data-editor-BYwb17Bf.js} +13 -13
- package/dist/{infoDiagram-WHAUD3N6-DNhmDn-6.js → infoDiagram-WHAUD3N6-B5Lkh3A9.js} +2 -2
- package/dist/{journeyDiagram-XKPGCS4Q-BOdK47P8.js → journeyDiagram-XKPGCS4Q-CV_9R9iP.js} +2 -2
- package/dist/{kanban-definition-3W4ZIXB7-A0JC9d0g.js → kanban-definition-3W4ZIXB7-Dp21D5Ym.js} +6 -6
- package/dist/{katex-DJyOeQ91.js → katex-CX2BKujk.js} +1 -1
- package/dist/{katex-Dm9nZf6A.js → katex-Db0k5oV_.js} +1 -1
- package/dist/{label-C4PtQcza.js → label-CxU5JNBW.js} +6 -6
- package/dist/main.js +270 -206
- package/dist/mermaid-4DMBBIKO-BhDCqnO1.js +6 -0
- package/dist/{mermaid-Bqp2Xw99.js → mermaid-B__BZSXU.js} +39 -39
- package/dist/{mhchem-BqdXeZVX.js → mhchem-w1tkUnWr.js} +1 -1
- package/dist/{mindmap-definition-VGOIOE7T-CS6nKN_L.js → mindmap-definition-VGOIOE7T-B_5mfdYp.js} +8 -8
- package/dist/{number-overlay-editor-Bz_bDJQb.js → number-overlay-editor-D-4WQAGX.js} +2 -2
- package/dist/{pieDiagram-ADFJNKIX-DSa60Grk.js → pieDiagram-ADFJNKIX-B-DGEopK.js} +3 -3
- package/dist/{quadrantDiagram-AYHSOK5B-CFnMbP2J.js → quadrantDiagram-AYHSOK5B-M_yRSIZn.js} +1 -1
- package/dist/{react-DdA8EBol.js → react-Bs6Z0kvn.js} +1 -1
- package/dist/{react-dom-DJW8xUDg.js → react-dom-CqtLRVZP.js} +2 -2
- package/dist/{react-plotly-jVjTu07w.js → react-plotly-BuRa9xtI.js} +1 -1
- package/dist/{react-vega-DgHpnZ04.js → react-vega-3WcLHYC7.js} +2 -2
- package/dist/{react-vega-CjiPWyw0.js → react-vega-DLFvGrpJ.js} +1 -1
- package/dist/{requirementDiagram-UZGBJVZJ-ytLQrFTk.js → requirementDiagram-UZGBJVZJ-9Wt82hOZ.js} +8 -8
- package/dist/{sankeyDiagram-TZEHDZUN-KQqXDoky.js → sankeyDiagram-TZEHDZUN-x_aTXZeN.js} +1 -1
- package/dist/{sequenceDiagram-WL72ISMW-ByLI04T5.js → sequenceDiagram-WL72ISMW-CXXmJqiQ.js} +3 -3
- package/dist/{slides-component-BVjvNo92.js → slides-component-Dp-y50K9.js} +4 -4
- package/dist/{spec-Dmb1KfK3.js → spec-HoYHAQo2.js} +6 -6
- package/dist/{stateDiagram-FKZM4ZOC-Dfz8vBbP.js → stateDiagram-FKZM4ZOC-CiSKS_Mx.js} +9 -9
- package/dist/{stateDiagram-v2-4FDKWEC3-DRYoLdT5.js → stateDiagram-v2-4FDKWEC3-A43Itnjp.js} +9 -9
- package/dist/style.css +1 -1
- package/dist/{timeline-definition-IT6M3QCI-CO48XU1B.js → timeline-definition-IT6M3QCI-DR26eWb4.js} +1 -1
- package/dist/{types-CzEZ3EWT.js → types-Bb-6p8hv.js} +8 -8
- package/dist/{useAsyncData-BjNwqCfS.js → useAsyncData-Dyq3DyOF.js} +3 -3
- package/dist/{useDeepCompareMemoize-CfoxVor3.js → useDeepCompareMemoize-CMGprt3H.js} +5 -5
- package/dist/{useIframeCapabilities-BBO_R0ww.js → useIframeCapabilities-DurI5SJh.js} +2 -2
- package/dist/{useTheme-BYG2SH8J.js → useTheme-SlKl8MlS.js} +5 -6
- package/dist/{vega-component-rDX7xwxH.js → vega-component-DU3aSp4m.js} +10 -10
- package/dist/{xychartDiagram-PRI3JC2R-CUIfjNVD.js → xychartDiagram-PRI3JC2R-BcVxCRox.js} +4 -4
- package/dist/{zod-DITCj31F.js → zod-bjADtMKr.js} +3 -3
- package/package.json +18 -18
- package/src/components/app-config/ai-config.tsx +11 -2
- package/src/components/app-config/user-config-form.tsx +0 -54
- package/src/components/chat/acp/__tests__/state.test.ts +69 -0
- package/src/components/chat/acp/state.ts +6 -6
- package/src/components/chat/chat-panel.tsx +47 -30
- package/src/components/data-table/__tests__/data-table.test.tsx +94 -2
- package/src/components/editor/actions/useCellActionButton.tsx +14 -1
- package/src/components/editor/cell/CreateCellButton.tsx +2 -1
- package/src/components/editor/cell/code/cell-editor.tsx +12 -0
- package/src/components/editor/database/__tests__/__snapshots__/as-code.test.ts.snap +15 -0
- package/src/components/editor/database/__tests__/as-code.test.ts +8 -0
- package/src/components/editor/database/as-code.ts +3 -0
- package/src/components/editor/database/schemas.ts +9 -0
- package/src/components/editor/renderers/cell-array.tsx +2 -1
- package/src/components/editor/renderers/vertical-layout/vertical-layout.tsx +12 -0
- package/src/components/pages/gallery-page.tsx +37 -6
- package/src/core/MarimoApp.tsx +12 -8
- package/src/core/ai/context/providers/file.ts +1 -1
- package/src/core/cells/__tests__/cells.test.ts +120 -0
- package/src/core/cells/__tests__/session.test.ts +37 -1
- package/src/core/cells/cells.ts +14 -0
- package/src/core/cells/session.ts +20 -8
- package/src/core/codemirror/language/languages/markdown.ts +7 -0
- package/src/core/config/feature-flag.tsx +0 -4
- package/src/core/dom/uiregistry.ts +4 -1
- package/src/core/run-app.tsx +11 -4
- package/src/core/static/__tests__/files.test.ts +195 -1
- package/src/core/static/files.ts +39 -9
- package/src/plugins/core/registerReactComponent.tsx +9 -1
- package/src/plugins/impl/__tests__/DataTablePlugin.test.tsx +164 -0
- package/src/plugins/impl/anywidget/AnyWidgetPlugin.tsx +7 -1
- package/src/utils/__tests__/blob.test.ts +3 -3
- package/src/utils/__tests__/id-tree.test.ts +22 -7
- package/src/utils/__tests__/mime-types.test.ts +8 -10
- package/src/utils/__tests__/url-parser.test.ts +22 -0
- package/src/utils/blob.ts +14 -27
- package/src/utils/id-tree.tsx +11 -19
- package/src/utils/mime-types.ts +5 -5
- package/src/utils/url-parser.ts +1 -1
- package/dist/assets/__vite-browser-external-DRa9CT_O.js +0 -1
- package/dist/mermaid-4DMBBIKO-o3xNphpD.js +0 -6
package/dist/{timeline-definition-IT6M3QCI-CO48XU1B.js → timeline-definition-IT6M3QCI-DR26eWb4.js}
RENAMED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import "./purify.es-Brw-U87Q.js";
|
|
2
2
|
import { t as arc_default } from "./arc-CEWBr4jc.js";
|
|
3
3
|
import { i as log, n as __export, r as __name, t as select_default } from "./src-szye8OCw.js";
|
|
4
|
-
import { G as setupGraphViewbox, Q as is_dark_default, X as darken_default, Z as lighten_default, a as clear, b as getConfig2, o as commonDb_exports } from "./chunk-ABZYJK2D-
|
|
4
|
+
import { G as setupGraphViewbox, Q as is_dark_default, X as darken_default, Z as lighten_default, a as clear, b as getConfig2, o as commonDb_exports } from "./chunk-ABZYJK2D-BXTC53mt.js";
|
|
5
5
|
var parser = (function() {
|
|
6
6
|
var t = /* @__PURE__ */ __name(function(t2, S2, C2, w) {
|
|
7
7
|
for (C2 || (C2 = {}), w = t2.length; w--; C2[t2[w]] = S2) ;
|
|
@@ -3,17 +3,17 @@ var __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { en
|
|
|
3
3
|
var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "symbol" ? key + "" : key, value);
|
|
4
4
|
var _a;
|
|
5
5
|
import { s as __toESM } from "./chunk-BNovOVIE.js";
|
|
6
|
-
import { t as require_react } from "./react-
|
|
7
|
-
import { t as require_compiler_runtime } from "./compiler-runtime-
|
|
8
|
-
import { D as dispatchDiscreteCustomEvent, E as Primitive, M as composeEventHandlers, N as createLucideIcon, O as createSlot, S as useId, T as useCallbackRef, _ as Arrow, b as createPopperScope, c as withSmartCollisionBoundary, g as Anchor, h as Portal, i as useFocusGuards, j as createContextScope, m as Presence, n as hideOthers, o as MAX_HEIGHT_OFFSET, p as useControllableState, r as FocusScope, s as withFullScreenAsRoot, t as Combination_default, u as StyleNamespace, v as Content, w as DismissableLayer, y as Root2$1 } from "./Combination-
|
|
9
|
-
import { t as Check } from "./check-
|
|
10
|
-
import { A as $a916eb452884faea$export$b7a616150fdb9f44, C as useDirection, F as $b5e257d569688ac6$export$619500959fc48b26, I as X, L as ChevronUp, M as $18f2051aff69b9bf$export$43bb16f9c6d9e3f7, R as ChevronDown, _ as menuItemVariants, b as menuSubTriggerVariants, g as menuControlVariants, h as menuControlCheckVariants, j as $488c6ddbf4ef74c2$export$cc77c4ff7e8673c5, k as upperFirst_default, m as menuContentCommon, v as menuLabelVariants, w as createCollection, y as menuSeparatorVariants } from "./label-
|
|
6
|
+
import { t as require_react } from "./react-Bs6Z0kvn.js";
|
|
7
|
+
import { t as require_compiler_runtime } from "./compiler-runtime-B_OLMU9S.js";
|
|
8
|
+
import { D as dispatchDiscreteCustomEvent, E as Primitive, M as composeEventHandlers, N as createLucideIcon, O as createSlot, S as useId, T as useCallbackRef, _ as Arrow, b as createPopperScope, c as withSmartCollisionBoundary, g as Anchor, h as Portal, i as useFocusGuards, j as createContextScope, m as Presence, n as hideOthers, o as MAX_HEIGHT_OFFSET, p as useControllableState, r as FocusScope, s as withFullScreenAsRoot, t as Combination_default, u as StyleNamespace, v as Content, w as DismissableLayer, y as Root2$1 } from "./Combination-BTMrlhzT.js";
|
|
9
|
+
import { t as Check } from "./check-DkNR52Mm.js";
|
|
10
|
+
import { A as $a916eb452884faea$export$b7a616150fdb9f44, C as useDirection, F as $b5e257d569688ac6$export$619500959fc48b26, I as X, L as ChevronUp, M as $18f2051aff69b9bf$export$43bb16f9c6d9e3f7, R as ChevronDown, _ as menuItemVariants, b as menuSubTriggerVariants, g as menuControlVariants, h as menuControlCheckVariants, j as $488c6ddbf4ef74c2$export$cc77c4ff7e8673c5, k as upperFirst_default, m as menuContentCommon, v as menuLabelVariants, w as createCollection, y as menuSeparatorVariants } from "./label-CxU5JNBW.js";
|
|
11
11
|
import { n as clsx_default } from "./clsx-D2KVTYnW.js";
|
|
12
|
-
import { c as useComposedRefs, l as Events, s as composeRefs, t as Button, u as cn } from "./button-
|
|
12
|
+
import { c as useComposedRefs, l as Events, s as composeRefs, t as Button, u as cn } from "./button-Cy0ElmIm.js";
|
|
13
13
|
import { s as Logger } from "./hotkeys-B5WnGZXF.js";
|
|
14
14
|
import { t as require_jsx_runtime } from "./jsx-runtime-CTBg5pdT.js";
|
|
15
|
-
import { t as require_react_dom } from "./react-dom-
|
|
16
|
-
import { h as useEvent_default } from "./useTheme-
|
|
15
|
+
import { t as require_react_dom } from "./react-dom-CqtLRVZP.js";
|
|
16
|
+
import { h as useEvent_default } from "./useTheme-SlKl8MlS.js";
|
|
17
17
|
import { t as toString_default } from "./toString-C4TLO6FA.js";
|
|
18
18
|
import { i as debounce_default, n as Constants } from "./constants-DrOu5vvd.js";
|
|
19
19
|
import { t as memoizeLastValue } from "./once-BqS42WgZ.js";
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { s as __toESM } from "./chunk-BNovOVIE.js";
|
|
2
|
-
import { t as require_react } from "./react-
|
|
3
|
-
import { t as require_compiler_runtime } from "./compiler-runtime-
|
|
4
|
-
import { h as useEvent_default } from "./useTheme-
|
|
2
|
+
import { t as require_react } from "./react-Bs6Z0kvn.js";
|
|
3
|
+
import { t as require_compiler_runtime } from "./compiler-runtime-B_OLMU9S.js";
|
|
4
|
+
import { h as useEvent_default } from "./useTheme-SlKl8MlS.js";
|
|
5
5
|
import { t as invariant } from "./invariant-D9QLJ4SZ.js";
|
|
6
6
|
var import_compiler_runtime = require_compiler_runtime(), import_react = /* @__PURE__ */ __toESM(require_react(), 1), Result = {
|
|
7
7
|
error(e, s) {
|
|
@@ -2,13 +2,13 @@ var __defProp = Object.defineProperty;
|
|
|
2
2
|
var __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
3
3
|
var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "symbol" ? key + "" : key, value);
|
|
4
4
|
import { s as __toESM, t as __commonJSMin } from "./chunk-BNovOVIE.js";
|
|
5
|
-
import { t as require_react } from "./react-
|
|
6
|
-
import { t as require_compiler_runtime } from "./compiler-runtime-
|
|
7
|
-
import { N as createLucideIcon } from "./Combination-
|
|
8
|
-
import { a as cva, u as cn } from "./button-
|
|
5
|
+
import { t as require_react } from "./react-Bs6Z0kvn.js";
|
|
6
|
+
import { t as require_compiler_runtime } from "./compiler-runtime-B_OLMU9S.js";
|
|
7
|
+
import { N as createLucideIcon } from "./Combination-BTMrlhzT.js";
|
|
8
|
+
import { a as cva, u as cn } from "./button-Cy0ElmIm.js";
|
|
9
9
|
import { s as Logger } from "./hotkeys-B5WnGZXF.js";
|
|
10
10
|
import { t as require_jsx_runtime } from "./jsx-runtime-CTBg5pdT.js";
|
|
11
|
-
import { f as waitFor, p as isIslands, u as store, x as atom } from "./useTheme-
|
|
11
|
+
import { f as waitFor, p as isIslands, u as store, x as atom } from "./useTheme-SlKl8MlS.js";
|
|
12
12
|
import { r as KnownQueryParams } from "./constants-DrOu5vvd.js";
|
|
13
13
|
import { i as tableFromIPC } from "./loader-B0KEFFi-.js";
|
|
14
14
|
var CircleQuestionMark = createLucideIcon("circle-question-mark", [
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { s as __toESM } from "./chunk-BNovOVIE.js";
|
|
2
|
-
import { t as require_react } from "./react-
|
|
3
|
-
import { t as require_compiler_runtime } from "./compiler-runtime-
|
|
2
|
+
import { t as require_react } from "./react-Bs6Z0kvn.js";
|
|
3
|
+
import { t as require_compiler_runtime } from "./compiler-runtime-B_OLMU9S.js";
|
|
4
4
|
import { s as Logger } from "./hotkeys-B5WnGZXF.js";
|
|
5
5
|
import { n as once } from "./once-BqS42WgZ.js";
|
|
6
6
|
function testStorage(e) {
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import { s as __toESM } from "./chunk-BNovOVIE.js";
|
|
2
|
-
import { t as require_react } from "./react-
|
|
3
|
-
import { t as require_compiler_runtime } from "./compiler-runtime-
|
|
2
|
+
import { t as require_react } from "./react-Bs6Z0kvn.js";
|
|
3
|
+
import { t as require_compiler_runtime } from "./compiler-runtime-B_OLMU9S.js";
|
|
4
4
|
import { a as resolvePlatform, n as OverridingHotkeyProvider, s as Logger } from "./hotkeys-B5WnGZXF.js";
|
|
5
5
|
import { t as _baseIsEqual_default } from "./_baseIsEqual-CBSjxu-D.js";
|
|
6
6
|
import { t as merge_default } from "./merge-Dl1bfxsj.js";
|
|
7
|
-
import { A as looseObject, B as union, I as record, N as number, P as object, R as string, T as boolean, b as _enum, w as array } from "./zod-
|
|
7
|
+
import { A as looseObject, B as union, I as record, N as number, P as object, R as string, T as boolean, b as _enum, w as array } from "./zod-bjADtMKr.js";
|
|
8
8
|
function hasInitialValue(e) {
|
|
9
9
|
return "init" in e;
|
|
10
10
|
}
|
|
@@ -57,7 +57,6 @@ function getMountedOrPendingDependents(e, k, A) {
|
|
|
57
57
|
}
|
|
58
58
|
var BUILDING_BLOCK_atomRead = (e, k, ...A) => k.read(...A), BUILDING_BLOCK_atomWrite = (e, k, ...A) => k.write(...A), BUILDING_BLOCK_atomOnInit = (e, k) => {
|
|
59
59
|
if (k.INTERNAL_onInit) return k.INTERNAL_onInit(e);
|
|
60
|
-
if (k.unstable_onInit) return console.warn("[DEPRECATED] atom.unstable_onInit is renamed to atom.INTERNAL_onInit."), k.unstable_onInit(e);
|
|
61
60
|
}, BUILDING_BLOCK_atomOnMount = (e, k, A) => {
|
|
62
61
|
var _a;
|
|
63
62
|
return (_a = k.onMount) == null ? void 0 : _a.call(k, A);
|
|
@@ -334,9 +333,9 @@ function defaultRead(e) {
|
|
|
334
333
|
function defaultWrite(e, k, A) {
|
|
335
334
|
return k(this, typeof A == "function" ? A(e(this)) : A);
|
|
336
335
|
}
|
|
337
|
-
var
|
|
336
|
+
var overriddenCreateStore;
|
|
338
337
|
function createStore() {
|
|
339
|
-
return
|
|
338
|
+
return overriddenCreateStore ? overriddenCreateStore() : buildStore();
|
|
340
339
|
}
|
|
341
340
|
var defaultStore;
|
|
342
341
|
function getDefaultStore() {
|
|
@@ -1,20 +1,20 @@
|
|
|
1
1
|
import { s as __toESM } from "./chunk-BNovOVIE.js";
|
|
2
|
-
import { t as require_react } from "./react-
|
|
3
|
-
import { t as require_compiler_runtime } from "./compiler-runtime-
|
|
4
|
-
import "./Combination-
|
|
5
|
-
import { S as CircleQuestionMark, a as AlertTitle, m as asRemoteURL, n as arrow, o as isValid, r as Alert, t as useDeepCompareMemoize } from "./useDeepCompareMemoize-
|
|
6
|
-
import { l as Events } from "./button-
|
|
2
|
+
import { t as require_react } from "./react-Bs6Z0kvn.js";
|
|
3
|
+
import { t as require_compiler_runtime } from "./compiler-runtime-B_OLMU9S.js";
|
|
4
|
+
import "./Combination-BTMrlhzT.js";
|
|
5
|
+
import { S as CircleQuestionMark, a as AlertTitle, m as asRemoteURL, n as arrow, o as isValid, r as Alert, t as useDeepCompareMemoize } from "./useDeepCompareMemoize-CMGprt3H.js";
|
|
6
|
+
import { l as Events } from "./button-Cy0ElmIm.js";
|
|
7
7
|
import { o as Objects, s as Logger } from "./hotkeys-B5WnGZXF.js";
|
|
8
8
|
import { t as require_jsx_runtime } from "./jsx-runtime-CTBg5pdT.js";
|
|
9
|
-
import "./react-dom-
|
|
10
|
-
import { l as Tooltip, n as ErrorBanner } from "./error-banner-
|
|
11
|
-
import { h as useEvent_default, n as useTheme } from "./useTheme-
|
|
9
|
+
import "./react-dom-CqtLRVZP.js";
|
|
10
|
+
import { l as Tooltip, n as ErrorBanner } from "./error-banner-D2zjeN_a.js";
|
|
11
|
+
import { h as useEvent_default, n as useTheme } from "./useTheme-SlKl8MlS.js";
|
|
12
12
|
import { t as _baseUniq_default } from "./_baseUniq-4lqa8rDi.js";
|
|
13
13
|
import { i as debounce_default } from "./constants-DrOu5vvd.js";
|
|
14
14
|
import { a as tooltipHandler, n as vegaLoadData } from "./loader-B0KEFFi-.js";
|
|
15
15
|
import { n as formats } from "./vega-loader.browser-BJ1uJidF.js";
|
|
16
|
-
import { t as useAsyncData } from "./useAsyncData-
|
|
17
|
-
import { t as j } from "./react-vega-
|
|
16
|
+
import { t as useAsyncData } from "./useAsyncData-Dyq3DyOF.js";
|
|
17
|
+
import { t as j } from "./react-vega-DLFvGrpJ.js";
|
|
18
18
|
import "./defaultLocale-qS7DaAmi.js";
|
|
19
19
|
import "./defaultLocale-Bxoo2-30.js";
|
|
20
20
|
function uniq(e) {
|
|
@@ -5,13 +5,13 @@ import { n as ordinal } from "./ordinal-IlASfRja.js";
|
|
|
5
5
|
import { t as range } from "./range-BYuZFTbA.js";
|
|
6
6
|
import "./defaultLocale-qS7DaAmi.js";
|
|
7
7
|
import { t as line_default } from "./line-LK_5q2B9.js";
|
|
8
|
-
import { i as cleanAndMerge } from "./chunk-S3R3BYOJ-
|
|
8
|
+
import { i as cleanAndMerge } from "./chunk-S3R3BYOJ-CBkH6JZZ.js";
|
|
9
9
|
import { n as initRange } from "./init-BfRhston.js";
|
|
10
10
|
import { i as log, r as __name } from "./src-szye8OCw.js";
|
|
11
|
-
import { B as setAccTitle, C as getDiagramTitle, I as sanitizeText, T as getThemeVariables3, U as setDiagramTitle, _ as getAccDescription, a as clear, c as configureSvgSize, d as defaultConfig_default, v as getAccTitle, y as getConfig, z as setAccDescription } from "./chunk-ABZYJK2D-
|
|
12
|
-
import { t as selectSvgElement } from "./chunk-EXTU4WIE-
|
|
11
|
+
import { B as setAccTitle, C as getDiagramTitle, I as sanitizeText, T as getThemeVariables3, U as setDiagramTitle, _ as getAccDescription, a as clear, c as configureSvgSize, d as defaultConfig_default, v as getAccTitle, y as getConfig, z as setAccDescription } from "./chunk-ABZYJK2D-BXTC53mt.js";
|
|
12
|
+
import { t as selectSvgElement } from "./chunk-EXTU4WIE-DyoOs5QX.js";
|
|
13
13
|
import "./dist-BYznkC5E.js";
|
|
14
|
-
import { t as computeDimensionOfText } from "./chunk-JA3XYJ7Z-
|
|
14
|
+
import { t as computeDimensionOfText } from "./chunk-JA3XYJ7Z-BGnAIbOP.js";
|
|
15
15
|
function band() {
|
|
16
16
|
var e = ordinal().unknown(void 0), w = e.domain, T = e.range, D = 0, O = 1, k, A, j = false, M = 0, N = 0, P = 0.5;
|
|
17
17
|
delete e.unknown;
|
|
@@ -1187,7 +1187,7 @@ var Doc = class {
|
|
|
1187
1187
|
const version = {
|
|
1188
1188
|
major: 4,
|
|
1189
1189
|
minor: 3,
|
|
1190
|
-
patch:
|
|
1190
|
+
patch: 6
|
|
1191
1191
|
}, $ZodType = /* @__PURE__ */ $constructor("$ZodType", (f, V) => {
|
|
1192
1192
|
var _a2;
|
|
1193
1193
|
var H;
|
|
@@ -2038,7 +2038,7 @@ const $ZodRecord = /* @__PURE__ */ $constructor("$ZodRecord", (f, V) => {
|
|
|
2038
2038
|
issues: []
|
|
2039
2039
|
}, U);
|
|
2040
2040
|
if (J instanceof Promise) throw Error("Async schemas not supported in object keys currently");
|
|
2041
|
-
if (typeof K2 == "string" && number$2.test(K2) && J.issues.length
|
|
2041
|
+
if (typeof K2 == "string" && number$2.test(K2) && J.issues.length) {
|
|
2042
2042
|
let f2 = V.keyType._zod.run({
|
|
2043
2043
|
value: Number(K2),
|
|
2044
2044
|
issues: []
|
|
@@ -8447,7 +8447,7 @@ function finalize(f, V) {
|
|
|
8447
8447
|
U(K);
|
|
8448
8448
|
let H3 = f.seen.get(K), q2 = H3.schema;
|
|
8449
8449
|
if (q2.$ref && (f.target === "draft-07" || f.target === "draft-04" || f.target === "openapi-3.0") ? (W2.allOf = W2.allOf ?? [], W2.allOf.push(q2)) : Object.assign(W2, q2), Object.assign(W2, G2), V2._zod.parent === K) for (let f2 in W2) f2 === "$ref" || f2 === "allOf" || f2 in G2 || delete W2[f2];
|
|
8450
|
-
if (q2.$ref) for (let f2 in W2) f2 === "$ref" || f2 === "allOf" || f2 in H3.def && JSON.stringify(W2[f2]) === JSON.stringify(H3.def[f2]) && delete W2[f2];
|
|
8450
|
+
if (q2.$ref && H3.def) for (let f2 in W2) f2 === "$ref" || f2 === "allOf" || f2 in H3.def && JSON.stringify(W2[f2]) === JSON.stringify(H3.def[f2]) && delete W2[f2];
|
|
8451
8451
|
}
|
|
8452
8452
|
let q = V2._zod.parent;
|
|
8453
8453
|
if (q && q !== K) {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@marimo-team/islands",
|
|
3
|
-
"version": "0.19.8-
|
|
3
|
+
"version": "0.19.8-dev40",
|
|
4
4
|
"main": "dist/main.js",
|
|
5
5
|
"types": "dist/index.d.ts",
|
|
6
6
|
"type": "module",
|
|
@@ -21,7 +21,7 @@
|
|
|
21
21
|
"./unstable_internal/*": "./src/*"
|
|
22
22
|
},
|
|
23
23
|
"dependencies": {
|
|
24
|
-
"@ai-sdk/react": "^2.0.
|
|
24
|
+
"@ai-sdk/react": "^2.0.125",
|
|
25
25
|
"@anywidget/types": "^0.2.0",
|
|
26
26
|
"@codemirror/autocomplete": "^6.20.0",
|
|
27
27
|
"@codemirror/commands": "^6.10.1",
|
|
@@ -114,7 +114,7 @@
|
|
|
114
114
|
"@xterm/addon-web-links": "^0.12.0",
|
|
115
115
|
"@xterm/xterm": "^5.5.0",
|
|
116
116
|
"@zed-industries/agent-client-protocol": "^0.4.5",
|
|
117
|
-
"ai": "^5.0.
|
|
117
|
+
"ai": "^5.0.123",
|
|
118
118
|
"ansi_up": "^6.0.6",
|
|
119
119
|
"class-variance-authority": "^0.7.1",
|
|
120
120
|
"clsx": "^2.1.1",
|
|
@@ -127,18 +127,18 @@
|
|
|
127
127
|
"dompurify": "^3.3.1",
|
|
128
128
|
"eslint-plugin-header": "^3.1.1",
|
|
129
129
|
"htm": "^3.1.1",
|
|
130
|
-
"html-react-parser": "^5.2.
|
|
130
|
+
"html-react-parser": "^5.2.14",
|
|
131
131
|
"html-to-image": "1.11.13",
|
|
132
132
|
"humanize-duration": "^3.33.2",
|
|
133
133
|
"iconify-icon": "^2.3.0",
|
|
134
|
-
"jotai": "^2.
|
|
134
|
+
"jotai": "^2.17.0",
|
|
135
135
|
"jotai-scope": "^0.10.0",
|
|
136
136
|
"js-cookie": "^3.0.5",
|
|
137
|
-
"katex": "^0.16.
|
|
137
|
+
"katex": "^0.16.28",
|
|
138
138
|
"lodash-es": "^4.17.22",
|
|
139
139
|
"loro-codemirror": "^0.3.3",
|
|
140
|
-
"loro-crdt": "^1.10.
|
|
141
|
-
"lucide-react": "^0.
|
|
140
|
+
"loro-crdt": "^1.10.5",
|
|
141
|
+
"lucide-react": "^0.563.0",
|
|
142
142
|
"lz-string": "^1.5.0",
|
|
143
143
|
"marked": "^15.0.12",
|
|
144
144
|
"mermaid": "^11.12.2",
|
|
@@ -152,7 +152,7 @@
|
|
|
152
152
|
"react-codemirror-merge": "4.25.4",
|
|
153
153
|
"react-dnd": "^16.0.1",
|
|
154
154
|
"react-dnd-html5-backend": "^16.0.1",
|
|
155
|
-
"react-dropzone": "^14.
|
|
155
|
+
"react-dropzone": "^14.4.0",
|
|
156
156
|
"react-error-boundary": "^5.0.0",
|
|
157
157
|
"react-grid-layout": "^1.5.3",
|
|
158
158
|
"react-hook-form": "7.54.2",
|
|
@@ -165,7 +165,7 @@
|
|
|
165
165
|
"reactflow": "^11.11.4",
|
|
166
166
|
"remark-gfm": "^4.0.1",
|
|
167
167
|
"rpc-anywhere": "^1.7.0",
|
|
168
|
-
"sql-formatter": "^15.
|
|
168
|
+
"sql-formatter": "^15.7.0",
|
|
169
169
|
"streamdown": "^2.1.0",
|
|
170
170
|
"string-dedent": "^3.0.2",
|
|
171
171
|
"swiper": "^11.2.10",
|
|
@@ -183,7 +183,7 @@
|
|
|
183
183
|
"vscode-jsonrpc": "^8.2.1",
|
|
184
184
|
"vscode-languageserver-protocol": "^3.17.5",
|
|
185
185
|
"web-vitals": "^4.2.4",
|
|
186
|
-
"zod": "^4.3.
|
|
186
|
+
"zod": "^4.3.6"
|
|
187
187
|
},
|
|
188
188
|
"scripts": {
|
|
189
189
|
"preinstall": "npx only-allow pnpm",
|
|
@@ -211,9 +211,9 @@
|
|
|
211
211
|
"react-dom": "^17 || ^18 || ^19"
|
|
212
212
|
},
|
|
213
213
|
"devDependencies": {
|
|
214
|
-
"@babel/plugin-proposal-decorators": "^7.28.
|
|
214
|
+
"@babel/plugin-proposal-decorators": "^7.28.6",
|
|
215
215
|
"@babel/preset-typescript": "^7.25.9",
|
|
216
|
-
"@biomejs/biome": "2.3.
|
|
216
|
+
"@biomejs/biome": "2.3.13",
|
|
217
217
|
"@codecov/vite-plugin": "^1.9.1",
|
|
218
218
|
"@csstools/postcss-light-dark-function": "^2.0.11",
|
|
219
219
|
"@playwright/test": "^1.57.0",
|
|
@@ -224,10 +224,10 @@
|
|
|
224
224
|
"@testing-library/jest-dom": "^6.9.1",
|
|
225
225
|
"@testing-library/react": "^16.3.1",
|
|
226
226
|
"@types/dompurify": "^3.2.0",
|
|
227
|
-
"@types/katex": "^0.16.
|
|
227
|
+
"@types/katex": "^0.16.8",
|
|
228
228
|
"@types/lodash-es": "^4.17.12",
|
|
229
|
-
"@types/node": "^24.10.
|
|
230
|
-
"@types/react": "^19.2.
|
|
229
|
+
"@types/node": "^24.10.9",
|
|
230
|
+
"@types/react": "^19.2.10",
|
|
231
231
|
"@types/react-dom": "^19.2.3",
|
|
232
232
|
"@types/react-plotly.js": "^2.6.4",
|
|
233
233
|
"@types/timestring": "^6.0.5",
|
|
@@ -251,9 +251,9 @@
|
|
|
251
251
|
"npm-run-all2": "^6.2.6",
|
|
252
252
|
"postcss": "^8.5.6",
|
|
253
253
|
"postcss-plugin-namespace": "^0.0.3",
|
|
254
|
-
"react": "^19.2.
|
|
254
|
+
"react": "^19.2.4",
|
|
255
255
|
"react-compiler-runtime": "19.1.0-rc.3",
|
|
256
|
-
"react-dom": "^19.2.
|
|
256
|
+
"react-dom": "^19.2.4",
|
|
257
257
|
"storybook": "^10.2.0",
|
|
258
258
|
"stylelint": "^16.26.1",
|
|
259
259
|
"stylelint-config-standard": "^36.0.1",
|
|
@@ -609,9 +609,13 @@ export const CustomProvidersConfig: React.FC<AiConfigProps> = ({
|
|
|
609
609
|
const isDuplicate =
|
|
610
610
|
KNOWN_PROVIDERS.includes(normalizedName as KnownProviderId) ||
|
|
611
611
|
(customProviders && Object.keys(customProviders).includes(normalizedName));
|
|
612
|
+
const hasInvalidChars = normalizedName.includes(".");
|
|
612
613
|
|
|
613
614
|
const hasValidValues =
|
|
614
|
-
normalizedName.trim() &&
|
|
615
|
+
normalizedName.trim() &&
|
|
616
|
+
newProviderBaseUrl.trim() &&
|
|
617
|
+
!isDuplicate &&
|
|
618
|
+
!hasInvalidChars;
|
|
615
619
|
|
|
616
620
|
const resetForm = () => {
|
|
617
621
|
setNewProviderName("");
|
|
@@ -669,7 +673,12 @@ export const CustomProvidersConfig: React.FC<AiConfigProps> = ({
|
|
|
669
673
|
A provider with this name already exists.
|
|
670
674
|
</p>
|
|
671
675
|
)}
|
|
672
|
-
{
|
|
676
|
+
{hasInvalidChars && (
|
|
677
|
+
<p className="text-xs text-destructive">
|
|
678
|
+
Provider names cannot contain '.' characters.
|
|
679
|
+
</p>
|
|
680
|
+
)}
|
|
681
|
+
{newProviderName && !hasInvalidChars && (
|
|
673
682
|
<p className="text-xs text-muted-secondary">
|
|
674
683
|
Use models with prefix:{" "}
|
|
675
684
|
<Kbd className="inline text-xs">{normalizedName}/</Kbd>
|
|
@@ -1296,34 +1296,6 @@ export const UserConfigForm: React.FC = () => {
|
|
|
1296
1296
|
</div>
|
|
1297
1297
|
)}
|
|
1298
1298
|
/>
|
|
1299
|
-
<FormField
|
|
1300
|
-
control={form.control}
|
|
1301
|
-
name="experimental.performant_table_charts"
|
|
1302
|
-
render={({ field }) => (
|
|
1303
|
-
<div className="flex flex-col gap-y-1">
|
|
1304
|
-
<FormItem className={formItemClasses}>
|
|
1305
|
-
<FormLabel className="font-normal">
|
|
1306
|
-
Performant Table Charts
|
|
1307
|
-
</FormLabel>
|
|
1308
|
-
<FormControl>
|
|
1309
|
-
<Checkbox
|
|
1310
|
-
data-testid="performant-table-charts-checkbox"
|
|
1311
|
-
checked={field.value === true}
|
|
1312
|
-
onCheckedChange={field.onChange}
|
|
1313
|
-
/>
|
|
1314
|
-
</FormControl>
|
|
1315
|
-
</FormItem>
|
|
1316
|
-
<IsOverridden
|
|
1317
|
-
userConfig={config}
|
|
1318
|
-
name="experimental.performant_table_charts"
|
|
1319
|
-
/>
|
|
1320
|
-
<FormDescription>
|
|
1321
|
-
Enable experimental table charts which are computed on the
|
|
1322
|
-
backend.
|
|
1323
|
-
</FormDescription>
|
|
1324
|
-
</div>
|
|
1325
|
-
)}
|
|
1326
|
-
/>
|
|
1327
1299
|
<FormField
|
|
1328
1300
|
control={form.control}
|
|
1329
1301
|
name="experimental.external_agents"
|
|
@@ -1356,32 +1328,6 @@ export const UserConfigForm: React.FC = () => {
|
|
|
1356
1328
|
</div>
|
|
1357
1329
|
)}
|
|
1358
1330
|
/>
|
|
1359
|
-
<FormField
|
|
1360
|
-
control={form.control}
|
|
1361
|
-
name="experimental.chat_modes"
|
|
1362
|
-
render={({ field }) => (
|
|
1363
|
-
<div className="flex flex-col gap-y-1">
|
|
1364
|
-
<FormItem className={formItemClasses}>
|
|
1365
|
-
<FormLabel className="font-normal">Chat Mode</FormLabel>
|
|
1366
|
-
<FormControl>
|
|
1367
|
-
<Checkbox
|
|
1368
|
-
data-testid="chat-mode-checkbox"
|
|
1369
|
-
checked={field.value === true}
|
|
1370
|
-
onCheckedChange={field.onChange}
|
|
1371
|
-
/>
|
|
1372
|
-
</FormControl>
|
|
1373
|
-
</FormItem>
|
|
1374
|
-
<IsOverridden
|
|
1375
|
-
userConfig={config}
|
|
1376
|
-
name="experimental.chat_modes"
|
|
1377
|
-
/>
|
|
1378
|
-
<FormDescription>
|
|
1379
|
-
Switch between different modes in the Chat sidebar, to
|
|
1380
|
-
enable tool use.
|
|
1381
|
-
</FormDescription>
|
|
1382
|
-
</div>
|
|
1383
|
-
)}
|
|
1384
|
-
/>
|
|
1385
1331
|
<FormField
|
|
1386
1332
|
control={form.control}
|
|
1387
1333
|
name="experimental.server_side_pdf_export"
|
|
@@ -9,6 +9,7 @@ import {
|
|
|
9
9
|
type ExternalAgentId,
|
|
10
10
|
getAgentConnectionCommand,
|
|
11
11
|
getAgentDisplayName,
|
|
12
|
+
getAgentWebSocketUrl,
|
|
12
13
|
getSessionsByAgent,
|
|
13
14
|
removeSession,
|
|
14
15
|
type TabId,
|
|
@@ -697,4 +698,72 @@ describe("state utility functions", () => {
|
|
|
697
698
|
`);
|
|
698
699
|
});
|
|
699
700
|
});
|
|
701
|
+
|
|
702
|
+
describe("getAgentWebSocketUrl", () => {
|
|
703
|
+
const originalLocation = window.location;
|
|
704
|
+
|
|
705
|
+
afterEach(() => {
|
|
706
|
+
// Restore original window.location
|
|
707
|
+
Object.defineProperty(window, "location", {
|
|
708
|
+
value: originalLocation,
|
|
709
|
+
writable: true,
|
|
710
|
+
});
|
|
711
|
+
});
|
|
712
|
+
|
|
713
|
+
it("should return ws:// URL with localhost for http protocol", () => {
|
|
714
|
+
Object.defineProperty(window, "location", {
|
|
715
|
+
value: {
|
|
716
|
+
hostname: "localhost",
|
|
717
|
+
protocol: "http:",
|
|
718
|
+
},
|
|
719
|
+
writable: true,
|
|
720
|
+
});
|
|
721
|
+
|
|
722
|
+
expect(getAgentWebSocketUrl("claude")).toMatchInlineSnapshot(
|
|
723
|
+
`"ws://localhost:3017/message"`,
|
|
724
|
+
);
|
|
725
|
+
});
|
|
726
|
+
|
|
727
|
+
it("should return wss:// URL for https protocol", () => {
|
|
728
|
+
Object.defineProperty(window, "location", {
|
|
729
|
+
value: {
|
|
730
|
+
hostname: "example.com",
|
|
731
|
+
protocol: "https:",
|
|
732
|
+
},
|
|
733
|
+
writable: true,
|
|
734
|
+
});
|
|
735
|
+
|
|
736
|
+
expect(getAgentWebSocketUrl("claude")).toMatchInlineSnapshot(
|
|
737
|
+
`"wss://example.com:3017/message"`,
|
|
738
|
+
);
|
|
739
|
+
});
|
|
740
|
+
|
|
741
|
+
it("should work with IP addresses", () => {
|
|
742
|
+
Object.defineProperty(window, "location", {
|
|
743
|
+
value: {
|
|
744
|
+
hostname: "192.168.1.100",
|
|
745
|
+
protocol: "http:",
|
|
746
|
+
},
|
|
747
|
+
writable: true,
|
|
748
|
+
});
|
|
749
|
+
|
|
750
|
+
expect(getAgentWebSocketUrl("claude")).toMatchInlineSnapshot(
|
|
751
|
+
`"ws://192.168.1.100:3017/message"`,
|
|
752
|
+
);
|
|
753
|
+
});
|
|
754
|
+
|
|
755
|
+
it("should work with remote hostnames", () => {
|
|
756
|
+
Object.defineProperty(window, "location", {
|
|
757
|
+
value: {
|
|
758
|
+
hostname: "marimo.example.com",
|
|
759
|
+
protocol: "https:",
|
|
760
|
+
},
|
|
761
|
+
writable: true,
|
|
762
|
+
});
|
|
763
|
+
|
|
764
|
+
expect(getAgentWebSocketUrl("gemini")).toMatchInlineSnapshot(
|
|
765
|
+
`"wss://marimo.example.com:3019/message"`,
|
|
766
|
+
);
|
|
767
|
+
});
|
|
768
|
+
});
|
|
700
769
|
});
|
|
@@ -233,13 +233,17 @@ export function getAgentDisplayName(agentId: ExternalAgentId): string {
|
|
|
233
233
|
}
|
|
234
234
|
|
|
235
235
|
export function getAgentWebSocketUrl(agentId: ExternalAgentId): string {
|
|
236
|
-
|
|
236
|
+
const port = AGENT_CONFIG[agentId].port;
|
|
237
|
+
// Use the current page's hostname so the agent is reachable when
|
|
238
|
+
// marimo is accessed remotely (e.g. via direct IP or reverse proxy).
|
|
239
|
+
const hostname = window.location.hostname;
|
|
240
|
+
const protocol = window.location.protocol === "https:" ? "wss:" : "ws:";
|
|
241
|
+
return `${protocol}//${hostname}:${port}/message` as const;
|
|
237
242
|
}
|
|
238
243
|
|
|
239
244
|
interface AgentConfig {
|
|
240
245
|
port: number;
|
|
241
246
|
command: string;
|
|
242
|
-
webSocketUrl: string;
|
|
243
247
|
sessionSupport: SessionSupportType;
|
|
244
248
|
}
|
|
245
249
|
|
|
@@ -247,25 +251,21 @@ const AGENT_CONFIG: Record<ExternalAgentId, AgentConfig> = {
|
|
|
247
251
|
claude: {
|
|
248
252
|
port: 3017,
|
|
249
253
|
command: "npx @zed-industries/claude-code-acp",
|
|
250
|
-
webSocketUrl: "ws://localhost:3017/message",
|
|
251
254
|
sessionSupport: "single",
|
|
252
255
|
},
|
|
253
256
|
gemini: {
|
|
254
257
|
port: 3019,
|
|
255
258
|
command: "npx @google/gemini-cli --experimental-acp",
|
|
256
|
-
webSocketUrl: "ws://localhost:3019/message",
|
|
257
259
|
sessionSupport: "single",
|
|
258
260
|
},
|
|
259
261
|
codex: {
|
|
260
262
|
port: 3021,
|
|
261
263
|
command: "npx @zed-industries/codex-acp",
|
|
262
|
-
webSocketUrl: "ws://localhost:3021/message",
|
|
263
264
|
sessionSupport: "single",
|
|
264
265
|
},
|
|
265
266
|
opencode: {
|
|
266
267
|
port: 3023,
|
|
267
268
|
command: "npx opencode-ai acp",
|
|
268
|
-
webSocketUrl: "ws://localhost:3023/message",
|
|
269
269
|
sessionSupport: "single",
|
|
270
270
|
},
|
|
271
271
|
};
|