@yudaocode/univer-sheets-ui 1.6.205 → 1.6.207

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/lib/cjs/index.js CHANGED
@@ -121,6 +121,7 @@ function resolveSheetsUIFeatures(raw) {
121
121
  fieldDrag: raw?.fieldDrag ?? true,
122
122
  syntaxSelector: raw?.syntaxSelector ?? true,
123
123
  advancedCellBinding: raw?.advancedCellBinding ?? true,
124
+ contextualCellBinding: Boolean(raw?.contextualCellBinding),
124
125
  builtinPreviewModal: raw?.builtinPreviewModal ?? true
125
126
  };
126
127
  }
@@ -314,7 +315,9 @@ var enUS = {
314
315
  listExpandBadge: "List Expand",
315
316
  emptyBoundCells: "No dataset bindings found (or data already expanded; press Ctrl+Z to restore template).",
316
317
  kindList: "Vertical List",
317
- kindScalar: "Scalar Value"
318
+ kindCrossTab: "Cross-Tab Horizontal",
319
+ kindScalar: "Scalar Value",
320
+ hiddenSheetBadge: "Hidden"
318
321
  },
319
322
  inspector: {
320
323
  activeCellLabel: "Active Cell: ",
@@ -329,6 +332,7 @@ var enUS = {
329
332
  subTabAnalytics: "Analytics",
330
333
  subTabFill: "Form Fill",
331
334
  datasetSectionTitle: "Dataset & Cross-Tab Expansion",
335
+ mergedCellExpandHint: "Merged cells only support vertical expansion without grouping",
332
336
  cellFilterTitle: "Cell Dataset Filter (cellFilterConditions)",
333
337
  cellFilterAddBtn: "+ Add Filter",
334
338
  cellFilterEmptyHint: "No cell-level filter configured (supports field or $param.xxx rules)",
@@ -409,7 +413,9 @@ var zhCN = {
409
413
  listExpandBadge: "\u5217\u8868\u5C55\u5F00",
410
414
  emptyBoundCells: "\u5F53\u524D\u5DE5\u4F5C\u7C3F\u6682\u65E0\u7ED1\u5B9A\u8868\u8FBE\u5F0F\uFF08\u6216\u5DF2\u5B8C\u6210\u6570\u636E\u586B\u5145\uFF0C\u6309 Ctrl+Z \u53EF\u56DE\u5230\u6A21\u677F\u6001\uFF09\u3002",
411
415
  kindList: "\u5217\u8868\u81EA\u52A8\u4E0B\u63A8",
412
- kindScalar: "\u5355\u503C\u586B\u5145"
416
+ kindCrossTab: "\u6A2A\u5411\u4EA4\u53C9\u6269\u5C55",
417
+ kindScalar: "\u5355\u503C\u586B\u5145",
418
+ hiddenSheetBadge: "\u9690\u85CF\u8868"
413
419
  },
414
420
  inspector: {
415
421
  activeCellLabel: "\u5F53\u524D\u5355\u5143\u683C\uFF1A",
@@ -424,6 +430,7 @@ var zhCN = {
424
430
  subTabAnalytics: "\u900F\u89C6",
425
431
  subTabFill: "\u586B\u62A5",
426
432
  datasetSectionTitle: "\u6570\u636E\u96C6\u4E0E\u4EA4\u53C9\u6269\u5C55",
433
+ mergedCellExpandHint: "\u5408\u5E76\u5355\u5143\u683C\u4EC5\u652F\u6301\u7EB5\u5411\u6269\u5C55\u4E14\u4E0D\u5206\u7EC4",
427
434
  cellFilterTitle: "\u5355\u5143\u683C\u6570\u636E\u8FC7\u6EE4\u6761\u4EF6 (cellFilterConditions)",
428
435
  cellFilterAddBtn: "+ \u6DFB\u52A0\u8FC7\u6EE4",
429
436
  cellFilterEmptyHint: "\u672A\u914D\u7F6E\u5355\u5143\u683C\u7EA7\u8FC7\u6EE4\u6761\u4EF6\uFF08\u652F\u6301\u6309\u5B57\u6BB5\u6216 $param.xxx \u52A8\u6001\u7B5B\u9009\uFF09",
@@ -617,14 +624,25 @@ var SheetInspectorPanel = () => {
617
624
  }
618
625
  }
619
626
  const metadata = templateService.getTemplateMetadata(unitId);
627
+ const effectiveSyntax = templateService.getPlaceholderSyntax(unitId);
628
+ const effectiveImplicitExpand = templateService.getImplicitExpand(unitId);
620
629
  const allFields = (metadata.datasets ?? []).flatMap((g) => g.fields);
621
- const boundCount = (0, import_univer_sheets2.scanWorkbookBoundCells)(workbook.save(), metadata.sampleData).length;
630
+ const boundCount = (0, import_univer_sheets2.scanWorkbookBoundCells)(workbook.save(), metadata.sampleData, {
631
+ implicitExpand: effectiveImplicitExpand
632
+ }).length;
622
633
  const printCfg = metadata.printConfig ?? {};
623
634
  const protectionCfg = metadata.protection;
624
635
  const charts = metadata.charts ?? [];
625
636
  const activeAlertRule = cellMeta.alertRules?.[0];
626
- const currentExprMatch = typeof activeCell?.v === "string" ? activeCell.v.trim().match(/^(?:\$|#)\{(#?[a-zA-Z0-9_.\[\]]+)\}$/) : null;
637
+ const currentExprMatch = typeof activeCell?.v === "string" ? activeCell.v.trim().match(/^(?:\$|#)\{(#?[\p{L}\p{N}_.\[\]-]+)\}$/u) : null;
627
638
  const currentBoundKey = currentExprMatch?.[1] ?? "";
639
+ const activeCellText = activeCell?.v == null ? "" : String(activeCell.v);
640
+ const isMergedCell = Boolean(resolvedMaster.mergeRange);
641
+ const restrictMergedExpand = features.contextualCellBinding && isMergedCell;
642
+ const isDynamicBoundCell = features.contextualCellBinding ? effectiveSyntax === "hash" ? activeCellText.includes("#{") : activeCellText.includes("${") || activeCellText.includes("#{") : true;
643
+ const showStaticAutoOption = !features.contextualCellBinding || !isDynamicBoundCell;
644
+ const hasExplicitListToken = typeof activeCell?.v === "string" && (activeCell.v.includes("${#") || activeCell.v.includes("#{#") || activeCell.v.includes("[]."));
645
+ const resolvedExpandValue = cellMeta.expand ?? (hasExplicitListToken ? "v" : effectiveImplicitExpand);
628
646
  const patchCellMeta = (patch) => {
629
647
  commandService.syncExecuteCommand(import_univer_sheets2.SetSheetCellMetaCommand.id, {
630
648
  unitId,
@@ -874,7 +892,7 @@ var SheetInspectorPanel = () => {
874
892
  /* @__PURE__ */ (0, import_jsx_runtime2.jsxs)(
875
893
  "select",
876
894
  {
877
- value: metadata.placeholderSyntax ?? "dollar",
895
+ value: effectiveSyntax,
878
896
  onChange: (e) => templateService.setTemplateMetadata(unitId, {
879
897
  ...metadata,
880
898
  placeholderSyntax: e.target.value
@@ -883,12 +901,12 @@ var SheetInspectorPanel = () => {
883
901
  /* @__PURE__ */ (0, import_jsx_runtime2.jsxs)("option", { value: "dollar", children: [
884
902
  "$",
885
903
  "{set.field}",
886
- "\uFF08\u6807\u51C6\u6A21\u677F\u8BED\u6CD5\uFF09"
904
+ "\uFF08\u7F8E\u5143\u82B1\u62EC\u53F7\u8BED\u6CD5\uFF09"
887
905
  ] }),
888
906
  /* @__PURE__ */ (0, import_jsx_runtime2.jsxs)("option", { value: "hash", children: [
889
907
  "#",
890
908
  "{set.field}",
891
- "\uFF08\u517C\u5BB9 AJ-Report / \u4E2D\u56FD\u5F0F\u62A5\u8868\uFF09"
909
+ "\uFF08\u4E95\u53F7\u82B1\u62EC\u53F7\u8BED\u6CD5\uFF09"
892
910
  ] })
893
911
  ]
894
912
  }
@@ -929,22 +947,22 @@ var SheetInspectorPanel = () => {
929
947
  }
930
948
  )
931
949
  ] }),
932
- /* @__PURE__ */ (0, import_jsx_runtime2.jsxs)("label", { className: "yudao-sheet-field-row", children: [
950
+ isDynamicBoundCell && /* @__PURE__ */ (0, import_jsx_runtime2.jsxs)("label", { className: "yudao-sheet-field-row", children: [
933
951
  /* @__PURE__ */ (0, import_jsx_runtime2.jsx)("span", { children: "\u6269\u5C55\u65B9\u5411\uFF08\u652F\u6301\u4EA4\u53C9\u8868\u6A2A\u5411\u88C2\u53D8\u5217\uFF09" }),
934
952
  /* @__PURE__ */ (0, import_jsx_runtime2.jsxs)(
935
953
  "select",
936
954
  {
937
- value: cellMeta.expand ?? "v",
955
+ value: resolvedExpandValue,
938
956
  onChange: (e) => patchCellMeta({ expand: e.target.value }),
939
957
  children: [
940
958
  /* @__PURE__ */ (0, import_jsx_runtime2.jsx)("option", { value: "v", children: "\u7EB5\u5411\u5411\u4E0B\u6269\u5C55\u884C (List)" }),
941
- /* @__PURE__ */ (0, import_jsx_runtime2.jsx)("option", { value: "h", children: "\u6A2A\u5411\u5411\u53F3\u6269\u5C55\u5217 (Cross-Tab \u4EA4\u53C9\u8868)" }),
942
- features.advancedCellBinding && /* @__PURE__ */ (0, import_jsx_runtime2.jsx)("option", { value: "none", children: "\u4E0D\u6269\u5C55\uFF08\u9759\u6001\u5355\u503C\u66FF\u6362\uFF09" })
959
+ /* @__PURE__ */ (0, import_jsx_runtime2.jsx)("option", { value: "h", disabled: restrictMergedExpand && resolvedExpandValue !== "h", children: "\u6A2A\u5411\u5411\u53F3\u6269\u5C55\u5217 (Cross-Tab \u4EA4\u53C9\u8868)" }),
960
+ (features.advancedCellBinding || resolvedExpandValue === "none") && /* @__PURE__ */ (0, import_jsx_runtime2.jsx)("option", { value: "none", children: "\u4E0D\u6269\u5C55\uFF08\u9759\u6001\u5355\u503C\u66FF\u6362\uFF09" })
943
961
  ]
944
962
  }
945
963
  )
946
964
  ] }),
947
- features.advancedCellBinding && /* @__PURE__ */ (0, import_jsx_runtime2.jsxs)(import_jsx_runtime2.Fragment, { children: [
965
+ features.advancedCellBinding && isDynamicBoundCell && /* @__PURE__ */ (0, import_jsx_runtime2.jsxs)(import_jsx_runtime2.Fragment, { children: [
948
966
  /* @__PURE__ */ (0, import_jsx_runtime2.jsxs)("div", { style: { display: "grid", gridTemplateColumns: "1fr 1fr", gap: 6 }, children: [
949
967
  /* @__PURE__ */ (0, import_jsx_runtime2.jsxs)("label", { className: "yudao-sheet-field-row", children: [
950
968
  /* @__PURE__ */ (0, import_jsx_runtime2.jsx)("span", { children: "\u5DE6\u7236\u683C (leftParentCell)" }),
@@ -1144,18 +1162,20 @@ var SheetInspectorPanel = () => {
1144
1162
  ] })
1145
1163
  ] }),
1146
1164
  /* @__PURE__ */ (0, import_jsx_runtime2.jsxs)("div", { style: { display: "flex", flexDirection: "column", gap: 5 }, children: [
1147
- /* @__PURE__ */ (0, import_jsx_runtime2.jsxs)("label", { style: { display: "flex", alignItems: "center", gap: 6, cursor: "pointer" }, children: [
1165
+ isDynamicBoundCell && /* @__PURE__ */ (0, import_jsx_runtime2.jsxs)("label", { style: { display: "flex", alignItems: "center", gap: 6, cursor: "pointer" }, children: [
1148
1166
  /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(
1149
1167
  "input",
1150
1168
  {
1151
1169
  type: "checkbox",
1152
1170
  checked: Boolean(cellMeta.group),
1171
+ disabled: restrictMergedExpand && !cellMeta.group,
1153
1172
  onChange: (e) => patchCellMeta({ group: e.target.checked })
1154
1173
  }
1155
1174
  ),
1156
1175
  /* @__PURE__ */ (0, import_jsx_runtime2.jsx)("span", { children: "\u76F8\u90BB\u76F8\u540C\u5206\u7EC4\u503C\u81EA\u52A8\u7EB5\u5411\u5408\u5E76\u5355\u5143\u683C (Group)" })
1157
1176
  ] }),
1158
- features.advancedCellBinding && /* @__PURE__ */ (0, import_jsx_runtime2.jsxs)("label", { style: { display: "flex", alignItems: "center", gap: 6, cursor: "pointer" }, children: [
1177
+ isDynamicBoundCell && restrictMergedExpand && /* @__PURE__ */ (0, import_jsx_runtime2.jsx)("div", { style: { fontSize: 11, color: "#7D8698" }, children: t("yudaoSheets.inspector.mergedCellExpandHint") }),
1178
+ features.advancedCellBinding && isDynamicBoundCell && /* @__PURE__ */ (0, import_jsx_runtime2.jsxs)("label", { style: { display: "flex", alignItems: "center", gap: 6, cursor: "pointer" }, children: [
1159
1179
  /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(
1160
1180
  "input",
1161
1181
  {
@@ -1166,18 +1186,20 @@ var SheetInspectorPanel = () => {
1166
1186
  ),
1167
1187
  /* @__PURE__ */ (0, import_jsx_runtime2.jsx)("span", { children: "\u81EA\u52A8\u751F\u6210\u9012\u589E\u5E8F\u53F7 (=SEQ / \u6309\u7EC4\u91CD\u6392)" })
1168
1188
  ] }),
1169
- /* @__PURE__ */ (0, import_jsx_runtime2.jsxs)("label", { style: { display: "flex", alignItems: "center", gap: 6, cursor: "pointer" }, children: [
1189
+ showStaticAutoOption && /* @__PURE__ */ (0, import_jsx_runtime2.jsxs)("label", { style: { display: "flex", alignItems: "center", gap: 6, cursor: "pointer" }, children: [
1170
1190
  /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(
1171
1191
  "input",
1172
1192
  {
1173
1193
  type: "checkbox",
1174
- checked: Boolean(cellMeta.auto || activeCell?.custom?.auto),
1175
- onChange: (e) => patchCellMeta({ auto: e.target.checked || void 0 })
1194
+ checked: Boolean(cellMeta.auto),
1195
+ onChange: (e) => patchCellMeta({
1196
+ auto: templateService.getCellMetaLayout(unitId) === "flat" ? e.target.checked : e.target.checked || void 0
1197
+ })
1176
1198
  }
1177
1199
  ),
1178
1200
  /* @__PURE__ */ (0, import_jsx_runtime2.jsx)("span", { children: "\u4F34\u968F\u540C\u884C\u5217\u8868\u81EA\u52A8\u590D\u5236\u6269\u5C55 (auto)" })
1179
1201
  ] }),
1180
- features.advancedCellBinding && /* @__PURE__ */ (0, import_jsx_runtime2.jsxs)("label", { style: { display: "flex", alignItems: "center", gap: 6, cursor: "pointer" }, children: [
1202
+ features.advancedCellBinding && isDynamicBoundCell && /* @__PURE__ */ (0, import_jsx_runtime2.jsxs)("label", { style: { display: "flex", alignItems: "center", gap: 6, cursor: "pointer" }, children: [
1181
1203
  /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(
1182
1204
  "input",
1183
1205
  {
@@ -1312,7 +1334,7 @@ var SheetInspectorPanel = () => {
1312
1334
  )
1313
1335
  ] })
1314
1336
  ] }),
1315
- /* @__PURE__ */ (0, import_jsx_runtime2.jsxs)(
1337
+ isDynamicBoundCell && (!features.contextualCellBinding || resolvedExpandValue !== "h") && /* @__PURE__ */ (0, import_jsx_runtime2.jsxs)(
1316
1338
  "div",
1317
1339
  {
1318
1340
  style: {
@@ -3647,20 +3669,22 @@ var SheetLeftSidebar = () => {
3647
3669
  }
3648
3670
  void rev;
3649
3671
  void metaVersion;
3650
- const metadata = templateService.getTemplateMetadata(workbook.getUnitId());
3672
+ const unitId = workbook.getUnitId();
3673
+ const metadata = templateService.getTemplateMetadata(unitId);
3674
+ const effectiveSyntax = templateService.getPlaceholderSyntax(unitId);
3675
+ const effectiveImplicitExpand = templateService.getImplicitExpand(unitId);
3651
3676
  const datasets = metadata.datasets ?? [];
3652
- const boundCells = (0, import_univer_sheets3.scanWorkbookBoundCells)(workbook.save(), metadata.sampleData).filter((item) => {
3653
- const sh = workbook.getSheetBySheetId(item.sheetId);
3654
- return sh ? !sh.isSheetHidden() : true;
3677
+ const boundCells = (0, import_univer_sheets3.scanWorkbookBoundCells)(workbook.save(), metadata.sampleData, {
3678
+ implicitExpand: effectiveImplicitExpand
3655
3679
  });
3656
3680
  const handleJumpToCell = (item) => {
3657
3681
  try {
3658
- const unitId = workbook.getUnitId();
3682
+ const unitId2 = workbook.getUnitId();
3659
3683
  const targetSheet = workbook.getSheetBySheetId(item.sheetId);
3660
3684
  if (!targetSheet || targetSheet.isSheetHidden()) return;
3661
3685
  if (workbook.getActiveSheet()?.getSheetId() !== item.sheetId) {
3662
3686
  commandService.syncExecuteCommand(import_sheets2.SetWorksheetActiveOperation.id, {
3663
- unitId,
3687
+ unitId: unitId2,
3664
3688
  subUnitId: item.sheetId
3665
3689
  });
3666
3690
  }
@@ -3675,7 +3699,7 @@ var SheetLeftSidebar = () => {
3675
3699
  endColumn: master.col
3676
3700
  };
3677
3701
  const isMerged = Boolean(master.mergeRange);
3678
- selectionService.setSelections(unitId, item.sheetId, [
3702
+ selectionService.setSelections(unitId2, item.sheetId, [
3679
3703
  {
3680
3704
  range: selRange,
3681
3705
  primary: {
@@ -3692,7 +3716,7 @@ var SheetLeftSidebar = () => {
3692
3716
  }
3693
3717
  ]);
3694
3718
  commandService.syncExecuteCommand(import_sheets2.ScrollToCellOperation.id, {
3695
- unitId,
3719
+ unitId: unitId2,
3696
3720
  range: selRange
3697
3721
  });
3698
3722
  } catch {
@@ -3794,7 +3818,7 @@ var SheetLeftSidebar = () => {
3794
3818
  e.dataTransfer.setData("application/x-yudao-sheet-field", fieldExpr);
3795
3819
  e.dataTransfer.setData(
3796
3820
  "text/plain",
3797
- metadata.placeholderSyntax === "hash" ? `#{${fieldExpr.replace(/^#/, "")}}` : fieldExpr
3821
+ fieldExpr.startsWith("${") || fieldExpr.startsWith("#{") ? fieldExpr : effectiveSyntax === "hash" ? `#{${fieldExpr}}` : `\${${fieldExpr}}`
3798
3822
  );
3799
3823
  e.dataTransfer.effectAllowed = "copy";
3800
3824
  },
@@ -3814,39 +3838,50 @@ var SheetLeftSidebar = () => {
3814
3838
  },
3815
3839
  group.id || group.name
3816
3840
  ))
3817
- ] }) : /* @__PURE__ */ (0, import_jsx_runtime3.jsx)("div", { className: "yudao-sheet-left-body", children: boundCells.length === 0 ? /* @__PURE__ */ (0, import_jsx_runtime3.jsx)("div", { style: { fontSize: 12, color: "#7D8698", textAlign: "center", padding: "24px 8px" }, children: t("yudaoSheets.leftSidebar.emptyBoundCells") }) : boundCells.map((item) => /* @__PURE__ */ (0, import_jsx_runtime3.jsxs)(
3818
- "div",
3819
- {
3820
- className: "yudao-sheet-section",
3821
- style: { padding: "8px 10px", cursor: "pointer", background: "#FFFFFF" },
3822
- onClick: () => handleJumpToCell(item),
3823
- children: [
3824
- /* @__PURE__ */ (0, import_jsx_runtime3.jsxs)("div", { style: { display: "flex", justifyContent: "space-between", alignItems: "center" }, children: [
3825
- /* @__PURE__ */ (0, import_jsx_runtime3.jsxs)("strong", { style: { color: "#1B1C1F", fontSize: 12 }, children: [
3826
- item.sheetName,
3827
- "!",
3828
- item.cellRef
3841
+ ] }) : /* @__PURE__ */ (0, import_jsx_runtime3.jsx)("div", { className: "yudao-sheet-left-body", children: boundCells.length === 0 ? /* @__PURE__ */ (0, import_jsx_runtime3.jsx)("div", { style: { fontSize: 12, color: "#7D8698", textAlign: "center", padding: "24px 8px" }, children: t("yudaoSheets.leftSidebar.emptyBoundCells") }) : boundCells.map((item) => {
3842
+ const isHiddenSheet = Boolean(workbook.getSheetBySheetId(item.sheetId)?.isSheetHidden());
3843
+ return /* @__PURE__ */ (0, import_jsx_runtime3.jsxs)(
3844
+ "div",
3845
+ {
3846
+ className: "yudao-sheet-section",
3847
+ style: {
3848
+ padding: "8px 10px",
3849
+ cursor: isHiddenSheet ? "not-allowed" : "pointer",
3850
+ opacity: isHiddenSheet ? 0.72 : 1,
3851
+ background: "#FFFFFF"
3852
+ },
3853
+ onClick: () => handleJumpToCell(item),
3854
+ children: [
3855
+ /* @__PURE__ */ (0, import_jsx_runtime3.jsxs)("div", { style: { display: "flex", justifyContent: "space-between", alignItems: "center" }, children: [
3856
+ /* @__PURE__ */ (0, import_jsx_runtime3.jsxs)("strong", { style: { color: "#1B1C1F", fontSize: 12 }, children: [
3857
+ item.sheetName,
3858
+ "!",
3859
+ item.cellRef
3860
+ ] }),
3861
+ /* @__PURE__ */ (0, import_jsx_runtime3.jsxs)(
3862
+ "span",
3863
+ {
3864
+ style: {
3865
+ fontSize: 10,
3866
+ fontWeight: 500,
3867
+ padding: "1px 6px",
3868
+ borderRadius: 999,
3869
+ background: item.kind === "list" || item.kind === "crossTab" ? "#F3F5FF" : "#EEEFF1",
3870
+ color: item.kind === "list" || item.kind === "crossTab" ? "#2C53F1" : "#4E5565"
3871
+ },
3872
+ children: [
3873
+ isHiddenSheet ? `${t("yudaoSheets.leftSidebar.hiddenSheetBadge")} \xB7 ` : "",
3874
+ item.kind === "crossTab" ? t("yudaoSheets.leftSidebar.kindCrossTab") : item.kind === "list" ? t("yudaoSheets.leftSidebar.kindList") : t("yudaoSheets.leftSidebar.kindScalar")
3875
+ ]
3876
+ }
3877
+ )
3829
3878
  ] }),
3830
- /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(
3831
- "span",
3832
- {
3833
- style: {
3834
- fontSize: 10,
3835
- fontWeight: 500,
3836
- padding: "1px 6px",
3837
- borderRadius: 999,
3838
- background: item.kind === "list" ? "#F3F5FF" : "#EEEFF1",
3839
- color: item.kind === "list" ? "#2C53F1" : "#4E5565"
3840
- },
3841
- children: item.kind === "list" ? t("yudaoSheets.leftSidebar.kindList") : t("yudaoSheets.leftSidebar.kindScalar")
3842
- }
3843
- )
3844
- ] }),
3845
- /* @__PURE__ */ (0, import_jsx_runtime3.jsx)("code", { style: { fontSize: 11, color: "#7D8698", wordBreak: "break-all" }, children: item.rawText })
3846
- ]
3847
- },
3848
- `${item.sheetId}_${item.row}_${item.col}`
3849
- )) })
3879
+ /* @__PURE__ */ (0, import_jsx_runtime3.jsx)("code", { style: { fontSize: 11, color: "#7D8698", wordBreak: "break-all" }, children: item.rawText })
3880
+ ]
3881
+ },
3882
+ `${item.sheetId}_${item.row}_${item.col}`
3883
+ );
3884
+ }) })
3850
3885
  ] });
3851
3886
  };
3852
3887
 
@@ -3948,6 +3983,7 @@ var SheetPreviewAndIoModal = () => {
3948
3983
  const compiled = effectiveData ? (0, import_univer_sheets4.compileWorkbookWithDataset)(snap, effectiveData, {
3949
3984
  metadata: tplMeta,
3950
3985
  printConfig: cfg,
3986
+ implicitExpand: unitId ? templateService.getImplicitExpand(unitId) : void 0,
3951
3987
  loopBlocks,
3952
3988
  conditionProperties,
3953
3989
  drillLinks,
@@ -4151,6 +4187,7 @@ var SheetPreviewAndIoModal = () => {
4151
4187
  data: parsedData,
4152
4188
  printConfig: printCfg,
4153
4189
  metadata: templateService.getTemplateMetadata(unitId),
4190
+ implicitExpand: templateService.getImplicitExpand(unitId),
4154
4191
  target: ioTarget
4155
4192
  });
4156
4193
  const mime = format === "xlsx" ? "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet" : format === "xls" ? "application/vnd.ms-excel" : format === "pdf" ? "application/pdf" : format === "docx" ? "application/vnd.openxmlformats-officedocument.wordprocessingml.document" : format === "xml" ? "application/xml;charset=utf-8" : format === "html" ? "text/html;charset=utf-8" : "text/csv;charset=utf-8";