UNPKG

@atlaskit/editor-core

Version:

A package contains Atlassian editor core functionality

89 lines (82 loc) 4.87 kB
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.paragraphStylesWithScaledMargin = exports.paragraphStylesUGCRefreshed = exports.paragraphStylesUGCModernized = exports.paragraphStylesOldWithScaledMargin = exports.paragraphStylesOld = void 0; var _react = require("@emotion/react"); /* eslint-disable @atlaskit/ui-styling-standard/use-compiled */ var blockNodesVerticalMargin = '0.75rem'; var scaledBlockNodesVerticalMargin = '0.75em'; // When both platform_editor_content_mode_button_mvp & confluence_compact_text_format are cleaned up, // simplify the name/ use the other paragraph style name // eslint-disable-next-line @atlaskit/ui-styling-standard/no-exported-styles var paragraphStylesWithScaledMargin = exports.paragraphStylesWithScaledMargin = (0, _react.css)({ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-nested-selectors -- Ignored via go/DSP-18766 '.ProseMirror p': { // The `editor.font.body` token is used for the UGC typography theme. // We don't use `editorUGCToken('editor.font.body')` here because we want to build this styles statically. // See platform/packages/editor/editor-common/src/ugc-tokens/get-editor-ugc-token.tsx // eslint-disable-next-line @atlaskit/design-system/use-tokens-typography font: 'normal 400 1em/1.714 "Atlassian Sans", ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", Ubuntu, "Helvetica Neue", sans-serif', marginTop: scaledBlockNodesVerticalMargin, marginBottom: 0 } }); // When both platform_editor_content_mode_button_mvp & confluence_compact_text_format are cleaned up, // simplify the name/ use the other paragraph style name // eslint-disable-next-line @atlaskit/ui-styling-standard/no-exported-styles var paragraphStylesOldWithScaledMargin = exports.paragraphStylesOldWithScaledMargin = (0, _react.css)({ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-nested-selectors -- Ignored via go/DSP-18766 '.ProseMirror p': { // eslint-disable-next-line @atlaskit/design-system/use-tokens-typography fontSize: '1em', // eslint-disable-next-line @atlaskit/design-system/use-tokens-typography lineHeight: 1.714, fontWeight: "var(--ds-font-weight-regular, 400)", marginTop: scaledBlockNodesVerticalMargin, marginBottom: 0, // eslint-disable-next-line @atlaskit/design-system/use-tokens-typography letterSpacing: '-0.005em' } }); // eslint-disable-next-line @atlaskit/ui-styling-standard/no-exported-styles var paragraphStylesUGCRefreshed = exports.paragraphStylesUGCRefreshed = (0, _react.css)({ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-nested-selectors -- Ignored via go/DSP-18766 '.ProseMirror p': { // The `editor.font.body` token is used for the UGC typography theme. // We don't use `editorUGCToken('editor.font.body')` here because we want to build this styles statically. // See platform/packages/editor/editor-common/src/ugc-tokens/get-editor-ugc-token.tsx // eslint-disable-next-line @atlaskit/design-system/use-tokens-typography font: 'normal 400 1em/1.714 "Atlassian Sans", ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", Ubuntu, "Helvetica Neue", sans-serif', marginTop: blockNodesVerticalMargin, marginBottom: 0 } }); // eslint-disable-next-line @atlaskit/ui-styling-standard/no-exported-styles var paragraphStylesUGCModernized = exports.paragraphStylesUGCModernized = (0, _react.css)({ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-nested-selectors -- Ignored via go/DSP-18766 '.ProseMirror p': { // The `editor.font.body` token is used for the UGC typography theme. // We don't use `editorUGCToken('editor.font.body')` here because we want to build this styles statically. // See platform/packages/editor/editor-common/src/ugc-tokens/get-editor-ugc-token.tsx // eslint-disable-next-line @atlaskit/design-system/use-tokens-typography font: 'normal 400 1em/1.714 ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", Ubuntu, "Helvetica Neue", sans-serif', marginTop: blockNodesVerticalMargin, marginBottom: 0 } }); // eslint-disable-next-line @atlaskit/ui-styling-standard/no-exported-styles var paragraphStylesOld = exports.paragraphStylesOld = (0, _react.css)({ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-nested-selectors -- Ignored via go/DSP-18766 '.ProseMirror p': { // eslint-disable-next-line @atlaskit/design-system/use-tokens-typography fontSize: '1em', // eslint-disable-next-line @atlaskit/design-system/use-tokens-typography lineHeight: 1.714, fontWeight: "var(--ds-font-weight-regular, 400)", marginTop: blockNodesVerticalMargin, marginBottom: 0, // eslint-disable-next-line @atlaskit/design-system/use-tokens-typography letterSpacing: '-0.005em' } });