@atlaskit/renderer 109.32.2 → 109.32.4

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 (76) hide show
  1. package/CHANGELOG.md +19 -0
  2. package/dist/cjs/actions/get-renderer-range-inline-node-names.js +24 -0
  3. package/dist/cjs/actions/index.js +22 -1
  4. package/dist/cjs/react/marks/breakout.js +5 -1
  5. package/dist/cjs/react/nodes/blockCard.js +1 -0
  6. package/dist/cjs/react/nodes/codeBlock/components/codeBlockButtonContainer.js +3 -0
  7. package/dist/cjs/react/nodes/codeBlock/components/codeBlockContainer.js +1 -1
  8. package/dist/cjs/react/nodes/codeBlock/components/lightWeightCodeBlock.js +4 -2
  9. package/dist/cjs/react/nodes/embedCard.js +2 -0
  10. package/dist/cjs/react/nodes/extension.js +1 -0
  11. package/dist/cjs/react/nodes/layoutColumn.js +6 -1
  12. package/dist/cjs/react/nodes/media/index.js +6 -1
  13. package/dist/cjs/react/nodes/mediaSingle/styles.js +3 -0
  14. package/dist/cjs/react/nodes/multiBodiedExtension.js +2 -1
  15. package/dist/cjs/react/nodes/panel.js +6 -3
  16. package/dist/cjs/react/nodes/table/colgroup.js +1 -1
  17. package/dist/cjs/react/nodes/table/sticky.js +55 -44
  18. package/dist/cjs/ui/Expand.js +2 -0
  19. package/dist/cjs/ui/ExtensionRenderer.js +1 -0
  20. package/dist/cjs/ui/Renderer/index.js +2 -2
  21. package/dist/cjs/ui/Renderer/truncated-wrapper.js +2 -0
  22. package/dist/cjs/ui/annotations/draft/component.js +4 -1
  23. package/dist/cjs/ui/annotations/selection/mounter.js +25 -5
  24. package/dist/es2019/actions/get-renderer-range-inline-node-names.js +19 -0
  25. package/dist/es2019/actions/index.js +22 -1
  26. package/dist/es2019/react/marks/breakout.js +5 -1
  27. package/dist/es2019/react/nodes/blockCard.js +1 -0
  28. package/dist/es2019/react/nodes/codeBlock/components/codeBlockButtonContainer.js +3 -0
  29. package/dist/es2019/react/nodes/codeBlock/components/codeBlockContainer.js +1 -1
  30. package/dist/es2019/react/nodes/codeBlock/components/lightWeightCodeBlock.js +4 -2
  31. package/dist/es2019/react/nodes/embedCard.js +2 -0
  32. package/dist/es2019/react/nodes/extension.js +1 -0
  33. package/dist/es2019/react/nodes/layoutColumn.js +7 -1
  34. package/dist/es2019/react/nodes/media/index.js +6 -1
  35. package/dist/es2019/react/nodes/mediaSingle/styles.js +4 -0
  36. package/dist/es2019/react/nodes/multiBodiedExtension.js +2 -1
  37. package/dist/es2019/react/nodes/panel.js +6 -3
  38. package/dist/es2019/react/nodes/table/colgroup.js +1 -1
  39. package/dist/es2019/react/nodes/table/sticky.js +59 -44
  40. package/dist/es2019/ui/Expand.js +2 -0
  41. package/dist/es2019/ui/ExtensionRenderer.js +1 -0
  42. package/dist/es2019/ui/Renderer/index.js +2 -2
  43. package/dist/es2019/ui/Renderer/truncated-wrapper.js +2 -0
  44. package/dist/es2019/ui/annotations/draft/component.js +5 -1
  45. package/dist/es2019/ui/annotations/selection/mounter.js +25 -5
  46. package/dist/esm/actions/get-renderer-range-inline-node-names.js +18 -0
  47. package/dist/esm/actions/index.js +22 -1
  48. package/dist/esm/react/marks/breakout.js +5 -1
  49. package/dist/esm/react/nodes/blockCard.js +1 -0
  50. package/dist/esm/react/nodes/codeBlock/components/codeBlockButtonContainer.js +3 -0
  51. package/dist/esm/react/nodes/codeBlock/components/codeBlockContainer.js +1 -1
  52. package/dist/esm/react/nodes/codeBlock/components/lightWeightCodeBlock.js +4 -2
  53. package/dist/esm/react/nodes/embedCard.js +2 -0
  54. package/dist/esm/react/nodes/extension.js +1 -0
  55. package/dist/esm/react/nodes/layoutColumn.js +7 -1
  56. package/dist/esm/react/nodes/media/index.js +6 -1
  57. package/dist/esm/react/nodes/mediaSingle/styles.js +4 -0
  58. package/dist/esm/react/nodes/multiBodiedExtension.js +2 -1
  59. package/dist/esm/react/nodes/panel.js +6 -3
  60. package/dist/esm/react/nodes/table/colgroup.js +1 -1
  61. package/dist/esm/react/nodes/table/sticky.js +55 -44
  62. package/dist/esm/ui/Expand.js +2 -0
  63. package/dist/esm/ui/ExtensionRenderer.js +1 -0
  64. package/dist/esm/ui/Renderer/index.js +2 -2
  65. package/dist/esm/ui/Renderer/truncated-wrapper.js +2 -0
  66. package/dist/esm/ui/annotations/draft/component.js +5 -1
  67. package/dist/esm/ui/annotations/selection/mounter.js +25 -5
  68. package/dist/types/actions/get-renderer-range-inline-node-names.d.ts +12 -0
  69. package/dist/types/actions/index.d.ts +3 -0
  70. package/dist/types/analytics/events.d.ts +3 -1
  71. package/dist/types/react/nodes/extension.d.ts +1 -0
  72. package/dist/types-ts4.5/actions/get-renderer-range-inline-node-names.d.ts +12 -0
  73. package/dist/types-ts4.5/actions/index.d.ts +3 -0
  74. package/dist/types-ts4.5/analytics/events.d.ts +3 -1
  75. package/dist/types-ts4.5/react/nodes/extension.d.ts +1 -0
  76. package/package.json +156 -160
@@ -6,6 +6,7 @@ import { AddNodeMarkStep, RemoveMarkStep, RemoveNodeMarkStep } from '@atlaskit/e
6
6
  import { createAnnotationStep, getPosFromRange } from '../steps';
7
7
  import { ACTION, ACTION_SUBJECT, EVENT_TYPE, ACTION_SUBJECT_ID } from '@atlaskit/editor-common/analytics';
8
8
  import { getIndexMatch } from './matches-utils';
9
+ import { getRendererRangeInlineNodeNames } from './get-renderer-range-inline-node-names';
9
10
  export default class RendererActions {
10
11
  // Any kind of refence is allowed
11
12
 
@@ -96,7 +97,16 @@ export default class RendererActions {
96
97
  action: ACTION.DELETED,
97
98
  actionSubject: ACTION_SUBJECT.ANNOTATION,
98
99
  actionSubjectId: ACTION_SUBJECT_ID.INLINE_COMMENT,
99
- eventType: EVENT_TYPE.TRACK
100
+ eventType: EVENT_TYPE.TRACK,
101
+ attributes: {
102
+ inlineNodeNames: step instanceof RemoveMarkStep ? getRendererRangeInlineNodeNames({
103
+ pos: {
104
+ from: from,
105
+ to: to
106
+ },
107
+ actions: this
108
+ }) : undefined
109
+ }
100
110
  };
101
111
  this.onAnalyticsEvent(payload);
102
112
  }
@@ -145,6 +155,10 @@ export default class RendererActions {
145
155
  }
146
156
  return this._privateValidatePositionsForAnnotation(pos.from, pos.to);
147
157
  }
158
+
159
+ /**
160
+ * Note: False indicates that the selection not able to be calculated.
161
+ */
148
162
  getPositionFromRange(range, isCommentsOnMediaBugFixEnabled, isCommentsOnMediaBugVideoComment) {
149
163
  if (!this.doc || !this.schema || !range) {
150
164
  return false;
@@ -244,6 +258,13 @@ export default class RendererActions {
244
258
  return {
245
259
  step,
246
260
  doc: this.transformer.encode(doc),
261
+ inlineNodeTypes: getRendererRangeInlineNodeNames({
262
+ actions: this,
263
+ pos: {
264
+ from,
265
+ to
266
+ }
267
+ }),
247
268
  originalSelection,
248
269
  numMatches,
249
270
  matchIndex,
@@ -3,7 +3,9 @@ import { css, jsx } from '@emotion/react';
3
3
  import { WidthConsumer } from '@atlaskit/editor-common/ui';
4
4
  import { calcBreakoutWidth } from '@atlaskit/editor-common/utils';
5
5
  import { blockNodesVerticalMargin } from '@atlaskit/editor-shared-styles';
6
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-exported-styles, @atlaskit/design-system/no-exported-css -- Ignored via go/DSP-18766
6
7
  export const wrapperStyles = css({
8
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values, @atlaskit/ui-styling-standard/no-unsafe-values -- Ignored via go/DSP-18766
7
9
  margin: `${blockNodesVerticalMargin} 0`,
8
10
  // eslint-disable-next-line @atlaskit/design-system/use-tokens-space
9
11
  marginLeft: '50%',
@@ -14,7 +16,9 @@ export default function Breakout(props) {
14
16
  width
15
17
  }) => jsx("div", {
16
18
  css: wrapperStyles,
17
- "data-mode": props.mode,
19
+ "data-mode": props.mode
20
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values -- Ignored via go/DSP-18766
21
+ ,
18
22
  style: {
19
23
  width: calcBreakoutWidth(props.mode, width)
20
24
  }
@@ -93,6 +93,7 @@ export default function BlockCard(props) {
93
93
  css: datasourceContainerStyle,
94
94
  "data-testid": "renderer-datasource-table",
95
95
  style: {
96
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values -- Ignored via go/DSP-18766
96
97
  width: isNodeNested ? '100%' : calcBreakoutWidth(layout, width)
97
98
  }
98
99
  }, jsx(DatasourceTableView, {
@@ -17,6 +17,7 @@ const codeBlockButtonsStyle = css({
17
17
  right: "var(--ds-space-075, 6px)",
18
18
  top: "var(--ds-space-050, 4px)",
19
19
  padding: "var(--ds-space-025, 2px)",
20
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-nested-selectors -- Ignored via go/DSP-18766
20
21
  button: {
21
22
  height: '32px',
22
23
  width: '32px',
@@ -32,9 +33,11 @@ const codeBlockButtonsStyle = css({
32
33
  height: '32px',
33
34
  width: '32px'
34
35
  },
36
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-nested-selectors -- Ignored via go/DSP-18766
35
37
  '&.clicked': {
36
38
  backgroundColor: `${`var(--ds-background-neutral-bold-pressed, ${N700})`}`,
37
39
  borderRadius: '4px',
40
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-important-styles -- Ignored via go/DSP-18766
38
41
  color: `${`var(--ds-icon-inverse, ${N0})`} !important`
39
42
  }
40
43
  }
@@ -6,7 +6,7 @@ import { fontSize } from '@atlaskit/theme/constants';
6
6
  import { CodeBlockSharedCssClassName } from '@atlaskit/editor-common/styles';
7
7
  import CodeBlockButtonContainer from './codeBlockButtonContainer';
8
8
 
9
- // eslint-disable-next-line @atlaskit/design-system/no-css-tagged-template-expression
9
+ // eslint-disable-next-line @atlaskit/design-system/no-css-tagged-template-expression, @atlaskit/design-system/consistent-css-prop-usage -- Ignored via go/DSP-18766
10
10
  const codeBlockStyleOverrides = css`
11
11
  tab-size: 4;
12
12
  background-color: ${`var(--ds-surface-raised, ${N20})`};
@@ -5,7 +5,7 @@ import { blockNodesVerticalMargin } from '@atlaskit/editor-shared-styles';
5
5
  import { codeBlockSharedStyles, CodeBlockSharedCssClassName } from '@atlaskit/editor-common/styles';
6
6
  import { useBidiWarnings } from '../../../hooks/use-bidi-warnings';
7
7
  import { RendererCssClassName } from '../../../../consts';
8
- // eslint-disable-next-line @atlaskit/design-system/no-css-tagged-template-expression -- needs manual remediation
8
+ // eslint-disable-next-line @atlaskit/design-system/no-css-tagged-template-expression, @atlaskit/design-system/consistent-css-prop-usage -- Ignored via go/DSP-18766
9
9
  const lightWeightCodeBlockStyles = css`
10
10
  .${CodeBlockSharedCssClassName.CODEBLOCK_CONTAINER} {
11
11
  cursor: text;
@@ -45,7 +45,9 @@ const LightWeightCodeBlock = /*#__PURE__*/forwardRef(({
45
45
  return jsx("div", {
46
46
  // eslint-disable-next-line @atlaskit/ui-styling-standard/no-classname-prop -- Ignored via go/DSP-18766
47
47
  className: classNames,
48
- ref: ref,
48
+ ref: ref
49
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values, @atlaskit/design-system/consistent-css-prop-usage -- Ignored via go/DSP-18766
50
+ ,
49
51
  css: [codeBlockSharedStyles(), lightWeightCodeBlockStyles]
50
52
  }, jsx("div", {
51
53
  className: CodeBlockSharedCssClassName.CODEBLOCK_CONTAINER
@@ -14,9 +14,11 @@ import { AnalyticsContext } from '@atlaskit/analytics-next';
14
14
  const embedCardWrapperStyles = css({
15
15
  width: '100%',
16
16
  height: '100%',
17
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-nested-selectors -- Ignored via go/DSP-18766
17
18
  '> div': {
18
19
  height: '100%'
19
20
  },
21
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-nested-selectors -- Ignored via go/DSP-18766
20
22
  '.loader-wrapper': {
21
23
  height: '100%'
22
24
  },
@@ -20,6 +20,7 @@ export const renderExtension = (content, layout, options = {}, removeOverflow) =
20
20
  ,
21
21
  className: `${RendererCssClassName.EXTENSION} ${options.shadowClassNames} ${centerAlignClass}`,
22
22
  style: {
23
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values -- Ignored via go/DSP-18766
23
24
  width: isTopLevel ? calcBreakoutWidth(layout, width) : '100%'
24
25
  },
25
26
  "data-layout": layout
@@ -2,7 +2,13 @@
2
2
  import React from 'react';
3
3
  import { jsx, css } from '@emotion/react';
4
4
  import { WidthProvider, clearNextSiblingMarginTopStyle, clearNextSiblingBlockMarkMarginTopStyle } from '@atlaskit/editor-common/ui';
5
- const layoutColumnClearMarginTopStyles = css(clearNextSiblingMarginTopStyle, clearNextSiblingBlockMarkMarginTopStyle);
5
+
6
+ // eslint-disable-next-line @atlaskit/design-system/consistent-css-prop-usage -- Ignored via go/DSP-18766
7
+ const layoutColumnClearMarginTopStyles = css(
8
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values, @atlaskit/ui-styling-standard/no-unsafe-values -- Ignored via go/DSP-18766
9
+ clearNextSiblingMarginTopStyle,
10
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values, @atlaskit/ui-styling-standard/no-unsafe-values -- Ignored via go/DSP-18766
11
+ clearNextSiblingBlockMarkMarginTopStyle);
6
12
  export default function LayoutSection(props) {
7
13
  return jsx("div", {
8
14
  "data-layout-column": true,
@@ -20,6 +20,7 @@ import { CommentBadge as CommentBadgeComponent } from '@atlaskit/editor-common/m
20
20
  import { injectIntl } from 'react-intl-next';
21
21
  import { useInlineCommentSubscriberContext, useInlineCommentsFilter } from '../../../ui/annotations/hooks';
22
22
  import { AnnotationUpdateEvent } from '@atlaskit/editor-common/types';
23
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-exported-styles, @atlaskit/design-system/no-exported-css, @atlaskit/design-system/no-css-tagged-template-expression, @atlaskit/design-system/consistent-css-prop-usage -- Ignored via go/DSP-18766
23
24
  export const linkStyle = css`
24
25
  position: absolute;
25
26
  background: transparent;
@@ -31,6 +32,8 @@ export const linkStyle = css`
31
32
  width: 100% !important;
32
33
  height: 100% !important;
33
34
  `;
35
+
36
+ // eslint-disable-next-line @atlaskit/design-system/no-css-tagged-template-expression -- Ignored via go/DSP-18766
34
37
  export const borderStyle = (color, width) => css`
35
38
  position: absolute;
36
39
  width: 100% !important;
@@ -52,7 +55,9 @@ const MediaBorder = ({
52
55
  return jsx("div", {
53
56
  "data-mark-type": "border",
54
57
  "data-color": borderColor,
55
- "data-size": borderWidth,
58
+ "data-size": borderWidth
59
+ // eslint-disable-next-line @atlaskit/design-system/consistent-css-prop-usage -- Ignored via go/DSP-18766
60
+ ,
56
61
  css: borderStyle(paletteColorValue, borderWidth)
57
62
  }, jsx(MediaBorderGapFiller, {
58
63
  borderColor: borderColor
@@ -1,8 +1,12 @@
1
1
  /** @jsx jsx */
2
2
  import { css } from '@emotion/react';
3
+
4
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-exported-styles, @atlaskit/design-system/no-exported-css -- Ignored via go/DSP-18766
3
5
  export const uiMediaSingleBaseStyles = css({
4
6
  transition: 'all 0.1s linear'
5
7
  });
8
+
9
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-exported-styles, @atlaskit/design-system/no-exported-css -- Ignored via go/DSP-18766
6
10
  export const uiMediaSingleLayoutStyles = css({
7
11
  // eslint-disable-next-line @atlaskit/design-system/use-tokens-space
8
12
  marginLeft: '50%',
@@ -41,7 +41,7 @@ const useMultiBodiedExtensionActions = ({
41
41
  return actions;
42
42
  };
43
43
 
44
- // eslint-disable-next-line @atlaskit/design-system/no-css-tagged-template-expression -- needs manual remediation
44
+ // eslint-disable-next-line @atlaskit/design-system/no-css-tagged-template-expression, @atlaskit/design-system/consistent-css-prop-usage -- Ignored via go/DSP-18766
45
45
  const navigationCssExtended = css`
46
46
  ${sharedMultiBodiedExtensionStyles.mbeNavigation};
47
47
  margin-left: 0 !important;
@@ -101,6 +101,7 @@ const MultiBodiedExtension = props => {
101
101
  // eslint-disable-next-line @atlaskit/ui-styling-standard/no-classname-prop -- Ignored via go/DSP-18766
102
102
  className: `${RendererCssClassName.EXTENSION} ${centerAlignClass} ${overflowContainerClass}`,
103
103
  style: {
104
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values -- Ignored via go/DSP-18766
104
105
  width: isTopLevel ? calcBreakoutWidth(layout, width) : '100%'
105
106
  },
106
107
  "data-layout": layout
@@ -37,9 +37,12 @@ const PanelStyled = ({
37
37
  }
38
38
  `;
39
39
  }
40
- return jsx("div", _extends({
41
- css: styles
42
- }, props), props.children);
40
+ return (
41
+ // eslint-disable-next-line @atlaskit/design-system/consistent-css-prop-usage -- Ignored via go/DSP-18766
42
+ jsx("div", _extends({
43
+ css: styles
44
+ }, props), props.children)
45
+ );
43
46
  };
44
47
  PanelStyled.displayName = 'PanelStyled';
45
48
  const panelIcons = {
@@ -161,7 +161,7 @@ export const Colgroup = props => {
161
161
  return null;
162
162
  }
163
163
  return /*#__PURE__*/React.createElement("colgroup", null, isNumberColumnEnabled && /*#__PURE__*/React.createElement("col", {
164
- // eslint-disable-next-line @atlaskit/ui-styling-standard/enforce-style-prop -- Ignored via go/DSP-18766
164
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/enforce-style-prop, @atlaskit/ui-styling-standard/no-imported-style-values -- Ignored via go/DSP-18766
165
165
  style: {
166
166
  width: akEditorTableNumberColumnWidth
167
167
  },
@@ -29,12 +29,18 @@ const fixedTableDivStaticStyles = (top, width, rendererAppearance) => {
29
29
  } else {
30
30
  stickyHeaderZIndex = akEditorStickyHeaderZIndex;
31
31
  }
32
+
33
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-values -- Ignored via go/DSP-18766
32
34
  return css(typeof top === 'number' && `top: ${top}px;`, {
35
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-values -- Ignored via go/DSP-18766
33
36
  width: `${width}px`,
37
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-values -- Ignored via go/DSP-18766
34
38
  zIndex: stickyHeaderZIndex,
39
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-nested-selectors, @atlaskit/ui-styling-standard/no-unsafe-values, @atlaskit/ui-styling-standard/no-imported-style-values -- Ignored via go/DSP-18766
35
40
  [`& .${TableSharedCssClassName.TABLE_CONTAINER}, & .${TableSharedCssClassName.TABLE_STICKY_WRAPPER} > table`]: {
36
41
  marginTop: 0,
37
42
  marginBottom: 0,
43
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-nested-selectors -- Ignored via go/DSP-18766
38
44
  tr: {
39
45
  background: "var(--ds-surface, white)"
40
46
  }
@@ -42,14 +48,18 @@ const fixedTableDivStaticStyles = (top, width, rendererAppearance) => {
42
48
  borderTop: `${tableStickyPadding}px solid ${"var(--ds-surface, white)"}`,
43
49
  background: "var(--ds-surface-overlay, white)",
44
50
  boxShadow: `0 6px 4px -4px ${`var(--ds-shadow-overflow-perimeter, ${N40A})`}`,
51
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-nested-selectors, @atlaskit/ui-styling-standard/no-unsafe-selectors -- Ignored via go/DSP-18766
45
52
  "div[data-expanded='false'] &": {
46
53
  display: 'none'
47
54
  },
55
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-nested-selectors, @atlaskit/ui-styling-standard/no-unsafe-values, @atlaskit/ui-styling-standard/no-imported-style-values -- Ignored via go/DSP-18766
48
56
  [`& .${TableSharedCssClassName.TABLE_CONTAINER}.is-sticky.right-shadow::after, & .${TableSharedCssClassName.TABLE_CONTAINER}.is-sticky.left-shadow::before`]: {
49
57
  top: '0px',
50
58
  height: '100%'
51
59
  },
60
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-nested-selectors -- Ignored via go/DSP-18766
52
61
  "&.fixed-table-div-custom-table-resizing[mode='stick']": {
62
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-values -- Ignored via go/DSP-18766
53
63
  zIndex: stickyHeaderZIndex
54
64
  }
55
65
  });
@@ -69,7 +79,9 @@ export const FixedTableDiv = props => {
69
79
  "data-testid": "sticky-table-fixed"
70
80
  // eslint-disable-next-line @atlaskit/ui-styling-standard/no-classname-prop -- Ignored via go/DSP-18766
71
81
  ,
72
- className: isTableResizingEnabled(rendererAppearance) ? 'fixed-table-div-custom-table-resizing' : '',
82
+ className: isTableResizingEnabled(rendererAppearance) ? 'fixed-table-div-custom-table-resizing' : ''
83
+ // eslint-disable-next-line @atlaskit/design-system/consistent-css-prop-usage -- Ignored via go/DSP-18766
84
+ ,
73
85
  css: fixedTableCss
74
86
  }), props.children);
75
87
  };
@@ -94,60 +106,63 @@ export const StickyTable = ({
94
106
  /* eslint-disable @atlaskit/design-system/ensure-design-token-usage */
95
107
  if (isTableResizingEnabled(rendererAppearance)) {
96
108
  styles = css({
97
- // eslint-disable-next-line @atlaskit/design-system/ensure-design-token-usage/preview
109
+ // eslint-disable-next-line @atlaskit/design-system/ensure-design-token-usage/preview, @atlaskit/ui-styling-standard/no-unsafe-values -- Ignored via go/DSP-18766
98
110
  top: mode === 'pin-bottom' ? top : undefined,
99
111
  position: 'absolute'
100
112
  });
101
113
  } else {
102
114
  styles = css({
103
- // eslint-disable-next-line @atlaskit/design-system/ensure-design-token-usage/preview
115
+ // eslint-disable-next-line @atlaskit/design-system/ensure-design-token-usage/preview, @atlaskit/ui-styling-standard/no-unsafe-values -- Ignored via go/DSP-18766
104
116
  left: left && left < 0 ? left : undefined,
105
- // eslint-disable-next-line @atlaskit/design-system/ensure-design-token-usage/preview
117
+ // eslint-disable-next-line @atlaskit/design-system/ensure-design-token-usage/preview, @atlaskit/ui-styling-standard/no-unsafe-values -- Ignored via go/DSP-18766
106
118
  top: mode === 'pin-bottom' ? top : undefined,
107
119
  position: 'relative'
108
120
  });
109
121
  }
110
122
  /* eslint-enable @atlaskit/design-system/ensure-design-token-usage */
111
- return jsx("div", {
112
- css: styles
113
- }, jsx(FixedTableDiv, {
114
- top: mode === 'stick' ? top : undefined,
115
- mode: rowHeight > 300 ? 'none' : mode,
116
- wrapperWidth: wrapperWidth,
117
- rendererAppearance: rendererAppearance
118
- }, jsx("div", {
119
- // eslint-disable-next-line @atlaskit/ui-styling-standard/no-classname-prop -- Ignored via go/DSP-18766
120
- className: `${TableSharedCssClassName.TABLE_CONTAINER} is-sticky ${shadowClassNames || ''}`,
121
- "data-layout": layout,
122
- style: {
123
- width: tableWidth
124
- }
125
- }, jsx("div", {
126
- ref: innerRef
127
- // eslint-disable-next-line @atlaskit/ui-styling-standard/no-classname-prop -- Ignored via go/DSP-18766
128
- ,
129
- className: `${TableSharedCssClassName.TABLE_STICKY_WRAPPER}`,
130
- style: {
131
- // eslint-disable-next-line @atlaskit/ui-styling-standard/enforce-style-prop -- Ignored via go/DSP-18766
132
- overflow: 'hidden'
133
- }
134
- }, jsx(Table, {
135
- columnWidths: columnWidths,
136
- layout: layout,
137
- isNumberColumnEnabled: isNumberColumnEnabled,
138
- renderWidth: renderWidth,
139
- tableNode: tableNode,
140
- rendererAppearance: rendererAppearance
141
- },
142
- /**
143
- * @see https://product-fabric.atlassian.net/browse/ED-10235
144
- * We pass prop 'invisible' to our table's children nodes meaning
145
- * they exist inside of the 'invisible' duplicated table component that
146
- * enables sticky headers.
147
- */
148
- recursivelyInjectProps(children, {
149
- invisible: true
150
- }))))));
123
+ return (
124
+ // eslint-disable-next-line @atlaskit/design-system/consistent-css-prop-usage -- Ignored via go/DSP-18766
125
+ jsx("div", {
126
+ css: styles
127
+ }, jsx(FixedTableDiv, {
128
+ top: mode === 'stick' ? top : undefined,
129
+ mode: rowHeight > 300 ? 'none' : mode,
130
+ wrapperWidth: wrapperWidth,
131
+ rendererAppearance: rendererAppearance
132
+ }, jsx("div", {
133
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-classname-prop -- Ignored via go/DSP-18766
134
+ className: `${TableSharedCssClassName.TABLE_CONTAINER} is-sticky ${shadowClassNames || ''}`,
135
+ "data-layout": layout,
136
+ style: {
137
+ width: tableWidth
138
+ }
139
+ }, jsx("div", {
140
+ ref: innerRef
141
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-classname-prop -- Ignored via go/DSP-18766
142
+ ,
143
+ className: `${TableSharedCssClassName.TABLE_STICKY_WRAPPER}`,
144
+ style: {
145
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/enforce-style-prop -- Ignored via go/DSP-18766
146
+ overflow: 'hidden'
147
+ }
148
+ }, jsx(Table, {
149
+ columnWidths: columnWidths,
150
+ layout: layout,
151
+ isNumberColumnEnabled: isNumberColumnEnabled,
152
+ renderWidth: renderWidth,
153
+ tableNode: tableNode,
154
+ rendererAppearance: rendererAppearance
155
+ },
156
+ /**
157
+ * @see https://product-fabric.atlassian.net/browse/ED-10235
158
+ * We pass prop 'invisible' to our table's children nodes meaning
159
+ * they exist inside of the 'invisible' duplicated table component that
160
+ * enables sticky headers.
161
+ */
162
+ recursivelyInjectProps(children, {
163
+ invisible: true
164
+ }))))))
165
+ );
151
166
  };
152
167
 
153
168
  /**
@@ -17,7 +17,9 @@ import { ActiveHeaderIdConsumer } from './active-header-id-provider';
17
17
  const titleStyles = css({
18
18
  outline: 'none',
19
19
  border: 'none',
20
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values, @atlaskit/ui-styling-standard/no-unsafe-values -- Ignored via go/DSP-18766
20
21
  fontSize: relativeFontSizeToBase16(fontSize()),
22
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values, @atlaskit/ui-styling-standard/no-unsafe-values -- Ignored via go/DSP-18766
21
23
  lineHeight: akEditorLineHeight,
22
24
  fontWeight: 'normal',
23
25
  display: 'flex',
@@ -13,6 +13,7 @@ const inlineExtensionStyle = css({
13
13
  verticalAlign: 'middle',
14
14
  // es-lint-disable-next-line @atlaskit/design-system/ensure-design-token-usage
15
15
  margin: `1px 1px ${"var(--ds-space-050, 4px)"}`,
16
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-nested-selectors -- Ignored via go/DSP-18766
16
17
  '& .rich-media-item': {
17
18
  maxWidth: '100%'
18
19
  }
@@ -37,7 +37,7 @@ import { nodeToReact } from '../../react/nodes';
37
37
  export const NORMAL_SEVERITY_THRESHOLD = 2000;
38
38
  export const DEGRADED_SEVERITY_THRESHOLD = 3000;
39
39
  const packageName = "@atlaskit/renderer";
40
- const packageVersion = "109.32.2";
40
+ const packageVersion = "109.32.4";
41
41
  export const defaultNodeComponents = nodeToReact;
42
42
  export class Renderer extends PureComponent {
43
43
  constructor(props) {
@@ -521,7 +521,7 @@ const RendererWrapper = /*#__PURE__*/React.memo(props => {
521
521
  ref: innerRef,
522
522
  onClick: onClick,
523
523
  onMouseDown: onMouseDown
524
- // eslint-disable-next-line @atlaskit/design-system/consistent-css-prop-usage
524
+ // eslint-disable-next-line @atlaskit/design-system/consistent-css-prop-usage, @atlaskit/ui-styling-standard/no-imported-style-values -- Ignored via go/DSP-18766
525
525
  ,
526
526
  css: rendererStyles({
527
527
  appearance,
@@ -4,10 +4,12 @@ import { Component } from 'react';
4
4
  const fadeOutStyles = (maxHeight, top, backgroundColor) => css({
5
5
  position: 'relative',
6
6
  overflowY: 'hidden',
7
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-values -- Ignored via go/DSP-18766
7
8
  maxHeight: `${maxHeight}px`,
8
9
  '&::after': {
9
10
  content: "''",
10
11
  position: 'absolute',
12
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-values -- Ignored via go/DSP-18766
11
13
  top: `${top}px`,
12
14
  bottom: 0,
13
15
  left: 0,
@@ -10,11 +10,15 @@ import { dataAttributes } from './dom';
10
10
  import { AnnotationSharedCSSByState } from '@atlaskit/editor-common/styles';
11
11
  import { segmentText } from '../../../react/utils/segment-text';
12
12
  import { renderTextSegments } from '../../../react/utils/render-text-segments';
13
+
14
+ // eslint-disable-next-line @atlaskit/design-system/consistent-css-prop-usage -- Ignored via go/DSP-18766
13
15
  const markStyles = () => css({
14
16
  color: 'inherit',
15
17
  backgroundColor: 'unset',
16
18
  WebkitTapHighlightColor: 'transparent'
17
- }, AnnotationSharedCSSByState().focus);
19
+ },
20
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values, @atlaskit/ui-styling-standard/no-unsafe-values -- Ignored via go/DSP-18766
21
+ AnnotationSharedCSSByState().focus);
18
22
  export const AnnotationDraft = ({
19
23
  draftPosition,
20
24
  children
@@ -3,6 +3,7 @@ import { AnnotationTypes } from '@atlaskit/adf-schema';
3
3
  import { updateWindowSelectionAroundDraft } from '../draft';
4
4
  import { FabricChannel } from '@atlaskit/analytics-listeners';
5
5
  import { ACTION, ACTION_SUBJECT, EVENT_TYPE, ACTION_SUBJECT_ID } from '@atlaskit/editor-common/analytics';
6
+ import { getRendererRangeInlineNodeNames } from '../../../actions/get-renderer-range-inline-node-names';
6
7
  import { RendererContext as ActionsContext } from '../../RendererActionsContext';
7
8
  import { ProvidersContext } from '../context';
8
9
  export const SelectionInlineCommentMounter = /*#__PURE__*/React.memo(props => {
@@ -46,7 +47,12 @@ export const SelectionInlineCommentMounter = /*#__PURE__*/React.memo(props => {
46
47
  action: ACTION.INSERTED,
47
48
  actionSubject: ACTION_SUBJECT.ANNOTATION,
48
49
  actionSubjectId: ACTION_SUBJECT_ID.INLINE_COMMENT,
49
- attributes: {},
50
+ attributes: {
51
+ inlineNodeNames: getRendererRangeInlineNodeNames({
52
+ pos: positionToAnnotate,
53
+ actions
54
+ })
55
+ },
50
56
  eventType: EVENT_TYPE.TRACK
51
57
  }).fire(FabricChannel.editor);
52
58
  }
@@ -69,7 +75,12 @@ export const SelectionInlineCommentMounter = /*#__PURE__*/React.memo(props => {
69
75
  action: ACTION.CREATE_NOT_ALLOWED,
70
76
  actionSubject: ACTION_SUBJECT.ANNOTATION,
71
77
  actionSubjectId: ACTION_SUBJECT_ID.INLINE_COMMENT,
72
- attributes: {},
78
+ attributes: {
79
+ inlineNodeNames: getRendererRangeInlineNodeNames({
80
+ pos: documentPosition,
81
+ actions
82
+ })
83
+ },
73
84
  eventType: EVENT_TYPE.TRACK
74
85
  }).fire(FabricChannel.editor);
75
86
  }
@@ -85,7 +96,11 @@ export const SelectionInlineCommentMounter = /*#__PURE__*/React.memo(props => {
85
96
  actionSubjectId: ACTION_SUBJECT_ID.INLINE_COMMENT,
86
97
  eventType: EVENT_TYPE.TRACK,
87
98
  attributes: {
88
- overlap: uniqueAnnotationsInRange.length
99
+ overlap: uniqueAnnotationsInRange.length,
100
+ inlineNodeNames: getRendererRangeInlineNodeNames({
101
+ pos: documentPosition,
102
+ actions
103
+ })
89
104
  }
90
105
  }).fire(FabricChannel.editor);
91
106
  }
@@ -124,12 +139,17 @@ export const SelectionInlineCommentMounter = /*#__PURE__*/React.memo(props => {
124
139
  actionSubject: ACTION_SUBJECT.ANNOTATION,
125
140
  actionSubjectId: ACTION_SUBJECT_ID.INLINE_COMMENT,
126
141
  eventType: EVENT_TYPE.TRACK,
127
- attributes: {}
142
+ attributes: {
143
+ inlineNodeNames: getRendererRangeInlineNodeNames({
144
+ pos: documentPosition,
145
+ actions
146
+ })
147
+ }
128
148
  }).fire(FabricChannel.editor);
129
149
  }
130
150
  removeDraftModeCallback();
131
151
  onCloseProps();
132
- }, [onCloseProps, removeDraftModeCallback, createAnalyticsEvent]);
152
+ }, [actions, documentPosition, onCloseProps, removeDraftModeCallback, createAnalyticsEvent]);
133
153
  return /*#__PURE__*/React.createElement(Component, {
134
154
  range: range,
135
155
  draftRange: draftRange,
@@ -0,0 +1,18 @@
1
+ import { getRangeInlineNodeNames } from '@atlaskit/editor-common/utils';
2
+ import { getBooleanFF } from '@atlaskit/platform-feature-flags';
3
+ export function getRendererRangeInlineNodeNames(_ref) {
4
+ var actions = _ref.actions,
5
+ pos = _ref.pos;
6
+ if (!getBooleanFF('platform.editor.allow-inline-comments-for-inline-nodes-round-2_ctuxz')) {
7
+ return undefined;
8
+ }
9
+ var doc = actions.doc;
10
+ if (!pos || !doc) {
11
+ return undefined;
12
+ }
13
+ var inlineNodeNames = getRangeInlineNodeNames({
14
+ doc: doc,
15
+ pos: pos
16
+ });
17
+ return inlineNodeNames;
18
+ }
@@ -11,6 +11,7 @@ import { AddNodeMarkStep, RemoveMarkStep, RemoveNodeMarkStep } from '@atlaskit/e
11
11
  import { createAnnotationStep, getPosFromRange } from '../steps';
12
12
  import { ACTION, ACTION_SUBJECT, EVENT_TYPE, ACTION_SUBJECT_ID } from '@atlaskit/editor-common/analytics';
13
13
  import { getIndexMatch } from './matches-utils';
14
+ import { getRendererRangeInlineNodeNames } from './get-renderer-range-inline-node-names';
14
15
  var RendererActions = /*#__PURE__*/function () {
15
16
  // Any kind of refence is allowed
16
17
 
@@ -109,7 +110,16 @@ var RendererActions = /*#__PURE__*/function () {
109
110
  action: ACTION.DELETED,
110
111
  actionSubject: ACTION_SUBJECT.ANNOTATION,
111
112
  actionSubjectId: ACTION_SUBJECT_ID.INLINE_COMMENT,
112
- eventType: EVENT_TYPE.TRACK
113
+ eventType: EVENT_TYPE.TRACK,
114
+ attributes: {
115
+ inlineNodeNames: step instanceof RemoveMarkStep ? getRendererRangeInlineNodeNames({
116
+ pos: {
117
+ from: from,
118
+ to: to
119
+ },
120
+ actions: this
121
+ }) : undefined
122
+ }
113
123
  };
114
124
  this.onAnalyticsEvent(payload);
115
125
  }
@@ -162,6 +172,10 @@ var RendererActions = /*#__PURE__*/function () {
162
172
  }
163
173
  return this._privateValidatePositionsForAnnotation(pos.from, pos.to);
164
174
  }
175
+
176
+ /**
177
+ * Note: False indicates that the selection not able to be calculated.
178
+ */
165
179
  }, {
166
180
  key: "getPositionFromRange",
167
181
  value: function getPositionFromRange(range, isCommentsOnMediaBugFixEnabled, isCommentsOnMediaBugVideoComment) {
@@ -259,6 +273,13 @@ var RendererActions = /*#__PURE__*/function () {
259
273
  return _objectSpread({
260
274
  step: step,
261
275
  doc: this.transformer.encode(doc),
276
+ inlineNodeTypes: getRendererRangeInlineNodeNames({
277
+ actions: this,
278
+ pos: {
279
+ from: from,
280
+ to: to
281
+ }
282
+ }),
262
283
  originalSelection: originalSelection,
263
284
  numMatches: numMatches,
264
285
  matchIndex: matchIndex,