@king-design/vue 3.3.0 → 3.3.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/__tests__/__snapshots__/Vue Next Demos.md +72 -66
- package/components/breadcrumb/index.js +1 -1
- package/components/breadcrumb/index.vdt.js +6 -2
- package/components/button/index.vdt.js +3 -2
- package/components/cascader/index.js +2 -1
- package/components/cascader/index.spec.js +32 -0
- package/components/cascader/index.vdt.js +8 -3
- package/components/cascader/styles.js +1 -1
- package/components/cascader/useFilterable.d.ts +2 -1
- package/components/cascader/useFilterable.js +15 -4
- package/components/checkbox/index.vdt.js +4 -2
- package/components/config/index.d.ts +2 -0
- package/components/config/index.js +3 -0
- package/components/datepicker/index.d.ts +1 -0
- package/components/datepicker/index.js +2 -0
- package/components/dialog/base.d.ts +1 -0
- package/components/dropdown/menu.js +1 -1
- package/components/input/index.d.ts +1 -1
- package/components/input/index.js +1 -1
- package/components/input/index.vdt.js +4 -2
- package/components/menu/styles.js +3 -3
- package/components/radio/index.vdt.js +4 -2
- package/components/select/base.d.ts +1 -0
- package/components/select/base.vdt.js +4 -2
- package/components/select/useInput.js +5 -1
- package/components/table/styles.js +3 -3
- package/components/tabs/index.d.ts +1 -0
- package/components/tooltip/styles.js +1 -1
- package/components/upload/index.vdt.js +4 -2
- package/components/upload/styles.js +1 -1
- package/package.json +2 -2
|
@@ -1,9 +1,13 @@
|
|
|
1
1
|
import _extends from "@babel/runtime-corejs3/helpers/extends";
|
|
2
2
|
import _spliceInstanceProperty from "@babel/runtime-corejs3/core-js/instance/splice";
|
|
3
|
-
import { createElementVNode as _$ce, noop as _$no, className as _$cn, createVNode as _$cv } from 'intact-vue-next';
|
|
3
|
+
import { createElementVNode as _$ce, createUnknownComponentVNode as _$cc, noop as _$no, className as _$cn, createVNode as _$cv } from 'intact-vue-next';
|
|
4
4
|
import { getRestProps, mapChildren } from '../utils';
|
|
5
5
|
import { BreadcrumbItem } from './item';
|
|
6
6
|
import { makeStyles } from './styles';
|
|
7
|
+
import { Icon } from '../icon';
|
|
8
|
+
var _$tmp0 = {
|
|
9
|
+
'className': 'k-icon-right'
|
|
10
|
+
};
|
|
7
11
|
export default function ($props, $blocks, $__proto__) {
|
|
8
12
|
var _classNameObj;
|
|
9
13
|
$blocks || ($blocks = {});
|
|
@@ -17,7 +21,7 @@ export default function ($props, $blocks, $__proto__) {
|
|
|
17
21
|
className = _this$get.className;
|
|
18
22
|
var k = this.config.k;
|
|
19
23
|
var classNameObj = (_classNameObj = {}, _classNameObj[k + "-breadcrumb"] = true, _classNameObj[className] = className, _classNameObj[makeStyles(k)] = true, _classNameObj);
|
|
20
|
-
var separatorVNode = _$ce(2, 'span', (_$blocks['separator'] = function ($super) {
|
|
24
|
+
var separatorVNode = _$ce(2, 'span', !$blocks.separator && !separator ? _$cc(Icon, _$tmp0) : (_$blocks['separator'] = function ($super) {
|
|
21
25
|
return separator;
|
|
22
26
|
}, __$blocks['separator'] = function ($super, data) {
|
|
23
27
|
var block = $blocks['separator'];
|
|
@@ -30,7 +30,8 @@ export default function ($props, $blocks, $__proto__) {
|
|
|
30
30
|
ghost = _this$get.ghost;
|
|
31
31
|
var _this$config = this.config,
|
|
32
32
|
cls = _this$config.cls,
|
|
33
|
-
k = _this$config.k
|
|
33
|
+
k = _this$config.k,
|
|
34
|
+
disableWave = _this$config.disableWave;
|
|
34
35
|
var checked = this.isChecked();
|
|
35
36
|
var isIcon = function isIcon(child) {
|
|
36
37
|
return child.tag === Icon || child.className && child.className.indexOf('icon') > -1;
|
|
@@ -66,7 +67,7 @@ export default function ($props, $blocks, $__proto__) {
|
|
|
66
67
|
var typeStyles = theme[type];
|
|
67
68
|
var waveColor = typeStyles && typeStyles.borderColor || theme.primary.borderColor;
|
|
68
69
|
return _$cc(Wave, {
|
|
69
|
-
'disabled': loading || disabled || type === 'none' || type === 'link',
|
|
70
|
+
'disabled': loading || disabled || type === 'none' || type === 'link' || disableWave,
|
|
70
71
|
'inset': type === 'flat' ? '-1px' : '-2px',
|
|
71
72
|
'color': waveColor,
|
|
72
73
|
'children': _$cc(DynamicButton, _extends({
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import _inheritsLoose from "@babel/runtime-corejs3/helpers/inheritsLoose";
|
|
2
2
|
import _extends from "@babel/runtime-corejs3/helpers/extends";
|
|
3
3
|
import _concatInstanceProperty from "@babel/runtime-corejs3/core-js/instance/concat";
|
|
4
|
+
import _valuesInstanceProperty from "@babel/runtime-corejs3/core-js/instance/values";
|
|
4
5
|
import template from './index.vdt';
|
|
5
6
|
import { BaseSelect } from '../select/base';
|
|
6
7
|
import { _$ } from '../../i18n';
|
|
@@ -41,7 +42,7 @@ export var Cascader = /*#__PURE__*/function (_BaseSelect) {
|
|
|
41
42
|
_this.value = useValue();
|
|
42
43
|
_this.label = useLabel(_this.fields);
|
|
43
44
|
_this.load = useLoad(_this.fields);
|
|
44
|
-
_this.filterable = useFilterable(_this.input.keywords, _this.value.setValue, _this.fields);
|
|
45
|
+
_this.filterable = useFilterable(_this.input.keywords, _this.value.setValue, _this.fields, _valuesInstanceProperty(_this.value));
|
|
45
46
|
_this.positionObj = {
|
|
46
47
|
my: 'left top',
|
|
47
48
|
at: 'right top',
|
|
@@ -433,4 +433,36 @@ describe('Cascader', function () {
|
|
|
433
433
|
}
|
|
434
434
|
}, _callee10);
|
|
435
435
|
})));
|
|
436
|
+
it('should only show submenu while the root menu will show', /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee11() {
|
|
437
|
+
var _mount10, instance, element, _element$querySelecto2, dom, input;
|
|
438
|
+
return _regeneratorRuntime.wrap(function _callee11$(_context14) {
|
|
439
|
+
while (1) switch (_context14.prev = _context14.next) {
|
|
440
|
+
case 0:
|
|
441
|
+
_mount10 = mount(FilterDemo), instance = _mount10[0], element = _mount10[1];
|
|
442
|
+
instance.set('values', [['beijing', 'haidian']]);
|
|
443
|
+
_context14.next = 4;
|
|
444
|
+
return wait();
|
|
445
|
+
case 4:
|
|
446
|
+
_element$querySelecto2 = element.querySelectorAll('.k-cascader'), dom = _element$querySelecto2[1];
|
|
447
|
+
dispatchEvent(dom, 'click');
|
|
448
|
+
_context14.next = 8;
|
|
449
|
+
return wait();
|
|
450
|
+
case 8:
|
|
451
|
+
input = dom.querySelector('.k-input-inner'); // should show layer when input empty string
|
|
452
|
+
input.value = 's';
|
|
453
|
+
dispatchEvent(input, 'input');
|
|
454
|
+
_context14.next = 13;
|
|
455
|
+
return wait();
|
|
456
|
+
case 13:
|
|
457
|
+
document.body.click();
|
|
458
|
+
_context14.next = 16;
|
|
459
|
+
return wait();
|
|
460
|
+
case 16:
|
|
461
|
+
expect(getElement('.k-cascader-menu')).to.not.exist;
|
|
462
|
+
case 17:
|
|
463
|
+
case "end":
|
|
464
|
+
return _context14.stop();
|
|
465
|
+
}
|
|
466
|
+
}, _callee11);
|
|
467
|
+
})));
|
|
436
468
|
});
|
|
@@ -17,7 +17,8 @@ export default function ($props, $blocks, $__proto__) {
|
|
|
17
17
|
trigger = _this$get.trigger,
|
|
18
18
|
filterable = _this$get.filterable,
|
|
19
19
|
fields = _this$get.fields,
|
|
20
|
-
multiple = _this$get.multiple
|
|
20
|
+
multiple = _this$get.multiple,
|
|
21
|
+
show = _this$get.show;
|
|
21
22
|
var k = this.config.k;
|
|
22
23
|
var baseMenuStyles = makeMenuStyles(k);
|
|
23
24
|
var classNameObj = (_classNameObj = {}, _classNameObj[k + "-cascader-menu"] = true, _classNameObj[makeMenuStyles(k)] = true, _classNameObj);
|
|
@@ -41,7 +42,7 @@ export default function ($props, $blocks, $__proto__) {
|
|
|
41
42
|
}
|
|
42
43
|
return _mapInstanceProperty(data).call(data, function (item, index) {
|
|
43
44
|
var value = getField(item, 'value');
|
|
44
|
-
var showed = isShowed(value, level);
|
|
45
|
+
var showed = show && isShowed(value, level);
|
|
45
46
|
var selected = parentSelected && isSelected(value, level);
|
|
46
47
|
var children = getField(item, 'children');
|
|
47
48
|
var Item = function Item() {
|
|
@@ -74,7 +75,8 @@ export default function ($props, $blocks, $__proto__) {
|
|
|
74
75
|
var _this$filterable = this.filterable,
|
|
75
76
|
filter = _filterInstanceProperty(_this$filterable),
|
|
76
77
|
keywords = _this$filterable.keywords.value,
|
|
77
|
-
selectByFilter = _this$filterable.selectByFilter
|
|
78
|
+
selectByFilter = _this$filterable.selectByFilter,
|
|
79
|
+
isSelectedItem = _this$filterable.isSelectedItem;
|
|
78
80
|
return _$su.call($this, {
|
|
79
81
|
'className': _$cn(k + "-cascader")
|
|
80
82
|
}, function ($blocks) {
|
|
@@ -93,9 +95,12 @@ export default function ($props, $blocks, $__proto__) {
|
|
|
93
95
|
var items = filter();
|
|
94
96
|
if (!items.length) return _$ce(2, 'div', _$('无匹配数据'), 0, _$cn(k + "-cascader-empty"));
|
|
95
97
|
return _$ma(items, function ($value, $key) {
|
|
98
|
+
var _$cn4;
|
|
96
99
|
return _$cc(DropdownItem, {
|
|
97
100
|
'ev-select': selectByFilter.bind(null, $value),
|
|
98
101
|
'disabled': $value.disabled,
|
|
102
|
+
'hideOnSelect': !multiple,
|
|
103
|
+
'className': _$cn((_$cn4 = {}, _$cn4[k + "-selected"] = isSelectedItem($value), _$cn4)),
|
|
99
104
|
'children': function () {
|
|
100
105
|
// highlight keywords
|
|
101
106
|
var label = _mapInstanceProperty($value).call($value, function (item) {
|
|
@@ -43,5 +43,5 @@ export var makeMenuStyles = cache(function makeMenuStyles(k) {
|
|
|
43
43
|
return /*#__PURE__*/css("min-width:", cascader.width, "!important;height:", cascader.height, ";overflow:auto;.", k, "-cascader-arrow{float:right;height:100%;margin-left:", cascader.arrowGap, ";line-height:inherit;}.", k, "-cascader-loading{display:block;text-align:center;margin-top:", cascader.loadingGap, ";}.", k, "-cascader-empty{padding:", cascader.empty.padding, ";color:", cascader.empty.color, ";text-align:center;}.", k, "-cascader-option{&.", k, "-selected{color:", cascader.selectedColor, ";}&.", k, "-active{background:", cascader.activeBgColor, ";}}");
|
|
44
44
|
});
|
|
45
45
|
export var makeFilterMenuStyles = cache(function makeFilterMenuStyles(k) {
|
|
46
|
-
return /*#__PURE__*/css("min-width:", _filterInstanceProperty(cascader).minWidth, "!important;height:auto;max-height:", _filterInstanceProperty(cascader).maxHeight, ";em{font-style:normal;color:", _filterInstanceProperty(cascader).highlightColor, ";}");
|
|
46
|
+
return /*#__PURE__*/css("min-width:", _filterInstanceProperty(cascader).minWidth, "!important;height:auto;max-height:", _filterInstanceProperty(cascader).maxHeight, ";em{font-style:normal;color:", _filterInstanceProperty(cascader).highlightColor, ";}.", k, "-dropdown-item.", k, "-selected{color:", cascader.selectedColor, ";}");
|
|
47
47
|
});
|
|
@@ -2,8 +2,9 @@ import type { CascaderData } from './';
|
|
|
2
2
|
import { State } from '../../hooks/useState';
|
|
3
3
|
import type { Value } from './useValue';
|
|
4
4
|
import type { useFields } from './useFields';
|
|
5
|
-
export declare function useFilterable(keywords: State<string>, setValue: (value: Value) => void, getField: ReturnType<typeof useFields>): {
|
|
5
|
+
export declare function useFilterable(keywords: State<string>, setValue: (value: Value) => void, getField: ReturnType<typeof useFields>, values: State<Value[]>): {
|
|
6
6
|
filter: () => CascaderData<any>[][];
|
|
7
7
|
selectByFilter: (data: CascaderData<any>[]) => void;
|
|
8
8
|
keywords: State<string>;
|
|
9
|
+
isSelectedItem: (data: CascaderData<any>[]) => boolean;
|
|
9
10
|
};
|
|
@@ -1,9 +1,11 @@
|
|
|
1
1
|
import _filterInstanceProperty from "@babel/runtime-corejs3/core-js/instance/filter";
|
|
2
2
|
import _includesInstanceProperty from "@babel/runtime-corejs3/core-js/instance/includes";
|
|
3
3
|
import _sliceInstanceProperty from "@babel/runtime-corejs3/core-js/instance/slice";
|
|
4
|
+
import _findInstanceProperty from "@babel/runtime-corejs3/core-js/instance/find";
|
|
4
5
|
import _mapInstanceProperty from "@babel/runtime-corejs3/core-js/instance/map";
|
|
5
6
|
import { useInstance } from 'intact-vue-next';
|
|
6
|
-
|
|
7
|
+
import { isEqualArray } from '../utils';
|
|
8
|
+
export function useFilterable(keywords, setValue, getField, values) {
|
|
7
9
|
var instance = useInstance();
|
|
8
10
|
function filter() {
|
|
9
11
|
var ret = [];
|
|
@@ -44,14 +46,23 @@ export function useFilterable(keywords, setValue, getField) {
|
|
|
44
46
|
return ret;
|
|
45
47
|
}
|
|
46
48
|
function selectByFilter(data) {
|
|
47
|
-
|
|
49
|
+
setValue(getValue(data));
|
|
50
|
+
}
|
|
51
|
+
function isSelectedItem(data) {
|
|
52
|
+
var _context2;
|
|
53
|
+
return !!_findInstanceProperty(_context2 = values.value).call(_context2, function (value) {
|
|
54
|
+
return isEqualArray(value, getValue(data));
|
|
55
|
+
});
|
|
56
|
+
}
|
|
57
|
+
function getValue(data) {
|
|
58
|
+
return _mapInstanceProperty(data).call(data, function (item) {
|
|
48
59
|
return getField(item, 'value');
|
|
49
60
|
});
|
|
50
|
-
setValue(value);
|
|
51
61
|
}
|
|
52
62
|
return {
|
|
53
63
|
filter: filter,
|
|
54
64
|
selectByFilter: selectByFilter,
|
|
55
|
-
keywords: keywords
|
|
65
|
+
keywords: keywords,
|
|
66
|
+
isSelectedItem: isSelectedItem
|
|
56
67
|
};
|
|
57
68
|
}
|
|
@@ -22,7 +22,9 @@ export default function ($props, $blocks, $__proto__) {
|
|
|
22
22
|
title = _this$get.title,
|
|
23
23
|
rest = _objectWithoutPropertiesLoose(_this$get, _excluded);
|
|
24
24
|
var isChecked = this.isChecked();
|
|
25
|
-
var
|
|
25
|
+
var _this$config = this.config,
|
|
26
|
+
k = _this$config.k,
|
|
27
|
+
disableWave = _this$config.disableWave;
|
|
26
28
|
var classNameObj = (_classNameObj = {}, _classNameObj[k + "-checkbox"] = true, _classNameObj[k + "-disabled"] = disabled, _classNameObj[k + "-checked"] = isChecked, _classNameObj[k + "-indeterminate"] = indeterminate, _classNameObj[className] = className, _classNameObj[makeStyles(k)] = true, _classNameObj);
|
|
27
29
|
var events = ['ev-click', 'ev-change', 'ev-mouseenter', 'ev-mouseleave'].reduce(function (memo, name) {
|
|
28
30
|
if (rest[name]) {
|
|
@@ -45,7 +47,7 @@ export default function ($props, $blocks, $__proto__) {
|
|
|
45
47
|
'ev-click': this.onClick,
|
|
46
48
|
'ev-keypress': this.onKeypress
|
|
47
49
|
}, events), [_$cc(Wave, {
|
|
48
|
-
'disabled': disabled,
|
|
50
|
+
'disabled': disabled || disableWave,
|
|
49
51
|
'inset': '-2px',
|
|
50
52
|
'children': _$ce(2, 'span', _$cv('input', _extends({
|
|
51
53
|
'type': 'checkbox',
|
|
@@ -2,11 +2,13 @@ import { ProviderProps } from '../context';
|
|
|
2
2
|
import { Component } from 'intact-vue-next';
|
|
3
3
|
export interface ConfigProps {
|
|
4
4
|
classNamePrefix?: string;
|
|
5
|
+
disableWave?: boolean;
|
|
5
6
|
}
|
|
6
7
|
declare const ConfigConsumer: import('intact-vue-next').ComponentConstructor<Component<import("../context").ConsumerProps<ConfigProps>, {}, {}, {}>>;
|
|
7
8
|
declare function useConfigContext(): {
|
|
8
9
|
cls: (name: string) => string;
|
|
9
10
|
readonly k: string;
|
|
11
|
+
readonly disableWave: boolean;
|
|
10
12
|
};
|
|
11
13
|
/**
|
|
12
14
|
* for vue/react type checking
|
|
@@ -4,6 +4,7 @@ import { State } from '../../hooks/useState';
|
|
|
4
4
|
import { Shortcut } from './shortcuts';
|
|
5
5
|
import { BasePicker, BasePickerProps, BasePickerEvents, BasePickerBlocks, Value } from './basepicker';
|
|
6
6
|
export * as shortcuts from './shortcuts';
|
|
7
|
+
export { dayjs };
|
|
7
8
|
export interface DatepickerProps<V extends Value = Value, M extends boolean = boolean, R extends boolean = boolean> extends BasePickerProps<V extends string ? V : V | string, M, R> {
|
|
8
9
|
type?: 'date' | 'datetime' | 'year' | 'month';
|
|
9
10
|
shortcuts?: Shortcut[];
|
|
@@ -5,6 +5,7 @@ import { __decorate } from "tslib";
|
|
|
5
5
|
import { provide } from 'intact-vue-next';
|
|
6
6
|
import template from './index.vdt';
|
|
7
7
|
import { DATEPICKER } from './constants';
|
|
8
|
+
import dayjs from './dayjs';
|
|
8
9
|
import { useValue } from './useValue';
|
|
9
10
|
import { isNullOrUndefined } from 'intact-shared';
|
|
10
11
|
import { _$ } from '../../i18n';
|
|
@@ -17,6 +18,7 @@ import { useKeyboards } from './useKeyboards';
|
|
|
17
18
|
import { BasePicker } from './basepicker';
|
|
18
19
|
import * as _shortcuts from './shortcuts';
|
|
19
20
|
export { _shortcuts as shortcuts };
|
|
21
|
+
export { dayjs };
|
|
20
22
|
var typeDefs = _extends({}, BasePicker.typeDefs, {
|
|
21
23
|
type: ['date', 'datetime', 'year', 'month'],
|
|
22
24
|
shortcuts: Array
|
|
@@ -75,7 +75,7 @@ function useKeyboardForDropdownMenu(dropdown) {
|
|
|
75
75
|
return focusByIndex(0);
|
|
76
76
|
};
|
|
77
77
|
// In Cascader the menu may have been replaced by another menu, in this case,
|
|
78
|
-
// if the dropdown has showed while we mounted the menu, add keydown listener
|
|
78
|
+
// if the dropdown has showed while we mounted the menu, add the keydown listener
|
|
79
79
|
if (dropdown.get('value')) {
|
|
80
80
|
onShow();
|
|
81
81
|
}
|
|
@@ -15,7 +15,7 @@ export interface InputProps<V extends Value = Value> extends InputHTMLAttributes
|
|
|
15
15
|
type?: HTMLInputTypes;
|
|
16
16
|
value?: V;
|
|
17
17
|
defaultValue?: string | number;
|
|
18
|
-
placeholder?: string;
|
|
18
|
+
placeholder?: string | number;
|
|
19
19
|
readonly?: boolean;
|
|
20
20
|
clearable?: boolean;
|
|
21
21
|
disabled?: boolean;
|
|
@@ -58,7 +58,9 @@ export default function ($props, $blocks, $__proto__) {
|
|
|
58
58
|
isFocus = _this$focusHook.isFocus,
|
|
59
59
|
focusInputOnClick = _this$focusHook.focusInputOnClick;
|
|
60
60
|
var isNotAutoRows = isStringOrNumber(rows) && rows !== 'auto';
|
|
61
|
-
var
|
|
61
|
+
var _this$config = this.config,
|
|
62
|
+
k = _this$config.k,
|
|
63
|
+
disableWave = _this$config.disableWave;
|
|
62
64
|
var classNameObj = (_classNameObj = {}, _classNameObj[k + "-input"] = true, _classNameObj[k + "-" + size] = size !== 'default', _classNameObj[k + "-group"] = $blocks.prepend || $blocks.append, _classNameObj[k + "-disabled"] = disabled, _classNameObj[k + "-clearable"] = clearable, _classNameObj[k + "-auto-width"] = autoWidth, _classNameObj[k + "-fluid"] = fluid, _classNameObj[k + "-stack-clear"] = stackClearIcon, _classNameObj[k + "-inline"] = inline, _classNameObj[k + "-flat"] = flat, _classNameObj[k + "-type-textarea"] = type === 'textarea', _classNameObj[k + "-focus"] = isFocus.value, _classNameObj[k + "-resize-" + resize] = type === 'textarea' && isNotAutoRows, _classNameObj[k + "-resize-none"] = type === 'textarea' && !isNotAutoRows, _classNameObj[className] = className, _classNameObj[makeStyles(k)] = true, _classNameObj);
|
|
63
65
|
var _this$showPassword = this.showPassword,
|
|
64
66
|
isShowPassword = _this$showPassword.isShow,
|
|
@@ -96,7 +98,7 @@ export default function ($props, $blocks, $__proto__) {
|
|
|
96
98
|
'children': function children(isInvalid) {
|
|
97
99
|
var _$cn3, _$cn4;
|
|
98
100
|
return _$cc(Wave, {
|
|
99
|
-
'disabled': waveDisabled || disabled || isInvalid,
|
|
101
|
+
'disabled': waveDisabled || disabled || isInvalid || disableWave,
|
|
100
102
|
'inset': '-2px',
|
|
101
103
|
'children': _$ce(2, 'div', [$blocks.prefix ? _$ce(2, 'div', (_$blocks['prefix'] = function ($super) {
|
|
102
104
|
return null;
|
|
@@ -20,7 +20,7 @@ var defaults = {
|
|
|
20
20
|
},
|
|
21
21
|
item: {
|
|
22
22
|
height: '40px',
|
|
23
|
-
padding: '0
|
|
23
|
+
padding: '0 12px',
|
|
24
24
|
bodyPadding: '0 4px',
|
|
25
25
|
color: '#aeaeb9',
|
|
26
26
|
hoverColor: '#fff',
|
|
@@ -36,7 +36,7 @@ var defaults = {
|
|
|
36
36
|
},
|
|
37
37
|
title: {
|
|
38
38
|
height: '40px',
|
|
39
|
-
padding: '0
|
|
39
|
+
padding: '0 12px',
|
|
40
40
|
color: '#fff'
|
|
41
41
|
},
|
|
42
42
|
icon: {
|
|
@@ -112,7 +112,7 @@ export { menu };
|
|
|
112
112
|
export var makeMenuStyles = cache(function makeMenuStyles(k) {
|
|
113
113
|
// we must increase the priority by adding &.${k}-menu
|
|
114
114
|
// to override the css of dropdownMenu
|
|
115
|
-
return /*#__PURE__*/css("&.", k, "-menu{width:", menu.width, ";transition:width ", menu.transition, ";background:", menu.bgColor, ";font-size:", menu.fontSize, ";position:relative;}.", k, "-icon{width:", menu.icon.width, ";margin-right:", menu.icon.gap, ";text-align:center;flex-shrink:0;}.", k, "-menu-header{height:", menu.header.height, ";padding:0
|
|
115
|
+
return /*#__PURE__*/css("&.", k, "-menu{width:", menu.width, ";transition:width ", menu.transition, ";background:", menu.bgColor, ";font-size:", menu.fontSize, ";position:relative;}.", k, "-icon{width:", menu.icon.width, ";margin-right:", menu.icon.gap, ";text-align:center;flex-shrink:0;}.", k, "-menu-header{height:", menu.header.height, ";padding:0 16px;color:", menu.header.color, ";font-size:", menu.header.fontSize, ";font-weight:bold;}.", k, "-menu-body{padding:", menu.item.bodyPadding, ";max-height:calc(100% - ", menu.header.height, ");overflow-y:auto;overflow-x:hidden;scrollbar-width:none;}.", k, "-menu-title{height:", menu.title.height, ";border-top:", menu.border, ";margin-top:4px;.", k, "-menu-name{transition:all ", menu.transition, ";height:", menu.title.height, ";color:", menu.title.color, ";font-weight:bold;}}.", k, "-menu-arrow-box{width:14px;height:60px;cursor:pointer;background:", menu.bgColor, ";border-radius:0 8px 8px 0;position:absolute;display:flex;align-items:center;justify-content:center;top:50%;left:calc(", menu.width, " - 2px);transition:left ", menu.transition, ";transform:translateY(-50%);border:", menu.border, ";border-left:none;.", k, "-icon{margin-right:0;}&:hover{.", k, "-menu-arrow:before{color:", menu.item.activeBgColor, ";}}}&.", k, "-light{border-right:1px solid ", theme.color.disabledBg, ";background:", menu.light.bgColor, ";.", k, "-menu-header{color:", menu.light.title.color, ";}.", k, "-menu-item{.", k, "-menu-item-title{color:", menu.light.item.color, ";&:hover{background:", menu.light.item.hoverBg, ";}}.", k, "-menu-item-arrow{color:", menu.light.item.color, ";}&.", k, "-highlighted{>.", k, "-menu-item-title{color:", menu.light.item.hoverColor, ";}}&.", k, "-disabled{>.", k, "-menu-item-title{color:", menu.light.item.disabledColor, "!important;}}}.", k, "-menu-title{border-top:", menu.light.border, ";.", k, "-menu-name{color:", menu.light.title.color, ";}}.", k, "-menu-arrow-box{background:", menu.light.bgColor, ";border:", menu.light.border, ";border-left:none;&:hover{.", k, "-menu-arrow:before{color:", menu.light.active.color, ";}}}.", k, "-menu:not(.", k, "-dropdown-menu){background:", menu.light.bgColor, ";}&.", k, "-horizontal{.", k, "-menu-header{border-right:", menu.light.border, ";}.", k, "-menu-body>.", k, "-menu-title{border-right:", menu.light.border, ";}}.", k, "-menu-item.", k, "-active{>.", k, "-menu-item-title{color:", menu.light.active.color, "!important;background:", menu.light.active.bgColor, ";}}.", k, "-sub-menu{.", k, "-menu-item-title,.", k, "-menu-item-arrow{color:", menu.light.item.subTitleColor, "!important;}}}", _mapInstanceProperty(sizes).call(sizes, function (size) {
|
|
116
116
|
var styles = menu[size];
|
|
117
117
|
return /*#__PURE__*/css("&.", k, "-", size, "{width:", styles.width, ";font-size:", styles.fontSize, ";.", k, "-menu{font-size:", styles.fontSize, ";}.", k, "-menu-arrow-box{left:calc(", styles.width, " - 2px);}}");
|
|
118
118
|
}), "&.", k, "-collapsed{width:calc(", menu.icon.width, " + (", getLeft(menu.item.padding), " + ", getLeft(menu.item.bodyPadding), ") * 2);.", k, "-icon{margin-right:0;}.", k, "-menu-item-arrow{display:none;}}&.", k, "-collapsed-arrow{width:0px;border-left:none;.", k, "-menu-body{overflow:hidden;padding:0;}.", k, "-menu-arrow-box{left:0;.", k, "-menu-arrow:before{transform:rotateY(180deg);}}}&.", k, "-dropdown-menu{width:fit-content;min-width:", menu.dropdown.minWidth, ";.", k, "-menu-item-arrow{transform:rotate(-90deg);}}&.", k, "-horizontal{width:auto;display:flex;.", k, "-menu-body{display:flex;align-items:center;.", k, "-menu-title{border-top:none;border-right:", menu.border, ";}}}");
|
|
@@ -22,7 +22,9 @@ export default function ($props, $blocks, $__proto__) {
|
|
|
22
22
|
title = _this$get.title,
|
|
23
23
|
rest = _objectWithoutPropertiesLoose(_this$get, _excluded);
|
|
24
24
|
var isChecked = value === trueValue;
|
|
25
|
-
var
|
|
25
|
+
var _this$config = this.config,
|
|
26
|
+
k = _this$config.k,
|
|
27
|
+
disableWave = _this$config.disableWave;
|
|
26
28
|
var classNameObj = (_classNameObj = {}, _classNameObj[k + "-radio"] = true, _classNameObj[k + "-disabled"] = disabled, _classNameObj[k + "-checked"] = isChecked, _classNameObj[className] = className, _classNameObj[makeStyles(k)] = true, _classNameObj);
|
|
27
29
|
|
|
28
30
|
// let evClick;
|
|
@@ -47,7 +49,7 @@ export default function ($props, $blocks, $__proto__) {
|
|
|
47
49
|
'ev-keypress': this.onKeypress,
|
|
48
50
|
'ev-click': this.fixClick
|
|
49
51
|
}), [_$cc(Wave, {
|
|
50
|
-
'disabled': disabled,
|
|
52
|
+
'disabled': disabled || disableWave,
|
|
51
53
|
'inset': '-2px',
|
|
52
54
|
'children': _$ce(2, 'span', _$cv('input', _extends({}, getRestProps(this, rest), {
|
|
53
55
|
'type': 'radio',
|
|
@@ -54,6 +54,7 @@ export declare abstract class BaseSelect<T extends BaseSelectProps<any> = BaseSe
|
|
|
54
54
|
protected config: {
|
|
55
55
|
cls: (name: string) => string;
|
|
56
56
|
readonly k: string;
|
|
57
|
+
readonly disableWave: boolean;
|
|
57
58
|
};
|
|
58
59
|
init(): void;
|
|
59
60
|
protected abstract getPlaceholder(): Children;
|
|
@@ -45,7 +45,9 @@ export default function ($props, $blocks, $__proto__) {
|
|
|
45
45
|
flat = _flatInstanceProperty(_this$get),
|
|
46
46
|
nowrap = _this$get.nowrap,
|
|
47
47
|
draggable = _this$get.draggable;
|
|
48
|
-
var
|
|
48
|
+
var _this$config = this.config,
|
|
49
|
+
k = _this$config.k,
|
|
50
|
+
disableWave = _this$config.disableWave;
|
|
49
51
|
var classNameObj = (_classNameObj = {}, _classNameObj[k + "-select"] = true, _classNameObj[k + "-disabled"] = disabled, _classNameObj[k + "-" + size] = size !== 'default', _classNameObj[k + "-fluid"] = fluid, _classNameObj[k + "-inline"] = inline, _classNameObj[k + "-flat"] = flat, _classNameObj[k + "-nowrap"] = nowrap, _classNameObj[className] = className, _classNameObj[$props.className] = $props.className, _classNameObj[makeStyles(k)] = true, _classNameObj);
|
|
50
52
|
var placeholder = this.getPlaceholder();
|
|
51
53
|
var label = this.getLabel();
|
|
@@ -77,7 +79,7 @@ export default function ($props, $blocks, $__proto__) {
|
|
|
77
79
|
'children': function children(isInvalid) {
|
|
78
80
|
var _$cn2;
|
|
79
81
|
return _$cc(Wave, {
|
|
80
|
-
'disabled': disabled || isInvalid || inline,
|
|
82
|
+
'disabled': disabled || isInvalid || inline || disableWave,
|
|
81
83
|
'inset': '-2px',
|
|
82
84
|
'children': _$cc(Dropdown, {
|
|
83
85
|
'trigger': 'click',
|
|
@@ -36,7 +36,11 @@ export function useInput(resetKeywords) {
|
|
|
36
36
|
filterable = _component$get.filterable;
|
|
37
37
|
if (multiple && filterable) {
|
|
38
38
|
focusInput();
|
|
39
|
-
|
|
39
|
+
/**
|
|
40
|
+
* don't reset keywords on multiple mode for continue selection
|
|
41
|
+
* https://github.com/ksc-fe/kpc/issues/983
|
|
42
|
+
*/
|
|
43
|
+
// resetKeywords(keywords);
|
|
40
44
|
}
|
|
41
45
|
});
|
|
42
46
|
return {
|
|
@@ -29,7 +29,7 @@ var defaults = {
|
|
|
29
29
|
get color() {
|
|
30
30
|
return theme.color.lightBlack;
|
|
31
31
|
},
|
|
32
|
-
padding: "0
|
|
32
|
+
padding: "0 8px 0 12px",
|
|
33
33
|
fontSize: "12px",
|
|
34
34
|
fontWeight: "bold",
|
|
35
35
|
textAlign: 'left',
|
|
@@ -42,7 +42,7 @@ var defaults = {
|
|
|
42
42
|
get hoverBgcolor() {
|
|
43
43
|
return theme.color.bg;
|
|
44
44
|
},
|
|
45
|
-
padding: "11px
|
|
45
|
+
padding: "11px 8px 11px 12px"
|
|
46
46
|
},
|
|
47
47
|
// stripe
|
|
48
48
|
stripeBgColor: '#f9f9fc',
|
|
@@ -90,7 +90,7 @@ setDefault(function () {
|
|
|
90
90
|
makeGroupMenuStyles == null || makeGroupMenuStyles.clearCache();
|
|
91
91
|
});
|
|
92
92
|
export var makeStyles = cache(function makeStyles(k) {
|
|
93
|
-
return /*#__PURE__*/css("font-size:", table.fontSize, ";color:", table.color, ";position:relative;z-index:0;.", k, "-table-wrapper{border-bottom:", table.border, ";overflow:auto;border-radius:", table.borderRadius, ";}table{width:100%;border-spacing:0;table-layout:fixed;}thead{text-align:", table.thead.textAlign, ";font-size:", table.thead.fontSize, ";font-weight:", table.thead.fontWeight, ";position:sticky;top:0;z-index:2;tr{height:", table.thead.height, ";&:not(:last-of-type) th{border-bottom:", table.border, ";}}}th{padding:", table.thead.padding, ";position:relative;background:", table.thead.bgColor, ";line-height:normal;&:before{content:'';height:", table.thead.delimiterHeight, ";position:absolute;background-color:", table.thead.delimiterColor, ";width:1px;left:1px;top:50%;transform:translateY(-50%);}&:first-of-type:before{display:none;}}.", k, "-table-title{display:inline-flex;align-items:center;max-width:100%;color:", table.thead.color, ";}.", k, "-table-title-text{flex:1;display:inline-flex;line-height:1.4;}tbody{tr{&:hover td{background:", table.tbody.hoverBgcolor, ";}&:last-of-type td{border-bottom-color:transparent;}}}td{padding:", table.tbody.padding, ";border-bottom:", table.border, ";background:", table.bgColor, ";word-wrap:break-word;}.", k, "-fixed-left,.", k, "-fixed-right{position:sticky;z-index:1;&:after{content:'';display:block;transition:box-shadow ", table.transition, ";position:absolute;top:0;bottom:0px;width:10px;pointer-events:none;}}.", k, "-fixed-left:after{right:-11px;}.", k, "-fixed-right:after{left:-11px;}&.", k, "-scroll-left .", k, "-fixed-right:after{box-shadow:", table.fixRightShadow, ";}&.", k, "-scroll-right .", k, "-fixed-left:after{box-shadow:", table.fixLeftShadow, ";}&.", k, "-scroll-middle{.", k, "-fixed-left:after{box-shadow:", table.fixLeftShadow, ";}.", k, "-fixed-right:after{box-shadow:", table.fixRightShadow, ";}}.", k, "-fixed-right+.", k, "-fixed-right:after{display:none;}.", k, "-table-affix-header{position:sticky;top:0;left:0;.", k, "-affix-wrapper{overflow:hidden;}&.", k, "-fixed{position:relative;}}&.", k, "-border,&.", k, "-grid{.", k, "-table-wrapper{border-top:", table.border, ";border-left:", table.border, ";border-right:", table.border, ";}}&.", k, "-grid{td:not(:last-of-type),th:not(:last-of-type){border-right:", table.border, ";}th:before{display:none;}}&.", k, "-stripe{tr:nth-child(even):not(:hover) td{background:", table.stripeBgColor, ";}}.", k, "-table-group{margin-left:", table.group.gap, ";}.", k, "-table-check{.", k, "-checkbox,.", k, "-radio{position:relative;top:-1px;}}.", k, "-column-sortable{cursor:pointer;}.", k, "-column-sort{.", k, "-icon{display:block;height:", _sortInstanceProperty(table).iconHeight, ";line-height:", _sortInstanceProperty(table).iconHeight, ";margin:0 0 1px ", _sortInstanceProperty(table).gap, ";}&.", k, "-desc .", k, "-icon.", k, "-desc,&.", k, "-asc .", k, "-icon.", k, "-asc{color:", _sortInstanceProperty(table).enabledColor, ";}}.", k, "-table-spin.", k, "-overlay{z-index:2;}.", k, "-table-empty{text-align:center;}tr.", k, "-expand{td{padding:0;background:#fdfcff;}}&.", k, "-with-expand{tr:not(.", k, "-expand){td{border-bottom:none;}}}.", k, "-table-expand{border-top:", table.border, ";box-sizing:content-box;}tbody tr.", k, "-selected td{background:", table.selectedBgColor, ";}.", k, "-table-arrow{width:", table.arrow.width, "!important;margin-right:", table.arrow.gap, ";transition:transform ", table.transition, ";position:relative;top:-1px;}tr.", k, "-spreaded{.", k, "-table-arrow{transform:rotate(90deg);}}.", k, "-table-resize{height:100%;width:", table.resizeWidth, ";position:absolute;top:0;left:-1px;cursor:ew-resize;}tr.", k, "-dragging{opacity:", table.draggingOpacity, ";}.", k, "-table-scrollbar{overflow-x:auto;overflow-y:hidden;}.", k, "-table-scrollbar-inner{height:1px;}", _mapInstanceProperty(aligns).call(aligns, function (type) {
|
|
93
|
+
return /*#__PURE__*/css("font-size:", table.fontSize, ";color:", table.color, ";position:relative;z-index:0;.", k, "-table-wrapper{border-bottom:", table.border, ";overflow:auto;border-radius:", table.borderRadius, ";}table{width:100%;border-spacing:0;table-layout:fixed;}thead{text-align:", table.thead.textAlign, ";font-size:", table.thead.fontSize, ";font-weight:", table.thead.fontWeight, ";position:sticky;top:0;z-index:2;tr{height:", table.thead.height, ";&:not(:last-of-type) th{border-bottom:", table.border, ";}}}th{padding:", table.thead.padding, ";position:relative;background:", table.thead.bgColor, ";line-height:normal;&:before{content:'';height:", table.thead.delimiterHeight, ";position:absolute;background-color:", table.thead.delimiterColor, ";width:1px;left:1px;top:50%;transform:translateY(-50%);}&.", k, "-fixed-right:before{left:-2px;}&:first-of-type:before{display:none;}}.", k, "-table-title{display:inline-flex;align-items:center;max-width:100%;color:", table.thead.color, ";}.", k, "-table-title-text{flex:1;display:inline-flex;line-height:1.4;}tbody{tr{&:hover td{background:", table.tbody.hoverBgcolor, ";}&:last-of-type td{border-bottom-color:transparent;}}}td{padding:", table.tbody.padding, ";border-bottom:", table.border, ";background:", table.bgColor, ";word-wrap:break-word;}.", k, "-fixed-left,.", k, "-fixed-right{position:sticky;z-index:1;&:after{content:'';display:block;transition:box-shadow ", table.transition, ";position:absolute;top:0;bottom:0px;width:10px;pointer-events:none;}}.", k, "-fixed-left:after{right:-11px;}.", k, "-fixed-right:after{left:-11px;}&.", k, "-scroll-left .", k, "-fixed-right:after{box-shadow:", table.fixRightShadow, ";}&.", k, "-scroll-right .", k, "-fixed-left:after{box-shadow:", table.fixLeftShadow, ";}&.", k, "-scroll-middle{.", k, "-fixed-left:after{box-shadow:", table.fixLeftShadow, ";}.", k, "-fixed-right:after{box-shadow:", table.fixRightShadow, ";}}.", k, "-fixed-right+.", k, "-fixed-right:after{display:none;}.", k, "-table-affix-header{position:sticky;top:0;left:0;.", k, "-affix-wrapper{overflow:hidden;}&.", k, "-fixed{position:relative;}}&.", k, "-border,&.", k, "-grid{.", k, "-table-wrapper{border-top:", table.border, ";border-left:", table.border, ";border-right:", table.border, ";}}&.", k, "-grid{td:not(:last-of-type),th:not(:last-of-type){border-right:", table.border, ";}th:before{display:none;}}&.", k, "-stripe{tr:nth-child(even):not(:hover) td{background:", table.stripeBgColor, ";}}.", k, "-table-group{margin-left:", table.group.gap, ";}.", k, "-table-check{.", k, "-checkbox,.", k, "-radio{position:relative;top:-1px;}}.", k, "-column-sortable{cursor:pointer;}.", k, "-column-sort{.", k, "-icon{display:block;height:", _sortInstanceProperty(table).iconHeight, ";line-height:", _sortInstanceProperty(table).iconHeight, ";margin:0 0 1px ", _sortInstanceProperty(table).gap, ";}&.", k, "-desc .", k, "-icon.", k, "-desc,&.", k, "-asc .", k, "-icon.", k, "-asc{color:", _sortInstanceProperty(table).enabledColor, ";}}.", k, "-table-spin.", k, "-overlay{z-index:2;}.", k, "-table-empty{text-align:center;}tr.", k, "-expand{td{padding:0;background:#fdfcff;}}&.", k, "-with-expand{tr:not(.", k, "-expand){td{border-bottom:none;}}}.", k, "-table-expand{border-top:", table.border, ";box-sizing:content-box;}tbody tr.", k, "-selected td{background:", table.selectedBgColor, ";}.", k, "-table-arrow{width:", table.arrow.width, "!important;margin-right:", table.arrow.gap, ";transition:transform ", table.transition, ";position:relative;top:-1px;}tr.", k, "-spreaded{.", k, "-table-arrow{transform:rotate(90deg);}}.", k, "-table-resize{height:100%;width:", table.resizeWidth, ";position:absolute;top:0;left:-1px;cursor:ew-resize;}tr.", k, "-dragging{opacity:", table.draggingOpacity, ";}.", k, "-table-scrollbar{overflow-x:auto;overflow-y:hidden;}.", k, "-table-scrollbar-inner{height:1px;}", _mapInstanceProperty(aligns).call(aligns, function (type) {
|
|
94
94
|
return /*#__PURE__*/css(".", k, "-align-", type, "{text-align:", type, ";}");
|
|
95
95
|
}), ">.", k, "-pagination{margin:16px 0;}&.", k, "-fix-header{min-height:0;.", k, "-table-wrapper{height:100%;}}");
|
|
96
96
|
});
|
|
@@ -71,7 +71,7 @@ export var makeStyles = cache(function makeStyles(k) {
|
|
|
71
71
|
}
|
|
72
72
|
return /*#__PURE__*/css("&.", k, "-", theme, "{background:", bgColor, ";color:", color, ";.", k, "-tooltip-arrow{", _mapInstanceProperty(_context = _Object$keys(directionMap)).call(_context, function (direction) {
|
|
73
73
|
var borderDirection = directionMap[direction];
|
|
74
|
-
return /*#__PURE__*/css("&.", k, "-", direction, "{
|
|
74
|
+
return /*#__PURE__*/css("&.", k, "-", direction, "{&:before{border-", borderDirection, "-color:", bgColor, ";}}");
|
|
75
75
|
}), ";}}");
|
|
76
76
|
}), ".", k, "-tooltip-footer{padding-top:", tooltip.confirm.gaps, ";.", k, "-btn:not(:first-of-type){margin-left:", tooltip.confirm.gaps, ";}}&.", k, "-small{padding:", tooltip.smallPadding, ";}}");
|
|
77
77
|
});
|
|
@@ -24,10 +24,11 @@ export default function ($props, $blocks, $__proto__) {
|
|
|
24
24
|
files = _this$get.files,
|
|
25
25
|
children = _this$get.children,
|
|
26
26
|
type = _this$get.type,
|
|
27
|
-
directory = _this$get.directory
|
|
27
|
+
directory = _this$get.directory,
|
|
28
|
+
disabled = _this$get.disabled;
|
|
28
29
|
var drag = this.drag;
|
|
29
30
|
var k = this.config.k;
|
|
30
|
-
var classNameObj = (_classNameObj = {}, _classNameObj[k + "-upload"] = true, _classNameObj[className] = className, _classNameObj[k + "-drag"] = type === 'drag', _classNameObj[k + "-dragover"] = drag.dragOver.value, _classNameObj[k + "-gallery"] = type === 'gallery', _classNameObj[makeStyles(k)] = true, _classNameObj);
|
|
31
|
+
var classNameObj = (_classNameObj = {}, _classNameObj[k + "-upload"] = true, _classNameObj[className] = className, _classNameObj[k + "-drag"] = type === 'drag', _classNameObj[k + "-dragover"] = drag.dragOver.value, _classNameObj[k + "-gallery"] = type === 'gallery', _classNameObj[k + "-disabled"] = disabled, _classNameObj[makeStyles(k)] = true, _classNameObj);
|
|
31
32
|
var events = {
|
|
32
33
|
'ev-click': this.selectFile
|
|
33
34
|
};
|
|
@@ -49,6 +50,7 @@ export default function ($props, $blocks, $__proto__) {
|
|
|
49
50
|
};
|
|
50
51
|
return block ? block.call($this, callBlock, data) : callBlock();
|
|
51
52
|
}, __$blocks['children'](_$no)) : type !== 'gallery' ? type === 'select' ? _$cc(Button, {
|
|
53
|
+
'disabled': disabled,
|
|
52
54
|
'children': [_$cc(Icon, {
|
|
53
55
|
'className': _$cn(k + "-icon-upload")
|
|
54
56
|
}), _$('点击上传')]
|
|
@@ -113,7 +113,7 @@ setDefault(function () {
|
|
|
113
113
|
makeUploadDialogStyles == null || makeUploadDialogStyles.clearCache();
|
|
114
114
|
});
|
|
115
115
|
export var makeStyles = cache(function makeStyles(k) {
|
|
116
|
-
return /*#__PURE__*/css("font-size:", upload.fontSize, ";position:relative;.", k, "-icon-upload{position:relative;top:-1px;}.", k, "-upload-handle{display:inline-block;vertical-align:middle;color:", upload.color, ";}.", k, "-upload-tip{margin-top:", upload.tip.gap, ";color:", upload.color, ";}.", k, "-upload-files{margin-top:", upload.filesGap, ";}.", k, "-upload-file{margin:", upload.file.margin, ";padding-right:", upload.file.delete.width, ";position:relative;&:hover{.", k, "-upload-close{display:inline-flex;position:absolute;right:", upload.file.delete.right, ";top:", upload.file.delete.top, ";}.", k, "-upload-file-main{background:", upload.file.bgColor, ";}}}.", k, "-upload-file-main{padding:", upload.file.padding, ";border-radius:", upload.file.borderRadius, ";}.", k, "-upload-name{display:flex;align-items:center;height:", upload.file.height, ";}.", k, "-upload-file-icon{margin-right:", upload.file.fileIconGap, ";}.", k, "-upload-file-name{flex:1;}.", k, "-upload-status-icon{color:", upload.file.status.color, ";margin-right:", upload.file.status.offsetRight, ";}.", k, "-upload-close{display:none;}.", k, "-upload-file.", k, "-error{color:", upload.file.errorColor, ";.", k, "-upload-status-icon{color:", upload.file.status.errorColor, ";}}.", k, "-upload-progress{.", k, "-progress-text{width:auto!important;}}&.", k, "-drag{.", k, "-upload-handle{display:block;border:", upload.drag.border, ";border-radius:", upload.drag.borderRadius, ";cursor:pointer;text-align:center;transition:border-color ", upload.transition, ";background:", upload.drag.bgColor, ";&:hover{border-color:", upload.drag.hoverBorderColor, ";}}.", k, "-upload-area{padding:", upload.drag.padding, ";.", k, "-icon{display:inline-block;font-size:", upload.drag.icon.fontSize, ";margin-bottom:", upload.drag.icon.gap, ";}}&.", k, "-dragover{.", k, "-upload-handle{border-color:", upload.drag.overBorderColor, ";}}}.", k, "-upload-pictures{display:inline-block;vertical-align:middle;}.", k, "-upload-picture{padding:", upload.gallery.padding, ";position:relative;vertical-align:middle;&.", k, "-error{border-color:", upload.gallery.errorBorderColor, ";}.", k, "-upload-close{display:inline-flex;}&:hover{.", k, "-upload-icons{opacity:1;}}.", k, "-upload-img{display:inline-block;width:100%;height:100%;}.", k, "-upload-icons{opacity:0;transition:opacity ", upload.transition, ";}}.", k, "-upload-picture-card{display:inline-flex;width:", upload.gallery.width, ";height:", upload.gallery.height, ";border-radius:", upload.gallery.borderRadius, ";border:", upload.gallery.border, ";margin:", upload.gallery.margin, ";background:", upload.gallery.bgColor, ";align-items:center;justify-content:center;flex-direction:column;}.", k, "-upload-add{border:", upload.gallery.add.border, ";cursor:pointer;&:hover{border-color:", upload.gallery.add.hoverBorderColor, ";}}.", k, "-upload-overlap{position:absolute;width:100%;height:100%;left:0;top:0;background:", upload.overlap.bgColor, ";display:flex;align-items:center;justify-content:center;gap:", upload.overlap.iconGap, ";color:", upload.overlap.color, ";.", k, "-icon:not(:hover){color:inherit;}.", k, "-upload-progress{position:absolute;width:100%;top:50%;padding:", upload.gallery.padding, ";transform:translateY(-50%);}}");
|
|
116
|
+
return /*#__PURE__*/css("font-size:", upload.fontSize, ";position:relative;.", k, "-icon-upload{position:relative;top:-1px;}.", k, "-upload-handle{display:inline-block;vertical-align:middle;color:", upload.color, ";}.", k, "-upload-tip{margin-top:", upload.tip.gap, ";color:", upload.color, ";}.", k, "-upload-files{margin-top:", upload.filesGap, ";}.", k, "-upload-file{margin:", upload.file.margin, ";padding-right:", upload.file.delete.width, ";position:relative;&:hover{.", k, "-upload-close{display:inline-flex;position:absolute;right:", upload.file.delete.right, ";top:", upload.file.delete.top, ";}.", k, "-upload-file-main{background:", upload.file.bgColor, ";}}}.", k, "-upload-file-main{padding:", upload.file.padding, ";border-radius:", upload.file.borderRadius, ";}.", k, "-upload-name{display:flex;align-items:center;height:", upload.file.height, ";}.", k, "-upload-file-icon{margin-right:", upload.file.fileIconGap, ";}.", k, "-upload-file-name{flex:1;}.", k, "-upload-status-icon{color:", upload.file.status.color, ";margin-right:", upload.file.status.offsetRight, ";}.", k, "-upload-close{display:none;}.", k, "-upload-file.", k, "-error{color:", upload.file.errorColor, ";.", k, "-upload-status-icon{color:", upload.file.status.errorColor, ";}}.", k, "-upload-progress{.", k, "-progress-text{width:auto!important;}}&.", k, "-drag{.", k, "-upload-handle{display:block;border:", upload.drag.border, ";border-radius:", upload.drag.borderRadius, ";cursor:pointer;text-align:center;transition:border-color ", upload.transition, ";background:", upload.drag.bgColor, ";&:hover{border-color:", upload.drag.hoverBorderColor, ";}}.", k, "-upload-area{padding:", upload.drag.padding, ";.", k, "-icon{display:inline-block;font-size:", upload.drag.icon.fontSize, ";margin-bottom:", upload.drag.icon.gap, ";}}&.", k, "-dragover{.", k, "-upload-handle{border-color:", upload.drag.overBorderColor, ";}}}.", k, "-upload-pictures{display:inline-block;vertical-align:middle;}.", k, "-upload-picture{padding:", upload.gallery.padding, ";position:relative;vertical-align:middle;&.", k, "-error{border-color:", upload.gallery.errorBorderColor, ";}.", k, "-upload-close{display:inline-flex;}&:hover{.", k, "-upload-icons{opacity:1;}}.", k, "-upload-img{display:inline-block;width:100%;height:100%;}.", k, "-upload-icons{opacity:0;transition:opacity ", upload.transition, ";}}.", k, "-upload-picture-card{display:inline-flex;width:", upload.gallery.width, ";height:", upload.gallery.height, ";border-radius:", upload.gallery.borderRadius, ";border:", upload.gallery.border, ";margin:", upload.gallery.margin, ";background:", upload.gallery.bgColor, ";align-items:center;justify-content:center;flex-direction:column;}.", k, "-upload-add{border:", upload.gallery.add.border, ";cursor:pointer;&:hover{border-color:", upload.gallery.add.hoverBorderColor, ";}}.", k, "-upload-overlap{position:absolute;width:100%;height:100%;left:0;top:0;background:", upload.overlap.bgColor, ";display:flex;align-items:center;justify-content:center;gap:", upload.overlap.iconGap, ";color:", upload.overlap.color, ";.", k, "-icon:not(:hover){color:inherit;}.", k, "-upload-progress{position:absolute;width:100%;top:50%;padding:", upload.gallery.padding, ";transform:translateY(-50%);}}&.", k, "-disabled{.", k, "-upload-add,.", k, "-upload-handle{cursor:auto;a{color:", upload.color, ";}&:hover{border-color:", theme.color.border, ";}}}");
|
|
117
117
|
});
|
|
118
118
|
export var makeUploadDialogStyles = cache(function makeUploadDialogStyles(k) {
|
|
119
119
|
return /*#__PURE__*/css(process.env.NODE_ENV === "production" ? {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@king-design/vue",
|
|
3
|
-
"version": "3.3.
|
|
3
|
+
"version": "3.3.1",
|
|
4
4
|
"description": "King-Design UI components for Vue3.0.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"component",
|
|
@@ -37,7 +37,7 @@
|
|
|
37
37
|
"@emotion/css": "^11.5.0",
|
|
38
38
|
"dayjs": "^1.10.7",
|
|
39
39
|
"enquire.js": "^2.1.6",
|
|
40
|
-
"intact-vue-next": "3.0.
|
|
40
|
+
"intact-vue-next": "3.0.34",
|
|
41
41
|
"monaco-editor": "^0.26.1",
|
|
42
42
|
"mxgraphx": "^4.0.7",
|
|
43
43
|
"resize-observer-polyfill": "^1.5.1",
|