energy-components 1.1.2 → 1.1.3
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 +11 -11
- package/dist/components/button.es.js +1 -1
- package/dist/components/card.es.js +21 -9
- package/dist/components/checkbox.es.js +1 -1
- package/dist/components/datepicker.es.js +2008 -2008
- package/dist/components/dropdown.es.js +97 -97
- package/dist/components/{icon-svg-CEZ-L3iv.js → icon-svg-GoL3_ayS.js} +699 -665
- package/dist/components/iconList.es.js +1 -1
- package/dist/components/iconSvg.es.js +1 -1
- package/dist/components/index.es.js +1 -1
- package/dist/components/infoBox.es.js +1 -1
- package/dist/components/link.es.js +1 -1
- package/dist/components/modal.es.js +28 -26
- package/dist/components/multiselect.es.js +2 -2
- package/dist/components/overlay.es.js +3 -3
- package/dist/components/persistentToast.es.js +8 -8
- package/dist/components/radioButton.es.js +1 -1
- package/dist/components/sidebar.es.js +11 -11
- package/dist/components/style/button.css +1 -1
- package/dist/components/style/card.css +1 -1
- package/dist/components/style/datepicker.css +1 -1
- package/dist/components/style/link.css +1 -1
- package/dist/components/style/modal.css +1 -1
- package/dist/components/style/tag.css +1 -1
- package/dist/components/style/textArea.css +1 -1
- package/dist/components/style/textField.css +1 -1
- package/dist/components/switch.es.js +1 -1
- package/dist/components/tabBar.es.js +27 -27
- package/dist/components/tag.es.js +1 -1
- package/dist/components/textArea.es.js +75 -75
- package/dist/components/textField.es.js +11 -11
- package/dist/components/tooltip.es.js +255 -252
- package/dist/energy-components.es.js +3751 -3700
- package/dist/energy-components.umd.js +1 -1
- package/dist/style.css +1 -1
- package/dist/types/src/components/buttons/action-button/action-button.vue.d.ts +4 -4
- package/dist/types/src/components/buttons/button/button.vue.d.ts +11 -18
- package/dist/types/src/components/buttons/floating-action-button/floating-action-button.vue.d.ts +4 -4
- package/dist/types/src/components/content/accordion/accordion.vue.d.ts +20 -24
- package/dist/types/src/components/content/acordion-group/accordion-group.vue.d.ts +8 -15
- package/dist/types/src/components/content/card/card.vue.d.ts +26 -15
- package/dist/types/src/components/content/divider/divider.vue.d.ts +4 -4
- package/dist/types/src/components/content/tag/tag.vue.d.ts +4 -4
- package/dist/types/src/components/feedback/indicator/indicator.vue.d.ts +7 -4
- package/dist/types/src/components/feedback/info-box/info-box.vue.d.ts +7 -4
- package/dist/types/src/components/feedback/persistent-toast/persistent-toast.vue.d.ts +13 -19
- package/dist/types/src/components/icon-svg/icon-list.vue.d.ts +1 -1
- package/dist/types/src/components/icon-svg/icon-svg.vue.d.ts +4 -4
- package/dist/types/src/components/input/checkbox/checkbox.vue.d.ts +13 -20
- package/dist/types/src/components/input/dropdown/dropdown.vue.d.ts +26 -36
- package/dist/types/src/components/input/radio-button/radio-button.vue.d.ts +4 -4
- package/dist/types/src/components/input/radio-button/radio-group.vue.d.ts +13 -20
- package/dist/types/src/components/input/switch/switch.vue.d.ts +13 -19
- package/dist/types/src/components/input/text-area/text-area.vue.d.ts +16 -25
- package/dist/types/src/components/input/text-field/text-field.vue.d.ts +15 -23
- package/dist/types/src/components/layout/sidebar/sidebar.vue.d.ts +16 -21
- package/dist/types/src/components/navigation/breadcrumbs/breadcrumbs.vue.d.ts +6 -6
- package/dist/types/src/components/navigation/link/link.vue.d.ts +11 -17
- package/dist/types/src/components/navigation/pagination/pagination.vue.d.ts +6 -6
- package/dist/types/src/components/navigation/tab-bar/tab-bar.vue.d.ts +24 -27
- package/dist/types/src/components/overlay/modal/modal.vue.d.ts +92 -58
- package/dist/types/src/components/overlay/overlay/overlay.vue.d.ts +11 -18
- package/dist/types/src/components/overlay/tooltip/tooltip.vue.d.ts +19 -22
- package/dist/types/src/composables/breakpoints.d.ts +1 -1
- package/dist/types/src/helpers/mobileMockup.vue.d.ts +1 -1
- package/dist/types/tsconfig.tsbuildinfo +1 -1
- package/package.json +2 -2
|
@@ -1,17 +1,17 @@
|
|
|
1
|
-
import { defineComponent as H, mergeModels as x, toRefs as J, useModel as K, ref as Q, computed as
|
|
2
|
-
import
|
|
3
|
-
import
|
|
4
|
-
import { I as
|
|
5
|
-
import
|
|
6
|
-
import
|
|
7
|
-
import { _ as
|
|
8
|
-
import './style/dropdown.css';const
|
|
1
|
+
import { defineComponent as H, mergeModels as x, toRefs as J, useModel as K, ref as Q, computed as y, openBlock as i, createElementBlock as b, createVNode as B, mergeProps as W, unref as n, withModifiers as u, createSlots as M, withCtx as o, normalizeClass as X, renderSlot as d, createElementVNode as a, createBlock as T, createCommentVNode as O, Fragment as Y, toDisplayString as D, nextTick as q } from "vue";
|
|
2
|
+
import Z from "./multiselect.es.js";
|
|
3
|
+
import ee from "./textField.es.js";
|
|
4
|
+
import { I as le } from "./icon-svg-GoL3_ayS.js";
|
|
5
|
+
import te from "./checkbox.es.js";
|
|
6
|
+
import se from "./radioButton.es.js";
|
|
7
|
+
import { _ as re } from "./_plugin-vue_export-helper-CHgC5LLL.js";
|
|
8
|
+
import './style/dropdown.css';const ne = { class: "rds-e-dropdown" }, oe = { class: "rds-e-dropdown__option" }, de = { class: "rds-e-dropdown__option-container" }, ae = { class: "rds-e-dropdown__option--prepend" }, ie = { class: "rds-e-dropdown__option--content" }, ue = {
|
|
9
9
|
key: 0,
|
|
10
10
|
class: "rds-e-dropdown__option-detail"
|
|
11
|
-
},
|
|
11
|
+
}, ce = { key: 1 }, fe = {
|
|
12
12
|
key: 0,
|
|
13
13
|
class: "rds-e-dropdown__option--append"
|
|
14
|
-
},
|
|
14
|
+
}, me = { class: "rds-e-dropdown__after-list" }, pe = { class: "rds-e-dropdown__after-list-container" }, ve = /* @__PURE__ */ H({
|
|
15
15
|
__name: "dropdown",
|
|
16
16
|
props: /* @__PURE__ */ x({
|
|
17
17
|
/**
|
|
@@ -115,58 +115,58 @@ import './style/dropdown.css';const de = (t) => (Z("data-v-9e2c3262"), t = t(),
|
|
|
115
115
|
modelModifiers: {}
|
|
116
116
|
}),
|
|
117
117
|
emits: /* @__PURE__ */ x(["open", "close", "select", "change"], ["update:modelValue"]),
|
|
118
|
-
setup(t, { expose: $, emit:
|
|
119
|
-
const c = t,
|
|
120
|
-
disabled:
|
|
121
|
-
options:
|
|
122
|
-
limit:
|
|
123
|
-
multiple:
|
|
124
|
-
} = J(c),
|
|
125
|
-
get: () =>
|
|
118
|
+
setup(t, { expose: $, emit: E }) {
|
|
119
|
+
const c = t, f = E, {
|
|
120
|
+
disabled: m,
|
|
121
|
+
options: h,
|
|
122
|
+
limit: C,
|
|
123
|
+
multiple: p
|
|
124
|
+
} = J(c), r = K(t, "modelValue"), v = Q(), j = y(() => h.value.every((e) => typeof e == "object" && (e == null ? void 0 : e.id) && (e == null ? void 0 : e.label))), N = y(() => !p.value || c.closeOnSelect), _ = y({
|
|
125
|
+
get: () => r.value ? c.multiple ? Array.isArray(r.value) ? r.value.length > C.value ? c.limitText(C.value) : r.value.map((e) => typeof e == "string" ? e : e.label).join(", ") : "" : typeof r.value == "object" ? r.value.label : typeof r.value == "string" ? r.value : "" : "",
|
|
126
126
|
set: () => null
|
|
127
|
-
}),
|
|
127
|
+
}), F = y(() => ({
|
|
128
128
|
"rds-e-dropdown-input": !0,
|
|
129
|
-
"rds-e-dropdown--disabled":
|
|
129
|
+
"rds-e-dropdown--disabled": m.value,
|
|
130
130
|
"rds-e-dropdown--small": c.small
|
|
131
|
-
})),
|
|
131
|
+
})), S = y(() => {
|
|
132
132
|
const e = {};
|
|
133
|
-
return
|
|
133
|
+
return j.value && Object.assign(e, {
|
|
134
134
|
"track-by": "id",
|
|
135
135
|
label: "label"
|
|
136
136
|
}), e;
|
|
137
137
|
}), k = (e) => {
|
|
138
|
-
if (
|
|
139
|
-
if (Array.isArray(
|
|
140
|
-
if (typeof e == "string") return
|
|
141
|
-
if (
|
|
142
|
-
return
|
|
138
|
+
if (r.value === e) return !0;
|
|
139
|
+
if (Array.isArray(r.value)) {
|
|
140
|
+
if (typeof e == "string") return r.value.includes(e);
|
|
141
|
+
if (S.value.label)
|
|
142
|
+
return r.value.some((s) => s.id === e.id);
|
|
143
143
|
}
|
|
144
144
|
return !1;
|
|
145
|
-
},
|
|
146
|
-
|
|
145
|
+
}, I = (e) => {
|
|
146
|
+
f("open", e);
|
|
147
147
|
}, L = (e) => {
|
|
148
|
-
|
|
148
|
+
f("close", e);
|
|
149
149
|
}, U = (e) => {
|
|
150
|
-
|
|
151
|
-
|
|
150
|
+
q(() => {
|
|
151
|
+
f("select", e);
|
|
152
152
|
});
|
|
153
153
|
}, P = () => {
|
|
154
|
-
|
|
155
|
-
if (
|
|
156
|
-
const e =
|
|
157
|
-
(
|
|
154
|
+
q(() => {
|
|
155
|
+
if (p.value) {
|
|
156
|
+
const e = h.value.filter(
|
|
157
|
+
(s) => k(s)
|
|
158
158
|
) || [];
|
|
159
|
-
|
|
159
|
+
f("change", e);
|
|
160
160
|
} else {
|
|
161
|
-
const e =
|
|
162
|
-
(
|
|
161
|
+
const e = h.value.find(
|
|
162
|
+
(s) => k(s)
|
|
163
163
|
);
|
|
164
|
-
|
|
164
|
+
f("change", [e]);
|
|
165
165
|
}
|
|
166
166
|
});
|
|
167
167
|
}, A = (e) => {
|
|
168
168
|
v.value.select(e);
|
|
169
|
-
},
|
|
169
|
+
}, R = () => {
|
|
170
170
|
v.value.activate();
|
|
171
171
|
}, z = () => {
|
|
172
172
|
v.value.deactivate();
|
|
@@ -177,57 +177,57 @@ import './style/dropdown.css';const de = (t) => (Z("data-v-9e2c3262"), t = t(),
|
|
|
177
177
|
/**
|
|
178
178
|
* Abre el dropdown
|
|
179
179
|
*/
|
|
180
|
-
activate:
|
|
180
|
+
activate: R,
|
|
181
181
|
/**
|
|
182
182
|
* Cierra el dropdown
|
|
183
183
|
*/
|
|
184
184
|
deactivate: z
|
|
185
|
-
}), (e,
|
|
186
|
-
|
|
185
|
+
}), (e, s) => (i(), b("div", ne, [
|
|
186
|
+
B(Z, W({
|
|
187
187
|
ref_key: "multiselect",
|
|
188
188
|
ref: v,
|
|
189
|
-
modelValue:
|
|
190
|
-
"onUpdate:modelValue":
|
|
191
|
-
class:
|
|
192
|
-
options:
|
|
193
|
-
"close-on-select":
|
|
189
|
+
modelValue: r.value,
|
|
190
|
+
"onUpdate:modelValue": s[2] || (s[2] = (l) => r.value = l),
|
|
191
|
+
class: F.value,
|
|
192
|
+
options: n(h),
|
|
193
|
+
"close-on-select": N.value,
|
|
194
194
|
"show-labels": !1,
|
|
195
|
-
disabled:
|
|
196
|
-
multiple:
|
|
195
|
+
disabled: n(m),
|
|
196
|
+
multiple: n(p),
|
|
197
197
|
searchable: !1,
|
|
198
198
|
"open-direction": "bottom",
|
|
199
|
-
limit:
|
|
199
|
+
limit: n(C),
|
|
200
200
|
"limit-text": t.limitText
|
|
201
|
-
},
|
|
202
|
-
onOpen:
|
|
201
|
+
}, S.value, {
|
|
202
|
+
onOpen: I,
|
|
203
203
|
onClose: L,
|
|
204
204
|
onSelect: U,
|
|
205
205
|
"onUpdate:modelValue": P,
|
|
206
|
-
onFocus:
|
|
206
|
+
onFocus: s[3] || (s[3] = u(() => R(), ["prevent"])),
|
|
207
207
|
onBlur: u(() => null, ["prevent"])
|
|
208
|
-
}),
|
|
209
|
-
selection:
|
|
210
|
-
|
|
208
|
+
}), M({
|
|
209
|
+
selection: o(({ isOpen: l }) => [
|
|
210
|
+
B(n(ee), {
|
|
211
211
|
id: `multiselect-dropdown-${t.id}`,
|
|
212
|
-
modelValue:
|
|
213
|
-
"onUpdate:modelValue":
|
|
212
|
+
modelValue: _.value,
|
|
213
|
+
"onUpdate:modelValue": s[1] || (s[1] = (w) => _.value = w),
|
|
214
214
|
class: "rds-e-dropdown__input",
|
|
215
|
-
disabled:
|
|
215
|
+
disabled: n(m),
|
|
216
216
|
label: t.label,
|
|
217
217
|
error: t.error,
|
|
218
218
|
helper: t.helper,
|
|
219
219
|
"helper-text": t.helperText,
|
|
220
220
|
readonly: "",
|
|
221
|
-
onClick: u((w) => l ? null :
|
|
222
|
-
},
|
|
223
|
-
"right-icon":
|
|
224
|
-
|
|
221
|
+
onClick: u((w) => l ? null : R(), ["prevent", "stop"])
|
|
222
|
+
}, M({
|
|
223
|
+
"right-icon": o(() => [
|
|
224
|
+
B(n(le), {
|
|
225
225
|
name: "arrow_down",
|
|
226
226
|
"aria-hidden": "true",
|
|
227
227
|
class: X(["rds-e-dropdown__input-caret", {
|
|
228
228
|
"rds-e-dropdown__input-caret--open": l
|
|
229
229
|
}]),
|
|
230
|
-
onClick:
|
|
230
|
+
onClick: s[0] || (s[0] = u(() => {
|
|
231
231
|
}, ["self", "stop"])),
|
|
232
232
|
onMousedown: u(G, ["self", "prevent", "stop"])
|
|
233
233
|
}, null, 8, ["class"])
|
|
@@ -236,94 +236,94 @@ import './style/dropdown.css';const de = (t) => (Z("data-v-9e2c3262"), t = t(),
|
|
|
236
236
|
}, [
|
|
237
237
|
e.$slots["helper-text"] ? {
|
|
238
238
|
name: "helper-text",
|
|
239
|
-
fn:
|
|
239
|
+
fn: o(() => [
|
|
240
240
|
d(e.$slots, "helper-text", {}, void 0, !0)
|
|
241
241
|
]),
|
|
242
242
|
key: "0"
|
|
243
243
|
} : void 0
|
|
244
244
|
]), 1032, ["id", "modelValue", "disabled", "label", "error", "helper", "helper-text", "onClick"])
|
|
245
245
|
]),
|
|
246
|
-
placeholder:
|
|
247
|
-
|
|
246
|
+
placeholder: o(() => [
|
|
247
|
+
s[4] || (s[4] = a("span", null, null, -1))
|
|
248
248
|
]),
|
|
249
|
-
option:
|
|
250
|
-
|
|
251
|
-
|
|
252
|
-
|
|
253
|
-
|
|
249
|
+
option: o(({ option: l, search: w, index: V }) => [
|
|
250
|
+
a("div", oe, [
|
|
251
|
+
a("div", de, [
|
|
252
|
+
a("div", ae, [
|
|
253
|
+
n(p) ? (i(), T(n(te), {
|
|
254
254
|
key: 0,
|
|
255
|
-
id: `${
|
|
255
|
+
id: `${V}-${l.id}`,
|
|
256
256
|
small: t.small,
|
|
257
257
|
"is-checked": k(l),
|
|
258
|
-
disabled:
|
|
258
|
+
disabled: n(m) || (l == null ? void 0 : l.$isDisabled) || !1,
|
|
259
259
|
onClick: u((g) => A(l), ["prevent", "stop"])
|
|
260
|
-
}, null, 8, ["id", "small", "is-checked", "disabled", "onClick"])) : !
|
|
260
|
+
}, null, 8, ["id", "small", "is-checked", "disabled", "onClick"])) : !n(p) && t.showRadio ? (i(), T(n(se), {
|
|
261
261
|
key: 1,
|
|
262
|
-
id: `${
|
|
262
|
+
id: `${V}-${l.id}`,
|
|
263
263
|
small: t.small,
|
|
264
264
|
"group-name": `group-${t.id}`,
|
|
265
265
|
checked: k(l),
|
|
266
|
-
disabled:
|
|
266
|
+
disabled: n(m) || (l == null ? void 0 : l.$isDisabled) || !1,
|
|
267
267
|
option: l,
|
|
268
268
|
onClick: u((g) => A(l), ["prevent", "stop"])
|
|
269
|
-
}, null, 8, ["id", "small", "group-name", "checked", "disabled", "option", "onClick"])) :
|
|
269
|
+
}, null, 8, ["id", "small", "group-name", "checked", "disabled", "option", "onClick"])) : O("", !0)
|
|
270
270
|
]),
|
|
271
|
-
|
|
271
|
+
a("div", ie, [
|
|
272
272
|
d(e.$slots, "singleLabel", { option: l }, () => {
|
|
273
273
|
var g;
|
|
274
274
|
return [
|
|
275
|
-
(g =
|
|
276
|
-
|
|
277
|
-
l != null && l.detail ? (i(),
|
|
278
|
-
], 64)) : (i(),
|
|
275
|
+
(g = S.value) != null && g.label ? (i(), b(Y, { key: 0 }, [
|
|
276
|
+
a("span", null, D(l.label), 1),
|
|
277
|
+
l != null && l.detail ? (i(), b("span", ue, D(l.detail), 1)) : O("", !0)
|
|
278
|
+
], 64)) : (i(), b("span", ce, D(l), 1))
|
|
279
279
|
];
|
|
280
280
|
}, !0)
|
|
281
281
|
])
|
|
282
282
|
]),
|
|
283
|
-
e.$slots.optionAppend ? (i(),
|
|
283
|
+
e.$slots.optionAppend ? (i(), b("div", fe, [
|
|
284
284
|
d(e.$slots, "optionAppend", {
|
|
285
285
|
option: l,
|
|
286
286
|
search: w,
|
|
287
|
-
index:
|
|
287
|
+
index: V
|
|
288
288
|
}, void 0, !0)
|
|
289
|
-
])) :
|
|
289
|
+
])) : O("", !0)
|
|
290
290
|
])
|
|
291
291
|
]),
|
|
292
292
|
_: 2
|
|
293
293
|
}, [
|
|
294
294
|
e.$slots.limit ? {
|
|
295
295
|
name: "limit",
|
|
296
|
-
fn:
|
|
296
|
+
fn: o(() => [
|
|
297
297
|
d(e.$slots, "limit", {}, void 0, !0)
|
|
298
298
|
]),
|
|
299
299
|
key: "0"
|
|
300
300
|
} : void 0,
|
|
301
301
|
e.$slots.maxElements ? {
|
|
302
302
|
name: "maxElements",
|
|
303
|
-
fn:
|
|
303
|
+
fn: o(() => [
|
|
304
304
|
d(e.$slots, "maxElements", {}, void 0, !0)
|
|
305
305
|
]),
|
|
306
306
|
key: "1"
|
|
307
307
|
} : void 0,
|
|
308
308
|
e.$slots.noResult ? {
|
|
309
309
|
name: "noResult",
|
|
310
|
-
fn:
|
|
310
|
+
fn: o(({ search: l }) => [
|
|
311
311
|
d(e.$slots, "noResult", { search: l }, void 0, !0)
|
|
312
312
|
]),
|
|
313
313
|
key: "2"
|
|
314
314
|
} : void 0,
|
|
315
315
|
e.$slots.noOptions ? {
|
|
316
316
|
name: "noOptions",
|
|
317
|
-
fn:
|
|
317
|
+
fn: o(() => [
|
|
318
318
|
d(e.$slots, "noOptions", {}, void 0, !0)
|
|
319
319
|
]),
|
|
320
320
|
key: "3"
|
|
321
321
|
} : void 0,
|
|
322
322
|
e.$slots.afterList ? {
|
|
323
323
|
name: "afterList",
|
|
324
|
-
fn:
|
|
325
|
-
|
|
326
|
-
|
|
324
|
+
fn: o(() => [
|
|
325
|
+
a("div", me, [
|
|
326
|
+
a("div", pe, [
|
|
327
327
|
d(e.$slots, "afterList", {}, void 0, !0)
|
|
328
328
|
])
|
|
329
329
|
])
|
|
@@ -333,7 +333,7 @@ import './style/dropdown.css';const de = (t) => (Z("data-v-9e2c3262"), t = t(),
|
|
|
333
333
|
]), 1040, ["modelValue", "class", "options", "close-on-select", "disabled", "multiple", "limit", "limit-text"])
|
|
334
334
|
]));
|
|
335
335
|
}
|
|
336
|
-
}),
|
|
336
|
+
}), Ce = /* @__PURE__ */ re(ve, [["__scopeId", "data-v-9e2c3262"]]);
|
|
337
337
|
export {
|
|
338
|
-
|
|
338
|
+
Ce as default
|
|
339
339
|
};
|