: str_replace(): Passing null to parameter #2 ($replace) of type array|string is deprecated in
if (event.defaultPrevented)
if (showTimeoutRef.current)
if (!showOnHoverProp(event))
const element = event.currentTarget;
store.setAnchorElement(element);
store.setDisclosureElement(element);
const { showTimeout, timeout } = store.getState();
const showHovercard = () => {
showTimeoutRef.current = 0;
store == null ? void 0 : store.setAnchorElement(element);
store == null ? void 0 : store.show();
store == null ? void 0 : store.setDisclosureElement(element);
const timeoutMs = showTimeout != null ? showTimeout : timeout;
showTimeoutRef.current = window.setTimeout(showHovercard, timeoutMs);
const ref = (0,external_React_.useCallback)(
const { anchorElement } = store.getState();
if (anchorElement == null ? void 0 : anchorElement.isConnected)
store.setAnchorElement(element);
props = _4R3V3JGP_spreadProps(_4R3V3JGP_spreadValues({}, props), {
ref: useMergeRefs(ref, props.ref),
props = useFocusable(props);
var HovercardAnchor = createComponent(
const htmlProps = useHovercardAnchor(props);
return _3ORBWXWF_createElement("a", htmlProps);
;// CONCATENATED MODULE: ./node_modules/@ariakit/react-core/esm/__chunks/MNFF5YOJ.js
// src/tooltip/tooltip-context.tsx
var MNFF5YOJ_ctx = createStoreContext(
[HovercardContextProvider],
[HovercardScopedContextProvider]
var useTooltipContext = MNFF5YOJ_ctx.useContext;
var useTooltipScopedContext = MNFF5YOJ_ctx.useScopedContext;
var useTooltipProviderContext = MNFF5YOJ_ctx.useProviderContext;
var TooltipContextProvider = MNFF5YOJ_ctx.ContextProvider;
var TooltipScopedContextProvider = MNFF5YOJ_ctx.ScopedContextProvider;
;// CONCATENATED MODULE: ./node_modules/@ariakit/react-core/esm/tooltip/tooltip-anchor.js
// src/tooltip/tooltip-anchor.ts
var globalStore = createStore({
var useTooltipAnchor = createHook(
var _b = _a, { store, showOnHover = true } = _b, props = __objRest(_b, ["store", "showOnHover"]);
const context = useTooltipProviderContext();
store = store || context;
const canShowOnHoverRef = (0,external_React_.useRef)(false);
(0,external_React_.useEffect)(() => {
return sync(store, ["mounted"], (state) => {
canShowOnHoverRef.current = false;
(0,external_React_.useEffect)(() => {
return sync(store, ["mounted", "skipTimeout"], (state) => {
const { activeStore } = globalStore.getState();
if (activeStore !== store) {
activeStore == null ? void 0 : activeStore.hide();
return globalStore.setState("activeStore", store);
const id = setTimeout(() => {
const { activeStore } = globalStore.getState();
if (activeStore !== store)
globalStore.setState("activeStore", null);
return () => clearTimeout(id);
const onMouseEnterProp = props.onMouseEnter;
const onMouseEnter = useEvent((event) => {
onMouseEnterProp == null ? void 0 : onMouseEnterProp(event);
canShowOnHoverRef.current = true;
const onFocusVisibleProp = props.onFocusVisible;
const onFocusVisible = useEvent((event) => {
onFocusVisibleProp == null ? void 0 : onFocusVisibleProp(event);
if (event.defaultPrevented)
store == null ? void 0 : store.setAnchorElement(event.currentTarget);
store == null ? void 0 : store.show();
const onBlurProp = props.onBlur;
const onBlur = useEvent((event) => {
onBlurProp == null ? void 0 : onBlurProp(event);
if (event.defaultPrevented)
const { activeStore } = globalStore.getState();
if (activeStore === store) {
globalStore.setState("activeStore", null);
const type = store.useState("type");
const contentId = store.useState((state) => {
return (_a2 = state.contentElement) == null ? void 0 : _a2.id;
props = _4R3V3JGP_spreadProps(_4R3V3JGP_spreadValues({
"aria-labelledby": type === "label" ? contentId : void 0,
"aria-describedby": type === "description" ? contentId : void 0
props = useHovercardAnchor(_4R3V3JGP_spreadValues({
showOnHover: (event) => {
if (!canShowOnHoverRef.current)
if (isFalsyBooleanCallback(showOnHover, event))
const { activeStore } = globalStore.getState();
store == null ? void 0 : store.show();
var TooltipAnchor = createComponent((props) => {
const htmlProps = useTooltipAnchor(props);
return _3ORBWXWF_createElement("div", htmlProps);
;// CONCATENATED MODULE: ./node_modules/@ariakit/react-core/esm/__chunks/YMV43K4F.js
// src/hovercard/utils/polygon.ts
function getEventPoint(event) {
return [event.clientX, event.clientY];
function isPointInPolygon(point, polygon) {
const length = polygon.length;
for (let l = length, i = 0, j = l - 1; i < l; j = i++) {
const [xi, yi] = polygon[i];
const [xj, yj] = polygon[j];
const [, vy] = polygon[j === 0 ? l - 1 : j - 1] || [0, 0];
const where = (yi - yj) * (x - xi) - (xi - xj) * (y - yi);
} else if (y == yi && (x >= xj && x <= xi || x >= xi && x <= xj)) {
function getEnterPointPlacement(enterPoint, rect) {
const { top, right, bottom, left } = rect;
const [x, y] = enterPoint;
const placementX = x < left ? "left" : x > right ? "right" : null;
const placementY = y < top ? "top" : y > bottom ? "bottom" : null;
return [placementX, placementY];
function getElementPolygon(element, enterPoint) {
const rect = element.getBoundingClientRect();
const { top, right, bottom, left } = rect;
const [x, y] = getEnterPointPlacement(enterPoint, rect);
const polygon = [enterPoint];
polygon.push([x === "left" ? left : right, top]);
polygon.push([x === "left" ? right : left, top]);
polygon.push([x === "left" ? right : left, bottom]);
polygon.push([x === "left" ? left : right, bottom]);
} else if (y === "top") {
polygon.push([left, top]);
polygon.push([left, bottom]);
polygon.push([right, bottom]);
polygon.push([right, top]);
polygon.push([left, bottom]);
polygon.push([left, top]);
polygon.push([right, top]);
polygon.push([right, bottom]);
;// CONCATENATED MODULE: ./node_modules/@ariakit/react-core/esm/__chunks/MKDDWKFK.js
// src/dialog/utils/is-backdrop.ts
function MKDDWKFK_isBackdrop(element, ...ids) {
const backdrop = element.getAttribute("data-backdrop");
return ids.some((id) => backdrop === id);
;// CONCATENATED MODULE: ./node_modules/@ariakit/react-core/esm/__chunks/X6WIMZJE.js
// src/dialog/utils/orchestrate.ts
var cleanups = /* @__PURE__ */ new WeakMap();
function orchestrate(element, key, setup) {
if (!cleanups.has(element)) {
cleanups.set(element, /* @__PURE__ */ new Map());
const elementCleanups = cleanups.get(element);
const prevCleanup = elementCleanups.get(key);
elementCleanups.set(key, setup());
(_a = elementCleanups.get(key)) == null ? void 0 : _a();
elementCleanups.delete(key);
const nextCleanup = () => {
elementCleanups.delete(key);
elementCleanups.set(key, nextCleanup);
const isCurrent = elementCleanups.get(key) === nextCleanup;
elementCleanups.set(key, prevCleanup);
function setAttribute(element, attr, value) {
const previousValue = element.getAttribute(attr);
element.setAttribute(attr, value);
if (previousValue == null) {
element.removeAttribute(attr);
element.setAttribute(attr, previousValue);
return orchestrate(element, attr, setup);
function setProperty(element, property, value) {
const exists = property in element;
const previousValue = element[property];
element[property] = value;
delete element[property];
element[property] = previousValue;
return orchestrate(element, property, setup);
function assignStyle(element, style) {
const prevStyle = element.style.cssText;
Object.assign(element.style, style);
element.style.cssText = prevStyle;
return orchestrate(element, "style", setup);
function setCSSProperty(element, property, value) {
const previousValue = element.style.getPropertyValue(property);
element.style.setProperty(property, value);
element.style.setProperty(property, previousValue);
element.style.removeProperty(property);
return orchestrate(element, property, setup);
;// CONCATENATED MODULE: ./node_modules/@ariakit/react-core/esm/__chunks/72E5EPFF.js
// src/dialog/utils/walk-tree-outside.ts
var ignoreTags = ["SCRIPT", "STYLE"];
function getSnapshotPropertyName(id) {
return `__ariakit-dialog-snapshot-${id}`;
function inSnapshot(id, element) {
const doc = DLOEKDPY_getDocument(element);
const propertyName = getSnapshotPropertyName(id);
if (!doc.body[propertyName])
if (element === doc.body)
if (!!element[propertyName])
if (!element.parentElement)
element = element.parentElement;
function isValidElement(id, element, ignoredElements) {
if (ignoreTags.includes(element.tagName))
if (!inSnapshot(id, element))
return !ignoredElements.some(
(enabledElement) => enabledElement && contains(element, enabledElement)
function _72E5EPFF_walkTreeOutside(id, elements, callback, ancestorCallback) {
for (let element of elements) {
if (!(element == null ? void 0 : element.isConnected))
const hasAncestorAlready = elements.some((maybeAncestor) => {
if (maybeAncestor === element)
return maybeAncestor.contains(element);
const doc = DLOEKDPY_getDocument(element);
const originalElement = element;
while (element.parentElement && element !== doc.body) {
ancestorCallback == null ? void 0 : ancestorCallback(element.parentElement, originalElement);
if (!hasAncestorAlready) {
for (const child of element.parentElement.children) {
if (isValidElement(id, child, elements)) {
callback(child, originalElement);
element = element.parentElement;
function createWalkTreeSnapshot(id, elements) {
const { body } = DLOEKDPY_getDocument(elements[0]);
const markElement = (element) => {
cleanups.push(setProperty(element, getSnapshotPropertyName(id), true));
_72E5EPFF_walkTreeOutside(id, elements, markElement);
setProperty(body, getSnapshotPropertyName(id), true),
() => cleanups.forEach((fn) => fn())
;// CONCATENATED MODULE: ./node_modules/@ariakit/react-core/esm/__chunks/TL67WVI6.js
// src/dialog/utils/mark-tree-outside.ts
function getPropertyName(id = "", ancestor = false) {
return `__ariakit-dialog-${ancestor ? "ancestor" : "outside"}${id ? `-${id}` : ""}`;
function markElement(element, id = "") {
setProperty(element, getPropertyName(), true),
setProperty(element, getPropertyName(id), true)
function markAncestor(element, id = "") {
setProperty(element, getPropertyName("", true), true),
setProperty(element, getPropertyName(id, true), true)
function isElementMarked(element, id) {