"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.usePopover = void 0;
const react_1 = require("react");
const usePopover = () => {
    const [anchor, setAnchor] = (0, react_1.useState)(null);
    const open = (event) => setAnchor(event.currentTarget);
    const close = () => setAnchor(null);
    const actions = {
        open,
        close,
    };
    return { isOpen: Boolean(anchor), anchor, actions };
};
exports.usePopover = usePopover;
