@atlaskit/renderer 109.29.5 → 109.30.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +18 -0
- package/dist/cjs/react/marks/alignment.js +3 -1
- package/dist/cjs/react/marks/backgroundColor.js +6 -2
- package/dist/cjs/react/marks/breakout.js +3 -1
- package/dist/cjs/react/marks/code.js +3 -1
- package/dist/cjs/react/marks/indentation.js +1 -0
- package/dist/cjs/react/marks/strike.js +9 -5
- package/dist/cjs/react/marks/textColor.js +6 -2
- package/dist/cjs/react/nodes/blockCard.js +1 -0
- package/dist/cjs/react/nodes/bulletList.js +1 -0
- package/dist/cjs/react/nodes/codeBlock/codeBlock.js +3 -1
- package/dist/cjs/react/nodes/codeBlock/components/codeBlockContainer.js +13 -10
- package/dist/cjs/react/nodes/codeBlock/components/codeBlockCopyButton.js +3 -1
- package/dist/cjs/react/nodes/codeBlock/components/codeBlockWrapButton.js +3 -1
- package/dist/cjs/react/nodes/codeBlock/components/lightWeightCodeBlock.js +3 -0
- package/dist/cjs/react/nodes/codeBlock/windowedCodeBlock.js +6 -2
- package/dist/cjs/react/nodes/date.js +12 -7
- package/dist/cjs/react/nodes/doc.js +4 -1
- package/dist/cjs/react/nodes/embedCard.js +1 -0
- package/dist/cjs/react/nodes/extension.js +3 -1
- package/dist/cjs/react/nodes/heading-anchor.js +7 -4
- package/dist/cjs/react/nodes/media/index.js +4 -10
- package/dist/cjs/react/nodes/mediaGroup.js +1 -0
- package/dist/cjs/react/nodes/multiBodiedExtension.js +6 -1
- package/dist/cjs/react/nodes/orderedList.js +1 -0
- package/dist/cjs/react/nodes/panel.js +4 -1
- package/dist/cjs/react/nodes/table/colgroup.js +9 -4
- package/dist/cjs/react/nodes/table/sticky.js +8 -2
- package/dist/cjs/react/nodes/table.js +2 -0
- package/dist/cjs/react/nodes/tableCell.js +6 -1
- package/dist/cjs/react/nodes/tableRow.js +4 -1
- package/dist/cjs/react/nodes/unknownBlock.js +1 -0
- package/dist/cjs/ui/ExtensionRenderer.js +7 -4
- package/dist/cjs/ui/Renderer/index.js +4 -2
- package/dist/cjs/ui/Renderer/style.js +4 -5
- package/dist/es2019/react/marks/alignment.js +3 -1
- package/dist/es2019/react/marks/backgroundColor.js +6 -2
- package/dist/es2019/react/marks/breakout.js +3 -1
- package/dist/es2019/react/marks/code.js +3 -1
- package/dist/es2019/react/marks/indentation.js +1 -0
- package/dist/es2019/react/marks/strike.js +9 -5
- package/dist/es2019/react/marks/textColor.js +6 -2
- package/dist/es2019/react/nodes/blockCard.js +1 -0
- package/dist/es2019/react/nodes/bulletList.js +1 -0
- package/dist/es2019/react/nodes/codeBlock/codeBlock.js +3 -1
- package/dist/es2019/react/nodes/codeBlock/components/codeBlockContainer.js +13 -10
- package/dist/es2019/react/nodes/codeBlock/components/codeBlockCopyButton.js +3 -1
- package/dist/es2019/react/nodes/codeBlock/components/codeBlockWrapButton.js +3 -1
- package/dist/es2019/react/nodes/codeBlock/components/lightWeightCodeBlock.js +3 -0
- package/dist/es2019/react/nodes/codeBlock/windowedCodeBlock.js +6 -2
- package/dist/es2019/react/nodes/date.js +12 -7
- package/dist/es2019/react/nodes/doc.js +4 -1
- package/dist/es2019/react/nodes/embedCard.js +1 -0
- package/dist/es2019/react/nodes/extension.js +3 -1
- package/dist/es2019/react/nodes/heading-anchor.js +7 -4
- package/dist/es2019/react/nodes/media/index.js +4 -10
- package/dist/es2019/react/nodes/mediaGroup.js +1 -0
- package/dist/es2019/react/nodes/multiBodiedExtension.js +6 -1
- package/dist/es2019/react/nodes/orderedList.js +1 -0
- package/dist/es2019/react/nodes/panel.js +4 -1
- package/dist/es2019/react/nodes/table/colgroup.js +5 -1
- package/dist/es2019/react/nodes/table/sticky.js +8 -2
- package/dist/es2019/react/nodes/table.js +2 -0
- package/dist/es2019/react/nodes/tableCell.js +6 -1
- package/dist/es2019/react/nodes/tableRow.js +4 -1
- package/dist/es2019/react/nodes/unknownBlock.js +1 -0
- package/dist/es2019/ui/ExtensionRenderer.js +7 -4
- package/dist/es2019/ui/Renderer/index.js +4 -2
- package/dist/es2019/ui/Renderer/style.js +6 -7
- package/dist/esm/react/marks/alignment.js +3 -1
- package/dist/esm/react/marks/backgroundColor.js +6 -2
- package/dist/esm/react/marks/breakout.js +3 -1
- package/dist/esm/react/marks/code.js +3 -1
- package/dist/esm/react/marks/indentation.js +1 -0
- package/dist/esm/react/marks/strike.js +9 -5
- package/dist/esm/react/marks/textColor.js +6 -2
- package/dist/esm/react/nodes/blockCard.js +1 -0
- package/dist/esm/react/nodes/bulletList.js +1 -0
- package/dist/esm/react/nodes/codeBlock/codeBlock.js +3 -1
- package/dist/esm/react/nodes/codeBlock/components/codeBlockContainer.js +13 -10
- package/dist/esm/react/nodes/codeBlock/components/codeBlockCopyButton.js +3 -1
- package/dist/esm/react/nodes/codeBlock/components/codeBlockWrapButton.js +3 -1
- package/dist/esm/react/nodes/codeBlock/components/lightWeightCodeBlock.js +3 -0
- package/dist/esm/react/nodes/codeBlock/windowedCodeBlock.js +6 -2
- package/dist/esm/react/nodes/date.js +12 -7
- package/dist/esm/react/nodes/doc.js +4 -1
- package/dist/esm/react/nodes/embedCard.js +1 -0
- package/dist/esm/react/nodes/extension.js +3 -1
- package/dist/esm/react/nodes/heading-anchor.js +7 -4
- package/dist/esm/react/nodes/media/index.js +4 -10
- package/dist/esm/react/nodes/mediaGroup.js +1 -0
- package/dist/esm/react/nodes/multiBodiedExtension.js +6 -1
- package/dist/esm/react/nodes/orderedList.js +1 -0
- package/dist/esm/react/nodes/panel.js +4 -1
- package/dist/esm/react/nodes/table/colgroup.js +9 -4
- package/dist/esm/react/nodes/table/sticky.js +8 -2
- package/dist/esm/react/nodes/table.js +2 -0
- package/dist/esm/react/nodes/tableCell.js +6 -1
- package/dist/esm/react/nodes/tableRow.js +4 -1
- package/dist/esm/react/nodes/unknownBlock.js +1 -0
- package/dist/esm/ui/ExtensionRenderer.js +7 -4
- package/dist/esm/ui/Renderer/index.js +4 -2
- package/dist/esm/ui/Renderer/style.js +4 -5
- package/dist/types/react/nodes/extension.d.ts +2 -1
- package/dist/types/react/nodes/media/index.d.ts +0 -1
- package/dist/types-ts4.5/react/nodes/extension.d.ts +2 -1
- package/dist/types-ts4.5/react/nodes/media/index.d.ts +0 -1
- package/package.json +3 -3
|
@@ -31,10 +31,7 @@ function _interopRequireWildcard(e, r) { if (!r && e && e.__esModule) return e;
|
|
|
31
31
|
var FullPagePadding = exports.FullPagePadding = 32;
|
|
32
32
|
var tableShadowWidth = 32;
|
|
33
33
|
var TELEPOINTER_ID = exports.TELEPOINTER_ID = 'ai-streaming-telepointer';
|
|
34
|
-
var telepointerStyles = function telepointerStyles() {
|
|
35
|
-
var _getGlobalTheme = (0, _tokens.getGlobalTheme)(),
|
|
36
|
-
colorMode = _getGlobalTheme.colorMode;
|
|
37
|
-
|
|
34
|
+
var telepointerStyles = function telepointerStyles(colorMode) {
|
|
38
35
|
// eslint-disable-next-line @atlaskit/design-system/ensure-design-token-usage/preview, @atlaskit/design-system/no-css-tagged-template-expression -- needs manual remediation
|
|
39
36
|
return (0, _react.css)(_templateObject || (_templateObject = (0, _taggedTemplateLiteral2.default)(["\n #", " {\n display: inline-block;\n position: relative;\n width: 1.5px;\n height: 25px;\n background: linear-gradient(\n 45deg,\n ", " -12.02%,\n ", " 19.18%,\n ", " 71.87%\n );\n margin-left: ", ";\n\n &::after {\n content: 'AI';\n position: absolute;\n display: block;\n top: 0;\n left: 0;\n font-size: 10px;\n font-weight: 700;\n width: 12.5px;\n height: 13px;\n padding-top: 1px;\n padding-left: 1.5px;\n line-height: initial;\n border-radius: 0px 2px 2px 0px;\n color: ", ";\n background: linear-gradient(\n 45deg,\n ", " -57%,\n ", " 71.87%\n );\n }\n }\n "])), TELEPOINTER_ID, colorMode === 'dark' ? '#f5cd47' : '#f8e6a0', colorMode === 'dark' ? '#60c6d2' : '#8bdbe5', colorMode === 'dark' ? '#388bff' : '#0c66e4', "var(--ds-space-025, 2px)", "var(--ds-text-inverse, white)", colorMode === 'dark' ? '#60c6d2' : '#8bdbe5', colorMode === 'dark' ? '#388bff' : '#0c66e4');
|
|
40
37
|
};
|
|
@@ -109,6 +106,8 @@ var getShadowOverrides = function getShadowOverrides() {
|
|
|
109
106
|
};
|
|
110
107
|
var rendererStyles = exports.rendererStyles = function rendererStyles(wrapperProps) {
|
|
111
108
|
return function (theme) {
|
|
109
|
+
var _getGlobalTheme = (0, _tokens.getGlobalTheme)(),
|
|
110
|
+
colorMode = _getGlobalTheme.colorMode;
|
|
112
111
|
// This is required to be compatible with styled-components prop structure.
|
|
113
112
|
var themeProps = {
|
|
114
113
|
theme: theme
|
|
@@ -116,7 +115,7 @@ var rendererStyles = exports.rendererStyles = function rendererStyles(wrapperPro
|
|
|
116
115
|
var useBlockRenderForCodeBlock = wrapperProps.useBlockRenderForCodeBlock;
|
|
117
116
|
|
|
118
117
|
// eslint-disable-next-line @atlaskit/design-system/ensure-design-token-usage/preview, @atlaskit/design-system/no-css-tagged-template-expression
|
|
119
|
-
return (0, _react.css)(_templateObject9 || (_templateObject9 = (0, _taggedTemplateLiteral2.default)(["\n font-size: ", "px;\n line-height: 1.5rem;\n color: ", ";\n\n .", "::after {\n // we add a clearfix after ak-renderer-document in order to\n // contain internal floats (such as media images that are \"wrap-left\")\n // to just the renderer (and not spill outside of it)\n content: '';\n visibility: hidden;\n display: block;\n height: 0;\n clear: both;\n }\n\n ", "\n ", "\n\n .", " {\n ", "\n }\n\n & h1 {\n ", "\n }\n\n & h2 {\n ", "\n }\n\n & h3 {\n ", "\n }\n\n & h4 {\n ", "\n }\n\n & h5 {\n ", "\n }\n\n & h6 {\n ", "\n }\n\n & span.akActionMark {\n color: ", ";\n text-decoration: none;\n\n &:hover {\n color: ", ";\n text-decoration: underline;\n }\n\n &:active {\n color: ", ";\n }\n }\n\n & span.akActionMark {\n cursor: pointer;\n }\n\n & span[data-placeholder] {\n color: ", ";\n }\n\n ", "\n ", ";\n ", ";\n ", ";\n ", ";\n ", ";\n ", ";\n ", ";\n ", ";\n ", ";\n ", ";\n ", ";\n ", ";\n ", ";\n ", ";\n ", "\n\n & .UnknownBlock {\n font-family: ", ";\n font-size: ", ";\n font-weight: 400;\n white-space: pre-wrap;\n word-wrap: break-word;\n }\n\n & span.date-node {\n background: ", ";\n border-radius: ", ";\n color: ", ";\n padding: ", " ", ";\n margin: 0 1px;\n transition: background 0.3s;\n }\n\n & span.date-node-highlighted {\n background: ", ";\n color: ", ";\n }\n\n & .renderer-image {\n max-width: 100%;\n display: block;\n margin: ", " 0;\n }\n\n .", ".rich-media-wrapped\n + .", ":not(.rich-media-wrapped) {\n clear: both;\n }\n\n & .code-block,\n & blockquote,\n & hr,\n & > div > div:not(.rich-media-wrapped),\n .", ".rich-media-wrapped\n + .rich-media-wrapped\n + *:not(.rich-media-wrapped),\n .", ".rich-media-wrapped + div:not(.rich-media-wrapped),\n .", ".image-align-start,\n .", ".image-center,\n .", ".image-align-end {\n clear: both;\n }\n\n & .rich-media-wrapped {\n & + h1,\n & + h2,\n & + h3,\n & + h4,\n & + h5,\n & + h6 {\n margin-top: ", ";\n }\n }\n\n ", "\n /* plugin styles */\n ", " &\n div[class^='image-wrap-'] + div[class^='image-wrap-'] {\n margin-left: 0;\n margin-right: 0;\n }\n\n /* Breakout for tables and extensions */\n .", " > {\n ", "\n\n * .", " {\n overflow-x: auto;\n }\n\n & .", ":first-child {\n margin-top: 0;\n }\n }\n\n .", " {\n .", " {\n margin-top: ", ";\n }\n\n .", " {\n margin-left: 50%;\n transform: translateX(-50%);\n }\n\n .", " {\n overflow-x: auto;\n }\n\n .", "\n .", " {\n display: flex;\n }\n }\n\n ", "\n\n .", " .", " {\n z-index: 0;\n transition: all 0.1s linear;\n display: flex; /* needed to avoid position: fixed jumpiness in Chrome */\n\n /** Shadow overrides */\n &.", "::after,\n &.", "::before {\n top: ", "px;\n height: calc(100% - ", "px);\n z-index: ", ";\n }\n\n ", "\n\n &\n .", ",\n &\n .", " {\n height: calc(100% - ", "px);\n }\n\n /**\n * A hack for making all the <th /> heights equal in case some have shorter\n * content than others.\n *\n * This is done to make sort buttons fill entire <th />.\n */\n table {\n height: 1px; /* will be ignored */\n ", ";\n margin-left: 0;\n margin-right: 0;\n }\n\n table tr:first-of-type {\n height: 100%;\n\n td,\n th {\n position: relative;\n }\n }\n\n table[data-number-column='true'] {\n .", " {\n background-color: ", ";\n border-right: 1px solid\n ", ";\n width: ", "px;\n text-align: center;\n color: ", ";\n font-size: ", ";\n }\n\n .fixed .", " {\n border-right: 0px none;\n }\n }\n }\n\n tr[data-header-row].fixed {\n position: fixed !important;\n display: flex;\n overflow: hidden;\n z-index: ", ";\n\n border-right: 1px solid\n ", ";\n border-bottom: 1px solid\n ", ";\n\n /* this is to compensate for the table border */\n transform: translateX(-1px);\n }\n\n .sticky > th {\n z-index: ", ";\n position: sticky !important;\n top: 0;\n }\n\n /* Make the number column header sticky */\n .sticky > td {\n position: sticky !important;\n top: 0;\n }\n\n /* add border for position: sticky\n and work around background-clip: padding-box\n bug for FF causing box-shadow bug in Chrome */\n .sticky th,\n .sticky td {\n box-shadow:\n 0px 1px\n ", ",\n 0px -0.5px ", ",\n inset -1px 0px ", ",\n 0px -1px ", ";\n }\n\n /* this will remove jumpiness caused in Chrome for sticky headers */\n .fixed + tr {\n min-height: 0px;\n }\n\n /*\n * We wrap CodeBlock in a grid to prevent it from overflowing the container of the renderer.\n * See ED-4159.\n */\n & .code-block {\n max-width: 100%;\n /* -ms- properties are necessary until MS supports the latest version of the grid spec */\n /* stylelint-disable value-no-vendor-prefix, declaration-block-no-duplicate-properties */\n display: block;\n /* stylelint-enable */\n\n position: relative;\n border-radius: ", ";\n\n /*\n * The overall renderer has word-wrap: break; which causes issues with\n * code block line numbers in Safari / iOS.\n */\n word-wrap: normal;\n }\n\n & .MediaGroup,\n & .code-block {\n margin-top: ", ";\n\n &:first-child {\n margin-top: 0;\n }\n }\n\n ", "\n\n ", "\n\n ", ";\n & [data-layout-section] {\n margin-top: ", ";\n & > div + div {\n margin-left: ", ";\n }\n\n @media screen and (max-width: ", "px) {\n & > div + div {\n margin-left: 0;\n }\n }\n\n & .MediaGroup,\n & .code-block {\n margin-top: ", ";\n\n &:first-child {\n margin-top: 0;\n }\n }\n }\n\n & li {\n > .code-block {\n margin: ", " 0 0 0;\n }\n > .code-block:first-child {\n margin-top: 0;\n }\n\n > div:last-of-type.code-block {\n margin-bottom: ", ";\n }\n }\n\n &:not([data-node-type='decisionList']) > li,\n // This prevents https://product-fabric.atlassian.net/browse/ED-20924\n &:not(.", ") > li {\n ", "\n }\n "])), (0, _editorSharedStyles.editorFontSize)(themeProps), "var(--ds-text, ".concat(colors.N800, ")"), _consts.RendererCssClassName.DOCUMENT, fullPageStyles(wrapperProps, themeProps), fullWidthStyles(wrapperProps), _consts.RendererCssClassName.DOCUMENT, _mediaInline.mediaInlineImageStyles, headingAnchorStyle('h1'), headingAnchorStyle('h2'), headingAnchorStyle('h3'), headingAnchorStyle('h4'), headingAnchorStyle('h5'), headingAnchorStyle('h6'), "var(--ds-link, ".concat(colors.B400, ")"), "var(--ds-link, ".concat(colors.B300, ")"), "var(--ds-link-pressed, ".concat(colors.B500, ")"), "var(--ds-text-subtlest, ".concat(colors.N200, ")"), telepointerStyles(), _styles.whitespaceSharedStyles, _styles.blockquoteSharedStyles, (0, _styles.headingsSharedStyles)(), (0, _styles.ruleSharedStyles)(), _styles.paragraphSharedStyles, _styles.listsSharedStyles, _styles.indentationSharedStyles, _styles.blockMarksSharedStyles, (0, _styles.codeMarkSharedStyles)(), _styles.shadowSharedStyle, _styles.dateSharedStyle, _styles.textColorStyles, _styles.backgroundColorStyles, _styles.tasksAndDecisionsStyles, _styles.smartCardSharedStyles, (0, _constants.fontFamily)(), (0, _editorSharedStyles.relativeFontSizeToBase16)((0, _constants.fontSize)()), "var(--ds-background-neutral, ".concat(colors.N30A, ")"), "var(--ds-border-radius-100, 3px)", "var(--ds-text, ".concat(colors.N800, ")"), "var(--ds-space-025, 2px)", "var(--ds-space-050, 4px)", "var(--ds-background-danger, ".concat(colors.R50, ")"), "var(--ds-text-danger, ".concat(colors.R500, ")"), "var(--ds-space-300, 24px)", _styles.richMediaClassName, _styles.richMediaClassName, _styles.richMediaClassName, _styles.richMediaClassName, _styles.richMediaClassName, _styles.richMediaClassName, _styles.richMediaClassName, "var(--ds-space-100, 8px)", alignedHeadingAnchorStyle(wrapperProps), _styles.mediaSingleSharedStyle, _consts.RendererCssClassName.DOCUMENT, breakoutWidthStyle(), _consts.RendererCssClassName.EXTENSION_OVERFLOW_CONTAINER, _consts.RendererCssClassName.EXTENSION, _consts.RendererCssClassName.DOCUMENT, _consts.RendererCssClassName.EXTENSION, _editorSharedStyles.blockNodesVerticalMargin, _consts.RendererCssClassName.EXTENSION_CENTER_ALIGN, _styles.TableSharedCssClassName.TABLE_NODE_WRAPPER, _ui.shadowObserverClassNames.SHADOW_CONTAINER, _styles.TableSharedCssClassName.TABLE_NODE_WRAPPER, (0, _styles.tableSharedStyle)(), _consts.RendererCssClassName.DOCUMENT, _styles.TableSharedCssClassName.TABLE_CONTAINER, _ui.shadowClassNames.RIGHT_SHADOW, _ui.shadowClassNames.LEFT_SHADOW, _styles.tableMarginTop - 1, _styles.tableMarginTop, _editorSharedStyles.akEditorStickyHeaderZIndex, getShadowOverrides(), _ui.shadowObserverClassNames.SENTINEL_LEFT, _ui.shadowObserverClassNames.SENTINEL_RIGHT, _styles.tableMarginTop, tableSortableColumnStyle(wrapperProps), _consts.RendererCssClassName.NUMBER_COLUMN, "var(--ds-background-neutral, ".concat(_editorSharedStyles.akEditorTableToolbar, ")"), "var(--ds-background-accent-gray-subtler, ".concat(_editorSharedStyles.akEditorTableBorder, ")"), _editorSharedStyles.akEditorTableNumberColumnWidth, "var(--ds-text-subtlest, ".concat(colors.N200, ")"), (0, _editorSharedStyles.relativeFontSizeToBase16)((0, _constants.fontSize)()), _consts.RendererCssClassName.NUMBER_COLUMN, _editorSharedStyles.akEditorStickyHeaderZIndex, "var(--ds-background-accent-gray-subtler, ".concat(_editorSharedStyles.akEditorTableBorder, ")"), "var(--ds-background-accent-gray-subtler, ".concat(_editorSharedStyles.akEditorTableBorder, ")"), _editorSharedStyles.akEditorStickyHeaderZIndex, "var(--ds-background-accent-gray-subtler, ".concat(_editorSharedStyles.akEditorTableBorder, ")"), "var(--ds-background-accent-gray-subtler, ".concat(_editorSharedStyles.akEditorTableBorder, ")"), "var(--ds-background-accent-gray-subtler, ".concat(_editorSharedStyles.akEditorTableToolbar, ")"), "var(--ds-background-accent-gray-subtler, ".concat(_editorSharedStyles.akEditorTableToolbar, ")"), "var(--ds-border-radius-100, 3px)", _editorSharedStyles.blockNodesVerticalMargin, useGridRenderForCodeBlock(useBlockRenderForCodeBlock), (0, _lightWeightCodeBlock.getLightWeightCodeBlockStylesForRootRendererStyleSheet)(), _styles.columnLayoutSharedStyle, "var(--ds-space-250, 20px)", "var(--ds-space-400, 32px)", _editorSharedStyles.gridMediumMaxWidth, _editorSharedStyles.blockNodesVerticalMargin, _editorSharedStyles.blockNodesVerticalMargin, _editorSharedStyles.blockNodesVerticalMargin, _styles.SmartCardSharedCssClassName.BLOCK_CARD_CONTAINER, _utils.browser.safari ? _styles.codeBlockInListSafariFix : '');
|
|
118
|
+
return (0, _react.css)(_templateObject9 || (_templateObject9 = (0, _taggedTemplateLiteral2.default)(["\n font-size: ", "px;\n line-height: 1.5rem;\n color: ", ";\n\n .", "::after {\n // we add a clearfix after ak-renderer-document in order to\n // contain internal floats (such as media images that are \"wrap-left\")\n // to just the renderer (and not spill outside of it)\n content: '';\n visibility: hidden;\n display: block;\n height: 0;\n clear: both;\n }\n\n ", "\n ", "\n\n .", " {\n ", "\n }\n\n & h1 {\n ", "\n }\n\n & h2 {\n ", "\n }\n\n & h3 {\n ", "\n }\n\n & h4 {\n ", "\n }\n\n & h5 {\n ", "\n }\n\n & h6 {\n ", "\n }\n\n & span.akActionMark {\n color: ", ";\n text-decoration: none;\n\n &:hover {\n color: ", ";\n text-decoration: underline;\n }\n\n &:active {\n color: ", ";\n }\n }\n\n & span.akActionMark {\n cursor: pointer;\n }\n\n & span[data-placeholder] {\n color: ", ";\n }\n\n ", "\n ", ";\n ", ";\n ", ";\n ", ";\n ", ";\n ", ";\n ", ";\n ", ";\n ", ";\n ", ";\n ", ";\n ", ";\n ", ";\n ", ";\n ", "\n\n & .UnknownBlock {\n font-family: ", ";\n font-size: ", ";\n font-weight: 400;\n white-space: pre-wrap;\n word-wrap: break-word;\n }\n\n & span.date-node {\n background: ", ";\n border-radius: ", ";\n color: ", ";\n padding: ", " ", ";\n margin: 0 1px;\n transition: background 0.3s;\n }\n\n & span.date-node-highlighted {\n background: ", ";\n color: ", ";\n }\n\n & .renderer-image {\n max-width: 100%;\n display: block;\n margin: ", " 0;\n }\n\n .", ".rich-media-wrapped\n + .", ":not(.rich-media-wrapped) {\n clear: both;\n }\n\n & .code-block,\n & blockquote,\n & hr,\n & > div > div:not(.rich-media-wrapped),\n .", ".rich-media-wrapped\n + .rich-media-wrapped\n + *:not(.rich-media-wrapped),\n .", ".rich-media-wrapped + div:not(.rich-media-wrapped),\n .", ".image-align-start,\n .", ".image-center,\n .", ".image-align-end {\n clear: both;\n }\n\n & .rich-media-wrapped {\n & + h1,\n & + h2,\n & + h3,\n & + h4,\n & + h5,\n & + h6 {\n margin-top: ", ";\n }\n }\n\n ", "\n /* plugin styles */\n ", " &\n div[class^='image-wrap-'] + div[class^='image-wrap-'] {\n margin-left: 0;\n margin-right: 0;\n }\n\n /* Breakout for tables and extensions */\n .", " > {\n ", "\n\n * .", " {\n overflow-x: auto;\n }\n\n & .", ":first-child {\n margin-top: 0;\n }\n }\n\n .", " {\n .", " {\n margin-top: ", ";\n }\n\n .", " {\n margin-left: 50%;\n transform: translateX(-50%);\n }\n\n .", " {\n overflow-x: auto;\n }\n\n .", "\n .", " {\n display: flex;\n }\n }\n\n ", "\n\n .", " .", " {\n z-index: 0;\n transition: all 0.1s linear;\n display: flex; /* needed to avoid position: fixed jumpiness in Chrome */\n\n /** Shadow overrides */\n &.", "::after,\n &.", "::before {\n top: ", "px;\n height: calc(100% - ", "px);\n z-index: ", ";\n }\n\n ", "\n\n &\n .", ",\n &\n .", " {\n height: calc(100% - ", "px);\n }\n\n /**\n * A hack for making all the <th /> heights equal in case some have shorter\n * content than others.\n *\n * This is done to make sort buttons fill entire <th />.\n */\n table {\n height: 1px; /* will be ignored */\n ", ";\n margin-left: 0;\n margin-right: 0;\n }\n\n table tr:first-of-type {\n height: 100%;\n\n td,\n th {\n position: relative;\n }\n }\n\n table[data-number-column='true'] {\n .", " {\n background-color: ", ";\n border-right: 1px solid\n ", ";\n width: ", "px;\n text-align: center;\n color: ", ";\n font-size: ", ";\n }\n\n .fixed .", " {\n border-right: 0px none;\n }\n }\n }\n\n tr[data-header-row].fixed {\n position: fixed !important;\n display: flex;\n overflow: hidden;\n z-index: ", ";\n\n border-right: 1px solid\n ", ";\n border-bottom: 1px solid\n ", ";\n\n /* this is to compensate for the table border */\n transform: translateX(-1px);\n }\n\n .sticky > th {\n z-index: ", ";\n position: sticky !important;\n top: 0;\n }\n\n /* Make the number column header sticky */\n .sticky > td {\n position: sticky !important;\n top: 0;\n }\n\n /* add border for position: sticky\n and work around background-clip: padding-box\n bug for FF causing box-shadow bug in Chrome */\n .sticky th,\n .sticky td {\n box-shadow:\n 0px 1px\n ", ",\n 0px -0.5px ", ",\n inset -1px 0px ", ",\n 0px -1px ", ";\n }\n\n /* this will remove jumpiness caused in Chrome for sticky headers */\n .fixed + tr {\n min-height: 0px;\n }\n\n /*\n * We wrap CodeBlock in a grid to prevent it from overflowing the container of the renderer.\n * See ED-4159.\n */\n & .code-block {\n max-width: 100%;\n /* -ms- properties are necessary until MS supports the latest version of the grid spec */\n /* stylelint-disable value-no-vendor-prefix, declaration-block-no-duplicate-properties */\n display: block;\n /* stylelint-enable */\n\n position: relative;\n border-radius: ", ";\n\n /*\n * The overall renderer has word-wrap: break; which causes issues with\n * code block line numbers in Safari / iOS.\n */\n word-wrap: normal;\n }\n\n & .MediaGroup,\n & .code-block {\n margin-top: ", ";\n\n &:first-child {\n margin-top: 0;\n }\n }\n\n ", "\n\n ", "\n\n ", ";\n & [data-layout-section] {\n margin-top: ", ";\n & > div + div {\n margin-left: ", ";\n }\n\n @media screen and (max-width: ", "px) {\n & > div + div {\n margin-left: 0;\n }\n }\n\n & .MediaGroup,\n & .code-block {\n margin-top: ", ";\n\n &:first-child {\n margin-top: 0;\n }\n }\n }\n\n & li {\n > .code-block {\n margin: ", " 0 0 0;\n }\n > .code-block:first-child {\n margin-top: 0;\n }\n\n > div:last-of-type.code-block {\n margin-bottom: ", ";\n }\n }\n\n &:not([data-node-type='decisionList']) > li,\n // This prevents https://product-fabric.atlassian.net/browse/ED-20924\n &:not(.", ") > li {\n ", "\n }\n "])), (0, _editorSharedStyles.editorFontSize)(themeProps), "var(--ds-text, ".concat(colors.N800, ")"), _consts.RendererCssClassName.DOCUMENT, fullPageStyles(wrapperProps, themeProps), fullWidthStyles(wrapperProps), _consts.RendererCssClassName.DOCUMENT, _mediaInline.mediaInlineImageStyles, headingAnchorStyle('h1'), headingAnchorStyle('h2'), headingAnchorStyle('h3'), headingAnchorStyle('h4'), headingAnchorStyle('h5'), headingAnchorStyle('h6'), "var(--ds-link, ".concat(colors.B400, ")"), "var(--ds-link, ".concat(colors.B300, ")"), "var(--ds-link-pressed, ".concat(colors.B500, ")"), "var(--ds-text-subtlest, ".concat(colors.N200, ")"), telepointerStyles(colorMode), _styles.whitespaceSharedStyles, _styles.blockquoteSharedStyles, (0, _styles.headingsSharedStyles)(), (0, _styles.ruleSharedStyles)(), _styles.paragraphSharedStyles, _styles.listsSharedStyles, _styles.indentationSharedStyles, _styles.blockMarksSharedStyles, (0, _styles.codeMarkSharedStyles)(), _styles.shadowSharedStyle, _styles.dateSharedStyle, _styles.textColorStyles, (0, _styles.backgroundColorStyles)(colorMode), _styles.tasksAndDecisionsStyles, _styles.smartCardSharedStyles, (0, _constants.fontFamily)(), (0, _editorSharedStyles.relativeFontSizeToBase16)((0, _constants.fontSize)()), "var(--ds-background-neutral, ".concat(colors.N30A, ")"), "var(--ds-border-radius-100, 3px)", "var(--ds-text, ".concat(colors.N800, ")"), "var(--ds-space-025, 2px)", "var(--ds-space-050, 4px)", "var(--ds-background-danger, ".concat(colors.R50, ")"), "var(--ds-text-danger, ".concat(colors.R500, ")"), "var(--ds-space-300, 24px)", _styles.richMediaClassName, _styles.richMediaClassName, _styles.richMediaClassName, _styles.richMediaClassName, _styles.richMediaClassName, _styles.richMediaClassName, _styles.richMediaClassName, "var(--ds-space-100, 8px)", alignedHeadingAnchorStyle(wrapperProps), _styles.mediaSingleSharedStyle, _consts.RendererCssClassName.DOCUMENT, breakoutWidthStyle(), _consts.RendererCssClassName.EXTENSION_OVERFLOW_CONTAINER, _consts.RendererCssClassName.EXTENSION, _consts.RendererCssClassName.DOCUMENT, _consts.RendererCssClassName.EXTENSION, _editorSharedStyles.blockNodesVerticalMargin, _consts.RendererCssClassName.EXTENSION_CENTER_ALIGN, _styles.TableSharedCssClassName.TABLE_NODE_WRAPPER, _ui.shadowObserverClassNames.SHADOW_CONTAINER, _styles.TableSharedCssClassName.TABLE_NODE_WRAPPER, (0, _styles.tableSharedStyle)(), _consts.RendererCssClassName.DOCUMENT, _styles.TableSharedCssClassName.TABLE_CONTAINER, _ui.shadowClassNames.RIGHT_SHADOW, _ui.shadowClassNames.LEFT_SHADOW, _styles.tableMarginTop - 1, _styles.tableMarginTop, _editorSharedStyles.akEditorStickyHeaderZIndex, getShadowOverrides(), _ui.shadowObserverClassNames.SENTINEL_LEFT, _ui.shadowObserverClassNames.SENTINEL_RIGHT, _styles.tableMarginTop, tableSortableColumnStyle(wrapperProps), _consts.RendererCssClassName.NUMBER_COLUMN, "var(--ds-background-neutral, ".concat(_editorSharedStyles.akEditorTableToolbar, ")"), "var(--ds-background-accent-gray-subtler, ".concat(_editorSharedStyles.akEditorTableBorder, ")"), _editorSharedStyles.akEditorTableNumberColumnWidth, "var(--ds-text-subtlest, ".concat(colors.N200, ")"), (0, _editorSharedStyles.relativeFontSizeToBase16)((0, _constants.fontSize)()), _consts.RendererCssClassName.NUMBER_COLUMN, _editorSharedStyles.akEditorStickyHeaderZIndex, "var(--ds-background-accent-gray-subtler, ".concat(_editorSharedStyles.akEditorTableBorder, ")"), "var(--ds-background-accent-gray-subtler, ".concat(_editorSharedStyles.akEditorTableBorder, ")"), _editorSharedStyles.akEditorStickyHeaderZIndex, "var(--ds-background-accent-gray-subtler, ".concat(_editorSharedStyles.akEditorTableBorder, ")"), "var(--ds-background-accent-gray-subtler, ".concat(_editorSharedStyles.akEditorTableBorder, ")"), "var(--ds-background-accent-gray-subtler, ".concat(_editorSharedStyles.akEditorTableToolbar, ")"), "var(--ds-background-accent-gray-subtler, ".concat(_editorSharedStyles.akEditorTableToolbar, ")"), "var(--ds-border-radius-100, 3px)", _editorSharedStyles.blockNodesVerticalMargin, useGridRenderForCodeBlock(useBlockRenderForCodeBlock), (0, _lightWeightCodeBlock.getLightWeightCodeBlockStylesForRootRendererStyleSheet)(), _styles.columnLayoutSharedStyle, "var(--ds-space-250, 20px)", "var(--ds-space-400, 32px)", _editorSharedStyles.gridMediumMaxWidth, _editorSharedStyles.blockNodesVerticalMargin, _editorSharedStyles.blockNodesVerticalMargin, _editorSharedStyles.blockNodesVerticalMargin, _styles.SmartCardSharedCssClassName.BLOCK_CARD_CONTAINER, _utils.browser.safari ? _styles.codeBlockInListSafariFix : '');
|
|
120
119
|
};
|
|
121
120
|
};
|
|
122
121
|
var useGridRenderForCodeBlock = function useGridRenderForCodeBlock(codeBlockRenderAsBlock) {
|
|
@@ -17,7 +17,9 @@ const MarkWrapper = props => {
|
|
|
17
17
|
);
|
|
18
18
|
};
|
|
19
19
|
export default function Alignment(props) {
|
|
20
|
-
return jsx(MarkWrapper
|
|
20
|
+
return jsx(MarkWrapper
|
|
21
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-classname-prop -- Ignored via go/DSP-18766
|
|
22
|
+
, {
|
|
21
23
|
className: "fabric-editor-block-mark fabric-editor-alignment",
|
|
22
24
|
"data-align": props.align
|
|
23
25
|
}, props.children);
|
|
@@ -41,8 +41,12 @@ export default function BackgroundColor(props) {
|
|
|
41
41
|
['--custom-palette-color']: paletteColorValue
|
|
42
42
|
}), [paletteColorValue]);
|
|
43
43
|
return /*#__PURE__*/React.createElement("span", _extends({}, props.dataAttributes, {
|
|
44
|
-
"data-background-custom-color": props.color
|
|
45
|
-
|
|
44
|
+
"data-background-custom-color": props.color
|
|
45
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-classname-prop -- Ignored via go/DSP-18766
|
|
46
|
+
,
|
|
47
|
+
className: "fabric-background-color-mark"
|
|
48
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/enforce-style-prop -- Ignored via go/DSP-18766
|
|
49
|
+
,
|
|
46
50
|
style: style
|
|
47
51
|
}), props.children);
|
|
48
52
|
}
|
|
@@ -17,7 +17,9 @@ export default function Breakout(props) {
|
|
|
17
17
|
"data-mode": props.mode,
|
|
18
18
|
style: {
|
|
19
19
|
width: calcBreakoutWidth(props.mode, width)
|
|
20
|
-
}
|
|
20
|
+
}
|
|
21
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-classname-prop -- Ignored via go/DSP-18766
|
|
22
|
+
,
|
|
21
23
|
className: "fabric-editor-breakout-mark fabric-editor-block-mark"
|
|
22
24
|
}, props.children));
|
|
23
25
|
}
|
|
@@ -8,7 +8,9 @@ export const isCodeMark = mark => {
|
|
|
8
8
|
};
|
|
9
9
|
export function CodeWithIntl(props) {
|
|
10
10
|
const codeBidiWarningLabel = props.intl.formatMessage(codeBidiWarningMessages.label);
|
|
11
|
-
return /*#__PURE__*/React.createElement(AkCode
|
|
11
|
+
return /*#__PURE__*/React.createElement(AkCode
|
|
12
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-classname-prop -- Ignored via go/DSP-18766
|
|
13
|
+
, _extends({
|
|
12
14
|
className: "code",
|
|
13
15
|
codeBidiWarningLabel: codeBidiWarningLabel,
|
|
14
16
|
codeBidiWarningTooltipEnabled: props.codeBidiWarningTooltipEnabled
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
export default function Indentation(props) {
|
|
3
3
|
return /*#__PURE__*/React.createElement("div", {
|
|
4
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-classname-prop -- Ignored via go/DSP-18766
|
|
4
5
|
className: "fabric-editor-block-mark fabric-editor-indentation-mark",
|
|
5
6
|
"data-level": props.level
|
|
6
7
|
}, props.children);
|
|
@@ -1,9 +1,13 @@
|
|
|
1
1
|
import _extends from "@babel/runtime/helpers/extends";
|
|
2
2
|
import React from 'react';
|
|
3
3
|
export default function Strike(props) {
|
|
4
|
-
return
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
}
|
|
8
|
-
|
|
4
|
+
return (
|
|
5
|
+
/*#__PURE__*/
|
|
6
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/enforce-style-prop -- Ignored via go/DSP-18766
|
|
7
|
+
React.createElement("span", _extends({}, props.dataAttributes, {
|
|
8
|
+
style: {
|
|
9
|
+
textDecoration: 'line-through'
|
|
10
|
+
}
|
|
11
|
+
}), props.children)
|
|
12
|
+
);
|
|
9
13
|
}
|
|
@@ -45,8 +45,12 @@ export default function TextColor(props) {
|
|
|
45
45
|
['--custom-palette-color']: paletteColorValue
|
|
46
46
|
}), [paletteColorValue]);
|
|
47
47
|
return /*#__PURE__*/React.createElement("span", _extends({}, props.dataAttributes, {
|
|
48
|
-
"data-text-custom-color": props.color
|
|
49
|
-
|
|
48
|
+
"data-text-custom-color": props.color
|
|
49
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-classname-prop -- Ignored via go/DSP-18766
|
|
50
|
+
,
|
|
51
|
+
className: "fabric-text-color-mark"
|
|
52
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/enforce-style-prop -- Ignored via go/DSP-18766
|
|
53
|
+
,
|
|
50
54
|
style: style
|
|
51
55
|
}), props.children);
|
|
52
56
|
}
|
|
@@ -112,6 +112,7 @@ export default function BlockCard(props) {
|
|
|
112
112
|
return jsx(AnalyticsContext, {
|
|
113
113
|
data: analyticsData
|
|
114
114
|
}, jsx("div", {
|
|
115
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-classname-prop -- Ignored via go/DSP-18766
|
|
115
116
|
className: "blockCardView-content-wrap",
|
|
116
117
|
"data-block-card": true,
|
|
117
118
|
"data-card-data": data ? JSON.stringify(data) : undefined,
|
|
@@ -3,6 +3,7 @@ import { bulletListSelector } from '@atlaskit/adf-schema';
|
|
|
3
3
|
import { getListIndentLevel } from '../utils/lists';
|
|
4
4
|
export default function BulletList(props) {
|
|
5
5
|
return /*#__PURE__*/React.createElement("ul", {
|
|
6
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-classname-prop -- Ignored via go/DSP-18766
|
|
6
7
|
className: bulletListSelector.substr(1),
|
|
7
8
|
"data-indent-level": props.path ? getListIndentLevel(props.path) : 1
|
|
8
9
|
}, props.children);
|
|
@@ -19,7 +19,9 @@ function CodeBlock(props) {
|
|
|
19
19
|
const [wrapLongLines, setWrapLongLines] = useState(false);
|
|
20
20
|
return jsx(CodeBlockContainer, {
|
|
21
21
|
allowCopyToClipboard: allowCopyToClipboard,
|
|
22
|
-
allowWrapCodeBlock: allowWrapCodeBlock
|
|
22
|
+
allowWrapCodeBlock: allowWrapCodeBlock
|
|
23
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-classname-prop -- Ignored via go/DSP-18766
|
|
24
|
+
,
|
|
23
25
|
className: className,
|
|
24
26
|
setWrapLongLines: setWrapLongLines,
|
|
25
27
|
text: text,
|
|
@@ -42,15 +42,18 @@ const CodeBlockContainer = ({
|
|
|
42
42
|
text,
|
|
43
43
|
wrapLongLines
|
|
44
44
|
}) => {
|
|
45
|
-
return
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
45
|
+
return (
|
|
46
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-classname-prop -- Ignored via go/DSP-18766
|
|
47
|
+
jsx("div", {
|
|
48
|
+
className: className,
|
|
49
|
+
css: codeBlockStyleOverrides
|
|
50
|
+
}, jsx(CodeBlockButtonContainer, {
|
|
51
|
+
allowCopyToClipboard: allowCopyToClipboard,
|
|
52
|
+
allowWrapCodeBlock: allowWrapCodeBlock,
|
|
53
|
+
setWrapLongLines: setWrapLongLines,
|
|
54
|
+
text: text,
|
|
55
|
+
wrapLongLines: wrapLongLines
|
|
56
|
+
}), children)
|
|
57
|
+
);
|
|
55
58
|
};
|
|
56
59
|
export default CodeBlockContainer;
|
|
@@ -30,7 +30,9 @@ const CopyButton = ({
|
|
|
30
30
|
}, jsx(Button, {
|
|
31
31
|
appearance: "subtle",
|
|
32
32
|
"aria-haspopup": true,
|
|
33
|
-
"aria-label": tooltip
|
|
33
|
+
"aria-label": tooltip
|
|
34
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-classname-prop -- Ignored via go/DSP-18766
|
|
35
|
+
,
|
|
34
36
|
className: className,
|
|
35
37
|
iconBefore: jsx(CopyIcon, {
|
|
36
38
|
label: tooltip
|
|
@@ -37,7 +37,9 @@ const CodeBlockWrapButton = ({
|
|
|
37
37
|
}, jsx(Button, {
|
|
38
38
|
appearance: "subtle",
|
|
39
39
|
"aria-haspopup": true,
|
|
40
|
-
"aria-label": wrapMessage
|
|
40
|
+
"aria-label": wrapMessage
|
|
41
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-classname-prop -- Ignored via go/DSP-18766
|
|
42
|
+
,
|
|
41
43
|
className: `wrap-code ${wrapLongLines ? 'clicked' : ''}`,
|
|
42
44
|
iconBefore: jsx(Icon, {
|
|
43
45
|
glyph: WrapIcon,
|
|
@@ -43,14 +43,17 @@ const LightWeightCodeBlock = /*#__PURE__*/forwardRef(({
|
|
|
43
43
|
});
|
|
44
44
|
const classNames = [LightWeightCodeBlockCssClassName.CONTAINER, className].join(' ');
|
|
45
45
|
return jsx("div", {
|
|
46
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-classname-prop -- Ignored via go/DSP-18766
|
|
46
47
|
className: classNames,
|
|
47
48
|
ref: ref,
|
|
48
49
|
css: [codeBlockSharedStyles(), lightWeightCodeBlockStyles]
|
|
49
50
|
}, jsx("div", {
|
|
50
51
|
className: CodeBlockSharedCssClassName.CODEBLOCK_CONTAINER
|
|
51
52
|
}, jsx("div", {
|
|
53
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-classname-prop -- Ignored via go/DSP-18766
|
|
52
54
|
className: CodeBlockSharedCssClassName.CODEBLOCK_CONTENT_WRAPPER
|
|
53
55
|
}, jsx("div", {
|
|
56
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-classname-prop -- Ignored via go/DSP-18766
|
|
54
57
|
className: CodeBlockSharedCssClassName.CODEBLOCK_LINE_NUMBER_GUTTER
|
|
55
58
|
}, textRows.map((_, index) => jsx("span", {
|
|
56
59
|
key: index
|
|
@@ -31,7 +31,9 @@ const WindowedCodeBlock = ({
|
|
|
31
31
|
const memoizedLightWeightCodeBlock = jsx(MemoizedLightWeightCodeBlock, {
|
|
32
32
|
ref: trackingRef,
|
|
33
33
|
text: text,
|
|
34
|
-
codeBidiWarningTooltipEnabled: codeBidiWarningTooltipEnabled
|
|
34
|
+
codeBidiWarningTooltipEnabled: codeBidiWarningTooltipEnabled
|
|
35
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-classname-prop -- Ignored via go/DSP-18766
|
|
36
|
+
,
|
|
35
37
|
className: rootClassName
|
|
36
38
|
});
|
|
37
39
|
const [wrapLongLines, setWrapLongLines] = useState(false);
|
|
@@ -39,7 +41,9 @@ const WindowedCodeBlock = ({
|
|
|
39
41
|
fallback: memoizedLightWeightCodeBlock
|
|
40
42
|
}, jsx(CodeBlockContainer, {
|
|
41
43
|
allowCopyToClipboard: allowCopyToClipboard,
|
|
42
|
-
allowWrapCodeBlock: allowWrapCodeBlock
|
|
44
|
+
allowWrapCodeBlock: allowWrapCodeBlock
|
|
45
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-classname-prop -- Ignored via go/DSP-18766
|
|
46
|
+
,
|
|
43
47
|
className: className,
|
|
44
48
|
setWrapLongLines: setWrapLongLines,
|
|
45
49
|
text: text,
|
|
@@ -13,13 +13,18 @@ class Date extends PureComponent {
|
|
|
13
13
|
intl
|
|
14
14
|
} = this.props;
|
|
15
15
|
const className = !!parentIsIncompleteTask && isPastDate(timestamp) ? 'date-node date-node-highlighted' : 'date-node';
|
|
16
|
-
return
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
"
|
|
22
|
-
|
|
16
|
+
return (
|
|
17
|
+
/*#__PURE__*/
|
|
18
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-classname-prop -- Ignored via go/DSP-18766
|
|
19
|
+
React.createElement("span", {
|
|
20
|
+
className: DateSharedCssClassName.DATE_WRAPPER
|
|
21
|
+
}, /*#__PURE__*/React.createElement("span", {
|
|
22
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-classname-prop -- Ignored via go/DSP-18766
|
|
23
|
+
className: className,
|
|
24
|
+
"data-node-type": "date",
|
|
25
|
+
"data-timestamp": timestamp
|
|
26
|
+
}, parentIsIncompleteTask ? timestampToTaskContext(timestamp, intl) : timestampToString(timestamp, intl)))
|
|
27
|
+
);
|
|
23
28
|
}
|
|
24
29
|
}
|
|
25
30
|
export const DateComponent = injectIntl(Date);
|
|
@@ -2,13 +2,16 @@ import React from 'react';
|
|
|
2
2
|
import { RendererCssClassName } from '../../consts';
|
|
3
3
|
import { useSelectAllTrap } from '../utils/use-select-all-trap';
|
|
4
4
|
export default function Doc(props) {
|
|
5
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-classname-prop -- Ignored via go/DSP-18766
|
|
5
6
|
return /*#__PURE__*/React.createElement("div", {
|
|
6
7
|
className: RendererCssClassName.DOCUMENT
|
|
7
8
|
}, props.children);
|
|
8
9
|
}
|
|
9
10
|
export function DocWithSelectAllTrap(props) {
|
|
10
11
|
return /*#__PURE__*/React.createElement("div", {
|
|
11
|
-
ref: useSelectAllTrap()
|
|
12
|
+
ref: useSelectAllTrap()
|
|
13
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-classname-prop -- Ignored via go/DSP-18766
|
|
14
|
+
,
|
|
12
15
|
className: RendererCssClassName.DOCUMENT
|
|
13
16
|
}, props.children);
|
|
14
17
|
}
|
|
@@ -152,6 +152,7 @@ export default function EmbedCard(props) {
|
|
|
152
152
|
}, jsx("div", {
|
|
153
153
|
css: embedCardWrapperStyles
|
|
154
154
|
}, jsx("div", {
|
|
155
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-classname-prop -- Ignored via go/DSP-18766
|
|
155
156
|
className: "embedCardView-content-wrap",
|
|
156
157
|
"data-embed-card": true,
|
|
157
158
|
"data-layout": layout,
|
|
@@ -15,7 +15,9 @@ export const renderExtension = (content, layout, options = {}, removeOverflow) =
|
|
|
15
15
|
return /*#__PURE__*/React.createElement(WidthConsumer, null, ({
|
|
16
16
|
width
|
|
17
17
|
}) => /*#__PURE__*/React.createElement("div", {
|
|
18
|
-
ref: options.handleRef
|
|
18
|
+
ref: options.handleRef
|
|
19
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-classname-prop -- Ignored via go/DSP-18766
|
|
20
|
+
,
|
|
19
21
|
className: `${RendererCssClassName.EXTENSION} ${options.shadowClassNames} ${centerAlignClass}`,
|
|
20
22
|
style: {
|
|
21
23
|
width: isTopLevel ? calcBreakoutWidth(layout, width) : '100%'
|
|
@@ -15,10 +15,13 @@ const CopyAnchorWrapperWithRef = /*#__PURE__*/React.forwardRef((props, ref) => {
|
|
|
15
15
|
children,
|
|
16
16
|
...rest
|
|
17
17
|
} = props;
|
|
18
|
-
return
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
18
|
+
return (
|
|
19
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-classname-prop -- Ignored via go/DSP-18766
|
|
20
|
+
jsx("span", _extends({}, rest, {
|
|
21
|
+
className: HeadingAnchorWrapperClassName,
|
|
22
|
+
ref: ref
|
|
23
|
+
}), children)
|
|
24
|
+
);
|
|
22
25
|
});
|
|
23
26
|
const copyAnchorButtonStyles = css({
|
|
24
27
|
display: 'inline',
|
|
@@ -192,8 +192,7 @@ class Media extends PureComponent {
|
|
|
192
192
|
width,
|
|
193
193
|
height,
|
|
194
194
|
mediaSingleElement,
|
|
195
|
-
isDrafting = false
|
|
196
|
-
isInPageInclude
|
|
195
|
+
isDrafting = false
|
|
197
196
|
} = this.props;
|
|
198
197
|
const annotationMarks = this.props.isAnnotationMark ? this.props.marks.filter(this.props.isAnnotationMark) : undefined;
|
|
199
198
|
const borderMark = this.props.marks.find(this.props.isBorderMark);
|
|
@@ -201,6 +200,7 @@ class Media extends PureComponent {
|
|
|
201
200
|
const linkHref = linkMark === null || linkMark === void 0 ? void 0 : linkMark.attrs.href;
|
|
202
201
|
const eventHandlers = linkHref ? undefined : this.props.eventHandlers;
|
|
203
202
|
const shouldOpenMediaViewer = !linkHref && allowMediaViewer;
|
|
203
|
+
const isInPageInclude = mediaSingleElement === null || mediaSingleElement === void 0 ? void 0 : mediaSingleElement.closest('[data-node-type="include"]');
|
|
204
204
|
const showCommentBadge = !!annotationMarks && (featureFlags === null || featureFlags === void 0 ? void 0 : featureFlags.commentsOnMedia) && (!(featureFlags !== null && featureFlags !== void 0 && featureFlags.commentsOnMediaIncludePage) || !isInPageInclude);
|
|
205
205
|
return jsx(MediaLink, {
|
|
206
206
|
mark: linkMark,
|
|
@@ -282,11 +282,6 @@ const MediaWithDraftAnnotation = props => {
|
|
|
282
282
|
dataAttributes
|
|
283
283
|
} = props;
|
|
284
284
|
const pos = dataAttributes && dataAttributes['data-renderer-start-pos'];
|
|
285
|
-
let parentElementClosest;
|
|
286
|
-
if (typeof document !== "undefined") {
|
|
287
|
-
const elementAtPos = pos && document.querySelector(`[data-renderer-start-pos="${pos}"]`);
|
|
288
|
-
parentElementClosest = elementAtPos instanceof Element ? elementAtPos.closest('[data-node-type="include"]') : null;
|
|
289
|
-
}
|
|
290
285
|
const [position, setPosition] = useState();
|
|
291
286
|
const [shouldApplyDraftAnnotation, setShouldApplyDraftAnnotation] = useState(false);
|
|
292
287
|
useEffect(() => {
|
|
@@ -302,7 +297,7 @@ const MediaWithDraftAnnotation = props => {
|
|
|
302
297
|
setShouldApplyDraftAnnotation(false);
|
|
303
298
|
setPosition(undefined);
|
|
304
299
|
}
|
|
305
|
-
}, [draftPosition,
|
|
300
|
+
}, [draftPosition, pos, shouldApplyDraftAnnotation, isCommentsOnMediaBugFixEnabled]);
|
|
306
301
|
const applyDraftAnnotation = props.allowAnnotationsDraftMode && shouldApplyDraftAnnotation && position !== undefined;
|
|
307
302
|
const dataAttributesWithDraftAnnotation = useMemo(() => applyDraftAnnotation ? {
|
|
308
303
|
...dataAttributes,
|
|
@@ -311,8 +306,7 @@ const MediaWithDraftAnnotation = props => {
|
|
|
311
306
|
} : dataAttributes, [applyDraftAnnotation, dataAttributes]);
|
|
312
307
|
return jsx(Media, _extends({}, props, {
|
|
313
308
|
dataAttributes: dataAttributesWithDraftAnnotation,
|
|
314
|
-
isDrafting: shouldApplyDraftAnnotation
|
|
315
|
-
isInPageInclude: !!parentElementClosest
|
|
309
|
+
isDrafting: shouldApplyDraftAnnotation
|
|
316
310
|
}));
|
|
317
311
|
};
|
|
318
312
|
export default MediaWithDraftAnnotation;
|
|
@@ -48,6 +48,7 @@ export default class MediaGroup extends PureComponent {
|
|
|
48
48
|
} else {
|
|
49
49
|
content = this.renderStrip();
|
|
50
50
|
}
|
|
51
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-classname-prop -- Ignored via go/DSP-18766
|
|
51
52
|
return /*#__PURE__*/React.createElement("div", {
|
|
52
53
|
className: "MediaGroup"
|
|
53
54
|
}, content);
|
|
@@ -98,12 +98,14 @@ const MultiBodiedExtension = props => {
|
|
|
98
98
|
const centerAlignClass = isTopLevel && ['wide', 'full-width'].includes(layout) ? RendererCssClassName.EXTENSION_CENTER_ALIGN : '';
|
|
99
99
|
function renderMbeContent(width) {
|
|
100
100
|
return jsx("div", {
|
|
101
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-classname-prop -- Ignored via go/DSP-18766
|
|
101
102
|
className: `${RendererCssClassName.EXTENSION} ${centerAlignClass} ${overflowContainerClass}`,
|
|
102
103
|
style: {
|
|
103
104
|
width: isTopLevel ? calcBreakoutWidth(layout, width) : '100%'
|
|
104
105
|
},
|
|
105
106
|
"data-layout": layout
|
|
106
107
|
}, jsx("nav", {
|
|
108
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-classname-prop -- Ignored via go/DSP-18766
|
|
107
109
|
className: "multiBodiedExtension-navigation",
|
|
108
110
|
css: navigationCssExtended,
|
|
109
111
|
"data-testid": "multiBodiedExtension-navigation"
|
|
@@ -130,11 +132,14 @@ const MultiBodiedExtension = props => {
|
|
|
130
132
|
isTopLevel: path.length < 1
|
|
131
133
|
});
|
|
132
134
|
})), jsx("article", {
|
|
133
|
-
"data-testid": "multiBodiedExtension--frames"
|
|
135
|
+
"data-testid": "multiBodiedExtension--frames"
|
|
136
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-classname-prop -- Ignored via go/DSP-18766
|
|
137
|
+
,
|
|
134
138
|
className: `multiBodiedExtension--frames`
|
|
135
139
|
}, children));
|
|
136
140
|
}
|
|
137
141
|
return jsx("section", {
|
|
142
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-classname-prop -- Ignored via go/DSP-18766
|
|
138
143
|
className: "multiBodiedExtension--container"
|
|
139
144
|
// eslint-disable-next-line @atlaskit/design-system/consistent-css-prop-usage
|
|
140
145
|
,
|
|
@@ -18,6 +18,7 @@ export default function OrderedList(props) {
|
|
|
18
18
|
extraProps.start = resolveOrder(props.order);
|
|
19
19
|
}
|
|
20
20
|
return /*#__PURE__*/React.createElement("ol", _extends({
|
|
21
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-classname-prop -- Ignored via go/DSP-18766
|
|
21
22
|
className: orderedListSelector.substr(1),
|
|
22
23
|
"data-indent-level": props.path ? getListIndentLevel(props.path) : 1,
|
|
23
24
|
start: props.start
|
|
@@ -85,12 +85,15 @@ const Panel = props => {
|
|
|
85
85
|
const icon = getIcon();
|
|
86
86
|
const renderIcon = () => {
|
|
87
87
|
if (icon) {
|
|
88
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-classname-prop -- Ignored via go/DSP-18766
|
|
88
89
|
return jsx("div", {
|
|
89
90
|
className: PanelSharedCssClassName.icon
|
|
90
91
|
}, icon);
|
|
91
92
|
}
|
|
92
93
|
};
|
|
93
|
-
return jsx(PanelStyled
|
|
94
|
+
return jsx(PanelStyled
|
|
95
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-classname-prop -- Ignored via go/DSP-18766
|
|
96
|
+
, {
|
|
94
97
|
className: PanelSharedCssClassName.prefix,
|
|
95
98
|
"data-panel-type": panelType,
|
|
96
99
|
"data-panel-color": panelColor,
|
|
@@ -147,11 +147,15 @@ export const Colgroup = props => {
|
|
|
147
147
|
return null;
|
|
148
148
|
}
|
|
149
149
|
return /*#__PURE__*/React.createElement("colgroup", null, isNumberColumnEnabled && /*#__PURE__*/React.createElement("col", {
|
|
150
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/enforce-style-prop -- Ignored via go/DSP-18766
|
|
150
151
|
style: {
|
|
151
152
|
width: akEditorTableNumberColumnWidth
|
|
152
153
|
},
|
|
153
154
|
"data-test-id": 'num'
|
|
154
|
-
}), colStyles.map((style, idx) =>
|
|
155
|
+
}), colStyles.map((style, idx) =>
|
|
156
|
+
/*#__PURE__*/
|
|
157
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/enforce-style-prop -- Ignored via go/DSP-18766
|
|
158
|
+
React.createElement("col", {
|
|
155
159
|
key: idx,
|
|
156
160
|
style: style
|
|
157
161
|
})));
|
|
@@ -66,7 +66,9 @@ export const FixedTableDiv = props => {
|
|
|
66
66
|
mode
|
|
67
67
|
};
|
|
68
68
|
return jsx("div", _extends({}, attrs, {
|
|
69
|
-
"data-testid": "sticky-table-fixed"
|
|
69
|
+
"data-testid": "sticky-table-fixed"
|
|
70
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-classname-prop -- Ignored via go/DSP-18766
|
|
71
|
+
,
|
|
70
72
|
className: isTableResizingEnabled(rendererAppearance) ? 'fixed-table-div-custom-table-resizing' : '',
|
|
71
73
|
css: fixedTableCss
|
|
72
74
|
}), props.children);
|
|
@@ -114,15 +116,19 @@ export const StickyTable = ({
|
|
|
114
116
|
wrapperWidth: wrapperWidth,
|
|
115
117
|
rendererAppearance: rendererAppearance
|
|
116
118
|
}, jsx("div", {
|
|
119
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-classname-prop -- Ignored via go/DSP-18766
|
|
117
120
|
className: `${TableSharedCssClassName.TABLE_CONTAINER} is-sticky ${shadowClassNames || ''}`,
|
|
118
121
|
"data-layout": layout,
|
|
119
122
|
style: {
|
|
120
123
|
width: tableWidth
|
|
121
124
|
}
|
|
122
125
|
}, jsx("div", {
|
|
123
|
-
ref: innerRef
|
|
126
|
+
ref: innerRef
|
|
127
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-classname-prop -- Ignored via go/DSP-18766
|
|
128
|
+
,
|
|
124
129
|
className: `${TableSharedCssClassName.TABLE_STICKY_WRAPPER}`,
|
|
125
130
|
style: {
|
|
131
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/enforce-style-prop -- Ignored via go/DSP-18766
|
|
126
132
|
overflow: 'hidden'
|
|
127
133
|
}
|
|
128
134
|
}, jsx(Table, {
|
|
@@ -289,6 +289,7 @@ export class TableContainer extends React.Component {
|
|
|
289
289
|
updatedLayout = layout;
|
|
290
290
|
}
|
|
291
291
|
return /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement("div", {
|
|
292
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-classname-prop -- Ignored via go/DSP-18766
|
|
292
293
|
className: `${TableSharedCssClassName.TABLE_CONTAINER} ${this.props.shadowClassNames || ''}`,
|
|
293
294
|
"data-layout": updatedLayout,
|
|
294
295
|
ref: this.props.handleRef,
|
|
@@ -313,6 +314,7 @@ export class TableContainer extends React.Component {
|
|
|
313
314
|
tableNode: tableNode,
|
|
314
315
|
rendererAppearance: rendererAppearance
|
|
315
316
|
}, [children && children[0]]), /*#__PURE__*/React.createElement("div", {
|
|
317
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-classname-prop -- Ignored via go/DSP-18766
|
|
316
318
|
className: TableSharedCssClassName.TABLE_NODE_WRAPPER,
|
|
317
319
|
ref: this.wrapperRef,
|
|
318
320
|
onScroll: this.props.stickyHeaders && this.onWrapperScrolled
|
|
@@ -141,6 +141,7 @@ const getWithCellProps = WrapperComponent => {
|
|
|
141
141
|
// the background color is not taken from the inline style.
|
|
142
142
|
// Instead it is taken from the data-cell-background attribute
|
|
143
143
|
// (added via getDataAttributes below).
|
|
144
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/enforce-style-prop -- Ignored via go/DSP-18766
|
|
144
145
|
,
|
|
145
146
|
style: getStyle({
|
|
146
147
|
background,
|
|
@@ -149,7 +150,9 @@ const getWithCellProps = WrapperComponent => {
|
|
|
149
150
|
colorMode
|
|
150
151
|
}),
|
|
151
152
|
colorname: colorName,
|
|
152
|
-
onClick: onClick
|
|
153
|
+
onClick: onClick
|
|
154
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-classname-prop -- Ignored via go/DSP-18766
|
|
155
|
+
,
|
|
153
156
|
className: className
|
|
154
157
|
}, getDataAttributes(colwidth, background), {
|
|
155
158
|
"aria-sort": ariaSort
|
|
@@ -172,11 +175,13 @@ export const withSortableColumn = WrapperComponent => {
|
|
|
172
175
|
return /*#__PURE__*/React.createElement(WrapperComponent, props);
|
|
173
176
|
}
|
|
174
177
|
return /*#__PURE__*/React.createElement(WrapperComponent, _extends({}, props, {
|
|
178
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-classname-prop -- Ignored via go/DSP-18766
|
|
175
179
|
className: RendererCssClassName.SORTABLE_COLUMN_WRAPPER,
|
|
176
180
|
ariaSort: getSortOrderLabel(intl, sortOrdered)
|
|
177
181
|
}), /*#__PURE__*/React.createElement("div", {
|
|
178
182
|
className: RendererCssClassName.SORTABLE_COLUMN
|
|
179
183
|
}, children, /*#__PURE__*/React.createElement("figure", {
|
|
184
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-classname-prop -- Ignored via go/DSP-18766
|
|
180
185
|
className: `${RendererCssClassName.SORTABLE_COLUMN_ICON_WRAPPER} ${sortOrderedClassName}`
|
|
181
186
|
}, /*#__PURE__*/React.createElement(SortingIcon, {
|
|
182
187
|
isSortingAllowed: !!onSorting,
|