buefy 0.9.26 → 0.9.28
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/README.md +3 -1
- package/dist/buefy.css +15904 -0
- package/dist/buefy.esm.js +17883 -0
- package/dist/buefy.esm.min.js +2 -0
- package/dist/buefy.js +17967 -0
- package/dist/buefy.min.css +1 -0
- package/dist/buefy.min.js +2 -0
- package/dist/cjs/Autocomplete-7a39c5ce.js +673 -0
- package/dist/cjs/Button-01827709.js +114 -0
- package/dist/cjs/CheckRadioMixin-c910f2ed.js +45 -0
- package/dist/cjs/Checkbox-43f54cc7.js +70 -0
- package/dist/cjs/Datepicker-680659bc.js +1679 -0
- package/dist/cjs/DropdownItem-422f8c34.js +559 -0
- package/dist/cjs/Field-4557b10c.js +315 -0
- package/dist/cjs/FormElementMixin-193a88b8.js +163 -0
- package/dist/cjs/Icon-78961800.js +189 -0
- package/dist/cjs/Image-c4bcd9b3.js +299 -0
- package/dist/cjs/InjectedChildMixin-d6bf7f91.js +135 -0
- package/dist/cjs/Input-e5a72d97.js +248 -0
- package/dist/cjs/Loading-6f2c7075.js +150 -0
- package/dist/cjs/MessageMixin-8d959514.js +146 -0
- package/dist/cjs/Modal-4cf07210.js +278 -0
- package/dist/cjs/NoticeMixin-01121bd2.js +154 -0
- package/dist/cjs/Pagination-d6b3fb85.js +413 -0
- package/dist/cjs/Select-2b3879bc.js +100 -0
- package/dist/cjs/SlotComponent-4fb48389.js +53 -0
- package/dist/cjs/TabbedChildMixin-907cad32.js +222 -0
- package/dist/cjs/Tag-437f65fb.js +154 -0
- package/dist/cjs/Timepicker-498fa02b.js +67 -0
- package/dist/cjs/TimepickerMixin-6c1a4ab4.js +661 -0
- package/dist/cjs/Tooltip-c1df7ee3.js +370 -0
- package/dist/cjs/_rollupPluginBabelHelpers-8b2e54ad.js +365 -0
- package/dist/cjs/autocomplete.js +22 -0
- package/dist/cjs/breadcrumb.js +139 -0
- package/dist/cjs/button.js +20 -0
- package/dist/cjs/carousel.js +662 -0
- package/dist/cjs/checkbox.js +86 -0
- package/dist/cjs/clockpicker.js +461 -0
- package/dist/cjs/collapse.js +128 -0
- package/dist/cjs/colorpicker.js +23 -0
- package/dist/cjs/config-8cfb5a4a.js +81 -0
- package/dist/cjs/config.js +18 -0
- package/dist/cjs/datepicker.js +27 -0
- package/dist/cjs/datetimepicker.js +377 -0
- package/dist/cjs/dialog.js +308 -0
- package/dist/cjs/dropdown.js +23 -0
- package/dist/cjs/field.js +18 -0
- package/dist/cjs/helpers.js +375 -0
- package/dist/cjs/icon.js +19 -0
- package/dist/cjs/image.js +19 -0
- package/dist/cjs/index-99d1c930.js +1633 -0
- package/dist/cjs/index.js +216 -0
- package/dist/cjs/input.js +21 -0
- package/dist/cjs/loading.js +38 -0
- package/dist/cjs/menu.js +304 -0
- package/dist/cjs/message.js +67 -0
- package/dist/cjs/modal.js +59 -0
- package/dist/cjs/navbar.js +679 -0
- package/dist/cjs/notification.js +181 -0
- package/dist/cjs/numberinput.js +278 -0
- package/dist/cjs/pagination.js +22 -0
- package/dist/cjs/plugins-7f41b028.js +94 -0
- package/dist/cjs/progress.js +239 -0
- package/dist/cjs/radio.js +130 -0
- package/dist/cjs/rate.js +156 -0
- package/dist/cjs/select.js +21 -0
- package/dist/cjs/sidebar.js +303 -0
- package/dist/cjs/skeleton.js +111 -0
- package/dist/cjs/slider.js +603 -0
- package/dist/cjs/snackbar.js +132 -0
- package/dist/cjs/ssr-20dba236.js +10 -0
- package/dist/cjs/steps.js +278 -0
- package/dist/cjs/switch.js +139 -0
- package/dist/cjs/table.js +1695 -0
- package/dist/cjs/tabs.js +214 -0
- package/dist/cjs/tag.js +70 -0
- package/dist/cjs/taginput.js +331 -0
- package/dist/cjs/timepicker.js +28 -0
- package/dist/cjs/toast.js +106 -0
- package/dist/cjs/tooltip.js +19 -0
- package/dist/cjs/trapFocus-261420b0.js +49 -0
- package/dist/cjs/upload.js +205 -0
- package/dist/components/autocomplete/index.js +1620 -0
- package/dist/components/autocomplete/index.min.js +2 -0
- package/dist/components/breadcrumb/index.js +297 -0
- package/dist/components/breadcrumb/index.min.js +2 -0
- package/dist/components/button/index.js +569 -0
- package/dist/components/button/index.min.js +2 -0
- package/dist/components/carousel/index.js +1629 -0
- package/dist/components/carousel/index.min.js +2 -0
- package/dist/components/checkbox/index.js +279 -0
- package/dist/components/checkbox/index.min.js +2 -0
- package/dist/components/clockpicker/index.js +3131 -0
- package/dist/components/clockpicker/index.min.js +2 -0
- package/dist/components/collapse/index.js +217 -0
- package/dist/components/collapse/index.min.js +2 -0
- package/dist/components/colorpicker/index.js +4249 -0
- package/dist/components/colorpicker/index.min.js +2 -0
- package/dist/components/datepicker/index.js +3845 -0
- package/dist/components/datepicker/index.min.js +2 -0
- package/dist/components/datetimepicker/index.js +4902 -0
- package/dist/components/datetimepicker/index.min.js +2 -0
- package/dist/components/dialog/index.js +1168 -0
- package/dist/components/dialog/index.min.js +2 -0
- package/dist/components/dropdown/index.js +1043 -0
- package/dist/components/dropdown/index.min.js +2 -0
- package/dist/components/field/index.js +511 -0
- package/dist/components/field/index.min.js +2 -0
- package/dist/components/icon/index.js +463 -0
- package/dist/components/icon/index.min.js +2 -0
- package/dist/components/image/index.js +513 -0
- package/dist/components/image/index.min.js +2 -0
- package/dist/components/input/index.js +862 -0
- package/dist/components/input/index.min.js +2 -0
- package/dist/components/loading/index.js +366 -0
- package/dist/components/loading/index.min.js +2 -0
- package/dist/components/menu/index.js +748 -0
- package/dist/components/menu/index.min.js +2 -0
- package/dist/components/message/index.js +650 -0
- package/dist/components/message/index.min.js +2 -0
- package/dist/components/modal/index.js +624 -0
- package/dist/components/modal/index.min.js +2 -0
- package/dist/components/navbar/index.js +805 -0
- package/dist/components/navbar/index.min.js +2 -0
- package/dist/components/notification/index.js +923 -0
- package/dist/components/notification/index.min.js +2 -0
- package/dist/components/numberinput/index.js +1119 -0
- package/dist/components/numberinput/index.min.js +2 -0
- package/dist/components/pagination/index.js +868 -0
- package/dist/components/pagination/index.min.js +2 -0
- package/dist/components/progress/index.js +621 -0
- package/dist/components/progress/index.min.js +2 -0
- package/dist/components/radio/index.js +260 -0
- package/dist/components/radio/index.min.js +2 -0
- package/dist/components/rate/index.js +600 -0
- package/dist/components/rate/index.min.js +2 -0
- package/dist/components/select/index.js +715 -0
- package/dist/components/select/index.min.js +2 -0
- package/dist/components/sidebar/index.js +467 -0
- package/dist/components/sidebar/index.min.js +2 -0
- package/dist/components/skeleton/index.js +200 -0
- package/dist/components/skeleton/index.min.js +2 -0
- package/dist/components/slider/index.js +1264 -0
- package/dist/components/slider/index.min.js +2 -0
- package/dist/components/snackbar/index.js +527 -0
- package/dist/components/snackbar/index.min.js +2 -0
- package/dist/components/steps/index.js +1180 -0
- package/dist/components/steps/index.min.js +2 -0
- package/dist/components/switch/index.js +297 -0
- package/dist/components/switch/index.min.js +2 -0
- package/dist/components/table/index.js +3480 -0
- package/dist/components/table/index.min.js +2 -0
- package/dist/components/tabs/index.js +1116 -0
- package/dist/components/tabs/index.min.js +2 -0
- package/dist/components/tag/index.js +307 -0
- package/dist/components/tag/index.min.js +2 -0
- package/dist/components/taginput/index.js +2104 -0
- package/dist/components/taginput/index.min.js +2 -0
- package/dist/components/timepicker/index.js +2843 -0
- package/dist/components/timepicker/index.min.js +2 -0
- package/dist/components/toast/index.js +501 -0
- package/dist/components/toast/index.min.js +2 -0
- package/dist/components/tooltip/index.js +630 -0
- package/dist/components/tooltip/index.min.js +2 -0
- package/dist/components/upload/index.js +525 -0
- package/dist/components/upload/index.min.js +2 -0
- package/dist/esm/Autocomplete-1a6e8770.js +671 -0
- package/dist/esm/Button-521f6efc.js +112 -0
- package/dist/esm/CheckRadioMixin-e726a83c.js +43 -0
- package/dist/esm/Checkbox-1d02686e.js +68 -0
- package/dist/esm/Datepicker-0ae1e826.js +1677 -0
- package/dist/esm/DropdownItem-55682322.js +556 -0
- package/dist/esm/Field-3ceba31e.js +313 -0
- package/dist/esm/FormElementMixin-b223d3c7.js +161 -0
- package/dist/esm/Icon-60d47b31.js +187 -0
- package/dist/esm/Image-75808acb.js +297 -0
- package/dist/esm/InjectedChildMixin-b4220787.js +130 -0
- package/dist/esm/Input-20612b63.js +246 -0
- package/dist/esm/Loading-ae028ea5.js +148 -0
- package/dist/esm/MessageMixin-d577a9f5.js +144 -0
- package/dist/esm/Modal-7da7641f.js +276 -0
- package/dist/esm/NoticeMixin-bd6f61d9.js +152 -0
- package/dist/esm/Pagination-68f12c1e.js +409 -0
- package/dist/esm/Select-97781d4e.js +98 -0
- package/dist/esm/SlotComponent-8871a20f.js +51 -0
- package/dist/esm/TabbedChildMixin-bcb13767.js +219 -0
- package/dist/esm/Tag-6365aa46.js +152 -0
- package/dist/esm/Timepicker-38480bbc.js +65 -0
- package/dist/esm/TimepickerMixin-d736b0a9.js +659 -0
- package/dist/esm/Tooltip-d98a769c.js +368 -0
- package/dist/esm/_rollupPluginBabelHelpers-df313029.js +350 -0
- package/dist/esm/autocomplete.js +18 -0
- package/dist/esm/breadcrumb.js +133 -0
- package/dist/esm/button.js +16 -0
- package/dist/esm/carousel.js +655 -0
- package/dist/esm/checkbox.js +81 -0
- package/dist/esm/clockpicker.js +456 -0
- package/dist/esm/collapse.js +123 -0
- package/dist/esm/colorpicker.js +14 -0
- package/dist/esm/config-e7d4b9c2.js +78 -0
- package/dist/esm/config.js +14 -0
- package/dist/esm/datepicker.js +23 -0
- package/dist/esm/datetimepicker.js +372 -0
- package/dist/esm/dialog.js +302 -0
- package/dist/esm/dropdown.js +18 -0
- package/dist/esm/field.js +14 -0
- package/dist/esm/helpers.js +348 -0
- package/dist/esm/icon.js +15 -0
- package/dist/esm/image.js +15 -0
- package/dist/esm/index-903f63ea.js +1629 -0
- package/dist/esm/index.js +182 -0
- package/dist/esm/input.js +17 -0
- package/dist/esm/loading.js +33 -0
- package/dist/esm/menu.js +297 -0
- package/dist/esm/message.js +62 -0
- package/dist/esm/modal.js +54 -0
- package/dist/esm/navbar.js +672 -0
- package/dist/esm/notification.js +175 -0
- package/dist/esm/numberinput.js +273 -0
- package/dist/esm/pagination.js +17 -0
- package/dist/esm/plugins-218aea86.js +89 -0
- package/dist/esm/progress.js +233 -0
- package/dist/esm/radio.js +124 -0
- package/dist/esm/rate.js +151 -0
- package/dist/esm/select.js +17 -0
- package/dist/esm/sidebar.js +298 -0
- package/dist/esm/skeleton.js +106 -0
- package/dist/esm/slider.js +597 -0
- package/dist/esm/snackbar.js +126 -0
- package/dist/esm/ssr-b847d137.js +7 -0
- package/dist/esm/steps.js +272 -0
- package/dist/esm/switch.js +134 -0
- package/dist/esm/table.js +1689 -0
- package/dist/esm/tabs.js +208 -0
- package/dist/esm/tag.js +65 -0
- package/dist/esm/taginput.js +326 -0
- package/dist/esm/timepicker.js +24 -0
- package/dist/esm/toast.js +100 -0
- package/dist/esm/tooltip.js +15 -0
- package/dist/esm/trapFocus-f0736873.js +47 -0
- package/dist/esm/upload.js +200 -0
- package/dist/vetur/attributes.json +3238 -0
- package/dist/vetur/tags.json +1183 -0
- package/package.json +3 -3
- package/src/components/autocomplete/Autocomplete.spec.js +16 -0
- package/src/components/autocomplete/Autocomplete.vue +9 -3
- package/src/components/colorpicker/ColorpickerHSLRepresentationSquare.vue +2 -0
- package/src/components/colorpicker/ColorpickerHSLRepresentationTriangle.vue +2 -0
- package/src/components/dropdown/Dropdown.vue +51 -3
- package/src/components/numberinput/Numberinput.vue +4 -0
- package/src/components/sidebar/Sidebar.vue +1 -0
- package/src/components/slider/Slider.vue +7 -2
- package/src/components/slider/SliderThumb.vue +8 -0
- package/src/components/table/Table.vue +4 -1
- package/src/components/table/TableColumn.spec.js +51 -0
- package/src/components/table/TableColumn.vue +8 -1
- package/src/components/taginput/Taginput.vue +7 -2
- package/src/components/tooltip/Tooltip.vue +10 -3
- package/src/scss/components/_dropdown.scss +4 -2
|
@@ -0,0 +1,132 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
|
+
|
|
5
|
+
var config = require('./config-8cfb5a4a.js');
|
|
6
|
+
var NoticeMixin = require('./NoticeMixin-01121bd2.js');
|
|
7
|
+
var plugins = require('./plugins-7f41b028.js');
|
|
8
|
+
var helpers = require('./helpers.js');
|
|
9
|
+
require('./_rollupPluginBabelHelpers-8b2e54ad.js');
|
|
10
|
+
|
|
11
|
+
//
|
|
12
|
+
var script = {
|
|
13
|
+
name: 'BSnackbar',
|
|
14
|
+
mixins: [NoticeMixin.NoticeMixin],
|
|
15
|
+
props: {
|
|
16
|
+
actionText: {
|
|
17
|
+
type: String,
|
|
18
|
+
default: 'OK'
|
|
19
|
+
},
|
|
20
|
+
onAction: {
|
|
21
|
+
type: Function,
|
|
22
|
+
default: function _default() {}
|
|
23
|
+
},
|
|
24
|
+
cancelText: {
|
|
25
|
+
type: String | null,
|
|
26
|
+
default: null
|
|
27
|
+
}
|
|
28
|
+
},
|
|
29
|
+
data: function data() {
|
|
30
|
+
return {
|
|
31
|
+
newDuration: this.duration || config.config.defaultSnackbarDuration
|
|
32
|
+
};
|
|
33
|
+
},
|
|
34
|
+
methods: {
|
|
35
|
+
/**
|
|
36
|
+
* Click listener.
|
|
37
|
+
* Call action prop before closing (from Mixin).
|
|
38
|
+
*/
|
|
39
|
+
action: function action() {
|
|
40
|
+
this.onAction();
|
|
41
|
+
this.close();
|
|
42
|
+
}
|
|
43
|
+
}
|
|
44
|
+
};
|
|
45
|
+
|
|
46
|
+
/* script */
|
|
47
|
+
const __vue_script__ = script;
|
|
48
|
+
|
|
49
|
+
/* template */
|
|
50
|
+
var __vue_render__ = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('transition',{attrs:{"enter-active-class":_vm.transition.enter,"leave-active-class":_vm.transition.leave}},[_c('div',{directives:[{name:"show",rawName:"v-show",value:(_vm.isActive),expression:"isActive"}],staticClass:"snackbar",class:[_vm.type,_vm.position],attrs:{"role":_vm.actionText ? 'alertdialog' : 'alert'},on:{"mouseenter":_vm.pause,"mouseleave":_vm.removePause}},[(_vm.$slots.default)?[_vm._t("default")]:[_c('div',{staticClass:"text",domProps:{"innerHTML":_vm._s(_vm.message)}})],(_vm.cancelText)?_c('div',{staticClass:"action is-light is-cancel",on:{"click":_vm.close}},[_c('button',{staticClass:"button"},[_vm._v(_vm._s(_vm.cancelText))])]):_vm._e(),(_vm.actionText)?_c('div',{staticClass:"action",class:_vm.type,on:{"click":_vm.action}},[_c('button',{staticClass:"button"},[_vm._v(_vm._s(_vm.actionText))])]):_vm._e()],2)])};
|
|
51
|
+
var __vue_staticRenderFns__ = [];
|
|
52
|
+
|
|
53
|
+
/* style */
|
|
54
|
+
const __vue_inject_styles__ = undefined;
|
|
55
|
+
/* scoped */
|
|
56
|
+
const __vue_scope_id__ = undefined;
|
|
57
|
+
/* module identifier */
|
|
58
|
+
const __vue_module_identifier__ = undefined;
|
|
59
|
+
/* functional template */
|
|
60
|
+
const __vue_is_functional_template__ = false;
|
|
61
|
+
/* style inject */
|
|
62
|
+
|
|
63
|
+
/* style inject SSR */
|
|
64
|
+
|
|
65
|
+
/* style inject shadow dom */
|
|
66
|
+
|
|
67
|
+
|
|
68
|
+
|
|
69
|
+
const __vue_component__ = /*#__PURE__*/plugins.normalizeComponent(
|
|
70
|
+
{ render: __vue_render__, staticRenderFns: __vue_staticRenderFns__ },
|
|
71
|
+
__vue_inject_styles__,
|
|
72
|
+
__vue_script__,
|
|
73
|
+
__vue_scope_id__,
|
|
74
|
+
__vue_is_functional_template__,
|
|
75
|
+
__vue_module_identifier__,
|
|
76
|
+
false,
|
|
77
|
+
undefined,
|
|
78
|
+
undefined,
|
|
79
|
+
undefined
|
|
80
|
+
);
|
|
81
|
+
|
|
82
|
+
var Snackbar = __vue_component__;
|
|
83
|
+
|
|
84
|
+
var localVueInstance;
|
|
85
|
+
var SnackbarProgrammatic = {
|
|
86
|
+
open: function open(params) {
|
|
87
|
+
var parent;
|
|
88
|
+
if (typeof params === 'string') {
|
|
89
|
+
params = {
|
|
90
|
+
message: params
|
|
91
|
+
};
|
|
92
|
+
}
|
|
93
|
+
var defaultParam = {
|
|
94
|
+
type: 'is-success',
|
|
95
|
+
position: config.config.defaultSnackbarPosition || 'is-bottom-right',
|
|
96
|
+
queue: true
|
|
97
|
+
};
|
|
98
|
+
if (params.parent) {
|
|
99
|
+
parent = params.parent;
|
|
100
|
+
delete params.parent;
|
|
101
|
+
}
|
|
102
|
+
var slot;
|
|
103
|
+
if (Array.isArray(params.message)) {
|
|
104
|
+
slot = params.message;
|
|
105
|
+
delete params.message;
|
|
106
|
+
}
|
|
107
|
+
var propsData = helpers.merge(defaultParam, params);
|
|
108
|
+
var vm = typeof window !== 'undefined' && window.Vue ? window.Vue : localVueInstance || config.VueInstance;
|
|
109
|
+
var SnackbarComponent = vm.extend(Snackbar);
|
|
110
|
+
var component = new SnackbarComponent({
|
|
111
|
+
parent: parent,
|
|
112
|
+
el: document.createElement('div'),
|
|
113
|
+
propsData: propsData
|
|
114
|
+
});
|
|
115
|
+
if (slot) {
|
|
116
|
+
component.$slots.default = slot;
|
|
117
|
+
component.$forceUpdate();
|
|
118
|
+
}
|
|
119
|
+
return component;
|
|
120
|
+
}
|
|
121
|
+
};
|
|
122
|
+
var Plugin = {
|
|
123
|
+
install: function install(Vue) {
|
|
124
|
+
localVueInstance = Vue;
|
|
125
|
+
plugins.registerComponentProgrammatic(Vue, 'snackbar', SnackbarProgrammatic);
|
|
126
|
+
}
|
|
127
|
+
};
|
|
128
|
+
plugins.use(Plugin);
|
|
129
|
+
|
|
130
|
+
exports.BSnackbar = Snackbar;
|
|
131
|
+
exports.SnackbarProgrammatic = SnackbarProgrammatic;
|
|
132
|
+
exports["default"] = Plugin;
|
|
@@ -0,0 +1,278 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
|
+
|
|
5
|
+
var _rollupPluginBabelHelpers = require('./_rollupPluginBabelHelpers-8b2e54ad.js');
|
|
6
|
+
var Icon = require('./Icon-78961800.js');
|
|
7
|
+
var TabbedChildMixin = require('./TabbedChildMixin-907cad32.js');
|
|
8
|
+
var config = require('./config-8cfb5a4a.js');
|
|
9
|
+
var plugins = require('./plugins-7f41b028.js');
|
|
10
|
+
require('./helpers.js');
|
|
11
|
+
require('./SlotComponent-4fb48389.js');
|
|
12
|
+
require('./InjectedChildMixin-d6bf7f91.js');
|
|
13
|
+
|
|
14
|
+
var script$1 = {
|
|
15
|
+
name: 'BSteps',
|
|
16
|
+
components: _rollupPluginBabelHelpers._defineProperty({}, Icon.Icon.name, Icon.Icon),
|
|
17
|
+
mixins: [TabbedChildMixin.TabbedMixin('step')],
|
|
18
|
+
props: {
|
|
19
|
+
type: [String, Object],
|
|
20
|
+
iconPack: String,
|
|
21
|
+
iconPrev: {
|
|
22
|
+
type: String,
|
|
23
|
+
default: function _default() {
|
|
24
|
+
return config.config.defaultIconPrev;
|
|
25
|
+
}
|
|
26
|
+
},
|
|
27
|
+
iconNext: {
|
|
28
|
+
type: String,
|
|
29
|
+
default: function _default() {
|
|
30
|
+
return config.config.defaultIconNext;
|
|
31
|
+
}
|
|
32
|
+
},
|
|
33
|
+
hasNavigation: {
|
|
34
|
+
type: Boolean,
|
|
35
|
+
default: true
|
|
36
|
+
},
|
|
37
|
+
labelPosition: {
|
|
38
|
+
type: String,
|
|
39
|
+
validator: function validator(value) {
|
|
40
|
+
return ['bottom', 'right', 'left'].indexOf(value) > -1;
|
|
41
|
+
},
|
|
42
|
+
default: 'bottom'
|
|
43
|
+
},
|
|
44
|
+
rounded: {
|
|
45
|
+
type: Boolean,
|
|
46
|
+
default: true
|
|
47
|
+
},
|
|
48
|
+
mobileMode: {
|
|
49
|
+
type: String,
|
|
50
|
+
validator: function validator(value) {
|
|
51
|
+
return ['minimalist', 'compact'].indexOf(value) > -1;
|
|
52
|
+
},
|
|
53
|
+
default: 'minimalist'
|
|
54
|
+
},
|
|
55
|
+
ariaNextLabel: String,
|
|
56
|
+
ariaPreviousLabel: String
|
|
57
|
+
},
|
|
58
|
+
computed: {
|
|
59
|
+
// Override mixin implementation to always have a value
|
|
60
|
+
activeItem: function activeItem() {
|
|
61
|
+
var _this = this;
|
|
62
|
+
return this.childItems.filter(function (i) {
|
|
63
|
+
return i.value === _this.activeId;
|
|
64
|
+
})[0] || this.items[0];
|
|
65
|
+
},
|
|
66
|
+
wrapperClasses: function wrapperClasses() {
|
|
67
|
+
return [this.size, _rollupPluginBabelHelpers._defineProperty({
|
|
68
|
+
'is-vertical': this.vertical
|
|
69
|
+
}, this.position, this.position && this.vertical)];
|
|
70
|
+
},
|
|
71
|
+
mainClasses: function mainClasses() {
|
|
72
|
+
return [this.type, _rollupPluginBabelHelpers._defineProperty({
|
|
73
|
+
'has-label-right': this.labelPosition === 'right',
|
|
74
|
+
'has-label-left': this.labelPosition === 'left',
|
|
75
|
+
'is-animated': this.animated,
|
|
76
|
+
'is-rounded': this.rounded
|
|
77
|
+
}, "mobile-".concat(this.mobileMode), this.mobileMode !== null)];
|
|
78
|
+
},
|
|
79
|
+
/**
|
|
80
|
+
* Check if previous button is available.
|
|
81
|
+
*/
|
|
82
|
+
hasPrev: function hasPrev() {
|
|
83
|
+
return this.prevItemIdx !== null;
|
|
84
|
+
},
|
|
85
|
+
/**
|
|
86
|
+
* Retrieves the next visible item index
|
|
87
|
+
*/
|
|
88
|
+
nextItemIdx: function nextItemIdx() {
|
|
89
|
+
var idx = this.activeItem ? this.items.indexOf(this.activeItem) : 0;
|
|
90
|
+
return this.getNextItemIdx(idx);
|
|
91
|
+
},
|
|
92
|
+
/**
|
|
93
|
+
* Retrieves the next visible item
|
|
94
|
+
*/
|
|
95
|
+
nextItem: function nextItem() {
|
|
96
|
+
var nextItem = null;
|
|
97
|
+
if (this.nextItemIdx !== null) {
|
|
98
|
+
nextItem = this.items[this.nextItemIdx];
|
|
99
|
+
}
|
|
100
|
+
return nextItem;
|
|
101
|
+
},
|
|
102
|
+
/**
|
|
103
|
+
* Retrieves the next visible item index
|
|
104
|
+
*/
|
|
105
|
+
prevItemIdx: function prevItemIdx() {
|
|
106
|
+
if (!this.activeItem) {
|
|
107
|
+
return null;
|
|
108
|
+
}
|
|
109
|
+
var idx = this.items.indexOf(this.activeItem);
|
|
110
|
+
return this.getPrevItemIdx(idx);
|
|
111
|
+
},
|
|
112
|
+
/**
|
|
113
|
+
* Retrieves the previous visible item
|
|
114
|
+
*/
|
|
115
|
+
prevItem: function prevItem() {
|
|
116
|
+
if (!this.activeItem) {
|
|
117
|
+
return null;
|
|
118
|
+
}
|
|
119
|
+
var prevItem = null;
|
|
120
|
+
if (this.prevItemIdx !== null) {
|
|
121
|
+
prevItem = this.items[this.prevItemIdx];
|
|
122
|
+
}
|
|
123
|
+
return prevItem;
|
|
124
|
+
},
|
|
125
|
+
/**
|
|
126
|
+
* Check if next button is available.
|
|
127
|
+
*/
|
|
128
|
+
hasNext: function hasNext() {
|
|
129
|
+
return this.nextItemIdx !== null;
|
|
130
|
+
},
|
|
131
|
+
navigationProps: function navigationProps() {
|
|
132
|
+
return {
|
|
133
|
+
previous: {
|
|
134
|
+
disabled: !this.hasPrev,
|
|
135
|
+
action: this.prev
|
|
136
|
+
},
|
|
137
|
+
next: {
|
|
138
|
+
disabled: !this.hasNext,
|
|
139
|
+
action: this.next
|
|
140
|
+
}
|
|
141
|
+
};
|
|
142
|
+
}
|
|
143
|
+
},
|
|
144
|
+
methods: {
|
|
145
|
+
/**
|
|
146
|
+
* Return if the step should be clickable or not.
|
|
147
|
+
*/
|
|
148
|
+
isItemClickable: function isItemClickable(stepItem) {
|
|
149
|
+
if (stepItem.clickable === undefined) {
|
|
150
|
+
return stepItem.index < this.activeItem.index;
|
|
151
|
+
}
|
|
152
|
+
return stepItem.clickable;
|
|
153
|
+
},
|
|
154
|
+
/**
|
|
155
|
+
* Previous button click listener.
|
|
156
|
+
*/
|
|
157
|
+
prev: function prev() {
|
|
158
|
+
if (this.hasPrev) {
|
|
159
|
+
this.activeId = this.prevItem.value;
|
|
160
|
+
}
|
|
161
|
+
},
|
|
162
|
+
/**
|
|
163
|
+
* Previous button click listener.
|
|
164
|
+
*/
|
|
165
|
+
next: function next() {
|
|
166
|
+
if (this.hasNext) {
|
|
167
|
+
this.activeId = this.nextItem.value;
|
|
168
|
+
}
|
|
169
|
+
}
|
|
170
|
+
}
|
|
171
|
+
};
|
|
172
|
+
|
|
173
|
+
/* script */
|
|
174
|
+
const __vue_script__$1 = script$1;
|
|
175
|
+
|
|
176
|
+
/* template */
|
|
177
|
+
var __vue_render__ = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('div',{staticClass:"b-steps",class:_vm.wrapperClasses},[_c('nav',{staticClass:"steps",class:_vm.mainClasses},[_c('ul',{staticClass:"step-items"},_vm._l((_vm.items),function(childItem){return _c('li',{directives:[{name:"show",rawName:"v-show",value:(childItem.visible),expression:"childItem.visible"}],key:childItem.value,staticClass:"step-item",class:[childItem.type || _vm.type, childItem.headerClass, {
|
|
178
|
+
'is-active': childItem.isActive,
|
|
179
|
+
'is-previous': _vm.activeItem.index > childItem.index
|
|
180
|
+
}]},[_c('a',{staticClass:"step-link",class:{'is-clickable': _vm.isItemClickable(childItem)},on:{"click":function($event){_vm.isItemClickable(childItem) && _vm.childClick(childItem);}}},[_c('div',{staticClass:"step-marker"},[(childItem.icon)?_c('b-icon',{attrs:{"icon":childItem.icon,"pack":childItem.iconPack,"size":_vm.size}}):(childItem.step)?_c('span',[_vm._v(_vm._s(childItem.step))]):_vm._e()],1),_c('div',{staticClass:"step-details"},[_c('span',{staticClass:"step-title"},[_vm._v(_vm._s(childItem.label))])])])])}),0)]),_c('section',{staticClass:"step-content",class:{'is-transitioning': _vm.isTransitioning}},[_vm._t("default")],2),_vm._t("navigation",[(_vm.hasNavigation)?_c('nav',{staticClass:"step-navigation"},[_c('a',{staticClass:"pagination-previous",attrs:{"role":"button","disabled":_vm.navigationProps.previous.disabled,"aria-label":_vm.ariaPreviousLabel},on:{"click":function($event){$event.preventDefault();return _vm.navigationProps.previous.action($event)}}},[_c('b-icon',{attrs:{"icon":_vm.iconPrev,"pack":_vm.iconPack,"both":"","aria-hidden":"true"}})],1),_c('a',{staticClass:"pagination-next",attrs:{"role":"button","disabled":_vm.navigationProps.next.disabled,"aria-label":_vm.ariaNextLabel},on:{"click":function($event){$event.preventDefault();return _vm.navigationProps.next.action($event)}}},[_c('b-icon',{attrs:{"icon":_vm.iconNext,"pack":_vm.iconPack,"both":"","aria-hidden":"true"}})],1)]):_vm._e()],{"previous":_vm.navigationProps.previous,"next":_vm.navigationProps.next})],2)};
|
|
181
|
+
var __vue_staticRenderFns__ = [];
|
|
182
|
+
|
|
183
|
+
/* style */
|
|
184
|
+
const __vue_inject_styles__$1 = undefined;
|
|
185
|
+
/* scoped */
|
|
186
|
+
const __vue_scope_id__$1 = undefined;
|
|
187
|
+
/* module identifier */
|
|
188
|
+
const __vue_module_identifier__$1 = undefined;
|
|
189
|
+
/* functional template */
|
|
190
|
+
const __vue_is_functional_template__$1 = false;
|
|
191
|
+
/* style inject */
|
|
192
|
+
|
|
193
|
+
/* style inject SSR */
|
|
194
|
+
|
|
195
|
+
/* style inject shadow dom */
|
|
196
|
+
|
|
197
|
+
|
|
198
|
+
|
|
199
|
+
const __vue_component__$1 = /*#__PURE__*/plugins.normalizeComponent(
|
|
200
|
+
{ render: __vue_render__, staticRenderFns: __vue_staticRenderFns__ },
|
|
201
|
+
__vue_inject_styles__$1,
|
|
202
|
+
__vue_script__$1,
|
|
203
|
+
__vue_scope_id__$1,
|
|
204
|
+
__vue_is_functional_template__$1,
|
|
205
|
+
__vue_module_identifier__$1,
|
|
206
|
+
false,
|
|
207
|
+
undefined,
|
|
208
|
+
undefined,
|
|
209
|
+
undefined
|
|
210
|
+
);
|
|
211
|
+
|
|
212
|
+
var Steps = __vue_component__$1;
|
|
213
|
+
|
|
214
|
+
var script = {
|
|
215
|
+
name: 'BStepItem',
|
|
216
|
+
mixins: [TabbedChildMixin.TabbedChildMixin('step')],
|
|
217
|
+
props: {
|
|
218
|
+
step: [String, Number],
|
|
219
|
+
type: [String, Object],
|
|
220
|
+
clickable: {
|
|
221
|
+
type: Boolean,
|
|
222
|
+
default: undefined
|
|
223
|
+
}
|
|
224
|
+
},
|
|
225
|
+
data: function data() {
|
|
226
|
+
return {
|
|
227
|
+
elementClass: 'step-item'
|
|
228
|
+
};
|
|
229
|
+
}
|
|
230
|
+
};
|
|
231
|
+
|
|
232
|
+
/* script */
|
|
233
|
+
const __vue_script__ = script;
|
|
234
|
+
|
|
235
|
+
/* template */
|
|
236
|
+
|
|
237
|
+
/* style */
|
|
238
|
+
const __vue_inject_styles__ = undefined;
|
|
239
|
+
/* scoped */
|
|
240
|
+
const __vue_scope_id__ = undefined;
|
|
241
|
+
/* module identifier */
|
|
242
|
+
const __vue_module_identifier__ = undefined;
|
|
243
|
+
/* functional template */
|
|
244
|
+
const __vue_is_functional_template__ = undefined;
|
|
245
|
+
/* style inject */
|
|
246
|
+
|
|
247
|
+
/* style inject SSR */
|
|
248
|
+
|
|
249
|
+
/* style inject shadow dom */
|
|
250
|
+
|
|
251
|
+
|
|
252
|
+
|
|
253
|
+
const __vue_component__ = /*#__PURE__*/plugins.normalizeComponent(
|
|
254
|
+
{},
|
|
255
|
+
__vue_inject_styles__,
|
|
256
|
+
__vue_script__,
|
|
257
|
+
__vue_scope_id__,
|
|
258
|
+
__vue_is_functional_template__,
|
|
259
|
+
__vue_module_identifier__,
|
|
260
|
+
false,
|
|
261
|
+
undefined,
|
|
262
|
+
undefined,
|
|
263
|
+
undefined
|
|
264
|
+
);
|
|
265
|
+
|
|
266
|
+
var StepItem = __vue_component__;
|
|
267
|
+
|
|
268
|
+
var Plugin = {
|
|
269
|
+
install: function install(Vue) {
|
|
270
|
+
plugins.registerComponent(Vue, Steps);
|
|
271
|
+
plugins.registerComponent(Vue, StepItem);
|
|
272
|
+
}
|
|
273
|
+
};
|
|
274
|
+
plugins.use(Plugin);
|
|
275
|
+
|
|
276
|
+
exports.BStepItem = StepItem;
|
|
277
|
+
exports.BSteps = Steps;
|
|
278
|
+
exports["default"] = Plugin;
|
|
@@ -0,0 +1,139 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
|
+
|
|
5
|
+
var config = require('./config-8cfb5a4a.js');
|
|
6
|
+
var plugins = require('./plugins-7f41b028.js');
|
|
7
|
+
|
|
8
|
+
//
|
|
9
|
+
var script = {
|
|
10
|
+
name: 'BSwitch',
|
|
11
|
+
props: {
|
|
12
|
+
value: [String, Number, Boolean, Function, Object, Array, Date],
|
|
13
|
+
nativeValue: [String, Number, Boolean, Function, Object, Array, Date],
|
|
14
|
+
disabled: Boolean,
|
|
15
|
+
type: String,
|
|
16
|
+
passiveType: String,
|
|
17
|
+
name: String,
|
|
18
|
+
required: Boolean,
|
|
19
|
+
size: String,
|
|
20
|
+
ariaLabelledby: String,
|
|
21
|
+
trueValue: {
|
|
22
|
+
type: [String, Number, Boolean, Function, Object, Array, Date],
|
|
23
|
+
default: true
|
|
24
|
+
},
|
|
25
|
+
falseValue: {
|
|
26
|
+
type: [String, Number, Boolean, Function, Object, Array, Date],
|
|
27
|
+
default: false
|
|
28
|
+
},
|
|
29
|
+
rounded: {
|
|
30
|
+
type: Boolean,
|
|
31
|
+
default: function _default() {
|
|
32
|
+
return config.config.defaultSwitchRounded;
|
|
33
|
+
}
|
|
34
|
+
},
|
|
35
|
+
outlined: {
|
|
36
|
+
type: Boolean,
|
|
37
|
+
default: false
|
|
38
|
+
},
|
|
39
|
+
leftLabel: {
|
|
40
|
+
type: Boolean,
|
|
41
|
+
default: false
|
|
42
|
+
}
|
|
43
|
+
},
|
|
44
|
+
data: function data() {
|
|
45
|
+
return {
|
|
46
|
+
newValue: this.value,
|
|
47
|
+
isMouseDown: false
|
|
48
|
+
};
|
|
49
|
+
},
|
|
50
|
+
computed: {
|
|
51
|
+
computedValue: {
|
|
52
|
+
get: function get() {
|
|
53
|
+
return this.newValue;
|
|
54
|
+
},
|
|
55
|
+
set: function set(value) {
|
|
56
|
+
this.newValue = value;
|
|
57
|
+
this.$emit('input', value);
|
|
58
|
+
}
|
|
59
|
+
},
|
|
60
|
+
newClass: function newClass() {
|
|
61
|
+
return [this.size, {
|
|
62
|
+
'is-disabled': this.disabled,
|
|
63
|
+
'is-rounded': this.rounded,
|
|
64
|
+
'is-outlined': this.outlined,
|
|
65
|
+
'has-left-label': this.leftLabel
|
|
66
|
+
}];
|
|
67
|
+
},
|
|
68
|
+
checkClasses: function checkClasses() {
|
|
69
|
+
return [{
|
|
70
|
+
'is-elastic': this.isMouseDown && !this.disabled
|
|
71
|
+
}, this.passiveType && "".concat(this.passiveType, "-passive"), this.type];
|
|
72
|
+
},
|
|
73
|
+
showControlLabel: function showControlLabel() {
|
|
74
|
+
return !!this.$slots.default;
|
|
75
|
+
}
|
|
76
|
+
},
|
|
77
|
+
watch: {
|
|
78
|
+
/**
|
|
79
|
+
* When v-model change, set internal value.
|
|
80
|
+
*/
|
|
81
|
+
value: function value(_value) {
|
|
82
|
+
this.newValue = _value;
|
|
83
|
+
}
|
|
84
|
+
},
|
|
85
|
+
methods: {
|
|
86
|
+
focus: function focus() {
|
|
87
|
+
// MacOS FireFox and Safari do not focus when clicked
|
|
88
|
+
this.$refs.input.focus();
|
|
89
|
+
}
|
|
90
|
+
}
|
|
91
|
+
};
|
|
92
|
+
|
|
93
|
+
/* script */
|
|
94
|
+
const __vue_script__ = script;
|
|
95
|
+
|
|
96
|
+
/* template */
|
|
97
|
+
var __vue_render__ = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('label',{ref:"label",staticClass:"switch",class:_vm.newClass,attrs:{"disabled":_vm.disabled},on:{"click":_vm.focus,"keydown":function($event){if(!$event.type.indexOf('key')&&_vm._k($event.keyCode,"enter",13,$event.key,"Enter")){ return null; }$event.preventDefault();return _vm.$refs.label.click()},"mousedown":function($event){_vm.isMouseDown = true;},"mouseup":function($event){_vm.isMouseDown = false;},"mouseout":function($event){_vm.isMouseDown = false;},"blur":function($event){_vm.isMouseDown = false;}}},[_c('input',{directives:[{name:"model",rawName:"v-model",value:(_vm.computedValue),expression:"computedValue"}],ref:"input",attrs:{"type":"checkbox","disabled":_vm.disabled,"name":_vm.name,"required":_vm.required,"true-value":_vm.trueValue,"false-value":_vm.falseValue,"aria-labelledby":_vm.ariaLabelledby},domProps:{"value":_vm.nativeValue,"checked":Array.isArray(_vm.computedValue)?_vm._i(_vm.computedValue,_vm.nativeValue)>-1:_vm._q(_vm.computedValue,_vm.trueValue)},on:{"click":function($event){$event.stopPropagation();},"change":function($event){var $$a=_vm.computedValue,$$el=$event.target,$$c=$$el.checked?(_vm.trueValue):(_vm.falseValue);if(Array.isArray($$a)){var $$v=_vm.nativeValue,$$i=_vm._i($$a,$$v);if($$el.checked){$$i<0&&(_vm.computedValue=$$a.concat([$$v]));}else {$$i>-1&&(_vm.computedValue=$$a.slice(0,$$i).concat($$a.slice($$i+1)));}}else {_vm.computedValue=$$c;}}}}),_c('span',{staticClass:"check",class:_vm.checkClasses}),(_vm.showControlLabel)?_c('span',{staticClass:"control-label",attrs:{"id":_vm.ariaLabelledby}},[_vm._t("default")],2):_vm._e()])};
|
|
98
|
+
var __vue_staticRenderFns__ = [];
|
|
99
|
+
|
|
100
|
+
/* style */
|
|
101
|
+
const __vue_inject_styles__ = undefined;
|
|
102
|
+
/* scoped */
|
|
103
|
+
const __vue_scope_id__ = undefined;
|
|
104
|
+
/* module identifier */
|
|
105
|
+
const __vue_module_identifier__ = undefined;
|
|
106
|
+
/* functional template */
|
|
107
|
+
const __vue_is_functional_template__ = false;
|
|
108
|
+
/* style inject */
|
|
109
|
+
|
|
110
|
+
/* style inject SSR */
|
|
111
|
+
|
|
112
|
+
/* style inject shadow dom */
|
|
113
|
+
|
|
114
|
+
|
|
115
|
+
|
|
116
|
+
const __vue_component__ = /*#__PURE__*/plugins.normalizeComponent(
|
|
117
|
+
{ render: __vue_render__, staticRenderFns: __vue_staticRenderFns__ },
|
|
118
|
+
__vue_inject_styles__,
|
|
119
|
+
__vue_script__,
|
|
120
|
+
__vue_scope_id__,
|
|
121
|
+
__vue_is_functional_template__,
|
|
122
|
+
__vue_module_identifier__,
|
|
123
|
+
false,
|
|
124
|
+
undefined,
|
|
125
|
+
undefined,
|
|
126
|
+
undefined
|
|
127
|
+
);
|
|
128
|
+
|
|
129
|
+
var Switch = __vue_component__;
|
|
130
|
+
|
|
131
|
+
var Plugin = {
|
|
132
|
+
install: function install(Vue) {
|
|
133
|
+
plugins.registerComponent(Vue, Switch);
|
|
134
|
+
}
|
|
135
|
+
};
|
|
136
|
+
plugins.use(Plugin);
|
|
137
|
+
|
|
138
|
+
exports.BSwitch = Switch;
|
|
139
|
+
exports["default"] = Plugin;
|