@atlaskit/editor-common 82.2.2 → 82.4.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (272) hide show
  1. package/CHANGELOG.md +31 -0
  2. package/dist/cjs/collab/index.js +1 -1
  3. package/dist/cjs/element-browser/ViewMore.js +1 -0
  4. package/dist/cjs/element-browser/components/CategoryList.js +2 -0
  5. package/dist/cjs/element-browser/components/ElementList/ElementList.js +19 -1
  6. package/dist/cjs/element-browser/components/ElementSearch.js +56 -42
  7. package/dist/cjs/element-browser/components/StatelessElementBrowser.js +18 -0
  8. package/dist/cjs/extensibility/Extension/Extension/index.js +6 -3
  9. package/dist/cjs/extensibility/Extension/Extension/styles.js +24 -9
  10. package/dist/cjs/extensibility/Extension/InlineExtension/index.js +3 -2
  11. package/dist/cjs/extensibility/Extension/InlineExtension/styles.js +9 -4
  12. package/dist/cjs/extensibility/Extension/Lozenge/ExtensionLabel.js +11 -6
  13. package/dist/cjs/extensibility/Extension/Lozenge/LozengeComponent.js +20 -15
  14. package/dist/cjs/extensibility/Extension/Lozenge/index.js +1 -0
  15. package/dist/cjs/extensibility/Extension/styles.js +13 -0
  16. package/dist/cjs/extensibility/ExtensionNodeWrapper.js +2 -0
  17. package/dist/cjs/extensibility/MultiBodiedExtension/index.js +20 -4
  18. package/dist/cjs/extensibility/MultiBodiedExtension/styles.js +14 -2
  19. package/dist/cjs/keymaps/index.js +2 -1
  20. package/dist/cjs/link/LinkPicker/HyperlinkAddToolbar/HyperlinkAddToolbar.js +2 -0
  21. package/dist/cjs/link/LinkSearch/LinkSearchList.js +2 -0
  22. package/dist/cjs/link/LinkSearch/LinkSearchListItem.js +9 -0
  23. package/dist/cjs/link/LinkSearch/ToolbarComponents.js +7 -0
  24. package/dist/cjs/media-inline/inline-image-wrapper.js +9 -1
  25. package/dist/cjs/media-inline/styles.js +12 -1
  26. package/dist/cjs/media-inline/views/frame.js +7 -4
  27. package/dist/cjs/media-inline/views/icon-wrapper.js +1 -0
  28. package/dist/cjs/media-inline/views/wrapper.js +1 -0
  29. package/dist/cjs/media-single/CommentBadge.js +5 -1
  30. package/dist/cjs/messages/help-dialog.js +5 -0
  31. package/dist/cjs/monitoring/error.js +1 -1
  32. package/dist/cjs/rank.js +1 -1
  33. package/dist/cjs/selection/gap-cursor/styles.js +1 -1
  34. package/dist/cjs/styles/shared/annotation.js +6 -0
  35. package/dist/cjs/styles/shared/background-color.js +4 -0
  36. package/dist/cjs/styles/shared/block-marks.js +1 -0
  37. package/dist/cjs/styles/shared/blockquote.js +8 -1
  38. package/dist/cjs/styles/shared/code-block.js +2 -0
  39. package/dist/cjs/styles/shared/code-mark.js +1 -0
  40. package/dist/cjs/styles/shared/column-layout.js +6 -1
  41. package/dist/cjs/styles/shared/date.js +2 -0
  42. package/dist/cjs/styles/shared/embedCard.js +8 -0
  43. package/dist/cjs/styles/shared/expand.js +1 -0
  44. package/dist/cjs/styles/shared/grid.js +7 -0
  45. package/dist/cjs/styles/shared/headings.js +6 -0
  46. package/dist/cjs/styles/shared/indentation.js +8 -0
  47. package/dist/cjs/styles/shared/link.js +4 -1
  48. package/dist/cjs/styles/shared/lists.js +1 -1
  49. package/dist/cjs/styles/shared/media-single.js +8 -1
  50. package/dist/cjs/styles/shared/paragraph.js +4 -1
  51. package/dist/cjs/styles/shared/plugins.js +8 -0
  52. package/dist/cjs/styles/shared/resizer.js +1 -1
  53. package/dist/cjs/styles/shared/rule.js +2 -1
  54. package/dist/cjs/styles/shared/shadow.js +4 -1
  55. package/dist/cjs/styles/shared/smartCard.js +1 -1
  56. package/dist/cjs/styles/shared/tableCell.js +1 -0
  57. package/dist/cjs/styles/shared/task-decision.js +2 -0
  58. package/dist/cjs/styles/shared/text-color.js +3 -0
  59. package/dist/cjs/styles/shared/unsupported-content.js +1 -1
  60. package/dist/cjs/styles/shared/whitespace.js +3 -1
  61. package/dist/cjs/table/SortingIcon.js +2 -2
  62. package/dist/cjs/ui/DropList/index.js +5 -1
  63. package/dist/cjs/ui/Expand/index.js +13 -0
  64. package/dist/cjs/ui/MediaSingle/index.js +3 -1
  65. package/dist/cjs/ui/MediaSingle/link.js +1 -0
  66. package/dist/cjs/ui/MediaSingle/styled.js +6 -3
  67. package/dist/cjs/ui/Messages/index.js +12 -7
  68. package/dist/cjs/ui/MultiBodiedExtension/index.js +24 -0
  69. package/dist/cjs/ui/PanelTextInput/index.js +1 -0
  70. package/dist/cjs/ui/PanelTextInput/styles.js +6 -0
  71. package/dist/cjs/ui/Popup/index.js +1 -0
  72. package/dist/cjs/ui/UnsupportedBlock/index.js +2 -0
  73. package/dist/cjs/ui/UnsupportedInline/index.js +2 -0
  74. package/dist/cjs/ui/clear-next-sibling-margin-top.js +6 -2
  75. package/dist/cjs/ui-color/ColorPalette/Color/index.js +60 -8
  76. package/dist/cjs/ui-color/ColorPalette/Color/styles.js +3 -0
  77. package/dist/cjs/ui-color/ColorPalette/Palettes/highlightColorPalette.js +38 -2
  78. package/dist/cjs/ui-color/ColorPalette/Palettes/paletteMessages.js +1 -1
  79. package/dist/cjs/ui-color/ColorPalette/index.js +5 -2
  80. package/dist/cjs/ui-color/ColorPalette/styles.js +1 -0
  81. package/dist/cjs/ui-menu/ColorPickerButton/index.js +7 -0
  82. package/dist/cjs/ui-menu/DropdownMenu/index.js +1 -0
  83. package/dist/cjs/utils/annotation/index.js +24 -0
  84. package/dist/cjs/utils/index.js +6 -0
  85. package/dist/es2019/collab/index.js +1 -1
  86. package/dist/es2019/element-browser/ViewMore.js +1 -0
  87. package/dist/es2019/element-browser/components/CategoryList.js +3 -0
  88. package/dist/es2019/element-browser/components/ElementList/ElementList.js +19 -1
  89. package/dist/es2019/element-browser/components/ElementSearch.js +56 -42
  90. package/dist/es2019/element-browser/components/StatelessElementBrowser.js +18 -0
  91. package/dist/es2019/extensibility/Extension/Extension/index.js +6 -3
  92. package/dist/es2019/extensibility/Extension/Extension/styles.js +24 -9
  93. package/dist/es2019/extensibility/Extension/InlineExtension/index.js +3 -2
  94. package/dist/es2019/extensibility/Extension/InlineExtension/styles.js +10 -4
  95. package/dist/es2019/extensibility/Extension/Lozenge/ExtensionLabel.js +11 -6
  96. package/dist/es2019/extensibility/Extension/Lozenge/LozengeComponent.js +19 -14
  97. package/dist/es2019/extensibility/Extension/Lozenge/index.js +1 -0
  98. package/dist/es2019/extensibility/Extension/styles.js +14 -0
  99. package/dist/es2019/extensibility/ExtensionNodeWrapper.js +2 -0
  100. package/dist/es2019/extensibility/MultiBodiedExtension/index.js +21 -5
  101. package/dist/es2019/extensibility/MultiBodiedExtension/styles.js +14 -2
  102. package/dist/es2019/keymaps/index.js +1 -0
  103. package/dist/es2019/link/LinkPicker/HyperlinkAddToolbar/HyperlinkAddToolbar.js +2 -0
  104. package/dist/es2019/link/LinkSearch/LinkSearchList.js +2 -0
  105. package/dist/es2019/link/LinkSearch/LinkSearchListItem.js +9 -0
  106. package/dist/es2019/link/LinkSearch/ToolbarComponents.js +8 -0
  107. package/dist/es2019/media-inline/inline-image-wrapper.js +9 -1
  108. package/dist/es2019/media-inline/styles.js +12 -1
  109. package/dist/es2019/media-inline/views/frame.js +3 -1
  110. package/dist/es2019/media-inline/views/icon-wrapper.js +1 -0
  111. package/dist/es2019/media-inline/views/wrapper.js +1 -0
  112. package/dist/es2019/media-single/CommentBadge.js +5 -1
  113. package/dist/es2019/messages/help-dialog.js +5 -0
  114. package/dist/es2019/monitoring/error.js +1 -1
  115. package/dist/es2019/rank.js +1 -1
  116. package/dist/es2019/selection/gap-cursor/styles.js +1 -1
  117. package/dist/es2019/styles/shared/annotation.js +6 -0
  118. package/dist/es2019/styles/shared/background-color.js +5 -0
  119. package/dist/es2019/styles/shared/block-marks.js +2 -0
  120. package/dist/es2019/styles/shared/blockquote.js +8 -1
  121. package/dist/es2019/styles/shared/code-block.js +2 -0
  122. package/dist/es2019/styles/shared/code-mark.js +2 -0
  123. package/dist/es2019/styles/shared/column-layout.js +6 -0
  124. package/dist/es2019/styles/shared/date.js +3 -0
  125. package/dist/es2019/styles/shared/embedCard.js +8 -0
  126. package/dist/es2019/styles/shared/expand.js +1 -0
  127. package/dist/es2019/styles/shared/grid.js +7 -0
  128. package/dist/es2019/styles/shared/headings.js +12 -0
  129. package/dist/es2019/styles/shared/indentation.js +9 -0
  130. package/dist/es2019/styles/shared/link.js +3 -0
  131. package/dist/es2019/styles/shared/lists.js +1 -1
  132. package/dist/es2019/styles/shared/media-single.js +15 -0
  133. package/dist/es2019/styles/shared/panel.js +1 -0
  134. package/dist/es2019/styles/shared/paragraph.js +4 -1
  135. package/dist/es2019/styles/shared/plugins.js +8 -0
  136. package/dist/es2019/styles/shared/resizer.js +1 -1
  137. package/dist/es2019/styles/shared/rule.js +2 -1
  138. package/dist/es2019/styles/shared/shadow.js +9 -0
  139. package/dist/es2019/styles/shared/smartCard.js +1 -1
  140. package/dist/es2019/styles/shared/tableCell.js +1 -0
  141. package/dist/es2019/styles/shared/task-decision.js +2 -0
  142. package/dist/es2019/styles/shared/text-color.js +4 -0
  143. package/dist/es2019/styles/shared/unsupported-content.js +1 -1
  144. package/dist/es2019/styles/shared/whitespace.js +2 -0
  145. package/dist/es2019/table/SortingIcon.js +2 -2
  146. package/dist/es2019/ui/DropList/index.js +5 -1
  147. package/dist/es2019/ui/Expand/index.js +13 -0
  148. package/dist/es2019/ui/MediaSingle/index.js +3 -1
  149. package/dist/es2019/ui/MediaSingle/link.js +2 -0
  150. package/dist/es2019/ui/MediaSingle/styled.js +3 -1
  151. package/dist/es2019/ui/Messages/index.js +5 -1
  152. package/dist/es2019/ui/MultiBodiedExtension/index.js +24 -0
  153. package/dist/es2019/ui/PanelTextInput/index.js +1 -0
  154. package/dist/es2019/ui/PanelTextInput/styles.js +6 -0
  155. package/dist/es2019/ui/Popup/index.js +1 -0
  156. package/dist/es2019/ui/UnsupportedBlock/index.js +2 -0
  157. package/dist/es2019/ui/UnsupportedInline/index.js +2 -0
  158. package/dist/es2019/ui/clear-next-sibling-margin-top.js +7 -2
  159. package/dist/es2019/ui-color/ColorPalette/Color/index.js +64 -2
  160. package/dist/es2019/ui-color/ColorPalette/Color/styles.js +3 -0
  161. package/dist/es2019/ui-color/ColorPalette/Palettes/highlightColorPalette.js +36 -1
  162. package/dist/es2019/ui-color/ColorPalette/Palettes/paletteMessages.js +1 -1
  163. package/dist/es2019/ui-color/ColorPalette/index.js +5 -2
  164. package/dist/es2019/ui-color/ColorPalette/styles.js +1 -0
  165. package/dist/es2019/ui-menu/ColorPickerButton/index.js +7 -0
  166. package/dist/es2019/ui-menu/DropdownMenu/index.js +1 -0
  167. package/dist/es2019/utils/annotation/index.js +22 -0
  168. package/dist/es2019/utils/index.js +1 -1
  169. package/dist/esm/collab/index.js +1 -1
  170. package/dist/esm/element-browser/ViewMore.js +1 -0
  171. package/dist/esm/element-browser/components/CategoryList.js +2 -0
  172. package/dist/esm/element-browser/components/ElementList/ElementList.js +19 -1
  173. package/dist/esm/element-browser/components/ElementSearch.js +56 -42
  174. package/dist/esm/element-browser/components/StatelessElementBrowser.js +18 -0
  175. package/dist/esm/extensibility/Extension/Extension/index.js +6 -3
  176. package/dist/esm/extensibility/Extension/Extension/styles.js +24 -9
  177. package/dist/esm/extensibility/Extension/InlineExtension/index.js +3 -2
  178. package/dist/esm/extensibility/Extension/InlineExtension/styles.js +10 -4
  179. package/dist/esm/extensibility/Extension/Lozenge/ExtensionLabel.js +11 -6
  180. package/dist/esm/extensibility/Extension/Lozenge/LozengeComponent.js +20 -15
  181. package/dist/esm/extensibility/Extension/Lozenge/index.js +1 -0
  182. package/dist/esm/extensibility/Extension/styles.js +14 -0
  183. package/dist/esm/extensibility/ExtensionNodeWrapper.js +2 -0
  184. package/dist/esm/extensibility/MultiBodiedExtension/index.js +20 -4
  185. package/dist/esm/extensibility/MultiBodiedExtension/styles.js +14 -2
  186. package/dist/esm/keymaps/index.js +1 -0
  187. package/dist/esm/link/LinkPicker/HyperlinkAddToolbar/HyperlinkAddToolbar.js +2 -0
  188. package/dist/esm/link/LinkSearch/LinkSearchList.js +2 -0
  189. package/dist/esm/link/LinkSearch/LinkSearchListItem.js +9 -0
  190. package/dist/esm/link/LinkSearch/ToolbarComponents.js +8 -0
  191. package/dist/esm/media-inline/inline-image-wrapper.js +9 -1
  192. package/dist/esm/media-inline/styles.js +12 -1
  193. package/dist/esm/media-inline/views/frame.js +7 -4
  194. package/dist/esm/media-inline/views/icon-wrapper.js +1 -0
  195. package/dist/esm/media-inline/views/wrapper.js +1 -0
  196. package/dist/esm/media-single/CommentBadge.js +5 -1
  197. package/dist/esm/messages/help-dialog.js +5 -0
  198. package/dist/esm/monitoring/error.js +1 -1
  199. package/dist/esm/rank.js +1 -1
  200. package/dist/esm/selection/gap-cursor/styles.js +1 -1
  201. package/dist/esm/styles/shared/annotation.js +6 -0
  202. package/dist/esm/styles/shared/background-color.js +5 -0
  203. package/dist/esm/styles/shared/block-marks.js +2 -0
  204. package/dist/esm/styles/shared/blockquote.js +8 -1
  205. package/dist/esm/styles/shared/code-block.js +2 -0
  206. package/dist/esm/styles/shared/code-mark.js +1 -0
  207. package/dist/esm/styles/shared/column-layout.js +5 -0
  208. package/dist/esm/styles/shared/date.js +2 -0
  209. package/dist/esm/styles/shared/embedCard.js +8 -0
  210. package/dist/esm/styles/shared/expand.js +1 -0
  211. package/dist/esm/styles/shared/grid.js +7 -0
  212. package/dist/esm/styles/shared/headings.js +6 -0
  213. package/dist/esm/styles/shared/indentation.js +9 -0
  214. package/dist/esm/styles/shared/link.js +3 -0
  215. package/dist/esm/styles/shared/lists.js +1 -1
  216. package/dist/esm/styles/shared/media-single.js +7 -0
  217. package/dist/esm/styles/shared/paragraph.js +4 -1
  218. package/dist/esm/styles/shared/plugins.js +8 -0
  219. package/dist/esm/styles/shared/resizer.js +1 -1
  220. package/dist/esm/styles/shared/rule.js +2 -1
  221. package/dist/esm/styles/shared/shadow.js +3 -0
  222. package/dist/esm/styles/shared/smartCard.js +1 -1
  223. package/dist/esm/styles/shared/tableCell.js +1 -0
  224. package/dist/esm/styles/shared/task-decision.js +2 -0
  225. package/dist/esm/styles/shared/text-color.js +4 -0
  226. package/dist/esm/styles/shared/unsupported-content.js +1 -1
  227. package/dist/esm/styles/shared/whitespace.js +2 -0
  228. package/dist/esm/table/SortingIcon.js +2 -2
  229. package/dist/esm/ui/DropList/index.js +5 -1
  230. package/dist/esm/ui/Expand/index.js +13 -0
  231. package/dist/esm/ui/MediaSingle/index.js +3 -1
  232. package/dist/esm/ui/MediaSingle/link.js +2 -0
  233. package/dist/esm/ui/MediaSingle/styled.js +6 -3
  234. package/dist/esm/ui/Messages/index.js +12 -7
  235. package/dist/esm/ui/MultiBodiedExtension/index.js +24 -0
  236. package/dist/esm/ui/PanelTextInput/index.js +1 -0
  237. package/dist/esm/ui/PanelTextInput/styles.js +6 -0
  238. package/dist/esm/ui/Popup/index.js +1 -0
  239. package/dist/esm/ui/UnsupportedBlock/index.js +2 -0
  240. package/dist/esm/ui/UnsupportedInline/index.js +2 -0
  241. package/dist/esm/ui/clear-next-sibling-margin-top.js +6 -2
  242. package/dist/esm/ui-color/ColorPalette/Color/index.js +60 -8
  243. package/dist/esm/ui-color/ColorPalette/Color/styles.js +3 -0
  244. package/dist/esm/ui-color/ColorPalette/Palettes/highlightColorPalette.js +37 -1
  245. package/dist/esm/ui-color/ColorPalette/Palettes/paletteMessages.js +1 -1
  246. package/dist/esm/ui-color/ColorPalette/index.js +5 -2
  247. package/dist/esm/ui-color/ColorPalette/styles.js +1 -0
  248. package/dist/esm/ui-menu/ColorPickerButton/index.js +7 -0
  249. package/dist/esm/ui-menu/DropdownMenu/index.js +1 -0
  250. package/dist/esm/utils/annotation/index.js +22 -0
  251. package/dist/esm/utils/index.js +1 -1
  252. package/dist/types/analytics/types/highlight-events.d.ts +4 -2
  253. package/dist/types/analytics/types/inline-comment-events.d.ts +1 -0
  254. package/dist/types/keymaps/index.d.ts +1 -0
  255. package/dist/types/messages/help-dialog.d.ts +5 -0
  256. package/dist/types/types/feature-flags.d.ts +8 -0
  257. package/dist/types/ui-color/ColorPalette/Color/index.d.ts +5 -2
  258. package/dist/types/ui-color/ColorPalette/Palettes/highlightColorPalette.d.ts +3 -0
  259. package/dist/types/ui-color/ColorPalette/Palettes/type.d.ts +2 -0
  260. package/dist/types/utils/annotation/index.d.ts +10 -0
  261. package/dist/types/utils/index.d.ts +1 -1
  262. package/dist/types-ts4.5/analytics/types/highlight-events.d.ts +4 -2
  263. package/dist/types-ts4.5/analytics/types/inline-comment-events.d.ts +1 -0
  264. package/dist/types-ts4.5/keymaps/index.d.ts +1 -0
  265. package/dist/types-ts4.5/messages/help-dialog.d.ts +5 -0
  266. package/dist/types-ts4.5/types/feature-flags.d.ts +8 -0
  267. package/dist/types-ts4.5/ui-color/ColorPalette/Color/index.d.ts +5 -2
  268. package/dist/types-ts4.5/ui-color/ColorPalette/Palettes/highlightColorPalette.d.ts +3 -0
  269. package/dist/types-ts4.5/ui-color/ColorPalette/Palettes/type.d.ts +2 -0
  270. package/dist/types-ts4.5/utils/annotation/index.d.ts +10 -0
  271. package/dist/types-ts4.5/utils/index.d.ts +1 -1
  272. package/package.json +5 -2
@@ -119,6 +119,7 @@ var PanelTextInput = /*#__PURE__*/function (_PureComponent) {
119
119
  inputId = _this$props2.inputId;
120
120
  var value = this.state.value;
121
121
  return jsx("input", {
122
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values, @atlaskit/design-system/consistent-css-prop-usage -- Ignored via go/DSP-18766
122
123
  css: [panelTextInput, width !== undefined && panelTextInputWithCustomWidth(width)],
123
124
  role: role,
124
125
  "aria-autocomplete": ariaAutoComplete ? 'list' : undefined,
@@ -2,7 +2,9 @@ import { css } from '@emotion/react';
2
2
  import { relativeFontSizeToBase16 } from '@atlaskit/editor-shared-styles';
3
3
  import { B100, N100, N30, N400 } from '@atlaskit/theme/colors';
4
4
  // Normal .className gets overridden by input[type=text] hence this hack to produce input.className
5
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-exported-styles, @atlaskit/design-system/no-exported-css -- Ignored via go/DSP-18766
5
6
  export var panelTextInput = css({
7
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-nested-selectors, @atlaskit/ui-styling-standard/no-unsafe-selectors -- Ignored via go/DSP-18766
6
8
  'input&': {
7
9
  background: 'transparent',
8
10
  border: "2px solid ".concat("var(--ds-border, ".concat(N30, ")")),
@@ -10,11 +12,13 @@ export var panelTextInput = css({
10
12
  boxSizing: 'content-box',
11
13
  color: "var(--ds-text-subtle, ".concat(N400, ")"),
12
14
  flexGrow: 1,
15
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values, @atlaskit/ui-styling-standard/no-unsafe-values -- Ignored via go/DSP-18766
13
16
  fontSize: relativeFontSizeToBase16(13),
14
17
  lineHeight: '20px',
15
18
  padding: "var(--ds-space-075, 6px)".concat(" ", "var(--ds-space-400, 32px)", " ", "var(--ds-space-075, 6px)", " ", "var(--ds-space-100, 8px)"),
16
19
  minWidth: '145px',
17
20
  /* Hides IE10+ built-in [x] clear input button */
21
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-selectors -- Ignored via go/DSP-18766
18
22
  '&::-ms-clear': {
19
23
  display: 'none'
20
24
  },
@@ -29,7 +33,9 @@ export var panelTextInput = css({
29
33
  });
30
34
  export var panelTextInputWithCustomWidth = function panelTextInputWithCustomWidth(width) {
31
35
  return css({
36
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-nested-selectors, @atlaskit/ui-styling-standard/no-unsafe-selectors -- Ignored via go/DSP-18766
32
37
  'input&': {
38
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-values -- Ignored via go/DSP-18766
33
39
  width: "".concat(width, "px")
34
40
  }
35
41
  });
@@ -287,6 +287,7 @@ var Popup = /*#__PURE__*/function (_React$Component) {
287
287
  style: _objectSpread(_objectSpread({
288
288
  // eslint-disable-next-line @atlaskit/ui-styling-standard/enforce-style-prop -- Ignored via go/DSP-18766
289
289
  position: 'absolute',
290
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values -- Ignored via go/DSP-18766
290
291
  zIndex: this.props.zIndex || akEditorFloatingPanelZIndex
291
292
  }, position), this.props.style),
292
293
  "aria-label": ariaLabel,
@@ -14,10 +14,12 @@ import { getUnsupportedContent } from '../unsupported-content-helper';
14
14
  var blockNodeStyle = css({
15
15
  background: "var(--ds-background-disabled, ".concat(N30, ")"),
16
16
  border: "1px dashed ".concat("var(--ds-border-disabled, ".concat(N50, ")")),
17
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values, @atlaskit/ui-styling-standard/no-unsafe-values -- Ignored via go/DSP-18766
17
18
  borderRadius: "".concat(borderRadius(), "px"),
18
19
  boxSizing: 'border-box',
19
20
  cursor: 'default',
20
21
  display: 'flex',
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
  fontSize: relativeFontSizeToBase16(fontSize()),
22
24
  margin: "var(--ds-space-100, 8px)".concat(" 0"),
23
25
  minHeight: '24px',
@@ -15,10 +15,12 @@ var inlineNodeStyle = css({
15
15
  alignItems: 'center',
16
16
  background: "var(--ds-background-disabled, ".concat(N30, ")"),
17
17
  border: "1px dashed ".concat("var(--ds-border-disabled, ".concat(N50, ")")),
18
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values, @atlaskit/ui-styling-standard/no-unsafe-values -- Ignored via go/DSP-18766
18
19
  borderRadius: "".concat(borderRadius(), "px"),
19
20
  boxSizing: 'border-box',
20
21
  cursor: 'default',
21
22
  display: 'inline-flex',
23
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values, @atlaskit/ui-styling-standard/no-unsafe-values -- Ignored via go/DSP-18766
22
24
  fontSize: relativeFontSizeToBase16(fontSize()),
23
25
  margin: "0 ".concat("var(--ds-space-025, 2px)"),
24
26
  minHeight: '24px',
@@ -3,9 +3,11 @@ import { css } from '@emotion/react';
3
3
 
4
4
  // We use !important to ensure next sibling gets the margin reset no matter what
5
5
 
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 var clearNextSiblingMarginTopStyle = css({
8
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-nested-selectors -- Ignored via go/DSP-18766
7
9
  '& + *': {
8
- // eslint-disable-next-line @atlaskit/design-system/ensure-design-token-usage/preview
10
+ // eslint-disable-next-line @atlaskit/design-system/ensure-design-token-usage/preview, @atlaskit/ui-styling-standard/no-important-styles -- Ignored via go/DSP-18766
9
11
  marginTop: '0 !important'
10
12
  }
11
13
  });
@@ -13,7 +15,9 @@ var textElements = ['p', 'h1', 'h2', 'h3', 'h4', 'h5', 'h6'];
13
15
  var nextSiblingBlockMarkContentSelectors = textElements.map(function (elem) {
14
16
  return "+ .fabric-editor-block-mark > ".concat(elem);
15
17
  }).join(',');
18
+
19
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-exported-styles, @atlaskit/design-system/no-exported-css -- Ignored via go/DSP-18766
16
20
  export var clearNextSiblingBlockMarkMarginTopStyle = css(_defineProperty({}, "".concat(nextSiblingBlockMarkContentSelectors), {
17
- // eslint-disable-next-line @atlaskit/design-system/ensure-design-token-usage/preview
21
+ // eslint-disable-next-line @atlaskit/design-system/ensure-design-token-usage/preview, @atlaskit/ui-styling-standard/no-important-styles -- Ignored via go/DSP-18766
18
22
  marginTop: '0 !important'
19
23
  }));
@@ -11,15 +11,64 @@ function _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.
11
11
  import React, { PureComponent } from 'react';
12
12
  import { jsx } from '@emotion/react';
13
13
  import EditorDoneIcon from '@atlaskit/icon/glyph/editor/done';
14
+ import { getBooleanFF } from '@atlaskit/platform-feature-flags';
14
15
  import { N0 } from '@atlaskit/theme/colors';
15
16
  import Tooltip from '@atlaskit/tooltip';
16
17
  import { buttonStyle, buttonWrapperStyle } from './styles';
17
- var Color = /*#__PURE__*/function (_PureComponent) {
18
- _inherits(Color, _PureComponent);
19
- var _super = _createSuper(Color);
20
- function Color() {
18
+ function FunctionalComponentColor(props) {
19
+ var autoFocus = props.autoFocus,
20
+ tabIndex = props.tabIndex,
21
+ value = props.value,
22
+ label = props.label,
23
+ isSelected = props.isSelected,
24
+ borderColor = props.borderColor,
25
+ _props$checkMarkColor = props.checkMarkColor,
26
+ checkMarkColor = _props$checkMarkColor === void 0 ? N0 : _props$checkMarkColor,
27
+ hexToPaletteColor = props.hexToPaletteColor,
28
+ decorator = props.decorator;
29
+ var colorStyle = hexToPaletteColor ? hexToPaletteColor(value) : value;
30
+ var onMouseDown = function onMouseDown(e) {
31
+ e.preventDefault();
32
+ };
33
+ var onClick = function onClick(e) {
34
+ var onClick = props.onClick,
35
+ value = props.value,
36
+ label = props.label;
37
+ e.preventDefault();
38
+ onClick(value, label);
39
+ };
40
+ return jsx(Tooltip, {
41
+ content: label
42
+ }, jsx("span", {
43
+ css: buttonWrapperStyle
44
+ }, jsx("button", {
45
+ type: "button",
46
+ css: buttonStyle,
47
+ "aria-label": label,
48
+ role: "radio",
49
+ "aria-checked": isSelected,
50
+ onClick: onClick,
51
+ onMouseDown: onMouseDown,
52
+ tabIndex: tabIndex
53
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-classname-prop -- Ignored via go/DSP-18766
54
+ ,
55
+ className: "".concat(isSelected ? 'selected' : ''),
56
+ style: {
57
+ backgroundColor: colorStyle || 'transparent',
58
+ border: "1px solid ".concat(borderColor)
59
+ },
60
+ autoFocus: autoFocus
61
+ }, !decorator && isSelected && jsx(EditorDoneIcon, {
62
+ primaryColor: checkMarkColor,
63
+ label: ""
64
+ }), decorator)));
65
+ }
66
+ var ClassComponentColor = /*#__PURE__*/function (_PureComponent) {
67
+ _inherits(ClassComponentColor, _PureComponent);
68
+ var _super = _createSuper(ClassComponentColor);
69
+ function ClassComponentColor() {
21
70
  var _this;
22
- _classCallCheck(this, Color);
71
+ _classCallCheck(this, ClassComponentColor);
23
72
  for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {
24
73
  args[_key] = arguments[_key];
25
74
  }
@@ -37,7 +86,7 @@ var Color = /*#__PURE__*/function (_PureComponent) {
37
86
  });
38
87
  return _this;
39
88
  }
40
- _createClass(Color, [{
89
+ _createClass(ClassComponentColor, [{
41
90
  key: "render",
42
91
  value: function render() {
43
92
  var _this$props2 = this.props,
@@ -56,7 +105,9 @@ var Color = /*#__PURE__*/function (_PureComponent) {
56
105
  }, jsx("span", {
57
106
  css: buttonWrapperStyle
58
107
  }, jsx("button", {
59
- type: "button",
108
+ type: "button"
109
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values, @atlaskit/design-system/consistent-css-prop-usage -- Ignored via go/DSP-18766
110
+ ,
60
111
  css: buttonStyle,
61
112
  "aria-label": label,
62
113
  role: "radio",
@@ -78,6 +129,7 @@ var Color = /*#__PURE__*/function (_PureComponent) {
78
129
  }))));
79
130
  }
80
131
  }]);
81
- return Color;
132
+ return ClassComponentColor;
82
133
  }(PureComponent);
134
+ var Color = getBooleanFF('platform.editor.transparent-diagonal-decorator') ? FunctionalComponentColor : ClassComponentColor;
83
135
  export default Color;
@@ -2,6 +2,7 @@ import { css } from '@emotion/react';
2
2
  import { N0, N50, N900 } from '@atlaskit/theme/colors';
3
3
  /** this is not new usage - old code extracted from editor-core */
4
4
  /* eslint-disable @atlaskit/design-system/ensure-design-token-usage */
5
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-exported-styles, @atlaskit/design-system/no-exported-css -- Ignored via go/DSP-18766
5
6
  export var buttonStyle = css({
6
7
  height: '26px',
7
8
  width: '26px',
@@ -16,6 +17,7 @@ export var buttonStyle = css({
16
17
 
17
18
  /** this is not new usage - old code extracted from editor-core */
18
19
  /* eslint-disable @atlaskit/design-system/ensure-design-token-usage */
20
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-exported-styles, @atlaskit/design-system/no-exported-css -- Ignored via go/DSP-18766
19
21
  export var buttonWrapperStyle = css({
20
22
  border: '1px solid transparent',
21
23
  fontSize: 0,
@@ -24,6 +26,7 @@ export var buttonWrapperStyle = css({
24
26
  padding: "var(--ds-space-025, 2px)",
25
27
  borderRadius: '6px',
26
28
  '&:focus-within, &:focus, &:hover': {
29
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-important-styles -- Ignored via go/DSP-18766
27
30
  borderColor: "".concat("var(--ds-border, ".concat(N50, ")"), " !important")
28
31
  }
29
32
  });
@@ -1,15 +1,51 @@
1
+ /** @jsx jsx */
2
+
3
+ import { jsx } from '@emotion/react';
1
4
  import { backgroundColorPalette } from '@atlaskit/adf-schema';
5
+ import Icon from '@atlaskit/icon';
6
+ import { useThemeObserver } from '@atlaskit/tokens';
2
7
  import { DEFAULT_BORDER_COLOR } from './common';
3
8
  import getColorMessage from './getColorMessage';
4
9
  import paletteMessages from './paletteMessages';
5
10
  import { mapPaletteColor } from './textColorPalette';
6
11
  export var REMOVE_HIGHLIGHT_COLOR = '#00000000';
12
+ var DiagonalLineGlyph = function DiagonalLineGlyph() {
13
+ return jsx("svg", {
14
+ width: "24",
15
+ height: "24",
16
+ viewBox: "0 0 24 24",
17
+ fill: "none",
18
+ xmlns: "http://www.w3.org/2000/svg"
19
+ }, jsx("rect", {
20
+ width: "24",
21
+ height: "24",
22
+ fill: "white",
23
+ fillOpacity: "0.01"
24
+ }), jsx("path", {
25
+ fillRule: "evenodd",
26
+ clipRule: "evenodd",
27
+ d: "M17.2038 7.70388C17.5955 8.09565 17.5941 8.73128 17.2005 9.12127L9.1213 17.1277C8.73027 17.5152 8.09958 17.5138 7.71031 17.1245C7.31854 16.7328 7.31997 16.0971 7.71351 15.7071L15.7928 7.70069C16.1838 7.31318 16.8145 7.31461 17.2038 7.70388Z",
28
+ fill: "currentColor",
29
+ fillOpacity: "0.5"
30
+ }));
31
+ };
32
+ export var EditorDiagonalLineIcon = function EditorDiagonalLineIcon() {
33
+ var _useThemeObserver = useThemeObserver(),
34
+ colorMode = _useThemeObserver.colorMode;
35
+ var primaryColor = colorMode === 'dark' ? "var(--ds-background-accent-gray-bolder, #626F86)" : "var(--ds-background-accent-gray-subtle, #8590A2)";
36
+ return jsx(Icon, {
37
+ glyph: DiagonalLineGlyph,
38
+ label: "",
39
+ primaryColor: primaryColor
40
+ });
41
+ };
7
42
  export var highlightColorPalette = [{
8
43
  value: REMOVE_HIGHLIGHT_COLOR,
9
44
  label: 'No color',
10
45
  // Mostly informative, only used for analytics
11
46
  border: DEFAULT_BORDER_COLOR,
12
- message: getColorMessage(paletteMessages, 'no-color')
47
+ message: getColorMessage(paletteMessages, 'no-color'),
48
+ decorator: jsx(EditorDiagonalLineIcon, null)
13
49
  }];
14
50
  backgroundColorPalette.forEach(function (label, color) {
15
51
  highlightColorPalette.push(mapPaletteColor(label, color));
@@ -123,7 +123,7 @@ export default defineMessages({
123
123
  // Colors only used in highlight palette
124
124
  'no-color': {
125
125
  id: 'fabric.theme.no-color',
126
- defaultMessage: 'Remove highlight',
126
+ defaultMessage: 'No highlight',
127
127
  description: 'Tooltip for the no color option in the highlight color palette in the main editor toolbar'
128
128
  },
129
129
  lime: {
@@ -54,6 +54,7 @@ var ColorPalette = function ColorPalette(props) {
54
54
  }, [palette, cols]);
55
55
  return jsx(React.Fragment, null, colorsPerRow.map(function (row) {
56
56
  return jsx("div", {
57
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values, @atlaskit/design-system/consistent-css-prop-usage -- Ignored via go/DSP-18766
57
58
  css: colorPaletteWrapper
58
59
  // eslint-disable-next-line @atlaskit/ui-styling-standard/no-classname-prop -- Ignored via go/DSP-18766
59
60
  ,
@@ -64,7 +65,8 @@ var ColorPalette = function ColorPalette(props) {
64
65
  var value = _ref.value,
65
66
  label = _ref.label,
66
67
  border = _ref.border,
67
- message = _ref.message;
68
+ message = _ref.message,
69
+ decorator = _ref.decorator;
68
70
  if (paletteColorTooltipMessages) {
69
71
  if (tokenTheme === 'dark') {
70
72
  message = getColorMessage(paletteColorTooltipMessages.dark, value.toUpperCase());
@@ -81,7 +83,8 @@ var ColorPalette = function ColorPalette(props) {
81
83
  onClick: onClick,
82
84
  isSelected: value === selectedColor,
83
85
  checkMarkColor: getCheckMarkColor(value, useIconToken),
84
- hexToPaletteColor: hexToPaletteColor
86
+ hexToPaletteColor: hexToPaletteColor,
87
+ decorator: decorator
85
88
  });
86
89
  }));
87
90
  }));
@@ -1,4 +1,5 @@
1
1
  import { css } from '@emotion/react';
2
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-exported-styles, @atlaskit/design-system/no-exported-css -- Ignored via go/DSP-18766
2
3
  export var colorPaletteWrapper = css({
3
4
  padding: "0 ".concat("var(--ds-space-100, 8px)"),
4
5
  /* Firefox bug fix: https://product-fabric.atlassian.net/browse/ED-1789 */
@@ -25,6 +25,7 @@ var colorPickerExpandContainer = css({
25
25
  // Control the size of color picker buttons and preview
26
26
  // TODO: https://product-fabric.atlassian.net/browse/DSP-4134
27
27
  /* eslint-disable @atlaskit/design-system/ensure-design-token-usage */
28
+ // eslint-disable-next-line @atlaskit/design-system/consistent-css-prop-usage -- Ignored via go/DSP-18766
28
29
  var colorPickerWrapper = function colorPickerWrapper() {
29
30
  return css({
30
31
  borderRadius: "var(--ds-border-radius, 3px)",
@@ -168,17 +169,23 @@ var ColorPickerButton = function ColorPickerButton(props) {
168
169
  return css({
169
170
  padding: "var(--ds-space-075, 6px)".concat(" 10px"),
170
171
  backgroundColor: "var(--ds-background-neutral-subtle, transparent)",
172
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-values -- Ignored via go/DSP-18766
171
173
  height: "".concat(!!((_props$size = props.size) !== null && _props$size !== void 0 && _props$size.height) ? 'inherit' : ''),
174
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-selectors -- Ignored via go/DSP-18766
172
175
  '&:before': {
173
176
  display: 'flex',
174
177
  justifyContent: 'center',
175
178
  alignItems: 'center',
176
179
  alignSelf: 'center',
177
180
  content: "''",
181
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values, @atlaskit/ui-styling-standard/no-unsafe-values -- Ignored via go/DSP-18766
178
182
  border: "1px solid ".concat(DEFAULT_BORDER_COLOR),
179
183
  borderRadius: "var(--ds-border-radius, 3px)",
184
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-values -- Ignored via go/DSP-18766
180
185
  backgroundColor: currentColor || 'transparent',
186
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-values -- Ignored via go/DSP-18766
181
187
  width: ((_props$size2 = props.size) === null || _props$size2 === void 0 ? void 0 : _props$size2.width) || '14px',
188
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-values -- Ignored via go/DSP-18766
182
189
  height: ((_props$size3 = props.size) === null || _props$size3 === void 0 ? void 0 : _props$size3.height) || '14px',
183
190
  padding: 0,
184
191
  margin: "0px ".concat("var(--ds-space-025, 2px)")
@@ -34,6 +34,7 @@ import { ArrowKeyNavigationProvider } from '../ArrowKeyNavigationProvider';
34
34
  import { ArrowKeyNavigationType } from '../ArrowKeyNavigationProvider/types';
35
35
  var wrapper = css({
36
36
  /* tooltip in ToolbarButton is display:block */
37
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-nested-selectors -- Ignored via go/DSP-18766
37
38
  '& > div > div': {
38
39
  display: 'flex'
39
40
  }
@@ -1,3 +1,4 @@
1
+ import _toConsumableArray from "@babel/runtime/helpers/toConsumableArray";
1
2
  import { getBooleanFF } from '@atlaskit/platform-feature-flags';
2
3
  export var canApplyAnnotationOnRange = function canApplyAnnotationOnRange(rangeSelection, doc, schema) {
3
4
  var from = rangeSelection.from,
@@ -89,4 +90,25 @@ export function containsAnyAnnotations(slice, state) {
89
90
  });
90
91
  });
91
92
  return hasAnnotation;
93
+ }
94
+
95
+ /**
96
+ * This returns a list of node names that are inline nodes in the range.
97
+ */
98
+ export function getRangeInlineNodeNames(_ref) {
99
+ var doc = _ref.doc,
100
+ pos = _ref.pos;
101
+ if (!getBooleanFF('platform.editor.allow-inline-comments-for-inline-nodes-round-2_ctuxz')) {
102
+ return undefined;
103
+ }
104
+ var nodeNames = new Set();
105
+ doc.nodesBetween(pos.from, pos.to, function (node) {
106
+ if (node.isInline) {
107
+ nodeNames.add(node.type.name);
108
+ }
109
+ });
110
+
111
+ // We sort the list alphabetically to make human consumption of the list easier (in tools like the analytics extension)
112
+ var sortedNames = _toConsumableArray(nodeNames).sort();
113
+ return sortedNames;
92
114
  }
@@ -2,7 +2,7 @@ import { hasParentNodeOfType } from '@atlaskit/editor-prosemirror/utils';
2
2
  import { hasDocAsParent } from './document';
3
3
  import { isEmptyParagraph } from './editor-core-utils';
4
4
  export { shouldAutoLinkifyMatch } from './should-auto-linkify-tld';
5
- export { canApplyAnnotationOnRange, containsAnyAnnotations, getAnnotationIdsFromRange, hasAnnotationMark } from './annotation';
5
+ export { canApplyAnnotationOnRange, containsAnyAnnotations, getAnnotationIdsFromRange, hasAnnotationMark, getRangeInlineNodeNames } from './annotation';
6
6
  export { getExtensionLozengeData } from './macro';
7
7
  export { default as browser } from './browser';
8
8
  export { default as ErrorReporter } from './error-reporter';
@@ -1,6 +1,8 @@
1
- import type { ACTION, ACTION_SUBJECT, ACTION_SUBJECT_ID } from './enums';
1
+ import type { ACTION, ACTION_SUBJECT, ACTION_SUBJECT_ID, INPUT_METHOD } from './enums';
2
2
  import type { TrackAEP } from './utils';
3
- export type HighlightToolbarToggleAEP = TrackAEP<ACTION.OPENED | ACTION.CLOSED, ACTION_SUBJECT.TOOLBAR, ACTION_SUBJECT_ID.FORMAT_BACKGROUND_COLOR, undefined, undefined>;
3
+ export type HighlightToolbarToggleAEP = TrackAEP<ACTION.OPENED | ACTION.CLOSED, ACTION_SUBJECT.TOOLBAR, ACTION_SUBJECT_ID.FORMAT_BACKGROUND_COLOR, {
4
+ inputMethod: INPUT_METHOD.TOOLBAR | INPUT_METHOD.SHORTCUT;
5
+ }, undefined>;
4
6
  export type HighlightTextAEP = TrackAEP<ACTION.FORMATTED, ACTION_SUBJECT.TEXT, ACTION_SUBJECT_ID.FORMAT_BACKGROUND_COLOR, {
5
7
  newColor: string;
6
8
  previousColor: string;
@@ -6,6 +6,7 @@ export type AnnotationAEPAttributes = undefined | {} | AnnotationDraftAEPAttribu
6
6
  export type AnnotationDraftAEPAttributes = {
7
7
  inputMethod: INPUT_METHOD.TOOLBAR | INPUT_METHOD.SHORTCUT;
8
8
  overlap: number;
9
+ inlineNodeNames?: string[];
9
10
  };
10
11
  export type AnnotationResolvedAEPAttributes = {
11
12
  method: RESOLVE_METHOD;
@@ -89,6 +89,7 @@ export declare const selectTable: Keymap;
89
89
  export declare const increaseMediaSize: Keymap;
90
90
  export declare const decreaseMediaSize: Keymap;
91
91
  export declare const activateVideoControls: Keymap;
92
+ export declare const toggleHighlightPalette: Keymap;
92
93
  export declare function tooltip(keymap?: Keymap, description?: string): string | undefined;
93
94
  export declare const ToolTipContent: React.MemoExoticComponent<({ description, shortcutOverride, keymap, }: {
94
95
  description?: string | React.ReactNode;
@@ -84,4 +84,9 @@ export declare const helpDialogMessages: {
84
84
  defaultMessage: string;
85
85
  description: string;
86
86
  };
87
+ highlightColor: {
88
+ id: string;
89
+ defaultMessage: string;
90
+ description: string;
91
+ };
87
92
  };
@@ -285,6 +285,14 @@ export type FeatureFlags = {
285
285
  * @default false
286
286
  */
287
287
  commentsOnMediaAnalytics?: boolean;
288
+ /**
289
+ * @description
290
+ * Enables block elements drag and drop
291
+ *
292
+ * @see https://product-fabric.atlassian.net/browse/ED-22939
293
+ * @default false
294
+ */
295
+ elementDragAndDrop?: boolean;
288
296
  };
289
297
  export type FeatureFlagKey = keyof FeatureFlags;
290
298
  export type GetEditorFeatureFlags = () => FeatureFlags;
@@ -1,5 +1,5 @@
1
1
  /** @jsx jsx */
2
- import React, { PureComponent } from 'react';
2
+ import React, { PureComponent, type ReactElement } from 'react';
3
3
  import { jsx } from '@emotion/react';
4
4
  export interface Props {
5
5
  value: string;
@@ -11,10 +11,13 @@ export interface Props {
11
11
  checkMarkColor?: string;
12
12
  autoFocus?: boolean;
13
13
  hexToPaletteColor?: (hexColor: string) => string | undefined;
14
+ decorator?: ReactElement;
14
15
  }
15
- declare class Color extends PureComponent<Props> {
16
+ declare function FunctionalComponentColor(props: Props): jsx.JSX.Element;
17
+ declare class ClassComponentColor extends PureComponent<Props> {
16
18
  render(): jsx.JSX.Element;
17
19
  onMouseDown: (e: React.MouseEvent<{}>) => void;
18
20
  onClick: (e: React.MouseEvent<{}>) => void;
19
21
  }
22
+ declare const Color: typeof ClassComponentColor | typeof FunctionalComponentColor;
20
23
  export default Color;
@@ -1,3 +1,6 @@
1
+ /** @jsx jsx */
2
+ import { jsx } from '@emotion/react';
1
3
  import type { PaletteColor } from './type';
2
4
  export declare const REMOVE_HIGHLIGHT_COLOR = "#00000000";
5
+ export declare const EditorDiagonalLineIcon: () => jsx.JSX.Element;
3
6
  export declare const highlightColorPalette: Array<PaletteColor>;
@@ -1,9 +1,11 @@
1
+ import { type ReactElement } from 'react';
1
2
  import { type MessageDescriptor } from 'react-intl-next';
2
3
  export interface PaletteColor {
3
4
  value: string;
4
5
  label: string;
5
6
  border: string;
6
7
  message?: MessageDescriptor;
8
+ decorator?: ReactElement;
7
9
  }
8
10
  export type Palette = Array<PaletteColor>;
9
11
  export type PaletteTooltipMessages = {
@@ -8,4 +8,14 @@ export declare const canApplyAnnotationOnRange: (rangeSelection: Range, doc: PMN
8
8
  export declare const getAnnotationIdsFromRange: (rangeSelection: Range, doc: PMNode, schema: Schema) => string[];
9
9
  export declare function hasAnnotationMark(node: PMNode, state: EditorState): boolean;
10
10
  export declare function containsAnyAnnotations(slice: Slice, state: EditorState): boolean;
11
+ /**
12
+ * This returns a list of node names that are inline nodes in the range.
13
+ */
14
+ export declare function getRangeInlineNodeNames({ doc, pos, }: {
15
+ doc: PMNode;
16
+ pos: {
17
+ from: number;
18
+ to: number;
19
+ };
20
+ }): string[] | undefined;
11
21
  export {};
@@ -2,7 +2,7 @@ import type { Node as PMNode, ResolvedPos, Schema } from '@atlaskit/editor-prose
2
2
  import type { EditorState, Selection } from '@atlaskit/editor-prosemirror/state';
3
3
  import type { ContentNodeWithPos } from '@atlaskit/editor-prosemirror/utils';
4
4
  export { shouldAutoLinkifyMatch } from './should-auto-linkify-tld';
5
- export { canApplyAnnotationOnRange, containsAnyAnnotations, getAnnotationIdsFromRange, hasAnnotationMark, } from './annotation';
5
+ export { canApplyAnnotationOnRange, containsAnyAnnotations, getAnnotationIdsFromRange, hasAnnotationMark, getRangeInlineNodeNames, } from './annotation';
6
6
  export { getExtensionLozengeData } from './macro';
7
7
  export type { Params } from './macro';
8
8
  export { default as browser } from './browser';
@@ -1,6 +1,8 @@
1
- import type { ACTION, ACTION_SUBJECT, ACTION_SUBJECT_ID } from './enums';
1
+ import type { ACTION, ACTION_SUBJECT, ACTION_SUBJECT_ID, INPUT_METHOD } from './enums';
2
2
  import type { TrackAEP } from './utils';
3
- export type HighlightToolbarToggleAEP = TrackAEP<ACTION.OPENED | ACTION.CLOSED, ACTION_SUBJECT.TOOLBAR, ACTION_SUBJECT_ID.FORMAT_BACKGROUND_COLOR, undefined, undefined>;
3
+ export type HighlightToolbarToggleAEP = TrackAEP<ACTION.OPENED | ACTION.CLOSED, ACTION_SUBJECT.TOOLBAR, ACTION_SUBJECT_ID.FORMAT_BACKGROUND_COLOR, {
4
+ inputMethod: INPUT_METHOD.TOOLBAR | INPUT_METHOD.SHORTCUT;
5
+ }, undefined>;
4
6
  export type HighlightTextAEP = TrackAEP<ACTION.FORMATTED, ACTION_SUBJECT.TEXT, ACTION_SUBJECT_ID.FORMAT_BACKGROUND_COLOR, {
5
7
  newColor: string;
6
8
  previousColor: string;
@@ -6,6 +6,7 @@ export type AnnotationAEPAttributes = undefined | {} | AnnotationDraftAEPAttribu
6
6
  export type AnnotationDraftAEPAttributes = {
7
7
  inputMethod: INPUT_METHOD.TOOLBAR | INPUT_METHOD.SHORTCUT;
8
8
  overlap: number;
9
+ inlineNodeNames?: string[];
9
10
  };
10
11
  export type AnnotationResolvedAEPAttributes = {
11
12
  method: RESOLVE_METHOD;
@@ -89,6 +89,7 @@ export declare const selectTable: Keymap;
89
89
  export declare const increaseMediaSize: Keymap;
90
90
  export declare const decreaseMediaSize: Keymap;
91
91
  export declare const activateVideoControls: Keymap;
92
+ export declare const toggleHighlightPalette: Keymap;
92
93
  export declare function tooltip(keymap?: Keymap, description?: string): string | undefined;
93
94
  export declare const ToolTipContent: React.MemoExoticComponent<({ description, shortcutOverride, keymap, }: {
94
95
  description?: string | React.ReactNode;
@@ -84,4 +84,9 @@ export declare const helpDialogMessages: {
84
84
  defaultMessage: string;
85
85
  description: string;
86
86
  };
87
+ highlightColor: {
88
+ id: string;
89
+ defaultMessage: string;
90
+ description: string;
91
+ };
87
92
  };
@@ -285,6 +285,14 @@ export type FeatureFlags = {
285
285
  * @default false
286
286
  */
287
287
  commentsOnMediaAnalytics?: boolean;
288
+ /**
289
+ * @description
290
+ * Enables block elements drag and drop
291
+ *
292
+ * @see https://product-fabric.atlassian.net/browse/ED-22939
293
+ * @default false
294
+ */
295
+ elementDragAndDrop?: boolean;
288
296
  };
289
297
  export type FeatureFlagKey = keyof FeatureFlags;
290
298
  export type GetEditorFeatureFlags = () => FeatureFlags;
@@ -1,5 +1,5 @@
1
1
  /** @jsx jsx */
2
- import React, { PureComponent } from 'react';
2
+ import React, { PureComponent, type ReactElement } from 'react';
3
3
  import { jsx } from '@emotion/react';
4
4
  export interface Props {
5
5
  value: string;
@@ -11,10 +11,13 @@ export interface Props {
11
11
  checkMarkColor?: string;
12
12
  autoFocus?: boolean;
13
13
  hexToPaletteColor?: (hexColor: string) => string | undefined;
14
+ decorator?: ReactElement;
14
15
  }
15
- declare class Color extends PureComponent<Props> {
16
+ declare function FunctionalComponentColor(props: Props): jsx.JSX.Element;
17
+ declare class ClassComponentColor extends PureComponent<Props> {
16
18
  render(): jsx.JSX.Element;
17
19
  onMouseDown: (e: React.MouseEvent<{}>) => void;
18
20
  onClick: (e: React.MouseEvent<{}>) => void;
19
21
  }
22
+ declare const Color: typeof ClassComponentColor | typeof FunctionalComponentColor;
20
23
  export default Color;
@@ -1,3 +1,6 @@
1
+ /** @jsx jsx */
2
+ import { jsx } from '@emotion/react';
1
3
  import type { PaletteColor } from './type';
2
4
  export declare const REMOVE_HIGHLIGHT_COLOR = "#00000000";
5
+ export declare const EditorDiagonalLineIcon: () => jsx.JSX.Element;
3
6
  export declare const highlightColorPalette: Array<PaletteColor>;
@@ -1,9 +1,11 @@
1
+ import { type ReactElement } from 'react';
1
2
  import { type MessageDescriptor } from 'react-intl-next';
2
3
  export interface PaletteColor {
3
4
  value: string;
4
5
  label: string;
5
6
  border: string;
6
7
  message?: MessageDescriptor;
8
+ decorator?: ReactElement;
7
9
  }
8
10
  export type Palette = Array<PaletteColor>;
9
11
  export type PaletteTooltipMessages = {