vueless 0.0.302 → 0.0.304
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/package.json +1 -1
- package/ui.form-calendar/composables/attrs.composable.js +4 -19
- package/ui.form-calendar/configs/default.config.js +2 -5
- package/ui.form-calendar/index.vue +8 -11
- package/ui.form-date-picker-range/configs/default.config.js +4 -1
- package/ui.loader/index.vue +8 -5
- package/web-types.json +7 -1
package/package.json
CHANGED
|
@@ -29,9 +29,8 @@ export default function useAttrs(props) {
|
|
|
29
29
|
|
|
30
30
|
attrs[`${key}Attrs`] = getAttrs(key, { classes });
|
|
31
31
|
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
) {
|
|
32
|
+
// eslint-disable-next-line prettier/prettier
|
|
33
|
+
if (["timepickerInputHours", "timepickerInputMinutes", "timepickerInputSeconds"].includes(key)) {
|
|
35
34
|
const keyAttrs = attrs[`${key}Attrs`];
|
|
36
35
|
|
|
37
36
|
attrs[`${key}Attrs`] = computed(() => ({
|
|
@@ -42,22 +41,8 @@ export default function useAttrs(props) {
|
|
|
42
41
|
|
|
43
42
|
// TODO: Need to find other solution
|
|
44
43
|
// classes is not reactive here, which may cause problems in styling by `config` prop
|
|
45
|
-
if (key === "day") {
|
|
46
|
-
attrs[`${key}Attrs`] = (classes) => {
|
|
47
|
-
return getAttrs("day", { classes }).value;
|
|
48
|
-
};
|
|
49
|
-
}
|
|
50
|
-
|
|
51
|
-
if (key === "month") {
|
|
52
|
-
attrs[`${key}Attrs`] = (classes) => {
|
|
53
|
-
return getAttrs("month", { classes }).value;
|
|
54
|
-
};
|
|
55
|
-
}
|
|
56
|
-
|
|
57
|
-
if (key === "year") {
|
|
58
|
-
attrs[`${key}Attrs`] = (classes) => {
|
|
59
|
-
return getAttrs("year", { classes }).value;
|
|
60
|
-
};
|
|
44
|
+
if (key === "day" || key === "month" || key === "year") {
|
|
45
|
+
attrs[`${key}Attrs`] = (classes) => getAttrs(key, { classes }).value;
|
|
61
46
|
}
|
|
62
47
|
}
|
|
63
48
|
|
|
@@ -1,10 +1,7 @@
|
|
|
1
1
|
export default /*tw*/ {
|
|
2
2
|
wrapper: "p-3 pb-4 w-64 border border-gray-300 rounded-dynamic bg-white shadow overflow-hidden focus:outline-none",
|
|
3
3
|
navigation: "mb-2 pb-2 border-b flex items-center justify-between",
|
|
4
|
-
|
|
5
|
-
dayViewSwitchLabel: "flex gap-1",
|
|
6
|
-
dayViewSwitchLabelMonth: "",
|
|
7
|
-
dayViewSwitchLabelIcon: "",
|
|
4
|
+
viewSwitchButton: "{UButton} -ml-3 pl-3 text-sm rounded-l-none",
|
|
8
5
|
nextPrevWrapper: {
|
|
9
6
|
base: "flex",
|
|
10
7
|
variants: {
|
|
@@ -122,7 +119,7 @@ export default /*tw*/ {
|
|
|
122
119
|
okLabel: "Ok",
|
|
123
120
|
},
|
|
124
121
|
defaults: {
|
|
125
|
-
|
|
122
|
+
viewSwitchIcon: "keyboard_arrow_down",
|
|
126
123
|
nextIcon: "keyboard_arrow_right",
|
|
127
124
|
prevIcon: "keyboard_arrow_left",
|
|
128
125
|
userFormat: "j F, Y",
|
|
@@ -11,17 +11,16 @@
|
|
|
11
11
|
no-ring
|
|
12
12
|
size="sm"
|
|
13
13
|
variant="thirdary"
|
|
14
|
-
:right-icon="config.defaults.
|
|
15
|
-
v-bind="
|
|
14
|
+
:right-icon="isCurrentView.day && config.defaults.viewSwitchIcon"
|
|
15
|
+
v-bind="viewSwitchButtonAttrs"
|
|
16
16
|
@mousedown.prevent.capture
|
|
17
17
|
@click="onClickViewSwitch"
|
|
18
18
|
>
|
|
19
|
-
<
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
</
|
|
23
|
-
<
|
|
24
|
-
<span v-if="isCurrentView.year" v-text="viewSwitchLabel.yearsRange" />
|
|
19
|
+
<template v-if="isCurrentView.day">
|
|
20
|
+
{{ viewSwitchLabel.month }} {{ viewSwitchLabel.year }}
|
|
21
|
+
</template>
|
|
22
|
+
<template v-if="isCurrentView.month">{{ viewSwitchLabel.year }}</template>
|
|
23
|
+
<template v-if="isCurrentView.year">{{ viewSwitchLabel.yearsRange }}</template>
|
|
25
24
|
</UButton>
|
|
26
25
|
</Teleport>
|
|
27
26
|
|
|
@@ -321,9 +320,7 @@ const {
|
|
|
321
320
|
config,
|
|
322
321
|
wrapperAttrs,
|
|
323
322
|
navigationAttrs,
|
|
324
|
-
|
|
325
|
-
dayViewSwitchLabelAttrs,
|
|
326
|
-
dayViewSwitchLabelMonthAttrs,
|
|
323
|
+
viewSwitchButtonAttrs,
|
|
327
324
|
nextPrevButtonAttrs,
|
|
328
325
|
timepickerAttrs,
|
|
329
326
|
timepickerLabelAttrs,
|
|
@@ -64,7 +64,10 @@ export default /*tw*/ {
|
|
|
64
64
|
component: "{UCalendar}",
|
|
65
65
|
wrapper: "p-0 mt-2 w-full border-none shadow-none",
|
|
66
66
|
navigation: "mb-0 border-none",
|
|
67
|
-
|
|
67
|
+
viewSwitchButton: {
|
|
68
|
+
base: "rounded-dynamic px-4",
|
|
69
|
+
rightIcon: "hidden",
|
|
70
|
+
},
|
|
68
71
|
day: "w-full h-10 mb-0.5",
|
|
69
72
|
},
|
|
70
73
|
i18n: {
|
package/ui.loader/index.vue
CHANGED
|
@@ -1,11 +1,14 @@
|
|
|
1
1
|
<template>
|
|
2
2
|
<Transition v-bind="config.transition">
|
|
3
3
|
<div v-if="loading" v-bind="loaderAttrs">
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
4
|
+
<!-- @slot Use it to add something instead of the default loader. -->
|
|
5
|
+
<slot>
|
|
6
|
+
<div
|
|
7
|
+
v-for="ellipse in ELLIPSES_AMOUNT"
|
|
8
|
+
:key="ellipse"
|
|
9
|
+
v-bind="ellipseAttrs(ellipseClasses)"
|
|
10
|
+
/>
|
|
11
|
+
</slot>
|
|
9
12
|
</div>
|
|
10
13
|
</Transition>
|
|
11
14
|
</template>
|
package/web-types.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"framework": "vue",
|
|
3
3
|
"name": "vueless",
|
|
4
|
-
"version": "0.0.
|
|
4
|
+
"version": "0.0.304",
|
|
5
5
|
"contributions": {
|
|
6
6
|
"html": {
|
|
7
7
|
"description-markup": "markdown",
|
|
@@ -5703,6 +5703,12 @@
|
|
|
5703
5703
|
"default": "md"
|
|
5704
5704
|
}
|
|
5705
5705
|
],
|
|
5706
|
+
"slots": [
|
|
5707
|
+
{
|
|
5708
|
+
"name": "default",
|
|
5709
|
+
"description": "Use it to add something instead of the default loader."
|
|
5710
|
+
}
|
|
5711
|
+
],
|
|
5706
5712
|
"source": {
|
|
5707
5713
|
"module": "./src/ui.loader/index.vue",
|
|
5708
5714
|
"symbol": "default"
|