@inploi/plugin-feedback 6.0.0 → 6.1.0

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.
@@ -1923,10 +1923,6 @@ const oppositeSideMap = {
1923
1923
  bottom: "top",
1924
1924
  top: "bottom"
1925
1925
  };
1926
- const oppositeAlignmentMap = {
1927
- start: "end",
1928
- end: "start"
1929
- };
1930
1926
  function clamp(start, value, end) {
1931
1927
  return max(start, min(value, end));
1932
1928
  }
@@ -1945,9 +1941,9 @@ function getOppositeAxis(axis) {
1945
1941
  function getAxisLength(axis) {
1946
1942
  return axis === "y" ? "height" : "width";
1947
1943
  }
1948
- const yAxisSides = /* @__PURE__ */ new Set(["top", "bottom"]);
1949
1944
  function getSideAxis(placement) {
1950
- return yAxisSides.has(getSide(placement)) ? "y" : "x";
1945
+ const firstChar = placement[0];
1946
+ return firstChar === "t" || firstChar === "b" ? "y" : "x";
1951
1947
  }
1952
1948
  function getAlignmentAxis(placement) {
1953
1949
  return getOppositeAxis(getSideAxis(placement));
@@ -1970,7 +1966,7 @@ function getExpandedPlacements(placement) {
1970
1966
  return [getOppositeAlignmentPlacement(placement), oppositePlacement, getOppositeAlignmentPlacement(oppositePlacement)];
1971
1967
  }
1972
1968
  function getOppositeAlignmentPlacement(placement) {
1973
- return placement.replace(/start|end/g, (alignment) => oppositeAlignmentMap[alignment]);
1969
+ return placement.includes("start") ? placement.replace("start", "end") : placement.replace("end", "start");
1974
1970
  }
1975
1971
  const lrPlacement = ["left", "right"];
1976
1972
  const rlPlacement = ["right", "left"];
@@ -2002,7 +1998,8 @@ function getOppositeAxisPlacements(placement, flipAlignment, direction, rtl) {
2002
1998
  return list;
2003
1999
  }
2004
2000
  function getOppositePlacement(placement) {
2005
- return placement.replace(/left|right|bottom|top/g, (side) => oppositeSideMap[side]);
2001
+ const side = getSide(placement);
2002
+ return oppositeSideMap[side] + placement.slice(side.length);
2006
2003
  }
2007
2004
  function expandPaddingObject(padding) {
2008
2005
  return {
@@ -2094,6 +2091,63 @@ function computeCoordsFromPlacement(_ref, placement, rtl) {
2094
2091
  }
2095
2092
  return coords;
2096
2093
  }
2094
+ async function detectOverflow(state, options2) {
2095
+ var _await$platform$isEle;
2096
+ if (options2 === void 0) {
2097
+ options2 = {};
2098
+ }
2099
+ const {
2100
+ x: x2,
2101
+ y: y2,
2102
+ platform: platform2,
2103
+ rects,
2104
+ elements,
2105
+ strategy
2106
+ } = state;
2107
+ const {
2108
+ boundary = "clippingAncestors",
2109
+ rootBoundary = "viewport",
2110
+ elementContext = "floating",
2111
+ altBoundary = false,
2112
+ padding = 0
2113
+ } = evaluate(options2, state);
2114
+ const paddingObject = getPaddingObject(padding);
2115
+ const altContext = elementContext === "floating" ? "reference" : "floating";
2116
+ const element = elements[altBoundary ? altContext : elementContext];
2117
+ const clippingClientRect = rectToClientRect(await platform2.getClippingRect({
2118
+ element: ((_await$platform$isEle = await (platform2.isElement == null ? void 0 : platform2.isElement(element))) != null ? _await$platform$isEle : true) ? element : element.contextElement || await (platform2.getDocumentElement == null ? void 0 : platform2.getDocumentElement(elements.floating)),
2119
+ boundary,
2120
+ rootBoundary,
2121
+ strategy
2122
+ }));
2123
+ const rect = elementContext === "floating" ? {
2124
+ x: x2,
2125
+ y: y2,
2126
+ width: rects.floating.width,
2127
+ height: rects.floating.height
2128
+ } : rects.reference;
2129
+ const offsetParent = await (platform2.getOffsetParent == null ? void 0 : platform2.getOffsetParent(elements.floating));
2130
+ const offsetScale = await (platform2.isElement == null ? void 0 : platform2.isElement(offsetParent)) ? await (platform2.getScale == null ? void 0 : platform2.getScale(offsetParent)) || {
2131
+ x: 1,
2132
+ y: 1
2133
+ } : {
2134
+ x: 1,
2135
+ y: 1
2136
+ };
2137
+ const elementClientRect = rectToClientRect(platform2.convertOffsetParentRelativeRectToViewportRelativeRect ? await platform2.convertOffsetParentRelativeRectToViewportRelativeRect({
2138
+ elements,
2139
+ rect,
2140
+ offsetParent,
2141
+ strategy
2142
+ }) : rect);
2143
+ return {
2144
+ top: (clippingClientRect.top - elementClientRect.top + paddingObject.top) / offsetScale.y,
2145
+ bottom: (elementClientRect.bottom - clippingClientRect.bottom + paddingObject.bottom) / offsetScale.y,
2146
+ left: (clippingClientRect.left - elementClientRect.left + paddingObject.left) / offsetScale.x,
2147
+ right: (elementClientRect.right - clippingClientRect.right + paddingObject.right) / offsetScale.x
2148
+ };
2149
+ }
2150
+ const MAX_RESET_COUNT = 50;
2097
2151
  const computePosition$1 = async (reference, floating, config) => {
2098
2152
  const {
2099
2153
  placement = "bottom",
@@ -2101,7 +2155,10 @@ const computePosition$1 = async (reference, floating, config) => {
2101
2155
  middleware = [],
2102
2156
  platform: platform2
2103
2157
  } = config;
2104
- const validMiddleware = middleware.filter(Boolean);
2158
+ const platformWithDetectOverflow = platform2.detectOverflow ? platform2 : {
2159
+ ...platform2,
2160
+ detectOverflow
2161
+ };
2105
2162
  const rtl = await (platform2.isRTL == null ? void 0 : platform2.isRTL(floating));
2106
2163
  let rects = await platform2.getElementRects({
2107
2164
  reference,
@@ -2113,13 +2170,17 @@ const computePosition$1 = async (reference, floating, config) => {
2113
2170
  y: y2
2114
2171
  } = computeCoordsFromPlacement(rects, placement, rtl);
2115
2172
  let statefulPlacement = placement;
2116
- let middlewareData = {};
2117
2173
  let resetCount = 0;
2118
- for (let i2 = 0; i2 < validMiddleware.length; i2++) {
2174
+ const middlewareData = {};
2175
+ for (let i2 = 0; i2 < middleware.length; i2++) {
2176
+ const currentMiddleware = middleware[i2];
2177
+ if (!currentMiddleware) {
2178
+ continue;
2179
+ }
2119
2180
  const {
2120
2181
  name,
2121
2182
  fn: fn2
2122
- } = validMiddleware[i2];
2183
+ } = currentMiddleware;
2123
2184
  const {
2124
2185
  x: nextX,
2125
2186
  y: nextY,
@@ -2133,7 +2194,7 @@ const computePosition$1 = async (reference, floating, config) => {
2133
2194
  strategy,
2134
2195
  middlewareData,
2135
2196
  rects,
2136
- platform: platform2,
2197
+ platform: platformWithDetectOverflow,
2137
2198
  elements: {
2138
2199
  reference,
2139
2200
  floating
@@ -2141,14 +2202,11 @@ const computePosition$1 = async (reference, floating, config) => {
2141
2202
  });
2142
2203
  x2 = nextX != null ? nextX : x2;
2143
2204
  y2 = nextY != null ? nextY : y2;
2144
- middlewareData = {
2145
- ...middlewareData,
2146
- [name]: {
2147
- ...middlewareData[name],
2148
- ...data
2149
- }
2205
+ middlewareData[name] = {
2206
+ ...middlewareData[name],
2207
+ ...data
2150
2208
  };
2151
- if (reset && resetCount <= 50) {
2209
+ if (reset && resetCount < MAX_RESET_COUNT) {
2152
2210
  resetCount++;
2153
2211
  if (typeof reset === "object") {
2154
2212
  if (reset.placement) {
@@ -2177,62 +2235,6 @@ const computePosition$1 = async (reference, floating, config) => {
2177
2235
  middlewareData
2178
2236
  };
2179
2237
  };
2180
- async function detectOverflow(state, options2) {
2181
- var _await$platform$isEle;
2182
- if (options2 === void 0) {
2183
- options2 = {};
2184
- }
2185
- const {
2186
- x: x2,
2187
- y: y2,
2188
- platform: platform2,
2189
- rects,
2190
- elements,
2191
- strategy
2192
- } = state;
2193
- const {
2194
- boundary = "clippingAncestors",
2195
- rootBoundary = "viewport",
2196
- elementContext = "floating",
2197
- altBoundary = false,
2198
- padding = 0
2199
- } = evaluate(options2, state);
2200
- const paddingObject = getPaddingObject(padding);
2201
- const altContext = elementContext === "floating" ? "reference" : "floating";
2202
- const element = elements[altBoundary ? altContext : elementContext];
2203
- const clippingClientRect = rectToClientRect(await platform2.getClippingRect({
2204
- element: ((_await$platform$isEle = await (platform2.isElement == null ? void 0 : platform2.isElement(element))) != null ? _await$platform$isEle : true) ? element : element.contextElement || await (platform2.getDocumentElement == null ? void 0 : platform2.getDocumentElement(elements.floating)),
2205
- boundary,
2206
- rootBoundary,
2207
- strategy
2208
- }));
2209
- const rect = elementContext === "floating" ? {
2210
- x: x2,
2211
- y: y2,
2212
- width: rects.floating.width,
2213
- height: rects.floating.height
2214
- } : rects.reference;
2215
- const offsetParent = await (platform2.getOffsetParent == null ? void 0 : platform2.getOffsetParent(elements.floating));
2216
- const offsetScale = await (platform2.isElement == null ? void 0 : platform2.isElement(offsetParent)) ? await (platform2.getScale == null ? void 0 : platform2.getScale(offsetParent)) || {
2217
- x: 1,
2218
- y: 1
2219
- } : {
2220
- x: 1,
2221
- y: 1
2222
- };
2223
- const elementClientRect = rectToClientRect(platform2.convertOffsetParentRelativeRectToViewportRelativeRect ? await platform2.convertOffsetParentRelativeRectToViewportRelativeRect({
2224
- elements,
2225
- rect,
2226
- offsetParent,
2227
- strategy
2228
- }) : rect);
2229
- return {
2230
- top: (clippingClientRect.top - elementClientRect.top + paddingObject.top) / offsetScale.y,
2231
- bottom: (elementClientRect.bottom - clippingClientRect.bottom + paddingObject.bottom) / offsetScale.y,
2232
- left: (clippingClientRect.left - elementClientRect.left + paddingObject.left) / offsetScale.x,
2233
- right: (elementClientRect.right - clippingClientRect.right + paddingObject.right) / offsetScale.x
2234
- };
2235
- }
2236
2238
  const arrow$3 = (options2) => ({
2237
2239
  name: "arrow",
2238
2240
  options: options2,
@@ -2334,7 +2336,7 @@ const flip$2 = function(options2) {
2334
2336
  fallbackPlacements.push(...getOppositeAxisPlacements(initialPlacement, flipAlignment, fallbackAxisSideDirection, rtl));
2335
2337
  }
2336
2338
  const placements = [initialPlacement, ...fallbackPlacements];
2337
- const overflow = await detectOverflow(state, detectOverflowOptions);
2339
+ const overflow = await platform2.detectOverflow(state, detectOverflowOptions);
2338
2340
  const overflows = [];
2339
2341
  let overflowsData = ((_middlewareData$flip = middlewareData.flip) == null ? void 0 : _middlewareData$flip.overflows) || [];
2340
2342
  if (checkMainAxis) {
@@ -2353,15 +2355,20 @@ const flip$2 = function(options2) {
2353
2355
  const nextIndex = (((_middlewareData$flip2 = middlewareData.flip) == null ? void 0 : _middlewareData$flip2.index) || 0) + 1;
2354
2356
  const nextPlacement = placements[nextIndex];
2355
2357
  if (nextPlacement) {
2356
- return {
2357
- data: {
2358
- index: nextIndex,
2359
- overflows: overflowsData
2360
- },
2361
- reset: {
2362
- placement: nextPlacement
2363
- }
2364
- };
2358
+ const ignoreCrossAxisOverflow = checkCrossAxis === "alignment" ? initialSideAxis !== getSideAxis(nextPlacement) : false;
2359
+ if (!ignoreCrossAxisOverflow || // We leave the current main axis only if every placement on that axis
2360
+ // overflows the main axis.
2361
+ overflowsData.every((d2) => getSideAxis(d2.placement) === initialSideAxis ? d2.overflows[0] > 0 : true)) {
2362
+ return {
2363
+ data: {
2364
+ index: nextIndex,
2365
+ overflows: overflowsData
2366
+ },
2367
+ reset: {
2368
+ placement: nextPlacement
2369
+ }
2370
+ };
2371
+ }
2365
2372
  }
2366
2373
  let resetPlacement = (_overflowsData$filter = overflowsData.filter((d2) => d2.overflows[0] <= 0).sort((a2, b2) => a2.overflows[1] - b2.overflows[1])[0]) == null ? void 0 : _overflowsData$filter.placement;
2367
2374
  if (!resetPlacement) {
@@ -2419,7 +2426,8 @@ const hide$2 = function(options2) {
2419
2426
  options: options2,
2420
2427
  async fn(state) {
2421
2428
  const {
2422
- rects
2429
+ rects,
2430
+ platform: platform2
2423
2431
  } = state;
2424
2432
  const {
2425
2433
  strategy = "referenceHidden",
@@ -2427,7 +2435,7 @@ const hide$2 = function(options2) {
2427
2435
  } = evaluate(options2, state);
2428
2436
  switch (strategy) {
2429
2437
  case "referenceHidden": {
2430
- const overflow = await detectOverflow(state, {
2438
+ const overflow = await platform2.detectOverflow(state, {
2431
2439
  ...detectOverflowOptions,
2432
2440
  elementContext: "reference"
2433
2441
  });
@@ -2440,7 +2448,7 @@ const hide$2 = function(options2) {
2440
2448
  };
2441
2449
  }
2442
2450
  case "escaped": {
2443
- const overflow = await detectOverflow(state, {
2451
+ const overflow = await platform2.detectOverflow(state, {
2444
2452
  ...detectOverflowOptions,
2445
2453
  altBoundary: true
2446
2454
  });
@@ -2459,6 +2467,7 @@ const hide$2 = function(options2) {
2459
2467
  }
2460
2468
  };
2461
2469
  };
2470
+ const originSides = /* @__PURE__ */ new Set(["left", "top"]);
2462
2471
  async function convertValueToCoords(state, options2) {
2463
2472
  const {
2464
2473
  placement,
@@ -2469,7 +2478,7 @@ async function convertValueToCoords(state, options2) {
2469
2478
  const side = getSide(placement);
2470
2479
  const alignment = getAlignment(placement);
2471
2480
  const isVertical = getSideAxis(placement) === "y";
2472
- const mainAxisMulti = ["left", "top"].includes(side) ? -1 : 1;
2481
+ const mainAxisMulti = originSides.has(side) ? -1 : 1;
2473
2482
  const crossAxisMulti = rtl && isVertical ? -1 : 1;
2474
2483
  const rawValue = evaluate(options2, state);
2475
2484
  let {
@@ -2481,10 +2490,9 @@ async function convertValueToCoords(state, options2) {
2481
2490
  crossAxis: 0,
2482
2491
  alignmentAxis: null
2483
2492
  } : {
2484
- mainAxis: 0,
2485
- crossAxis: 0,
2486
- alignmentAxis: null,
2487
- ...rawValue
2493
+ mainAxis: rawValue.mainAxis || 0,
2494
+ crossAxis: rawValue.crossAxis || 0,
2495
+ alignmentAxis: rawValue.alignmentAxis
2488
2496
  };
2489
2497
  if (alignment && typeof alignmentAxis === "number") {
2490
2498
  crossAxis = alignment === "end" ? alignmentAxis * -1 : alignmentAxis;
@@ -2538,7 +2546,8 @@ const shift$2 = function(options2) {
2538
2546
  const {
2539
2547
  x: x2,
2540
2548
  y: y2,
2541
- placement
2549
+ placement,
2550
+ platform: platform2
2542
2551
  } = state;
2543
2552
  const {
2544
2553
  mainAxis: checkMainAxis = true,
@@ -2561,7 +2570,7 @@ const shift$2 = function(options2) {
2561
2570
  x: x2,
2562
2571
  y: y2
2563
2572
  };
2564
- const overflow = await detectOverflow(state, detectOverflowOptions);
2573
+ const overflow = await platform2.detectOverflow(state, detectOverflowOptions);
2565
2574
  const crossAxis = getSideAxis(getSide(placement));
2566
2575
  const mainAxis = getOppositeAxis(crossAxis);
2567
2576
  let mainAxisCoord = coords[mainAxis];
@@ -2589,7 +2598,11 @@ const shift$2 = function(options2) {
2589
2598
  ...limitedCoords,
2590
2599
  data: {
2591
2600
  x: limitedCoords.x - x2,
2592
- y: limitedCoords.y - y2
2601
+ y: limitedCoords.y - y2,
2602
+ enabled: {
2603
+ [mainAxis]: checkMainAxis,
2604
+ [crossAxis]: checkCrossAxis
2605
+ }
2593
2606
  }
2594
2607
  };
2595
2608
  }
@@ -2644,7 +2657,7 @@ const limitShift$2 = function(options2) {
2644
2657
  if (checkCrossAxis) {
2645
2658
  var _middlewareData$offse, _middlewareData$offse2;
2646
2659
  const len = mainAxis === "y" ? "width" : "height";
2647
- const isOriginSide = ["top", "left"].includes(getSide(placement));
2660
+ const isOriginSide = originSides.has(getSide(placement));
2648
2661
  const limitMin = rects.reference[crossAxis] - rects.floating[len] + (isOriginSide ? ((_middlewareData$offse = middlewareData.offset) == null ? void 0 : _middlewareData$offse[crossAxis]) || 0 : 0) + (isOriginSide ? 0 : computedOffset.crossAxis);
2649
2662
  const limitMax = rects.reference[crossAxis] + rects.reference[len] + (isOriginSide ? 0 : ((_middlewareData$offse2 = middlewareData.offset) == null ? void 0 : _middlewareData$offse2[crossAxis]) || 0) - (isOriginSide ? computedOffset.crossAxis : 0);
2650
2663
  if (crossAxisCoord < limitMin) {
@@ -2668,6 +2681,7 @@ const size$2 = function(options2) {
2668
2681
  name: "size",
2669
2682
  options: options2,
2670
2683
  async fn(state) {
2684
+ var _state$middlewareData, _state$middlewareData2;
2671
2685
  const {
2672
2686
  placement,
2673
2687
  rects,
@@ -2679,7 +2693,7 @@ const size$2 = function(options2) {
2679
2693
  },
2680
2694
  ...detectOverflowOptions
2681
2695
  } = evaluate(options2, state);
2682
- const overflow = await detectOverflow(state, detectOverflowOptions);
2696
+ const overflow = await platform2.detectOverflow(state, detectOverflowOptions);
2683
2697
  const side = getSide(placement);
2684
2698
  const alignment = getAlignment(placement);
2685
2699
  const isYAxis = getSideAxis(placement) === "y";
@@ -2703,10 +2717,11 @@ const size$2 = function(options2) {
2703
2717
  const noShift = !state.middlewareData.shift;
2704
2718
  let availableHeight = overflowAvailableHeight;
2705
2719
  let availableWidth = overflowAvailableWidth;
2706
- if (isYAxis) {
2707
- availableWidth = alignment || noShift ? min(overflowAvailableWidth, maximumClippingWidth) : maximumClippingWidth;
2708
- } else {
2709
- availableHeight = alignment || noShift ? min(overflowAvailableHeight, maximumClippingHeight) : maximumClippingHeight;
2720
+ if ((_state$middlewareData = state.middlewareData.shift) != null && _state$middlewareData.enabled.x) {
2721
+ availableWidth = maximumClippingWidth;
2722
+ }
2723
+ if ((_state$middlewareData2 = state.middlewareData.shift) != null && _state$middlewareData2.enabled.y) {
2724
+ availableHeight = maximumClippingHeight;
2710
2725
  }
2711
2726
  if (noShift && !alignment) {
2712
2727
  const xMin = max(overflow.left, 0);
@@ -2777,7 +2792,6 @@ function isShadowRoot(value) {
2777
2792
  }
2778
2793
  return value instanceof ShadowRoot || value instanceof getWindow(value).ShadowRoot;
2779
2794
  }
2780
- const invalidOverflowDisplayValues = /* @__PURE__ */ new Set(["inline", "contents"]);
2781
2795
  function isOverflowElement(element) {
2782
2796
  const {
2783
2797
  overflow,
@@ -2785,29 +2799,31 @@ function isOverflowElement(element) {
2785
2799
  overflowY,
2786
2800
  display
2787
2801
  } = getComputedStyle$1(element);
2788
- return /auto|scroll|overlay|hidden|clip/.test(overflow + overflowY + overflowX) && !invalidOverflowDisplayValues.has(display);
2802
+ return /auto|scroll|overlay|hidden|clip/.test(overflow + overflowY + overflowX) && display !== "inline" && display !== "contents";
2789
2803
  }
2790
- const tableElements = /* @__PURE__ */ new Set(["table", "td", "th"]);
2791
2804
  function isTableElement(element) {
2792
- return tableElements.has(getNodeName(element));
2805
+ return /^(table|td|th)$/.test(getNodeName(element));
2793
2806
  }
2794
- const topLayerSelectors = [":popover-open", ":modal"];
2795
2807
  function isTopLayer(element) {
2796
- return topLayerSelectors.some((selector) => {
2797
- try {
2798
- return element.matches(selector);
2799
- } catch (_e) {
2800
- return false;
2808
+ try {
2809
+ if (element.matches(":popover-open")) {
2810
+ return true;
2801
2811
  }
2802
- });
2812
+ } catch (_e) {
2813
+ }
2814
+ try {
2815
+ return element.matches(":modal");
2816
+ } catch (_e) {
2817
+ return false;
2818
+ }
2803
2819
  }
2804
- const transformProperties = ["transform", "translate", "scale", "rotate", "perspective"];
2805
- const willChangeValues = ["transform", "translate", "scale", "rotate", "perspective", "filter"];
2806
- const containValues = ["paint", "layout", "strict", "content"];
2820
+ const willChangeRe = /transform|translate|scale|rotate|perspective|filter/;
2821
+ const containRe = /paint|layout|strict|content/;
2822
+ const isNotNone = (value) => !!value && value !== "none";
2823
+ let isWebKitValue;
2807
2824
  function isContainingBlock(elementOrCss) {
2808
- const webkit = isWebKit();
2809
2825
  const css = isElement(elementOrCss) ? getComputedStyle$1(elementOrCss) : elementOrCss;
2810
- return transformProperties.some((value) => css[value] ? css[value] !== "none" : false) || (css.containerType ? css.containerType !== "normal" : false) || !webkit && (css.backdropFilter ? css.backdropFilter !== "none" : false) || !webkit && (css.filter ? css.filter !== "none" : false) || willChangeValues.some((value) => (css.willChange || "").includes(value)) || containValues.some((value) => (css.contain || "").includes(value));
2826
+ return isNotNone(css.transform) || isNotNone(css.translate) || isNotNone(css.scale) || isNotNone(css.rotate) || isNotNone(css.perspective) || !isWebKit() && (isNotNone(css.backdropFilter) || isNotNone(css.filter)) || willChangeRe.test(css.willChange || "") || containRe.test(css.contain || "");
2811
2827
  }
2812
2828
  function getContainingBlock(element) {
2813
2829
  let currentNode = getParentNode(element);
@@ -2822,13 +2838,13 @@ function getContainingBlock(element) {
2822
2838
  return null;
2823
2839
  }
2824
2840
  function isWebKit() {
2825
- if (typeof CSS === "undefined" || !CSS.supports)
2826
- return false;
2827
- return CSS.supports("-webkit-backdrop-filter", "none");
2841
+ if (isWebKitValue == null) {
2842
+ isWebKitValue = typeof CSS !== "undefined" && CSS.supports && CSS.supports("-webkit-backdrop-filter", "none");
2843
+ }
2844
+ return isWebKitValue;
2828
2845
  }
2829
- const lastTraversableNodeNames = /* @__PURE__ */ new Set(["html", "body", "#document"]);
2830
2846
  function isLastTraversableNode(node) {
2831
- return lastTraversableNodeNames.has(getNodeName(node));
2847
+ return /^(html|body|#document)$/.test(getNodeName(node));
2832
2848
  }
2833
2849
  function getComputedStyle$1(element) {
2834
2850
  return getWindow(element).getComputedStyle(element);
@@ -2882,8 +2898,9 @@ function getOverflowAncestors(node, list, traverseIframes) {
2882
2898
  if (isBody) {
2883
2899
  const frameElement = getFrameElement(win);
2884
2900
  return list.concat(win, win.visualViewport || [], isOverflowElement(scrollableAncestor) ? scrollableAncestor : [], frameElement && traverseIframes ? getOverflowAncestors(frameElement) : []);
2901
+ } else {
2902
+ return list.concat(scrollableAncestor, getOverflowAncestors(scrollableAncestor, [], traverseIframes));
2885
2903
  }
2886
- return list.concat(scrollableAncestor, getOverflowAncestors(scrollableAncestor, [], traverseIframes));
2887
2904
  }
2888
2905
  function getFrameElement(win) {
2889
2906
  return win.parent && Object.getPrototypeOf(win.parent) ? win.frameElement : null;
@@ -3005,6 +3022,22 @@ function getBoundingClientRect(element, includeScale, isFixedStrategy, offsetPar
3005
3022
  y: y2
3006
3023
  });
3007
3024
  }
3025
+ function getWindowScrollBarX(element, rect) {
3026
+ const leftScroll = getNodeScroll(element).scrollLeft;
3027
+ if (!rect) {
3028
+ return getBoundingClientRect(getDocumentElement(element)).left + leftScroll;
3029
+ }
3030
+ return rect.left + leftScroll;
3031
+ }
3032
+ function getHTMLOffset(documentElement, scroll) {
3033
+ const htmlRect = documentElement.getBoundingClientRect();
3034
+ const x2 = htmlRect.left + scroll.scrollLeft - getWindowScrollBarX(documentElement, htmlRect);
3035
+ const y2 = htmlRect.top + scroll.scrollTop;
3036
+ return {
3037
+ x: x2,
3038
+ y: y2
3039
+ };
3040
+ }
3008
3041
  function convertOffsetParentRelativeRectToViewportRelativeRect(_ref) {
3009
3042
  let {
3010
3043
  elements,
@@ -3029,26 +3062,24 @@ function convertOffsetParentRelativeRectToViewportRelativeRect(_ref) {
3029
3062
  if (getNodeName(offsetParent) !== "body" || isOverflowElement(documentElement)) {
3030
3063
  scroll = getNodeScroll(offsetParent);
3031
3064
  }
3032
- if (isHTMLElement(offsetParent)) {
3065
+ if (isOffsetParentAnElement) {
3033
3066
  const offsetRect = getBoundingClientRect(offsetParent);
3034
3067
  scale = getScale(offsetParent);
3035
3068
  offsets.x = offsetRect.x + offsetParent.clientLeft;
3036
3069
  offsets.y = offsetRect.y + offsetParent.clientTop;
3037
3070
  }
3038
3071
  }
3072
+ const htmlOffset = documentElement && !isOffsetParentAnElement && !isFixed ? getHTMLOffset(documentElement, scroll) : createCoords(0);
3039
3073
  return {
3040
3074
  width: rect.width * scale.x,
3041
3075
  height: rect.height * scale.y,
3042
- x: rect.x * scale.x - scroll.scrollLeft * scale.x + offsets.x,
3043
- y: rect.y * scale.y - scroll.scrollTop * scale.y + offsets.y
3076
+ x: rect.x * scale.x - scroll.scrollLeft * scale.x + offsets.x + htmlOffset.x,
3077
+ y: rect.y * scale.y - scroll.scrollTop * scale.y + offsets.y + htmlOffset.y
3044
3078
  };
3045
3079
  }
3046
3080
  function getClientRects(element) {
3047
3081
  return Array.from(element.getClientRects());
3048
3082
  }
3049
- function getWindowScrollBarX(element) {
3050
- return getBoundingClientRect(getDocumentElement(element)).left + getNodeScroll(element).scrollLeft;
3051
- }
3052
3083
  function getDocumentRect(element) {
3053
3084
  const html = getDocumentElement(element);
3054
3085
  const scroll = getNodeScroll(element);
@@ -3067,6 +3098,7 @@ function getDocumentRect(element) {
3067
3098
  y: y2
3068
3099
  };
3069
3100
  }
3101
+ const SCROLLBAR_MAX = 25;
3070
3102
  function getViewportRect(element, strategy) {
3071
3103
  const win = getWindow(element);
3072
3104
  const html = getDocumentElement(element);
@@ -3084,6 +3116,19 @@ function getViewportRect(element, strategy) {
3084
3116
  y2 = visualViewport.offsetTop;
3085
3117
  }
3086
3118
  }
3119
+ const windowScrollbarX = getWindowScrollBarX(html);
3120
+ if (windowScrollbarX <= 0) {
3121
+ const doc = html.ownerDocument;
3122
+ const body = doc.body;
3123
+ const bodyStyles = getComputedStyle(body);
3124
+ const bodyMarginInline = doc.compatMode === "CSS1Compat" ? parseFloat(bodyStyles.marginLeft) + parseFloat(bodyStyles.marginRight) || 0 : 0;
3125
+ const clippingStableScrollbarWidth = Math.abs(html.clientWidth - body.clientWidth - bodyMarginInline);
3126
+ if (clippingStableScrollbarWidth <= SCROLLBAR_MAX) {
3127
+ width -= clippingStableScrollbarWidth;
3128
+ }
3129
+ } else if (windowScrollbarX <= SCROLLBAR_MAX) {
3130
+ width += windowScrollbarX;
3131
+ }
3087
3132
  return {
3088
3133
  width,
3089
3134
  height,
@@ -3118,9 +3163,10 @@ function getClientRectFromClippingAncestor(element, clippingAncestor, strategy)
3118
3163
  } else {
3119
3164
  const visualOffsets = getVisualOffsets(element);
3120
3165
  rect = {
3121
- ...clippingAncestor,
3122
3166
  x: clippingAncestor.x - visualOffsets.x,
3123
- y: clippingAncestor.y - visualOffsets.y
3167
+ y: clippingAncestor.y - visualOffsets.y,
3168
+ width: clippingAncestor.width,
3169
+ height: clippingAncestor.height
3124
3170
  };
3125
3171
  }
3126
3172
  return rectToClientRect(rect);
@@ -3147,7 +3193,7 @@ function getClippingElementAncestors(element, cache) {
3147
3193
  if (!currentNodeIsContaining && computedStyle.position === "fixed") {
3148
3194
  currentContainingBlockComputedStyle = null;
3149
3195
  }
3150
- const shouldDropCurrentNode = elementIsFixed ? !currentNodeIsContaining && !currentContainingBlockComputedStyle : !currentNodeIsContaining && computedStyle.position === "static" && !!currentContainingBlockComputedStyle && ["absolute", "fixed"].includes(currentContainingBlockComputedStyle.position) || isOverflowElement(currentNode) && !currentNodeIsContaining && hasFixedPositionAncestor(element, currentNode);
3196
+ const shouldDropCurrentNode = elementIsFixed ? !currentNodeIsContaining && !currentContainingBlockComputedStyle : !currentNodeIsContaining && computedStyle.position === "static" && !!currentContainingBlockComputedStyle && (currentContainingBlockComputedStyle.position === "absolute" || currentContainingBlockComputedStyle.position === "fixed") || isOverflowElement(currentNode) && !currentNodeIsContaining && hasFixedPositionAncestor(element, currentNode);
3151
3197
  if (shouldDropCurrentNode) {
3152
3198
  result = result.filter((ancestor) => ancestor !== currentNode);
3153
3199
  } else {
@@ -3167,20 +3213,23 @@ function getClippingRect(_ref) {
3167
3213
  } = _ref;
3168
3214
  const elementClippingAncestors = boundary === "clippingAncestors" ? isTopLayer(element) ? [] : getClippingElementAncestors(element, this._c) : [].concat(boundary);
3169
3215
  const clippingAncestors = [...elementClippingAncestors, rootBoundary];
3170
- const firstClippingAncestor = clippingAncestors[0];
3171
- const clippingRect = clippingAncestors.reduce((accRect, clippingAncestor) => {
3172
- const rect = getClientRectFromClippingAncestor(element, clippingAncestor, strategy);
3173
- accRect.top = max(rect.top, accRect.top);
3174
- accRect.right = min(rect.right, accRect.right);
3175
- accRect.bottom = min(rect.bottom, accRect.bottom);
3176
- accRect.left = max(rect.left, accRect.left);
3177
- return accRect;
3178
- }, getClientRectFromClippingAncestor(element, firstClippingAncestor, strategy));
3216
+ const firstRect = getClientRectFromClippingAncestor(element, clippingAncestors[0], strategy);
3217
+ let top = firstRect.top;
3218
+ let right = firstRect.right;
3219
+ let bottom = firstRect.bottom;
3220
+ let left = firstRect.left;
3221
+ for (let i2 = 1; i2 < clippingAncestors.length; i2++) {
3222
+ const rect = getClientRectFromClippingAncestor(element, clippingAncestors[i2], strategy);
3223
+ top = max(rect.top, top);
3224
+ right = min(rect.right, right);
3225
+ bottom = min(rect.bottom, bottom);
3226
+ left = max(rect.left, left);
3227
+ }
3179
3228
  return {
3180
- width: clippingRect.right - clippingRect.left,
3181
- height: clippingRect.bottom - clippingRect.top,
3182
- x: clippingRect.left,
3183
- y: clippingRect.top
3229
+ width: right - left,
3230
+ height: bottom - top,
3231
+ x: left,
3232
+ y: top
3184
3233
  };
3185
3234
  }
3186
3235
  function getDimensions(element) {
@@ -3203,6 +3252,9 @@ function getRectRelativeToOffsetParent(element, offsetParent, strategy) {
3203
3252
  scrollTop: 0
3204
3253
  };
3205
3254
  const offsets = createCoords(0);
3255
+ function setLeftRTLScrollbarOffset() {
3256
+ offsets.x = getWindowScrollBarX(documentElement);
3257
+ }
3206
3258
  if (isOffsetParentAnElement || !isOffsetParentAnElement && !isFixed) {
3207
3259
  if (getNodeName(offsetParent) !== "body" || isOverflowElement(documentElement)) {
3208
3260
  scroll = getNodeScroll(offsetParent);
@@ -3212,11 +3264,15 @@ function getRectRelativeToOffsetParent(element, offsetParent, strategy) {
3212
3264
  offsets.x = offsetRect.x + offsetParent.clientLeft;
3213
3265
  offsets.y = offsetRect.y + offsetParent.clientTop;
3214
3266
  } else if (documentElement) {
3215
- offsets.x = getWindowScrollBarX(documentElement);
3267
+ setLeftRTLScrollbarOffset();
3216
3268
  }
3217
3269
  }
3218
- const x2 = rect.left + scroll.scrollLeft - offsets.x;
3219
- const y2 = rect.top + scroll.scrollTop - offsets.y;
3270
+ if (isFixed && !isOffsetParentAnElement && documentElement) {
3271
+ setLeftRTLScrollbarOffset();
3272
+ }
3273
+ const htmlOffset = documentElement && !isOffsetParentAnElement && !isFixed ? getHTMLOffset(documentElement, scroll) : createCoords(0);
3274
+ const x2 = rect.left + scroll.scrollLeft - offsets.x - htmlOffset.x;
3275
+ const y2 = rect.top + scroll.scrollTop - offsets.y - htmlOffset.y;
3220
3276
  return {
3221
3277
  x: x2,
3222
3278
  y: y2,
@@ -3234,7 +3290,11 @@ function getTrueOffsetParent(element, polyfill) {
3234
3290
  if (polyfill) {
3235
3291
  return polyfill(element);
3236
3292
  }
3237
- return element.offsetParent;
3293
+ let rawOffsetParent = element.offsetParent;
3294
+ if (getDocumentElement(element) === rawOffsetParent) {
3295
+ rawOffsetParent = rawOffsetParent.ownerDocument.body;
3296
+ }
3297
+ return rawOffsetParent;
3238
3298
  }
3239
3299
  function getOffsetParent(element, polyfill) {
3240
3300
  const win = getWindow(element);
@@ -3289,6 +3349,9 @@ const platform = {
3289
3349
  isElement,
3290
3350
  isRTL
3291
3351
  };
3352
+ function rectsAreEqual(a2, b2) {
3353
+ return a2.x === b2.x && a2.y === b2.y && a2.width === b2.width && a2.height === b2.height;
3354
+ }
3292
3355
  function observeMove(element, onMove) {
3293
3356
  let io = null;
3294
3357
  let timeoutId;
@@ -3307,12 +3370,13 @@ function observeMove(element, onMove) {
3307
3370
  threshold = 1;
3308
3371
  }
3309
3372
  cleanup();
3373
+ const elementRectForRootMargin = element.getBoundingClientRect();
3310
3374
  const {
3311
3375
  left,
3312
3376
  top,
3313
3377
  width,
3314
3378
  height
3315
- } = element.getBoundingClientRect();
3379
+ } = elementRectForRootMargin;
3316
3380
  if (!skip) {
3317
3381
  onMove();
3318
3382
  }
@@ -3343,6 +3407,9 @@ function observeMove(element, onMove) {
3343
3407
  refresh(false, ratio);
3344
3408
  }
3345
3409
  }
3410
+ if (ratio === 1 && !rectsAreEqual(elementRectForRootMargin, element.getBoundingClientRect())) {
3411
+ refresh();
3412
+ }
3346
3413
  isFirstUpdate = false;
3347
3414
  }
3348
3415
  try {
@@ -3351,7 +3418,7 @@ function observeMove(element, onMove) {
3351
3418
  // Handle <iframe>s
3352
3419
  root: root.ownerDocument
3353
3420
  });
3354
- } catch (e2) {
3421
+ } catch (_e) {
3355
3422
  io = new IntersectionObserver(handleObserve, options2);
3356
3423
  }
3357
3424
  io.observe(element);
@@ -3371,7 +3438,7 @@ function autoUpdate(reference, floating, update, options2) {
3371
3438
  animationFrame = false
3372
3439
  } = options2;
3373
3440
  const referenceEl = unwrapElement(reference);
3374
- const ancestors = ancestorScroll || ancestorResize ? [...referenceEl ? getOverflowAncestors(referenceEl) : [], ...getOverflowAncestors(floating)] : [];
3441
+ const ancestors = ancestorScroll || ancestorResize ? [...referenceEl ? getOverflowAncestors(referenceEl) : [], ...floating ? getOverflowAncestors(floating) : []] : [];
3375
3442
  ancestors.forEach((ancestor) => {
3376
3443
  ancestorScroll && ancestor.addEventListener("scroll", update, {
3377
3444
  passive: true
@@ -3384,7 +3451,7 @@ function autoUpdate(reference, floating, update, options2) {
3384
3451
  if (elementResize) {
3385
3452
  resizeObserver = new ResizeObserver((_ref) => {
3386
3453
  let [firstEntry] = _ref;
3387
- if (firstEntry && firstEntry.target === referenceEl && resizeObserver) {
3454
+ if (firstEntry && firstEntry.target === referenceEl && resizeObserver && floating) {
3388
3455
  resizeObserver.unobserve(floating);
3389
3456
  cancelAnimationFrame(reobserveFrame);
3390
3457
  reobserveFrame = requestAnimationFrame(() => {
@@ -3397,7 +3464,9 @@ function autoUpdate(reference, floating, update, options2) {
3397
3464
  if (referenceEl && !animationFrame) {
3398
3465
  resizeObserver.observe(referenceEl);
3399
3466
  }
3400
- resizeObserver.observe(floating);
3467
+ if (floating) {
3468
+ resizeObserver.observe(floating);
3469
+ }
3401
3470
  }
3402
3471
  let frameId;
3403
3472
  let prevRefRect = animationFrame ? getBoundingClientRect(reference) : null;
@@ -3406,7 +3475,7 @@ function autoUpdate(reference, floating, update, options2) {
3406
3475
  }
3407
3476
  function frameLoop() {
3408
3477
  const nextRefRect = getBoundingClientRect(reference);
3409
- if (prevRefRect && (nextRefRect.x !== prevRefRect.x || nextRefRect.y !== prevRefRect.y || nextRefRect.width !== prevRefRect.width || nextRefRect.height !== prevRefRect.height)) {
3478
+ if (prevRefRect && !rectsAreEqual(prevRefRect, nextRefRect)) {
3410
3479
  update();
3411
3480
  }
3412
3481
  prevRefRect = nextRefRect;
@@ -5409,52 +5478,62 @@ var designTokens = () => {
5409
5478
  };
5410
5479
  };
5411
5480
  const [black, white, transparent] = ["oklch(0 0 0)", "oklch(100 0 0)", "transparent"];
5412
- const tokens = designTokens().core(({ theme }) => ({
5413
- color: {
5414
- transparent,
5415
- black,
5416
- white,
5417
- lowest: theme.mode === "light" ? white : black,
5418
- highest: theme.mode === "light" ? black : white,
5419
- ...generatePalette({
5420
- prefix: "a-",
5421
- hue: theme.accent.hue,
5422
- chroma: theme.accent.chroma,
5423
- mode: theme.mode,
5424
- transform: sameAsInput
5425
- }),
5426
- ...generatePalette({
5427
- prefix: "n-",
5428
- hue: theme.accent.hue,
5429
- chroma: 0.05,
5430
- mode: theme.mode,
5431
- transform: sameAsInput
5432
- }),
5433
- ...generatePalette({
5434
- prefix: "p-",
5435
- hue: theme.positive.hue,
5436
- chroma: theme.positive.chroma,
5437
- mode: theme.mode,
5438
- transform: sameAsInput
5439
- }),
5440
- ...generatePalette({
5441
- prefix: "e-",
5442
- hue: theme.negative.hue,
5443
- chroma: theme.negative.chroma,
5444
- mode: theme.mode,
5445
- transform: sameAsInput
5446
- })
5447
- },
5448
- radius: {
5449
- base: theme.corners === "rounded" ? ".25rem" : theme.corners === "soft" ? ".125rem" : "0",
5450
- multiplier: theme.corners === "rounded" ? "0.5rem" : theme.corners === "soft" ? "0.175rem" : "0"
5451
- },
5452
- duration: {
5453
- snappy: ".4s",
5454
- medium: ".6s",
5455
- slow: ".9s"
5456
- }
5457
- })).semantic(({ core }) => ({
5481
+ const tokens = designTokens().core(({ theme }) => {
5482
+ const accent = generatePalette({
5483
+ prefix: "a-",
5484
+ hue: theme.accent.hue,
5485
+ chroma: theme.accent.chroma,
5486
+ mode: theme.mode,
5487
+ transform: sameAsInput
5488
+ });
5489
+ const exact = theme.exactAccent;
5490
+ return {
5491
+ color: {
5492
+ transparent,
5493
+ black,
5494
+ white,
5495
+ lowest: theme.mode === "light" ? white : black,
5496
+ highest: theme.mode === "light" ? black : white,
5497
+ ...accent,
5498
+ /** The solid accent fill (the submit button), pressed, and its text. An exact accent lands unchanged here only:
5499
+ * text and focus rings keep the palette's contrast-controlled shades. */
5500
+ "a-solid": (exact == null ? void 0 : exact.color) ?? accent["a-9"],
5501
+ "a-solid-pressed": exact ? `color-mix(in oklab, ${exact.color} 88%, black)` : theme.mode === "light" ? accent["a-10"] : accent["a-8"],
5502
+ "on-a": (exact == null ? void 0 : exact.text) ?? (theme.mode === "light" ? accent["a-1"] : white),
5503
+ ...generatePalette({
5504
+ prefix: "n-",
5505
+ hue: theme.accent.hue,
5506
+ // An achromatic accent gets achromatic neutrals; otherwise neutrals carry a faint tint of the accent hue.
5507
+ chroma: theme.accent.chroma === 0 ? 0 : 0.05,
5508
+ mode: theme.mode,
5509
+ transform: sameAsInput
5510
+ }),
5511
+ ...generatePalette({
5512
+ prefix: "p-",
5513
+ hue: theme.positive.hue,
5514
+ chroma: theme.positive.chroma,
5515
+ mode: theme.mode,
5516
+ transform: sameAsInput
5517
+ }),
5518
+ ...generatePalette({
5519
+ prefix: "e-",
5520
+ hue: theme.negative.hue,
5521
+ chroma: theme.negative.chroma,
5522
+ mode: theme.mode,
5523
+ transform: sameAsInput
5524
+ })
5525
+ },
5526
+ radius: {
5527
+ base: theme.corners === "rounded" ? ".25rem" : theme.corners === "soft" ? ".125rem" : "0",
5528
+ multiplier: theme.corners === "rounded" ? "0.5rem" : theme.corners === "soft" ? "0.175rem" : "0"
5529
+ },
5530
+ duration: {
5531
+ snappy: ".4s",
5532
+ medium: ".6s",
5533
+ slow: ".9s"
5534
+ }
5535
+ };
5536
+ }).semantic(({ core }) => ({
5458
5537
  radius: {
5459
5538
  sm: `calc(${core("radius.base")} + (0 * ${core("radius.multiplier")}))`,
5460
5539
  md: `calc(${core("radius.base")} + (1 * ${core("radius.multiplier")}))`,
@@ -5686,7 +5765,7 @@ const CommentForm = ({
5686
5765
  "button",
5687
5766
  {
5688
5767
  onTouchStart: noop,
5689
- class: "bg-accent-9 active:bg-accent-10 theme-dark:active:bg-accent-8 fr ease-expo-out duration-snappy text-accent-1 theme-dark:text-highest grid items-center overflow-hidden rounded-lg px-5 py-2 pl-2.5 text-center transition-all hover:scale-[1.02] active:scale-[.97]",
5768
+ class: "bg-accent-solid active:bg-accent-solid-pressed fr ease-expo-out duration-snappy text-on-accent grid items-center overflow-hidden rounded-lg px-5 py-2 pl-2.5 text-center transition-all hover:scale-[1.02] active:scale-[.97]",
5690
5769
  children: submission.state === "submitting" ? t2("submitting") : t2("submit")
5691
5770
  }
5692
5771
  ),
@@ -6168,8 +6247,8 @@ const tailwind = `[data-widget='inploi-feedback'] {
6168
6247
  border-width: 1px;
6169
6248
  }
6170
6249
 
6171
- [data-widget='inploi-feedback'] .bg-accent-9 {
6172
- background-color: var(--i-color-a-9);
6250
+ [data-widget='inploi-feedback'] .bg-accent-solid {
6251
+ background-color: var(--i-color-a-solid);
6173
6252
  }
6174
6253
 
6175
6254
  [data-widget='inploi-feedback'] .bg-lowest {
@@ -6287,10 +6366,6 @@ const tailwind = `[data-widget='inploi-feedback'] {
6287
6366
  letter-spacing: -0.025em;
6288
6367
  }
6289
6368
 
6290
- [data-widget='inploi-feedback'] .text-accent-1 {
6291
- color: var(--i-color-a-1);
6292
- }
6293
-
6294
6369
  [data-widget='inploi-feedback'] .text-accent-10 {
6295
6370
  color: var(--i-color-a-10);
6296
6371
  }
@@ -6307,6 +6382,10 @@ const tailwind = `[data-widget='inploi-feedback'] {
6307
6382
  color: var(--i-color-n-12);
6308
6383
  }
6309
6384
 
6385
+ [data-widget='inploi-feedback'] .text-on-accent {
6386
+ color: var(--i-color-on-a);
6387
+ }
6388
+
6310
6389
  [data-widget='inploi-feedback'] .underline {
6311
6390
  text-decoration-line: underline;
6312
6391
  }
@@ -6342,6 +6421,12 @@ const tailwind = `[data-widget='inploi-feedback'] {
6342
6421
  outline-style: solid;
6343
6422
  }
6344
6423
 
6424
+ [data-widget='inploi-feedback'] .ring {
6425
+ --tw-ring-offset-shadow: var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);
6426
+ --tw-ring-shadow: var(--tw-ring-inset) 0 0 0 calc(3px + var(--tw-ring-offset-width)) var(--tw-ring-color);
6427
+ box-shadow: var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow, 0 0 #0000);
6428
+ }
6429
+
6345
6430
  [data-widget='inploi-feedback'] .ring-1 {
6346
6431
  --tw-ring-offset-shadow: var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);
6347
6432
  --tw-ring-shadow: var(--tw-ring-inset) 0 0 0 calc(1px + var(--tw-ring-offset-width)) var(--tw-ring-color);
@@ -6514,8 +6599,8 @@ const tailwind = `[data-widget='inploi-feedback'] {
6514
6599
  transform: translate(var(--tw-translate-x), var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y));
6515
6600
  }
6516
6601
 
6517
- [data-widget='inploi-feedback'] .active\\:bg-accent-10:active {
6518
- background-color: var(--i-color-a-10);
6602
+ [data-widget='inploi-feedback'] .active\\:bg-accent-solid-pressed:active {
6603
+ background-color: var(--i-color-a-solid-pressed);
6519
6604
  }
6520
6605
 
6521
6606
  [data-widget='inploi-feedback'] .aria-\\[pressed\\=true\\]\\:text-negative-11[aria-pressed="true"] {
@@ -6553,14 +6638,6 @@ const tailwind = `[data-widget='inploi-feedback'] {
6553
6638
  color: var(--i-color-a-10);
6554
6639
  }
6555
6640
 
6556
- [data-widget='inploi-feedback'] .dark .theme-dark\\:text-highest {
6557
- color: var(--i-color-highest);
6558
- }
6559
-
6560
- [data-widget='inploi-feedback'] .dark .theme-dark\\:active\\:bg-accent-8:active {
6561
- background-color: var(--i-color-a-8);
6562
- }
6563
-
6564
6641
  [data-widget='inploi-feedback'] .rounded .theme-rounded\\:rounded-sm {
6565
6642
  border-radius: var(--i-radius-sm);
6566
6643
  }
@@ -6649,6 +6726,7 @@ const createFeedbackDomManager = (logger) => {
6649
6726
  const feedbackPlugin = () => createPlugin(({ apiClient, logger, analytics }) => {
6650
6727
  const dom = createFeedbackDomManager(logger);
6651
6728
  let prerendered = false;
6729
+ const targets = /* @__PURE__ */ new Set();
6652
6730
  const App = ({ params }) => {
6653
6731
  return _$2(k$3, {}, [
6654
6732
  [
@@ -6676,7 +6754,15 @@ const feedbackPlugin = () => createPlugin(({ apiClient, logger, analytics }) =>
6676
6754
  typeof window !== "undefined",
6677
6755
  "the `render` method of JobSearch cannot be called in non-browser environments. Use `prerender` instead."
6678
6756
  );
6679
- fn2(_$2(App, { params }), dom.getRenderTargetElement(params.key));
6757
+ const target = params.target ?? dom.getRenderTargetElement(params.key);
6758
+ targets.add(target);
6759
+ fn2(_$2(App, { params }), target);
6760
+ },
6761
+ /** Release components, portals and document listeners when an owning widget unmounts. */
6762
+ destroy: () => {
6763
+ for (const target of targets)
6764
+ J$1(null, target);
6765
+ targets.clear();
6680
6766
  },
6681
6767
  "~brand": "@inploi/plugin-feedback"
6682
6768
  };