@abdellatifui/react 3.2.55 → 3.2.57

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/nextgen.d.ts CHANGED
@@ -81,7 +81,6 @@ export declare interface AccordionItemProps {
81
81
  props: any;
82
82
  api: any;
83
83
  }) => void;
84
- delay?: number;
85
84
  }
86
85
 
87
86
  export declare interface AdvancedSpinnerProps extends SpinnerProps {
package/dist/nextgen.js CHANGED
@@ -19268,25 +19268,22 @@ const Rd = An({}), QS = (e) => {
19268
19268
  onClose: u = () => {
19269
19269
  },
19270
19270
  defaultOpen: f = !1,
19271
- disabled: p = !1,
19272
- delay: m = 0
19273
- } = e, { updateApi: h, options: g } = De(Rd), d = lt(5, !0, !1), [b, S] = $();
19274
- function w() {
19275
- const x = t.current.dataset.state != "open", k = { ...e, open: x, ref: t, refTrigger: r };
19276
- x && (l(k), setTimeout(() => {
19277
- S(s);
19278
- }, m)), x || (u(k), S(null)), h((v) => ({ ...v, ...k }));
19271
+ disabled: p = !1
19272
+ } = e, { updateApi: m, options: h } = De(Rd), g = lt(5, !0, !1);
19273
+ function d() {
19274
+ const b = t.current.dataset.state != "open", S = { ...e, open: b, ref: t, refTrigger: r };
19275
+ b && l(S), b || u(S), m((w) => ({ ...w, ...S }));
19279
19276
  }
19280
19277
  return q(() => {
19281
19278
  f && r?.current && setTimeout(() => {
19282
19279
  pe(r.current).click();
19283
19280
  }, 100);
19284
- }, [f]), /* @__PURE__ */ c.jsxs(ea, { ref: t, id: d, onClick: w, className: H(Bw({
19281
+ }, [f]), /* @__PURE__ */ c.jsxs(ea, { ref: t, id: g, onClick: d, className: H(Bw({
19285
19282
  disabled: p,
19286
- border: g.border
19283
+ border: h.border
19287
19284
  }), a), disabled: p, value: o, children: [
19288
19285
  /* @__PURE__ */ c.jsx(ta, { ref: r, children: i }),
19289
- /* @__PURE__ */ c.jsx(na, { children: b })
19286
+ /* @__PURE__ */ c.jsx(na, { children: s })
19290
19287
  ] }, n);
19291
19288
  }, Od = ge((e, n) => {
19292
19289
  const [t, r] = $(/* @__PURE__ */ c.jsx(Ca, { size: 16 })), { value: o, restoreSec: s, outline: i = !0, className: a = "" } = e;
@@ -22532,26 +22529,29 @@ const Kd = An({ name: "", onChange: () => {
22532
22529
  }, []), q(() => {
22533
22530
  if (!S || !h || !w.connected) return;
22534
22531
  console.log("Mounting Notification Listener ...");
22535
- const v = (E) => {
22536
- if (console.log("API : Coming Notification : ", E), E?._role === "alert") {
22537
- const A = E?.status === 200;
22532
+ const v = (A) => {
22533
+ if (console.log("API : Coming Notification : ", A), A?._role === "alert") {
22534
+ const T = A?.status === 200;
22538
22535
  abui?.alert?.({
22539
- error: !A,
22540
- success: A,
22541
- body: E?.message,
22542
- ...E?._options
22536
+ error: !T,
22537
+ success: T,
22538
+ body: A?.message,
22539
+ ...A?._options
22543
22540
  });
22544
- } else if (E?._role === "toast") {
22545
- const A = E?.status === 200 ? "success" : "error";
22541
+ } else if (A?._role === "toast") {
22542
+ const T = A?.status === 200 ? "success" : "error";
22546
22543
  abui?.toast?.({
22547
- body: E?.message,
22548
- type: A,
22549
- ...E?._options
22544
+ body: A?.message,
22545
+ type: T,
22546
+ ...A?._options
22550
22547
  });
22551
22548
  }
22549
+ }, E = (A) => {
22550
+ const { url: T } = A;
22551
+ window.open(T, "_self");
22552
22552
  };
22553
- return w.on("/stream/notify", v), () => {
22554
- console.log("Unmounting Notification Listener ..."), w.off("/stream/notify", v);
22553
+ return w.on("/stream/notify", v), w.on("/stream/redirect", E), () => {
22554
+ console.log("Unmounting Notification Listener ..."), w.off("/stream/notify", v), w.off("/stream/redirect", E);
22555
22555
  };
22556
22556
  }, [h, S, w?.connected]);
22557
22557
  const x = oe((v) => async (...E) => {
@@ -22566,7 +22566,7 @@ const Kd = An({ name: "", onChange: () => {
22566
22566
  return T;
22567
22567
  } catch (T) {
22568
22568
  const _ = T;
22569
- throw l && l(_), u && u(_), T;
22569
+ return l && l(_), u && u(_), _;
22570
22570
  }
22571
22571
  }, [f, a, u, p, l]), k = le(() => {
22572
22572
  const v = up.create({
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@abdellatifui/react",
3
3
  "private": false,
4
- "version": "3.2.55",
4
+ "version": "3.2.57",
5
5
  "type": "module",
6
6
  "types": "dist/nextgen.d.ts",
7
7
  "files": [