@gitlab/ui 132.1.0 → 132.2.0
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/components/base/accordion/accordion_item.js +1 -3
- package/dist/components/base/avatar/avatar.js +76 -5
- package/dist/components/base/badge/badge.js +5 -7
- package/dist/components/base/button/button.js +1 -3
- package/dist/components/base/collapse/collapse.js +2 -6
- package/dist/components/base/datepicker/datepicker.js +4 -5
- package/dist/components/base/daterange_picker/daterange_picker.js +2 -4
- package/dist/components/base/dropdown/dropdown_item.js +3 -4
- package/dist/components/base/filtered_search/filtered_search.js +55 -7
- package/dist/components/base/filtered_search/filtered_search_token.js +6 -14
- package/dist/components/base/filtered_search/filtered_search_token_segment.js +39 -19
- package/dist/components/base/filtered_search/filtered_search_utils.js +57 -7
- package/dist/components/base/form/form_checkbox/form_checkbox.js +13 -26
- package/dist/components/base/form/form_checkbox/form_checkbox_group.js +1 -3
- package/dist/components/base/form/form_fields/form_fields_loop.js +57 -6
- package/dist/components/base/form/form_group/form_group.js +1 -3
- package/dist/components/base/form/form_input/form_input.js +95 -41
- package/dist/components/base/form/form_input_group/form_input_group.js +2 -4
- package/dist/components/base/form/form_radio/form_radio.js +5 -9
- package/dist/components/base/form/form_radio_group/form_radio_group.js +1 -3
- package/dist/components/base/form/form_select/form_select.js +76 -5
- package/dist/components/base/infinite_scroll/infinite_scroll.js +7 -14
- package/dist/components/base/link/link.js +26 -7
- package/dist/components/base/new_dropdowns/base_dropdown/base_dropdown.js +93 -32
- package/dist/components/base/new_dropdowns/disclosure/disclosure_dropdown.js +2 -6
- package/dist/components/base/new_dropdowns/disclosure/disclosure_dropdown_item.js +2 -6
- package/dist/components/base/new_dropdowns/listbox/listbox.js +5 -13
- package/dist/components/base/new_dropdowns/listbox/listbox_item.js +1 -3
- package/dist/components/base/new_dropdowns/listbox/mock_data.js +2 -6
- package/dist/components/base/new_dropdowns/listbox/utils.js +6 -11
- package/dist/components/base/path/path.js +1 -5
- package/dist/components/base/search_box_by_type/search_box_by_type.js +2 -6
- package/dist/components/base/skeleton_loader/skeleton_loader.js +3 -5
- package/dist/components/base/table/table.js +32 -21
- package/dist/components/base/table_lite/table_lite.js +1 -3
- package/dist/components/base/tabs/tab/tab.js +1 -3
- package/dist/components/base/tabs/tabs/scrollable_tabs.js +1 -5
- package/dist/components/base/token_selector/token_selector.js +2 -6
- package/dist/components/charts/area/area.js +6 -7
- package/dist/components/charts/column/column.js +11 -15
- package/dist/components/charts/discrete_scatter/discrete_scatter.js +57 -5
- package/dist/components/charts/gauge/gauge.js +13 -21
- package/dist/components/charts/heatmap/heatmap.js +66 -18
- package/dist/components/charts/legend/legend.js +59 -13
- package/dist/components/charts/line/line.js +6 -7
- package/dist/components/charts/shared/tooltip/tooltip.js +11 -18
- package/dist/components/charts/sparkline/sparkline.js +72 -19
- package/dist/components/charts/stacked_column/stacked_column.js +18 -31
- package/dist/components/dashboards/dashboard_layout/grid_layout/grid_layout.js +37 -21
- package/dist/components/utilities/friendly_wrap/friendly_wrap.js +3 -7
- package/dist/components/utilities/intersperse/intersperse.js +6 -11
- package/dist/components/utilities/sprintf/sprintf.js +58 -7
- package/dist/components/utilities/truncate/truncate.js +2 -4
- package/dist/components/utilities/truncate_text/truncate_text.js +1 -3
- package/dist/config.js +3 -4
- package/dist/directives/hover_load/hover_load.js +1 -3
- package/dist/directives/outside/outside.js +9 -16
- package/dist/directives/resize_observer/resize_observer.js +6 -8
- package/dist/directives/safe_html/safe_html.js +1 -3
- package/dist/directives/safe_link/safe_link.js +11 -14
- package/dist/index.css +2 -2
- package/dist/index.css.map +1 -1
- package/dist/tokens/build/js/tokens.dark.js +95 -95
- package/dist/tokens/build/js/tokens.js +74 -74
- package/dist/tokens/common_story_options.js +7 -8
- package/dist/utils/charts/config.js +122 -90
- package/dist/utils/constants.js +26 -1
- package/dist/utils/data_utils.js +28 -1
- package/dist/utils/form_options_utils.js +4 -6
- package/dist/utils/is_slot_empty.js +3 -5
- package/dist/utils/stories_utils.js +8 -8
- package/dist/utils/use_mock_intersection_observer.js +63 -12
- package/dist/utils/utils.js +76 -19
- package/dist/vendor/bootstrap-vue/src/components/button/button-close.js +8 -11
- package/dist/vendor/bootstrap-vue/src/components/button/button.js +12 -17
- package/dist/vendor/bootstrap-vue/src/components/dropdown/dropdown-divider.js +3 -6
- package/dist/vendor/bootstrap-vue/src/components/dropdown/dropdown-form.js +6 -9
- package/dist/vendor/bootstrap-vue/src/components/dropdown/dropdown-group.js +14 -19
- package/dist/vendor/bootstrap-vue/src/components/dropdown/dropdown-header.js +8 -13
- package/dist/vendor/bootstrap-vue/src/components/dropdown/dropdown-item-button.js +9 -12
- package/dist/vendor/bootstrap-vue/src/components/dropdown/dropdown-item.js +8 -11
- package/dist/vendor/bootstrap-vue/src/components/dropdown/dropdown-text.js +9 -14
- package/dist/vendor/bootstrap-vue/src/components/dropdown/dropdown.js +34 -43
- package/dist/vendor/bootstrap-vue/src/components/form/form-invalid-feedback.js +5 -9
- package/dist/vendor/bootstrap-vue/src/components/form/form-text.js +7 -10
- package/dist/vendor/bootstrap-vue/src/components/form/form-valid-feedback.js +5 -9
- package/dist/vendor/bootstrap-vue/src/components/form/form.js +7 -10
- package/dist/vendor/bootstrap-vue/src/components/form-group/form-group.js +25 -33
- package/dist/vendor/bootstrap-vue/src/components/form-select/form-select-option-group.js +6 -11
- package/dist/vendor/bootstrap-vue/src/components/form-select/form-select-option.js +6 -12
- package/dist/vendor/bootstrap-vue/src/components/form-select/form-select.js +28 -29
- package/dist/vendor/bootstrap-vue/src/components/form-textarea/form-textarea.js +7 -10
- package/dist/vendor/bootstrap-vue/src/components/layout/col.js +7 -11
- package/dist/vendor/bootstrap-vue/src/components/layout/form-row.js +3 -5
- package/dist/vendor/bootstrap-vue/src/components/link/link.js +19 -31
- package/dist/vendor/bootstrap-vue/src/components/modal/helpers/modal-manager.js +3 -4
- package/dist/vendor/bootstrap-vue/src/components/modal/modal.js +59 -68
- package/dist/vendor/bootstrap-vue/src/components/popover/helpers/bv-popover-template.js +2 -4
- package/dist/vendor/bootstrap-vue/src/components/popover/popover.js +4 -5
- package/dist/vendor/bootstrap-vue/src/components/table/helpers/default-sort-compare.js +11 -7
- package/dist/vendor/bootstrap-vue/src/components/table/helpers/mixin-bottom-row.js +4 -6
- package/dist/vendor/bootstrap-vue/src/components/table/helpers/mixin-busy.js +3 -6
- package/dist/vendor/bootstrap-vue/src/components/table/helpers/mixin-caption.js +4 -7
- package/dist/vendor/bootstrap-vue/src/components/table/helpers/mixin-colgroup.js +1 -3
- package/dist/vendor/bootstrap-vue/src/components/table/helpers/mixin-empty.js +16 -20
- package/dist/vendor/bootstrap-vue/src/components/table/helpers/mixin-filtering.js +14 -25
- package/dist/vendor/bootstrap-vue/src/components/table/helpers/mixin-items.js +23 -35
- package/dist/vendor/bootstrap-vue/src/components/table/helpers/mixin-pagination.js +6 -8
- package/dist/vendor/bootstrap-vue/src/components/table/helpers/mixin-provider.js +8 -10
- package/dist/vendor/bootstrap-vue/src/components/table/helpers/mixin-selectable.js +8 -15
- package/dist/vendor/bootstrap-vue/src/components/table/helpers/mixin-sorting.js +33 -41
- package/dist/vendor/bootstrap-vue/src/components/table/helpers/mixin-stacked.js +3 -8
- package/dist/vendor/bootstrap-vue/src/components/table/helpers/mixin-table-renderer.js +38 -50
- package/dist/vendor/bootstrap-vue/src/components/table/helpers/mixin-tbody-row.js +19 -31
- package/dist/vendor/bootstrap-vue/src/components/table/helpers/mixin-tbody.js +13 -23
- package/dist/vendor/bootstrap-vue/src/components/table/helpers/mixin-tfoot.js +5 -6
- package/dist/vendor/bootstrap-vue/src/components/table/helpers/mixin-thead.js +17 -21
- package/dist/vendor/bootstrap-vue/src/components/table/helpers/mixin-top-row.js +4 -6
- package/dist/vendor/bootstrap-vue/src/components/table/helpers/sanitize-row.js +1 -3
- package/dist/vendor/bootstrap-vue/src/components/table/tbody.js +3 -6
- package/dist/vendor/bootstrap-vue/src/components/table/td.js +9 -14
- package/dist/vendor/bootstrap-vue/src/components/table/tfoot.js +1 -2
- package/dist/vendor/bootstrap-vue/src/components/table/thead.js +1 -2
- package/dist/vendor/bootstrap-vue/src/components/table/tr.js +2 -5
- package/dist/vendor/bootstrap-vue/src/components/tabs/tab.js +19 -36
- package/dist/vendor/bootstrap-vue/src/components/tabs/tabs.js +66 -81
- package/dist/vendor/bootstrap-vue/src/components/tooltip/helpers/bv-popper.js +2 -6
- package/dist/vendor/bootstrap-vue/src/components/tooltip/helpers/bv-tooltip-template.js +5 -11
- package/dist/vendor/bootstrap-vue/src/components/tooltip/helpers/bv-tooltip.js +8 -14
- package/dist/vendor/bootstrap-vue/src/components/tooltip/tooltip.js +19 -22
- package/dist/vendor/bootstrap-vue/src/components/transition/bv-transition.js +7 -10
- package/dist/vendor/bootstrap-vue/src/components/transporter/transporter.js +7 -14
- package/dist/vendor/bootstrap-vue/src/directives/modal/modal.js +4 -5
- package/dist/vendor/bootstrap-vue/src/directives/visible/visible.js +5 -9
- package/dist/vendor/bootstrap-vue/src/mixins/dropdown.js +17 -29
- package/dist/vendor/bootstrap-vue/src/mixins/form-control.js +6 -7
- package/dist/vendor/bootstrap-vue/src/mixins/form-custom.js +1 -2
- package/dist/vendor/bootstrap-vue/src/mixins/form-options.js +5 -6
- package/dist/vendor/bootstrap-vue/src/mixins/form-size.js +1 -2
- package/dist/vendor/bootstrap-vue/src/mixins/form-state.js +1 -2
- package/dist/vendor/bootstrap-vue/src/mixins/form-text.js +29 -43
- package/dist/vendor/bootstrap-vue/src/mixins/id.js +1 -2
- package/dist/vendor/bootstrap-vue/src/utils/create-new-child-component.js +62 -15
- package/dist/vendor/bootstrap-vue/src/utils/dom.js +3 -9
- package/dist/vendor/bootstrap-vue/src/utils/events.js +7 -5
- package/dist/vendor/bootstrap-vue/src/utils/plugins.js +4 -5
- package/dist/vendor/bootstrap-vue/src/utils/router.js +9 -13
- package/package.json +9 -7
- package/src/scss/gitlab_ui.scss +3 -0
- package/src/scss/storybook.scss +3 -0
- package/src/scss/themes.scss +84 -0
- package/src/tokens/build/css/tokens.css +142 -142
- package/src/tokens/build/css/tokens.dark.css +138 -138
- package/src/tokens/build/docs/tokens-tailwind-docs.dark.json +580 -580
- package/src/tokens/build/docs/tokens-tailwind-docs.json +495 -495
- package/src/tokens/build/figma/constants.dark.json +799 -799
- package/src/tokens/build/figma/constants.json +799 -799
- package/src/tokens/build/js/tokens.dark.js +95 -95
- package/src/tokens/build/js/tokens.js +74 -74
- package/src/tokens/build/json/tokens.dark.json +1668 -1668
- package/src/tokens/build/json/tokens.json +1647 -1647
- package/src/tokens/build/scss/_tokens.dark.scss +138 -138
- package/src/tokens/build/scss/_tokens.scss +142 -142
- package/src/tokens/build/scss/_tokens_custom_properties.scss +73 -73
- package/src/tokens/constant/color.blue.tokens.json +182 -0
- package/src/tokens/constant/color.brand.tokens.json +252 -0
- package/src/tokens/constant/color.data.tokens.json +894 -0
- package/src/tokens/constant/color.green.tokens.json +182 -0
- package/src/tokens/constant/color.neutral.tokens.json +230 -0
- package/src/tokens/constant/color.orange.tokens.json +182 -0
- package/src/tokens/constant/color.purple.tokens.json +182 -0
- package/src/tokens/constant/color.red.tokens.json +182 -0
- package/src/tokens/constant/color.theme.tokens.json +1168 -0
- package/src/tokens/deprecated/deprecated.color.tokens.json +134 -1340
- package/src/utils/constants.js +9 -0
- package/src/vendor/bootstrap-vue/src/components/button/button-close.js +4 -5
- package/src/vendor/bootstrap-vue/src/components/button/button.js +7 -8
- package/src/vendor/bootstrap-vue/src/components/dropdown/dropdown-divider.js +1 -2
- package/src/vendor/bootstrap-vue/src/components/dropdown/dropdown-form.js +2 -8
- package/src/vendor/bootstrap-vue/src/components/dropdown/dropdown-group.js +6 -7
- package/src/vendor/bootstrap-vue/src/components/dropdown/dropdown-header.js +3 -4
- package/src/vendor/bootstrap-vue/src/components/dropdown/dropdown-item-button.js +6 -12
- package/src/vendor/bootstrap-vue/src/components/dropdown/dropdown-item.js +2 -3
- package/src/vendor/bootstrap-vue/src/components/dropdown/dropdown-text.js +3 -4
- package/src/vendor/bootstrap-vue/src/components/dropdown/dropdown.js +19 -26
- package/src/vendor/bootstrap-vue/src/components/form/form-text.js +4 -6
- package/src/vendor/bootstrap-vue/src/components/form/form.js +4 -6
- package/src/vendor/bootstrap-vue/src/components/form-group/form-group.js +14 -20
- package/src/vendor/bootstrap-vue/src/components/form-select/form-select-option-group.js +1 -2
- package/src/vendor/bootstrap-vue/src/components/form-select/form-select-option.js +1 -4
- package/src/vendor/bootstrap-vue/src/components/form-select/form-select.js +13 -14
- package/src/vendor/bootstrap-vue/src/components/form-textarea/form-textarea.js +5 -6
- package/src/vendor/bootstrap-vue/src/components/modal/modal.js +53 -62
- package/src/vendor/bootstrap-vue/src/components/popover/popover.js +4 -10
- package/src/vendor/bootstrap-vue/src/components/table/helpers/mixin-busy.js +1 -2
- package/src/vendor/bootstrap-vue/src/components/table/helpers/mixin-caption.js +2 -3
- package/src/vendor/bootstrap-vue/src/components/table/helpers/mixin-empty.js +5 -6
- package/src/vendor/bootstrap-vue/src/components/table/helpers/mixin-filtering.js +5 -13
- package/src/vendor/bootstrap-vue/src/components/table/helpers/mixin-items.js +12 -21
- package/src/vendor/bootstrap-vue/src/components/table/helpers/mixin-pagination.js +2 -3
- package/src/vendor/bootstrap-vue/src/components/table/helpers/mixin-provider.js +5 -11
- package/src/vendor/bootstrap-vue/src/components/table/helpers/mixin-selectable.js +4 -5
- package/src/vendor/bootstrap-vue/src/components/table/helpers/mixin-sorting.js +14 -21
- package/src/vendor/bootstrap-vue/src/components/table/helpers/mixin-stacked.js +1 -2
- package/src/vendor/bootstrap-vue/src/components/table/helpers/mixin-table-renderer.js +14 -20
- package/src/vendor/bootstrap-vue/src/components/table/helpers/mixin-tbody-row.js +3 -9
- package/src/vendor/bootstrap-vue/src/components/table/helpers/mixin-tbody.js +1 -2
- package/src/vendor/bootstrap-vue/src/components/table/helpers/mixin-tfoot.js +5 -11
- package/src/vendor/bootstrap-vue/src/components/table/helpers/mixin-thead.js +4 -5
- package/src/vendor/bootstrap-vue/src/components/table/tbody.js +2 -3
- package/src/vendor/bootstrap-vue/src/components/table/td.js +5 -6
- package/src/vendor/bootstrap-vue/src/components/table/tfoot.js +1 -2
- package/src/vendor/bootstrap-vue/src/components/table/thead.js +1 -2
- package/src/vendor/bootstrap-vue/src/components/table/tr.js +1 -2
- package/src/vendor/bootstrap-vue/src/components/tabs/tab.js +10 -16
- package/src/vendor/bootstrap-vue/src/components/tabs/tabs.js +33 -39
- package/src/vendor/bootstrap-vue/src/components/tooltip/tooltip.js +17 -25
- package/src/vendor/bootstrap-vue/src/components/transition/bv-transition.js +4 -5
- package/src/vendor/bootstrap-vue/src/components/transporter/transporter.js +4 -10
- package/src/vendor/bootstrap-vue/src/mixins/dropdown.js +9 -15
- package/src/vendor/bootstrap-vue/src/mixins/form-control.js +6 -7
- package/src/vendor/bootstrap-vue/src/mixins/form-custom.js +1 -2
- package/src/vendor/bootstrap-vue/src/mixins/form-options.js +5 -6
- package/src/vendor/bootstrap-vue/src/mixins/form-size.js +1 -2
- package/src/vendor/bootstrap-vue/src/mixins/form-state.js +1 -2
- package/src/vendor/bootstrap-vue/src/mixins/form-text.js +21 -33
- package/src/vendor/bootstrap-vue/src/mixins/id.js +1 -2
- package/dist/vendor/bootstrap-vue/src/mixins/model.js +0 -10
- package/dist/vendor/bootstrap-vue/src/utils/model.js +0 -33
- package/src/tokens/constant/color.tokens.json +0 -3422
- package/src/vendor/bootstrap-vue/src/mixins/model.js +0 -5
- package/src/vendor/bootstrap-vue/src/utils/model.js +0 -29
|
@@ -4,6 +4,76 @@ import { getAvatarChar } from '../../../utils/string_utils';
|
|
|
4
4
|
import { avatarSizeValidator } from './utils';
|
|
5
5
|
import __vue_normalize__ from 'vue-runtime-helpers/dist/normalize-component.js';
|
|
6
6
|
|
|
7
|
+
function _arrayLikeToArray(r, a) {
|
|
8
|
+
(null == a || a > r.length) && (a = r.length);
|
|
9
|
+
for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e];
|
|
10
|
+
return n;
|
|
11
|
+
}
|
|
12
|
+
function _arrayWithHoles(r) {
|
|
13
|
+
if (Array.isArray(r)) return r;
|
|
14
|
+
}
|
|
15
|
+
function _iterableToArrayLimit(r, l) {
|
|
16
|
+
var t = null == r ? null : "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"];
|
|
17
|
+
if (null != t) {
|
|
18
|
+
var e,
|
|
19
|
+
n,
|
|
20
|
+
i,
|
|
21
|
+
u,
|
|
22
|
+
a = [],
|
|
23
|
+
f = !0,
|
|
24
|
+
o = !1;
|
|
25
|
+
try {
|
|
26
|
+
if (i = (t = t.call(r)).next, 0 === l) {
|
|
27
|
+
if (Object(t) !== t) return;
|
|
28
|
+
f = !1;
|
|
29
|
+
} else for (; !(f = (e = i.call(t)).done) && (a.push(e.value), a.length !== l); f = !0);
|
|
30
|
+
} catch (r) {
|
|
31
|
+
o = !0, n = r;
|
|
32
|
+
} finally {
|
|
33
|
+
try {
|
|
34
|
+
if (!f && null != t.return && (u = t.return(), Object(u) !== u)) return;
|
|
35
|
+
} finally {
|
|
36
|
+
if (o) throw n;
|
|
37
|
+
}
|
|
38
|
+
}
|
|
39
|
+
return a;
|
|
40
|
+
}
|
|
41
|
+
}
|
|
42
|
+
function _nonIterableRest() {
|
|
43
|
+
throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
|
|
44
|
+
}
|
|
45
|
+
function _objectWithoutProperties(e, t) {
|
|
46
|
+
if (null == e) return {};
|
|
47
|
+
var o,
|
|
48
|
+
r,
|
|
49
|
+
i = _objectWithoutPropertiesLoose(e, t);
|
|
50
|
+
if (Object.getOwnPropertySymbols) {
|
|
51
|
+
var n = Object.getOwnPropertySymbols(e);
|
|
52
|
+
for (r = 0; r < n.length; r++) o = n[r], -1 === t.indexOf(o) && {}.propertyIsEnumerable.call(e, o) && (i[o] = e[o]);
|
|
53
|
+
}
|
|
54
|
+
return i;
|
|
55
|
+
}
|
|
56
|
+
function _objectWithoutPropertiesLoose(r, e) {
|
|
57
|
+
if (null == r) return {};
|
|
58
|
+
var t = {};
|
|
59
|
+
for (var n in r) if ({}.hasOwnProperty.call(r, n)) {
|
|
60
|
+
if (-1 !== e.indexOf(n)) continue;
|
|
61
|
+
t[n] = r[n];
|
|
62
|
+
}
|
|
63
|
+
return t;
|
|
64
|
+
}
|
|
65
|
+
function _slicedToArray(r, e) {
|
|
66
|
+
return _arrayWithHoles(r) || _iterableToArrayLimit(r, e) || _unsupportedIterableToArray(r, e) || _nonIterableRest();
|
|
67
|
+
}
|
|
68
|
+
function _unsupportedIterableToArray(r, a) {
|
|
69
|
+
if (r) {
|
|
70
|
+
if ("string" == typeof r) return _arrayLikeToArray(r, a);
|
|
71
|
+
var t = {}.toString.call(r).slice(8, -1);
|
|
72
|
+
return "Object" === t && r.constructor && (t = r.constructor.name), "Map" === t || "Set" === t ? Array.from(r) : "Arguments" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray(r, a) : void 0;
|
|
73
|
+
}
|
|
74
|
+
}
|
|
75
|
+
|
|
76
|
+
const _excluded = ["default"];
|
|
7
77
|
const IDENTICON_BG_COUNT = 7;
|
|
8
78
|
var script = {
|
|
9
79
|
name: 'GlAvatar',
|
|
@@ -79,16 +149,17 @@ var script = {
|
|
|
79
149
|
// eslint-disable-next-line @gitlab/tailwind-no-interpolation -- Not a CSS utility
|
|
80
150
|
return `gl-avatar-s${this.size}`;
|
|
81
151
|
}
|
|
82
|
-
const
|
|
83
|
-
default
|
|
84
|
-
|
|
85
|
-
} = this.size;
|
|
152
|
+
const _this$size = this.size,
|
|
153
|
+
defaultSize = _this$size.default,
|
|
154
|
+
nonDefaultSizes = _objectWithoutProperties(_this$size, _excluded);
|
|
86
155
|
return [
|
|
87
156
|
// eslint-disable-next-line @gitlab/tailwind-no-interpolation -- Not a CSS utility
|
|
88
157
|
`gl-avatar-s${defaultSize || avatarSizeOptions[1]}`, ...Object.entries(nonDefaultSizes).map(
|
|
89
158
|
// eslint-disable-next-line @gitlab/tailwind-no-interpolation -- Not a CSS utility
|
|
90
159
|
_ref => {
|
|
91
|
-
let
|
|
160
|
+
let _ref2 = _slicedToArray(_ref, 2),
|
|
161
|
+
breakpoint = _ref2[0],
|
|
162
|
+
size = _ref2[1];
|
|
92
163
|
return `gl-${breakpoint}-avatar-s${size}`;
|
|
93
164
|
})];
|
|
94
165
|
},
|
|
@@ -126,13 +126,11 @@ var script = {
|
|
|
126
126
|
},
|
|
127
127
|
computedProps() {
|
|
128
128
|
if (!this.isLink) return {};
|
|
129
|
-
const
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
disabled
|
|
135
|
-
} = this;
|
|
129
|
+
const href = this.href,
|
|
130
|
+
rel = this.rel,
|
|
131
|
+
target = this.target,
|
|
132
|
+
active = this.active,
|
|
133
|
+
disabled = this.disabled;
|
|
136
134
|
return {
|
|
137
135
|
href,
|
|
138
136
|
rel,
|
|
@@ -360,9 +360,7 @@ var script = {
|
|
|
360
360
|
// Add SPACE keydown handler for link has `href` of `#`
|
|
361
361
|
// Add ENTER handler for non-standard tags
|
|
362
362
|
if (!this.disabled && (this.isNonStandardTag || this.isHashLink)) {
|
|
363
|
-
const
|
|
364
|
-
code
|
|
365
|
-
} = event;
|
|
363
|
+
const code = event.code;
|
|
366
364
|
if (code === SPACE || code === ENTER && this.isNonStandardTag) {
|
|
367
365
|
const target = event.currentTarget || event.target;
|
|
368
366
|
stopEvent(event, {
|
|
@@ -32,9 +32,7 @@ var script = {
|
|
|
32
32
|
},
|
|
33
33
|
computed: {
|
|
34
34
|
classObject() {
|
|
35
|
-
const
|
|
36
|
-
transitioning
|
|
37
|
-
} = this;
|
|
35
|
+
const transitioning = this.transitioning;
|
|
38
36
|
return {
|
|
39
37
|
collapse: !transitioning,
|
|
40
38
|
show: this.show && !transitioning
|
|
@@ -89,9 +87,7 @@ var script = {
|
|
|
89
87
|
return Boolean(el && el.nodeType === Node.ELEMENT_NODE) && el.offsetHeight;
|
|
90
88
|
},
|
|
91
89
|
emitState() {
|
|
92
|
-
const
|
|
93
|
-
show
|
|
94
|
-
} = this;
|
|
90
|
+
const show = this.show;
|
|
95
91
|
this.$emit('input', show);
|
|
96
92
|
},
|
|
97
93
|
enter(el) {
|
|
@@ -30,11 +30,10 @@ const highlightPastDates = pikaday => {
|
|
|
30
30
|
const pikaButtons = pikaday.el.querySelectorAll('.pika-button');
|
|
31
31
|
const today = new Date();
|
|
32
32
|
pikaButtons.forEach(pikaButton => {
|
|
33
|
-
const
|
|
34
|
-
pikaYear,
|
|
35
|
-
pikaMonth,
|
|
36
|
-
pikaDay
|
|
37
|
-
} = pikaButton.dataset;
|
|
33
|
+
const _pikaButton$dataset = pikaButton.dataset,
|
|
34
|
+
pikaYear = _pikaButton$dataset.pikaYear,
|
|
35
|
+
pikaMonth = _pikaButton$dataset.pikaMonth,
|
|
36
|
+
pikaDay = _pikaButton$dataset.pikaDay;
|
|
38
37
|
const pikaButtonDate = new Date(pikaYear, pikaMonth, pikaDay);
|
|
39
38
|
if (isBefore(today, pikaButtonDate)) {
|
|
40
39
|
pikaButton.classList.add('is-past-date');
|
|
@@ -98,10 +98,9 @@ var script = {
|
|
|
98
98
|
},
|
|
99
99
|
computed: {
|
|
100
100
|
bootstrapComponent() {
|
|
101
|
-
const
|
|
102
|
-
href,
|
|
103
|
-
to
|
|
104
|
-
} = this.$attrs;
|
|
101
|
+
const _this$$attrs = this.$attrs,
|
|
102
|
+
href = _this$$attrs.href,
|
|
103
|
+
to = _this$$attrs.to;
|
|
105
104
|
// Support 'href' and Vue Router's 'to'
|
|
106
105
|
return href || to ? BDropdownItem : BDropdownItemButton;
|
|
107
106
|
},
|
|
@@ -8,6 +8,55 @@ import GlFilteredSearchTerm from './filtered_search_term';
|
|
|
8
8
|
import { termTokenDefinition, isEmptyTerm, createTerm, INTENT_ACTIVATE_PREVIOUS, ensureTokenId, normalizeTokens, needDenormalization, denormalizeTokens } from './filtered_search_utils';
|
|
9
9
|
import __vue_normalize__ from 'vue-runtime-helpers/dist/normalize-component.js';
|
|
10
10
|
|
|
11
|
+
function _arrayLikeToArray(r, a) {
|
|
12
|
+
(null == a || a > r.length) && (a = r.length);
|
|
13
|
+
for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e];
|
|
14
|
+
return n;
|
|
15
|
+
}
|
|
16
|
+
function _arrayWithHoles(r) {
|
|
17
|
+
if (Array.isArray(r)) return r;
|
|
18
|
+
}
|
|
19
|
+
function _iterableToArrayLimit(r, l) {
|
|
20
|
+
var t = null == r ? null : "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"];
|
|
21
|
+
if (null != t) {
|
|
22
|
+
var e,
|
|
23
|
+
n,
|
|
24
|
+
i,
|
|
25
|
+
u,
|
|
26
|
+
a = [],
|
|
27
|
+
f = !0,
|
|
28
|
+
o = !1;
|
|
29
|
+
try {
|
|
30
|
+
if (i = (t = t.call(r)).next, 0 === l) {
|
|
31
|
+
if (Object(t) !== t) return;
|
|
32
|
+
f = !1;
|
|
33
|
+
} else for (; !(f = (e = i.call(t)).done) && (a.push(e.value), a.length !== l); f = !0);
|
|
34
|
+
} catch (r) {
|
|
35
|
+
o = !0, n = r;
|
|
36
|
+
} finally {
|
|
37
|
+
try {
|
|
38
|
+
if (!f && null != t.return && (u = t.return(), Object(u) !== u)) return;
|
|
39
|
+
} finally {
|
|
40
|
+
if (o) throw n;
|
|
41
|
+
}
|
|
42
|
+
}
|
|
43
|
+
return a;
|
|
44
|
+
}
|
|
45
|
+
}
|
|
46
|
+
function _nonIterableRest() {
|
|
47
|
+
throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
|
|
48
|
+
}
|
|
49
|
+
function _slicedToArray(r, e) {
|
|
50
|
+
return _arrayWithHoles(r) || _iterableToArrayLimit(r, e) || _unsupportedIterableToArray(r, e) || _nonIterableRest();
|
|
51
|
+
}
|
|
52
|
+
function _unsupportedIterableToArray(r, a) {
|
|
53
|
+
if (r) {
|
|
54
|
+
if ("string" == typeof r) return _arrayLikeToArray(r, a);
|
|
55
|
+
var t = {}.toString.call(r).slice(8, -1);
|
|
56
|
+
return "Object" === t && r.constructor && (t = r.constructor.name), "Map" === t || "Set" === t ? Array.from(r) : "Arguments" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray(r, a) : void 0;
|
|
57
|
+
}
|
|
58
|
+
}
|
|
59
|
+
|
|
11
60
|
let portalUuid = 0;
|
|
12
61
|
function initialState() {
|
|
13
62
|
return [createTerm()];
|
|
@@ -65,9 +114,7 @@ var script = {
|
|
|
65
114
|
|
|
66
115
|
// eslint-disable-next-line no-underscore-dangle
|
|
67
116
|
const isOk = Array.isArray(value) && value.every(_ref => {
|
|
68
|
-
let
|
|
69
|
-
token
|
|
70
|
-
} = _ref;
|
|
117
|
+
let token = _ref.token;
|
|
71
118
|
return !token || token.__v_skip;
|
|
72
119
|
});
|
|
73
120
|
if (!isOk) {
|
|
@@ -304,13 +351,14 @@ var script = {
|
|
|
304
351
|
this.activeTokenIdx = null;
|
|
305
352
|
},
|
|
306
353
|
destroyToken(idx) {
|
|
307
|
-
let {
|
|
308
|
-
intent
|
|
309
|
-
} = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};
|
|
354
|
+
let _ref2 = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {},
|
|
355
|
+
intent = _ref2.intent;
|
|
310
356
|
if (this.tokens.length === 1) {
|
|
311
357
|
return;
|
|
312
358
|
}
|
|
313
|
-
const
|
|
359
|
+
const _this$tokens$splice = this.tokens.splice(idx, 1),
|
|
360
|
+
_this$tokens$splice2 = _slicedToArray(_this$tokens$splice, 1),
|
|
361
|
+
destroyedToken = _this$tokens$splice2[0];
|
|
314
362
|
/**
|
|
315
363
|
* Emitted when a token is destroyed, with the token as the payload.
|
|
316
364
|
*/
|
|
@@ -232,9 +232,7 @@ var script = {
|
|
|
232
232
|
},
|
|
233
233
|
replaceToken(newType) {
|
|
234
234
|
const newTokenConfig = this.availableTokens.find(_ref => {
|
|
235
|
-
let
|
|
236
|
-
type
|
|
237
|
-
} = _ref;
|
|
235
|
+
let type = _ref.type;
|
|
238
236
|
return type === newType;
|
|
239
237
|
});
|
|
240
238
|
if (newTokenConfig === this.config) {
|
|
@@ -259,23 +257,17 @@ var script = {
|
|
|
259
257
|
}
|
|
260
258
|
},
|
|
261
259
|
handleOperatorKeydown(evt, _ref2) {
|
|
262
|
-
let
|
|
263
|
-
|
|
264
|
-
|
|
265
|
-
|
|
266
|
-
} = _ref2;
|
|
267
|
-
const {
|
|
268
|
-
key
|
|
269
|
-
} = evt;
|
|
260
|
+
let inputValue = _ref2.inputValue,
|
|
261
|
+
suggestedValue = _ref2.suggestedValue,
|
|
262
|
+
applySuggestion = _ref2.applySuggestion;
|
|
263
|
+
const key = evt.key;
|
|
270
264
|
if (key === ' ' || key === 'Spacebar') {
|
|
271
265
|
applySuggestion(suggestedValue);
|
|
272
266
|
return;
|
|
273
267
|
}
|
|
274
268
|
const potentialValue = `${inputValue}${key}`;
|
|
275
269
|
if (key.length === 1 && !this.operators.find(_ref3 => {
|
|
276
|
-
let
|
|
277
|
-
value
|
|
278
|
-
} = _ref3;
|
|
270
|
+
let value = _ref3.value;
|
|
279
271
|
return value.startsWith(potentialValue);
|
|
280
272
|
})) {
|
|
281
273
|
if (this.tokenEmpty) {
|
|
@@ -6,6 +6,31 @@ import GlFilteredSearchSuggestionList from './filtered_search_suggestion_list';
|
|
|
6
6
|
import { TERM_TOKEN_TYPE, splitOnQuotes, match, wrapTokenInQuotes, FILTERED_SEARCH_SUGGESTIONS_CLASS } from './filtered_search_utils';
|
|
7
7
|
import __vue_normalize__ from 'vue-runtime-helpers/dist/normalize-component.js';
|
|
8
8
|
|
|
9
|
+
function _arrayLikeToArray(r, a) {
|
|
10
|
+
(null == a || a > r.length) && (a = r.length);
|
|
11
|
+
for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e];
|
|
12
|
+
return n;
|
|
13
|
+
}
|
|
14
|
+
function _arrayWithHoles(r) {
|
|
15
|
+
if (Array.isArray(r)) return r;
|
|
16
|
+
}
|
|
17
|
+
function _iterableToArray(r) {
|
|
18
|
+
if ("undefined" != typeof Symbol && null != r[Symbol.iterator] || null != r["@@iterator"]) return Array.from(r);
|
|
19
|
+
}
|
|
20
|
+
function _nonIterableRest() {
|
|
21
|
+
throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
|
|
22
|
+
}
|
|
23
|
+
function _toArray(r) {
|
|
24
|
+
return _arrayWithHoles(r) || _iterableToArray(r) || _unsupportedIterableToArray(r) || _nonIterableRest();
|
|
25
|
+
}
|
|
26
|
+
function _unsupportedIterableToArray(r, a) {
|
|
27
|
+
if (r) {
|
|
28
|
+
if ("string" == typeof r) return _arrayLikeToArray(r, a);
|
|
29
|
+
var t = {}.toString.call(r).slice(8, -1);
|
|
30
|
+
return "Object" === t && r.constructor && (t = r.constructor.name), "Map" === t || "Set" === t ? Array.from(r) : "Arguments" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray(r, a) : void 0;
|
|
31
|
+
}
|
|
32
|
+
}
|
|
33
|
+
|
|
9
34
|
// We need some helpers to ensure @vue/compat compatibility
|
|
10
35
|
// @vue/compat will render comment nodes for v-if and comments in HTML
|
|
11
36
|
// Also it makes use of fragments - both comments and nodes are Symbols.
|
|
@@ -143,9 +168,7 @@ var script = {
|
|
|
143
168
|
if (!this.termsAsTokens()) return false;
|
|
144
169
|
if (!this.options) return false;
|
|
145
170
|
return this.options.some(_ref => {
|
|
146
|
-
let
|
|
147
|
-
value
|
|
148
|
-
} = _ref;
|
|
171
|
+
let value = _ref.value;
|
|
149
172
|
return value === TERM_TOKEN_TYPE;
|
|
150
173
|
});
|
|
151
174
|
},
|
|
@@ -230,7 +253,10 @@ var script = {
|
|
|
230
253
|
if (newValue.indexOf(' ') === -1 || hasUnclosedQuote) {
|
|
231
254
|
return;
|
|
232
255
|
}
|
|
233
|
-
const
|
|
256
|
+
const _splitOnQuotes$filter = splitOnQuotes(newValue).filter((w, idx, arr) => Boolean(w) || idx === arr.length - 1),
|
|
257
|
+
_splitOnQuotes$filter2 = _toArray(_splitOnQuotes$filter),
|
|
258
|
+
firstWord = _splitOnQuotes$filter2[0],
|
|
259
|
+
otherWords = _arrayLikeToArray(_splitOnQuotes$filter2).slice(1);
|
|
234
260
|
this.$emit('input', firstWord);
|
|
235
261
|
if (otherWords.length) {
|
|
236
262
|
/**
|
|
@@ -253,19 +279,16 @@ var script = {
|
|
|
253
279
|
},
|
|
254
280
|
getMatchingOptionForInputValue(inputValue) {
|
|
255
281
|
var _this$options3;
|
|
256
|
-
let {
|
|
257
|
-
|
|
258
|
-
|
|
259
|
-
loose
|
|
260
|
-
};
|
|
282
|
+
let _ref2 = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {
|
|
283
|
+
loose: false
|
|
284
|
+
},
|
|
285
|
+
loose = _ref2.loose;
|
|
261
286
|
return (_this$options3 = this.options) === null || _this$options3 === void 0 ? void 0 : _this$options3.find(option => loose ? match(option[this.optionTextField], inputValue) : option[this.optionTextField] === inputValue);
|
|
262
287
|
},
|
|
263
288
|
activate() {
|
|
264
289
|
this.fallbackValue = this.value;
|
|
265
290
|
this.$nextTick(() => {
|
|
266
|
-
const
|
|
267
|
-
input
|
|
268
|
-
} = this.$refs;
|
|
291
|
+
const input = this.$refs.input;
|
|
269
292
|
if (input) {
|
|
270
293
|
input.focus();
|
|
271
294
|
input.scrollIntoView({
|
|
@@ -307,13 +330,10 @@ var script = {
|
|
|
307
330
|
return (_option$value = option.value) === null || _option$value === void 0 ? void 0 : _option$value.toString().startsWith('gl-filtered-search-suggestion-group-');
|
|
308
331
|
},
|
|
309
332
|
handleInputKeydown(e) {
|
|
310
|
-
const
|
|
311
|
-
|
|
312
|
-
|
|
313
|
-
|
|
314
|
-
suggestions,
|
|
315
|
-
input
|
|
316
|
-
} = this.$refs;
|
|
333
|
+
const key = e.key;
|
|
334
|
+
const _this$$refs = this.$refs,
|
|
335
|
+
suggestions = _this$$refs.suggestions,
|
|
336
|
+
input = _this$$refs.input;
|
|
317
337
|
const suggestedValue = suggestions === null || suggestions === void 0 ? void 0 : suggestions.getValue();
|
|
318
338
|
const handlers = {
|
|
319
339
|
ArrowLeft: () => {
|
|
@@ -1,6 +1,55 @@
|
|
|
1
1
|
import { first, last, isString } from 'lodash-es';
|
|
2
2
|
import { modulo } from '../../../utils/number_utils';
|
|
3
3
|
|
|
4
|
+
function _arrayLikeToArray(r, a) {
|
|
5
|
+
(null == a || a > r.length) && (a = r.length);
|
|
6
|
+
for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e];
|
|
7
|
+
return n;
|
|
8
|
+
}
|
|
9
|
+
function _arrayWithHoles(r) {
|
|
10
|
+
if (Array.isArray(r)) return r;
|
|
11
|
+
}
|
|
12
|
+
function _iterableToArrayLimit(r, l) {
|
|
13
|
+
var t = null == r ? null : "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"];
|
|
14
|
+
if (null != t) {
|
|
15
|
+
var e,
|
|
16
|
+
n,
|
|
17
|
+
i,
|
|
18
|
+
u,
|
|
19
|
+
a = [],
|
|
20
|
+
f = !0,
|
|
21
|
+
o = !1;
|
|
22
|
+
try {
|
|
23
|
+
if (i = (t = t.call(r)).next, 0 === l) {
|
|
24
|
+
if (Object(t) !== t) return;
|
|
25
|
+
f = !1;
|
|
26
|
+
} else for (; !(f = (e = i.call(t)).done) && (a.push(e.value), a.length !== l); f = !0);
|
|
27
|
+
} catch (r) {
|
|
28
|
+
o = !0, n = r;
|
|
29
|
+
} finally {
|
|
30
|
+
try {
|
|
31
|
+
if (!f && null != t.return && (u = t.return(), Object(u) !== u)) return;
|
|
32
|
+
} finally {
|
|
33
|
+
if (o) throw n;
|
|
34
|
+
}
|
|
35
|
+
}
|
|
36
|
+
return a;
|
|
37
|
+
}
|
|
38
|
+
}
|
|
39
|
+
function _nonIterableRest() {
|
|
40
|
+
throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
|
|
41
|
+
}
|
|
42
|
+
function _slicedToArray(r, e) {
|
|
43
|
+
return _arrayWithHoles(r) || _iterableToArrayLimit(r, e) || _unsupportedIterableToArray(r, e) || _nonIterableRest();
|
|
44
|
+
}
|
|
45
|
+
function _unsupportedIterableToArray(r, a) {
|
|
46
|
+
if (r) {
|
|
47
|
+
if ("string" == typeof r) return _arrayLikeToArray(r, a);
|
|
48
|
+
var t = {}.toString.call(r).slice(8, -1);
|
|
49
|
+
return "Object" === t && r.constructor && (t = r.constructor.name), "Map" === t || "Set" === t ? Array.from(r) : "Arguments" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray(r, a) : void 0;
|
|
50
|
+
}
|
|
51
|
+
}
|
|
52
|
+
|
|
4
53
|
const TERM_TOKEN_TYPE = 'filtered-search-term';
|
|
5
54
|
const INTENT_ACTIVATE_PREVIOUS = 'intent-activate-previous';
|
|
6
55
|
const TOKEN_CLOSE_SELECTOR = '.gl-token-close';
|
|
@@ -88,12 +137,10 @@ function stepIndexAndWrap(index, step, length) {
|
|
|
88
137
|
* options prop).
|
|
89
138
|
*/
|
|
90
139
|
function tokenToOption(_ref) {
|
|
91
|
-
let
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
optionComponent
|
|
96
|
-
} = _ref;
|
|
140
|
+
let icon = _ref.icon,
|
|
141
|
+
title = _ref.title,
|
|
142
|
+
type = _ref.type,
|
|
143
|
+
optionComponent = _ref.optionComponent;
|
|
97
144
|
return {
|
|
98
145
|
icon,
|
|
99
146
|
title,
|
|
@@ -194,7 +241,10 @@ function splitOnQuotes(str) {
|
|
|
194
241
|
result.push(part);
|
|
195
242
|
}
|
|
196
243
|
} else {
|
|
197
|
-
const
|
|
244
|
+
const _part$split = part.split('"', 2),
|
|
245
|
+
_part$split2 = _slicedToArray(_part$split, 2),
|
|
246
|
+
firstPart = _part$split2[0],
|
|
247
|
+
secondPart = _part$split2[1];
|
|
198
248
|
if (waitingForMatchingQuote) {
|
|
199
249
|
waitingForMatchingQuote = false;
|
|
200
250
|
quoteContent += ` ${firstPart}"`;
|
|
@@ -146,10 +146,8 @@ var script = {
|
|
|
146
146
|
return this.computedState === false ? 'true' : null;
|
|
147
147
|
},
|
|
148
148
|
isChecked() {
|
|
149
|
-
const
|
|
150
|
-
|
|
151
|
-
computedLocalChecked: checked
|
|
152
|
-
} = this;
|
|
149
|
+
const value = this.value,
|
|
150
|
+
checked = this.computedLocalChecked;
|
|
153
151
|
return Array.isArray(checked) ? looseIndexOf(checked, value) > -1 : looseEqual(checked, value);
|
|
154
152
|
},
|
|
155
153
|
isDisabled() {
|
|
@@ -167,12 +165,10 @@ var script = {
|
|
|
167
165
|
return (this.isGroup ? this.group.groupName : this.name) || null;
|
|
168
166
|
},
|
|
169
167
|
computedAttrs() {
|
|
170
|
-
const
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
isChecked: checked
|
|
175
|
-
} = this;
|
|
168
|
+
const disabled = this.isDisabled,
|
|
169
|
+
required = this.isRequired,
|
|
170
|
+
value = this.value,
|
|
171
|
+
checked = this.isChecked;
|
|
176
172
|
return {
|
|
177
173
|
...this.$attrs,
|
|
178
174
|
id: this.internalId,
|
|
@@ -219,25 +215,18 @@ var script = {
|
|
|
219
215
|
* @event input
|
|
220
216
|
*/
|
|
221
217
|
this.$emit('input', newValue);
|
|
222
|
-
const
|
|
223
|
-
input
|
|
224
|
-
} = this.$refs;
|
|
218
|
+
const input = this.$refs.input;
|
|
225
219
|
if (input) {
|
|
226
220
|
this.$emit('update:indeterminate', input.indeterminate);
|
|
227
221
|
}
|
|
228
222
|
}
|
|
229
223
|
},
|
|
230
224
|
handleChange(_ref) {
|
|
231
|
-
let
|
|
232
|
-
target
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
} = _ref;
|
|
237
|
-
const {
|
|
238
|
-
value,
|
|
239
|
-
uncheckedValue
|
|
240
|
-
} = this;
|
|
225
|
+
let _ref$target = _ref.target,
|
|
226
|
+
checked = _ref$target.checked,
|
|
227
|
+
indeterminate = _ref$target.indeterminate;
|
|
228
|
+
const value = this.value,
|
|
229
|
+
uncheckedValue = this.uncheckedValue;
|
|
241
230
|
|
|
242
231
|
// Update `computedLocalChecked`
|
|
243
232
|
let localChecked = this.computedLocalChecked;
|
|
@@ -279,9 +268,7 @@ var script = {
|
|
|
279
268
|
setIndeterminate(state) {
|
|
280
269
|
// Indeterminate only supported in single checkbox mode
|
|
281
270
|
const computedState = Array.isArray(this.computedLocalChecked) ? false : state;
|
|
282
|
-
const
|
|
283
|
-
input
|
|
284
|
-
} = this.$refs;
|
|
271
|
+
const input = this.$refs.input;
|
|
285
272
|
if (input) {
|
|
286
273
|
input.indeterminate = computedState;
|
|
287
274
|
// Emit update event to prop
|
|
@@ -105,9 +105,7 @@ var script = {
|
|
|
105
105
|
return isBoolean(this.state) ? this.state : null;
|
|
106
106
|
},
|
|
107
107
|
computedAriaInvalid() {
|
|
108
|
-
const
|
|
109
|
-
ariaInvalid
|
|
110
|
-
} = this;
|
|
108
|
+
const ariaInvalid = this.ariaInvalid;
|
|
111
109
|
if (ariaInvalid === true || ariaInvalid === 'true' || ariaInvalid === '') {
|
|
112
110
|
return 'true';
|
|
113
111
|
}
|