import { jsx } from "react/jsx-runtime";
import * as React from "react";
import { FaCheck } from "react-icons/fa";
import { ImSpinner2, ImMinus } from "react-icons/im";
import { IoIosWarning } from "react-icons/io";
import { RiCloseLine } from "react-icons/ri";
import { stripNullOrUndefined } from "../../utils/objects.js";
const systemDefaults = {
  validationMode: "both",
  buttonDisplaySize: "medium",
  buttonDisplayStyle: "primary",
  buttonPendingPosition: "right",
  inputStatusPosition: "right",
  inputDisplaySize: "medium",
  hideInputErrorIconOnStatus: true,
  disableControlOnPending: true,
  scrollValidationErrorsIntoView: false,
  requiredIndicator: "*",
  validationErrorIcon: jsx(IoIosWarning, { size: 24 }),
  spinnerIcon: jsx(ImSpinner2, {}),
  dialogCloseButtonIcon: jsx(RiCloseLine, { size: 24 }),
  globalPortalTo: typeof document !== "undefined" ? document.body : void 0,
  toastDuration: 5e3,
  toastPosition: "bottom-right",
  toastCloseButtonIcon: jsx(RiCloseLine, { size: 18 }),
  toastDisplayMode: "add",
  checkboxCustomIndicator: jsx(FaCheck, {}),
  checkboxCustomIndeterminateIndicator: jsx(ImMinus, {}),
  tooltipDelay: 700,
  tooltipShowArrow: false,
  tooltipSide: "top",
  autoValidate: true
};
const ArmstrongConfigContext = React.createContext(systemDefaults);
const ArmstrongConfigProvider = ({ children, ...config }) => {
  return jsx(ArmstrongConfigContext.Provider, { value: { ...systemDefaults, ...stripNullOrUndefined(config) }, children });
};
const useArmstrongConfig = (localOverrides) => {
  const config = React.useContext(ArmstrongConfigContext);
  return { ...config, ...stripNullOrUndefined(localOverrides) };
};
export {
  ArmstrongConfigProvider,
  useArmstrongConfig
};
//# sourceMappingURL=config.context.js.map
