aloha-vue 2.85.0 → 2.87.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/CHANGELOG.md +1215 -1200
- package/README.md +117 -117
- package/dist/aloha-vue.css +13827 -13601
- package/dist/aloha-vue.css.map +1 -1
- package/dist/aloha-vue.es.js +60235 -57401
- package/dist/aloha-vue.umd.js +319 -319
- package/package.json +1 -1
- package/scss/components/AButton.scss +6 -6
- package/scss/components/ADivider.scss +9 -9
- package/scss/components/AElement.scss +6 -6
- package/scss/components/AGroupButtonDropdown.scss +4 -4
- package/scss/components/AIcon.scss +17 -17
- package/scss/components/ALoading.scss +18 -18
- package/scss/components/AMenu.scss +634 -634
- package/scss/components/AProgressCirle.scss +43 -43
- package/scss/components/AShowMore.scss +9 -9
- package/scss/components/ATableForm.scss +7 -7
- package/scss/components/ATabs.scss +186 -186
- package/scss/components/ui/AColorPicker.scss +243 -0
- package/scss/components/ui/AJson.scss +11 -11
- package/scss/components/ui/ui.scss +1 -0
- package/scss/text/text_line_height.scss +17 -17
- package/scss/text/text_size.scss +88 -88
- package/scss/utils/acordion.scss +173 -173
- package/scss/utils/alert.scss +81 -81
- package/scss/utils/aloha_prefix.scss +1 -1
- package/scss/utils/backdrop.scss +24 -24
- package/scss/utils/border.scss +65 -65
- package/scss/utils/breakpoint.scss +48 -48
- package/scss/utils/button_close.scss +22 -22
- package/scss/utils/button_group.scss +69 -69
- package/scss/utils/color_utils.scss +234 -234
- package/scss/utils/display.scss +67 -67
- package/scss/utils/flex.scss +141 -141
- package/scss/utils/float.scss +10 -10
- package/scss/utils/global.scss +44 -44
- package/scss/utils/global_variables.scss +26 -26
- package/scss/utils/grid.scss +95 -95
- package/scss/utils/list_columns.scss +31 -31
- package/scss/utils/list_group.scss +127 -127
- package/scss/utils/notification.scss +36 -36
- package/scss/utils/overflow.scss +40 -40
- package/scss/utils/pagination.scss +94 -94
- package/scss/utils/position.scss +90 -90
- package/scss/utils/progress.scss +70 -70
- package/scss/utils/screenreader.scss +16 -16
- package/scss/utils/spinner.scss +35 -35
- package/scss/utils/utils.scss +19 -19
- package/scss/utils/vars_global.scss +12 -12
- package/src/AAlert/i18n/AAlertI18n.js +4 -0
- package/src/AAlert/i18n/nl.json +3 -0
- package/src/AAlert/i18n/pl.json +3 -0
- package/src/ACarousel/i18n/ACarouselI18n.js +4 -0
- package/src/ACarousel/i18n/nl.json +9 -0
- package/src/ACarousel/i18n/pl.json +9 -0
- package/src/ACloak/i18n/ACloakI18n.js +4 -0
- package/src/ACloak/i18n/nl.json +3 -0
- package/src/ACloak/i18n/pl.json +3 -0
- package/src/ADisclosure/i18n/ADisclosureI18n.js +4 -0
- package/src/ADisclosure/i18n/nl.json +4 -0
- package/src/ADisclosure/i18n/pl.json +4 -0
- package/src/AFilters/i18n/AFiltersI18n.js +4 -0
- package/src/AFilters/i18n/nl.json +30 -0
- package/src/AFilters/i18n/pl.json +30 -0
- package/src/AGroupButtonDropdown/AGroupButtonDropdown.js +119 -119
- package/src/ALinkCopy/i18n/ALinkCopyI18n.js +4 -0
- package/src/ALinkCopy/i18n/nl.json +4 -0
- package/src/ALinkCopy/i18n/pl.json +4 -0
- package/src/ALoading/i18n/ALoadingI18n.js +4 -0
- package/src/ALoading/i18n/nl.json +3 -0
- package/src/ALoading/i18n/pl.json +3 -0
- package/src/AMenu/i18n/AMenu2I18n.js +4 -0
- package/src/AMenu/i18n/nl.json +14 -0
- package/src/AMenu/i18n/pl.json +14 -0
- package/src/AModal/compositionAPI/ZIndexAPI.js +48 -48
- package/src/AModal/i18n/AModalI18n.js +4 -0
- package/src/AModal/i18n/nl.json +7 -0
- package/src/AModal/i18n/pl.json +7 -0
- package/src/APagination/i18n/APaginationI18n.js +4 -0
- package/src/APagination/i18n/nl.json +12 -0
- package/src/APagination/i18n/pl.json +12 -0
- package/src/AProgress/AProgress.js +141 -141
- package/src/AProgressCircle/AProgressCircle.js +160 -160
- package/src/AShowMore/i18n/AShowMoreI18n.js +4 -0
- package/src/AShowMore/i18n/nl.json +6 -0
- package/src/AShowMore/i18n/pl.json +6 -0
- package/src/ASpinner/i18n/ASpinnerI18n.js +4 -0
- package/src/ASpinner/i18n/nl.json +3 -0
- package/src/ASpinner/i18n/pl.json +3 -0
- package/src/ATable/ATableHeaderTh/ATableHeaderTh.js +188 -188
- package/src/ATable/i18n/ATableI18n.js +4 -0
- package/src/ATable/i18n/nl.json +54 -0
- package/src/ATable/i18n/pl.json +54 -0
- package/src/ATableForm/i18n/ATableFormI18n.js +4 -0
- package/src/ATableForm/i18n/nl.json +18 -0
- package/src/ATableForm/i18n/pl.json +18 -0
- package/src/ATranslation/compositionAPI/UtilsAPI.js +6 -1
- package/src/ATranslation/compositionAPI/__tests__/UtilsAPI.getTranslatedText.test.js +38 -0
- package/src/AVerticalScroll/i18n/AVerticalScrollI18n.js +4 -0
- package/src/AVerticalScroll/i18n/nl.json +4 -0
- package/src/AVerticalScroll/i18n/pl.json +4 -0
- package/src/AWizard/i18n/AWizardI18n.js +4 -0
- package/src/AWizard/i18n/nl.json +16 -0
- package/src/AWizard/i18n/pl.json +16 -0
- package/src/PVP/new.txt +39 -39
- package/src/PuxDatepicker/PuxDatepicker.js +670 -670
- package/src/PuxDatepicker/PuxDatepicker.pug +131 -131
- package/src/PuxDatepicker/PuxDatepicker.vue +2 -2
- package/src/PuxDatepicker/PuxDatepickerCalendarPanel/PuxDatepickerCalendarPanel.pug +136 -136
- package/src/PuxDatepicker/PuxDatepickerCalendarPanel/PuxDatepickerCalendarPanel.vue +2 -2
- package/src/PuxDatepicker/PuxDatepickerIcon/PuxDatepickerIcon.js +30 -30
- package/src/PuxDatepicker/PuxDatepickerIcon/PuxDatepickerIcon.pug +6 -6
- package/src/PuxDatepicker/PuxDatepickerIcon/PuxDatepickerIcon.vue +2 -2
- package/src/PuxDatepicker/locale/languages.js +174 -174
- package/src/PuxDatepicker/mixins/PanelMixin.js +76 -76
- package/src/PuxDatepicker/panel/PanelDate/PanelDate.pug +41 -41
- package/src/PuxDatepicker/panel/PanelDate/PanelDate.vue +2 -2
- package/src/PuxDatepicker/panel/PanelMonth/PanelMonth.pug +16 -16
- package/src/PuxDatepicker/panel/PanelMonth/PanelMonth.vue +2 -2
- package/src/PuxDatepicker/panel/PanelTime/PanelTime.pug +20 -20
- package/src/PuxDatepicker/panel/PanelTime/PanelTime.vue +2 -2
- package/src/PuxDatepicker/panel/PanelYear/PanelYear.pug +16 -16
- package/src/PuxDatepicker/panel/PanelYear/PanelYear.vue +2 -2
- package/src/PuxDatepicker/panel/PanelYearItem/PanelYearItem.js +55 -55
- package/src/PuxDatepicker/panel/PanelYearItem/PanelYearItem.pug +9 -9
- package/src/PuxDatepicker/panel/PanelYearItem/PanelYearItem.vue +2 -2
- package/src/PuxDatepicker/utils/keysCode.js +9 -9
- package/src/PuxDatepicker/utils/scroll-into-view.js +23 -23
- package/src/PuxDatepicker/utils/transform.js +23 -23
- package/src/filters/i18n/Filters18n.js +4 -0
- package/src/filters/i18n/nl.json +11 -0
- package/src/filters/i18n/pl.json +11 -0
- package/src/i18n/allLanguages.js +96 -0
- package/src/i18n/nl.json +4 -0
- package/src/i18n/pl.json +4 -0
- package/src/index.js +4 -0
- package/src/ui/ACheckbox/ACheckbox.js +5 -0
- package/src/ui/ACheckbox/i18n/ACheckboxI18n.js +4 -0
- package/src/ui/ACheckbox/i18n/nl.json +5 -0
- package/src/ui/ACheckbox/i18n/pl.json +5 -0
- package/src/ui/AColorPicker/AColorPicker.js +743 -0
- package/src/ui/AColorPicker/AColorPickerSaturation/AColorPickerSaturation.js +102 -0
- package/src/ui/AColorPicker/AColorPickerSaturation/compositionAPI/SaturationAPI.js +77 -0
- package/src/ui/AColorPicker/AColorPickerSlider/AColorPickerSlider.js +125 -0
- package/src/ui/AColorPicker/AColorPickerSlider/compositionAPI/SliderAPI.js +73 -0
- package/src/ui/AColorPicker/__tests__/AColorPicker.test.js +204 -0
- package/src/ui/AColorPicker/__tests__/colorUtils.test.js +104 -0
- package/src/ui/AColorPicker/compositionAPI/ColorStateAPI.js +133 -0
- package/src/ui/AColorPicker/compositionAPI/ConfirmAPI.js +36 -0
- package/src/ui/AColorPicker/compositionAPI/FormatAPI.js +59 -0
- package/src/ui/AColorPicker/compositionAPI/InputAPI.js +63 -0
- package/src/ui/AColorPicker/compositionAPI/KeyboardStepAPI.js +42 -0
- package/src/ui/AColorPicker/compositionAPI/PointerDragAPI.js +70 -0
- package/src/ui/AColorPicker/compositionAPI/PopoverAPI.js +196 -0
- package/src/ui/AColorPicker/compositionAPI/PredefineAPI.js +42 -0
- package/src/ui/AColorPicker/compositionAPI/ToggleClassAPI.js +24 -0
- package/src/ui/AColorPicker/i18n/AColorPickerI18n.js +25 -0
- package/src/ui/AColorPicker/i18n/ar.json +14 -0
- package/src/ui/AColorPicker/i18n/de.json +14 -0
- package/src/ui/AColorPicker/i18n/en.json +14 -0
- package/src/ui/AColorPicker/i18n/es.json +14 -0
- package/src/ui/AColorPicker/i18n/fr.json +14 -0
- package/src/ui/AColorPicker/i18n/hr.json +14 -0
- package/src/ui/AColorPicker/i18n/it.json +14 -0
- package/src/ui/AColorPicker/i18n/nl.json +14 -0
- package/src/ui/AColorPicker/i18n/pl.json +14 -0
- package/src/ui/AColorPicker/i18n/ru.json +14 -0
- package/src/ui/AColorPicker/i18n/uk.json +14 -0
- package/src/ui/AColorPicker/utils/colorUtils.js +296 -0
- package/src/ui/ADatepicker/ADatepickerCalendarPanel/ADatepickerCalendarPanel.js +68 -68
- package/src/ui/ADatepicker/i18n/ADatepickerI18n.js +4 -0
- package/src/ui/ADatepicker/i18n/nl.json +58 -0
- package/src/ui/ADatepicker/i18n/pl.json +58 -0
- package/src/ui/ADatepicker/panel/APanelTime/APanelTime.js +147 -147
- package/src/ui/ADatepicker/panel/APanelYear/APanelYear.js +123 -123
- package/src/ui/ADatepickerAlt/ADatepickerCalendarPanel/ADatepickerCalendarPanel.js +804 -804
- package/src/ui/ADatepickerAlt/panel/APanelDate/APanelDate.js +353 -353
- package/src/ui/ADatepickerAlt/panel/APanelMonth/APanelMonth.js +187 -187
- package/src/ui/ADatepickerAlt/panel/APanelTime/APanelTime.js +303 -303
- package/src/ui/ADatepickerAlt/panel/APanelYear/APanelYear.js +162 -162
- package/src/ui/ADatepickerRange/i18n/ADatepickerRangeI18n.js +4 -0
- package/src/ui/ADatepickerRange/i18n/nl.json +4 -0
- package/src/ui/ADatepickerRange/i18n/pl.json +4 -0
- package/src/ui/AErrors/i18n/AErrorsI18n.js +4 -0
- package/src/ui/AErrors/i18n/nl.json +3 -0
- package/src/ui/AErrors/i18n/pl.json +3 -0
- package/src/ui/AFieldset/__tests__/AFieldset.ClassColumn.test.js +1 -0
- package/src/ui/AFieldset/i18n/AFieldsetI18n.js +4 -0
- package/src/ui/AFieldset/i18n/nl.json +4 -0
- package/src/ui/AFieldset/i18n/pl.json +4 -0
- package/src/ui/AFormElementBtnClear/i18n/AFormElementBtnClearI18n.js +4 -0
- package/src/ui/AFormElementBtnClear/i18n/nl.json +3 -0
- package/src/ui/AFormElementBtnClear/i18n/pl.json +3 -0
- package/src/ui/AInput/i18n/AInputI18n.js +4 -0
- package/src/ui/AInput/i18n/nl.json +4 -0
- package/src/ui/AInput/i18n/pl.json +4 -0
- package/src/ui/AInputCurrency/i18n/AInputCurrencyI18n.js +4 -0
- package/src/ui/AInputCurrency/i18n/nl.json +4 -0
- package/src/ui/AInputCurrency/i18n/pl.json +4 -0
- package/src/ui/AInputNumber/i18n/AInputNumberI18n.js +4 -0
- package/src/ui/AInputNumber/i18n/nl.json +4 -0
- package/src/ui/AInputNumber/i18n/pl.json +4 -0
- package/src/ui/AInputNumberRange/i18n/AInputNumberRangeI18n.js +4 -0
- package/src/ui/AInputNumberRange/i18n/nl.json +4 -0
- package/src/ui/AInputNumberRange/i18n/pl.json +4 -0
- package/src/ui/AJson/i18n/AJsonI18n.js +4 -0
- package/src/ui/AJson/i18n/nl.json +8 -0
- package/src/ui/AJson/i18n/pl.json +8 -0
- package/src/ui/AMultiselectOrdered/i18n/AMultiselectOrderedI18n.js +4 -0
- package/src/ui/AMultiselectOrdered/i18n/nl.json +12 -0
- package/src/ui/AMultiselectOrdered/i18n/pl.json +12 -0
- package/src/ui/ARadio/i18n/ARadioI18n.js +4 -0
- package/src/ui/ARadio/i18n/nl.json +5 -0
- package/src/ui/ARadio/i18n/pl.json +5 -0
- package/src/ui/ARequired/i18n/ARequiredI18n.js +4 -0
- package/src/ui/ARequired/i18n/nl.json +3 -0
- package/src/ui/ARequired/i18n/pl.json +3 -0
- package/src/ui/ARouterLinkConfig/i18n/ARouterLinkConfigI18n.js +4 -0
- package/src/ui/ARouterLinkConfig/i18n/nl.json +14 -0
- package/src/ui/ARouterLinkConfig/i18n/pl.json +14 -0
- package/src/ui/ASelect/i18n/ASelectI18n.js +4 -0
- package/src/ui/ASelect/i18n/ar.json +5 -5
- package/src/ui/ASelect/i18n/de.json +4 -4
- package/src/ui/ASelect/i18n/en.json +5 -5
- package/src/ui/ASelect/i18n/es.json +5 -5
- package/src/ui/ASelect/i18n/fr.json +5 -5
- package/src/ui/ASelect/i18n/hr.json +5 -5
- package/src/ui/ASelect/i18n/it.json +5 -5
- package/src/ui/ASelect/i18n/nl.json +11 -0
- package/src/ui/ASelect/i18n/pl.json +11 -0
- package/src/ui/ASelect/i18n/ru.json +5 -5
- package/src/ui/ASelectStyle/i18n/ASelectStyleI18n.js +4 -0
- package/src/ui/ASelectStyle/i18n/nl.json +292 -0
- package/src/ui/ASelectStyle/i18n/pl.json +292 -0
- package/src/ui/ASlider/i18n/ASliderI18n.js +4 -0
- package/src/ui/ASlider/i18n/nl.json +5 -0
- package/src/ui/ASlider/i18n/pl.json +5 -0
- package/src/ui/ASwitch/i18n/ASwitchI18n.js +4 -0
- package/src/ui/ASwitch/i18n/nl.json +5 -0
- package/src/ui/ASwitch/i18n/pl.json +5 -0
- package/src/ui/AUiComponents.js +2 -0
- package/src/ui/AValidatedJson/i18n/AValidatedJsonI18n.js +4 -0
- package/src/ui/AValidatedJson/i18n/nl.json +25 -0
- package/src/ui/AValidatedJson/i18n/pl.json +25 -0
- package/src/ui/compositionApi/__tests__/UiStyleHideAPI.test.js +9 -4
|
@@ -1,162 +1,162 @@
|
|
|
1
|
-
/* eslint vue/component-api-style: off */
|
|
2
|
-
import {
|
|
3
|
-
h,
|
|
4
|
-
} from "vue";
|
|
5
|
-
|
|
6
|
-
import APanelYearItem from "../APanelYearItem/APanelYearItem";
|
|
7
|
-
|
|
8
|
-
import AKeysCode from "../../../../const/AKeysCode";
|
|
9
|
-
import PanelMixin from "../../mixins/PanelMixin";
|
|
10
|
-
import {
|
|
11
|
-
isUndefined,
|
|
12
|
-
range,
|
|
13
|
-
} from "lodash-es";
|
|
14
|
-
|
|
15
|
-
// @vue/component
|
|
16
|
-
export default {
|
|
17
|
-
name: "APanelYear",
|
|
18
|
-
mixins: [
|
|
19
|
-
PanelMixin,
|
|
20
|
-
],
|
|
21
|
-
props: {
|
|
22
|
-
value: {
|
|
23
|
-
type: [String, Number, Boolean, Array, Object, Date, Function, Symbol],
|
|
24
|
-
required: false,
|
|
25
|
-
default: undefined,
|
|
26
|
-
},
|
|
27
|
-
firstYear: {
|
|
28
|
-
type: Number,
|
|
29
|
-
required: true,
|
|
30
|
-
},
|
|
31
|
-
disabledYear: {
|
|
32
|
-
type: Function,
|
|
33
|
-
required: false,
|
|
34
|
-
default: undefined,
|
|
35
|
-
},
|
|
36
|
-
},
|
|
37
|
-
emits: [
|
|
38
|
-
"handleIconYear",
|
|
39
|
-
"select",
|
|
40
|
-
],
|
|
41
|
-
data() {
|
|
42
|
-
return {
|
|
43
|
-
yearIndexForFocus: undefined,
|
|
44
|
-
};
|
|
45
|
-
},
|
|
46
|
-
computed: {
|
|
47
|
-
firstYearLocal() {
|
|
48
|
-
return Math.floor(this.firstYear / 10) * 10;
|
|
49
|
-
},
|
|
50
|
-
|
|
51
|
-
yearFromValue() {
|
|
52
|
-
return this.value && new Date(this.value).getFullYear();
|
|
53
|
-
},
|
|
54
|
-
|
|
55
|
-
idForFocus() {
|
|
56
|
-
if (!isUndefined(this.yearIndexForFocus)) {
|
|
57
|
-
return this.getIdForYear(this.yearIndexForFocus);
|
|
58
|
-
}
|
|
59
|
-
return "";
|
|
60
|
-
},
|
|
61
|
-
|
|
62
|
-
yearIndexFromValueOrToday() {
|
|
63
|
-
const DIFF_FIRST_AND_VALUE_YEAR = this.yearFromValueOrToday - this.firstYearLocal;
|
|
64
|
-
if (DIFF_FIRST_AND_VALUE_YEAR <= 9 && DIFF_FIRST_AND_VALUE_YEAR >= 0) {
|
|
65
|
-
return DIFF_FIRST_AND_VALUE_YEAR;
|
|
66
|
-
}
|
|
67
|
-
return 0;
|
|
68
|
-
},
|
|
69
|
-
|
|
70
|
-
yearFromValueOrToday() {
|
|
71
|
-
return this.yearFromValue || new Date().getFullYear();
|
|
72
|
-
},
|
|
73
|
-
|
|
74
|
-
prefixForId() {
|
|
75
|
-
return `${ this.id }_year_`;
|
|
76
|
-
},
|
|
77
|
-
},
|
|
78
|
-
methods: {
|
|
79
|
-
isDisabled(year) {
|
|
80
|
-
return !!(typeof this.disabledYear === "function" && this.disabledYear(year));
|
|
81
|
-
},
|
|
82
|
-
|
|
83
|
-
selectYear({ year, isButtonClick }) {
|
|
84
|
-
if (this.isDisabled(year)) {
|
|
85
|
-
return;
|
|
86
|
-
}
|
|
87
|
-
this.$emit("select", ({ year, isButtonClick }));
|
|
88
|
-
},
|
|
89
|
-
|
|
90
|
-
getIdForYear(yearIndex) {
|
|
91
|
-
return `${ this.prefixForId }${ yearIndex }`;
|
|
92
|
-
},
|
|
93
|
-
|
|
94
|
-
setFocusToActiveYear() {
|
|
95
|
-
setTimeout(() => {
|
|
96
|
-
this.setDefaultYearForFocus();
|
|
97
|
-
document.getElementById(this.idForFocus).focus();
|
|
98
|
-
this.setListenerForPressButtons();
|
|
99
|
-
});
|
|
100
|
-
},
|
|
101
|
-
|
|
102
|
-
setDefaultYearForFocus() {
|
|
103
|
-
this.yearIndexForFocus = this.yearIndexFromValueOrToday;
|
|
104
|
-
},
|
|
105
|
-
|
|
106
|
-
pressButton($event) {
|
|
107
|
-
const KEY_CODE = $event.keyCode;
|
|
108
|
-
if (KEY_CODE === AKeysCode.arrowUp || KEY_CODE === AKeysCode.arrowLeft) {
|
|
109
|
-
this.setFocusToLastYear();
|
|
110
|
-
this.stopCurrentEvent($event);
|
|
111
|
-
} else if (KEY_CODE === AKeysCode.arrowDown || KEY_CODE === AKeysCode.arrowRight) {
|
|
112
|
-
this.setFocusToNextYear();
|
|
113
|
-
this.stopCurrentEvent($event);
|
|
114
|
-
}
|
|
115
|
-
},
|
|
116
|
-
|
|
117
|
-
setFocusToLastYear() {
|
|
118
|
-
const NEW_YEAR_FOR_FOCUS = this.yearIndexForFocus - 1;
|
|
119
|
-
if (NEW_YEAR_FOR_FOCUS >= 0 && NEW_YEAR_FOR_FOCUS <= 9) {
|
|
120
|
-
this.yearIndexForFocus = NEW_YEAR_FOR_FOCUS;
|
|
121
|
-
} else {
|
|
122
|
-
this.$emit("handleIconYear", -1);
|
|
123
|
-
this.yearIndexForFocus = 9;
|
|
124
|
-
}
|
|
125
|
-
this.setFocusToElementWithTimeout(this.idForFocus);
|
|
126
|
-
},
|
|
127
|
-
|
|
128
|
-
setFocusToNextYear() {
|
|
129
|
-
const NEW_YEAR_FOR_FOCUS = this.yearIndexForFocus + 1;
|
|
130
|
-
if (NEW_YEAR_FOR_FOCUS <= 9 && NEW_YEAR_FOR_FOCUS >= 0) {
|
|
131
|
-
this.yearIndexForFocus = NEW_YEAR_FOR_FOCUS;
|
|
132
|
-
} else {
|
|
133
|
-
this.$emit("handleIconYear", 1);
|
|
134
|
-
this.yearIndexForFocus = 0;
|
|
135
|
-
}
|
|
136
|
-
this.setFocusToElementWithTimeout(this.idForFocus);
|
|
137
|
-
},
|
|
138
|
-
},
|
|
139
|
-
render() {
|
|
140
|
-
return h("ul", {
|
|
141
|
-
class: "pux_datepicker__panel pux_datepicker__panel_year pux_datepicker__panel__list",
|
|
142
|
-
role: "listbox",
|
|
143
|
-
"aria-labelledby": this.idForHeader,
|
|
144
|
-
...this.attributesForMainElement,
|
|
145
|
-
}, [
|
|
146
|
-
range(10).map(index => {
|
|
147
|
-
return h(APanelYearItem, {
|
|
148
|
-
key: index,
|
|
149
|
-
class: {
|
|
150
|
-
pux_datepicker__panel__cell_focus: index === this.yearIndexForFocus,
|
|
151
|
-
},
|
|
152
|
-
year: this.firstYearLocal + index,
|
|
153
|
-
yearFromValue: this.yearFromValue,
|
|
154
|
-
yearIndex: index,
|
|
155
|
-
prefixForId: this.prefixForId,
|
|
156
|
-
isDisabled: this.isDisabled,
|
|
157
|
-
onSelectYear: this.selectYear,
|
|
158
|
-
});
|
|
159
|
-
}),
|
|
160
|
-
]);
|
|
161
|
-
},
|
|
162
|
-
};
|
|
1
|
+
/* eslint vue/component-api-style: off */
|
|
2
|
+
import {
|
|
3
|
+
h,
|
|
4
|
+
} from "vue";
|
|
5
|
+
|
|
6
|
+
import APanelYearItem from "../APanelYearItem/APanelYearItem";
|
|
7
|
+
|
|
8
|
+
import AKeysCode from "../../../../const/AKeysCode";
|
|
9
|
+
import PanelMixin from "../../mixins/PanelMixin";
|
|
10
|
+
import {
|
|
11
|
+
isUndefined,
|
|
12
|
+
range,
|
|
13
|
+
} from "lodash-es";
|
|
14
|
+
|
|
15
|
+
// @vue/component
|
|
16
|
+
export default {
|
|
17
|
+
name: "APanelYear",
|
|
18
|
+
mixins: [
|
|
19
|
+
PanelMixin,
|
|
20
|
+
],
|
|
21
|
+
props: {
|
|
22
|
+
value: {
|
|
23
|
+
type: [String, Number, Boolean, Array, Object, Date, Function, Symbol],
|
|
24
|
+
required: false,
|
|
25
|
+
default: undefined,
|
|
26
|
+
},
|
|
27
|
+
firstYear: {
|
|
28
|
+
type: Number,
|
|
29
|
+
required: true,
|
|
30
|
+
},
|
|
31
|
+
disabledYear: {
|
|
32
|
+
type: Function,
|
|
33
|
+
required: false,
|
|
34
|
+
default: undefined,
|
|
35
|
+
},
|
|
36
|
+
},
|
|
37
|
+
emits: [
|
|
38
|
+
"handleIconYear",
|
|
39
|
+
"select",
|
|
40
|
+
],
|
|
41
|
+
data() {
|
|
42
|
+
return {
|
|
43
|
+
yearIndexForFocus: undefined,
|
|
44
|
+
};
|
|
45
|
+
},
|
|
46
|
+
computed: {
|
|
47
|
+
firstYearLocal() {
|
|
48
|
+
return Math.floor(this.firstYear / 10) * 10;
|
|
49
|
+
},
|
|
50
|
+
|
|
51
|
+
yearFromValue() {
|
|
52
|
+
return this.value && new Date(this.value).getFullYear();
|
|
53
|
+
},
|
|
54
|
+
|
|
55
|
+
idForFocus() {
|
|
56
|
+
if (!isUndefined(this.yearIndexForFocus)) {
|
|
57
|
+
return this.getIdForYear(this.yearIndexForFocus);
|
|
58
|
+
}
|
|
59
|
+
return "";
|
|
60
|
+
},
|
|
61
|
+
|
|
62
|
+
yearIndexFromValueOrToday() {
|
|
63
|
+
const DIFF_FIRST_AND_VALUE_YEAR = this.yearFromValueOrToday - this.firstYearLocal;
|
|
64
|
+
if (DIFF_FIRST_AND_VALUE_YEAR <= 9 && DIFF_FIRST_AND_VALUE_YEAR >= 0) {
|
|
65
|
+
return DIFF_FIRST_AND_VALUE_YEAR;
|
|
66
|
+
}
|
|
67
|
+
return 0;
|
|
68
|
+
},
|
|
69
|
+
|
|
70
|
+
yearFromValueOrToday() {
|
|
71
|
+
return this.yearFromValue || new Date().getFullYear();
|
|
72
|
+
},
|
|
73
|
+
|
|
74
|
+
prefixForId() {
|
|
75
|
+
return `${ this.id }_year_`;
|
|
76
|
+
},
|
|
77
|
+
},
|
|
78
|
+
methods: {
|
|
79
|
+
isDisabled(year) {
|
|
80
|
+
return !!(typeof this.disabledYear === "function" && this.disabledYear(year));
|
|
81
|
+
},
|
|
82
|
+
|
|
83
|
+
selectYear({ year, isButtonClick }) {
|
|
84
|
+
if (this.isDisabled(year)) {
|
|
85
|
+
return;
|
|
86
|
+
}
|
|
87
|
+
this.$emit("select", ({ year, isButtonClick }));
|
|
88
|
+
},
|
|
89
|
+
|
|
90
|
+
getIdForYear(yearIndex) {
|
|
91
|
+
return `${ this.prefixForId }${ yearIndex }`;
|
|
92
|
+
},
|
|
93
|
+
|
|
94
|
+
setFocusToActiveYear() {
|
|
95
|
+
setTimeout(() => {
|
|
96
|
+
this.setDefaultYearForFocus();
|
|
97
|
+
document.getElementById(this.idForFocus).focus();
|
|
98
|
+
this.setListenerForPressButtons();
|
|
99
|
+
});
|
|
100
|
+
},
|
|
101
|
+
|
|
102
|
+
setDefaultYearForFocus() {
|
|
103
|
+
this.yearIndexForFocus = this.yearIndexFromValueOrToday;
|
|
104
|
+
},
|
|
105
|
+
|
|
106
|
+
pressButton($event) {
|
|
107
|
+
const KEY_CODE = $event.keyCode;
|
|
108
|
+
if (KEY_CODE === AKeysCode.arrowUp || KEY_CODE === AKeysCode.arrowLeft) {
|
|
109
|
+
this.setFocusToLastYear();
|
|
110
|
+
this.stopCurrentEvent($event);
|
|
111
|
+
} else if (KEY_CODE === AKeysCode.arrowDown || KEY_CODE === AKeysCode.arrowRight) {
|
|
112
|
+
this.setFocusToNextYear();
|
|
113
|
+
this.stopCurrentEvent($event);
|
|
114
|
+
}
|
|
115
|
+
},
|
|
116
|
+
|
|
117
|
+
setFocusToLastYear() {
|
|
118
|
+
const NEW_YEAR_FOR_FOCUS = this.yearIndexForFocus - 1;
|
|
119
|
+
if (NEW_YEAR_FOR_FOCUS >= 0 && NEW_YEAR_FOR_FOCUS <= 9) {
|
|
120
|
+
this.yearIndexForFocus = NEW_YEAR_FOR_FOCUS;
|
|
121
|
+
} else {
|
|
122
|
+
this.$emit("handleIconYear", -1);
|
|
123
|
+
this.yearIndexForFocus = 9;
|
|
124
|
+
}
|
|
125
|
+
this.setFocusToElementWithTimeout(this.idForFocus);
|
|
126
|
+
},
|
|
127
|
+
|
|
128
|
+
setFocusToNextYear() {
|
|
129
|
+
const NEW_YEAR_FOR_FOCUS = this.yearIndexForFocus + 1;
|
|
130
|
+
if (NEW_YEAR_FOR_FOCUS <= 9 && NEW_YEAR_FOR_FOCUS >= 0) {
|
|
131
|
+
this.yearIndexForFocus = NEW_YEAR_FOR_FOCUS;
|
|
132
|
+
} else {
|
|
133
|
+
this.$emit("handleIconYear", 1);
|
|
134
|
+
this.yearIndexForFocus = 0;
|
|
135
|
+
}
|
|
136
|
+
this.setFocusToElementWithTimeout(this.idForFocus);
|
|
137
|
+
},
|
|
138
|
+
},
|
|
139
|
+
render() {
|
|
140
|
+
return h("ul", {
|
|
141
|
+
class: "pux_datepicker__panel pux_datepicker__panel_year pux_datepicker__panel__list",
|
|
142
|
+
role: "listbox",
|
|
143
|
+
"aria-labelledby": this.idForHeader,
|
|
144
|
+
...this.attributesForMainElement,
|
|
145
|
+
}, [
|
|
146
|
+
range(10).map(index => {
|
|
147
|
+
return h(APanelYearItem, {
|
|
148
|
+
key: index,
|
|
149
|
+
class: {
|
|
150
|
+
pux_datepicker__panel__cell_focus: index === this.yearIndexForFocus,
|
|
151
|
+
},
|
|
152
|
+
year: this.firstYearLocal + index,
|
|
153
|
+
yearFromValue: this.yearFromValue,
|
|
154
|
+
yearIndex: index,
|
|
155
|
+
prefixForId: this.prefixForId,
|
|
156
|
+
isDisabled: this.isDisabled,
|
|
157
|
+
onSelectYear: this.selectYear,
|
|
158
|
+
});
|
|
159
|
+
}),
|
|
160
|
+
]);
|
|
161
|
+
},
|
|
162
|
+
};
|
|
@@ -5,6 +5,8 @@ import es from "./es.json";
|
|
|
5
5
|
import fr from "./fr.json";
|
|
6
6
|
import hr from "./hr.json";
|
|
7
7
|
import it from "./it.json";
|
|
8
|
+
import nl from "./nl.json";
|
|
9
|
+
import pl from "./pl.json";
|
|
8
10
|
import ru from "./ru.json";
|
|
9
11
|
import uk from "./uk.json";
|
|
10
12
|
|
|
@@ -16,6 +18,8 @@ export default {
|
|
|
16
18
|
fr,
|
|
17
19
|
hr,
|
|
18
20
|
it,
|
|
21
|
+
nl,
|
|
22
|
+
pl,
|
|
19
23
|
ru,
|
|
20
24
|
uk,
|
|
21
25
|
};
|
|
@@ -5,6 +5,8 @@ import es from "./es.json";
|
|
|
5
5
|
import fr from "./fr.json";
|
|
6
6
|
import hr from "./hr.json";
|
|
7
7
|
import it from "./it.json";
|
|
8
|
+
import nl from "./nl.json";
|
|
9
|
+
import pl from "./pl.json";
|
|
8
10
|
import ru from "./ru.json";
|
|
9
11
|
import uk from "./uk.json";
|
|
10
12
|
|
|
@@ -16,6 +18,8 @@ export default {
|
|
|
16
18
|
fr,
|
|
17
19
|
hr,
|
|
18
20
|
it,
|
|
21
|
+
nl,
|
|
22
|
+
pl,
|
|
19
23
|
ru,
|
|
20
24
|
uk,
|
|
21
25
|
};
|
|
@@ -60,6 +60,7 @@ vi.mock("../../../index", async() => {
|
|
|
60
60
|
UIExcludeRenderAttributesAPI: () => ({
|
|
61
61
|
attributesToExcludeFromRender: computed(() => ({})),
|
|
62
62
|
}),
|
|
63
|
+
UiModelDependenciesProvideAPI: () => {},
|
|
63
64
|
UiStyleHideAPI: () => ({
|
|
64
65
|
componentStyleHide: computed(() => ""),
|
|
65
66
|
}),
|
|
@@ -5,6 +5,8 @@ import es from "./es.json";
|
|
|
5
5
|
import fr from "./fr.json";
|
|
6
6
|
import hr from "./hr.json";
|
|
7
7
|
import it from "./it.json";
|
|
8
|
+
import nl from "./nl.json";
|
|
9
|
+
import pl from "./pl.json";
|
|
8
10
|
import ru from "./ru.json";
|
|
9
11
|
import uk from "./uk.json";
|
|
10
12
|
|
|
@@ -16,6 +18,8 @@ export default {
|
|
|
16
18
|
fr,
|
|
17
19
|
hr,
|
|
18
20
|
it,
|
|
21
|
+
nl,
|
|
22
|
+
pl,
|
|
19
23
|
ru,
|
|
20
24
|
uk,
|
|
21
25
|
};
|
|
@@ -5,6 +5,8 @@ import es from "./es.json";
|
|
|
5
5
|
import fr from "./fr.json";
|
|
6
6
|
import hr from "./hr.json";
|
|
7
7
|
import it from "./it.json";
|
|
8
|
+
import nl from "./nl.json";
|
|
9
|
+
import pl from "./pl.json";
|
|
8
10
|
import ru from "./ru.json";
|
|
9
11
|
import uk from "./uk.json";
|
|
10
12
|
|
|
@@ -16,6 +18,8 @@ export default {
|
|
|
16
18
|
fr,
|
|
17
19
|
hr,
|
|
18
20
|
it,
|
|
21
|
+
nl,
|
|
22
|
+
pl,
|
|
19
23
|
ru,
|
|
20
24
|
uk,
|
|
21
25
|
};
|
|
@@ -5,6 +5,8 @@ import es from "./es.json";
|
|
|
5
5
|
import fr from "./fr.json";
|
|
6
6
|
import hr from "./hr.json";
|
|
7
7
|
import it from "./it.json";
|
|
8
|
+
import nl from "./nl.json";
|
|
9
|
+
import pl from "./pl.json";
|
|
8
10
|
import ru from "./ru.json";
|
|
9
11
|
import uk from "./uk.json";
|
|
10
12
|
|
|
@@ -16,6 +18,8 @@ export default {
|
|
|
16
18
|
fr,
|
|
17
19
|
hr,
|
|
18
20
|
it,
|
|
21
|
+
nl,
|
|
22
|
+
pl,
|
|
19
23
|
ru,
|
|
20
24
|
uk,
|
|
21
25
|
};
|
|
@@ -5,6 +5,8 @@ import es from "./es.json";
|
|
|
5
5
|
import fr from "./fr.json";
|
|
6
6
|
import hr from "./hr.json";
|
|
7
7
|
import it from "./it.json";
|
|
8
|
+
import nl from "./nl.json";
|
|
9
|
+
import pl from "./pl.json";
|
|
8
10
|
import ru from "./ru.json";
|
|
9
11
|
import uk from "./uk.json";
|
|
10
12
|
|
|
@@ -16,6 +18,8 @@ export default {
|
|
|
16
18
|
fr,
|
|
17
19
|
hr,
|
|
18
20
|
it,
|
|
21
|
+
nl,
|
|
22
|
+
pl,
|
|
19
23
|
ru,
|
|
20
24
|
uk,
|
|
21
25
|
};
|
|
@@ -5,6 +5,8 @@ import es from "./es.json";
|
|
|
5
5
|
import fr from "./fr.json";
|
|
6
6
|
import hr from "./hr.json";
|
|
7
7
|
import it from "./it.json";
|
|
8
|
+
import nl from "./nl.json";
|
|
9
|
+
import pl from "./pl.json";
|
|
8
10
|
import ru from "./ru.json";
|
|
9
11
|
import uk from "./uk.json";
|
|
10
12
|
|
|
@@ -16,6 +18,8 @@ export default {
|
|
|
16
18
|
fr,
|
|
17
19
|
hr,
|
|
18
20
|
it,
|
|
21
|
+
nl,
|
|
22
|
+
pl,
|
|
19
23
|
ru,
|
|
20
24
|
uk,
|
|
21
25
|
};
|
|
@@ -5,6 +5,8 @@ import es from "./es.json";
|
|
|
5
5
|
import fr from "./fr.json";
|
|
6
6
|
import hr from "./hr.json";
|
|
7
7
|
import it from "./it.json";
|
|
8
|
+
import nl from "./nl.json";
|
|
9
|
+
import pl from "./pl.json";
|
|
8
10
|
import ru from "./ru.json";
|
|
9
11
|
import uk from "./uk.json";
|
|
10
12
|
|
|
@@ -16,6 +18,8 @@ export default {
|
|
|
16
18
|
fr,
|
|
17
19
|
hr,
|
|
18
20
|
it,
|
|
21
|
+
nl,
|
|
22
|
+
pl,
|
|
19
23
|
ru,
|
|
20
24
|
uk,
|
|
21
25
|
};
|
|
@@ -5,6 +5,8 @@ import es from "./es.json";
|
|
|
5
5
|
import fr from "./fr.json";
|
|
6
6
|
import hr from "./hr.json";
|
|
7
7
|
import it from "./it.json";
|
|
8
|
+
import nl from "./nl.json";
|
|
9
|
+
import pl from "./pl.json";
|
|
8
10
|
import ru from "./ru.json";
|
|
9
11
|
import uk from "./uk.json";
|
|
10
12
|
|
|
@@ -16,6 +18,8 @@ export default {
|
|
|
16
18
|
fr,
|
|
17
19
|
hr,
|
|
18
20
|
it,
|
|
21
|
+
nl,
|
|
22
|
+
pl,
|
|
19
23
|
ru,
|
|
20
24
|
uk,
|
|
21
25
|
};
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
{
|
|
2
|
+
"_A_JSON_CURRENT_VALUE_": "Huidige waarde",
|
|
3
|
+
"_A_JSON_DISCARD_ALL_CHANGES_": "Alle wijzigingen negeren",
|
|
4
|
+
"_A_JSON_ERROR_HTML_{{error}}_": "De invoer kan niet in een JSON-object worden omgezet. Controleer uw invoer:<br>{{ error }}",
|
|
5
|
+
"_A_JSON_FORMAT_INPUT_": "Invoer opmaken",
|
|
6
|
+
"_A_JSON_INPUT_": "Invoer",
|
|
7
|
+
"_A_JSON_RESET_INPUT_": "Invoer terugzetten naar huidige waarde"
|
|
8
|
+
}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
{
|
|
2
|
+
"_A_JSON_CURRENT_VALUE_": "Bieżąca wartość",
|
|
3
|
+
"_A_JSON_DISCARD_ALL_CHANGES_": "Odrzuć wszystkie zmiany",
|
|
4
|
+
"_A_JSON_ERROR_HTML_{{error}}_": "Dane wejściowe nie mogą zostać przekonwertowane na obiekt JSON. Sprawdź wprowadzone dane:<br>{{ error }}",
|
|
5
|
+
"_A_JSON_FORMAT_INPUT_": "Formatuj dane wejściowe",
|
|
6
|
+
"_A_JSON_INPUT_": "Dane wejściowe",
|
|
7
|
+
"_A_JSON_RESET_INPUT_": "Przywróć dane wejściowe do bieżącej wartości"
|
|
8
|
+
}
|
|
@@ -5,6 +5,8 @@ import es from "./es.json";
|
|
|
5
5
|
import fr from "./fr.json";
|
|
6
6
|
import hr from "./hr.json";
|
|
7
7
|
import it from "./it.json";
|
|
8
|
+
import nl from "./nl.json";
|
|
9
|
+
import pl from "./pl.json";
|
|
8
10
|
import ru from "./ru.json";
|
|
9
11
|
import uk from "./uk.json";
|
|
10
12
|
|
|
@@ -16,6 +18,8 @@ export default {
|
|
|
16
18
|
fr,
|
|
17
19
|
hr,
|
|
18
20
|
it,
|
|
21
|
+
nl,
|
|
22
|
+
pl,
|
|
19
23
|
ru,
|
|
20
24
|
uk,
|
|
21
25
|
};
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
{
|
|
2
|
+
"_A_MULTISELECT_ORDERED_BTN_DELETE_": "Uit lijst verwijderen",
|
|
3
|
+
"_A_MULTISELECT_ORDERED_BTN_DOWN_": "Dichter naar het einde van de lijst verplaatsen",
|
|
4
|
+
"_A_MULTISELECT_ORDERED_BTN_GROUP_ARIA_LABEL_": "Acties voor",
|
|
5
|
+
"_A_MULTISELECT_ORDERED_BTN_UP_": "Dichter naar het begin van de lijst verplaatsen",
|
|
6
|
+
"_A_MULTISELECT_ORDERED_DESELECT_ALL_": "Alles deselecteren",
|
|
7
|
+
"_A_MULTISELECT_ORDERED_GROUP_ALL_": "Selectiebeheer",
|
|
8
|
+
"_A_MULTISELECT_ORDERED_GROUP_INVALID_ENTRIES_": "Ongeldige items",
|
|
9
|
+
"_A_MULTISELECT_ORDERED_LABEL_SELECT_": "Een item selecteren",
|
|
10
|
+
"_A_MULTISELECT_ORDERED_MODEL_EMPTY_": "Geen items geselecteerd",
|
|
11
|
+
"_A_MULTISELECT_ORDERED_SELECT_ALL_": "Alles selecteren"
|
|
12
|
+
}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
{
|
|
2
|
+
"_A_MULTISELECT_ORDERED_BTN_DELETE_": "Usuń z listy",
|
|
3
|
+
"_A_MULTISELECT_ORDERED_BTN_DOWN_": "Przesuń bliżej końca listy",
|
|
4
|
+
"_A_MULTISELECT_ORDERED_BTN_GROUP_ARIA_LABEL_": "Akcje dla",
|
|
5
|
+
"_A_MULTISELECT_ORDERED_BTN_UP_": "Przesuń bliżej początku listy",
|
|
6
|
+
"_A_MULTISELECT_ORDERED_DESELECT_ALL_": "Odznacz wszystko",
|
|
7
|
+
"_A_MULTISELECT_ORDERED_GROUP_ALL_": "Sterowanie wyborem",
|
|
8
|
+
"_A_MULTISELECT_ORDERED_GROUP_INVALID_ENTRIES_": "Nieprawidłowe wpisy",
|
|
9
|
+
"_A_MULTISELECT_ORDERED_LABEL_SELECT_": "Wybierz element",
|
|
10
|
+
"_A_MULTISELECT_ORDERED_MODEL_EMPTY_": "Nie wybrano żadnych elementów",
|
|
11
|
+
"_A_MULTISELECT_ORDERED_SELECT_ALL_": "Zaznacz wszystko"
|
|
12
|
+
}
|