stk-table-vue 0.11.7 → 0.11.9

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 (57) hide show
  1. package/README.md +173 -172
  2. package/lib/index-C40Rz-HL.js +1 -1
  3. package/lib/src/StkTable/StkTable.vue.d.ts +1 -7
  4. package/lib/src/StkTable/types/index.d.ts +6 -5
  5. package/lib/src/StkTable/useColResize.d.ts +1 -1
  6. package/lib/src/StkTable/useFixedStyle.d.ts +2 -2
  7. package/lib/src/StkTable/useVirtualScroll.d.ts +1 -1
  8. package/lib/src/StkTable/utils/index.d.ts +1 -0
  9. package/lib/stk-table-vue.js +163 -115
  10. package/lib/style.css +1 -1
  11. package/package.json +84 -75
  12. package/src/StkTable/StkTable.vue +1746 -1742
  13. package/src/StkTable/components/DragHandle.vue +9 -9
  14. package/src/StkTable/components/Filter/Dropdown/index.ts +16 -16
  15. package/src/StkTable/components/Filter/Dropdown/index.vue +185 -185
  16. package/src/StkTable/components/Filter/Filter.less +129 -129
  17. package/src/StkTable/components/Filter/Filter.vue +61 -61
  18. package/src/StkTable/components/Filter/index.ts +6 -6
  19. package/src/StkTable/components/Filter/types.ts +18 -18
  20. package/src/StkTable/components/Filter/useFilter.ts +90 -90
  21. package/src/StkTable/components/SortIcon.vue +6 -6
  22. package/src/StkTable/components/TreeNodeCell.vue +19 -19
  23. package/src/StkTable/components/TriangleIcon.vue +3 -3
  24. package/src/StkTable/const.ts +50 -50
  25. package/src/StkTable/features/const.ts +1 -1
  26. package/src/StkTable/features/index.ts +1 -1
  27. package/src/StkTable/features/useAreaSelection.ts +780 -780
  28. package/src/StkTable/index.ts +9 -9
  29. package/src/StkTable/registerFeature.ts +35 -35
  30. package/src/StkTable/style.less +723 -723
  31. package/src/StkTable/types/highlightDimOptions.ts +26 -26
  32. package/src/StkTable/types/index.ts +393 -391
  33. package/src/StkTable/useAutoResize.ts +87 -87
  34. package/src/StkTable/useColResize.ts +202 -200
  35. package/src/StkTable/useFixedCol.ts +139 -139
  36. package/src/StkTable/useFixedStyle.ts +75 -74
  37. package/src/StkTable/useGetFixedColPosition.ts +63 -63
  38. package/src/StkTable/useHighlight.ts +249 -247
  39. package/src/StkTable/useKeyboardArrowScroll.ts +114 -112
  40. package/src/StkTable/useMaxRowSpan.ts +50 -50
  41. package/src/StkTable/useMergeCells.ts +138 -131
  42. package/src/StkTable/useRowExpand.ts +80 -80
  43. package/src/StkTable/useScrollRowByRow.ts +96 -96
  44. package/src/StkTable/useScrollbar.ts +169 -159
  45. package/src/StkTable/useSorter.ts +259 -259
  46. package/src/StkTable/useTableColumns.ts +129 -129
  47. package/src/StkTable/useThDrag.ts +96 -96
  48. package/src/StkTable/useTrDrag.ts +100 -100
  49. package/src/StkTable/useTree.ts +151 -151
  50. package/src/StkTable/useVirtualScroll.ts +554 -511
  51. package/src/StkTable/useWheeling.ts +23 -23
  52. package/src/StkTable/utils/constRefUtils.ts +29 -29
  53. package/src/StkTable/utils/index.ts +324 -314
  54. package/src/StkTable/utils/useTriggerRef.ts +33 -33
  55. package/src/VirtualTree.vue +622 -622
  56. package/src/VirtualTreeSelect.vue +367 -367
  57. package/src/vite-env.d.ts +10 -10
package/README.md CHANGED
@@ -1,172 +1,173 @@
1
- <p align="center">
2
- <a href="https://ja-plus.github.io/stk-table-vue/">
3
- <img src="./docs-src/public/assets/logo.svg" width="152">
4
- </a>
5
- <h3 align='center'>Stk Table Vue</h3>
6
- <p align="center">
7
- <a href="https://www.npmjs.com/package/stk-table-vue"><img src="https://img.shields.io/npm/v/stk-table-vue"></a>
8
- <a href="https://www.npmjs.com/package/stk-table-vue"><img src="https://img.shields.io/npm/dw/stk-table-vue"></a>
9
- <a href="https://github.com/ja-plus/stk-table-vue/stargazers"><img src="https://img.shields.io/github/stars/ja-plus/stk-table-vue.svg"></a>
10
- <a href="https://raw.githubusercontent.com/ja-plus/stk-table-vue/master/LICENSE"><img src="https://img.shields.io/npm/l/stk-table-vue"></a>
11
- <a href="https://github.com/ja-plus/stk-table-vue"><img src="https://img.shields.io/npm/types/stk-table-vue"></a>
12
- </p>
13
- </p>
14
-
15
- > Stk Table Vue(Sticky Table) is a high-performance virtual list component based on Vue.
16
- >
17
- > Used for real-time data display, with data highlighting and dynamic effects
18
- >
19
- > Support Vue3 and Vue2.7
20
-
21
-
22
- ## Documentation
23
- ### [Stk Table Vue Official en](https://ja-plus.github.io/stk-table-vue/en/)
24
- ### [Stk Table Vue Official zh-CN](https://ja-plus.github.io/stk-table-vue/)
25
-
26
-
27
- ## Repo:
28
- - [Github](https://github.com/ja-plus/stk-table-vue)
29
- - [Gitee](https://gitee.com/japlus/stk-table-vue) 🇨🇳
30
-
31
- ## Demo
32
- [<span style="font-size: 16px;font-weight: bold;">Online Demo in stackblitz</span>](https://stackblitz.com/edit/vitejs-vite-ad91hh?file=src%2FDemo%2Findex.vue)
33
-
34
- ## Usage
35
- > npm install stk-table-vue
36
-
37
- ```html
38
- <script setup>
39
- import { StkTable } from 'stk-table-vue'
40
- import { ref, useTemplateRef } from 'vue'
41
- const stkTableRef = ref<InstanceType<typeof StkTable>>();
42
- // or Vue 3.5 useTemplateRef
43
- const stkTableRef = useTemplateRef('stkTableRef');
44
-
45
- // highlight row
46
- stkTableRef.value.setHighlightDimRow([rowKey],{
47
- method: 'css'|'animation',// default animation。
48
- className: 'custom-class-name', // method css。
49
- keyframe: [{backgroundColor:'#aaa'}, {backgroundColor: '#222'}],//same as https://developer.mozilla.org/zh-CN/docs/Web/API/Web_Animations_API/Keyframe_Formats
50
- duration: 2000,。
51
- });
52
- // highlight cell
53
- stkTableRef.value.setHighlightDimCell(rowKey, colDataIndex, {
54
- method: 'css'|'animation',
55
- className:'custom-class-name', // method css。
56
- keyframe: [{backgroundColor:'#aaa'}, {backgroundColor: '#222'}], // method animation。
57
- duration: 2000,。
58
- });
59
-
60
- const columns = [
61
- {title: 'name', dataIndex: 'name'},
62
- {title: 'age', dataIndex: 'age'},
63
- {title: 'address', dataIndex: 'address'},
64
- ];
65
-
66
- const dataSource = [
67
- {id: 1, name: 'John', age: 32, address: 'New York'},
68
- {id: 2, name: 'Jim', age: 42, address: 'London'},
69
- {id: 3, name: 'Joe', age: 52, address: 'Tokyo'},
70
- {id: 4, name: 'Jack', age: 62, address: 'Sydney'},
71
- {id: 5, name: 'Jill', age: 72, address: 'Paris'},
72
- ]
73
-
74
- </script>
75
-
76
- <template>
77
- <StkTable ref='stkTableRef' row-key="id" :data-source="dataSource" :columns="columns"></StkTable>
78
- </template>
79
-
80
- ```
81
-
82
- ### Vue2.7 Usage
83
- [Vue2.7 Usage](https://ja-plus.github.io/stk-table-vue/main/start/vue2-usage.html)
84
-
85
- ## API
86
- * [Props](https://ja-plus.github.io/stk-table-vue/main/api/table-props.html)
87
-
88
- * [Emits](https://ja-plus.github.io/stk-table-vue/main/api/emits.html)
89
-
90
- * [Slots](https://ja-plus.github.io/stk-table-vue/main/api/slots.html)
91
-
92
- * [Expose](https://ja-plus.github.io/stk-table-vue/main/api/expose.html)
93
-
94
- * [StkTableColumn: Define column type](https://ja-plus.github.io/stk-table-vue/main/api/stk-table-column.html)
95
-
96
- * [Highlight: setHighlightDimCell & setHighlightDimRow](https://ja-plus.github.io/stk-table-vue/main/api/expose.html#sethighlightdimcell)
97
-
98
-
99
- ### Example
100
- ```vue
101
- <template>
102
- <StkTable
103
- ref="stkTable"
104
- row-key="name"
105
- v-model:columns="columns"
106
- :style="{height:props.height}"
107
- theme='dark'
108
- height='200px'
109
- bordered="h"
110
- :row-height="28"
111
- :show-overflow="false"
112
- :show-header-overflow="false"
113
- :sort-remote="false"
114
- col-resizable
115
- header-drag
116
- virtual
117
- virtual-x
118
- no-data-full
119
- col-resizable
120
- auto-resize
121
- fixed-col-shadow
122
- :col-min-width="10"
123
- :headless="false"
124
- :data-source="dataSource"
125
- @current-change="onCurrentChange"
126
- @row-menu="onRowMenu"
127
- @header-row-menu="onHeaderRowMenu"
128
- @row-click="onRowClick"
129
- @row-dblclick="onRowDblclick"
130
- @sort-change="handleSortChange"
131
- @cell-click="onCellClick"
132
- @header-cell-click="onHeaderCellClick"
133
- @scroll="onTableScroll"
134
- @scroll-x="onTableScrollX"
135
- @col-order-change="onColOrderChange"
136
- />
137
- </template>
138
- <script setup>
139
- import { h, defineComponent } from 'vue';
140
- const columns = [
141
- {
142
- title: 'Name',
143
- dataIndex: 'name',
144
- fixed: 'left',
145
- width: '200px',
146
- headerClassName: 'my-th',
147
- className: 'my-td',
148
- sorter: true,
149
- customHeaderCell: function FunctionalComponent(props){
150
- return h(
151
- 'span',
152
- { style: 'overflow:hidden;text-overflow:ellipsis;white-space:nowrap' },
153
- props.col.title + '(render) text-overflow,',
154
- );
155
- },
156
- customCell: defineComponent({
157
- setup(){
158
- //...
159
- return () => <div></div> // vue jsx
160
- }
161
- })
162
- },
163
- ]
164
- </script>
165
- ```
166
-
167
- ## Compare
168
- Compare performance with other vue table [vue-table-compare](https://github.com/ja-plus/vue-table-compare)
169
-
170
-
171
- ## Other
172
- * `$*$`
1
+ <p align="center">
2
+ <a href="https://ja-plus.github.io/stk-table-vue/">
3
+ <img src="./docs-src/public/assets/logo.svg" width="152">
4
+ </a>
5
+ <h3 align='center'>Stk Table Vue</h3>
6
+ <p align="center">
7
+ <a href="https://www.npmjs.com/package/stk-table-vue"><img src="https://img.shields.io/npm/v/stk-table-vue"></a>
8
+ <a href="https://www.npmjs.com/package/stk-table-vue"><img src="https://img.shields.io/npm/dw/stk-table-vue"></a>
9
+ <a href="https://github.com/ja-plus/stk-table-vue/stargazers"><img src="https://img.shields.io/github/stars/ja-plus/stk-table-vue.svg"></a>
10
+ <a href="https://raw.githubusercontent.com/ja-plus/stk-table-vue/master/LICENSE"><img src="https://img.shields.io/npm/l/stk-table-vue"></a>
11
+ <a href="https://github.com/ja-plus/stk-table-vue"><img src="https://img.shields.io/npm/types/stk-table-vue"></a>
12
+ </p>
13
+ </p>
14
+
15
+ Stk Table Vue(Sticky Table) is a high-performance virtual list component based on Vue.
16
+
17
+ Smooth performance with tens of thousands of rows
18
+
19
+ Used for real-time data display, with data highlighting and dynamic effects.
20
+
21
+ Support Vue3 and Vue2.7
22
+
23
+
24
+ ## Documentation
25
+ ### [Stk Table Vue Official](https://ja-plus.github.io/stk-table-vue/)
26
+
27
+
28
+ ## Repo:
29
+ - [Github](https://github.com/ja-plus/stk-table-vue)
30
+ - [Gitee](https://gitee.com/japlus/stk-table-vue)
31
+
32
+ ## Demo
33
+ [<span style="font-size: 16px;font-weight: bold;">Online Demo in stackblitz</span>](https://stackblitz.com/edit/vitejs-vite-ad91hh?file=src%2FDemo%2Findex.vue)
34
+
35
+ ## Usage
36
+ > npm install stk-table-vue
37
+
38
+ ```html
39
+ <script setup>
40
+ import { StkTable } from 'stk-table-vue'
41
+ import { ref, useTemplateRef } from 'vue'
42
+ const stkTableRef = ref<InstanceType<typeof StkTable>>();
43
+ // or Vue 3.5 useTemplateRef
44
+ const stkTableRef = useTemplateRef('stkTableRef');
45
+
46
+ // highlight row
47
+ stkTableRef.value.setHighlightDimRow([rowKey],{
48
+ method: 'css'|'animation',// default animation。
49
+ className: 'custom-class-name', // method css。
50
+ keyframe: [{backgroundColor:'#aaa'}, {backgroundColor: '#222'}],//same as https://developer.mozilla.org/zh-CN/docs/Web/API/Web_Animations_API/Keyframe_Formats
51
+ duration: 2000,。
52
+ });
53
+ // highlight cell
54
+ stkTableRef.value.setHighlightDimCell(rowKey, colDataIndex, {
55
+ method: 'css'|'animation',
56
+ className:'custom-class-name', // method css。
57
+ keyframe: [{backgroundColor:'#aaa'}, {backgroundColor: '#222'}], // method animation。
58
+ duration: 2000,。
59
+ });
60
+
61
+ const columns = [
62
+ {title: 'name', dataIndex: 'name'},
63
+ {title: 'age', dataIndex: 'age'},
64
+ {title: 'address', dataIndex: 'address'},
65
+ ];
66
+
67
+ const dataSource = [
68
+ {id: 1, name: 'John', age: 32, address: 'New York'},
69
+ {id: 2, name: 'Jim', age: 42, address: 'London'},
70
+ {id: 3, name: 'Joe', age: 52, address: 'Tokyo'},
71
+ {id: 4, name: 'Jack', age: 62, address: 'Sydney'},
72
+ {id: 5, name: 'Jill', age: 72, address: 'Paris'},
73
+ ]
74
+
75
+ </script>
76
+
77
+ <template>
78
+ <StkTable ref='stkTableRef' row-key="id" :data-source="dataSource" :columns="columns"></StkTable>
79
+ </template>
80
+
81
+ ```
82
+
83
+ ### Vue2.7 Usage
84
+ [Vue2.7 Usage](https://ja-plus.github.io/stk-table-vue/main/start/vue2-usage.html)
85
+
86
+ ## API
87
+ * [Props](https://ja-plus.github.io/stk-table-vue/main/api/table-props.html)
88
+
89
+ * [Emits](https://ja-plus.github.io/stk-table-vue/main/api/emits.html)
90
+
91
+ * [Slots](https://ja-plus.github.io/stk-table-vue/main/api/slots.html)
92
+
93
+ * [Expose](https://ja-plus.github.io/stk-table-vue/main/api/expose.html)
94
+
95
+ * [StkTableColumn: Define column type](https://ja-plus.github.io/stk-table-vue/main/api/stk-table-column.html)
96
+
97
+ * [Highlight: setHighlightDimCell & setHighlightDimRow](https://ja-plus.github.io/stk-table-vue/main/api/expose.html#sethighlightdimcell)
98
+
99
+
100
+ ### Example
101
+ ```vue
102
+ <template>
103
+ <StkTable
104
+ ref="stkTable"
105
+ row-key="name"
106
+ v-model:columns="columns"
107
+ :style="{height:props.height}"
108
+ theme='dark'
109
+ height='200px'
110
+ bordered="h"
111
+ :row-height="28"
112
+ :show-overflow="false"
113
+ :show-header-overflow="false"
114
+ :sort-remote="false"
115
+ col-resizable
116
+ header-drag
117
+ virtual
118
+ virtual-x
119
+ no-data-full
120
+ col-resizable
121
+ auto-resize
122
+ fixed-col-shadow
123
+ :col-min-width="10"
124
+ :headless="false"
125
+ :data-source="dataSource"
126
+ @current-change="onCurrentChange"
127
+ @row-menu="onRowMenu"
128
+ @header-row-menu="onHeaderRowMenu"
129
+ @row-click="onRowClick"
130
+ @row-dblclick="onRowDblclick"
131
+ @sort-change="handleSortChange"
132
+ @cell-click="onCellClick"
133
+ @header-cell-click="onHeaderCellClick"
134
+ @scroll="onTableScroll"
135
+ @scroll-x="onTableScrollX"
136
+ @col-order-change="onColOrderChange"
137
+ />
138
+ </template>
139
+ <script setup>
140
+ import { h, defineComponent } from 'vue';
141
+ const columns = [
142
+ {
143
+ title: 'Name',
144
+ dataIndex: 'name',
145
+ fixed: 'left',
146
+ width: '200px',
147
+ headerClassName: 'my-th',
148
+ className: 'my-td',
149
+ sorter: true,
150
+ customHeaderCell: function FunctionalComponent(props){
151
+ return h(
152
+ 'span',
153
+ { style: 'overflow:hidden;text-overflow:ellipsis;white-space:nowrap' },
154
+ props.col.title + '(render) text-overflow,',
155
+ );
156
+ },
157
+ customCell: defineComponent({
158
+ setup(){
159
+ //...
160
+ return () => <div></div> // vue jsx
161
+ }
162
+ })
163
+ },
164
+ ]
165
+ </script>
166
+ ```
167
+
168
+ ## Compare
169
+ Compare performance with other vue table [vue-table-compare](https://github.com/ja-plus/vue-table-compare)
170
+
171
+
172
+ ## Other
173
+ * `$*$`
@@ -1,6 +1,6 @@
1
1
  /**
2
2
  * name: stk-table-vue
3
- * version: v0.11.6
3
+ * version: v0.11.9
4
4
  * description: High performance realtime virtual table for vue3 and vue2.7
5
5
  * author: japlus
6
6
  * homepage: https://ja-plus.github.io/stk-table-vue/
@@ -418,13 +418,7 @@ declare const __VLS_component: import('vue').DefineComponent<import('vue').Extra
418
418
  })) | (UniqKey | (PrivateRowDT & {
419
419
  children?: (PrivateRowDT & /*elided*/ any)[];
420
420
  }))[], option?: {
421
- expand
422
- /**
423
- * props cannot be placed in a separate file. It will cause compilation errors with vue 2.7 compiler.
424
- */
425
- ? /**
426
- * props cannot be placed in a separate file. It will cause compilation errors with vue 2.7 compiler.
427
- */: boolean;
421
+ expand?: boolean;
428
422
  }) => void;
429
423
  /**
430
424
  * 获取拖选选中的单元格信息
@@ -254,12 +254,13 @@ export type SortConfig<T extends Record<string, any>> = {
254
254
  multiSortLimit?: number;
255
255
  };
256
256
  /** th td type */
257
- export declare const enum TagType {
258
- TH = 0,
259
- TD = 1,
257
+ export declare const TagType: {
258
+ readonly TH: 0;
259
+ readonly TD: 1;
260
260
  /** tfoot */
261
- TF = 2
262
- }
261
+ readonly TF: 2;
262
+ };
263
+ export type TagType = (typeof TagType)[keyof typeof TagType];
263
264
  export type HighlightConfig = {
264
265
  /** Duration of the highlight in seconds */
265
266
  duration?: number;
@@ -2,4 +2,4 @@ import { ComputedRef, Ref, ShallowRef } from 'vue';
2
2
  import { StkTableColumn, UniqKey } from './types';
3
3
 
4
4
  /** 列宽拖动 */
5
- export declare function useColResize<DT extends Record<string, any>>(props: any, emits: any, tableContainerRef: Ref<HTMLElement | undefined>, tableHeaderLast: ShallowRef<StkTableColumn<DT>[]>, colResizeIndicatorRef: Ref<HTMLElement | undefined>, colKeyGen: ComputedRef<(p: any) => UniqKey>, fixedCols: Ref<StkTableColumn<DT>[]>): readonly [ComputedRef<((col: StkTableColumn<DT>) => boolean) | (() => any)>, Ref<boolean, boolean>, (e: MouseEvent, col: StkTableColumn<DT>, leftHandle?: boolean) => void];
5
+ export declare function useColResize<DT extends Record<string, any>>(props: any, emits: any, tableContainerRef: Ref<HTMLElement | undefined>, tableHeaderLast: ShallowRef<StkTableColumn<DT>[]>, colResizeIndicatorRef: Ref<HTMLElement | undefined>, colKeyGen: ComputedRef<(p: any) => UniqKey>, fixedCols: Ref<StkTableColumn<DT>[]>, onColWidthChange?: () => void): readonly [ComputedRef<((col: StkTableColumn<DT>) => boolean) | (() => any)>, Ref<boolean, boolean>, (e: MouseEvent, col: StkTableColumn<DT>, leftHandle?: boolean) => void];
@@ -1,4 +1,4 @@
1
- import { CSSProperties, ComputedRef, Ref } from 'vue';
1
+ import { ComputedRef, Ref } from 'vue';
2
2
  import { StkTableColumn, TagType } from './types';
3
3
  import { VirtualScrollStore, VirtualScrollXStore } from './useVirtualScroll';
4
4
 
@@ -13,4 +13,4 @@ import { VirtualScrollStore, VirtualScrollXStore } from './useVirtualScroll';
13
13
  * @param virtualX_offsetRight
14
14
  * @returns
15
15
  */
16
- export declare function useFixedStyle<DT extends Record<string, any>>(props: any, isRelativeMode: Ref<boolean>, getFixedColPosition: ComputedRef<(col: StkTableColumn<DT>) => number>, virtualScroll: Ref<VirtualScrollStore>, virtualScrollX: Ref<VirtualScrollXStore>, virtualX_on: Ref<boolean>, virtualX_offsetRight: Ref<number>): (tagType: TagType, col: StkTableColumn<DT>, depth?: number) => CSSProperties | null;
16
+ export declare function useFixedStyle<DT extends Record<string, any>>(props: any, isRelativeMode: Ref<boolean>, getFixedColPosition: ComputedRef<(col: StkTableColumn<DT>) => number>, virtualScroll: Ref<VirtualScrollStore>, virtualScrollX: Ref<VirtualScrollXStore>, virtualX_on: Ref<boolean>, virtualX_offsetRight: Ref<number>): (tagType: TagType, col: StkTableColumn<DT>, depth?: number) => string;
@@ -75,4 +75,4 @@ export declare function useVirtualScroll(props: any, tableContainerRef: Ref<HTML
75
75
  endIndex: number;
76
76
  offsetLeft: number;
77
77
  scrollLeft: number;
78
- }>, import('vue').ComputedRef<any>, import('vue').ComputedRef<PrivateRowDT[]>, import('vue').ComputedRef<number>, import('vue').ComputedRef<any>, import('vue').ComputedRef<PrivateStkTableColumn<PrivateRowDT>[]>, import('vue').ComputedRef<number>, import('vue').ComputedRef<number>, (height?: number) => void, (height?: number) => void, () => void, (sTop?: number) => void, (sLeft?: number) => void, (rowKey: UniqKey, height?: number | null) => void, () => void];
78
+ }>, import('vue').ComputedRef<any>, import('vue').ComputedRef<PrivateRowDT[]>, import('vue').ComputedRef<number>, import('vue').ComputedRef<any>, import('vue').ComputedRef<PrivateStkTableColumn<PrivateRowDT>[]>, import('vue').ComputedRef<number>, import('vue').ComputedRef<number>, (height?: number) => void, (height?: number) => void, () => void, (sTop?: number) => void, (sLeft?: number) => void, (rowKey: UniqKey, height?: number | null) => void, () => void, () => void];
@@ -68,3 +68,4 @@ export declare function throttle<T extends (...args: any[]) => any>(fn: T, delay
68
68
  * @returns A throttled function that executes on the next animation frame
69
69
  */
70
70
  export declare function rafThrottle<T extends (...args: any[]) => any>(fn: T): (...args: Parameters<T>) => void;
71
+ export declare function debounce<T extends (...args: any[]) => any>(fn: T, delay: number): (...args: Parameters<T>) => void;