@atlaskit/renderer 114.11.1 → 114.11.2

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.
Files changed (47) hide show
  1. package/CHANGELOG.md +8 -0
  2. package/dist/cjs/react/marks/alignment.js +3 -15
  3. package/dist/cjs/react/nodes/codeBlock/components/codeBlockContainer.js +3 -10
  4. package/dist/cjs/react/nodes/codeBlock/components/lightWeightCodeBlock.js +8 -53
  5. package/dist/cjs/react/nodes/layoutColumn.js +3 -11
  6. package/dist/cjs/react/nodes/media/index.js +28 -58
  7. package/dist/cjs/react/nodes/panel.js +2 -26
  8. package/dist/cjs/react/nodes/table/sticky.js +3 -57
  9. package/dist/cjs/ui/Expand.js +12 -62
  10. package/dist/cjs/ui/Renderer/RendererStyleContainer.js +19 -42
  11. package/dist/cjs/ui/Renderer/index.js +4 -2
  12. package/dist/cjs/ui/Renderer/style.js +2 -208
  13. package/dist/cjs/ui/annotations/draft/component.js +2 -17
  14. package/dist/cjs/ui/annotations/element/mark.js +12 -61
  15. package/dist/es2019/react/marks/alignment.js +2 -17
  16. package/dist/es2019/react/nodes/codeBlock/components/codeBlockContainer.js +2 -39
  17. package/dist/es2019/react/nodes/codeBlock/components/lightWeightCodeBlock.js +5 -50
  18. package/dist/es2019/react/nodes/layoutColumn.js +4 -12
  19. package/dist/es2019/react/nodes/media/index.js +3 -36
  20. package/dist/es2019/react/nodes/panel.js +2 -41
  21. package/dist/es2019/react/nodes/table/sticky.js +3 -70
  22. package/dist/es2019/ui/Expand.js +11 -67
  23. package/dist/es2019/ui/Renderer/RendererStyleContainer.js +20 -43
  24. package/dist/es2019/ui/Renderer/index.js +4 -2
  25. package/dist/es2019/ui/Renderer/style.js +1 -889
  26. package/dist/es2019/ui/annotations/draft/component.js +2 -15
  27. package/dist/es2019/ui/annotations/element/mark.js +9 -71
  28. package/dist/esm/react/marks/alignment.js +2 -16
  29. package/dist/esm/react/nodes/codeBlock/components/codeBlockContainer.js +2 -11
  30. package/dist/esm/react/nodes/codeBlock/components/lightWeightCodeBlock.js +7 -52
  31. package/dist/esm/react/nodes/layoutColumn.js +4 -12
  32. package/dist/esm/react/nodes/media/index.js +28 -58
  33. package/dist/esm/react/nodes/panel.js +3 -27
  34. package/dist/esm/react/nodes/table/sticky.js +3 -57
  35. package/dist/esm/ui/Expand.js +12 -62
  36. package/dist/esm/ui/Renderer/RendererStyleContainer.js +20 -43
  37. package/dist/esm/ui/Renderer/index.js +4 -2
  38. package/dist/esm/ui/Renderer/style.js +1 -203
  39. package/dist/esm/ui/annotations/draft/component.js +2 -17
  40. package/dist/esm/ui/annotations/element/mark.js +9 -56
  41. package/dist/types/react/nodes/codeBlock/components/lightWeightCodeBlock.d.ts +1 -1
  42. package/dist/types/ui/Renderer/style.d.ts +0 -11
  43. package/dist/types/ui/annotations/element/mark.d.ts +30 -6
  44. package/dist/types-ts4.5/react/nodes/codeBlock/components/lightWeightCodeBlock.d.ts +1 -1
  45. package/dist/types-ts4.5/ui/Renderer/style.d.ts +0 -11
  46. package/dist/types-ts4.5/ui/annotations/element/mark.d.ts +30 -6
  47. package/package.json +5 -5
@@ -17,7 +17,6 @@ import { N40A } from '@atlaskit/theme/colors';
17
17
  import { fg } from '@atlaskit/platform-feature-flags';
18
18
  import { Table } from './table';
19
19
  import { recursivelyInjectProps } from '../../utils/inject-props';
20
- import { componentWithFG } from '@atlaskit/platform-feature-flags-react';
21
20
  export var tableStickyPadding = 8;
22
21
  var modeSpecficStyles = {
23
22
  none: css({
@@ -33,7 +32,7 @@ var modeSpecficStyles = {
33
32
 
34
33
  // refactored based on fixedTableDivStaticStyles
35
34
  // TODO: DSP-4123 - Quality ticket
36
- var fixedTableDivStaticStylesNew = css(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty({
35
+ var fixedTableDivStaticStyles = css(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty({
37
36
  zIndex: 'var(--ak-renderer-sticky-header-zindex)'
38
37
  }, "& .".concat(TableSharedCssClassName.TABLE_CONTAINER, ", & .").concat(TableSharedCssClassName.TABLE_STICKY_WRAPPER, " > table"), {
39
38
  marginTop: 0,
@@ -51,59 +50,7 @@ var fixedTableDivStaticStylesNew = css(_defineProperty(_defineProperty(_definePr
51
50
  // eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-values -- Ignored via go/DSP-18766
52
51
  zIndex: 'var(--ak-renderer-sticky-header-zindex)'
53
52
  }));
54
-
55
- // TODO: DSP-4123 - Quality ticket
56
- var fixedTableDivStaticStyles = function fixedTableDivStaticStyles(top, width, allowTableResizing) {
57
- var stickyHeaderZIndex;
58
- if (allowTableResizing) {
59
- stickyHeaderZIndex = 13;
60
- } else {
61
- stickyHeaderZIndex = akEditorStickyHeaderZIndex;
62
- }
63
-
64
- // eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-values -- Ignored via go/DSP-18766
65
- return css(typeof top === 'number' && "top: ".concat(top, "px;"), _defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty({
66
- // eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-values -- Ignored via go/DSP-18766
67
- width: "".concat(width, "px"),
68
- // eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-values -- Ignored via go/DSP-18766
69
- zIndex: stickyHeaderZIndex
70
- }, "& .".concat(TableSharedCssClassName.TABLE_CONTAINER, ", & .").concat(TableSharedCssClassName.TABLE_STICKY_WRAPPER, " > table"), {
71
- marginTop: 0,
72
- marginBottom: 0,
73
- // eslint-disable-next-line @atlaskit/ui-styling-standard/no-nested-selectors -- Ignored via go/DSP-18766
74
- tr: {
75
- background: "var(--ds-surface, white)"
76
- }
77
- }), "borderTop", "".concat(tableStickyPadding, "px solid ", "var(--ds-surface, white)")), "background", "var(--ds-surface-overlay, white)"), "boxShadow", "0 6px 4px -4px ".concat("var(--ds-shadow-overflow-perimeter, ".concat(N40A, ")"))), "div[data-expanded='false'] &", {
78
- display: 'none'
79
- }), "& .".concat(TableSharedCssClassName.TABLE_CONTAINER, ".is-sticky.right-shadow::after, & .").concat(TableSharedCssClassName.TABLE_CONTAINER, ".is-sticky.left-shadow::before"), {
80
- top: '0px',
81
- height: '100%'
82
- }), "&.fixed-table-div-custom-table-resizing[mode='stick']", {
83
- // eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-values -- Ignored via go/DSP-18766
84
- zIndex: stickyHeaderZIndex
85
- }));
86
- };
87
- var FixedTableDivOld = function FixedTableDivOld(props) {
88
- var top = props.top,
89
- wrapperWidth = props.wrapperWidth,
90
- mode = props.mode,
91
- allowTableResizing = props.allowTableResizing;
92
- var fixedTableCss = [fixedTableDivStaticStyles(top, wrapperWidth, allowTableResizing), modeSpecficStyles === null || modeSpecficStyles === void 0 ? void 0 : modeSpecficStyles[mode]];
93
- var attrs = {
94
- mode: mode
95
- };
96
- return jsx("div", _extends({}, attrs, {
97
- "data-testid": "sticky-table-fixed"
98
- // eslint-disable-next-line @atlaskit/ui-styling-standard/no-classname-prop -- Ignored via go/DSP-18766
99
- ,
100
- className: allowTableResizing ? 'fixed-table-div-custom-table-resizing' : ''
101
- // eslint-disable-next-line @atlaskit/design-system/consistent-css-prop-usage -- Ignored via go/DSP-18766
102
- ,
103
- css: fixedTableCss
104
- }), props.children);
105
- };
106
- var FixedTableDivNew = function FixedTableDivNew(props) {
53
+ var FixedTableDiv = function FixedTableDiv(props) {
107
54
  var top = props.top,
108
55
  wrapperWidth = props.wrapperWidth,
109
56
  mode = props.mode,
@@ -122,7 +69,7 @@ var FixedTableDivNew = function FixedTableDivNew(props) {
122
69
  // eslint-disable-next-line @atlaskit/ui-styling-standard/no-classname-prop -- Ignored via go/DSP-18766
123
70
  ,
124
71
  className: allowTableResizing ? 'fixed-table-div-custom-table-resizing' : '',
125
- css: [fixedTableDivStaticStylesNew, modeSpecficStyles === null || modeSpecficStyles === void 0 ? void 0 : modeSpecficStyles[mode]],
72
+ css: [fixedTableDivStaticStyles, modeSpecficStyles === null || modeSpecficStyles === void 0 ? void 0 : modeSpecficStyles[mode]],
126
73
  style: {
127
74
  '--ak-renderer-sticky-header-zindex': stickyHeaderZIndex,
128
75
  width: "".concat(wrapperWidth, "px"),
@@ -130,7 +77,6 @@ var FixedTableDivNew = function FixedTableDivNew(props) {
130
77
  }
131
78
  }), props.children);
132
79
  };
133
- var FixedTableDiv = componentWithFG('platform_editor_emotion_refactor_renderer', FixedTableDivNew, FixedTableDivOld);
134
80
  export var StickyTable = function StickyTable(_ref) {
135
81
  var top = _ref.top,
136
82
  left = _ref.left,
@@ -1,10 +1,7 @@
1
1
  import _slicedToArray from "@babel/runtime/helpers/slicedToArray";
2
2
  import _objectWithoutProperties from "@babel/runtime/helpers/objectWithoutProperties";
3
3
  import _extends from "@babel/runtime/helpers/extends";
4
- import _taggedTemplateLiteral from "@babel/runtime/helpers/taggedTemplateLiteral";
5
- var _excluded = ["expanded"],
6
- _excluded2 = ["expanded"];
7
- var _templateObject, _templateObject2, _templateObject3;
4
+ var _excluded = ["expanded"];
8
5
  /**
9
6
  * @jsxRuntime classic
10
7
  * @jsx jsx
@@ -14,7 +11,7 @@ import { css, jsx } from '@emotion/react';
14
11
  import React, { useCallback, useRef } from 'react';
15
12
  // eslint-disable-next-line @atlaskit/design-system/no-deprecated-imports
16
13
  import { ACTION, ACTION_SUBJECT, EVENT_TYPE } from '@atlaskit/editor-common/analytics';
17
- import { clearNextSiblingMarginTopStyle, ExpandIconWrapper, ExpandLayoutWrapperWithRef, expandMessages, sharedExpandStyles, WidthProvider } from '@atlaskit/editor-common/ui';
14
+ import { ExpandIconWrapper, ExpandLayoutWrapperWithRef, expandMessages, WidthProvider } from '@atlaskit/editor-common/ui';
18
15
  import { akEditorLineHeight, akEditorSwoopCubicBezier, akLayoutGutterOffset } from '@atlaskit/editor-shared-styles';
19
16
  import { default as ChevronRightIconLegacy } from '@atlaskit/icon/glyph/chevron-right';
20
17
  import ChevronRightIcon from '@atlaskit/icon/utility/chevron-right';
@@ -23,7 +20,6 @@ import _uniqueId from 'lodash/uniqueId';
23
20
  import { injectIntl } from 'react-intl-next';
24
21
  import { MODE, PLATFORM } from '../analytics/events';
25
22
  import { ActiveHeaderIdConsumer } from './active-header-id-provider';
26
- import { componentWithFG } from '@atlaskit/platform-feature-flags-react';
27
23
  var titleStyles = css({
28
24
  outline: 'none',
29
25
  border: 'none',
@@ -123,51 +119,23 @@ var contentContainerStylesNotExpanded = css({
123
119
  userSelect: 'none'
124
120
  }
125
121
  });
126
- var ContainerOld = function ContainerOld(props) {
127
- var paddingBottom = props.expanded ? "var(--ds-space-100, 8px)" : "var(--ds-space-0, 0px)";
128
- var sharedContainerStyles = sharedExpandStyles.containerStyles(props);
129
-
130
- // eslint-disable-next-line @atlaskit/design-system/no-css-tagged-template-expression -- needs manual remediation
131
- var styles = function styles() {
132
- return css(_templateObject || (_templateObject = _taggedTemplateLiteral(["\n\t\t", "\n\t\tpadding: 0;\n\t\tpadding-bottom: ", ";\n\t"])), sharedContainerStyles(), paddingBottom);
133
- };
134
- return (
135
- // Ignored via go/ees005
136
- // eslint-disable-next-line react/jsx-props-no-spreading, @atlaskit/design-system/consistent-css-prop-usage
137
- jsx("div", _extends({
138
- css: styles
139
- }, props), props.children)
140
- );
141
- };
142
- var ContainerNew = function ContainerNew(props) {
122
+ var clearNextSiblingMarginTopStyle = css({
123
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-nested-selectors -- Ignored via go/DSP-18766
124
+ '& + *': {
125
+ // eslint-disable-next-line @atlaskit/design-system/ensure-design-token-usage/preview, @atlaskit/ui-styling-standard/no-important-styles -- Ignored via go/DSP-18766
126
+ marginTop: '0 !important'
127
+ }
128
+ });
129
+ var Container = function Container(props) {
143
130
  return jsx("div", _extends({
144
131
  css: [containerStyles, props['data-node-type'] === 'expand' && containerStylesDataNodeTypeExpand, props.expanded && containerStylesExpanded, props.focused && containerStylesFocused]
145
132
  // Ignored via go/ees005
146
133
  // eslint-disable-next-line react/jsx-props-no-spreading
147
134
  }, props), props.children);
148
135
  };
149
- var Container = componentWithFG('platform_editor_emotion_refactor_renderer', ContainerNew, ContainerOld);
150
- var TitleContainerOld = function TitleContainerOld(props) {
151
- var paddingBottom = !props.expanded ? "var(--ds-space-100, 8px)" : "var(--ds-space-0, 0px)";
152
-
153
- // eslint-disable-next-line @atlaskit/design-system/no-css-tagged-template-expression -- needs manual remediation
154
- var styles = function styles() {
155
- return css(_templateObject2 || (_templateObject2 = _taggedTemplateLiteral(["\n\t\t", "\n\t\tpadding: ", ";\n\t\tpadding-bottom: ", ";\n\t"])), sharedExpandStyles.titleContainerStyles(), "var(--ds-space-100, 8px)", paddingBottom);
156
- };
136
+ var TitleContainer = function TitleContainer(props) {
157
137
  var expanded = props.expanded,
158
138
  buttonProps = _objectWithoutProperties(props, _excluded);
159
- return (
160
- // Ignored via go/ees005
161
- // eslint-disable-next-line react/jsx-props-no-spreading, @atlaskit/design-system/consistent-css-prop-usage, @atlaskit/design-system/no-html-button
162
- jsx("button", _extends({
163
- type: "button",
164
- css: styles
165
- }, buttonProps), props.children)
166
- );
167
- };
168
- var TitleContainerNew = function TitleContainerNew(props) {
169
- var expanded = props.expanded,
170
- buttonProps = _objectWithoutProperties(props, _excluded2);
171
139
  return (
172
140
  // eslint-disable-next-line @atlaskit/design-system/no-html-button
173
141
  jsx("button", _extends({
@@ -178,32 +146,14 @@ var TitleContainerNew = function TitleContainerNew(props) {
178
146
  }, buttonProps), props.children)
179
147
  );
180
148
  };
181
- var TitleContainer = componentWithFG('platform_editor_emotion_refactor_renderer', TitleContainerNew, TitleContainerOld);
182
149
  TitleContainer.displayName = 'TitleContainerButton';
183
- var ContentContainerOld = function ContentContainerOld(props) {
184
- var sharedContentStyles = sharedExpandStyles.contentStyles(props);
185
- var visibility = props.expanded ? 'visible' : 'hidden';
186
-
187
- // eslint-disable-next-line @atlaskit/design-system/no-css-tagged-template-expression -- needs manual remediation
188
- var styles = function styles() {
189
- return css(_templateObject3 || (_templateObject3 = _taggedTemplateLiteral(["\n\t\t", ";\n\t\tpadding-right: ", ";\n\t\tpadding-left: ", ";\n\t\tvisibility: ", ";\n\t"])), sharedContentStyles(), "var(--ds-space-200, 16px)", "var(--ds-space-400, 32px)", visibility);
190
- };
191
- return (
192
- // Ignored via go/ees005
193
- // eslint-disable-next-line react/jsx-props-no-spreading, @atlaskit/design-system/consistent-css-prop-usage
194
- jsx("div", _extends({
195
- css: styles
196
- }, props), props.children)
197
- );
198
- };
199
- var ContentContainerNew = function ContentContainerNew(props) {
150
+ var ContentContainer = function ContentContainer(props) {
200
151
  return jsx("div", _extends({
201
152
  css: [contentContainerStyles, props.expanded && contentContainerStylesExpanded, !props.expanded && contentContainerStylesNotExpanded]
202
153
  // Ignored via go/ees005
203
154
  // eslint-disable-next-line react/jsx-props-no-spreading
204
155
  }, props), props.children);
205
156
  };
206
- var ContentContainer = componentWithFG('platform_editor_emotion_refactor_renderer', ContentContainerNew, ContentContainerOld);
207
157
  function fireExpandToggleAnalytics(nodeType, expanded, fireAnalyticsEvent) {
208
158
  if (!fireAnalyticsEvent) {
209
159
  return;
@@ -10,7 +10,7 @@ var _css, _css3;
10
10
  // eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled
11
11
  import { css, jsx } from '@emotion/react';
12
12
  import { B300, B400, B500, N20, N200, N30A, N40A, N60A, N800, R50, R500, Y300, Y75 } from '@atlaskit/theme/colors';
13
- import { FullPagePadding, rendererStyles } from './style';
13
+ import { FullPagePadding } from './style';
14
14
  import { fg } from '@atlaskit/platform-feature-flags';
15
15
  import { RendererCssClassName } from '../../consts';
16
16
  import { akEditorBlockquoteBorderColor, akEditorDefaultLayoutWidth, akEditorFullWidthLayoutWidth, akEditorLineHeight, akEditorSelectedNodeClassName, akEditorShadowZIndex, akEditorStickyHeaderZIndex, akEditorTableBorder, akEditorTableCellMinWidth, akEditorTableNumberColumnWidth, akEditorTableToolbar, blockNodesVerticalMargin, gridMediumMaxWidth } from '@atlaskit/editor-shared-styles';
@@ -1349,58 +1349,35 @@ export var RendererStyleContainer = function RendererStyleContainer(props) {
1349
1349
  appearance = props.appearance,
1350
1350
  allowNestedHeaderLinks = props.allowNestedHeaderLinks,
1351
1351
  allowColumnSorting = props.allowColumnSorting,
1352
- allowAnnotations = props.allowAnnotations,
1353
- allowTableResizing = props.allowTableResizing,
1354
1352
  useBlockRenderForCodeBlock = props.useBlockRenderForCodeBlock,
1355
1353
  children = props.children,
1356
1354
  innerRef = props.innerRef,
1357
1355
  testId = props.testId;
1358
1356
  var isAdvancedLayoutsOn = editorExperiment('advanced_layouts', true);
1359
- if (fg('platform_editor_emotion_refactor_renderer')) {
1360
- return (
1361
- // eslint-disable-next-line jsx-a11y/click-events-have-key-events, jsx-a11y/no-static-element-interactions, @atlassian/a11y/interactive-element-not-keyboard-focusable
1362
- jsx("div", {
1363
- ref: innerRef,
1364
- onClick: onClick,
1365
- onMouseDown: onMouseDown,
1366
- style: {
1367
- '--ak-renderer-base-font-size': "".concat(getBaseFontSize(appearance), "px"),
1368
- '--ak-renderer-editor-font-heading-h1': "".concat(editorUGCToken('editor.font.heading.h1')),
1369
- '--ak-renderer-editor-font-heading-h2': "".concat(editorUGCToken('editor.font.heading.h2')),
1370
- '--ak-renderer-editor-font-heading-h3': "".concat(editorUGCToken('editor.font.heading.h3')),
1371
- '--ak-renderer-editor-font-heading-h4': "".concat(editorUGCToken('editor.font.heading.h4')),
1372
- '--ak-renderer-editor-font-heading-h5': "".concat(editorUGCToken('editor.font.heading.h5')),
1373
- '--ak-renderer-editor-font-heading-h6': "".concat(editorUGCToken('editor.font.heading.h6')),
1374
- '--ak-renderer-editor-font-normal-text': "".concat(editorUGCToken('editor.font.body'))
1375
- },
1376
- css: [baseStyles, appearance === 'full-page' && rendererFullPageStyles, appearance === 'full-width' && rendererFullWidthStyles, !isTableResizingEnabled(appearance) && rendererFullWidthStylesForTableResizing, telepointerStyles, whitespaceSharedStyles, blockquoteSharedStyles, fg('platform_editor_typography_ugc') ? headingsSharedStylesWithEditorUGC : headingsSharedStyles, headingWithAlignmentStyles, ruleSharedStyles, fg('platform_editor_typography_ugc') ? paragraphSharedStylesWithEditorUGC : paragraphSharedStyles, listsSharedStyles, browser.gecko && listsSharedStylesForGekko, indentationSharedStyles, blockMarksSharedStyles, codeMarkSharedStyles, shadowSharedStyle, dateSharedStyle, textColorStyles, backgroundColorStyles, tasksAndDecisionsStyles, smartCardStyles, fg('platform-linking-visual-refresh-v1') && smartCardStylesAvatarFix,
1377
- // eslint-disable-next-line @atlaskit/platform/ensure-feature-flag-prefix
1378
- fg('editor_inline_comments_on_inline_nodes') && rendererAnnotationStyles,
1379
- // eslint-disable-next-line @atlaskit/platform/no-preconditioning, @atlaskit/platform/ensure-feature-flag-prefix
1380
- fg('editor_inline_comments_on_inline_nodes') &&
1381
- // eslint-disable-next-line @atlaskit/platform/ensure-feature-flag-prefix
1382
- fg('annotations_align_editor_and_renderer_styles') && rendererAnnotationStylesCommentHeightFix, baseOtherStyles, allowNestedHeaderLinks && alignedHeadingAnchorStyle, mediaSingleSharedStyle, tableSharedStyle, tableRendererHeaderStylesForTableCellOnly, isBackgroundClipBrowserFixNeeded() && tableStylesBackGroundClipForGeckoForTableCellOnly, fg('platform_editor_nested_dnd_styles_changes') ? firstNodeWithNotMarginTopWithNestedDnD : firstNodeWithNotMarginTop, rendererTableStyles, isStickyScrollbarEnabled(appearance) && stickyScrollbarStyles, rendererTableHeaderEqualHeightStylesForTableCellOnly, allowColumnSorting && rendererTableSortableColumnStyles, allowColumnSorting && allowNestedHeaderLinks && rendererTableHeaderEqualHeightStylesAllowNestedHeaderLinks, fg('platform_editor_tables_numbered_column_correction') ? rendererTableColumnStyles : rendererTableColumnStylesOld, stickyHeaderStyles, codeBlockAndLayoutStyles, columnLayoutSharedStyle, isAdvancedLayoutsOn && columnLayoutResponsiveSharedStyle, isAdvancedLayoutsOn && columnLayoutResponsiveRendererStyles, isAdvancedLayoutsOn && layoutSectionForAdvancedLayoutsStyles, !useBlockRenderForCodeBlock && gridRenderForCodeBlockStyles, browser.safari && codeBlockInListSafariFixStyles],
1383
- "data-testid": testId
1384
- }, children)
1385
- );
1386
- }
1387
1357
  return (
1388
1358
  // eslint-disable-next-line jsx-a11y/click-events-have-key-events, jsx-a11y/no-static-element-interactions, @atlassian/a11y/interactive-element-not-keyboard-focusable
1389
1359
  jsx("div", {
1390
1360
  ref: innerRef,
1391
1361
  onClick: onClick,
1392
- onMouseDown: onMouseDown
1393
- // eslint-disable-next-line @atlaskit/design-system/consistent-css-prop-usage, @atlaskit/ui-styling-standard/no-imported-style-values -- Ignored via go/DSP-18766
1394
- ,
1395
- css: rendererStyles({
1396
- appearance: appearance,
1397
- allowNestedHeaderLinks: allowNestedHeaderLinks,
1398
- allowColumnSorting: !!allowColumnSorting,
1399
- useBlockRenderForCodeBlock: useBlockRenderForCodeBlock,
1400
- allowAnnotations: allowAnnotations,
1401
- allowTableResizing: allowTableResizing
1402
- }),
1362
+ onMouseDown: onMouseDown,
1363
+ style: {
1364
+ '--ak-renderer-base-font-size': "".concat(getBaseFontSize(appearance), "px"),
1365
+ '--ak-renderer-editor-font-heading-h1': "".concat(editorUGCToken('editor.font.heading.h1')),
1366
+ '--ak-renderer-editor-font-heading-h2': "".concat(editorUGCToken('editor.font.heading.h2')),
1367
+ '--ak-renderer-editor-font-heading-h3': "".concat(editorUGCToken('editor.font.heading.h3')),
1368
+ '--ak-renderer-editor-font-heading-h4': "".concat(editorUGCToken('editor.font.heading.h4')),
1369
+ '--ak-renderer-editor-font-heading-h5': "".concat(editorUGCToken('editor.font.heading.h5')),
1370
+ '--ak-renderer-editor-font-heading-h6': "".concat(editorUGCToken('editor.font.heading.h6')),
1371
+ '--ak-renderer-editor-font-normal-text': "".concat(editorUGCToken('editor.font.body'))
1372
+ },
1373
+ css: [baseStyles, appearance === 'full-page' && rendererFullPageStyles, appearance === 'full-width' && rendererFullWidthStyles, appearance === 'full-width' && !isTableResizingEnabled(appearance) && rendererFullWidthStylesForTableResizing, telepointerStyles, whitespaceSharedStyles, blockquoteSharedStyles, fg('platform_editor_typography_ugc') ? headingsSharedStylesWithEditorUGC : headingsSharedStyles, headingWithAlignmentStyles, ruleSharedStyles, fg('platform_editor_typography_ugc') ? paragraphSharedStylesWithEditorUGC : paragraphSharedStyles, listsSharedStyles, browser.gecko && listsSharedStylesForGekko, indentationSharedStyles, blockMarksSharedStyles, codeMarkSharedStyles, shadowSharedStyle, dateSharedStyle, textColorStyles, backgroundColorStyles, tasksAndDecisionsStyles, smartCardStyles, fg('platform-linking-visual-refresh-v1') && smartCardStylesAvatarFix,
1374
+ // eslint-disable-next-line @atlaskit/platform/ensure-feature-flag-prefix
1375
+ fg('editor_inline_comments_on_inline_nodes') && rendererAnnotationStyles,
1376
+ // eslint-disable-next-line @atlaskit/platform/no-preconditioning, @atlaskit/platform/ensure-feature-flag-prefix
1377
+ fg('editor_inline_comments_on_inline_nodes') &&
1378
+ // eslint-disable-next-line @atlaskit/platform/ensure-feature-flag-prefix
1379
+ fg('annotations_align_editor_and_renderer_styles') && rendererAnnotationStylesCommentHeightFix, baseOtherStyles, allowNestedHeaderLinks && alignedHeadingAnchorStyle, mediaSingleSharedStyle, tableSharedStyle, tableRendererHeaderStylesForTableCellOnly, isBackgroundClipBrowserFixNeeded() && tableStylesBackGroundClipForGeckoForTableCellOnly, fg('platform_editor_nested_dnd_styles_changes') ? firstNodeWithNotMarginTopWithNestedDnD : firstNodeWithNotMarginTop, rendererTableStyles, isStickyScrollbarEnabled(appearance) && stickyScrollbarStyles, rendererTableHeaderEqualHeightStylesForTableCellOnly, allowColumnSorting && rendererTableSortableColumnStyles, allowColumnSorting && allowNestedHeaderLinks && rendererTableHeaderEqualHeightStylesAllowNestedHeaderLinks, fg('platform_editor_tables_numbered_column_correction') ? rendererTableColumnStyles : rendererTableColumnStylesOld, stickyHeaderStyles, codeBlockAndLayoutStyles, columnLayoutSharedStyle, isAdvancedLayoutsOn && columnLayoutResponsiveSharedStyle, isAdvancedLayoutsOn && columnLayoutResponsiveRendererStyles, isAdvancedLayoutsOn && layoutSectionForAdvancedLayoutsStyles, !useBlockRenderForCodeBlock && gridRenderForCodeBlockStyles, browser.safari && codeBlockInListSafariFixStyles],
1403
1380
  "data-testid": testId
1404
- }, props.children)
1381
+ }, children)
1405
1382
  );
1406
1383
  };
@@ -49,7 +49,7 @@ import { removeEmptySpaceAroundContent } from './rendererHelper';
49
49
  export var NORMAL_SEVERITY_THRESHOLD = 2000;
50
50
  export var DEGRADED_SEVERITY_THRESHOLD = 3000;
51
51
  var packageName = "@atlaskit/renderer";
52
- var packageVersion = "114.11.1";
52
+ var packageVersion = "114.11.2";
53
53
  var setAsQueryContainerStyles = css({
54
54
  containerName: 'ak-renderer-wrapper',
55
55
  containerType: 'inline-size',
@@ -438,6 +438,7 @@ export var RendererFunctionalComponent = function RendererFunctionalComponent(pr
438
438
  }, jsx(UnsupportedBlock, null));
439
439
  }
440
440
  };
441
+ var RendererFunctionalComponentMemoized = /*#__PURE__*/React.memo(RendererFunctionalComponent);
441
442
  export function Renderer(props) {
442
443
  var _React$useContext = React.useContext(AnnotationsPositionContext),
443
444
  startPos = _React$useContext.startPos;
@@ -445,7 +446,8 @@ export function Renderer(props) {
445
446
  isTopLevelRenderer = _useRendererContext.isTopLevelRenderer;
446
447
  var _ref = useContext(ValidationContext) || {},
447
448
  skipValidation = _ref.skipValidation;
448
- return jsx(RendererFunctionalComponent
449
+ var RendererComponent = fg('cc_perf_reduce_rerenders') ? RendererFunctionalComponentMemoized : RendererFunctionalComponent;
450
+ return jsx(RendererComponent
449
451
  // Ignored via go/ees005
450
452
  // eslint-disable-next-line react/jsx-props-no-spreading
451
453
  , _extends({}, props, {
@@ -1,204 +1,2 @@
1
- import _taggedTemplateLiteral from "@babel/runtime/helpers/taggedTemplateLiteral";
2
- var _templateObject, _templateObject2, _templateObject3, _templateObject4, _templateObject5, _templateObject6, _templateObject7, _templateObject8, _templateObject9, _templateObject10;
3
- /* eslint-disable @atlaskit/design-system/no-css-tagged-template-expression -- needs manual remediation */
4
- /* eslint-disable @atlaskit/design-system/ensure-design-token-usage */
5
- // eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
6
- // eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
7
- import { css } from '@emotion/react';
8
- import { fg } from '@atlaskit/platform-feature-flags';
9
- // Ignored via go/ees005
10
- // eslint-disable-next-line import/no-namespace
11
- import * as colors from '@atlaskit/theme/colors';
12
- import { N60A, Y300, Y75, N40A } from '@atlaskit/theme/colors';
13
- import { getGlobalTheme } from '@atlaskit/tokens';
14
- import { mediaInlineImageStyles } from '@atlaskit/editor-common/media-inline';
15
- import { tableSharedStyle, columnLayoutSharedStyle, columnLayoutResponsiveSharedStyle, columnLayoutResponsiveRendererStyles, blockquoteSharedStyles, headingsSharedStyles, ruleSharedStyles, whitespaceSharedStyles, paragraphSharedStyles, listsSharedStyles, indentationSharedStyles, blockMarksSharedStyles, mediaSingleSharedStyle, TableSharedCssClassName, tableMarginTop, codeMarkSharedStyles, shadowSharedStyle, dateSharedStyle, richMediaClassName, tasksAndDecisionsStyles, getSmartCardSharedStyles, smartCardSharedStyles, tableCellPadding, textColorStyles, backgroundColorStyles, codeBlockInListSafariFix, SmartCardSharedCssClassName } from '@atlaskit/editor-common/styles';
16
- import { shadowClassNames, shadowObserverClassNames } from '@atlaskit/editor-common/ui';
17
- import { browser } from '@atlaskit/editor-common/browser';
18
- import { editorFontSize, blockNodesVerticalMargin, akEditorTableToolbar, akEditorTableBorder, akEditorTableNumberColumnWidth, gridMediumMaxWidth, akEditorFullWidthLayoutWidth, akEditorStickyHeaderZIndex, relativeFontSizeToBase16 } from '@atlaskit/editor-shared-styles';
19
- import { RendererCssClassName } from '../../consts';
20
- import { HeadingAnchorWrapperClassName } from '../../react/nodes/heading-anchor';
21
- import { getLightWeightCodeBlockStylesForRootRendererStyleSheet } from '../../react/nodes/codeBlock/components/lightWeightCodeBlock';
22
- import { isTableResizingEnabled, isStickyScrollbarEnabled } from '../../react/nodes/table';
23
- import { SORTABLE_COLUMN_ICON_CLASSNAME } from '@atlaskit/editor-common/table';
24
- import { editorExperiment } from '@atlaskit/tmp-editor-statsig/experiments';
25
1
  export var FullPagePadding = 32;
26
- var tableShadowWidth = 32;
27
- export var TELEPOINTER_ID = 'ai-streaming-telepointer';
28
- var telepointerStyles = css(_templateObject || (_templateObject = _taggedTemplateLiteral(["\n\t#", " {\n\t\tdisplay: inline-block;\n\t\tposition: relative;\n\t\twidth: 1.5px;\n\t\theight: 25px;\n\t\tbackground-color: ", ";\n\t\tmargin-left: ", ";\n\n\t\t&::after {\n\t\t\tcontent: 'AI';\n\t\t\tposition: absolute;\n\t\t\tdisplay: block;\n\t\t\ttop: 0;\n\t\t\tleft: 0;\n\t\t\tfont-size: 10px;\n\t\t\tfont-weight: ", ";\n\t\t\twidth: 12.5px;\n\t\t\theight: 13px;\n\t\t\tpadding-top: 1px;\n\t\t\tpadding-left: 1.5px;\n\t\t\tline-height: initial;\n\t\t\tborder-radius: 0px 2px 2px 0px;\n\t\t\tcolor: ", ";\n\t\t\tbackground-color: ", ";\n\t\t}\n\t}\n"])), TELEPOINTER_ID, "var(--ds-background-brand-bold, #0C66E4)", "var(--ds-space-025, 2px)", "var(--ds-font-weight-bold, 700)", "var(--ds-text-inverse, white)", "var(--ds-background-brand-bold, #0C66E4)");
29
-
30
- /**
31
- * **DEPRECATED**
32
- *
33
- * Originally defined in `@atlaskit/theme/typography`, but moved here as it has since been deleted in favor of typography tokens.
34
- * This should be removed as part of editor token work. More info:
35
- * https://atlassian.slack.com/archives/C075G5D7ZP1/p1733449725865539?thread_ts=1732159801.409789&cid=C075G5D7ZP1
36
- * */
37
- var headingSizesImport = {
38
- h900: {
39
- size: 35,
40
- lineHeight: 40
41
- },
42
- h800: {
43
- size: 29,
44
- lineHeight: 32
45
- },
46
- h700: {
47
- size: 24,
48
- lineHeight: 28
49
- },
50
- h600: {
51
- size: 20,
52
- lineHeight: 24
53
- },
54
- h500: {
55
- size: 16,
56
- lineHeight: 20
57
- },
58
- h400: {
59
- size: 14,
60
- lineHeight: 16
61
- },
62
- h300: {
63
- size: 12,
64
- lineHeight: 16
65
- },
66
- h200: {
67
- size: 12,
68
- lineHeight: 16
69
- },
70
- h100: {
71
- size: 11,
72
- lineHeight: 16
73
- }
74
- };
75
- var getLineHeight = function getLineHeight(fontCode) {
76
- return headingSizesImport[fontCode].lineHeight / headingSizesImport[fontCode].size;
77
- };
78
- var headingSizes = {
79
- h1: {
80
- lineHeight: getLineHeight('h700')
81
- },
82
- h2: {
83
- lineHeight: getLineHeight('h600')
84
- },
85
- h3: {
86
- lineHeight: getLineHeight('h500')
87
- },
88
- h4: {
89
- lineHeight: getLineHeight('h400')
90
- },
91
- h5: {
92
- lineHeight: getLineHeight('h300')
93
- },
94
- h6: {
95
- lineHeight: getLineHeight('h100')
96
- }
97
- };
98
- var headingAnchorStyle = function headingAnchorStyle(headingTag) {
99
- return css(_templateObject2 || (_templateObject2 = _taggedTemplateLiteral(["\n\t/**\n * The copy link button doesn't reserve space in the DOM so that\n * the text alignment isn't impacted by the button/icon's space.\n */\n\t.", " {\n\t\tposition: absolute;\n\t\theight: ", "em;\n\n\t\tmargin-left: ", ";\n\n\t\tbutton {\n\t\t\tpadding-left: 0;\n\t\t\tpadding-right: 0;\n\t\t}\n\t}\n\n\t/**\n * Applies hover effects to the heading anchor link button\n * to fade in when the user rolls over the heading.\n *\n * The link is persistent on mobile, so we use feature detection\n * to enable hover effects for systems that support it (desktop).\n *\n * @see https://caniuse.com/mdn-css_at-rules_media_hover\n */\n\t@media (hover: hover) and (pointer: fine) {\n\t\t.", " {\n\t\t\t> button {\n\t\t\t\topacity: 0;\n\t\t\t\ttransform: translate(-8px, 0px);\n\t\t\t\ttransition:\n\t\t\t\t\topacity 0.2s ease 0s,\n\t\t\t\t\ttransform 0.2s ease 0s;\n\t\t\t}\n\t\t}\n\n\t\t&:hover {\n\t\t\t.", " > button {\n\t\t\t\topacity: 1;\n\t\t\t\ttransform: none !important;\n\t\t\t}\n\t\t}\n\t}\n\n\t/**\n * Adds the visibility of the button when in focus through keyboard navigation.\n */\n\t.", " {\n\t\tbutton:focus {\n\t\t\topacity: 1;\n\t\t\ttransform: none !important;\n\t\t}\n\t}\n"])), HeadingAnchorWrapperClassName, headingSizes[headingTag].lineHeight, "var(--ds-space-075, 6px)", HeadingAnchorWrapperClassName, HeadingAnchorWrapperClassName, HeadingAnchorWrapperClassName);
100
- };
101
- var alignedHeadingAnchorStyle = function alignedHeadingAnchorStyle(_ref) {
102
- var allowNestedHeaderLinks = _ref.allowNestedHeaderLinks;
103
- if (!allowNestedHeaderLinks) {
104
- return '';
105
- }
106
- return css(_templateObject3 || (_templateObject3 = _taggedTemplateLiteral(["\n\t\t.fabric-editor-block-mark[data-align] > {\n\t\t\th1,\n\t\t\th2,\n\t\t\th3,\n\t\t\th4,\n\t\t\th5,\n\t\t\th6 {\n\t\t\t\tposition: relative;\n\t\t\t}\n\t\t}\n\n\t\t/**\n * For right-alignment we flip the link to be before the heading\n * text so that the text is flush up against the edge of the editor's\n * container edge.\n */\n\t\t.fabric-editor-block-mark:not([data-align='center'])[data-align] {\n\t\t\t.", " {\n\t\t\t\tmargin: 0 ", " 0 0;\n\t\t\t\t// If the anchor is right aligned then the left side of the heading\n\t\t\t\t// is aligned with the left side of the anchor.\n\t\t\t\t// In order to align as expected we transform it the width of the element (plus our expected 6px)\n\t\t\t\t// to the left\n\t\t\t\ttransform: translateX(calc(-100% - ", "));\n\t\t\t}\n\n\t\t\t@media (hover: hover) and (pointer: fine) {\n\t\t\t\t.", " > button {\n\t\t\t\t\ttransform: translate(8px, 0px);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t"])), HeadingAnchorWrapperClassName, "var(--ds-space-075, 6px)", "var(--ds-space-075, 6px)", HeadingAnchorWrapperClassName);
107
- };
108
- var tableSortableColumnStyle = function tableSortableColumnStyle(_ref2) {
109
- var allowColumnSorting = _ref2.allowColumnSorting,
110
- allowNestedHeaderLinks = _ref2.allowNestedHeaderLinks;
111
- if (!allowColumnSorting) {
112
- return '';
113
- }
114
- var headingsCss = '';
115
- if (allowNestedHeaderLinks) {
116
- headingsCss = "\n /**\n * When the sort button is enabled we want the heading's copy link button\n * to reserve space so that it can prematurely wrap to avoid the button\n * being displayed underneath the sort button (hidden or obscured).\n *\n * The two buttons fight each other since the sort button is displayed\n * on hover of the <th /> and the copy link button is displayed on hover\n * of the heading.\n *\n * Note that this can break the WYSIWYG experience in the case where\n * a heading fills the width of the table cell and the only thing which\n * wraps is the copy link button. This is hopefully a rare fringe case.\n */\n .".concat(HeadingAnchorWrapperClassName, " {\n position: unset;\n }\n > {\n h1, h2, h3, h4, h5, h6 {\n margin-right: 30px;\n }\n }\n ");
117
- }
118
- return css(_templateObject4 || (_templateObject4 = _taggedTemplateLiteral(["\n\t\t.", " {\n\t\t\tpadding: 0;\n\n\t\t\t.", " {\n\t\t\t\twidth: 100%;\n\t\t\t\theight: 100%;\n\t\t\t\tpadding: ", "px;\n\t\t\t\tborder-width: 1.5px;\n\t\t\t\tborder-style: solid;\n\t\t\t\tborder-color: transparent;\n\n\t\t\t\t> *:first-child {\n\t\t\t\t\tmargin-top: 0;\n\t\t\t\t}\n\n\t\t\t\t> .ProseMirror-gapcursor:first-child + *,\n\t\t\t\t> style:first-child + .ProseMirror-gapcursor + * {\n\t\t\t\t\tmargin-top: 0;\n\t\t\t\t}\n\n\t\t\t\t> .ProseMirror-gapcursor:first-child + span + *,\n\t\t\t\t> style:first-child + .ProseMirror-gapcursor + span + * {\n\t\t\t\t\tmargin-top: 0;\n\t\t\t\t}\n\n\t\t\t\t@supports selector(:focus-visible) {\n\t\t\t\t\t&:focus {\n\t\t\t\t\t\toutline: unset;\n\t\t\t\t\t}\n\t\t\t\t\t&:focus-visible {\n\t\t\t\t\t\tborder-color: ", ";\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\t", "\n\t\t\t}\n\n\t\t\t", "\n\t\t}\n\t"])), RendererCssClassName.SORTABLE_COLUMN_WRAPPER, RendererCssClassName.SORTABLE_COLUMN, tableCellPadding, "var(--ds-border-focused, ".concat(colors.B300, ")"), headingsCss, css(_templateObject5 || (_templateObject5 = _taggedTemplateLiteral(["\n\t\t\t\t// New styles\n\t\t\t\t> .", "\n\t\t\t\t\t> .", " {\n\t\t\t\t\tmargin: 0;\n\n\t\t\t\t\t.", " {\n\t\t\t\t\t\topacity: 1;\n\t\t\t\t\t\ttransition: opacity 0.2s ease-in-out;\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\t> .", "\n\t\t\t\t\t> .", " {\n\t\t\t\t\t.", " {\n\t\t\t\t\t\topacity: 0;\n\t\t\t\t\t\t&:focus {\n\t\t\t\t\t\t\topacity: 1;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\t&:hover:not(\n\t\t\t\t\t\t:has(\n\t\t\t\t\t\t\t\t.", "\n\t\t\t\t\t\t\t\t\t.", ":hover\n\t\t\t\t\t\t\t)\n\t\t\t\t\t)\n\t\t\t\t\t> .", "\n\t\t\t\t\t> .", " {\n\t\t\t\t\t.", " {\n\t\t\t\t\t\topacity: 1;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t"])), RendererCssClassName.SORTABLE_COLUMN, RendererCssClassName.SORTABLE_COLUMN_ICON_WRAPPER, SORTABLE_COLUMN_ICON_CLASSNAME, RendererCssClassName.SORTABLE_COLUMN, RendererCssClassName.SORTABLE_COLUMN_NO_ORDER, SORTABLE_COLUMN_ICON_CLASSNAME, RendererCssClassName.SORTABLE_COLUMN_WRAPPER, RendererCssClassName.SORTABLE_COLUMN, RendererCssClassName.SORTABLE_COLUMN, RendererCssClassName.SORTABLE_COLUMN_NO_ORDER, SORTABLE_COLUMN_ICON_CLASSNAME));
119
- };
120
- var fullPageStyles = function fullPageStyles(_ref3, _ref4) {
121
- var appearance = _ref3.appearance;
122
- var theme = _ref4.theme;
123
- if (appearance !== 'full-page') {
124
- return '';
125
- }
126
- return css(_templateObject6 || (_templateObject6 = _taggedTemplateLiteral(["\n\t\tmax-width: ", ";\n\t\tmargin: 0 auto;\n\t\tpadding: 0 ", "px;\n\t"])), theme && theme.layoutMaxWidth ? "".concat(theme.layoutMaxWidth, "px") : 'none', appearance === 'full-page' ? FullPagePadding : 0);
127
- };
128
- var fullWidthStyles = function fullWidthStyles(_ref5) {
129
- var appearance = _ref5.appearance;
130
- if (appearance !== 'full-width') {
131
- return '';
132
- }
133
- return css(_templateObject7 || (_templateObject7 = _taggedTemplateLiteral(["\n\t\tmax-width: ", "px;\n\t\tmargin: 0 auto;\n\n\t\t/* don't override if the breakout mark has width attribute defined */\n\t\t.fabric-editor-breakout-mark:not([data-has-width='true']),\n\t\t.ak-renderer-extension {\n\t\t\twidth: 100% !important;\n\t\t}\n\n\t\t", "\n\t"])), akEditorFullWidthLayoutWidth, isTableResizingEnabled(appearance) ? '' : "\n .pm-table-container {\n width: 100% !important;\n }\n ");
134
- };
135
- var breakoutWidthStyle = function breakoutWidthStyle() {
136
- return css(_templateObject8 || (_templateObject8 = _taggedTemplateLiteral(["\n\t\t*:not([data-mark-type='fragment']) .", " {\n\t\t\t// Ignored via go/ees007\n\t\t\t// eslint-disable-next-line @atlaskit/editor/enforce-todo-comment-format\n\t\t\t// TODO - improve inline style logic on table container so important styles aren't required here\n\t\t\twidth: 100% !important;\n\t\t\tleft: 0 !important;\n\t\t}\n\n\t\t[data-mark-type='fragment'] * .", " {\n\t\t\t// Ignored via go/ees007\n\t\t\t// eslint-disable-next-line @atlaskit/editor/enforce-todo-comment-format\n\t\t\t// TODO - improve inline style logic on table container so important styles aren't required here\n\t\t\twidth: 100% !important;\n\t\t\tleft: 0 !important;\n\t\t}\n\t"])), TableSharedCssClassName.TABLE_CONTAINER, TableSharedCssClassName.TABLE_CONTAINER);
137
- };
138
- var getShadowOverrides = function getShadowOverrides() {
139
- return css(_templateObject9 || (_templateObject9 = _taggedTemplateLiteral(["\n\t\t/** Shadow overrides */\n\t\t&.", "::after, &.", "::before {\n\t\t\twidth: ", "px;\n\t\t\tbackground: linear-gradient(\n\t\t\t\t\tto left,\n\t\t\t\t\ttransparent 0,\n\t\t\t\t\t", " 140%\n\t\t\t\t),\n\t\t\t\tlinear-gradient(\n\t\t\t\t\tto right,\n\t\t\t\t\t", " 0px,\n\t\t\t\t\ttransparent 1px\n\t\t\t\t);\n\t\t}\n\n\t\t&.", "::after {\n\t\t\tbackground: linear-gradient(\n\t\t\t\t\tto right,\n\t\t\t\t\ttransparent 0,\n\t\t\t\t\t", " 140%\n\t\t\t\t),\n\t\t\t\tlinear-gradient(\n\t\t\t\t\tto left,\n\t\t\t\t\t", " 0px,\n\t\t\t\t\ttransparent 1px\n\t\t\t\t);\n\t\t\tright: 0px;\n\t\t}\n\t"])), shadowClassNames.RIGHT_SHADOW, shadowClassNames.LEFT_SHADOW, tableShadowWidth, "var(--ds-shadow-overflow-spread, ".concat(N40A, ")"), "var(--ds-shadow-overflow-perimeter, transparent)", shadowClassNames.RIGHT_SHADOW, "var(--ds-shadow-overflow-spread, ".concat(N40A, ")"), "var(--ds-shadow-overflow-perimeter, transparent)");
140
- };
141
- function getAnnotationStyles(_ref6) {
142
- var allowAnnotations = _ref6.allowAnnotations;
143
- if (!fg('editor_inline_comments_on_inline_nodes')) {
144
- return '';
145
- }
146
- if (fg('annotations_align_editor_and_renderer_styles')) {
147
- return css({
148
- // eslint-disable-next-line @atlaskit/ui-styling-standard/no-nested-selectors
149
- '& [data-annotation-draft-mark][data-annotation-inline-node]': {
150
- borderBottom: '2px solid transparent',
151
- cursor: 'pointer',
152
- padding: '1px 0 2px',
153
- background: "var(--ds-background-accent-yellow-subtler, ".concat(Y75, ")"),
154
- borderBottomColor: "var(--ds-border-accent-yellow, ".concat(Y300, ")"),
155
- boxShadow: "var(--ds-shadow-overlay, ".concat("1px 2px 3px ".concat(N60A, ", -1px 2px 3px ").concat(N60A), ")")
156
- },
157
- // eslint-disable-next-line @atlaskit/ui-styling-standard/no-nested-selectors
158
- '& [data-annotation-draft-mark][data-annotation-inline-node][data-inline-card]': {
159
- padding: '5px 0 3px 0'
160
- },
161
- // eslint-disable-next-line @atlaskit/ui-styling-standard/no-nested-selectors
162
- '& [data-annotation-draft-mark][data-annotation-inline-node].date-lozenger-container': {
163
- paddingTop: "var(--ds-space-025, 2px)"
164
- }
165
- });
166
- }
167
- return css({
168
- // eslint-disable-next-line @atlaskit/ui-styling-standard/no-nested-selectors
169
- "& [data-mark-type='annotation'][data-mark-annotation-state='active'] [data-annotation-mark], & [data-annotation-draft-mark][data-annotation-inline-node]": {
170
- background: "var(--ds-background-accent-yellow-subtler, ".concat(Y75, ")"),
171
- borderBottom: "2px solid ".concat("var(--ds-border-accent-yellow, ".concat(Y300, ")")),
172
- boxShadow: "var(--ds-shadow-overlay, ".concat("1px 2px 3px ".concat(N60A, ", -1px 2px 3px ").concat(N60A), ")"),
173
- cursor: 'pointer',
174
- padding: "var(--ds-space-050, 4px)".concat(" ", "var(--ds-space-025, 2px)")
175
- }
176
- });
177
- }
178
- var tableRowHeight = 44;
179
- var stickyScrollbarStyles = "\n\tposition: relative;\n\tflex-direction: column;\n\n\t> .".concat(TableSharedCssClassName.TABLE_STICKY_SCROLLBAR_CONTAINER, " {\n\t width: 100%;\n\t display: block;\n\t visibility: hidden;\n\t overflow-x: auto;\n\t position: sticky;\n\t bottom: ", "var(--ds-space-0, 0px)", ";\n\t z-index: 1;\n\t}\n\n\t> .").concat(TableSharedCssClassName.TABLE_STICKY_SCROLLBAR_SENTINEL_BOTTOM, ",\n\t> .").concat(TableSharedCssClassName.TABLE_STICKY_SCROLLBAR_SENTINEL_TOP, " {\n\t position: absolute;\n\t width: 100%;\n\t height: 1px;\n\t margin-top: -1px;\n\t // need this to avoid sentinel being focused via keyboard\n\t // this still allows it to be detected by intersection observer\n\t visibility: hidden;\n\t }\n\t > .").concat(TableSharedCssClassName.TABLE_STICKY_SCROLLBAR_SENTINEL_TOP, " {\n\t top: ").concat(tableRowHeight * 3, "px;\n\t }\n\t > .").concat(TableSharedCssClassName.TABLE_STICKY_SCROLLBAR_SENTINEL_BOTTOM, " {\n\t bottom: ", "var(--ds-space-250, 20px)", "; // MAX_BROWSER_SCROLLBAR_HEIGHT = 20;\n\t }\n ");
180
-
181
- // Ignored via go/ees005
182
- // eslint-disable-next-line @typescript-eslint/no-explicit-any
183
- export var rendererStyles = function rendererStyles(wrapperProps) {
184
- return function (theme) {
185
- var _getGlobalTheme = getGlobalTheme(),
186
- typography = _getGlobalTheme.typography;
187
- // This is required to be compatible with styled-components prop structure.
188
- var themeProps = {
189
- theme: theme
190
- };
191
- var useBlockRenderForCodeBlock = wrapperProps.useBlockRenderForCodeBlock,
192
- appearance = wrapperProps.appearance;
193
- var isAdvancedLayoutsOn = editorExperiment('advanced_layouts', true);
194
-
195
- // eslint-disable-next-line @atlaskit/design-system/ensure-design-token-usage/preview, @atlaskit/design-system/no-css-tagged-template-expression
196
- return css(_templateObject10 || (_templateObject10 = _taggedTemplateLiteral(["\n\t\tfont-size: ", "px;\n\t\tline-height: 1.5rem;\n\t\tcolor: ", ";\n\n\t\t.", "::after {\n\t\t\t// we add a clearfix after ak-renderer-document in order to\n\t\t\t// contain internal floats (such as media images that are \"wrap-left\")\n\t\t\t// to just the renderer (and not spill outside of it)\n\t\t\tcontent: '';\n\t\t\tvisibility: hidden;\n\t\t\tdisplay: block;\n\t\t\theight: 0;\n\t\t\tclear: both;\n\t\t}\n\n\t\t", "\n\t\t", "\n\n .", " {\n\t\t\t", "\n\t\t}\n\n\t\t& h1 {\n\t\t\t", "\n\t\t}\n\n\t\t& h2 {\n\t\t\t", "\n\t\t}\n\n\t\t& h3 {\n\t\t\t", "\n\t\t}\n\n\t\t& h4 {\n\t\t\t", "\n\t\t}\n\n\t\t& h5 {\n\t\t\t", "\n\t\t}\n\n\t\t& h6 {\n\t\t\t", "\n\t\t}\n\n\t\t& span.akActionMark {\n\t\t\tcolor: ", ";\n\t\t\ttext-decoration: none;\n\n\t\t\t&:hover {\n\t\t\t\tcolor: ", ";\n\t\t\t\ttext-decoration: underline;\n\t\t\t}\n\n\t\t\t&:active {\n\t\t\t\tcolor: ", ";\n\t\t\t}\n\t\t}\n\n\t\t& span.akActionMark {\n\t\t\tcursor: pointer;\n\t\t}\n\n\t\t& span[data-placeholder] {\n\t\t\tcolor: ", ";\n\t\t}\n\n\t\t", "\n\t\t", ";\n\t\t", ";\n\t\t", ";\n\t\t", ";\n\t\t", ";\n\t\t", ";\n\t\t", ";\n\t\t", ";\n\t\t", ";\n\t\t", ";\n\t\t", ";\n\t\t", ";\n\t\t", ";\n\t\t", ";\n\t\t", "\n\t\t", "\n\n\t\t& .UnknownBlock {\n\t\t\tfont-family: ", ";\n\t\t\tfont-size: ", ";\n\t\t\tfont-weight: ", ";\n\t\t\twhite-space: pre-wrap;\n\t\t\tword-wrap: break-word;\n\t\t}\n\n\t\t& span.date-node {\n\t\t\tbackground: ", ";\n\t\t\tborder-radius: ", ";\n\t\t\tcolor: ", ";\n\t\t\tpadding: ", " ", ";\n\t\t\tmargin: 0 1px;\n\t\t\ttransition: background 0.3s;\n\t\t}\n\n\t\t& span.date-node-highlighted {\n\t\t\tbackground: ", ";\n\t\t\tcolor: ", ";\n\t\t}\n\n\t\t& .renderer-image {\n\t\t\tmax-width: 100%;\n\t\t\tdisplay: block;\n\t\t\tmargin: ", " 0;\n\t\t}\n\n\t\t.", ".rich-media-wrapped + .", ":not(.rich-media-wrapped) {\n\t\t\tclear: both;\n\t\t}\n\n\t\t& .code-block,\n\t\t& blockquote,\n\t\t& hr,\n\t\t& > div > div:not(.rich-media-wrapped),\n\t\t.", ".rich-media-wrapped + .rich-media-wrapped + *:not(.rich-media-wrapped),\n\t\t.", ".rich-media-wrapped + div:not(.rich-media-wrapped),\n\t\t.", ".image-align-start,\n\t\t\t.", ".image-center,\n\t\t\t.", ".image-align-end {\n\t\t\tclear: both;\n\t\t}\n\n\t\t& .rich-media-wrapped {\n\t\t\t& + h1,\n\t\t\t& + h2,\n\t\t\t& + h3,\n\t\t\t& + h4,\n\t\t\t& + h5,\n\t\t\t& + h6 {\n\t\t\t\tmargin-top: ", ";\n\t\t\t}\n\t\t}\n\n\t\t", "\n\t\t/* plugin styles */\n ", " &\n div[class^='image-wrap-'] + div[class^='image-wrap-'] {\n\t\t\tmargin-left: 0;\n\t\t\tmargin-right: 0;\n\t\t}\n\n\t\t/* Breakout for tables and extensions */\n\t\t.", " > {\n\t\t\t", "\n\n\t\t\t* .", " {\n\t\t\t\toverflow-x: auto;\n\t\t\t}\n\n\t\t\t& .", ":first-child {\n\t\t\t\tmargin-top: 0;\n\t\t\t}\n\t\t}\n\n\t\t.", " {\n\t\t\t.", " {\n\t\t\t\tmargin-top: ", ";\n\t\t\t}\n\n\t\t\t.", " {\n\t\t\t\tmargin-left: 50%;\n\t\t\t\ttransform: translateX(-50%);\n\t\t\t}\n\n\t\t\t.", " {\n\t\t\t\toverflow-x: auto;\n\t\t\t}\n\n\t\t\t.", " .", " {\n\t\t\t\tdisplay: flex;\n\t\t\t}\n\t\t}\n\n\t\t", "\n\n\t\t.", " .", " {\n\t\t\tz-index: 0;\n\t\t\ttransition: all 0.1s linear;\n\t\t\tdisplay: flex; /* needed to avoid position: fixed jumpiness in Chrome */\n\n\t\t\t/** Shadow overrides */\n\t\t\t&.", "::after, &.", "::before {\n\t\t\t\ttop: ", "px;\n\t\t\t\theight: calc(100% - ", "px);\n\t\t\t\tz-index: ", ";\n\t\t\t}\n\n\t\t\t", "\n\n\t\t\t", "\n\n\t\t\t&\n .", ",\n &\n .", " {\n\t\t\t\theight: calc(100% - ", "px);\n\t\t\t}\n\n\t\t\t/**\n\t\t\t * A hack for making all the <th /> heights equal in case some have shorter\n\t\t\t * content than others.\n\t\t\t *\n\t\t\t * This is done to make sort buttons fill entire <th />.\n\t\t\t*/\n\t\t\t", " {\n\t\t\t\theight: 1px; /* will be ignored */\n\t\t\t\t", ";\n\t\t\t\tmargin-left: 0;\n\t\t\t\tmargin-right: 0;\n\t\t\t}\n\n\t\t\t", " {\n\t\t\t\theight: 100%;\n\n\t\t\t\ttd,\n\t\t\t\tth {\n\t\t\t\t\tposition: relative;\n\t\t\t\t}\n\t\t\t}\n\n\t\t\ttable[data-number-column='true'] {\n\t\t\t\t.", " {\n\t\t\t\t\tbackground-color: ", ";\n\t\t\t\t\tborder-right: 1px solid\n\t\t\t\t\t\t", ";\n\t\t\t\t\twidth: ", "px;\n\t\t\t\t\ttext-align: center;\n\t\t\t\t\tcolor: ", ";\n\t\t\t\t\tfont-size: ", ";\n\t\t\t\t}\n\n\t\t\t\t.fixed .", " {\n\t\t\t\t\tborder-right: 0px none;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\ttr[data-header-row].fixed {\n\t\t\tposition: fixed !important;\n\t\t\tdisplay: flex;\n\t\t\toverflow: hidden;\n\t\t\tz-index: ", ";\n\n\t\t\tborder-right: 1px solid ", ";\n\t\t\tborder-bottom: 1px solid ", ";\n\n\t\t\t/* this is to compensate for the table border */\n\t\t\ttransform: translateX(-1px);\n\t\t}\n\n\t\t.sticky > th {\n\t\t\tz-index: ", ";\n\t\t\tposition: sticky !important;\n\t\t\ttop: 0;\n\t\t}\n\n\t\t/* Make the number column header sticky */\n\t\t.sticky > td {\n\t\t\tposition: sticky !important;\n\t\t\ttop: 0;\n\t\t}\n\n\t\t/* add border for position: sticky\n and work around background-clip: padding-box\n bug for FF causing box-shadow bug in Chrome */\n\t\t.sticky th,\n\t\t.sticky td {\n\t\t\tbox-shadow:\n\t\t\t\t0px 1px ", ",\n\t\t\t\t0px -0.5px ", ",\n\t\t\t\tinset -1px 0px ", ",\n\t\t\t\t0px -1px ", ";\n\t\t}\n\n\t\t/* this will remove jumpiness caused in Chrome for sticky headers */\n\t\t.fixed + tr {\n\t\t\tmin-height: 0px;\n\t\t}\n\n\t\t/*\n * We wrap CodeBlock in a grid to prevent it from overflowing the container of the renderer.\n * See ED-4159.\n */\n\t\t& .code-block {\n\t\t\tmax-width: 100%;\n\t\t\t/* -ms- properties are necessary until MS supports the latest version of the grid spec */\n\t\t\t/* stylelint-disable value-no-vendor-prefix, declaration-block-no-duplicate-properties */\n\t\t\tdisplay: block;\n\t\t\t/* stylelint-enable */\n\n\t\t\tposition: relative;\n\t\t\tborder-radius: ", ";\n\n\t\t\t/*\n * The overall renderer has word-wrap: break; which causes issues with\n * code block line numbers in Safari / iOS.\n */\n\t\t\tword-wrap: normal;\n\t\t}\n\n\t\t& .MediaGroup,\n\t\t& .code-block {\n\t\t\tmargin-top: ", ";\n\n\t\t\t&:first-child {\n\t\t\t\tmargin-top: 0;\n\t\t\t}\n\t\t}\n\n\t\t", "\n\n\t\t", "\n\n ", ";\n\t\t", ";\n\t\t& [data-layout-section] {\n\t\t\tmargin-top: ", ";\n\t\t\t& > div + div {\n\t\t\t\tmargin-left: ", ";\n\t\t\t}\n\n\t\t\t@media screen and (max-width: ", "px) {\n\t\t\t\t& > div + div {\n\t\t\t\t\tmargin-left: 0;\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t& .MediaGroup,\n\t\t\t& .code-block {\n\t\t\t\tmargin-top: ", ";\n\n\t\t\t\t&:first-child {\n\t\t\t\t\tmargin-top: 0;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\t& li {\n\t\t\t> .code-block {\n\t\t\t\tmargin: ", " 0 0 0;\n\t\t\t}\n\t\t\t> .code-block:first-child {\n\t\t\t\tmargin-top: 0;\n\t\t\t}\n\n\t\t\t> div:last-of-type.code-block {\n\t\t\t\tmargin-bottom: ", ";\n\t\t\t}\n\t\t}\n\n\t\t&:not([data-node-type='decisionList']) > li,\n // This prevents https://product-fabric.atlassian.net/browse/ED-20924\n &:not(.", ") > li {\n\t\t\t", "\n\t\t}\n\t"])), editorFontSize(themeProps), "var(--ds-text, ".concat(colors.N800, ")"), RendererCssClassName.DOCUMENT, fullPageStyles(wrapperProps, themeProps), fullWidthStyles(wrapperProps), RendererCssClassName.DOCUMENT, 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, whitespaceSharedStyles, blockquoteSharedStyles, headingsSharedStyles(typography), ruleSharedStyles(), paragraphSharedStyles(typography), listsSharedStyles, indentationSharedStyles, blockMarksSharedStyles, codeMarkSharedStyles(), shadowSharedStyle, dateSharedStyle, textColorStyles, backgroundColorStyles(), tasksAndDecisionsStyles, fg('platform-linking-visual-refresh-v1') ? getSmartCardSharedStyles() : smartCardSharedStyles, getAnnotationStyles(wrapperProps), "var(--ds-font-family-body, ui-sans-serif, -apple-system, BlinkMacSystemFont, \"Segoe UI\", Ubuntu, \"Helvetica Neue\", sans-serif)", relativeFontSizeToBase16(14), "var(--ds-font-weight-regular, 400)", "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)", richMediaClassName, richMediaClassName, richMediaClassName, richMediaClassName, richMediaClassName, richMediaClassName, richMediaClassName, "var(--ds-space-100, 8px)", alignedHeadingAnchorStyle(wrapperProps), mediaSingleSharedStyle, RendererCssClassName.DOCUMENT, breakoutWidthStyle(), RendererCssClassName.EXTENSION_OVERFLOW_CONTAINER, RendererCssClassName.EXTENSION, RendererCssClassName.DOCUMENT, RendererCssClassName.EXTENSION, blockNodesVerticalMargin, RendererCssClassName.EXTENSION_CENTER_ALIGN, TableSharedCssClassName.TABLE_NODE_WRAPPER, shadowObserverClassNames.SHADOW_CONTAINER, TableSharedCssClassName.TABLE_NODE_WRAPPER, tableSharedStyle(), RendererCssClassName.DOCUMENT, TableSharedCssClassName.TABLE_CONTAINER, shadowClassNames.RIGHT_SHADOW, shadowClassNames.LEFT_SHADOW, tableMarginTop - 1, tableMarginTop, akEditorStickyHeaderZIndex, getShadowOverrides(), isStickyScrollbarEnabled(appearance) ? stickyScrollbarStyles : '', shadowObserverClassNames.SENTINEL_LEFT, shadowObserverClassNames.SENTINEL_RIGHT, tableMarginTop, fg('platform_editor_renderer_table_header_styles') ? ".".concat(TableSharedCssClassName.TABLE_NODE_WRAPPER, " > table, .").concat(TableSharedCssClassName.TABLE_STICKY_WRAPPER, " > table") : 'table', tableSortableColumnStyle(wrapperProps), fg('platform_editor_renderer_table_header_styles') ? ".".concat(TableSharedCssClassName.TABLE_NODE_WRAPPER, " > table > tbody > tr:first-of-type, .").concat(TableSharedCssClassName.TABLE_STICKY_WRAPPER, " > table > tbody > tr:first-of-type") : 'table tr:first-of-type', RendererCssClassName.NUMBER_COLUMN, fg('platform_editor_tables_numbered_column_correction') ? "var(--ds-background-accent-gray-subtlest, #F1F2F4)" : "var(--ds-background-neutral, ".concat(akEditorTableToolbar, ")"), "var(--ds-background-accent-gray-subtler, ".concat(akEditorTableBorder, ")"), akEditorTableNumberColumnWidth, "var(--ds-text-subtlest, ".concat(colors.N200, ")"), relativeFontSizeToBase16(14), RendererCssClassName.NUMBER_COLUMN, akEditorStickyHeaderZIndex, "var(--ds-background-accent-gray-subtler, ".concat(akEditorTableBorder, ")"), "var(--ds-background-accent-gray-subtler, ".concat(akEditorTableBorder, ")"), akEditorStickyHeaderZIndex, "var(--ds-background-accent-gray-subtler, ".concat(akEditorTableBorder, ")"), "var(--ds-background-accent-gray-subtler, ".concat(akEditorTableBorder, ")"), "var(--ds-background-accent-gray-subtler, ".concat(akEditorTableToolbar, ")"), "var(--ds-background-accent-gray-subtler, ".concat(akEditorTableToolbar, ")"), "var(--ds-border-radius-100, 3px)", blockNodesVerticalMargin, useGridRenderForCodeBlock(useBlockRenderForCodeBlock), getLightWeightCodeBlockStylesForRootRendererStyleSheet(), isAdvancedLayoutsOn ? columnLayoutResponsiveSharedStyle : columnLayoutSharedStyle, isAdvancedLayoutsOn && columnLayoutResponsiveRendererStyles, "var(--ds-space-250, 20px)", isAdvancedLayoutsOn ? 0 : "var(--ds-space-400, 32px)", gridMediumMaxWidth, blockNodesVerticalMargin, blockNodesVerticalMargin, blockNodesVerticalMargin, SmartCardSharedCssClassName.BLOCK_CARD_CONTAINER, browser.safari ? codeBlockInListSafariFix : '');
197
- };
198
- };
199
- var useGridRenderForCodeBlock = function useGridRenderForCodeBlock(codeBlockRenderAsBlock) {
200
- if (codeBlockRenderAsBlock) {
201
- return '';
202
- }
203
- return "& .code-block {\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: -ms-grid;\n display: grid;\n -ms-grid-columns: auto 1fr;\n /* stylelint-enable */\n\n grid-template-columns: minmax(0, 1fr);\n\n & > span {\n /* stylelint-disable value-no-vendor-prefix */\n -ms-grid-row: 1;\n -ms-grid-column: 2;\n /* stylelint-enable */\n grid-column: 1;\n }\n }";
204
- };
2
+ export var TELEPOINTER_ID = 'ai-streaming-telepointer';
@@ -12,26 +12,11 @@ import { AnnotationsDraftContext } from '../context';
12
12
  import { splitText, calcTextSplitOffset, findTextString } from './text';
13
13
  import { calcInsertDraftPositionOnText } from './position';
14
14
  import { dataAttributes } from './dom';
15
- import { AnnotationSharedCSSByState } from '@atlaskit/editor-common/styles';
16
15
  import { segmentText } from '../../../react/utils/segment-text';
17
16
  import { renderTextSegments } from '../../../react/utils/render-text-segments';
18
- import { fg } from '@atlaskit/platform-feature-flags';
19
-
20
- // eslint-disable-next-line @atlaskit/design-system/consistent-css-prop-usage -- Ignored via go/DSP-18766
21
- var markStyles = function markStyles() {
22
- return css({
23
- color: 'inherit',
24
- backgroundColor: 'unset',
25
- WebkitTapHighlightColor: 'transparent'
26
- },
27
- // eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values, @atlaskit/ui-styling-standard/no-unsafe-values -- Ignored via go/DSP-18766
28
- AnnotationSharedCSSByState().common,
29
- // eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values, @atlaskit/ui-styling-standard/no-unsafe-values -- Ignored via go/DSP-18766
30
- AnnotationSharedCSSByState().focus);
31
- };
32
17
 
33
18
  // Localized AnnotationSharedCSSByState().common and AnnotationSharedCSSByState().focus
34
- var markStylesNew = css({
19
+ var markStyles = css({
35
20
  color: 'inherit',
36
21
  backgroundColor: 'unset',
37
22
  WebkitTapHighlightColor: 'transparent',
@@ -58,7 +43,7 @@ export var AnnotationDraft = function AnnotationDraft(_ref) {
58
43
  // Ignored via go/ees005
59
44
  // eslint-disable-next-line react/jsx-props-no-spreading
60
45
  }, dataAttributes(draftPosition), {
61
- css: fg('platform_editor_emotion_refactor_renderer') ? markStylesNew : markStyles
46
+ css: markStyles
62
47
  }), children);
63
48
  };
64
49
  export var getAnnotationIndex = function getAnnotationIndex(annotationPosition, fragmentCount) {