@stackone/malachite 0.58.0 → 0.58.1

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/index.js CHANGED
@@ -9253,29 +9253,23 @@ const $8 = () => {
9253
9253
  const a = q(null), [o, n] = H(null);
9254
9254
  return x1(() => {
9255
9255
  if (a.current && !o) {
9256
- const s = a.current.shadowRoot;
9257
- if (s) {
9258
- n(s);
9259
- return;
9260
- }
9261
- const l = a.current.attachShadow({ mode: "open" });
9262
- n(l);
9256
+ const s = a.current.shadowRoot ?? a.current.attachShadow({ mode: "open" }), l = $8();
9257
+ (!l || !_8(s, l)) && e9(s, k2), n(s);
9263
9258
  }
9264
9259
  }, [o]), x1(() => {
9265
- if (!o)
9266
- return;
9267
- const s = $8();
9268
- if ((!s || !_8(o, s)) && e9(o, k2), A2(), G8(), H8(), t) {
9269
- z8(o, t);
9270
- return;
9271
- }
9272
- return j8(o), () => {
9273
- try {
9274
- O8(o);
9275
- } catch (l) {
9276
- console.warn("Error during shadow root cleanup:", l);
9260
+ if (o) {
9261
+ if (A2(), G8(), H8(), t) {
9262
+ z8(o, t);
9263
+ return;
9277
9264
  }
9278
- };
9265
+ return j8(o), () => {
9266
+ try {
9267
+ O8(o);
9268
+ } catch (s) {
9269
+ console.warn("Error during shadow root cleanup:", s);
9270
+ }
9271
+ };
9272
+ }
9279
9273
  }, [o, t]), o === null ? /* @__PURE__ */ i("div", { ref: a, "data-testid": "shadow-root-wrapper", style: r }) : /* @__PURE__ */ i("div", { ref: a, style: r, children: o && we(/* @__PURE__ */ i("div", { style: { isolation: "isolate" }, children: e }), o) });
9280
9274
  }, co = ({ children: e, className: t = "" }) => /* @__PURE__ */ i(M2, { children: /* @__PURE__ */ i("div", { className: t, children: e }) }), ho = ({
9281
9275
  children: e,