nubomed-ui 2.0.31 → 2.0.32
Sign up to get free protection for your applications and to get access to all the features.
- package/nubomed-ui.common.js +384 -63
- package/nubomed-ui.common.js.map +1 -1
- package/nubomed-ui.umd.js +391 -70
- package/nubomed-ui.umd.js.map +1 -1
- package/nubomed-ui.umd.min.js +1 -1
- package/nubomed-ui.umd.min.js.map +1 -1
- package/package.json +1 -1
package/nubomed-ui.umd.js
CHANGED
@@ -1,13 +1,13 @@
|
|
1
1
|
(function webpackUniversalModuleDefinition(root, factory) {
|
2
2
|
if(typeof exports === 'object' && typeof module === 'object')
|
3
|
-
module.exports = factory(require("
|
3
|
+
module.exports = factory(require("vue"));
|
4
4
|
else if(typeof define === 'function' && define.amd)
|
5
|
-
define([
|
5
|
+
define([], factory);
|
6
6
|
else if(typeof exports === 'object')
|
7
|
-
exports["nubomed-ui"] = factory(require("
|
7
|
+
exports["nubomed-ui"] = factory(require("vue"));
|
8
8
|
else
|
9
|
-
root["nubomed-ui"] = factory(root["
|
10
|
-
})((typeof self !== 'undefined' ? self : this), function(
|
9
|
+
root["nubomed-ui"] = factory(root["Vue"]);
|
10
|
+
})((typeof self !== 'undefined' ? self : this), function(__WEBPACK_EXTERNAL_MODULE__9274__) {
|
11
11
|
return /******/ (function() { // webpackBootstrap
|
12
12
|
/******/ var __webpack_modules__ = ({
|
13
13
|
|
@@ -167,6 +167,27 @@ ___CSS_LOADER_EXPORT___.push([module.id, ".iconfont[data-v-1d7955de]{display:inl
|
|
167
167
|
/* harmony default export */ __webpack_exports__["default"] = (___CSS_LOADER_EXPORT___);
|
168
168
|
|
169
169
|
|
170
|
+
/***/ }),
|
171
|
+
|
172
|
+
/***/ 4474:
|
173
|
+
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
174
|
+
|
175
|
+
"use strict";
|
176
|
+
__webpack_require__.r(__webpack_exports__);
|
177
|
+
/* harmony import */ var _node_modules_css_loader_dist_runtime_noSourceMaps_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(1601);
|
178
|
+
/* harmony import */ var _node_modules_css_loader_dist_runtime_noSourceMaps_js__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_node_modules_css_loader_dist_runtime_noSourceMaps_js__WEBPACK_IMPORTED_MODULE_0__);
|
179
|
+
/* harmony import */ var _node_modules_css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6314);
|
180
|
+
/* harmony import */ var _node_modules_css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_node_modules_css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_1__);
|
181
|
+
// Imports
|
182
|
+
|
183
|
+
|
184
|
+
var ___CSS_LOADER_EXPORT___ = _node_modules_css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_1___default()((_node_modules_css_loader_dist_runtime_noSourceMaps_js__WEBPACK_IMPORTED_MODULE_0___default()));
|
185
|
+
// Module
|
186
|
+
___CSS_LOADER_EXPORT___.push([module.id, ".el-pagination--left[data-v-15e54efa]{text-align:left}.el-pagination--center[data-v-15e54efa]{text-align:center}.el-pagination--right[data-v-15e54efa]{text-align:right}", ""]);
|
187
|
+
// Exports
|
188
|
+
/* harmony default export */ __webpack_exports__["default"] = (___CSS_LOADER_EXPORT___);
|
189
|
+
|
190
|
+
|
170
191
|
/***/ }),
|
171
192
|
|
172
193
|
/***/ 9836:
|
@@ -1122,6 +1143,346 @@ src.install = function (Vue) {
|
|
1122
1143
|
|
1123
1144
|
/***/ }),
|
1124
1145
|
|
1146
|
+
/***/ 135:
|
1147
|
+
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) {
|
1148
|
+
|
1149
|
+
"use strict";
|
1150
|
+
__webpack_require__.r(__webpack_exports__);
|
1151
|
+
/* harmony import */ var _src_index_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(5113);
|
1152
|
+
/*
|
1153
|
+
* @Author: chenghuan.dong
|
1154
|
+
* @Date: 2024-11-14 09:43:03
|
1155
|
+
* @LastEditTime: 2024-11-14 09:54:03
|
1156
|
+
* @LastEditors: chenghuan.dong
|
1157
|
+
* @Description:
|
1158
|
+
* @FilePath: \nubomed-ui\packages\components\NBNotify\index.js
|
1159
|
+
*/
|
1160
|
+
|
1161
|
+
/* harmony default export */ __webpack_exports__["default"] = (_src_index_js__WEBPACK_IMPORTED_MODULE_0__["default"]);
|
1162
|
+
|
1163
|
+
/***/ }),
|
1164
|
+
|
1165
|
+
/***/ 5113:
|
1166
|
+
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) {
|
1167
|
+
|
1168
|
+
"use strict";
|
1169
|
+
// ESM COMPAT FLAG
|
1170
|
+
__webpack_require__.r(__webpack_exports__);
|
1171
|
+
|
1172
|
+
// EXPORTS
|
1173
|
+
__webpack_require__.d(__webpack_exports__, {
|
1174
|
+
"default": function() { return /* binding */ NBNotify_src; }
|
1175
|
+
});
|
1176
|
+
|
1177
|
+
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.array.push.js
|
1178
|
+
var es_array_push = __webpack_require__(4114);
|
1179
|
+
// EXTERNAL MODULE: ./node_modules/core-js/modules/esnext.iterator.constructor.js
|
1180
|
+
var esnext_iterator_constructor = __webpack_require__(8992);
|
1181
|
+
// EXTERNAL MODULE: ./node_modules/core-js/modules/esnext.iterator.for-each.js
|
1182
|
+
var esnext_iterator_for_each = __webpack_require__(3949);
|
1183
|
+
// EXTERNAL MODULE: external {"commonjs":"vue","commonjs2":"vue","root":"Vue"}
|
1184
|
+
var external_commonjs_vue_commonjs2_vue_root_Vue_ = __webpack_require__(9274);
|
1185
|
+
var external_commonjs_vue_commonjs2_vue_root_Vue_default = /*#__PURE__*/__webpack_require__.n(external_commonjs_vue_commonjs2_vue_root_Vue_);
|
1186
|
+
;// ./node_modules/thread-loader/dist/cjs.js!./node_modules/babel-loader/lib/index.js??clonedRuleSet-82.use[1]!./node_modules/@vue/vue-loader-v15/lib/loaders/templateLoader.js??ruleSet[1].rules[3]!./node_modules/@vue/vue-loader-v15/lib/index.js??vue-loader-options!./packages/components/NBNotify/src/index.vue?vue&type=template&id=15e54efa&scoped=true
|
1187
|
+
var render = function render() {
|
1188
|
+
var _vm = this,
|
1189
|
+
_c = _vm._self._c;
|
1190
|
+
return _c('transition', {
|
1191
|
+
attrs: {
|
1192
|
+
"name": "el-notification-fade"
|
1193
|
+
}
|
1194
|
+
}, [_c('div', {
|
1195
|
+
directives: [{
|
1196
|
+
name: "show",
|
1197
|
+
rawName: "v-show",
|
1198
|
+
value: _vm.visible,
|
1199
|
+
expression: "visible"
|
1200
|
+
}],
|
1201
|
+
class: ['el-notification', 'nb-notification'],
|
1202
|
+
style: _vm.positionStyle,
|
1203
|
+
attrs: {
|
1204
|
+
"role": "alert"
|
1205
|
+
},
|
1206
|
+
on: {
|
1207
|
+
"mouseenter": function ($event) {
|
1208
|
+
return _vm.clearTimer();
|
1209
|
+
},
|
1210
|
+
"mouseleave": function ($event) {
|
1211
|
+
return _vm.startTimer();
|
1212
|
+
},
|
1213
|
+
"click": _vm.click
|
1214
|
+
}
|
1215
|
+
}, [_vm.type || _vm.iconClass ? _c('i', {
|
1216
|
+
staticClass: "el-notification__icon",
|
1217
|
+
class: [_vm.typeClass, _vm.iconClass]
|
1218
|
+
}) : _vm._e(), _c('div', {
|
1219
|
+
staticClass: "el-notification__group",
|
1220
|
+
class: {
|
1221
|
+
'is-with-icon': _vm.typeClass || _vm.iconClass
|
1222
|
+
}
|
1223
|
+
}, [_c('h2', {
|
1224
|
+
staticClass: "el-notification__title",
|
1225
|
+
domProps: {
|
1226
|
+
"textContent": _vm._s(_vm.title)
|
1227
|
+
}
|
1228
|
+
}), _c('div', {
|
1229
|
+
directives: [{
|
1230
|
+
name: "show",
|
1231
|
+
rawName: "v-show",
|
1232
|
+
value: _vm.message,
|
1233
|
+
expression: "message"
|
1234
|
+
}],
|
1235
|
+
staticClass: "el-notification__content"
|
1236
|
+
}, [_vm._t("default", function () {
|
1237
|
+
return [!_vm.dangerouslyUseHTMLString ? _c('p', [_vm._v(_vm._s(_vm.message))]) : _vm._e(), _c('p', {
|
1238
|
+
domProps: {
|
1239
|
+
"innerHTML": _vm._s(_vm.message)
|
1240
|
+
}
|
1241
|
+
})];
|
1242
|
+
})], 2), _vm.showClose ? _c('div', {
|
1243
|
+
staticClass: "el-notification__closeBtn el-icon-close",
|
1244
|
+
on: {
|
1245
|
+
"click": function ($event) {
|
1246
|
+
$event.stopPropagation();
|
1247
|
+
return _vm.close.apply(null, arguments);
|
1248
|
+
}
|
1249
|
+
}
|
1250
|
+
}) : _vm._e()])])]);
|
1251
|
+
};
|
1252
|
+
var staticRenderFns = [];
|
1253
|
+
|
1254
|
+
;// ./node_modules/thread-loader/dist/cjs.js!./node_modules/babel-loader/lib/index.js??clonedRuleSet-82.use[1]!./node_modules/@vue/vue-loader-v15/lib/index.js??vue-loader-options!./packages/components/NBNotify/src/index.vue?vue&type=script&lang=js
|
1255
|
+
let typeMap = {
|
1256
|
+
success: 'success',
|
1257
|
+
info: 'info',
|
1258
|
+
warning: 'warning',
|
1259
|
+
error: 'error'
|
1260
|
+
};
|
1261
|
+
/* harmony default export */ var srcvue_type_script_lang_js = ({
|
1262
|
+
name: 'NBNotify',
|
1263
|
+
data() {
|
1264
|
+
return {
|
1265
|
+
visible: false,
|
1266
|
+
title: '',
|
1267
|
+
message: '',
|
1268
|
+
duration: 4500,
|
1269
|
+
type: '',
|
1270
|
+
showClose: false,
|
1271
|
+
customClass: '',
|
1272
|
+
iconClass: '',
|
1273
|
+
onClose: null,
|
1274
|
+
onClick: null,
|
1275
|
+
closed: false,
|
1276
|
+
verticalOffset: 0,
|
1277
|
+
timer: null,
|
1278
|
+
dangerouslyUseHTMLString: true,
|
1279
|
+
position: 'top-right'
|
1280
|
+
};
|
1281
|
+
},
|
1282
|
+
computed: {
|
1283
|
+
typeClass() {
|
1284
|
+
return this.type && typeMap[this.type] ? `el-icon-${typeMap[this.type]}` : '';
|
1285
|
+
},
|
1286
|
+
horizontalClass() {
|
1287
|
+
return this.position.indexOf('right') > -1 ? 'right' : 'left';
|
1288
|
+
},
|
1289
|
+
verticalProperty() {
|
1290
|
+
return /^top-/.test(this.position) ? 'top' : 'bottom';
|
1291
|
+
},
|
1292
|
+
positionStyle() {
|
1293
|
+
return {
|
1294
|
+
[this.verticalProperty]: `${this.verticalOffset}px`
|
1295
|
+
};
|
1296
|
+
}
|
1297
|
+
},
|
1298
|
+
watch: {
|
1299
|
+
closed(newVal) {
|
1300
|
+
if (newVal) {
|
1301
|
+
this.visible = false;
|
1302
|
+
this.$el.addEventListener('transitionend', this.destroyElement);
|
1303
|
+
}
|
1304
|
+
}
|
1305
|
+
},
|
1306
|
+
methods: {
|
1307
|
+
destroyElement() {
|
1308
|
+
this.$el.removeEventListener('transitionend', this.destroyElement);
|
1309
|
+
this.$destroy(true);
|
1310
|
+
this.$el.parentNode.removeChild(this.$el);
|
1311
|
+
},
|
1312
|
+
click() {
|
1313
|
+
if (typeof this.onClick === 'function') {
|
1314
|
+
this.onClick();
|
1315
|
+
}
|
1316
|
+
},
|
1317
|
+
close() {
|
1318
|
+
this.closed = true;
|
1319
|
+
if (typeof this.onClose === 'function') {
|
1320
|
+
this.onClose();
|
1321
|
+
}
|
1322
|
+
},
|
1323
|
+
clearTimer() {
|
1324
|
+
clearTimeout(this.timer);
|
1325
|
+
},
|
1326
|
+
startTimer() {
|
1327
|
+
if (this.duration > 0) {
|
1328
|
+
this.timer = setTimeout(() => {
|
1329
|
+
if (!this.closed) {
|
1330
|
+
this.close();
|
1331
|
+
}
|
1332
|
+
}, this.duration);
|
1333
|
+
}
|
1334
|
+
},
|
1335
|
+
keydown(e) {
|
1336
|
+
if (e.keyCode === 46 || e.keyCode === 8) {
|
1337
|
+
this.clearTimer(); // detele 取消倒计时
|
1338
|
+
} else if (e.keyCode === 27) {
|
1339
|
+
// esc关闭消息
|
1340
|
+
if (!this.closed) {
|
1341
|
+
this.close();
|
1342
|
+
}
|
1343
|
+
} else {
|
1344
|
+
this.startTimer(); // 恢复倒计时
|
1345
|
+
}
|
1346
|
+
}
|
1347
|
+
},
|
1348
|
+
mounted() {
|
1349
|
+
if (this.duration > 0) {
|
1350
|
+
this.timer = setTimeout(() => {
|
1351
|
+
if (!this.closed) {
|
1352
|
+
this.close();
|
1353
|
+
}
|
1354
|
+
}, this.duration);
|
1355
|
+
}
|
1356
|
+
document.addEventListener('keydown', this.keydown);
|
1357
|
+
},
|
1358
|
+
beforeDestroy() {
|
1359
|
+
document.removeEventListener('keydown', this.keydown);
|
1360
|
+
}
|
1361
|
+
});
|
1362
|
+
;// ./packages/components/NBNotify/src/index.vue?vue&type=script&lang=js
|
1363
|
+
/* harmony default export */ var NBNotify_srcvue_type_script_lang_js = (srcvue_type_script_lang_js);
|
1364
|
+
// EXTERNAL MODULE: ./node_modules/vue-style-loader/index.js??clonedRuleSet-64.use[0]!./node_modules/css-loader/dist/cjs.js??clonedRuleSet-64.use[1]!./node_modules/@vue/vue-loader-v15/lib/loaders/stylePostLoader.js!./node_modules/postcss-loader/dist/cjs.js??clonedRuleSet-64.use[2]!./node_modules/postcss-loader/dist/cjs.js??clonedRuleSet-64.use[3]!./node_modules/sass-loader/dist/cjs.js??clonedRuleSet-64.use[4]!./node_modules/@vue/vue-loader-v15/lib/index.js??vue-loader-options!./packages/components/NBNotify/src/index.vue?vue&type=style&index=0&id=15e54efa&prod&lang=scss&scoped=true
|
1365
|
+
var srcvue_type_style_index_0_id_15e54efa_prod_lang_scss_scoped_true = __webpack_require__(8974);
|
1366
|
+
;// ./packages/components/NBNotify/src/index.vue?vue&type=style&index=0&id=15e54efa&prod&lang=scss&scoped=true
|
1367
|
+
|
1368
|
+
// EXTERNAL MODULE: ./node_modules/@vue/vue-loader-v15/lib/runtime/componentNormalizer.js
|
1369
|
+
var componentNormalizer = __webpack_require__(1656);
|
1370
|
+
;// ./packages/components/NBNotify/src/index.vue
|
1371
|
+
|
1372
|
+
|
1373
|
+
|
1374
|
+
;
|
1375
|
+
|
1376
|
+
|
1377
|
+
/* normalize component */
|
1378
|
+
|
1379
|
+
var component = (0,componentNormalizer/* default */.A)(
|
1380
|
+
NBNotify_srcvue_type_script_lang_js,
|
1381
|
+
render,
|
1382
|
+
staticRenderFns,
|
1383
|
+
false,
|
1384
|
+
null,
|
1385
|
+
"15e54efa",
|
1386
|
+
null
|
1387
|
+
|
1388
|
+
)
|
1389
|
+
|
1390
|
+
/* harmony default export */ var src = (component.exports);
|
1391
|
+
;// ./packages/components/NBNotify/src/index.js
|
1392
|
+
|
1393
|
+
|
1394
|
+
|
1395
|
+
/*
|
1396
|
+
* @Author: chenghuan.dong
|
1397
|
+
* @Date: 2024-11-14 09:44:58
|
1398
|
+
* @LastEditTime: 2024-11-14 10:06:12
|
1399
|
+
* @LastEditors: chenghuan.dong
|
1400
|
+
* @Description:
|
1401
|
+
* @FilePath: \nubomed-ui\packages\components\NBNotify\src\index.js
|
1402
|
+
*/
|
1403
|
+
|
1404
|
+
|
1405
|
+
// import merge from '../../../utils/merge'
|
1406
|
+
// import { PopupManager } from '../../../utils/popup'
|
1407
|
+
// import { isVNode } from '../../../utils/vdom'
|
1408
|
+
const NotificationConstructor = external_commonjs_vue_commonjs2_vue_root_Vue_default().extend(src);
|
1409
|
+
let instance;
|
1410
|
+
let instances = [];
|
1411
|
+
let seed = 1;
|
1412
|
+
const Notification = function (options) {
|
1413
|
+
if ((external_commonjs_vue_commonjs2_vue_root_Vue_default()).prototype.$isServer) return;
|
1414
|
+
options = Object.assign({}, options);
|
1415
|
+
const userOnClose = options.onClose;
|
1416
|
+
const id = 'notification_' + seed++;
|
1417
|
+
const position = options.position || 'top-right';
|
1418
|
+
options.onClose = function () {
|
1419
|
+
Notification.close(id, userOnClose);
|
1420
|
+
};
|
1421
|
+
instance = new NotificationConstructor({
|
1422
|
+
data: options
|
1423
|
+
});
|
1424
|
+
instance.$slots.default = [options.message];
|
1425
|
+
options.message = 'REPLACED_BY_VNODE';
|
1426
|
+
instance.id = id;
|
1427
|
+
instance.$mount();
|
1428
|
+
document.body.appendChild(instance.$el);
|
1429
|
+
instance.visible = true;
|
1430
|
+
instance.dom = instance.$el;
|
1431
|
+
// instance.dom.style.zIndex = PopupManager.nextZIndex()
|
1432
|
+
|
1433
|
+
let verticalOffset = options.offset || 0;
|
1434
|
+
instances.filter(item => item.position === position).forEach(item => {
|
1435
|
+
verticalOffset += item.$el.offsetHeight + 16;
|
1436
|
+
});
|
1437
|
+
verticalOffset += 16;
|
1438
|
+
instance.verticalOffset = verticalOffset;
|
1439
|
+
instances.push(instance);
|
1440
|
+
return instance;
|
1441
|
+
};
|
1442
|
+
['success', 'warning', 'info', 'error'].forEach(type => {
|
1443
|
+
Notification[type] = options => {
|
1444
|
+
if (typeof options === 'string') {
|
1445
|
+
options = {
|
1446
|
+
message: options
|
1447
|
+
};
|
1448
|
+
}
|
1449
|
+
options.type = type;
|
1450
|
+
return Notification(options);
|
1451
|
+
};
|
1452
|
+
});
|
1453
|
+
Notification.close = function (id, userOnClose) {
|
1454
|
+
let index = -1;
|
1455
|
+
const len = instances.length;
|
1456
|
+
const instance = instances.filter((instance, i) => {
|
1457
|
+
if (instance.id === id) {
|
1458
|
+
index = i;
|
1459
|
+
return true;
|
1460
|
+
}
|
1461
|
+
return false;
|
1462
|
+
})[0];
|
1463
|
+
if (!instance) return;
|
1464
|
+
if (typeof userOnClose === 'function') {
|
1465
|
+
userOnClose(instance);
|
1466
|
+
}
|
1467
|
+
instances.splice(index, 1);
|
1468
|
+
if (len <= 1) return;
|
1469
|
+
const position = instance.position;
|
1470
|
+
const removedHeight = instance.dom.offsetHeight;
|
1471
|
+
for (let i = index; i < len - 1; i++) {
|
1472
|
+
if (instances[i].position === position) {
|
1473
|
+
instances[i].dom.style[instance.verticalProperty] = parseInt(instances[i].dom.style[instance.verticalProperty], 10) - removedHeight - 16 + 'px';
|
1474
|
+
}
|
1475
|
+
}
|
1476
|
+
};
|
1477
|
+
Notification.closeAll = function () {
|
1478
|
+
for (let i = instances.length - 1; i >= 0; i--) {
|
1479
|
+
instances[i].close();
|
1480
|
+
}
|
1481
|
+
};
|
1482
|
+
/* harmony default export */ var NBNotify_src = (Notification);
|
1483
|
+
|
1484
|
+
/***/ }),
|
1485
|
+
|
1125
1486
|
/***/ 5168:
|
1126
1487
|
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) {
|
1127
1488
|
|
@@ -1476,6 +1837,22 @@ var update = add("7cd5ae63", content, true, {"sourceMap":false,"shadowMode":fals
|
|
1476
1837
|
|
1477
1838
|
/***/ }),
|
1478
1839
|
|
1840
|
+
/***/ 8974:
|
1841
|
+
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
1842
|
+
|
1843
|
+
// style-loader: Adds some css to the DOM by adding a <style> tag
|
1844
|
+
|
1845
|
+
// load the styles
|
1846
|
+
var content = __webpack_require__(4474);
|
1847
|
+
if(content.__esModule) content = content.default;
|
1848
|
+
if(typeof content === 'string') content = [[module.id, content, '']];
|
1849
|
+
if(content.locals) module.exports = content.locals;
|
1850
|
+
// add the styles to the DOM
|
1851
|
+
var add = (__webpack_require__(9548)/* ["default"] */ .A)
|
1852
|
+
var update = add("6359d55d", content, true, {"sourceMap":false,"shadowMode":false});
|
1853
|
+
|
1854
|
+
/***/ }),
|
1855
|
+
|
1479
1856
|
/***/ 4136:
|
1480
1857
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
1481
1858
|
|
@@ -1799,6 +2176,8 @@ var map = {
|
|
1799
2176
|
"./NBFullDialog/index.js": 2064,
|
1800
2177
|
"./NBHeader/index.js": 1678,
|
1801
2178
|
"./NBIcon/index.js": 1343,
|
2179
|
+
"./NBNotify/index.js": 135,
|
2180
|
+
"./NBNotify/src/index.js": 5113,
|
1802
2181
|
"./NBPagination/index.js": 5168,
|
1803
2182
|
"./NBSummaryBar/index.js": 5749,
|
1804
2183
|
"./NBTag/index.js": 7996
|
@@ -1906,11 +2285,11 @@ module.exports = __webpack_require__.p + "fonts/iconfont.c068c01a.woff";
|
|
1906
2285
|
|
1907
2286
|
/***/ }),
|
1908
2287
|
|
1909
|
-
/***/
|
2288
|
+
/***/ 9274:
|
1910
2289
|
/***/ (function(module) {
|
1911
2290
|
|
1912
2291
|
"use strict";
|
1913
|
-
module.exports =
|
2292
|
+
module.exports = __WEBPACK_EXTERNAL_MODULE__9274__;
|
1914
2293
|
|
1915
2294
|
/***/ }),
|
1916
2295
|
|
@@ -4421,65 +4800,8 @@ var esnext_iterator_for_each = __webpack_require__(3949);
|
|
4421
4800
|
function camelToKebab(camelCaseStr) {
|
4422
4801
|
return camelCaseStr.replace(/([a-z])([A-Z])/g, '$1-$2').toLowerCase();
|
4423
4802
|
}
|
4424
|
-
// EXTERNAL MODULE:
|
4425
|
-
var
|
4426
|
-
;// ./packages/feedback/nb-notify.js
|
4427
|
-
/*
|
4428
|
-
* @Author: chenghuan.dong
|
4429
|
-
* @Date: 2024-11-12 17:58:53
|
4430
|
-
* @LastEditTime: 2024-11-14 09:27:35
|
4431
|
-
* @LastEditors: chenghuan.dong
|
4432
|
-
* @Description: 对应样式styles/element-ui/notification.scss
|
4433
|
-
* @FilePath: \nubomed-ui\packages\feedback\nb-notify.js
|
4434
|
-
*/
|
4435
|
-
|
4436
|
-
|
4437
|
-
// console.log('1')
|
4438
|
-
|
4439
|
-
/**
|
4440
|
-
* @param {string} obj.type 图标类型, 可选值: success warning error
|
4441
|
-
* @param {string} obj.title 标题,支持换行显示,用<br>隔开
|
4442
|
-
* @param {string} obj.customClass 自定义样式
|
4443
|
-
* @param {string} obj.duration 显示时间, 毫秒。设为 0 则不会自动关闭
|
4444
|
-
*/
|
4445
|
-
|
4446
|
-
const nbNotify = obj => {
|
4447
|
-
console.log('nbNotify', obj);
|
4448
|
-
return (0,external_ELEMENT_.Notification)({
|
4449
|
-
duration: obj.duration === undefined ? 2000 : obj.duration,
|
4450
|
-
center: true,
|
4451
|
-
dangerouslyUseHTMLString: true,
|
4452
|
-
showClose: false,
|
4453
|
-
customClass: `nb-notification nb-notification--${obj.type} ${obj.customClass ? obj.customClass : ''}`,
|
4454
|
-
position: 'top-left',
|
4455
|
-
message: obj.message,
|
4456
|
-
type: obj.type,
|
4457
|
-
offset: 284,
|
4458
|
-
onClose: () => {
|
4459
|
-
if (obj.onClose) {
|
4460
|
-
obj.onClose();
|
4461
|
-
}
|
4462
|
-
}
|
4463
|
-
});
|
4464
|
-
};
|
4465
|
-
|
4466
|
-
// 可直接通过$notify[type]的形式调用
|
4467
|
-
const types = ['success', 'warning', 'error'];
|
4468
|
-
types.forEach(type => {
|
4469
|
-
nbNotify[type] = obj => {
|
4470
|
-
if (typeof obj === 'string') {
|
4471
|
-
obj = {
|
4472
|
-
message: obj
|
4473
|
-
};
|
4474
|
-
}
|
4475
|
-
if (typeof obj === 'object' && obj.title) {
|
4476
|
-
obj.message = obj.title;
|
4477
|
-
}
|
4478
|
-
obj.type = type;
|
4479
|
-
return nbNotify(obj);
|
4480
|
-
};
|
4481
|
-
});
|
4482
|
-
/* harmony default export */ var nb_notify = (nbNotify);
|
4803
|
+
// EXTERNAL MODULE: ./packages/components/NBNotify/index.js
|
4804
|
+
var NBNotify = __webpack_require__(135);
|
4483
4805
|
// EXTERNAL MODULE: ./packages/iconfont/iconfont.css
|
4484
4806
|
var iconfont = __webpack_require__(3050);
|
4485
4807
|
;// ./locale/lang/zh-CN.js
|
@@ -4612,7 +4934,7 @@ const i18n = function (fn) {
|
|
4612
4934
|
/*
|
4613
4935
|
* @Author: chenghuan.dong
|
4614
4936
|
* @Date: 2024-11-08 17:23:47
|
4615
|
-
* @LastEditTime: 2024-11-
|
4937
|
+
* @LastEditTime: 2024-11-14 09:53:15
|
4616
4938
|
* @LastEditors: chenghuan.dong
|
4617
4939
|
* @Description: 主index.js导出全部组件
|
4618
4940
|
* @FilePath: \nubomed-ui\packages\index.js
|
@@ -4648,7 +4970,7 @@ const install = function (Vue, options = {}) {
|
|
4648
4970
|
});
|
4649
4971
|
|
4650
4972
|
// 全局
|
4651
|
-
Vue.prototype.$nbNotify =
|
4973
|
+
Vue.prototype.$nbNotify = NBNotify["default"];
|
4652
4974
|
};
|
4653
4975
|
|
4654
4976
|
// if (typeof window !== 'undefined' && window.Vue) {
|
@@ -4660,8 +4982,7 @@ const packages_i18n = locale.i18n;
|
|
4660
4982
|
install,
|
4661
4983
|
...components,
|
4662
4984
|
locale: locale,
|
4663
|
-
i18n: packages_i18n
|
4664
|
-
nbNotify: nb_notify
|
4985
|
+
i18n: packages_i18n
|
4665
4986
|
});
|
4666
4987
|
;// ./node_modules/@vue/cli-service/lib/commands/build/entry-lib.js
|
4667
4988
|
|