@atlaskit/editor-common 80.5.2 → 81.0.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 (237) hide show
  1. package/CHANGELOG.md +15 -0
  2. package/afm-cc/tsconfig.json +0 -3
  3. package/dist/cjs/monitoring/error.js +1 -1
  4. package/dist/cjs/ui/DropList/index.js +1 -1
  5. package/dist/es2019/monitoring/error.js +1 -1
  6. package/dist/es2019/ui/DropList/index.js +1 -1
  7. package/dist/esm/monitoring/error.js +1 -1
  8. package/dist/esm/ui/DropList/index.js +1 -1
  9. package/dist/types/analytics/types/avatar.d.ts +2 -2
  10. package/dist/types/analytics/types/config-panel-events.d.ts +2 -2
  11. package/dist/types/analytics/types/date-events.d.ts +2 -2
  12. package/dist/types/analytics/types/dispatch-analytics-event.d.ts +1 -1
  13. package/dist/types/analytics/types/experimental-events.d.ts +2 -2
  14. package/dist/types/card/link-toolbar-button-group-options.d.ts +1 -1
  15. package/dist/types/extensions/extension-fields-helpers.d.ts +2 -2
  16. package/dist/types/extensions/types/extension-manifest-common.d.ts +1 -1
  17. package/dist/types/extensions/types/extension-provider.d.ts +2 -2
  18. package/dist/types/link/LinkPicker/EditorLinkPicker/index.d.ts +2 -2
  19. package/dist/types/link/LinkSearch/index.d.ts +2 -2
  20. package/dist/types/link/LinkSearch/transformTimeStamp.d.ts +1 -1
  21. package/dist/types/link/LinkSearch/types.d.ts +3 -3
  22. package/dist/types/link/LinkSearch/withActivityProvider.d.ts +2 -2
  23. package/dist/types/link/types.d.ts +2 -2
  24. package/dist/types/provider-factory/context.d.ts +1 -1
  25. package/dist/types/provider-factory/profile-card-provider.d.ts +1 -1
  26. package/dist/types/provider-factory/provider-factory.d.ts +1 -1
  27. package/dist/types/provider-factory/with-providers.d.ts +3 -3
  28. package/dist/types/transforms/layout.d.ts +1 -1
  29. package/dist/types/types/copy-button.d.ts +1 -1
  30. package/dist/types/types/resizable-media-single.d.ts +1 -1
  31. package/dist/types/types/type-ahead.d.ts +1 -1
  32. package/dist/types/ufo/experience-store.d.ts +1 -1
  33. package/dist/types/ui/EventHandlers/index.d.ts +1 -1
  34. package/dist/types/ui/Layer/index.d.ts +2 -2
  35. package/dist/types/ui/Mention/index.d.ts +2 -2
  36. package/dist/types/ui/Mention/types.d.ts +1 -1
  37. package/dist/types/ui/ResizerLegacy/styled.d.ts +1 -1
  38. package/dist/types/ui/ResizerLegacy/types.d.ts +3 -3
  39. package/dist/types/ui/WithCreateAnalyticsEvent/index.d.ts +1 -1
  40. package/dist/types/ui/unsupported-content-helper.d.ts +2 -2
  41. package/dist/types/ui-color/ColorPalette/Palettes/borderColorPalette.d.ts +1 -1
  42. package/dist/types/ui-color/ColorPalette/Palettes/cellBackgroundColorPalette.d.ts +1 -1
  43. package/dist/types/ui-color/ColorPalette/Palettes/getColorMessage.d.ts +1 -1
  44. package/dist/types/ui-color/ColorPalette/Palettes/panelBackgroundPalette.d.ts +1 -1
  45. package/dist/types/ui-color/ColorPalette/Palettes/type.d.ts +1 -1
  46. package/dist/types/ui-menu/ToolbarButton/styles.d.ts +1 -1
  47. package/dist/types/ui-react/ReactEditorViewContext.d.ts +1 -1
  48. package/dist/types/utils/analytics.d.ts +1 -1
  49. package/dist/types/utils/commands.d.ts +3 -3
  50. package/dist/types/utils/compareNodes.d.ts +2 -2
  51. package/dist/types/utils/get-performance-options.d.ts +1 -1
  52. package/dist/types/utils/imageLoader.d.ts +1 -1
  53. package/dist/types/utils/macro.d.ts +1 -1
  54. package/dist/types/utils/performance/hooks/use-component-render-tracking/index.d.ts +1 -1
  55. package/dist/types/utils/plugin-state-factory.d.ts +2 -2
  56. package/dist/types/utils/slice.d.ts +1 -1
  57. package/dist/types-ts4.5/analytics/types/avatar.d.ts +2 -2
  58. package/dist/types-ts4.5/analytics/types/config-panel-events.d.ts +2 -2
  59. package/dist/types-ts4.5/analytics/types/date-events.d.ts +2 -2
  60. package/dist/types-ts4.5/analytics/types/dispatch-analytics-event.d.ts +1 -1
  61. package/dist/types-ts4.5/analytics/types/experimental-events.d.ts +2 -2
  62. package/dist/types-ts4.5/card/link-toolbar-button-group-options.d.ts +1 -1
  63. package/dist/types-ts4.5/extensions/extension-fields-helpers.d.ts +2 -2
  64. package/dist/types-ts4.5/extensions/types/extension-manifest-common.d.ts +1 -1
  65. package/dist/types-ts4.5/extensions/types/extension-provider.d.ts +2 -2
  66. package/dist/types-ts4.5/link/LinkPicker/EditorLinkPicker/index.d.ts +2 -2
  67. package/dist/types-ts4.5/link/LinkSearch/index.d.ts +2 -2
  68. package/dist/types-ts4.5/link/LinkSearch/transformTimeStamp.d.ts +1 -1
  69. package/dist/types-ts4.5/link/LinkSearch/types.d.ts +3 -3
  70. package/dist/types-ts4.5/link/LinkSearch/withActivityProvider.d.ts +2 -2
  71. package/dist/types-ts4.5/link/types.d.ts +2 -2
  72. package/dist/types-ts4.5/provider-factory/context.d.ts +1 -1
  73. package/dist/types-ts4.5/provider-factory/profile-card-provider.d.ts +1 -1
  74. package/dist/types-ts4.5/provider-factory/provider-factory.d.ts +1 -1
  75. package/dist/types-ts4.5/provider-factory/with-providers.d.ts +3 -3
  76. package/dist/types-ts4.5/transforms/layout.d.ts +1 -1
  77. package/dist/types-ts4.5/types/copy-button.d.ts +1 -1
  78. package/dist/types-ts4.5/types/resizable-media-single.d.ts +1 -1
  79. package/dist/types-ts4.5/types/type-ahead.d.ts +1 -1
  80. package/dist/types-ts4.5/ufo/experience-store.d.ts +1 -1
  81. package/dist/types-ts4.5/ui/EventHandlers/index.d.ts +1 -1
  82. package/dist/types-ts4.5/ui/Layer/index.d.ts +2 -2
  83. package/dist/types-ts4.5/ui/Mention/index.d.ts +2 -2
  84. package/dist/types-ts4.5/ui/Mention/types.d.ts +1 -1
  85. package/dist/types-ts4.5/ui/ResizerLegacy/styled.d.ts +1 -1
  86. package/dist/types-ts4.5/ui/ResizerLegacy/types.d.ts +3 -3
  87. package/dist/types-ts4.5/ui/WithCreateAnalyticsEvent/index.d.ts +1 -1
  88. package/dist/types-ts4.5/ui/unsupported-content-helper.d.ts +2 -2
  89. package/dist/types-ts4.5/ui-color/ColorPalette/Palettes/borderColorPalette.d.ts +1 -1
  90. package/dist/types-ts4.5/ui-color/ColorPalette/Palettes/cellBackgroundColorPalette.d.ts +1 -1
  91. package/dist/types-ts4.5/ui-color/ColorPalette/Palettes/getColorMessage.d.ts +1 -1
  92. package/dist/types-ts4.5/ui-color/ColorPalette/Palettes/panelBackgroundPalette.d.ts +1 -1
  93. package/dist/types-ts4.5/ui-color/ColorPalette/Palettes/type.d.ts +1 -1
  94. package/dist/types-ts4.5/ui-menu/ToolbarButton/styles.d.ts +1 -1
  95. package/dist/types-ts4.5/ui-react/ReactEditorViewContext.d.ts +1 -1
  96. package/dist/types-ts4.5/utils/analytics.d.ts +1 -1
  97. package/dist/types-ts4.5/utils/commands.d.ts +3 -3
  98. package/dist/types-ts4.5/utils/compareNodes.d.ts +2 -2
  99. package/dist/types-ts4.5/utils/get-performance-options.d.ts +1 -1
  100. package/dist/types-ts4.5/utils/imageLoader.d.ts +1 -1
  101. package/dist/types-ts4.5/utils/macro.d.ts +1 -1
  102. package/dist/types-ts4.5/utils/performance/hooks/use-component-render-tracking/index.d.ts +1 -1
  103. package/dist/types-ts4.5/utils/plugin-state-factory.d.ts +2 -2
  104. package/dist/types-ts4.5/utils/slice.d.ts +1 -1
  105. package/package.json +3 -5
  106. package/tsconfig.json +0 -1
  107. package/dist/cjs/__tests_external__/cases/fundamentals/collection.js +0 -15
  108. package/dist/cjs/__tests_external__/cases/fundamentals/test-cases/editor-is-present.js +0 -20
  109. package/dist/cjs/__tests_external__/cases/fundamentals/test-cases/editor-typing.js +0 -28
  110. package/dist/cjs/__tests_external__/cases/smart-links/index.js +0 -33
  111. package/dist/cjs/__tests_external__/cases/smart-links/test-cases/block/delete.js +0 -35
  112. package/dist/cjs/__tests_external__/cases/smart-links/test-cases/block/edit.js +0 -65
  113. package/dist/cjs/__tests_external__/cases/smart-links/test-cases/block/index.js +0 -16
  114. package/dist/cjs/__tests_external__/cases/smart-links/test-cases/block/insert.js +0 -34
  115. package/dist/cjs/__tests_external__/cases/smart-links/test-cases/embed/delete.js +0 -35
  116. package/dist/cjs/__tests_external__/cases/smart-links/test-cases/embed/edit.js +0 -65
  117. package/dist/cjs/__tests_external__/cases/smart-links/test-cases/embed/index.js +0 -16
  118. package/dist/cjs/__tests_external__/cases/smart-links/test-cases/embed/insert.js +0 -34
  119. package/dist/cjs/__tests_external__/cases/smart-links/test-cases/inline/delete.js +0 -34
  120. package/dist/cjs/__tests_external__/cases/smart-links/test-cases/inline/edit.js +0 -63
  121. package/dist/cjs/__tests_external__/cases/smart-links/test-cases/inline/index.js +0 -17
  122. package/dist/cjs/__tests_external__/cases/smart-links/test-cases/inline/insert.js +0 -33
  123. package/dist/cjs/__tests_external__/cases/smart-links/test-cases/inline/unlink.js +0 -36
  124. package/dist/cjs/__tests_external__/cases/smart-links/test-cases/types.js +0 -5
  125. package/dist/cjs/__tests_external__/cases/smart-links/test-cases/url/index.js +0 -14
  126. package/dist/cjs/__tests_external__/cases/smart-links/test-cases/url/insert.js +0 -31
  127. package/dist/cjs/__tests_external__/cases/types.js +0 -5
  128. package/dist/cjs/__tests_external__/index.js +0 -44
  129. package/dist/cjs/__tests_external__/page-objects/Editor.js +0 -47
  130. package/dist/cjs/__tests_external__/page-objects/EditorSmartLink.js +0 -208
  131. package/dist/cjs/__tests_external__/page-objects/Renderer.js +0 -35
  132. package/dist/cjs/in-product.js +0 -42
  133. package/dist/es2019/__tests_external__/cases/fundamentals/collection.js +0 -7
  134. package/dist/es2019/__tests_external__/cases/fundamentals/test-cases/editor-is-present.js +0 -12
  135. package/dist/es2019/__tests_external__/cases/fundamentals/test-cases/editor-typing.js +0 -22
  136. package/dist/es2019/__tests_external__/cases/smart-links/index.js +0 -4
  137. package/dist/es2019/__tests_external__/cases/smart-links/test-cases/block/delete.js +0 -28
  138. package/dist/es2019/__tests_external__/cases/smart-links/test-cases/block/edit.js +0 -57
  139. package/dist/es2019/__tests_external__/cases/smart-links/test-cases/block/index.js +0 -8
  140. package/dist/es2019/__tests_external__/cases/smart-links/test-cases/block/insert.js +0 -27
  141. package/dist/es2019/__tests_external__/cases/smart-links/test-cases/embed/delete.js +0 -28
  142. package/dist/es2019/__tests_external__/cases/smart-links/test-cases/embed/edit.js +0 -57
  143. package/dist/es2019/__tests_external__/cases/smart-links/test-cases/embed/index.js +0 -8
  144. package/dist/es2019/__tests_external__/cases/smart-links/test-cases/embed/insert.js +0 -27
  145. package/dist/es2019/__tests_external__/cases/smart-links/test-cases/inline/delete.js +0 -27
  146. package/dist/es2019/__tests_external__/cases/smart-links/test-cases/inline/edit.js +0 -55
  147. package/dist/es2019/__tests_external__/cases/smart-links/test-cases/inline/index.js +0 -9
  148. package/dist/es2019/__tests_external__/cases/smart-links/test-cases/inline/insert.js +0 -26
  149. package/dist/es2019/__tests_external__/cases/smart-links/test-cases/inline/unlink.js +0 -29
  150. package/dist/es2019/__tests_external__/cases/smart-links/test-cases/types.js +0 -1
  151. package/dist/es2019/__tests_external__/cases/smart-links/test-cases/url/index.js +0 -6
  152. package/dist/es2019/__tests_external__/cases/smart-links/test-cases/url/insert.js +0 -24
  153. package/dist/es2019/__tests_external__/cases/types.js +0 -1
  154. package/dist/es2019/__tests_external__/index.js +0 -3
  155. package/dist/es2019/__tests_external__/page-objects/Editor.js +0 -19
  156. package/dist/es2019/__tests_external__/page-objects/EditorSmartLink.js +0 -143
  157. package/dist/es2019/__tests_external__/page-objects/Renderer.js +0 -9
  158. package/dist/es2019/in-product.js +0 -1
  159. package/dist/esm/__tests_external__/cases/fundamentals/collection.js +0 -9
  160. package/dist/esm/__tests_external__/cases/fundamentals/test-cases/editor-is-present.js +0 -14
  161. package/dist/esm/__tests_external__/cases/fundamentals/test-cases/editor-typing.js +0 -22
  162. package/dist/esm/__tests_external__/cases/smart-links/index.js +0 -4
  163. package/dist/esm/__tests_external__/cases/smart-links/test-cases/block/delete.js +0 -29
  164. package/dist/esm/__tests_external__/cases/smart-links/test-cases/block/edit.js +0 -59
  165. package/dist/esm/__tests_external__/cases/smart-links/test-cases/block/index.js +0 -10
  166. package/dist/esm/__tests_external__/cases/smart-links/test-cases/block/insert.js +0 -28
  167. package/dist/esm/__tests_external__/cases/smart-links/test-cases/embed/delete.js +0 -29
  168. package/dist/esm/__tests_external__/cases/smart-links/test-cases/embed/edit.js +0 -59
  169. package/dist/esm/__tests_external__/cases/smart-links/test-cases/embed/index.js +0 -10
  170. package/dist/esm/__tests_external__/cases/smart-links/test-cases/embed/insert.js +0 -28
  171. package/dist/esm/__tests_external__/cases/smart-links/test-cases/inline/delete.js +0 -28
  172. package/dist/esm/__tests_external__/cases/smart-links/test-cases/inline/edit.js +0 -57
  173. package/dist/esm/__tests_external__/cases/smart-links/test-cases/inline/index.js +0 -11
  174. package/dist/esm/__tests_external__/cases/smart-links/test-cases/inline/insert.js +0 -27
  175. package/dist/esm/__tests_external__/cases/smart-links/test-cases/inline/unlink.js +0 -30
  176. package/dist/esm/__tests_external__/cases/smart-links/test-cases/types.js +0 -1
  177. package/dist/esm/__tests_external__/cases/smart-links/test-cases/url/index.js +0 -8
  178. package/dist/esm/__tests_external__/cases/smart-links/test-cases/url/insert.js +0 -25
  179. package/dist/esm/__tests_external__/cases/types.js +0 -1
  180. package/dist/esm/__tests_external__/index.js +0 -3
  181. package/dist/esm/__tests_external__/page-objects/Editor.js +0 -40
  182. package/dist/esm/__tests_external__/page-objects/EditorSmartLink.js +0 -201
  183. package/dist/esm/__tests_external__/page-objects/Renderer.js +0 -28
  184. package/dist/esm/in-product.js +0 -1
  185. package/dist/types/__tests_external__/cases/fundamentals/collection.d.ts +0 -3
  186. package/dist/types/__tests_external__/cases/fundamentals/test-cases/editor-is-present.d.ts +0 -3
  187. package/dist/types/__tests_external__/cases/fundamentals/test-cases/editor-typing.d.ts +0 -3
  188. package/dist/types/__tests_external__/cases/smart-links/index.d.ts +0 -4
  189. package/dist/types/__tests_external__/cases/smart-links/test-cases/block/delete.d.ts +0 -3
  190. package/dist/types/__tests_external__/cases/smart-links/test-cases/block/edit.d.ts +0 -4
  191. package/dist/types/__tests_external__/cases/smart-links/test-cases/block/index.d.ts +0 -3
  192. package/dist/types/__tests_external__/cases/smart-links/test-cases/block/insert.d.ts +0 -3
  193. package/dist/types/__tests_external__/cases/smart-links/test-cases/embed/delete.d.ts +0 -3
  194. package/dist/types/__tests_external__/cases/smart-links/test-cases/embed/edit.d.ts +0 -4
  195. package/dist/types/__tests_external__/cases/smart-links/test-cases/embed/index.d.ts +0 -3
  196. package/dist/types/__tests_external__/cases/smart-links/test-cases/embed/insert.d.ts +0 -3
  197. package/dist/types/__tests_external__/cases/smart-links/test-cases/inline/delete.d.ts +0 -3
  198. package/dist/types/__tests_external__/cases/smart-links/test-cases/inline/edit.d.ts +0 -4
  199. package/dist/types/__tests_external__/cases/smart-links/test-cases/inline/index.d.ts +0 -3
  200. package/dist/types/__tests_external__/cases/smart-links/test-cases/inline/insert.d.ts +0 -3
  201. package/dist/types/__tests_external__/cases/smart-links/test-cases/inline/unlink.d.ts +0 -3
  202. package/dist/types/__tests_external__/cases/smart-links/test-cases/types.d.ts +0 -4
  203. package/dist/types/__tests_external__/cases/smart-links/test-cases/url/index.d.ts +0 -3
  204. package/dist/types/__tests_external__/cases/smart-links/test-cases/url/insert.d.ts +0 -3
  205. package/dist/types/__tests_external__/cases/types.d.ts +0 -7
  206. package/dist/types/__tests_external__/index.d.ts +0 -3
  207. package/dist/types/__tests_external__/page-objects/Editor.d.ts +0 -11
  208. package/dist/types/__tests_external__/page-objects/EditorSmartLink.d.ts +0 -43
  209. package/dist/types/__tests_external__/page-objects/Renderer.d.ts +0 -8
  210. package/dist/types/in-product.d.ts +0 -1
  211. package/dist/types-ts4.5/__tests_external__/cases/fundamentals/collection.d.ts +0 -3
  212. package/dist/types-ts4.5/__tests_external__/cases/fundamentals/test-cases/editor-is-present.d.ts +0 -3
  213. package/dist/types-ts4.5/__tests_external__/cases/fundamentals/test-cases/editor-typing.d.ts +0 -3
  214. package/dist/types-ts4.5/__tests_external__/cases/smart-links/index.d.ts +0 -4
  215. package/dist/types-ts4.5/__tests_external__/cases/smart-links/test-cases/block/delete.d.ts +0 -3
  216. package/dist/types-ts4.5/__tests_external__/cases/smart-links/test-cases/block/edit.d.ts +0 -4
  217. package/dist/types-ts4.5/__tests_external__/cases/smart-links/test-cases/block/index.d.ts +0 -3
  218. package/dist/types-ts4.5/__tests_external__/cases/smart-links/test-cases/block/insert.d.ts +0 -3
  219. package/dist/types-ts4.5/__tests_external__/cases/smart-links/test-cases/embed/delete.d.ts +0 -3
  220. package/dist/types-ts4.5/__tests_external__/cases/smart-links/test-cases/embed/edit.d.ts +0 -4
  221. package/dist/types-ts4.5/__tests_external__/cases/smart-links/test-cases/embed/index.d.ts +0 -3
  222. package/dist/types-ts4.5/__tests_external__/cases/smart-links/test-cases/embed/insert.d.ts +0 -3
  223. package/dist/types-ts4.5/__tests_external__/cases/smart-links/test-cases/inline/delete.d.ts +0 -3
  224. package/dist/types-ts4.5/__tests_external__/cases/smart-links/test-cases/inline/edit.d.ts +0 -4
  225. package/dist/types-ts4.5/__tests_external__/cases/smart-links/test-cases/inline/index.d.ts +0 -3
  226. package/dist/types-ts4.5/__tests_external__/cases/smart-links/test-cases/inline/insert.d.ts +0 -3
  227. package/dist/types-ts4.5/__tests_external__/cases/smart-links/test-cases/inline/unlink.d.ts +0 -3
  228. package/dist/types-ts4.5/__tests_external__/cases/smart-links/test-cases/types.d.ts +0 -4
  229. package/dist/types-ts4.5/__tests_external__/cases/smart-links/test-cases/url/index.d.ts +0 -3
  230. package/dist/types-ts4.5/__tests_external__/cases/smart-links/test-cases/url/insert.d.ts +0 -3
  231. package/dist/types-ts4.5/__tests_external__/cases/types.d.ts +0 -7
  232. package/dist/types-ts4.5/__tests_external__/index.d.ts +0 -3
  233. package/dist/types-ts4.5/__tests_external__/page-objects/Editor.d.ts +0 -9
  234. package/dist/types-ts4.5/__tests_external__/page-objects/EditorSmartLink.d.ts +0 -41
  235. package/dist/types-ts4.5/__tests_external__/page-objects/Renderer.d.ts +0 -6
  236. package/dist/types-ts4.5/in-product.d.ts +0 -1
  237. package/in-product/package.json +0 -15
@@ -1,4 +1,4 @@
1
- import { IntlShape } from 'react-intl-next';
1
+ import { type IntlShape } from 'react-intl-next';
2
2
  export declare const transformTimeStamp: (intl: IntlShape, lastViewedDate?: Date, lastUpdatedDate?: Date) => {
3
3
  pageAction: string;
4
4
  dateString: string;
@@ -1,6 +1,6 @@
1
- import { KeyboardEvent } from 'react';
2
- import { ActivityItem, ActivityProvider } from '@atlaskit/activity-provider';
3
- import { INPUT_METHOD } from '../../analytics';
1
+ import { type KeyboardEvent } from 'react';
2
+ import { type ActivityItem, type ActivityProvider } from '@atlaskit/activity-provider';
3
+ import { type INPUT_METHOD } from '../../analytics';
4
4
  export type RecentSearchInputTypes = INPUT_METHOD.TYPEAHEAD | INPUT_METHOD.MANUAL;
5
5
  export interface ChildProps {
6
6
  activityProvider: ActivityProvider | null;
@@ -1,6 +1,6 @@
1
1
  import React from 'react';
2
- import { ActivityProvider } from '@atlaskit/activity-provider';
3
- import { ProviderFactory } from '../../provider-factory';
2
+ import { type ActivityProvider } from '@atlaskit/activity-provider';
3
+ import { type ProviderFactory } from '../../provider-factory';
4
4
  import type { Providers } from '../../provider-factory';
5
5
  import type { Diff } from '../../utils';
6
6
  export interface ExpandedActivityProviderProps {
@@ -1,5 +1,5 @@
1
- import { Node } from '@atlaskit/editor-prosemirror/model';
2
- import { INPUT_METHOD } from '../analytics';
1
+ import { type Node } from '@atlaskit/editor-prosemirror/model';
2
+ import { type INPUT_METHOD } from '../analytics';
3
3
  import type { EditorAppearance } from '../types';
4
4
  export declare enum LinkAction {
5
5
  SHOW_INSERT_TOOLBAR = "SHOW_INSERT_TOOLBAR",
@@ -1,6 +1,6 @@
1
1
  import React from 'react';
2
2
  import ProviderFactory from './provider-factory';
3
- import { ProviderType } from './types';
3
+ import { type ProviderType } from './types';
4
4
  export declare const ProviderFactoryProvider: React.Provider<ProviderFactory>;
5
5
  export declare const useProviderFactory: () => ProviderFactory;
6
6
  export declare const useProvider: <T extends string>(name: T) => ProviderType<T> | undefined;
@@ -1,4 +1,4 @@
1
- import { ProfileCardAction, ProfileClient } from '@atlaskit/profilecard';
1
+ import { type ProfileCardAction, type ProfileClient } from '@atlaskit/profilecard';
2
2
  export interface ProfilecardProvider {
3
3
  cloudId: string;
4
4
  resourceClient: ProfileClient;
@@ -1,4 +1,4 @@
1
- import { ProviderHandler, ProviderName, Providers, ProviderType } from './types';
1
+ import { type ProviderHandler, type ProviderName, type Providers, type ProviderType } from './types';
2
2
  export default class ProviderFactory {
3
3
  private providers;
4
4
  private subscribers;
@@ -1,6 +1,6 @@
1
- import { PureComponent, ReactNode } from 'react';
2
- import ProviderFactory from './provider-factory';
3
- import { ProviderName, Providers } from './types';
1
+ import { PureComponent, type ReactNode } from 'react';
2
+ import type ProviderFactory from './provider-factory';
3
+ import { type ProviderName, type Providers } from './types';
4
4
  export interface Props {
5
5
  providerFactory: ProviderFactory;
6
6
  providers: ProviderName[];
@@ -1,4 +1,4 @@
1
- import { Fragment, Node, Schema, Slice } from '@atlaskit/editor-prosemirror/model';
1
+ import { Fragment, type Node, type Schema, Slice } from '@atlaskit/editor-prosemirror/model';
2
2
  export declare function unwrapContentFromLayout(maybeLayoutSection: Node): Node | Node[];
3
3
  export declare function removeLayoutFromFirstChild(node: Node, i: number): Node | Node[];
4
4
  export declare function removeLayoutFromLastChild(node: Node, i: number, fragment: Fragment): Node | Node[];
@@ -1,7 +1,7 @@
1
1
  import type { IntlShape } from 'react-intl-next';
2
2
  import type { MarkType, NodeType } from '@atlaskit/editor-prosemirror/model';
3
3
  import type { EditorState } from '@atlaskit/editor-prosemirror/state';
4
- import { Command } from './command';
4
+ import { type Command } from './command';
5
5
  export type MarkOptions = {
6
6
  state: EditorState;
7
7
  formatMessage: IntlShape['formatMessage'];
@@ -1,4 +1,4 @@
1
- import { ResolvedPos } from '@atlaskit/editor-prosemirror/model';
1
+ import { type ResolvedPos } from '@atlaskit/editor-prosemirror/model';
2
2
  export interface SnapPointsProps {
3
3
  $pos?: ResolvedPos | null;
4
4
  akEditorWideLayoutWidth: number;
@@ -1,5 +1,5 @@
1
1
  import type { ReactElement } from 'react';
2
- import { Fragment, Node as PMNode } from '@atlaskit/editor-prosemirror/model';
2
+ import { type Fragment, type Node as PMNode } from '@atlaskit/editor-prosemirror/model';
3
3
  import type { EditorState, Transaction } from '@atlaskit/editor-prosemirror/state';
4
4
  import type { TypeAheadPayload } from '../analytics/types/type-ahead';
5
5
  import type { SelectItemMode, TypeAheadAvailableNodes } from '../type-ahead';
@@ -1,4 +1,4 @@
1
- import { EditorView } from '@atlaskit/editor-prosemirror/view';
1
+ import { type EditorView } from '@atlaskit/editor-prosemirror/view';
2
2
  import { UFOExperience } from '@atlaskit/ufo';
3
3
  import type { CustomData, ExperienceConfig } from '@atlaskit/ufo/types';
4
4
  export declare const experienceConfig: ExperienceConfig;
@@ -1,4 +1,4 @@
1
- import { SyntheticEvent } from 'react';
1
+ import { type SyntheticEvent } from 'react';
2
2
  import type { CardEvent, InlineCardEvent } from '@atlaskit/media-card';
3
3
  import type { Identifier } from '@atlaskit/media-client';
4
4
  export interface CardSurroundings {
@@ -1,5 +1,5 @@
1
- import React, { Component, ReactNode } from 'react';
2
- import { Data } from 'popper.js';
1
+ import React, { Component, type ReactNode } from 'react';
2
+ import { type Data } from 'popper.js';
3
3
  export type Props = {
4
4
  content: ReactNode | null;
5
5
  offset: string;
@@ -1,7 +1,7 @@
1
1
  import { PureComponent } from 'react';
2
2
  import { ProviderFactory } from '../../provider-factory';
3
- import { ProfilecardProvider } from '../../provider-factory/profile-card-provider';
4
- import { MentionEventHandlers } from '../EventHandlers';
3
+ import { type ProfilecardProvider } from '../../provider-factory/profile-card-provider';
4
+ import { type MentionEventHandlers } from '../EventHandlers';
5
5
  export interface MentionProps {
6
6
  id: string;
7
7
  providers?: ProviderFactory;
@@ -1,2 +1,2 @@
1
- import { ProfileCardAction } from '@atlaskit/profilecard';
1
+ import { type ProfileCardAction } from '@atlaskit/profilecard';
2
2
  export type { ProfileCardAction };
@@ -1,2 +1,2 @@
1
- import { MediaSingleWrapperProps as MediaSingleDimensionHelperProps } from '../MediaSingle/styled';
1
+ import { type MediaSingleWrapperProps as MediaSingleDimensionHelperProps } from '../MediaSingle/styled';
2
2
  export declare const wrapperStyle: (props: MediaSingleDimensionHelperProps) => import("@emotion/react").SerializedStyles;
@@ -1,6 +1,6 @@
1
- import { RichMediaLayout } from '@atlaskit/adf-schema';
2
- import { EditorView } from '@atlaskit/editor-prosemirror/view';
3
- import { MediaClientConfig } from '@atlaskit/media-core';
1
+ import { type RichMediaLayout } from '@atlaskit/adf-schema';
2
+ import { type EditorView } from '@atlaskit/editor-prosemirror/view';
3
+ import { type MediaClientConfig } from '@atlaskit/media-core';
4
4
  import type { DispatchAnalyticsEvent } from '../../analytics';
5
5
  import type { getPosHandler } from '../../react-node-view';
6
6
  import type { GridType } from '../../types';
@@ -1,5 +1,5 @@
1
1
  import React from 'react';
2
- import { CreateUIAnalyticsEvent } from '@atlaskit/analytics-next';
2
+ import { type CreateUIAnalyticsEvent } from '@atlaskit/analytics-next';
3
3
  export type Props = {
4
4
  render: (createAnalyticsEvent?: CreateUIAnalyticsEvent) => React.ReactNode;
5
5
  };
@@ -1,3 +1,3 @@
1
- import { IntlShape } from 'react-intl-next';
2
- import { Node as PMNode } from '@atlaskit/editor-prosemirror/model';
1
+ import { type IntlShape } from 'react-intl-next';
2
+ import { type Node as PMNode } from '@atlaskit/editor-prosemirror/model';
3
3
  export declare function getUnsupportedContent(message: any, prefix: string, node?: PMNode, intl?: IntlShape): any;
@@ -1,3 +1,3 @@
1
- import { PaletteColor } from './type';
1
+ import { type PaletteColor } from './type';
2
2
  declare const borderColorPalette: Array<PaletteColor>;
3
3
  export default borderColorPalette;
@@ -1,3 +1,3 @@
1
- import { PaletteColor } from './type';
1
+ import { type PaletteColor } from './type';
2
2
  declare const cellBackgroundColorPalette: Array<PaletteColor>;
3
3
  export default cellBackgroundColorPalette;
@@ -1,2 +1,2 @@
1
- import { MessageDescriptor } from 'react-intl-next';
1
+ import { type MessageDescriptor } from 'react-intl-next';
2
2
  export default function getColorMessage(messages: Record<string | number, MessageDescriptor>, color: string): MessageDescriptor | undefined;
@@ -1,4 +1,4 @@
1
- import { PaletteColor } from './type';
1
+ import { type PaletteColor } from './type';
2
2
  /** this is not new usage - old code extracted from editor-core */
3
3
  export declare const panelBackgroundPalette: PaletteColor[];
4
4
  export declare const panelDarkModeBackgroundPalette: PaletteColor[];
@@ -1,4 +1,4 @@
1
- import { MessageDescriptor } from 'react-intl-next';
1
+ import { type MessageDescriptor } from 'react-intl-next';
2
2
  export interface PaletteColor {
3
3
  value: string;
4
4
  label: string;
@@ -1,4 +1,4 @@
1
1
  import React from 'react';
2
- import { ButtonProps } from '@atlaskit/button/standard-button';
2
+ import { type ButtonProps } from '@atlaskit/button/standard-button';
3
3
  declare const _default: React.ForwardRefExoticComponent<ButtonProps & React.RefAttributes<HTMLElement>>;
4
4
  export default _default;
@@ -1,5 +1,5 @@
1
1
  import React from 'react';
2
- import { EditorView } from '@atlaskit/editor-prosemirror/view';
2
+ import { type EditorView } from '@atlaskit/editor-prosemirror/view';
3
3
  type ReactEditorViewContextProps = {
4
4
  editorView?: EditorView;
5
5
  editorRef?: React.RefObject<HTMLDivElement>;
@@ -1,5 +1,5 @@
1
1
  import { EDITOR_APPEARANCE_CONTEXT } from '@atlaskit/analytics-namespaced-context';
2
- import { ACTION, ACTION_SUBJECT, ACTION_SUBJECT_ID, EVENT_TYPE } from '../analytics';
2
+ import { type ACTION, type ACTION_SUBJECT, type ACTION_SUBJECT_ID, type EVENT_TYPE } from '../analytics';
3
3
  export declare const getAnalyticsAppearance: (appearance?: string) => EDITOR_APPEARANCE_CONTEXT | undefined;
4
4
  export declare const getAnalyticsEditorAppearance: (editorAppearance?: string) => string;
5
5
  export declare const getAnalyticsEventSeverity: (duration: number, normalThreshold: number, degradedThreshold: number) => SEVERITY;
@@ -1,6 +1,6 @@
1
- import { Fragment, Node as PMNode, ResolvedPos } from '@atlaskit/editor-prosemirror/model';
2
- import { EditorState, Transaction } from '@atlaskit/editor-prosemirror/state';
3
- import { EditorAnalyticsAPI } from '../analytics';
1
+ import { Fragment, type Node as PMNode, type ResolvedPos } from '@atlaskit/editor-prosemirror/model';
2
+ import { type EditorState, type Transaction } from '@atlaskit/editor-prosemirror/state';
3
+ import { type EditorAnalyticsAPI } from '../analytics';
4
4
  import type { Command, Predicate } from '../types';
5
5
  export type WalkNode = {
6
6
  $pos: ResolvedPos;
@@ -1,5 +1,5 @@
1
- import { CardAttributes } from '@atlaskit/adf-schema';
2
- import { Node as PMNode } from '@atlaskit/editor-prosemirror/model';
1
+ import { type CardAttributes } from '@atlaskit/adf-schema';
2
+ import { type Node as PMNode } from '@atlaskit/editor-prosemirror/model';
3
3
  import { SortOrder } from '../types';
4
4
  export declare enum ContentType {
5
5
  NUMBER = 0,
@@ -1,5 +1,5 @@
1
1
  import type { EditorView } from '@atlaskit/editor-prosemirror/view';
2
- import { AnalyticsEventPayload } from '../analytics';
2
+ import { type AnalyticsEventPayload } from '../analytics';
3
3
  export declare function getPerformanceOptions(view: EditorView): {
4
4
  trackingEnabled: boolean;
5
5
  samplingRate: number;
@@ -1,4 +1,4 @@
1
- import React, { ComponentType } from 'react';
1
+ import React, { type ComponentType } from 'react';
2
2
  export interface ImageLoaderProps {
3
3
  url?: string;
4
4
  onExternalImageLoaded?: (dimensions: {
@@ -1,4 +1,4 @@
1
- import { Node as PmNode } from '@atlaskit/editor-prosemirror/model';
1
+ import { type Node as PmNode } from '@atlaskit/editor-prosemirror/model';
2
2
  export interface Params {
3
3
  node: PmNode;
4
4
  type: 'image' | 'icon';
@@ -1,4 +1,4 @@
1
- import { PropsDifference, ShallowPropsDifference } from '../../../compare-props';
1
+ import { type PropsDifference, type ShallowPropsDifference } from '../../../compare-props';
2
2
  type PropsDiff<Props> = ShallowPropsDifference<Props> | PropsDifference<Props>;
3
3
  type OnRenderCb<Props = undefined> = ({ renderCount, propsDifference, }: {
4
4
  renderCount: number;
@@ -1,6 +1,6 @@
1
1
  import type { EditorState, PluginKey, ReadonlyTransaction, SafeStateField, Transaction } from '@atlaskit/editor-prosemirror/state';
2
- import { Dispatch } from '../event-dispatcher';
3
- import { Command } from '../types';
2
+ import { type Dispatch } from '../event-dispatcher';
3
+ import { type Command } from '../types';
4
4
  export type Reducer<PluginState, Action> = (state: PluginState, action: Action) => PluginState;
5
5
  type MapState<PluginState> = (tr: ReadonlyTransaction, pluginState: PluginState, editorState: EditorState) => PluginState;
6
6
  type SafePlugin<PluginState, Action, InitialState extends PluginState> = {
@@ -1,4 +1,4 @@
1
- import { Fragment, Node, Slice } from '@atlaskit/editor-prosemirror/model';
1
+ import { Fragment, type Node, Slice } from '@atlaskit/editor-prosemirror/model';
2
2
  /**
3
3
  * A helper to get the underlying array of a fragment.
4
4
  */
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@atlaskit/editor-common",
3
- "version": "80.5.2",
3
+ "version": "81.0.0",
4
4
  "description": "A package that contains common classes and components for editor and renderer",
5
5
  "publishConfig": {
6
6
  "registry": "https://registry.npmjs.org/"
@@ -38,7 +38,6 @@
38
38
  "./provider-factory": "./src/provider-factory.ts",
39
39
  "./styles": "./src/styles/index.ts",
40
40
  "./validator": "./src/validator.ts",
41
- "./in-product": "./src/in-product.ts",
42
41
  "./type-ahead": "./src/type-ahead/index.ts",
43
42
  "./ufo": "./src/ufo/index.ts",
44
43
  "./insert": "./src/insert/index.ts",
@@ -97,7 +96,7 @@
97
96
  },
98
97
  "dependencies": {
99
98
  "@atlaskit/activity-provider": "^2.4.0",
100
- "@atlaskit/adf-schema": "^36.8.0",
99
+ "@atlaskit/adf-schema": "^36.10.7",
101
100
  "@atlaskit/adf-utils": "^19.2.0",
102
101
  "@atlaskit/analytics-listeners": "^8.9.0",
103
102
  "@atlaskit/analytics-namespaced-context": "^6.9.0",
@@ -115,7 +114,6 @@
115
114
  "@atlaskit/emoji": "^67.6.0",
116
115
  "@atlaskit/icon": "^22.3.0",
117
116
  "@atlaskit/icon-object": "^6.4.0",
118
- "@atlaskit/in-product-testing": "^0.2.0",
119
117
  "@atlaskit/link-datasource": "^2.3.0",
120
118
  "@atlaskit/link-picker": "^1.36.0",
121
119
  "@atlaskit/media-card": "^77.11.0",
@@ -132,7 +130,7 @@
132
130
  "@atlaskit/primitives": "^6.3.0",
133
131
  "@atlaskit/profilecard": "^19.13.0",
134
132
  "@atlaskit/section-message": "^6.5.0",
135
- "@atlaskit/smart-card": "^26.73.0",
133
+ "@atlaskit/smart-card": "^27.0.0",
136
134
  "@atlaskit/smart-user-picker": "^6.9.0",
137
135
  "@atlaskit/spinner": "^16.1.0",
138
136
  "@atlaskit/task-decision": "^17.10.0",
package/tsconfig.json CHANGED
@@ -15,6 +15,5 @@
15
15
  "exclude": [
16
16
  "node_modules",
17
17
  "src/json-schema",
18
- "../editor-common-tests/src/__tests_external__"
19
18
  ]
20
19
  }
@@ -1,15 +0,0 @@
1
- "use strict";
2
-
3
- Object.defineProperty(exports, "__esModule", {
4
- value: true
5
- });
6
- exports.fundamentalsTestCollection = void 0;
7
- var _inProductTesting = require("@atlaskit/in-product-testing");
8
- var _editorIsPresent = require("./test-cases/editor-is-present");
9
- var _editorTyping = require("./test-cases/editor-typing");
10
- var fundamentalsTestCollection = exports.fundamentalsTestCollection = function fundamentalsTestCollection(opts) {
11
- return new _inProductTesting.InProductTestCollection({
12
- title: '@atlaskit/editor-core -> Editor fundamentals happy path tests',
13
- testCases: [(0, _editorIsPresent.editorIsPresentTestCase)(opts), (0, _editorTyping.editorTypingTestCase)(opts)]
14
- });
15
- };
@@ -1,20 +0,0 @@
1
- "use strict";
2
-
3
- Object.defineProperty(exports, "__esModule", {
4
- value: true
5
- });
6
- exports.editorIsPresentTestCase = void 0;
7
- var _inProductTesting = require("@atlaskit/in-product-testing");
8
- var _Editor = require("../../../page-objects/Editor");
9
- var editorIsPresentTestCase = exports.editorIsPresentTestCase = function editorIsPresentTestCase(testOptions) {
10
- return new _inProductTesting.InProductTestCase({
11
- testOptions: testOptions,
12
- title: 'content-area, title of Editor are visible',
13
- id: 'editor-is-present',
14
- assertions: function assertions(cy) {
15
- var editor = new _Editor.EditorPageObject(cy);
16
- editor.getTitleArea().should('be.visible');
17
- editor.getEditorArea().should('be.visible');
18
- }
19
- });
20
- };
@@ -1,28 +0,0 @@
1
- "use strict";
2
-
3
- Object.defineProperty(exports, "__esModule", {
4
- value: true
5
- });
6
- exports.editorTypingTestCase = void 0;
7
- var _inProductTesting = require("@atlaskit/in-product-testing");
8
- var _Editor = require("../../../page-objects/Editor");
9
- var _Renderer = require("../../../page-objects/Renderer");
10
- var editorTypingTestCase = exports.editorTypingTestCase = function editorTypingTestCase(opts) {
11
- return new _inProductTesting.InProductTestCase({
12
- title: 'typing in Editor works',
13
- id: 'editor-typing',
14
- assertions: function assertions(cy) {
15
- var _opts$ui;
16
- var editor = new _Editor.EditorPageObject(cy);
17
- editor.getEditorArea().type('abcdef');
18
- editor.getEditorArea().contains('abcdef');
19
- if (!opts || !((_opts$ui = opts.ui) !== null && _opts$ui !== void 0 && _opts$ui.publishButton)) {
20
- return;
21
- }
22
- var publishButton = opts.ui.publishButton;
23
- var renderer = new _Renderer.RendererPageObject(cy);
24
- cy.get(publishButton).click();
25
- renderer.getContent().contains('abcdef');
26
- }
27
- });
28
- };
@@ -1,33 +0,0 @@
1
- "use strict";
2
-
3
- Object.defineProperty(exports, "__esModule", {
4
- value: true
5
- });
6
- Object.defineProperty(exports, "blockSmartLinksTestCollection", {
7
- enumerable: true,
8
- get: function get() {
9
- return _block.blockSmartLinksTestCollection;
10
- }
11
- });
12
- Object.defineProperty(exports, "blueLinksTestCollection", {
13
- enumerable: true,
14
- get: function get() {
15
- return _url.blueLinksTestCollection;
16
- }
17
- });
18
- Object.defineProperty(exports, "embedSmartLinksTestCollection", {
19
- enumerable: true,
20
- get: function get() {
21
- return _embed.embedSmartLinksTestCollection;
22
- }
23
- });
24
- Object.defineProperty(exports, "inlineSmartLinksTestCollection", {
25
- enumerable: true,
26
- get: function get() {
27
- return _inline.inlineSmartLinksTestCollection;
28
- }
29
- });
30
- var _inline = require("./test-cases/inline");
31
- var _block = require("./test-cases/block");
32
- var _embed = require("./test-cases/embed");
33
- var _url = require("./test-cases/url");
@@ -1,35 +0,0 @@
1
- "use strict";
2
-
3
- Object.defineProperty(exports, "__esModule", {
4
- value: true
5
- });
6
- exports.deleteBlockSmartLinkTestCase = void 0;
7
- var _inProductTesting = require("@atlaskit/in-product-testing");
8
- var _inProduct = require("@atlaskit/smart-card/in-product");
9
- var _Editor = require("../../../../page-objects/Editor");
10
- var _EditorSmartLink = require("../../../../page-objects/EditorSmartLink");
11
- var deleteBlockSmartLinkTestCase = exports.deleteBlockSmartLinkTestCase = function deleteBlockSmartLinkTestCase(_ref) {
12
- var ui = _ref.ui,
13
- url = _ref.url;
14
- return new _inProductTesting.InProductTestCase({
15
- title: 'able to delete a Block Smart Link using floating toolbar',
16
- id: 'delete-block-smart-link',
17
- assertions: function assertions(cy) {
18
- var editor = new _Editor.EditorPageObject(cy);
19
- var editorWithSmartLinks = new _EditorSmartLink.EditorSmartLinkPageObject(cy, editor);
20
- var blockCard = new _inProduct.BlockCardPageObject(cy);
21
- editorWithSmartLinks.insertSmartLinkByTyping(url);
22
- editorWithSmartLinks.switchAfterInsert('block');
23
- (0, _inProduct.blockSmartLinkRendersTestCase)({
24
- url: url
25
- }).assertions(cy);
26
- editorWithSmartLinks.deleteSmartLink('block');
27
- blockCard.expectCardNotExists();
28
- if (ui !== null && ui !== void 0 && ui.publishButton) {
29
- var renderer = editor.publish(ui);
30
- renderer.expectContentReady();
31
- blockCard.expectCardNotExists();
32
- }
33
- }
34
- });
35
- };
@@ -1,65 +0,0 @@
1
- "use strict";
2
-
3
- Object.defineProperty(exports, "__esModule", {
4
- value: true
5
- });
6
- exports.editBlockSmartLinkUrlTestCase = exports.editBlockSmartLinkTitleTestCase = void 0;
7
- var _inProductTesting = require("@atlaskit/in-product-testing");
8
- var _inProduct = require("@atlaskit/smart-card/in-product");
9
- var _Editor = require("../../../../page-objects/Editor");
10
- var _EditorSmartLink = require("../../../../page-objects/EditorSmartLink");
11
- var editBlockSmartLinkTitleTestCase = exports.editBlockSmartLinkTitleTestCase = function editBlockSmartLinkTitleTestCase(_ref) {
12
- var ui = _ref.ui,
13
- url = _ref.url;
14
- return new _inProductTesting.InProductTestCase({
15
- title: 'editing a Block Smart Link renders as Blue Link (title)',
16
- id: 'block-smart-link-edit-title',
17
- assertions: function assertions(cy) {
18
- var editor = new _Editor.EditorPageObject(cy);
19
- var editorWithSmartLinks = new _EditorSmartLink.EditorSmartLinkPageObject(cy, editor);
20
- var blockCard = new _inProduct.BlockCardPageObject(cy);
21
- editorWithSmartLinks.insertSmartLinkByTyping(url);
22
- editorWithSmartLinks.switchAfterInsert('block');
23
- (0, _inProduct.blockSmartLinkRendersTestCase)({
24
- url: url
25
- }).assertions(cy);
26
- editorWithSmartLinks.changeLinkLabel('Avocorne is watching you 🥑', 'block');
27
- blockCard.assertHrefRendered(url);
28
- blockCard.expectCardNotExists();
29
- if (ui !== null && ui !== void 0 && ui.publishButton) {
30
- var renderer = editor.publish(ui);
31
- renderer.expectContentReady();
32
- blockCard.assertHrefRendered(url);
33
- blockCard.expectCardNotExists();
34
- }
35
- }
36
- });
37
- };
38
- var editBlockSmartLinkUrlTestCase = exports.editBlockSmartLinkUrlTestCase = function editBlockSmartLinkUrlTestCase(_ref2) {
39
- var ui = _ref2.ui,
40
- url = _ref2.url;
41
- return new _inProductTesting.InProductTestCase({
42
- title: 'editing a Block Smart Link renders as Blue Link (URL)',
43
- id: 'block-smart-link-edit',
44
- assertions: function assertions(cy) {
45
- var editor = new _Editor.EditorPageObject(cy);
46
- var editorWithSmartLinks = new _EditorSmartLink.EditorSmartLinkPageObject(cy, editor);
47
- var blockCard = new _inProduct.BlockCardPageObject(cy);
48
- editorWithSmartLinks.insertSmartLinkByTyping(url);
49
- editorWithSmartLinks.switchAfterInsert('block');
50
- (0, _inProduct.blockSmartLinkRendersTestCase)({
51
- url: url
52
- }).assertions(cy);
53
- var newUrl = 'https://avo.corne.com';
54
- editorWithSmartLinks.changeLinkUrl(newUrl, 'block');
55
- blockCard.expectCardNotExists();
56
- blockCard.assertHrefRendered(newUrl);
57
- if (ui !== null && ui !== void 0 && ui.publishButton) {
58
- var renderer = editor.publish(ui);
59
- renderer.expectContentReady();
60
- blockCard.assertHrefRendered(newUrl);
61
- blockCard.expectCardNotExists();
62
- }
63
- }
64
- });
65
- };
@@ -1,16 +0,0 @@
1
- "use strict";
2
-
3
- Object.defineProperty(exports, "__esModule", {
4
- value: true
5
- });
6
- exports.blockSmartLinksTestCollection = void 0;
7
- var _inProductTesting = require("@atlaskit/in-product-testing");
8
- var _delete = require("./delete");
9
- var _edit = require("./edit");
10
- var _insert = require("./insert");
11
- var blockSmartLinksTestCollection = exports.blockSmartLinksTestCollection = function blockSmartLinksTestCollection(opts) {
12
- return new _inProductTesting.InProductTestCollection({
13
- title: '@atlaskit/editor-core -> Block Smart Links, happy paths',
14
- testCases: [(0, _insert.switchToBlockSmartLinkTestCase)(opts), (0, _edit.editBlockSmartLinkTitleTestCase)(opts), (0, _edit.editBlockSmartLinkUrlTestCase)(opts), (0, _delete.deleteBlockSmartLinkTestCase)(opts)]
15
- });
16
- };
@@ -1,34 +0,0 @@
1
- "use strict";
2
-
3
- Object.defineProperty(exports, "__esModule", {
4
- value: true
5
- });
6
- exports.switchToBlockSmartLinkTestCase = void 0;
7
- var _inProductTesting = require("@atlaskit/in-product-testing");
8
- var _inProduct = require("@atlaskit/smart-card/in-product");
9
- var _Editor = require("../../../../page-objects/Editor");
10
- var _EditorSmartLink = require("../../../../page-objects/EditorSmartLink");
11
- var switchToBlockSmartLinkTestCase = exports.switchToBlockSmartLinkTestCase = function switchToBlockSmartLinkTestCase(_ref) {
12
- var ui = _ref.ui,
13
- url = _ref.url;
14
- return new _inProductTesting.InProductTestCase({
15
- title: 'switching to a Block Smart Link works',
16
- id: 'switch-to-block',
17
- assertions: function assertions(cy) {
18
- var editor = new _Editor.EditorPageObject(cy);
19
- var editorWithSmartLinks = new _EditorSmartLink.EditorSmartLinkPageObject(cy, editor);
20
- editorWithSmartLinks.insertSmartLinkByTyping(url);
21
- editorWithSmartLinks.switchAfterInsert('block');
22
- (0, _inProduct.blockSmartLinkRendersTestCase)({
23
- url: url
24
- }).assertions(cy);
25
- if (ui !== null && ui !== void 0 && ui.publishButton) {
26
- var renderer = editor.publish(ui);
27
- renderer.expectContentReady();
28
- (0, _inProduct.blockSmartLinkRendersTestCase)({
29
- url: url
30
- }).assertions(cy);
31
- }
32
- }
33
- });
34
- };