import { jsx as r } from "react/jsx-runtime";
import { useCallback as s } from "react";
import l from "../../hooks/useDialogNavigationContext.js";
import m from "../../../button/Button.js";
const g = ({ to: o, onClick: t, ...i }) => {
  const { navigateTo: a } = l(), n = s(() => {
    const e = () => a(o);
    t ? t(e) : e();
  }, [a, o, t]);
  return /* @__PURE__ */ r(m, { ...i, type: "button", onClick: n });
};
g.displayName = "DialogNavigateButton";
export {
  g as default
};
//# sourceMappingURL=DialogNavigateButton.js.map
