PageSourceSearch

https://app.zellsy.ai/assets/TableDropdown-BjYaV48L.js

js zellsy.ai collected 2026-10-05 15:18:10 UTC 53,631 bytes, 1,421 lines download raw bytes

vendor: 4,550 bytes, lines 1-144
1import { r as reactExports, j as jsxRuntimeExports } from "./vendor-react-CBUOmk1-.js";
2var top = "top";
3var bottom = "bottom";
4var right = "right";
5var left = "left";
6var auto = "auto";
7var basePlacements = [top, bottom, right, left];
8var start = "start";
9var end = "end";
10var clippingParents = "clippingParents";
11var viewport = "viewport";
12var popper = "popper";
13var reference = "reference";
14var variationPlacements = /* @__PURE__ */ basePlacements.reduce(function(acc, placement) {
15  return acc.concat([placement + "-" + start, placement + "-" + end]);
16}, []);
17var placements = /* @__PURE__ */ [].concat(basePlacements, [auto]).reduce(function(acc, placement) {
18  return acc.concat([placement, placement + "-" + start, placement + "-" + end]);
19}, []);
20var beforeRead = "beforeRead";
21var read = "read";
22var afterRead = "afterRead";
23var beforeMain = "beforeMain";
24var main = "main";
25var afterMain = "afterMain";
26var beforeWrite = "beforeWrite";
27var write = "write";
28var afterWrite = "afterWrite";
29var modifierPhases = [beforeRead, read, afterRead, beforeMain, main, afterMain, beforeWrite, write, afterWrite];
30function getNodeName(element) {
31  return element ? (element.nodeName || "").toLowerCase() : null;
32}
33function getWindow(node) {
34  if (node == null) {
35    return window;
36  }
37  if (node.toString() !== "[object Window]") {
38    var ownerDocument = node.ownerDocument;
39    return ownerDocument ? ownerDocument.defaultView || window : window;
40  }
41  return node;
42}
43function isElement(node) {
44  var OwnElement = getWindow(node).Element;
45  return node instanceof OwnElement || node instanceof Element;
46}
47function isHTMLElement(node) {
48  var OwnElement = getWindow(node).HTMLElement;
49  return node instanceof OwnElement || node instanceof HTMLElement;
50}
51function isShadowRoot(node) {
52  if (typeof ShadowRoot === "undefined") {
53    return false;
54  }
55  var OwnElement = getWindow(node).ShadowRoot;
56  return node instanceof OwnElement || node instanceof ShadowRoot;
57}
58function applyStyles(_ref) {
59  var state = _ref.state;
60  Object.keys(state.elements).forEach(function(name) {
61    var style = state.styles[name] || {};
62    var attributes = state.attributes[name] || {};
63    var element = state.elements[name];
64    if (!isHTMLElement(element) || !getNodeName(element)) {
65      return;
66    }
67    Object.assign(element.style, style);
68    Object.keys(attributes).forEach(function(name2) {
69      var value = attributes[name2];
70      if (value === false) {
71        element.removeAttribute(name2);
72      } else {
73        element.setAttribute(name2, value === true ? "" : value);
74      }
75    });
76  });
77}
78function effect$2(_ref2) {
79  var state = _ref2.state;
80  var initialStyles = {
81    popper: {
82      position: state.options.strategy,
83      left: "0",
84      top: "0",
85      margin: "0"
86    },
87    arrow: {
88      position: "absolute"
89    },
90    reference: {}
91  };
92  Object.assign(state.elements.popper.style, initialStyles.popper);
93  state.styles = initialStyles;
94  if (state.elements.arrow) {
95    Object.assign(state.elements.arrow.style, initialStyles.arrow);
96  }
97  return function() {
98    Object.keys(state.elements).forEach(function(name) {
99      var element = state.elements[name];
100      var attributes = state.attributes[name] || {};
101      var styleProperties = Object.keys(state.styles.hasOwnProperty(name) ? state.styles[name] : initialStyles[name]);
102      var style = styleProperties.reduce(function(style2, property) {
103        style2[property] = "";
104        return style2;
105      }, {});
106      if (!isHTMLElement(element) || !getNodeName(element)) {
107        return;
108      }
109      Object.assign(element.style, style);
110      Object.keys(attributes).forEach(function(attribute) {
111        element.removeAttribute(attribute);
112      });
113    });
114  };
115}
116const applyStyles$1 = {
117  name: "applyStyles",
118  enabled: true,
119  phase: "write",
120  fn: applyStyles,
121  effect: effect$2,
122  requires: ["computeStyles"]
123};
124function getBasePlacement(placement) {
125  return placement.split("-")[0];
126}
127var max = Math.max;
128var min = Math.min;
129var round = Math.round;
130function getUAString() {
131  var uaData = navigator.userAgentData;
132  if (uaData != null && uaData.brands && Array.isArray(uaData.brands)) {
133    return uaData.brands.map(function(item) {
134      return item.brand + "/" + item.version;
135    }).join(" ");
136  }
137  return navigator.userAgent;
138}
139function isLayoutViewport() {
140  return !/^((?!chrome|android).)*safari/i.test(getUAString());
141}
142function getBoundingClientRect(element, includeScale, isFixedStrategy) {
143  if (includeScale === void 0) {
144    includeScale = false;
vendor: 13,169 bytes, lines 145-499
145  }
146  if (isFixedStrategy === void 0) {
147    isFixedStrategy = false;
148  }
149  var clientRect = element.getBoundingClientRect();
150  var scaleX = 1;
151  var scaleY = 1;
152  if (includeScale && isHTMLElement(element)) {
153    scaleX = element.offsetWidth > 0 ? round(clientRect.width) / element.offsetWidth || 1 : 1;
154    scaleY = element.offsetHeight > 0 ? round(clientRect.height) / element.offsetHeight || 1 : 1;
155  }
156  var _ref = isElement(element) ? getWindow(element) : window, visualViewport = _ref.visualViewport;
157  var addVisualOffsets = !isLayoutViewport() && isFixedStrategy;
158  var x = (clientRect.left + (addVisualOffsets && visualViewport ? visualViewport.offsetLeft : 0)) / scaleX;
159  var y = (clientRect.top + (addVisualOffsets && visualViewport ? visualViewport.offsetTop : 0)) / scaleY;
160  var width = clientRect.width / scaleX;
161  var height = clientRect.height / scaleY;
162  return {
163    width,
164    height,
165    top: y,
166    right: x + width,
167    bottom: y + height,
168    left: x,
169    x,
170    y
171  };
172}
173function getLayoutRect(element) {
174  var clientRect = getBoundingClientRect(element);
175  var width = element.offsetWidth;
176  var height = element.offsetHeight;
177  if (Math.abs(clientRect.width - width) <= 1) {
178    width = clientRect.width;
179  }
180  if (Math.abs(clientRect.height - height) <= 1) {
181    height = clientRect.height;
182  }
183  return {
184    x: element.offsetLeft,
185    y: element.offsetTop,
186    width,
187    height
188  };
189}
190function contains(parent, child) {
191  var rootNode = child.getRootNode && child.getRootNode();
192  if (parent.contains(child)) {
193    return true;
194  } else if (rootNode && isShadowRoot(rootNode)) {
195    var next = child;
196    do {
197      if (next && parent.isSameNode(next)) {
198        return true;
199      }
200      next = next.parentNode || next.host;
201    } while (next);
202  }
203  return false;
204}
205function getComputedStyle(element) {
206  return getWindow(element).getComputedStyle(element);
207}
208function isTableElement(element) {
209  return ["table", "td", "th"].indexOf(getNodeName(element)) >= 0;
210}
211function getDocumentElement(element) {
212  return ((isElement(element) ? element.ownerDocument : (
213    // $FlowFixMe[prop-missing]
214    element.document
215  )) || window.document).documentElement;
216}
217function getParentNode(element) {
218  if (getNodeName(element) === "html") {
219    return element;
220  }
221  return (
222    // this is a quicker (but less type safe) way to save quite some bytes from the bundle
223    // $FlowFixMe[incompatible-return]
224    // $FlowFixMe[prop-missing]
225    element.assignedSlot || // step into the shadow DOM of the parent of a slotted node
226    element.parentNode || // DOM Element detected
227    (isShadowRoot(element) ? element.host : null) || // ShadowRoot detected
228    // $FlowFixMe[incompatible-call]: HTMLElement is a Node
229    getDocumentElement(element)
230  );
231}
232function getTrueOffsetParent(element) {
233  if (!isHTMLElement(element) || // https://github.com/popperjs/popper-core/issues/837
234  getComputedStyle(element).position === "fixed") {
235    return null;
236  }
237  return element.offsetParent;
238}
239function getContainingBlock(element) {
240  var isFirefox = /firefox/i.test(getUAString());
241  var isIE = /Trident/i.test(getUAString());
242  if (isIE && isHTMLElement(element)) {
243    var elementCss = getComputedStyle(element);
244    if (elementCss.position === "fixed") {
245      return null;
246    }
247  }
248  var currentNode = getParentNode(element);
249  if (isShadowRoot(currentNode)) {
250    currentNode = currentNode.host;
251  }
252  while (isHTMLElement(currentNode) && ["html", "body"].indexOf(getNodeName(currentNode)) < 0) {
253    var css = getComputedStyle(currentNode);
254    if (css.transform !== "none" || css.perspective !== "none" || css.contain === "paint" || ["transform", "perspective"].indexOf(css.willChange) !== -1 || isFirefox && css.willChange === "filter" || isFirefox && css.filter && css.filter !== "none") {
255      return currentNode;
256    } else {
257      currentNode = currentNode.parentNode;
258    }
259  }
260  return null;
261}
262function getOffsetParent(element) {
263  var window2 = getWindow(element);
264  var offsetParent = getTrueOffsetParent(element);
265  while (offsetParent && isTableElement(offsetParent) && getComputedStyle(offsetParent).position === "static") {
266    offsetParent = getTrueOffsetParent(offsetParent);
267  }
268  if (offsetParent && (getNodeName(offsetParent) === "html" || getNodeName(offsetParent) === "body" && getComputedStyle(offsetParent).position === "static")) {
269    return window2;
270  }
271  return offsetParent || getContainingBlock(element) || window2;
272}
273function getMainAxisFromPlacement(placement) {
274  return ["top", "bottom"].indexOf(placement) >= 0 ? "x" : "y";
275}
276function within(min$1, value, max$1) {
277  return max(min$1, min(value, max$1));
278}
279function withinMaxClamp(min2, value, max2) {
280  var v = within(min2, value, max2);
281  return v > max2 ? max2 : v;
282}
283function getFreshSideObject() {
284  return {
285    top: 0,
286    right: 0,
287    bottom: 0,
288    left: 0
289  };
290}
291function mergePaddingObject(paddingObject) {
292  return Object.assign({}, getFreshSideObject(), paddingObject);
293}
294function expandToHashMap(value, keys) {
295  return keys.reduce(function(hashMap, key) {
296    hashMap[key] = value;
297    return hashMap;
298  }, {});
299}
300var toPaddingObject = function toPaddingObject2(padding, state) {
301  padding = typeof padding === "function" ? padding(Object.assign({}, state.rects, {
302    placement: state.placement
303  })) : padding;
304  return mergePaddingObject(typeof padding !== "number" ? padding : expandToHashMap(padding, basePlacements));
305};
306function arrow(_ref) {
307  var _state$modifiersData$;
308  var state = _ref.state, name = _ref.name, options = _ref.options;
309  var arrowElement = state.elements.arrow;
310  var popperOffsets2 = state.modifiersData.popperOffsets;
311  var basePlacement = getBasePlacement(state.placement);
312  var axis = getMainAxisFromPlacement(basePlacement);
313  var isVertical = [left, right].indexOf(basePlacement) >= 0;
314  var len = isVertical ? "height" : "width";
315  if (!arrowElement || !popperOffsets2) {
316    return;
317  }
318  var paddingObject = toPaddingObject(options.padding, state);
319  var arrowRect = getLayoutRect(arrowElement);
320  var minProp = axis === "y" ? top : left;
321  var maxProp = axis === "y" ? bottom : right;
322  var endDiff = state.rects.reference[len] + state.rects.reference[axis] - popperOffsets2[axis] - state.rects.popper[len];
323  var startDiff = popperOffsets2[axis] - state.rects.reference[axis];
324  var arrowOffsetParent = getOffsetParent(arrowElement);
325  var clientSize = arrowOffsetParent ? axis === "y" ? arrowOffsetParent.clientHeight || 0 : arrowOffsetParent.clientWidth || 0 : 0;
326  var centerToReference = endDiff / 2 - startDiff / 2;
327  var min2 = paddingObject[minProp];
328  var max2 = clientSize - arrowRect[len] - paddingObject[maxProp];
329  var center = clientSize / 2 - arrowRect[len] / 2 + centerToReference;
330  var offset2 = within(min2, center, max2);
331  var axisProp = axis;
332  state.modifiersData[name] = (_state$modifiersData$ = {}, _state$modifiersData$[axisProp] = offset2, _state$modifiersData$.centerOffset = offset2 - center, _state$modifiersData$);
333}
334function effect$1(_ref2) {
335  var state = _ref2.state, options = _ref2.options;
336  var _options$element = options.element, arrowElement = _options$element === void 0 ? "[data-popper-arrow]" : _options$element;
337  if (arrowElement == null) {
338    return;
339  }
340  if (typeof arrowElement === "string") {
341    arrowElement = state.elements.popper.querySelector(arrowElement);
342    if (!arrowElement) {
343      return;
344    }
345  }
346  if (!contains(state.elements.popper, arrowElement)) {
347    return;
348  }
349  state.elements.arrow = arrowElement;
350}
351const arrow$1 = {
352  name: "arrow",
353  enabled: true,
354  phase: "main",
355  fn: arrow,
356  effect: effect$1,
357  requires: ["popperOffsets"],
358  requiresIfExists: ["preventOverflow"]
359};
360function getVariation(placement) {
361  return placement.split("-")[1];
362}
363var unsetSides = {
364  top: "auto",
365  right: "auto",
366  bottom: "auto",
367  left: "auto"
368};
369function roundOffsetsByDPR(_ref, win) {
370  var x = _ref.x, y = _ref.y;
371  var dpr = win.devicePixelRatio || 1;
372  return {
373    x: round(x * dpr) / dpr || 0,
374    y: round(y * dpr) / dpr || 0
375  };
376}
377function mapToStyles(_ref2) {
378  var _Object$assign2;
379  var popper2 = _ref2.popper, popperRect = _ref2.popperRect, placement = _ref2.placement, variation = _ref2.variation, offsets = _ref2.offsets, position = _ref2.position, gpuAcceleration = _ref2.gpuAcceleration, adaptive = _ref2.adaptive, roundOffsets = _ref2.roundOffsets, isFixed = _ref2.isFixed;
380  var _offsets$x = offsets.x, x = _offsets$x === void 0 ? 0 : _offsets$x, _offsets$y = offsets.y, y = _offsets$y === void 0 ? 0 : _offsets$y;
381  var _ref3 = typeof roundOffsets === "function" ? roundOffsets({
382    x,
383    y
384  }) : {
385    x,
386    y
387  };
388  x = _ref3.x;
389  y = _ref3.y;
390  var hasX = offsets.hasOwnProperty("x");
391  var hasY = offsets.hasOwnProperty("y");
392  var sideX = left;
393  var sideY = top;
394  var win = window;
395  if (adaptive) {
396    var offsetParent = getOffsetParent(popper2);
397    var heightProp = "clientHeight";
398    var widthProp = "clientWidth";
399    if (offsetParent === getWindow(popper2)) {
400      offsetParent = getDocumentElement(popper2);
401      if (getComputedStyle(offsetParent).position !== "static" && position === "absolute") {
402        heightProp = "scrollHeight";
403        widthProp = "scrollWidth";
404      }
405    }
406    offsetParent = offsetParent;
407    if (placement === top || (placement === left || placement === right) && variation === end) {
408      sideY = bottom;
409      var offsetY = isFixed && offsetParent === win && win.visualViewport ? win.visualViewport.height : (
410        // $FlowFixMe[prop-missing]
411        offsetParent[heightProp]
412      );
413      y -= offsetY - popperRect.height;
414      y *= gpuAcceleration ? 1 : -1;
415    }
416    if (placement === left || (placement === top || placement === bottom) && variation === end) {
417      sideX = right;
418      var offsetX = isFixed && offsetParent === win && win.visualViewport ? win.visualViewport.width : (
419        // $FlowFixMe[prop-missing]
420        offsetParent[widthProp]
421      );
422      x -= offsetX - popperRect.width;
423      x *= gpuAcceleration ? 1 : -1;
424    }
425  }
426  var commonStyles = Object.assign({
427    position
428  }, adaptive && unsetSides);
429  var _ref4 = roundOffsets === true ? roundOffsetsByDPR({
430    x,
431    y
432  }, getWindow(popper2)) : {
433    x,
434    y
435  };
436  x = _ref4.x;
437  y = _ref4.y;
438  if (gpuAcceleration) {
439    var _Object$assign;
440    return Object.assign({}, commonStyles, (_Object$assign = {}, _Object$assign[sideY] = hasY ? "0" : "", _Object$assign[sideX] = hasX ? "0" : "", _Object$assign.transform = (win.devicePixelRatio || 1) <= 1 ? "translate(" + x + "px, " + y + "px)" : "translate3d(" + x + "px, " + y + "px, 0)", _Object$assign));
441  }
442  return Object.assign({}, commonStyles, (_Object$assign2 = {}, _Object$assign2[sideY] = hasY ? y + "px" : "", _Object$assign2[sideX] = hasX ? x + "px" : "", _Object$assign2.transform = "", _Object$assign2));
443}
444function computeStyles(_ref5) {
445  var state = _ref5.state, options = _ref5.options;
446  var _options$gpuAccelerat = options.gpuAcceleration, gpuAcceleration = _options$gpuAccelerat === void 0 ? true : _options$gpuAccelerat, _options$adaptive = options.adaptive, adaptive = _options$adaptive === void 0 ? true : _options$adaptive, _options$roundOffsets = options.roundOffsets, roundOffsets = _options$roundOffsets === void 0 ? true : _options$roundOffsets;
447  var commonStyles = {
448    placement: getBasePlacement(state.placement),
449    variation: getVariation(state.placement),
450    popper: state.elements.popper,
451    popperRect: state.rects.popper,
452    gpuAcceleration,
453    isFixed: state.options.strategy === "fixed"
454  };
455  if (state.modifiersData.popperOffsets != null) {
456    state.styles.popper = Object.assign({}, state.styles.popper, mapToStyles(Object.assign({}, commonStyles, {
457      offsets: state.modifiersData.popperOffsets,
458      position: state.options.strategy,
459      adaptive,
460      roundOffsets
461    })));
462  }
463  if (state.modifiersData.arrow != null) {
464    state.styles.arrow = Object.assign({}, state.styles.arrow, mapToStyles(Object.assign({}, commonStyles, {
465      offsets: state.modifiersData.arrow,
466      position: "absolute",
467      adaptive: false,
468      roundOffsets
469    })));
470  }
471  state.attributes.popper = Object.assign({}, state.attributes.popper, {
472    "data-popper-placement": state.placement
473  });
474}
475const computeStyles$1 = {
476  name: "computeStyles",
477  enabled: true,
478  phase: "beforeWrite",
479  fn: computeStyles,
480  data: {}
481};
482var passive = {
483  passive: true
484};
485function effect(_ref) {
486  var state = _ref.state, instance = _ref.instance, options = _ref.options;
487  var _options$scroll = options.scroll, scroll = _options$scroll === void 0 ? true : _options$scroll, _options$resize = options.resize, resize = _options$resize === void 0 ? true : _options$resize;
488  var window2 = getWindow(state.elements.popper);
489  var scrollParents = [].concat(state.scrollParents.reference, state.scrollParents.popper);
490  if (scroll) {
491    scrollParents.forEach(function(scrollParent) {
492      scrollParent.addEventListener("scroll", instance.update, passive);
493    });
494  }
495  if (resize) {
496    window2.addEventListener("resize", instance.update, passive);
497  }
498  return function() {
499    if (scroll) {
500      scrollParents.forEach(function(scrollParent) {
501        scrollParent.removeEventListener("scroll", instance.update, passive);
502      });
503    }
504    if (resize) {
505      window2.removeEventListener("resize", instance.update, passive);
506    }
507  };
508}
509const eventListeners = {
510  name: "eventListeners",
511  enabled: true,
512  phase: "write",
513  fn: function fn() {
514  },
515  effect,
516  data: {}
517};
518var hash$1 = {
519  left: "right",
520  right: "left",
521  bottom: "top",
522  top: "bottom"
523};
524function getOppositePlacement(placement) {
525  return placement.replace(/left|right|bottom|top/g, function(matched) {
526    return hash$1[matched];
527  });
528}
529var hash = {
530  start: "end",
531  end: "start"
532};
533function getOppositeVariationPlacement(placement) {
534  return placement.replace(/start|end/g, function(matched) {
535    return hash[matched];
536  });
537}
538function getWindowScroll(node) {
539  var win = getWindow(node);
540  var scrollLeft = win.pageXOffset;
541  var scrollTop = win.pageYOffset;
542  return {
543    scrollLeft,
544    scrollTop
545  };
546}
547function getWindowScrollBarX(element) {
548  return getBoundingClientRect(getDocumentElement(element)).left + getWindowScroll(element).scrollLeft;
549}
550function getViewportRect(element, strategy) {
551  var win = getWindow(element);
552  var html = getDocumentElement(element);
553  var visualViewport = win.visualViewport;
554  var width = html.clientWidth;
555  var height = html.clientHeight;
556  var x = 0;
557  var y = 0;
558  if (visualViewport) {
559    width = visualViewport.width;
vendor: 20,126 bytes, lines 560-1048
560    height = visualViewport.height;
561    var layoutViewport = isLayoutViewport();
562    if (layoutViewport || !layoutViewport && strategy === "fixed") {
563      x = visualViewport.offsetLeft;
564      y = visualViewport.offsetTop;
565    }
566  }
567  return {
568    width,
569    height,
570    x: x + getWindowScrollBarX(element),
571    y
572  };
573}
574function getDocumentRect(element) {
575  var _element$ownerDocumen;
576  var html = getDocumentElement(element);
577  var winScroll = getWindowScroll(element);
578  var body = (_element$ownerDocumen = element.ownerDocument) == null ? void 0 : _element$ownerDocumen.body;
579  var width = max(html.scrollWidth, html.clientWidth, body ? body.scrollWidth : 0, body ? body.clientWidth : 0);
580  var height = max(html.scrollHeight, html.clientHeight, body ? body.scrollHeight : 0, body ? body.clientHeight : 0);
581  var x = -winScroll.scrollLeft + getWindowScrollBarX(element);
582  var y = -winScroll.scrollTop;
583  if (getComputedStyle(body || html).direction === "rtl") {
584    x += max(html.clientWidth, body ? body.clientWidth : 0) - width;
585  }
586  return {
587    width,
588    height,
589    x,
590    y
591  };
592}
593function isScrollParent(element) {
594  var _getComputedStyle = getComputedStyle(element), overflow = _getComputedStyle.overflow, overflowX = _getComputedStyle.overflowX, overflowY = _getComputedStyle.overflowY;
595  return /auto|scroll|overlay|hidden/.test(overflow + overflowY + overflowX);
596}
597function getScrollParent(node) {
598  if (["html", "body", "#document"].indexOf(getNodeName(node)) >= 0) {
599    return node.ownerDocument.body;
600  }
601  if (isHTMLElement(node) && isScrollParent(node)) {
602    return node;
603  }
604  return getScrollParent(getParentNode(node));
605}
606function listScrollParents(element, list) {
607  var _element$ownerDocumen;
608  if (list === void 0) {
609    list = [];
610  }
611  var scrollParent = getScrollParent(element);
612  var isBody = scrollParent === ((_element$ownerDocumen = element.ownerDocument) == null ? void 0 : _element$ownerDocumen.body);
613  var win = getWindow(scrollParent);
614  var target = isBody ? [win].concat(win.visualViewport || [], isScrollParent(scrollParent) ? scrollParent : []) : scrollParent;
615  var updatedList = list.concat(target);
616  return isBody ? updatedList : (
617    // $FlowFixMe[incompatible-call]: isBody tells us target will be an HTMLElement here
618    updatedList.concat(listScrollParents(getParentNode(target)))
619  );
620}
621function rectToClientRect(rect) {
622  return Object.assign({}, rect, {
623    left: rect.x,
624    top: rect.y,
625    right: rect.x + rect.width,
626    bottom: rect.y + rect.height
627  });
628}
629function getInnerBoundingClientRect(element, strategy) {
630  var rect = getBoundingClientRect(element, false, strategy === "fixed");
631  rect.top = rect.top + element.clientTop;
632  rect.left = rect.left + element.clientLeft;
633  rect.bottom = rect.top + element.clientHeight;
634  rect.right = rect.left + element.clientWidth;
635  rect.width = element.clientWidth;
636  rect.height = element.clientHeight;
637  rect.x = rect.left;
638  rect.y = rect.top;
639  return rect;
640}
641function getClientRectFromMixedType(element, clippingParent, strategy) {
642  return clippingParent === viewport ? rectToClientRect(getViewportRect(element, strategy)) : isElement(clippingParent) ? getInnerBoundingClientRect(clippingParent, strategy) : rectToClientRect(getDocumentRect(getDocumentElement(element)));
643}
644function getClippingParents(element) {
645  var clippingParents2 = listScrollParents(getParentNode(element));
646  var canEscapeClipping = ["absolute", "fixed"].indexOf(getComputedStyle(element).position) >= 0;
647  var clipperElement = canEscapeClipping && isHTMLElement(element) ? getOffsetParent(element) : element;
648  if (!isElement(clipperElement)) {
649    return [];
650  }
651  return clippingParents2.filter(function(clippingParent) {
652    return isElement(clippingParent) && contains(clippingParent, clipperElement) && getNodeName(clippingParent) !== "body";
653  });
654}
655function getClippingRect(element, boundary, rootBoundary, strategy) {
656  var mainClippingParents = boundary === "clippingParents" ? getClippingParents(element) : [].concat(boundary);
657  var clippingParents2 = [].concat(mainClippingParents, [rootBoundary]);
658  var firstClippingParent = clippingParents2[0];
659  var clippingRect = clippingParents2.reduce(function(accRect, clippingParent) {
660    var rect = getClientRectFromMixedType(element, clippingParent, strategy);
661    accRect.top = max(rect.top, accRect.top);
662    accRect.right = min(rect.right, accRect.right);
663    accRect.bottom = min(rect.bottom, accRect.bottom);
664    accRect.left = max(rect.left, accRect.left);
665    return accRect;
666  }, getClientRectFromMixedType(element, firstClippingParent, strategy));
667  clippingRect.width = clippingRect.right - clippingRect.left;
668  clippingRect.height = clippingRect.bottom - clippingRect.top;
669  clippingRect.x = clippingRect.left;
670  clippingRect.y = clippingRect.top;
671  return clippingRect;
672}
673function computeOffsets(_ref) {
674  var reference2 = _ref.reference, element = _ref.element, placement = _ref.placement;
675  var basePlacement = placement ? getBasePlacement(placement) : null;
676  var variation = placement ? getVariation(placement) : null;
677  var commonX = reference2.x + reference2.width / 2 - element.width / 2;
678  var commonY = reference2.y + reference2.height / 2 - element.height / 2;
679  var offsets;
680  switch (basePlacement) {
681    case top:
682      offsets = {
683        x: commonX,
684        y: reference2.y - element.height
685      };
686      break;
687    case bottom:
688      offsets = {
689        x: commonX,
690        y: reference2.y + reference2.height
691      };
692      break;
693    case right:
694      offsets = {
695        x: reference2.x + reference2.width,
696        y: commonY
697      };
698      break;
699    case left:
700      offsets = {
701        x: reference2.x - element.width,
702        y: commonY
703      };
704      break;
705    default:
706      offsets = {
707        x: reference2.x,
708        y: reference2.y
709      };
710  }
711  var mainAxis = basePlacement ? getMainAxisFromPlacement(basePlacement) : null;
712  if (mainAxis != null) {
713    var len = mainAxis === "y" ? "height" : "width";
714    switch (variation) {
715      case start:
716        offsets[mainAxis] = offsets[mainAxis] - (reference2[len] / 2 - element[len] / 2);
717        break;
718      case end:
719        offsets[mainAxis] = offsets[mainAxis] + (reference2[len] / 2 - element[len] / 2);
720        break;
721    }
722  }
723  return offsets;
724}
725function detectOverflow(state, options) {
726  if (options === void 0) {
727    options = {};
728  }
729  var _options = options, _options$placement = _options.placement, placement = _options$placement === void 0 ? state.placement : _options$placement, _options$strategy = _options.strategy, strategy = _options$strategy === void 0 ? state.strategy : _options$strategy, _options$boundary = _options.boundary, boundary = _options$boundary === void 0 ? clippingParents : _options$boundary, _options$rootBoundary = _options.rootBoundary, rootBoundary = _options$rootBoundary === void 0 ? viewport : _options$rootBoundary, _options$elementConte = _options.elementContext, elementContext = _options$elementConte === void 0 ? popper : _options$elementConte, _options$altBoundary = _options.altBoundary, altBoundary = _options$altBoundary === void 0 ? false : _options$altBoundary, _options$padding = _options.padding, padding = _options$padding === void 0 ? 0 : _options$padding;
730  var paddingObject = mergePaddingObject(typeof padding !== "number" ? padding : expandToHashMap(padding, basePlacements));
731  var altContext = elementContext === popper ? reference : popper;
732  var popperRect = state.rects.popper;
733  var element = state.elements[altBoundary ? altContext : elementContext];
734  var clippingClientRect = getClippingRect(isElement(element) ? element : element.contextElement || getDocumentElement(state.elements.popper), boundary, rootBoundary, strategy);
735  var referenceClientRect = getBoundingClientRect(state.elements.reference);
736  var popperOffsets2 = computeOffsets({
737    reference: referenceClientRect,
738    element: popperRect,
739    placement
740  });
741  var popperClientRect = rectToClientRect(Object.assign({}, popperRect, popperOffsets2));
742  var elementClientRect = elementContext === popper ? popperClientRect : referenceClientRect;
743  var overflowOffsets = {
744    top: clippingClientRect.top - elementClientRect.top + paddingObject.top,
745    bottom: elementClientRect.bottom - clippingClientRect.bottom + paddingObject.bottom,
746    left: clippingClientRect.left - elementClientRect.left + paddingObject.left,
747    right: elementClientRect.right - clippingClientRect.right + paddingObject.right
748  };
749  var offsetData = state.modifiersData.offset;
750  if (elementContext === popper && offsetData) {
751    var offset2 = offsetData[placement];
752    Object.keys(overflowOffsets).forEach(function(key) {
753      var multiply = [right, bottom].indexOf(key) >= 0 ? 1 : -1;
754      var axis = [top, bottom].indexOf(key) >= 0 ? "y" : "x";
755      overflowOffsets[key] += offset2[axis] * multiply;
756    });
757  }
758  return overflowOffsets;
759}
760function computeAutoPlacement(state, options) {
761  if (options === void 0) {
762    options = {};
763  }
764  var _options = options, placement = _options.placement, boundary = _options.boundary, rootBoundary = _options.rootBoundary, padding = _options.padding, flipVariations = _options.flipVariations, _options$allowedAutoP = _options.allowedAutoPlacements, allowedAutoPlacements = _options$allowedAutoP === void 0 ? placements : _options$allowedAutoP;
765  var variation = getVariation(placement);
766  var placements$1 = variation ? flipVariations ? variationPlacements : variationPlacements.filter(function(placement2) {
767    return getVariation(placement2) === variation;
768  }) : basePlacements;
769  var allowedPlacements = placements$1.filter(function(placement2) {
770    return allowedAutoPlacements.indexOf(placement2) >= 0;
771  });
772  if (allowedPlacements.length === 0) {
773    allowedPlacements = placements$1;
774  }
775  var overflows = allowedPlacements.reduce(function(acc, placement2) {
776    acc[placement2] = detectOverflow(state, {
777      placement: placement2,
778      boundary,
779      rootBoundary,
780      padding
781    })[getBasePlacement(placement2)];
782    return acc;
783  }, {});
784  return Object.keys(overflows).sort(function(a, b) {
785    return overflows[a] - overflows[b];
786  });
787}
788function getExpandedFallbackPlacements(placement) {
789  if (getBasePlacement(placement) === auto) {
790    return [];
791  }
792  var oppositePlacement = getOppositePlacement(placement);
793  return [getOppositeVariationPlacement(placement), oppositePlacement, getOppositeVariationPlacement(oppositePlacement)];
794}
795function flip(_ref) {
796  var state = _ref.state, options = _ref.options, name = _ref.name;
797  if (state.modifiersData[name]._skip) {
798    return;
799  }
800  var _options$mainAxis = options.mainAxis, checkMainAxis = _options$mainAxis === void 0 ? true : _options$mainAxis, _options$altAxis = options.altAxis, checkAltAxis = _options$altAxis === void 0 ? true : _options$altAxis, specifiedFallbackPlacements = options.fallbackPlacements, padding = options.padding, boundary = options.boundary, rootBoundary = options.rootBoundary, altBoundary = options.altBoundary, _options$flipVariatio = options.flipVariations, flipVariations = _options$flipVariatio === void 0 ? true : _options$flipVariatio, allowedAutoPlacements = options.allowedAutoPlacements;
801  var preferredPlacement = state.options.placement;
802  var basePlacement = getBasePlacement(preferredPlacement);
803  var isBasePlacement = basePlacement === preferredPlacement;
804  var fallbackPlacements = specifiedFallbackPlacements || (isBasePlacement || !flipVariations ? [getOppositePlacement(preferredPlacement)] : getExpandedFallbackPlacements(preferredPlacement));
805  var placements2 = [preferredPlacement].concat(fallbackPlacements).reduce(function(acc, placement2) {
806    return acc.concat(getBasePlacement(placement2) === auto ? computeAutoPlacement(state, {
807      placement: placement2,
808      boundary,
809      rootBoundary,
810      padding,
811      flipVariations,
812      allowedAutoPlacements
813    }) : placement2);
814  }, []);
815  var referenceRect = state.rects.reference;
816  var popperRect = state.rects.popper;
817  var checksMap = /* @__PURE__ */ new Map();
818  var makeFallbackChecks = true;
819  var firstFittingPlacement = placements2[0];
820  for (var i = 0; i < placements2.length; i++) {
821    var placement = placements2[i];
822    var _basePlacement = getBasePlacement(placement);
823    var isStartVariation = getVariation(placement) === start;
824    var isVertical = [top, bottom].indexOf(_basePlacement) >= 0;
825    var len = isVertical ? "width" : "height";
826    var overflow = detectOverflow(state, {
827      placement,
828      boundary,
829      rootBoundary,
830      altBoundary,
831      padding
832    });
833    var mainVariationSide = isVertical ? isStartVariation ? right : left : isStartVariation ? bottom : top;
834    if (referenceRect[len] > popperRect[len]) {
835      mainVariationSide = getOppositePlacement(mainVariationSide);
836    }
837    var altVariationSide = getOppositePlacement(mainVariationSide);
838    var checks = [];
839    if (checkMainAxis) {
840      checks.push(overflow[_basePlacement] <= 0);
841    }
842    if (checkAltAxis) {
843      checks.push(overflow[mainVariationSide] <= 0, overflow[altVariationSide] <= 0);
844    }
845    if (checks.every(function(check) {
846      return check;
847    })) {
848      firstFittingPlacement = placement;
849      makeFallbackChecks = false;
850      break;
851    }
852    checksMap.set(placement, checks);
853  }
854  if (makeFallbackChecks) {
855    var numberOfChecks = flipVariations ? 3 : 1;
856    var _loop = function _loop2(_i2) {
857      var fittingPlacement = placements2.find(function(placement2) {
858        var checks2 = checksMap.get(placement2);
859        if (checks2) {
860          return checks2.slice(0, _i2).every(function(check) {
861            return check;
862          });
863        }
864      });
865      if (fittingPlacement) {
866        firstFittingPlacement = fittingPlacement;
867        return "break";
868      }
869    };
870    for (var _i = numberOfChecks; _i > 0; _i--) {
871      var _ret = _loop(_i);
872      if (_ret === "break") break;
873    }
874  }
875  if (state.placement !== firstFittingPlacement) {
876    state.modifiersData[name]._skip = true;
877    state.placement = firstFittingPlacement;
878    state.reset = true;
879  }
880}
881const flip$1 = {
882  name: "flip",
883  enabled: true,
884  phase: "main",
885  fn: flip,
886  requiresIfExists: ["offset"],
887  data: {
888    _skip: false
889  }
890};
891function getSideOffsets(overflow, rect, preventedOffsets) {
892  if (preventedOffsets === void 0) {
893    preventedOffsets = {
894      x: 0,
895      y: 0
896    };
897  }
898  return {
899    top: overflow.top - rect.height - preventedOffsets.y,
900    right: overflow.right - rect.width + preventedOffsets.x,
901    bottom: overflow.bottom - rect.height + preventedOffsets.y,
902    left: overflow.left - rect.width - preventedOffsets.x
903  };
904}
905function isAnySideFullyClipped(overflow) {
906  return [top, right, bottom, left].some(function(side) {
907    return overflow[side] >= 0;
908  });
909}
910function hide(_ref) {
911  var state = _ref.state, name = _ref.name;
912  var referenceRect = state.rects.reference;
913  var popperRect = state.rects.popper;
914  var preventedOffsets = state.modifiersData.preventOverflow;
915  var referenceOverflow = detectOverflow(state, {
916    elementContext: "reference"
917  });
918  var popperAltOverflow = detectOverflow(state, {
919    altBoundary: true
920  });
921  var referenceClippingOffsets = getSideOffsets(referenceOverflow, referenceRect);
922  var popperEscapeOffsets = getSideOffsets(popperAltOverflow, popperRect, preventedOffsets);
923  var isReferenceHidden = isAnySideFullyClipped(referenceClippingOffsets);
924  var hasPopperEscaped = isAnySideFullyClipped(popperEscapeOffsets);
925  state.modifiersData[name] = {
926    referenceClippingOffsets,
927    popperEscapeOffsets,
928    isReferenceHidden,
929    hasPopperEscaped
930  };
931  state.attributes.popper = Object.assign({}, state.attributes.popper, {
932    "data-popper-reference-hidden": isReferenceHidden,
933    "data-popper-escaped": hasPopperEscaped
934  });
935}
936const hide$1 = {
937  name: "hide",
938  enabled: true,
939  phase: "main",
940  requiresIfExists: ["preventOverflow"],
941  fn: hide
942};
943function distanceAndSkiddingToXY(placement, rects, offset2) {
944  var basePlacement = getBasePlacement(placement);
945  var invertDistance = [left, top].indexOf(basePlacement) >= 0 ? -1 : 1;
946  var _ref = typeof offset2 === "function" ? offset2(Object.assign({}, rects, {
947    placement
948  })) : offset2, skidding = _ref[0], distance = _ref[1];
949  skidding = skidding || 0;
950  distance = (distance || 0) * invertDistance;
951  return [left, right].indexOf(basePlacement) >= 0 ? {
952    x: distance,
953    y: skidding
954  } : {
955    x: skidding,
956    y: distance
957  };
958}
959function offset(_ref2) {
960  var state = _ref2.state, options = _ref2.options, name = _ref2.name;
961  var _options$offset = options.offset, offset2 = _options$offset === void 0 ? [0, 0] : _options$offset;
962  var data = placements.reduce(function(acc, placement) {
963    acc[placement] = distanceAndSkiddingToXY(placement, state.rects, offset2);
964    return acc;
965  }, {});
966  var _data$state$placement = data[state.placement], x = _data$state$placement.x, y = _data$state$placement.y;
967  if (state.modifiersData.popperOffsets != null) {
968    state.modifiersData.popperOffsets.x += x;
969    state.modifiersData.popperOffsets.y += y;
970  }
971  state.modifiersData[name] = data;
972}
973const offset$1 = {
974  name: "offset",
975  enabled: true,
976  phase: "main",
977  requires: ["popperOffsets"],
978  fn: offset
979};
980function popperOffsets(_ref) {
981  var state = _ref.state, name = _ref.name;
982  state.modifiersData[name] = computeOffsets({
983    reference: state.rects.reference,
984    element: state.rects.popper,
985    placement: state.placement
986  });
987}
988const popperOffsets$1 = {
989  name: "popperOffsets",
990  enabled: true,
991  phase: "read",
992  fn: popperOffsets,
993  data: {}
994};
995function getAltAxis(axis) {
996  return axis === "x" ? "y" : "x";
997}
998function preventOverflow(_ref) {
999  var state = _ref.state, options = _ref.options, name = _ref.name;
1000  var _options$mainAxis = options.mainAxis, checkMainAxis = _options$mainAxis === void 0 ? true : _options$mainAxis, _options$altAxis = options.altAxis, checkAltAxis = _options$altAxis === void 0 ? false : _options$altAxis, boundary = options.boundary, rootBoundary = options.rootBoundary, altBoundary = options.altBoundary, padding = options.padding, _options$tether = options.tether, tether = _options$tether === void 0 ? true : _options$tether, _options$tetherOffset = options.tetherOffset, tetherOffset = _options$tetherOffset === void 0 ? 0 : _options$tetherOffset;
1001  var overflow = detectOverflow(state, {
1002    boundary,
1003    rootBoundary,
1004    padding,
1005    altBoundary
1006  });
1007  var basePlacement = getBasePlacement(state.placement);
1008  var variation = getVariation(state.placement);
1009  var isBasePlacement = !variation;
1010  var mainAxis = getMainAxisFromPlacement(basePlacement);
1011  var altAxis = getAltAxis(mainAxis);
1012  var popperOffsets2 = state.modifiersData.popperOffsets;
1013  var referenceRect = state.rects.reference;
1014  var popperRect = state.rects.popper;
1015  var tetherOffsetValue = typeof tetherOffset === "function" ? tetherOffset(Object.assign({}, state.rects, {
1016    placement: state.placement
1017  })) : tetherOffset;
1018  var normalizedTetherOffsetValue = typeof tetherOffsetValue === "number" ? {
1019    mainAxis: tetherOffsetValue,
1020    altAxis: tetherOffsetValue
1021  } : Object.assign({
1022    mainAxis: 0,
1023    altAxis: 0
1024  }, tetherOffsetValue);
1025  var offsetModifierState = state.modifiersData.offset ? state.modifiersData.offset[state.placement] : null;
1026  var data = {
1027    x: 0,
1028    y: 0
1029  };
1030  if (!popperOffsets2) {
1031    return;
1032  }
1033  if (checkMainAxis) {
1034    var _offsetModifierState$;
1035    var mainSide = mainAxis === "y" ? top : left;
1036    var altSide = mainAxis === "y" ? bottom : right;
1037    var len = mainAxis === "y" ? "height" : "width";
1038    var offset2 = popperOffsets2[mainAxis];
1039    var min$1 = offset2 + overflow[mainSide];
1040    var max$1 = offset2 - overflow[altSide];
1041    var additive = tether ? -popperRect[len] / 2 : 0;
1042    var minLen = variation === start ? referenceRect[len] : popperRect[len];
1043    var maxLen = variation === start ? -popperRect[len] : -referenceRect[len];
1044    var arrowElement = state.elements.arrow;
1045    var arrowRect = tether && arrowElement ? getLayoutRect(arrowElement) : {
1046      width: 0,
1047      height: 0
1048    };
vendor: 4,780 bytes, lines 1049-1147
1049    var arrowPaddingObject = state.modifiersData["arrow#persistent"] ? state.modifiersData["arrow#persistent"].padding : getFreshSideObject();
1050    var arrowPaddingMin = arrowPaddingObject[mainSide];
1051    var arrowPaddingMax = arrowPaddingObject[altSide];
1052    var arrowLen = within(0, referenceRect[len], arrowRect[len]);
1053    var minOffset = isBasePlacement ? referenceRect[len] / 2 - additive - arrowLen - arrowPaddingMin - normalizedTetherOffsetValue.mainAxis : minLen - arrowLen - arrowPaddingMin - normalizedTetherOffsetValue.mainAxis;
1054    var maxOffset = isBasePlacement ? -referenceRect[len] / 2 + additive + arrowLen + arrowPaddingMax + normalizedTetherOffsetValue.mainAxis : maxLen + arrowLen + arrowPaddingMax + normalizedTetherOffsetValue.mainAxis;
1055    var arrowOffsetParent = state.elements.arrow && getOffsetParent(state.elements.arrow);
1056    var clientOffset = arrowOffsetParent ? mainAxis === "y" ? arrowOffsetParent.clientTop || 0 : arrowOffsetParent.clientLeft || 0 : 0;
1057    var offsetModifierValue = (_offsetModifierState$ = offsetModifierState == null ? void 0 : offsetModifierState[mainAxis]) != null ? _offsetModifierState$ : 0;
1058    var tetherMin = offset2 + minOffset - offsetModifierValue - clientOffset;
1059    var tetherMax = offset2 + maxOffset - offsetModifierValue;
1060    var preventedOffset = within(tether ? min(min$1, tetherMin) : min$1, offset2, tether ? max(max$1, tetherMax) : max$1);
1061    popperOffsets2[mainAxis] = preventedOffset;
1062    data[mainAxis] = preventedOffset - offset2;
1063  }
1064  if (checkAltAxis) {
1065    var _offsetModifierState$2;
1066    var _mainSide = mainAxis === "x" ? top : left;
1067    var _altSide = mainAxis === "x" ? bottom : right;
1068    var _offset = popperOffsets2[altAxis];
1069    var _len = altAxis === "y" ? "height" : "width";
1070    var _min = _offset + overflow[_mainSide];
1071    var _max = _offset - overflow[_altSide];
1072    var isOriginSide = [top, left].indexOf(basePlacement) !== -1;
1073    var _offsetModifierValue = (_offsetModifierState$2 = offsetModifierState == null ? void 0 : offsetModifierState[altAxis]) != null ? _offsetModifierState$2 : 0;
1074    var _tetherMin = isOriginSide ? _min : _offset - referenceRect[_len] - popperRect[_len] - _offsetModifierValue + normalizedTetherOffsetValue.altAxis;
1075    var _tetherMax = isOriginSide ? _offset + referenceRect[_len] + popperRect[_len] - _offsetModifierValue - normalizedTetherOffsetValue.altAxis : _max;
1076    var _preventedOffset = tether && isOriginSide ? withinMaxClamp(_tetherMin, _offset, _tetherMax) : within(tether ? _tetherMin : _min, _offset, tether ? _tetherMax : _max);
1077    popperOffsets2[altAxis] = _preventedOffset;
1078    data[altAxis] = _preventedOffset - _offset;
1079  }
1080  state.modifiersData[name] = data;
1081}
1082const preventOverflow$1 = {
1083  name: "preventOverflow",
1084  enabled: true,
1085  phase: "main",
1086  fn: preventOverflow,
1087  requiresIfExists: ["offset"]
1088};
1089function getHTMLElementScroll(element) {
1090  return {
1091    scrollLeft: element.scrollLeft,
1092    scrollTop: element.scrollTop
1093  };
1094}
1095function getNodeScroll(node) {
1096  if (node === getWindow(node) || !isHTMLElement(node)) {
1097    return getWindowScroll(node);
1098  } else {
1099    return getHTMLElementScroll(node);
1100  }
1101}
1102function isElementScaled(element) {
1103  var rect = element.getBoundingClientRect();
1104  var scaleX = round(rect.width) / element.offsetWidth || 1;
1105  var scaleY = round(rect.height) / element.offsetHeight || 1;
1106  return scaleX !== 1 || scaleY !== 1;
1107}
1108function getCompositeRect(elementOrVirtualElement, offsetParent, isFixed) {
1109  if (isFixed === void 0) {
1110    isFixed = false;
1111  }
1112  var isOffsetParentAnElement = isHTMLElement(offsetParent);
1113  var offsetParentIsScaled = isHTMLElement(offsetParent) && isElementScaled(offsetParent);
1114  var documentElement = getDocumentElement(offsetParent);
1115  var rect = getBoundingClientRect(elementOrVirtualElement, offsetParentIsScaled, isFixed);
1116  var scroll = {
1117    scrollLeft: 0,
1118    scrollTop: 0
1119  };
1120  var offsets = {
1121    x: 0,
1122    y: 0
1123  };
1124  if (isOffsetParentAnElement || !isOffsetParentAnElement && !isFixed) {
1125    if (getNodeName(offsetParent) !== "body" || // https://github.com/popperjs/popper-core/issues/1078
1126    isScrollParent(documentElement)) {
1127      scroll = getNodeScroll(offsetParent);
1128    }
1129    if (isHTMLElement(offsetParent)) {
1130      offsets = getBoundingClientRect(offsetParent, true);
1131      offsets.x += offsetParent.clientLeft;
1132      offsets.y += offsetParent.clientTop;
1133    } else if (documentElement) {
1134      offsets.x = getWindowScrollBarX(documentElement);
1135    }
1136  }
1137  return {
1138    x: rect.left + scroll.scrollLeft - offsets.x,
1139    y: rect.top + scroll.scrollTop - offsets.y,
1140    width: rect.width,
1141    height: rect.height
1142  };
1143}
1144function order(modifiers) {
1145  var map = /* @__PURE__ */ new Map();
1146  var visited = /* @__PURE__ */ new Set();
1147  var result = [];
vendor: 4,092 bytes, lines 1148-1263
1148  modifiers.forEach(function(modifier) {
1149    map.set(modifier.name, modifier);
1150  });
1151  function sort(modifier) {
1152    visited.add(modifier.name);
1153    var requires = [].concat(modifier.requires || [], modifier.requiresIfExists || []);
1154    requires.forEach(function(dep) {
1155      if (!visited.has(dep)) {
1156        var depModifier = map.get(dep);
1157        if (depModifier) {
1158          sort(depModifier);
1159        }
1160      }
1161    });
1162    result.push(modifier);
1163  }
1164  modifiers.forEach(function(modifier) {
1165    if (!visited.has(modifier.name)) {
1166      sort(modifier);
1167    }
1168  });
1169  return result;
1170}
1171function orderModifiers(modifiers) {
1172  var orderedModifiers = order(modifiers);
1173  return modifierPhases.reduce(function(acc, phase) {
1174    return acc.concat(orderedModifiers.filter(function(modifier) {
1175      return modifier.phase === phase;
1176    }));
1177  }, []);
1178}
1179function debounce(fn2) {
1180  var pending;
1181  return function() {
1182    if (!pending) {
1183      pending = new Promise(function(resolve) {
1184        Promise.resolve().then(function() {
1185          pending = void 0;
1186          resolve(fn2());
1187        });
1188      });
1189    }
1190    return pending;
1191  };
1192}
1193function mergeByName(modifiers) {
1194  var merged = modifiers.reduce(function(merged2, current) {
1195    var existing = merged2[current.name];
1196    merged2[current.name] = existing ? Object.assign({}, existing, current, {
1197      options: Object.assign({}, existing.options, current.options),
1198      data: Object.assign({}, existing.data, current.data)
1199    }) : current;
1200    return merged2;
1201  }, {});
1202  return Object.keys(merged).map(function(key) {
1203    return merged[key];
1204  });
1205}
1206var DEFAULT_OPTIONS = {
1207  placement: "bottom",
1208  modifiers: [],
1209  strategy: "absolute"
1210};
1211function areValidElements() {
1212  for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {
1213    args[_key] = arguments[_key];
1214  }
1215  return !args.some(function(element) {
1216    return !(element && typeof element.getBoundingClientRect === "function");
1217  });
1218}
1219function popperGenerator(generatorOptions) {
1220  if (generatorOptions === void 0) {
1221    generatorOptions = {};
1222  }
1223  var _generatorOptions = generatorOptions, _generatorOptions$def = _generatorOptions.defaultModifiers, defaultModifiers2 = _generatorOptions$def === void 0 ? [] : _generatorOptions$def, _generatorOptions$def2 = _generatorOptions.defaultOptions, defaultOptions = _generatorOptions$def2 === void 0 ? DEFAULT_OPTIONS : _generatorOptions$def2;
1224  return function createPopper2(reference2, popper2, options) {
1225    if (options === void 0) {
1226      options = defaultOptions;
1227    }
1228    var state = {
1229      placement: "bottom",
1230      orderedModifiers: [],
1231      options: Object.assign({}, DEFAULT_OPTIONS, defaultOptions),
1232      modifiersData: {},
1233      elements: {
1234        reference: reference2,
1235        popper: popper2
1236      },
1237      attributes: {},
1238      styles: {}
1239    };
1240    var effectCleanupFns = [];
1241    var isDestroyed = false;
1242    var instance = {
1243      state,
1244      setOptions: function setOptions(setOptionsAction) {
1245        var options2 = typeof setOptionsAction === "function" ? setOptionsAction(state.options) : setOptionsAction;
1246        cleanupModifierEffects();
1247        state.options = Object.assign({}, defaultOptions, state.options, options2);
1248        state.scrollParents = {
1249          reference: isElement(reference2) ? listScrollParents(reference2) : reference2.contextElement ? listScrollParents(reference2.contextElement) : [],
1250          popper: listScrollParents(popper2)
1251        };
1252        var orderedModifiers = orderModifiers(mergeByName([].concat(defaultModifiers2, state.options.modifiers)));
1253        state.orderedModifiers = orderedModifiers.filter(function(m) {
1254          return m.enabled;
1255        });
1256        runModifierEffects();
1257        return instance.update();
1258      },
1259      // Sync update – it will always be executed, even if not necessary. This
1260      // is useful for low frequency updates where sync behavior simplifies the
1261      // logic.
1262      // For high frequency updates (e.g. `resize` and `scroll` events), always
1263      // prefer the async Popper#update method
1264      forceUpdate: function forceUpdate() {
1265        if (isDestroyed) {
1266          return;
1267        }
1268        var _state$elements = state.elements, reference3 = _state$elements.reference, popper3 = _state$elements.popper;
1269        if (!areValidElements(reference3, popper3)) {
1270          return;
1271        }
1272        state.rects = {
1273          reference: getCompositeRect(reference3, getOffsetParent(popper3), state.options.strategy === "fixed"),
1274          popper: getLayoutRect(popper3)
1275        };
1276        state.reset = false;
1277        state.placement = state.options.placement;
1278        state.orderedModifiers.forEach(function(modifier) {
1279          return state.modifiersData[modifier.name] = Object.assign({}, modifier.data);
1280        });
1281        for (var index = 0; index < state.orderedModifiers.length; index++) {
1282          if (state.reset === true) {
1283            state.reset = false;
1284            index = -1;
1285            continue;
1286          }
1287          var _state$orderedModifie = state.orderedModifiers[index], fn2 = _state$orderedModifie.fn, _state$orderedModifie2 = _state$orderedModifie.options, _options = _state$orderedModifie2 === void 0 ? {} : _state$orderedModifie2, name = _state$orderedModifie.name;
1288          if (typeof fn2 === "function") {
1289            state = fn2({
1290              state,
1291              options: _options,
1292              name,
1293              instance
1294            }) || state;
1295          }
1296        }
1297      },
1298      // Async and optimistically optimized update – it will not be executed if
1299      // not necessary (debounced to run at most once-per-tick)
1300      update: debounce(function() {
1301        return new Promise(function(resolve) {
1302          instance.forceUpdate();
1303          resolve(state);
1304        });
1305      }),
1306      destroy: function destroy() {
1307        cleanupModifierEffects();
1308        isDestroyed = true;
1309      }
1310    };
1311    if (!areValidElements(reference2, popper2)) {
1312      return instance;
1313    }
1314    instance.setOptions(options).then(function(state2) {
1315      if (!isDestroyed && options.onFirstUpdate) {
1316        options.onFirstUpdate(state2);
1317      }
1318    });
1319    function runModifierEffects() {
1320      state.orderedModifiers.forEach(function(_ref) {
1321        var name = _ref.name, _ref$options = _ref.options, options2 = _ref$options === void 0 ? {} : _ref$options, effect2 = _ref.effect;
1322        if (typeof effect2 === "function") {
1323          var cleanupFn = effect2({
1324            state,
1325            name,
1326            instance,
1327            options: options2
1328          });
1329          var noopFn = function noopFn2() {
1330          };
1331          effectCleanupFns.push(cleanupFn || noopFn);
1332        }
1333      });
1334    }
1335    function cleanupModifierEffects() {
1336      effectCleanupFns.forEach(function(fn2) {
1337        return fn2();
1338      });
1339      effectCleanupFns = [];
1340    }
1341    return instance;
1342  };
1343}
1344var defaultModifiers = [eventListeners, popperOffsets$1, computeStyles$1, applyStyles$1, offset$1, flip$1, preventOverflow$1, arrow$1, hide$1];
1345var createPopper = /* @__PURE__ */ popperGenerator({
1346  defaultModifiers
1347});
1348const TableDropdown = ({
1349  dropdownButton,
1350  dropdownContent
1351}) => {
1352  const [isOpen, setIsOpen] = reactExports.useState(false);
1353  const buttonRef = reactExports.useRef(null);
1354  const contentRef = reactExports.useRef(null);
1355  const popperInstanceRef = reactExports.useRef(null);
1356  const close = (event) => {
1357    const target = event.target;
1358    if (buttonRef.current && contentRef.current) {
1359      const dropdown = buttonRef.current.closest("div");
1360      if (dropdown && !dropdown.contains(target)) {
1361        setIsOpen(false);
1362      }
1363    }
1364  };
1365  const toggle = () => {
1366    setIsOpen(!isOpen);
1367    if (popperInstanceRef.current) {
1368      popperInstanceRef.current.update();
1369    }
1370  };
1371  reactExports.useEffect(() => {
1372    document.addEventListener("click", close);
1373    if (buttonRef.current && contentRef.current) {
1374      popperInstanceRef.current = createPopper(
1375        buttonRef.current,
1376        contentRef.current,
1377        {
1378          placement: "bottom-end",
1379          modifiers: [
1380            {
1381              name: "offset",
1382              options: {
1383                offset: [0, 4]
1384              }
1385            }
1386          ]
1387        }
1388      );
1389    }
1390    return () => {
1391      document.removeEventListener("click", close);
1392      if (popperInstanceRef.current) {
1393        popperInstanceRef.current.destroy();
1394        popperInstanceRef.current = null;
1395      }
1396    };
1397  }, []);
1398  return /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { children: [
1399    /* @__PURE__ */ jsxRuntimeExports.jsx("div", { onClick: toggle, ref: buttonRef, children: dropdownButton }),
1400    /* @__PURE__ */ jsxRuntimeExports.jsx(
1401      "div",
1402      {
1403        className: "z-50 fixed inset-0 pointer-events-none",
1404        style: { display: isOpen ? "block" : "none" },
1405        children: /* @__PURE__ */ jsxRuntimeExports.jsx("div", { ref: contentRef, className: "pointer-events-auto inline-block", children: /* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "bg-white border border-gray-200 rounded-lg shadow-xl dark:border-gray-800 dark:bg-gray-800 min-w-32 max-w-40 overflow-hidden", children: /* @__PURE__ */ jsxRuntimeExports.jsx(
1406          "div",
1407          {
1408            className: "py-1",
1409            role: "menu",
1410            "aria-orientation": "vertical",
1411            "aria-labelledby": "options-menu",
1412            children: dropdownContent
1413          }
1414        ) }) })
1415      }
1416    )
1417  ] });
1418};
1419export {
1420  TableDropdown as T
1421};

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.