@atlaskit/editor-common
Version:
A package that contains common classes and components for editor and renderer
13 lines (12 loc) • 738 B
JavaScript
import _extends from "@babel/runtime/helpers/extends";
import React, { forwardRef } from 'react';
import { expValEquals } from '@atlaskit/tmp-editor-statsig/exp-val-equals';
import { isSSR } from '../core-utils/is-ssr';
/**
* A component that serves as a placeholder for the content DOM of a ProseMirror NodeView.
* It forwards a ref to the underlying div element, which can be used to access the content DOM for rendering the NodeView's content.
*/
export const NodeViewContentHole = /*#__PURE__*/forwardRef((props, ref) => /*#__PURE__*/React.createElement("div", _extends({}, props, {
ref: ref,
"data-ssr-content-dom-ref": isSSR() && expValEquals('platform_editor_editor_ssr_streaming', 'isEnabled', true) ? '' : undefined
})));