bkui-vue 2.0.1-beta.15 → 2.0.1-beta.15.table.1

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 (195) hide show
  1. package/dist/index.cjs.js +63 -63
  2. package/dist/index.esm.js +15152 -15326
  3. package/dist/index.umd.js +63 -63
  4. package/dist/style.css +1 -1
  5. package/dist/style.variable.css +1 -1
  6. package/lib/affix/affix.css +129 -0
  7. package/lib/affix/affix.variable.css +258 -0
  8. package/lib/alert/alert.css +132 -3
  9. package/lib/alert/alert.variable.css +258 -0
  10. package/lib/backtop/backtop.css +132 -3
  11. package/lib/backtop/backtop.variable.css +390 -3
  12. package/lib/badge/badge.css +155 -26
  13. package/lib/badge/badge.variable.css +258 -0
  14. package/lib/breadcrumb/breadcrumb.css +134 -5
  15. package/lib/breadcrumb/breadcrumb.variable.css +392 -5
  16. package/lib/button/button.css +272 -143
  17. package/lib/button/button.variable.css +258 -0
  18. package/lib/button/index.js +0 -1
  19. package/lib/card/card.css +133 -4
  20. package/lib/card/card.variable.css +391 -4
  21. package/lib/cascader/cascader.css +152 -23
  22. package/lib/cascader/cascader.variable.css +410 -23
  23. package/lib/checkbox/checkbox.css +138 -9
  24. package/lib/checkbox/checkbox.variable.css +258 -0
  25. package/lib/code-diff/code-diff.css +129 -0
  26. package/lib/code-diff/code-diff.variable.css +258 -0
  27. package/lib/collapse/collapse.css +130 -1
  28. package/lib/collapse/collapse.variable.css +258 -0
  29. package/lib/collapse-transition/collapse-transition.css +129 -0
  30. package/lib/collapse-transition/collapse-transition.variable.css +258 -0
  31. package/lib/color-picker/color-picker.css +129 -0
  32. package/lib/color-picker/color-picker.variable.css +258 -0
  33. package/lib/config-provider/config-provider.css +129 -0
  34. package/lib/config-provider/config-provider.variable.css +258 -0
  35. package/lib/container/container.css +129 -0
  36. package/lib/container/container.variable.css +387 -0
  37. package/lib/container/index.js +0 -1
  38. package/lib/date-picker/date-picker.css +146 -17
  39. package/lib/date-picker/date-picker.variable.css +258 -0
  40. package/lib/date-picker/index.js +1 -0
  41. package/lib/date-picker/panel/date-range.d.ts +4 -4
  42. package/lib/dialog/dialog.css +137 -8
  43. package/lib/dialog/dialog.variable.css +395 -8
  44. package/lib/divider/divider.css +132 -3
  45. package/lib/divider/divider.variable.css +258 -0
  46. package/lib/dropdown/dropdown.css +129 -0
  47. package/lib/dropdown/dropdown.variable.css +387 -0
  48. package/lib/exception/exception.css +129 -0
  49. package/lib/exception/exception.variable.css +258 -0
  50. package/lib/fixed-navbar/fixed-navbar.css +133 -4
  51. package/lib/fixed-navbar/fixed-navbar.variable.css +258 -0
  52. package/lib/form/form.css +129 -0
  53. package/lib/form/form.variable.css +258 -0
  54. package/lib/form/index.js +0 -1
  55. package/lib/image/image-viewer.css +129 -0
  56. package/lib/image/image-viewer.variable.css +258 -0
  57. package/lib/image/image.css +129 -0
  58. package/lib/image/image.variable.css +387 -0
  59. package/lib/image/index.js +0 -1
  60. package/lib/index.js +1 -1
  61. package/lib/info-box/info-box.css +133 -4
  62. package/lib/info-box/info-box.variable.css +258 -0
  63. package/lib/input/index.js +0 -1
  64. package/lib/input/input.css +201 -72
  65. package/lib/input/input.variable.css +459 -72
  66. package/lib/link/link.css +145 -16
  67. package/lib/link/link.variable.css +258 -0
  68. package/lib/loading/loading.css +145 -16
  69. package/lib/loading/loading.variable.css +403 -16
  70. package/lib/menu/menu.css +147 -18
  71. package/lib/menu/menu.variable.css +405 -18
  72. package/lib/menu/submenu.css +129 -0
  73. package/lib/menu/submenu.variable.css +258 -0
  74. package/lib/message/message.css +150 -21
  75. package/lib/message/message.variable.css +258 -0
  76. package/lib/modal/modal.css +133 -4
  77. package/lib/modal/modal.variable.css +391 -4
  78. package/lib/navigation/navigation.css +131 -2
  79. package/lib/navigation/navigation.variable.css +258 -0
  80. package/lib/notify/notify.css +136 -7
  81. package/lib/notify/notify.variable.css +258 -0
  82. package/lib/pagination/pagination.css +130 -1
  83. package/lib/pagination/pagination.variable.css +258 -0
  84. package/lib/plugin-popover/index.js +0 -1
  85. package/lib/pop-confirm/pop-confirm.css +129 -0
  86. package/lib/pop-confirm/pop-confirm.variable.css +258 -0
  87. package/lib/popover/index.js +0 -1
  88. package/lib/popover/popover.css +129 -0
  89. package/lib/popover/popover.variable.css +258 -0
  90. package/lib/process/process.css +142 -13
  91. package/lib/process/process.variable.css +258 -0
  92. package/lib/progress/index.js +0 -1
  93. package/lib/progress/progress.css +133 -4
  94. package/lib/progress/progress.variable.css +391 -4
  95. package/lib/radio/radio.css +171 -42
  96. package/lib/radio/radio.variable.css +258 -0
  97. package/lib/rate/rate.css +129 -0
  98. package/lib/rate/rate.variable.css +258 -0
  99. package/lib/resize-layout/resize-layout.css +129 -0
  100. package/lib/resize-layout/resize-layout.variable.css +258 -0
  101. package/lib/scrollbar/scrollbar.css +129 -0
  102. package/lib/scrollbar/scrollbar.variable.css +258 -0
  103. package/lib/search-select/search-select.css +162 -33
  104. package/lib/search-select/search-select.variable.css +420 -33
  105. package/lib/select/index.js +0 -2
  106. package/lib/select/select.css +168 -39
  107. package/lib/select/select.variable.css +426 -39
  108. package/lib/sideslider/sideslider.css +130 -1
  109. package/lib/sideslider/sideslider.variable.css +258 -0
  110. package/lib/slider/slider.css +134 -5
  111. package/lib/slider/slider.variable.css +258 -0
  112. package/lib/steps/steps.css +167 -38
  113. package/lib/steps/steps.variable.css +258 -0
  114. package/lib/styles/mixins/animate.css +129 -0
  115. package/lib/styles/mixins/animate.variable.css +258 -0
  116. package/lib/styles/mixins/mixins.css +129 -0
  117. package/lib/styles/mixins/mixins.variable.css +129 -0
  118. package/lib/styles/mixins/popper.css +129 -0
  119. package/lib/styles/mixins/popper.variable.css +258 -0
  120. package/lib/styles/mixins/scroll.css +129 -0
  121. package/lib/styles/mixins/scroll.variable.css +258 -0
  122. package/lib/styles/reset.css +129 -0
  123. package/lib/styles/reset.variable.css +258 -0
  124. package/lib/styles/themes/themes.css +129 -0
  125. package/lib/styles/themes/themes.less +306 -127
  126. package/lib/styles/themes/themes.variable.css +129 -0
  127. package/lib/swiper/swiper.css +129 -0
  128. package/lib/swiper/swiper.variable.css +258 -0
  129. package/lib/switcher/switcher.css +146 -17
  130. package/lib/switcher/switcher.variable.css +404 -17
  131. package/lib/tab/tab.css +146 -17
  132. package/lib/tab/tab.variable.css +258 -0
  133. package/lib/table/const.d.ts +12 -0
  134. package/lib/table/events.d.ts +2 -98
  135. package/lib/table/hooks/use-column-resize.d.ts +5 -0
  136. package/lib/table/{plugins → hooks}/use-column-template.d.ts +1 -2
  137. package/lib/table/hooks/use-columns.d.ts +53 -0
  138. package/lib/table/{plugins → hooks}/use-draggable.d.ts +2 -2
  139. package/lib/table/hooks/use-fixed-column.d.ts +10 -0
  140. package/lib/table/hooks/use-head.d.ts +15 -0
  141. package/lib/table/hooks/use-layout.d.ts +20 -0
  142. package/lib/table/hooks/use-pagination.d.ts +16 -0
  143. package/lib/table/hooks/use-render.d.ts +23 -0
  144. package/lib/table/hooks/use-rows.d.ts +25 -0
  145. package/lib/table/hooks/use-settings.d.ts +23 -0
  146. package/lib/table/index.d.ts +27 -502
  147. package/lib/table/index.js +3125 -3524
  148. package/lib/table/plugins/head-filter.css +129 -0
  149. package/lib/table/plugins/head-filter.d.ts +2 -1
  150. package/lib/table/plugins/head-filter.variable.css +258 -0
  151. package/lib/table/plugins/head-sort.css +129 -0
  152. package/lib/table/plugins/head-sort.variable.css +258 -0
  153. package/lib/table/plugins/settings.css +130 -0
  154. package/lib/table/plugins/settings.less +1 -0
  155. package/lib/table/plugins/settings.variable.css +259 -0
  156. package/lib/table/props.d.ts +17 -8
  157. package/lib/table/table.css +321 -191
  158. package/lib/table/table.d.ts +18 -174
  159. package/lib/table/table.less +24 -22
  160. package/lib/table/table.variable.css +579 -191
  161. package/lib/table/utils.d.ts +24 -3
  162. package/lib/table-column/index.js +18 -2
  163. package/lib/tag/tag.css +134 -5
  164. package/lib/tag/tag.variable.css +258 -0
  165. package/lib/tag-input/tag-input.css +147 -18
  166. package/lib/tag-input/tag-input.variable.css +258 -0
  167. package/lib/time-picker/time-picker.css +129 -0
  168. package/lib/time-picker/time-picker.variable.css +258 -0
  169. package/lib/timeline/timeline.css +148 -19
  170. package/lib/timeline/timeline.variable.css +258 -0
  171. package/lib/transfer/transfer.css +148 -19
  172. package/lib/transfer/transfer.variable.css +258 -0
  173. package/lib/tree/tree.css +138 -9
  174. package/lib/tree/tree.variable.css +396 -9
  175. package/lib/upload/upload.css +156 -27
  176. package/lib/upload/upload.variable.css +414 -27
  177. package/lib/virtual-render/index.js +1 -1
  178. package/lib/virtual-render/virtual-render.css +129 -0
  179. package/lib/virtual-render/virtual-render.variable.css +387 -0
  180. package/package.json +1 -1
  181. package/lib/table/plugins/col-group.d.ts +0 -38
  182. package/lib/table/plugins/settings.d.ts +0 -16
  183. package/lib/table/plugins/use-active-columns.d.ts +0 -16
  184. package/lib/table/plugins/use-column-resize.d.ts +0 -35
  185. package/lib/table/plugins/use-fixed-column.d.ts +0 -27
  186. package/lib/table/plugins/use-head-cell.d.ts +0 -7
  187. package/lib/table/plugins/use-pagination.d.ts +0 -23
  188. package/lib/table/use-attributes.d.ts +0 -62
  189. package/lib/table/use-column.d.ts +0 -155
  190. package/lib/table/use-common.d.ts +0 -1679
  191. package/lib/table/use-render.d.ts +0 -11
  192. /package/lib/table/{plugins → components}/body-empty.d.ts +0 -0
  193. /package/lib/table/{plugins → hooks}/use-observer-resize.d.ts +0 -0
  194. /package/lib/table/{plugins → hooks}/use-scroll-loading.d.ts +0 -0
  195. /package/lib/table/{plugins → hooks}/use-shift-key.d.ts +0 -0
@@ -0,0 +1,53 @@
1
+ import { IEmptyObject } from '../const';
2
+ import { Column, TablePropTypes } from '../props';
3
+ declare const useColumns: (props: TablePropTypes) => {
4
+ needColSpan: import("vue").ComputedRef<boolean>;
5
+ needRowSpan: import("vue").ComputedRef<boolean>;
6
+ headHeight: import("vue").ComputedRef<number>;
7
+ tableColumnSchema: WeakMap<object, any> & Omit<WeakMap<object, any>, keyof WeakMap<any, any>>;
8
+ tableColumnList: any[];
9
+ visibleColumns: any[];
10
+ debounceUpdateColumns: import("lodash").DebouncedFunc<(columns: any) => void>;
11
+ sortColumns: any[];
12
+ filterColumns: any[];
13
+ clearColumnSort: () => void;
14
+ formatColumns: () => void;
15
+ isHiddenColumn: (col: Column) => any;
16
+ getColumnId: (col: Column) => any;
17
+ getColumnOrderWidth: (col: Column, orders?: string[]) => number;
18
+ getColumnAttribute: (col: Column | IEmptyObject, attributeName: string) => any;
19
+ getHeadColumnClass: (column: Column, colIndex: number) => {
20
+ [x: string]: boolean;
21
+ column_fixed: boolean;
22
+ column_fixed_left: boolean;
23
+ column_fixed_right: boolean;
24
+ };
25
+ getColumnClass: (column: Column, colIndex: number) => {
26
+ [x: string]: boolean;
27
+ column_fixed: boolean;
28
+ column_fixed_left: boolean;
29
+ column_fixed_right: boolean;
30
+ };
31
+ getFixedStlye: (column: Column) => any;
32
+ getColumnRect: (column: Column) => any;
33
+ getColumnCustomClass: (column: any, row?: any) => any;
34
+ getColumnRefAttribute: (col: Column | IEmptyObject, attributeName: string) => any;
35
+ resolveEventListener: (col: Column) => any;
36
+ setColumnIsHidden: (column: Column, value?: boolean) => void;
37
+ setColumnResizeWidth: (column: Column, value: number) => void;
38
+ setColumnSortOption: (column: Column, option: Record<string, any>) => void;
39
+ setColumnFilterOption: (column: Column, option: Record<string, any>) => void;
40
+ setColumnAttributeBySettings: (settings: any, checkedVal?: string[]) => void;
41
+ setColumnAttribute: (col: Column, attrName: string, attrValue: string | number | boolean | any[] | Record<string, any> | ((...args: any[]) => boolean | number | string | void)) => void;
42
+ setColumnSortActive: (column: Column, active: boolean) => void;
43
+ setFixedStyle: (column: Column, style: any) => void;
44
+ setColumnRect: (col: any, { left, right, width, height }: {
45
+ left?: number;
46
+ right?: number;
47
+ width?: number;
48
+ height?: number;
49
+ }) => void;
50
+ setVisibleColumns: () => void;
51
+ };
52
+ export type UseColumns = ReturnType<typeof useColumns>;
53
+ export default useColumns;
@@ -1,7 +1,7 @@
1
1
  import { SetupContext } from 'vue';
2
2
  import { TablePropTypes } from '../props';
3
- import { ITableResponse } from '../use-attributes';
4
- declare const _default: (props: TablePropTypes, resp: ITableResponse, ctx: SetupContext<any>) => {
3
+ import { UseRows } from './use-rows';
4
+ declare const _default: (props: TablePropTypes, rows: UseRows, ctx: SetupContext<any>) => {
5
5
  onDragenter?: undefined;
6
6
  onDragleave?: undefined;
7
7
  onDragstart?: undefined;
@@ -0,0 +1,10 @@
1
+ import { TablePropTypes } from '../props';
2
+ import { UseColumns } from './use-columns';
3
+ /**
4
+ * 固定列Hooks
5
+ */
6
+ declare const _default: (_props: TablePropTypes, columns: UseColumns) => {
7
+ renderFixedRows: () => JSX.Element[];
8
+ resolveFixedColumnStyle: () => void;
9
+ };
10
+ export default _default;
@@ -0,0 +1,15 @@
1
+ import { SetupContext } from 'vue';
2
+ import { Column, TablePropTypes } from '../props';
3
+ import { UseColumns } from './use-columns';
4
+ import { UseRows } from './use-rows';
5
+ declare const _default: ({ props, columns, rows, ctx, column, index, }: {
6
+ props: TablePropTypes;
7
+ columns: UseColumns;
8
+ ctx: SetupContext;
9
+ column: Column;
10
+ index: number;
11
+ rows: UseRows;
12
+ }) => {
13
+ getTH: () => JSX.Element;
14
+ };
15
+ export default _default;
@@ -0,0 +1,20 @@
1
+ import { Ref } from 'vue';
2
+ import { TablePropTypes } from '../props';
3
+ declare const _default: (props: TablePropTypes, ctx: any) => {
4
+ renderContainer: (childrend: any) => JSX.Element;
5
+ renderHeader: (childrend?: any, settings?: any) => JSX.Element;
6
+ renderBody: (list: any, childrend?: any, fixedRows?: any, loadingRow?: any) => JSX.Element;
7
+ renderFooter: (childrend?: any) => JSX.Element;
8
+ setBodyHeight: (height: number | string) => void;
9
+ setFootHeight: (height: number) => void;
10
+ setTranslateX: (val: number) => void;
11
+ setDragOffsetX: (val: number) => void;
12
+ setFixedColumns: (values: any[]) => void;
13
+ setOffsetRight: () => void;
14
+ setLineHeight: (val: number) => void;
15
+ refRoot: Ref<any>;
16
+ refHead: Ref<any>;
17
+ refBody: Ref<any>;
18
+ refFooter: Ref<any>;
19
+ };
20
+ export default _default;
@@ -0,0 +1,16 @@
1
+ import { TablePropTypes } from '../props';
2
+ declare const usePagination: (props: TablePropTypes) => {
3
+ options: {
4
+ enabled: boolean;
5
+ count: number;
6
+ limit: number;
7
+ current: number;
8
+ align: string;
9
+ layout: string[];
10
+ };
11
+ isShowPagination: import("vue").ComputedRef<boolean>;
12
+ setPagination: (option: Record<string, any>) => void;
13
+ disabledPagination: (disable?: boolean) => void;
14
+ };
15
+ export type UsePagination = ReturnType<typeof usePagination>;
16
+ export default usePagination;
@@ -0,0 +1,23 @@
1
+ import { SetupContext } from 'vue';
2
+ import { TablePropTypes } from '../props';
3
+ import { UseColumns } from './use-columns';
4
+ import { UsePagination } from './use-pagination';
5
+ import { UseRows } from './use-rows';
6
+ import { UseSettings } from './use-settings';
7
+ type RenderType = {
8
+ props: TablePropTypes;
9
+ ctx: SetupContext;
10
+ columns: UseColumns;
11
+ rows: UseRows;
12
+ pagination: UsePagination;
13
+ settings: UseSettings;
14
+ };
15
+ declare const _default: ({ props, ctx, columns, rows, pagination, settings }: RenderType) => {
16
+ renderColumns: () => JSX.Element;
17
+ renderTBody: (list?: any) => import("vue").VNode<import("vue").RendererNode, import("vue").RendererElement, {
18
+ [key: string]: any;
19
+ }>[] | JSX.Element;
20
+ renderTFoot: () => JSX.Element;
21
+ setDragEvents: (events: Record<string, Function>) => void;
22
+ };
23
+ export default _default;
@@ -0,0 +1,25 @@
1
+ import { IEmptyObject } from '../const';
2
+ import { TablePropTypes } from '../props';
3
+ declare const useRows: (props: TablePropTypes) => {
4
+ setRowIndex: (row: any, index: number) => void;
5
+ setRowExpand: (row: any, isExpand: boolean) => void;
6
+ isRowChecked: (row: any, index: number) => any;
7
+ setPageRowList: (rowList: any[]) => void;
8
+ clearSelection: () => void;
9
+ formatDataSchema: () => void;
10
+ toggleRowSelection: (row: any) => void;
11
+ setRowSelectionAll: (val: boolean) => void;
12
+ setRowSelection: (row: any, isSelected: boolean, index?: number) => void;
13
+ setAllRowExpand: (value?: boolean) => void;
14
+ setTableIsNeedRowSpan: (val: boolean) => void;
15
+ getRowAttribute: (item: IEmptyObject | any, attrName: string) => any;
16
+ getRowSelection: () => any[];
17
+ getRowIndeterminate: () => any;
18
+ getRowCheckedAllValue: () => any;
19
+ changePageRowIndex: (sourceIndex: any, targetIndex: any) => void;
20
+ toggleAllSelection: (value?: boolean) => void;
21
+ tableRowList: import("vue").ComputedRef<any[]>;
22
+ pageRowList: any[];
23
+ };
24
+ export type UseRows = ReturnType<typeof useRows>;
25
+ export default useRows;
@@ -0,0 +1,23 @@
1
+ import { SetupContext } from 'vue';
2
+ import { TablePropTypes } from '../props';
3
+ import { UseColumns } from './use-columns';
4
+ declare const useSettings: (props: TablePropTypes, ctx: SetupContext, columns: UseColumns) => {
5
+ options: {
6
+ fields: any[];
7
+ checked: any[];
8
+ limit: number;
9
+ size: string;
10
+ sizeList: {
11
+ value?: string;
12
+ label?: string;
13
+ height?: number;
14
+ }[];
15
+ showLineHeight: boolean;
16
+ extCls: string;
17
+ trigger: string;
18
+ height: number;
19
+ };
20
+ renderSettings: () => JSX.Element;
21
+ };
22
+ export type UseSettings = ReturnType<typeof useSettings>;
23
+ export default useSettings;