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.
- package/dist/index.cjs.js +63 -63
- package/dist/index.esm.js +15152 -15326
- package/dist/index.umd.js +63 -63
- package/dist/style.css +1 -1
- package/dist/style.variable.css +1 -1
- package/lib/affix/affix.css +129 -0
- package/lib/affix/affix.variable.css +258 -0
- package/lib/alert/alert.css +132 -3
- package/lib/alert/alert.variable.css +258 -0
- package/lib/backtop/backtop.css +132 -3
- package/lib/backtop/backtop.variable.css +390 -3
- package/lib/badge/badge.css +155 -26
- package/lib/badge/badge.variable.css +258 -0
- package/lib/breadcrumb/breadcrumb.css +134 -5
- package/lib/breadcrumb/breadcrumb.variable.css +392 -5
- package/lib/button/button.css +272 -143
- package/lib/button/button.variable.css +258 -0
- package/lib/button/index.js +0 -1
- package/lib/card/card.css +133 -4
- package/lib/card/card.variable.css +391 -4
- package/lib/cascader/cascader.css +152 -23
- package/lib/cascader/cascader.variable.css +410 -23
- package/lib/checkbox/checkbox.css +138 -9
- package/lib/checkbox/checkbox.variable.css +258 -0
- package/lib/code-diff/code-diff.css +129 -0
- package/lib/code-diff/code-diff.variable.css +258 -0
- package/lib/collapse/collapse.css +130 -1
- package/lib/collapse/collapse.variable.css +258 -0
- package/lib/collapse-transition/collapse-transition.css +129 -0
- package/lib/collapse-transition/collapse-transition.variable.css +258 -0
- package/lib/color-picker/color-picker.css +129 -0
- package/lib/color-picker/color-picker.variable.css +258 -0
- package/lib/config-provider/config-provider.css +129 -0
- package/lib/config-provider/config-provider.variable.css +258 -0
- package/lib/container/container.css +129 -0
- package/lib/container/container.variable.css +387 -0
- package/lib/container/index.js +0 -1
- package/lib/date-picker/date-picker.css +146 -17
- package/lib/date-picker/date-picker.variable.css +258 -0
- package/lib/date-picker/index.js +1 -0
- package/lib/date-picker/panel/date-range.d.ts +4 -4
- package/lib/dialog/dialog.css +137 -8
- package/lib/dialog/dialog.variable.css +395 -8
- package/lib/divider/divider.css +132 -3
- package/lib/divider/divider.variable.css +258 -0
- package/lib/dropdown/dropdown.css +129 -0
- package/lib/dropdown/dropdown.variable.css +387 -0
- package/lib/exception/exception.css +129 -0
- package/lib/exception/exception.variable.css +258 -0
- package/lib/fixed-navbar/fixed-navbar.css +133 -4
- package/lib/fixed-navbar/fixed-navbar.variable.css +258 -0
- package/lib/form/form.css +129 -0
- package/lib/form/form.variable.css +258 -0
- package/lib/form/index.js +0 -1
- package/lib/image/image-viewer.css +129 -0
- package/lib/image/image-viewer.variable.css +258 -0
- package/lib/image/image.css +129 -0
- package/lib/image/image.variable.css +387 -0
- package/lib/image/index.js +0 -1
- package/lib/index.js +1 -1
- package/lib/info-box/info-box.css +133 -4
- package/lib/info-box/info-box.variable.css +258 -0
- package/lib/input/index.js +0 -1
- package/lib/input/input.css +201 -72
- package/lib/input/input.variable.css +459 -72
- package/lib/link/link.css +145 -16
- package/lib/link/link.variable.css +258 -0
- package/lib/loading/loading.css +145 -16
- package/lib/loading/loading.variable.css +403 -16
- package/lib/menu/menu.css +147 -18
- package/lib/menu/menu.variable.css +405 -18
- package/lib/menu/submenu.css +129 -0
- package/lib/menu/submenu.variable.css +258 -0
- package/lib/message/message.css +150 -21
- package/lib/message/message.variable.css +258 -0
- package/lib/modal/modal.css +133 -4
- package/lib/modal/modal.variable.css +391 -4
- package/lib/navigation/navigation.css +131 -2
- package/lib/navigation/navigation.variable.css +258 -0
- package/lib/notify/notify.css +136 -7
- package/lib/notify/notify.variable.css +258 -0
- package/lib/pagination/pagination.css +130 -1
- package/lib/pagination/pagination.variable.css +258 -0
- package/lib/plugin-popover/index.js +0 -1
- package/lib/pop-confirm/pop-confirm.css +129 -0
- package/lib/pop-confirm/pop-confirm.variable.css +258 -0
- package/lib/popover/index.js +0 -1
- package/lib/popover/popover.css +129 -0
- package/lib/popover/popover.variable.css +258 -0
- package/lib/process/process.css +142 -13
- package/lib/process/process.variable.css +258 -0
- package/lib/progress/index.js +0 -1
- package/lib/progress/progress.css +133 -4
- package/lib/progress/progress.variable.css +391 -4
- package/lib/radio/radio.css +171 -42
- package/lib/radio/radio.variable.css +258 -0
- package/lib/rate/rate.css +129 -0
- package/lib/rate/rate.variable.css +258 -0
- package/lib/resize-layout/resize-layout.css +129 -0
- package/lib/resize-layout/resize-layout.variable.css +258 -0
- package/lib/scrollbar/scrollbar.css +129 -0
- package/lib/scrollbar/scrollbar.variable.css +258 -0
- package/lib/search-select/search-select.css +162 -33
- package/lib/search-select/search-select.variable.css +420 -33
- package/lib/select/index.js +0 -2
- package/lib/select/select.css +168 -39
- package/lib/select/select.variable.css +426 -39
- package/lib/sideslider/sideslider.css +130 -1
- package/lib/sideslider/sideslider.variable.css +258 -0
- package/lib/slider/slider.css +134 -5
- package/lib/slider/slider.variable.css +258 -0
- package/lib/steps/steps.css +167 -38
- package/lib/steps/steps.variable.css +258 -0
- package/lib/styles/mixins/animate.css +129 -0
- package/lib/styles/mixins/animate.variable.css +258 -0
- package/lib/styles/mixins/mixins.css +129 -0
- package/lib/styles/mixins/mixins.variable.css +129 -0
- package/lib/styles/mixins/popper.css +129 -0
- package/lib/styles/mixins/popper.variable.css +258 -0
- package/lib/styles/mixins/scroll.css +129 -0
- package/lib/styles/mixins/scroll.variable.css +258 -0
- package/lib/styles/reset.css +129 -0
- package/lib/styles/reset.variable.css +258 -0
- package/lib/styles/themes/themes.css +129 -0
- package/lib/styles/themes/themes.less +306 -127
- package/lib/styles/themes/themes.variable.css +129 -0
- package/lib/swiper/swiper.css +129 -0
- package/lib/swiper/swiper.variable.css +258 -0
- package/lib/switcher/switcher.css +146 -17
- package/lib/switcher/switcher.variable.css +404 -17
- package/lib/tab/tab.css +146 -17
- package/lib/tab/tab.variable.css +258 -0
- package/lib/table/const.d.ts +12 -0
- package/lib/table/events.d.ts +2 -98
- package/lib/table/hooks/use-column-resize.d.ts +5 -0
- package/lib/table/{plugins → hooks}/use-column-template.d.ts +1 -2
- package/lib/table/hooks/use-columns.d.ts +53 -0
- package/lib/table/{plugins → hooks}/use-draggable.d.ts +2 -2
- package/lib/table/hooks/use-fixed-column.d.ts +10 -0
- package/lib/table/hooks/use-head.d.ts +15 -0
- package/lib/table/hooks/use-layout.d.ts +20 -0
- package/lib/table/hooks/use-pagination.d.ts +16 -0
- package/lib/table/hooks/use-render.d.ts +23 -0
- package/lib/table/hooks/use-rows.d.ts +25 -0
- package/lib/table/hooks/use-settings.d.ts +23 -0
- package/lib/table/index.d.ts +27 -502
- package/lib/table/index.js +3125 -3524
- package/lib/table/plugins/head-filter.css +129 -0
- package/lib/table/plugins/head-filter.d.ts +2 -1
- package/lib/table/plugins/head-filter.variable.css +258 -0
- package/lib/table/plugins/head-sort.css +129 -0
- package/lib/table/plugins/head-sort.variable.css +258 -0
- package/lib/table/plugins/settings.css +130 -0
- package/lib/table/plugins/settings.less +1 -0
- package/lib/table/plugins/settings.variable.css +259 -0
- package/lib/table/props.d.ts +17 -8
- package/lib/table/table.css +321 -191
- package/lib/table/table.d.ts +18 -174
- package/lib/table/table.less +24 -22
- package/lib/table/table.variable.css +579 -191
- package/lib/table/utils.d.ts +24 -3
- package/lib/table-column/index.js +18 -2
- package/lib/tag/tag.css +134 -5
- package/lib/tag/tag.variable.css +258 -0
- package/lib/tag-input/tag-input.css +147 -18
- package/lib/tag-input/tag-input.variable.css +258 -0
- package/lib/time-picker/time-picker.css +129 -0
- package/lib/time-picker/time-picker.variable.css +258 -0
- package/lib/timeline/timeline.css +148 -19
- package/lib/timeline/timeline.variable.css +258 -0
- package/lib/transfer/transfer.css +148 -19
- package/lib/transfer/transfer.variable.css +258 -0
- package/lib/tree/tree.css +138 -9
- package/lib/tree/tree.variable.css +396 -9
- package/lib/upload/upload.css +156 -27
- package/lib/upload/upload.variable.css +414 -27
- package/lib/virtual-render/index.js +1 -1
- package/lib/virtual-render/virtual-render.css +129 -0
- package/lib/virtual-render/virtual-render.variable.css +387 -0
- package/package.json +1 -1
- package/lib/table/plugins/col-group.d.ts +0 -38
- package/lib/table/plugins/settings.d.ts +0 -16
- package/lib/table/plugins/use-active-columns.d.ts +0 -16
- package/lib/table/plugins/use-column-resize.d.ts +0 -35
- package/lib/table/plugins/use-fixed-column.d.ts +0 -27
- package/lib/table/plugins/use-head-cell.d.ts +0 -7
- package/lib/table/plugins/use-pagination.d.ts +0 -23
- package/lib/table/use-attributes.d.ts +0 -62
- package/lib/table/use-column.d.ts +0 -155
- package/lib/table/use-common.d.ts +0 -1679
- package/lib/table/use-render.d.ts +0 -11
- /package/lib/table/{plugins → components}/body-empty.d.ts +0 -0
- /package/lib/table/{plugins → hooks}/use-observer-resize.d.ts +0 -0
- /package/lib/table/{plugins → hooks}/use-scroll-loading.d.ts +0 -0
- /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 {
|
4
|
-
declare const _default: (props: TablePropTypes,
|
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;
|