buefy 0.9.13 → 0.9.14
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/buefy.css +1 -1
- package/dist/buefy.esm.js +167 -117
- package/dist/buefy.esm.min.js +2 -2
- package/dist/buefy.js +168 -116
- package/dist/buefy.min.css +1 -1
- package/dist/buefy.min.js +2 -2
- package/dist/cjs/autocomplete.js +5 -5
- package/dist/cjs/breadcrumb.js +1 -1
- package/dist/cjs/button.js +3 -3
- package/dist/cjs/carousel.js +4 -4
- package/dist/cjs/{chunk-c6fbc7b4.js → chunk-02406b6a.js} +2 -2
- package/dist/cjs/{chunk-d0f8ea39.js → chunk-0cc2e136.js} +6 -6
- package/dist/cjs/{chunk-114191ae.js → chunk-0d901f36.js} +2 -2
- package/dist/cjs/{chunk-9e4cf4c5.js → chunk-1061ac68.js} +1 -1
- package/dist/cjs/{chunk-2c7de785.js → chunk-1d2f05e0.js} +0 -0
- package/dist/cjs/{chunk-30670fac.js → chunk-2a2403f9.js} +78 -62
- package/dist/cjs/{chunk-d54e40f6.js → chunk-2cdb1a89.js} +2 -9
- package/dist/cjs/{chunk-34949503.js → chunk-4a3a5cf7.js} +1 -1
- package/dist/cjs/{chunk-fe2f57ee.js → chunk-4ebee779.js} +2 -2
- package/dist/cjs/{chunk-2062216d.js → chunk-5a7e385c.js} +1 -1
- package/dist/cjs/{chunk-f5106717.js → chunk-74fb31db.js} +3 -3
- package/dist/cjs/{chunk-7da0c017.js → chunk-a267720d.js} +21 -21
- package/dist/cjs/{chunk-a11294f9.js → chunk-a268cb3d.js} +2 -2
- package/dist/cjs/{chunk-c7b2aa4b.js → chunk-bb7da16a.js} +1 -1
- package/dist/cjs/{chunk-2ae50815.js → chunk-bebdaf0b.js} +3 -3
- package/dist/cjs/{chunk-9103eeda.js → chunk-c0adb618.js} +1 -1
- package/dist/cjs/{chunk-d120e215.js → chunk-d7d30e52.js} +1 -1
- package/dist/cjs/{chunk-fefd7b77.js → chunk-ddd15f05.js} +0 -0
- package/dist/cjs/{chunk-2911aa4b.js → chunk-e8dc6270.js} +14 -11
- package/dist/cjs/{chunk-3cc5d9a6.js → chunk-eb8d954b.js} +0 -0
- package/dist/cjs/{chunk-6cb902f8.js → chunk-f536c03f.js} +1 -1
- package/dist/cjs/{chunk-61023b09.js → chunk-fbf3566e.js} +2 -2
- package/dist/cjs/clockpicker.js +8 -8
- package/dist/cjs/config.js +1 -1
- package/dist/cjs/datepicker.js +9 -9
- package/dist/cjs/datetimepicker.js +11 -11
- package/dist/cjs/dialog.js +4 -4
- package/dist/cjs/dropdown.js +3 -3
- package/dist/cjs/field.js +2 -2
- package/dist/cjs/helpers.js +20 -0
- package/dist/cjs/icon.js +2 -2
- package/dist/cjs/image.js +2 -2
- package/dist/cjs/index.js +24 -22
- package/dist/cjs/input.js +4 -4
- package/dist/cjs/loading.js +2 -2
- package/dist/cjs/menu.js +2 -2
- package/dist/cjs/message.js +3 -3
- package/dist/cjs/modal.js +2 -2
- package/dist/cjs/navbar.js +3 -0
- package/dist/cjs/notification.js +4 -4
- package/dist/cjs/numberinput.js +4 -4
- package/dist/cjs/pagination.js +3 -3
- package/dist/cjs/progress.js +2 -2
- package/dist/cjs/rate.js +2 -2
- package/dist/cjs/select.js +4 -4
- package/dist/cjs/sidebar.js +1 -1
- package/dist/cjs/slider.js +2 -2
- package/dist/cjs/snackbar.js +4 -3
- package/dist/cjs/steps.js +5 -5
- package/dist/cjs/switch.js +1 -1
- package/dist/cjs/table.js +24 -22
- package/dist/cjs/tabs.js +7 -7
- package/dist/cjs/taginput.js +5 -5
- package/dist/cjs/timepicker.js +10 -10
- package/dist/cjs/toast.js +2 -2
- package/dist/cjs/tooltip.js +2 -2
- package/dist/cjs/upload.js +21 -7
- package/dist/components/autocomplete/index.js +78 -62
- package/dist/components/autocomplete/index.min.js +2 -2
- package/dist/components/breadcrumb/index.js +2 -2
- package/dist/components/breadcrumb/index.min.js +1 -1
- package/dist/components/button/index.js +2 -2
- package/dist/components/button/index.min.js +2 -2
- package/dist/components/carousel/index.js +2 -2
- package/dist/components/carousel/index.min.js +2 -2
- package/dist/components/checkbox/index.js +1 -1
- package/dist/components/checkbox/index.min.js +1 -1
- package/dist/components/clockpicker/index.js +22 -22
- package/dist/components/clockpicker/index.min.js +2 -2
- package/dist/components/collapse/index.js +1 -1
- package/dist/components/collapse/index.min.js +1 -1
- package/dist/components/datepicker/index.js +29 -26
- package/dist/components/datepicker/index.min.js +2 -2
- package/dist/components/datetimepicker/index.js +29 -26
- package/dist/components/datetimepicker/index.min.js +2 -2
- package/dist/components/dialog/index.js +2 -2
- package/dist/components/dialog/index.min.js +2 -2
- package/dist/components/dropdown/index.js +2 -2
- package/dist/components/dropdown/index.min.js +1 -1
- package/dist/components/field/index.js +22 -22
- package/dist/components/field/index.min.js +1 -1
- package/dist/components/icon/index.js +2 -2
- package/dist/components/icon/index.min.js +2 -2
- package/dist/components/image/index.js +2 -2
- package/dist/components/image/index.min.js +2 -2
- package/dist/components/input/index.js +2 -2
- package/dist/components/input/index.min.js +2 -2
- package/dist/components/loading/index.js +1 -1
- package/dist/components/loading/index.min.js +1 -1
- package/dist/components/menu/index.js +2 -2
- package/dist/components/menu/index.min.js +2 -2
- package/dist/components/message/index.js +2 -2
- package/dist/components/message/index.min.js +2 -2
- package/dist/components/modal/index.js +2 -2
- package/dist/components/modal/index.min.js +2 -2
- package/dist/components/navbar/index.js +4 -1
- package/dist/components/navbar/index.min.js +2 -2
- package/dist/components/notification/index.js +3 -10
- package/dist/components/notification/index.min.js +2 -2
- package/dist/components/numberinput/index.js +2 -2
- package/dist/components/numberinput/index.min.js +2 -2
- package/dist/components/pagination/index.js +2 -2
- package/dist/components/pagination/index.min.js +2 -2
- package/dist/components/progress/index.js +2 -2
- package/dist/components/progress/index.min.js +2 -2
- package/dist/components/radio/index.js +1 -1
- package/dist/components/radio/index.min.js +1 -1
- package/dist/components/rate/index.js +2 -2
- package/dist/components/rate/index.min.js +2 -2
- package/dist/components/select/index.js +2 -2
- package/dist/components/select/index.min.js +2 -2
- package/dist/components/sidebar/index.js +2 -2
- package/dist/components/sidebar/index.min.js +1 -1
- package/dist/components/skeleton/index.js +1 -1
- package/dist/components/skeleton/index.min.js +1 -1
- package/dist/components/slider/index.js +2 -2
- package/dist/components/slider/index.min.js +2 -2
- package/dist/components/snackbar/index.js +5 -11
- package/dist/components/snackbar/index.min.js +2 -2
- package/dist/components/steps/index.js +2 -2
- package/dist/components/steps/index.min.js +2 -2
- package/dist/components/switch/index.js +2 -2
- package/dist/components/switch/index.min.js +1 -1
- package/dist/components/table/index.js +36 -16
- package/dist/components/table/index.min.js +2 -2
- package/dist/components/tabs/index.js +4 -4
- package/dist/components/tabs/index.min.js +2 -2
- package/dist/components/tag/index.js +1 -1
- package/dist/components/tag/index.min.js +1 -1
- package/dist/components/taginput/index.js +78 -62
- package/dist/components/taginput/index.min.js +2 -2
- package/dist/components/timepicker/index.js +22 -22
- package/dist/components/timepicker/index.min.js +2 -2
- package/dist/components/toast/index.js +3 -10
- package/dist/components/toast/index.min.js +2 -2
- package/dist/components/tooltip/index.js +2 -2
- package/dist/components/tooltip/index.min.js +1 -1
- package/dist/components/upload/index.js +21 -7
- package/dist/components/upload/index.min.js +2 -2
- package/dist/esm/autocomplete.js +6 -6
- package/dist/esm/breadcrumb.js +1 -1
- package/dist/esm/button.js +4 -4
- package/dist/esm/carousel.js +4 -4
- package/dist/esm/{chunk-21fc0948.js → chunk-03f0ac1a.js} +6 -6
- package/dist/esm/{chunk-b0c0c6b0.js → chunk-0c4e4e90.js} +0 -0
- package/dist/esm/{chunk-ae8ab23a.js → chunk-113685dc.js} +3 -3
- package/dist/esm/{chunk-71a547bc.js → chunk-1b63211c.js} +1 -1
- package/dist/esm/{chunk-d7f92d97.js → chunk-1f41edb4.js} +1 -1
- package/dist/esm/{chunk-3773c62d.js → chunk-2229e354.js} +1 -1
- package/dist/esm/{chunk-83eb0d37.js → chunk-40f06d9c.js} +2 -2
- package/dist/esm/{chunk-75a5af93.js → chunk-590a6902.js} +1 -1
- package/dist/esm/{chunk-22e9f916.js → chunk-5f0c3fc4.js} +14 -11
- package/dist/esm/{chunk-6019fd7a.js → chunk-79ac4d01.js} +79 -63
- package/dist/esm/{chunk-8ed29c41.js → chunk-8cad1844.js} +1 -1
- package/dist/esm/{chunk-29ca0df8.js → chunk-91404fa9.js} +0 -0
- package/dist/esm/{chunk-b07e3182.js → chunk-97f201e0.js} +21 -21
- package/dist/esm/{chunk-c9c58d0c.js → chunk-9e0ae963.js} +0 -0
- package/dist/esm/{chunk-ece062a7.js → chunk-a8516afd.js} +2 -2
- package/dist/esm/{chunk-4b67a181.js → chunk-b66a83ce.js} +2 -2
- package/dist/esm/{chunk-9f7f7441.js → chunk-b99e83bd.js} +1 -1
- package/dist/esm/{chunk-18e8b067.js → chunk-bbf5d78a.js} +2 -2
- package/dist/esm/{chunk-8d0f95b8.js → chunk-e01e9ef0.js} +3 -3
- package/dist/esm/{chunk-799e084d.js → chunk-e7eb83d8.js} +2 -9
- package/dist/esm/{chunk-d92f0cd9.js → chunk-ea9bc877.js} +1 -1
- package/dist/esm/{chunk-e7c9b2cb.js → chunk-efec59b6.js} +2 -2
- package/dist/esm/clockpicker.js +8 -8
- package/dist/esm/config.js +1 -1
- package/dist/esm/datepicker.js +10 -10
- package/dist/esm/datetimepicker.js +11 -11
- package/dist/esm/dialog.js +4 -4
- package/dist/esm/dropdown.js +4 -4
- package/dist/esm/field.js +3 -3
- package/dist/esm/helpers.js +19 -1
- package/dist/esm/icon.js +3 -3
- package/dist/esm/image.js +3 -3
- package/dist/esm/index.js +23 -23
- package/dist/esm/input.js +5 -5
- package/dist/esm/loading.js +3 -3
- package/dist/esm/menu.js +2 -2
- package/dist/esm/message.js +3 -3
- package/dist/esm/modal.js +3 -3
- package/dist/esm/navbar.js +3 -0
- package/dist/esm/notification.js +4 -4
- package/dist/esm/numberinput.js +4 -4
- package/dist/esm/pagination.js +4 -4
- package/dist/esm/progress.js +2 -2
- package/dist/esm/rate.js +2 -2
- package/dist/esm/select.js +5 -5
- package/dist/esm/sidebar.js +1 -1
- package/dist/esm/slider.js +2 -2
- package/dist/esm/snackbar.js +4 -3
- package/dist/esm/steps.js +5 -5
- package/dist/esm/switch.js +1 -1
- package/dist/esm/table.js +25 -23
- package/dist/esm/tabs.js +7 -7
- package/dist/esm/taginput.js +5 -5
- package/dist/esm/timepicker.js +11 -11
- package/dist/esm/toast.js +2 -2
- package/dist/esm/tooltip.js +3 -3
- package/dist/esm/upload.js +21 -7
- package/dist/vetur/attributes.json +4 -0
- package/dist/vetur/tags.json +1 -0
- package/package.json +1 -1
- package/src/components/autocomplete/Autocomplete.vue +711 -701
- package/src/components/breadcrumb/__snapshots__/BreadcrumbItem.spec.js.snap +1 -5
- package/src/components/carousel/__snapshots__/CarouselList.spec.js.snap +48 -48
- package/src/components/datepicker/DatepickerTableRow.spec.js +26 -0
- package/src/components/datepicker/DatepickerTableRow.vue +4 -5
- package/src/components/field/Field.vue +271 -271
- package/src/components/navbar/NavbarDropdown.vue +4 -0
- package/src/components/snackbar/index.js +2 -1
- package/src/components/table/Table.spec.js +17 -3
- package/src/components/table/Table.vue +8 -9
- package/src/components/tabs/Tabs.vue +185 -183
- package/src/components/timepicker/__snapshots__/Timepicker.spec.js.snap +18 -47
- package/src/components/upload/Upload.vue +19 -7
- package/src/utils/NoticeMixin.js +1 -5
- package/src/utils/config.js +1 -1
- package/src/utils/helpers.js +16 -0
- package/types/components.d.ts +5 -0
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! Buefy v0.9.
|
|
1
|
+
/*! Buefy v0.9.14 | MIT License | github.com/buefy/buefy */
|
|
2
2
|
(function (global, factory) {
|
|
3
3
|
typeof exports === 'object' && typeof module !== 'undefined' ? factory(exports) :
|
|
4
4
|
typeof define === 'function' && define.amd ? define(['exports'], factory) :
|
|
@@ -465,7 +465,7 @@
|
|
|
465
465
|
defaultModalScroll: null,
|
|
466
466
|
defaultDatepickerMobileNative: true,
|
|
467
467
|
defaultTimepickerMobileNative: true,
|
|
468
|
-
defaultNoticeQueue:
|
|
468
|
+
defaultNoticeQueue: false,
|
|
469
469
|
defaultInputHasCounter: true,
|
|
470
470
|
defaultTaginputHasCounter: true,
|
|
471
471
|
defaultUseHtml5Validation: true,
|
|
@@ -1204,9 +1204,9 @@
|
|
|
1204
1204
|
});
|
|
1205
1205
|
},
|
|
1206
1206
|
|
|
1207
|
-
/**
|
|
1208
|
-
* White-listed items to not close when clicked.
|
|
1209
|
-
* Add input, dropdown and all children.
|
|
1207
|
+
/**
|
|
1208
|
+
* White-listed items to not close when clicked.
|
|
1209
|
+
* Add input, dropdown and all children.
|
|
1210
1210
|
*/
|
|
1211
1211
|
whiteList: function whiteList() {
|
|
1212
1212
|
var whiteList = [];
|
|
@@ -1273,43 +1273,43 @@
|
|
|
1273
1273
|
return whiteList;
|
|
1274
1274
|
},
|
|
1275
1275
|
|
|
1276
|
-
/**
|
|
1277
|
-
* Check if exists default slot
|
|
1276
|
+
/**
|
|
1277
|
+
* Check if exists default slot
|
|
1278
1278
|
*/
|
|
1279
1279
|
hasDefaultSlot: function hasDefaultSlot() {
|
|
1280
1280
|
return !!this.$scopedSlots.default;
|
|
1281
1281
|
},
|
|
1282
1282
|
|
|
1283
|
-
/**
|
|
1284
|
-
* Check if exists group slot
|
|
1283
|
+
/**
|
|
1284
|
+
* Check if exists group slot
|
|
1285
1285
|
*/
|
|
1286
1286
|
hasGroupSlot: function hasGroupSlot() {
|
|
1287
1287
|
return !!this.$scopedSlots.group;
|
|
1288
1288
|
},
|
|
1289
1289
|
|
|
1290
|
-
/**
|
|
1291
|
-
* Check if exists "empty" slot
|
|
1290
|
+
/**
|
|
1291
|
+
* Check if exists "empty" slot
|
|
1292
1292
|
*/
|
|
1293
1293
|
hasEmptySlot: function hasEmptySlot() {
|
|
1294
1294
|
return !!this.$slots.empty;
|
|
1295
1295
|
},
|
|
1296
1296
|
|
|
1297
|
-
/**
|
|
1298
|
-
* Check if exists "header" slot
|
|
1297
|
+
/**
|
|
1298
|
+
* Check if exists "header" slot
|
|
1299
1299
|
*/
|
|
1300
1300
|
hasHeaderSlot: function hasHeaderSlot() {
|
|
1301
1301
|
return !!this.$slots.header;
|
|
1302
1302
|
},
|
|
1303
1303
|
|
|
1304
|
-
/**
|
|
1305
|
-
* Check if exists "footer" slot
|
|
1304
|
+
/**
|
|
1305
|
+
* Check if exists "footer" slot
|
|
1306
1306
|
*/
|
|
1307
1307
|
hasFooterSlot: function hasFooterSlot() {
|
|
1308
1308
|
return !!this.$slots.footer;
|
|
1309
1309
|
},
|
|
1310
1310
|
|
|
1311
|
-
/**
|
|
1312
|
-
* Apply dropdownPosition property
|
|
1311
|
+
/**
|
|
1312
|
+
* Apply dropdownPosition property
|
|
1313
1313
|
*/
|
|
1314
1314
|
isOpenedTop: function isOpenedTop() {
|
|
1315
1315
|
return this.dropdownPosition === 'top' || this.dropdownPosition === 'auto' && !this.isListInViewportVertically;
|
|
@@ -1335,9 +1335,9 @@
|
|
|
1335
1335
|
}
|
|
1336
1336
|
},
|
|
1337
1337
|
watch: {
|
|
1338
|
-
/**
|
|
1339
|
-
* When dropdown is toggled, check the visibility to know when
|
|
1340
|
-
* to open upwards.
|
|
1338
|
+
/**
|
|
1339
|
+
* When dropdown is toggled, check the visibility to know when
|
|
1340
|
+
* to open upwards.
|
|
1341
1341
|
*/
|
|
1342
1342
|
isActive: function isActive(active) {
|
|
1343
1343
|
var _this2 = this;
|
|
@@ -1354,11 +1354,11 @@
|
|
|
1354
1354
|
}
|
|
1355
1355
|
},
|
|
1356
1356
|
|
|
1357
|
-
/**
|
|
1358
|
-
* When updating input's value
|
|
1359
|
-
* 1. Emit changes
|
|
1360
|
-
* 2. If value isn't the same as selected, set null
|
|
1361
|
-
* 3. Close dropdown if value is clear or else open it
|
|
1357
|
+
/**
|
|
1358
|
+
* When updating input's value
|
|
1359
|
+
* 1. Emit changes
|
|
1360
|
+
* 2. If value isn't the same as selected, set null
|
|
1361
|
+
* 3. Close dropdown if value is clear or else open it
|
|
1362
1362
|
*/
|
|
1363
1363
|
newValue: function newValue(value) {
|
|
1364
1364
|
this.$emit('input', value); // Check if selected is invalid
|
|
@@ -1375,17 +1375,17 @@
|
|
|
1375
1375
|
}
|
|
1376
1376
|
},
|
|
1377
1377
|
|
|
1378
|
-
/**
|
|
1379
|
-
* When v-model is changed:
|
|
1380
|
-
* 1. Update internal value.
|
|
1381
|
-
* 2. If it's invalid, validate again.
|
|
1378
|
+
/**
|
|
1379
|
+
* When v-model is changed:
|
|
1380
|
+
* 1. Update internal value.
|
|
1381
|
+
* 2. If it's invalid, validate again.
|
|
1382
1382
|
*/
|
|
1383
1383
|
value: function value(_value) {
|
|
1384
1384
|
this.newValue = _value;
|
|
1385
1385
|
},
|
|
1386
1386
|
|
|
1387
|
-
/**
|
|
1388
|
-
* Select first option if "keep-first
|
|
1387
|
+
/**
|
|
1388
|
+
* Select first option if "keep-first
|
|
1389
1389
|
*/
|
|
1390
1390
|
data: function data() {
|
|
1391
1391
|
var _this3 = this;
|
|
@@ -1399,21 +1399,37 @@
|
|
|
1399
1399
|
_this3.setHovered(null);
|
|
1400
1400
|
}
|
|
1401
1401
|
});
|
|
1402
|
+
} else {
|
|
1403
|
+
if (this.hovered) {
|
|
1404
|
+
// reset hovered if list doesn't contain it
|
|
1405
|
+
var hoveredValue = this.getValue(this.hovered);
|
|
1406
|
+
var data = this.computedData.map(function (d) {
|
|
1407
|
+
return d.items;
|
|
1408
|
+
}).reduce(function (a, b) {
|
|
1409
|
+
return [].concat(_toConsumableArray(a), _toConsumableArray(b));
|
|
1410
|
+
}, []);
|
|
1411
|
+
|
|
1412
|
+
if (!data.some(function (d) {
|
|
1413
|
+
return _this3.getValue(d) === hoveredValue;
|
|
1414
|
+
})) {
|
|
1415
|
+
this.setHovered(null);
|
|
1416
|
+
}
|
|
1417
|
+
}
|
|
1402
1418
|
}
|
|
1403
1419
|
}
|
|
1404
1420
|
},
|
|
1405
1421
|
methods: {
|
|
1406
|
-
/**
|
|
1407
|
-
* Set which option is currently hovered.
|
|
1422
|
+
/**
|
|
1423
|
+
* Set which option is currently hovered.
|
|
1408
1424
|
*/
|
|
1409
1425
|
setHovered: function setHovered(option) {
|
|
1410
1426
|
if (option === undefined) return;
|
|
1411
1427
|
this.hovered = option;
|
|
1412
1428
|
},
|
|
1413
1429
|
|
|
1414
|
-
/**
|
|
1415
|
-
* Set which option is currently selected, update v-model,
|
|
1416
|
-
* update input value and close dropdown.
|
|
1430
|
+
/**
|
|
1431
|
+
* Set which option is currently selected, update v-model,
|
|
1432
|
+
* update input value and close dropdown.
|
|
1417
1433
|
*/
|
|
1418
1434
|
setSelected: function setSelected(option) {
|
|
1419
1435
|
var _this4 = this;
|
|
@@ -1442,8 +1458,8 @@
|
|
|
1442
1458
|
this.checkValidity();
|
|
1443
1459
|
},
|
|
1444
1460
|
|
|
1445
|
-
/**
|
|
1446
|
-
* Select first option
|
|
1461
|
+
/**
|
|
1462
|
+
* Select first option
|
|
1447
1463
|
*/
|
|
1448
1464
|
selectFirstOption: function selectFirstOption(computedData) {
|
|
1449
1465
|
var _this5 = this;
|
|
@@ -1494,8 +1510,8 @@
|
|
|
1494
1510
|
});
|
|
1495
1511
|
},
|
|
1496
1512
|
|
|
1497
|
-
/**
|
|
1498
|
-
* Check if header or footer was selected.
|
|
1513
|
+
/**
|
|
1514
|
+
* Check if header or footer was selected.
|
|
1499
1515
|
*/
|
|
1500
1516
|
checkIfHeaderOrFooterSelected: function checkIfHeaderOrFooterSelected(event, triggerClick) {
|
|
1501
1517
|
var closeDropdown = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : true;
|
|
@@ -1515,8 +1531,8 @@
|
|
|
1515
1531
|
}
|
|
1516
1532
|
},
|
|
1517
1533
|
|
|
1518
|
-
/**
|
|
1519
|
-
* Close dropdown if clicked outside.
|
|
1534
|
+
/**
|
|
1535
|
+
* Close dropdown if clicked outside.
|
|
1520
1536
|
*/
|
|
1521
1537
|
clickedOutside: function clickedOutside(event) {
|
|
1522
1538
|
var target = isCustomElement(this) ? event.composedPath()[0] : event.target;
|
|
@@ -1530,9 +1546,9 @@
|
|
|
1530
1546
|
}
|
|
1531
1547
|
},
|
|
1532
1548
|
|
|
1533
|
-
/**
|
|
1534
|
-
* Return display text for the input.
|
|
1535
|
-
* If object, get value from path, or else just the value.
|
|
1549
|
+
/**
|
|
1550
|
+
* Return display text for the input.
|
|
1551
|
+
* If object, get value from path, or else just the value.
|
|
1536
1552
|
*/
|
|
1537
1553
|
getValue: function getValue(option) {
|
|
1538
1554
|
if (option === null) return;
|
|
@@ -1544,9 +1560,9 @@
|
|
|
1544
1560
|
return _typeof(option) === 'object' ? getValueByPath(option, this.field) : option;
|
|
1545
1561
|
},
|
|
1546
1562
|
|
|
1547
|
-
/**
|
|
1548
|
-
* Check if the scroll list inside the dropdown
|
|
1549
|
-
* reached it's end.
|
|
1563
|
+
/**
|
|
1564
|
+
* Check if the scroll list inside the dropdown
|
|
1565
|
+
* reached it's end.
|
|
1550
1566
|
*/
|
|
1551
1567
|
checkIfReachedTheEndOfScroll: function checkIfReachedTheEndOfScroll(list) {
|
|
1552
1568
|
if (list.clientHeight !== list.scrollHeight && list.scrollTop + list.clientHeight >= list.scrollHeight) {
|
|
@@ -1554,17 +1570,17 @@
|
|
|
1554
1570
|
}
|
|
1555
1571
|
},
|
|
1556
1572
|
|
|
1557
|
-
/**
|
|
1558
|
-
* Calculate if the dropdown is vertically visible when activated,
|
|
1559
|
-
* otherwise it is openened upwards.
|
|
1573
|
+
/**
|
|
1574
|
+
* Calculate if the dropdown is vertically visible when activated,
|
|
1575
|
+
* otherwise it is openened upwards.
|
|
1560
1576
|
*/
|
|
1561
1577
|
calcDropdownInViewportVertical: function calcDropdownInViewportVertical() {
|
|
1562
1578
|
var _this6 = this;
|
|
1563
1579
|
|
|
1564
1580
|
this.$nextTick(function () {
|
|
1565
|
-
/**
|
|
1566
|
-
* this.$refs.dropdown may be undefined
|
|
1567
|
-
* when Autocomplete is conditional rendered
|
|
1581
|
+
/**
|
|
1582
|
+
* this.$refs.dropdown may be undefined
|
|
1583
|
+
* when Autocomplete is conditional rendered
|
|
1568
1584
|
*/
|
|
1569
1585
|
if (_this6.$refs.dropdown === undefined) return;
|
|
1570
1586
|
|
|
@@ -1578,9 +1594,9 @@
|
|
|
1578
1594
|
});
|
|
1579
1595
|
},
|
|
1580
1596
|
|
|
1581
|
-
/**
|
|
1582
|
-
* Arrows keys listener.
|
|
1583
|
-
* If dropdown is active, set hovered option, or else just open.
|
|
1597
|
+
/**
|
|
1598
|
+
* Arrows keys listener.
|
|
1599
|
+
* If dropdown is active, set hovered option, or else just open.
|
|
1584
1600
|
*/
|
|
1585
1601
|
keyArrows: function keyArrows(direction) {
|
|
1586
1602
|
var sum = direction === 'down' ? 1 : -1;
|
|
@@ -1650,9 +1666,9 @@
|
|
|
1650
1666
|
}
|
|
1651
1667
|
},
|
|
1652
1668
|
|
|
1653
|
-
/**
|
|
1654
|
-
* Focus listener.
|
|
1655
|
-
* If value is the same as selected, select all text.
|
|
1669
|
+
/**
|
|
1670
|
+
* Focus listener.
|
|
1671
|
+
* If value is the same as selected, select all text.
|
|
1656
1672
|
*/
|
|
1657
1673
|
focused: function focused(event) {
|
|
1658
1674
|
if (this.getValue(this.selected) === this.newValue) {
|
|
@@ -1672,8 +1688,8 @@
|
|
|
1672
1688
|
this.$emit('focus', event);
|
|
1673
1689
|
},
|
|
1674
1690
|
|
|
1675
|
-
/**
|
|
1676
|
-
* Blur listener.
|
|
1691
|
+
/**
|
|
1692
|
+
* Blur listener.
|
|
1677
1693
|
*/
|
|
1678
1694
|
onBlur: function onBlur(event) {
|
|
1679
1695
|
this.hasFocus = false;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
/*! Buefy v0.9.
|
|
2
|
-
!function(e,t){"object"==typeof exports&&"undefined"!=typeof module?t(exports):"function"==typeof define&&define.amd?define(["exports"],t):t((e=e||self).Taginput={})}(this,function(e){"use strict";function t(e){return(t="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function i(e,t,i){return t in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}function n(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),i.push.apply(i,n)}return i}function o(e){for(var t=1;t<arguments.length;t++){var o=null!=arguments[t]?arguments[t]:{};t%2?n(Object(o),!0).forEach(function(t){i(e,t,o[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(o)):n(Object(o)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(o,t))})}return e}function s(e,t){if(null==e)return{};var i,n,o=function(e,t){if(null==e)return{};var i,n,o={},s=Object.keys(e);for(n=0;n<s.length;n++)i=s[n],t.indexOf(i)>=0||(o[i]=e[i]);return o}(e,t);if(Object.getOwnPropertySymbols){var s=Object.getOwnPropertySymbols(e);for(n=0;n<s.length;n++)i=s[n],t.indexOf(i)>=0||Object.prototype.propertyIsEnumerable.call(e,i)&&(o[i]=e[i])}return o}function a(e){return function(e){if(Array.isArray(e))return e}(e)||l(e)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance")}()}function r(e){return function(e){if(Array.isArray(e)){for(var t=0,i=new Array(e.length);t<e.length;t++)i[t]=e[t];return i}}(e)||l(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance")}()}function l(e){if(Symbol.iterator in Object(e)||"[object Arguments]"===Object.prototype.toString.call(e))return Array.from(e)}function c(e,t){return t.split(".").reduce(function(e,t){return e?e[t]:null},e)}var u=function(e){return"object"===t(e)&&!Array.isArray(e)},d=function e(t,n){var s=arguments.length>2&&void 0!==arguments[2]&&arguments[2];if(s||!Object.assign){var a=Object.getOwnPropertyNames(n).map(function(o){return i({},o,function(e){return u(n[e])&&null!==t&&t.hasOwnProperty(e)&&u(t[e])}(o)?e(t[o],n[o],s):n[o])}).reduce(function(e,t){return o({},e,{},t)},{});return o({},t,{},a)}return Object.assign(t,n)};var h=function(e,t,i,n,o,s,a,r,l,c){"boolean"!=typeof a&&(l=r,r=a,a=!1);var u,d="function"==typeof i?i.options:i;if(e&&e.render&&(d.render=e.render,d.staticRenderFns=e.staticRenderFns,d._compiled=!0,o&&(d.functional=!0)),n&&(d._scopeId=n),s?(u=function(e){(e=e||this.$vnode&&this.$vnode.ssrContext||this.parent&&this.parent.$vnode&&this.parent.$vnode.ssrContext)||"undefined"==typeof __VUE_SSR_CONTEXT__||(e=__VUE_SSR_CONTEXT__),t&&t.call(this,l(e)),e&&e._registeredComponents&&e._registeredComponents.add(s)},d._ssrRegister=u):t&&(u=a?function(){t.call(this,c(this.$root.$options.shadowRoot))}:function(e){t.call(this,r(e))}),u)if(d.functional){var h=d.render;d.render=function(e,t){return u.call(t),h(e,t)}}else{var p=d.beforeCreate;d.beforeCreate=p?[].concat(p,u):[u]}return i};var p=h({render:function(){var e=this,t=e.$createElement,i=e._self._c||t;return e.attached&&e.closable?i("div",{staticClass:"tags has-addons"},[i("span",{staticClass:"tag",class:[e.type,e.size,{"is-rounded":e.rounded}]},[e.icon?i("b-icon",{attrs:{icon:e.icon,size:e.size,type:e.iconType,pack:e.iconPack}}):e._e(),i("span",{class:{"has-ellipsis":e.ellipsis},on:{click:e.click}},[e._t("default")],2)],1),i("a",{staticClass:"tag",class:[e.size,e.closeType,{"is-rounded":e.rounded},e.closeIcon?"has-delete-icon":"is-delete"],attrs:{role:"button","aria-label":e.ariaCloseLabel,tabindex:!!e.tabstop&&0,disabled:e.disabled},on:{click:e.close,keyup:function(t){return!t.type.indexOf("key")&&e._k(t.keyCode,"delete",[8,46],t.key,["Backspace","Delete","Del"])?null:(t.preventDefault(),e.close(t))}}},[e.closeIcon?i("b-icon",{attrs:{"custom-class":"",icon:e.closeIcon,size:e.size,type:e.closeIconType,pack:e.closeIconPack}}):e._e()],1)]):i("span",{staticClass:"tag",class:[e.type,e.size,{"is-rounded":e.rounded}]},[e.icon?i("b-icon",{attrs:{icon:e.icon,size:e.size,type:e.iconType,pack:e.iconPack}}):e._e(),i("span",{class:{"has-ellipsis":e.ellipsis},on:{click:e.click}},[e._t("default")],2),e.closable?i("a",{staticClass:"delete is-small",class:e.closeType,attrs:{role:"button","aria-label":e.ariaCloseLabel,disabled:e.disabled,tabindex:!!e.tabstop&&0},on:{click:e.close,keyup:function(t){return!t.type.indexOf("key")&&e._k(t.keyCode,"delete",[8,46],t.key,["Backspace","Delete","Del"])?null:(t.preventDefault(),e.close(t))}}}):e._e()],1)},staticRenderFns:[]},void 0,{name:"BTag",props:{attached:Boolean,closable:Boolean,type:String,size:String,rounded:Boolean,disabled:Boolean,ellipsis:Boolean,tabstop:{type:Boolean,default:!0},ariaCloseLabel:String,icon:String,iconType:String,iconPack:String,closeType:String,closeIcon:String,closeIconPack:String,closeIconType:String},methods:{close:function(e){this.disabled||this.$emit("close",e)},click:function(e){this.disabled||this.$emit("click",e)}}},void 0,!1,void 0,void 0,void 0),f={defaultContainerElement:null,defaultIconPack:"mdi",defaultIconComponent:null,defaultIconPrev:"chevron-left",defaultIconNext:"chevron-right",defaultLocale:void 0,defaultDialogConfirmText:null,defaultDialogCancelText:null,defaultSnackbarDuration:3500,defaultSnackbarPosition:null,defaultToastDuration:2e3,defaultToastPosition:null,defaultNotificationDuration:2e3,defaultNotificationPosition:null,defaultTooltipType:"is-primary",defaultTooltipDelay:null,defaultSidebarDelay:null,defaultInputAutocomplete:"on",defaultDateFormatter:null,defaultDateParser:null,defaultDateCreator:null,defaultTimeCreator:null,defaultDayNames:null,defaultMonthNames:null,defaultFirstDayOfWeek:null,defaultUnselectableDaysOfWeek:null,defaultTimeFormatter:null,defaultTimeParser:null,defaultModalCanCancel:["escape","x","outside","button"],defaultModalScroll:null,defaultDatepickerMobileNative:!0,defaultTimepickerMobileNative:!0,defaultNoticeQueue:!0,defaultInputHasCounter:!0,defaultTaginputHasCounter:!0,defaultUseHtml5Validation:!0,defaultDropdownMobileModal:!0,defaultFieldLabelPosition:null,defaultDatepickerYearsRange:[-100,10],defaultDatepickerNearbyMonthDays:!0,defaultDatepickerNearbySelectableMonthDays:!1,defaultDatepickerShowWeekNumber:!1,defaultDatepickerWeekNumberClickable:!1,defaultDatepickerMobileModal:!0,defaultTrapFocus:!0,defaultAutoFocus:!0,defaultButtonRounded:!1,defaultSwitchRounded:!0,defaultCarouselInterval:3500,defaultTabsExpanded:!1,defaultTabsAnimated:!0,defaultTabsType:null,defaultStatusIcon:!0,defaultProgrammaticPromise:!1,defaultLinkTags:["a","button","input","router-link","nuxt-link","n-link","RouterLink","NuxtLink","NLink"],defaultImageWebpFallback:null,defaultImageLazy:!0,defaultImageResponsive:!0,defaultImageRatio:null,defaultImageSrcsetFormatter:null,defaultBreadcrumbTag:"a",defaultBreadcrumbAlign:"is-left",defaultBreadcrumbSeparator:"",defaultBreadcrumbSize:"is-medium",customIconPacks:null},m={props:{size:String,expanded:Boolean,loading:Boolean,rounded:Boolean,icon:String,iconPack:String,autocomplete:String,maxlength:[Number,String],useHtml5Validation:{type:Boolean,default:function(){return f.defaultUseHtml5Validation}},validationMessage:String,locale:{type:[String,Array],default:function(){return f.defaultLocale}},statusIcon:{type:Boolean,default:function(){return f.defaultStatusIcon}}},data:function(){return{isValid:!0,isFocused:!1,newIconPack:this.iconPack||f.defaultIconPack}},computed:{parentField:function(){for(var e=this.$parent,t=0;t<3;t++)e&&!e.$data._isField&&(e=e.$parent);return e},statusType:function(){var e=(this.parentField||{}).newType;if(e){if("string"==typeof e)return e;for(var t in e)if(e[t])return t}},statusMessage:function(){if(this.parentField)return this.parentField.newMessage||this.parentField.$slots.message},iconSize:function(){switch(this.size){case"is-small":return this.size;case"is-medium":return;case"is-large":return"mdi"===this.newIconPack?"is-medium":""}}},methods:{focus:function(){var e=this.getElement();void 0!==e&&this.$nextTick(function(){e&&e.focus()})},onBlur:function(e){this.isFocused=!1,this.$emit("blur",e),this.checkHtml5Validity()},onFocus:function(e){this.isFocused=!0,this.$emit("focus",e),this.checkHtml5Validity()},getElement:function(){for(var e,t=this.$refs[this.$data._elementRef];(e=t)&&e._isVue;)t=t.$refs[t.$data._elementRef];return t},setInvalid:function(){var e=this.validationMessage||this.getElement().validationMessage;this.setValidity("is-danger",e)},setValidity:function(e,t){var i=this;this.$nextTick(function(){i.parentField&&(i.parentField.type||(i.parentField.newType=e),i.parentField.message||(i.parentField.newMessage=t))})},checkHtml5Validity:function(){if(this.useHtml5Validation){var e=this.getElement();if(void 0!==e)return e.checkValidity()?(this.setValidity(null,null),this.isValid=!0):(this.setInvalid(),this.isValid=!1),this.isValid}}}},g={sizes:{default:"mdi-24px","is-small":null,"is-medium":"mdi-36px","is-large":"mdi-48px"},iconPrefix:"mdi-"},y=function(){var e=f&&f.defaultIconComponent?"":"fa-";return{sizes:{default:null,"is-small":null,"is-medium":e+"lg","is-large":e+"2x"},iconPrefix:e,internalIcons:{information:"info-circle",alert:"exclamation-triangle","alert-circle":"exclamation-circle","chevron-right":"angle-right","chevron-left":"angle-left","chevron-down":"angle-down","eye-off":"eye-slash","menu-down":"caret-down","menu-up":"caret-up","close-circle":"times-circle"}}};var v=h({render:function(){var e=this,t=e.$createElement,i=e._self._c||t;return i("span",{staticClass:"icon",class:[e.newType,e.size]},[e.useIconComponent?i(e.useIconComponent,{tag:"component",class:[e.customClass],attrs:{icon:[e.newPack,e.newIcon],size:e.newCustomSize}}):i("i",{class:[e.newPack,e.newIcon,e.newCustomSize,e.customClass]})],1)},staticRenderFns:[]},void 0,{name:"BIcon",props:{type:[String,Object],component:String,pack:String,icon:String,size:String,customSize:String,customClass:String,both:Boolean},computed:{iconConfig:function(){var e;return(e={mdi:g,fa:y(),fas:y(),far:y(),fad:y(),fab:y(),fal:y()},f&&f.customIconPacks&&(e=d(e,f.customIconPacks,!0)),e)[this.newPack]},iconPrefix:function(){return this.iconConfig&&this.iconConfig.iconPrefix?this.iconConfig.iconPrefix:""},newIcon:function(){return"".concat(this.iconPrefix).concat(this.getEquivalentIconOf(this.icon))},newPack:function(){return this.pack||f.defaultIconPack},newType:function(){if(this.type){var e=[];if("string"==typeof this.type)e=this.type.split("-");else for(var t in this.type)if(this.type[t]){e=t.split("-");break}if(!(e.length<=1)){var i=a(e).slice(1);return"has-text-".concat(i.join("-"))}}},newCustomSize:function(){return this.customSize||this.customSizeByPack},customSizeByPack:function(){if(this.iconConfig&&this.iconConfig.sizes){if(this.size&&void 0!==this.iconConfig.sizes[this.size])return this.iconConfig.sizes[this.size];if(this.iconConfig.sizes.default)return this.iconConfig.sizes.default}return null},useIconComponent:function(){return this.component||f.defaultIconComponent}},methods:{getEquivalentIconOf:function(e){return this.both&&this.iconConfig&&this.iconConfig.internalIcons&&this.iconConfig.internalIcons[e]?this.iconConfig.internalIcons[e]:e}}},void 0,!1,void 0,void 0,void 0);var b=h({render:function(){var e=this,t=e.$createElement,i=e._self._c||t;return i("div",{staticClass:"control",class:e.rootClasses},["textarea"!==e.type?i("input",e._b({ref:"input",staticClass:"input",class:[e.inputClasses,e.customClass],attrs:{type:e.newType,autocomplete:e.newAutocomplete,maxlength:e.maxlength},domProps:{value:e.computedValue},on:{input:e.onInput,change:e.onChange,blur:e.onBlur,focus:e.onFocus}},"input",e.$attrs,!1)):i("textarea",e._b({ref:"textarea",staticClass:"textarea",class:[e.inputClasses,e.customClass],attrs:{maxlength:e.maxlength},domProps:{value:e.computedValue},on:{input:e.onInput,change:e.onChange,blur:e.onBlur,focus:e.onFocus}},"textarea",e.$attrs,!1)),e.icon?i("b-icon",{staticClass:"is-left",class:{"is-clickable":e.iconClickable},attrs:{icon:e.icon,pack:e.iconPack,size:e.iconSize},nativeOn:{click:function(t){return e.iconClick("icon-click",t)}}}):e._e(),!e.loading&&e.hasIconRight?i("b-icon",{staticClass:"is-right",class:{"is-clickable":e.passwordReveal||e.iconRightClickable},attrs:{icon:e.rightIcon,pack:e.iconPack,size:e.iconSize,type:e.rightIconType,both:""},nativeOn:{click:function(t){return e.rightIconClick(t)}}}):e._e(),e.maxlength&&e.hasCounter&&"number"!==e.type?i("small",{staticClass:"help counter",class:{"is-invisible":!e.isFocused}},[e._v(" "+e._s(e.valueLength)+" / "+e._s(e.maxlength)+" ")]):e._e()],1)},staticRenderFns:[]},void 0,{name:"BInput",components:i({},v.name,v),mixins:[m],inheritAttrs:!1,props:{value:[Number,String],type:{type:String,default:"text"},lazy:{type:Boolean,default:!1},passwordReveal:Boolean,iconClickable:Boolean,hasCounter:{type:Boolean,default:function(){return f.defaultInputHasCounter}},customClass:{type:String,default:""},iconRight:String,iconRightClickable:Boolean,iconRightType:String},data:function(){return{newValue:this.value,newType:this.type,newAutocomplete:this.autocomplete||f.defaultInputAutocomplete,isPasswordVisible:!1,_elementRef:"textarea"===this.type?"textarea":"input"}},computed:{computedValue:{get:function(){return this.newValue},set:function(e){this.newValue=e,this.$emit("input",e)}},rootClasses:function(){return[this.iconPosition,this.size,{"is-expanded":this.expanded,"is-loading":this.loading,"is-clearfix":!this.hasMessage}]},inputClasses:function(){return[this.statusType,this.size,{"is-rounded":this.rounded}]},hasIconRight:function(){return this.passwordReveal||this.loading||this.statusIcon&&this.statusTypeIcon||this.iconRight},rightIcon:function(){return this.passwordReveal?this.passwordVisibleIcon:this.iconRight?this.iconRight:this.statusTypeIcon},rightIconType:function(){return this.passwordReveal?"is-primary":this.iconRight?this.iconRightType||null:this.statusType},iconPosition:function(){var e="";return this.icon&&(e+="has-icons-left "),this.hasIconRight&&(e+="has-icons-right"),e},statusTypeIcon:function(){switch(this.statusType){case"is-success":return"check";case"is-danger":return"alert-circle";case"is-info":return"information";case"is-warning":return"alert"}},hasMessage:function(){return!!this.statusMessage},passwordVisibleIcon:function(){return this.isPasswordVisible?"eye-off":"eye"},valueLength:function(){return"string"==typeof this.computedValue?this.computedValue.length:"number"==typeof this.computedValue?this.computedValue.toString().length:0}},watch:{value:function(e){this.newValue=e}},methods:{togglePasswordVisibility:function(){var e=this;this.isPasswordVisible=!this.isPasswordVisible,this.newType=this.isPasswordVisible?"text":"password",this.$nextTick(function(){e.focus()})},iconClick:function(e,t){var i=this;this.$emit(e,t),this.$nextTick(function(){i.focus()})},rightIconClick:function(e){this.passwordReveal?this.togglePasswordVisibility():this.iconRightClickable&&this.iconClick("icon-right-click",e)},onInput:function(e){if(!this.lazy){var t=e.target.value;this.updateValue(t)}},onChange:function(e){if(this.lazy){var t=e.target.value;this.updateValue(t)}},updateValue:function(e){this.computedValue=e,!this.isValid&&this.checkHtml5Validity()}}},void 0,!1,void 0,void 0,void 0);var w,k=h({render:function(){var e=this,t=e.$createElement,i=e._self._c||t;return i("div",{staticClass:"autocomplete control",class:{"is-expanded":e.expanded}},[i("b-input",e._b({ref:"input",attrs:{type:e.type,size:e.size,loading:e.loading,rounded:e.rounded,icon:e.icon,"icon-right":e.newIconRight,"icon-right-clickable":e.newIconRightClickable,"icon-pack":e.iconPack,maxlength:e.maxlength,autocomplete:e.newAutocomplete,"use-html5-validation":!1,"aria-autocomplete":e.ariaAutocomplete},on:{input:e.onInput,focus:e.focused,blur:e.onBlur,"icon-right-click":e.rightIconClick,"icon-click":function(t){return e.$emit("icon-click",t)}},nativeOn:{keydown:[function(t){return e.keydown(t)},function(t){return!t.type.indexOf("key")&&e._k(t.keyCode,"up",38,t.key,["Up","ArrowUp"])?null:(t.preventDefault(),e.keyArrows("up"))},function(t){return!t.type.indexOf("key")&&e._k(t.keyCode,"down",40,t.key,["Down","ArrowDown"])?null:(t.preventDefault(),e.keyArrows("down"))}]},model:{value:e.newValue,callback:function(t){e.newValue=t},expression:"newValue"}},"b-input",e.$attrs,!1)),i("transition",{attrs:{name:"fade"}},[i("div",{directives:[{name:"show",rawName:"v-show",value:e.isActive&&(!e.isEmpty||e.hasEmptySlot||e.hasHeaderSlot),expression:"isActive && (!isEmpty || hasEmptySlot || hasHeaderSlot)"}],ref:"dropdown",staticClass:"dropdown-menu",class:{"is-opened-top":e.isOpenedTop&&!e.appendToBody},style:e.style},[i("div",{directives:[{name:"show",rawName:"v-show",value:e.isActive,expression:"isActive"}],staticClass:"dropdown-content",style:e.contentStyle},[e.hasHeaderSlot?i("div",{staticClass:"dropdown-item dropdown-header",class:{"is-hovered":e.headerHovered},attrs:{role:"button",tabindex:"0"},on:{click:function(t){return e.selectHeaderOrFoterByClick(t,"header")}}},[e._t("header")],2):e._e(),e._l(e.computedData,function(t,n){return[t.group?i("div",{key:n+"group",staticClass:"dropdown-item"},[e.hasGroupSlot?e._t("group",null,{group:t.group,index:n}):i("span",{staticClass:"has-text-weight-bold"},[e._v(" "+e._s(t.group)+" ")])],2):e._e(),e._l(t.items,function(t,o){return i("a",{key:n+":"+o,staticClass:"dropdown-item",class:{"is-hovered":t===e.hovered},attrs:{role:"button",tabindex:"0"},on:{click:function(i){return i.stopPropagation(),e.setSelected(t,!e.keepOpen,i)}}},[e.hasDefaultSlot?e._t("default",null,{option:t,index:o}):i("span",[e._v(" "+e._s(e.getValue(t,!0))+" ")])],2)})]}),e.isEmpty&&e.hasEmptySlot?i("div",{staticClass:"dropdown-item is-disabled"},[e._t("empty")],2):e._e(),e.hasFooterSlot?i("div",{staticClass:"dropdown-item dropdown-footer",class:{"is-hovered":e.footerHovered},attrs:{role:"button",tabindex:"0"},on:{click:function(t){return e.selectHeaderOrFoterByClick(t,"footer")}}},[e._t("footer")],2):e._e()],2)])])],1)},staticRenderFns:[]},void 0,{name:"BAutocomplete",components:i({},b.name,b),mixins:[m],inheritAttrs:!1,props:{value:[Number,String],data:{type:Array,default:function(){return[]}},field:{type:String,default:"value"},keepFirst:Boolean,clearOnSelect:Boolean,openOnFocus:Boolean,customFormatter:Function,checkInfiniteScroll:Boolean,keepOpen:Boolean,selectOnClickOutside:Boolean,clearable:Boolean,maxHeight:[String,Number],dropdownPosition:{type:String,default:"auto"},groupField:String,groupOptions:String,iconRight:String,iconRightClickable:Boolean,appendToBody:Boolean,type:{type:String,default:"text"},confirmKeys:{type:Array,default:function(){return["Tab","Enter"]}},selectableHeader:Boolean,selectableFooter:Boolean},data:function(){return{selected:null,hovered:null,headerHovered:null,footerHovered:null,isActive:!1,newValue:this.value,newAutocomplete:this.autocomplete||"off",ariaAutocomplete:this.keepFirst?"both":"list",isListInViewportVertically:!0,hasFocus:!1,style:{},_isAutocomplete:!0,_elementRef:"input",_bodyEl:void 0}},computed:{computedData:function(){var e=this;if(this.groupField){if(this.groupOptions){var t=[];return this.data.forEach(function(i){var n=c(i,e.groupField),o=c(i,e.groupOptions);t.push({group:n,items:o})}),t}var i={};this.data.forEach(function(t){var n=c(t,e.groupField);i[n]||(i[n]=[]),i[n].push(t)});var n=[];return Object.keys(i).forEach(function(e){n.push({group:e,items:i[e]})}),n}return[{items:this.data}]},isEmpty:function(){return!this.computedData||!this.computedData.some(function(e){return e.items&&e.items.length})},whiteList:function(){var e=[];if(e.push(this.$refs.input.$el.querySelector("input")),e.push(this.$refs.dropdown),void 0!==this.$refs.dropdown){var t=this.$refs.dropdown.querySelectorAll("*"),i=!0,n=!1,o=void 0;try{for(var s,a=t[Symbol.iterator]();!(i=(s=a.next()).done);i=!0){var r=s.value;e.push(r)}}catch(e){n=!0,o=e}finally{try{i||null==a.return||a.return()}finally{if(n)throw o}}}if(this.$parent.$data._isTaginput){e.push(this.$parent.$el);var l=this.$parent.$el.querySelectorAll("*"),c=!0,u=!1,d=void 0;try{for(var h,p=l[Symbol.iterator]();!(c=(h=p.next()).done);c=!0){var f=h.value;e.push(f)}}catch(e){u=!0,d=e}finally{try{c||null==p.return||p.return()}finally{if(u)throw d}}}return e},hasDefaultSlot:function(){return!!this.$scopedSlots.default},hasGroupSlot:function(){return!!this.$scopedSlots.group},hasEmptySlot:function(){return!!this.$slots.empty},hasHeaderSlot:function(){return!!this.$slots.header},hasFooterSlot:function(){return!!this.$slots.footer},isOpenedTop:function(){return"top"===this.dropdownPosition||"auto"===this.dropdownPosition&&!this.isListInViewportVertically},newIconRight:function(){return this.clearable&&this.newValue?"close-circle":this.iconRight},newIconRightClickable:function(){return!!this.clearable||this.iconRightClickable},contentStyle:function(){return{maxHeight:(e=this.maxHeight,void 0===e?null:isNaN(e)?e:e+"px")};var e}},watch:{isActive:function(e){var t=this;"auto"===this.dropdownPosition&&(e?this.calcDropdownInViewportVertical():setTimeout(function(){t.calcDropdownInViewportVertical()},100))},newValue:function(e){this.$emit("input",e);var t=this.getValue(this.selected);t&&t!==e&&this.setSelected(null,!1),!this.hasFocus||this.openOnFocus&&!e||(this.isActive=!!e)},value:function(e){this.newValue=e},data:function(){var e=this;this.keepFirst&&this.$nextTick(function(){e.isActive?e.selectFirstOption(e.computedData):e.setHovered(null)})}},methods:{setHovered:function(e){void 0!==e&&(this.hovered=e)},setSelected:function(e){var t=this,i=!(arguments.length>1&&void 0!==arguments[1])||arguments[1],n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:void 0;if(void 0!==e){if(this.selected=e,this.$emit("select",this.selected,n),null!==this.selected){if(this.clearOnSelect){var o=this.$refs.input;o.newValue="",o.$refs.input.value=""}else this.newValue=this.getValue(this.selected);this.setHovered(null)}i&&this.$nextTick(function(){t.isActive=!1}),this.checkValidity()}},selectFirstOption:function(e){var t=this;this.$nextTick(function(){var i=e.filter(function(e){return e.items&&e.items.length});if(i.length){var n=i[0].items[0];t.setHovered(n)}else t.setHovered(null)})},keydown:function(e){var t=e.key;if("Enter"===t&&e.preventDefault(),"Escape"!==t&&"Tab"!==t||(this.isActive=!1),this.confirmKeys.indexOf(t)>=0){","===t&&e.preventDefault();var i=!this.keepOpen||"Tab"===t;if(null===this.hovered)return void this.checkIfHeaderOrFooterSelected(e,null,i);this.setSelected(this.hovered,i,e)}},selectHeaderOrFoterByClick:function(e,t){this.checkIfHeaderOrFooterSelected(e,{origin:t})},checkIfHeaderOrFooterSelected:function(e,t){var i=!(arguments.length>2&&void 0!==arguments[2])||arguments[2];this.selectableHeader&&(this.headerHovered||t&&"header"===t.origin)&&(this.$emit("select-header",e),this.headerHovered=!1,t&&this.setHovered(null),i&&(this.isActive=!1)),this.selectableFooter&&(this.footerHovered||t&&"footer"===t.origin)&&(this.$emit("select-footer",e),this.footerHovered=!1,t&&this.setHovered(null),i&&(this.isActive=!1))},clickedOutside:function(e){var t="shadowRoot"in this.$root.$options?e.composedPath()[0]:e.target;!this.hasFocus&&this.whiteList.indexOf(t)<0&&(this.keepFirst&&this.hovered&&this.selectOnClickOutside?this.setSelected(this.hovered,!0):this.isActive=!1)},getValue:function(e){if(null!==e)return void 0!==this.customFormatter?this.customFormatter(e):"object"===t(e)?c(e,this.field):e},checkIfReachedTheEndOfScroll:function(e){e.clientHeight!==e.scrollHeight&&e.scrollTop+e.clientHeight>=e.scrollHeight&&this.$emit("infinite-scroll")},calcDropdownInViewportVertical:function(){var e=this;this.$nextTick(function(){if(void 0!==e.$refs.dropdown){var t=e.$refs.dropdown.getBoundingClientRect();e.isListInViewportVertically=t.top>=0&&t.bottom<=(window.innerHeight||document.documentElement.clientHeight),e.appendToBody&&e.updateAppendToBody()}})},keyArrows:function(e){var t="down"===e?1:-1;if(this.isActive){var i,n=this.computedData.map(function(e){return e.items}).reduce(function(e,t){return[].concat(r(e),r(t))},[]);this.hasHeaderSlot&&this.selectableHeader&&n.unshift(void 0),this.hasFooterSlot&&this.selectableFooter&&n.push(void 0),i=(i=(i=this.headerHovered?0+t:this.footerHovered?n.length-1+t:n.indexOf(this.hovered)+t)>n.length-1?n.length-1:i)<0?0:i,this.footerHovered=!1,this.headerHovered=!1,this.setHovered(void 0!==n[i]?n[i]:null),this.hasFooterSlot&&this.selectableFooter&&i===n.length-1&&(this.footerHovered=!0),this.hasHeaderSlot&&this.selectableHeader&&0===i&&(this.headerHovered=!0);var o=this.$refs.dropdown.querySelector(".dropdown-content"),s="a.dropdown-item:not(.is-disabled)";this.hasHeaderSlot&&this.selectableHeader&&(s+=",div.dropdown-header"),this.hasFooterSlot&&this.selectableFooter&&(s+=",div.dropdown-footer");var a=o.querySelectorAll(s)[i];if(!a)return;var l=o.scrollTop,c=o.scrollTop+o.clientHeight-a.clientHeight;a.offsetTop<l?o.scrollTop=a.offsetTop:a.offsetTop>=c&&(o.scrollTop=a.offsetTop-o.clientHeight+a.clientHeight)}else this.isActive=!0},focused:function(e){this.getValue(this.selected)===this.newValue&&this.$el.querySelector("input").select(),this.openOnFocus&&(this.isActive=!0,this.keepFirst&&this.selectFirstOption(this.computedData)),this.hasFocus=!0,this.$emit("focus",e)},onBlur:function(e){this.hasFocus=!1,this.$emit("blur",e)},onInput:function(){var e=this.getValue(this.selected);e&&e===this.newValue||(this.$emit("typing",this.newValue),this.checkValidity())},rightIconClick:function(e){this.clearable?(this.newValue="",this.setSelected(null,!1),this.openOnFocus&&this.$refs.input.$el.focus()):this.$emit("icon-right-click",e)},checkValidity:function(){var e=this;this.useHtml5Validation&&this.$nextTick(function(){e.checkHtml5Validity()})},updateAppendToBody:function(){var e=this.$refs.dropdown,t=this.$refs.input.$el;if(e&&t){var i=this.$data._bodyEl;i.classList.forEach(function(e){return i.classList.remove(e)}),i.classList.add("autocomplete"),i.classList.add("control"),this.expandend&&i.classList.add("is-expandend");var n=t.getBoundingClientRect(),o=n.top+window.scrollY,s=n.left+window.scrollX;this.isOpenedTop?o-=e.clientHeight:o+=t.clientHeight,this.style={position:"absolute",top:"".concat(o,"px"),left:"".concat(s,"px"),width:"".concat(t.clientWidth,"px"),maxWidth:"".concat(t.clientWidth,"px"),zIndex:"99"}}}},created:function(){"undefined"!=typeof window&&(document.addEventListener("click",this.clickedOutside),"auto"===this.dropdownPosition&&window.addEventListener("resize",this.calcDropdownInViewportVertical))},mounted:function(){var e=this;if(this.checkInfiniteScroll&&this.$refs.dropdown&&this.$refs.dropdown.querySelector(".dropdown-content")){var t=this.$refs.dropdown.querySelector(".dropdown-content");t.addEventListener("scroll",function(){return e.checkIfReachedTheEndOfScroll(t)})}this.appendToBody&&(this.$data._bodyEl=function(e){var t=document.createElement("div");t.style.position="absolute",t.style.left="0px",t.style.top="0px",t.style.width="100%";var i=document.createElement("div");return t.appendChild(i),i.appendChild(e),document.body.appendChild(t),t}(this.$refs.dropdown),this.updateAppendToBody())},beforeDestroy:function(){var e;("undefined"!=typeof window&&(document.removeEventListener("click",this.clickedOutside),"auto"===this.dropdownPosition&&window.removeEventListener("resize",this.calcDropdownInViewportVertical)),this.checkInfiniteScroll&&this.$refs.dropdown&&this.$refs.dropdown.querySelector(".dropdown-content"))&&this.$refs.dropdown.querySelector(".dropdown-content").removeEventListener("scroll",this.checkIfReachedTheEndOfScroll);this.appendToBody&&(void 0!==(e=this.$data._bodyEl).remove?e.remove():void 0!==e.parentNode&&null!==e.parentNode&&e.parentNode.removeChild(e))}},void 0,!1,void 0,void 0,void 0);var S,T=h({render:function(){var e=this,t=e.$createElement,i=e._self._c||t;return i("div",{staticClass:"taginput control",class:e.rootClasses},[i("div",{staticClass:"taginput-container",class:[e.statusType,e.size,e.containerClasses],attrs:{disabled:e.disabled},on:{click:function(t){e.hasInput&&e.focus(t)}}},[e._t("selected",e._l(e.tags,function(t,n){return i("b-tag",{key:e.getNormalizedTagText(t)+n,attrs:{type:e.type,"close-type":e.closeType,size:e.size,rounded:e.rounded,attached:e.attached,tabstop:!1,disabled:e.disabled,ellipsis:e.ellipsis,closable:e.closable,"aria-close-label":e.ariaCloseLabel,title:e.ellipsis&&e.getNormalizedTagText(t)},on:{close:function(t){return e.removeTag(n,t)}}},[e._t("tag",[e._v(" "+e._s(e.getNormalizedTagText(t))+" ")],{tag:t})],2)}),{tags:e.tags}),e.hasInput?i("b-autocomplete",e._g(e._b({ref:"autocomplete",attrs:{data:e.data,field:e.field,icon:e.icon,"icon-pack":e.iconPack,maxlength:e.maxlength,"has-counter":!1,size:e.size,disabled:e.disabled,loading:e.loading,autocomplete:e.nativeAutocomplete,"open-on-focus":e.openOnFocus,"keep-open":e.openOnFocus,"keep-first":e.keepFirst,"group-field":e.groupField,"group-options":e.groupOptions,"use-html5-validation":e.useHtml5Validation,"check-infinite-scroll":e.checkInfiniteScroll,"append-to-body":e.appendToBody,"confirm-keys":e.confirmKeys},on:{typing:e.onTyping,focus:e.onFocus,blur:e.customOnBlur,select:e.onSelect,"infinite-scroll":e.emitInfiniteScroll},nativeOn:{keydown:function(t){return e.keydown(t)},compositionstart:function(t){e.isComposing=!0},compositionend:function(t){e.isComposing=!1}},scopedSlots:e._u([e.hasHeaderSlot?{key:"header",fn:function(){return[e._t("header")]},proxy:!0}:null,e.hasDefaultSlot?{key:"default",fn:function(t){return[e._t("default",null,{option:t.option,index:t.index})]}}:null,e.hasEmptySlot?{key:"empty",fn:function(){return[e._t("empty")]},proxy:!0}:null,e.hasFooterSlot?{key:"footer",fn:function(){return[e._t("footer")]},proxy:!0}:null],null,!0),model:{value:e.newTag,callback:function(t){e.newTag=t},expression:"newTag"}},"b-autocomplete",e.$attrs,!1),e.listeners)):e._e()],2),e.hasCounter&&(e.maxtags||e.maxlength)?i("small",{staticClass:"help counter"},[e.maxlength&&e.valueLength>0?[e._v(" "+e._s(e.valueLength)+" / "+e._s(e.maxlength)+" ")]:e.maxtags?[e._v(" "+e._s(e.tagsLength)+" / "+e._s(e.maxtags)+" ")]:e._e()],2):e._e()])},staticRenderFns:[]},void 0,{name:"BTaginput",components:(w={},i(w,k.name,k),i(w,p.name,p),w),mixins:[m],inheritAttrs:!1,props:{value:{type:Array,default:function(){return[]}},data:{type:Array,default:function(){return[]}},type:String,closeType:String,rounded:{type:Boolean,default:!1},attached:{type:Boolean,default:!1},maxtags:{type:[Number,String],required:!1},hasCounter:{type:Boolean,default:function(){return f.defaultTaginputHasCounter}},field:{type:String,default:"value"},autocomplete:Boolean,groupField:String,groupOptions:String,nativeAutocomplete:String,openOnFocus:Boolean,keepFirst:Boolean,disabled:Boolean,ellipsis:Boolean,closable:{type:Boolean,default:!0},ariaCloseLabel:String,confirmKeys:{type:Array,default:function(){return[",","Tab","Enter"]}},removeOnKeys:{type:Array,default:function(){return["Backspace"]}},allowNew:Boolean,onPasteSeparators:{type:Array,default:function(){return[","]}},beforeAdding:{type:Function,default:function(){return!0}},allowDuplicates:{type:Boolean,default:!1},checkInfiniteScroll:{type:Boolean,default:!1},createTag:{type:Function,default:function(e){return e}},appendToBody:Boolean},data:function(){return{tags:Array.isArray(this.value)?this.value.slice(0):this.value||[],newTag:"",isComposing:!1,_elementRef:"autocomplete",_isTaginput:!0}},computed:{listeners:function(){var e=this.$listeners,t=(e.input,s(e,["input"]));return t},rootClasses:function(){return{"is-expanded":this.expanded}},containerClasses:function(){return{"is-focused":this.isFocused,"is-focusable":this.hasInput}},valueLength:function(){return this.newTag.trim().length},hasDefaultSlot:function(){return!!this.$scopedSlots.default},hasEmptySlot:function(){return!!this.$slots.empty},hasHeaderSlot:function(){return!!this.$slots.header},hasFooterSlot:function(){return!!this.$slots.footer},hasInput:function(){return null==this.maxtags||1===this.maxtags||this.tagsLength<this.maxtags},tagsLength:function(){return this.tags.length},separatorsAsRegExp:function(){var e=this.onPasteSeparators;return e.length?new RegExp(e.map(function(e){return e?e.replace(/[-[\]{}()*+?.,\\^$|#\s]/g,"\\$&"):null}).join("|"),"g"):null}},watch:{value:function(e){this.tags=Array.isArray(e)?e.slice(0):e||[]},hasInput:function(){this.hasInput||this.onBlur()}},methods:{addTag:function(e){var t=this,i=e||this.newTag.trim();if(i){if(!this.autocomplete){var n=this.separatorsAsRegExp;if(n&&i.match(n))return void i.split(n).map(function(e){return e.trim()}).filter(function(e){return 0!==e.length}).map(this.addTag)}(!!this.allowDuplicates||-1===this.tags.indexOf(i))&&this.beforeAdding(i)&&(1===this.maxtags&&(this.tags=[]),this.tags.push(this.createTag(i)),this.$emit("input",this.tags),this.$emit("add",i)),requestAnimationFrame(function(){t.newTag="",t.$emit("typing","")})}},getNormalizedTagText:function(e){return"object"===t(e)&&(e=c(e,this.field)),"".concat(e)},customOnBlur:function(e){this.autocomplete||this.addTag(),this.onBlur(e)},onSelect:function(e){var t=this;e&&(this.addTag(e),this.$nextTick(function(){t.newTag=""}))},removeTag:function(e,t){var i=this.tags.splice(e,1)[0];return this.$emit("input",this.tags),this.$emit("remove",i),t&&t.stopPropagation(),this.openOnFocus&&this.$refs.autocomplete&&this.$refs.autocomplete.focus(),i},removeLastTag:function(){this.tagsLength>0&&this.removeTag(this.tagsLength-1)},keydown:function(e){var t=e.key;if(-1===this.removeOnKeys.indexOf(t)||this.newTag.length||this.removeLastTag(),(!this.autocomplete||this.allowNew)&&this.confirmKeys.indexOf(t)>=0){if("Tab"!==t&&e.preventDefault(),"Enter"===t&&this.isComposing)return;this.addTag()}},onTyping:function(e){this.$emit("typing",e.trim())},emitInfiniteScroll:function(){this.$emit("infinite-scroll")}}},void 0,!1,void 0,void 0,void 0),x={install:function(e){!function(e,t){e.component(t.name,t)}(e,T)}};S=x,"undefined"!=typeof window&&window.Vue&&window.Vue.use(S),e.BTaginput=T,e.default=x,Object.defineProperty(e,"__esModule",{value:!0})});
|
|
1
|
+
/*! Buefy v0.9.14 | MIT License | github.com/buefy/buefy */
|
|
2
|
+
!function(e,t){"object"==typeof exports&&"undefined"!=typeof module?t(exports):"function"==typeof define&&define.amd?define(["exports"],t):t((e=e||self).Taginput={})}(this,function(e){"use strict";function t(e){return(t="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function i(e,t,i){return t in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}function n(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),i.push.apply(i,n)}return i}function o(e){for(var t=1;t<arguments.length;t++){var o=null!=arguments[t]?arguments[t]:{};t%2?n(Object(o),!0).forEach(function(t){i(e,t,o[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(o)):n(Object(o)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(o,t))})}return e}function s(e,t){if(null==e)return{};var i,n,o=function(e,t){if(null==e)return{};var i,n,o={},s=Object.keys(e);for(n=0;n<s.length;n++)i=s[n],t.indexOf(i)>=0||(o[i]=e[i]);return o}(e,t);if(Object.getOwnPropertySymbols){var s=Object.getOwnPropertySymbols(e);for(n=0;n<s.length;n++)i=s[n],t.indexOf(i)>=0||Object.prototype.propertyIsEnumerable.call(e,i)&&(o[i]=e[i])}return o}function a(e){return function(e){if(Array.isArray(e))return e}(e)||l(e)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance")}()}function r(e){return function(e){if(Array.isArray(e)){for(var t=0,i=new Array(e.length);t<e.length;t++)i[t]=e[t];return i}}(e)||l(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance")}()}function l(e){if(Symbol.iterator in Object(e)||"[object Arguments]"===Object.prototype.toString.call(e))return Array.from(e)}function c(e,t){return t.split(".").reduce(function(e,t){return e?e[t]:null},e)}var u=function(e){return"object"===t(e)&&!Array.isArray(e)},d=function e(t,n){var s=arguments.length>2&&void 0!==arguments[2]&&arguments[2];if(s||!Object.assign){var a=Object.getOwnPropertyNames(n).map(function(o){return i({},o,function(e){return u(n[e])&&null!==t&&t.hasOwnProperty(e)&&u(t[e])}(o)?e(t[o],n[o],s):n[o])}).reduce(function(e,t){return o({},e,{},t)},{});return o({},t,{},a)}return Object.assign(t,n)};var h=function(e,t,i,n,o,s,a,r,l,c){"boolean"!=typeof a&&(l=r,r=a,a=!1);var u,d="function"==typeof i?i.options:i;if(e&&e.render&&(d.render=e.render,d.staticRenderFns=e.staticRenderFns,d._compiled=!0,o&&(d.functional=!0)),n&&(d._scopeId=n),s?(u=function(e){(e=e||this.$vnode&&this.$vnode.ssrContext||this.parent&&this.parent.$vnode&&this.parent.$vnode.ssrContext)||"undefined"==typeof __VUE_SSR_CONTEXT__||(e=__VUE_SSR_CONTEXT__),t&&t.call(this,l(e)),e&&e._registeredComponents&&e._registeredComponents.add(s)},d._ssrRegister=u):t&&(u=a?function(){t.call(this,c(this.$root.$options.shadowRoot))}:function(e){t.call(this,r(e))}),u)if(d.functional){var h=d.render;d.render=function(e,t){return u.call(t),h(e,t)}}else{var p=d.beforeCreate;d.beforeCreate=p?[].concat(p,u):[u]}return i};var p=h({render:function(){var e=this,t=e.$createElement,i=e._self._c||t;return e.attached&&e.closable?i("div",{staticClass:"tags has-addons"},[i("span",{staticClass:"tag",class:[e.type,e.size,{"is-rounded":e.rounded}]},[e.icon?i("b-icon",{attrs:{icon:e.icon,size:e.size,type:e.iconType,pack:e.iconPack}}):e._e(),i("span",{class:{"has-ellipsis":e.ellipsis},on:{click:e.click}},[e._t("default")],2)],1),i("a",{staticClass:"tag",class:[e.size,e.closeType,{"is-rounded":e.rounded},e.closeIcon?"has-delete-icon":"is-delete"],attrs:{role:"button","aria-label":e.ariaCloseLabel,tabindex:!!e.tabstop&&0,disabled:e.disabled},on:{click:e.close,keyup:function(t){return!t.type.indexOf("key")&&e._k(t.keyCode,"delete",[8,46],t.key,["Backspace","Delete","Del"])?null:(t.preventDefault(),e.close(t))}}},[e.closeIcon?i("b-icon",{attrs:{"custom-class":"",icon:e.closeIcon,size:e.size,type:e.closeIconType,pack:e.closeIconPack}}):e._e()],1)]):i("span",{staticClass:"tag",class:[e.type,e.size,{"is-rounded":e.rounded}]},[e.icon?i("b-icon",{attrs:{icon:e.icon,size:e.size,type:e.iconType,pack:e.iconPack}}):e._e(),i("span",{class:{"has-ellipsis":e.ellipsis},on:{click:e.click}},[e._t("default")],2),e.closable?i("a",{staticClass:"delete is-small",class:e.closeType,attrs:{role:"button","aria-label":e.ariaCloseLabel,disabled:e.disabled,tabindex:!!e.tabstop&&0},on:{click:e.close,keyup:function(t){return!t.type.indexOf("key")&&e._k(t.keyCode,"delete",[8,46],t.key,["Backspace","Delete","Del"])?null:(t.preventDefault(),e.close(t))}}}):e._e()],1)},staticRenderFns:[]},void 0,{name:"BTag",props:{attached:Boolean,closable:Boolean,type:String,size:String,rounded:Boolean,disabled:Boolean,ellipsis:Boolean,tabstop:{type:Boolean,default:!0},ariaCloseLabel:String,icon:String,iconType:String,iconPack:String,closeType:String,closeIcon:String,closeIconPack:String,closeIconType:String},methods:{close:function(e){this.disabled||this.$emit("close",e)},click:function(e){this.disabled||this.$emit("click",e)}}},void 0,!1,void 0,void 0,void 0),f={defaultContainerElement:null,defaultIconPack:"mdi",defaultIconComponent:null,defaultIconPrev:"chevron-left",defaultIconNext:"chevron-right",defaultLocale:void 0,defaultDialogConfirmText:null,defaultDialogCancelText:null,defaultSnackbarDuration:3500,defaultSnackbarPosition:null,defaultToastDuration:2e3,defaultToastPosition:null,defaultNotificationDuration:2e3,defaultNotificationPosition:null,defaultTooltipType:"is-primary",defaultTooltipDelay:null,defaultSidebarDelay:null,defaultInputAutocomplete:"on",defaultDateFormatter:null,defaultDateParser:null,defaultDateCreator:null,defaultTimeCreator:null,defaultDayNames:null,defaultMonthNames:null,defaultFirstDayOfWeek:null,defaultUnselectableDaysOfWeek:null,defaultTimeFormatter:null,defaultTimeParser:null,defaultModalCanCancel:["escape","x","outside","button"],defaultModalScroll:null,defaultDatepickerMobileNative:!0,defaultTimepickerMobileNative:!0,defaultNoticeQueue:!1,defaultInputHasCounter:!0,defaultTaginputHasCounter:!0,defaultUseHtml5Validation:!0,defaultDropdownMobileModal:!0,defaultFieldLabelPosition:null,defaultDatepickerYearsRange:[-100,10],defaultDatepickerNearbyMonthDays:!0,defaultDatepickerNearbySelectableMonthDays:!1,defaultDatepickerShowWeekNumber:!1,defaultDatepickerWeekNumberClickable:!1,defaultDatepickerMobileModal:!0,defaultTrapFocus:!0,defaultAutoFocus:!0,defaultButtonRounded:!1,defaultSwitchRounded:!0,defaultCarouselInterval:3500,defaultTabsExpanded:!1,defaultTabsAnimated:!0,defaultTabsType:null,defaultStatusIcon:!0,defaultProgrammaticPromise:!1,defaultLinkTags:["a","button","input","router-link","nuxt-link","n-link","RouterLink","NuxtLink","NLink"],defaultImageWebpFallback:null,defaultImageLazy:!0,defaultImageResponsive:!0,defaultImageRatio:null,defaultImageSrcsetFormatter:null,defaultBreadcrumbTag:"a",defaultBreadcrumbAlign:"is-left",defaultBreadcrumbSeparator:"",defaultBreadcrumbSize:"is-medium",customIconPacks:null},m={props:{size:String,expanded:Boolean,loading:Boolean,rounded:Boolean,icon:String,iconPack:String,autocomplete:String,maxlength:[Number,String],useHtml5Validation:{type:Boolean,default:function(){return f.defaultUseHtml5Validation}},validationMessage:String,locale:{type:[String,Array],default:function(){return f.defaultLocale}},statusIcon:{type:Boolean,default:function(){return f.defaultStatusIcon}}},data:function(){return{isValid:!0,isFocused:!1,newIconPack:this.iconPack||f.defaultIconPack}},computed:{parentField:function(){for(var e=this.$parent,t=0;t<3;t++)e&&!e.$data._isField&&(e=e.$parent);return e},statusType:function(){var e=(this.parentField||{}).newType;if(e){if("string"==typeof e)return e;for(var t in e)if(e[t])return t}},statusMessage:function(){if(this.parentField)return this.parentField.newMessage||this.parentField.$slots.message},iconSize:function(){switch(this.size){case"is-small":return this.size;case"is-medium":return;case"is-large":return"mdi"===this.newIconPack?"is-medium":""}}},methods:{focus:function(){var e=this.getElement();void 0!==e&&this.$nextTick(function(){e&&e.focus()})},onBlur:function(e){this.isFocused=!1,this.$emit("blur",e),this.checkHtml5Validity()},onFocus:function(e){this.isFocused=!0,this.$emit("focus",e),this.checkHtml5Validity()},getElement:function(){for(var e,t=this.$refs[this.$data._elementRef];(e=t)&&e._isVue;)t=t.$refs[t.$data._elementRef];return t},setInvalid:function(){var e=this.validationMessage||this.getElement().validationMessage;this.setValidity("is-danger",e)},setValidity:function(e,t){var i=this;this.$nextTick(function(){i.parentField&&(i.parentField.type||(i.parentField.newType=e),i.parentField.message||(i.parentField.newMessage=t))})},checkHtml5Validity:function(){if(this.useHtml5Validation){var e=this.getElement();if(void 0!==e)return e.checkValidity()?(this.setValidity(null,null),this.isValid=!0):(this.setInvalid(),this.isValid=!1),this.isValid}}}},g={sizes:{default:"mdi-24px","is-small":null,"is-medium":"mdi-36px","is-large":"mdi-48px"},iconPrefix:"mdi-"},v=function(){var e=f&&f.defaultIconComponent?"":"fa-";return{sizes:{default:null,"is-small":null,"is-medium":e+"lg","is-large":e+"2x"},iconPrefix:e,internalIcons:{information:"info-circle",alert:"exclamation-triangle","alert-circle":"exclamation-circle","chevron-right":"angle-right","chevron-left":"angle-left","chevron-down":"angle-down","eye-off":"eye-slash","menu-down":"caret-down","menu-up":"caret-up","close-circle":"times-circle"}}};var y=h({render:function(){var e=this,t=e.$createElement,i=e._self._c||t;return i("span",{staticClass:"icon",class:[e.newType,e.size]},[e.useIconComponent?i(e.useIconComponent,{tag:"component",class:[e.customClass],attrs:{icon:[e.newPack,e.newIcon],size:e.newCustomSize}}):i("i",{class:[e.newPack,e.newIcon,e.newCustomSize,e.customClass]})],1)},staticRenderFns:[]},void 0,{name:"BIcon",props:{type:[String,Object],component:String,pack:String,icon:String,size:String,customSize:String,customClass:String,both:Boolean},computed:{iconConfig:function(){var e;return(e={mdi:g,fa:v(),fas:v(),far:v(),fad:v(),fab:v(),fal:v()},f&&f.customIconPacks&&(e=d(e,f.customIconPacks,!0)),e)[this.newPack]},iconPrefix:function(){return this.iconConfig&&this.iconConfig.iconPrefix?this.iconConfig.iconPrefix:""},newIcon:function(){return"".concat(this.iconPrefix).concat(this.getEquivalentIconOf(this.icon))},newPack:function(){return this.pack||f.defaultIconPack},newType:function(){if(this.type){var e=[];if("string"==typeof this.type)e=this.type.split("-");else for(var t in this.type)if(this.type[t]){e=t.split("-");break}if(!(e.length<=1)){var i=a(e).slice(1);return"has-text-".concat(i.join("-"))}}},newCustomSize:function(){return this.customSize||this.customSizeByPack},customSizeByPack:function(){if(this.iconConfig&&this.iconConfig.sizes){if(this.size&&void 0!==this.iconConfig.sizes[this.size])return this.iconConfig.sizes[this.size];if(this.iconConfig.sizes.default)return this.iconConfig.sizes.default}return null},useIconComponent:function(){return this.component||f.defaultIconComponent}},methods:{getEquivalentIconOf:function(e){return this.both&&this.iconConfig&&this.iconConfig.internalIcons&&this.iconConfig.internalIcons[e]?this.iconConfig.internalIcons[e]:e}}},void 0,!1,void 0,void 0,void 0);var b=h({render:function(){var e=this,t=e.$createElement,i=e._self._c||t;return i("div",{staticClass:"control",class:e.rootClasses},["textarea"!==e.type?i("input",e._b({ref:"input",staticClass:"input",class:[e.inputClasses,e.customClass],attrs:{type:e.newType,autocomplete:e.newAutocomplete,maxlength:e.maxlength},domProps:{value:e.computedValue},on:{input:e.onInput,change:e.onChange,blur:e.onBlur,focus:e.onFocus}},"input",e.$attrs,!1)):i("textarea",e._b({ref:"textarea",staticClass:"textarea",class:[e.inputClasses,e.customClass],attrs:{maxlength:e.maxlength},domProps:{value:e.computedValue},on:{input:e.onInput,change:e.onChange,blur:e.onBlur,focus:e.onFocus}},"textarea",e.$attrs,!1)),e.icon?i("b-icon",{staticClass:"is-left",class:{"is-clickable":e.iconClickable},attrs:{icon:e.icon,pack:e.iconPack,size:e.iconSize},nativeOn:{click:function(t){return e.iconClick("icon-click",t)}}}):e._e(),!e.loading&&e.hasIconRight?i("b-icon",{staticClass:"is-right",class:{"is-clickable":e.passwordReveal||e.iconRightClickable},attrs:{icon:e.rightIcon,pack:e.iconPack,size:e.iconSize,type:e.rightIconType,both:""},nativeOn:{click:function(t){return e.rightIconClick(t)}}}):e._e(),e.maxlength&&e.hasCounter&&"number"!==e.type?i("small",{staticClass:"help counter",class:{"is-invisible":!e.isFocused}},[e._v(" "+e._s(e.valueLength)+" / "+e._s(e.maxlength)+" ")]):e._e()],1)},staticRenderFns:[]},void 0,{name:"BInput",components:i({},y.name,y),mixins:[m],inheritAttrs:!1,props:{value:[Number,String],type:{type:String,default:"text"},lazy:{type:Boolean,default:!1},passwordReveal:Boolean,iconClickable:Boolean,hasCounter:{type:Boolean,default:function(){return f.defaultInputHasCounter}},customClass:{type:String,default:""},iconRight:String,iconRightClickable:Boolean,iconRightType:String},data:function(){return{newValue:this.value,newType:this.type,newAutocomplete:this.autocomplete||f.defaultInputAutocomplete,isPasswordVisible:!1,_elementRef:"textarea"===this.type?"textarea":"input"}},computed:{computedValue:{get:function(){return this.newValue},set:function(e){this.newValue=e,this.$emit("input",e)}},rootClasses:function(){return[this.iconPosition,this.size,{"is-expanded":this.expanded,"is-loading":this.loading,"is-clearfix":!this.hasMessage}]},inputClasses:function(){return[this.statusType,this.size,{"is-rounded":this.rounded}]},hasIconRight:function(){return this.passwordReveal||this.loading||this.statusIcon&&this.statusTypeIcon||this.iconRight},rightIcon:function(){return this.passwordReveal?this.passwordVisibleIcon:this.iconRight?this.iconRight:this.statusTypeIcon},rightIconType:function(){return this.passwordReveal?"is-primary":this.iconRight?this.iconRightType||null:this.statusType},iconPosition:function(){var e="";return this.icon&&(e+="has-icons-left "),this.hasIconRight&&(e+="has-icons-right"),e},statusTypeIcon:function(){switch(this.statusType){case"is-success":return"check";case"is-danger":return"alert-circle";case"is-info":return"information";case"is-warning":return"alert"}},hasMessage:function(){return!!this.statusMessage},passwordVisibleIcon:function(){return this.isPasswordVisible?"eye-off":"eye"},valueLength:function(){return"string"==typeof this.computedValue?this.computedValue.length:"number"==typeof this.computedValue?this.computedValue.toString().length:0}},watch:{value:function(e){this.newValue=e}},methods:{togglePasswordVisibility:function(){var e=this;this.isPasswordVisible=!this.isPasswordVisible,this.newType=this.isPasswordVisible?"text":"password",this.$nextTick(function(){e.focus()})},iconClick:function(e,t){var i=this;this.$emit(e,t),this.$nextTick(function(){i.focus()})},rightIconClick:function(e){this.passwordReveal?this.togglePasswordVisibility():this.iconRightClickable&&this.iconClick("icon-right-click",e)},onInput:function(e){if(!this.lazy){var t=e.target.value;this.updateValue(t)}},onChange:function(e){if(this.lazy){var t=e.target.value;this.updateValue(t)}},updateValue:function(e){this.computedValue=e,!this.isValid&&this.checkHtml5Validity()}}},void 0,!1,void 0,void 0,void 0);var w,k=h({render:function(){var e=this,t=e.$createElement,i=e._self._c||t;return i("div",{staticClass:"autocomplete control",class:{"is-expanded":e.expanded}},[i("b-input",e._b({ref:"input",attrs:{type:e.type,size:e.size,loading:e.loading,rounded:e.rounded,icon:e.icon,"icon-right":e.newIconRight,"icon-right-clickable":e.newIconRightClickable,"icon-pack":e.iconPack,maxlength:e.maxlength,autocomplete:e.newAutocomplete,"use-html5-validation":!1,"aria-autocomplete":e.ariaAutocomplete},on:{input:e.onInput,focus:e.focused,blur:e.onBlur,"icon-right-click":e.rightIconClick,"icon-click":function(t){return e.$emit("icon-click",t)}},nativeOn:{keydown:[function(t){return e.keydown(t)},function(t){return!t.type.indexOf("key")&&e._k(t.keyCode,"up",38,t.key,["Up","ArrowUp"])?null:(t.preventDefault(),e.keyArrows("up"))},function(t){return!t.type.indexOf("key")&&e._k(t.keyCode,"down",40,t.key,["Down","ArrowDown"])?null:(t.preventDefault(),e.keyArrows("down"))}]},model:{value:e.newValue,callback:function(t){e.newValue=t},expression:"newValue"}},"b-input",e.$attrs,!1)),i("transition",{attrs:{name:"fade"}},[i("div",{directives:[{name:"show",rawName:"v-show",value:e.isActive&&(!e.isEmpty||e.hasEmptySlot||e.hasHeaderSlot),expression:"isActive && (!isEmpty || hasEmptySlot || hasHeaderSlot)"}],ref:"dropdown",staticClass:"dropdown-menu",class:{"is-opened-top":e.isOpenedTop&&!e.appendToBody},style:e.style},[i("div",{directives:[{name:"show",rawName:"v-show",value:e.isActive,expression:"isActive"}],staticClass:"dropdown-content",style:e.contentStyle},[e.hasHeaderSlot?i("div",{staticClass:"dropdown-item dropdown-header",class:{"is-hovered":e.headerHovered},attrs:{role:"button",tabindex:"0"},on:{click:function(t){return e.selectHeaderOrFoterByClick(t,"header")}}},[e._t("header")],2):e._e(),e._l(e.computedData,function(t,n){return[t.group?i("div",{key:n+"group",staticClass:"dropdown-item"},[e.hasGroupSlot?e._t("group",null,{group:t.group,index:n}):i("span",{staticClass:"has-text-weight-bold"},[e._v(" "+e._s(t.group)+" ")])],2):e._e(),e._l(t.items,function(t,o){return i("a",{key:n+":"+o,staticClass:"dropdown-item",class:{"is-hovered":t===e.hovered},attrs:{role:"button",tabindex:"0"},on:{click:function(i){return i.stopPropagation(),e.setSelected(t,!e.keepOpen,i)}}},[e.hasDefaultSlot?e._t("default",null,{option:t,index:o}):i("span",[e._v(" "+e._s(e.getValue(t,!0))+" ")])],2)})]}),e.isEmpty&&e.hasEmptySlot?i("div",{staticClass:"dropdown-item is-disabled"},[e._t("empty")],2):e._e(),e.hasFooterSlot?i("div",{staticClass:"dropdown-item dropdown-footer",class:{"is-hovered":e.footerHovered},attrs:{role:"button",tabindex:"0"},on:{click:function(t){return e.selectHeaderOrFoterByClick(t,"footer")}}},[e._t("footer")],2):e._e()],2)])])],1)},staticRenderFns:[]},void 0,{name:"BAutocomplete",components:i({},b.name,b),mixins:[m],inheritAttrs:!1,props:{value:[Number,String],data:{type:Array,default:function(){return[]}},field:{type:String,default:"value"},keepFirst:Boolean,clearOnSelect:Boolean,openOnFocus:Boolean,customFormatter:Function,checkInfiniteScroll:Boolean,keepOpen:Boolean,selectOnClickOutside:Boolean,clearable:Boolean,maxHeight:[String,Number],dropdownPosition:{type:String,default:"auto"},groupField:String,groupOptions:String,iconRight:String,iconRightClickable:Boolean,appendToBody:Boolean,type:{type:String,default:"text"},confirmKeys:{type:Array,default:function(){return["Tab","Enter"]}},selectableHeader:Boolean,selectableFooter:Boolean},data:function(){return{selected:null,hovered:null,headerHovered:null,footerHovered:null,isActive:!1,newValue:this.value,newAutocomplete:this.autocomplete||"off",ariaAutocomplete:this.keepFirst?"both":"list",isListInViewportVertically:!0,hasFocus:!1,style:{},_isAutocomplete:!0,_elementRef:"input",_bodyEl:void 0}},computed:{computedData:function(){var e=this;if(this.groupField){if(this.groupOptions){var t=[];return this.data.forEach(function(i){var n=c(i,e.groupField),o=c(i,e.groupOptions);t.push({group:n,items:o})}),t}var i={};this.data.forEach(function(t){var n=c(t,e.groupField);i[n]||(i[n]=[]),i[n].push(t)});var n=[];return Object.keys(i).forEach(function(e){n.push({group:e,items:i[e]})}),n}return[{items:this.data}]},isEmpty:function(){return!this.computedData||!this.computedData.some(function(e){return e.items&&e.items.length})},whiteList:function(){var e=[];if(e.push(this.$refs.input.$el.querySelector("input")),e.push(this.$refs.dropdown),void 0!==this.$refs.dropdown){var t=this.$refs.dropdown.querySelectorAll("*"),i=!0,n=!1,o=void 0;try{for(var s,a=t[Symbol.iterator]();!(i=(s=a.next()).done);i=!0){var r=s.value;e.push(r)}}catch(e){n=!0,o=e}finally{try{i||null==a.return||a.return()}finally{if(n)throw o}}}if(this.$parent.$data._isTaginput){e.push(this.$parent.$el);var l=this.$parent.$el.querySelectorAll("*"),c=!0,u=!1,d=void 0;try{for(var h,p=l[Symbol.iterator]();!(c=(h=p.next()).done);c=!0){var f=h.value;e.push(f)}}catch(e){u=!0,d=e}finally{try{c||null==p.return||p.return()}finally{if(u)throw d}}}return e},hasDefaultSlot:function(){return!!this.$scopedSlots.default},hasGroupSlot:function(){return!!this.$scopedSlots.group},hasEmptySlot:function(){return!!this.$slots.empty},hasHeaderSlot:function(){return!!this.$slots.header},hasFooterSlot:function(){return!!this.$slots.footer},isOpenedTop:function(){return"top"===this.dropdownPosition||"auto"===this.dropdownPosition&&!this.isListInViewportVertically},newIconRight:function(){return this.clearable&&this.newValue?"close-circle":this.iconRight},newIconRightClickable:function(){return!!this.clearable||this.iconRightClickable},contentStyle:function(){return{maxHeight:(e=this.maxHeight,void 0===e?null:isNaN(e)?e:e+"px")};var e}},watch:{isActive:function(e){var t=this;"auto"===this.dropdownPosition&&(e?this.calcDropdownInViewportVertical():setTimeout(function(){t.calcDropdownInViewportVertical()},100))},newValue:function(e){this.$emit("input",e);var t=this.getValue(this.selected);t&&t!==e&&this.setSelected(null,!1),!this.hasFocus||this.openOnFocus&&!e||(this.isActive=!!e)},value:function(e){this.newValue=e},data:function(){var e=this;if(this.keepFirst)this.$nextTick(function(){e.isActive?e.selectFirstOption(e.computedData):e.setHovered(null)});else if(this.hovered){var t=this.getValue(this.hovered),i=this.computedData.map(function(e){return e.items}).reduce(function(e,t){return[].concat(r(e),r(t))},[]);i.some(function(i){return e.getValue(i)===t})||this.setHovered(null)}}},methods:{setHovered:function(e){void 0!==e&&(this.hovered=e)},setSelected:function(e){var t=this,i=!(arguments.length>1&&void 0!==arguments[1])||arguments[1],n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:void 0;if(void 0!==e){if(this.selected=e,this.$emit("select",this.selected,n),null!==this.selected){if(this.clearOnSelect){var o=this.$refs.input;o.newValue="",o.$refs.input.value=""}else this.newValue=this.getValue(this.selected);this.setHovered(null)}i&&this.$nextTick(function(){t.isActive=!1}),this.checkValidity()}},selectFirstOption:function(e){var t=this;this.$nextTick(function(){var i=e.filter(function(e){return e.items&&e.items.length});if(i.length){var n=i[0].items[0];t.setHovered(n)}else t.setHovered(null)})},keydown:function(e){var t=e.key;if("Enter"===t&&e.preventDefault(),"Escape"!==t&&"Tab"!==t||(this.isActive=!1),this.confirmKeys.indexOf(t)>=0){","===t&&e.preventDefault();var i=!this.keepOpen||"Tab"===t;if(null===this.hovered)return void this.checkIfHeaderOrFooterSelected(e,null,i);this.setSelected(this.hovered,i,e)}},selectHeaderOrFoterByClick:function(e,t){this.checkIfHeaderOrFooterSelected(e,{origin:t})},checkIfHeaderOrFooterSelected:function(e,t){var i=!(arguments.length>2&&void 0!==arguments[2])||arguments[2];this.selectableHeader&&(this.headerHovered||t&&"header"===t.origin)&&(this.$emit("select-header",e),this.headerHovered=!1,t&&this.setHovered(null),i&&(this.isActive=!1)),this.selectableFooter&&(this.footerHovered||t&&"footer"===t.origin)&&(this.$emit("select-footer",e),this.footerHovered=!1,t&&this.setHovered(null),i&&(this.isActive=!1))},clickedOutside:function(e){var t="shadowRoot"in this.$root.$options?e.composedPath()[0]:e.target;!this.hasFocus&&this.whiteList.indexOf(t)<0&&(this.keepFirst&&this.hovered&&this.selectOnClickOutside?this.setSelected(this.hovered,!0):this.isActive=!1)},getValue:function(e){if(null!==e)return void 0!==this.customFormatter?this.customFormatter(e):"object"===t(e)?c(e,this.field):e},checkIfReachedTheEndOfScroll:function(e){e.clientHeight!==e.scrollHeight&&e.scrollTop+e.clientHeight>=e.scrollHeight&&this.$emit("infinite-scroll")},calcDropdownInViewportVertical:function(){var e=this;this.$nextTick(function(){if(void 0!==e.$refs.dropdown){var t=e.$refs.dropdown.getBoundingClientRect();e.isListInViewportVertically=t.top>=0&&t.bottom<=(window.innerHeight||document.documentElement.clientHeight),e.appendToBody&&e.updateAppendToBody()}})},keyArrows:function(e){var t="down"===e?1:-1;if(this.isActive){var i,n=this.computedData.map(function(e){return e.items}).reduce(function(e,t){return[].concat(r(e),r(t))},[]);this.hasHeaderSlot&&this.selectableHeader&&n.unshift(void 0),this.hasFooterSlot&&this.selectableFooter&&n.push(void 0),i=(i=(i=this.headerHovered?0+t:this.footerHovered?n.length-1+t:n.indexOf(this.hovered)+t)>n.length-1?n.length-1:i)<0?0:i,this.footerHovered=!1,this.headerHovered=!1,this.setHovered(void 0!==n[i]?n[i]:null),this.hasFooterSlot&&this.selectableFooter&&i===n.length-1&&(this.footerHovered=!0),this.hasHeaderSlot&&this.selectableHeader&&0===i&&(this.headerHovered=!0);var o=this.$refs.dropdown.querySelector(".dropdown-content"),s="a.dropdown-item:not(.is-disabled)";this.hasHeaderSlot&&this.selectableHeader&&(s+=",div.dropdown-header"),this.hasFooterSlot&&this.selectableFooter&&(s+=",div.dropdown-footer");var a=o.querySelectorAll(s)[i];if(!a)return;var l=o.scrollTop,c=o.scrollTop+o.clientHeight-a.clientHeight;a.offsetTop<l?o.scrollTop=a.offsetTop:a.offsetTop>=c&&(o.scrollTop=a.offsetTop-o.clientHeight+a.clientHeight)}else this.isActive=!0},focused:function(e){this.getValue(this.selected)===this.newValue&&this.$el.querySelector("input").select(),this.openOnFocus&&(this.isActive=!0,this.keepFirst&&this.selectFirstOption(this.computedData)),this.hasFocus=!0,this.$emit("focus",e)},onBlur:function(e){this.hasFocus=!1,this.$emit("blur",e)},onInput:function(){var e=this.getValue(this.selected);e&&e===this.newValue||(this.$emit("typing",this.newValue),this.checkValidity())},rightIconClick:function(e){this.clearable?(this.newValue="",this.setSelected(null,!1),this.openOnFocus&&this.$refs.input.$el.focus()):this.$emit("icon-right-click",e)},checkValidity:function(){var e=this;this.useHtml5Validation&&this.$nextTick(function(){e.checkHtml5Validity()})},updateAppendToBody:function(){var e=this.$refs.dropdown,t=this.$refs.input.$el;if(e&&t){var i=this.$data._bodyEl;i.classList.forEach(function(e){return i.classList.remove(e)}),i.classList.add("autocomplete"),i.classList.add("control"),this.expandend&&i.classList.add("is-expandend");var n=t.getBoundingClientRect(),o=n.top+window.scrollY,s=n.left+window.scrollX;this.isOpenedTop?o-=e.clientHeight:o+=t.clientHeight,this.style={position:"absolute",top:"".concat(o,"px"),left:"".concat(s,"px"),width:"".concat(t.clientWidth,"px"),maxWidth:"".concat(t.clientWidth,"px"),zIndex:"99"}}}},created:function(){"undefined"!=typeof window&&(document.addEventListener("click",this.clickedOutside),"auto"===this.dropdownPosition&&window.addEventListener("resize",this.calcDropdownInViewportVertical))},mounted:function(){var e=this;if(this.checkInfiniteScroll&&this.$refs.dropdown&&this.$refs.dropdown.querySelector(".dropdown-content")){var t=this.$refs.dropdown.querySelector(".dropdown-content");t.addEventListener("scroll",function(){return e.checkIfReachedTheEndOfScroll(t)})}this.appendToBody&&(this.$data._bodyEl=function(e){var t=document.createElement("div");t.style.position="absolute",t.style.left="0px",t.style.top="0px",t.style.width="100%";var i=document.createElement("div");return t.appendChild(i),i.appendChild(e),document.body.appendChild(t),t}(this.$refs.dropdown),this.updateAppendToBody())},beforeDestroy:function(){var e;("undefined"!=typeof window&&(document.removeEventListener("click",this.clickedOutside),"auto"===this.dropdownPosition&&window.removeEventListener("resize",this.calcDropdownInViewportVertical)),this.checkInfiniteScroll&&this.$refs.dropdown&&this.$refs.dropdown.querySelector(".dropdown-content"))&&this.$refs.dropdown.querySelector(".dropdown-content").removeEventListener("scroll",this.checkIfReachedTheEndOfScroll);this.appendToBody&&(void 0!==(e=this.$data._bodyEl).remove?e.remove():void 0!==e.parentNode&&null!==e.parentNode&&e.parentNode.removeChild(e))}},void 0,!1,void 0,void 0,void 0);var S,T=h({render:function(){var e=this,t=e.$createElement,i=e._self._c||t;return i("div",{staticClass:"taginput control",class:e.rootClasses},[i("div",{staticClass:"taginput-container",class:[e.statusType,e.size,e.containerClasses],attrs:{disabled:e.disabled},on:{click:function(t){e.hasInput&&e.focus(t)}}},[e._t("selected",e._l(e.tags,function(t,n){return i("b-tag",{key:e.getNormalizedTagText(t)+n,attrs:{type:e.type,"close-type":e.closeType,size:e.size,rounded:e.rounded,attached:e.attached,tabstop:!1,disabled:e.disabled,ellipsis:e.ellipsis,closable:e.closable,"aria-close-label":e.ariaCloseLabel,title:e.ellipsis&&e.getNormalizedTagText(t)},on:{close:function(t){return e.removeTag(n,t)}}},[e._t("tag",[e._v(" "+e._s(e.getNormalizedTagText(t))+" ")],{tag:t})],2)}),{tags:e.tags}),e.hasInput?i("b-autocomplete",e._g(e._b({ref:"autocomplete",attrs:{data:e.data,field:e.field,icon:e.icon,"icon-pack":e.iconPack,maxlength:e.maxlength,"has-counter":!1,size:e.size,disabled:e.disabled,loading:e.loading,autocomplete:e.nativeAutocomplete,"open-on-focus":e.openOnFocus,"keep-open":e.openOnFocus,"keep-first":e.keepFirst,"group-field":e.groupField,"group-options":e.groupOptions,"use-html5-validation":e.useHtml5Validation,"check-infinite-scroll":e.checkInfiniteScroll,"append-to-body":e.appendToBody,"confirm-keys":e.confirmKeys},on:{typing:e.onTyping,focus:e.onFocus,blur:e.customOnBlur,select:e.onSelect,"infinite-scroll":e.emitInfiniteScroll},nativeOn:{keydown:function(t){return e.keydown(t)},compositionstart:function(t){e.isComposing=!0},compositionend:function(t){e.isComposing=!1}},scopedSlots:e._u([e.hasHeaderSlot?{key:"header",fn:function(){return[e._t("header")]},proxy:!0}:null,e.hasDefaultSlot?{key:"default",fn:function(t){return[e._t("default",null,{option:t.option,index:t.index})]}}:null,e.hasEmptySlot?{key:"empty",fn:function(){return[e._t("empty")]},proxy:!0}:null,e.hasFooterSlot?{key:"footer",fn:function(){return[e._t("footer")]},proxy:!0}:null],null,!0),model:{value:e.newTag,callback:function(t){e.newTag=t},expression:"newTag"}},"b-autocomplete",e.$attrs,!1),e.listeners)):e._e()],2),e.hasCounter&&(e.maxtags||e.maxlength)?i("small",{staticClass:"help counter"},[e.maxlength&&e.valueLength>0?[e._v(" "+e._s(e.valueLength)+" / "+e._s(e.maxlength)+" ")]:e.maxtags?[e._v(" "+e._s(e.tagsLength)+" / "+e._s(e.maxtags)+" ")]:e._e()],2):e._e()])},staticRenderFns:[]},void 0,{name:"BTaginput",components:(w={},i(w,k.name,k),i(w,p.name,p),w),mixins:[m],inheritAttrs:!1,props:{value:{type:Array,default:function(){return[]}},data:{type:Array,default:function(){return[]}},type:String,closeType:String,rounded:{type:Boolean,default:!1},attached:{type:Boolean,default:!1},maxtags:{type:[Number,String],required:!1},hasCounter:{type:Boolean,default:function(){return f.defaultTaginputHasCounter}},field:{type:String,default:"value"},autocomplete:Boolean,groupField:String,groupOptions:String,nativeAutocomplete:String,openOnFocus:Boolean,keepFirst:Boolean,disabled:Boolean,ellipsis:Boolean,closable:{type:Boolean,default:!0},ariaCloseLabel:String,confirmKeys:{type:Array,default:function(){return[",","Tab","Enter"]}},removeOnKeys:{type:Array,default:function(){return["Backspace"]}},allowNew:Boolean,onPasteSeparators:{type:Array,default:function(){return[","]}},beforeAdding:{type:Function,default:function(){return!0}},allowDuplicates:{type:Boolean,default:!1},checkInfiniteScroll:{type:Boolean,default:!1},createTag:{type:Function,default:function(e){return e}},appendToBody:Boolean},data:function(){return{tags:Array.isArray(this.value)?this.value.slice(0):this.value||[],newTag:"",isComposing:!1,_elementRef:"autocomplete",_isTaginput:!0}},computed:{listeners:function(){var e=this.$listeners,t=(e.input,s(e,["input"]));return t},rootClasses:function(){return{"is-expanded":this.expanded}},containerClasses:function(){return{"is-focused":this.isFocused,"is-focusable":this.hasInput}},valueLength:function(){return this.newTag.trim().length},hasDefaultSlot:function(){return!!this.$scopedSlots.default},hasEmptySlot:function(){return!!this.$slots.empty},hasHeaderSlot:function(){return!!this.$slots.header},hasFooterSlot:function(){return!!this.$slots.footer},hasInput:function(){return null==this.maxtags||1===this.maxtags||this.tagsLength<this.maxtags},tagsLength:function(){return this.tags.length},separatorsAsRegExp:function(){var e=this.onPasteSeparators;return e.length?new RegExp(e.map(function(e){return e?e.replace(/[-[\]{}()*+?.,\\^$|#\s]/g,"\\$&"):null}).join("|"),"g"):null}},watch:{value:function(e){this.tags=Array.isArray(e)?e.slice(0):e||[]},hasInput:function(){this.hasInput||this.onBlur()}},methods:{addTag:function(e){var t=this,i=e||this.newTag.trim();if(i){if(!this.autocomplete){var n=this.separatorsAsRegExp;if(n&&i.match(n))return void i.split(n).map(function(e){return e.trim()}).filter(function(e){return 0!==e.length}).map(this.addTag)}(!!this.allowDuplicates||-1===this.tags.indexOf(i))&&this.beforeAdding(i)&&(1===this.maxtags&&(this.tags=[]),this.tags.push(this.createTag(i)),this.$emit("input",this.tags),this.$emit("add",i)),requestAnimationFrame(function(){t.newTag="",t.$emit("typing","")})}},getNormalizedTagText:function(e){return"object"===t(e)&&(e=c(e,this.field)),"".concat(e)},customOnBlur:function(e){this.autocomplete||this.addTag(),this.onBlur(e)},onSelect:function(e){var t=this;e&&(this.addTag(e),this.$nextTick(function(){t.newTag=""}))},removeTag:function(e,t){var i=this.tags.splice(e,1)[0];return this.$emit("input",this.tags),this.$emit("remove",i),t&&t.stopPropagation(),this.openOnFocus&&this.$refs.autocomplete&&this.$refs.autocomplete.focus(),i},removeLastTag:function(){this.tagsLength>0&&this.removeTag(this.tagsLength-1)},keydown:function(e){var t=e.key;if(-1===this.removeOnKeys.indexOf(t)||this.newTag.length||this.removeLastTag(),(!this.autocomplete||this.allowNew)&&this.confirmKeys.indexOf(t)>=0){if("Tab"!==t&&e.preventDefault(),"Enter"===t&&this.isComposing)return;this.addTag()}},onTyping:function(e){this.$emit("typing",e.trim())},emitInfiniteScroll:function(){this.$emit("infinite-scroll")}}},void 0,!1,void 0,void 0,void 0),x={install:function(e){!function(e,t){e.component(t.name,t)}(e,T)}};S=x,"undefined"!=typeof window&&window.Vue&&window.Vue.use(S),e.BTaginput=T,e.default=x,Object.defineProperty(e,"__esModule",{value:!0})});
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! Buefy v0.9.
|
|
1
|
+
/*! Buefy v0.9.14 | MIT License | github.com/buefy/buefy */
|
|
2
2
|
(function (global, factory) {
|
|
3
3
|
typeof exports === 'object' && typeof module !== 'undefined' ? factory(exports) :
|
|
4
4
|
typeof define === 'function' && define.amd ? define(['exports'], factory) :
|
|
@@ -135,7 +135,7 @@
|
|
|
135
135
|
defaultModalScroll: null,
|
|
136
136
|
defaultDatepickerMobileNative: true,
|
|
137
137
|
defaultTimepickerMobileNative: true,
|
|
138
|
-
defaultNoticeQueue:
|
|
138
|
+
defaultNoticeQueue: false,
|
|
139
139
|
defaultInputHasCounter: true,
|
|
140
140
|
defaultTaginputHasCounter: true,
|
|
141
141
|
defaultUseHtml5Validation: true,
|
|
@@ -2556,12 +2556,12 @@
|
|
|
2556
2556
|
return this.grouped || this.groupMultiline || this.hasAddons();
|
|
2557
2557
|
},
|
|
2558
2558
|
|
|
2559
|
-
/**
|
|
2560
|
-
* Correct Bulma class for the side of the addon or group.
|
|
2561
|
-
*
|
|
2562
|
-
* This is not kept like the others (is-small, etc.),
|
|
2563
|
-
* because since 'has-addons' is set automatically it
|
|
2564
|
-
* doesn't make sense to teach users what addons are exactly.
|
|
2559
|
+
/**
|
|
2560
|
+
* Correct Bulma class for the side of the addon or group.
|
|
2561
|
+
*
|
|
2562
|
+
* This is not kept like the others (is-small, etc.),
|
|
2563
|
+
* because since 'has-addons' is set automatically it
|
|
2564
|
+
* doesn't make sense to teach users what addons are exactly.
|
|
2565
2565
|
*/
|
|
2566
2566
|
newPosition: function newPosition() {
|
|
2567
2567
|
if (this.position === undefined) return;
|
|
@@ -2571,9 +2571,9 @@
|
|
|
2571
2571
|
if (this.position) return prefix + position[1];
|
|
2572
2572
|
},
|
|
2573
2573
|
|
|
2574
|
-
/**
|
|
2575
|
-
* Formatted message in case it's an array
|
|
2576
|
-
* (each element is separated by <br> tag)
|
|
2574
|
+
/**
|
|
2575
|
+
* Formatted message in case it's an array
|
|
2576
|
+
* (each element is separated by <br> tag)
|
|
2577
2577
|
*/
|
|
2578
2578
|
formattedMessage: function formattedMessage() {
|
|
2579
2579
|
if (this.parent && this.parent.hasInnerField) {
|
|
@@ -2643,22 +2643,22 @@
|
|
|
2643
2643
|
}
|
|
2644
2644
|
},
|
|
2645
2645
|
watch: {
|
|
2646
|
-
/**
|
|
2647
|
-
* Set internal type when prop change.
|
|
2646
|
+
/**
|
|
2647
|
+
* Set internal type when prop change.
|
|
2648
2648
|
*/
|
|
2649
2649
|
type: function type(value) {
|
|
2650
2650
|
this.newType = value;
|
|
2651
2651
|
},
|
|
2652
2652
|
|
|
2653
|
-
/**
|
|
2654
|
-
* Set internal message when prop change.
|
|
2653
|
+
/**
|
|
2654
|
+
* Set internal message when prop change.
|
|
2655
2655
|
*/
|
|
2656
2656
|
message: function message(value) {
|
|
2657
2657
|
this.newMessage = value;
|
|
2658
2658
|
},
|
|
2659
2659
|
|
|
2660
|
-
/**
|
|
2661
|
-
* Set parent message if we use Field in Field.
|
|
2660
|
+
/**
|
|
2661
|
+
* Set parent message if we use Field in Field.
|
|
2662
2662
|
*/
|
|
2663
2663
|
newMessage: function newMessage(value) {
|
|
2664
2664
|
if (this.parent && this.parent.hasInnerField) {
|
|
@@ -2673,11 +2673,11 @@
|
|
|
2673
2673
|
}
|
|
2674
2674
|
},
|
|
2675
2675
|
methods: {
|
|
2676
|
-
/**
|
|
2677
|
-
* Field has addons if there are more than one slot
|
|
2678
|
-
* (element / component) in the Field.
|
|
2679
|
-
* Or is grouped when prop is set.
|
|
2680
|
-
* Is a method to be called when component re-render.
|
|
2676
|
+
/**
|
|
2677
|
+
* Field has addons if there are more than one slot
|
|
2678
|
+
* (element / component) in the Field.
|
|
2679
|
+
* Or is grouped when prop is set.
|
|
2680
|
+
* Is a method to be called when component re-render.
|
|
2681
2681
|
*/
|
|
2682
2682
|
fieldType: function fieldType() {
|
|
2683
2683
|
if (this.grouped) return 'is-grouped';
|