@wikicasa-dev/components 2.1.15 → 2.1.16

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.
@@ -1 +1 @@
1
- .no-transition[data-v-581c6b6a]{transition-duration:0ms!important}.disable-select[data-v-581c6b6a]{-webkit-user-select:none;-moz-user-select:none;user-select:none}.swiper-button-disabled[data-v-581c6b6a]{pointer-events:auto!important}
1
+ .no-transition[data-v-cbcbf618]{transition-duration:0ms!important}.disable-select[data-v-cbcbf618]{-webkit-user-select:none;-moz-user-select:none;user-select:none}.swiper-button-disabled[data-v-cbcbf618]{pointer-events:auto!important}
@@ -28,7 +28,7 @@ declare function __VLS_template(): {
28
28
  };
29
29
  type __VLS_TemplateResult = ReturnType<typeof __VLS_template>;
30
30
  declare const __VLS_component: import('vue').DefineComponent<SwiperCarouselProps, {
31
- swiper: {
31
+ swiper: import('vue').ComputedRef<{
32
32
  params: {
33
33
  modules?: import('swiper/types').SwiperModule[] | undefined;
34
34
  injectStyles?: string[] | undefined;
@@ -2312,7 +2312,7 @@ declare const __VLS_component: import('vue').DefineComponent<SwiperCarouselProps
2312
2312
  addSlide: (index: number, slides: HTMLElement | string | string[] | HTMLElement[]) => void;
2313
2313
  removeSlide: (slideIndex: number | number[]) => void;
2314
2314
  removeAllSlides: () => void;
2315
- } | null;
2315
+ } | null>;
2316
2316
  moveTo(index: number, speed?: number, runCallbacks?: boolean): void;
2317
2317
  }, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {
2318
2318
  click: () => any;
@@ -2,7 +2,7 @@ import o from "../../packages/components/lib/components/carousel/SwiperCarousel.
2
2
  import '../../assets/packages/components/lib/components/carousel/SwiperCarousel2.css';import '../../assets/packages/components/lib/components/carousel/SwiperCarousel.css';/* empty css */
3
3
  /* empty css */
4
4
  import r from "../../_virtual/_plugin-vue_export-helper.js";
5
- const e = /* @__PURE__ */ r(o, [["__scopeId", "data-v-581c6b6a"]]);
5
+ const c = /* @__PURE__ */ r(o, [["__scopeId", "data-v-cbcbf618"]]);
6
6
  export {
7
- e as default
7
+ c as default
8
8
  };
@@ -1,12 +1,12 @@
1
- import { defineComponent as J, reactive as Q, ref as k, useId as U, computed as f, onMounted as X, watch as Y, nextTick as M, createElementBlock as l, openBlock as p, normalizeClass as u, createElementVNode as v, createCommentVNode as y, renderSlot as E, Fragment as P, renderList as F, mergeProps as T, withModifiers as O } from "vue";
1
+ import { defineComponent as Q, reactive as U, ref as k, useId as X, computed as f, onMounted as Y, watch as x, nextTick as M, createElementBlock as l, openBlock as p, normalizeClass as u, createElementVNode as v, createCommentVNode as y, renderSlot as E, Fragment as P, renderList as F, mergeProps as T, withModifiers as O } from "vue";
2
2
  import { Swiper as B } from "swiper";
3
- import x from "../../../../../node_modules/.pnpm/swiper@11.2.6/node_modules/swiper/modules/zoom.js";
3
+ import _ from "../../../../../node_modules/.pnpm/swiper@11.2.6/node_modules/swiper/modules/zoom.js";
4
4
  import '../../../../../assets/node_modules/.pnpm/swiper@11.2.6/node_modules/swiper/modules/zoom.css';import '../../../../../assets/node_modules/.pnpm/swiper@11.2.6/node_modules/swiper/swiper.css';/* empty css */
5
5
  /* empty css */
6
6
  import "../../../../../node_modules/.pnpm/js-cookie@3.0.5/node_modules/js-cookie/dist/js.cookie.js";
7
- import { shallowCopyObjectTo as _ } from "../../../../../node_modules/.pnpm/@wikicasa-dev_utilities@1.1.21/node_modules/@wikicasa-dev/utilities/dist/utils/ObjectUtils.js";
7
+ import { shallowCopyObjectTo as ee } from "../../../../../node_modules/.pnpm/@wikicasa-dev_utilities@1.1.21/node_modules/@wikicasa-dev/utilities/dist/utils/ObjectUtils.js";
8
8
  import "../../../../../_virtual/polyline.js";
9
- const ee = ["id"], te = ["id", "data-cy"], se = ["data-idx", "alt", "width", "height", "onLoad"], ie = ["id"], ae = ["alt"], we = /* @__PURE__ */ J({
9
+ const te = ["id"], se = ["id", "data-cy"], ie = ["data-idx", "alt", "width", "height", "onLoad"], ae = ["id"], re = ["alt"], me = /* @__PURE__ */ Q({
10
10
  inheritAttrs: !1,
11
11
  __name: "SwiperCarousel",
12
12
  props: {
@@ -21,14 +21,14 @@ const ee = ["id"], te = ["id", "data-cy"], se = ["data-idx", "alt", "width", "he
21
21
  },
22
22
  emits: ["moved", "click", "firstSlideLoaded"],
23
23
  setup(s, { expose: D, emit: j }) {
24
- const $ = j, r = Q({
25
- swiperParams: { modules: [x] },
24
+ const $ = j, r = U({
25
+ swiperParams: { modules: [_] },
26
26
  swiper: null,
27
27
  initCarousel: !1
28
- }), S = k(), A = k(!1), N = U(), d = f(() => s.id ?? N), g = f(() => s.swiperOptions?.slidesPerView || 1), V = f(() => !!s.swiperOptions?.keyboard), C = f(() => !!s.swiperOptions.navigation), I = f(() => !!s.swiperOptions.pagination), W = f(() => !!s.swiperOptions.autoplay), q = f(
28
+ }), S = k(), A = k(!1), N = X(), d = f(() => s.id ?? N), V = f(() => r.swiper), g = f(() => s.swiperOptions?.slidesPerView || 1), W = f(() => !!s.swiperOptions?.keyboard), C = f(() => !!s.swiperOptions.navigation), I = f(() => !!s.swiperOptions.pagination), q = f(() => !!s.swiperOptions.autoplay), K = f(
29
29
  () => s.swiperOptions?.effect || "slider"
30
- ), K = () => {
31
- s.swiperOptions && _(s.swiperOptions, r.swiperParams);
30
+ ), R = () => {
31
+ s.swiperOptions && ee(s.swiperOptions, r.swiperParams);
32
32
  }, z = (e, i = -1, t = !1) => {
33
33
  if (!e.images)
34
34
  return { src: e.src || "" };
@@ -46,8 +46,8 @@ const ee = ["id"], te = ["id", "data-cy"], se = ["data-idx", "alt", "width", "he
46
46
  let n = e.images;
47
47
  e.images.length > 3 ? n = e.images.slice(2, 5) : s.shiftFirstImage && (n[0] = n[1]), o = n.reduce((c, w, m) => (m === 0 && (a = `${w.storagePath}`), m > 0 && (c += ", "), `${c}${w.storagePath} ${m + 1}x`), "");
48
48
  }
49
- const G = a, H = o;
50
- return typeof g.value == "number" && i > g.value ? (a = "", o = "", { sizes: b, "data-src": G, "data-srcset": H }) : t ? {
49
+ const H = a, J = o;
50
+ return typeof g.value == "number" && i > g.value ? (a = "", o = "", { sizes: b, "data-src": H, "data-srcset": J }) : t ? {
51
51
  src: a,
52
52
  srcset: o,
53
53
  sizes: b,
@@ -60,7 +60,7 @@ const ee = ["id"], te = ["id", "data-cy"], se = ["data-idx", "alt", "width", "he
60
60
  loading: s.lazyLoadImages || i >= g.value ? "lazy" : void 0,
61
61
  fetchpriority: !s.lazyLoadImages && i === 0 ? "high" : "low"
62
62
  };
63
- }, h = [], R = (e) => {
63
+ }, h = [], Z = (e) => {
64
64
  if (typeof g.value == "string") return;
65
65
  const i = h[e];
66
66
  if (i && !i.src && (i.src = i.dataset.src || "", i.srcset = i.dataset.srcset || ""), e < g.value || e + 1 >= (s.images ?? []).length)
@@ -69,18 +69,18 @@ const ee = ["id"], te = ["id", "data-cy"], se = ["data-idx", "alt", "width", "he
69
69
  t && !t.src && (t.src = t?.dataset.src || "", t.srcset = t?.dataset.srcset || "");
70
70
  };
71
71
  D({
72
- swiper: r.swiper,
72
+ swiper: V,
73
73
  moveTo(e, i = 0, t = !0) {
74
74
  r.swiper?.slideTo(e, i, t);
75
75
  }
76
76
  });
77
- const L = k(null), Z = (e) => {
77
+ const L = k(null), G = (e) => {
78
78
  e === 0 && h && h[e] && M(() => {
79
79
  L.value?.setAttribute("data-first-slide-loaded", "true"), $("firstSlideLoaded");
80
80
  });
81
81
  };
82
- return X(async () => {
83
- if (K(), V.value) {
82
+ return Y(async () => {
83
+ if (R(), W.value) {
84
84
  const { Keyboard: t } = await import("../../../lazyModules/Swiper/keyboard.js");
85
85
  r.swiperParams.modules?.push(t), r.swiperParams.keyboard = s.swiperOptions.keyboard;
86
86
  }
@@ -112,7 +112,7 @@ const ee = ["id"], te = ["id", "data-cy"], se = ["data-idx", "alt", "width", "he
112
112
  ...a
113
113
  };
114
114
  }
115
- if (W.value) {
115
+ if (q.value) {
116
116
  const { Autoplay: t } = await import("../../../lazyModules/Swiper/autoplay.js");
117
117
  r.swiperParams.modules?.push(t), r.swiperParams.autoplay = s.swiperOptions.autoplay;
118
118
  }
@@ -123,7 +123,7 @@ const ee = ["id"], te = ["id", "data-cy"], se = ["data-idx", "alt", "width", "he
123
123
  A.value = !0;
124
124
  },
125
125
  slideChange: (t) => {
126
- R(t.activeIndex), $("moved", { activeIndex: t.activeIndex });
126
+ Z(t.activeIndex), $("moved", { activeIndex: t.activeIndex });
127
127
  }
128
128
  }
129
129
  };
@@ -142,7 +142,7 @@ const ee = ["id"], te = ["id", "data-cy"], se = ["data-idx", "alt", "width", "he
142
142
  };
143
143
  }
144
144
  e.lazyPreloadPrevNext = 1, r.swiper = new B(`#${d.value}`, e), S.value?.classList.remove("uikit-hidden");
145
- }), Y(
145
+ }), x(
146
146
  () => s.images,
147
147
  () => {
148
148
  M(() => {
@@ -165,7 +165,7 @@ const ee = ["id"], te = ["id", "data-cy"], se = ["data-idx", "alt", "width", "he
165
165
  ref: S,
166
166
  class: u(["swiper-wrapper", [
167
167
  e.$attrs["swiper-wrapper-classes"],
168
- q.value === "none" && "no-transition"
168
+ K.value === "none" && "no-transition"
169
169
  ]]),
170
170
  onClick: i[0] || (i[0] = (t) => $("click"))
171
171
  }, [
@@ -190,8 +190,8 @@ const ee = ["id"], te = ["id", "data-cy"], se = ["data-idx", "alt", "width", "he
190
190
  itemprop: "image",
191
191
  width: t.width,
192
192
  height: t.height,
193
- onLoad: (o) => Z(a)
194
- }), null, 16, se))
193
+ onLoad: (o) => G(a)
194
+ }), null, 16, ie))
195
195
  ], 2)
196
196
  ], 2))), 128)),
197
197
  E(e.$slots, "last_slide", {}, void 0, !0)
@@ -217,7 +217,7 @@ const ee = ["id"], te = ["id", "data-cy"], se = ["data-idx", "alt", "width", "he
217
217
  }, ["stop"]))
218
218
  })
219
219
  ], 64)) : y("", !0)
220
- ], 10, te),
220
+ ], 10, se),
221
221
  e.thumbSwiperOptions ? (p(), l("div", {
222
222
  key: 0,
223
223
  id: `thumb_${d.value}`,
@@ -236,13 +236,13 @@ const ee = ["id"], te = ["id", "data-cy"], se = ["data-idx", "alt", "width", "he
236
236
  ref_for: !0
237
237
  }, z(t, -1, !1), {
238
238
  alt: t.alt
239
- }), null, 16, ae)
239
+ }), null, 16, re)
240
240
  ], 2))), 128))
241
241
  ], 2)
242
- ], 10, ie)) : y("", !0)
243
- ], 10, ee));
242
+ ], 10, ae)) : y("", !0)
243
+ ], 10, te));
244
244
  }
245
245
  });
246
246
  export {
247
- we as default
247
+ me as default
248
248
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@wikicasa-dev/components",
3
- "version": "2.1.15",
3
+ "version": "2.1.16",
4
4
  "description": "Wikicasa frontend components",
5
5
  "type": "module",
6
6
  "main": "./dist/index.js",