burne-ui 1.6.3 → 1.6.4

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.
@@ -5961,8 +5961,9 @@ function rs(n) {
5961
5961
  }
5962
5962
  Dr(n);
5963
5963
  }
5964
- function fc(n = document) {
5965
- typeof document > "u" || n.querySelectorAll(`[${_n}]`).forEach(rs);
5964
+ function fc(n) {
5965
+ if (typeof document > "u") return;
5966
+ document.querySelectorAll(`[${_n}]`).forEach(rs);
5966
5967
  }
5967
5968
  function dc() {
5968
5969
  Zr || typeof document > "u" || (Zr = new MutationObserver((n) => {
@@ -7024,10 +7025,12 @@ const pu = [
7024
7025
  ]),
7025
7026
  ...Object.values(Yn)
7026
7027
  ];
7027
- function Xf(n = document.documentElement) {
7028
- for (const e of pu)
7029
- n.style.removeProperty(e);
7030
- delete n.dataset.theme;
7028
+ function Xf(n) {
7029
+ if (typeof document > "u") return;
7030
+ const e = n ?? document.documentElement;
7031
+ for (const t of pu)
7032
+ e.style.removeProperty(t);
7033
+ delete e.dataset.theme;
7031
7034
  }
7032
7035
  let Li = "";
7033
7036
  function gu(n) {
@@ -7106,10 +7109,12 @@ function gu(n) {
7106
7109
  enableLoadingDots: n.enableLoadingDots
7107
7110
  }));
7108
7111
  }
7109
- function mu(n, e = document.documentElement) {
7110
- n.theme === "light" ? e.dataset.theme = "light" : delete e.dataset.theme, e.style.setProperty("--space", `${n.space}rem`), e.style.setProperty("--size", `${n.size}rem`), e.style.setProperty("--radius", `${n.radius}rem`), e.style.setProperty("--border-width", n.borderWidth === 0 ? "0px" : `${n.borderWidth}px`), e.style.setProperty("--font-family-sans", n.fontFamily), e.style.setProperty("--font-family-mono", n.fontFamilyMono), hu(e, n.fontWeights), gu(n), du(e, n.textScale), fu(e, n.theme, n.shadowStrength, n.shadowSize), e.style.setProperty("--toast-scrim-size", String(n.toastScrimSize)), e.style.setProperty("--toast-scrim-density", String(n.toastScrimDensity));
7111
- for (const [t, r] of Object.entries(Yn))
7112
- e.style.setProperty(r, n.colors[t]);
7112
+ function mu(n, e) {
7113
+ if (typeof document > "u") return;
7114
+ const t = e ?? document.documentElement;
7115
+ n.theme === "light" ? t.dataset.theme = "light" : delete t.dataset.theme, t.style.setProperty("--space", `${n.space}rem`), t.style.setProperty("--size", `${n.size}rem`), t.style.setProperty("--radius", `${n.radius}rem`), t.style.setProperty("--border-width", n.borderWidth === 0 ? "0px" : `${n.borderWidth}px`), t.style.setProperty("--font-family-sans", n.fontFamily), t.style.setProperty("--font-family-mono", n.fontFamilyMono), hu(t, n.fontWeights), gu(n), du(t, n.textScale), fu(t, n.theme, n.shadowStrength, n.shadowSize), t.style.setProperty("--toast-scrim-size", String(n.toastScrimSize)), t.style.setProperty("--toast-scrim-density", String(n.toastScrimDensity));
7116
+ for (const [r, i] of Object.entries(Yn))
7117
+ t.style.setProperty(i, n.colors[r]);
7113
7118
  }
7114
7119
  function _u(n) {
7115
7120
  const e = [
@@ -7252,11 +7257,13 @@ function yu(n, e, t) {
7252
7257
  }), e.style.setProperty(s, a);
7253
7258
  Or.set(e, o);
7254
7259
  }
7255
- function jf(n = document.documentElement) {
7256
- var e;
7257
- (e = Or.get(n)) == null || e.forEach((t, r) => {
7258
- t.value ? n.style.setProperty(r, t.value, t.priority) : n.style.removeProperty(r);
7259
- }), Or.delete(n);
7260
+ function jf(n) {
7261
+ var t;
7262
+ if (typeof document > "u") return;
7263
+ const e = n ?? document.documentElement;
7264
+ (t = Or.get(e)) == null || t.forEach((r, i) => {
7265
+ r.value ? e.style.setProperty(i, r.value, r.priority) : e.style.removeProperty(i);
7266
+ }), Or.delete(e);
7260
7267
  }
7261
7268
  function xu(n) {
7262
7269
  return {
@@ -7313,18 +7320,19 @@ function fs(n) {
7313
7320
  r !== void 0 && (e[t] = r);
7314
7321
  return e;
7315
7322
  }
7316
- function wu(n, e = document.documentElement, t = Zn(n.theme)) {
7317
- const r = cs(n, t);
7323
+ function wu(n, e, t = Zn(n.theme)) {
7324
+ if (typeof document > "u") return;
7325
+ const r = e ?? document.documentElement, i = cs(n, t);
7318
7326
  if (n.motion) {
7319
- const i = n.motion;
7320
- i.interactiveDuration !== void 0 && (r.interactiveDuration = i.interactiveDuration), i.interactiveEase !== void 0 && (r.interactiveEase = i.interactiveEase), i.hoverLiftEase !== void 0 && (r.hoverLiftEase = i.hoverLiftEase), i.tooltipDuration !== void 0 && (r.tooltipDuration = i.tooltipDuration), i.switchThumbDuration !== void 0 && (r.switchThumbDuration = i.switchThumbDuration), i.switchThumbEase !== void 0 && (r.switchThumbEase = i.switchThumbEase), i.selectionFillDuration !== void 0 && (r.selectionFillDuration = i.selectionFillDuration), i.selectionFillEase !== void 0 && (r.selectionFillEase = i.selectionFillEase), i.hoverLiftScale !== void 0 && (r.hoverLiftScale = i.hoverLiftScale), i.badgeAnchorHoverLiftScale !== void 0 && (r.badgeAnchorHoverLiftScale = i.badgeAnchorHoverLiftScale), i.pressSqueezeScale !== void 0 && (r.pressSqueezeMid = i.pressSqueezeScale[1]), i.rippleDefaultDuration !== void 0 && (r.rippleDefaultDuration = i.rippleDefaultDuration), i.rippleDefaultOpacityFrom !== void 0 && (r.rippleDefaultOpacityFrom = i.rippleDefaultOpacityFrom), i.rippleExpandableDuration !== void 0 && (r.rippleExpandableDuration = i.rippleExpandableDuration), i.rippleExpandableOpacityFrom !== void 0 && (r.rippleExpandableOpacityFrom = i.rippleExpandableOpacityFrom), i.rippleEaseCss !== void 0 && (r.rippleEaseCss = i.rippleEaseCss), i.feedbackExpandDuration !== void 0 && (r.feedbackExpandDuration = i.feedbackExpandDuration), i.expandDuration !== void 0 && (r.expandDuration = i.expandDuration), i.expandOpenEase !== void 0 && (r.expandOpenEase = i.expandOpenEase), i.progressFillDuration !== void 0 && (r.progressFillDuration = i.progressFillDuration), i.progressFillEase !== void 0 && (r.progressFillEase = i.progressFillEase), i.loadingDotsDuration !== void 0 && (r.loadingDotsDuration = i.loadingDotsDuration), i.loadingDotsEaseUp !== void 0 && (r.loadingDotsEaseUp = i.loadingDotsEaseUp), i.loadingDotsEaseDown !== void 0 && (r.loadingDotsEaseDown = i.loadingDotsEaseDown), i.enableHoverLift !== void 0 && (r.enableHoverLift = i.enableHoverLift), i.enablePressSqueeze !== void 0 && (r.enablePressSqueeze = i.enablePressSqueeze), i.enableToggleButtonFill !== void 0 && (r.enableToggleButtonFill = i.enableToggleButtonFill), i.enableRipple !== void 0 && (r.enableRipple = i.enableRipple), i.enableExpandable !== void 0 && (r.enableExpandable = i.enableExpandable), i.enableToastStack !== void 0 && (r.enableToastStack = i.enableToastStack), i.enableAsyncButtonCrossfade !== void 0 && (r.enableAsyncButtonCrossfade = i.enableAsyncButtonCrossfade), i.enableContentFade !== void 0 && (r.enableContentFade = i.enableContentFade), i.enableFeedbackExpand !== void 0 && (r.enableFeedbackExpand = i.enableFeedbackExpand), i.enableProgressFill !== void 0 && (r.enableProgressFill = i.enableProgressFill), i.enableLoadingDots !== void 0 && (r.enableLoadingDots = i.enableLoadingDots);
7327
+ const o = n.motion;
7328
+ o.interactiveDuration !== void 0 && (i.interactiveDuration = o.interactiveDuration), o.interactiveEase !== void 0 && (i.interactiveEase = o.interactiveEase), o.hoverLiftEase !== void 0 && (i.hoverLiftEase = o.hoverLiftEase), o.tooltipDuration !== void 0 && (i.tooltipDuration = o.tooltipDuration), o.switchThumbDuration !== void 0 && (i.switchThumbDuration = o.switchThumbDuration), o.switchThumbEase !== void 0 && (i.switchThumbEase = o.switchThumbEase), o.selectionFillDuration !== void 0 && (i.selectionFillDuration = o.selectionFillDuration), o.selectionFillEase !== void 0 && (i.selectionFillEase = o.selectionFillEase), o.hoverLiftScale !== void 0 && (i.hoverLiftScale = o.hoverLiftScale), o.badgeAnchorHoverLiftScale !== void 0 && (i.badgeAnchorHoverLiftScale = o.badgeAnchorHoverLiftScale), o.pressSqueezeScale !== void 0 && (i.pressSqueezeMid = o.pressSqueezeScale[1]), o.rippleDefaultDuration !== void 0 && (i.rippleDefaultDuration = o.rippleDefaultDuration), o.rippleDefaultOpacityFrom !== void 0 && (i.rippleDefaultOpacityFrom = o.rippleDefaultOpacityFrom), o.rippleExpandableDuration !== void 0 && (i.rippleExpandableDuration = o.rippleExpandableDuration), o.rippleExpandableOpacityFrom !== void 0 && (i.rippleExpandableOpacityFrom = o.rippleExpandableOpacityFrom), o.rippleEaseCss !== void 0 && (i.rippleEaseCss = o.rippleEaseCss), o.feedbackExpandDuration !== void 0 && (i.feedbackExpandDuration = o.feedbackExpandDuration), o.expandDuration !== void 0 && (i.expandDuration = o.expandDuration), o.expandOpenEase !== void 0 && (i.expandOpenEase = o.expandOpenEase), o.progressFillDuration !== void 0 && (i.progressFillDuration = o.progressFillDuration), o.progressFillEase !== void 0 && (i.progressFillEase = o.progressFillEase), o.loadingDotsDuration !== void 0 && (i.loadingDotsDuration = o.loadingDotsDuration), o.loadingDotsEaseUp !== void 0 && (i.loadingDotsEaseUp = o.loadingDotsEaseUp), o.loadingDotsEaseDown !== void 0 && (i.loadingDotsEaseDown = o.loadingDotsEaseDown), o.enableHoverLift !== void 0 && (i.enableHoverLift = o.enableHoverLift), o.enablePressSqueeze !== void 0 && (i.enablePressSqueeze = o.enablePressSqueeze), o.enableToggleButtonFill !== void 0 && (i.enableToggleButtonFill = o.enableToggleButtonFill), o.enableRipple !== void 0 && (i.enableRipple = o.enableRipple), o.enableExpandable !== void 0 && (i.enableExpandable = o.enableExpandable), o.enableToastStack !== void 0 && (i.enableToastStack = o.enableToastStack), o.enableAsyncButtonCrossfade !== void 0 && (i.enableAsyncButtonCrossfade = o.enableAsyncButtonCrossfade), o.enableContentFade !== void 0 && (i.enableContentFade = o.enableContentFade), o.enableFeedbackExpand !== void 0 && (i.enableFeedbackExpand = o.enableFeedbackExpand), o.enableProgressFill !== void 0 && (i.enableProgressFill = o.enableProgressFill), o.enableLoadingDots !== void 0 && (i.enableLoadingDots = o.enableLoadingDots);
7321
7329
  }
7322
- mu(r, e), yu(n.customTokens, e, t);
7330
+ mu(i, r), yu(n.customTokens, r, t);
7323
7331
  }
7324
7332
  function Zn(n = "system") {
7325
7333
  return n === "light" || n === "dark" ? n : typeof window < "u" && window.matchMedia("(prefers-color-scheme: light)").matches ? "light" : "dark";
7326
7334
  }
7327
- function Qf(n, e = document.documentElement, t = "dark") {
7335
+ function Qf(n, e, t = "dark") {
7328
7336
  wu({ theme: t, tokens: n }, e, t);
7329
7337
  }
7330
7338
  function Jf(n) {
@@ -7404,8 +7412,10 @@ function Eu(n, e) {
7404
7412
  } catch {
7405
7413
  }
7406
7414
  }
7407
- function Cu(n, e = document.documentElement) {
7408
- n === "light" ? e.dataset.theme = "light" : delete e.dataset.theme;
7415
+ function Cu(n, e) {
7416
+ if (typeof document > "u") return;
7417
+ const t = e ?? document.documentElement;
7418
+ n === "light" ? t.dataset.theme = "light" : delete t.dataset.theme;
7409
7419
  }
7410
7420
  function td({
7411
7421
  children: n,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "burne-ui",
3
- "version": "1.6.3",
3
+ "version": "1.6.4",
4
4
  "description": "React UI kit (Burne UI)",
5
5
  "type": "module",
6
6
  "sideEffects": [