vistaview 0.10.17 → 0.10.18

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/react.d.ts CHANGED
@@ -5,6 +5,7 @@ export interface VistaViewProps {
5
5
  children: ReactNode;
6
6
  selector?: string;
7
7
  options?: VistaOpt;
8
+ ref?: React.Ref<VistaInterface>;
8
9
  }
9
- export declare const VistaView: import('react').ForwardRefExoticComponent<VistaViewProps & import('react').HTMLAttributes<HTMLDivElement> & import('react').RefAttributes<VistaInterface>>;
10
+ export declare function VistaView({ children, selector, options, id, ref, ...rest }: VistaViewProps & React.HTMLAttributes<HTMLDivElement>): import("react/jsx-runtime").JSX.Element;
10
11
  //# sourceMappingURL=react.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"react.d.ts","sourceRoot":"","sources":["../src/react.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAEvC,OAAO,KAAK,EAAE,cAAc,EAAE,cAAc,EAAE,QAAQ,EAAE,MAAM,aAAa,CAAC;AAE5E,wBAAgB,YAAY,CAAC,OAAO,EAAE,cAAc,GAAG,cAAc,CAuBpE;AAED,MAAM,WAAW,cAAc;IAC7B,QAAQ,EAAE,SAAS,CAAC;IACpB,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,OAAO,CAAC,EAAE,QAAQ,CAAC;CACpB;AAED,eAAO,MAAM,SAAS,4JA6BrB,CAAC"}
1
+ {"version":3,"file":"react.d.ts","sourceRoot":"","sources":["../src/react.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAEvC,OAAO,KAAK,EAAE,cAAc,EAAE,cAAc,EAAE,QAAQ,EAAE,MAAM,aAAa,CAAC;AAE5E,wBAAgB,YAAY,CAAC,OAAO,EAAE,cAAc,GAAG,cAAc,CAuBpE;AAED,MAAM,WAAW,cAAc;IAC7B,QAAQ,EAAE,SAAS,CAAC;IACpB,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,OAAO,CAAC,EAAE,QAAQ,CAAC;IACnB,GAAG,CAAC,EAAE,KAAK,CAAC,GAAG,CAAC,cAAc,CAAC,CAAC;CACjC;AAED,wBAAgB,SAAS,CAAC,EAAE,QAAQ,EAAE,QAAgB,EAAE,OAAO,EAAE,EAAE,EAAE,GAAG,EAAE,GAAG,IAAI,EAAE,EAAE,cAAc,GAAG,KAAK,CAAC,cAAc,CAAC,cAAc,CAAC,2CA2BzI"}
package/dist/react.js CHANGED
@@ -1,12 +1,12 @@
1
1
  "use client";
2
2
  import { t as v, u as I, s as g, i as w } from "./web-D29dUeNW.js";
3
- import { forwardRef as y, useRef as l, useId as x, useImperativeHandle as V, useEffect as i, useCallback as t } from "react";
3
+ import { useRef as l, useEffect as a, useCallback as t, useId as y, useImperativeHandle as x } from "react";
4
4
  import { vistaView as m } from "./vistaview.js";
5
- import { mergeProps as $ } from "solid-js";
6
- var z = /* @__PURE__ */ v("<div>");
7
- function _(o) {
5
+ import { mergeProps as V } from "solid-js";
6
+ var $ = /* @__PURE__ */ v("<div>");
7
+ function P(o) {
8
8
  const r = l(null);
9
- return i(() => (r.current = m(o), () => {
9
+ return a(() => (r.current = m(o), () => {
10
10
  var e;
11
11
  (e = r.current) == null || e.destroy(), r.current = null;
12
12
  }), []), {
@@ -52,16 +52,17 @@ function _(o) {
52
52
  }, [])
53
53
  };
54
54
  }
55
- const b = y(({
55
+ function _({
56
56
  children: o,
57
57
  selector: r = "> a",
58
58
  options: e,
59
59
  id: n,
60
+ ref: p,
60
61
  ...d
61
- }, p) => {
62
- const a = l(null), s = l(null), f = x(), c = n || `vvw-gallery-${f.replace(/:/g, "")}`;
63
- return V(p, () => s.current, []), i(() => {
64
- if (a.current)
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(() => {
65
+ if (i.current)
65
66
  return s.current = m({
66
67
  ...e,
67
68
  elements: `#${c} ${r}`
@@ -70,13 +71,13 @@ const b = y(({
70
71
  (u = s.current) == null || u.destroy(), s.current = null;
71
72
  };
72
73
  }, [c, r]), (() => {
73
- var u = z();
74
- return I(a, u), g(u, $(d, {
74
+ var u = $();
75
+ return I(i, u), g(u, V(d, {
75
76
  id: c
76
77
  }), !1), w(u, o), u;
77
78
  })();
78
- });
79
+ }
79
80
  export {
80
- b as VistaView,
81
- _ as useVistaView
81
+ _ as VistaView,
82
+ P as useVistaView
82
83
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "vistaview",
3
- "version": "0.10.17",
3
+ "version": "0.10.18",
4
4
  "description": "A lightweight, zero-dependency image lightbox library with smooth animations and touch support",
5
5
  "keywords": [
6
6
  "image",