vistaview 0.10.18 → 0.10.20

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/README.md CHANGED
@@ -373,15 +373,21 @@ function Gallery() {
373
373
 
374
374
  ```svelte
375
375
  <script>
376
- import { VistaView } from 'vistaview/svelte';
376
+ import { useVistaView } from 'vistaview/svelte';
377
377
  import 'vistaview/style.css';
378
+
379
+ const id = 'gallery-' + Math.random().toString(36).slice(2);
380
+ const vista = useVistaView({
381
+ elements: `#${id} a`,
382
+ });
378
383
  </script>
379
384
 
380
- <VistaView selector="> a">
381
- <a href="/full.jpg">
382
- <img src="/thumb.jpg" alt="Photo" />
385
+ <div id={id}>
386
+ <a href="/images/full.jpg">
387
+ <img src="/images/thumb.jpg" alt="Photo" />
383
388
  </a>
384
- </VistaView>
389
+ <button on:click={() => vista.open(0)}>Open Gallery</button>
390
+ </div>
385
391
  ```
386
392
 
387
393
  ## Accessibility
package/dist/react.js CHANGED
@@ -1,12 +1,10 @@
1
1
  "use client";
2
- import { t as v, u as I, s as g, i as w } from "./web-D29dUeNW.js";
3
- import { useRef as l, useEffect as a, useCallback as t, useId as y, useImperativeHandle as x } from "react";
4
- import { vistaView as m } from "./vistaview.js";
5
- import { mergeProps as V } from "solid-js";
6
- var $ = /* @__PURE__ */ v("<div>");
7
- function P(o) {
8
- const r = l(null);
9
- return a(() => (r.current = m(o), () => {
2
+ import { jsx as v } from "react/jsx-runtime";
3
+ import { useRef as s, useEffect as a, useCallback as t, useId as I, useImperativeHandle as g } from "react";
4
+ import { vistaView as d } from "./vistaview.js";
5
+ function V(c) {
6
+ const r = s(null);
7
+ return a(() => (r.current = d(c), () => {
10
8
  var e;
11
9
  (e = r.current) == null || e.destroy(), r.current = null;
12
10
  }), []), {
@@ -52,32 +50,20 @@ function P(o) {
52
50
  }, [])
53
51
  };
54
52
  }
55
- function _({
56
- children: o,
57
- selector: r = "> a",
58
- options: e,
59
- id: n,
60
- ref: p,
61
- ...d
62
- }) {
63
- const i = l(null), s = l(null), f = y(), c = n || `vvw-gallery-${f.replace(/:/g, "")}`;
64
- return x(p, () => s.current, []), a(() => {
53
+ function z({ children: c, selector: r = "> a", options: e, id: n, ref: m, ...f }) {
54
+ const i = s(null), u = s(null), p = I(), o = n || `vvw-gallery-${p.replace(/:/g, "")}`;
55
+ return g(m, () => u.current, []), a(() => {
65
56
  if (i.current)
66
- return s.current = m({
57
+ return u.current = d({
67
58
  ...e,
68
- elements: `#${c} ${r}`
59
+ elements: `#${o} ${r}`
69
60
  }), () => {
70
- var u;
71
- (u = s.current) == null || u.destroy(), s.current = null;
61
+ var l;
62
+ (l = u.current) == null || l.destroy(), u.current = null;
72
63
  };
73
- }, [c, r]), (() => {
74
- var u = $();
75
- return I(i, u), g(u, V(d, {
76
- id: c
77
- }), !1), w(u, o), u;
78
- })();
64
+ }, [o, r]), /* @__PURE__ */ v("div", { ref: i, ...f, id: o, children: c });
79
65
  }
80
66
  export {
81
- _ as VistaView,
82
- P as useVistaView
67
+ z as VistaView,
68
+ V as useVistaView
83
69
  };
package/dist/solid.js CHANGED
@@ -1,53 +1,493 @@
1
- import { t as y, u as I, s as x, i as V } from "./web-D29dUeNW.js";
2
- import { onCleanup as m, createSignal as $, onMount as z, mergeProps as C } from "solid-js";
3
- import { vistaView as p } from "./vistaview.js";
4
- var a = /* @__PURE__ */ y("<div>");
5
- function P(t) {
6
- const r = p(t);
7
- return m(() => {
8
- r == null || r.destroy();
1
+ import { untrack as L, createRenderEffect as g, sharedConfig as h, onCleanup as N, createSignal as M, onMount as x, mergeProps as k } from "solid-js";
2
+ import { vistaView as O } from "./vistaview.js";
3
+ const R = [
4
+ "allowfullscreen",
5
+ "async",
6
+ "alpha",
7
+ "autofocus",
8
+ "autoplay",
9
+ "checked",
10
+ "controls",
11
+ "default",
12
+ "disabled",
13
+ "formnovalidate",
14
+ "hidden",
15
+ "indeterminate",
16
+ "inert",
17
+ "ismap",
18
+ "loop",
19
+ "multiple",
20
+ "muted",
21
+ "nomodule",
22
+ "novalidate",
23
+ "open",
24
+ "playsinline",
25
+ "readonly",
26
+ "required",
27
+ "reversed",
28
+ "seamless",
29
+ "selected",
30
+ "adauctionheaders",
31
+ "browsingtopics",
32
+ "credentialless",
33
+ "defaultchecked",
34
+ "defaultmuted",
35
+ "defaultselected",
36
+ "defer",
37
+ "disablepictureinpicture",
38
+ "disableremoteplayback",
39
+ "preservespitch",
40
+ "shadowrootclonable",
41
+ "shadowrootcustomelementregistry",
42
+ "shadowrootdelegatesfocus",
43
+ "shadowrootserializable",
44
+ "sharedstoragewritable"
45
+ ], V = /* @__PURE__ */ new Set([
46
+ "className",
47
+ "value",
48
+ "readOnly",
49
+ "noValidate",
50
+ "formNoValidate",
51
+ "isMap",
52
+ "noModule",
53
+ "playsInline",
54
+ "adAuctionHeaders",
55
+ "allowFullscreen",
56
+ "browsingTopics",
57
+ "defaultChecked",
58
+ "defaultMuted",
59
+ "defaultSelected",
60
+ "disablePictureInPicture",
61
+ "disableRemotePlayback",
62
+ "preservesPitch",
63
+ "shadowRootClonable",
64
+ "shadowRootCustomElementRegistry",
65
+ "shadowRootDelegatesFocus",
66
+ "shadowRootSerializable",
67
+ "sharedStorageWritable",
68
+ ...R
69
+ ]), D = /* @__PURE__ */ new Set(["innerHTML", "textContent", "innerText", "children"]), j = /* @__PURE__ */ Object.assign(/* @__PURE__ */ Object.create(null), {
70
+ className: "class",
71
+ htmlFor: "for"
72
+ }), B = /* @__PURE__ */ Object.assign(/* @__PURE__ */ Object.create(null), {
73
+ class: "className",
74
+ novalidate: {
75
+ $: "noValidate",
76
+ FORM: 1
77
+ },
78
+ formnovalidate: {
79
+ $: "formNoValidate",
80
+ BUTTON: 1,
81
+ INPUT: 1
82
+ },
83
+ ismap: {
84
+ $: "isMap",
85
+ IMG: 1
86
+ },
87
+ nomodule: {
88
+ $: "noModule",
89
+ SCRIPT: 1
90
+ },
91
+ playsinline: {
92
+ $: "playsInline",
93
+ VIDEO: 1
94
+ },
95
+ readonly: {
96
+ $: "readOnly",
97
+ INPUT: 1,
98
+ TEXTAREA: 1
99
+ },
100
+ adauctionheaders: {
101
+ $: "adAuctionHeaders",
102
+ IFRAME: 1
103
+ },
104
+ allowfullscreen: {
105
+ $: "allowFullscreen",
106
+ IFRAME: 1
107
+ },
108
+ browsingtopics: {
109
+ $: "browsingTopics",
110
+ IMG: 1
111
+ },
112
+ defaultchecked: {
113
+ $: "defaultChecked",
114
+ INPUT: 1
115
+ },
116
+ defaultmuted: {
117
+ $: "defaultMuted",
118
+ AUDIO: 1,
119
+ VIDEO: 1
120
+ },
121
+ defaultselected: {
122
+ $: "defaultSelected",
123
+ OPTION: 1
124
+ },
125
+ disablepictureinpicture: {
126
+ $: "disablePictureInPicture",
127
+ VIDEO: 1
128
+ },
129
+ disableremoteplayback: {
130
+ $: "disableRemotePlayback",
131
+ AUDIO: 1,
132
+ VIDEO: 1
133
+ },
134
+ preservespitch: {
135
+ $: "preservesPitch",
136
+ AUDIO: 1,
137
+ VIDEO: 1
138
+ },
139
+ shadowrootclonable: {
140
+ $: "shadowRootClonable",
141
+ TEMPLATE: 1
142
+ },
143
+ shadowrootdelegatesfocus: {
144
+ $: "shadowRootDelegatesFocus",
145
+ TEMPLATE: 1
146
+ },
147
+ shadowrootserializable: {
148
+ $: "shadowRootSerializable",
149
+ TEMPLATE: 1
150
+ },
151
+ sharedstoragewritable: {
152
+ $: "sharedStorageWritable",
153
+ IFRAME: 1,
154
+ IMG: 1
155
+ }
156
+ });
157
+ function F(i, e) {
158
+ const t = B[i];
159
+ return typeof t == "object" ? t[e] ? t.$ : void 0 : t;
160
+ }
161
+ const _ = /* @__PURE__ */ new Set(["beforeinput", "click", "dblclick", "contextmenu", "focusin", "focusout", "input", "keydown", "keyup", "mousedown", "mousemove", "mouseout", "mouseover", "mouseup", "pointerdown", "pointermove", "pointerout", "pointerover", "pointerup", "touchend", "touchmove", "touchstart"]);
162
+ function U(i, e, t) {
163
+ let l = t.length, n = e.length, o = l, f = 0, s = 0, r = e[n - 1].nextSibling, c = null;
164
+ for (; f < n || s < o; ) {
165
+ if (e[f] === t[s]) {
166
+ f++, s++;
167
+ continue;
168
+ }
169
+ for (; e[n - 1] === t[o - 1]; )
170
+ n--, o--;
171
+ if (n === f) {
172
+ const a = o < l ? s ? t[s - 1].nextSibling : t[o - s] : r;
173
+ for (; s < o; ) i.insertBefore(t[s++], a);
174
+ } else if (o === s)
175
+ for (; f < n; )
176
+ (!c || !c.has(e[f])) && e[f].remove(), f++;
177
+ else if (e[f] === t[o - 1] && t[s] === e[n - 1]) {
178
+ const a = e[--n].nextSibling;
179
+ i.insertBefore(t[s++], e[f++].nextSibling), i.insertBefore(t[--o], a), e[n] = t[o];
180
+ } else {
181
+ if (!c) {
182
+ c = /* @__PURE__ */ new Map();
183
+ let d = s;
184
+ for (; d < o; ) c.set(t[d], d++);
185
+ }
186
+ const a = c.get(e[f]);
187
+ if (a != null)
188
+ if (s < a && a < o) {
189
+ let d = f, u = 1, y;
190
+ for (; ++d < n && d < o && !((y = c.get(e[d])) == null || y !== a + u); )
191
+ u++;
192
+ if (u > a - s) {
193
+ const $ = e[f];
194
+ for (; s < a; ) i.insertBefore(t[s++], $);
195
+ } else i.replaceChild(t[s++], e[f++]);
196
+ } else f++;
197
+ else e[f++].remove();
198
+ }
199
+ }
200
+ }
201
+ const T = "_$DX_DELEGATE";
202
+ function H(i, e, t, l) {
203
+ let n;
204
+ const o = () => {
205
+ const s = document.createElement("template");
206
+ return s.innerHTML = i, s.content.firstChild;
207
+ }, f = () => (n || (n = o())).cloneNode(!0);
208
+ return f.cloneNode = f, f;
209
+ }
210
+ function G(i, e = window.document) {
211
+ const t = e[T] || (e[T] = /* @__PURE__ */ new Set());
212
+ for (let l = 0, n = i.length; l < n; l++) {
213
+ const o = i[l];
214
+ t.has(o) || (t.add(o), e.addEventListener(o, Z));
215
+ }
216
+ }
217
+ function A(i, e, t) {
218
+ m(i) || (t == null ? i.removeAttribute(e) : i.setAttribute(e, t));
219
+ }
220
+ function z(i, e, t) {
221
+ m(i) || (t ? i.setAttribute(e, "") : i.removeAttribute(e));
222
+ }
223
+ function K(i, e) {
224
+ m(i) || (e == null ? i.removeAttribute("class") : i.className = e);
225
+ }
226
+ function p(i, e, t, l) {
227
+ if (l)
228
+ Array.isArray(t) ? (i[`$$${e}`] = t[0], i[`$$${e}Data`] = t[1]) : i[`$$${e}`] = t;
229
+ else if (Array.isArray(t)) {
230
+ const n = t[0];
231
+ i.addEventListener(e, t[0] = (o) => n.call(i, t[1], o));
232
+ } else i.addEventListener(e, t, typeof t != "function" && t);
233
+ }
234
+ function q(i, e, t = {}) {
235
+ const l = Object.keys(e || {}), n = Object.keys(t);
236
+ let o, f;
237
+ for (o = 0, f = n.length; o < f; o++) {
238
+ const s = n[o];
239
+ !s || s === "undefined" || e[s] || (C(i, s, !1), delete t[s]);
240
+ }
241
+ for (o = 0, f = l.length; o < f; o++) {
242
+ const s = l[o], r = !!e[s];
243
+ !s || s === "undefined" || t[s] === r || !r || (C(i, s, !0), t[s] = r);
244
+ }
245
+ return t;
246
+ }
247
+ function W(i, e, t) {
248
+ if (!e) return t ? A(i, "style") : e;
249
+ const l = i.style;
250
+ if (typeof e == "string") return l.cssText = e;
251
+ typeof t == "string" && (l.cssText = t = void 0), t || (t = {}), e || (e = {});
252
+ let n, o;
253
+ for (o in t)
254
+ e[o] == null && l.removeProperty(o), delete t[o];
255
+ for (o in e)
256
+ n = e[o], n !== t[o] && (l.setProperty(o, n), t[o] = n);
257
+ return t;
258
+ }
259
+ function X(i, e = {}, t, l) {
260
+ const n = {};
261
+ return g(() => typeof e.ref == "function" && S(e.ref, i)), g(() => J(i, e, t, !0, n, !0)), n;
262
+ }
263
+ function S(i, e, t) {
264
+ return L(() => i(e, t));
265
+ }
266
+ function Y(i, e, t, l) {
267
+ if (typeof e != "function") return w(i, e, l, t);
268
+ g((n) => w(i, e(), n, t), l);
269
+ }
270
+ function J(i, e, t, l, n = {}, o = !1) {
271
+ e || (e = {});
272
+ for (const f in n)
273
+ if (!(f in e)) {
274
+ if (f === "children") continue;
275
+ n[f] = I(i, f, null, n[f], t, o, e);
276
+ }
277
+ for (const f in e) {
278
+ if (f === "children")
279
+ continue;
280
+ const s = e[f];
281
+ n[f] = I(i, f, s, n[f], t, o, e);
282
+ }
283
+ }
284
+ function m(i) {
285
+ return !!h.context && !h.done && (!i || i.isConnected);
286
+ }
287
+ function Q(i) {
288
+ return i.toLowerCase().replace(/-([a-z])/g, (e, t) => t.toUpperCase());
289
+ }
290
+ function C(i, e, t) {
291
+ const l = e.trim().split(/\s+/);
292
+ for (let n = 0, o = l.length; n < o; n++) i.classList.toggle(l[n], t);
293
+ }
294
+ function I(i, e, t, l, n, o, f) {
295
+ let s, r, c, a, d;
296
+ if (e === "style") return W(i, t, l);
297
+ if (e === "classList") return q(i, t, l);
298
+ if (t === l) return l;
299
+ if (e === "ref")
300
+ o || t(i);
301
+ else if (e.slice(0, 3) === "on:") {
302
+ const u = e.slice(3);
303
+ l && i.removeEventListener(u, l, typeof l != "function" && l), t && i.addEventListener(u, t, typeof t != "function" && t);
304
+ } else if (e.slice(0, 10) === "oncapture:") {
305
+ const u = e.slice(10);
306
+ l && i.removeEventListener(u, l, !0), t && i.addEventListener(u, t, !0);
307
+ } else if (e.slice(0, 2) === "on") {
308
+ const u = e.slice(2).toLowerCase(), y = _.has(u);
309
+ if (!y && l) {
310
+ const $ = Array.isArray(l) ? l[0] : l;
311
+ i.removeEventListener(u, $);
312
+ }
313
+ (y || t) && (p(i, u, t, y), y && G([u]));
314
+ } else if (e.slice(0, 5) === "attr:")
315
+ A(i, e.slice(5), t);
316
+ else if (e.slice(0, 5) === "bool:")
317
+ z(i, e.slice(5), t);
318
+ else if ((d = e.slice(0, 5) === "prop:") || (c = D.has(e)) || (a = F(e, i.tagName)) || (r = V.has(e)) || (s = i.nodeName.includes("-") || "is" in f)) {
319
+ if (d)
320
+ e = e.slice(5), r = !0;
321
+ else if (m(i)) return t;
322
+ e === "class" || e === "className" ? K(i, t) : s && !r && !c ? i[Q(e)] = t : i[a || e] = t;
323
+ } else
324
+ A(i, j[e] || e, t);
325
+ return t;
326
+ }
327
+ function Z(i) {
328
+ if (h.registry && h.events && h.events.find(([r, c]) => c === i))
329
+ return;
330
+ let e = i.target;
331
+ const t = `$$${i.type}`, l = i.target, n = i.currentTarget, o = (r) => Object.defineProperty(i, "target", {
332
+ configurable: !0,
333
+ value: r
334
+ }), f = () => {
335
+ const r = e[t];
336
+ if (r && !e.disabled) {
337
+ const c = e[`${t}Data`];
338
+ if (c !== void 0 ? r.call(e, c, i) : r.call(e, i), i.cancelBubble) return;
339
+ }
340
+ return e.host && typeof e.host != "string" && !e.host._$host && e.contains(i.target) && o(e.host), !0;
341
+ }, s = () => {
342
+ for (; f() && (e = e._$host || e.parentNode || e.host); ) ;
343
+ };
344
+ if (Object.defineProperty(i, "currentTarget", {
345
+ configurable: !0,
346
+ get() {
347
+ return e || document;
348
+ }
349
+ }), h.registry && !h.done && (h.done = _$HY.done = !0), i.composedPath) {
350
+ const r = i.composedPath();
351
+ o(r[0]);
352
+ for (let c = 0; c < r.length - 2 && (e = r[c], !!f()); c++) {
353
+ if (e._$host) {
354
+ e = e._$host, s();
355
+ break;
356
+ }
357
+ if (e.parentNode === n)
358
+ break;
359
+ }
360
+ } else s();
361
+ o(l);
362
+ }
363
+ function w(i, e, t, l, n) {
364
+ const o = m(i);
365
+ if (o) {
366
+ !t && (t = [...i.childNodes]);
367
+ let s = [];
368
+ for (let r = 0; r < t.length; r++) {
369
+ const c = t[r];
370
+ c.nodeType === 8 && c.data.slice(0, 2) === "!$" ? c.remove() : s.push(c);
371
+ }
372
+ t = s;
373
+ }
374
+ for (; typeof t == "function"; ) t = t();
375
+ if (e === t) return t;
376
+ const f = typeof e;
377
+ if (i = i, f === "string" || f === "number") {
378
+ if (o || f === "number" && (e = e.toString(), e === t))
379
+ return t;
380
+ t !== "" && typeof t == "string" ? t = i.firstChild.data = e : t = i.textContent = e;
381
+ } else if (e == null || f === "boolean") {
382
+ if (o) return t;
383
+ t = b(i, t, l);
384
+ } else {
385
+ if (f === "function")
386
+ return g(() => {
387
+ let s = e();
388
+ for (; typeof s == "function"; ) s = s();
389
+ t = w(i, s, t, l);
390
+ }), () => t;
391
+ if (Array.isArray(e)) {
392
+ const s = [], r = t && Array.isArray(t);
393
+ if (E(s, e, t, n))
394
+ return g(() => t = w(i, s, t, l, !0)), () => t;
395
+ if (o)
396
+ return s.length ? t = [...i.childNodes] : t;
397
+ s.length === 0 ? t = b(i, t, l) : r ? t.length === 0 ? P(i, s, l) : U(i, t, s) : (t && b(i), P(i, s)), t = s;
398
+ } else if (e.nodeType) {
399
+ if (o && e.parentNode) return t = e;
400
+ Array.isArray(t) ? b(i, t, null, e) : t == null || t === "" || !i.firstChild ? i.appendChild(e) : i.replaceChild(e, i.firstChild), t = e;
401
+ }
402
+ }
403
+ return t;
404
+ }
405
+ function E(i, e, t, l) {
406
+ let n = !1;
407
+ for (let o = 0, f = e.length; o < f; o++) {
408
+ let s = e[o], r = t && t[i.length], c;
409
+ if (!(s == null || s === !0 || s === !1)) if ((c = typeof s) == "object" && s.nodeType)
410
+ i.push(s);
411
+ else if (Array.isArray(s))
412
+ n = E(i, s, r) || n;
413
+ else if (c === "function")
414
+ if (l) {
415
+ for (; typeof s == "function"; ) s = s();
416
+ n = E(i, Array.isArray(s) ? s : [s], Array.isArray(r) ? r : [r]) || n;
417
+ } else
418
+ i.push(s), n = !0;
419
+ else {
420
+ const a = String(s);
421
+ r && r.nodeType === 3 && r.data === a ? i.push(r) : i.push(document.createTextNode(a));
422
+ }
423
+ }
424
+ return n;
425
+ }
426
+ function P(i, e, t = null) {
427
+ for (let l = 0, n = e.length; l < n; l++) i.insertBefore(e[l], t);
428
+ }
429
+ function b(i, e, t, l) {
430
+ if (t === void 0) return i.textContent = "";
431
+ const n = l || document.createTextNode("");
432
+ if (e.length) {
433
+ let o = !1;
434
+ for (let f = e.length - 1; f >= 0; f--) {
435
+ const s = e[f];
436
+ if (n !== s) {
437
+ const r = s.parentNode === i;
438
+ !o && !f ? r ? i.replaceChild(n, s) : i.insertBefore(n, t) : r && s.remove();
439
+ } else o = !0;
440
+ }
441
+ } else i.insertBefore(n, t);
442
+ return [n];
443
+ }
444
+ var v = /* @__PURE__ */ H("<div>");
445
+ function ie(i) {
446
+ const e = O(i);
447
+ return N(() => {
448
+ e == null || e.destroy();
9
449
  }), {
10
- open: (e = 0) => r == null ? void 0 : r.open(e),
11
- close: () => (r == null ? void 0 : r.close()) ?? Promise.resolve(),
12
- reset: () => r == null ? void 0 : r.reset(),
13
- next: () => r == null ? void 0 : r.next(),
14
- prev: () => r == null ? void 0 : r.prev(),
15
- zoomIn: () => r == null ? void 0 : r.zoomIn(),
16
- zoomOut: () => r == null ? void 0 : r.zoomOut(),
17
- getCurrentIndex: () => (r == null ? void 0 : r.getCurrentIndex()) ?? -1,
18
- view: (e) => r == null ? void 0 : r.view(e),
19
- destroy: () => r == null ? void 0 : r.destroy()
450
+ open: (t = 0) => e == null ? void 0 : e.open(t),
451
+ close: () => (e == null ? void 0 : e.close()) ?? Promise.resolve(),
452
+ reset: () => e == null ? void 0 : e.reset(),
453
+ next: () => e == null ? void 0 : e.next(),
454
+ prev: () => e == null ? void 0 : e.prev(),
455
+ zoomIn: () => e == null ? void 0 : e.zoomIn(),
456
+ zoomOut: () => e == null ? void 0 : e.zoomOut(),
457
+ getCurrentIndex: () => (e == null ? void 0 : e.getCurrentIndex()) ?? -1,
458
+ view: (t) => e == null ? void 0 : e.view(t),
459
+ destroy: () => e == null ? void 0 : e.destroy()
20
460
  };
21
461
  }
22
- function S(t) {
23
- const [r, e] = $(null);
24
- let s;
462
+ function se(i) {
463
+ const [e, t] = M(null);
464
+ let l;
25
465
  const {
26
- selector: d = "> a",
27
- options: v,
28
- ref: l,
29
- id: f,
30
- children: g,
31
- ...i
32
- } = t, u = f || `vvw-gallery-${Math.random().toString(36).substr(2, 9)}`;
33
- return z(() => {
34
- if (!s) return;
35
- const o = p({
36
- ...v,
37
- elements: `#${u} ${d}`
466
+ selector: n = "> a",
467
+ options: o,
468
+ ref: f,
469
+ id: s,
470
+ children: r,
471
+ ...c
472
+ } = i, a = s || `vvw-gallery-${Math.random().toString(36).substr(2, 9)}`;
473
+ return x(() => {
474
+ if (!l) return;
475
+ const d = O({
476
+ ...o,
477
+ elements: `#${a} ${n}`
38
478
  });
39
- o && (e(o), l == null || l(o));
40
- }), m(() => {
41
- var o;
42
- (o = r()) == null || o.destroy();
479
+ d && (t(d), f == null || f(d));
480
+ }), N(() => {
481
+ var d;
482
+ (d = e()) == null || d.destroy();
43
483
  }), (() => {
44
- var o = a();
45
- return I((w) => s = w, o), x(o, C(i, {
46
- id: u
47
- }), !1), V(o, g), o;
484
+ var d = v();
485
+ return S((u) => l = u, d), X(d, k(c, {
486
+ id: a
487
+ }), !1), Y(d, r), d;
48
488
  })();
49
489
  }
50
490
  export {
51
- S as VistaView,
52
- P as useVistaView
491
+ se as VistaView,
492
+ ie as useVistaView
53
493
  };
package/dist/svelte.d.ts CHANGED
@@ -1,8 +1,3 @@
1
- import { VistaParamsNeo, VistaInterface, VistaOpt } from './vistaview';
1
+ import { VistaParamsNeo, VistaInterface } from './vistaview';
2
2
  export declare function useVistaView(options: VistaParamsNeo): VistaInterface;
3
- export interface VistaViewProps extends VistaOpt {
4
- selector?: string;
5
- ref?: VistaInterface;
6
- }
7
- export { default as VistaView } from './VistaView.svelte';
8
3
  //# sourceMappingURL=svelte.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"svelte.d.ts","sourceRoot":"","sources":["../src/svelte.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,cAAc,EAAE,cAAc,EAAE,MAAM,aAAa,CAAC;AAClE,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,aAAa,CAAC;AAE5C,wBAAgB,YAAY,CAAC,OAAO,EAAE,cAAc,GAAG,cAAc,CA8BpE;AAED,MAAM,WAAW,cAAe,SAAQ,QAAQ;IAC9C,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,GAAG,CAAC,EAAE,cAAc,CAAC;CACtB;AAED,OAAO,EAAE,OAAO,IAAI,SAAS,EAAE,MAAM,oBAAoB,CAAC"}
1
+ {"version":3,"file":"svelte.d.ts","sourceRoot":"","sources":["../src/svelte.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,cAAc,EAAE,cAAc,EAAE,MAAM,aAAa,CAAC;AAElE,wBAAgB,YAAY,CAAC,OAAO,EAAE,cAAc,GAAG,cAAc,CA8BpE"}