bkui-vue 0.0.2-beta.113 → 0.0.2-beta.115
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 +30 -30
- package/dist/index.esm.js +5261 -5233
- package/dist/index.umd.js +30 -30
- package/dist/style.css +1 -1
- package/dist/style.variable.css +1 -1
- package/lib/affix/affix.css +1 -0
- package/lib/affix/affix.variable.css +3 -0
- package/lib/alert/alert.css +1 -0
- package/lib/alert/alert.variable.css +3 -0
- package/lib/backtop/backtop.css +1 -0
- package/lib/backtop/backtop.variable.css +4 -0
- package/lib/badge/badge.css +1 -0
- package/lib/badge/badge.variable.css +3 -0
- package/lib/breadcrumb/breadcrumb.css +1 -0
- package/lib/breadcrumb/breadcrumb.variable.css +4 -0
- package/lib/button/button.css +4 -0
- package/lib/button/button.less +86 -82
- package/lib/button/button.variable.css +6 -0
- package/lib/card/card.css +1 -0
- package/lib/card/card.variable.css +4 -0
- package/lib/cascader/cascader.css +1 -0
- package/lib/cascader/cascader.variable.css +4 -0
- package/lib/checkbox/checkbox.css +1 -0
- package/lib/checkbox/checkbox.variable.css +3 -0
- package/lib/code-diff/code-diff.css +1 -0
- package/lib/code-diff/code-diff.variable.css +3 -0
- package/lib/collapse/collapse.css +1 -0
- package/lib/collapse/collapse.variable.css +3 -0
- package/lib/collapse-transition/collapse-transition.css +1 -0
- package/lib/collapse-transition/collapse-transition.variable.css +3 -0
- package/lib/color-picker/color-picker.css +1 -0
- package/lib/color-picker/color-picker.variable.css +3 -0
- package/lib/config-provider/config-provider.css +1 -0
- package/lib/config-provider/config-provider.variable.css +3 -0
- package/lib/container/container.css +1 -0
- package/lib/container/container.variable.css +4 -0
- package/lib/date-picker/date-picker.css +1 -0
- package/lib/date-picker/date-picker.variable.css +3 -0
- package/lib/dialog/dialog.css +1 -0
- package/lib/dialog/dialog.variable.css +4 -0
- package/lib/divider/divider.css +1 -0
- package/lib/divider/divider.variable.css +3 -0
- package/lib/dropdown/dropdown.css +1 -0
- package/lib/dropdown/dropdown.variable.css +4 -0
- package/lib/dropdown/index.js +2 -2
- package/lib/exception/exception.css +1 -0
- package/lib/exception/exception.variable.css +3 -0
- package/lib/fixed-navbar/fixed-navbar.css +1 -0
- package/lib/fixed-navbar/fixed-navbar.variable.css +3 -0
- package/lib/form/form.css +1 -0
- package/lib/form/form.variable.css +3 -0
- package/lib/image/image-viewer.css +1 -0
- package/lib/image/image-viewer.variable.css +3 -0
- package/lib/image/image.css +1 -0
- package/lib/image/image.variable.css +4 -0
- package/lib/info-box/info-box.css +1 -0
- package/lib/info-box/info-box.variable.css +3 -0
- package/lib/input/input.css +1 -0
- package/lib/input/input.variable.css +4 -0
- package/lib/link/link.css +1 -0
- package/lib/link/link.variable.css +3 -0
- package/lib/loading/loading.css +1 -0
- package/lib/loading/loading.variable.css +4 -0
- package/lib/menu/menu.css +1 -0
- package/lib/menu/menu.variable.css +4 -0
- package/lib/menu/submenu.css +1 -0
- package/lib/menu/submenu.variable.css +3 -0
- package/lib/message/message.css +1 -0
- package/lib/message/message.variable.css +3 -0
- package/lib/modal/modal.css +1 -0
- package/lib/modal/modal.variable.css +4 -0
- package/lib/navigation/navigation.css +1 -0
- package/lib/navigation/navigation.variable.css +3 -0
- package/lib/notify/notify.css +1 -0
- package/lib/notify/notify.variable.css +3 -0
- package/lib/pagination/pagination.css +2 -0
- package/lib/pagination/pagination.less +1 -0
- package/lib/pagination/pagination.variable.css +4 -0
- package/lib/pop-confirm/pop-confirm.css +1 -0
- package/lib/pop-confirm/pop-confirm.variable.css +3 -0
- package/lib/popover/popover.css +1 -0
- package/lib/popover/popover.variable.css +3 -0
- package/lib/process/process.css +1 -0
- package/lib/process/process.variable.css +3 -0
- package/lib/progress/progress.css +1 -0
- package/lib/progress/progress.variable.css +4 -0
- package/lib/radio/radio.css +1 -0
- package/lib/radio/radio.variable.css +3 -0
- package/lib/rate/index.js +16 -4
- package/lib/rate/rate.css +1 -0
- package/lib/rate/rate.variable.css +3 -0
- package/lib/rate/star.css +4 -0
- package/lib/rate/star.less +3 -0
- package/lib/rate/star.variable.css +6 -0
- package/lib/resize-layout/resize-layout.css +3 -2
- package/lib/resize-layout/resize-layout.less +2 -2
- package/lib/resize-layout/resize-layout.variable.css +5 -2
- package/lib/search-select/search-select.css +1 -0
- package/lib/search-select/search-select.variable.css +4 -0
- package/lib/select/index.js +10 -0
- package/lib/select/select.css +1 -0
- package/lib/select/select.variable.css +4 -0
- package/lib/sideslider/sideslider.css +1 -0
- package/lib/sideslider/sideslider.variable.css +3 -0
- package/lib/slider/index.js +7 -1
- package/lib/slider/slider.css +3 -0
- package/lib/slider/slider.less +2 -0
- package/lib/slider/slider.variable.css +5 -0
- package/lib/steps/steps.css +1 -0
- package/lib/steps/steps.variable.css +3 -0
- package/lib/styles/mixins/animate.css +1 -0
- package/lib/styles/mixins/animate.variable.css +3 -0
- package/lib/styles/mixins/mixins.css +1 -0
- package/lib/styles/mixins/mixins.variable.css +1 -0
- package/lib/styles/mixins/popper.css +1 -0
- package/lib/styles/mixins/popper.variable.css +3 -0
- package/lib/styles/mixins/scroll.css +1 -0
- package/lib/styles/mixins/scroll.variable.css +3 -0
- package/lib/styles/reset.css +1 -0
- package/lib/styles/reset.variable.css +3 -0
- package/lib/styles/themes/themes.css +1 -0
- package/lib/styles/themes/themes.less +2 -0
- package/lib/styles/themes/themes.variable.css +1 -0
- package/lib/swiper/swiper.css +1 -0
- package/lib/swiper/swiper.variable.css +3 -0
- package/lib/switcher/switcher.css +1 -0
- package/lib/switcher/switcher.variable.css +4 -0
- package/lib/tab/tab.css +1 -0
- package/lib/tab/tab.variable.css +3 -0
- package/lib/table/index.d.ts +0 -18
- package/lib/table/index.js +72 -33
- package/lib/table/plugins/head-filter.css +1 -0
- package/lib/table/plugins/head-filter.variable.css +3 -0
- package/lib/table/plugins/head-sort.css +1 -0
- package/lib/table/plugins/head-sort.variable.css +3 -0
- package/lib/table/plugins/settings.css +1 -0
- package/lib/table/plugins/settings.d.ts +0 -7
- package/lib/table/plugins/settings.variable.css +3 -0
- package/lib/table/props.d.ts +0 -8
- package/lib/table/table.css +5 -0
- package/lib/table/table.d.ts +0 -11
- package/lib/table/table.variable.css +8 -0
- package/lib/table/use-attributes.d.ts +4 -1
- package/lib/table-column/index.js +1 -5
- package/lib/tag/tag.css +1 -0
- package/lib/tag/tag.variable.css +3 -0
- package/lib/tag-input/index.js +7 -4
- package/lib/tag-input/list-tag-render.d.ts +11 -0
- package/lib/tag-input/tag-input.css +1 -0
- package/lib/tag-input/tag-input.variable.css +3 -0
- package/lib/time-picker/time-picker.css +1 -0
- package/lib/time-picker/time-picker.variable.css +3 -0
- package/lib/timeline/timeline.css +1 -0
- package/lib/timeline/timeline.variable.css +3 -0
- package/lib/transfer/transfer.css +1 -0
- package/lib/transfer/transfer.variable.css +3 -0
- package/lib/tree/index.js +2 -1
- package/lib/tree/tree.css +1 -0
- package/lib/tree/tree.variable.css +4 -0
- package/lib/upload/upload.css +1 -0
- package/lib/upload/upload.variable.css +4 -0
- package/lib/virtual-render/virtual-render.css +1 -0
- package/lib/virtual-render/virtual-render.variable.css +4 -0
- package/package.json +1 -1
- package/lib/table/render.d.ts +0 -130
package/lib/table/index.js
CHANGED
@@ -614,11 +614,7 @@ var tableProps = {
|
|
614
614
|
/**
|
615
615
|
* 是否采用flex布局表格
|
616
616
|
*/
|
617
|
-
isFlex: external_shared_namespaceObject.PropTypes.bool.def(true)
|
618
|
-
/**
|
619
|
-
* VirtualRender throttleDelay
|
620
|
-
*/
|
621
|
-
throttleDelay: external_shared_namespaceObject.PropTypes.number.def(120)
|
617
|
+
isFlex: external_shared_namespaceObject.PropTypes.bool.def(true)
|
622
618
|
};
|
623
619
|
;// CONCATENATED MODULE: ../../packages/table/src/components/table-column.tsx
|
624
620
|
|
@@ -3009,9 +3005,13 @@ var getElementTextWidth = function getElementTextWidth(element, text) {
|
|
3009
3005
|
return getTextWidth(text || (element === null || element === void 0 ? void 0 : element.innerHTML), getCanvasFont(element));
|
3010
3006
|
};
|
3011
3007
|
var isColumnHidden = function isColumnHidden(settingFields, column, checked) {
|
3008
|
+
var getFieldValue = function getFieldValue(field) {
|
3009
|
+
var _field$field;
|
3010
|
+
return (_field$field = field.field) !== null && _field$field !== void 0 ? _field$field : field.id;
|
3011
|
+
};
|
3012
3012
|
var isSettingField = function isSettingField(col) {
|
3013
3013
|
return settingFields.some(function (field) {
|
3014
|
-
return field
|
3014
|
+
return getFieldValue(field) === resolvePropVal(col, ['field', 'type'], [col]);
|
3015
3015
|
});
|
3016
3016
|
};
|
3017
3017
|
return isSettingField(column) && checked.length && !checked.includes(resolvePropVal(column, ['field', 'type'], [column]));
|
@@ -3172,18 +3172,28 @@ function use_attributes_objectSpread(target) { for (var i = 1; i < arguments.len
|
|
3172
3172
|
|
3173
3173
|
|
3174
3174
|
/* harmony default export */ const use_attributes = (function (props) {
|
3175
|
-
var
|
3176
|
-
|
3177
|
-
|
3175
|
+
var getDefaultSettings = function getDefaultSettings() {
|
3176
|
+
var _ref, _SETTING_SIZE$size;
|
3177
|
+
var _props$settings = props.settings,
|
3178
|
+
size = _props$settings.size,
|
3179
|
+
_props$settings$field = _props$settings.fields,
|
3180
|
+
fields = _props$settings$field === void 0 ? [] : _props$settings$field,
|
3181
|
+
_props$settings$check = _props$settings.checked,
|
3182
|
+
checked = _props$settings$check === void 0 ? [] : _props$settings$check;
|
3183
|
+
var height = (_ref = (_SETTING_SIZE$size = SETTING_SIZE[size]) !== null && _SETTING_SIZE$size !== void 0 ? _SETTING_SIZE$size : props.rowHeight) !== null && _ref !== void 0 ? _ref : SETTING_SIZE.small;
|
3184
|
+
return {
|
3185
|
+
size: size,
|
3186
|
+
height: height,
|
3187
|
+
fields: fields,
|
3188
|
+
checked: checked
|
3189
|
+
};
|
3190
|
+
};
|
3178
3191
|
var formatData = (0,external_vue_namespaceObject.reactive)({
|
3179
3192
|
data: _toConsumableArray(props.data),
|
3180
3193
|
dataSchema: new WeakMap(),
|
3181
3194
|
columns: _toConsumableArray(props.columns),
|
3182
3195
|
columnSchema: new WeakMap(),
|
3183
|
-
settings:
|
3184
|
-
size: size,
|
3185
|
-
height: height
|
3186
|
-
},
|
3196
|
+
settings: getDefaultSettings(),
|
3187
3197
|
layout: {
|
3188
3198
|
hasScrollY: false,
|
3189
3199
|
bottom: 0,
|
@@ -3198,6 +3208,27 @@ function use_attributes_objectSpread(target) { for (var i = 1; i < arguments.len
|
|
3198
3208
|
multiFilter = _usePagination.multiFilter,
|
3199
3209
|
sort = _usePagination.sort,
|
3200
3210
|
resetStartEndIndex = _usePagination.resetStartEndIndex;
|
3211
|
+
var updateSettings = function updateSettings(settings, rowHeight) {
|
3212
|
+
if (settings) {
|
3213
|
+
var _ref2, _ref3;
|
3214
|
+
var size = settings.size,
|
3215
|
+
_settings$fields = settings.fields,
|
3216
|
+
fields = _settings$fields === void 0 ? [] : _settings$fields,
|
3217
|
+
_settings$checked = settings.checked,
|
3218
|
+
checked = _settings$checked === void 0 ? [] : _settings$checked;
|
3219
|
+
var height = (_ref2 = (_ref3 = rowHeight !== null && rowHeight !== void 0 ? rowHeight : SETTING_SIZE[size]) !== null && _ref3 !== void 0 ? _ref3 : props.rowHeight) !== null && _ref2 !== void 0 ? _ref2 : SETTING_SIZE.small;
|
3220
|
+
Object.assign(formatData.settings, {
|
3221
|
+
size: size,
|
3222
|
+
height: height,
|
3223
|
+
fields: fields,
|
3224
|
+
checked: checked
|
3225
|
+
});
|
3226
|
+
return;
|
3227
|
+
}
|
3228
|
+
if (rowHeight) {
|
3229
|
+
formatData.settings.height = rowHeight;
|
3230
|
+
}
|
3231
|
+
};
|
3201
3232
|
var resolveMinWidth = function resolveMinWidth(col) {
|
3202
3233
|
if (/^\d+/.test("".concat(col.minWidth))) {
|
3203
3234
|
return col.minWidth;
|
@@ -3211,8 +3242,6 @@ function use_attributes_objectSpread(target) { for (var i = 1; i < arguments.len
|
|
3211
3242
|
}
|
3212
3243
|
return minWidth;
|
3213
3244
|
};
|
3214
|
-
var checked = ((_props$settings = props.settings) === null || _props$settings === void 0 ? void 0 : _props$settings.checked) || [];
|
3215
|
-
var settingFields = ((_props$settings2 = props.settings) === null || _props$settings2 === void 0 ? void 0 : _props$settings2.fields) || [];
|
3216
3245
|
/**
|
3217
3246
|
* Format columns
|
3218
3247
|
* @param columns
|
@@ -3225,14 +3254,14 @@ function use_attributes_objectSpread(target) { for (var i = 1; i < arguments.len
|
|
3225
3254
|
var needColSpan = neepColspanOrRowspan(['colspan']);
|
3226
3255
|
(columns || []).forEach(function (col, index) {
|
3227
3256
|
var _Object$assign;
|
3228
|
-
var
|
3257
|
+
var _ref4 = needColSpan ? getColumnSpanConfig(col, index, skipColNum) : {
|
3229
3258
|
skipCol: false,
|
3230
3259
|
skipColumnNum: 0,
|
3231
3260
|
skipColLen: 0
|
3232
3261
|
},
|
3233
|
-
skipCol =
|
3234
|
-
skipColumnNum =
|
3235
|
-
skipColLen =
|
3262
|
+
skipCol = _ref4.skipCol,
|
3263
|
+
skipColumnNum = _ref4.skipColumnNum,
|
3264
|
+
skipColLen = _ref4.skipColLen;
|
3236
3265
|
skipColNum = skipColumnNum;
|
3237
3266
|
if (!formatData.columnSchema.has(col)) {
|
3238
3267
|
var _formatData$columnSch;
|
@@ -3241,7 +3270,7 @@ function use_attributes_objectSpread(target) { for (var i = 1; i < arguments.len
|
|
3241
3270
|
fn = _resolveColumnSortPro.fn,
|
3242
3271
|
scope = _resolveColumnSortPro.scope,
|
3243
3272
|
active = _resolveColumnSortPro.active;
|
3244
|
-
formatData.columnSchema.set(col, (_formatData$columnSch = {}, defineProperty_defineProperty(_formatData$columnSch, COLUMN_ATTRIBUTE.CALC_WIDTH, undefined), defineProperty_defineProperty(_formatData$columnSch, COLUMN_ATTRIBUTE.RESIZE_WIDTH, undefined), defineProperty_defineProperty(_formatData$columnSch, COLUMN_ATTRIBUTE.COL_MIN_WIDTH, resolveMinWidth(col)), defineProperty_defineProperty(_formatData$columnSch, COLUMN_ATTRIBUTE.LISTENERS, new Map()), defineProperty_defineProperty(_formatData$columnSch, COLUMN_ATTRIBUTE.WIDTH, col.width), defineProperty_defineProperty(_formatData$columnSch, COLUMN_ATTRIBUTE.IS_HIDDEN, isColumnHidden(
|
3273
|
+
formatData.columnSchema.set(col, (_formatData$columnSch = {}, defineProperty_defineProperty(_formatData$columnSch, COLUMN_ATTRIBUTE.CALC_WIDTH, undefined), defineProperty_defineProperty(_formatData$columnSch, COLUMN_ATTRIBUTE.RESIZE_WIDTH, undefined), defineProperty_defineProperty(_formatData$columnSch, COLUMN_ATTRIBUTE.COL_MIN_WIDTH, resolveMinWidth(col)), defineProperty_defineProperty(_formatData$columnSch, COLUMN_ATTRIBUTE.LISTENERS, new Map()), defineProperty_defineProperty(_formatData$columnSch, COLUMN_ATTRIBUTE.WIDTH, col.width), defineProperty_defineProperty(_formatData$columnSch, COLUMN_ATTRIBUTE.IS_HIDDEN, isColumnHidden(formatData.settings.fields, col, formatData.settings.checked)), defineProperty_defineProperty(_formatData$columnSch, COLUMN_ATTRIBUTE.COL_SORT_TYPE, type), defineProperty_defineProperty(_formatData$columnSch, COLUMN_ATTRIBUTE.COL_SORT_FN, fn), defineProperty_defineProperty(_formatData$columnSch, COLUMN_ATTRIBUTE.COL_FILTER_FN, undefined), defineProperty_defineProperty(_formatData$columnSch, COLUMN_ATTRIBUTE.COL_FILTER_SCOPE, undefined), defineProperty_defineProperty(_formatData$columnSch, COLUMN_ATTRIBUTE.COL_SORT_SCOPE, scope), defineProperty_defineProperty(_formatData$columnSch, COLUMN_ATTRIBUTE.COL_SORT_ACTIVE, active), defineProperty_defineProperty(_formatData$columnSch, COLUMN_ATTRIBUTE.COL_IS_DRAG, false), defineProperty_defineProperty(_formatData$columnSch, COLUMN_ATTRIBUTE.COL_SPAN, {
|
3245
3274
|
skipCol: skipCol,
|
3246
3275
|
skipColumnNum: skipColumnNum,
|
3247
3276
|
skipColLen: skipColLen
|
@@ -3385,10 +3414,10 @@ function use_attributes_objectSpread(target) { for (var i = 1; i < arguments.len
|
|
3385
3414
|
* @returns
|
3386
3415
|
*/
|
3387
3416
|
var getColumnOrderWidth = function getColumnOrderWidth(col) {
|
3388
|
-
var _formatData$columnSch4,
|
3417
|
+
var _formatData$columnSch4, _ref5, _target$orders$;
|
3389
3418
|
var orders = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : ORDER_LIST;
|
3390
3419
|
var target = (_formatData$columnSch4 = formatData.columnSchema.get(col)) !== null && _formatData$columnSch4 !== void 0 ? _formatData$columnSch4 : {};
|
3391
|
-
return (
|
3420
|
+
return (_ref5 = (_target$orders$ = target[orders[0]]) !== null && _target$orders$ !== void 0 ? _target$orders$ : target[orders[1]]) !== null && _ref5 !== void 0 ? _ref5 : target[orders[2]];
|
3392
3421
|
};
|
3393
3422
|
/**
|
3394
3423
|
* 指定列是否展示状态
|
@@ -3591,8 +3620,8 @@ function use_attributes_objectSpread(target) { for (var i = 1; i < arguments.len
|
|
3591
3620
|
var resolveColumnWidth = function resolveColumnWidth(root) {
|
3592
3621
|
var autoWidth = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : COL_MIN_WIDTH;
|
3593
3622
|
var offsetWidth = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : 0;
|
3594
|
-
var
|
3595
|
-
width =
|
3623
|
+
var _ref6 = root.getBoundingClientRect() || {},
|
3624
|
+
width = _ref6.width;
|
3596
3625
|
var availableWidth = width - offsetWidth;
|
3597
3626
|
// 可用来平均的宽度
|
3598
3627
|
var avgWidth = availableWidth;
|
@@ -3719,6 +3748,7 @@ function use_attributes_objectSpread(target) { for (var i = 1; i < arguments.len
|
|
3719
3748
|
sortData: sortData,
|
3720
3749
|
isCheckedAll: isCheckedAll,
|
3721
3750
|
hasCheckedRow: hasCheckedRow,
|
3751
|
+
updateSettings: updateSettings,
|
3722
3752
|
pageData: pageData,
|
3723
3753
|
localPagination: localPagination,
|
3724
3754
|
formatData: formatData
|
@@ -4966,8 +4996,7 @@ function settings_isSlot(s) {
|
|
4966
4996
|
name: 'Settings',
|
4967
4997
|
props: {
|
4968
4998
|
settings: ITableSettings,
|
4969
|
-
columns: external_shared_namespaceObject.PropTypes.arrayOf(IColumnType).def([])
|
4970
|
-
rowHeight: RowHeightFunctionNumberType.def(LINE_HEIGHT)
|
4999
|
+
columns: external_shared_namespaceObject.PropTypes.arrayOf(IColumnType).def([])
|
4971
5000
|
},
|
4972
5001
|
emits: ['change'],
|
4973
5002
|
setup: function setup(props, _ref) {
|
@@ -4992,7 +5021,7 @@ function settings_isSlot(s) {
|
|
4992
5021
|
}),
|
4993
5022
|
checked: [],
|
4994
5023
|
limit: 0,
|
4995
|
-
size:
|
5024
|
+
size: 'small',
|
4996
5025
|
sizeList: defaultSizeList,
|
4997
5026
|
showLineHeight: true
|
4998
5027
|
};
|
@@ -5000,7 +5029,7 @@ function settings_isSlot(s) {
|
|
5000
5029
|
return props.settings;
|
5001
5030
|
});
|
5002
5031
|
var activeSize = (0,external_vue_namespaceObject.ref)(localSettings.value.size || 'small');
|
5003
|
-
var activeHeight = (0,external_vue_namespaceObject.ref)(
|
5032
|
+
var activeHeight = (0,external_vue_namespaceObject.ref)(SETTING_SIZE.small);
|
5004
5033
|
var checkedFields = (0,external_vue_namespaceObject.ref)(localSettings.value.checked || []);
|
5005
5034
|
var className = resolveClassName('table-settings');
|
5006
5035
|
var theme = "light ".concat(className);
|
@@ -5317,10 +5346,9 @@ function use_render_isSlot(s) {
|
|
5317
5346
|
size = arg.size,
|
5318
5347
|
height = arg.height,
|
5319
5348
|
fields = arg.fields;
|
5320
|
-
tableResp.
|
5321
|
-
tableResp.
|
5349
|
+
tableResp.updateSettings(arg);
|
5350
|
+
tableResp.setColumnAttributeBySettings(props.settings, checked);
|
5322
5351
|
if (checked.length) {
|
5323
|
-
tableResp.setColumnAttributeBySettings(props.settings, checked);
|
5324
5352
|
(0,external_vue_namespaceObject.nextTick)(function () {
|
5325
5353
|
resetTableHeight(root.value);
|
5326
5354
|
});
|
@@ -5336,7 +5364,6 @@ function use_render_isSlot(s) {
|
|
5336
5364
|
"class": "table-head-settings",
|
5337
5365
|
"settings": props.settings,
|
5338
5366
|
"columns": columns.value,
|
5339
|
-
"rowHeight": props.rowHeight,
|
5340
5367
|
"onChange": handleSettingsChanged
|
5341
5368
|
}, {
|
5342
5369
|
"default": function _default() {
|
@@ -6152,6 +6179,18 @@ function table_objectSpread(target) { for (var i = 1; i < arguments.length; i++)
|
|
6152
6179
|
resetTableHeight(root.value);
|
6153
6180
|
});
|
6154
6181
|
});
|
6182
|
+
(0,external_vue_namespaceObject.watch)(function () {
|
6183
|
+
return [props.settings];
|
6184
|
+
}, function () {
|
6185
|
+
tableSchema.updateSettings(props.settings);
|
6186
|
+
}, {
|
6187
|
+
deep: true
|
6188
|
+
});
|
6189
|
+
(0,external_vue_namespaceObject.watch)(function () {
|
6190
|
+
return [props.rowHeight];
|
6191
|
+
}, function () {
|
6192
|
+
tableSchema.updateSettings(undefined, props.rowHeight);
|
6193
|
+
});
|
6155
6194
|
var handleScrollChanged = function handleScrollChanged(args) {
|
6156
6195
|
var _tableSchema$formatDa;
|
6157
6196
|
var preBottom = (_tableSchema$formatDa = tableSchema.formatData.layout.bottom) !== null && _tableSchema$formatDa !== void 0 ? _tableSchema$formatDa : 0;
|
@@ -6230,7 +6269,7 @@ function table_objectSpread(target) { for (var i = 1; i < arguments.length; i++)
|
|
6230
6269
|
}, scrollClass.value, {
|
6231
6270
|
"contentClassName": tableBodyContentClass.value,
|
6232
6271
|
"onContentScroll": handleScrollChanged,
|
6233
|
-
"throttleDelay":
|
6272
|
+
"throttleDelay": 120,
|
6234
6273
|
"scrollEvent": true,
|
6235
6274
|
"rowKey": props.rowKey,
|
6236
6275
|
"enabled": props.virtualEnabled,
|
@@ -11,6 +11,7 @@
|
|
11
11
|
--white-color: var(--white-color);
|
12
12
|
--whitesmoke-color: var(--whitesmoke-color);
|
13
13
|
--disable-color: var(--disable-color);
|
14
|
+
--disable-bg-color: var(--disable-bg-color);
|
14
15
|
--font-size-base: var(--font-size-base);
|
15
16
|
--font-size-medium: var(--font-size-medium);
|
16
17
|
--font-size-large: var(--font-size-large);
|
@@ -133,6 +134,7 @@
|
|
133
134
|
--white-color: white;
|
134
135
|
--whitesmoke-color: #fafbfd;
|
135
136
|
--disable-color: #dcdee5;
|
137
|
+
--disable-bg-color: #f9fafd;
|
136
138
|
--font-size-base: 12px;
|
137
139
|
--font-size-medium: 14px;
|
138
140
|
--font-size-large: 16px;
|
@@ -255,6 +257,7 @@
|
|
255
257
|
--white-color: white;
|
256
258
|
--whitesmoke-color: #fafbfd;
|
257
259
|
--disable-color: #dcdee5;
|
260
|
+
--disable-bg-color: #f9fafd;
|
258
261
|
--font-size-base: 12px;
|
259
262
|
--font-size-medium: 14px;
|
260
263
|
--font-size-large: 16px;
|
@@ -11,6 +11,7 @@
|
|
11
11
|
--white-color: var(--white-color);
|
12
12
|
--whitesmoke-color: var(--whitesmoke-color);
|
13
13
|
--disable-color: var(--disable-color);
|
14
|
+
--disable-bg-color: var(--disable-bg-color);
|
14
15
|
--font-size-base: var(--font-size-base);
|
15
16
|
--font-size-medium: var(--font-size-medium);
|
16
17
|
--font-size-large: var(--font-size-large);
|
@@ -133,6 +134,7 @@
|
|
133
134
|
--white-color: white;
|
134
135
|
--whitesmoke-color: #fafbfd;
|
135
136
|
--disable-color: #dcdee5;
|
137
|
+
--disable-bg-color: #f9fafd;
|
136
138
|
--font-size-base: 12px;
|
137
139
|
--font-size-medium: 14px;
|
138
140
|
--font-size-large: 16px;
|
@@ -255,6 +257,7 @@
|
|
255
257
|
--white-color: white;
|
256
258
|
--whitesmoke-color: #fafbfd;
|
257
259
|
--disable-color: #dcdee5;
|
260
|
+
--disable-bg-color: #f9fafd;
|
258
261
|
--font-size-base: 12px;
|
259
262
|
--font-size-medium: 14px;
|
260
263
|
--font-size-large: 16px;
|
@@ -3,21 +3,14 @@ declare const _default: import("vue").DefineComponent<{
|
|
3
3
|
columns: import("vue-types").VueTypeDef<import("../props").Column[]> & {
|
4
4
|
default: () => import("../props").Column[];
|
5
5
|
};
|
6
|
-
rowHeight: import("vue-types").VueTypeDef<import("../props").RowHeightFunctionNumber> & {
|
7
|
-
default: import("../props").RowHeightFunctionNumber;
|
8
|
-
};
|
9
6
|
}, () => "" | JSX.Element, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, "change"[], "change", import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
|
10
7
|
settings: import("vue-types").VueTypeDef<import("../props").ISettingPropType>;
|
11
8
|
columns: import("vue-types").VueTypeDef<import("../props").Column[]> & {
|
12
9
|
default: () => import("../props").Column[];
|
13
10
|
};
|
14
|
-
rowHeight: import("vue-types").VueTypeDef<import("../props").RowHeightFunctionNumber> & {
|
15
|
-
default: import("../props").RowHeightFunctionNumber;
|
16
|
-
};
|
17
11
|
}>> & {
|
18
12
|
onChange?: (...args: any[]) => any;
|
19
13
|
}, {
|
20
14
|
columns: import("../props").Column[];
|
21
|
-
rowHeight: import("../props").RowHeightFunctionNumber;
|
22
15
|
}, {}>;
|
23
16
|
export default _default;
|
@@ -11,6 +11,7 @@
|
|
11
11
|
--white-color: var(--white-color);
|
12
12
|
--whitesmoke-color: var(--whitesmoke-color);
|
13
13
|
--disable-color: var(--disable-color);
|
14
|
+
--disable-bg-color: var(--disable-bg-color);
|
14
15
|
--font-size-base: var(--font-size-base);
|
15
16
|
--font-size-medium: var(--font-size-medium);
|
16
17
|
--font-size-large: var(--font-size-large);
|
@@ -133,6 +134,7 @@
|
|
133
134
|
--white-color: white;
|
134
135
|
--whitesmoke-color: #fafbfd;
|
135
136
|
--disable-color: #dcdee5;
|
137
|
+
--disable-bg-color: #f9fafd;
|
136
138
|
--font-size-base: 12px;
|
137
139
|
--font-size-medium: 14px;
|
138
140
|
--font-size-large: 16px;
|
@@ -255,6 +257,7 @@
|
|
255
257
|
--white-color: white;
|
256
258
|
--whitesmoke-color: #fafbfd;
|
257
259
|
--disable-color: #dcdee5;
|
260
|
+
--disable-bg-color: #f9fafd;
|
258
261
|
--font-size-base: 12px;
|
259
262
|
--font-size-medium: 14px;
|
260
263
|
--font-size-large: 16px;
|
package/lib/table/props.d.ts
CHANGED
@@ -534,13 +534,5 @@ export declare const tableProps: {
|
|
534
534
|
} & {
|
535
535
|
default: boolean;
|
536
536
|
};
|
537
|
-
/**
|
538
|
-
* VirtualRender throttleDelay
|
539
|
-
*/
|
540
|
-
throttleDelay: import("vue-types").VueTypeValidableDef<number> & {
|
541
|
-
default: number;
|
542
|
-
} & {
|
543
|
-
default: number;
|
544
|
-
};
|
545
537
|
};
|
546
538
|
export {};
|
package/lib/table/table.css
CHANGED
@@ -11,6 +11,7 @@
|
|
11
11
|
--white-color: white;
|
12
12
|
--whitesmoke-color: #fafbfd;
|
13
13
|
--disable-color: #dcdee5;
|
14
|
+
--disable-bg-color: #f9fafd;
|
14
15
|
--font-size-base: 12px;
|
15
16
|
--font-size-medium: 14px;
|
16
17
|
--font-size-large: 16px;
|
@@ -527,6 +528,9 @@
|
|
527
528
|
cursor: not-allowed;
|
528
529
|
border-color: var(--disable-color);
|
529
530
|
}
|
531
|
+
.bk-button.is-disabled:not(.is-text) {
|
532
|
+
background-color: var(--disable-bg-color);
|
533
|
+
}
|
530
534
|
.bk-button-group {
|
531
535
|
display: inline-block;
|
532
536
|
font-size: 0;
|
@@ -673,6 +677,7 @@
|
|
673
677
|
}
|
674
678
|
.bk-pagination-list {
|
675
679
|
display: flex;
|
680
|
+
margin-right: 8px;
|
676
681
|
}
|
677
682
|
.bk-pagination-list-pre-batch,
|
678
683
|
.bk-pagination-list-next-batch,
|
package/lib/table/table.d.ts
CHANGED
@@ -151,11 +151,6 @@ declare const _default: import("vue").DefineComponent<{
|
|
151
151
|
} & {
|
152
152
|
default: boolean;
|
153
153
|
};
|
154
|
-
throttleDelay: import("vue-types").VueTypeValidableDef<number> & {
|
155
|
-
default: number;
|
156
|
-
} & {
|
157
|
-
default: number;
|
158
|
-
};
|
159
154
|
}, () => JSX.Element, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
|
160
155
|
columnPick: (_cols: import("./props").IColumnActive[]) => boolean;
|
161
156
|
columnFilter: (_args: {
|
@@ -387,11 +382,6 @@ declare const _default: import("vue").DefineComponent<{
|
|
387
382
|
} & {
|
388
383
|
default: boolean;
|
389
384
|
};
|
390
|
-
throttleDelay: import("vue-types").VueTypeValidableDef<number> & {
|
391
|
-
default: number;
|
392
|
-
} & {
|
393
|
-
default: number;
|
394
|
-
};
|
395
385
|
}>> & {
|
396
386
|
onSelect?: (_args: {
|
397
387
|
row: any;
|
@@ -485,7 +475,6 @@ declare const _default: import("vue").DefineComponent<{
|
|
485
475
|
checked: unknown[];
|
486
476
|
cellClass: any;
|
487
477
|
headHeight: number;
|
488
|
-
throttleDelay: number;
|
489
478
|
rowKey: any;
|
490
479
|
scrollLoading: boolean | {
|
491
480
|
[key: string]: any;
|
@@ -11,6 +11,7 @@
|
|
11
11
|
--white-color: var(--white-color);
|
12
12
|
--whitesmoke-color: var(--whitesmoke-color);
|
13
13
|
--disable-color: var(--disable-color);
|
14
|
+
--disable-bg-color: var(--disable-bg-color);
|
14
15
|
--font-size-base: var(--font-size-base);
|
15
16
|
--font-size-medium: var(--font-size-medium);
|
16
17
|
--font-size-large: var(--font-size-large);
|
@@ -133,6 +134,7 @@
|
|
133
134
|
--white-color: white;
|
134
135
|
--whitesmoke-color: #fafbfd;
|
135
136
|
--disable-color: #dcdee5;
|
137
|
+
--disable-bg-color: #f9fafd;
|
136
138
|
--font-size-base: 12px;
|
137
139
|
--font-size-medium: 14px;
|
138
140
|
--font-size-large: 16px;
|
@@ -255,6 +257,7 @@
|
|
255
257
|
--white-color: white;
|
256
258
|
--whitesmoke-color: #fafbfd;
|
257
259
|
--disable-color: #dcdee5;
|
260
|
+
--disable-bg-color: #f9fafd;
|
258
261
|
--font-size-base: 12px;
|
259
262
|
--font-size-medium: 14px;
|
260
263
|
--font-size-large: 16px;
|
@@ -377,6 +380,7 @@
|
|
377
380
|
--white-color: white;
|
378
381
|
--whitesmoke-color: #fafbfd;
|
379
382
|
--disable-color: #dcdee5;
|
383
|
+
--disable-bg-color: #f9fafd;
|
380
384
|
--font-size-base: 12px;
|
381
385
|
--font-size-medium: 14px;
|
382
386
|
--font-size-large: 16px;
|
@@ -893,6 +897,9 @@
|
|
893
897
|
cursor: not-allowed;
|
894
898
|
border-color: var(--disable-color);
|
895
899
|
}
|
900
|
+
.bk-button.is-disabled:not(.is-text) {
|
901
|
+
background-color: var(--disable-bg-color);
|
902
|
+
}
|
896
903
|
.bk-button-group {
|
897
904
|
display: inline-block;
|
898
905
|
font-size: 0;
|
@@ -1039,6 +1046,7 @@
|
|
1039
1046
|
}
|
1040
1047
|
.bk-pagination-list {
|
1041
1048
|
display: flex;
|
1049
|
+
margin-right: 8px;
|
1042
1050
|
}
|
1043
1051
|
.bk-pagination-list-pre-batch,
|
1044
1052
|
.bk-pagination-list-next-batch,
|
@@ -1,5 +1,5 @@
|
|
1
1
|
import { IEmptyObject } from './const';
|
2
|
-
import { Column, Settings, SortScope, TablePropTypes } from './props';
|
2
|
+
import { Column, Field, Settings, SortScope, TablePropTypes } from './props';
|
3
3
|
export type ITableFormatData = {
|
4
4
|
data: any[];
|
5
5
|
dataSchema: WeakMap<object, any>;
|
@@ -8,6 +8,8 @@ export type ITableFormatData = {
|
|
8
8
|
settings: {
|
9
9
|
size: string;
|
10
10
|
height: number;
|
11
|
+
fields: Field[];
|
12
|
+
checked: string[];
|
11
13
|
};
|
12
14
|
layout: {
|
13
15
|
bottom: number;
|
@@ -47,6 +49,7 @@ export type ITableResponse = {
|
|
47
49
|
hasCheckedRow: () => boolean;
|
48
50
|
setRowSelectionAll: (val: boolean) => void;
|
49
51
|
setRowIndeterminate: () => void;
|
52
|
+
updateSettings: (settings?: Settings, rowHeight?: number) => void;
|
50
53
|
pageData: any[];
|
51
54
|
localPagination: any;
|
52
55
|
formatData: ITableFormatData;
|
@@ -585,11 +585,7 @@ var tableProps = {
|
|
585
585
|
/**
|
586
586
|
* 是否采用flex布局表格
|
587
587
|
*/
|
588
|
-
isFlex: external_shared_namespaceObject.PropTypes.bool.def(true)
|
589
|
-
/**
|
590
|
-
* VirtualRender throttleDelay
|
591
|
-
*/
|
592
|
-
throttleDelay: external_shared_namespaceObject.PropTypes.number.def(120)
|
588
|
+
isFlex: external_shared_namespaceObject.PropTypes.bool.def(true)
|
593
589
|
};
|
594
590
|
;// CONCATENATED MODULE: ../../packages/table/src/components/table-column.tsx
|
595
591
|
|
package/lib/tag/tag.css
CHANGED
package/lib/tag/tag.variable.css
CHANGED
@@ -11,6 +11,7 @@
|
|
11
11
|
--white-color: var(--white-color);
|
12
12
|
--whitesmoke-color: var(--whitesmoke-color);
|
13
13
|
--disable-color: var(--disable-color);
|
14
|
+
--disable-bg-color: var(--disable-bg-color);
|
14
15
|
--font-size-base: var(--font-size-base);
|
15
16
|
--font-size-medium: var(--font-size-medium);
|
16
17
|
--font-size-large: var(--font-size-large);
|
@@ -133,6 +134,7 @@
|
|
133
134
|
--white-color: white;
|
134
135
|
--whitesmoke-color: #fafbfd;
|
135
136
|
--disable-color: #dcdee5;
|
137
|
+
--disable-bg-color: #f9fafd;
|
136
138
|
--font-size-base: 12px;
|
137
139
|
--font-size-medium: 14px;
|
138
140
|
--font-size-large: 16px;
|
@@ -255,6 +257,7 @@
|
|
255
257
|
--white-color: white;
|
256
258
|
--whitesmoke-color: #fafbfd;
|
257
259
|
--disable-color: #dcdee5;
|
260
|
+
--disable-bg-color: #f9fafd;
|
258
261
|
--font-size-base: 12px;
|
259
262
|
--font-size-medium: 14px;
|
260
263
|
--font-size-large: 16px;
|
package/lib/tag-input/index.js
CHANGED
@@ -414,14 +414,15 @@ var useTagsOverflow = function useTagsOverflow(tagInputRef, collapseTags, select
|
|
414
414
|
searchKeyword: external_shared_namespaceObject.PropTypes.string,
|
415
415
|
tpl: {
|
416
416
|
type: Function
|
417
|
-
}
|
417
|
+
},
|
418
|
+
disabled: external_shared_namespaceObject.PropTypes.bool.def(false)
|
418
419
|
},
|
419
420
|
render: function render() {
|
420
421
|
var _this = this;
|
421
422
|
var _usePrefix = (0,external_config_provider_namespaceObject.usePrefix)(),
|
422
423
|
resolveClassName = _usePrefix.resolveClassName;
|
423
424
|
var highlightKeyword = function highlightKeyword(value) {
|
424
|
-
if (_this.searchKeyword) {
|
425
|
+
if (_this.searchKeyword && !_this.disabled) {
|
425
426
|
var keywordReg = new RegExp("(".concat(_this.searchKeyword, ")"), 'i');
|
426
427
|
return value.replace(keywordReg, '<strong class="highlight-text">$1</strong>');
|
427
428
|
}
|
@@ -1602,7 +1603,8 @@ function tag_input_objectSpread(target) { for (var i = 1; i < arguments.length;
|
|
1602
1603
|
"displayKey": _this.displayKey,
|
1603
1604
|
"tpl": _this.tpl,
|
1604
1605
|
"searchKey": _this.searchKey,
|
1605
|
-
"searchKeyword": _this.curInputValue
|
1606
|
+
"searchKeyword": _this.curInputValue,
|
1607
|
+
"disabled": item.disabled
|
1606
1608
|
}, null)]);
|
1607
1609
|
})])]) : (0,external_vue_namespaceObject.createVNode)("li", {
|
1608
1610
|
"class": ["".concat(_this.resolveClassName('selector-list-item')), {
|
@@ -1614,7 +1616,8 @@ function tag_input_objectSpread(target) { for (var i = 1; i < arguments.length;
|
|
1614
1616
|
"displayKey": _this.displayKey,
|
1615
1617
|
"tpl": _this.tpl,
|
1616
1618
|
"searchKey": _this.searchKey,
|
1617
|
-
"searchKeyword": _this.curInputValue
|
1619
|
+
"searchKeyword": _this.curInputValue,
|
1620
|
+
"disabled": group.disabled
|
1618
1621
|
}, null)]);
|
1619
1622
|
}), _this.isPageLoading ? (0,external_vue_namespaceObject.createVNode)("li", {
|
1620
1623
|
"class": "".concat(_this.resolveClassName('selector-list-item'), " loading")
|
@@ -16,6 +16,11 @@ declare const _default: import("vue").DefineComponent<{
|
|
16
16
|
tpl: {
|
17
17
|
type: FunctionConstructor;
|
18
18
|
};
|
19
|
+
disabled: import("vue-types").VueTypeValidableDef<boolean> & {
|
20
|
+
default: boolean;
|
21
|
+
} & {
|
22
|
+
default: boolean;
|
23
|
+
};
|
19
24
|
}, unknown, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
|
20
25
|
node: import("vue-types").VueTypeValidableDef<{
|
21
26
|
[key: string]: any;
|
@@ -34,7 +39,13 @@ declare const _default: import("vue").DefineComponent<{
|
|
34
39
|
tpl: {
|
35
40
|
type: FunctionConstructor;
|
36
41
|
};
|
42
|
+
disabled: import("vue-types").VueTypeValidableDef<boolean> & {
|
43
|
+
default: boolean;
|
44
|
+
} & {
|
45
|
+
default: boolean;
|
46
|
+
};
|
37
47
|
}>>, {
|
48
|
+
disabled: boolean;
|
38
49
|
displayKey: string;
|
39
50
|
node: {
|
40
51
|
[key: string]: any;
|
@@ -11,6 +11,7 @@
|
|
11
11
|
--white-color: var(--white-color);
|
12
12
|
--whitesmoke-color: var(--whitesmoke-color);
|
13
13
|
--disable-color: var(--disable-color);
|
14
|
+
--disable-bg-color: var(--disable-bg-color);
|
14
15
|
--font-size-base: var(--font-size-base);
|
15
16
|
--font-size-medium: var(--font-size-medium);
|
16
17
|
--font-size-large: var(--font-size-large);
|
@@ -133,6 +134,7 @@
|
|
133
134
|
--white-color: white;
|
134
135
|
--whitesmoke-color: #fafbfd;
|
135
136
|
--disable-color: #dcdee5;
|
137
|
+
--disable-bg-color: #f9fafd;
|
136
138
|
--font-size-base: 12px;
|
137
139
|
--font-size-medium: 14px;
|
138
140
|
--font-size-large: 16px;
|
@@ -255,6 +257,7 @@
|
|
255
257
|
--white-color: white;
|
256
258
|
--whitesmoke-color: #fafbfd;
|
257
259
|
--disable-color: #dcdee5;
|
260
|
+
--disable-bg-color: #f9fafd;
|
258
261
|
--font-size-base: 12px;
|
259
262
|
--font-size-medium: 14px;
|
260
263
|
--font-size-large: 16px;
|