@marimo-team/islands 0.23.2-dev25 → 0.23.2-dev28

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.
Files changed (101) hide show
  1. package/dist/_basePickBy-C-mod5Dp.js +34 -0
  2. package/dist/{_baseUniq-C87CckHL.js → _baseUniq-Be_p_Ty6.js} +2 -2
  3. package/dist/{architecture-7HQA4BMR-BHdkAMvZ.js → architecture-7HQA4BMR-kNyKQXbB.js} +2 -2
  4. package/dist/{architectureDiagram-VXUJARFQ-B3YQo9At.js → architectureDiagram-VXUJARFQ-Dx_Dniiw.js} +11 -11
  5. package/dist/{blockDiagram-VD42YOAC-CpQ3TKEN.js → blockDiagram-VD42YOAC-D3hGPvEt.js} +4 -4
  6. package/dist/{c4Diagram-YG6GDRKO-CZSU4uqU.js → c4Diagram-YG6GDRKO-CtY1WMbV.js} +1 -1
  7. package/dist/{chat-ui-CNHw9Osh.js → chat-ui-CQtPb6Dj.js} +4 -4
  8. package/dist/{chunk-4F5CHEZ2-D5mClyDv.js → chunk-4F5CHEZ2-oWcaQSBe.js} +1 -1
  9. package/dist/{chunk-B2363JML-Br0eA2T3.js → chunk-B2363JML-72CRxZbk.js} +1 -1
  10. package/dist/{chunk-B4BG7PRW-4BjV11Br.js → chunk-B4BG7PRW-ChYfc4rf.js} +2 -2
  11. package/dist/{chunk-DI55MBZ5-DITY3EyP.js → chunk-DI55MBZ5-CYNE3N2j.js} +2 -2
  12. package/dist/{chunk-FRFDVMJY-DnEvEFRR.js → chunk-FRFDVMJY-Dgl-7l0K.js} +1 -1
  13. package/dist/{chunk-JA3XYJ7Z-BcPEfxk_.js → chunk-JA3XYJ7Z-B2BoMdpr.js} +1 -1
  14. package/dist/{chunk-JZLCHNYA-2bnLL3xL.js → chunk-JZLCHNYA-CkHD9mQU.js} +2 -2
  15. package/dist/{chunk-N4CR4FBY-CpZSuGSU.js → chunk-N4CR4FBY-DDeXUk3y.js} +4 -4
  16. package/dist/{chunk-PL6DKKU2-DnId6G-x.js → chunk-PL6DKKU2-CpBHhdj8.js} +1 -1
  17. package/dist/{chunk-QXUST7PY-Ch6F5Obl.js → chunk-QXUST7PY-BnSZbSK7.js} +3 -3
  18. package/dist/{chunk-S3R3BYOJ-B0UOFJwq.js → chunk-S3R3BYOJ-DVdRer7T.js} +1 -1
  19. package/dist/{chunk-SJTYNZTY-BsBZnJUj.js → chunk-SJTYNZTY-DPOwAZc-.js} +1 -1
  20. package/dist/{chunk-TCCFYFTB-Clbl-fTg.js → chunk-TCCFYFTB-BdE6BTq1.js} +6 -6
  21. package/dist/{chunk-TQ3KTPDO-CFkSQ30e.js → chunk-TQ3KTPDO-BCXCq8f2.js} +1 -1
  22. package/dist/{chunk-UMXZTB3W-D-A834Bq.js → chunk-UMXZTB3W-C5Hu2atA.js} +1 -1
  23. package/dist/{classDiagram-v2-WZHVMYZB-DrmbGANl.js → classDiagram-2ON5EDUG-sUXB0Obe.js} +6 -6
  24. package/dist/{classDiagram-2ON5EDUG-C8-zE3Zv.js → classDiagram-v2-WZHVMYZB-JeF9-idj.js} +6 -6
  25. package/dist/{clone-DZFQCtFJ.js → clone-B48LSK6I.js} +1 -1
  26. package/dist/{constants-CvyfaCvs.js → constants-CcdcOQyC.js} +2 -1
  27. package/dist/{dagre-6UL2VRFP-OMItEBnY.js → dagre-6UL2VRFP-Bs_DhCUk.js} +9 -9
  28. package/dist/{dagre-QVd-lCXU.js → dagre-BLW2E2fh.js} +19 -8
  29. package/dist/{diagram-PSM6KHXK-CkKbohWI.js → diagram-PSM6KHXK-VB3japmQ.js} +10 -10
  30. package/dist/{diagram-QEK2KX5R-DjUMpVcx.js → diagram-QEK2KX5R-B8nm2JL9.js} +10 -10
  31. package/dist/{diagram-S2PKOQOG-b-c0d-wZ.js → diagram-S2PKOQOG-D6PR_2iv.js} +10 -10
  32. package/dist/{erDiagram-Q2GNP2WA-CDhLaOZ1.js → erDiagram-Q2GNP2WA-gjAse7Jb.js} +5 -5
  33. package/dist/{flowDiagram-NV44I4VS-BDi4O4CL.js → flowDiagram-NV44I4VS-CQTSZWcI.js} +5 -5
  34. package/dist/{ganttDiagram-JELNMOA3-BpZE6kVp.js → ganttDiagram-JELNMOA3-aktqk_om.js} +1 -1
  35. package/dist/{gitGraph-G5XIXVHT-B_c6xFJv.js → gitGraph-G5XIXVHT-Cy06nzLg.js} +2 -2
  36. package/dist/{gitGraphDiagram-V2S2FVAM-iQnXzbPM.js → gitGraphDiagram-V2S2FVAM-C1ntKO33.js} +10 -10
  37. package/dist/{glide-data-editor-BFqEJGJW.js → glide-data-editor-DBgJAMqf.js} +2 -2
  38. package/dist/{graphlib-BV1_gi0C.js → graphlib-Cr691-na.js} +3 -3
  39. package/dist/{hasIn-DnfJcYpY.js → hasIn-BDDmuo1w.js} +1 -1
  40. package/dist/{info-VBDWY6EO-BTyzxmhr.js → info-VBDWY6EO-BIO6A8nW.js} +2 -2
  41. package/dist/{infoDiagram-HS3SLOUP-OYrX6uO3.js → infoDiagram-HS3SLOUP-CtfUf0g_.js} +9 -9
  42. package/dist/{input-CSVEkmaZ.js → input-Czatnqbz.js} +1 -1
  43. package/dist/{kanban-definition-3W4ZIXB7-DHEAKdZt.js → kanban-definition-3W4ZIXB7-C5FK4v7x.js} +3 -3
  44. package/dist/main.js +367 -183
  45. package/dist/{mermaid-BbhZNQeB.js → mermaid-CcM8GHeT.js} +29 -29
  46. package/dist/{mermaid-parser.core-ntCgyx0x.js → mermaid-parser.core-fZdPSYor.js} +8 -8
  47. package/dist/min-DAIOAwWK.js +102 -0
  48. package/dist/{mindmap-definition-VGOIOE7T-CxEUZZvY.js → mindmap-definition-VGOIOE7T-BvrQf8XZ.js} +5 -5
  49. package/dist/{packet-DYOGHKS2-BhvnpoGi.js → packet-DYOGHKS2-DDx1z7B-.js} +2 -2
  50. package/dist/pick-DfX21dj2.js +18 -0
  51. package/dist/{pie-VRWISCQL-dILuA3iG.js → pie-VRWISCQL-BgRtyDMT.js} +2 -2
  52. package/dist/{pieDiagram-ADFJNKIX-U3LrUqAS.js → pieDiagram-ADFJNKIX-DAhjFwJD.js} +10 -10
  53. package/dist/{process-output-Bekznt_B.js → process-output-CzeGyEyz.js} +2138 -2124
  54. package/dist/{radar-ZZBFDIW7-DwFrOJDj.js → radar-ZZBFDIW7-xwh47Yzn.js} +2 -2
  55. package/dist/{requirementDiagram-UZGBJVZJ-D0zpQnKC.js → requirementDiagram-UZGBJVZJ-B3nnp0VG.js} +5 -5
  56. package/dist/{sequenceDiagram-WL72ISMW-D1BJxLjH.js → sequenceDiagram-WL72ISMW-D2mpRRG2.js} +1 -1
  57. package/dist/{stateDiagram-FKZM4ZOC-B1S8jGMn.js → stateDiagram-FKZM4ZOC-QD9Wuca0.js} +8 -8
  58. package/dist/{stateDiagram-v2-4FDKWEC3-BH5ozUbc.js → stateDiagram-v2-4FDKWEC3-DnUhJ525.js} +6 -6
  59. package/dist/{toDate-B1AzlBoW.js → toDate-BxaMtnNb.js} +1 -1
  60. package/dist/{treemap-GDKQZRPO-bx2ngsgN.js → treemap-GDKQZRPO-5ZsmvXgc.js} +2 -2
  61. package/dist/{types-pwjdK009.js → types-DZvw9zQT.js} +1 -1
  62. package/dist/{useDeepCompareMemoize-CsyOnnjc.js → useDeepCompareMemoize-BOrrcIxj.js} +1 -1
  63. package/dist/{vega-component-KBJXEDZz.js → vega-component-CrVeizNZ.js} +3 -3
  64. package/dist/{xychartDiagram-PRI3JC2R-CuAZiqHS.js → xychartDiagram-PRI3JC2R-BMsB7VdF.js} +2 -2
  65. package/package.json +2 -2
  66. package/src/components/data-table/TableBottomBar.tsx +5 -1
  67. package/src/components/data-table/__tests__/filters.test.ts +304 -0
  68. package/src/components/data-table/__tests__/pagination.test.tsx +46 -132
  69. package/src/components/data-table/column-explorer-panel/column-explorer.tsx +1 -1
  70. package/src/components/data-table/filters.ts +87 -33
  71. package/src/components/data-table/pagination.tsx +189 -76
  72. package/src/components/data-table/types.ts +0 -4
  73. package/src/components/editor/Output.tsx +1 -1
  74. package/src/components/editor/actions/useNotebookActions.tsx +12 -0
  75. package/src/components/editor/cell/code/cell-editor.tsx +1 -0
  76. package/src/core/cells/__tests__/apply-transaction.test.ts +42 -0
  77. package/src/core/cells/__tests__/logs.test.ts +101 -0
  78. package/src/core/cells/logs.ts +9 -1
  79. package/src/core/codemirror/__tests__/__snapshots__/setup.test.ts.snap +4 -14
  80. package/src/core/codemirror/cells/extensions.ts +0 -4
  81. package/src/core/codemirror/keymaps/keymaps.ts +69 -2
  82. package/src/core/codemirror/language/languages/python.ts +9 -9
  83. package/src/core/codemirror/lsp/__tests__/notebook-lsp.test.ts +8 -1
  84. package/src/core/codemirror/lsp/federated-lsp.ts +2 -2
  85. package/src/core/codemirror/lsp/notebook-lsp.ts +2 -2
  86. package/src/core/codemirror/lsp/utils.ts +21 -6
  87. package/src/core/constants.ts +1 -0
  88. package/src/plugins/impl/DataTablePlugin.tsx +7 -20
  89. package/src/plugins/impl/TabsPlugin.tsx +18 -12
  90. package/src/plugins/impl/data-frames/DataFramePlugin.tsx +4 -4
  91. package/src/plugins/impl/data-frames/schema.ts +41 -9
  92. package/src/plugins/impl/data-frames/utils/operators.ts +2 -0
  93. package/src/plugins/impl/matplotlib/matplotlib-renderer.ts +16 -0
  94. package/src/plugins/impl/plotly/__tests__/PlotlyPlugin.test.tsx +50 -0
  95. package/src/plugins/impl/plotly/__tests__/selection.test.ts +82 -0
  96. package/src/plugins/impl/plotly/selection.ts +62 -3
  97. package/dist/_basePickBy-Sow3pJjS.js +0 -41
  98. package/dist/min-Ds3gG0Ff.js +0 -96
  99. package/dist/range-fJeId9Ri.js +0 -30
  100. /package/dist/{isEmpty-B7FX9wKt.js → isEmpty-D3lf6gH3.js} +0 -0
  101. /package/dist/{memoize-CSTI9eOX.js → memoize-DEvRzlwP.js} +0 -0
@@ -1,6 +1,6 @@
1
- import "./chunk-TCCFYFTB-Clbl-fTg.js";
1
+ import "./chunk-TCCFYFTB-BdE6BTq1.js";
2
2
  import "./main-XimWhSi_.js";
3
- import { n as createRadarServices, t as RadarModule } from "./chunk-TQ3KTPDO-CFkSQ30e.js";
3
+ import { n as createRadarServices, t as RadarModule } from "./chunk-TQ3KTPDO-BCXCq8f2.js";
4
4
  export {
5
5
  createRadarServices
6
6
  };
@@ -1,16 +1,16 @@
1
1
  var _a;
2
2
  import "./purify.es-hTCfRGdl.js";
3
- import { g as utils_default } from "./chunk-S3R3BYOJ-B0UOFJwq.js";
3
+ import { g as utils_default } from "./chunk-S3R3BYOJ-DVdRer7T.js";
4
4
  import { i as log, n as __export, r as __name } from "./src-DbP20yFZ.js";
5
5
  import { B as setAccTitle, C as getDiagramTitle, U as setDiagramTitle, _ as getAccDescription, a as clear, b as getConfig2, v as getAccTitle, z as setAccDescription } from "./chunk-ABZYJK2D-CZYCCtLy.js";
6
6
  import "./chunk-HN2XXSSU-DAhNp1ig.js";
7
7
  import "./chunk-CVBHYZKI-BXHgce-x.js";
8
8
  import "./chunk-ATLVNIR6-DaOzLLgN.js";
9
9
  import "./dist-BjWd_Ei9.js";
10
- import "./chunk-JA3XYJ7Z-BcPEfxk_.js";
11
- import "./chunk-JZLCHNYA-2bnLL3xL.js";
12
- import "./chunk-QXUST7PY-Ch6F5Obl.js";
13
- import { r as render, t as getRegisteredLayoutAlgorithm } from "./chunk-N4CR4FBY-CpZSuGSU.js";
10
+ import "./chunk-JA3XYJ7Z-B2BoMdpr.js";
11
+ import "./chunk-JZLCHNYA-CkHD9mQU.js";
12
+ import "./chunk-QXUST7PY-BnSZbSK7.js";
13
+ import { r as render, t as getRegisteredLayoutAlgorithm } from "./chunk-N4CR4FBY-DDeXUk3y.js";
14
14
  import { t as getDiagramElement } from "./chunk-55IACEB6-DRsSqxbU.js";
15
15
  import { t as setupViewPortForSVG } from "./chunk-QN33PNHL-B9p5ojHB.js";
16
16
  var parser = (function() {
@@ -1,6 +1,6 @@
1
1
  var _a;
2
2
  import "./purify.es-hTCfRGdl.js";
3
- import { g as utils_default, p as parseFontSize, t as ZERO_WIDTH_SPACE } from "./chunk-S3R3BYOJ-B0UOFJwq.js";
3
+ import { g as utils_default, p as parseFontSize, t as ZERO_WIDTH_SPACE } from "./chunk-S3R3BYOJ-DVdRer7T.js";
4
4
  import { i as log, r as __name, t as select_default } from "./src-DbP20yFZ.js";
5
5
  import { B as setAccTitle, C as getDiagramTitle, E as getUrl, H as setConfig2, I as sanitizeText, N as renderKatexSanitized, O as hasKatex, U as setDiagramTitle, _ as getAccDescription, a as clear, b as getConfig2, c as configureSvgSize, i as calculateMathMLDimensions, r as assignWithDepth_default, s as common_default, v as getAccTitle, y as getConfig, z as setAccDescription } from "./chunk-ABZYJK2D-CZYCCtLy.js";
6
6
  import { n as load, t as JSON_SCHEMA } from "./chunk-MI3HLSF2-AKwFNP3m.js";
@@ -1,22 +1,22 @@
1
- import { t as layout } from "./dagre-QVd-lCXU.js";
2
- import { t as Graph } from "./graphlib-BV1_gi0C.js";
1
+ import { t as layout } from "./dagre-BLW2E2fh.js";
2
+ import { t as Graph } from "./graphlib-Cr691-na.js";
3
3
  import "./purify.es-hTCfRGdl.js";
4
4
  import { _ as basis_default } from "./step-qd10PbTJ.js";
5
5
  import { t as line_default } from "./line-PAEmCpyD.js";
6
- import { g as utils_default } from "./chunk-S3R3BYOJ-B0UOFJwq.js";
6
+ import { g as utils_default } from "./chunk-S3R3BYOJ-DVdRer7T.js";
7
7
  import { i as log, r as __name, t as select_default } from "./src-DbP20yFZ.js";
8
8
  import { E as getUrl, b as getConfig2, c as configureSvgSize, s as common_default } from "./chunk-ABZYJK2D-CZYCCtLy.js";
9
9
  import "./chunk-HN2XXSSU-DAhNp1ig.js";
10
10
  import "./chunk-CVBHYZKI-BXHgce-x.js";
11
11
  import "./chunk-ATLVNIR6-DaOzLLgN.js";
12
12
  import "./dist-BjWd_Ei9.js";
13
- import "./chunk-JA3XYJ7Z-BcPEfxk_.js";
14
- import "./chunk-JZLCHNYA-2bnLL3xL.js";
15
- import "./chunk-QXUST7PY-Ch6F5Obl.js";
16
- import "./chunk-N4CR4FBY-CpZSuGSU.js";
13
+ import "./chunk-JA3XYJ7Z-B2BoMdpr.js";
14
+ import "./chunk-JZLCHNYA-CkHD9mQU.js";
15
+ import "./chunk-QXUST7PY-BnSZbSK7.js";
16
+ import "./chunk-N4CR4FBY-DDeXUk3y.js";
17
17
  import "./chunk-55IACEB6-DRsSqxbU.js";
18
18
  import "./chunk-QN33PNHL-B9p5ojHB.js";
19
- import { i as styles_default, n as stateDiagram_default, t as StateDB } from "./chunk-DI55MBZ5-DITY3EyP.js";
19
+ import { i as styles_default, n as stateDiagram_default, t as StateDB } from "./chunk-DI55MBZ5-CYNE3N2j.js";
20
20
  var drawStartState = /* @__PURE__ */ __name((e) => e.append("circle").attr("class", "start-state").attr("r", getConfig2().state.sizeUnit).attr("cx", getConfig2().state.padding + getConfig2().state.sizeUnit).attr("cy", getConfig2().state.padding + getConfig2().state.sizeUnit), "drawStartState"), drawDivider = /* @__PURE__ */ __name((e) => e.append("line").style("stroke", "grey").style("stroke-dasharray", "3").attr("x1", getConfig2().state.textHeight).attr("class", "divider").attr("x2", getConfig2().state.textHeight * 2).attr("y1", 0).attr("y2", 0), "drawDivider"), drawSimpleState = /* @__PURE__ */ __name((e, h) => {
21
21
  let g = e.append("text").attr("x", 2 * getConfig2().state.padding).attr("y", getConfig2().state.textHeight + 2 * getConfig2().state.padding).attr("font-size", getConfig2().state.fontSize).attr("class", "state-title").text(h.id), _ = g.node().getBBox();
22
22
  return e.insert("rect", ":first-child").attr("x", getConfig2().state.padding).attr("y", getConfig2().state.padding).attr("width", _.width + 2 * getConfig2().state.padding).attr("height", _.height + 2 * getConfig2().state.padding).attr("rx", getConfig2().state.radius), g;
@@ -1,18 +1,18 @@
1
1
  import "./purify.es-hTCfRGdl.js";
2
- import "./chunk-S3R3BYOJ-B0UOFJwq.js";
2
+ import "./chunk-S3R3BYOJ-DVdRer7T.js";
3
3
  import { r as __name } from "./src-DbP20yFZ.js";
4
4
  import "./chunk-ABZYJK2D-CZYCCtLy.js";
5
5
  import "./chunk-HN2XXSSU-DAhNp1ig.js";
6
6
  import "./chunk-CVBHYZKI-BXHgce-x.js";
7
7
  import "./chunk-ATLVNIR6-DaOzLLgN.js";
8
8
  import "./dist-BjWd_Ei9.js";
9
- import "./chunk-JA3XYJ7Z-BcPEfxk_.js";
10
- import "./chunk-JZLCHNYA-2bnLL3xL.js";
11
- import "./chunk-QXUST7PY-Ch6F5Obl.js";
12
- import "./chunk-N4CR4FBY-CpZSuGSU.js";
9
+ import "./chunk-JA3XYJ7Z-B2BoMdpr.js";
10
+ import "./chunk-JZLCHNYA-CkHD9mQU.js";
11
+ import "./chunk-QXUST7PY-BnSZbSK7.js";
12
+ import "./chunk-N4CR4FBY-DDeXUk3y.js";
13
13
  import "./chunk-55IACEB6-DRsSqxbU.js";
14
14
  import "./chunk-QN33PNHL-B9p5ojHB.js";
15
- import { i as styles_default, n as stateDiagram_default, r as stateRenderer_v3_unified_default, t as StateDB } from "./chunk-DI55MBZ5-DITY3EyP.js";
15
+ import { i as styles_default, n as stateDiagram_default, r as stateRenderer_v3_unified_default, t as StateDB } from "./chunk-DI55MBZ5-CYNE3N2j.js";
16
16
  var diagram = {
17
17
  parser: stateDiagram_default,
18
18
  get db() {
@@ -5,7 +5,7 @@ import { t as __commonJSMin } from "./chunk-BNovOVIE.js";
5
5
  import { _ as Logger } from "./button-D1C3g5GI.js";
6
6
  import { t as require_compiler_runtime } from "./compiler-runtime-CEbnTgxf.js";
7
7
  import { u as createLucideIcon } from "./dist-CTtLBPLZ.js";
8
- import { r as KnownQueryParams } from "./constants-CvyfaCvs.js";
8
+ import { r as KnownQueryParams } from "./constants-CcdcOQyC.js";
9
9
  import { f as waitFor, p as isIslands, u as store, y as atom } from "./useTheme-CzwDokKe.js";
10
10
  var CircleQuestionMark = createLucideIcon("circle-question-mark", [
11
11
  ["circle", {
@@ -1,6 +1,6 @@
1
- import "./chunk-TCCFYFTB-Clbl-fTg.js";
1
+ import "./chunk-TCCFYFTB-BdE6BTq1.js";
2
2
  import "./main-XimWhSi_.js";
3
- import { n as createTreemapServices, t as TreemapModule } from "./chunk-B2363JML-Br0eA2T3.js";
3
+ import { n as createTreemapServices, t as TreemapModule } from "./chunk-B2363JML-72CRxZbk.js";
4
4
  export {
5
5
  createTreemapServices
6
6
  };
@@ -4,7 +4,7 @@ import { t as require_react } from "./react-DA-nE2FX.js";
4
4
  import { t as require_compiler_runtime } from "./compiler-runtime-CEbnTgxf.js";
5
5
  import { u as createLucideIcon } from "./dist-CTtLBPLZ.js";
6
6
  import { t as require_jsx_runtime } from "./jsx-runtime-9hcJiI23.js";
7
- import { n as Constants } from "./constants-CvyfaCvs.js";
7
+ import { n as Constants } from "./constants-CcdcOQyC.js";
8
8
  var Pencil = createLucideIcon("pencil", [["path", {
9
9
  d: "M21.174 6.812a1 1 0 0 0-3.986-3.987L3.842 16.174a2 2 0 0 0-.5.83l-1.321 4.352a.5.5 0 0 0 .623.622l4.353-1.32a2 2 0 0 0 .83-.497z",
10
10
  key: "1a8usu"
@@ -2,7 +2,7 @@ import { s as __toESM } from "./chunk-BNovOVIE.js";
2
2
  import { g as cn, r as cva } from "./button-D1C3g5GI.js";
3
3
  import { t as require_react } from "./react-DA-nE2FX.js";
4
4
  import { t as require_compiler_runtime } from "./compiler-runtime-CEbnTgxf.js";
5
- import { t as toDate } from "./toDate-B1AzlBoW.js";
5
+ import { t as toDate } from "./toDate-BxaMtnNb.js";
6
6
  import { t as require_jsx_runtime } from "./jsx-runtime-9hcJiI23.js";
7
7
  import { C as dequal } from "./useTheme-CzwDokKe.js";
8
8
  import { i as tableFromIPC } from "./loader-ZFbGsMN1.js";
@@ -2,16 +2,16 @@ import { s as __toESM } from "./chunk-BNovOVIE.js";
2
2
  import { _ as Logger, c as Objects, g as cn, h as Events } from "./button-D1C3g5GI.js";
3
3
  import { t as require_react } from "./react-DA-nE2FX.js";
4
4
  import { t as require_compiler_runtime } from "./compiler-runtime-CEbnTgxf.js";
5
- import { c as asRemoteURL, g as CircleQuestionMark } from "./toDate-B1AzlBoW.js";
5
+ import { c as asRemoteURL, g as CircleQuestionMark } from "./toDate-BxaMtnNb.js";
6
6
  import "./react-dom-D5FDLRUB.js";
7
7
  import { t as require_jsx_runtime } from "./jsx-runtime-9hcJiI23.js";
8
8
  import "./zod-W5ZEjzaE.js";
9
9
  import { n as ErrorBanner } from "./error-banner-B_ioHva3.js";
10
10
  import { t as Tooltip } from "./tooltip-DwNnFsxZ.js";
11
- import { i as debounce_default } from "./constants-CvyfaCvs.js";
11
+ import { i as debounce_default } from "./constants-CcdcOQyC.js";
12
12
  import { n as useTheme, w as useEvent_default } from "./useTheme-CzwDokKe.js";
13
13
  import { s as uniq } from "./arrays-beUWo8RF.js";
14
- import { a as AlertTitle, n as arrow, o as isValid, r as Alert, t as useDeepCompareMemoize } from "./useDeepCompareMemoize-CsyOnnjc.js";
14
+ import { a as AlertTitle, n as arrow, o as isValid, r as Alert, t as useDeepCompareMemoize } from "./useDeepCompareMemoize-BOrrcIxj.js";
15
15
  import { n as formats } from "./vega-loader.browser-DqEcFOPD.js";
16
16
  import { a as getContainerWidth, n as vegaLoadData, s as tooltipHandler } from "./loader-ZFbGsMN1.js";
17
17
  import { t as useAsyncData } from "./useAsyncData-BL98MPIy.js";
@@ -5,13 +5,13 @@ import { n as ordinal } from "./ordinal-D7fa8Sey.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-PAEmCpyD.js";
8
- import { i as cleanAndMerge } from "./chunk-S3R3BYOJ-B0UOFJwq.js";
8
+ import { i as cleanAndMerge } from "./chunk-S3R3BYOJ-DVdRer7T.js";
9
9
  import { n as initRange } from "./init-Cge3yl4r.js";
10
10
  import { i as log, r as __name } from "./src-DbP20yFZ.js";
11
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-CZYCCtLy.js";
12
12
  import { t as selectSvgElement } from "./chunk-EXTU4WIE-jUPSAk3i.js";
13
13
  import "./dist-BjWd_Ei9.js";
14
- import { t as computeDimensionOfText } from "./chunk-JA3XYJ7Z-BcPEfxk_.js";
14
+ import { t as computeDimensionOfText } from "./chunk-JA3XYJ7Z-B2BoMdpr.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;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@marimo-team/islands",
3
- "version": "0.23.2-dev25",
3
+ "version": "0.23.2-dev28",
4
4
  "main": "dist/main.js",
5
5
  "types": "dist/index.d.ts",
6
6
  "type": "module",
@@ -54,7 +54,7 @@
54
54
  "@lezer/lr": "^1.4.8",
55
55
  "@lezer/markdown": "^1.6.3",
56
56
  "@lezer/python": "^1.1.18",
57
- "@marimo-team/codemirror-ai": "^0.3.5",
57
+ "@marimo-team/codemirror-ai": "^0.3.7",
58
58
  "@marimo-team/codemirror-languageserver": "^1.16.12",
59
59
  "@marimo-team/codemirror-mcp": "^0.1.5",
60
60
  "@marimo-team/codemirror-sql": "^0.2.4",
@@ -142,7 +142,11 @@ export const TableBottomBar = <TData,>({
142
142
 
143
143
  return (
144
144
  <span>
145
- {prettifyRowColumnCount(table.getRowCount(), totalColumns, locale)}
145
+ {prettifyRowColumnCount({
146
+ numRows: table.getRowCount(),
147
+ totalColumns,
148
+ locale,
149
+ })}
146
150
  </span>
147
151
  );
148
152
  };
@@ -0,0 +1,304 @@
1
+ /* Copyright 2026 Marimo. All rights reserved. */
2
+ import { describe, expect, it } from "vitest";
3
+ import {
4
+ filterToFilterCondition,
5
+ filtersToFilterGroup,
6
+ Filter,
7
+ } from "../filters";
8
+ import {
9
+ FilterConditionSchema,
10
+ FilterGroupSchema,
11
+ } from "@/plugins/impl/data-frames/schema";
12
+
13
+ describe("filterToFilterCondition", () => {
14
+ it("returns empty array for undefined filter", () => {
15
+ expect(filterToFilterCondition("col", undefined)).toEqual([]);
16
+ });
17
+
18
+ it("handles is_null filter", () => {
19
+ const result = filterToFilterCondition(
20
+ "col",
21
+ Filter.number({ operator: "is_null" }),
22
+ );
23
+ expect(result).toEqual([
24
+ {
25
+ column_id: "col",
26
+ operator: "is_null",
27
+ value: undefined,
28
+ type: "condition",
29
+ negate: false,
30
+ },
31
+ ]);
32
+ });
33
+
34
+ it("handles is_not_null filter", () => {
35
+ const result = filterToFilterCondition(
36
+ "col",
37
+ Filter.number({ operator: "is_not_null" }),
38
+ );
39
+ expect(result).toEqual([
40
+ {
41
+ column_id: "col",
42
+ operator: "is_not_null",
43
+ value: undefined,
44
+ type: "condition",
45
+ negate: false,
46
+ },
47
+ ]);
48
+ });
49
+
50
+ it("handles number filter with min only", () => {
51
+ const result = filterToFilterCondition("age", Filter.number({ min: 18 }));
52
+ expect(result).toHaveLength(1);
53
+ expect(result[0]).toMatchObject({
54
+ column_id: "age",
55
+ operator: ">=",
56
+ value: 18,
57
+ type: "condition",
58
+ negate: false,
59
+ });
60
+ });
61
+
62
+ it("handles number filter with max only", () => {
63
+ const result = filterToFilterCondition("age", Filter.number({ max: 65 }));
64
+ expect(result).toHaveLength(1);
65
+ expect(result[0]).toMatchObject({
66
+ column_id: "age",
67
+ operator: "<=",
68
+ value: 65,
69
+ type: "condition",
70
+ negate: false,
71
+ });
72
+ });
73
+
74
+ it("handles number filter with min and max", () => {
75
+ const result = filterToFilterCondition(
76
+ "age",
77
+ Filter.number({ min: 18, max: 65 }),
78
+ );
79
+ expect(result).toHaveLength(2);
80
+ expect(result[0]).toMatchObject({ operator: ">=", value: 18 });
81
+ expect(result[1]).toMatchObject({ operator: "<=", value: 65 });
82
+ });
83
+
84
+ it("handles text filter", () => {
85
+ const result = filterToFilterCondition(
86
+ "name",
87
+ Filter.text({ text: "foo", operator: "contains" }),
88
+ );
89
+ expect(result).toEqual([
90
+ {
91
+ column_id: "name",
92
+ operator: "contains",
93
+ value: "foo",
94
+ type: "condition",
95
+ negate: false,
96
+ },
97
+ ]);
98
+ });
99
+
100
+ it("handles boolean true filter", () => {
101
+ const result = filterToFilterCondition(
102
+ "active",
103
+ Filter.boolean({ value: true }),
104
+ );
105
+ expect(result).toEqual([
106
+ {
107
+ column_id: "active",
108
+ operator: "is_true",
109
+ value: undefined,
110
+ type: "condition",
111
+ negate: false,
112
+ },
113
+ ]);
114
+ });
115
+
116
+ it("handles boolean false filter", () => {
117
+ const result = filterToFilterCondition(
118
+ "active",
119
+ Filter.boolean({ value: false }),
120
+ );
121
+ expect(result).toEqual([
122
+ {
123
+ column_id: "active",
124
+ operator: "is_false",
125
+ value: undefined,
126
+ type: "condition",
127
+ negate: false,
128
+ },
129
+ ]);
130
+ });
131
+
132
+ it("handles select in filter", () => {
133
+ const result = filterToFilterCondition(
134
+ "status",
135
+ Filter.select({ options: ["a", "b"], operator: "in" }),
136
+ );
137
+ expect(result).toEqual([
138
+ {
139
+ column_id: "status",
140
+ operator: "in",
141
+ value: ["a", "b"],
142
+ type: "condition",
143
+ negate: false,
144
+ },
145
+ ]);
146
+ });
147
+
148
+ it("handles date filter with min and max", () => {
149
+ const min = new Date("2024-01-01");
150
+ const max = new Date("2024-12-31");
151
+ const result = filterToFilterCondition(
152
+ "created",
153
+ Filter.date({ min, max }),
154
+ );
155
+ expect(result).toHaveLength(2);
156
+ expect(result[0]).toMatchObject({
157
+ operator: ">=",
158
+ value: min.toISOString(),
159
+ });
160
+ expect(result[1]).toMatchObject({
161
+ operator: "<=",
162
+ value: max.toISOString(),
163
+ });
164
+ });
165
+
166
+ it("every condition has type and negate fields", () => {
167
+ const result = filterToFilterCondition(
168
+ "col",
169
+ Filter.number({ min: 1, max: 10 }),
170
+ );
171
+ for (const condition of result) {
172
+ expect(condition).toHaveProperty("type", "condition");
173
+ expect(condition).toHaveProperty("negate", false);
174
+ }
175
+ });
176
+ });
177
+
178
+ describe("filtersToFilterGroup", () => {
179
+ it("returns empty AND group for no filters", () => {
180
+ const result = filtersToFilterGroup([]);
181
+ expect(result).toEqual({
182
+ type: "group",
183
+ operator: "and",
184
+ children: [],
185
+ negate: false,
186
+ });
187
+ });
188
+
189
+ it("wraps single filter in AND group", () => {
190
+ const result = filtersToFilterGroup([
191
+ { id: "age", value: Filter.number({ min: 18 }) },
192
+ ]);
193
+ expect(result.type).toBe("group");
194
+ expect(result.operator).toBe("and");
195
+ expect(result.negate).toBe(false);
196
+ expect(result.children).toHaveLength(1);
197
+ });
198
+
199
+ it("wraps multiple filters in AND group", () => {
200
+ const result = filtersToFilterGroup([
201
+ { id: "age", value: Filter.number({ min: 18 }) },
202
+ { id: "name", value: Filter.text({ text: "foo", operator: "contains" }) },
203
+ ]);
204
+ expect(result.children).toHaveLength(2);
205
+ expect(result.operator).toBe("and");
206
+ });
207
+
208
+ it("flattens multi-condition filters", () => {
209
+ const result = filtersToFilterGroup([
210
+ { id: "age", value: Filter.number({ min: 18, max: 65 }) },
211
+ ]);
212
+ // min + max = 2 conditions
213
+ expect(result.children).toHaveLength(2);
214
+ });
215
+ });
216
+
217
+ describe("schema validation", () => {
218
+ it("FilterConditionSchema accepts valid condition", () => {
219
+ const result = FilterConditionSchema.safeParse({
220
+ column_id: "age",
221
+ operator: ">=",
222
+ value: 18,
223
+ });
224
+ expect(result.success).toBe(true);
225
+ if (result.success) {
226
+ expect(result.data.type).toBe("condition");
227
+ expect(result.data.negate).toBe(false);
228
+ }
229
+ });
230
+
231
+ it("FilterConditionSchema defaults type and negate", () => {
232
+ const result = FilterConditionSchema.safeParse({
233
+ column_id: "age",
234
+ operator: "==",
235
+ value: 5,
236
+ });
237
+ expect(result.success).toBe(true);
238
+ if (result.success) {
239
+ expect(result.data.type).toBe("condition");
240
+ expect(result.data.negate).toBe(false);
241
+ }
242
+ });
243
+
244
+ it("FilterConditionSchema accepts negate=true", () => {
245
+ const result = FilterConditionSchema.safeParse({
246
+ column_id: "age",
247
+ operator: "==",
248
+ value: 5,
249
+ negate: true,
250
+ });
251
+ expect(result.success).toBe(true);
252
+ if (result.success) {
253
+ expect(result.data.negate).toBe(true);
254
+ }
255
+ });
256
+
257
+ it("FilterGroupSchema accepts valid group", () => {
258
+ const result = FilterGroupSchema.safeParse({
259
+ type: "group",
260
+ operator: "and",
261
+ children: [{ column_id: "age", operator: ">=", value: 18 }],
262
+ });
263
+ expect(result.success).toBe(true);
264
+ });
265
+
266
+ it("FilterGroupSchema accepts nested groups", () => {
267
+ const result = FilterGroupSchema.safeParse({
268
+ type: "group",
269
+ operator: "or",
270
+ children: [
271
+ {
272
+ type: "group",
273
+ operator: "and",
274
+ children: [
275
+ { column_id: "a", operator: "==", value: 1 },
276
+ { column_id: "b", operator: ">", value: 2 },
277
+ ],
278
+ },
279
+ { column_id: "c", operator: "==", value: 3 },
280
+ ],
281
+ });
282
+ expect(result.success).toBe(true);
283
+ });
284
+
285
+ it("FilterGroupSchema rejects invalid operator", () => {
286
+ const result = FilterGroupSchema.safeParse({
287
+ type: "group",
288
+ operator: "xor",
289
+ children: [],
290
+ });
291
+ expect(result.success).toBe(false);
292
+ });
293
+
294
+ it("FilterGroupSchema defaults fields", () => {
295
+ const result = FilterGroupSchema.safeParse({});
296
+ expect(result.success).toBe(true);
297
+ if (result.success) {
298
+ expect(result.data.type).toBe("group");
299
+ expect(result.data.operator).toBe("and");
300
+ expect(result.data.children).toEqual([]);
301
+ expect(result.data.negate).toBe(false);
302
+ }
303
+ });
304
+ });