@ulu/frontend-vue 0.5.5 → 0.5.7

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.
@@ -22,6 +22,7 @@ declare const __VLS_component: import('vue').DefineComponent<{}, {
22
22
  titleTo?: string | Record<string, any> | undefined;
23
23
  titleHref?: string | undefined;
24
24
  titleTarget?: string | undefined;
25
+ image?: string | Record<string, any> | undefined;
25
26
  imageSrc?: string | undefined;
26
27
  imageAlt?: string | undefined;
27
28
  $props: {
@@ -42,6 +43,7 @@ declare const __VLS_component: import('vue').DefineComponent<{}, {
42
43
  readonly titleTo?: string | Record<string, any> | undefined;
43
44
  readonly titleHref?: string | undefined;
44
45
  readonly titleTarget?: string | undefined;
46
+ readonly image?: string | Record<string, any> | undefined;
45
47
  readonly imageSrc?: string | undefined;
46
48
  readonly imageAlt?: string | undefined;
47
49
  };
@@ -1 +1 @@
1
- {"version":3,"file":"UluCard.vue.d.ts","sourceRoot":"","sources":["../../../lib/components/elements/UluCard.vue"],"names":[],"mappings":"AA+EA;wBAkpBqB,uBAAuB,CAAC,OAAO,eAAe,EAAE,oBAAoB,CAAC,OAAO,CAAC,CAAC;;6BAEtE,CAAC,EAAE,CAAC;;;AAbjC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;QAUG"}
1
+ {"version":3,"file":"UluCard.vue.d.ts","sourceRoot":"","sources":["../../../lib/components/elements/UluCard.vue"],"names":[],"mappings":"AA+EA;wBAitBqB,uBAAuB,CAAC,OAAO,eAAe,EAAE,oBAAoB,CAAC,OAAO,CAAC,CAAC;;6BAEtE,CAAC,EAAE,CAAC;;;AAbjC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;QAUG"}
@@ -1,14 +1,16 @@
1
- import { useSlots as N, ref as f, computed as r, createBlock as k, openBlock as a, resolveDynamicComponent as B, normalizeStyle as R, normalizeClass as h, unref as n, withCtx as S, createElementVNode as C, createElementBlock as m, createCommentVNode as y, renderSlot as i, createTextVNode as x, toDisplayString as b } from "vue";
2
- import { RouterLink as P } from "vue-router";
3
- import { useModifiers as V } from "../../composables/useModifiers.js";
4
- import { refToElement as I } from "../../utils/dom.js";
5
- const q = { class: "card__body" }, L = { class: "card__main" }, F = ["href", "target"], G = {
1
+ import { useSlots as R, computed as r, ref as f, createBlock as k, openBlock as a, resolveDynamicComponent as z, normalizeStyle as V, normalizeClass as h, unref as n, withCtx as S, createElementVNode as $, createElementBlock as m, createCommentVNode as g, renderSlot as i, createTextVNode as C, toDisplayString as x, createVNode as I, normalizeProps as q, guardReactiveProps as L } from "vue";
2
+ import { RouterLink as B } from "vue-router";
3
+ import { useModifiers as F } from "../../composables/useModifiers.js";
4
+ import { refToElement as G } from "../../utils/dom.js";
5
+ import { warnDeprecatedProp as O } from "../../utils/props.js";
6
+ import J from "./UluImage.vue.js";
7
+ const K = { class: "card__body" }, Q = { class: "card__main" }, W = ["href", "target"], X = {
6
8
  key: 0,
7
9
  class: "card__aside"
8
- }, J = ["src", "alt"], K = {
10
+ }, Y = {
9
11
  key: 1,
10
12
  class: "card__footer"
11
- }, Z = {
13
+ }, oe = {
12
14
  __name: "UluCard",
13
15
  props: {
14
16
  /**
@@ -82,11 +84,17 @@ const q = { class: "card__body" }, L = { class: "card__main" }, F = ["href", "ta
82
84
  default: () => ({})
83
85
  },
84
86
  /**
85
- * Source of image
87
+ * Unified image prop configuration passed to UluImage. Can be a string (src) or an object matching UluImage props.
88
+ */
89
+ image: [String, Object],
90
+ /**
91
+ * This is deprecated and will be removed in future version use "image" prop or image slot
92
+ * @deprecated Use `image` instead.
86
93
  */
87
94
  imageSrc: String,
88
95
  /**
89
- * Alt text for image
96
+ * This is deprecated and will be removed in future version use "image" prop or image slot
97
+ * @deprecated Use `image` (as an object with `alt`) instead.
90
98
  */
91
99
  imageAlt: String,
92
100
  /**
@@ -112,118 +120,118 @@ const q = { class: "card__body" }, L = { class: "card__main" }, F = ["href", "ta
112
120
  modifiers: [Array, String]
113
121
  },
114
122
  emits: ["proxy-click"],
115
- setup(e, { emit: $ }) {
116
- const t = e, O = $, s = N();
117
- t.proxyClick && (t.to || t.href) && console.warn("UluCard: 'proxyClick' is ignored when 'to' or 'href' are present."), (t.titleTo || t.titleHref) && (t.to || t.href) && console.warn("UluCard: 'titleTo'/'titleHref' should not be used with 'to'/'href'.");
118
- const T = f(null), v = f(null), { resolvedModifiers: H } = V({ props: t, baseClass: "card" }), E = f(null), c = f(!1), u = r(() => t.proxyClick && !t.to && !t.href), w = r(() => u.value && (t.titleTo || t.titleHref)), M = r(() => u.value && !w.value), g = r(() => u.value || null), z = r(() => ({
123
+ setup(t, { emit: p }) {
124
+ const e = t, H = p, s = R();
125
+ e.proxyClick && (e.to || e.href) && console.warn("UluCard: 'proxyClick' is ignored when 'to' or 'href' are present."), (e.titleTo || e.titleHref) && (e.to || e.href) && console.warn("UluCard: 'titleTo'/'titleHref' should not be used with 'to'/'href'."), O("UluCard", e, "imageSrc", "image"), O("UluCard", e, "imageAlt", "image");
126
+ const b = r(() => e.image ? typeof e.image == "string" ? { src: e.image } : e.image : e.imageSrc ? {
127
+ src: e.imageSrc,
128
+ alt: e.imageAlt || ""
129
+ } : null), T = f(null), y = f(null), { resolvedModifiers: M } = F({ props: e, baseClass: "card" }), w = f(null), c = f(!1), u = r(() => e.proxyClick && !e.to && !e.href), E = r(() => u.value && (e.titleTo || e.titleHref)), U = r(() => u.value && !E.value), v = r(() => u.value || null), P = r(() => ({
119
130
  selectorPrevent: "input, select, textarea, button, a, [tabindex='-1']",
120
131
  mousedownDurationPrevent: 250,
121
- ...t.proxyClickOptions
122
- })), j = r(() => u.value ? "pointer" : null), D = r(() => t.to ? P : t.href ? "a" : t.cardElement);
123
- function U({ target: l, timeStamp: d }) {
124
- if (!g.value) return;
125
- const { selectorPrevent: o } = z.value;
126
- c.value = !1, l.closest(o) || (c.value = !0, E.value = d);
132
+ ...e.proxyClickOptions
133
+ })), j = r(() => u.value ? "pointer" : null), D = r(() => e.to ? B : e.href ? "a" : e.cardElement);
134
+ function A({ target: l, timeStamp: d }) {
135
+ if (!v.value) return;
136
+ const { selectorPrevent: o } = P.value;
137
+ c.value = !1, l.closest(o) || (c.value = !0, w.value = d);
127
138
  }
128
- function A({ timeStamp: l }) {
129
- if (!g.value || !c.value) return;
130
- const { mousedownDurationPrevent: d } = z.value;
131
- if (l - E.value < d) {
132
- if (w.value) {
133
- const o = I(v.value);
139
+ function N({ timeStamp: l }) {
140
+ if (!v.value || !c.value) return;
141
+ const { mousedownDurationPrevent: d } = P.value;
142
+ if (l - w.value < d) {
143
+ if (E.value) {
144
+ const o = G(y.value);
134
145
  o ? o.click() : console.warn("Unable to resolve title link ref");
135
- } else if (M.value) {
146
+ } else if (U.value) {
136
147
  const o = T.value?.querySelector("[data-ulu-card-proxy-target]");
137
- o ? o.click() : O("proxy-click");
148
+ o ? o.click() : H("proxy-click");
138
149
  }
139
150
  }
140
151
  c.value = !1;
141
152
  }
142
- return (l, d) => (a(), k(B(D.value), {
153
+ return (l, d) => (a(), k(z(D.value), {
143
154
  ref_key: "cardRoot",
144
155
  ref: T,
145
156
  class: h(["card", [
146
157
  {
147
- "card--horizontal": e.horizontal || e.horizontalCenter,
148
- "card--horizontal-center": e.horizontalCenter,
149
- "card--overlay": e.overlay
158
+ "card--horizontal": t.horizontal || t.horizontalCenter,
159
+ "card--horizontal-center": t.horizontalCenter,
160
+ "card--overlay": t.overlay
150
161
  },
151
- n(H)
162
+ n(M)
152
163
  ]]),
153
- onMousedown: U,
154
- onMouseup: A,
155
- style: R({ cursor: j.value }),
156
- target: e.target,
157
- to: e.to,
158
- href: e.href,
159
- "data-ulu-proxy-click-init": g.value
164
+ onMousedown: A,
165
+ onMouseup: N,
166
+ style: V({ cursor: j.value }),
167
+ target: t.target,
168
+ to: t.to,
169
+ href: t.href,
170
+ "data-ulu-proxy-click-init": v.value
160
171
  }, {
161
172
  default: S(() => [
162
- C("div", q, [
163
- C("div", L, [
164
- e.title || n(s).title ? (a(), k(B(e.titleElement), {
173
+ $("div", K, [
174
+ $("div", Q, [
175
+ t.title || n(s).title ? (a(), k(z(t.titleElement), {
165
176
  key: 0,
166
- class: h(["card__title", e.classes.title])
177
+ class: h(["card__title", t.classes.title])
167
178
  }, {
168
179
  default: S(() => [
169
- e.titleTo ? (a(), k(n(P), {
180
+ t.titleTo ? (a(), k(n(B), {
170
181
  key: 0,
171
182
  class: "card__title-link",
172
- to: e.titleTo,
183
+ to: t.titleTo,
173
184
  ref_key: "link",
174
- ref: v
185
+ ref: y
175
186
  }, {
176
187
  default: S(() => [
177
188
  i(l.$slots, "title", {}, () => [
178
- x(b(e.title), 1)
189
+ C(x(t.title), 1)
179
190
  ])
180
191
  ]),
181
192
  _: 3
182
- }, 8, ["to"])) : e.titleHref ? (a(), m("a", {
193
+ }, 8, ["to"])) : t.titleHref ? (a(), m("a", {
183
194
  key: 1,
184
195
  class: "card__title-link",
185
- href: e.titleHref,
186
- target: e.titleTarget,
196
+ href: t.titleHref,
197
+ target: t.titleTarget,
187
198
  ref_key: "link",
188
- ref: v
199
+ ref: y
189
200
  }, [
190
201
  i(l.$slots, "title", {}, () => [
191
- x(b(e.title), 1)
202
+ C(x(t.title), 1)
192
203
  ])
193
- ], 8, F)) : i(l.$slots, "title", { key: 2 }, () => [
194
- x(b(e.title), 1)
204
+ ], 8, W)) : i(l.$slots, "title", { key: 2 }, () => [
205
+ C(x(t.title), 1)
195
206
  ])
196
207
  ]),
197
208
  _: 3
198
- }, 8, ["class"])) : y("", !0),
209
+ }, 8, ["class"])) : g("", !0),
199
210
  i(l.$slots, "body")
200
211
  ]),
201
- n(s).aside ? (a(), m("div", G, [
212
+ n(s).aside ? (a(), m("div", X, [
202
213
  i(l.$slots, "aside")
203
- ])) : y("", !0)
214
+ ])) : g("", !0)
204
215
  ]),
205
- n(s).image || e.imageSrc ? (a(), m("div", {
216
+ n(s).image || b.value ? (a(), m("div", {
206
217
  key: 0,
207
218
  class: h(["card__image", [
208
- { "card__image--icon": e.imageIcon },
209
- e.classes.image
219
+ { "card__image--icon": t.imageIcon },
220
+ t.classes.image
210
221
  ]])
211
222
  }, [
212
223
  i(l.$slots, "image", {}, () => [
213
- C("img", {
214
- src: e.imageSrc,
215
- alt: e.imageAlt
216
- }, null, 8, J)
224
+ I(J, q(L(b.value)), null, 16)
217
225
  ])
218
- ], 2)) : y("", !0),
219
- n(s).footer ? (a(), m("div", K, [
226
+ ], 2)) : g("", !0),
227
+ n(s).footer ? (a(), m("div", Y, [
220
228
  i(l.$slots, "footer")
221
- ])) : y("", !0)
229
+ ])) : g("", !0)
222
230
  ]),
223
231
  _: 3
224
232
  }, 40, ["class", "style", "target", "to", "href", "data-ulu-proxy-click-init"]));
225
233
  }
226
234
  };
227
235
  export {
228
- Z as default
236
+ oe as default
229
237
  };
@@ -1,4 +1,9 @@
1
- declare const _default: import('vue').DefineComponent<{}, {
1
+ declare const _default: __VLS_WithTemplateSlots<typeof __VLS_component, __VLS_TemplateResult["slots"]>;
2
+ export default _default;
3
+ type __VLS_WithTemplateSlots<T, S> = T & (new () => {
4
+ $slots: S;
5
+ });
6
+ declare const __VLS_component: import('vue').DefineComponent<{}, {
2
7
  classes: Record<string, any>;
3
8
  alt: string;
4
9
  src: string;
@@ -10,5 +15,12 @@ declare const _default: import('vue').DefineComponent<{}, {
10
15
  readonly sources?: unknown[] | undefined;
11
16
  };
12
17
  }, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, true, {}, any>;
13
- export default _default;
18
+ type __VLS_TemplateResult = {
19
+ attrs: Partial<{}>;
20
+ slots: {
21
+ default?(_: {}): any;
22
+ };
23
+ refs: {};
24
+ rootEl: any;
25
+ };
14
26
  //# sourceMappingURL=UluImage.vue.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"UluImage.vue.d.ts","sourceRoot":"","sources":["../../../lib/components/elements/UluImage.vue"],"names":[],"mappings":"AAuBA;"}
1
+ {"version":3,"file":"UluImage.vue.d.ts","sourceRoot":"","sources":["../../../lib/components/elements/UluImage.vue"],"names":[],"mappings":"AAwBA;wBA2KqB,uBAAuB,CAAC,OAAO,eAAe,EAAE,oBAAoB,CAAC,OAAO,CAAC,CAAC;;6BAEtE,CAAC,EAAE,CAAC;;;AAVjC;;;;;;;;;;;2OAOG"}
@@ -1,5 +1,6 @@
1
- import { createElementBlock as t, openBlock as s, normalizeClass as n, createElementVNode as u, Fragment as i, renderList as m, mergeProps as r } from "vue";
2
- const o = ["src", "alt"], g = ["src", "alt"], y = /* @__PURE__ */ Object.assign({
1
+ import { createElementBlock as r, openBlock as s, normalizeClass as n, renderSlot as u, createElementVNode as i, Fragment as m, renderList as o, createBlock as f, mergeProps as l } from "vue";
2
+ import d from "./UluImageSource.vue.js";
3
+ const g = ["src", "alt"], y = ["src", "alt"], B = /* @__PURE__ */ Object.assign({
3
4
  inheritAttrs: !1
4
5
  }, {
5
6
  __name: "UluImage",
@@ -30,24 +31,25 @@ const o = ["src", "alt"], g = ["src", "alt"], y = /* @__PURE__ */ Object.assign(
30
31
  }
31
32
  },
32
33
  setup(e) {
33
- return (l, d) => e.sources?.length ? (s(), t("picture", {
34
+ return (t, k) => e.sources?.length || t.$slots.default ? (s(), r("picture", {
34
35
  key: 0,
35
36
  class: n(e.classes?.picture)
36
37
  }, [
37
- (s(!0), t(i, null, m(e.sources, (a, c) => (s(), t("source", r({ key: c }, { ref_for: !0 }, a), null, 16))), 128)),
38
- u("img", r({
38
+ u(t.$slots, "default"),
39
+ (s(!0), r(m, null, o(e.sources, (a, c) => (s(), f(d, l({ key: c }, { ref_for: !0 }, a), null, 16))), 128)),
40
+ i("img", l({
39
41
  src: e.src,
40
42
  alt: e.alt,
41
43
  class: e.classes?.img
42
- }, l.$attrs), null, 16, o)
43
- ], 2)) : (s(), t("img", r({
44
+ }, t.$attrs), null, 16, g)
45
+ ], 2)) : (s(), r("img", l({
44
46
  key: 1,
45
47
  src: e.src,
46
48
  alt: e.alt,
47
49
  class: e.classes?.img
48
- }, l.$attrs), null, 16, g));
50
+ }, t.$attrs), null, 16, y));
49
51
  }
50
52
  });
51
53
  export {
52
- y as default
54
+ B as default
53
55
  };
@@ -0,0 +1,10 @@
1
+ declare const _default: import('vue').DefineComponent<{}, {
2
+ srcset: string;
3
+ media?: string | undefined;
4
+ $props: {
5
+ readonly srcset?: string | undefined;
6
+ readonly media?: string | undefined;
7
+ };
8
+ }, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, true, {}, any>;
9
+ export default _default;
10
+ //# sourceMappingURL=UluImageSource.vue.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"UluImageSource.vue.d.ts","sourceRoot":"","sources":["../../../lib/components/elements/UluImageSource.vue"],"names":[],"mappings":"AAOA;"}
@@ -0,0 +1,31 @@
1
+ import { createElementBlock as r, openBlock as s, mergeProps as a } from "vue";
2
+ const c = ["srcset", "media"], o = /* @__PURE__ */ Object.assign({
3
+ inheritAttrs: !1
4
+ }, {
5
+ __name: "UluImageSource",
6
+ props: {
7
+ /**
8
+ * Source set (e.g. image paths)
9
+ */
10
+ srcset: {
11
+ type: String,
12
+ required: !0
13
+ },
14
+ /**
15
+ * Media query (e.g. (min-width: 600px))
16
+ */
17
+ media: {
18
+ type: String,
19
+ default: void 0
20
+ }
21
+ },
22
+ setup(e) {
23
+ return (t, n) => (s(), r("source", a({
24
+ srcset: e.srcset,
25
+ media: e.media
26
+ }, t.$attrs), null, 16, c));
27
+ }
28
+ });
29
+ export {
30
+ o as default
31
+ };
@@ -23,6 +23,7 @@ export { default as UluDefinitionListItem } from './elements/UluDefinitionListIt
23
23
  export { default as UluExternalLink } from './elements/UluExternalLink.vue';
24
24
  export { default as UluIcon } from './elements/UluIcon.vue';
25
25
  export { default as UluImage } from './elements/UluImage.vue';
26
+ export { default as UluImageSource } from './elements/UluImageSource.vue';
26
27
  export { default as UluList } from './elements/UluList.vue';
27
28
  export { default as UluListItem } from './elements/UluListItem.vue';
28
29
  export { default as UluCounterList } from './elements/UluCounterList.vue';
@@ -11,6 +11,6 @@ declare const _default: import('vue').DefineComponent<{}, {
11
11
  readonly alt?: string | undefined;
12
12
  readonly imageId?: string | undefined;
13
13
  };
14
- }, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, true, {}, HTMLImageElement>;
14
+ }, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, true, {}, any>;
15
15
  export default _default;
16
16
  //# sourceMappingURL=UluPlaceholderImage.vue.d.ts.map
@@ -1,6 +1,7 @@
1
- import { computed as n, createElementBlock as d, openBlock as h } from "vue";
2
- import { randomInt as o } from "@ulu/utils/random.js";
3
- const s = ["src", "alt"], g = {
1
+ import { computed as o, createBlock as m, openBlock as d } from "vue";
2
+ import { randomInt as n } from "@ulu/utils/random.js";
3
+ import h from "../elements/UluImage.vue.js";
4
+ const g = {
4
5
  __name: "UluPlaceholderImage",
5
6
  props: {
6
7
  imageId: String,
@@ -28,17 +29,17 @@ const s = ["src", "alt"], g = {
28
29
  random: Boolean
29
30
  },
30
31
  setup(e) {
31
- const t = e, a = n(() => t.random ? {
32
- width: o(500, 1e3),
33
- height: o(500, 1e3)
34
- } : { width: t.width, height: t.height }), c = n(() => {
32
+ const t = e, a = o(() => t.random ? {
33
+ width: n(500, 1e3),
34
+ height: n(500, 1e3)
35
+ } : { width: t.width, height: t.height }), c = o(() => {
35
36
  const { width: r, height: i } = a.value;
36
37
  return `https://picsum.photos/${t.imageId ? `id/${t.imageId}/` : ""}${r}/${i}`;
37
38
  });
38
- return (r, i) => (h(), d("img", {
39
+ return (r, i) => (d(), m(h, {
39
40
  src: c.value,
40
41
  alt: e.alt
41
- }, null, 8, s));
42
+ }, null, 8, ["src", "alt"]));
42
43
  }
43
44
  };
44
45
  export {
package/dist/index.js CHANGED
@@ -8,11 +8,11 @@ import { default as U } from "./plugins/breakpoints/index.js";
8
8
  import { default as n } from "./components/collapsible/UluAccordion.vue.js";
9
9
  import { default as S } from "./components/collapsible/UluAccordionGroup.vue.js";
10
10
  import { default as T } from "./components/collapsible/UluCollapsible.vue.js";
11
- import { default as A } from "./components/collapsible/UluDropdown.vue.js";
11
+ import { default as g } from "./components/collapsible/UluDropdown.vue.js";
12
12
  import { default as h } from "./components/collapsible/UluModal.vue.js";
13
13
  import { default as P } from "./components/collapsible/UluOverflowPopover.vue.js";
14
14
  import { default as C } from "./components/collapsible/UluTab.vue.js";
15
- import { default as y } from "./components/collapsible/UluTabGroup.vue.js";
15
+ import { default as v } from "./components/collapsible/UluTabGroup.vue.js";
16
16
  import { default as R } from "./components/collapsible/UluTabList.vue.js";
17
17
  import { default as w } from "./components/collapsible/UluTabPanel.vue.js";
18
18
  import { default as D } from "./components/collapsible/UluTabPanels.vue.js";
@@ -30,209 +30,211 @@ import { default as te } from "./components/elements/UluDefinitionListItem.vue.j
30
30
  import { default as le } from "./components/elements/UluExternalLink.vue.js";
31
31
  import { default as fe } from "./components/elements/UluIcon.vue.js";
32
32
  import { default as me } from "./components/elements/UluImage.vue.js";
33
- import { default as de } from "./components/elements/UluList.vue.js";
34
- import { default as Ue } from "./components/elements/UluListItem.vue.js";
35
- import { default as ne } from "./components/elements/UluCounterList.vue.js";
36
- import { default as Se } from "./components/elements/UluOverflowScroller.vue.js";
37
- import { default as Te } from "./components/elements/UluRule.vue.js";
38
- import { default as Ae } from "./components/elements/UluScrollSlider.vue.js";
39
- import { default as he } from "./components/elements/UluSlider.vue.js";
40
- import { default as Pe } from "./components/elements/UluSpokeSpinner.vue.js";
41
- import { default as Ce } from "./components/elements/UluTable.vue.js";
42
- import { default as ye } from "./components/elements/UluTag.vue.js";
43
- import { default as Re } from "./components/forms/UluSelectableMenu.vue.js";
44
- import { default as we } from "./components/forms/UluFileDisplay.vue.js";
45
- import { default as De } from "./components/forms/UluFormFile.vue.js";
46
- import { default as Ee } from "./components/forms/UluFormMessage.vue.js";
47
- import { default as We } from "./components/forms/UluFormSelect.vue.js";
48
- import { default as He } from "./components/forms/UluFormText.vue.js";
49
- import { default as Ve } from "./components/forms/UluSearchForm.vue.js";
50
- import { default as ze } from "./components/forms/UluForm.vue.js";
51
- import { default as Ke } from "./components/forms/UluFormActions.vue.js";
52
- import { default as Xe } from "./components/forms/UluFormCheckbox.vue.js";
53
- import { default as Ze } from "./components/forms/UluFormFieldset.vue.js";
54
- import { default as $e } from "./components/forms/UluFormItem.vue.js";
55
- import { default as oo } from "./components/forms/UluFormItemsInline.vue.js";
56
- import { default as to } from "./components/forms/UluFormRadio.vue.js";
57
- import { default as lo } from "./components/forms/UluFormRequiredChar.vue.js";
58
- import { default as fo } from "./components/forms/UluFormTextarea.vue.js";
59
- import { default as mo } from "./components/layout/UluAdaptiveLayout.vue.js";
60
- import { default as xo } from "./components/layout/UluDataGrid.vue.js";
61
- import { default as io } from "./components/layout/UluTitleRail.vue.js";
62
- import { default as co } from "./components/layout/UluWhenBreakpoint.vue.js";
63
- import { default as Fo } from "./components/navigation/UluBreadcrumb.vue.js";
64
- import { default as bo } from "./components/navigation/UluMenu.vue.js";
65
- import { default as go } from "./components/navigation/UluMenuStack.vue.js";
66
- import { default as ko } from "./components/navigation/UluNavStrip.vue.js";
67
- import { default as Lo } from "./components/navigation/UluPager.vue.js";
68
- import { default as vo } from "./components/utils/UluAction.vue.js";
69
- import { default as Io } from "./components/utils/UluConditionalText.vue.js";
70
- import { default as Mo } from "./components/utils/UluConditionalWrapper.vue.js";
71
- import { default as Bo } from "./components/utils/UluPlaceholderImage.vue.js";
72
- import { default as No } from "./components/utils/UluPlaceholderText.vue.js";
73
- import { default as Go } from "./components/utils/UluRouteAnnouncer.vue.js";
74
- import { default as qo } from "./components/utils/UluSanityRichText.vue.js";
75
- import { default as Oo } from "./components/visualizations/UluAnimateNumber.vue.js";
76
- import { default as jo } from "./components/visualizations/UluProgressBar.vue.js";
77
- import { default as Jo } from "./components/visualizations/UluProgressCircle.vue.js";
78
- import { default as Qo } from "./components/systems/facets/UluFacetsActiveFilters.vue.js";
79
- import { default as Yo } from "./components/systems/facets/UluFacetsFilterLists.vue.js";
80
- import { default as _o } from "./components/systems/facets/UluFacetsFilterAccordions.vue.js";
81
- import { default as er } from "./components/systems/facets/UluFacetsFilterPopovers.vue.js";
82
- import { default as rr } from "./components/systems/facets/UluFacetsFilterSelects.vue.js";
83
- import { default as ar } from "./components/systems/facets/UluFacetsHeaderLayout.vue.js";
84
- import { default as ur } from "./components/systems/facets/UluFacetsResults.vue.js";
85
- import { default as sr } from "./components/systems/facets/UluFacetsSearch.vue.js";
86
- import { default as pr } from "./components/systems/facets/UluFacetsSidebarLayout.vue.js";
87
- import { default as xr } from "./components/systems/facets/UluFacetsSort.vue.js";
88
- import { default as ir } from "./components/systems/facets/UluFacetsList.vue.js";
89
- import { default as cr } from "./components/systems/scroll-anchors/UluScrollAnchors.vue.js";
90
- import { default as Fr } from "./components/systems/scroll-anchors/UluScrollAnchorsNav.vue.js";
91
- import { default as br } from "./components/systems/scroll-anchors/UluScrollAnchorsNavAnimated.vue.js";
92
- import { default as gr } from "./components/systems/scroll-anchors/UluScrollAnchorsSection.vue.js";
93
- import { default as kr } from "./components/systems/scroll-anchors/UluScrollAnchorsHeadlessSection.vue.js";
94
- import { default as Lr } from "./components/systems/skeleton/UluShowSkeleton.vue.js";
95
- import { default as vr } from "./components/systems/skeleton/UluSkeletonContent.vue.js";
96
- import { default as Ir } from "./components/systems/skeleton/UluSkeletonMedia.vue.js";
97
- import { default as Mr } from "./components/systems/skeleton/UluSkeletonText.vue.js";
98
- import { default as Br } from "./components/systems/table-sticky/UluTableSticky.vue.js";
99
- import { default as Nr } from "./components/systems/table-sticky/UluTableStickyRows.vue.js";
100
- import { default as Gr } from "./components/systems/table-sticky/UluTableStickyTable.vue.js";
101
- import { useTooltip as qr } from "./plugins/popovers/useTooltip.js";
102
- import { default as Or } from "./components/elements/UluMain.vue.js";
103
- import { default as jr } from "./components/navigation/UluSkipLink.vue.js";
104
- import { default as Jr } from "./components/utils/UluEmpty.vue.js";
105
- import { default as Qr } from "./components/utils/UluEmptyView.vue.js";
106
- import { useFacets as Yr } from "./components/systems/facets/useFacets.js";
107
- import { useScrollAnchors as _r } from "./components/systems/scroll-anchors/useScrollAnchors.js";
108
- import { useScrollAnchorSection as et } from "./components/systems/scroll-anchors/useScrollAnchorSection.js";
109
- import { useScrollAnchorSections as rt } from "./components/systems/scroll-anchors/useScrollAnchorSections.js";
110
- import { useIcon as at } from "./composables/useIcon.js";
111
- import { useModifiers as ut } from "./composables/useModifiers.js";
112
- import { useWindowResize as st } from "./composables/useWindowResize.js";
113
- import { useRequiredInject as pt } from "./composables/useRequiredInject.js";
114
- import { useBreakpointManager as xt } from "./composables/useBreakpointManager.js";
115
- import { usePagination as it } from "./composables/usePagination.js";
116
- import { useDocumentTitle as ct } from "./composables/useDocumentTitle.js";
117
- import { useUluFloating as Ft } from "./composables/useUluFloating.js";
118
- import { useTableData as bt } from "./composables/useTableData.js";
33
+ import { default as de } from "./components/elements/UluImageSource.vue.js";
34
+ import { default as Ue } from "./components/elements/UluList.vue.js";
35
+ import { default as ne } from "./components/elements/UluListItem.vue.js";
36
+ import { default as Se } from "./components/elements/UluCounterList.vue.js";
37
+ import { default as Te } from "./components/elements/UluOverflowScroller.vue.js";
38
+ import { default as ge } from "./components/elements/UluRule.vue.js";
39
+ import { default as he } from "./components/elements/UluScrollSlider.vue.js";
40
+ import { default as Pe } from "./components/elements/UluSlider.vue.js";
41
+ import { default as Ce } from "./components/elements/UluSpokeSpinner.vue.js";
42
+ import { default as ve } from "./components/elements/UluTable.vue.js";
43
+ import { default as Re } from "./components/elements/UluTag.vue.js";
44
+ import { default as we } from "./components/forms/UluSelectableMenu.vue.js";
45
+ import { default as De } from "./components/forms/UluFileDisplay.vue.js";
46
+ import { default as Ee } from "./components/forms/UluFormFile.vue.js";
47
+ import { default as We } from "./components/forms/UluFormMessage.vue.js";
48
+ import { default as He } from "./components/forms/UluFormSelect.vue.js";
49
+ import { default as Ve } from "./components/forms/UluFormText.vue.js";
50
+ import { default as ze } from "./components/forms/UluSearchForm.vue.js";
51
+ import { default as Ke } from "./components/forms/UluForm.vue.js";
52
+ import { default as Xe } from "./components/forms/UluFormActions.vue.js";
53
+ import { default as Ze } from "./components/forms/UluFormCheckbox.vue.js";
54
+ import { default as $e } from "./components/forms/UluFormFieldset.vue.js";
55
+ import { default as oo } from "./components/forms/UluFormItem.vue.js";
56
+ import { default as to } from "./components/forms/UluFormItemsInline.vue.js";
57
+ import { default as lo } from "./components/forms/UluFormRadio.vue.js";
58
+ import { default as fo } from "./components/forms/UluFormRequiredChar.vue.js";
59
+ import { default as mo } from "./components/forms/UluFormTextarea.vue.js";
60
+ import { default as xo } from "./components/layout/UluAdaptiveLayout.vue.js";
61
+ import { default as io } from "./components/layout/UluDataGrid.vue.js";
62
+ import { default as co } from "./components/layout/UluTitleRail.vue.js";
63
+ import { default as Fo } from "./components/layout/UluWhenBreakpoint.vue.js";
64
+ import { default as bo } from "./components/navigation/UluBreadcrumb.vue.js";
65
+ import { default as Ao } from "./components/navigation/UluMenu.vue.js";
66
+ import { default as ko } from "./components/navigation/UluMenuStack.vue.js";
67
+ import { default as Lo } from "./components/navigation/UluNavStrip.vue.js";
68
+ import { default as Io } from "./components/navigation/UluPager.vue.js";
69
+ import { default as yo } from "./components/utils/UluAction.vue.js";
70
+ import { default as Mo } from "./components/utils/UluConditionalText.vue.js";
71
+ import { default as Bo } from "./components/utils/UluConditionalWrapper.vue.js";
72
+ import { default as No } from "./components/utils/UluPlaceholderImage.vue.js";
73
+ import { default as Go } from "./components/utils/UluPlaceholderText.vue.js";
74
+ import { default as qo } from "./components/utils/UluRouteAnnouncer.vue.js";
75
+ import { default as Oo } from "./components/utils/UluSanityRichText.vue.js";
76
+ import { default as jo } from "./components/visualizations/UluAnimateNumber.vue.js";
77
+ import { default as Jo } from "./components/visualizations/UluProgressBar.vue.js";
78
+ import { default as Qo } from "./components/visualizations/UluProgressCircle.vue.js";
79
+ import { default as Yo } from "./components/systems/facets/UluFacetsActiveFilters.vue.js";
80
+ import { default as _o } from "./components/systems/facets/UluFacetsFilterLists.vue.js";
81
+ import { default as er } from "./components/systems/facets/UluFacetsFilterAccordions.vue.js";
82
+ import { default as rr } from "./components/systems/facets/UluFacetsFilterPopovers.vue.js";
83
+ import { default as ar } from "./components/systems/facets/UluFacetsFilterSelects.vue.js";
84
+ import { default as ur } from "./components/systems/facets/UluFacetsHeaderLayout.vue.js";
85
+ import { default as sr } from "./components/systems/facets/UluFacetsResults.vue.js";
86
+ import { default as pr } from "./components/systems/facets/UluFacetsSearch.vue.js";
87
+ import { default as xr } from "./components/systems/facets/UluFacetsSidebarLayout.vue.js";
88
+ import { default as ir } from "./components/systems/facets/UluFacetsSort.vue.js";
89
+ import { default as cr } from "./components/systems/facets/UluFacetsList.vue.js";
90
+ import { default as Fr } from "./components/systems/scroll-anchors/UluScrollAnchors.vue.js";
91
+ import { default as br } from "./components/systems/scroll-anchors/UluScrollAnchorsNav.vue.js";
92
+ import { default as Ar } from "./components/systems/scroll-anchors/UluScrollAnchorsNavAnimated.vue.js";
93
+ import { default as kr } from "./components/systems/scroll-anchors/UluScrollAnchorsSection.vue.js";
94
+ import { default as Lr } from "./components/systems/scroll-anchors/UluScrollAnchorsHeadlessSection.vue.js";
95
+ import { default as Ir } from "./components/systems/skeleton/UluShowSkeleton.vue.js";
96
+ import { default as yr } from "./components/systems/skeleton/UluSkeletonContent.vue.js";
97
+ import { default as Mr } from "./components/systems/skeleton/UluSkeletonMedia.vue.js";
98
+ import { default as Br } from "./components/systems/skeleton/UluSkeletonText.vue.js";
99
+ import { default as Nr } from "./components/systems/table-sticky/UluTableSticky.vue.js";
100
+ import { default as Gr } from "./components/systems/table-sticky/UluTableStickyRows.vue.js";
101
+ import { default as qr } from "./components/systems/table-sticky/UluTableStickyTable.vue.js";
102
+ import { useTooltip as Or } from "./plugins/popovers/useTooltip.js";
103
+ import { default as jr } from "./components/elements/UluMain.vue.js";
104
+ import { default as Jr } from "./components/navigation/UluSkipLink.vue.js";
105
+ import { default as Qr } from "./components/utils/UluEmpty.vue.js";
106
+ import { default as Yr } from "./components/utils/UluEmptyView.vue.js";
107
+ import { useFacets as _r } from "./components/systems/facets/useFacets.js";
108
+ import { useScrollAnchors as et } from "./components/systems/scroll-anchors/useScrollAnchors.js";
109
+ import { useScrollAnchorSection as rt } from "./components/systems/scroll-anchors/useScrollAnchorSection.js";
110
+ import { useScrollAnchorSections as at } from "./components/systems/scroll-anchors/useScrollAnchorSections.js";
111
+ import { useIcon as ut } from "./composables/useIcon.js";
112
+ import { useModifiers as st } from "./composables/useModifiers.js";
113
+ import { useWindowResize as pt } from "./composables/useWindowResize.js";
114
+ import { useRequiredInject as xt } from "./composables/useRequiredInject.js";
115
+ import { useBreakpointManager as it } from "./composables/useBreakpointManager.js";
116
+ import { usePagination as ct } from "./composables/usePagination.js";
117
+ import { useDocumentTitle as Ft } from "./composables/useDocumentTitle.js";
118
+ import { useUluFloating as bt } from "./composables/useUluFloating.js";
119
+ import { useTableData as At } from "./composables/useTableData.js";
119
120
  export {
120
121
  n as UluAccordion,
121
122
  S as UluAccordionGroup,
122
- vo as UluAction,
123
- mo as UluAdaptiveLayout,
123
+ yo as UluAction,
124
+ xo as UluAdaptiveLayout,
124
125
  E as UluAlert,
125
- Oo as UluAnimateNumber,
126
+ jo as UluAnimateNumber,
126
127
  W as UluBadge,
127
128
  H as UluBadgeStack,
128
- Fo as UluBreadcrumb,
129
+ bo as UluBreadcrumb,
129
130
  V as UluButton,
130
131
  z as UluButtonVerbose,
131
132
  K as UluCallout,
132
133
  X as UluCaptionedFigure,
133
134
  Z as UluCard,
134
135
  T as UluCollapsible,
135
- Io as UluConditionalText,
136
- Mo as UluConditionalWrapper,
137
- ne as UluCounterList,
138
- xo as UluDataGrid,
136
+ Mo as UluConditionalText,
137
+ Bo as UluConditionalWrapper,
138
+ Se as UluCounterList,
139
+ io as UluDataGrid,
139
140
  $ as UluDataTable,
140
141
  oe as UluDefinitionList,
141
142
  te as UluDefinitionListItem,
142
- A as UluDropdown,
143
- Jr as UluEmpty,
144
- Qr as UluEmptyView,
143
+ g as UluDropdown,
144
+ Qr as UluEmpty,
145
+ Yr as UluEmptyView,
145
146
  le as UluExternalLink,
146
- Qo as UluFacetsActiveFilters,
147
- _o as UluFacetsFilterAccordions,
148
- Yo as UluFacetsFilterLists,
149
- er as UluFacetsFilterPopovers,
150
- rr as UluFacetsFilterSelects,
151
- ar as UluFacetsHeaderLayout,
152
- ir as UluFacetsList,
153
- ur as UluFacetsResults,
154
- sr as UluFacetsSearch,
155
- pr as UluFacetsSidebarLayout,
156
- xr as UluFacetsSort,
157
- we as UluFileDisplay,
158
- ze as UluForm,
159
- Ke as UluFormActions,
160
- Xe as UluFormCheckbox,
161
- Ze as UluFormFieldset,
162
- De as UluFormFile,
163
- $e as UluFormItem,
164
- oo as UluFormItemsInline,
165
- Ee as UluFormMessage,
166
- to as UluFormRadio,
167
- lo as UluFormRequiredChar,
168
- We as UluFormSelect,
169
- He as UluFormText,
170
- fo as UluFormTextarea,
147
+ Yo as UluFacetsActiveFilters,
148
+ er as UluFacetsFilterAccordions,
149
+ _o as UluFacetsFilterLists,
150
+ rr as UluFacetsFilterPopovers,
151
+ ar as UluFacetsFilterSelects,
152
+ ur as UluFacetsHeaderLayout,
153
+ cr as UluFacetsList,
154
+ sr as UluFacetsResults,
155
+ pr as UluFacetsSearch,
156
+ xr as UluFacetsSidebarLayout,
157
+ ir as UluFacetsSort,
158
+ De as UluFileDisplay,
159
+ Ke as UluForm,
160
+ Xe as UluFormActions,
161
+ Ze as UluFormCheckbox,
162
+ $e as UluFormFieldset,
163
+ Ee as UluFormFile,
164
+ oo as UluFormItem,
165
+ to as UluFormItemsInline,
166
+ We as UluFormMessage,
167
+ lo as UluFormRadio,
168
+ fo as UluFormRequiredChar,
169
+ He as UluFormSelect,
170
+ Ve as UluFormText,
171
+ mo as UluFormTextarea,
171
172
  fe as UluIcon,
172
173
  me as UluImage,
173
- de as UluList,
174
- Ue as UluListItem,
175
- Or as UluMain,
176
- bo as UluMenu,
177
- go as UluMenuStack,
174
+ de as UluImageSource,
175
+ Ue as UluList,
176
+ ne as UluListItem,
177
+ jr as UluMain,
178
+ Ao as UluMenu,
179
+ ko as UluMenuStack,
178
180
  h as UluModal,
179
- ko as UluNavStrip,
181
+ Lo as UluNavStrip,
180
182
  P as UluOverflowPopover,
181
- Se as UluOverflowScroller,
182
- Lo as UluPager,
183
- Bo as UluPlaceholderImage,
184
- No as UluPlaceholderText,
185
- jo as UluProgressBar,
186
- Jo as UluProgressCircle,
187
- Go as UluRouteAnnouncer,
188
- Te as UluRule,
189
- qo as UluSanityRichText,
190
- cr as UluScrollAnchors,
191
- kr as UluScrollAnchorsHeadlessSection,
192
- Fr as UluScrollAnchorsNav,
193
- br as UluScrollAnchorsNavAnimated,
194
- gr as UluScrollAnchorsSection,
195
- Ae as UluScrollSlider,
196
- Ve as UluSearchForm,
197
- Re as UluSelectableMenu,
198
- Lr as UluShowSkeleton,
199
- vr as UluSkeletonContent,
200
- Ir as UluSkeletonMedia,
201
- Mr as UluSkeletonText,
202
- jr as UluSkipLink,
203
- he as UluSlider,
204
- Pe as UluSpokeSpinner,
183
+ Te as UluOverflowScroller,
184
+ Io as UluPager,
185
+ No as UluPlaceholderImage,
186
+ Go as UluPlaceholderText,
187
+ Jo as UluProgressBar,
188
+ Qo as UluProgressCircle,
189
+ qo as UluRouteAnnouncer,
190
+ ge as UluRule,
191
+ Oo as UluSanityRichText,
192
+ Fr as UluScrollAnchors,
193
+ Lr as UluScrollAnchorsHeadlessSection,
194
+ br as UluScrollAnchorsNav,
195
+ Ar as UluScrollAnchorsNavAnimated,
196
+ kr as UluScrollAnchorsSection,
197
+ he as UluScrollSlider,
198
+ ze as UluSearchForm,
199
+ we as UluSelectableMenu,
200
+ Ir as UluShowSkeleton,
201
+ yr as UluSkeletonContent,
202
+ Mr as UluSkeletonMedia,
203
+ Br as UluSkeletonText,
204
+ Jr as UluSkipLink,
205
+ Pe as UluSlider,
206
+ Ce as UluSpokeSpinner,
205
207
  C as UluTab,
206
- y as UluTabGroup,
208
+ v as UluTabGroup,
207
209
  R as UluTabList,
208
210
  w as UluTabPanel,
209
211
  D as UluTabPanels,
210
- Ce as UluTable,
211
- Br as UluTableSticky,
212
- Nr as UluTableStickyRows,
213
- Gr as UluTableStickyTable,
214
- ye as UluTag,
215
- io as UluTitleRail,
216
- co as UluWhenBreakpoint,
212
+ ve as UluTable,
213
+ Nr as UluTableSticky,
214
+ Gr as UluTableStickyRows,
215
+ qr as UluTableStickyTable,
216
+ Re as UluTag,
217
+ co as UluTitleRail,
218
+ Fo as UluWhenBreakpoint,
217
219
  U as breakpointsPlugin,
218
220
  t as corePlugin,
219
221
  m as modalsPlugin,
220
222
  l as popoversPlugin,
221
223
  d as toastPlugin,
222
- xt as useBreakpointManager,
223
- ct as useDocumentTitle,
224
- Yr as useFacets,
225
- at as useIcon,
226
- ut as useModifiers,
227
- it as usePagination,
228
- pt as useRequiredInject,
229
- et as useScrollAnchorSection,
230
- rt as useScrollAnchorSections,
231
- _r as useScrollAnchors,
232
- bt as useTableData,
233
- qr as useTooltip,
224
+ it as useBreakpointManager,
225
+ Ft as useDocumentTitle,
226
+ _r as useFacets,
227
+ ut as useIcon,
228
+ st as useModifiers,
229
+ ct as usePagination,
230
+ xt as useRequiredInject,
231
+ rt as useScrollAnchorSection,
232
+ at as useScrollAnchorSections,
233
+ et as useScrollAnchors,
234
+ At as useTableData,
235
+ Or as useTooltip,
234
236
  f as useTooltipFollow,
235
- Ft as useUluFloating,
236
- st as useWindowResize,
237
+ bt as useUluFloating,
238
+ pt as useWindowResize,
237
239
  e as utils
238
240
  };
@@ -4,4 +4,12 @@
4
4
  * @returns {Boolean} Whether all are objects within
5
5
  */
6
6
  export function isArrayOfObjects(array: any[]): boolean;
7
+ /**
8
+ * Logs a deprecation warning for a component prop in non-production environments.
9
+ * @param {String} componentName The name of the component using the deprecated prop.
10
+ * @param {Object} props The component's props object.
11
+ * @param {String} oldProp The name of the deprecated prop.
12
+ * @param {String} newProp The name of the new prop to use instead.
13
+ */
14
+ export function warnDeprecatedProp(componentName: string, props: Object, oldProp: string, newProp: string): void;
7
15
  //# sourceMappingURL=props.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"props.d.ts","sourceRoot":"","sources":["../../lib/utils/props.js"],"names":[],"mappings":"AAAA;;;;GAIG;AACH,wDAEC"}
1
+ {"version":3,"file":"props.d.ts","sourceRoot":"","sources":["../../lib/utils/props.js"],"names":[],"mappings":"AAAA;;;;GAIG;AACH,wDAEC;AAED;;;;;;GAMG;AACH,iEAJW,MAAM,0CAQhB"}
@@ -1,6 +1,10 @@
1
1
  function t(e) {
2
- return e.every((r) => typeof r == "object");
2
+ return e.every((n) => typeof n == "object");
3
+ }
4
+ function i(e, n, r, o) {
5
+ n[r] !== void 0 && typeof process < "u" && process.env.NODE_ENV !== "production" && console.warn(`[${e}]: Prop '${r}' is deprecated and will be removed in future, Use '${o}' instead`);
3
6
  }
4
7
  export {
5
- t as isArrayOfObjects
8
+ t as isArrayOfObjects,
9
+ i as warnDeprecatedProp
6
10
  };
package/dist/vite.d.ts ADDED
@@ -0,0 +1,5 @@
1
+ export namespace uluTransformAssetUrls {
2
+ let UluImage: string[];
3
+ let UluImageSource: string[];
4
+ }
5
+ //# sourceMappingURL=vite.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"vite.d.ts","sourceRoot":"","sources":["../lib/vite.js"],"names":[],"mappings":""}
package/dist/vite.js ADDED
@@ -0,0 +1,7 @@
1
+ const s = {
2
+ UluImage: ["src"],
3
+ UluImageSource: ["srcset"]
4
+ };
5
+ export {
6
+ s as uluTransformAssetUrls
7
+ };
@@ -61,7 +61,7 @@
61
61
  </div>
62
62
  </div>
63
63
  <div
64
- v-if="$slots.image || imageSrc"
64
+ v-if="$slots.image || resolvedImage"
65
65
  class="card__image"
66
66
  :class="[
67
67
  { 'card__image--icon' : imageIcon },
@@ -69,7 +69,7 @@
69
69
  ]"
70
70
  >
71
71
  <slot name="image">
72
- <img :src="imageSrc" :alt="imageAlt">
72
+ <UluImage v-bind="resolvedImage" />
73
73
  </slot>
74
74
  </div>
75
75
  <div class="card__footer" v-if="$slots.footer">
@@ -83,6 +83,8 @@
83
83
  import { RouterLink } from "vue-router";
84
84
  import { useModifiers } from "../../composables/useModifiers.js";
85
85
  import { refToElement } from '../../utils/dom.js';
86
+ import { warnDeprecatedProp } from '../../utils/props.js';
87
+ import UluImage from './UluImage.vue';
86
88
 
87
89
  const props = defineProps({
88
90
  /**
@@ -156,11 +158,17 @@
156
158
  default: () => ({})
157
159
  },
158
160
  /**
159
- * Source of image
161
+ * Unified image prop configuration passed to UluImage. Can be a string (src) or an object matching UluImage props.
162
+ */
163
+ image: [String, Object],
164
+ /**
165
+ * This is deprecated and will be removed in future version use "image" prop or image slot
166
+ * @deprecated Use `image` instead.
160
167
  */
161
168
  imageSrc: String,
162
169
  /**
163
- * Alt text for image
170
+ * This is deprecated and will be removed in future version use "image" prop or image slot
171
+ * @deprecated Use `image` (as an object with `alt`) instead.
164
172
  */
165
173
  imageAlt: String,
166
174
  /**
@@ -197,6 +205,26 @@
197
205
  console.warn("UluCard: 'titleTo'/'titleHref' should not be used with 'to'/'href'.");
198
206
  }
199
207
 
208
+ // Deprecation Warnings
209
+ // - Note these should be removed in the next minor or maybe major release
210
+ warnDeprecatedProp('UluCard', props, 'imageSrc', 'image');
211
+ warnDeprecatedProp('UluCard', props, 'imageAlt', 'image');
212
+
213
+ const resolvedImage = computed(() => {
214
+ if (props.image) {
215
+ if (typeof props.image === 'string') {
216
+ return { src: props.image };
217
+ }
218
+ return props.image;
219
+ } else if (props.imageSrc) {
220
+ return {
221
+ src: props.imageSrc,
222
+ alt: props.imageAlt || ''
223
+ };
224
+ }
225
+ return null;
226
+ });
227
+
200
228
  // --- Template refs
201
229
  const cardRoot = ref(null);
202
230
  const link = ref(null);
@@ -1,6 +1,7 @@
1
1
  <template>
2
- <picture v-if="sources?.length" :class="classes?.picture">
3
- <source
2
+ <picture v-if="sources?.length || $slots.default" :class="classes?.picture">
3
+ <slot />
4
+ <UluImageSource
4
5
  v-for="(source, index) in sources"
5
6
  :key="index"
6
7
  v-bind="source"
@@ -23,6 +24,8 @@
23
24
  </template>
24
25
 
25
26
  <script setup>
27
+ import UluImageSource from './UluImageSource.vue';
28
+
26
29
  defineOptions({
27
30
  inheritAttrs: false
28
31
  });
@@ -0,0 +1,30 @@
1
+ <template>
2
+ <source
3
+ :srcset="srcset"
4
+ :media="media"
5
+ v-bind="$attrs"
6
+ />
7
+ </template>
8
+
9
+ <script setup>
10
+ defineOptions({
11
+ inheritAttrs: false
12
+ });
13
+
14
+ defineProps({
15
+ /**
16
+ * Source set (e.g. image paths)
17
+ */
18
+ srcset: {
19
+ type: String,
20
+ required: true
21
+ },
22
+ /**
23
+ * Media query (e.g. (min-width: 600px))
24
+ */
25
+ media: {
26
+ type: String,
27
+ default: undefined
28
+ }
29
+ });
30
+ </script>
@@ -28,6 +28,7 @@ export { default as UluDefinitionListItem } from './elements/UluDefinitionListIt
28
28
  export { default as UluExternalLink } from './elements/UluExternalLink.vue';
29
29
  export { default as UluIcon } from './elements/UluIcon.vue';
30
30
  export { default as UluImage } from './elements/UluImage.vue';
31
+ export { default as UluImageSource } from './elements/UluImageSource.vue';
31
32
 
32
33
  // TODO (Still needs stylesheet for main library [and any scripting over there so it's contained in ulu])
33
34
  // export { default as UluImageSlider } from './elements/UluImageSlider.vue';
@@ -1,10 +1,11 @@
1
1
  <template>
2
- <img :src="src" :alt="alt">
2
+ <UluImage :src="src" :alt="alt" />
3
3
  </template>
4
4
 
5
5
  <script setup>
6
6
  import { computed } from 'vue';
7
7
  import { randomInt } from "@ulu/utils/random.js";
8
+ import UluImage from "../elements/UluImage.vue";
8
9
 
9
10
  const props = defineProps({
10
11
  imageId: String,
@@ -5,4 +5,17 @@
5
5
  */
6
6
  export function isArrayOfObjects(array) {
7
7
  return array.every(item => typeof item === "object");
8
+ }
9
+
10
+ /**
11
+ * Logs a deprecation warning for a component prop in non-production environments.
12
+ * @param {String} componentName The name of the component using the deprecated prop.
13
+ * @param {Object} props The component's props object.
14
+ * @param {String} oldProp The name of the deprecated prop.
15
+ * @param {String} newProp The name of the new prop to use instead.
16
+ */
17
+ export function warnDeprecatedProp(componentName, props, oldProp, newProp) {
18
+ if (props[oldProp] !== undefined && typeof process !== "undefined" && process.env.NODE_ENV !== "production") {
19
+ console.warn(`[${ componentName }]: Prop '${ oldProp }' is deprecated and will be removed in future, Use '${ newProp }' instead`);
20
+ }
8
21
  }
package/lib/vite.js ADDED
@@ -0,0 +1,25 @@
1
+ /**
2
+ * Vite/Vue plugin utility to automatically transform asset URLs for UluImage components.
3
+ *
4
+ * Usage in vite.config.js:
5
+ * import { uluTransformAssetUrls } from '@ulu/frontend-vue/vite.js';
6
+ * import vue from '@vitejs/plugin-vue';
7
+ *
8
+ * export default defineConfig({
9
+ * plugins: [
10
+ * vue({
11
+ * template: {
12
+ * transformAssetUrls: {
13
+ * // You can spread default tags if needed, or Vue handles merging objects depending on setup.
14
+ * ...uluTransformAssetUrls
15
+ * }
16
+ * }
17
+ * })
18
+ * ]
19
+ * });
20
+ */
21
+
22
+ export const uluTransformAssetUrls = {
23
+ UluImage: ['src'],
24
+ UluImageSource: ['srcset']
25
+ };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ulu/frontend-vue",
3
- "version": "0.5.5",
3
+ "version": "0.5.7",
4
4
  "description": "A modular, tree-shakeable Vue 3 component library for the Ulu Frontend theming system, plus general utilities for Vue development",
5
5
  "type": "module",
6
6
  "files": [