bkui-vue 0.0.1-beta.390 → 0.0.1-beta.392
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 +22 -22
- package/dist/index.esm.js +0 -1
- package/dist/index.umd.js +23 -23
- package/lib/affix/index.js +128 -60
- package/lib/alert/index.js +124 -56
- package/lib/animate-number/index.js +106 -42
- package/lib/backtop/index.js +133 -61
- package/lib/badge/badge.d.ts +1 -1
- package/lib/badge/index.d.ts +4 -4
- package/lib/badge/index.js +114 -50
- package/lib/breadcrumb/breadcrumb-item.d.ts +1 -1
- package/lib/breadcrumb/breadcrumb.d.ts +1 -1
- package/lib/breadcrumb/index.d.ts +5 -5
- package/lib/breadcrumb/index.js +133 -67
- package/lib/button/index.js +147 -68
- package/lib/card/index.js +154 -69
- package/lib/cascader/cascader.d.ts +3 -3
- package/lib/cascader/index.d.ts +10 -10
- package/lib/cascader/index.js +242 -168
- package/lib/checkbox/index.js +139 -77
- package/lib/code-diff/index.js +121 -79
- package/lib/collapse/index.js +150 -84
- package/lib/color-picker/color-picker.d.ts +1 -1
- package/lib/color-picker/index.d.ts +4 -4
- package/lib/color-picker/index.js +245 -193
- package/lib/components.js +671 -434
- package/lib/container/container.d.ts +1 -1
- package/lib/container/index.d.ts +4 -4
- package/lib/container/index.js +125 -64
- package/lib/date-picker/date-picker.d.ts +2 -2
- package/lib/date-picker/index.d.ts +7 -7
- package/lib/date-picker/index.js +563 -462
- package/lib/date-picker/panel/time-range.d.ts +3 -3
- package/lib/date-picker/panel/time.d.ts +3 -3
- package/lib/date-picker/time-picker.d.ts +3 -3
- package/lib/dialog/dialog.d.ts +2 -2
- package/lib/dialog/index.d.ts +7 -7
- package/lib/dialog/index.js +198 -108
- package/lib/directives/index.d.ts +1 -0
- package/lib/directives/index.js +139 -86
- package/lib/dist.index.js +133 -48
- package/lib/divider/index.js +118 -50
- package/lib/dropdown/dropdown.d.ts +2 -2
- package/lib/dropdown/index.d.ts +7 -7
- package/lib/dropdown/index.js +155 -73
- package/lib/exception/index.js +145 -97
- package/lib/fixed-navbar/fixed-navbar.d.ts +1 -1
- package/lib/fixed-navbar/index.d.ts +4 -4
- package/lib/fixed-navbar/index.js +107 -43
- package/lib/form/form-item.d.ts +1 -1
- package/lib/form/index.d.ts +1 -1
- package/lib/form/index.js +193 -107
- package/lib/icon/angle-double-down-line.js +90 -30
- package/lib/icon/angle-double-left-line.js +90 -30
- package/lib/icon/angle-double-left.js +90 -30
- package/lib/icon/angle-double-right-line.js +90 -30
- package/lib/icon/angle-double-right.js +90 -30
- package/lib/icon/angle-double-up-line.js +90 -30
- package/lib/icon/angle-down-fill.js +90 -30
- package/lib/icon/angle-down-line.js +90 -30
- package/lib/icon/angle-down.js +90 -30
- package/lib/icon/angle-left.js +90 -30
- package/lib/icon/angle-right.js +90 -30
- package/lib/icon/angle-up-fill.js +90 -30
- package/lib/icon/angle-up.js +90 -30
- package/lib/icon/archive-fill.js +90 -30
- package/lib/icon/arrows-left.js +90 -30
- package/lib/icon/arrows-right.js +90 -30
- package/lib/icon/audio-fill.js +90 -30
- package/lib/icon/bk.js +90 -30
- package/lib/icon/circle.js +90 -30
- package/lib/icon/close-line.js +90 -30
- package/lib/icon/close.js +90 -30
- package/lib/icon/code.js +90 -30
- package/lib/icon/cog-shape.js +90 -30
- package/lib/icon/collapse-left.js +90 -30
- package/lib/icon/copy.js +90 -30
- package/lib/icon/data-shape.js +90 -30
- package/lib/icon/del.js +90 -30
- package/lib/icon/doc-fill.js +90 -30
- package/lib/icon/done.js +90 -30
- package/lib/icon/down-shape.js +90 -30
- package/lib/icon/down-small.js +90 -30
- package/lib/icon/edit-line.js +90 -30
- package/lib/icon/ellipsis.js +90 -30
- package/lib/icon/enlarge-line.js +90 -30
- package/lib/icon/error.js +90 -30
- package/lib/icon/excel-fill.js +90 -30
- package/lib/icon/exclamation-circle-shape.js +90 -30
- package/lib/icon/eye.js +90 -30
- package/lib/icon/filliscreen-line.js +90 -30
- package/lib/icon/folder-open.js +90 -30
- package/lib/icon/folder-shape-open.js +90 -30
- package/lib/icon/folder-shape.js +90 -30
- package/lib/icon/folder.js +90 -30
- package/lib/icon/funnel.js +90 -30
- package/lib/icon/help-document-fill.js +90 -30
- package/lib/icon/help-fill.js +90 -30
- package/lib/icon/help.js +90 -30
- package/lib/icon/image-fill.js +90 -30
- package/lib/icon/img-placehoulder.js +88 -52
- package/lib/icon/index.js +255 -267
- package/lib/icon/info-line.js +88 -52
- package/lib/icon/info.js +88 -52
- package/lib/icon/left-shape.js +88 -52
- package/lib/icon/left-turn-line.js +88 -52
- package/lib/icon/narrow-line.js +88 -52
- package/lib/icon/original.js +88 -52
- package/lib/icon/pdf-fill.js +88 -52
- package/lib/icon/play-shape.js +88 -52
- package/lib/icon/plus.js +88 -52
- package/lib/icon/ppt-fill.js +88 -52
- package/lib/icon/qq.js +88 -52
- package/lib/icon/right-shape.js +88 -52
- package/lib/icon/right-turn-line.js +88 -52
- package/lib/icon/search.js +88 -52
- package/lib/icon/share.js +88 -52
- package/lib/icon/spinner.js +88 -52
- package/lib/icon/success.js +88 -52
- package/lib/icon/switcher-loading.js +88 -52
- package/lib/icon/text-file.js +88 -52
- package/lib/icon/text-fill.js +88 -52
- package/lib/icon/transfer.js +88 -52
- package/lib/icon/tree-application-shape.js +88 -52
- package/lib/icon/unfull-screen.js +88 -52
- package/lib/icon/unvisible.js +88 -52
- package/lib/icon/up-shape.js +88 -52
- package/lib/icon/upload.js +88 -52
- package/lib/icon/video-fill.js +88 -52
- package/lib/icon/warn.js +88 -52
- package/lib/icon/weixin.js +88 -52
- package/lib/image/index.js +213 -164
- package/lib/index.js +134 -50
- package/lib/info-box/index.js +206 -152
- package/lib/input/index.d.ts +4 -4
- package/lib/input/index.js +167 -99
- package/lib/input/input.d.ts +1 -1
- package/lib/link/index.d.ts +4 -4
- package/lib/link/index.js +115 -47
- package/lib/link/link.d.ts +1 -1
- package/lib/loading/index.d.ts +4 -4
- package/lib/loading/index.js +127 -67
- package/lib/loading/loading.d.ts +1 -1
- package/lib/menu/index.js +156 -92
- package/lib/message/index.js +148 -76
- package/lib/modal/index.d.ts +4 -4
- package/lib/modal/index.js +151 -85
- package/lib/modal/modal.d.ts +1 -1
- package/lib/navigation/index.js +134 -66
- package/lib/notify/index.js +153 -81
- package/lib/notify/notifyConstructor.d.ts +1 -1
- package/lib/overflow-title/index.js +128 -92
- package/lib/pagination/index.d.ts +4 -4
- package/lib/pagination/index.js +220 -131
- package/lib/pagination/pagination.d.ts +1 -1
- package/lib/plugin-popover/index.js +190 -143
- package/lib/plugins/index.js +100 -33
- package/lib/popover/index.d.ts +10 -10
- package/lib/popover/index.js +193 -148
- package/lib/popover/popover.d.ts +3 -3
- package/lib/popover2/index.js +99 -35
- package/lib/preset.js +104 -37
- package/lib/process/index.d.ts +4 -4
- package/lib/process/index.js +134 -92
- package/lib/process/process.d.ts +1 -1
- package/lib/progress/index.d.ts +7 -7
- package/lib/progress/index.js +127 -63
- package/lib/progress/progress.d.ts +2 -2
- package/lib/radio/index.js +142 -81
- package/lib/rate/index.js +127 -63
- package/lib/resize-layout/index.js +147 -79
- package/lib/search-select/index.js +220 -168
- package/lib/select/index.d.ts +10 -10
- package/lib/select/index.js +394 -315
- package/lib/select/select.d.ts +3 -3
- package/lib/shared/index.js +203 -228
- package/lib/sideslider/index.d.ts +4 -4
- package/lib/sideslider/index.js +137 -88
- package/lib/sideslider/sideslider.d.ts +1 -1
- package/lib/slider/index.d.ts +7 -7
- package/lib/slider/index.js +196 -147
- package/lib/slider/slider.d.ts +2 -2
- package/lib/steps/index.js +152 -105
- package/lib/swiper/index.js +126 -62
- package/lib/switcher/index.d.ts +4 -4
- package/lib/switcher/index.js +133 -65
- package/lib/switcher/switcher.d.ts +1 -1
- package/lib/tab/index.d.ts +4 -4
- package/lib/tab/index.js +188 -118
- package/lib/tab/tab.d.ts +1 -1
- package/lib/table/index.js +572 -457
- package/lib/table-column/index.js +197 -129
- package/lib/tag/index.js +130 -58
- package/lib/tag-input/index.d.ts +7 -7
- package/lib/tag-input/index.js +277 -175
- package/lib/tag-input/tag-input.d.ts +2 -2
- package/lib/time-picker/index.d.ts +10 -10
- package/lib/time-picker/index.js +111 -40
- package/lib/timeline/index.d.ts +4 -4
- package/lib/timeline/index.js +114 -50
- package/lib/timeline/timeline.d.ts +1 -1
- package/lib/transfer/index.js +174 -89
- package/lib/tree/index.js +235 -158
- package/lib/upload/index.d.ts +7 -7
- package/lib/upload/index.js +227 -173
- package/lib/upload/upload-list.d.ts +1 -1
- package/lib/upload/upload-trigger.d.ts +1 -1
- package/lib/upload/upload.d.ts +2 -2
- package/lib/virtual-render/index.js +154 -86
- package/package.json +1 -1
package/lib/button/index.js
CHANGED
@@ -1,41 +1,121 @@
|
|
1
|
-
|
2
|
-
|
3
|
-
|
4
|
-
|
5
|
-
|
6
|
-
|
1
|
+
(function webpackUniversalModuleDefinition(root, factory) {
|
2
|
+
if(typeof exports === 'object' && typeof module === 'object')
|
3
|
+
module.exports = factory(require("../shared"), require("vue"), require("../loading"));
|
4
|
+
else if(typeof define === 'function' && define.amd)
|
5
|
+
define(["../shared", "vue", "../loading"], factory);
|
6
|
+
else {
|
7
|
+
var a = typeof exports === 'object' ? factory(require("../shared"), require("vue"), require("../loading")) : factory(root["../shared"], root["vue"], root["../loading"]);
|
8
|
+
for(var i in a) (typeof exports === 'object' ? exports : root)[i] = a[i];
|
9
|
+
}
|
10
|
+
})(self, (__WEBPACK_EXTERNAL_MODULE__4212__, __WEBPACK_EXTERNAL_MODULE__748__, __WEBPACK_EXTERNAL_MODULE__4870__) => {
|
11
|
+
return /******/ (() => { // webpackBootstrap
|
12
|
+
/******/ "use strict";
|
13
|
+
/******/ var __webpack_modules__ = ({
|
14
|
+
|
15
|
+
/***/ 4870:
|
16
|
+
/***/ ((module) => {
|
17
|
+
|
18
|
+
module.exports = __WEBPACK_EXTERNAL_MODULE__4870__;
|
19
|
+
|
20
|
+
/***/ }),
|
21
|
+
|
22
|
+
/***/ 4212:
|
23
|
+
/***/ ((module) => {
|
24
|
+
|
25
|
+
module.exports = __WEBPACK_EXTERNAL_MODULE__4212__;
|
26
|
+
|
27
|
+
/***/ }),
|
28
|
+
|
29
|
+
/***/ 748:
|
30
|
+
/***/ ((module) => {
|
31
|
+
|
32
|
+
module.exports = __WEBPACK_EXTERNAL_MODULE__748__;
|
33
|
+
|
34
|
+
/***/ })
|
35
|
+
|
36
|
+
/******/ });
|
7
37
|
/************************************************************************/
|
8
|
-
/******/
|
9
|
-
/******/
|
10
|
-
/******/
|
11
|
-
/******/
|
12
|
-
/******/
|
13
|
-
/******/
|
14
|
-
/******/
|
15
|
-
/******/
|
38
|
+
/******/ // The module cache
|
39
|
+
/******/ var __webpack_module_cache__ = {};
|
40
|
+
/******/
|
41
|
+
/******/ // The require function
|
42
|
+
/******/ function __webpack_require__(moduleId) {
|
43
|
+
/******/ // Check if module is in cache
|
44
|
+
/******/ var cachedModule = __webpack_module_cache__[moduleId];
|
45
|
+
/******/ if (cachedModule !== undefined) {
|
46
|
+
/******/ return cachedModule.exports;
|
16
47
|
/******/ }
|
17
|
-
/******/
|
18
|
-
/******/
|
19
|
-
/******/
|
20
|
-
/******/
|
21
|
-
/******/
|
22
|
-
/******/
|
23
|
-
/******/
|
24
|
-
/******/
|
48
|
+
/******/ // Create a new module (and put it into the cache)
|
49
|
+
/******/ var module = __webpack_module_cache__[moduleId] = {
|
50
|
+
/******/ // no module.id needed
|
51
|
+
/******/ // no module.loaded needed
|
52
|
+
/******/ exports: {}
|
53
|
+
/******/ };
|
54
|
+
/******/
|
55
|
+
/******/ // Execute the module function
|
56
|
+
/******/ __webpack_modules__[moduleId](module, module.exports, __webpack_require__);
|
57
|
+
/******/
|
58
|
+
/******/ // Return the exports of the module
|
59
|
+
/******/ return module.exports;
|
60
|
+
/******/ }
|
61
|
+
/******/
|
62
|
+
/************************************************************************/
|
63
|
+
/******/ /* webpack/runtime/compat get default export */
|
64
|
+
/******/ (() => {
|
65
|
+
/******/ // getDefaultExport function for compatibility with non-harmony modules
|
66
|
+
/******/ __webpack_require__.n = (module) => {
|
67
|
+
/******/ var getter = module && module.__esModule ?
|
68
|
+
/******/ () => (module['default']) :
|
69
|
+
/******/ () => (module);
|
70
|
+
/******/ __webpack_require__.d(getter, { a: getter });
|
71
|
+
/******/ return getter;
|
72
|
+
/******/ };
|
73
|
+
/******/ })();
|
74
|
+
/******/
|
75
|
+
/******/ /* webpack/runtime/define property getters */
|
76
|
+
/******/ (() => {
|
77
|
+
/******/ // define getter functions for harmony exports
|
78
|
+
/******/ __webpack_require__.d = (exports, definition) => {
|
79
|
+
/******/ for(var key in definition) {
|
80
|
+
/******/ if(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) {
|
81
|
+
/******/ Object.defineProperty(exports, key, { enumerable: true, get: definition[key] });
|
82
|
+
/******/ }
|
83
|
+
/******/ }
|
84
|
+
/******/ };
|
85
|
+
/******/ })();
|
86
|
+
/******/
|
87
|
+
/******/ /* webpack/runtime/hasOwnProperty shorthand */
|
88
|
+
/******/ (() => {
|
89
|
+
/******/ __webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop))
|
90
|
+
/******/ })();
|
91
|
+
/******/
|
92
|
+
/******/ /* webpack/runtime/make namespace object */
|
93
|
+
/******/ (() => {
|
94
|
+
/******/ // define __esModule on exports
|
95
|
+
/******/ __webpack_require__.r = (exports) => {
|
96
|
+
/******/ if(typeof Symbol !== 'undefined' && Symbol.toStringTag) {
|
97
|
+
/******/ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
|
98
|
+
/******/ }
|
99
|
+
/******/ Object.defineProperty(exports, '__esModule', { value: true });
|
100
|
+
/******/ };
|
101
|
+
/******/ })();
|
102
|
+
/******/
|
25
103
|
/************************************************************************/
|
26
104
|
var __webpack_exports__ = {};
|
105
|
+
// This entry need to be wrapped in an IIFE because it need to be isolated against other modules in the chunk.
|
106
|
+
(() => {
|
107
|
+
// ESM COMPAT FLAG
|
108
|
+
__webpack_require__.r(__webpack_exports__);
|
27
109
|
|
28
110
|
// EXPORTS
|
29
111
|
__webpack_require__.d(__webpack_exports__, {
|
30
|
-
"
|
31
|
-
"
|
32
|
-
"
|
112
|
+
"BkButton": () => (/* binding */ BkButton),
|
113
|
+
"BkButtonGroup": () => (/* reexport */ button_group),
|
114
|
+
"default": () => (/* binding */ src)
|
33
115
|
});
|
34
116
|
|
35
|
-
|
36
|
-
var
|
37
|
-
var y = x => () => x
|
38
|
-
const external_shared_namespaceObject = x({ ["PropTypes"]: () => __WEBPACK_EXTERNAL_MODULE__shared_65459f0a__.PropTypes, ["classes"]: () => __WEBPACK_EXTERNAL_MODULE__shared_65459f0a__.classes, ["withInstallProps"]: () => __WEBPACK_EXTERNAL_MODULE__shared_65459f0a__.withInstallProps });
|
117
|
+
// EXTERNAL MODULE: external "../shared"
|
118
|
+
var external_shared_ = __webpack_require__(4212);
|
39
119
|
;// CONCATENATED MODULE: ../../node_modules/@babel/runtime/helpers/esm/defineProperty.js
|
40
120
|
function _defineProperty(obj, key, value) {
|
41
121
|
if (key in obj) {
|
@@ -51,14 +131,11 @@ function _defineProperty(obj, key, value) {
|
|
51
131
|
|
52
132
|
return obj;
|
53
133
|
}
|
54
|
-
|
55
|
-
var
|
56
|
-
|
57
|
-
|
58
|
-
|
59
|
-
var external_loading_x = y => { var x = {}; __webpack_require__.d(x, y); return x; }
|
60
|
-
var external_loading_y = x => () => x
|
61
|
-
const external_loading_namespaceObject = external_loading_x({ ["BkLoadingSize"]: () => __WEBPACK_EXTERNAL_MODULE__loading_4d683b23__.BkLoadingSize, ["default"]: () => __WEBPACK_EXTERNAL_MODULE__loading_4d683b23__["default"] });
|
134
|
+
// EXTERNAL MODULE: external "vue"
|
135
|
+
var external_vue_ = __webpack_require__(748);
|
136
|
+
// EXTERNAL MODULE: external "../loading"
|
137
|
+
var external_loading_ = __webpack_require__(4870);
|
138
|
+
var external_loading_default = /*#__PURE__*/__webpack_require__.n(external_loading_);
|
62
139
|
;// CONCATENATED MODULE: ../../packages/button/src/button.tsx
|
63
140
|
|
64
141
|
|
@@ -93,31 +170,31 @@ const external_loading_namespaceObject = external_loading_x({ ["BkLoadingSize"]:
|
|
93
170
|
|
94
171
|
var btnSizes = ['', 'small', 'large'];
|
95
172
|
var buttonProps = {
|
96
|
-
theme:
|
97
|
-
hoverTheme:
|
173
|
+
theme: external_shared_.PropTypes.theme(),
|
174
|
+
hoverTheme: external_shared_.PropTypes.theme(),
|
98
175
|
size: {
|
99
176
|
type: String,
|
100
177
|
"default": btnSizes[0]
|
101
178
|
},
|
102
|
-
title:
|
103
|
-
icon:
|
104
|
-
iconRight:
|
105
|
-
disabled:
|
106
|
-
loading:
|
179
|
+
title: external_shared_.PropTypes.string,
|
180
|
+
icon: external_shared_.PropTypes.string,
|
181
|
+
iconRight: external_shared_.PropTypes.string,
|
182
|
+
disabled: external_shared_.PropTypes.bool,
|
183
|
+
loading: external_shared_.PropTypes.bool,
|
107
184
|
loadingMode: {
|
108
185
|
type: String,
|
109
186
|
"default": 'default'
|
110
187
|
},
|
111
|
-
outline:
|
112
|
-
text:
|
113
|
-
selected:
|
188
|
+
outline: external_shared_.PropTypes.bool,
|
189
|
+
text: external_shared_.PropTypes.bool,
|
190
|
+
selected: external_shared_.PropTypes.bool,
|
114
191
|
// circle: PropTypes.bool,
|
115
192
|
nativeType: {
|
116
193
|
type: String,
|
117
194
|
"default": 'button'
|
118
195
|
}
|
119
196
|
};
|
120
|
-
/* harmony default export */ const src_button = ((0,
|
197
|
+
/* harmony default export */ const src_button = ((0,external_vue_.defineComponent)({
|
121
198
|
name: 'Button',
|
122
199
|
props: buttonProps,
|
123
200
|
emits: ['click', 'mouseover'],
|
@@ -127,19 +204,19 @@ var buttonProps = {
|
|
127
204
|
|
128
205
|
var _a;
|
129
206
|
|
130
|
-
var isHover = (0,
|
207
|
+
var isHover = (0,external_vue_.ref)(false);
|
131
208
|
var showSlot = (_a = slots["default"]) !== null && _a !== void 0 ? _a : false;
|
132
209
|
var btnClsPrefix = 'bk-button';
|
133
|
-
var isText = (0,
|
210
|
+
var isText = (0,external_vue_.computed)(function () {
|
134
211
|
return props.text && !props.hoverTheme;
|
135
212
|
});
|
136
|
-
var btnCls = (0,
|
213
|
+
var btnCls = (0,external_vue_.computed)(function () {
|
137
214
|
var _classes;
|
138
215
|
|
139
216
|
var hoverTheme = props.hoverTheme ? "".concat(btnClsPrefix, "-hover-").concat(props.hoverTheme) : '';
|
140
217
|
var btnThemeCls = props.theme ? "".concat(btnClsPrefix, "-").concat(props.theme) : '';
|
141
218
|
var themeCls = props.hoverTheme ? '' : btnThemeCls;
|
142
|
-
return (0,
|
219
|
+
return (0,external_shared_.classes)((_classes = {
|
143
220
|
'is-disabled': props.disabled,
|
144
221
|
'is-outline': props.outline,
|
145
222
|
'is-text': isText.value,
|
@@ -147,7 +224,7 @@ var buttonProps = {
|
|
147
224
|
'is-selected': props.selected
|
148
225
|
}, _defineProperty(_classes, "".concat(btnClsPrefix, "-").concat(props.size), props.size && btnSizes.includes(props.size)), _defineProperty(_classes, 'no-slot', !showSlot), _classes), "".concat(themeCls, " ").concat(btnClsPrefix, " ").concat(hoverTheme));
|
149
226
|
});
|
150
|
-
var loadingTheme = (0,
|
227
|
+
var loadingTheme = (0,external_vue_.computed)(function () {
|
151
228
|
if (props.text || props.outline || props.hoverTheme) {
|
152
229
|
if (isHover.value && !props.text) return 'white';
|
153
230
|
if (props.text && props.disabled) return;
|
@@ -156,8 +233,8 @@ var buttonProps = {
|
|
156
233
|
|
157
234
|
return !props.theme ? undefined : 'white';
|
158
235
|
});
|
159
|
-
var loadingSize = (0,
|
160
|
-
return isText.value || props.size ===
|
236
|
+
var loadingSize = (0,external_vue_.computed)(function () {
|
237
|
+
return isText.value || props.size === external_loading_.BkLoadingSize.Small ? external_loading_.BkLoadingSize.Mini : external_loading_.BkLoadingSize.Small;
|
161
238
|
});
|
162
239
|
|
163
240
|
var handleClick = function handleClick(e) {
|
@@ -182,7 +259,7 @@ var buttonProps = {
|
|
182
259
|
return function () {
|
183
260
|
var _a;
|
184
261
|
|
185
|
-
return (0,
|
262
|
+
return (0,external_vue_.createVNode)("button", {
|
186
263
|
"title": props.title,
|
187
264
|
"disabled": props.disabled,
|
188
265
|
"class": btnCls.value,
|
@@ -190,14 +267,14 @@ var buttonProps = {
|
|
190
267
|
"onClick": handleClick,
|
191
268
|
"onMouseover": handleMouseOver,
|
192
269
|
"onMouseleave": handleMouseout
|
193
|
-
}, [props.loading && (0,
|
270
|
+
}, [props.loading && (0,external_vue_.createVNode)((external_loading_default()), (0,external_vue_.mergeProps)({
|
194
271
|
"loading": true,
|
195
272
|
"class": "".concat(btnClsPrefix, "-loading"),
|
196
273
|
"mode": props.loadingMode,
|
197
274
|
"size": loadingSize.value
|
198
275
|
}, loadingTheme.value ? {
|
199
276
|
theme: loadingTheme.value
|
200
|
-
} : {}), null), slots["default"] && (0,
|
277
|
+
} : {}), null), slots["default"] && (0,external_vue_.createVNode)("span", {
|
201
278
|
"class": "".concat(btnClsPrefix, "-text")
|
202
279
|
}, [(_a = slots["default"]) === null || _a === void 0 ? void 0 : _a.call(slots)])]);
|
203
280
|
};
|
@@ -234,19 +311,19 @@ var buttonProps = {
|
|
234
311
|
*/
|
235
312
|
|
236
313
|
|
237
|
-
/* harmony default export */ const button_group = ((0,
|
314
|
+
/* harmony default export */ const button_group = ((0,external_vue_.defineComponent)({
|
238
315
|
name: 'ButtonGroup',
|
239
316
|
props: {
|
240
|
-
size:
|
317
|
+
size: external_shared_.PropTypes.size()
|
241
318
|
},
|
242
319
|
setup: function setup(props, ctx) {
|
243
|
-
var btnGroupCls = (0,
|
244
|
-
return (0,
|
320
|
+
var btnGroupCls = (0,external_vue_.computed)(function () {
|
321
|
+
return (0,external_shared_.classes)(_defineProperty({}, "bk-button-group-".concat(props.size), !!props.size), 'bk-button-group');
|
245
322
|
});
|
246
323
|
return function () {
|
247
324
|
var _a, _b;
|
248
325
|
|
249
|
-
return (0,
|
326
|
+
return (0,external_vue_.createVNode)("div", {
|
250
327
|
"class": btnGroupCls.value
|
251
328
|
}, [(_b = (_a = ctx.slots)["default"]) === null || _b === void 0 ? void 0 : _b.call(_a)]);
|
252
329
|
};
|
@@ -281,12 +358,14 @@ var buttonProps = {
|
|
281
358
|
|
282
359
|
|
283
360
|
|
284
|
-
var BkButton = (0,
|
361
|
+
var BkButton = (0,external_shared_.withInstallProps)(src_button, {
|
285
362
|
ButtonGroup: button_group
|
286
363
|
});
|
287
364
|
/* harmony default export */ const src = (BkButton);
|
288
365
|
|
289
|
-
|
290
|
-
|
291
|
-
|
292
|
-
|
366
|
+
})();
|
367
|
+
|
368
|
+
/******/ return __webpack_exports__;
|
369
|
+
/******/ })()
|
370
|
+
;
|
371
|
+
});
|
package/lib/card/index.js
CHANGED
@@ -1,40 +1,126 @@
|
|
1
|
-
|
2
|
-
|
3
|
-
|
4
|
-
|
5
|
-
|
6
|
-
|
7
|
-
|
1
|
+
(function webpackUniversalModuleDefinition(root, factory) {
|
2
|
+
if(typeof exports === 'object' && typeof module === 'object')
|
3
|
+
module.exports = factory(require("../shared"), require("vue"), require("../icon"), require("../input"));
|
4
|
+
else if(typeof define === 'function' && define.amd)
|
5
|
+
define(["../shared", "vue", "../icon", "../input"], factory);
|
6
|
+
else {
|
7
|
+
var a = typeof exports === 'object' ? factory(require("../shared"), require("vue"), require("../icon"), require("../input")) : factory(root["../shared"], root["vue"], root["../icon"], root["../input"]);
|
8
|
+
for(var i in a) (typeof exports === 'object' ? exports : root)[i] = a[i];
|
9
|
+
}
|
10
|
+
})(self, (__WEBPACK_EXTERNAL_MODULE__4212__, __WEBPACK_EXTERNAL_MODULE__748__, __WEBPACK_EXTERNAL_MODULE__6870__, __WEBPACK_EXTERNAL_MODULE__8133__) => {
|
11
|
+
return /******/ (() => { // webpackBootstrap
|
12
|
+
/******/ "use strict";
|
13
|
+
/******/ var __webpack_modules__ = ({
|
14
|
+
|
15
|
+
/***/ 6870:
|
16
|
+
/***/ ((module) => {
|
17
|
+
|
18
|
+
module.exports = __WEBPACK_EXTERNAL_MODULE__6870__;
|
19
|
+
|
20
|
+
/***/ }),
|
21
|
+
|
22
|
+
/***/ 8133:
|
23
|
+
/***/ ((module) => {
|
24
|
+
|
25
|
+
module.exports = __WEBPACK_EXTERNAL_MODULE__8133__;
|
26
|
+
|
27
|
+
/***/ }),
|
28
|
+
|
29
|
+
/***/ 4212:
|
30
|
+
/***/ ((module) => {
|
31
|
+
|
32
|
+
module.exports = __WEBPACK_EXTERNAL_MODULE__4212__;
|
33
|
+
|
34
|
+
/***/ }),
|
35
|
+
|
36
|
+
/***/ 748:
|
37
|
+
/***/ ((module) => {
|
38
|
+
|
39
|
+
module.exports = __WEBPACK_EXTERNAL_MODULE__748__;
|
40
|
+
|
41
|
+
/***/ })
|
42
|
+
|
43
|
+
/******/ });
|
8
44
|
/************************************************************************/
|
9
|
-
/******/
|
10
|
-
/******/
|
11
|
-
/******/
|
12
|
-
/******/
|
13
|
-
/******/
|
14
|
-
/******/
|
15
|
-
/******/
|
16
|
-
/******/
|
45
|
+
/******/ // The module cache
|
46
|
+
/******/ var __webpack_module_cache__ = {};
|
47
|
+
/******/
|
48
|
+
/******/ // The require function
|
49
|
+
/******/ function __webpack_require__(moduleId) {
|
50
|
+
/******/ // Check if module is in cache
|
51
|
+
/******/ var cachedModule = __webpack_module_cache__[moduleId];
|
52
|
+
/******/ if (cachedModule !== undefined) {
|
53
|
+
/******/ return cachedModule.exports;
|
17
54
|
/******/ }
|
18
|
-
/******/
|
19
|
-
/******/
|
20
|
-
/******/
|
21
|
-
/******/
|
22
|
-
/******/
|
23
|
-
/******/
|
24
|
-
/******/
|
25
|
-
/******/
|
55
|
+
/******/ // Create a new module (and put it into the cache)
|
56
|
+
/******/ var module = __webpack_module_cache__[moduleId] = {
|
57
|
+
/******/ // no module.id needed
|
58
|
+
/******/ // no module.loaded needed
|
59
|
+
/******/ exports: {}
|
60
|
+
/******/ };
|
61
|
+
/******/
|
62
|
+
/******/ // Execute the module function
|
63
|
+
/******/ __webpack_modules__[moduleId](module, module.exports, __webpack_require__);
|
64
|
+
/******/
|
65
|
+
/******/ // Return the exports of the module
|
66
|
+
/******/ return module.exports;
|
67
|
+
/******/ }
|
68
|
+
/******/
|
69
|
+
/************************************************************************/
|
70
|
+
/******/ /* webpack/runtime/compat get default export */
|
71
|
+
/******/ (() => {
|
72
|
+
/******/ // getDefaultExport function for compatibility with non-harmony modules
|
73
|
+
/******/ __webpack_require__.n = (module) => {
|
74
|
+
/******/ var getter = module && module.__esModule ?
|
75
|
+
/******/ () => (module['default']) :
|
76
|
+
/******/ () => (module);
|
77
|
+
/******/ __webpack_require__.d(getter, { a: getter });
|
78
|
+
/******/ return getter;
|
79
|
+
/******/ };
|
80
|
+
/******/ })();
|
81
|
+
/******/
|
82
|
+
/******/ /* webpack/runtime/define property getters */
|
83
|
+
/******/ (() => {
|
84
|
+
/******/ // define getter functions for harmony exports
|
85
|
+
/******/ __webpack_require__.d = (exports, definition) => {
|
86
|
+
/******/ for(var key in definition) {
|
87
|
+
/******/ if(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) {
|
88
|
+
/******/ Object.defineProperty(exports, key, { enumerable: true, get: definition[key] });
|
89
|
+
/******/ }
|
90
|
+
/******/ }
|
91
|
+
/******/ };
|
92
|
+
/******/ })();
|
93
|
+
/******/
|
94
|
+
/******/ /* webpack/runtime/hasOwnProperty shorthand */
|
95
|
+
/******/ (() => {
|
96
|
+
/******/ __webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop))
|
97
|
+
/******/ })();
|
98
|
+
/******/
|
99
|
+
/******/ /* webpack/runtime/make namespace object */
|
100
|
+
/******/ (() => {
|
101
|
+
/******/ // define __esModule on exports
|
102
|
+
/******/ __webpack_require__.r = (exports) => {
|
103
|
+
/******/ if(typeof Symbol !== 'undefined' && Symbol.toStringTag) {
|
104
|
+
/******/ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
|
105
|
+
/******/ }
|
106
|
+
/******/ Object.defineProperty(exports, '__esModule', { value: true });
|
107
|
+
/******/ };
|
108
|
+
/******/ })();
|
109
|
+
/******/
|
26
110
|
/************************************************************************/
|
27
111
|
var __webpack_exports__ = {};
|
112
|
+
// This entry need to be wrapped in an IIFE because it need to be isolated against other modules in the chunk.
|
113
|
+
(() => {
|
114
|
+
// ESM COMPAT FLAG
|
115
|
+
__webpack_require__.r(__webpack_exports__);
|
28
116
|
|
29
117
|
// EXPORTS
|
30
118
|
__webpack_require__.d(__webpack_exports__, {
|
31
|
-
"
|
119
|
+
"default": () => (/* binding */ src)
|
32
120
|
});
|
33
121
|
|
34
|
-
|
35
|
-
var
|
36
|
-
var y = x => () => x
|
37
|
-
const external_shared_namespaceObject = x({ ["PropTypes"]: () => __WEBPACK_EXTERNAL_MODULE__shared_65459f0a__.PropTypes, ["classes"]: () => __WEBPACK_EXTERNAL_MODULE__shared_65459f0a__.classes, ["withInstall"]: () => __WEBPACK_EXTERNAL_MODULE__shared_65459f0a__.withInstall });
|
122
|
+
// EXTERNAL MODULE: external "../shared"
|
123
|
+
var external_shared_ = __webpack_require__(4212);
|
38
124
|
;// CONCATENATED MODULE: ../../node_modules/@babel/runtime/helpers/esm/defineProperty.js
|
39
125
|
function _defineProperty(obj, key, value) {
|
40
126
|
if (key in obj) {
|
@@ -50,18 +136,13 @@ function _defineProperty(obj, key, value) {
|
|
50
136
|
|
51
137
|
return obj;
|
52
138
|
}
|
53
|
-
|
54
|
-
var
|
55
|
-
|
56
|
-
|
57
|
-
|
58
|
-
var
|
59
|
-
var
|
60
|
-
const external_icon_namespaceObject = external_icon_x({ ["AngleDown"]: () => __WEBPACK_EXTERNAL_MODULE__icon_85385c3e__.AngleDown, ["AngleRight"]: () => __WEBPACK_EXTERNAL_MODULE__icon_85385c3e__.AngleRight, ["EditLine"]: () => __WEBPACK_EXTERNAL_MODULE__icon_85385c3e__.EditLine });
|
61
|
-
;// CONCATENATED MODULE: external "../input"
|
62
|
-
var external_input_x = y => { var x = {}; __webpack_require__.d(x, y); return x; }
|
63
|
-
var external_input_y = x => () => x
|
64
|
-
const external_input_namespaceObject = external_input_x({ ["default"]: () => __WEBPACK_EXTERNAL_MODULE__input_752b0149__["default"] });
|
139
|
+
// EXTERNAL MODULE: external "vue"
|
140
|
+
var external_vue_ = __webpack_require__(748);
|
141
|
+
// EXTERNAL MODULE: external "../icon"
|
142
|
+
var external_icon_ = __webpack_require__(6870);
|
143
|
+
// EXTERNAL MODULE: external "../input"
|
144
|
+
var external_input_ = __webpack_require__(8133);
|
145
|
+
var external_input_default = /*#__PURE__*/__webpack_require__.n(external_input_);
|
65
146
|
;// CONCATENATED MODULE: ../../packages/card/src/card.tsx
|
66
147
|
|
67
148
|
|
@@ -95,29 +176,29 @@ const external_input_namespaceObject = external_input_x({ ["default"]: () => __W
|
|
95
176
|
|
96
177
|
|
97
178
|
|
98
|
-
/* harmony default export */ const card = ((0,
|
179
|
+
/* harmony default export */ const card = ((0,external_vue_.defineComponent)({
|
99
180
|
name: 'Card',
|
100
181
|
props: {
|
101
|
-
title:
|
102
|
-
showHeader:
|
103
|
-
showFooter:
|
104
|
-
collapseStatus:
|
105
|
-
border:
|
106
|
-
disableHeaderStyle:
|
107
|
-
position:
|
108
|
-
isEdit:
|
109
|
-
isCollapse:
|
182
|
+
title: external_shared_.PropTypes.string,
|
183
|
+
showHeader: external_shared_.PropTypes.bool.def(true),
|
184
|
+
showFooter: external_shared_.PropTypes.bool.def(false),
|
185
|
+
collapseStatus: external_shared_.PropTypes.bool.def(true),
|
186
|
+
border: external_shared_.PropTypes.bool.def(true),
|
187
|
+
disableHeaderStyle: external_shared_.PropTypes.bool.def(false),
|
188
|
+
position: external_shared_.PropTypes.string.def('left'),
|
189
|
+
isEdit: external_shared_.PropTypes.bool.def(false),
|
190
|
+
isCollapse: external_shared_.PropTypes.bool.def(false)
|
110
191
|
},
|
111
192
|
emits: ['update:collapseStatus', 'edit'],
|
112
193
|
setup: function setup(props, _ref) {
|
113
194
|
var emit = _ref.emit;
|
114
195
|
|
115
196
|
/** 展开&收起的状态 */
|
116
|
-
var collapseActive = (0,
|
197
|
+
var collapseActive = (0,external_vue_.ref)(true);
|
117
198
|
/** 是否显示编辑框 */
|
118
199
|
|
119
|
-
var showInput = (0,
|
120
|
-
var renderTitle = (0,
|
200
|
+
var showInput = (0,external_vue_.ref)(false);
|
201
|
+
var renderTitle = (0,external_vue_.ref)('');
|
121
202
|
|
122
203
|
var handleCollapse = function handleCollapse() {
|
123
204
|
if (!props.isCollapse) {
|
@@ -141,14 +222,14 @@ const external_input_namespaceObject = external_input_x({ ["default"]: () => __W
|
|
141
222
|
emit('edit', renderTitle);
|
142
223
|
};
|
143
224
|
|
144
|
-
(0,
|
225
|
+
(0,external_vue_.watch)(function () {
|
145
226
|
return props.collapseStatus;
|
146
227
|
}, function (val) {
|
147
228
|
props.isCollapse && (collapseActive.value = val);
|
148
229
|
}, {
|
149
230
|
immediate: true
|
150
231
|
});
|
151
|
-
(0,
|
232
|
+
(0,external_vue_.watch)(function () {
|
152
233
|
return props.title;
|
153
234
|
}, function (val) {
|
154
235
|
renderTitle.value = val;
|
@@ -172,13 +253,13 @@ const external_input_namespaceObject = external_input_x({ ["default"]: () => __W
|
|
172
253
|
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m;
|
173
254
|
|
174
255
|
var wrapperName = 'bk-card';
|
175
|
-
var cardClass = (0,
|
176
|
-
var headClass = (0,
|
256
|
+
var cardClass = (0,external_shared_.classes)((_classes = {}, _defineProperty(_classes, "".concat(wrapperName), true), _defineProperty(_classes, "".concat(wrapperName, "-border-none"), !this.$props.border), _classes), '');
|
257
|
+
var headClass = (0,external_shared_.classes)((_classes2 = {}, _defineProperty(_classes2, "".concat(wrapperName, "-head"), true), _defineProperty(_classes2, "".concat(wrapperName, "-head-").concat(this.$props.position), this.$props.isCollapse && this.$props.position), _defineProperty(_classes2, 'no-line-height', this.$props.disableHeaderStyle), _defineProperty(_classes2, 'collapse', !this.collapseActive), _classes2), '');
|
177
258
|
|
178
|
-
var defaultHeader = (0,
|
259
|
+
var defaultHeader = (0,external_vue_.createVNode)("div", {
|
179
260
|
"class": "title",
|
180
261
|
"title": this.renderTitle
|
181
|
-
}, [this.showInput ? (0,
|
262
|
+
}, [this.showInput ? (0,external_vue_.createVNode)((external_input_default()), {
|
182
263
|
"class": "".concat(wrapperName, "-input"),
|
183
264
|
"modelValue": _this.renderTitle,
|
184
265
|
"onUpdate:modelValue": function onUpdateModelValue($event) {
|
@@ -187,21 +268,21 @@ const external_input_namespaceObject = external_input_x({ ["default"]: () => __W
|
|
187
268
|
"onBlur": this.saveEdit
|
188
269
|
}, null) : this.renderTitle]);
|
189
270
|
|
190
|
-
var defaultIcon = (0,
|
271
|
+
var defaultIcon = (0,external_vue_.createVNode)("span", {
|
191
272
|
"class": "".concat(wrapperName, "-icon"),
|
192
273
|
"onClick": this.handleCollapse
|
193
|
-
}, [this.collapseActive ? (0,
|
274
|
+
}, [this.collapseActive ? (0,external_vue_.createVNode)(external_icon_.AngleDown, null, null) : (0,external_vue_.createVNode)(external_icon_.AngleRight, null, null)]);
|
194
275
|
|
195
|
-
return (0,
|
276
|
+
return (0,external_vue_.createVNode)("div", {
|
196
277
|
"class": cardClass
|
197
|
-
}, [this.$props.showHeader ? (0,
|
278
|
+
}, [this.$props.showHeader ? (0,external_vue_.createVNode)("div", {
|
198
279
|
"class": headClass
|
199
|
-
}, [this.$props.isCollapse && ((_c = (_b = (_a = this.$slots).icon) === null || _b === void 0 ? void 0 : _b.call(_a)) !== null && _c !== void 0 ? _c : defaultIcon), (_f = (_e = (_d = this.$slots).header) === null || _e === void 0 ? void 0 : _e.call(_d)) !== null && _f !== void 0 ? _f : defaultHeader, this.$props.isEdit && !this.showInput && (0,
|
280
|
+
}, [this.$props.isCollapse && ((_c = (_b = (_a = this.$slots).icon) === null || _b === void 0 ? void 0 : _b.call(_a)) !== null && _c !== void 0 ? _c : defaultIcon), (_f = (_e = (_d = this.$slots).header) === null || _e === void 0 ? void 0 : _e.call(_d)) !== null && _f !== void 0 ? _f : defaultHeader, this.$props.isEdit && !this.showInput && (0,external_vue_.createVNode)(external_icon_.EditLine, {
|
200
281
|
"class": "".concat(wrapperName, "-edit"),
|
201
282
|
"onClick": this.clickEdit
|
202
|
-
}, null)]) : '', this.collapseActive ? (0,
|
283
|
+
}, null)]) : '', this.collapseActive ? (0,external_vue_.createVNode)("div", null, [(0,external_vue_.createVNode)("div", {
|
203
284
|
"class": "".concat(wrapperName, "-body")
|
204
|
-
}, [(_j = (_h = (_g = this.$slots)["default"]) === null || _h === void 0 ? void 0 : _h.call(_g)) !== null && _j !== void 0 ? _j : 'Content']), this.$props.showFooter ? (0,
|
285
|
+
}, [(_j = (_h = (_g = this.$slots)["default"]) === null || _h === void 0 ? void 0 : _h.call(_g)) !== null && _j !== void 0 ? _j : 'Content']), this.$props.showFooter ? (0,external_vue_.createVNode)("div", {
|
205
286
|
"class": "".concat(wrapperName, "-footer")
|
206
287
|
}, [(_m = (_l = (_k = this.$slots).footer) === null || _l === void 0 ? void 0 : _l.call(_k)) !== null && _m !== void 0 ? _m : 'Footer']) : '']) : '']);
|
207
288
|
}
|
@@ -234,8 +315,12 @@ const external_input_namespaceObject = external_input_x({ ["default"]: () => __W
|
|
234
315
|
*/
|
235
316
|
|
236
317
|
|
237
|
-
var BkCard = (0,
|
318
|
+
var BkCard = (0,external_shared_.withInstall)(card);
|
238
319
|
;
|
239
320
|
/* harmony default export */ const src = (BkCard);
|
240
|
-
|
241
|
-
|
321
|
+
})();
|
322
|
+
|
323
|
+
/******/ return __webpack_exports__;
|
324
|
+
/******/ })()
|
325
|
+
;
|
326
|
+
});
|