rapid-spreadjs 1.0.54 → 1.0.55

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/index.esm.js CHANGED
@@ -520,9 +520,10 @@ const SheetUtils = {
520
520
  * 设置当前活动工作表的水印和数据绑定是否显示
521
521
  * @param spread 工作簿实例
522
522
  * @param cells 数据绑定单元格配置集合([{ row: number; col: number; title: string; pathPrev: string; pathField: string }])
523
- * @param isShow 是否显示
523
+ * @param isShow 是否显示水印
524
+ * @param isShowBindPath 是否显示数据绑定路径,默认为:true
524
525
  */
525
- setActiveSheetWatermark: (spread, cells, isShow) => {
526
+ setActiveSheetWatermark: (spread, cells, isShowWatermark, isShowBindPath = true) => {
526
527
  if (cells == null || cells == undefined) {
527
528
  return;
528
529
  }
@@ -531,9 +532,9 @@ const SheetUtils = {
531
532
  sheet.suspendPaint();
532
533
  cells.forEach((cell) => {
533
534
  // 设置或移除水印标签
534
- sheet.getCell(cell.row, cell.col).watermark(isShow ? `{${cell.title}}` : undefined);
535
+ sheet.getCell(cell.row, cell.col).watermark(isShowWatermark ? `{${cell.title}}` : undefined);
535
536
  // 设置或移除绑定路径
536
- sheet.setBindingPath(cell.row, cell.col, isShow ? `${cell.pathPrev}.${cell.pathField}` : undefined);
537
+ sheet.setBindingPath(cell.row, cell.col, isShowBindPath ? `${cell.pathPrev}.${cell.pathField}` : undefined);
537
538
  });
538
539
  // 恢复绘制
539
540
  sheet.resumePaint();