@marimo-team/islands 0.22.5-dev19 → 0.22.5-dev21
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.
|
@@ -5,7 +5,7 @@ import { s as __toESM, t as __commonJSMin } from "./chunk-BNovOVIE.js";
|
|
|
5
5
|
import { t as require_react } from "./react-Bs6Z0kvn.js";
|
|
6
6
|
import { t as require_compiler_runtime } from "./compiler-runtime-B_OLMU9S.js";
|
|
7
7
|
import { r as toast } from "./copy-BRF7ryOP.js";
|
|
8
|
-
import { $t as singleFacet, A as MarimoIncomingMessageEvent, Bt as PluralWord, C as contextToXml, D as AccordionContent, E as Accordion, Fn as Info, Gt as allTablesAtom, I as ChatBubbleIcon, In as File$1, Kt as dataSourceConnectionsAtom, Nn as LoaderCircle, O as AccordionItem, On as Wrench, Ot as createVariableInfoElement, Q as cellErrorsAtom, Rt as jotaiJsonStorage, S as Sections, Sn as Anchor2, T as AIContextRegistry, U as deserializeBlob, Vn as CircleX, W as base64ToDataURL, Yt as getRequestClient, Z as renderHTML, a as toPng, bn as atomWithStorage, d as Spinner, f as Popover, g as isOutputEmpty, h as PopoverTrigger, in as ZodLocalStorage, jt as moveToEndOfEditor, k as AccordionTrigger, kn as Trash2, ln as CellOutputId, m as PopoverContent, n as blobToString, nt as notebookAtom, o as MarkdownRenderer, qt as getTableType, t as processOutput, w as AIContextProvider, x as Boosts, xt as displayCellName, y as DatasourceContextProvider, zt as variablesAtom } from "./process-output-
|
|
8
|
+
import { $t as singleFacet, A as MarimoIncomingMessageEvent, Bt as PluralWord, C as contextToXml, D as AccordionContent, E as Accordion, Fn as Info, Gt as allTablesAtom, I as ChatBubbleIcon, In as File$1, Kt as dataSourceConnectionsAtom, Nn as LoaderCircle, O as AccordionItem, On as Wrench, Ot as createVariableInfoElement, Q as cellErrorsAtom, Rt as jotaiJsonStorage, S as Sections, Sn as Anchor2, T as AIContextRegistry, U as deserializeBlob, Vn as CircleX, W as base64ToDataURL, Yt as getRequestClient, Z as renderHTML, a as toPng, bn as atomWithStorage, d as Spinner, f as Popover, g as isOutputEmpty, h as PopoverTrigger, in as ZodLocalStorage, jt as moveToEndOfEditor, k as AccordionTrigger, kn as Trash2, ln as CellOutputId, m as PopoverContent, n as blobToString, nt as notebookAtom, o as MarkdownRenderer, qt as getTableType, t as processOutput, w as AIContextProvider, x as Boosts, xt as displayCellName, y as DatasourceContextProvider, zt as variablesAtom } from "./process-output-CS0tft0b.js";
|
|
9
9
|
import "./chunk-5FQGJX7Z-C428iZBW.js";
|
|
10
10
|
import { u as createLucideIcon } from "./dist-D56NKWim.js";
|
|
11
11
|
import { C as logNever, I as X, n as Strings, t as Label } from "./label-CIR53v8V.js";
|
package/dist/main.js
CHANGED
|
@@ -21,7 +21,7 @@ import { a as __toCommonJS, n as __esmMin, r as __export, s as __toESM, t as __c
|
|
|
21
21
|
import { t as require_react } from "./react-Bs6Z0kvn.js";
|
|
22
22
|
import { t as require_compiler_runtime } from "./compiler-runtime-B_OLMU9S.js";
|
|
23
23
|
import { n as Copy, r as toast, t as copyToClipboard } from "./copy-BRF7ryOP.js";
|
|
24
|
-
import { $ as createActions, A as MarimoIncomingMessageEvent, An as Table2, At as Paths, B as DotFilledIcon, Bn as Columns2, Bt as PluralWord, Cn as Close$1, Ct as isInternalCellName, D as AccordionContent, Dn as Trigger2, Dt as MarkdownLanguageAdapter, E as Accordion, En as Root2$4, Et as customPythonLanguageSupport, F as BorderAllIcon, Fn as Info, Ft as useChromeActions, G as base64ToDataView, Gn as import_lib, H as PinRightIcon, Hn as CircleAlert, Ht as DATA_TYPE_ICON, In as File, It as repl, J as extractBase64FromDataURL, Jt as convertStatsName, K as base64ToUint8Array, L as CheckIcon, Ln as FileText, Lt as adaptForLocalStorage, M as MarimoValueReadyEvent, Mn as NotebookPen, Mt as goToCellLine, N as MarimoValueUpdateEvent, Nn as LoaderCircle, Nt as DeferredRequestRegistry, O as AccordionItem, On as Wrench, P as createInputEvent, Pn as Layers, Pt as generateUUID, Qt as isUninstantiated, R as ChevronDownIcon, Rn as Eye, Rt as jotaiJsonStorage, St as getValidName, Tn as Item$1, Tt as Checkbox, U as deserializeBlob, Un as Braces, Ut as getDataTypeColor, V as PinLeftIcon, Vn as CircleX, Vt as PluralWords, Wn as esm_default$1, Wt as require_client, X as safeExtractSetUIElementMessageBuffers, Xt as requestClientAtom, Y as isDataURLString, Yt as getRequestClient, Z as renderHTML, Zt as useRequestClient, _ as useExpandedConsoleOutput, _n as jsonToMarkdown, _t as headingToIdentifier, a as toPng, an as filenameAtom, at as useCellActions, b as getDatasourceContext, bn as atomWithStorage, bt as getCellDomProps, c as useCellFocusActions, cn as parseInitialValue, ct as createCell, d as Spinner, dn as SCRATCH_CELL_ID, dt as initialModeAtom, en as elementContainsMarimoCellFile, et as getCellEditorView, f as Popover$1, fn as UIElementId, ft as kioskModeAtom, g as isOutputEmpty, gn as jsonParseWithSpecialChar, gt as isErrorMime, h as PopoverTrigger, hn as RANDOM_ID_ATTR, ht as outputIsStale, i as PythonIcon, it as reducer, j as MarimoValueInputEvent, jn as PaintRoller, k as AccordionTrigger, kn as Trash2, kt as PathBuilder, l as useLastFocusedCellId, ln as CellOutputId, lt as AnsiUp, m as PopoverContent, mn as OBJECT_ID_ATTR, mt as outputIsLoading, n as blobToString, nn as getTracebackInfo, nt as notebookAtom, o as MarkdownRenderer, on as parseAttrValue, ot as useCellIds, p as PopoverClose$1, pn as findCellId, pt as viewStateAtom, q as dataViewToBase64, r as filesToBase64, rn as NotebookScopedLocalStorage, rt as notebookOutline, s as LazyAnyLanguageCodeMirror, sn as parseDataset, st as useCellNames, t as processOutput, tn as extractAllTracebackInfo, tt as getCellNames, u as maybeAddAltairImport, un as HTMLCellId, ut as getInitialAppMode, v as useExpandedOutput, vn as jsonToTSV, vt as sanitizeHtml, wn as Content2$1, wt as normalizeName, xn as selectAtom, xt as displayCellName, yn as atomWithReducer, yt as DATA_CELL_ID, z as ChevronRightIcon, zn as Database, __tla as __tla_0 } from "./process-output-
|
|
24
|
+
import { $ as createActions, A as MarimoIncomingMessageEvent, An as Table2, At as Paths, B as DotFilledIcon, Bn as Columns2, Bt as PluralWord, Cn as Close$1, Ct as isInternalCellName, D as AccordionContent, Dn as Trigger2, Dt as MarkdownLanguageAdapter, E as Accordion, En as Root2$4, Et as customPythonLanguageSupport, F as BorderAllIcon, Fn as Info, Ft as useChromeActions, G as base64ToDataView, Gn as import_lib, H as PinRightIcon, Hn as CircleAlert, Ht as DATA_TYPE_ICON, In as File, It as repl, J as extractBase64FromDataURL, Jt as convertStatsName, K as base64ToUint8Array, L as CheckIcon, Ln as FileText, Lt as adaptForLocalStorage, M as MarimoValueReadyEvent, Mn as NotebookPen, Mt as goToCellLine, N as MarimoValueUpdateEvent, Nn as LoaderCircle, Nt as DeferredRequestRegistry, O as AccordionItem, On as Wrench, P as createInputEvent, Pn as Layers, Pt as generateUUID, Qt as isUninstantiated, R as ChevronDownIcon, Rn as Eye, Rt as jotaiJsonStorage, St as getValidName, Tn as Item$1, Tt as Checkbox, U as deserializeBlob, Un as Braces, Ut as getDataTypeColor, V as PinLeftIcon, Vn as CircleX, Vt as PluralWords, Wn as esm_default$1, Wt as require_client, X as safeExtractSetUIElementMessageBuffers, Xt as requestClientAtom, Y as isDataURLString, Yt as getRequestClient, Z as renderHTML, Zt as useRequestClient, _ as useExpandedConsoleOutput, _n as jsonToMarkdown, _t as headingToIdentifier, a as toPng, an as filenameAtom, at as useCellActions, b as getDatasourceContext, bn as atomWithStorage, bt as getCellDomProps, c as useCellFocusActions, cn as parseInitialValue, ct as createCell, d as Spinner, dn as SCRATCH_CELL_ID, dt as initialModeAtom, en as elementContainsMarimoCellFile, et as getCellEditorView, f as Popover$1, fn as UIElementId, ft as kioskModeAtom, g as isOutputEmpty, gn as jsonParseWithSpecialChar, gt as isErrorMime, h as PopoverTrigger, hn as RANDOM_ID_ATTR, ht as outputIsStale, i as PythonIcon, it as reducer, j as MarimoValueInputEvent, jn as PaintRoller, k as AccordionTrigger, kn as Trash2, kt as PathBuilder, l as useLastFocusedCellId, ln as CellOutputId, lt as AnsiUp, m as PopoverContent, mn as OBJECT_ID_ATTR, mt as outputIsLoading, n as blobToString, nn as getTracebackInfo, nt as notebookAtom, o as MarkdownRenderer, on as parseAttrValue, ot as useCellIds, p as PopoverClose$1, pn as findCellId, pt as viewStateAtom, q as dataViewToBase64, r as filesToBase64, rn as NotebookScopedLocalStorage, rt as notebookOutline, s as LazyAnyLanguageCodeMirror, sn as parseDataset, st as useCellNames, t as processOutput, tn as extractAllTracebackInfo, tt as getCellNames, u as maybeAddAltairImport, un as HTMLCellId, ut as getInitialAppMode, v as useExpandedOutput, vn as jsonToTSV, vt as sanitizeHtml, wn as Content2$1, wt as normalizeName, xn as selectAtom, xt as displayCellName, yn as atomWithReducer, yt as DATA_CELL_ID, z as ChevronRightIcon, zn as Database, __tla as __tla_0 } from "./process-output-CS0tft0b.js";
|
|
25
25
|
import { __tla as __tla_1 } from "./chunk-5FQGJX7Z-C428iZBW.js";
|
|
26
26
|
import { o as useSize, s as Root$4, u as createLucideIcon } from "./dist-D56NKWim.js";
|
|
27
27
|
import { A as $896ba0a80a8f4d36$export$85fd5fdf27bacc79, C as DEFAULT_COLOR_SCHEME, D as SCALE_TYPE_DESCRIPTIONS, E as EMPTY_VALUE$1, F as ListFilter, I as ChartPie, L as ChartColumn, M as $5a387cc49350e6db$export$722debc0e56fea39, N as Table$1, O as TIME_UNIT_DESCRIPTIONS, P as SquareFunction, S as DEFAULT_AGGREGATION, T as DEFAULT_TIME_UNIT, _ as AGGREGATION_TYPE_DESCRIPTIONS, a as AGGREGATION_FNS$1, b as COLOR_SCHEMES, c as COLOR_BY_FIELDS, d as NONE_VALUE, f as SELECTABLE_DATA_TYPES, g as TIME_UNITS, h as STRING_AGGREGATION_FNS, i as convertDataTypeToSelectable, j as $fb18d541ea1ad717$export$ad991b66133851cf, k as escapeFieldName, l as COMBINED_TIME_UNITS, m as SORT_TYPES, n as createSpecWithoutData, o as BIN_AGGREGATION, p as SINGLE_TIME_UNITS, r as isFieldSet, s as CHART_TYPES, t as augmentSpecWithData, u as ChartType, v as AGGREGATION_TYPE_ICON, w as DEFAULT_MAX_BINS_FACET, x as COUNT_FIELD, y as CHART_TYPE_ICON } from "./spec-ByDEU1T3.js";
|
|
@@ -37125,7 +37125,7 @@ ${E}`,
|
|
|
37125
37125
|
};
|
|
37126
37126
|
}
|
|
37127
37127
|
};
|
|
37128
|
-
var LazyChatbot = import_react.lazy(() => import("./chat-ui-
|
|
37128
|
+
var LazyChatbot = import_react.lazy(() => import("./chat-ui-CMF7kbIX.js").then((e) => ({
|
|
37129
37129
|
default: e.Chatbot
|
|
37130
37130
|
}))), messageSchema = array(object({
|
|
37131
37131
|
id: string(),
|
|
@@ -65633,7 +65633,7 @@ ${c}
|
|
|
65633
65633
|
return Logger.warn("Failed to get version from mount config"), null;
|
|
65634
65634
|
}
|
|
65635
65635
|
}
|
|
65636
|
-
const marimoVersionAtom = atom(getVersionFromMountConfig() || "0.22.5-
|
|
65636
|
+
const marimoVersionAtom = atom(getVersionFromMountConfig() || "0.22.5-dev21"), showCodeInRunModeAtom = atom(true);
|
|
65637
65637
|
atom(null);
|
|
65638
65638
|
var VIRTUAL_FILE_REGEX = /\/@file\/([^\s"&'/]+)\.([\dA-Za-z]+)/g, VirtualFileTracker = class e {
|
|
65639
65639
|
constructor() {
|
|
@@ -3976,7 +3976,7 @@ ${r.join("\n")}`;
|
|
|
3976
3976
|
return t.length === 0 ? null : t;
|
|
3977
3977
|
}
|
|
3978
3978
|
filenameAtom = atom(getFilenameFromDOM());
|
|
3979
|
-
atom(null), atom(void 0);
|
|
3979
|
+
atom(null), atom(null), atom(void 0);
|
|
3980
3980
|
var InMemoryStorage = class {
|
|
3981
3981
|
constructor() {
|
|
3982
3982
|
__publicField(this, "store", /* @__PURE__ */ new Map());
|
package/package.json
CHANGED
|
@@ -16,6 +16,22 @@ export const filenameAtom = atom<string | null>(getFilenameFromDOM());
|
|
|
16
16
|
*/
|
|
17
17
|
export const cwdAtom = atom<string | null>(null);
|
|
18
18
|
|
|
19
|
+
/**
|
|
20
|
+
* LSP workspace information from the backend.
|
|
21
|
+
* Contains the project root and the document's file URI.
|
|
22
|
+
*/
|
|
23
|
+
export interface LspWorkspace {
|
|
24
|
+
rootUri: string;
|
|
25
|
+
documentUri: string;
|
|
26
|
+
}
|
|
27
|
+
|
|
28
|
+
/**
|
|
29
|
+
* Atom for storing the LSP workspace information.
|
|
30
|
+
* This is populated during active notebook sessions
|
|
31
|
+
* and null for other pages.
|
|
32
|
+
*/
|
|
33
|
+
export const lspWorkspaceAtom = atom<LspWorkspace | null>(null);
|
|
34
|
+
|
|
19
35
|
/**
|
|
20
36
|
* Set for static notebooks.
|
|
21
37
|
*/
|
package/src/mount.tsx
CHANGED
|
@@ -36,7 +36,12 @@ import {
|
|
|
36
36
|
DEFAULT_RUNTIME_CONFIG,
|
|
37
37
|
runtimeConfigAtom,
|
|
38
38
|
} from "./core/runtime/config";
|
|
39
|
-
import {
|
|
39
|
+
import {
|
|
40
|
+
codeAtom,
|
|
41
|
+
cwdAtom,
|
|
42
|
+
filenameAtom,
|
|
43
|
+
lspWorkspaceAtom,
|
|
44
|
+
} from "./core/saving/file-state";
|
|
40
45
|
import { store } from "./core/state/jotai";
|
|
41
46
|
import { patchFetch, patchVegaLoader } from "./core/static/files";
|
|
42
47
|
import {
|
|
@@ -150,6 +155,16 @@ const mountOptionsSchema = z.object({
|
|
|
150
155
|
* absolute working directory of the notebook
|
|
151
156
|
*/
|
|
152
157
|
cwd: z.string().nullish().default(null),
|
|
158
|
+
/**
|
|
159
|
+
* LSP workspace information
|
|
160
|
+
*/
|
|
161
|
+
lspWorkspace: z
|
|
162
|
+
.object({
|
|
163
|
+
rootUri: z.string(),
|
|
164
|
+
documentUri: z.string(),
|
|
165
|
+
})
|
|
166
|
+
.nullish()
|
|
167
|
+
.default(null),
|
|
153
168
|
/**
|
|
154
169
|
* notebook code
|
|
155
170
|
*/
|
|
@@ -287,6 +302,7 @@ function initStore(options: unknown) {
|
|
|
287
302
|
// Files
|
|
288
303
|
store.set(filenameAtom, parsedOptions.data.filename);
|
|
289
304
|
store.set(cwdAtom, parsedOptions.data.cwd ?? null);
|
|
305
|
+
store.set(lspWorkspaceAtom, parsedOptions.data.lspWorkspace);
|
|
290
306
|
store.set(codeAtom, parsedOptions.data.code);
|
|
291
307
|
store.set(initialModeAtom, mode);
|
|
292
308
|
|