@marimo-team/islands 0.23.11-dev9 → 0.23.11
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/{ConnectedDataExplorerComponent-Z3RP7Vmm.js → ConnectedDataExplorerComponent-WqG-xX4l.js} +13 -13
- package/dist/{ErrorBoundary-DpbaKVv7.js → ErrorBoundary-BNx_OSVo.js} +2 -2
- package/dist/{any-language-editor-CAgFD4Kd.js → any-language-editor-rPSlOll9.js} +5 -5
- package/dist/assets/__vite-browser-external-DAm_YW43.js +1 -0
- package/dist/assets/{worker-CC0Oul9k.js → worker-DEDLIQQV.js} +2 -2
- package/dist/{button-C5K9fIPF.js → button-vQhauTmO.js} +20 -0
- package/dist/{capabilities-BceAxrAW.js → capabilities-BEHzIS99.js} +1 -1
- package/dist/{chat-ui-c1FdlK-C.js → chat-ui-k2kqhCv5.js} +135 -106
- package/dist/{check-BCaJeT-J.js → check-nrzHDi45.js} +1 -1
- package/dist/{code-visibility-0vPSjYnM.js → code-visibility-CFUW5L3i.js} +81 -68
- package/dist/{copy-UqRYxiOg.js → copy-UhDed7D4.js} +2 -2
- package/dist/{dist-Dk6PV_d3.js → dist-DYGLrbYQ.js} +2 -2
- package/dist/{error-banner-CJXYJ6Sb.js → error-banner-BHAkVFc2.js} +2 -2
- package/dist/{esm-BaH2eg5-.js → esm-Bqu9AE2K.js} +1 -1
- package/dist/{extends-D_hDsj6R.js → extends-9Yl5BEcg.js} +4 -4
- package/dist/{formats-C4wO47tk.js → formats-BV4bOfMI.js} +3 -3
- package/dist/{glide-data-editor-BPkCPs7L.js → glide-data-editor-BDTq6YUb.js} +9 -9
- package/dist/{html-to-image-D5-EpALB.js → html-to-image-C86pQALH.js} +16 -16
- package/dist/{input-OdWHkobi.js → input-AKkGXdyV.js} +6 -6
- package/dist/{label-CC4ytI1X.js → label-E3ZJXHu8.js} +2 -2
- package/dist/{loader-BWLPpjKK.js → loader-YPuQvn1Y.js} +1 -1
- package/dist/main.js +981 -978
- package/dist/{mermaid-BotvIKg9.js → mermaid-QFAR9YgY.js} +5 -5
- package/dist/{process-output-WDZE0cyS.js → process-output-nNw4OpSj.js} +3 -3
- package/dist/{reveal-component-BZpDHGsk.js → reveal-component-0u6v5UUq.js} +10 -10
- package/dist/{spec-X7FwLJni.js → spec-B45_YCNI.js} +4 -4
- package/dist/{strings-J57tzLr3.js → strings-Cq2s9_EQ.js} +4 -4
- package/dist/style.css +1 -1
- package/dist/{swiper-component-B2t5sN1q.js → swiper-component-BNa_4kh2.js} +2 -2
- package/dist/{toDate-d8RCRrRd.js → toDate-Do1xRzAo.js} +3 -3
- package/dist/{tooltip-DpcyNkQ2.js → tooltip-Bz3OAwrU.js} +3 -3
- package/dist/{types-ChtMFmZ2.js → types-D8gEGs4R.js} +1 -1
- package/dist/{useAsyncData-PonK__yh.js → useAsyncData-CL3o2p4i.js} +1 -1
- package/dist/{useDateFormatter-QB-3MpYr.js → useDateFormatter-BC6iSz9g.js} +2 -2
- package/dist/{useDeepCompareMemoize-D3NGWke6.js → useDeepCompareMemoize-BPx2MuOK.js} +1 -1
- package/dist/{useIframeCapabilities-C4JTXTIh.js → useIframeCapabilities-C6Ta3EyP.js} +1 -1
- package/dist/{useLifecycle-00mO3OSS.js → useLifecycle-C3Ec71q0.js} +3 -3
- package/dist/{useTheme-DEhDzATN.js → useTheme-ZhT6uIu3.js} +4 -3
- package/dist/{vega-component-DGPUhbDs.js → vega-component-C3AWYGAL.js} +10 -10
- package/dist/{zod-aLSua2NL.js → zod-DXqkaI_w.js} +1 -1
- package/package.json +1 -1
- package/src/components/ai/ai-model-dropdown.tsx +6 -0
- package/src/components/app-config/ai-config.tsx +73 -55
- package/src/components/app-config/data-form.tsx +33 -43
- package/src/components/app-config/is-overridden.tsx +125 -58
- package/src/components/app-config/user-config-form.tsx +178 -227
- package/src/components/chat/chat-display.tsx +5 -0
- package/src/components/chat/chat-panel.tsx +21 -8
- package/src/components/chat/tool-call/tool-call-view.tsx +4 -0
- package/src/components/chat/tool-call/tool-history-row.tsx +26 -5
- package/src/components/data-table/TableTopBar.tsx +4 -4
- package/src/components/data-table/__tests__/columns.test.tsx +20 -0
- package/src/components/data-table/__tests__/data-table.test.tsx +28 -0
- package/src/components/data-table/columns.tsx +16 -1
- package/src/components/data-table/data-table.tsx +3 -3
- package/src/components/data-table/filters/types.ts +1 -0
- package/src/components/data-table/renderers.tsx +5 -1
- package/src/components/datasources/__tests__/install-package-button.test.tsx +11 -0
- package/src/components/datasources/__tests__/utils.test.ts +127 -2
- package/src/components/datasources/datasources.tsx +44 -17
- package/src/components/datasources/install-package-button.tsx +3 -1
- package/src/components/datasources/utils.ts +45 -0
- package/src/components/editor/actions/useNotebookActions.tsx +62 -21
- package/src/components/editor/actions/useSetCodeVisibility.ts +57 -0
- package/src/components/editor/header/__tests__/status.test.tsx +0 -4
- package/src/components/editor/header/status.tsx +2 -3
- package/src/core/cells/__tests__/cells.test.ts +33 -0
- package/src/core/cells/cells.ts +1 -1
- package/src/core/config/config-schema.ts +6 -1
- package/src/core/edit-app.tsx +14 -0
- package/src/core/hotkeys/hotkeys.ts +20 -0
- package/src/core/websocket/__tests__/useMarimoKernelConnection.test.ts +0 -13
- package/src/core/websocket/types.ts +0 -1
- package/src/core/websocket/useMarimoKernelConnection.tsx +0 -14
- package/src/css/app/print.css +8 -0
- package/src/css/md.css +12 -0
- package/src/plugins/impl/DataTablePlugin.tsx +12 -5
- package/src/plugins/impl/__tests__/DataTablePlugin.test.tsx +1 -1
- package/src/plugins/impl/chat/chat-ui.tsx +1 -0
- package/src/plugins/impl/data-frames/DataFramePlugin.tsx +1 -1
- package/dist/assets/__vite-browser-external-eshhtsgZ.js +0 -1
- package/src/components/editor/actions/useHideAllMarkdownCode.ts +0 -53
|
@@ -181,6 +181,7 @@ interface Data<T> {
|
|
|
181
181
|
maxHeight?: number;
|
|
182
182
|
selection: DataTableSelection;
|
|
183
183
|
showDownload: boolean;
|
|
184
|
+
showSearch: boolean;
|
|
184
185
|
showFilters: boolean;
|
|
185
186
|
showColumnSummaries: boolean | "stats" | "chart";
|
|
186
187
|
showDataTypes: boolean;
|
|
@@ -195,6 +196,7 @@ interface Data<T> {
|
|
|
195
196
|
hiddenColumns?: string[];
|
|
196
197
|
textJustifyColumns?: Record<string, "left" | "center" | "right">;
|
|
197
198
|
wrappedColumns?: string[];
|
|
199
|
+
columnWidths?: Record<string, number>;
|
|
198
200
|
headerTooltip?: Record<string, string>;
|
|
199
201
|
totalColumns: number;
|
|
200
202
|
maxColumns: number | "all";
|
|
@@ -266,6 +268,7 @@ export const DataTablePlugin = createPlugin<S>("marimo-table")
|
|
|
266
268
|
showColumnExplorer: z.boolean().default(true),
|
|
267
269
|
showRowExplorer: z.boolean().default(true),
|
|
268
270
|
showChartBuilder: z.boolean().default(true),
|
|
271
|
+
showSearch: z.boolean().default(true),
|
|
269
272
|
rowHeaders: columnToFieldTypesSchema,
|
|
270
273
|
freezeColumnsLeft: z.array(z.string()).optional(),
|
|
271
274
|
freezeColumnsRight: z.array(z.string()).optional(),
|
|
@@ -274,6 +277,9 @@ export const DataTablePlugin = createPlugin<S>("marimo-table")
|
|
|
274
277
|
.record(z.string(), z.enum(["left", "center", "right"]))
|
|
275
278
|
.optional(),
|
|
276
279
|
wrappedColumns: z.array(z.string()).optional(),
|
|
280
|
+
columnWidths: z
|
|
281
|
+
.record(z.string(), z.number().int().positive())
|
|
282
|
+
.optional(),
|
|
277
283
|
headerTooltip: z.record(z.string(), z.string()).optional(),
|
|
278
284
|
fieldTypes: columnToFieldTypesSchema.nullish(),
|
|
279
285
|
totalColumns: z.number(),
|
|
@@ -381,7 +387,6 @@ export const DataTablePlugin = createPlugin<S>("marimo-table")
|
|
|
381
387
|
{...props.data}
|
|
382
388
|
{...props.functions}
|
|
383
389
|
host={props.host}
|
|
384
|
-
enableSearch={true}
|
|
385
390
|
data={props.data.data}
|
|
386
391
|
value={props.value}
|
|
387
392
|
setValue={props.setValue}
|
|
@@ -466,8 +471,6 @@ interface DataTableProps<T> extends Data<T>, DataTableFunctions {
|
|
|
466
471
|
// Selection
|
|
467
472
|
value: S;
|
|
468
473
|
setValue: (value: S) => void;
|
|
469
|
-
// Search
|
|
470
|
-
enableSearch: boolean;
|
|
471
474
|
// Filters
|
|
472
475
|
enableFilters?: boolean;
|
|
473
476
|
cellStyles?: CellStyleState | null;
|
|
@@ -837,7 +840,7 @@ const DataTableComponent = ({
|
|
|
837
840
|
setValue,
|
|
838
841
|
sorting,
|
|
839
842
|
setSorting,
|
|
840
|
-
|
|
843
|
+
showSearch,
|
|
841
844
|
searchQuery,
|
|
842
845
|
setSearchQuery,
|
|
843
846
|
filters,
|
|
@@ -848,6 +851,7 @@ const DataTableComponent = ({
|
|
|
848
851
|
hiddenColumns,
|
|
849
852
|
textJustifyColumns,
|
|
850
853
|
wrappedColumns,
|
|
854
|
+
columnWidths,
|
|
851
855
|
headerTooltip,
|
|
852
856
|
totalColumns,
|
|
853
857
|
get_row_ids,
|
|
@@ -935,6 +939,7 @@ const DataTableComponent = ({
|
|
|
935
939
|
const memoizedRowHeaders = useDeepCompareMemoize(rowHeaders);
|
|
936
940
|
const memoizedTextJustifyColumns = useDeepCompareMemoize(textJustifyColumns);
|
|
937
941
|
const memoizedWrappedColumns = useDeepCompareMemoize(wrappedColumns);
|
|
942
|
+
const memoizedColumnWidths = useDeepCompareMemoize(columnWidths);
|
|
938
943
|
const memoizedChartSpecModel = useDeepCompareMemoize(chartSpecModel);
|
|
939
944
|
const fractionDigitsByColumn = useDeepCompareMemoize(computedFractionDigits);
|
|
940
945
|
const shownColumns = memoizedClampedFieldTypes.length;
|
|
@@ -953,6 +958,7 @@ const DataTableComponent = ({
|
|
|
953
958
|
fieldTypes: memoizedClampedFieldTypes,
|
|
954
959
|
textJustifyColumns: memoizedTextJustifyColumns,
|
|
955
960
|
wrappedColumns: memoizedWrappedColumns,
|
|
961
|
+
columnWidths: memoizedColumnWidths,
|
|
956
962
|
headerTooltip: headerTooltip,
|
|
957
963
|
// Only show data types if they are explicitly set
|
|
958
964
|
showDataTypes: showDataTypes,
|
|
@@ -967,6 +973,7 @@ const DataTableComponent = ({
|
|
|
967
973
|
memoizedClampedFieldTypes,
|
|
968
974
|
memoizedTextJustifyColumns,
|
|
969
975
|
memoizedWrappedColumns,
|
|
976
|
+
memoizedColumnWidths,
|
|
970
977
|
headerTooltip,
|
|
971
978
|
calculate_top_k_rows,
|
|
972
979
|
fractionDigitsByColumn,
|
|
@@ -1138,7 +1145,7 @@ const DataTableComponent = ({
|
|
|
1138
1145
|
hoverTemplate={hoverTemplate}
|
|
1139
1146
|
cellHoverTexts={cellHoverTexts}
|
|
1140
1147
|
downloadAs={showDownload ? downloadAs : undefined}
|
|
1141
|
-
|
|
1148
|
+
showSearch={showSearch}
|
|
1142
1149
|
searchQuery={searchQuery}
|
|
1143
1150
|
onSearchQueryChange={setSearchQuery}
|
|
1144
1151
|
showFilters={showFilters}
|
|
@@ -94,7 +94,7 @@ describe("LoadingDataTableComponent", () => {
|
|
|
94
94
|
hasStableRowId: false,
|
|
95
95
|
lazy: false,
|
|
96
96
|
host,
|
|
97
|
-
|
|
97
|
+
showSearch: true,
|
|
98
98
|
value: [] as (number | string | { rowId: string; columnName?: string })[],
|
|
99
99
|
setValue,
|
|
100
100
|
download_as: vi.fn() as DownloadAsArgs,
|
|
@@ -338,7 +338,7 @@ export const DataFrameComponent = memo(
|
|
|
338
338
|
showDownload={showDownload}
|
|
339
339
|
download_as={download_as}
|
|
340
340
|
get_size_bytes={get_size_bytes}
|
|
341
|
-
|
|
341
|
+
showSearch={false}
|
|
342
342
|
showFilters={false}
|
|
343
343
|
search={search}
|
|
344
344
|
showColumnSummaries={false}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{t as e}from"./worker-CC0Oul9k.js";var t=e(((e,t)=>{t.exports={}}));export default t();
|
|
@@ -1,53 +0,0 @@
|
|
|
1
|
-
/* Copyright 2026 Marimo. All rights reserved. */
|
|
2
|
-
|
|
3
|
-
import { useCallback } from "react"; /* Copyright 2026 Marimo. All rights reserved. */
|
|
4
|
-
import { getNotebook, useCellActions } from "@/core/cells/cells";
|
|
5
|
-
import type { CellId } from "@/core/cells/ids";
|
|
6
|
-
import { MarkdownLanguageAdapter } from "@/core/codemirror/language/languages/markdown";
|
|
7
|
-
import { useRequestClient } from "@/core/network/requests";
|
|
8
|
-
import type { CellConfig } from "@/core/network/types";
|
|
9
|
-
import { Objects } from "@/utils/objects";
|
|
10
|
-
|
|
11
|
-
/**
|
|
12
|
-
* Hook to hide all markdown code cells
|
|
13
|
-
*/
|
|
14
|
-
export const useHideAllMarkdownCode = () => {
|
|
15
|
-
const { updateCellConfig } = useCellActions();
|
|
16
|
-
const { saveCellConfig } = useRequestClient();
|
|
17
|
-
|
|
18
|
-
return useCallback(async () => {
|
|
19
|
-
const markdownAdapter = new MarkdownLanguageAdapter();
|
|
20
|
-
const notebook = getNotebook();
|
|
21
|
-
const cellIds = notebook.cellIds.inOrderIds;
|
|
22
|
-
|
|
23
|
-
const newConfigs: Record<CellId, Partial<CellConfig>> = {};
|
|
24
|
-
|
|
25
|
-
// Find all markdown cells that aren't already hidden
|
|
26
|
-
for (const cellId of cellIds) {
|
|
27
|
-
if (notebook.cellData[cellId] === undefined) {
|
|
28
|
-
continue;
|
|
29
|
-
}
|
|
30
|
-
const { code, config } = notebook.cellData[cellId];
|
|
31
|
-
if (config.hide_code) {
|
|
32
|
-
continue;
|
|
33
|
-
}
|
|
34
|
-
if (markdownAdapter.isSupported(code)) {
|
|
35
|
-
newConfigs[cellId] = { hide_code: true };
|
|
36
|
-
}
|
|
37
|
-
}
|
|
38
|
-
|
|
39
|
-
const entries = Objects.entries(newConfigs);
|
|
40
|
-
|
|
41
|
-
if (entries.length === 0) {
|
|
42
|
-
return;
|
|
43
|
-
}
|
|
44
|
-
|
|
45
|
-
// Save to backend
|
|
46
|
-
await saveCellConfig({ configs: newConfigs });
|
|
47
|
-
|
|
48
|
-
// Update on frontend
|
|
49
|
-
for (const [cellId, config] of entries) {
|
|
50
|
-
updateCellConfig({ cellId, config });
|
|
51
|
-
}
|
|
52
|
-
}, [updateCellConfig]);
|
|
53
|
-
};
|