bkui-vue 0.0.2-beta.87 → 0.0.2-beta.89
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 +27 -27
- package/dist/index.esm.js +4464 -4517
- package/dist/index.umd.js +27 -27
- package/lib/plugin-popover/index.js +93 -277
- package/lib/popover/index.js +93 -277
- package/lib/select/index.js +10 -14
- package/lib/shared/index.js +91 -275
- package/lib/table/index.js +94 -278
- package/lib/tree/index.js +92 -276
- package/package.json +1 -1
package/lib/table/index.js
CHANGED
@@ -16,274 +16,8 @@ import * as __WEBPACK_EXTERNAL_MODULE__exception_12c197e0__ from "../exception";
|
|
16
16
|
import * as __WEBPACK_EXTERNAL_MODULE__popover_cf5f8dce__ from "../popover";
|
17
17
|
import * as __WEBPACK_EXTERNAL_MODULE__icon__2ba2075d__ from "../icon/";
|
18
18
|
import * as __WEBPACK_EXTERNAL_MODULE__button_59c00871__ from "../button";
|
19
|
-
/******/
|
20
|
-
|
21
|
-
/***/ 8022:
|
22
|
-
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {
|
23
|
-
|
24
|
-
var v1 = __webpack_require__(4481);
|
25
|
-
var v4 = __webpack_require__(6426);
|
26
|
-
|
27
|
-
var uuid = v4;
|
28
|
-
uuid.v1 = v1;
|
29
|
-
uuid.v4 = v4;
|
30
|
-
|
31
|
-
module.exports = uuid;
|
32
|
-
|
33
|
-
|
34
|
-
/***/ }),
|
35
|
-
|
36
|
-
/***/ 8725:
|
37
|
-
/***/ ((module) => {
|
38
|
-
|
39
|
-
/**
|
40
|
-
* Convert array of 16 byte values to UUID string format of the form:
|
41
|
-
* XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX
|
42
|
-
*/
|
43
|
-
var byteToHex = [];
|
44
|
-
for (var i = 0; i < 256; ++i) {
|
45
|
-
byteToHex[i] = (i + 0x100).toString(16).substr(1);
|
46
|
-
}
|
47
|
-
|
48
|
-
function bytesToUuid(buf, offset) {
|
49
|
-
var i = offset || 0;
|
50
|
-
var bth = byteToHex;
|
51
|
-
// join used to fix memory issue caused by concatenation: https://bugs.chromium.org/p/v8/issues/detail?id=3175#c4
|
52
|
-
return ([
|
53
|
-
bth[buf[i++]], bth[buf[i++]],
|
54
|
-
bth[buf[i++]], bth[buf[i++]], '-',
|
55
|
-
bth[buf[i++]], bth[buf[i++]], '-',
|
56
|
-
bth[buf[i++]], bth[buf[i++]], '-',
|
57
|
-
bth[buf[i++]], bth[buf[i++]], '-',
|
58
|
-
bth[buf[i++]], bth[buf[i++]],
|
59
|
-
bth[buf[i++]], bth[buf[i++]],
|
60
|
-
bth[buf[i++]], bth[buf[i++]]
|
61
|
-
]).join('');
|
62
|
-
}
|
63
|
-
|
64
|
-
module.exports = bytesToUuid;
|
65
|
-
|
66
|
-
|
67
|
-
/***/ }),
|
68
|
-
|
69
|
-
/***/ 9157:
|
70
|
-
/***/ ((module) => {
|
71
|
-
|
72
|
-
// Unique ID creation requires a high quality random # generator. In the
|
73
|
-
// browser this is a little complicated due to unknown quality of Math.random()
|
74
|
-
// and inconsistent support for the `crypto` API. We do the best we can via
|
75
|
-
// feature-detection
|
76
|
-
|
77
|
-
// getRandomValues needs to be invoked in a context where "this" is a Crypto
|
78
|
-
// implementation. Also, find the complete implementation of crypto on IE11.
|
79
|
-
var getRandomValues = (typeof(crypto) != 'undefined' && crypto.getRandomValues && crypto.getRandomValues.bind(crypto)) ||
|
80
|
-
(typeof(msCrypto) != 'undefined' && typeof window.msCrypto.getRandomValues == 'function' && msCrypto.getRandomValues.bind(msCrypto));
|
81
|
-
|
82
|
-
if (getRandomValues) {
|
83
|
-
// WHATWG crypto RNG - http://wiki.whatwg.org/wiki/Crypto
|
84
|
-
var rnds8 = new Uint8Array(16); // eslint-disable-line no-undef
|
85
|
-
|
86
|
-
module.exports = function whatwgRNG() {
|
87
|
-
getRandomValues(rnds8);
|
88
|
-
return rnds8;
|
89
|
-
};
|
90
|
-
} else {
|
91
|
-
// Math.random()-based (RNG)
|
92
|
-
//
|
93
|
-
// If all else fails, use Math.random(). It's fast, but is of unspecified
|
94
|
-
// quality.
|
95
|
-
var rnds = new Array(16);
|
96
|
-
|
97
|
-
module.exports = function mathRNG() {
|
98
|
-
for (var i = 0, r; i < 16; i++) {
|
99
|
-
if ((i & 0x03) === 0) r = Math.random() * 0x100000000;
|
100
|
-
rnds[i] = r >>> ((i & 0x03) << 3) & 0xff;
|
101
|
-
}
|
102
|
-
|
103
|
-
return rnds;
|
104
|
-
};
|
105
|
-
}
|
106
|
-
|
107
|
-
|
108
|
-
/***/ }),
|
109
|
-
|
110
|
-
/***/ 4481:
|
111
|
-
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {
|
112
|
-
|
113
|
-
var rng = __webpack_require__(9157);
|
114
|
-
var bytesToUuid = __webpack_require__(8725);
|
115
|
-
|
116
|
-
// **`v1()` - Generate time-based UUID**
|
117
|
-
//
|
118
|
-
// Inspired by https://github.com/LiosK/UUID.js
|
119
|
-
// and http://docs.python.org/library/uuid.html
|
120
|
-
|
121
|
-
var _nodeId;
|
122
|
-
var _clockseq;
|
123
|
-
|
124
|
-
// Previous uuid creation time
|
125
|
-
var _lastMSecs = 0;
|
126
|
-
var _lastNSecs = 0;
|
127
|
-
|
128
|
-
// See https://github.com/uuidjs/uuid for API details
|
129
|
-
function v1(options, buf, offset) {
|
130
|
-
var i = buf && offset || 0;
|
131
|
-
var b = buf || [];
|
132
|
-
|
133
|
-
options = options || {};
|
134
|
-
var node = options.node || _nodeId;
|
135
|
-
var clockseq = options.clockseq !== undefined ? options.clockseq : _clockseq;
|
136
|
-
|
137
|
-
// node and clockseq need to be initialized to random values if they're not
|
138
|
-
// specified. We do this lazily to minimize issues related to insufficient
|
139
|
-
// system entropy. See #189
|
140
|
-
if (node == null || clockseq == null) {
|
141
|
-
var seedBytes = rng();
|
142
|
-
if (node == null) {
|
143
|
-
// Per 4.5, create and 48-bit node id, (47 random bits + multicast bit = 1)
|
144
|
-
node = _nodeId = [
|
145
|
-
seedBytes[0] | 0x01,
|
146
|
-
seedBytes[1], seedBytes[2], seedBytes[3], seedBytes[4], seedBytes[5]
|
147
|
-
];
|
148
|
-
}
|
149
|
-
if (clockseq == null) {
|
150
|
-
// Per 4.2.2, randomize (14 bit) clockseq
|
151
|
-
clockseq = _clockseq = (seedBytes[6] << 8 | seedBytes[7]) & 0x3fff;
|
152
|
-
}
|
153
|
-
}
|
154
|
-
|
155
|
-
// UUID timestamps are 100 nano-second units since the Gregorian epoch,
|
156
|
-
// (1582-10-15 00:00). JSNumbers aren't precise enough for this, so
|
157
|
-
// time is handled internally as 'msecs' (integer milliseconds) and 'nsecs'
|
158
|
-
// (100-nanoseconds offset from msecs) since unix epoch, 1970-01-01 00:00.
|
159
|
-
var msecs = options.msecs !== undefined ? options.msecs : new Date().getTime();
|
160
|
-
|
161
|
-
// Per 4.2.1.2, use count of uuid's generated during the current clock
|
162
|
-
// cycle to simulate higher resolution clock
|
163
|
-
var nsecs = options.nsecs !== undefined ? options.nsecs : _lastNSecs + 1;
|
164
|
-
|
165
|
-
// Time since last uuid creation (in msecs)
|
166
|
-
var dt = (msecs - _lastMSecs) + (nsecs - _lastNSecs)/10000;
|
167
|
-
|
168
|
-
// Per 4.2.1.2, Bump clockseq on clock regression
|
169
|
-
if (dt < 0 && options.clockseq === undefined) {
|
170
|
-
clockseq = clockseq + 1 & 0x3fff;
|
171
|
-
}
|
172
|
-
|
173
|
-
// Reset nsecs if clock regresses (new clockseq) or we've moved onto a new
|
174
|
-
// time interval
|
175
|
-
if ((dt < 0 || msecs > _lastMSecs) && options.nsecs === undefined) {
|
176
|
-
nsecs = 0;
|
177
|
-
}
|
178
|
-
|
179
|
-
// Per 4.2.1.2 Throw error if too many uuids are requested
|
180
|
-
if (nsecs >= 10000) {
|
181
|
-
throw new Error('uuid.v1(): Can\'t create more than 10M uuids/sec');
|
182
|
-
}
|
183
|
-
|
184
|
-
_lastMSecs = msecs;
|
185
|
-
_lastNSecs = nsecs;
|
186
|
-
_clockseq = clockseq;
|
187
|
-
|
188
|
-
// Per 4.1.4 - Convert from unix epoch to Gregorian epoch
|
189
|
-
msecs += 12219292800000;
|
190
|
-
|
191
|
-
// `time_low`
|
192
|
-
var tl = ((msecs & 0xfffffff) * 10000 + nsecs) % 0x100000000;
|
193
|
-
b[i++] = tl >>> 24 & 0xff;
|
194
|
-
b[i++] = tl >>> 16 & 0xff;
|
195
|
-
b[i++] = tl >>> 8 & 0xff;
|
196
|
-
b[i++] = tl & 0xff;
|
197
|
-
|
198
|
-
// `time_mid`
|
199
|
-
var tmh = (msecs / 0x100000000 * 10000) & 0xfffffff;
|
200
|
-
b[i++] = tmh >>> 8 & 0xff;
|
201
|
-
b[i++] = tmh & 0xff;
|
202
|
-
|
203
|
-
// `time_high_and_version`
|
204
|
-
b[i++] = tmh >>> 24 & 0xf | 0x10; // include version
|
205
|
-
b[i++] = tmh >>> 16 & 0xff;
|
206
|
-
|
207
|
-
// `clock_seq_hi_and_reserved` (Per 4.2.2 - include variant)
|
208
|
-
b[i++] = clockseq >>> 8 | 0x80;
|
209
|
-
|
210
|
-
// `clock_seq_low`
|
211
|
-
b[i++] = clockseq & 0xff;
|
212
|
-
|
213
|
-
// `node`
|
214
|
-
for (var n = 0; n < 6; ++n) {
|
215
|
-
b[i + n] = node[n];
|
216
|
-
}
|
217
|
-
|
218
|
-
return buf ? buf : bytesToUuid(b);
|
219
|
-
}
|
220
|
-
|
221
|
-
module.exports = v1;
|
222
|
-
|
223
|
-
|
224
|
-
/***/ }),
|
225
|
-
|
226
|
-
/***/ 6426:
|
227
|
-
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {
|
228
|
-
|
229
|
-
var rng = __webpack_require__(9157);
|
230
|
-
var bytesToUuid = __webpack_require__(8725);
|
231
|
-
|
232
|
-
function v4(options, buf, offset) {
|
233
|
-
var i = buf && offset || 0;
|
234
|
-
|
235
|
-
if (typeof(options) == 'string') {
|
236
|
-
buf = options === 'binary' ? new Array(16) : null;
|
237
|
-
options = null;
|
238
|
-
}
|
239
|
-
options = options || {};
|
240
|
-
|
241
|
-
var rnds = options.random || (options.rng || rng)();
|
242
|
-
|
243
|
-
// Per 4.4, set bits for version and `clock_seq_hi_and_reserved`
|
244
|
-
rnds[6] = (rnds[6] & 0x0f) | 0x40;
|
245
|
-
rnds[8] = (rnds[8] & 0x3f) | 0x80;
|
246
|
-
|
247
|
-
// Copy bytes to buffer, if provided
|
248
|
-
if (buf) {
|
249
|
-
for (var ii = 0; ii < 16; ++ii) {
|
250
|
-
buf[i + ii] = rnds[ii];
|
251
|
-
}
|
252
|
-
}
|
253
|
-
|
254
|
-
return buf || bytesToUuid(rnds);
|
255
|
-
}
|
256
|
-
|
257
|
-
module.exports = v4;
|
258
|
-
|
259
|
-
|
260
|
-
/***/ })
|
261
|
-
|
262
|
-
/******/ });
|
263
|
-
/************************************************************************/
|
264
|
-
/******/ // The module cache
|
265
|
-
/******/ var __webpack_module_cache__ = {};
|
266
|
-
/******/
|
267
|
-
/******/ // The require function
|
268
|
-
/******/ function __webpack_require__(moduleId) {
|
269
|
-
/******/ // Check if module is in cache
|
270
|
-
/******/ var cachedModule = __webpack_module_cache__[moduleId];
|
271
|
-
/******/ if (cachedModule !== undefined) {
|
272
|
-
/******/ return cachedModule.exports;
|
273
|
-
/******/ }
|
274
|
-
/******/ // Create a new module (and put it into the cache)
|
275
|
-
/******/ var module = __webpack_module_cache__[moduleId] = {
|
276
|
-
/******/ // no module.id needed
|
277
|
-
/******/ // no module.loaded needed
|
278
|
-
/******/ exports: {}
|
279
|
-
/******/ };
|
280
|
-
/******/
|
281
|
-
/******/ // Execute the module function
|
282
|
-
/******/ __webpack_modules__[moduleId](module, module.exports, __webpack_require__);
|
283
|
-
/******/
|
284
|
-
/******/ // Return the exports of the module
|
285
|
-
/******/ return module.exports;
|
286
|
-
/******/ }
|
19
|
+
/******/ // The require scope
|
20
|
+
/******/ var __webpack_require__ = {};
|
287
21
|
/******/
|
288
22
|
/************************************************************************/
|
289
23
|
/******/ /* webpack/runtime/define property getters */
|
@@ -317,8 +51,6 @@ module.exports = v4;
|
|
317
51
|
/******/
|
318
52
|
/************************************************************************/
|
319
53
|
var __webpack_exports__ = {};
|
320
|
-
// This entry need to be wrapped in an IIFE because it need to be isolated against other modules in the chunk.
|
321
|
-
(() => {
|
322
54
|
|
323
55
|
// EXPORTS
|
324
56
|
__webpack_require__.d(__webpack_exports__, {
|
@@ -1746,8 +1478,94 @@ const external_loading_namespaceObject = external_loading_x({ ["BkLoadingMode"]:
|
|
1746
1478
|
renderScrollLoading: renderScrollLoading
|
1747
1479
|
};
|
1748
1480
|
});
|
1749
|
-
|
1750
|
-
|
1481
|
+
;// CONCATENATED MODULE: ../../node_modules/uuid/dist/esm-browser/native.js
|
1482
|
+
const randomUUID = typeof crypto !== 'undefined' && crypto.randomUUID && crypto.randomUUID.bind(crypto);
|
1483
|
+
/* harmony default export */ const esm_browser_native = ({
|
1484
|
+
randomUUID
|
1485
|
+
});
|
1486
|
+
;// CONCATENATED MODULE: ../../node_modules/uuid/dist/esm-browser/rng.js
|
1487
|
+
// Unique ID creation requires a high quality random # generator. In the browser we therefore
|
1488
|
+
// require the crypto API and do not support built-in fallback to lower quality random number
|
1489
|
+
// generators (like Math.random()).
|
1490
|
+
let getRandomValues;
|
1491
|
+
const rnds8 = new Uint8Array(16);
|
1492
|
+
function rng() {
|
1493
|
+
// lazy load so that environments that need to polyfill have a chance to do so
|
1494
|
+
if (!getRandomValues) {
|
1495
|
+
// getRandomValues needs to be invoked in a context where "this" is a Crypto implementation.
|
1496
|
+
getRandomValues = typeof crypto !== 'undefined' && crypto.getRandomValues && crypto.getRandomValues.bind(crypto);
|
1497
|
+
|
1498
|
+
if (!getRandomValues) {
|
1499
|
+
throw new Error('crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported');
|
1500
|
+
}
|
1501
|
+
}
|
1502
|
+
|
1503
|
+
return getRandomValues(rnds8);
|
1504
|
+
}
|
1505
|
+
;// CONCATENATED MODULE: ../../node_modules/uuid/dist/esm-browser/stringify.js
|
1506
|
+
|
1507
|
+
/**
|
1508
|
+
* Convert array of 16 byte values to UUID string format of the form:
|
1509
|
+
* XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX
|
1510
|
+
*/
|
1511
|
+
|
1512
|
+
const byteToHex = [];
|
1513
|
+
|
1514
|
+
for (let i = 0; i < 256; ++i) {
|
1515
|
+
byteToHex.push((i + 0x100).toString(16).slice(1));
|
1516
|
+
}
|
1517
|
+
|
1518
|
+
function unsafeStringify(arr, offset = 0) {
|
1519
|
+
// Note: Be careful editing this code! It's been tuned for performance
|
1520
|
+
// and works in ways you may not expect. See https://github.com/uuidjs/uuid/pull/434
|
1521
|
+
return byteToHex[arr[offset + 0]] + byteToHex[arr[offset + 1]] + byteToHex[arr[offset + 2]] + byteToHex[arr[offset + 3]] + '-' + byteToHex[arr[offset + 4]] + byteToHex[arr[offset + 5]] + '-' + byteToHex[arr[offset + 6]] + byteToHex[arr[offset + 7]] + '-' + byteToHex[arr[offset + 8]] + byteToHex[arr[offset + 9]] + '-' + byteToHex[arr[offset + 10]] + byteToHex[arr[offset + 11]] + byteToHex[arr[offset + 12]] + byteToHex[arr[offset + 13]] + byteToHex[arr[offset + 14]] + byteToHex[arr[offset + 15]];
|
1522
|
+
}
|
1523
|
+
|
1524
|
+
function stringify(arr, offset = 0) {
|
1525
|
+
const uuid = unsafeStringify(arr, offset); // Consistency check for valid UUID. If this throws, it's likely due to one
|
1526
|
+
// of the following:
|
1527
|
+
// - One or more input array values don't map to a hex octet (leading to
|
1528
|
+
// "undefined" in the uuid)
|
1529
|
+
// - Invalid input values for the RFC `version` or `variant` fields
|
1530
|
+
|
1531
|
+
if (!validate(uuid)) {
|
1532
|
+
throw TypeError('Stringified UUID is invalid');
|
1533
|
+
}
|
1534
|
+
|
1535
|
+
return uuid;
|
1536
|
+
}
|
1537
|
+
|
1538
|
+
/* harmony default export */ const esm_browser_stringify = ((/* unused pure expression or super */ null && (stringify)));
|
1539
|
+
;// CONCATENATED MODULE: ../../node_modules/uuid/dist/esm-browser/v4.js
|
1540
|
+
|
1541
|
+
|
1542
|
+
|
1543
|
+
|
1544
|
+
function v4(options, buf, offset) {
|
1545
|
+
if (esm_browser_native.randomUUID && !buf && !options) {
|
1546
|
+
return esm_browser_native.randomUUID();
|
1547
|
+
}
|
1548
|
+
|
1549
|
+
options = options || {};
|
1550
|
+
const rnds = options.random || (options.rng || rng)(); // Per 4.4, set bits for version and `clock_seq_hi_and_reserved`
|
1551
|
+
|
1552
|
+
rnds[6] = rnds[6] & 0x0f | 0x40;
|
1553
|
+
rnds[8] = rnds[8] & 0x3f | 0x80; // Copy bytes to buffer, if provided
|
1554
|
+
|
1555
|
+
if (buf) {
|
1556
|
+
offset = offset || 0;
|
1557
|
+
|
1558
|
+
for (let i = 0; i < 16; ++i) {
|
1559
|
+
buf[offset + i] = rnds[i];
|
1560
|
+
}
|
1561
|
+
|
1562
|
+
return buf;
|
1563
|
+
}
|
1564
|
+
|
1565
|
+
return unsafeStringify(rnds);
|
1566
|
+
}
|
1567
|
+
|
1568
|
+
/* harmony default export */ const esm_browser_v4 = (v4);
|
1751
1569
|
;// CONCATENATED MODULE: ../../packages/table/src/plugins/use-pagination.tsx
|
1752
1570
|
|
1753
1571
|
|
@@ -3115,7 +2933,7 @@ var getRowKey = function getRowKey(item, props, index) {
|
|
3115
2933
|
if (val !== null) {
|
3116
2934
|
return val;
|
3117
2935
|
}
|
3118
|
-
return (
|
2936
|
+
return esm_browser_v4();
|
3119
2937
|
};
|
3120
2938
|
var getRowKeyNull = function getRowKeyNull(item, props, index) {
|
3121
2939
|
if (typeof props.rowKey === 'string') {
|
@@ -3413,7 +3231,7 @@ function use_attributes_objectSpread(target) { for (var i = 1; i < arguments.len
|
|
3413
3231
|
skipCol: skipCol,
|
3414
3232
|
skipColumnNum: skipColumnNum,
|
3415
3233
|
skipColLen: skipColLen
|
3416
|
-
}), defineProperty_defineProperty(_formatData$columnSch, COLUMN_ATTRIBUTE.COL_UID, (
|
3234
|
+
}), defineProperty_defineProperty(_formatData$columnSch, COLUMN_ATTRIBUTE.COL_UID, esm_browser_v4()), _formatData$columnSch));
|
3417
3235
|
}
|
3418
3236
|
Object.assign(formatData.columnSchema.get(col), defineProperty_defineProperty({}, COLUMN_ATTRIBUTE.COL_SPAN, {
|
3419
3237
|
skipCol: skipCol,
|
@@ -3647,7 +3465,7 @@ function use_attributes_objectSpread(target) { for (var i = 1; i < arguments.len
|
|
3647
3465
|
var hasSelectedRow = false;
|
3648
3466
|
var hasUnSelectedRow = false;
|
3649
3467
|
(data || []).forEach(function (row, index) {
|
3650
|
-
var rowId = getRowId(row, (
|
3468
|
+
var rowId = getRowId(row, esm_browser_v4(), props);
|
3651
3469
|
var isSelected = isRowSelected(row);
|
3652
3470
|
if (isSelected) {
|
3653
3471
|
hasSelectedRow = true;
|
@@ -5433,7 +5251,7 @@ function use_render_isSlot(s) {
|
|
5433
5251
|
}
|
5434
5252
|
/* harmony default export */ const use_render = (function (props, context, tableResp, styleRef, head) {
|
5435
5253
|
var t = (0,external_config_provider_namespaceObject.useLocale)('table');
|
5436
|
-
var uuid = (
|
5254
|
+
var uuid = esm_browser_v4();
|
5437
5255
|
var formatData = (0,external_vue_namespaceObject.computed)(function () {
|
5438
5256
|
return tableResp.formatData;
|
5439
5257
|
});
|
@@ -6419,8 +6237,6 @@ var BkTable = (0,external_shared_namespaceObject.withInstallProps)(table, {
|
|
6419
6237
|
});
|
6420
6238
|
/* harmony default export */ const src = (BkTable);
|
6421
6239
|
|
6422
|
-
})();
|
6423
|
-
|
6424
6240
|
var __webpack_exports__BkTable = __webpack_exports__.IR;
|
6425
6241
|
var __webpack_exports__BkTableColumn = __webpack_exports__.Nr;
|
6426
6242
|
var __webpack_exports__default = __webpack_exports__.ZP;
|