UNPKG

json-joy

Version:

Collection of libraries for building collaborative editing apps.

15 lines 644 B
import * as React from 'react'; import { ContextPane } from 'nice-ui/lib/4-card/ContextMenu/ContextPane'; export const FormattingPane = ({ onEsc, children, ...rest }) => { return (React.createElement("div", { onKeyDown: onEsc ? (e) => { if (e.key === 'Escape') { e.preventDefault(); e.stopPropagation(); onEsc(); } } : void 0 }, React.createElement(ContextPane, { ...rest, style: { width: 'calc(min(600px, max(65vw, 260px)))', ...rest.style } }, children))); }; //# sourceMappingURL=FormattingPane.js.map