@atlaskit/editor-common 107.28.2 → 107.30.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (493) hide show
  1. package/CHANGELOG.md +27 -0
  2. package/afm-cc/tsconfig.json +7 -4
  3. package/dist/cjs/block-menu/messages.js +6 -1
  4. package/dist/cjs/code-block/index.js +58 -1
  5. package/dist/cjs/messages/block-menu.js +3 -3
  6. package/dist/cjs/monitoring/error.js +1 -1
  7. package/dist/cjs/styles/shared/smartCard.js +1 -1
  8. package/dist/cjs/ui/DropList/index.js +1 -1
  9. package/dist/es2019/block-menu/messages.js +6 -1
  10. package/dist/es2019/code-block/index.js +57 -0
  11. package/dist/es2019/messages/block-menu.js +3 -3
  12. package/dist/es2019/monitoring/error.js +1 -1
  13. package/dist/es2019/styles/shared/smartCard.js +2 -2
  14. package/dist/es2019/ui/DropList/index.js +1 -1
  15. package/dist/esm/block-menu/messages.js +6 -1
  16. package/dist/esm/code-block/index.js +57 -0
  17. package/dist/esm/messages/block-menu.js +3 -3
  18. package/dist/esm/monitoring/error.js +1 -1
  19. package/dist/esm/styles/shared/smartCard.js +1 -1
  20. package/dist/esm/ui/DropList/index.js +1 -1
  21. package/dist/types/analytics/api.d.ts +2 -2
  22. package/dist/types/analytics/types/activity-session-events.d.ts +14 -14
  23. package/dist/types/analytics/types/ai-definitions-events.d.ts +1 -1
  24. package/dist/types/analytics/types/ai-events.d.ts +2 -2
  25. package/dist/types/analytics/types/ai-inline-suggestion-events.d.ts +2 -2
  26. package/dist/types/analytics/types/ai-proactive-events.d.ts +12 -12
  27. package/dist/types/analytics/types/ai-unified-events.d.ts +11 -11
  28. package/dist/types/analytics/types/breakout-events.d.ts +4 -4
  29. package/dist/types/analytics/types/config-panel-events.d.ts +3 -3
  30. package/dist/types/analytics/types/cut-copy-events.d.ts +4 -4
  31. package/dist/types/analytics/types/datasource-clicked-events.d.ts +2 -2
  32. package/dist/types/analytics/types/date-events.d.ts +1 -1
  33. package/dist/types/analytics/types/element-events.d.ts +4 -4
  34. package/dist/types/analytics/types/events.d.ts +23 -23
  35. package/dist/types/analytics/types/extension-events.d.ts +5 -5
  36. package/dist/types/analytics/types/format-events.d.ts +6 -6
  37. package/dist/types/analytics/types/general-events.d.ts +32 -32
  38. package/dist/types/analytics/types/highlight-actions-menu-events.d.ts +1 -1
  39. package/dist/types/analytics/types/highlight-events.d.ts +1 -1
  40. package/dist/types/analytics/types/inline-comment-events.d.ts +1 -1
  41. package/dist/types/analytics/types/insert-events.d.ts +26 -26
  42. package/dist/types/analytics/types/link-events.d.ts +1 -1
  43. package/dist/types/analytics/types/link-tool-bar-events.d.ts +17 -17
  44. package/dist/types/analytics/types/list-events.d.ts +8 -8
  45. package/dist/types/analytics/types/loom-events.d.ts +1 -1
  46. package/dist/types/analytics/types/media-events.d.ts +9 -9
  47. package/dist/types/analytics/types/mention-events.d.ts +30 -30
  48. package/dist/types/analytics/types/move-content-events.d.ts +3 -3
  49. package/dist/types/analytics/types/ncs-session-step-events.d.ts +3 -3
  50. package/dist/types/analytics/types/node-events.d.ts +5 -5
  51. package/dist/types/analytics/types/offline-editing-event.d.ts +5 -5
  52. package/dist/types/analytics/types/paste-events.d.ts +6 -6
  53. package/dist/types/analytics/types/performance-report.d.ts +6 -6
  54. package/dist/types/analytics/types/referentiality-events.d.ts +2 -2
  55. package/dist/types/analytics/types/selection-events.d.ts +1 -1
  56. package/dist/types/analytics/types/smart-links.d.ts +2 -2
  57. package/dist/types/analytics/types/substitute-events.d.ts +1 -1
  58. package/dist/types/analytics/types/table-events.d.ts +19 -19
  59. package/dist/types/analytics/types/type-ahead.d.ts +3 -3
  60. package/dist/types/analytics/types/utils.d.ts +6 -6
  61. package/dist/types/analytics/types/view-events.d.ts +2 -2
  62. package/dist/types/annotation/index.d.ts +39 -39
  63. package/dist/types/block-menu/messages.d.ts +5 -0
  64. package/dist/types/card/LinkToolbarButtonGroup.d.ts +5 -5
  65. package/dist/types/card/MediaAndEmbedsToolbar/index.d.ts +2 -2
  66. package/dist/types/card/cardOptions.d.ts +36 -36
  67. package/dist/types/card/types.d.ts +8 -8
  68. package/dist/types/code-block/index.d.ts +6 -0
  69. package/dist/types/collab/index.d.ts +71 -71
  70. package/dist/types/doc-utils/editor-use-only.d.ts +1 -1
  71. package/dist/types/element-browser/ElementBrowser.d.ts +9 -9
  72. package/dist/types/element-browser/ViewMore.d.ts +1 -1
  73. package/dist/types/element-browser/components/CategoryList.d.ts +1 -1
  74. package/dist/types/element-browser/components/ElementList/ElementList.d.ts +11 -11
  75. package/dist/types/element-browser/components/ElementList/EmptyState.d.ts +1 -1
  76. package/dist/types/element-browser/components/ElementSearch.d.ts +4 -4
  77. package/dist/types/element-browser/components/StatelessElementBrowser.d.ts +14 -14
  78. package/dist/types/element-browser/hooks/use-select-and-focus-on-arrow-navigation.d.ts +12 -12
  79. package/dist/types/element-browser/types.d.ts +2 -2
  80. package/dist/types/extensibility/Extension/Extension/index.d.ts +12 -12
  81. package/dist/types/extensibility/Extension/InlineExtension/index.d.ts +5 -5
  82. package/dist/types/extensibility/Extension/LegacyContentHeader/index.d.ts +1 -1
  83. package/dist/types/extensibility/Extension/Lozenge/EditToggle.d.ts +2 -2
  84. package/dist/types/extensibility/Extension/Lozenge/ExtensionLabel.d.ts +6 -6
  85. package/dist/types/extensibility/Extension/Lozenge/LozengeComponent.d.ts +11 -11
  86. package/dist/types/extensibility/Extension/Lozenge/index.d.ts +9 -9
  87. package/dist/types/extensibility/Extension.d.ts +8 -8
  88. package/dist/types/extensibility/ExtensionComponent.d.ts +13 -13
  89. package/dist/types/extensibility/ExtensionNodeWrapper.d.ts +1 -1
  90. package/dist/types/extensibility/MultiBodiedExtension/action-api.d.ts +5 -5
  91. package/dist/types/extensibility/MultiBodiedExtension/index.d.ts +10 -10
  92. package/dist/types/extensibility/extensionNodeView.d.ts +8 -8
  93. package/dist/types/extensions/extension-handlers.d.ts +1 -1
  94. package/dist/types/extensions/types/extension-handler.d.ts +10 -10
  95. package/dist/types/extensions/types/extension-manifest-toolbar-item.d.ts +13 -13
  96. package/dist/types/extensions/types/extension-manifest.d.ts +26 -26
  97. package/dist/types/extensions/types/extension-provider.d.ts +3 -3
  98. package/dist/types/extensions/types/field-definitions.d.ts +40 -40
  99. package/dist/types/extensions/types/utils.d.ts +7 -7
  100. package/dist/types/floating-toolbar/DropdownMenuExtensionItems.d.ts +4 -4
  101. package/dist/types/floating-toolbar/DropdownMenuItem.d.ts +10 -10
  102. package/dist/types/guideline/relativeGuideline.d.ts +1 -1
  103. package/dist/types/guideline/types.d.ts +9 -9
  104. package/dist/types/guideline/updateGuideline.d.ts +1 -1
  105. package/dist/types/guideline/utils.d.ts +2 -2
  106. package/dist/types/icons/shared/DynamicStrokeIconDecoration.d.ts +1 -1
  107. package/dist/types/icons/shared/SteppedRainbowIconDecoration.d.ts +1 -1
  108. package/dist/types/insert/index.d.ts +2 -2
  109. package/dist/types/keymaps/index.d.ts +2 -2
  110. package/dist/types/lazy-node-view/index.d.ts +3 -3
  111. package/dist/types/link/ConfigureLinkOverlay/Dropdown.d.ts +3 -3
  112. package/dist/types/link/ConfigureLinkOverlay/handleNavigation.d.ts +1 -1
  113. package/dist/types/link/ConfigureLinkOverlay/index.d.ts +2 -2
  114. package/dist/types/link/LinkPicker/EditorLinkPicker/index.d.ts +3 -3
  115. package/dist/types/link/LinkPicker/HyperlinkAddToolbar/HyperlinkAddToolbar.d.ts +12 -12
  116. package/dist/types/link/LinkPicker/HyperlinkAddToolbar/index.d.ts +8 -8
  117. package/dist/types/link/LinkSearch/LinkSearchList.d.ts +6 -6
  118. package/dist/types/link/LinkSearch/LinkSearchListItem.d.ts +4 -4
  119. package/dist/types/link/LinkSearch/types.d.ts +11 -11
  120. package/dist/types/link/types.d.ts +9 -9
  121. package/dist/types/lists/indentation.d.ts +1 -1
  122. package/dist/types/lists/node.d.ts +2 -2
  123. package/dist/types/lists/replace-content.d.ts +1 -1
  124. package/dist/types/lists/selection.d.ts +1 -1
  125. package/dist/types/media-inline/inline-image-card.d.ts +4 -4
  126. package/dist/types/media-inline/inline-image-wrapper.d.ts +3 -3
  127. package/dist/types/media-inline/media-inline-image-card.d.ts +8 -8
  128. package/dist/types/media-inline/types.d.ts +4 -4
  129. package/dist/types/media-inline/views/error-view.d.ts +3 -3
  130. package/dist/types/media-inline/views/loading-view.d.ts +2 -2
  131. package/dist/types/media-single/CommentBadge.d.ts +6 -6
  132. package/dist/types/media-single/CommentBadgeNext.d.ts +1 -1
  133. package/dist/types/media-single/MediaBadges.d.ts +4 -4
  134. package/dist/types/media-single/utils.d.ts +5 -5
  135. package/dist/types/node-visibility/node-visibility-manager.d.ts +5 -5
  136. package/dist/types/portal/PortalManager.d.ts +1 -1
  137. package/dist/types/portal/common.d.ts +2 -2
  138. package/dist/types/preset/builder.d.ts +1 -1
  139. package/dist/types/preset/plugin-injection-api.d.ts +3 -3
  140. package/dist/types/provider-factory/card-provider.d.ts +1 -1
  141. package/dist/types/provider-factory/context-identifier-provider.d.ts +1 -1
  142. package/dist/types/provider-factory/image-upload-provider.d.ts +1 -1
  143. package/dist/types/provider-factory/macro-provider.d.ts +4 -4
  144. package/dist/types/provider-factory/media-provider.d.ts +5 -5
  145. package/dist/types/provider-factory/profile-card-provider.d.ts +1 -1
  146. package/dist/types/provider-factory/quick-insert-provider.d.ts +10 -10
  147. package/dist/types/provider-factory/search-provider.d.ts +3 -3
  148. package/dist/types/provider-factory/types.d.ts +11 -11
  149. package/dist/types/provider-helpers/promise-helpers.d.ts +1 -1
  150. package/dist/types/quick-insert/use-icon-themed.d.ts +1 -1
  151. package/dist/types/react-node-view/getInlineNodeViewProducer.d.ts +6 -6
  152. package/dist/types/react-node-view/index.d.ts +1 -1
  153. package/dist/types/resizer/BreakoutResizer.d.ts +10 -10
  154. package/dist/types/resizer/Resizer.d.ts +32 -32
  155. package/dist/types/resizer/types.d.ts +2 -2
  156. package/dist/types/safe-plugin/index.d.ts +1 -1
  157. package/dist/types/selection/gap-cursor/actions.d.ts +1 -1
  158. package/dist/types/selection/gap-cursor/selection.d.ts +1 -1
  159. package/dist/types/selection/index.d.ts +1 -1
  160. package/dist/types/selection/types.d.ts +3 -3
  161. package/dist/types/table/SortingIcon.d.ts +1 -1
  162. package/dist/types/toolbar/context.d.ts +1 -1
  163. package/dist/types/types/annotation/index.d.ts +43 -43
  164. package/dist/types/types/copy-button.d.ts +8 -8
  165. package/dist/types/types/doc-builder.d.ts +1 -1
  166. package/dist/types/types/editor-actions.d.ts +6 -6
  167. package/dist/types/types/editor-container-width.d.ts +7 -7
  168. package/dist/types/types/editor-plugin.d.ts +33 -33
  169. package/dist/types/types/empty-state-handler.d.ts +1 -1
  170. package/dist/types/types/feature-flags.d.ts +107 -107
  171. package/dist/types/types/feedback-dialog.d.ts +5 -5
  172. package/dist/types/types/floating-toolbar.d.ts +142 -142
  173. package/dist/types/types/hyperlink.d.ts +10 -10
  174. package/dist/types/types/input-rules.d.ts +1 -1
  175. package/dist/types/types/next-editor-plugin.d.ts +47 -47
  176. package/dist/types/types/performance-tracking.d.ts +90 -90
  177. package/dist/types/types/plugin-factory.d.ts +6 -6
  178. package/dist/types/types/prosemirror-config.d.ts +1 -1
  179. package/dist/types/types/quick-insert.d.ts +9 -9
  180. package/dist/types/types/selection-toolbar.d.ts +2 -2
  181. package/dist/types/types/supported-browsers.d.ts +1 -1
  182. package/dist/types/types/tables.d.ts +3 -3
  183. package/dist/types/types/text-formatting.d.ts +14 -14
  184. package/dist/types/types/toolbar.d.ts +2 -2
  185. package/dist/types/types/type-ahead.d.ts +29 -29
  186. package/dist/types/types/ui-components.d.ts +7 -7
  187. package/dist/types/types/user-preferences.d.ts +6 -6
  188. package/dist/types/ugc-tokens/editor-ugc-token-names.d.ts +1 -1
  189. package/dist/types/ui/Announcer/announcer.d.ts +5 -5
  190. package/dist/types/ui/AssistiveText/AssistiveText.d.ts +2 -2
  191. package/dist/types/ui/BaseTheme/index.d.ts +2 -2
  192. package/dist/types/ui/Caption/index.d.ts +2 -2
  193. package/dist/types/ui/ContextPanel/context.d.ts +4 -4
  194. package/dist/types/ui/DropList/index.d.ts +7 -7
  195. package/dist/types/ui/Emoji/index.d.ts +3 -3
  196. package/dist/types/ui/ErrorBoundary/index.d.ts +1 -1
  197. package/dist/types/ui/EventHandlers/index.d.ts +7 -7
  198. package/dist/types/ui/Expand/sharedStyles.d.ts +2 -2
  199. package/dist/types/ui/FloatingToolbar/Button.d.ts +20 -20
  200. package/dist/types/ui/FloatingToolbar/ButtonSpotlightCard.d.ts +1 -1
  201. package/dist/types/ui/HoverLinkOverlay/types.d.ts +4 -4
  202. package/dist/types/ui/Layer/index.d.ts +6 -6
  203. package/dist/types/ui/MediaSingle/grid.d.ts +4 -4
  204. package/dist/types/ui/MediaSingle/index.d.ts +12 -12
  205. package/dist/types/ui/MediaSingle/styled.d.ts +8 -8
  206. package/dist/types/ui/Mention/index.d.ts +3 -3
  207. package/dist/types/ui/Mention/mention-with-profilecard.d.ts +4 -4
  208. package/dist/types/ui/Mention/mention-with-providers.d.ts +4 -4
  209. package/dist/types/ui/OverflowShadow/index.d.ts +1 -1
  210. package/dist/types/ui/OverflowShadow/shadowObserver.d.ts +1 -1
  211. package/dist/types/ui/PanelTextInput/index.d.ts +18 -18
  212. package/dist/types/ui/Popup/index.d.ts +16 -16
  213. package/dist/types/ui/Popup/utils.d.ts +6 -6
  214. package/dist/types/ui/Pulse/Pulse.d.ts +1 -1
  215. package/dist/types/ui/ResizerLegacy/index.d.ts +11 -11
  216. package/dist/types/ui/ResizerLegacy/types.d.ts +8 -8
  217. package/dist/types/ui/TableSelector/index.d.ts +11 -11
  218. package/dist/types/ui/TableSelector/table-selector.d.ts +7 -7
  219. package/dist/types/ui/UnsupportedBlock/index.d.ts +1 -1
  220. package/dist/types/ui/UnsupportedInline/index.d.ts +1 -1
  221. package/dist/types/ui/WidthProvider/index.d.ts +2 -2
  222. package/dist/types/ui-color/ColorPalette/Color/index.d.ts +8 -8
  223. package/dist/types/ui-color/ColorPalette/Palettes/type.d.ts +3 -3
  224. package/dist/types/ui-color/ColorPalette/index.d.ts +4 -4
  225. package/dist/types/ui-menu/ArrowKeyNavigationProvider/types.d.ts +11 -11
  226. package/dist/types/ui-menu/ColorPickerButton/index.d.ts +11 -11
  227. package/dist/types/ui-menu/Dropdown/index.d.ts +15 -15
  228. package/dist/types/ui-menu/DropdownMenu/types.d.ts +33 -33
  229. package/dist/types/ui-menu/ToolbarArrowKeyNavigationProvider/index.d.ts +4 -4
  230. package/dist/types/ui-menu/ToolbarButton/index.d.ts +19 -19
  231. package/dist/types/ui-react/ReactEditorViewContext.d.ts +1 -1
  232. package/dist/types/ui-react/with-react-editor-view-outer-listeners.d.ts +5 -5
  233. package/dist/types/user-preferences/persistence-api.d.ts +8 -8
  234. package/dist/types/utils/breakout.d.ts +12 -12
  235. package/dist/types/utils/calculate-toolbar-position.d.ts +1 -1
  236. package/dist/types/utils/compare-props.d.ts +3 -3
  237. package/dist/types/utils/count-nodes.d.ts +1 -1
  238. package/dist/types/utils/create-wrap-selection-transaction.d.ts +1 -1
  239. package/dist/types/utils/editor-core-utils.d.ts +1 -1
  240. package/dist/types/utils/error-reporter.d.ts +1 -1
  241. package/dist/types/utils/get-performance-options.d.ts +2 -2
  242. package/dist/types/utils/hyperlink.d.ts +1 -1
  243. package/dist/types/utils/imageLoader.d.ts +3 -3
  244. package/dist/types/utils/input-rules.d.ts +2 -2
  245. package/dist/types/utils/macro.d.ts +1 -1
  246. package/dist/types/utils/page-element-counts.d.ts +2 -2
  247. package/dist/types/utils/performance/hooks/use-component-render-tracking/index.d.ts +2 -2
  248. package/dist/types/utils/performance/measure-render.d.ts +3 -3
  249. package/dist/types/utils/performance/measure-tti.d.ts +1 -1
  250. package/dist/types/utils/plugin-state-factory.d.ts +1 -1
  251. package/dist/types/utils/profiler/render-count.d.ts +3 -3
  252. package/dist/types/utils/track-unsupported-content.d.ts +5 -5
  253. package/dist/types/utils/unsupportedContent/get-unsupported-content-level-data.d.ts +1 -1
  254. package/dist/types/utils/unsupportedContent/types.d.ts +1 -1
  255. package/dist/types/utils/validator.d.ts +5 -5
  256. package/dist/types/with-plugin-state/index.d.ts +1 -1
  257. package/dist/types-ts4.5/analytics/api.d.ts +2 -2
  258. package/dist/types-ts4.5/analytics/types/activity-session-events.d.ts +14 -14
  259. package/dist/types-ts4.5/analytics/types/ai-definitions-events.d.ts +1 -1
  260. package/dist/types-ts4.5/analytics/types/ai-events.d.ts +2 -2
  261. package/dist/types-ts4.5/analytics/types/ai-inline-suggestion-events.d.ts +2 -2
  262. package/dist/types-ts4.5/analytics/types/ai-proactive-events.d.ts +12 -12
  263. package/dist/types-ts4.5/analytics/types/ai-unified-events.d.ts +11 -11
  264. package/dist/types-ts4.5/analytics/types/breakout-events.d.ts +4 -4
  265. package/dist/types-ts4.5/analytics/types/config-panel-events.d.ts +3 -3
  266. package/dist/types-ts4.5/analytics/types/cut-copy-events.d.ts +4 -4
  267. package/dist/types-ts4.5/analytics/types/datasource-clicked-events.d.ts +2 -2
  268. package/dist/types-ts4.5/analytics/types/date-events.d.ts +1 -1
  269. package/dist/types-ts4.5/analytics/types/element-events.d.ts +4 -4
  270. package/dist/types-ts4.5/analytics/types/events.d.ts +23 -23
  271. package/dist/types-ts4.5/analytics/types/extension-events.d.ts +5 -5
  272. package/dist/types-ts4.5/analytics/types/format-events.d.ts +6 -6
  273. package/dist/types-ts4.5/analytics/types/general-events.d.ts +32 -32
  274. package/dist/types-ts4.5/analytics/types/highlight-actions-menu-events.d.ts +1 -1
  275. package/dist/types-ts4.5/analytics/types/highlight-events.d.ts +1 -1
  276. package/dist/types-ts4.5/analytics/types/inline-comment-events.d.ts +1 -1
  277. package/dist/types-ts4.5/analytics/types/insert-events.d.ts +26 -26
  278. package/dist/types-ts4.5/analytics/types/link-events.d.ts +1 -1
  279. package/dist/types-ts4.5/analytics/types/link-tool-bar-events.d.ts +17 -17
  280. package/dist/types-ts4.5/analytics/types/list-events.d.ts +8 -8
  281. package/dist/types-ts4.5/analytics/types/loom-events.d.ts +1 -1
  282. package/dist/types-ts4.5/analytics/types/media-events.d.ts +9 -9
  283. package/dist/types-ts4.5/analytics/types/mention-events.d.ts +30 -30
  284. package/dist/types-ts4.5/analytics/types/move-content-events.d.ts +3 -3
  285. package/dist/types-ts4.5/analytics/types/ncs-session-step-events.d.ts +3 -3
  286. package/dist/types-ts4.5/analytics/types/node-events.d.ts +5 -5
  287. package/dist/types-ts4.5/analytics/types/offline-editing-event.d.ts +5 -5
  288. package/dist/types-ts4.5/analytics/types/paste-events.d.ts +6 -6
  289. package/dist/types-ts4.5/analytics/types/performance-report.d.ts +6 -6
  290. package/dist/types-ts4.5/analytics/types/referentiality-events.d.ts +2 -2
  291. package/dist/types-ts4.5/analytics/types/selection-events.d.ts +1 -1
  292. package/dist/types-ts4.5/analytics/types/smart-links.d.ts +2 -2
  293. package/dist/types-ts4.5/analytics/types/substitute-events.d.ts +1 -1
  294. package/dist/types-ts4.5/analytics/types/table-events.d.ts +19 -19
  295. package/dist/types-ts4.5/analytics/types/type-ahead.d.ts +3 -3
  296. package/dist/types-ts4.5/analytics/types/utils.d.ts +6 -6
  297. package/dist/types-ts4.5/analytics/types/view-events.d.ts +2 -2
  298. package/dist/types-ts4.5/annotation/index.d.ts +39 -39
  299. package/dist/types-ts4.5/block-menu/messages.d.ts +5 -0
  300. package/dist/types-ts4.5/card/LinkToolbarButtonGroup.d.ts +5 -5
  301. package/dist/types-ts4.5/card/MediaAndEmbedsToolbar/index.d.ts +2 -2
  302. package/dist/types-ts4.5/card/cardOptions.d.ts +36 -36
  303. package/dist/types-ts4.5/card/types.d.ts +8 -8
  304. package/dist/types-ts4.5/code-block/index.d.ts +6 -0
  305. package/dist/types-ts4.5/collab/index.d.ts +71 -71
  306. package/dist/types-ts4.5/doc-utils/editor-use-only.d.ts +1 -1
  307. package/dist/types-ts4.5/element-browser/ElementBrowser.d.ts +9 -9
  308. package/dist/types-ts4.5/element-browser/ViewMore.d.ts +1 -1
  309. package/dist/types-ts4.5/element-browser/components/CategoryList.d.ts +1 -1
  310. package/dist/types-ts4.5/element-browser/components/ElementList/ElementList.d.ts +11 -11
  311. package/dist/types-ts4.5/element-browser/components/ElementList/EmptyState.d.ts +1 -1
  312. package/dist/types-ts4.5/element-browser/components/ElementSearch.d.ts +4 -4
  313. package/dist/types-ts4.5/element-browser/components/StatelessElementBrowser.d.ts +14 -14
  314. package/dist/types-ts4.5/element-browser/hooks/use-select-and-focus-on-arrow-navigation.d.ts +12 -12
  315. package/dist/types-ts4.5/element-browser/types.d.ts +2 -2
  316. package/dist/types-ts4.5/extensibility/Extension/Extension/index.d.ts +12 -12
  317. package/dist/types-ts4.5/extensibility/Extension/InlineExtension/index.d.ts +5 -5
  318. package/dist/types-ts4.5/extensibility/Extension/LegacyContentHeader/index.d.ts +1 -1
  319. package/dist/types-ts4.5/extensibility/Extension/Lozenge/EditToggle.d.ts +2 -2
  320. package/dist/types-ts4.5/extensibility/Extension/Lozenge/ExtensionLabel.d.ts +6 -6
  321. package/dist/types-ts4.5/extensibility/Extension/Lozenge/LozengeComponent.d.ts +11 -11
  322. package/dist/types-ts4.5/extensibility/Extension/Lozenge/index.d.ts +9 -9
  323. package/dist/types-ts4.5/extensibility/Extension.d.ts +8 -8
  324. package/dist/types-ts4.5/extensibility/ExtensionComponent.d.ts +13 -13
  325. package/dist/types-ts4.5/extensibility/ExtensionNodeWrapper.d.ts +1 -1
  326. package/dist/types-ts4.5/extensibility/MultiBodiedExtension/action-api.d.ts +5 -5
  327. package/dist/types-ts4.5/extensibility/MultiBodiedExtension/index.d.ts +10 -10
  328. package/dist/types-ts4.5/extensibility/extensionNodeView.d.ts +8 -8
  329. package/dist/types-ts4.5/extensions/extension-handlers.d.ts +1 -1
  330. package/dist/types-ts4.5/extensions/types/extension-handler.d.ts +10 -10
  331. package/dist/types-ts4.5/extensions/types/extension-manifest-toolbar-item.d.ts +13 -13
  332. package/dist/types-ts4.5/extensions/types/extension-manifest.d.ts +26 -26
  333. package/dist/types-ts4.5/extensions/types/extension-provider.d.ts +3 -3
  334. package/dist/types-ts4.5/extensions/types/field-definitions.d.ts +40 -40
  335. package/dist/types-ts4.5/extensions/types/utils.d.ts +7 -7
  336. package/dist/types-ts4.5/floating-toolbar/DropdownMenuExtensionItems.d.ts +4 -4
  337. package/dist/types-ts4.5/floating-toolbar/DropdownMenuItem.d.ts +10 -10
  338. package/dist/types-ts4.5/guideline/relativeGuideline.d.ts +1 -1
  339. package/dist/types-ts4.5/guideline/types.d.ts +9 -9
  340. package/dist/types-ts4.5/guideline/updateGuideline.d.ts +1 -1
  341. package/dist/types-ts4.5/guideline/utils.d.ts +2 -2
  342. package/dist/types-ts4.5/icons/shared/DynamicStrokeIconDecoration.d.ts +1 -1
  343. package/dist/types-ts4.5/icons/shared/SteppedRainbowIconDecoration.d.ts +1 -1
  344. package/dist/types-ts4.5/insert/index.d.ts +2 -2
  345. package/dist/types-ts4.5/keymaps/index.d.ts +2 -2
  346. package/dist/types-ts4.5/lazy-node-view/index.d.ts +3 -3
  347. package/dist/types-ts4.5/link/ConfigureLinkOverlay/Dropdown.d.ts +3 -3
  348. package/dist/types-ts4.5/link/ConfigureLinkOverlay/handleNavigation.d.ts +1 -1
  349. package/dist/types-ts4.5/link/ConfigureLinkOverlay/index.d.ts +2 -2
  350. package/dist/types-ts4.5/link/LinkPicker/EditorLinkPicker/index.d.ts +3 -3
  351. package/dist/types-ts4.5/link/LinkPicker/HyperlinkAddToolbar/HyperlinkAddToolbar.d.ts +12 -12
  352. package/dist/types-ts4.5/link/LinkPicker/HyperlinkAddToolbar/index.d.ts +8 -8
  353. package/dist/types-ts4.5/link/LinkSearch/LinkSearchList.d.ts +6 -6
  354. package/dist/types-ts4.5/link/LinkSearch/LinkSearchListItem.d.ts +4 -4
  355. package/dist/types-ts4.5/link/LinkSearch/types.d.ts +11 -11
  356. package/dist/types-ts4.5/link/types.d.ts +9 -9
  357. package/dist/types-ts4.5/lists/indentation.d.ts +1 -1
  358. package/dist/types-ts4.5/lists/node.d.ts +2 -2
  359. package/dist/types-ts4.5/lists/replace-content.d.ts +1 -1
  360. package/dist/types-ts4.5/lists/selection.d.ts +1 -1
  361. package/dist/types-ts4.5/media-inline/inline-image-card.d.ts +4 -4
  362. package/dist/types-ts4.5/media-inline/inline-image-wrapper.d.ts +3 -3
  363. package/dist/types-ts4.5/media-inline/media-inline-image-card.d.ts +8 -8
  364. package/dist/types-ts4.5/media-inline/types.d.ts +4 -4
  365. package/dist/types-ts4.5/media-inline/views/error-view.d.ts +3 -3
  366. package/dist/types-ts4.5/media-inline/views/loading-view.d.ts +2 -2
  367. package/dist/types-ts4.5/media-single/CommentBadge.d.ts +6 -6
  368. package/dist/types-ts4.5/media-single/CommentBadgeNext.d.ts +1 -1
  369. package/dist/types-ts4.5/media-single/MediaBadges.d.ts +4 -4
  370. package/dist/types-ts4.5/media-single/utils.d.ts +5 -5
  371. package/dist/types-ts4.5/node-visibility/node-visibility-manager.d.ts +5 -5
  372. package/dist/types-ts4.5/portal/PortalManager.d.ts +1 -1
  373. package/dist/types-ts4.5/portal/common.d.ts +2 -2
  374. package/dist/types-ts4.5/preset/builder.d.ts +1 -1
  375. package/dist/types-ts4.5/preset/plugin-injection-api.d.ts +3 -3
  376. package/dist/types-ts4.5/provider-factory/card-provider.d.ts +1 -1
  377. package/dist/types-ts4.5/provider-factory/context-identifier-provider.d.ts +1 -1
  378. package/dist/types-ts4.5/provider-factory/image-upload-provider.d.ts +1 -1
  379. package/dist/types-ts4.5/provider-factory/macro-provider.d.ts +4 -4
  380. package/dist/types-ts4.5/provider-factory/media-provider.d.ts +5 -5
  381. package/dist/types-ts4.5/provider-factory/profile-card-provider.d.ts +1 -1
  382. package/dist/types-ts4.5/provider-factory/quick-insert-provider.d.ts +10 -10
  383. package/dist/types-ts4.5/provider-factory/search-provider.d.ts +3 -3
  384. package/dist/types-ts4.5/provider-factory/types.d.ts +11 -11
  385. package/dist/types-ts4.5/provider-helpers/promise-helpers.d.ts +1 -1
  386. package/dist/types-ts4.5/quick-insert/use-icon-themed.d.ts +1 -1
  387. package/dist/types-ts4.5/react-node-view/getInlineNodeViewProducer.d.ts +6 -6
  388. package/dist/types-ts4.5/react-node-view/index.d.ts +1 -1
  389. package/dist/types-ts4.5/resizer/BreakoutResizer.d.ts +10 -10
  390. package/dist/types-ts4.5/resizer/Resizer.d.ts +32 -32
  391. package/dist/types-ts4.5/resizer/types.d.ts +2 -2
  392. package/dist/types-ts4.5/safe-plugin/index.d.ts +1 -1
  393. package/dist/types-ts4.5/selection/gap-cursor/actions.d.ts +1 -1
  394. package/dist/types-ts4.5/selection/gap-cursor/selection.d.ts +1 -1
  395. package/dist/types-ts4.5/selection/index.d.ts +1 -1
  396. package/dist/types-ts4.5/selection/types.d.ts +3 -3
  397. package/dist/types-ts4.5/table/SortingIcon.d.ts +1 -1
  398. package/dist/types-ts4.5/toolbar/context.d.ts +1 -1
  399. package/dist/types-ts4.5/types/annotation/index.d.ts +43 -43
  400. package/dist/types-ts4.5/types/copy-button.d.ts +8 -8
  401. package/dist/types-ts4.5/types/doc-builder.d.ts +1 -1
  402. package/dist/types-ts4.5/types/editor-actions.d.ts +6 -6
  403. package/dist/types-ts4.5/types/editor-container-width.d.ts +7 -7
  404. package/dist/types-ts4.5/types/editor-plugin.d.ts +33 -33
  405. package/dist/types-ts4.5/types/empty-state-handler.d.ts +1 -1
  406. package/dist/types-ts4.5/types/feature-flags.d.ts +107 -107
  407. package/dist/types-ts4.5/types/feedback-dialog.d.ts +5 -5
  408. package/dist/types-ts4.5/types/floating-toolbar.d.ts +142 -142
  409. package/dist/types-ts4.5/types/hyperlink.d.ts +10 -10
  410. package/dist/types-ts4.5/types/input-rules.d.ts +1 -1
  411. package/dist/types-ts4.5/types/next-editor-plugin.d.ts +47 -47
  412. package/dist/types-ts4.5/types/performance-tracking.d.ts +90 -90
  413. package/dist/types-ts4.5/types/plugin-factory.d.ts +6 -6
  414. package/dist/types-ts4.5/types/prosemirror-config.d.ts +1 -1
  415. package/dist/types-ts4.5/types/quick-insert.d.ts +9 -9
  416. package/dist/types-ts4.5/types/selection-toolbar.d.ts +2 -2
  417. package/dist/types-ts4.5/types/supported-browsers.d.ts +1 -1
  418. package/dist/types-ts4.5/types/tables.d.ts +3 -3
  419. package/dist/types-ts4.5/types/text-formatting.d.ts +14 -14
  420. package/dist/types-ts4.5/types/toolbar.d.ts +2 -2
  421. package/dist/types-ts4.5/types/type-ahead.d.ts +29 -29
  422. package/dist/types-ts4.5/types/ui-components.d.ts +7 -7
  423. package/dist/types-ts4.5/types/user-preferences.d.ts +6 -6
  424. package/dist/types-ts4.5/ugc-tokens/editor-ugc-token-names.d.ts +1 -1
  425. package/dist/types-ts4.5/ui/Announcer/announcer.d.ts +5 -5
  426. package/dist/types-ts4.5/ui/AssistiveText/AssistiveText.d.ts +2 -2
  427. package/dist/types-ts4.5/ui/BaseTheme/index.d.ts +2 -2
  428. package/dist/types-ts4.5/ui/Caption/index.d.ts +2 -2
  429. package/dist/types-ts4.5/ui/ContextPanel/context.d.ts +4 -4
  430. package/dist/types-ts4.5/ui/DropList/index.d.ts +7 -7
  431. package/dist/types-ts4.5/ui/Emoji/index.d.ts +3 -3
  432. package/dist/types-ts4.5/ui/ErrorBoundary/index.d.ts +1 -1
  433. package/dist/types-ts4.5/ui/EventHandlers/index.d.ts +7 -7
  434. package/dist/types-ts4.5/ui/Expand/sharedStyles.d.ts +2 -2
  435. package/dist/types-ts4.5/ui/FloatingToolbar/Button.d.ts +20 -20
  436. package/dist/types-ts4.5/ui/FloatingToolbar/ButtonSpotlightCard.d.ts +1 -1
  437. package/dist/types-ts4.5/ui/HoverLinkOverlay/types.d.ts +4 -4
  438. package/dist/types-ts4.5/ui/Layer/index.d.ts +6 -6
  439. package/dist/types-ts4.5/ui/MediaSingle/grid.d.ts +4 -4
  440. package/dist/types-ts4.5/ui/MediaSingle/index.d.ts +12 -12
  441. package/dist/types-ts4.5/ui/MediaSingle/styled.d.ts +8 -8
  442. package/dist/types-ts4.5/ui/Mention/index.d.ts +3 -3
  443. package/dist/types-ts4.5/ui/Mention/mention-with-profilecard.d.ts +4 -4
  444. package/dist/types-ts4.5/ui/Mention/mention-with-providers.d.ts +4 -4
  445. package/dist/types-ts4.5/ui/OverflowShadow/index.d.ts +1 -1
  446. package/dist/types-ts4.5/ui/OverflowShadow/shadowObserver.d.ts +1 -1
  447. package/dist/types-ts4.5/ui/PanelTextInput/index.d.ts +18 -18
  448. package/dist/types-ts4.5/ui/Popup/index.d.ts +16 -16
  449. package/dist/types-ts4.5/ui/Popup/utils.d.ts +6 -6
  450. package/dist/types-ts4.5/ui/Pulse/Pulse.d.ts +1 -1
  451. package/dist/types-ts4.5/ui/ResizerLegacy/index.d.ts +11 -11
  452. package/dist/types-ts4.5/ui/ResizerLegacy/types.d.ts +8 -8
  453. package/dist/types-ts4.5/ui/TableSelector/index.d.ts +11 -11
  454. package/dist/types-ts4.5/ui/TableSelector/table-selector.d.ts +7 -7
  455. package/dist/types-ts4.5/ui/UnsupportedBlock/index.d.ts +1 -1
  456. package/dist/types-ts4.5/ui/UnsupportedInline/index.d.ts +1 -1
  457. package/dist/types-ts4.5/ui/WidthProvider/index.d.ts +2 -2
  458. package/dist/types-ts4.5/ui-color/ColorPalette/Color/index.d.ts +8 -8
  459. package/dist/types-ts4.5/ui-color/ColorPalette/Palettes/type.d.ts +3 -3
  460. package/dist/types-ts4.5/ui-color/ColorPalette/index.d.ts +4 -4
  461. package/dist/types-ts4.5/ui-menu/ArrowKeyNavigationProvider/types.d.ts +11 -11
  462. package/dist/types-ts4.5/ui-menu/ColorPickerButton/index.d.ts +11 -11
  463. package/dist/types-ts4.5/ui-menu/Dropdown/index.d.ts +15 -15
  464. package/dist/types-ts4.5/ui-menu/DropdownMenu/types.d.ts +33 -33
  465. package/dist/types-ts4.5/ui-menu/ToolbarArrowKeyNavigationProvider/index.d.ts +4 -4
  466. package/dist/types-ts4.5/ui-menu/ToolbarButton/index.d.ts +19 -19
  467. package/dist/types-ts4.5/ui-react/ReactEditorViewContext.d.ts +1 -1
  468. package/dist/types-ts4.5/ui-react/with-react-editor-view-outer-listeners.d.ts +5 -5
  469. package/dist/types-ts4.5/user-preferences/persistence-api.d.ts +8 -8
  470. package/dist/types-ts4.5/utils/breakout.d.ts +12 -12
  471. package/dist/types-ts4.5/utils/calculate-toolbar-position.d.ts +1 -1
  472. package/dist/types-ts4.5/utils/compare-props.d.ts +3 -3
  473. package/dist/types-ts4.5/utils/count-nodes.d.ts +1 -1
  474. package/dist/types-ts4.5/utils/create-wrap-selection-transaction.d.ts +1 -1
  475. package/dist/types-ts4.5/utils/editor-core-utils.d.ts +1 -1
  476. package/dist/types-ts4.5/utils/error-reporter.d.ts +1 -1
  477. package/dist/types-ts4.5/utils/get-performance-options.d.ts +2 -2
  478. package/dist/types-ts4.5/utils/hyperlink.d.ts +1 -1
  479. package/dist/types-ts4.5/utils/imageLoader.d.ts +3 -3
  480. package/dist/types-ts4.5/utils/input-rules.d.ts +2 -2
  481. package/dist/types-ts4.5/utils/macro.d.ts +1 -1
  482. package/dist/types-ts4.5/utils/page-element-counts.d.ts +2 -2
  483. package/dist/types-ts4.5/utils/performance/hooks/use-component-render-tracking/index.d.ts +2 -2
  484. package/dist/types-ts4.5/utils/performance/measure-render.d.ts +3 -3
  485. package/dist/types-ts4.5/utils/performance/measure-tti.d.ts +1 -1
  486. package/dist/types-ts4.5/utils/plugin-state-factory.d.ts +1 -1
  487. package/dist/types-ts4.5/utils/profiler/render-count.d.ts +3 -3
  488. package/dist/types-ts4.5/utils/track-unsupported-content.d.ts +5 -5
  489. package/dist/types-ts4.5/utils/unsupportedContent/get-unsupported-content-level-data.d.ts +1 -1
  490. package/dist/types-ts4.5/utils/unsupportedContent/types.d.ts +1 -1
  491. package/dist/types-ts4.5/utils/validator.d.ts +5 -5
  492. package/dist/types-ts4.5/with-plugin-state/index.d.ts +1 -1
  493. package/package.json +5 -9
package/CHANGELOG.md CHANGED
@@ -1,5 +1,32 @@
1
1
  # @atlaskit/editor-common
2
2
 
3
+ ## 107.30.0
4
+
5
+ ### Minor Changes
6
+
7
+ - [`0ff4a6c7a39ef`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/0ff4a6c7a39ef) -
8
+ Creates global fold state to retain folds after breakouts and page resizing
9
+
10
+ ### Patch Changes
11
+
12
+ - Updated dependencies
13
+
14
+ ## 107.29.0
15
+
16
+ ### Minor Changes
17
+
18
+ - [`f0b0ea63f59bc`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/f0b0ea63f59bc) -
19
+ [ux] ED-28803 Register Delete Button in block menu and add delete functionality and hover styles
20
+
21
+ ### Patch Changes
22
+
23
+ - [`e229628ac96dd`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/e229628ac96dd) -
24
+ [ED-28430] clean up FG platform_editor_find_and_replace_improvements_1 for find & replace
25
+ additional fixes
26
+ - [`0fdcb6f2f96fd`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/0fdcb6f2f96fd) -
27
+ Sorted type and interface props to improve Atlaskit docs
28
+ - Updated dependencies
29
+
3
30
  ## 107.28.2
4
31
 
5
32
  ### Patch Changes
@@ -3,11 +3,14 @@
3
3
  "compilerOptions": {
4
4
  "declaration": true,
5
5
  "target": "es5",
6
- "composite": true,
7
6
  "outDir": "../../../../../confluence/tsDist/@atlaskit__editor-common",
8
- "rootDir": "../"
7
+ "rootDir": "../",
8
+ "composite": true
9
9
  },
10
- "include": ["../src/**/*.ts", "../src/**/*.tsx"],
10
+ "include": [
11
+ "../src/**/*.ts",
12
+ "../src/**/*.tsx"
13
+ ],
11
14
  "exclude": [
12
15
  "../src/**/__tests__/*",
13
16
  "../src/**/*.test.*",
@@ -183,4 +186,4 @@
183
186
  "path": "../../../media/media-core/afm-cc/tsconfig.json"
184
187
  }
185
188
  ]
186
- }
189
+ }
@@ -8,7 +8,12 @@ var _reactIntlNext = require("react-intl-next");
8
8
  var messages = exports.messages = (0, _reactIntlNext.defineMessages)({
9
9
  copyBlock: {
10
10
  id: 'fabric.editor.block.menu.copy.block',
11
- defaultMessage: 'Copy Block',
11
+ defaultMessage: 'Copy block',
12
12
  description: 'Copy the selected block to the clipboard'
13
+ },
14
+ deleteBlock: {
15
+ id: 'fabric.editor.block.menu.delete.block',
16
+ defaultMessage: 'Delete',
17
+ description: 'Delete the selected block'
13
18
  }
14
19
  });
@@ -3,20 +3,36 @@
3
3
  Object.defineProperty(exports, "__esModule", {
4
4
  value: true
5
5
  });
6
- exports.updateCodeBlockWrappedStateNodeKeys = exports.transferCodeBlockWrappedValue = exports.isCodeBlockWordWrapEnabled = exports.defaultWordWrapState = exports.codeBlockWrappedStates = void 0;
6
+ exports.updateCodeBlockWrappedStateNodeKeys = exports.transferCodeBlockWrappedValue = exports.setCodeBlockFoldState = exports.isCodeBlockWordWrapEnabled = exports.getCodeBlockFoldState = exports.defaultWordWrapState = exports.codeBlockWrappedStates = void 0;
7
+ var _expValEquals = require("@atlaskit/tmp-editor-statsig/exp-val-equals");
7
8
  /* eslint-disable @atlaskit/platform/ensure-feature-flag-prefix */
8
9
 
9
10
  var defaultWordWrapState = exports.defaultWordWrapState = false;
10
11
  var codeBlockWrappedStates = exports.codeBlockWrappedStates = new WeakMap();
12
+
13
+ // Code folding state management - similar to word wrapping
14
+
15
+ var codeBlockFoldStates = new WeakMap();
11
16
  var isCodeBlockWordWrapEnabled = exports.isCodeBlockWordWrapEnabled = function isCodeBlockWordWrapEnabled(codeBlockNode) {
12
17
  var currentNodeWordWrapState = codeBlockWrappedStates.get(codeBlockNode);
13
18
  return currentNodeWordWrapState !== undefined ? currentNodeWordWrapState : defaultWordWrapState;
14
19
  };
20
+ var getCodeBlockFoldState = exports.getCodeBlockFoldState = function getCodeBlockFoldState(codeBlockNode) {
21
+ var currentNodeFoldState = codeBlockFoldStates.get(codeBlockNode);
22
+ return currentNodeFoldState || [];
23
+ };
24
+ var setCodeBlockFoldState = exports.setCodeBlockFoldState = function setCodeBlockFoldState(codeBlockNode, foldRanges) {
25
+ codeBlockFoldStates.set(codeBlockNode, foldRanges);
26
+ };
15
27
 
16
28
  /**
17
29
  * Swap the old node key with the new node key in the wrapped states WeakMap.
18
30
  */
19
31
  var transferCodeBlockWrappedValue = exports.transferCodeBlockWrappedValue = function transferCodeBlockWrappedValue(oldCodeBlockNode, newCodeBlockNode) {
32
+ if ((0, _expValEquals.expValEquals)('platform_editor_code_block_fold_gutter', 'isEnabled', true)) {
33
+ transferCodeBlockFoldValue(oldCodeBlockNode, newCodeBlockNode);
34
+ }
35
+
20
36
  // Don't overwrite the value for the new node if it already exists.
21
37
  // This can happen when a drag&drop is swapping nodes.
22
38
  if (codeBlockWrappedStates.has(newCodeBlockNode)) {
@@ -27,6 +43,20 @@ var transferCodeBlockWrappedValue = exports.transferCodeBlockWrappedValue = func
27
43
  codeBlockWrappedStates.delete(oldCodeBlockNode);
28
44
  };
29
45
 
46
+ /**
47
+ * Swap the old node key with the new node key in the fold states WeakMap.
48
+ */
49
+ var transferCodeBlockFoldValue = function transferCodeBlockFoldValue(oldCodeBlockNode, newCodeBlockNode) {
50
+ // Don't overwrite the value for the new node if it already exists.
51
+ // This can happen when a drag&drop is swapping nodes.
52
+ if (codeBlockFoldStates.has(newCodeBlockNode)) {
53
+ return;
54
+ }
55
+ var previousValue = getCodeBlockFoldState(oldCodeBlockNode);
56
+ codeBlockFoldStates.set(newCodeBlockNode, previousValue);
57
+ codeBlockFoldStates.delete(oldCodeBlockNode);
58
+ };
59
+
30
60
  /**
31
61
  * As the code block node is used as the wrapped state key, there is instances where the node will be destroyed & recreated and is no longer a valid key.
32
62
  * In these instances, we must get the value from that old node and set it to the value of the new node.
@@ -34,6 +64,9 @@ var transferCodeBlockWrappedValue = exports.transferCodeBlockWrappedValue = func
34
64
  */
35
65
  var updateCodeBlockWrappedStateNodeKeys = exports.updateCodeBlockWrappedStateNodeKeys = function updateCodeBlockWrappedStateNodeKeys(newCodeBlockNodes, oldState) {
36
66
  newCodeBlockNodes.forEach(function (newCodeBlockNode) {
67
+ if ((0, _expValEquals.expValEquals)('platform_editor_code_block_fold_gutter', 'isEnabled', true)) {
68
+ updateCodeBlockFoldStateNodeKeys(newCodeBlockNode, oldState);
69
+ }
37
70
  // Don't overwrite the value for the new node if it already exists.
38
71
  // This can happen when a drag&drop is swapping nodes.
39
72
  if (codeBlockWrappedStates.has(newCodeBlockNode.node)) {
@@ -51,4 +84,28 @@ var updateCodeBlockWrappedStateNodeKeys = exports.updateCodeBlockWrappedStateNod
51
84
  var previousValue = isCodeBlockWordWrapEnabled(oldCodeBlockNode);
52
85
  codeBlockWrappedStates.set(newCodeBlockNode.node, previousValue);
53
86
  });
87
+ };
88
+
89
+ /**
90
+ * As the code block node is used as the fold state key, there is instances where the node will be destroyed & recreated and is no longer a valid key.
91
+ * In these instances, we must get the value from that old node and set it to the value of the new node.
92
+ * This function takes all the given nodes, finds their old nodes from the old state and updates these old node keys.
93
+ */
94
+ var updateCodeBlockFoldStateNodeKeys = function updateCodeBlockFoldStateNodeKeys(newCodeBlockNode, oldState) {
95
+ // Don't overwrite the value for the new node if it already exists.
96
+ // This can happen when a drag&drop is swapping nodes.
97
+ if (codeBlockFoldStates.has(newCodeBlockNode.node)) {
98
+ return;
99
+ }
100
+
101
+ // Do not go out of range on the oldState doc. Happens on initial load.
102
+ if (oldState.doc.content.size <= newCodeBlockNode.pos) {
103
+ return;
104
+ }
105
+ var oldCodeBlockNode = oldState.doc.nodeAt(newCodeBlockNode.pos);
106
+ if (!oldCodeBlockNode || oldCodeBlockNode.type !== oldState.schema.nodes.codeBlock) {
107
+ return;
108
+ }
109
+ var previousValue = getCodeBlockFoldState(oldCodeBlockNode);
110
+ codeBlockFoldStates.set(newCodeBlockNode.node, previousValue);
54
111
  };
@@ -8,17 +8,17 @@ var _reactIntlNext = require("react-intl-next");
8
8
  var messages = exports.messages = (0, _reactIntlNext.defineMessages)({
9
9
  copyBlock: {
10
10
  id: 'fabric.editor.block.menu.copy.block',
11
- defaultMessage: 'Copy Block',
11
+ defaultMessage: 'Copy block',
12
12
  description: 'Copy the selected block to the clipboard'
13
13
  },
14
14
  moveUpBlock: {
15
15
  id: 'fabric.editor.block.menu.move.up',
16
- defaultMessage: 'Move Up',
16
+ defaultMessage: 'Move up',
17
17
  description: 'Move the selected block up'
18
18
  },
19
19
  moveDownBlock: {
20
20
  id: 'fabric.editor.block.menu.move.down',
21
- defaultMessage: 'Move Down',
21
+ defaultMessage: 'Move down',
22
22
  description: 'Move the selected block down'
23
23
  },
24
24
  copyLink: {
@@ -16,7 +16,7 @@ function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t =
16
16
  function _interopRequireWildcard(e, t) { if ("function" == typeof WeakMap) var r = new WeakMap(), n = new WeakMap(); return (_interopRequireWildcard = function _interopRequireWildcard(e, t) { if (!t && e && e.__esModule) return e; var o, i, f = { __proto__: null, default: e }; if (null === e || "object" != _typeof(e) && "function" != typeof e) return f; if (o = t ? n : r) { if (o.has(e)) return o.get(e); o.set(e, f); } for (var _t in e) "default" !== _t && {}.hasOwnProperty.call(e, _t) && ((i = (o = Object.defineProperty) && Object.getOwnPropertyDescriptor(e, _t)) && (i.get || i.set) ? o(f, _t, i) : f[_t] = e[_t]); return f; })(e, t); }
17
17
  var SENTRY_DSN = 'https://0b10c8e02fb44d8796c047b102c9bee8@o55978.ingest.sentry.io/4505129224110080';
18
18
  var packageName = 'editor-common'; // Sentry doesn't accept '/' in its releases https://docs.sentry.io/platforms/javascript/configuration/releases/
19
- var packageVersion = "107.28.1";
19
+ var packageVersion = "107.29.0";
20
20
  var sanitiseSentryEvents = function sanitiseSentryEvents(data, _hint) {
21
21
  // Remove URL as it has UGC
22
22
  // Ignored via go/ees007
@@ -18,5 +18,5 @@ var FLOATING_TOOLBAR_LINKPICKER_CLASSNAME = exports.FLOATING_TOOLBAR_LINKPICKER_
18
18
 
19
19
  // eslint-disable-next-line @atlaskit/design-system/no-css-tagged-template-expression, @atlaskit/ui-styling-standard/no-exported-styles -- Ignored via go/DSP-18766
20
20
  var smartCardStyles = exports.smartCardStyles = function smartCardStyles() {
21
- return (0, _react.css)(_templateObject || (_templateObject = (0, _taggedTemplateLiteral2.default)(["\n\t.", " {\n\t\tmax-width: calc(100% - 20px);\n\t\tvertical-align: top;\n\t\tword-break: break-all;\n\t\t", "\n\t\t.card {\n\t\t\tpadding-left: ", ";\n\t\t\tpadding-right: ", ";\n\t\t\tpadding-top: 0.5em;\n\t\t\tpadding-bottom: 0.5em;\n\t\t\tmargin-bottom: -0.5em;\n\n\t\t\t.", " > a:focus {\n\t\t\t\t", "\n\t\t\t}\n\t\t}\n\n\t\t", "\n\n\t\t", "\n\t\t.", " > a {\n\t\t\t/* EDM-1717: box-shadow Safari fix start */\n\t\t\tz-index: 1;\n\t\t\tposition: relative;\n\t\t\t/* EDM-1717: box-shadow Safari fix end */\n\t\t}\n\n\t\t&.danger {\n\t\t\t.", " > a {\n\t\t\t\tbox-shadow: 0 0 0 1px ", ";\n\t\t\t\t/* EDM-1717: box-shadow Safari fix start */\n\t\t\t\tz-index: 2;\n\t\t\t\t/* EDM-1717: box-shadow Safari fix end */\n\t\t\t}\n\t\t}\n\t}\n\n\t.", " {\n\t\t.", " > div {\n\t\t\tcursor: pointer;\n\n\t\t\ta {\n\t\t\t\tcursor: auto;\n\t\t\t}\n\t\t}\n\n\t\t&.", " .", " > div {\n\t\t\t", "\n\t\t\tborder-radius: ", ";\n\t\t}\n\n\t\t&.danger {\n\t\t\t.", " > div {\n\t\t\t\tbox-shadow: 0 0 0 1px ", " !important;\n\t\t\t}\n\t\t}\n\t}\n\n\t.", ".", " {\n\t\tmax-width: 100%;\n\t\tdisplay: flex;\n\t\tjustify-content: center;\n\n\t\t.", " {\n\t\t\tcursor: pointer;\n\t\t\tbackground-color: ", ";\n\t\t\tborder-radius: ", ";\n\t\t\tborder: 1px solid ", ";\n\t\t\toverflow: hidden;\n\t\t}\n\n\t\t&.", " {\n\t\t\t.", " {\n\t\t\t\t", "\n\n\t\t\t\tinput::selection {\n\t\t\t\t\tbackground-color: ", ";\n\t\t\t\t}\n\t\t\t\tinput::-moz-selection {\n\t\t\t\t\tbackground-color: ", ";\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\t&.danger {\n\t\t\t.", " {\n\t\t\t\tbox-shadow: 0 0 0 1px ", ";\n\t\t\t}\n\t\t}\n\t}\n\n\t.", " {\n\t\t.", " > div {\n\t\t\tcursor: pointer;\n\t\t\ta {\n\t\t\t\tcursor: auto;\n\t\t\t}\n\t\t\t&::after {\n\t\t\t\ttransition: box-shadow 0s;\n\t\t\t}\n\t\t}\n\n\t\t", "\n\n\t\t&.danger {\n\t\t\t.media-card-frame::after {\n\t\t\t\tbox-shadow: 0 0 0 1px ", " !important;\n\t\t\t\tbackground: ", " !important;\n\t\t\t}\n\t\t\t.richMedia-resize-handle-right::after,\n\t\t\t.richMedia-resize-handle-left::after {\n\t\t\t\tbackground: ", ";\n\t\t\t}\n\t\t}\n\t}\n\n\t.", " {\n\t\tpadding: 0;\n\t}\n"])), _smartCard.SmartCardSharedCssClassName.INLINE_CARD_CONTAINER, (0, _platformFeatureFlags.fg)('editor_inline_comments_on_inline_nodes') ? ".card-with-comment {\n background: ".concat("var(--ds-background-accent-yellow-subtler, #F8E6A0)", ";\n border-bottom: 2px solid ", "var(--ds-border-accent-yellow, #B38600)", ";\n box-shadow: ", "var(--ds-shadow-overlay, 0px 8px 12px #091E4226, 0px 0px 1px #091E424f)", ";\n }") : '', "var(--ds-space-025, 2px)", "var(--ds-space-025, 2px)", _smartCard.SmartCardSharedCssClassName.LOADER_WRAPPER, (0, _editorSharedStyles.getSelectionStyles)([_editorSharedStyles.SelectionStyle.BoxShadow]), (0, _experiments.editorExperiment)('platform_editor_controls', 'variant1') || (0, _expValEqualsNoExposure.expValEqualsNoExposure)('platform_editor_preview_panel_linking_exp', 'isEnabled', true) ? "[data-inlinecard-button-overlay='icon-wrapper-line-height'] span {\n\t\t\t\tline-height: 0;\n\t\t\t}" : '', (0, _expValEqualsNoExposure.expValEqualsNoExposure)('platform_editor_find_and_replace_improvements', 'isEnabled', true) && (0, _platformFeatureFlags.fg)('platform_editor_find_and_replace_improvements_1') ? "\n\t\t\t\t&.".concat(_editorSharedStyles.akEditorSelectedNodeClassName, ":not(.search-match-block) .").concat(_smartCard.SmartCardSharedCssClassName.LOADER_WRAPPER, " > a {\n\t\t\t\t").concat((0, _editorSharedStyles.getSelectionStyles)([_editorSharedStyles.SelectionStyle.BoxShadow]), "\n\t\t\t}") : "\n\t\t\t\t&.".concat(_editorSharedStyles.akEditorSelectedNodeClassName, " .").concat(_smartCard.SmartCardSharedCssClassName.LOADER_WRAPPER, " > a {\n\t\t\t\t").concat((0, _editorSharedStyles.getSelectionStyles)([_editorSharedStyles.SelectionStyle.BoxShadow]), "\n\t\t\t}"), _smartCard.SmartCardSharedCssClassName.LOADER_WRAPPER, _smartCard.SmartCardSharedCssClassName.LOADER_WRAPPER, "var(--ds-border-danger, ".concat(_editorSharedStyles.akEditorDeleteBorder, ")"), _smartCard.SmartCardSharedCssClassName.BLOCK_CARD_CONTAINER, _smartCard.SmartCardSharedCssClassName.LOADER_WRAPPER, _editorSharedStyles.akEditorSelectedNodeClassName, _smartCard.SmartCardSharedCssClassName.LOADER_WRAPPER, (0, _editorSharedStyles.getSelectionStyles)([_editorSharedStyles.SelectionStyle.BoxShadow]), "var(--ds-border-radius-200, 8px)", _smartCard.SmartCardSharedCssClassName.LOADER_WRAPPER, "var(--ds-border-danger, ".concat(_editorSharedStyles.akEditorDeleteBorder, ")"), _smartCard.SmartCardSharedCssClassName.DATASOURCE_CONTAINER, _smartCard.SmartCardSharedCssClassName.BLOCK_CARD_CONTAINER, DATASOURCE_INNER_CONTAINER_CLASSNAME, "var(--ds-background-neutral-subtle, #00000000)", "var(--ds-border-radius-200, 8px)", "var(--ds-border, #091E4224)", _editorSharedStyles.akEditorSelectedNodeClassName, DATASOURCE_INNER_CONTAINER_CLASSNAME, (0, _editorSharedStyles.getSelectionStyles)([_editorSharedStyles.SelectionStyle.BoxShadow]), "var(--ds-background-selected-hovered, #CCE0FF)", "var(--ds-background-selected-hovered, #CCE0FF)", DATASOURCE_INNER_CONTAINER_CLASSNAME, "var(--ds-border-danger, ".concat(_editorSharedStyles.akEditorDeleteBorder, ")"), _smartCard.SmartCardSharedCssClassName.EMBED_CARD_CONTAINER, _smartCard.SmartCardSharedCssClassName.LOADER_WRAPPER, (0, _expValEqualsNoExposure.expValEqualsNoExposure)('platform_editor_find_and_replace_improvements', 'isEnabled', true) && (0, _platformFeatureFlags.fg)('platform_editor_find_and_replace_improvements_1') ? "\n\t\t\t\t&.".concat(_editorSharedStyles.akEditorSelectedNodeClassName, ":not(.search-match-block) .").concat(_smartCard.SmartCardSharedCssClassName.LOADER_WRAPPER, " > div::after {\n\t\t\t\t\t").concat((0, _editorSharedStyles.getSelectionStyles)([_editorSharedStyles.SelectionStyle.BoxShadow]), "\n\t\t\t\t}\n\t\t\t") : "\n\t\t\t\t&.".concat(_editorSharedStyles.akEditorSelectedNodeClassName, " .").concat(_smartCard.SmartCardSharedCssClassName.LOADER_WRAPPER, " > div::after {\n\t\t\t\t\t").concat((0, _editorSharedStyles.getSelectionStyles)([_editorSharedStyles.SelectionStyle.BoxShadow]), "\n\t\t\t\t}\n\t\t\t"), "var(--ds-border-danger, ".concat(_editorSharedStyles.akEditorDeleteBorder, ")"), "var(--ds-background-danger, ".concat(_editorSharedStyles.akEditorDeleteBackground, ")"), "var(--ds-border-danger, ".concat(_editorSharedStyles.akEditorDeleteBorder, ")"), FLOATING_TOOLBAR_LINKPICKER_CLASSNAME);
21
+ return (0, _react.css)(_templateObject || (_templateObject = (0, _taggedTemplateLiteral2.default)(["\n\t.", " {\n\t\tmax-width: calc(100% - 20px);\n\t\tvertical-align: top;\n\t\tword-break: break-all;\n\t\t", "\n\t\t.card {\n\t\t\tpadding-left: ", ";\n\t\t\tpadding-right: ", ";\n\t\t\tpadding-top: 0.5em;\n\t\t\tpadding-bottom: 0.5em;\n\t\t\tmargin-bottom: -0.5em;\n\n\t\t\t.", " > a:focus {\n\t\t\t\t", "\n\t\t\t}\n\t\t}\n\n\t\t", "\n\n\t\t", "\n\t\t.", " > a {\n\t\t\t/* EDM-1717: box-shadow Safari fix start */\n\t\t\tz-index: 1;\n\t\t\tposition: relative;\n\t\t\t/* EDM-1717: box-shadow Safari fix end */\n\t\t}\n\n\t\t&.danger {\n\t\t\t.", " > a {\n\t\t\t\tbox-shadow: 0 0 0 1px ", ";\n\t\t\t\t/* EDM-1717: box-shadow Safari fix start */\n\t\t\t\tz-index: 2;\n\t\t\t\t/* EDM-1717: box-shadow Safari fix end */\n\t\t\t}\n\t\t}\n\t}\n\n\t.", " {\n\t\t.", " > div {\n\t\t\tcursor: pointer;\n\n\t\t\ta {\n\t\t\t\tcursor: auto;\n\t\t\t}\n\t\t}\n\n\t\t&.", " .", " > div {\n\t\t\t", "\n\t\t\tborder-radius: ", ";\n\t\t}\n\n\t\t&.danger {\n\t\t\t.", " > div {\n\t\t\t\tbox-shadow: 0 0 0 1px ", " !important;\n\t\t\t}\n\t\t}\n\t}\n\n\t.", ".", " {\n\t\tmax-width: 100%;\n\t\tdisplay: flex;\n\t\tjustify-content: center;\n\n\t\t.", " {\n\t\t\tcursor: pointer;\n\t\t\tbackground-color: ", ";\n\t\t\tborder-radius: ", ";\n\t\t\tborder: 1px solid ", ";\n\t\t\toverflow: hidden;\n\t\t}\n\n\t\t&.", " {\n\t\t\t.", " {\n\t\t\t\t", "\n\n\t\t\t\tinput::selection {\n\t\t\t\t\tbackground-color: ", ";\n\t\t\t\t}\n\t\t\t\tinput::-moz-selection {\n\t\t\t\t\tbackground-color: ", ";\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\t&.danger {\n\t\t\t.", " {\n\t\t\t\tbox-shadow: 0 0 0 1px ", ";\n\t\t\t}\n\t\t}\n\t}\n\n\t.", " {\n\t\t.", " > div {\n\t\t\tcursor: pointer;\n\t\t\ta {\n\t\t\t\tcursor: auto;\n\t\t\t}\n\t\t\t&::after {\n\t\t\t\ttransition: box-shadow 0s;\n\t\t\t}\n\t\t}\n\n\t\t", "\n\n\t\t&.danger {\n\t\t\t.media-card-frame::after {\n\t\t\t\tbox-shadow: 0 0 0 1px ", " !important;\n\t\t\t\tbackground: ", " !important;\n\t\t\t}\n\t\t\t.richMedia-resize-handle-right::after,\n\t\t\t.richMedia-resize-handle-left::after {\n\t\t\t\tbackground: ", ";\n\t\t\t}\n\t\t}\n\t}\n\n\t.", " {\n\t\tpadding: 0;\n\t}\n"])), _smartCard.SmartCardSharedCssClassName.INLINE_CARD_CONTAINER, (0, _platformFeatureFlags.fg)('editor_inline_comments_on_inline_nodes') ? ".card-with-comment {\n background: ".concat("var(--ds-background-accent-yellow-subtler, #F8E6A0)", ";\n border-bottom: 2px solid ", "var(--ds-border-accent-yellow, #B38600)", ";\n box-shadow: ", "var(--ds-shadow-overlay, 0px 8px 12px #091E4226, 0px 0px 1px #091E424f)", ";\n }") : '', "var(--ds-space-025, 2px)", "var(--ds-space-025, 2px)", _smartCard.SmartCardSharedCssClassName.LOADER_WRAPPER, (0, _editorSharedStyles.getSelectionStyles)([_editorSharedStyles.SelectionStyle.BoxShadow]), (0, _experiments.editorExperiment)('platform_editor_controls', 'variant1') || (0, _expValEqualsNoExposure.expValEqualsNoExposure)('platform_editor_preview_panel_linking_exp', 'isEnabled', true) ? "[data-inlinecard-button-overlay='icon-wrapper-line-height'] span {\n\t\t\t\tline-height: 0;\n\t\t\t}" : '', (0, _expValEqualsNoExposure.expValEqualsNoExposure)('platform_editor_find_and_replace_improvements', 'isEnabled', true) ? "\n\t\t\t\t&.".concat(_editorSharedStyles.akEditorSelectedNodeClassName, ":not(.search-match-block) .").concat(_smartCard.SmartCardSharedCssClassName.LOADER_WRAPPER, " > a {\n\t\t\t\t").concat((0, _editorSharedStyles.getSelectionStyles)([_editorSharedStyles.SelectionStyle.BoxShadow]), "\n\t\t\t}") : "\n\t\t\t\t&.".concat(_editorSharedStyles.akEditorSelectedNodeClassName, " .").concat(_smartCard.SmartCardSharedCssClassName.LOADER_WRAPPER, " > a {\n\t\t\t\t").concat((0, _editorSharedStyles.getSelectionStyles)([_editorSharedStyles.SelectionStyle.BoxShadow]), "\n\t\t\t}"), _smartCard.SmartCardSharedCssClassName.LOADER_WRAPPER, _smartCard.SmartCardSharedCssClassName.LOADER_WRAPPER, "var(--ds-border-danger, ".concat(_editorSharedStyles.akEditorDeleteBorder, ")"), _smartCard.SmartCardSharedCssClassName.BLOCK_CARD_CONTAINER, _smartCard.SmartCardSharedCssClassName.LOADER_WRAPPER, _editorSharedStyles.akEditorSelectedNodeClassName, _smartCard.SmartCardSharedCssClassName.LOADER_WRAPPER, (0, _editorSharedStyles.getSelectionStyles)([_editorSharedStyles.SelectionStyle.BoxShadow]), "var(--ds-border-radius-200, 8px)", _smartCard.SmartCardSharedCssClassName.LOADER_WRAPPER, "var(--ds-border-danger, ".concat(_editorSharedStyles.akEditorDeleteBorder, ")"), _smartCard.SmartCardSharedCssClassName.DATASOURCE_CONTAINER, _smartCard.SmartCardSharedCssClassName.BLOCK_CARD_CONTAINER, DATASOURCE_INNER_CONTAINER_CLASSNAME, "var(--ds-background-neutral-subtle, #00000000)", "var(--ds-border-radius-200, 8px)", "var(--ds-border, #091E4224)", _editorSharedStyles.akEditorSelectedNodeClassName, DATASOURCE_INNER_CONTAINER_CLASSNAME, (0, _editorSharedStyles.getSelectionStyles)([_editorSharedStyles.SelectionStyle.BoxShadow]), "var(--ds-background-selected-hovered, #CCE0FF)", "var(--ds-background-selected-hovered, #CCE0FF)", DATASOURCE_INNER_CONTAINER_CLASSNAME, "var(--ds-border-danger, ".concat(_editorSharedStyles.akEditorDeleteBorder, ")"), _smartCard.SmartCardSharedCssClassName.EMBED_CARD_CONTAINER, _smartCard.SmartCardSharedCssClassName.LOADER_WRAPPER, (0, _expValEqualsNoExposure.expValEqualsNoExposure)('platform_editor_find_and_replace_improvements', 'isEnabled', true) ? "\n\t\t\t\t&.".concat(_editorSharedStyles.akEditorSelectedNodeClassName, ":not(.search-match-block) .").concat(_smartCard.SmartCardSharedCssClassName.LOADER_WRAPPER, " > div::after {\n\t\t\t\t\t").concat((0, _editorSharedStyles.getSelectionStyles)([_editorSharedStyles.SelectionStyle.BoxShadow]), "\n\t\t\t\t}\n\t\t\t") : "\n\t\t\t\t&.".concat(_editorSharedStyles.akEditorSelectedNodeClassName, " .").concat(_smartCard.SmartCardSharedCssClassName.LOADER_WRAPPER, " > div::after {\n\t\t\t\t\t").concat((0, _editorSharedStyles.getSelectionStyles)([_editorSharedStyles.SelectionStyle.BoxShadow]), "\n\t\t\t\t}\n\t\t\t"), "var(--ds-border-danger, ".concat(_editorSharedStyles.akEditorDeleteBorder, ")"), "var(--ds-background-danger, ".concat(_editorSharedStyles.akEditorDeleteBackground, ")"), "var(--ds-border-danger, ".concat(_editorSharedStyles.akEditorDeleteBorder, ")"), FLOATING_TOOLBAR_LINKPICKER_CLASSNAME);
22
22
  };
@@ -24,7 +24,7 @@ function _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.
24
24
  * @jsx jsx
25
25
  */ // eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
26
26
  var packageName = "@atlaskit/editor-common";
27
- var packageVersion = "107.28.1";
27
+ var packageVersion = "107.29.0";
28
28
  var halfFocusRing = 1;
29
29
  var dropOffset = '0, 8';
30
30
  var fadeIn = (0, _react2.keyframes)({
@@ -2,7 +2,12 @@ import { defineMessages } from 'react-intl-next';
2
2
  export const messages = defineMessages({
3
3
  copyBlock: {
4
4
  id: 'fabric.editor.block.menu.copy.block',
5
- defaultMessage: 'Copy Block',
5
+ defaultMessage: 'Copy block',
6
6
  description: 'Copy the selected block to the clipboard'
7
+ },
8
+ deleteBlock: {
9
+ id: 'fabric.editor.block.menu.delete.block',
10
+ defaultMessage: 'Delete',
11
+ description: 'Delete the selected block'
7
12
  }
8
13
  });
@@ -1,16 +1,32 @@
1
1
  /* eslint-disable @atlaskit/platform/ensure-feature-flag-prefix */
2
2
 
3
+ import { expValEquals } from '@atlaskit/tmp-editor-statsig/exp-val-equals';
3
4
  export const defaultWordWrapState = false;
4
5
  export const codeBlockWrappedStates = new WeakMap();
6
+
7
+ // Code folding state management - similar to word wrapping
8
+
9
+ const codeBlockFoldStates = new WeakMap();
5
10
  export const isCodeBlockWordWrapEnabled = codeBlockNode => {
6
11
  const currentNodeWordWrapState = codeBlockWrappedStates.get(codeBlockNode);
7
12
  return currentNodeWordWrapState !== undefined ? currentNodeWordWrapState : defaultWordWrapState;
8
13
  };
14
+ export const getCodeBlockFoldState = codeBlockNode => {
15
+ const currentNodeFoldState = codeBlockFoldStates.get(codeBlockNode);
16
+ return currentNodeFoldState || [];
17
+ };
18
+ export const setCodeBlockFoldState = (codeBlockNode, foldRanges) => {
19
+ codeBlockFoldStates.set(codeBlockNode, foldRanges);
20
+ };
9
21
 
10
22
  /**
11
23
  * Swap the old node key with the new node key in the wrapped states WeakMap.
12
24
  */
13
25
  export const transferCodeBlockWrappedValue = (oldCodeBlockNode, newCodeBlockNode) => {
26
+ if (expValEquals('platform_editor_code_block_fold_gutter', 'isEnabled', true)) {
27
+ transferCodeBlockFoldValue(oldCodeBlockNode, newCodeBlockNode);
28
+ }
29
+
14
30
  // Don't overwrite the value for the new node if it already exists.
15
31
  // This can happen when a drag&drop is swapping nodes.
16
32
  if (codeBlockWrappedStates.has(newCodeBlockNode)) {
@@ -21,6 +37,20 @@ export const transferCodeBlockWrappedValue = (oldCodeBlockNode, newCodeBlockNode
21
37
  codeBlockWrappedStates.delete(oldCodeBlockNode);
22
38
  };
23
39
 
40
+ /**
41
+ * Swap the old node key with the new node key in the fold states WeakMap.
42
+ */
43
+ const transferCodeBlockFoldValue = (oldCodeBlockNode, newCodeBlockNode) => {
44
+ // Don't overwrite the value for the new node if it already exists.
45
+ // This can happen when a drag&drop is swapping nodes.
46
+ if (codeBlockFoldStates.has(newCodeBlockNode)) {
47
+ return;
48
+ }
49
+ const previousValue = getCodeBlockFoldState(oldCodeBlockNode);
50
+ codeBlockFoldStates.set(newCodeBlockNode, previousValue);
51
+ codeBlockFoldStates.delete(oldCodeBlockNode);
52
+ };
53
+
24
54
  /**
25
55
  * As the code block node is used as the wrapped state key, there is instances where the node will be destroyed & recreated and is no longer a valid key.
26
56
  * In these instances, we must get the value from that old node and set it to the value of the new node.
@@ -28,6 +58,9 @@ export const transferCodeBlockWrappedValue = (oldCodeBlockNode, newCodeBlockNode
28
58
  */
29
59
  export const updateCodeBlockWrappedStateNodeKeys = (newCodeBlockNodes, oldState) => {
30
60
  newCodeBlockNodes.forEach(newCodeBlockNode => {
61
+ if (expValEquals('platform_editor_code_block_fold_gutter', 'isEnabled', true)) {
62
+ updateCodeBlockFoldStateNodeKeys(newCodeBlockNode, oldState);
63
+ }
31
64
  // Don't overwrite the value for the new node if it already exists.
32
65
  // This can happen when a drag&drop is swapping nodes.
33
66
  if (codeBlockWrappedStates.has(newCodeBlockNode.node)) {
@@ -45,4 +78,28 @@ export const updateCodeBlockWrappedStateNodeKeys = (newCodeBlockNodes, oldState)
45
78
  const previousValue = isCodeBlockWordWrapEnabled(oldCodeBlockNode);
46
79
  codeBlockWrappedStates.set(newCodeBlockNode.node, previousValue);
47
80
  });
81
+ };
82
+
83
+ /**
84
+ * As the code block node is used as the fold state key, there is instances where the node will be destroyed & recreated and is no longer a valid key.
85
+ * In these instances, we must get the value from that old node and set it to the value of the new node.
86
+ * This function takes all the given nodes, finds their old nodes from the old state and updates these old node keys.
87
+ */
88
+ const updateCodeBlockFoldStateNodeKeys = (newCodeBlockNode, oldState) => {
89
+ // Don't overwrite the value for the new node if it already exists.
90
+ // This can happen when a drag&drop is swapping nodes.
91
+ if (codeBlockFoldStates.has(newCodeBlockNode.node)) {
92
+ return;
93
+ }
94
+
95
+ // Do not go out of range on the oldState doc. Happens on initial load.
96
+ if (oldState.doc.content.size <= newCodeBlockNode.pos) {
97
+ return;
98
+ }
99
+ const oldCodeBlockNode = oldState.doc.nodeAt(newCodeBlockNode.pos);
100
+ if (!oldCodeBlockNode || oldCodeBlockNode.type !== oldState.schema.nodes.codeBlock) {
101
+ return;
102
+ }
103
+ const previousValue = getCodeBlockFoldState(oldCodeBlockNode);
104
+ codeBlockFoldStates.set(newCodeBlockNode.node, previousValue);
48
105
  };
@@ -2,17 +2,17 @@ import { defineMessages } from 'react-intl-next';
2
2
  export const messages = defineMessages({
3
3
  copyBlock: {
4
4
  id: 'fabric.editor.block.menu.copy.block',
5
- defaultMessage: 'Copy Block',
5
+ defaultMessage: 'Copy block',
6
6
  description: 'Copy the selected block to the clipboard'
7
7
  },
8
8
  moveUpBlock: {
9
9
  id: 'fabric.editor.block.menu.move.up',
10
- defaultMessage: 'Move Up',
10
+ defaultMessage: 'Move up',
11
11
  description: 'Move the selected block up'
12
12
  },
13
13
  moveDownBlock: {
14
14
  id: 'fabric.editor.block.menu.move.down',
15
- defaultMessage: 'Move Down',
15
+ defaultMessage: 'Move down',
16
16
  description: 'Move the selected block down'
17
17
  },
18
18
  copyLink: {
@@ -1,7 +1,7 @@
1
1
  import { isFedRamp } from './environment';
2
2
  const SENTRY_DSN = 'https://0b10c8e02fb44d8796c047b102c9bee8@o55978.ingest.sentry.io/4505129224110080';
3
3
  const packageName = 'editor-common'; // Sentry doesn't accept '/' in its releases https://docs.sentry.io/platforms/javascript/configuration/releases/
4
- const packageVersion = "107.28.1";
4
+ const packageVersion = "107.29.0";
5
5
  const sanitiseSentryEvents = (data, _hint) => {
6
6
  // Remove URL as it has UGC
7
7
  // Ignored via go/ees007
@@ -35,7 +35,7 @@ export const smartCardStyles = () => css`
35
35
  line-height: 0;
36
36
  }` : ''}
37
37
 
38
- ${expValEqualsNoExposure('platform_editor_find_and_replace_improvements', 'isEnabled', true) && fg('platform_editor_find_and_replace_improvements_1') ? `
38
+ ${expValEqualsNoExposure('platform_editor_find_and_replace_improvements', 'isEnabled', true) ? `
39
39
  &.${akEditorSelectedNodeClassName}:not(.search-match-block) .${SmartCardSharedCssClassName.LOADER_WRAPPER} > a {
40
40
  ${getSelectionStyles([SelectionStyle.BoxShadow])}
41
41
  }` : `
@@ -124,7 +124,7 @@ export const smartCardStyles = () => css`
124
124
  }
125
125
  }
126
126
 
127
- ${expValEqualsNoExposure('platform_editor_find_and_replace_improvements', 'isEnabled', true) && fg('platform_editor_find_and_replace_improvements_1') ? `
127
+ ${expValEqualsNoExposure('platform_editor_find_and_replace_improvements', 'isEnabled', true) ? `
128
128
  &.${akEditorSelectedNodeClassName}:not(.search-match-block) .${SmartCardSharedCssClassName.LOADER_WRAPPER} > div::after {
129
129
  ${getSelectionStyles([SelectionStyle.BoxShadow])}
130
130
  }
@@ -14,7 +14,7 @@ import withAnalyticsEvents from '@atlaskit/analytics-next/withAnalyticsEvents';
14
14
  import { fg } from '@atlaskit/platform-feature-flags';
15
15
  import Layer from '../Layer';
16
16
  const packageName = "@atlaskit/editor-common";
17
- const packageVersion = "107.28.1";
17
+ const packageVersion = "107.29.0";
18
18
  const halfFocusRing = 1;
19
19
  const dropOffset = '0, 8';
20
20
  const fadeIn = keyframes({
@@ -2,7 +2,12 @@ import { defineMessages } from 'react-intl-next';
2
2
  export var messages = defineMessages({
3
3
  copyBlock: {
4
4
  id: 'fabric.editor.block.menu.copy.block',
5
- defaultMessage: 'Copy Block',
5
+ defaultMessage: 'Copy block',
6
6
  description: 'Copy the selected block to the clipboard'
7
+ },
8
+ deleteBlock: {
9
+ id: 'fabric.editor.block.menu.delete.block',
10
+ defaultMessage: 'Delete',
11
+ description: 'Delete the selected block'
7
12
  }
8
13
  });
@@ -1,16 +1,32 @@
1
1
  /* eslint-disable @atlaskit/platform/ensure-feature-flag-prefix */
2
2
 
3
+ import { expValEquals } from '@atlaskit/tmp-editor-statsig/exp-val-equals';
3
4
  export var defaultWordWrapState = false;
4
5
  export var codeBlockWrappedStates = new WeakMap();
6
+
7
+ // Code folding state management - similar to word wrapping
8
+
9
+ var codeBlockFoldStates = new WeakMap();
5
10
  export var isCodeBlockWordWrapEnabled = function isCodeBlockWordWrapEnabled(codeBlockNode) {
6
11
  var currentNodeWordWrapState = codeBlockWrappedStates.get(codeBlockNode);
7
12
  return currentNodeWordWrapState !== undefined ? currentNodeWordWrapState : defaultWordWrapState;
8
13
  };
14
+ export var getCodeBlockFoldState = function getCodeBlockFoldState(codeBlockNode) {
15
+ var currentNodeFoldState = codeBlockFoldStates.get(codeBlockNode);
16
+ return currentNodeFoldState || [];
17
+ };
18
+ export var setCodeBlockFoldState = function setCodeBlockFoldState(codeBlockNode, foldRanges) {
19
+ codeBlockFoldStates.set(codeBlockNode, foldRanges);
20
+ };
9
21
 
10
22
  /**
11
23
  * Swap the old node key with the new node key in the wrapped states WeakMap.
12
24
  */
13
25
  export var transferCodeBlockWrappedValue = function transferCodeBlockWrappedValue(oldCodeBlockNode, newCodeBlockNode) {
26
+ if (expValEquals('platform_editor_code_block_fold_gutter', 'isEnabled', true)) {
27
+ transferCodeBlockFoldValue(oldCodeBlockNode, newCodeBlockNode);
28
+ }
29
+
14
30
  // Don't overwrite the value for the new node if it already exists.
15
31
  // This can happen when a drag&drop is swapping nodes.
16
32
  if (codeBlockWrappedStates.has(newCodeBlockNode)) {
@@ -21,6 +37,20 @@ export var transferCodeBlockWrappedValue = function transferCodeBlockWrappedValu
21
37
  codeBlockWrappedStates.delete(oldCodeBlockNode);
22
38
  };
23
39
 
40
+ /**
41
+ * Swap the old node key with the new node key in the fold states WeakMap.
42
+ */
43
+ var transferCodeBlockFoldValue = function transferCodeBlockFoldValue(oldCodeBlockNode, newCodeBlockNode) {
44
+ // Don't overwrite the value for the new node if it already exists.
45
+ // This can happen when a drag&drop is swapping nodes.
46
+ if (codeBlockFoldStates.has(newCodeBlockNode)) {
47
+ return;
48
+ }
49
+ var previousValue = getCodeBlockFoldState(oldCodeBlockNode);
50
+ codeBlockFoldStates.set(newCodeBlockNode, previousValue);
51
+ codeBlockFoldStates.delete(oldCodeBlockNode);
52
+ };
53
+
24
54
  /**
25
55
  * As the code block node is used as the wrapped state key, there is instances where the node will be destroyed & recreated and is no longer a valid key.
26
56
  * In these instances, we must get the value from that old node and set it to the value of the new node.
@@ -28,6 +58,9 @@ export var transferCodeBlockWrappedValue = function transferCodeBlockWrappedValu
28
58
  */
29
59
  export var updateCodeBlockWrappedStateNodeKeys = function updateCodeBlockWrappedStateNodeKeys(newCodeBlockNodes, oldState) {
30
60
  newCodeBlockNodes.forEach(function (newCodeBlockNode) {
61
+ if (expValEquals('platform_editor_code_block_fold_gutter', 'isEnabled', true)) {
62
+ updateCodeBlockFoldStateNodeKeys(newCodeBlockNode, oldState);
63
+ }
31
64
  // Don't overwrite the value for the new node if it already exists.
32
65
  // This can happen when a drag&drop is swapping nodes.
33
66
  if (codeBlockWrappedStates.has(newCodeBlockNode.node)) {
@@ -45,4 +78,28 @@ export var updateCodeBlockWrappedStateNodeKeys = function updateCodeBlockWrapped
45
78
  var previousValue = isCodeBlockWordWrapEnabled(oldCodeBlockNode);
46
79
  codeBlockWrappedStates.set(newCodeBlockNode.node, previousValue);
47
80
  });
81
+ };
82
+
83
+ /**
84
+ * As the code block node is used as the fold state key, there is instances where the node will be destroyed & recreated and is no longer a valid key.
85
+ * In these instances, we must get the value from that old node and set it to the value of the new node.
86
+ * This function takes all the given nodes, finds their old nodes from the old state and updates these old node keys.
87
+ */
88
+ var updateCodeBlockFoldStateNodeKeys = function updateCodeBlockFoldStateNodeKeys(newCodeBlockNode, oldState) {
89
+ // Don't overwrite the value for the new node if it already exists.
90
+ // This can happen when a drag&drop is swapping nodes.
91
+ if (codeBlockFoldStates.has(newCodeBlockNode.node)) {
92
+ return;
93
+ }
94
+
95
+ // Do not go out of range on the oldState doc. Happens on initial load.
96
+ if (oldState.doc.content.size <= newCodeBlockNode.pos) {
97
+ return;
98
+ }
99
+ var oldCodeBlockNode = oldState.doc.nodeAt(newCodeBlockNode.pos);
100
+ if (!oldCodeBlockNode || oldCodeBlockNode.type !== oldState.schema.nodes.codeBlock) {
101
+ return;
102
+ }
103
+ var previousValue = getCodeBlockFoldState(oldCodeBlockNode);
104
+ codeBlockFoldStates.set(newCodeBlockNode.node, previousValue);
48
105
  };
@@ -2,17 +2,17 @@ import { defineMessages } from 'react-intl-next';
2
2
  export var messages = defineMessages({
3
3
  copyBlock: {
4
4
  id: 'fabric.editor.block.menu.copy.block',
5
- defaultMessage: 'Copy Block',
5
+ defaultMessage: 'Copy block',
6
6
  description: 'Copy the selected block to the clipboard'
7
7
  },
8
8
  moveUpBlock: {
9
9
  id: 'fabric.editor.block.menu.move.up',
10
- defaultMessage: 'Move Up',
10
+ defaultMessage: 'Move up',
11
11
  description: 'Move the selected block up'
12
12
  },
13
13
  moveDownBlock: {
14
14
  id: 'fabric.editor.block.menu.move.down',
15
- defaultMessage: 'Move Down',
15
+ defaultMessage: 'Move down',
16
16
  description: 'Move the selected block down'
17
17
  },
18
18
  copyLink: {
@@ -7,7 +7,7 @@ function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t =
7
7
  import { isFedRamp } from './environment';
8
8
  var SENTRY_DSN = 'https://0b10c8e02fb44d8796c047b102c9bee8@o55978.ingest.sentry.io/4505129224110080';
9
9
  var packageName = 'editor-common'; // Sentry doesn't accept '/' in its releases https://docs.sentry.io/platforms/javascript/configuration/releases/
10
- var packageVersion = "107.28.1";
10
+ var packageVersion = "107.29.0";
11
11
  var sanitiseSentryEvents = function sanitiseSentryEvents(data, _hint) {
12
12
  // Remove URL as it has UGC
13
13
  // Ignored via go/ees007
@@ -12,5 +12,5 @@ export var FLOATING_TOOLBAR_LINKPICKER_CLASSNAME = 'card-floating-toolbar--link-
12
12
 
13
13
  // eslint-disable-next-line @atlaskit/design-system/no-css-tagged-template-expression, @atlaskit/ui-styling-standard/no-exported-styles -- Ignored via go/DSP-18766
14
14
  export var smartCardStyles = function smartCardStyles() {
15
- return css(_templateObject || (_templateObject = _taggedTemplateLiteral(["\n\t.", " {\n\t\tmax-width: calc(100% - 20px);\n\t\tvertical-align: top;\n\t\tword-break: break-all;\n\t\t", "\n\t\t.card {\n\t\t\tpadding-left: ", ";\n\t\t\tpadding-right: ", ";\n\t\t\tpadding-top: 0.5em;\n\t\t\tpadding-bottom: 0.5em;\n\t\t\tmargin-bottom: -0.5em;\n\n\t\t\t.", " > a:focus {\n\t\t\t\t", "\n\t\t\t}\n\t\t}\n\n\t\t", "\n\n\t\t", "\n\t\t.", " > a {\n\t\t\t/* EDM-1717: box-shadow Safari fix start */\n\t\t\tz-index: 1;\n\t\t\tposition: relative;\n\t\t\t/* EDM-1717: box-shadow Safari fix end */\n\t\t}\n\n\t\t&.danger {\n\t\t\t.", " > a {\n\t\t\t\tbox-shadow: 0 0 0 1px ", ";\n\t\t\t\t/* EDM-1717: box-shadow Safari fix start */\n\t\t\t\tz-index: 2;\n\t\t\t\t/* EDM-1717: box-shadow Safari fix end */\n\t\t\t}\n\t\t}\n\t}\n\n\t.", " {\n\t\t.", " > div {\n\t\t\tcursor: pointer;\n\n\t\t\ta {\n\t\t\t\tcursor: auto;\n\t\t\t}\n\t\t}\n\n\t\t&.", " .", " > div {\n\t\t\t", "\n\t\t\tborder-radius: ", ";\n\t\t}\n\n\t\t&.danger {\n\t\t\t.", " > div {\n\t\t\t\tbox-shadow: 0 0 0 1px ", " !important;\n\t\t\t}\n\t\t}\n\t}\n\n\t.", ".", " {\n\t\tmax-width: 100%;\n\t\tdisplay: flex;\n\t\tjustify-content: center;\n\n\t\t.", " {\n\t\t\tcursor: pointer;\n\t\t\tbackground-color: ", ";\n\t\t\tborder-radius: ", ";\n\t\t\tborder: 1px solid ", ";\n\t\t\toverflow: hidden;\n\t\t}\n\n\t\t&.", " {\n\t\t\t.", " {\n\t\t\t\t", "\n\n\t\t\t\tinput::selection {\n\t\t\t\t\tbackground-color: ", ";\n\t\t\t\t}\n\t\t\t\tinput::-moz-selection {\n\t\t\t\t\tbackground-color: ", ";\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\t&.danger {\n\t\t\t.", " {\n\t\t\t\tbox-shadow: 0 0 0 1px ", ";\n\t\t\t}\n\t\t}\n\t}\n\n\t.", " {\n\t\t.", " > div {\n\t\t\tcursor: pointer;\n\t\t\ta {\n\t\t\t\tcursor: auto;\n\t\t\t}\n\t\t\t&::after {\n\t\t\t\ttransition: box-shadow 0s;\n\t\t\t}\n\t\t}\n\n\t\t", "\n\n\t\t&.danger {\n\t\t\t.media-card-frame::after {\n\t\t\t\tbox-shadow: 0 0 0 1px ", " !important;\n\t\t\t\tbackground: ", " !important;\n\t\t\t}\n\t\t\t.richMedia-resize-handle-right::after,\n\t\t\t.richMedia-resize-handle-left::after {\n\t\t\t\tbackground: ", ";\n\t\t\t}\n\t\t}\n\t}\n\n\t.", " {\n\t\tpadding: 0;\n\t}\n"])), SmartCardSharedCssClassName.INLINE_CARD_CONTAINER, fg('editor_inline_comments_on_inline_nodes') ? ".card-with-comment {\n background: ".concat("var(--ds-background-accent-yellow-subtler, #F8E6A0)", ";\n border-bottom: 2px solid ", "var(--ds-border-accent-yellow, #B38600)", ";\n box-shadow: ", "var(--ds-shadow-overlay, 0px 8px 12px #091E4226, 0px 0px 1px #091E424f)", ";\n }") : '', "var(--ds-space-025, 2px)", "var(--ds-space-025, 2px)", SmartCardSharedCssClassName.LOADER_WRAPPER, getSelectionStyles([SelectionStyle.BoxShadow]), editorExperiment('platform_editor_controls', 'variant1') || expValEqualsNoExposure('platform_editor_preview_panel_linking_exp', 'isEnabled', true) ? "[data-inlinecard-button-overlay='icon-wrapper-line-height'] span {\n\t\t\t\tline-height: 0;\n\t\t\t}" : '', expValEqualsNoExposure('platform_editor_find_and_replace_improvements', 'isEnabled', true) && fg('platform_editor_find_and_replace_improvements_1') ? "\n\t\t\t\t&.".concat(akEditorSelectedNodeClassName, ":not(.search-match-block) .").concat(SmartCardSharedCssClassName.LOADER_WRAPPER, " > a {\n\t\t\t\t").concat(getSelectionStyles([SelectionStyle.BoxShadow]), "\n\t\t\t}") : "\n\t\t\t\t&.".concat(akEditorSelectedNodeClassName, " .").concat(SmartCardSharedCssClassName.LOADER_WRAPPER, " > a {\n\t\t\t\t").concat(getSelectionStyles([SelectionStyle.BoxShadow]), "\n\t\t\t}"), SmartCardSharedCssClassName.LOADER_WRAPPER, SmartCardSharedCssClassName.LOADER_WRAPPER, "var(--ds-border-danger, ".concat(akEditorDeleteBorder, ")"), SmartCardSharedCssClassName.BLOCK_CARD_CONTAINER, SmartCardSharedCssClassName.LOADER_WRAPPER, akEditorSelectedNodeClassName, SmartCardSharedCssClassName.LOADER_WRAPPER, getSelectionStyles([SelectionStyle.BoxShadow]), "var(--ds-border-radius-200, 8px)", SmartCardSharedCssClassName.LOADER_WRAPPER, "var(--ds-border-danger, ".concat(akEditorDeleteBorder, ")"), SmartCardSharedCssClassName.DATASOURCE_CONTAINER, SmartCardSharedCssClassName.BLOCK_CARD_CONTAINER, DATASOURCE_INNER_CONTAINER_CLASSNAME, "var(--ds-background-neutral-subtle, #00000000)", "var(--ds-border-radius-200, 8px)", "var(--ds-border, #091E4224)", akEditorSelectedNodeClassName, DATASOURCE_INNER_CONTAINER_CLASSNAME, getSelectionStyles([SelectionStyle.BoxShadow]), "var(--ds-background-selected-hovered, #CCE0FF)", "var(--ds-background-selected-hovered, #CCE0FF)", DATASOURCE_INNER_CONTAINER_CLASSNAME, "var(--ds-border-danger, ".concat(akEditorDeleteBorder, ")"), SmartCardSharedCssClassName.EMBED_CARD_CONTAINER, SmartCardSharedCssClassName.LOADER_WRAPPER, expValEqualsNoExposure('platform_editor_find_and_replace_improvements', 'isEnabled', true) && fg('platform_editor_find_and_replace_improvements_1') ? "\n\t\t\t\t&.".concat(akEditorSelectedNodeClassName, ":not(.search-match-block) .").concat(SmartCardSharedCssClassName.LOADER_WRAPPER, " > div::after {\n\t\t\t\t\t").concat(getSelectionStyles([SelectionStyle.BoxShadow]), "\n\t\t\t\t}\n\t\t\t") : "\n\t\t\t\t&.".concat(akEditorSelectedNodeClassName, " .").concat(SmartCardSharedCssClassName.LOADER_WRAPPER, " > div::after {\n\t\t\t\t\t").concat(getSelectionStyles([SelectionStyle.BoxShadow]), "\n\t\t\t\t}\n\t\t\t"), "var(--ds-border-danger, ".concat(akEditorDeleteBorder, ")"), "var(--ds-background-danger, ".concat(akEditorDeleteBackground, ")"), "var(--ds-border-danger, ".concat(akEditorDeleteBorder, ")"), FLOATING_TOOLBAR_LINKPICKER_CLASSNAME);
15
+ return css(_templateObject || (_templateObject = _taggedTemplateLiteral(["\n\t.", " {\n\t\tmax-width: calc(100% - 20px);\n\t\tvertical-align: top;\n\t\tword-break: break-all;\n\t\t", "\n\t\t.card {\n\t\t\tpadding-left: ", ";\n\t\t\tpadding-right: ", ";\n\t\t\tpadding-top: 0.5em;\n\t\t\tpadding-bottom: 0.5em;\n\t\t\tmargin-bottom: -0.5em;\n\n\t\t\t.", " > a:focus {\n\t\t\t\t", "\n\t\t\t}\n\t\t}\n\n\t\t", "\n\n\t\t", "\n\t\t.", " > a {\n\t\t\t/* EDM-1717: box-shadow Safari fix start */\n\t\t\tz-index: 1;\n\t\t\tposition: relative;\n\t\t\t/* EDM-1717: box-shadow Safari fix end */\n\t\t}\n\n\t\t&.danger {\n\t\t\t.", " > a {\n\t\t\t\tbox-shadow: 0 0 0 1px ", ";\n\t\t\t\t/* EDM-1717: box-shadow Safari fix start */\n\t\t\t\tz-index: 2;\n\t\t\t\t/* EDM-1717: box-shadow Safari fix end */\n\t\t\t}\n\t\t}\n\t}\n\n\t.", " {\n\t\t.", " > div {\n\t\t\tcursor: pointer;\n\n\t\t\ta {\n\t\t\t\tcursor: auto;\n\t\t\t}\n\t\t}\n\n\t\t&.", " .", " > div {\n\t\t\t", "\n\t\t\tborder-radius: ", ";\n\t\t}\n\n\t\t&.danger {\n\t\t\t.", " > div {\n\t\t\t\tbox-shadow: 0 0 0 1px ", " !important;\n\t\t\t}\n\t\t}\n\t}\n\n\t.", ".", " {\n\t\tmax-width: 100%;\n\t\tdisplay: flex;\n\t\tjustify-content: center;\n\n\t\t.", " {\n\t\t\tcursor: pointer;\n\t\t\tbackground-color: ", ";\n\t\t\tborder-radius: ", ";\n\t\t\tborder: 1px solid ", ";\n\t\t\toverflow: hidden;\n\t\t}\n\n\t\t&.", " {\n\t\t\t.", " {\n\t\t\t\t", "\n\n\t\t\t\tinput::selection {\n\t\t\t\t\tbackground-color: ", ";\n\t\t\t\t}\n\t\t\t\tinput::-moz-selection {\n\t\t\t\t\tbackground-color: ", ";\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\t&.danger {\n\t\t\t.", " {\n\t\t\t\tbox-shadow: 0 0 0 1px ", ";\n\t\t\t}\n\t\t}\n\t}\n\n\t.", " {\n\t\t.", " > div {\n\t\t\tcursor: pointer;\n\t\t\ta {\n\t\t\t\tcursor: auto;\n\t\t\t}\n\t\t\t&::after {\n\t\t\t\ttransition: box-shadow 0s;\n\t\t\t}\n\t\t}\n\n\t\t", "\n\n\t\t&.danger {\n\t\t\t.media-card-frame::after {\n\t\t\t\tbox-shadow: 0 0 0 1px ", " !important;\n\t\t\t\tbackground: ", " !important;\n\t\t\t}\n\t\t\t.richMedia-resize-handle-right::after,\n\t\t\t.richMedia-resize-handle-left::after {\n\t\t\t\tbackground: ", ";\n\t\t\t}\n\t\t}\n\t}\n\n\t.", " {\n\t\tpadding: 0;\n\t}\n"])), SmartCardSharedCssClassName.INLINE_CARD_CONTAINER, fg('editor_inline_comments_on_inline_nodes') ? ".card-with-comment {\n background: ".concat("var(--ds-background-accent-yellow-subtler, #F8E6A0)", ";\n border-bottom: 2px solid ", "var(--ds-border-accent-yellow, #B38600)", ";\n box-shadow: ", "var(--ds-shadow-overlay, 0px 8px 12px #091E4226, 0px 0px 1px #091E424f)", ";\n }") : '', "var(--ds-space-025, 2px)", "var(--ds-space-025, 2px)", SmartCardSharedCssClassName.LOADER_WRAPPER, getSelectionStyles([SelectionStyle.BoxShadow]), editorExperiment('platform_editor_controls', 'variant1') || expValEqualsNoExposure('platform_editor_preview_panel_linking_exp', 'isEnabled', true) ? "[data-inlinecard-button-overlay='icon-wrapper-line-height'] span {\n\t\t\t\tline-height: 0;\n\t\t\t}" : '', expValEqualsNoExposure('platform_editor_find_and_replace_improvements', 'isEnabled', true) ? "\n\t\t\t\t&.".concat(akEditorSelectedNodeClassName, ":not(.search-match-block) .").concat(SmartCardSharedCssClassName.LOADER_WRAPPER, " > a {\n\t\t\t\t").concat(getSelectionStyles([SelectionStyle.BoxShadow]), "\n\t\t\t}") : "\n\t\t\t\t&.".concat(akEditorSelectedNodeClassName, " .").concat(SmartCardSharedCssClassName.LOADER_WRAPPER, " > a {\n\t\t\t\t").concat(getSelectionStyles([SelectionStyle.BoxShadow]), "\n\t\t\t}"), SmartCardSharedCssClassName.LOADER_WRAPPER, SmartCardSharedCssClassName.LOADER_WRAPPER, "var(--ds-border-danger, ".concat(akEditorDeleteBorder, ")"), SmartCardSharedCssClassName.BLOCK_CARD_CONTAINER, SmartCardSharedCssClassName.LOADER_WRAPPER, akEditorSelectedNodeClassName, SmartCardSharedCssClassName.LOADER_WRAPPER, getSelectionStyles([SelectionStyle.BoxShadow]), "var(--ds-border-radius-200, 8px)", SmartCardSharedCssClassName.LOADER_WRAPPER, "var(--ds-border-danger, ".concat(akEditorDeleteBorder, ")"), SmartCardSharedCssClassName.DATASOURCE_CONTAINER, SmartCardSharedCssClassName.BLOCK_CARD_CONTAINER, DATASOURCE_INNER_CONTAINER_CLASSNAME, "var(--ds-background-neutral-subtle, #00000000)", "var(--ds-border-radius-200, 8px)", "var(--ds-border, #091E4224)", akEditorSelectedNodeClassName, DATASOURCE_INNER_CONTAINER_CLASSNAME, getSelectionStyles([SelectionStyle.BoxShadow]), "var(--ds-background-selected-hovered, #CCE0FF)", "var(--ds-background-selected-hovered, #CCE0FF)", DATASOURCE_INNER_CONTAINER_CLASSNAME, "var(--ds-border-danger, ".concat(akEditorDeleteBorder, ")"), SmartCardSharedCssClassName.EMBED_CARD_CONTAINER, SmartCardSharedCssClassName.LOADER_WRAPPER, expValEqualsNoExposure('platform_editor_find_and_replace_improvements', 'isEnabled', true) ? "\n\t\t\t\t&.".concat(akEditorSelectedNodeClassName, ":not(.search-match-block) .").concat(SmartCardSharedCssClassName.LOADER_WRAPPER, " > div::after {\n\t\t\t\t\t").concat(getSelectionStyles([SelectionStyle.BoxShadow]), "\n\t\t\t\t}\n\t\t\t") : "\n\t\t\t\t&.".concat(akEditorSelectedNodeClassName, " .").concat(SmartCardSharedCssClassName.LOADER_WRAPPER, " > div::after {\n\t\t\t\t\t").concat(getSelectionStyles([SelectionStyle.BoxShadow]), "\n\t\t\t\t}\n\t\t\t"), "var(--ds-border-danger, ".concat(akEditorDeleteBorder, ")"), "var(--ds-background-danger, ".concat(akEditorDeleteBackground, ")"), "var(--ds-border-danger, ".concat(akEditorDeleteBorder, ")"), FLOATING_TOOLBAR_LINKPICKER_CLASSNAME);
16
16
  };
@@ -21,7 +21,7 @@ import withAnalyticsEvents from '@atlaskit/analytics-next/withAnalyticsEvents';
21
21
  import { fg } from '@atlaskit/platform-feature-flags';
22
22
  import Layer from '../Layer';
23
23
  var packageName = "@atlaskit/editor-common";
24
- var packageVersion = "107.28.1";
24
+ var packageVersion = "107.29.0";
25
25
  var halfFocusRing = 1;
26
26
  var dropOffset = '0, 8';
27
27
  var fadeIn = keyframes({
@@ -1,10 +1,10 @@
1
1
  import type { Transaction, Selection } from '@atlaskit/editor-prosemirror/state';
2
2
  import type { AnalyticsEventPayload } from './types/events';
3
3
  export type FireAnalyticsEventOptions = {
4
- immediate?: boolean;
5
4
  context?: {
6
5
  selection: Selection;
7
6
  };
7
+ immediate?: boolean;
8
8
  };
9
9
  export type EditorAnalyticsAPI = {
10
10
  /**
@@ -13,7 +13,7 @@ export type EditorAnalyticsAPI = {
13
13
  * @param {AnalyticsEventPayload} payload - analytics payload
14
14
  * @param {string} [channel="editor"] - optional channel identifier
15
15
  * @param {Transaction} tr - a transaction
16
- * @return {boolean} true if submitted successful, false if not submitted
16
+ * @returns {boolean} true if submitted successful, false if not submitted
17
17
  */
18
18
  attachAnalyticsEvent: (payload: AnalyticsEventPayload, channel?: string) => (tr: Transaction) => boolean;
19
19
  /**