@antv/s2-vue 2.0.0-next.2 → 2.0.0-next.4

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/esm/index.js CHANGED
@@ -87,7 +87,6 @@ const SHEET_COMPONENT_DEFAULT_OPTIONS = {
87
87
  autoAdjustBoundary: "body",
88
88
  operation: {
89
89
  hiddenColumns: true,
90
- trend: false,
91
90
  sort: true
92
91
  }
93
92
  },
@@ -2418,11 +2417,12 @@ const useEvents = (s2Ref, emit) => {
2418
2417
  useCellEvent(s2Ref, emit, S2Event.ROW_CELL_MOUSE_DOWN, "rowCellMouseDown");
2419
2418
  useCellEvent(s2Ref, emit, S2Event.ROW_CELL_MOUSE_UP, "rowCellMouseUp");
2420
2419
  useCellEvent(s2Ref, emit, S2Event.ROW_CELL_MOUSE_MOVE, "rowCellMouseMove");
2420
+ useS2Event(s2Ref, emit, S2Event.ROW_CELL_COLLAPSED, "rowCellCollapsed");
2421
2421
  useS2Event(
2422
2422
  s2Ref,
2423
2423
  emit,
2424
- S2Event.ROW_CELL_COLLAPSE_TREE_ROWS,
2425
- "rowCellCollapseTreeRows"
2424
+ S2Event.ROW_CELL_ALL_COLLAPSED,
2425
+ "rowCellAllCollapsed"
2426
2426
  );
2427
2427
  useS2Event(s2Ref, emit, S2Event.ROW_CELL_SCROLL, "rowCellScroll");
2428
2428
  useCellEvent(s2Ref, emit, S2Event.COL_CELL_HOVER, "colCellHover");
@@ -2442,6 +2442,8 @@ const useEvents = (s2Ref, emit) => {
2442
2442
  useCellEvent(s2Ref, emit, S2Event.COL_CELL_MOUSE_DOWN, "colCellMouseDown");
2443
2443
  useCellEvent(s2Ref, emit, S2Event.COL_CELL_MOUSE_UP, "colCellMouseUp");
2444
2444
  useCellEvent(s2Ref, emit, S2Event.COL_CELL_MOUSE_MOVE, "colCellMouseMove");
2445
+ useS2Event(s2Ref, emit, S2Event.COL_CELL_EXPANDED, "colCellExpanded");
2446
+ useS2Event(s2Ref, emit, S2Event.COL_CELL_HIDDEN, "colCellHidden");
2445
2447
  useCellEvent(s2Ref, emit, S2Event.DATA_CELL_HOVER, "dataCellHover");
2446
2448
  useCellEvent(s2Ref, emit, S2Event.DATA_CELL_CLICK, "dataCellClick");
2447
2449
  useCellEvent(
@@ -2469,12 +2471,6 @@ const useEvents = (s2Ref, emit) => {
2469
2471
  S2Event.DATA_CELL_MOUSE_MOVE,
2470
2472
  "dataCellMouseMove"
2471
2473
  );
2472
- useS2Event(
2473
- s2Ref,
2474
- emit,
2475
- S2Event.DATA_CELL_TREND_ICON_CLICK,
2476
- "dataCellTrendIconClick"
2477
- );
2478
2474
  useS2Event(
2479
2475
  s2Ref,
2480
2476
  emit,
@@ -2563,20 +2559,6 @@ const useEvents = (s2Ref, emit) => {
2563
2559
  );
2564
2560
  useS2Event(s2Ref, emit, S2Event.LAYOUT_PAGINATION, "layoutPagination");
2565
2561
  useS2Event(s2Ref, emit, S2Event.LAYOUT_CELL_SCROLL, "layoutCellScroll");
2566
- useS2Event(
2567
- s2Ref,
2568
- emit,
2569
- S2Event.LAYOUT_AFTER_COLLAPSE_ROWS,
2570
- "layoutAfterCollapseRows"
2571
- );
2572
- useS2Event(
2573
- s2Ref,
2574
- emit,
2575
- S2Event.LAYOUT_TREE_ROWS_COLLAPSE_ALL,
2576
- "collapseRowsAll"
2577
- );
2578
- useS2Event(s2Ref, emit, S2Event.LAYOUT_COLS_EXPANDED, "layoutColsExpanded");
2579
- useS2Event(s2Ref, emit, S2Event.LAYOUT_COLS_HIDDEN, "layoutColsHidden");
2580
2562
  useS2Event(s2Ref, emit, S2Event.LAYOUT_BEFORE_RENDER, "beforeRender");
2581
2563
  useS2Event(s2Ref, emit, S2Event.LAYOUT_AFTER_RENDER, "afterRender");
2582
2564
  useS2Event(s2Ref, emit, S2Event.LAYOUT_DESTROY, "destroy");
@@ -2659,6 +2641,12 @@ const useEvents = (s2Ref, emit) => {
2659
2641
  useS2Event(s2Ref, emit, S2Event.GLOBAL_RESET, "reset");
2660
2642
  useS2Event(s2Ref, emit, S2Event.GLOBAL_LINK_FIELD_JUMP, "linkFieldJump");
2661
2643
  useS2Event(s2Ref, emit, S2Event.GLOBAL_SCROLL, "scroll");
2644
+ useS2Event(
2645
+ s2Ref,
2646
+ emit,
2647
+ S2Event.LAYOUT_AFTER_REAL_DATA_CELL_RENDER,
2648
+ "layoutAfterRealDataCellRender"
2649
+ );
2662
2650
  useS2Event(
2663
2651
  s2Ref,
2664
2652
  emit,
@@ -2747,25 +2735,21 @@ const useSheetUpdate = (s2Ref, props) => {
2747
2735
  };
2748
2736
  const useResize = (s2Ref, props, dom) => {
2749
2737
  const unobserve = ref();
2750
- watch(
2751
- [s2Ref, () => props.adaptive],
2752
- ([s2, adaptive], _, onCleanup) => {
2753
- if (!s2) {
2754
- return;
2755
- }
2756
- unobserve.value = createResizeObserver({
2757
- s2,
2758
- adaptive,
2759
- wrapper: dom.wrapperRef.value,
2760
- container: dom.containerRef.value
2761
- });
2762
- onCleanup(() => {
2763
- var _a;
2764
- (_a = unobserve.value) == null ? void 0 : _a.call(unobserve);
2765
- });
2766
- },
2767
- { deep: true }
2768
- );
2738
+ watch([s2Ref, () => props.adaptive], ([s2, adaptive], _, onCleanup) => {
2739
+ if (!s2) {
2740
+ return;
2741
+ }
2742
+ unobserve.value = createResizeObserver({
2743
+ s2,
2744
+ adaptive,
2745
+ wrapper: dom.wrapperRef.value,
2746
+ container: dom.containerRef.value
2747
+ });
2748
+ onCleanup(() => {
2749
+ var _a;
2750
+ (_a = unobserve.value) == null ? void 0 : _a.call(unobserve);
2751
+ });
2752
+ });
2769
2753
  };
2770
2754
  function useSpreadSheet(props, emit) {
2771
2755
  const {
@@ -2883,7 +2867,8 @@ const initBaseSheetEmits = () => {
2883
2867
  "rowCellMouseDown",
2884
2868
  "rowCellMouseUp",
2885
2869
  "rowCellMouseMove",
2886
- "rowCellCollapseTreeRows",
2870
+ "rowCellCollapsed",
2871
+ "rowCellAllCollapsed",
2887
2872
  "rowCellScroll",
2888
2873
  "colCellHover",
2889
2874
  "colCellClick",
@@ -2892,6 +2877,8 @@ const initBaseSheetEmits = () => {
2892
2877
  "colCellMouseDown",
2893
2878
  "colCellMouseUp",
2894
2879
  "colCellMouseMove",
2880
+ "colCellExpanded",
2881
+ "colCellHidden",
2895
2882
  "dataCellHover",
2896
2883
  "dataCellClick",
2897
2884
  "dataCellDoubleClick",
@@ -2899,7 +2886,6 @@ const initBaseSheetEmits = () => {
2899
2886
  "dataCellMouseDown",
2900
2887
  "dataCellMouseUp",
2901
2888
  "dataCellMouseMove",
2902
- "dataCellTrendIconClick",
2903
2889
  "dataCellBrushSelection",
2904
2890
  "dataCellSelectMove",
2905
2891
  "cornerCellHover",
@@ -2923,11 +2909,6 @@ const initBaseSheetEmits = () => {
2923
2909
  "layoutAfterHeaderLayout",
2924
2910
  "layoutPagination",
2925
2911
  "layoutCellScroll",
2926
- "layoutCollapseRows",
2927
- "layoutAfterCollapseRows",
2928
- "collapseRowsAll",
2929
- "layoutColsExpanded",
2930
- "layoutColsHidden",
2931
2912
  "beforeRender",
2932
2913
  "afterRender",
2933
2914
  "mounted",
@@ -2959,6 +2940,7 @@ const initBaseSheetEmits = () => {
2959
2940
  "doubleClick",
2960
2941
  "scroll",
2961
2942
  "hover",
2943
+ "layoutAfterRealDataCellRender",
2962
2944
  "rowCellBrushSelection",
2963
2945
  "colCellBrushSelection"
2964
2946
  ];