import React from 'react';
import FormSettingContext from "./FormSettingContext";

/**
 * @title: 表单设置Provider
 * @description: 提供表单设置信息
 */
var FormSettingProvider = function FormSettingProvider(props) {
  var children = props.children,
    renderMode = props.renderMode,
    groupInfoPosition = props.groupInfoPosition,
    currentValue = props.currentValue,
    size = props.size;
  var value = React.useMemo(function () {
    return {
      renderMode: renderMode,
      groupInfoPosition: groupInfoPosition,
      currentValue: currentValue,
      size: size
    };
  }, [renderMode, groupInfoPosition, currentValue, size]);
  return /*#__PURE__*/React.createElement(FormSettingContext.Provider, {
    value: value
  }, children);
};
export default FormSettingProvider;