"use strict";

Object.defineProperty(exports, "__esModule", {
  value: true
});
exports.useIONewTypeface = exports.IONewTypefaceContextProvider = exports.IONewTypefaceContext = void 0;
var _react = require("react");
var _jsxRuntime = require("react/jsx-runtime");
/**
 * Experimental Context for new UI Representations
 */
const IONewTypefaceContext = exports.IONewTypefaceContext = /*#__PURE__*/(0, _react.createContext)({
  newTypefaceEnabled: true,
  setNewTypefaceEnabled: () => void 0
});
const useIONewTypeface = () => (0, _react.useContext)(IONewTypefaceContext);
exports.useIONewTypeface = useIONewTypeface;
const IONewTypefaceContextProvider = ({
  children,
  isNewTypefaceEnabled
}) => {
  const [newTypefaceEnabled, setNewTypefaceEnabled] = (0, _react.useState)(isNewTypefaceEnabled ?? true);
  return /*#__PURE__*/(0, _jsxRuntime.jsx)(IONewTypefaceContext.Provider, {
    value: {
      newTypefaceEnabled,
      setNewTypefaceEnabled
    },
    children: children
  });
};
exports.IONewTypefaceContextProvider = IONewTypefaceContextProvider;
//# sourceMappingURL=IONewTypefaceContextProvider.js.map