@digilogiclabs/saas-factory-ui 1.33.2 → 1.34.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.d.mts CHANGED
@@ -4987,9 +4987,9 @@ interface RandomPlayerPickerProps {
4987
4987
  * Visual intensity preset. Default "normal".
4988
4988
  * - "subtle" / "normal": current behavior — shorter spins, standard
4989
4989
  * ease-out curve.
4990
- * - "dramatic": physics-like spin — 1.5× duration, ease-out-quart
4990
+ * - "dramatic": physics-like spin — 2.5× duration, inertia-style
4991
4991
  * curve so motion continues through the full duration with a slow
4992
- * winding-down tail, +4 extra revolutions, plus more
4992
+ * winding-down tail, +12 extra revolutions, plus more
4993
4993
  * particles/glow/shake on reveal.
4994
4994
  */
4995
4995
  intensity?: RandomPlayerIntensity;
@@ -5074,6 +5074,40 @@ interface HeroBannerCta {
5074
5074
  interface HeroBannerSlide {
5075
5075
  /** Background image URL. */
5076
5076
  image?: string;
5077
+ /**
5078
+ * Render this slide's image as a real `<img>` (with `fetchpriority="high"`,
5079
+ * `loading="eager"`, `decoding="async"`) instead of a CSS `background-image`.
5080
+ *
5081
+ * Set this on the first slide to make it a reliable LCP target. CSS
5082
+ * backgrounds are valid LCP candidates but the browser discovers them
5083
+ * later (after CSS parse), and `<link rel="preload">` connects to real
5084
+ * `<img>` elements far more reliably than to `background-image` URLs.
5085
+ *
5086
+ * Only the slide with `priority: true` swaps to `<img>`; all other slides
5087
+ * stay on CSS `background-image` (cheaper to cycle). The `imageFilter`,
5088
+ * `bgColor`, overlays, and accent layers all still apply.
5089
+ */
5090
+ priority?: boolean;
5091
+ /**
5092
+ * Optional alt text for the priority `<img>`. Defaults to empty (decorative)
5093
+ * — appropriate when the slide already carries semantic text via headline /
5094
+ * kicker.
5095
+ */
5096
+ imageAlt?: string;
5097
+ /**
5098
+ * Optional intrinsic width of the priority image (in pixels). When set with
5099
+ * `imageHeight`, emitted as the `<img>` `width` HTML attribute. Lets the
5100
+ * browser compute aspect ratio for the preload connection without waiting
5101
+ * for image headers. Has no layout effect when the parent already sizes
5102
+ * the image via absolute positioning (the default). Ignored unless
5103
+ * `priority` is true.
5104
+ */
5105
+ imageWidth?: number;
5106
+ /**
5107
+ * Optional intrinsic height of the priority image (in pixels). Companion
5108
+ * to `imageWidth`. See `imageWidth` for usage notes.
5109
+ */
5110
+ imageHeight?: number;
5077
5111
  /** CSS gradient string (e.g. `"linear-gradient(135deg,#0f172a,#0f4c75)"`). */
5078
5112
  gradient?: string;
5079
5113
  /** Fallback solid background color. */
package/dist/index.d.ts CHANGED
@@ -4987,9 +4987,9 @@ interface RandomPlayerPickerProps {
4987
4987
  * Visual intensity preset. Default "normal".
4988
4988
  * - "subtle" / "normal": current behavior — shorter spins, standard
4989
4989
  * ease-out curve.
4990
- * - "dramatic": physics-like spin — 1.5× duration, ease-out-quart
4990
+ * - "dramatic": physics-like spin — 2.5× duration, inertia-style
4991
4991
  * curve so motion continues through the full duration with a slow
4992
- * winding-down tail, +4 extra revolutions, plus more
4992
+ * winding-down tail, +12 extra revolutions, plus more
4993
4993
  * particles/glow/shake on reveal.
4994
4994
  */
4995
4995
  intensity?: RandomPlayerIntensity;
@@ -5074,6 +5074,40 @@ interface HeroBannerCta {
5074
5074
  interface HeroBannerSlide {
5075
5075
  /** Background image URL. */
5076
5076
  image?: string;
5077
+ /**
5078
+ * Render this slide's image as a real `<img>` (with `fetchpriority="high"`,
5079
+ * `loading="eager"`, `decoding="async"`) instead of a CSS `background-image`.
5080
+ *
5081
+ * Set this on the first slide to make it a reliable LCP target. CSS
5082
+ * backgrounds are valid LCP candidates but the browser discovers them
5083
+ * later (after CSS parse), and `<link rel="preload">` connects to real
5084
+ * `<img>` elements far more reliably than to `background-image` URLs.
5085
+ *
5086
+ * Only the slide with `priority: true` swaps to `<img>`; all other slides
5087
+ * stay on CSS `background-image` (cheaper to cycle). The `imageFilter`,
5088
+ * `bgColor`, overlays, and accent layers all still apply.
5089
+ */
5090
+ priority?: boolean;
5091
+ /**
5092
+ * Optional alt text for the priority `<img>`. Defaults to empty (decorative)
5093
+ * — appropriate when the slide already carries semantic text via headline /
5094
+ * kicker.
5095
+ */
5096
+ imageAlt?: string;
5097
+ /**
5098
+ * Optional intrinsic width of the priority image (in pixels). When set with
5099
+ * `imageHeight`, emitted as the `<img>` `width` HTML attribute. Lets the
5100
+ * browser compute aspect ratio for the preload connection without waiting
5101
+ * for image headers. Has no layout effect when the parent already sizes
5102
+ * the image via absolute positioning (the default). Ignored unless
5103
+ * `priority` is true.
5104
+ */
5105
+ imageWidth?: number;
5106
+ /**
5107
+ * Optional intrinsic height of the priority image (in pixels). Companion
5108
+ * to `imageWidth`. See `imageWidth` for usage notes.
5109
+ */
5110
+ imageHeight?: number;
5077
5111
  /** CSS gradient string (e.g. `"linear-gradient(135deg,#0f172a,#0f4c75)"`). */
5078
5112
  gradient?: string;
5079
5113
  /** Fallback solid background color. */
package/dist/index.js CHANGED
@@ -10,8 +10,8 @@ var __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { en
10
10
  var __esm = (fn, res) => function __init() {
11
11
  return fn && (res = (0, fn[__getOwnPropNames(fn)[0]])(fn = 0)), res;
12
12
  };
13
- var __commonJS = (cb, mod) => function __require() {
14
- return mod || (0, cb[__getOwnPropNames(cb)[0]])((mod = { exports: {} }).exports, mod), mod.exports;
13
+ var __commonJS = (cb, mod2) => function __require() {
14
+ return mod2 || (0, cb[__getOwnPropNames(cb)[0]])((mod2 = { exports: {} }).exports, mod2), mod2.exports;
15
15
  };
16
16
  var __export = (target, all) => {
17
17
  for (var name in all)
@@ -25,15 +25,15 @@ var __copyProps = (to, from, except, desc) => {
25
25
  }
26
26
  return to;
27
27
  };
28
- var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
28
+ var __toESM = (mod2, isNodeMode, target) => (target = mod2 != null ? __create(__getProtoOf(mod2)) : {}, __copyProps(
29
29
  // If the importer is in node compatibility mode or this is not an ESM
30
30
  // file that has been converted to a CommonJS file using a Babel-
31
31
  // compatible transform (i.e. "__esModule" has not been set), then set
32
32
  // "default" to the CommonJS "module.exports" for node compatibility.
33
- isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
34
- mod
33
+ isNodeMode || !mod2 || !mod2.__esModule ? __defProp(target, "default", { value: mod2, enumerable: true }) : target,
34
+ mod2
35
35
  ));
36
- var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
36
+ var __toCommonJS = (mod2) => __copyProps(__defProp({}, "__esModule", { value: true }), mod2);
37
37
  var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "symbol" ? key + "" : key, value);
38
38
 
39
39
  // src/config/constants.ts
@@ -27747,15 +27747,6 @@ var SortIcon = ({ size = 13 }) => /* @__PURE__ */ (0, import_jsx_runtime110.jsxs
27747
27747
  ]
27748
27748
  }
27749
27749
  );
27750
- var STYLE_ID = "dll-news-ticker-styles";
27751
- function ensureStylesInjected() {
27752
- if (typeof document === "undefined") return;
27753
- if (document.getElementById(STYLE_ID)) return;
27754
- const el = document.createElement("style");
27755
- el.id = STYLE_ID;
27756
- el.textContent = NEWS_TICKER_CSS;
27757
- document.head.appendChild(el);
27758
- }
27759
27750
  function NewsTicker({
27760
27751
  items,
27761
27752
  speed = 40,
@@ -27784,9 +27775,6 @@ function NewsTicker({
27784
27775
  const inputRef = React85.useRef(null);
27785
27776
  const filterRef = React85.useRef(null);
27786
27777
  const [trackWidth, setTrackWidth] = React85.useState(0);
27787
- React85.useEffect(() => {
27788
- ensureStylesInjected();
27789
- }, []);
27790
27778
  const hasFiltersOrSort = filters.length > 0 || sorts.length > 0;
27791
27779
  const activeFilterCount = Object.values(activeFilters).filter((v) => v && v.length > 0).length + (activeSort ? 1 : 0);
27792
27780
  React85.useEffect(() => {
@@ -27872,6 +27860,7 @@ function NewsTicker({
27872
27860
  className: `ticker-root ${variantClass} ${className}`,
27873
27861
  style: { ["--ticker-h"]: `${height}px` },
27874
27862
  children: [
27863
+ /* @__PURE__ */ (0, import_jsx_runtime110.jsx)("style", { href: "dll-news-ticker-styles", precedence: "default", children: NEWS_TICKER_CSS }),
27875
27864
  /* @__PURE__ */ (0, import_jsx_runtime110.jsxs)("div", { className: "ticker-controls", children: [
27876
27865
  /* @__PURE__ */ (0, import_jsx_runtime110.jsx)(
27877
27866
  "button",
@@ -28643,15 +28632,6 @@ function useDebouncedValue(value, ms) {
28643
28632
  }, [value, ms]);
28644
28633
  return debounced;
28645
28634
  }
28646
- var STYLE_ID2 = "dll-filterable-grid-styles";
28647
- function ensureStylesInjected2() {
28648
- if (typeof document === "undefined") return;
28649
- if (document.getElementById(STYLE_ID2)) return;
28650
- const el = document.createElement("style");
28651
- el.id = STYLE_ID2;
28652
- el.textContent = FILTERABLE_GRID_CSS;
28653
- document.head.appendChild(el);
28654
- }
28655
28635
  function FilterSidebar({
28656
28636
  open,
28657
28637
  onClose,
@@ -28986,9 +28966,6 @@ function FilterableGrid({
28986
28966
  labels: labelOverrides,
28987
28967
  className = ""
28988
28968
  }) {
28989
- React86.useEffect(() => {
28990
- ensureStylesInjected2();
28991
- }, []);
28992
28969
  const labels = React86.useMemo(
28993
28970
  () => ({ ...DEFAULT_LABELS, ...labelOverrides }),
28994
28971
  [labelOverrides]
@@ -29243,6 +29220,7 @@ function FilterableGrid({
29243
29220
  const showEmpty = displayed.length === 0 && !loading;
29244
29221
  const currentState = stateRef.current;
29245
29222
  return /* @__PURE__ */ (0, import_jsx_runtime111.jsxs)("div", { className: `fg-root ${className}`.trim(), children: [
29223
+ /* @__PURE__ */ (0, import_jsx_runtime111.jsx)("style", { href: "dll-filterable-grid-styles", precedence: "default", children: FILTERABLE_GRID_CSS }),
29246
29224
  /* @__PURE__ */ (0, import_jsx_runtime111.jsx)("div", { className: "fg-sr-only", "aria-live": "polite", "aria-atomic": "true", children: announcement }),
29247
29225
  showSearch && /* @__PURE__ */ (0, import_jsx_runtime111.jsx)("div", { className: "fg-search-row", children: /* @__PURE__ */ (0, import_jsx_runtime111.jsxs)("div", { className: "fg-search", children: [
29248
29226
  /* @__PURE__ */ (0, import_jsx_runtime111.jsx)(SearchIcon2, { size: 16 }),
@@ -29999,7 +29977,6 @@ var STAGGER_STEP_MS = 35;
29999
29977
  var STAGGER_CAP = 14;
30000
29978
  var TILT_MAX_DEG = 12;
30001
29979
  var SCALE_HOVER = 1.04;
30002
- var STYLE_ID3 = "dll-tilt-card-styles";
30003
29980
  var TILT_CARD_CSS = `
30004
29981
  .tc-root {
30005
29982
  --tc-accent: #3b82f6;
@@ -30304,14 +30281,6 @@ var TILT_CARD_CSS = `
30304
30281
  }
30305
30282
  }
30306
30283
  `;
30307
- function ensureStylesInjected3() {
30308
- if (typeof document === "undefined") return;
30309
- if (document.getElementById(STYLE_ID3)) return;
30310
- const el = document.createElement("style");
30311
- el.id = STYLE_ID3;
30312
- el.textContent = TILT_CARD_CSS;
30313
- document.head.appendChild(el);
30314
- }
30315
30284
  function TiltCard({
30316
30285
  accent,
30317
30286
  accentSecondary,
@@ -30335,7 +30304,6 @@ function TiltCard({
30335
30304
  const uid = (0, import_react67.useId)().replace(/:/g, "");
30336
30305
  const rootRef = (0, import_react67.useRef)(null);
30337
30306
  const [hovered, setHovered] = (0, import_react67.useState)(false);
30338
- ensureStylesInjected3();
30339
30307
  const handleMove = (0, import_react67.useCallback)(
30340
30308
  (e) => {
30341
30309
  if (disableTilt && disableShine) return;
@@ -30440,8 +30408,9 @@ function TiltCard({
30440
30408
  "aria-pressed": as === "button" ? selected : void 0,
30441
30409
  "data-hovered": hovered || void 0
30442
30410
  };
30411
+ const stylesheet = /* @__PURE__ */ (0, import_jsx_runtime113.jsx)("style", { href: "dll-tilt-card-styles", precedence: "default", children: TILT_CARD_CSS });
30443
30412
  if (as === "button") {
30444
- return /* @__PURE__ */ (0, import_jsx_runtime113.jsx)(
30413
+ return /* @__PURE__ */ (0, import_jsx_runtime113.jsxs)(
30445
30414
  "button",
30446
30415
  {
30447
30416
  ...commonProps,
@@ -30449,11 +30418,14 @@ function TiltCard({
30449
30418
  disabled: selected,
30450
30419
  onClick: handleClick,
30451
30420
  onKeyDown: handleKey,
30452
- children: content
30421
+ children: [
30422
+ stylesheet,
30423
+ content
30424
+ ]
30453
30425
  }
30454
30426
  );
30455
30427
  }
30456
- return /* @__PURE__ */ (0, import_jsx_runtime113.jsx)(
30428
+ return /* @__PURE__ */ (0, import_jsx_runtime113.jsxs)(
30457
30429
  "div",
30458
30430
  {
30459
30431
  ...commonProps,
@@ -30462,7 +30434,10 @@ function TiltCard({
30462
30434
  "aria-disabled": selected || void 0,
30463
30435
  onClick: handleClick,
30464
30436
  onKeyDown: handleKey,
30465
- children: content
30437
+ children: [
30438
+ stylesheet,
30439
+ content
30440
+ ]
30466
30441
  }
30467
30442
  );
30468
30443
  }
@@ -33326,8 +33301,8 @@ var WEDGE_PALETTE = [
33326
33301
  "#14b8a6",
33327
33302
  "#f97316"
33328
33303
  ];
33329
- var DEFAULT_EASING = "cubic-bezier(0.12, 0.78, 0.22, 1)";
33330
- var DRAMATIC_EASING = "cubic-bezier(0.22, 1, 0.36, 1)";
33304
+ var DEFAULT_EASING = "cubic-bezier(0.25, 0.46, 0.45, 0.94)";
33305
+ var DRAMATIC_EASING = "cubic-bezier(0.39, 0.575, 0.565, 1)";
33331
33306
  var INTENSITY_CONFIG = {
33332
33307
  subtle: {
33333
33308
  particles: 14,
@@ -33352,9 +33327,9 @@ var INTENSITY_CONFIG = {
33352
33327
  shakePeak: 10,
33353
33328
  glowMult: 1.45,
33354
33329
  pulseStroke: 8,
33355
- durationMult: 1.5,
33330
+ durationMult: 2.5,
33356
33331
  easing: DRAMATIC_EASING,
33357
- revsBoost: 4
33332
+ revsBoost: 12
33358
33333
  }
33359
33334
  };
33360
33335
  function polar(cx, cy, r, a) {
@@ -33380,6 +33355,20 @@ function weightedIndex(pool) {
33380
33355
  }
33381
33356
  return pool.length - 1;
33382
33357
  }
33358
+ function mod(value, divisor) {
33359
+ return (value % divisor + divisor) % divisor;
33360
+ }
33361
+ function wheelIndexAtPointer(rotation, count2) {
33362
+ if (count2 < 1) return -1;
33363
+ const wedgeDeg = 360 / count2;
33364
+ const localDegAtPointer = mod(-rotation, 360);
33365
+ return Math.min(count2 - 1, Math.floor(localDegAtPointer / wedgeDeg));
33366
+ }
33367
+ function reelIndexAtCenter(reelY, centerOffsetPx, rowHeight, count2) {
33368
+ if (count2 < 1) return -1;
33369
+ const centerRow = Math.round((reelY + centerOffsetPx) / rowHeight);
33370
+ return mod(centerRow, count2);
33371
+ }
33383
33372
  function ReelStage({
33384
33373
  pool,
33385
33374
  winner,
@@ -33807,7 +33796,9 @@ function RandomPlayerPicker({
33807
33796
  const winnerIdx = weightedIndex(pool);
33808
33797
  const minRev = minRevolutions + intensityCfg.revsBoost;
33809
33798
  const maxRev = maxRevolutions + intensityCfg.revsBoost;
33810
- const revolutions = minRev + Math.random() * (maxRev - minRev);
33799
+ const minFullRevs = Math.ceil(minRev);
33800
+ const maxFullRevs = Math.max(minFullRevs, Math.floor(maxRev));
33801
+ const revolutions = minFullRevs + Math.floor(Math.random() * (maxFullRevs - minFullRevs + 1));
33811
33802
  const wedgeMidRad = winnerIdx * anglePerWedge + anglePerWedge / 2;
33812
33803
  const wedgeMidDeg = wedgeMidRad * 180 / Math.PI;
33813
33804
  const wheelWobble = (Math.random() - 0.5) * (anglePerWedge * 180 / Math.PI) * 0.6;
@@ -33821,10 +33812,12 @@ function RandomPlayerPicker({
33821
33812
  const currentCenterRow = Math.round(
33822
33813
  (reelY + centerOffsetPx) / reelRowHeight
33823
33814
  );
33824
- const currentCenterMod = (currentCenterRow % n + n) % n;
33815
+ const currentCenterMod = mod(currentCenterRow, n);
33825
33816
  const targetRowOffset = (winnerIdx - currentCenterMod + n) % n;
33826
33817
  const reelRevRows = Math.round(revolutions * n);
33827
33818
  const finalReelY = reelY + (reelRevRows + targetRowOffset) * reelRowHeight;
33819
+ const settledWinnerIdx = mode === "reel" ? reelIndexAtCenter(finalReelY, centerOffsetPx, reelRowHeight, n) : wheelIndexAtPointer(finalRotation, n);
33820
+ const finalWinnerIdx = settledWinnerIdx >= 0 && settledWinnerIdx < pool.length ? settledWinnerIdx : winnerIdx;
33828
33821
  const effectiveDuration = reducedMotion ? 250 : Math.round(spinDuration * intensityCfg.durationMult);
33829
33822
  setSpinning(true);
33830
33823
  setWinner(null);
@@ -33869,7 +33862,7 @@ function RandomPlayerPicker({
33869
33862
  schedule();
33870
33863
  }
33871
33864
  winnerTimer.current = setTimeout(() => {
33872
- const picked = pool[winnerIdx];
33865
+ const picked = pool[finalWinnerIdx];
33873
33866
  if (!picked) {
33874
33867
  setSpinning(false);
33875
33868
  return;
@@ -33916,7 +33909,7 @@ function RandomPlayerPicker({
33916
33909
  }
33917
33910
  if (removeWinners) {
33918
33911
  popTimer.current = setTimeout(() => {
33919
- setPool((p) => p.filter((_, i) => i !== winnerIdx));
33912
+ setPool((p) => p.filter((_, i) => i !== finalWinnerIdx));
33920
33913
  setWinner(null);
33921
33914
  setRotation(0);
33922
33915
  setReelY(0);
@@ -35061,23 +35054,46 @@ function DynamicHeroBanner({
35061
35054
  const filter = IMAGE_FILTERS[slide.imageFilter ?? imageFilter] ?? IMAGE_FILTERS.cinematic;
35062
35055
  const slideOverlayOpacity = slide.overlayOpacity ?? overlayOpacity;
35063
35056
  const slideAlign = slide.textAlign ?? textAlign;
35057
+ const usePriorityImg = slide.priority === true && !!slide.image;
35058
+ const bgDivStyle = usePriorityImg ? {
35059
+ position: "absolute",
35060
+ inset: 0,
35061
+ backgroundColor: slide.bgColor ?? "#0c0e14",
35062
+ transform: isCurrent ? "scale(1)" : "scale(1.06)",
35063
+ transition: reducedMotion ? "none" : `transform ${autoPlayInterval}ms linear`
35064
+ } : {
35065
+ position: "absolute",
35066
+ inset: 0,
35067
+ backgroundImage: slide.image ? `url(${slide.image})` : slide.gradient ?? "none",
35068
+ backgroundColor: slide.bgColor ?? "#0c0e14",
35069
+ backgroundSize: "cover",
35070
+ backgroundPosition: "center",
35071
+ filter,
35072
+ transform: isCurrent ? "scale(1)" : "scale(1.06)",
35073
+ transition: reducedMotion ? "none" : `transform ${autoPlayInterval}ms linear`
35074
+ };
35064
35075
  return /* @__PURE__ */ (0, import_jsx_runtime118.jsxs)("div", { style: bgStyle(i), "aria-hidden": !isCurrent, children: [
35065
- /* @__PURE__ */ (0, import_jsx_runtime118.jsx)(
35066
- "div",
35076
+ /* @__PURE__ */ (0, import_jsx_runtime118.jsx)("div", { style: bgDivStyle, children: usePriorityImg && /* @__PURE__ */ (0, import_jsx_runtime118.jsx)(
35077
+ "img",
35067
35078
  {
35079
+ src: slide.image,
35080
+ alt: slide.imageAlt ?? "",
35081
+ width: slide.imageWidth && slide.imageHeight ? slide.imageWidth : void 0,
35082
+ height: slide.imageWidth && slide.imageHeight ? slide.imageHeight : void 0,
35083
+ fetchPriority: "high",
35084
+ loading: "eager",
35085
+ decoding: "async",
35068
35086
  style: {
35069
35087
  position: "absolute",
35070
35088
  inset: 0,
35071
- backgroundImage: slide.image ? `url(${slide.image})` : slide.gradient ?? "none",
35072
- backgroundColor: slide.bgColor ?? "#0c0e14",
35073
- backgroundSize: "cover",
35074
- backgroundPosition: "center",
35075
- filter,
35076
- transform: isCurrent ? "scale(1)" : "scale(1.06)",
35077
- transition: reducedMotion ? "none" : `transform ${autoPlayInterval}ms linear`
35089
+ width: "100%",
35090
+ height: "100%",
35091
+ objectFit: "cover",
35092
+ objectPosition: "center",
35093
+ filter
35078
35094
  }
35079
35095
  }
35080
- ),
35096
+ ) }),
35081
35097
  /* @__PURE__ */ (0, import_jsx_runtime118.jsx)(
35082
35098
  "div",
35083
35099
  {
@@ -37192,10 +37208,10 @@ var DEFAULT_LAYOUT = {
37192
37208
  cardH: 56,
37193
37209
  detailMaxW: 320
37194
37210
  };
37195
- var STYLE_ID4 = "dll-flow-tree-styles";
37211
+ var STYLE_ID = "dll-flow-tree-styles";
37196
37212
  function FlowTreeStyles() {
37197
37213
  const reactHostingProps = {
37198
- href: STYLE_ID4,
37214
+ href: STYLE_ID,
37199
37215
  precedence: "default"
37200
37216
  };
37201
37217
  return /* @__PURE__ */ (0, import_jsx_runtime121.jsx)(
@@ -37206,11 +37222,11 @@ function FlowTreeStyles() {
37206
37222
  }
37207
37223
  );
37208
37224
  }
37209
- function ensureStylesInjected4() {
37225
+ function ensureStylesInjected() {
37210
37226
  if (typeof document === "undefined") return;
37211
- if (document.getElementById(STYLE_ID4)) return;
37227
+ if (document.getElementById(STYLE_ID)) return;
37212
37228
  const el = document.createElement("style");
37213
- el.id = STYLE_ID4;
37229
+ el.id = STYLE_ID;
37214
37230
  el.textContent = FLOW_TREE_CSS;
37215
37231
  document.head.appendChild(el);
37216
37232
  }
@@ -37698,7 +37714,7 @@ function FlowTree({
37698
37714
  autoCyclePaths
37699
37715
  }) {
37700
37716
  React87.useEffect(() => {
37701
- ensureStylesInjected4();
37717
+ ensureStylesInjected();
37702
37718
  }, []);
37703
37719
  const opts = React87.useMemo(
37704
37720
  () => ({ ...DEFAULT_LAYOUT, ...layoutOptions ?? {} }),
@@ -41594,7 +41610,6 @@ Scoreboard.displayName = "Scoreboard";
41594
41610
  // src/components/ui/step-wizard/index.tsx
41595
41611
  var import_react79 = require("react");
41596
41612
  var import_jsx_runtime128 = require("react/jsx-runtime");
41597
- var STYLE_ID5 = "dll-step-wizard-styles";
41598
41613
  var STEP_WIZARD_CSS = `
41599
41614
  .sw-root {
41600
41615
  --sw-accent: var(--primary, #3b82f6);
@@ -41752,27 +41767,19 @@ var STEP_WIZARD_CSS = `
41752
41767
  box-shadow: 0 4px 20px rgba(34, 197, 94, 0.25);
41753
41768
  }
41754
41769
  `;
41755
- function ensureStylesInjected5() {
41756
- if (typeof document === "undefined") return;
41757
- if (document.getElementById(STYLE_ID5)) return;
41758
- const el = document.createElement("style");
41759
- el.id = STYLE_ID5;
41760
- el.textContent = STEP_WIZARD_CSS;
41761
- document.head.appendChild(el);
41762
- }
41763
41770
  function StepProgress({
41764
41771
  steps,
41765
41772
  current,
41766
41773
  onJump,
41767
41774
  className = ""
41768
41775
  }) {
41769
- ensureStylesInjected5();
41770
41776
  const currentIdx = Math.max(
41771
41777
  0,
41772
41778
  steps.findIndex((s) => s.key === current)
41773
41779
  );
41774
41780
  const pct = steps.length <= 1 ? 100 : currentIdx / (steps.length - 1) * 100;
41775
41781
  return /* @__PURE__ */ (0, import_jsx_runtime128.jsxs)("div", { className: `sw-progress ${className}`.trim(), children: [
41782
+ /* @__PURE__ */ (0, import_jsx_runtime128.jsx)("style", { href: "dll-step-wizard-styles", precedence: "default", children: STEP_WIZARD_CSS }),
41776
41783
  /* @__PURE__ */ (0, import_jsx_runtime128.jsx)("div", { className: "sw-progress-row", children: steps.map((s, i) => {
41777
41784
  const state = i === currentIdx ? "active" : i < currentIdx ? "done" : "todo";
41778
41785
  const clickable = state === "done" && !!onJump;
@@ -41822,7 +41829,6 @@ function StepWizard({
41822
41829
  nextLabel = "Continue",
41823
41830
  className = ""
41824
41831
  }) {
41825
- ensureStylesInjected5();
41826
41832
  const currentIdx = steps.findIndex((s) => s.key === current);
41827
41833
  const safeIdx = currentIdx < 0 ? 0 : currentIdx;
41828
41834
  const isFirst = safeIdx === 0;
@@ -41853,6 +41859,7 @@ function StepWizard({
41853
41859
  return () => window.removeEventListener("keydown", onKey);
41854
41860
  }, [goBack, isFirst]);
41855
41861
  return /* @__PURE__ */ (0, import_jsx_runtime128.jsxs)("div", { className: `sw-root ${className}`.trim(), children: [
41862
+ /* @__PURE__ */ (0, import_jsx_runtime128.jsx)("style", { href: "dll-step-wizard-styles", precedence: "default", children: STEP_WIZARD_CSS }),
41856
41863
  !hideProgress && /* @__PURE__ */ (0, import_jsx_runtime128.jsx)(StepProgress, { steps, current, onJump: onChange }),
41857
41864
  banner && /* @__PURE__ */ (0, import_jsx_runtime128.jsx)("div", { className: "sw-banner", children: banner }),
41858
41865
  /* @__PURE__ */ (0, import_jsx_runtime128.jsx)("div", { className: "sw-content", children: renderStep(current) }, current),
@@ -41887,7 +41894,6 @@ function StepWizard({
41887
41894
 
41888
41895
  // src/components/ui/pill-toggle/index.tsx
41889
41896
  var import_jsx_runtime129 = require("react/jsx-runtime");
41890
- var STYLE_ID6 = "dll-pill-toggle-styles";
41891
41897
  var PILL_TOGGLE_CSS = `
41892
41898
  .pt-root {
41893
41899
  --pt-accent: var(--primary, #3b82f6);
@@ -41936,16 +41942,7 @@ var PILL_TOGGLE_CSS = `
41936
41942
  line-height: 1;
41937
41943
  }
41938
41944
  `;
41939
- function ensureStylesInjected6() {
41940
- if (typeof document === "undefined") return;
41941
- if (document.getElementById(STYLE_ID6)) return;
41942
- const el = document.createElement("style");
41943
- el.id = STYLE_ID6;
41944
- el.textContent = PILL_TOGGLE_CSS;
41945
- document.head.appendChild(el);
41946
- }
41947
41945
  function PillToggle(props) {
41948
- ensureStylesInjected6();
41949
41946
  const { options, ariaLabel, className = "" } = props;
41950
41947
  const isActive = (value) => {
41951
41948
  if (props.multi) return props.value.includes(value);
@@ -41965,31 +41962,34 @@ function PillToggle(props) {
41965
41962
  }
41966
41963
  props.onChange(value);
41967
41964
  };
41968
- return /* @__PURE__ */ (0, import_jsx_runtime129.jsx)(
41965
+ return /* @__PURE__ */ (0, import_jsx_runtime129.jsxs)(
41969
41966
  "div",
41970
41967
  {
41971
41968
  role: props.multi ? "group" : "radiogroup",
41972
41969
  "aria-label": ariaLabel,
41973
41970
  className: `pt-root ${className}`.trim(),
41974
- children: options.map((opt) => {
41975
- const active = isActive(opt.value);
41976
- return /* @__PURE__ */ (0, import_jsx_runtime129.jsxs)(
41977
- "button",
41978
- {
41979
- type: "button",
41980
- className: "pt-pill",
41981
- "data-active": active,
41982
- onClick: () => handleToggle(opt.value),
41983
- role: props.multi ? "checkbox" : "radio",
41984
- "aria-checked": active,
41985
- children: [
41986
- opt.icon && /* @__PURE__ */ (0, import_jsx_runtime129.jsx)("span", { className: "pt-icon", children: opt.icon }),
41987
- /* @__PURE__ */ (0, import_jsx_runtime129.jsx)("span", { children: opt.label })
41988
- ]
41989
- },
41990
- opt.value
41991
- );
41992
- })
41971
+ children: [
41972
+ /* @__PURE__ */ (0, import_jsx_runtime129.jsx)("style", { href: "dll-pill-toggle-styles", precedence: "default", children: PILL_TOGGLE_CSS }),
41973
+ options.map((opt) => {
41974
+ const active = isActive(opt.value);
41975
+ return /* @__PURE__ */ (0, import_jsx_runtime129.jsxs)(
41976
+ "button",
41977
+ {
41978
+ type: "button",
41979
+ className: "pt-pill",
41980
+ "data-active": active,
41981
+ onClick: () => handleToggle(opt.value),
41982
+ role: props.multi ? "checkbox" : "radio",
41983
+ "aria-checked": active,
41984
+ children: [
41985
+ opt.icon && /* @__PURE__ */ (0, import_jsx_runtime129.jsx)("span", { className: "pt-icon", children: opt.icon }),
41986
+ /* @__PURE__ */ (0, import_jsx_runtime129.jsx)("span", { children: opt.label })
41987
+ ]
41988
+ },
41989
+ opt.value
41990
+ );
41991
+ })
41992
+ ]
41993
41993
  }
41994
41994
  );
41995
41995
  }
@@ -41997,7 +41997,6 @@ function PillToggle(props) {
41997
41997
  // src/components/ui/tag-input/index.tsx
41998
41998
  var import_react80 = require("react");
41999
41999
  var import_jsx_runtime130 = require("react/jsx-runtime");
42000
- var STYLE_ID7 = "dll-tag-input-styles";
42001
42000
  var TAG_INPUT_CSS = `
42002
42001
  .ti-root {
42003
42002
  --ti-accent: var(--primary, #3b82f6);
@@ -42106,14 +42105,6 @@ var TAG_INPUT_CSS = `
42106
42105
  font-variant-numeric: tabular-nums;
42107
42106
  }
42108
42107
  `;
42109
- function ensureStylesInjected7() {
42110
- if (typeof document === "undefined") return;
42111
- if (document.getElementById(STYLE_ID7)) return;
42112
- const el = document.createElement("style");
42113
- el.id = STYLE_ID7;
42114
- el.textContent = TAG_INPUT_CSS;
42115
- document.head.appendChild(el);
42116
- }
42117
42108
  var defaultNormalize = (raw) => {
42118
42109
  const trimmed = raw.trim();
42119
42110
  if (!trimmed) return "";
@@ -42133,7 +42124,6 @@ function TagInput({
42133
42124
  onInputChange,
42134
42125
  className = ""
42135
42126
  }) {
42136
- ensureStylesInjected7();
42137
42127
  const [internalInput, setInternalInput] = (0, import_react80.useState)("");
42138
42128
  const isControlled = inputValue !== void 0;
42139
42129
  const input = isControlled ? inputValue : internalInput;
@@ -42181,6 +42171,7 @@ function TagInput({
42181
42171
  if (filteredSuggestions.length >= maxVisibleSuggestions) break;
42182
42172
  }
42183
42173
  return /* @__PURE__ */ (0, import_jsx_runtime130.jsxs)("div", { className: `ti-root ${className}`.trim(), children: [
42174
+ /* @__PURE__ */ (0, import_jsx_runtime130.jsx)("style", { href: "dll-tag-input-styles", precedence: "default", children: TAG_INPUT_CSS }),
42184
42175
  /* @__PURE__ */ (0, import_jsx_runtime130.jsxs)("div", { className: "ti-row", children: [
42185
42176
  /* @__PURE__ */ (0, import_jsx_runtime130.jsx)(
42186
42177
  "input",
@@ -42248,7 +42239,7 @@ function TagInput({
42248
42239
  // src/components/ui/sectioned-list-editor/index.tsx
42249
42240
  var import_react81 = require("react");
42250
42241
  var import_jsx_runtime131 = require("react/jsx-runtime");
42251
- var STYLE_ID8 = "dll-sectioned-list-editor-styles";
42242
+ var STYLE_ID2 = "dll-sectioned-list-editor-styles";
42252
42243
  var SECTIONED_LIST_CSS = `
42253
42244
  .sle-root {
42254
42245
  --sle-accent: var(--primary, #3b82f6);
@@ -42461,11 +42452,11 @@ var SECTIONED_LIST_CSS = `
42461
42452
  font-variant-numeric: tabular-nums;
42462
42453
  }
42463
42454
  `;
42464
- function ensureStylesInjected8() {
42455
+ function ensureStylesInjected2() {
42465
42456
  if (typeof document === "undefined") return;
42466
- if (document.getElementById(STYLE_ID8)) return;
42457
+ if (document.getElementById(STYLE_ID2)) return;
42467
42458
  const el = document.createElement("style");
42468
- el.id = STYLE_ID8;
42459
+ el.id = STYLE_ID2;
42469
42460
  el.textContent = SECTIONED_LIST_CSS;
42470
42461
  document.head.appendChild(el);
42471
42462
  }
@@ -42479,7 +42470,7 @@ function SectionedListEditor({
42479
42470
  renderSummary,
42480
42471
  className = ""
42481
42472
  }) {
42482
- ensureStylesInjected8();
42473
+ ensureStylesInjected2();
42483
42474
  const [activeKey, setActiveKey] = (0, import_react81.useState)(sections[0]?.key ?? "");
42484
42475
  const [input, setInput] = (0, import_react81.useState)("");
42485
42476
  const [customName, setCustomName] = (0, import_react81.useState)("");