import React from 'react';
import { RawIntlProvider } from 'react-intl';
import { expValEquals } from '@atlaskit/tmp-editor-statsig/exp-val-equals';
import { isSSR } from '../core-utils/is-ssr';
export function ExtensionSSRReactContextsProvider(_ref) {
  var children = _ref.children,
    intl = _ref.intl;
  if (!expValEquals('platform_editor_editor_ssr_streaming', 'isEnabled', true) || !isSSR()) {
    return children;
  }
  if (!intl) {
    return children;
  }
  return /*#__PURE__*/React.createElement(RawIntlProvider, {
    value: intl
  }, children);
}