energy-components 1.6.0-beta.1 → 1.7.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/accordion.es.js +13 -13
- package/dist/components/button.es.js +21 -21
- package/dist/components/checkbox.es.js +7 -7
- package/dist/components/dropdown.es.js +278 -148
- package/dist/components/filterChip.es.js +4 -4
- package/dist/components/{icon-svg-pUb3-FXk.js → icon-svg-BmDOQ0kL.js} +42 -26
- package/dist/components/iconList.es.js +5 -5
- package/dist/components/iconSvg.es.js +1 -1
- package/dist/components/index.es.js +62 -59
- package/dist/components/infoBox.es.js +17 -17
- package/dist/components/link.es.js +15 -15
- package/dist/components/modal.es.js +69 -39
- package/dist/components/multiselect.es.js +230 -184
- package/dist/components/multiselectcontentwrapper.es.js +140 -0
- package/dist/components/pagination.es.js +129 -86
- package/dist/components/persistentToast.es.js +9 -9
- package/dist/components/quantitySelector.es.js +9 -9
- package/dist/components/radioButton.es.js +16 -16
- package/dist/components/selectionChip.es.js +5 -5
- package/dist/components/sidedrawer.es.js +53 -33
- package/dist/components/style/button.css +1 -1
- package/dist/components/style/datepicker.css +1 -1
- package/dist/components/style/dropdown.css +1 -1
- package/dist/components/style/icon-svg.css +1 -1
- package/dist/components/style/modal.css +1 -1
- package/dist/components/style/multiselect.css +1 -1
- package/dist/components/style/multiselectcontentwrapper.css +1 -0
- package/dist/components/style/pagination.css +1 -1
- package/dist/components/style/sidedrawer.css +1 -1
- package/dist/components/style/tabBar.css +1 -1
- package/dist/components/style/tablepaginatedcomponent.css +1 -1
- package/dist/components/style/tableslotedcomponent.css +1 -1
- package/dist/components/style/textField.css +1 -1
- package/dist/components/style/tooltip.css +1 -1
- package/dist/components/switch.es.js +10 -10
- package/dist/components/tabBar.es.js +15 -13
- package/dist/components/tablepaginatedcomponent.es.js +69 -65
- package/dist/components/tableslotedcomponent.es.js +155 -148
- package/dist/components/tag.es.js +5 -5
- package/dist/components/textArea.es.js +22 -22
- package/dist/components/textField.es.js +93 -84
- package/dist/components/tooltip.es.js +178 -174
- package/dist/energy-components.es.js +6678 -6128
- package/dist/energy-components.umd.js +1 -1
- package/dist/style.css +1 -1
- package/dist/types/src/components/buttons/button/button.vue.d.ts +2 -2
- package/dist/types/src/components/icon-svg/icon-svg.vue.d.ts +19 -0
- package/dist/types/src/components/index.d.ts +1 -0
- package/dist/types/src/components/input/dropdown/Multiselect/MultiselectContentWrapper.vue.d.ts +86 -0
- package/dist/types/src/components/input/dropdown/dropdown.vue.d.ts +582 -0
- package/dist/types/src/components/input/filter-chip/filter-chip.vue.d.ts +2 -2
- package/dist/types/src/components/input/quantity-selector/quantity-selector.vue.d.ts +1 -1
- package/dist/types/src/components/input/selection-chip/selection-chip.vue.d.ts +2 -2
- package/dist/types/src/components/input/text-field/text-field.vue.d.ts +10 -3
- package/dist/types/src/components/layout/sidedrawer/sidedrawer.vue.d.ts +30 -0
- package/dist/types/src/components/navigation/pagination/pagination.vue.d.ts +80 -31
- package/dist/types/src/components/overlay/modal/modal.vue.d.ts +27 -1
- package/dist/types/src/components/overlay/tooltip/tooltip.vue.d.ts +1 -0
- package/dist/types/tsconfig.tsbuildinfo +1 -1
- package/package.json +5 -5
|
@@ -0,0 +1,140 @@
|
|
|
1
|
+
import { openBlock as o, createElementBlock as c, normalizeClass as m, withModifiers as u, normalizeStyle as b, createElementVNode as a, renderSlot as i, createTextVNode as g, toDisplayString as h, createCommentVNode as r, Fragment as S, renderList as y, withDirectives as _, vShow as f } from "vue";
|
|
2
|
+
import { _ as L } from "./_plugin-vue_export-helper-CHgC5LLL.js";
|
|
3
|
+
import './style/multiselectcontentwrapper.css';const w = {
|
|
4
|
+
name: "MultiselectContentWrapper",
|
|
5
|
+
props: {
|
|
6
|
+
teleported: {
|
|
7
|
+
type: Boolean,
|
|
8
|
+
default: !1
|
|
9
|
+
},
|
|
10
|
+
id: {
|
|
11
|
+
type: [String, Number],
|
|
12
|
+
default: () => `multiselect-${Date.now()}-${Math.floor(Math.random() * 1e3)}`
|
|
13
|
+
// Valor por defecto único
|
|
14
|
+
},
|
|
15
|
+
multiple: Boolean,
|
|
16
|
+
max: [Number, Boolean],
|
|
17
|
+
internalValue: Array,
|
|
18
|
+
filteredOptions: Array,
|
|
19
|
+
isSelected: Function,
|
|
20
|
+
optionHighlight: Function,
|
|
21
|
+
select: Function,
|
|
22
|
+
pointerSet: Function,
|
|
23
|
+
selectLabelText: String,
|
|
24
|
+
selectedLabelText: String,
|
|
25
|
+
deselectLabelText: String,
|
|
26
|
+
tagPlaceholder: String,
|
|
27
|
+
groupSelect: Boolean,
|
|
28
|
+
selectGroupLabelText: String,
|
|
29
|
+
deselectGroupLabelText: String,
|
|
30
|
+
getOptionLabel: Function,
|
|
31
|
+
groupHighlight: Function,
|
|
32
|
+
selectGroup: Function,
|
|
33
|
+
options: Array,
|
|
34
|
+
hasOptionGroup: Boolean,
|
|
35
|
+
search: String,
|
|
36
|
+
loading: Boolean,
|
|
37
|
+
showNoResults: Boolean,
|
|
38
|
+
showNoOptions: Boolean,
|
|
39
|
+
small: Boolean,
|
|
40
|
+
contentStyle: Object,
|
|
41
|
+
customStyle: Object
|
|
42
|
+
},
|
|
43
|
+
emits: ["focus"]
|
|
44
|
+
}, O = ["id", "aria-multiselectable"], M = { key: 0 }, v = { class: "multiselect__option" }, T = ["aria-selected", "id", "role"], x = ["onClick", "onMouseenter", "data-select", "data-selected", "data-deselect"], B = ["data-select", "data-deselect", "onMouseenter", "onMousedown"], F = { class: "multiselect__option" }, N = { class: "multiselect__option" };
|
|
45
|
+
function k(l, n, e, G, C, D) {
|
|
46
|
+
return o(), c("div", {
|
|
47
|
+
class: m([
|
|
48
|
+
"multiselect__content-wrapper",
|
|
49
|
+
{ "multiselect__content-wrapper--small": e.small },
|
|
50
|
+
e.teleported ? "multiselect__content-wrapper--teleported" : ""
|
|
51
|
+
]),
|
|
52
|
+
onFocus: n[0] || (n[0] = (t) => l.$emit("focus")),
|
|
53
|
+
tabindex: "-1",
|
|
54
|
+
onMousedown: n[1] || (n[1] = u(() => {
|
|
55
|
+
}, ["prevent"])),
|
|
56
|
+
style: b(e.customStyle),
|
|
57
|
+
ref: "wrapper"
|
|
58
|
+
}, [
|
|
59
|
+
a("ul", {
|
|
60
|
+
class: "multiselect__content",
|
|
61
|
+
style: b(e.contentStyle),
|
|
62
|
+
role: "listbox",
|
|
63
|
+
id: "listbox-" + (e.teleported ? "teleported-" : "") + e.id,
|
|
64
|
+
"aria-multiselectable": e.multiple
|
|
65
|
+
}, [
|
|
66
|
+
i(l.$slots, "beforeList", {}, void 0, !0),
|
|
67
|
+
e.multiple && e.max === e.internalValue.length ? (o(), c("li", M, [
|
|
68
|
+
a("span", v, [
|
|
69
|
+
i(l.$slots, "maxElements", {}, () => [
|
|
70
|
+
g("Maximum of " + h(e.max) + " options selected. First remove a selected option to select another.", 1)
|
|
71
|
+
], !0)
|
|
72
|
+
])
|
|
73
|
+
])) : r("", !0),
|
|
74
|
+
!e.max || e.internalValue.length < e.max ? (o(!0), c(S, { key: 1 }, y(e.filteredOptions, (t, s) => (o(), c("li", {
|
|
75
|
+
class: "multiselect__element",
|
|
76
|
+
key: s,
|
|
77
|
+
"aria-selected": e.isSelected(t),
|
|
78
|
+
id: e.id + "-" + s,
|
|
79
|
+
role: t && (t.$isLabel || t.$isDisabled) ? null : "option"
|
|
80
|
+
}, [
|
|
81
|
+
t && (t.$isLabel || t.$isDisabled) ? r("", !0) : (o(), c("span", {
|
|
82
|
+
key: 0,
|
|
83
|
+
class: m([e.optionHighlight(s, t), "multiselect__option"]),
|
|
84
|
+
onClick: u((d) => e.select(t), ["stop"]),
|
|
85
|
+
onMouseenter: u((d) => e.pointerSet(s), ["self"]),
|
|
86
|
+
"data-select": t && t.isTag ? e.tagPlaceholder : e.selectLabelText,
|
|
87
|
+
"data-selected": e.selectedLabelText,
|
|
88
|
+
"data-deselect": e.deselectLabelText
|
|
89
|
+
}, [
|
|
90
|
+
i(l.$slots, "option", {
|
|
91
|
+
option: t,
|
|
92
|
+
search: e.search,
|
|
93
|
+
index: s
|
|
94
|
+
}, () => [
|
|
95
|
+
a("span", null, h(e.getOptionLabel(t)), 1)
|
|
96
|
+
], !0)
|
|
97
|
+
], 42, x)),
|
|
98
|
+
t && (t.$isLabel || t.$isDisabled) ? (o(), c("span", {
|
|
99
|
+
key: 1,
|
|
100
|
+
"data-select": e.groupSelect && e.selectGroupLabelText,
|
|
101
|
+
"data-deselect": e.groupSelect && e.deselectGroupLabelText,
|
|
102
|
+
class: m([e.groupHighlight(s, t), "multiselect__option"]),
|
|
103
|
+
onMouseenter: u((d) => e.groupSelect && e.pointerSet(s), ["self"]),
|
|
104
|
+
onMousedown: u((d) => e.selectGroup(t), ["prevent"])
|
|
105
|
+
}, [
|
|
106
|
+
i(l.$slots, "option", {
|
|
107
|
+
option: t,
|
|
108
|
+
search: e.search,
|
|
109
|
+
index: s
|
|
110
|
+
}, () => [
|
|
111
|
+
a("span", null, h(e.getOptionLabel(t)), 1)
|
|
112
|
+
], !0)
|
|
113
|
+
], 42, B)) : r("", !0)
|
|
114
|
+
], 8, T))), 128)) : r("", !0),
|
|
115
|
+
_(a("li", null, [
|
|
116
|
+
a("span", F, [
|
|
117
|
+
i(l.$slots, "noResult", { search: e.search }, () => [
|
|
118
|
+
n[2] || (n[2] = g("No elements found. Consider changing the search query."))
|
|
119
|
+
], !0)
|
|
120
|
+
])
|
|
121
|
+
], 512), [
|
|
122
|
+
[f, e.showNoResults && e.filteredOptions.length === 0 && e.search && !e.loading]
|
|
123
|
+
]),
|
|
124
|
+
_(a("li", null, [
|
|
125
|
+
a("span", N, [
|
|
126
|
+
i(l.$slots, "noOptions", {}, () => [
|
|
127
|
+
n[3] || (n[3] = g("List is empty."))
|
|
128
|
+
], !0)
|
|
129
|
+
])
|
|
130
|
+
], 512), [
|
|
131
|
+
[f, e.showNoOptions && (e.options.length === 0 || e.hasOptionGroup === !0 && e.filteredOptions.length === 0) && !e.search && !e.loading]
|
|
132
|
+
]),
|
|
133
|
+
i(l.$slots, "afterList", {}, void 0, !0)
|
|
134
|
+
], 12, O)
|
|
135
|
+
], 38);
|
|
136
|
+
}
|
|
137
|
+
const A = /* @__PURE__ */ L(w, [["render", k], ["__scopeId", "data-v-b87add6b"]]);
|
|
138
|
+
export {
|
|
139
|
+
A as default
|
|
140
|
+
};
|
|
@@ -1,160 +1,203 @@
|
|
|
1
|
-
import { defineComponent as
|
|
2
|
-
import
|
|
3
|
-
import { _ as
|
|
4
|
-
import './style/pagination.css';const
|
|
1
|
+
import { defineComponent as j, toRefs as V, ref as A, computed as u, onBeforeMount as T, openBlock as o, createElementBlock as g, createElementVNode as f, createBlock as C, createCommentVNode as h, createVNode as P, Fragment as U, renderList as z, toDisplayString as k, unref as G } from "vue";
|
|
2
|
+
import c from "./actionButton.es.js";
|
|
3
|
+
import { _ as H } from "./_plugin-vue_export-helper-CHgC5LLL.js";
|
|
4
|
+
import './style/pagination.css';const J = { class: "rds-e-pagination-container rds-flex" }, K = { class: "rds-e-pagination" }, O = {
|
|
5
5
|
key: 0,
|
|
6
6
|
class: "rds-e-pagination-leyend"
|
|
7
|
-
},
|
|
7
|
+
}, Q = /* @__PURE__ */ j({
|
|
8
8
|
__name: "pagination",
|
|
9
9
|
props: {
|
|
10
10
|
/**
|
|
11
|
-
* La página actual que se está visualizando.
|
|
11
|
+
* La página actual que se está visualizando. Usada para inicializar el componente.
|
|
12
12
|
*/
|
|
13
13
|
currentPage: {
|
|
14
14
|
type: Number,
|
|
15
15
|
required: !0
|
|
16
16
|
},
|
|
17
17
|
/**
|
|
18
|
-
* Habilita
|
|
18
|
+
* Habilita los botones para "saltar" a la primera y última página.
|
|
19
19
|
*/
|
|
20
20
|
jumpTo: {
|
|
21
21
|
type: Boolean,
|
|
22
22
|
default: !1
|
|
23
23
|
},
|
|
24
24
|
/**
|
|
25
|
-
*
|
|
26
|
-
|
|
27
|
-
selected: {
|
|
28
|
-
type: Boolean,
|
|
29
|
-
default: !1
|
|
30
|
-
},
|
|
31
|
-
/**
|
|
32
|
-
* Ocultar la leyenda de paginación
|
|
25
|
+
* Oculta la leyenda "Mostrando resultados X-Y de Z".
|
|
26
|
+
* Solo tiene efecto si se usa la prop `totalItems`.
|
|
33
27
|
*/
|
|
34
28
|
hideLeyend: {
|
|
35
29
|
type: Boolean,
|
|
36
30
|
default: !1
|
|
37
31
|
},
|
|
38
32
|
/**
|
|
39
|
-
* El número total de items
|
|
33
|
+
* El número total de items a paginar.
|
|
34
|
+
* Requerido si no se proporciona `totalPages`. Habilita la leyenda.
|
|
40
35
|
*/
|
|
41
36
|
totalItems: {
|
|
42
37
|
type: Number,
|
|
43
|
-
required: !
|
|
38
|
+
required: !1,
|
|
39
|
+
default: void 0
|
|
44
40
|
},
|
|
45
41
|
/**
|
|
46
|
-
*
|
|
42
|
+
* Número de items a mostrar por página.
|
|
43
|
+
* Usado para calcular el total de páginas (si se usa `totalItems`) y el offset/end en el evento.
|
|
47
44
|
*/
|
|
48
45
|
itemsPerPage: {
|
|
49
46
|
type: Number,
|
|
50
47
|
default: 10
|
|
48
|
+
},
|
|
49
|
+
/**
|
|
50
|
+
* El número total de páginas.
|
|
51
|
+
* Usado como fallback si `totalItems` no se proporciona.
|
|
52
|
+
*/
|
|
53
|
+
totalPages: {
|
|
54
|
+
type: Number,
|
|
55
|
+
required: !1,
|
|
56
|
+
default: void 0
|
|
57
|
+
},
|
|
58
|
+
/**
|
|
59
|
+
* Controla si el número de la página activa se resalta visualmente.
|
|
60
|
+
* El resaltado requiere que esta prop sea true.
|
|
61
|
+
*/
|
|
62
|
+
selected: {
|
|
63
|
+
type: Boolean,
|
|
64
|
+
default: !1
|
|
65
|
+
},
|
|
66
|
+
/**
|
|
67
|
+
* Desactiva el evento por defecto de la paginación al cargar el componente.
|
|
68
|
+
* Si se desactiva, la carga de datos debe manejarse manualmente la primera vez que se carga el componente.
|
|
69
|
+
*/
|
|
70
|
+
disableFirstLoad: {
|
|
71
|
+
type: Boolean,
|
|
72
|
+
default: !1
|
|
51
73
|
}
|
|
52
74
|
},
|
|
53
75
|
emits: ["pageChanged"],
|
|
54
|
-
setup(
|
|
55
|
-
const
|
|
56
|
-
itemsPerPage:
|
|
57
|
-
totalItems:
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
}),
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
return a;
|
|
72
|
-
}), E = (
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
76
|
+
setup(p, { expose: N, emit: w }) {
|
|
77
|
+
const m = p, L = w, {
|
|
78
|
+
itemsPerPage: v,
|
|
79
|
+
totalItems: e,
|
|
80
|
+
totalPages: r,
|
|
81
|
+
hideLeyend: M,
|
|
82
|
+
disableFirstLoad: S
|
|
83
|
+
} = V(m), l = A(m.currentPage), d = u(() => typeof (e == null ? void 0 : e.value) == "number" && e.value >= 0), b = u(() => d.value && typeof (e == null ? void 0 : e.value) == "number" ? e.value <= 0 || v.value <= 0 ? 1 : Math.ceil(e.value / v.value) : typeof (r == null ? void 0 : r.value) == "number" && r.value > 0 ? r.value : (typeof (r == null ? void 0 : r.value) > "u" && typeof (e == null ? void 0 : e.value) > "u" && console.warn("[RDSPagination] Props `totalItems` o `totalPages` son requeridas."), 1)), $ = u(() => d.value && !M.value && typeof (e == null ? void 0 : e.value) == "number" && e.value > 0), F = u(() => !d.value || typeof (e == null ? void 0 : e.value) != "number" || e.value === 0 ? 0 : (l.value - 1) * v.value + 1), q = u(() => {
|
|
84
|
+
if (!d.value || typeof (e == null ? void 0 : e.value) != "number") return 0;
|
|
85
|
+
const t = l.value * v.value;
|
|
86
|
+
return Math.min(t, e.value);
|
|
87
|
+
}), _ = u(() => l.value === 1), B = u(() => l.value === b.value), D = u(() => {
|
|
88
|
+
const t = [], a = b.value, n = l.value;
|
|
89
|
+
if (a <= 3)
|
|
90
|
+
for (let i = 1; i <= a; i++)
|
|
91
|
+
t.push(i);
|
|
92
|
+
else n === 1 ? t.push(1, 2, Math.min(3, a)) : n === a ? t.push(Math.max(1, a - 2), a - 1, a) : t.push(n - 1, n, n + 1);
|
|
93
|
+
return [...new Set(t)].filter((i) => i >= 1 && i <= a);
|
|
94
|
+
}), E = (t) => {
|
|
95
|
+
let a = l.value;
|
|
96
|
+
const n = b.value;
|
|
97
|
+
if ("navigator" in t)
|
|
98
|
+
switch (t.navigator) {
|
|
99
|
+
case "next":
|
|
100
|
+
l.value < n && (a = l.value + 1);
|
|
101
|
+
break;
|
|
102
|
+
case "prev":
|
|
103
|
+
l.value > 1 && (a = l.value - 1);
|
|
104
|
+
break;
|
|
105
|
+
case "first":
|
|
106
|
+
l.value !== 1 && (a = 1);
|
|
107
|
+
break;
|
|
108
|
+
case "last":
|
|
109
|
+
l.value !== n && (a = n);
|
|
110
|
+
break;
|
|
111
|
+
}
|
|
112
|
+
else "page" in t && typeof t.page == "number" && t.page >= 1 && t.page <= n && t.page !== l.value && (a = t.page);
|
|
113
|
+
return a !== l.value ? (l.value = a, !0) : !1;
|
|
114
|
+
}, s = (t, a = !1) => {
|
|
115
|
+
if (E(t) || a) {
|
|
116
|
+
const i = v.value, y = (l.value - 1) * i;
|
|
117
|
+
let x = y + i;
|
|
118
|
+
d.value && typeof (e == null ? void 0 : e.value) == "number" && (x = Math.min(y + i, e.value));
|
|
119
|
+
const R = {
|
|
120
|
+
...t,
|
|
121
|
+
page: l.value,
|
|
122
|
+
offset: y,
|
|
123
|
+
limit: i,
|
|
124
|
+
end: x,
|
|
125
|
+
reset: a || void 0
|
|
126
|
+
};
|
|
127
|
+
L("pageChanged", R);
|
|
128
|
+
}
|
|
87
129
|
};
|
|
88
|
-
return
|
|
89
|
-
|
|
90
|
-
}),
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
130
|
+
return T(() => {
|
|
131
|
+
S.value || s({ navigator: "first", page: 1 });
|
|
132
|
+
}), N({
|
|
133
|
+
/** Resetea la paginación a la primera página y emite el evento pageChanged. */
|
|
134
|
+
resetPagination: () => {
|
|
135
|
+
l.value !== 1 && s({ page: 1 }, !0);
|
|
136
|
+
}
|
|
137
|
+
}), (t, a) => (o(), g("div", J, [
|
|
138
|
+
f("ul", K, [
|
|
139
|
+
f("li", null, [
|
|
140
|
+
p.jumpTo ? (o(), C(c, {
|
|
98
141
|
key: 0,
|
|
99
142
|
class: "rds-e-pagination__actionBtn",
|
|
100
143
|
variant: "ghost",
|
|
101
144
|
small: "",
|
|
102
145
|
icon: "back",
|
|
103
146
|
"aria-label": "First Page",
|
|
104
|
-
disabled:
|
|
105
|
-
onClick:
|
|
106
|
-
}, null, 8, ["disabled"])) :
|
|
147
|
+
disabled: _.value,
|
|
148
|
+
onClick: a[0] || (a[0] = (n) => s({ navigator: "first" }))
|
|
149
|
+
}, null, 8, ["disabled"])) : h("", !0)
|
|
107
150
|
]),
|
|
108
|
-
|
|
109
|
-
P(
|
|
151
|
+
f("li", null, [
|
|
152
|
+
P(c, {
|
|
110
153
|
class: "rds-e-pagination__actionBtn",
|
|
111
154
|
variant: "ghost",
|
|
112
155
|
small: "",
|
|
113
156
|
icon: "arrow_left",
|
|
114
157
|
"aria-label": "Prev page",
|
|
115
|
-
disabled:
|
|
116
|
-
onClick:
|
|
158
|
+
disabled: _.value,
|
|
159
|
+
onClick: a[1] || (a[1] = (n) => s({ navigator: "prev" }))
|
|
117
160
|
}, null, 8, ["disabled"])
|
|
118
161
|
]),
|
|
119
|
-
(o(!0),
|
|
120
|
-
P(
|
|
162
|
+
(o(!0), g(U, null, z(D.value, (n) => (o(), g("li", { key: n }, [
|
|
163
|
+
P(c, {
|
|
121
164
|
class: "rds-e-pagination__item",
|
|
122
|
-
variant:
|
|
165
|
+
variant: n === l.value && m.selected ? "primary" : "ghost",
|
|
123
166
|
small: "",
|
|
124
|
-
text: String(
|
|
167
|
+
text: String(n),
|
|
125
168
|
icon: "",
|
|
126
|
-
"aria-label": `page number ${
|
|
127
|
-
onClick: (
|
|
169
|
+
"aria-label": `page number ${n}`,
|
|
170
|
+
onClick: (i) => s({ page: n })
|
|
128
171
|
}, null, 8, ["variant", "text", "aria-label", "onClick"])
|
|
129
172
|
]))), 128)),
|
|
130
|
-
|
|
131
|
-
P(
|
|
173
|
+
f("li", null, [
|
|
174
|
+
P(c, {
|
|
132
175
|
class: "rds-e-pagination__actionBtn",
|
|
133
176
|
variant: "ghost",
|
|
134
177
|
icon: "arrow_right",
|
|
135
178
|
small: "",
|
|
136
179
|
"aria-label": "next page",
|
|
137
|
-
disabled:
|
|
138
|
-
onClick:
|
|
180
|
+
disabled: B.value,
|
|
181
|
+
onClick: a[2] || (a[2] = (n) => s({ navigator: "next" }))
|
|
139
182
|
}, null, 8, ["disabled"])
|
|
140
183
|
]),
|
|
141
|
-
|
|
142
|
-
|
|
184
|
+
f("li", null, [
|
|
185
|
+
p.jumpTo ? (o(), C(c, {
|
|
143
186
|
key: 0,
|
|
144
187
|
class: "rds-e-pagination__actionBtn",
|
|
145
188
|
variant: "ghost",
|
|
146
189
|
small: "",
|
|
147
190
|
icon: "last",
|
|
148
191
|
"aria-label": "last page",
|
|
149
|
-
disabled:
|
|
150
|
-
onClick:
|
|
151
|
-
}, null, 8, ["disabled"])) :
|
|
192
|
+
disabled: B.value,
|
|
193
|
+
onClick: a[3] || (a[3] = (n) => s({ navigator: "last" }))
|
|
194
|
+
}, null, 8, ["disabled"])) : h("", !0)
|
|
152
195
|
])
|
|
153
196
|
]),
|
|
154
|
-
|
|
197
|
+
$.value ? (o(), g("p", O, " Mostrando resultados " + k(F.value) + "-" + k(q.value) + " de " + k(G(e)), 1)) : h("", !0)
|
|
155
198
|
]));
|
|
156
199
|
}
|
|
157
|
-
}),
|
|
200
|
+
}), Z = /* @__PURE__ */ H(Q, [["__scopeId", "data-v-78eeeb8a"]]);
|
|
158
201
|
export {
|
|
159
|
-
|
|
202
|
+
Z as default
|
|
160
203
|
};
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import { defineComponent as v, toRefs as y, computed as g, openBlock as t, createElementBlock as s, normalizeClass as h, createElementVNode as i, createVNode as a, createCommentVNode as o, toDisplayString as c, renderSlot as l } from "vue";
|
|
2
|
-
import {
|
|
2
|
+
import { R as d } from "./icon-svg-BmDOQ0kL.js";
|
|
3
3
|
import { _ as k } from "./_plugin-vue_export-helper-CHgC5LLL.js";
|
|
4
|
-
import './style/persistentToast.css';const $ = { class: "alert" },
|
|
4
|
+
import './style/persistentToast.css';const $ = { class: "alert" }, S = {
|
|
5
5
|
key: 0,
|
|
6
6
|
class: "rds-e-persistent-toast__custom-icon-block"
|
|
7
|
-
},
|
|
7
|
+
}, C = { class: "rds-e-persistent-toast__wrapper" }, q = { class: "rds-e-persistent-toast__title__wrapper" }, w = {
|
|
8
8
|
key: 0,
|
|
9
9
|
class: "rds-e-persistent-toast__title rds-mb-03"
|
|
10
10
|
}, b = {
|
|
@@ -16,7 +16,7 @@ import './style/persistentToast.css';const $ = { class: "alert" }, C = {
|
|
|
16
16
|
}, B = {
|
|
17
17
|
key: 0,
|
|
18
18
|
class: "rds-e-persistent-toast__action-section"
|
|
19
|
-
},
|
|
19
|
+
}, N = /* @__PURE__ */ v({
|
|
20
20
|
__name: "persistent-toast",
|
|
21
21
|
props: {
|
|
22
22
|
/**
|
|
@@ -92,19 +92,19 @@ import './style/persistentToast.css';const $ = { class: "alert" }, C = {
|
|
|
92
92
|
), f = () => {
|
|
93
93
|
m("onCloseToastAction");
|
|
94
94
|
};
|
|
95
|
-
return (n,
|
|
95
|
+
return (n, R) => (t(), s("div", {
|
|
96
96
|
class: h(["rds-e-persistent-toast", p.value]),
|
|
97
97
|
role: "alert"
|
|
98
98
|
}, [
|
|
99
99
|
i("div", $, [
|
|
100
|
-
e.icon ? (t(), s("div",
|
|
100
|
+
e.icon ? (t(), s("div", S, [
|
|
101
101
|
a(d, {
|
|
102
102
|
name: e.icon,
|
|
103
103
|
class: "rds-e-persistent-toast__custom-icon",
|
|
104
104
|
"aria-hidden": "true"
|
|
105
105
|
}, null, 8, ["name"])
|
|
106
106
|
])) : o("", !0),
|
|
107
|
-
i("div",
|
|
107
|
+
i("div", C, [
|
|
108
108
|
i("div", q, [
|
|
109
109
|
e.title ? (t(), s("div", w, c(e.title), 1)) : o("", !0),
|
|
110
110
|
e.message && !n.$slots["content-section"] ? (t(), s("p", b, c(e.message), 1)) : o("", !0),
|
|
@@ -130,7 +130,7 @@ import './style/persistentToast.css';const $ = { class: "alert" }, C = {
|
|
|
130
130
|
])) : o("", !0)
|
|
131
131
|
], 2));
|
|
132
132
|
}
|
|
133
|
-
}),
|
|
133
|
+
}), E = /* @__PURE__ */ k(N, [["__scopeId", "data-v-9599464c"]]);
|
|
134
134
|
export {
|
|
135
|
-
|
|
135
|
+
E as default
|
|
136
136
|
};
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { defineComponent as
|
|
2
|
-
import {
|
|
3
|
-
import { _ } from "./_plugin-vue_export-helper-CHgC5LLL.js";
|
|
4
|
-
import './style/quantitySelector.css';const
|
|
1
|
+
import { defineComponent as V, mergeModels as c, useModel as w, ref as i, openBlock as B, createElementBlock as I, normalizeClass as r, createElementVNode as o, createVNode as m, withDirectives as f, vShow as v, vModelText as b } from "vue";
|
|
2
|
+
import { R as y } from "./icon-svg-BmDOQ0kL.js";
|
|
3
|
+
import { _ as D } from "./_plugin-vue_export-helper-CHgC5LLL.js";
|
|
4
|
+
import './style/quantitySelector.css';const _ = ["disabled"], M = ["disabled"], S = ["disabled"], x = ["disabled"], R = /* @__PURE__ */ V({
|
|
5
5
|
__name: "quantity-selector",
|
|
6
6
|
props: /* @__PURE__ */ c({
|
|
7
7
|
/**
|
|
@@ -52,7 +52,7 @@ import './style/quantitySelector.css';const D = ["disabled"], M = ["disabled"],
|
|
|
52
52
|
}),
|
|
53
53
|
emits: /* @__PURE__ */ c(["onClickPlus", "onClickMinus", "onChange", "onDelete"], ["update:modelValue"]),
|
|
54
54
|
setup(l, { emit: p }) {
|
|
55
|
-
const h = l, n = p, e =
|
|
55
|
+
const h = l, n = p, e = w(l, "modelValue"), s = i(!1), u = i(null), k = i(null), C = () => {
|
|
56
56
|
e.value < 99 && (e.value++, n("onChange", e.value)), n("onClickPlus");
|
|
57
57
|
}, q = () => {
|
|
58
58
|
h.deleteButton && e.value !== 0 ? (n("onDelete"), e.value = 0, n("onChange", e.value)) : e.value > 0 && (e.value--, n("onChange", e.value)), n("onClickMinus");
|
|
@@ -66,7 +66,7 @@ import './style/quantitySelector.css';const D = ["disabled"], M = ["disabled"],
|
|
|
66
66
|
}
|
|
67
67
|
s.value = !1;
|
|
68
68
|
};
|
|
69
|
-
return (t, a) => (
|
|
69
|
+
return (t, a) => (B(), I("div", {
|
|
70
70
|
class: r(["rds-e-quantity-selector", {
|
|
71
71
|
"rds-e-quantity-selector--disabled": l.disabled,
|
|
72
72
|
"rds-e-quantity-selector--small": l.size === "small",
|
|
@@ -84,7 +84,7 @@ import './style/quantitySelector.css';const D = ["disabled"], M = ["disabled"],
|
|
|
84
84
|
m(y, {
|
|
85
85
|
name: l.deleteButton && e.value !== 0 ? "delete" : "minus"
|
|
86
86
|
}, null, 8, ["name"])
|
|
87
|
-
], 10,
|
|
87
|
+
], 10, _),
|
|
88
88
|
f(o("input", {
|
|
89
89
|
ref_key: "mainInput",
|
|
90
90
|
ref: k,
|
|
@@ -137,7 +137,7 @@ import './style/quantitySelector.css';const D = ["disabled"], M = ["disabled"],
|
|
|
137
137
|
], 10, x)
|
|
138
138
|
], 2));
|
|
139
139
|
}
|
|
140
|
-
}),
|
|
140
|
+
}), A = /* @__PURE__ */ D(R, [["__scopeId", "data-v-e9c62df7"]]);
|
|
141
141
|
export {
|
|
142
|
-
|
|
142
|
+
A as default
|
|
143
143
|
};
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { defineComponent as
|
|
2
|
-
import {
|
|
3
|
-
import { g as
|
|
4
|
-
import { _ as
|
|
5
|
-
import './style/radioButton.css';const L = ["id", "value", "name", "disabled", "checked"], $ = ["for"], j = /* @__PURE__ */
|
|
1
|
+
import { defineComponent as B, ref as f, computed as m, inject as i, onMounted as _, onBeforeUnmount as D, openBlock as r, createElementBlock as b, normalizeClass as n, createElementVNode as v, unref as E, toDisplayString as N, createCommentVNode as w, createBlock as x } from "vue";
|
|
2
|
+
import { R as C } from "./icon-svg-BmDOQ0kL.js";
|
|
3
|
+
import { g as G } from "./getInstance-GhoEcxLF.js";
|
|
4
|
+
import { _ as I } from "./_plugin-vue_export-helper-CHgC5LLL.js";
|
|
5
|
+
import './style/radioButton.css';const L = ["id", "value", "name", "disabled", "checked"], $ = ["for"], j = /* @__PURE__ */ B({
|
|
6
6
|
__name: "radio-button",
|
|
7
7
|
props: {
|
|
8
8
|
/**
|
|
@@ -50,17 +50,17 @@ import './style/radioButton.css';const L = ["id", "value", "name", "disabled", "
|
|
|
50
50
|
}
|
|
51
51
|
},
|
|
52
52
|
setup(e) {
|
|
53
|
-
const o = e, d = f(!1), t = f(!1), y =
|
|
53
|
+
const o = e, d = f(!1), t = f(!1), y = G(), l = m(() => o.id || `input-${y}`), a = i("radioGroupValue"), p = i("radioGroupName");
|
|
54
54
|
a || console.warn("RDSRadioButton debe estar dentro de un RDSRadioGroup");
|
|
55
|
-
const
|
|
56
|
-
o.id && !
|
|
55
|
+
const S = i("validateId");
|
|
56
|
+
o.id && !S(o.id) && console.warn(
|
|
57
57
|
`RDSRadioButton con id ${o.id} tiene un id duplicado. Se generará un id único.`
|
|
58
58
|
);
|
|
59
|
-
const
|
|
59
|
+
const k = m(() => (a == null ? void 0 : a.value) === o.option), R = () => {
|
|
60
60
|
!o.disabled && a && (a.value = o.option);
|
|
61
|
-
},
|
|
61
|
+
}, g = () => {
|
|
62
62
|
t.value && (d.value = !0);
|
|
63
|
-
},
|
|
63
|
+
}, h = () => d.value = !1, s = (u) => {
|
|
64
64
|
u.key === "Tab" && (t.value = !0);
|
|
65
65
|
}, c = () => {
|
|
66
66
|
t.value = !1;
|
|
@@ -79,10 +79,10 @@ import './style/radioButton.css';const L = ["id", "value", "name", "disabled", "
|
|
|
79
79
|
class: n(`rds-e-radio ${e.error ? " rds-e-radio--error" : ""}`),
|
|
80
80
|
name: E(p),
|
|
81
81
|
disabled: e.disabled,
|
|
82
|
-
checked:
|
|
83
|
-
onChange:
|
|
84
|
-
onFocus:
|
|
85
|
-
onBlur:
|
|
82
|
+
checked: k.value,
|
|
83
|
+
onChange: R,
|
|
84
|
+
onFocus: g,
|
|
85
|
+
onBlur: h
|
|
86
86
|
}, null, 42, L),
|
|
87
87
|
v("label", {
|
|
88
88
|
for: l.value,
|
|
@@ -101,7 +101,7 @@ import './style/radioButton.css';const L = ["id", "value", "name", "disabled", "
|
|
|
101
101
|
], 10, $)
|
|
102
102
|
], 2));
|
|
103
103
|
}
|
|
104
|
-
}), V = /* @__PURE__ */
|
|
104
|
+
}), V = /* @__PURE__ */ I(j, [["__scopeId", "data-v-c8280e86"]]);
|
|
105
105
|
export {
|
|
106
106
|
V as default
|
|
107
107
|
};
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { defineComponent as r, ref as h, computed as s, openBlock as p, createElementBlock as u, normalizeClass as f, createVNode as g, createElementVNode as m, toDisplayString as _ } from "vue";
|
|
2
|
-
import {
|
|
2
|
+
import { R as b } from "./icon-svg-BmDOQ0kL.js";
|
|
3
3
|
import { _ as y } from "./_plugin-vue_export-helper-CHgC5LLL.js";
|
|
4
|
-
import './style/selectionChip.css';const C = ["disabled"], k = { class: "rds-e-selection-chip__text" },
|
|
4
|
+
import './style/selectionChip.css';const C = ["disabled"], k = { class: "rds-e-selection-chip__text" }, S = /* @__PURE__ */ r({
|
|
5
5
|
__name: "selection-chip",
|
|
6
6
|
props: {
|
|
7
7
|
/**
|
|
@@ -65,7 +65,7 @@ import './style/selectionChip.css';const C = ["disabled"], k = { class: "rds-e-s
|
|
|
65
65
|
}), d = () => {
|
|
66
66
|
e.disabled || c("onClickChip", e.filterValue);
|
|
67
67
|
};
|
|
68
|
-
return (t,
|
|
68
|
+
return (t, x) => (p(), u("button", {
|
|
69
69
|
ref_key: "chipRef",
|
|
70
70
|
ref: o,
|
|
71
71
|
class: f(a.value),
|
|
@@ -81,7 +81,7 @@ import './style/selectionChip.css';const C = ["disabled"], k = { class: "rds-e-s
|
|
|
81
81
|
m("span", k, _(i.text), 1)
|
|
82
82
|
], 10, C));
|
|
83
83
|
}
|
|
84
|
-
}),
|
|
84
|
+
}), V = /* @__PURE__ */ y(S, [["__scopeId", "data-v-9b7aba98"]]);
|
|
85
85
|
export {
|
|
86
|
-
|
|
86
|
+
V as default
|
|
87
87
|
};
|