@atlaskit/editor-core 164.0.3 → 166.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 (194) hide show
  1. package/CHANGELOG.md +43 -0
  2. package/dist/cjs/actions/index.js +9 -0
  3. package/dist/cjs/create-editor/ReactEditorView.js +14 -6
  4. package/dist/cjs/create-editor/create-plugins-list.js +1 -2
  5. package/dist/cjs/editor.js +32 -1
  6. package/dist/cjs/event-dispatcher/index.js +9 -0
  7. package/dist/cjs/nodeviews/ReactNodeView.js +1 -11
  8. package/dist/cjs/nodeviews/getInlineNodeViewProducer.styles.js +1 -1
  9. package/dist/cjs/nodeviews/getPerformanceOptions.js +1 -1
  10. package/dist/cjs/plugins/analytics/types/enums.js +1 -0
  11. package/dist/cjs/plugins/base/pm-plugins/frozen-editor.js +128 -79
  12. package/dist/cjs/plugins/base/utils/input-latency-tracking.js +157 -0
  13. package/dist/cjs/plugins/card/styles.js +3 -1
  14. package/dist/cjs/plugins/code-block/styles.js +6 -4
  15. package/dist/cjs/plugins/collab-edit/plugin-state.js +23 -5
  16. package/dist/cjs/plugins/date/styles.js +3 -1
  17. package/dist/cjs/plugins/emoji/index.js +30 -34
  18. package/dist/cjs/plugins/emoji/nodeviews/emoji.js +12 -66
  19. package/dist/cjs/plugins/emoji/styles.js +3 -17
  20. package/dist/cjs/plugins/expand/ui/styles.js +2 -2
  21. package/dist/cjs/plugins/extension/ui/styles.js +3 -1
  22. package/dist/cjs/plugins/feature-flags-context/feature-flags-from-props.js +20 -22
  23. package/dist/cjs/plugins/hyperlink/pm-plugins/input-rule.js +1 -9
  24. package/dist/cjs/plugins/hyperlink/pm-plugins/keymap.js +1 -9
  25. package/dist/cjs/plugins/layout/styles.js +3 -1
  26. package/dist/cjs/plugins/list/commands/indent-list.js +5 -1
  27. package/dist/cjs/plugins/list/commands/outdent-list.js +5 -1
  28. package/dist/cjs/plugins/list/transforms.js +11 -3
  29. package/dist/cjs/plugins/media/styles.js +3 -1
  30. package/dist/cjs/plugins/mentions/index.js +10 -14
  31. package/dist/cjs/plugins/mentions/nodeviews/mention.js +15 -67
  32. package/dist/cjs/plugins/mentions/pm-plugins/main.js +19 -10
  33. package/dist/cjs/plugins/mentions/type-ahead/index.js +7 -2
  34. package/dist/cjs/plugins/panel/styles.js +3 -1
  35. package/dist/cjs/plugins/placeholder-text/placeholder-text-nodeview.js +3 -1
  36. package/dist/cjs/plugins/rule/styles.js +3 -1
  37. package/dist/cjs/plugins/selection/utils.js +39 -23
  38. package/dist/cjs/plugins/table/pm-plugins/sticky-headers/nodeviews/tableRow.js +24 -0
  39. package/dist/cjs/plugins/table/ui/common-styles.js +1 -1
  40. package/dist/cjs/plugins/table/ui/consts.js +6 -4
  41. package/dist/cjs/plugins/tasks-and-decisions/styles.js +3 -1
  42. package/dist/cjs/plugins/type-ahead/index.js +6 -2
  43. package/dist/cjs/plugins/unsupported-content/index.js +22 -10
  44. package/dist/cjs/plugins/unsupported-content/styles.js +4 -2
  45. package/dist/cjs/plugins/unsupported-content/unsupported-inline-node-view.js +21 -0
  46. package/dist/cjs/ui/Appearance/Chromeless.js +6 -3
  47. package/dist/cjs/ui/Appearance/Comment/Comment.js +6 -4
  48. package/dist/cjs/ui/ChromeCollapsed/styles.js +3 -1
  49. package/dist/cjs/ui/ContentStyles/index.js +2 -2
  50. package/dist/cjs/ui/PortalProvider/PortalProviderThemesProvider.js +57 -0
  51. package/dist/cjs/ui/PortalProvider/index.js +66 -19
  52. package/dist/cjs/utils/check-if-mobile-bridge.js +19 -0
  53. package/dist/cjs/version-wrapper.js +1 -1
  54. package/dist/cjs/version.json +1 -1
  55. package/dist/es2019/actions/index.js +12 -1
  56. package/dist/es2019/create-editor/ReactEditorView.js +14 -6
  57. package/dist/es2019/create-editor/create-plugins-list.js +1 -2
  58. package/dist/es2019/editor.js +33 -2
  59. package/dist/es2019/event-dispatcher/index.js +8 -0
  60. package/dist/es2019/nodeviews/ReactNodeView.js +1 -10
  61. package/dist/es2019/nodeviews/getInlineNodeViewProducer.styles.js +9 -0
  62. package/dist/es2019/plugins/analytics/types/enums.js +1 -0
  63. package/dist/es2019/plugins/base/pm-plugins/frozen-editor.js +138 -80
  64. package/dist/es2019/plugins/base/utils/input-latency-tracking.js +128 -0
  65. package/dist/es2019/plugins/card/styles.js +9 -5
  66. package/dist/es2019/plugins/code-block/styles.js +11 -8
  67. package/dist/es2019/plugins/collab-edit/plugin-state.js +23 -8
  68. package/dist/es2019/plugins/date/styles.js +3 -1
  69. package/dist/es2019/plugins/emoji/index.js +16 -21
  70. package/dist/es2019/plugins/emoji/nodeviews/emoji.js +12 -31
  71. package/dist/es2019/plugins/emoji/styles.js +1 -82
  72. package/dist/es2019/plugins/expand/ui/styles.js +2 -2
  73. package/dist/es2019/plugins/extension/ui/styles.js +4 -2
  74. package/dist/es2019/plugins/feature-flags-context/feature-flags-from-props.js +20 -22
  75. package/dist/es2019/plugins/hyperlink/pm-plugins/input-rule.js +1 -8
  76. package/dist/es2019/plugins/hyperlink/pm-plugins/keymap.js +1 -8
  77. package/dist/es2019/plugins/layout/styles.js +3 -2
  78. package/dist/es2019/plugins/list/commands/indent-list.js +4 -1
  79. package/dist/es2019/plugins/list/commands/outdent-list.js +4 -1
  80. package/dist/es2019/plugins/list/transforms.js +9 -4
  81. package/dist/es2019/plugins/media/styles.js +9 -7
  82. package/dist/es2019/plugins/mentions/index.js +1 -6
  83. package/dist/es2019/plugins/mentions/nodeviews/mention.js +16 -35
  84. package/dist/es2019/plugins/mentions/pm-plugins/main.js +18 -10
  85. package/dist/es2019/plugins/mentions/type-ahead/index.js +7 -2
  86. package/dist/es2019/plugins/panel/styles.js +5 -4
  87. package/dist/es2019/plugins/placeholder-text/placeholder-text-nodeview.js +3 -1
  88. package/dist/es2019/plugins/rule/styles.js +2 -1
  89. package/dist/es2019/plugins/selection/utils.js +35 -20
  90. package/dist/es2019/plugins/table/pm-plugins/sticky-headers/nodeviews/tableRow.js +22 -0
  91. package/dist/es2019/plugins/table/ui/common-styles.js +4 -0
  92. package/dist/es2019/plugins/table/ui/consts.js +5 -4
  93. package/dist/es2019/plugins/tasks-and-decisions/styles.js +4 -2
  94. package/dist/es2019/plugins/type-ahead/index.js +5 -1
  95. package/dist/es2019/plugins/unsupported-content/index.js +23 -12
  96. package/dist/es2019/plugins/unsupported-content/styles.js +5 -3
  97. package/dist/es2019/plugins/unsupported-content/unsupported-inline-node-view.js +7 -0
  98. package/dist/es2019/ui/Appearance/Chromeless.js +5 -2
  99. package/dist/es2019/ui/Appearance/Comment/Comment.js +5 -2
  100. package/dist/es2019/ui/ChromeCollapsed/styles.js +2 -1
  101. package/dist/es2019/ui/ContentStyles/index.js +3 -3
  102. package/dist/es2019/ui/PortalProvider/PortalProviderThemesProvider.js +39 -0
  103. package/dist/es2019/ui/PortalProvider/index.js +39 -3
  104. package/dist/es2019/utils/check-if-mobile-bridge.js +12 -0
  105. package/dist/es2019/version-wrapper.js +1 -1
  106. package/dist/es2019/version.json +1 -1
  107. package/dist/esm/actions/index.js +8 -0
  108. package/dist/esm/create-editor/ReactEditorView.js +14 -6
  109. package/dist/esm/create-editor/create-plugins-list.js +1 -2
  110. package/dist/esm/editor.js +33 -2
  111. package/dist/esm/event-dispatcher/index.js +9 -0
  112. package/dist/esm/nodeviews/ReactNodeView.js +1 -10
  113. package/dist/esm/nodeviews/getInlineNodeViewProducer.styles.js +1 -1
  114. package/dist/esm/plugins/analytics/types/enums.js +1 -0
  115. package/dist/esm/plugins/base/pm-plugins/frozen-editor.js +128 -79
  116. package/dist/esm/plugins/base/utils/input-latency-tracking.js +149 -0
  117. package/dist/esm/plugins/card/styles.js +2 -1
  118. package/dist/esm/plugins/code-block/styles.js +5 -4
  119. package/dist/esm/plugins/collab-edit/plugin-state.js +21 -6
  120. package/dist/esm/plugins/date/styles.js +2 -1
  121. package/dist/esm/plugins/emoji/index.js +26 -29
  122. package/dist/esm/plugins/emoji/nodeviews/emoji.js +11 -56
  123. package/dist/esm/plugins/emoji/styles.js +3 -14
  124. package/dist/esm/plugins/expand/ui/styles.js +2 -2
  125. package/dist/esm/plugins/extension/ui/styles.js +2 -1
  126. package/dist/esm/plugins/feature-flags-context/feature-flags-from-props.js +20 -22
  127. package/dist/esm/plugins/hyperlink/pm-plugins/input-rule.js +1 -8
  128. package/dist/esm/plugins/hyperlink/pm-plugins/keymap.js +1 -8
  129. package/dist/esm/plugins/layout/styles.js +2 -1
  130. package/dist/esm/plugins/list/commands/indent-list.js +4 -1
  131. package/dist/esm/plugins/list/commands/outdent-list.js +4 -1
  132. package/dist/esm/plugins/list/transforms.js +9 -4
  133. package/dist/esm/plugins/media/styles.js +2 -1
  134. package/dist/esm/plugins/mentions/index.js +10 -14
  135. package/dist/esm/plugins/mentions/nodeviews/mention.js +13 -58
  136. package/dist/esm/plugins/mentions/pm-plugins/main.js +18 -10
  137. package/dist/esm/plugins/mentions/type-ahead/index.js +7 -2
  138. package/dist/esm/plugins/panel/styles.js +2 -1
  139. package/dist/esm/plugins/placeholder-text/placeholder-text-nodeview.js +3 -1
  140. package/dist/esm/plugins/rule/styles.js +2 -1
  141. package/dist/esm/plugins/selection/utils.js +35 -20
  142. package/dist/esm/plugins/table/pm-plugins/sticky-headers/nodeviews/tableRow.js +23 -0
  143. package/dist/esm/plugins/table/ui/common-styles.js +1 -1
  144. package/dist/esm/plugins/table/ui/consts.js +5 -4
  145. package/dist/esm/plugins/tasks-and-decisions/styles.js +2 -1
  146. package/dist/esm/plugins/type-ahead/index.js +6 -2
  147. package/dist/esm/plugins/unsupported-content/index.js +21 -11
  148. package/dist/esm/plugins/unsupported-content/styles.js +3 -2
  149. package/dist/esm/plugins/unsupported-content/unsupported-inline-node-view.js +7 -0
  150. package/dist/esm/ui/Appearance/Chromeless.js +6 -3
  151. package/dist/esm/ui/Appearance/Comment/Comment.js +6 -4
  152. package/dist/esm/ui/ChromeCollapsed/styles.js +2 -1
  153. package/dist/esm/ui/ContentStyles/index.js +3 -3
  154. package/dist/esm/ui/PortalProvider/PortalProviderThemesProvider.js +39 -0
  155. package/dist/esm/ui/PortalProvider/index.js +61 -19
  156. package/dist/esm/utils/check-if-mobile-bridge.js +12 -0
  157. package/dist/esm/version-wrapper.js +1 -1
  158. package/dist/esm/version.json +1 -1
  159. package/dist/types/actions/index.d.ts +3 -1
  160. package/dist/types/editor.d.ts +3 -0
  161. package/dist/types/event-dispatcher/index.d.ts +1 -0
  162. package/dist/types/nodeviews/ReactNodeView.d.ts +1 -5
  163. package/dist/types/plugins/analytics/types/enums.d.ts +1 -0
  164. package/dist/types/plugins/analytics/types/events.d.ts +2 -2
  165. package/dist/types/plugins/analytics/types/general-events.d.ts +10 -1
  166. package/dist/types/plugins/base/utils/input-latency-tracking.d.ts +44 -0
  167. package/dist/types/plugins/collab-edit/plugin-state.d.ts +4 -0
  168. package/dist/types/plugins/emoji/index.d.ts +2 -6
  169. package/dist/types/plugins/emoji/nodeviews/emoji.d.ts +4 -14
  170. package/dist/types/plugins/emoji/styles.d.ts +0 -1
  171. package/dist/types/plugins/emoji/types.d.ts +0 -1
  172. package/dist/types/plugins/list/transforms.d.ts +10 -1
  173. package/dist/types/plugins/mentions/nodeviews/mention.d.ts +6 -14
  174. package/dist/types/plugins/mentions/pm-plugins/main.d.ts +2 -5
  175. package/dist/types/plugins/selection/utils.d.ts +7 -15
  176. package/dist/types/plugins/table/pm-plugins/sticky-headers/nodeviews/tableRow.d.ts +3 -0
  177. package/dist/types/plugins/table/ui/consts.d.ts +2 -2
  178. package/dist/types/plugins/type-ahead/types.d.ts +1 -0
  179. package/dist/types/plugins/unsupported-content/unsupported-inline-node-view.d.ts +11 -0
  180. package/dist/types/types/editor-appearance-component.d.ts +1 -0
  181. package/dist/types/types/editor-props.d.ts +1 -0
  182. package/dist/types/types/feature-flags.d.ts +0 -14
  183. package/dist/types/ui/Appearance/Chromeless.d.ts +1 -0
  184. package/dist/types/ui/Appearance/Comment/Comment.d.ts +1 -0
  185. package/dist/types/ui/Appearance/FullPage/StyledComponents.d.ts +5 -5
  186. package/dist/types/ui/ContentStyles/index.d.ts +2 -2
  187. package/dist/types/ui/PortalProvider/PortalProviderThemesProvider.d.ts +6 -0
  188. package/dist/types/ui/PortalProvider/index.d.ts +5 -1
  189. package/dist/types/utils/check-if-mobile-bridge.d.ts +1 -0
  190. package/package.json +24 -23
  191. package/dist/cjs/plugins/emoji/nodeviews/emoji-next.js +0 -250
  192. package/dist/es2019/plugins/emoji/nodeviews/emoji-next.js +0 -177
  193. package/dist/esm/plugins/emoji/nodeviews/emoji-next.js +0 -234
  194. package/dist/types/plugins/emoji/nodeviews/emoji-next.d.ts +0 -31
@@ -7,6 +7,6 @@ declare type ContentStylesProps = {
7
7
  featureFlags?: FeatureFlags;
8
8
  };
9
9
  declare type Props = Omit<ContentStylesProps & React.HTMLProps<HTMLDivElement>, 'featureFlags'>;
10
- export declare const createEditorContentStyle: (styles?: SerializedStyles | undefined) => React.ForwardRefExoticComponent<Pick<Props, "cite" | "data" | "dir" | "form" | "label" | "slot" | "span" | "style" | "summary" | "title" | "default" | "mediaGroup" | "media" | "content" | "aria-label" | "aria-haspopup" | "children" | "pattern" | "value" | "type" | "width" | "accessKey" | "draggable" | "hidden" | "lang" | "className" | "id" | "prefix" | "contentEditable" | "inputMode" | "nonce" | "tabIndex" | "defaultValue" | "onError" | "onChange" | "open" | "onFocus" | "onBlur" | "placeholder" | "autoFocus" | "color" | "name" | "key" | "action" | "disabled" | "height" | "target" | "start" | "onClick" | "onMouseEnter" | "onMouseLeave" | "selected" | "href" | "accept" | "acceptCharset" | "allowFullScreen" | "allowTransparency" | "alt" | "as" | "async" | "autoComplete" | "autoPlay" | "capture" | "cellPadding" | "cellSpacing" | "charSet" | "challenge" | "checked" | "classID" | "cols" | "colSpan" | "controls" | "coords" | "crossOrigin" | "dateTime" | "defer" | "download" | "encType" | "formAction" | "formEncType" | "formMethod" | "formNoValidate" | "formTarget" | "frameBorder" | "headers" | "high" | "hrefLang" | "htmlFor" | "httpEquiv" | "integrity" | "keyParams" | "keyType" | "kind" | "list" | "loop" | "low" | "manifest" | "marginHeight" | "marginWidth" | "max" | "maxLength" | "method" | "min" | "minLength" | "multiple" | "muted" | "noValidate" | "optimum" | "playsInline" | "poster" | "preload" | "readOnly" | "rel" | "required" | "reversed" | "rows" | "rowSpan" | "sandbox" | "scope" | "scoped" | "scrolling" | "seamless" | "shape" | "size" | "sizes" | "src" | "srcDoc" | "srcLang" | "srcSet" | "step" | "useMap" | "wmode" | "wrap" | "defaultChecked" | "suppressContentEditableWarning" | "suppressHydrationWarning" | "contextMenu" | "spellCheck" | "is" | "radioGroup" | "role" | "about" | "datatype" | "inlist" | "property" | "resource" | "typeof" | "vocab" | "autoCapitalize" | "autoCorrect" | "autoSave" | "itemProp" | "itemScope" | "itemType" | "itemID" | "itemRef" | "results" | "security" | "unselectable" | "aria-activedescendant" | "aria-atomic" | "aria-autocomplete" | "aria-busy" | "aria-checked" | "aria-colcount" | "aria-colindex" | "aria-colspan" | "aria-controls" | "aria-current" | "aria-describedby" | "aria-details" | "aria-disabled" | "aria-dropeffect" | "aria-errormessage" | "aria-expanded" | "aria-flowto" | "aria-grabbed" | "aria-hidden" | "aria-invalid" | "aria-keyshortcuts" | "aria-labelledby" | "aria-level" | "aria-live" | "aria-modal" | "aria-multiline" | "aria-multiselectable" | "aria-orientation" | "aria-owns" | "aria-placeholder" | "aria-posinset" | "aria-pressed" | "aria-readonly" | "aria-relevant" | "aria-required" | "aria-roledescription" | "aria-rowcount" | "aria-rowindex" | "aria-rowspan" | "aria-selected" | "aria-setsize" | "aria-sort" | "aria-valuemax" | "aria-valuemin" | "aria-valuenow" | "aria-valuetext" | "dangerouslySetInnerHTML" | "onCopy" | "onCopyCapture" | "onCut" | "onCutCapture" | "onPaste" | "onPasteCapture" | "onCompositionEnd" | "onCompositionEndCapture" | "onCompositionStart" | "onCompositionStartCapture" | "onCompositionUpdate" | "onCompositionUpdateCapture" | "onFocusCapture" | "onBlurCapture" | "onChangeCapture" | "onBeforeInput" | "onBeforeInputCapture" | "onInput" | "onInputCapture" | "onReset" | "onResetCapture" | "onSubmit" | "onSubmitCapture" | "onInvalid" | "onInvalidCapture" | "onLoad" | "onLoadCapture" | "onErrorCapture" | "onKeyDown" | "onKeyDownCapture" | "onKeyPress" | "onKeyPressCapture" | "onKeyUp" | "onKeyUpCapture" | "onAbort" | "onAbortCapture" | "onCanPlay" | "onCanPlayCapture" | "onCanPlayThrough" | "onCanPlayThroughCapture" | "onDurationChange" | "onDurationChangeCapture" | "onEmptied" | "onEmptiedCapture" | "onEncrypted" | "onEncryptedCapture" | "onEnded" | "onEndedCapture" | "onLoadedData" | "onLoadedDataCapture" | "onLoadedMetadata" | "onLoadedMetadataCapture" | "onLoadStart" | "onLoadStartCapture" | "onPause" | "onPauseCapture" | "onPlay" | "onPlayCapture" | "onPlaying" | "onPlayingCapture" | "onProgress" | "onProgressCapture" | "onRateChange" | "onRateChangeCapture" | "onSeeked" | "onSeekedCapture" | "onSeeking" | "onSeekingCapture" | "onStalled" | "onStalledCapture" | "onSuspend" | "onSuspendCapture" | "onTimeUpdate" | "onTimeUpdateCapture" | "onVolumeChange" | "onVolumeChangeCapture" | "onWaiting" | "onWaitingCapture" | "onAuxClick" | "onAuxClickCapture" | "onClickCapture" | "onContextMenu" | "onContextMenuCapture" | "onDoubleClick" | "onDoubleClickCapture" | "onDrag" | "onDragCapture" | "onDragEnd" | "onDragEndCapture" | "onDragEnter" | "onDragEnterCapture" | "onDragExit" | "onDragExitCapture" | "onDragLeave" | "onDragLeaveCapture" | "onDragOver" | "onDragOverCapture" | "onDragStart" | "onDragStartCapture" | "onDrop" | "onDropCapture" | "onMouseDown" | "onMouseDownCapture" | "onMouseMove" | "onMouseMoveCapture" | "onMouseOut" | "onMouseOutCapture" | "onMouseOver" | "onMouseOverCapture" | "onMouseUp" | "onMouseUpCapture" | "onSelect" | "onSelectCapture" | "onTouchCancel" | "onTouchCancelCapture" | "onTouchEnd" | "onTouchEndCapture" | "onTouchMove" | "onTouchMoveCapture" | "onTouchStart" | "onTouchStartCapture" | "onPointerDown" | "onPointerDownCapture" | "onPointerMove" | "onPointerMoveCapture" | "onPointerUp" | "onPointerUpCapture" | "onPointerCancel" | "onPointerCancelCapture" | "onPointerEnter" | "onPointerEnterCapture" | "onPointerLeave" | "onPointerLeaveCapture" | "onPointerOver" | "onPointerOverCapture" | "onPointerOut" | "onPointerOutCapture" | "onGotPointerCapture" | "onGotPointerCaptureCapture" | "onLostPointerCapture" | "onLostPointerCaptureCapture" | "onScroll" | "onScrollCapture" | "onWheel" | "onWheelCapture" | "onAnimationStart" | "onAnimationStartCapture" | "onAnimationEnd" | "onAnimationEndCapture" | "onAnimationIteration" | "onAnimationIterationCapture" | "onTransitionEnd" | "onTransitionEndCapture" | "css" | "theme"> & React.RefAttributes<HTMLDivElement>>;
11
- declare const _default: React.ForwardRefExoticComponent<Pick<Props, "cite" | "data" | "dir" | "form" | "label" | "slot" | "span" | "style" | "summary" | "title" | "default" | "mediaGroup" | "media" | "content" | "aria-label" | "aria-haspopup" | "children" | "pattern" | "value" | "type" | "width" | "accessKey" | "draggable" | "hidden" | "lang" | "className" | "id" | "prefix" | "contentEditable" | "inputMode" | "nonce" | "tabIndex" | "defaultValue" | "onError" | "onChange" | "open" | "onFocus" | "onBlur" | "placeholder" | "autoFocus" | "color" | "name" | "key" | "action" | "disabled" | "height" | "target" | "start" | "onClick" | "onMouseEnter" | "onMouseLeave" | "selected" | "href" | "accept" | "acceptCharset" | "allowFullScreen" | "allowTransparency" | "alt" | "as" | "async" | "autoComplete" | "autoPlay" | "capture" | "cellPadding" | "cellSpacing" | "charSet" | "challenge" | "checked" | "classID" | "cols" | "colSpan" | "controls" | "coords" | "crossOrigin" | "dateTime" | "defer" | "download" | "encType" | "formAction" | "formEncType" | "formMethod" | "formNoValidate" | "formTarget" | "frameBorder" | "headers" | "high" | "hrefLang" | "htmlFor" | "httpEquiv" | "integrity" | "keyParams" | "keyType" | "kind" | "list" | "loop" | "low" | "manifest" | "marginHeight" | "marginWidth" | "max" | "maxLength" | "method" | "min" | "minLength" | "multiple" | "muted" | "noValidate" | "optimum" | "playsInline" | "poster" | "preload" | "readOnly" | "rel" | "required" | "reversed" | "rows" | "rowSpan" | "sandbox" | "scope" | "scoped" | "scrolling" | "seamless" | "shape" | "size" | "sizes" | "src" | "srcDoc" | "srcLang" | "srcSet" | "step" | "useMap" | "wmode" | "wrap" | "defaultChecked" | "suppressContentEditableWarning" | "suppressHydrationWarning" | "contextMenu" | "spellCheck" | "is" | "radioGroup" | "role" | "about" | "datatype" | "inlist" | "property" | "resource" | "typeof" | "vocab" | "autoCapitalize" | "autoCorrect" | "autoSave" | "itemProp" | "itemScope" | "itemType" | "itemID" | "itemRef" | "results" | "security" | "unselectable" | "aria-activedescendant" | "aria-atomic" | "aria-autocomplete" | "aria-busy" | "aria-checked" | "aria-colcount" | "aria-colindex" | "aria-colspan" | "aria-controls" | "aria-current" | "aria-describedby" | "aria-details" | "aria-disabled" | "aria-dropeffect" | "aria-errormessage" | "aria-expanded" | "aria-flowto" | "aria-grabbed" | "aria-hidden" | "aria-invalid" | "aria-keyshortcuts" | "aria-labelledby" | "aria-level" | "aria-live" | "aria-modal" | "aria-multiline" | "aria-multiselectable" | "aria-orientation" | "aria-owns" | "aria-placeholder" | "aria-posinset" | "aria-pressed" | "aria-readonly" | "aria-relevant" | "aria-required" | "aria-roledescription" | "aria-rowcount" | "aria-rowindex" | "aria-rowspan" | "aria-selected" | "aria-setsize" | "aria-sort" | "aria-valuemax" | "aria-valuemin" | "aria-valuenow" | "aria-valuetext" | "dangerouslySetInnerHTML" | "onCopy" | "onCopyCapture" | "onCut" | "onCutCapture" | "onPaste" | "onPasteCapture" | "onCompositionEnd" | "onCompositionEndCapture" | "onCompositionStart" | "onCompositionStartCapture" | "onCompositionUpdate" | "onCompositionUpdateCapture" | "onFocusCapture" | "onBlurCapture" | "onChangeCapture" | "onBeforeInput" | "onBeforeInputCapture" | "onInput" | "onInputCapture" | "onReset" | "onResetCapture" | "onSubmit" | "onSubmitCapture" | "onInvalid" | "onInvalidCapture" | "onLoad" | "onLoadCapture" | "onErrorCapture" | "onKeyDown" | "onKeyDownCapture" | "onKeyPress" | "onKeyPressCapture" | "onKeyUp" | "onKeyUpCapture" | "onAbort" | "onAbortCapture" | "onCanPlay" | "onCanPlayCapture" | "onCanPlayThrough" | "onCanPlayThroughCapture" | "onDurationChange" | "onDurationChangeCapture" | "onEmptied" | "onEmptiedCapture" | "onEncrypted" | "onEncryptedCapture" | "onEnded" | "onEndedCapture" | "onLoadedData" | "onLoadedDataCapture" | "onLoadedMetadata" | "onLoadedMetadataCapture" | "onLoadStart" | "onLoadStartCapture" | "onPause" | "onPauseCapture" | "onPlay" | "onPlayCapture" | "onPlaying" | "onPlayingCapture" | "onProgress" | "onProgressCapture" | "onRateChange" | "onRateChangeCapture" | "onSeeked" | "onSeekedCapture" | "onSeeking" | "onSeekingCapture" | "onStalled" | "onStalledCapture" | "onSuspend" | "onSuspendCapture" | "onTimeUpdate" | "onTimeUpdateCapture" | "onVolumeChange" | "onVolumeChangeCapture" | "onWaiting" | "onWaitingCapture" | "onAuxClick" | "onAuxClickCapture" | "onClickCapture" | "onContextMenu" | "onContextMenuCapture" | "onDoubleClick" | "onDoubleClickCapture" | "onDrag" | "onDragCapture" | "onDragEnd" | "onDragEndCapture" | "onDragEnter" | "onDragEnterCapture" | "onDragExit" | "onDragExitCapture" | "onDragLeave" | "onDragLeaveCapture" | "onDragOver" | "onDragOverCapture" | "onDragStart" | "onDragStartCapture" | "onDrop" | "onDropCapture" | "onMouseDown" | "onMouseDownCapture" | "onMouseMove" | "onMouseMoveCapture" | "onMouseOut" | "onMouseOutCapture" | "onMouseOver" | "onMouseOverCapture" | "onMouseUp" | "onMouseUpCapture" | "onSelect" | "onSelectCapture" | "onTouchCancel" | "onTouchCancelCapture" | "onTouchEnd" | "onTouchEndCapture" | "onTouchMove" | "onTouchMoveCapture" | "onTouchStart" | "onTouchStartCapture" | "onPointerDown" | "onPointerDownCapture" | "onPointerMove" | "onPointerMoveCapture" | "onPointerUp" | "onPointerUpCapture" | "onPointerCancel" | "onPointerCancelCapture" | "onPointerEnter" | "onPointerEnterCapture" | "onPointerLeave" | "onPointerLeaveCapture" | "onPointerOver" | "onPointerOverCapture" | "onPointerOut" | "onPointerOutCapture" | "onGotPointerCapture" | "onGotPointerCaptureCapture" | "onLostPointerCapture" | "onLostPointerCaptureCapture" | "onScroll" | "onScrollCapture" | "onWheel" | "onWheelCapture" | "onAnimationStart" | "onAnimationStartCapture" | "onAnimationEnd" | "onAnimationEndCapture" | "onAnimationIteration" | "onAnimationIterationCapture" | "onTransitionEnd" | "onTransitionEndCapture" | "css" | "theme"> & React.RefAttributes<HTMLDivElement>>;
10
+ export declare const createEditorContentStyle: (styles?: SerializedStyles | undefined) => React.ForwardRefExoticComponent<Pick<Props, "cite" | "data" | "dir" | "form" | "label" | "slot" | "span" | "style" | "summary" | "title" | "default" | "mediaGroup" | "media" | "content" | "aria-label" | "aria-haspopup" | "children" | "theme" | "pattern" | "value" | "type" | "width" | "color" | "height" | "accessKey" | "draggable" | "hidden" | "lang" | "className" | "id" | "prefix" | "contentEditable" | "inputMode" | "nonce" | "tabIndex" | "defaultValue" | "onError" | "onChange" | "open" | "onFocus" | "onBlur" | "placeholder" | "autoFocus" | "name" | "key" | "action" | "disabled" | "property" | "target" | "start" | "onClick" | "onMouseEnter" | "onMouseLeave" | "selected" | "href" | "accept" | "acceptCharset" | "allowFullScreen" | "allowTransparency" | "alt" | "as" | "async" | "autoComplete" | "autoPlay" | "capture" | "cellPadding" | "cellSpacing" | "charSet" | "challenge" | "checked" | "classID" | "cols" | "colSpan" | "controls" | "coords" | "crossOrigin" | "dateTime" | "defer" | "download" | "encType" | "formAction" | "formEncType" | "formMethod" | "formNoValidate" | "formTarget" | "frameBorder" | "headers" | "high" | "hrefLang" | "htmlFor" | "httpEquiv" | "integrity" | "keyParams" | "keyType" | "kind" | "list" | "loop" | "low" | "manifest" | "marginHeight" | "marginWidth" | "max" | "maxLength" | "method" | "min" | "minLength" | "multiple" | "muted" | "noValidate" | "optimum" | "playsInline" | "poster" | "preload" | "readOnly" | "rel" | "required" | "reversed" | "rows" | "rowSpan" | "sandbox" | "scope" | "scoped" | "scrolling" | "seamless" | "shape" | "size" | "sizes" | "src" | "srcDoc" | "srcLang" | "srcSet" | "step" | "useMap" | "wmode" | "wrap" | "defaultChecked" | "suppressContentEditableWarning" | "suppressHydrationWarning" | "contextMenu" | "spellCheck" | "is" | "radioGroup" | "role" | "about" | "datatype" | "inlist" | "resource" | "typeof" | "vocab" | "autoCapitalize" | "autoCorrect" | "autoSave" | "itemProp" | "itemScope" | "itemType" | "itemID" | "itemRef" | "results" | "security" | "unselectable" | "aria-activedescendant" | "aria-atomic" | "aria-autocomplete" | "aria-busy" | "aria-checked" | "aria-colcount" | "aria-colindex" | "aria-colspan" | "aria-controls" | "aria-current" | "aria-describedby" | "aria-details" | "aria-disabled" | "aria-dropeffect" | "aria-errormessage" | "aria-expanded" | "aria-flowto" | "aria-grabbed" | "aria-hidden" | "aria-invalid" | "aria-keyshortcuts" | "aria-labelledby" | "aria-level" | "aria-live" | "aria-modal" | "aria-multiline" | "aria-multiselectable" | "aria-orientation" | "aria-owns" | "aria-placeholder" | "aria-posinset" | "aria-pressed" | "aria-readonly" | "aria-relevant" | "aria-required" | "aria-roledescription" | "aria-rowcount" | "aria-rowindex" | "aria-rowspan" | "aria-selected" | "aria-setsize" | "aria-sort" | "aria-valuemax" | "aria-valuemin" | "aria-valuenow" | "aria-valuetext" | "dangerouslySetInnerHTML" | "onCopy" | "onCopyCapture" | "onCut" | "onCutCapture" | "onPaste" | "onPasteCapture" | "onCompositionEnd" | "onCompositionEndCapture" | "onCompositionStart" | "onCompositionStartCapture" | "onCompositionUpdate" | "onCompositionUpdateCapture" | "onFocusCapture" | "onBlurCapture" | "onChangeCapture" | "onBeforeInput" | "onBeforeInputCapture" | "onInput" | "onInputCapture" | "onReset" | "onResetCapture" | "onSubmit" | "onSubmitCapture" | "onInvalid" | "onInvalidCapture" | "onLoad" | "onLoadCapture" | "onErrorCapture" | "onKeyDown" | "onKeyDownCapture" | "onKeyPress" | "onKeyPressCapture" | "onKeyUp" | "onKeyUpCapture" | "onAbort" | "onAbortCapture" | "onCanPlay" | "onCanPlayCapture" | "onCanPlayThrough" | "onCanPlayThroughCapture" | "onDurationChange" | "onDurationChangeCapture" | "onEmptied" | "onEmptiedCapture" | "onEncrypted" | "onEncryptedCapture" | "onEnded" | "onEndedCapture" | "onLoadedData" | "onLoadedDataCapture" | "onLoadedMetadata" | "onLoadedMetadataCapture" | "onLoadStart" | "onLoadStartCapture" | "onPause" | "onPauseCapture" | "onPlay" | "onPlayCapture" | "onPlaying" | "onPlayingCapture" | "onProgress" | "onProgressCapture" | "onRateChange" | "onRateChangeCapture" | "onSeeked" | "onSeekedCapture" | "onSeeking" | "onSeekingCapture" | "onStalled" | "onStalledCapture" | "onSuspend" | "onSuspendCapture" | "onTimeUpdate" | "onTimeUpdateCapture" | "onVolumeChange" | "onVolumeChangeCapture" | "onWaiting" | "onWaitingCapture" | "onAuxClick" | "onAuxClickCapture" | "onClickCapture" | "onContextMenu" | "onContextMenuCapture" | "onDoubleClick" | "onDoubleClickCapture" | "onDrag" | "onDragCapture" | "onDragEnd" | "onDragEndCapture" | "onDragEnter" | "onDragEnterCapture" | "onDragExit" | "onDragExitCapture" | "onDragLeave" | "onDragLeaveCapture" | "onDragOver" | "onDragOverCapture" | "onDragStart" | "onDragStartCapture" | "onDrop" | "onDropCapture" | "onMouseDown" | "onMouseDownCapture" | "onMouseMove" | "onMouseMoveCapture" | "onMouseOut" | "onMouseOutCapture" | "onMouseOver" | "onMouseOverCapture" | "onMouseUp" | "onMouseUpCapture" | "onSelect" | "onSelectCapture" | "onTouchCancel" | "onTouchCancelCapture" | "onTouchEnd" | "onTouchEndCapture" | "onTouchMove" | "onTouchMoveCapture" | "onTouchStart" | "onTouchStartCapture" | "onPointerDown" | "onPointerDownCapture" | "onPointerMove" | "onPointerMoveCapture" | "onPointerUp" | "onPointerUpCapture" | "onPointerCancel" | "onPointerCancelCapture" | "onPointerEnter" | "onPointerEnterCapture" | "onPointerLeave" | "onPointerLeaveCapture" | "onPointerOver" | "onPointerOverCapture" | "onPointerOut" | "onPointerOutCapture" | "onGotPointerCapture" | "onGotPointerCaptureCapture" | "onLostPointerCapture" | "onLostPointerCaptureCapture" | "onScroll" | "onScrollCapture" | "onWheel" | "onWheelCapture" | "onAnimationStart" | "onAnimationStartCapture" | "onAnimationEnd" | "onAnimationEndCapture" | "onAnimationIteration" | "onAnimationIterationCapture" | "onTransitionEnd" | "onTransitionEndCapture" | "css"> & React.RefAttributes<HTMLDivElement>>;
11
+ declare const _default: React.ForwardRefExoticComponent<Pick<Props, "cite" | "data" | "dir" | "form" | "label" | "slot" | "span" | "style" | "summary" | "title" | "default" | "mediaGroup" | "media" | "content" | "aria-label" | "aria-haspopup" | "children" | "theme" | "pattern" | "value" | "type" | "width" | "color" | "height" | "accessKey" | "draggable" | "hidden" | "lang" | "className" | "id" | "prefix" | "contentEditable" | "inputMode" | "nonce" | "tabIndex" | "defaultValue" | "onError" | "onChange" | "open" | "onFocus" | "onBlur" | "placeholder" | "autoFocus" | "name" | "key" | "action" | "disabled" | "property" | "target" | "start" | "onClick" | "onMouseEnter" | "onMouseLeave" | "selected" | "href" | "accept" | "acceptCharset" | "allowFullScreen" | "allowTransparency" | "alt" | "as" | "async" | "autoComplete" | "autoPlay" | "capture" | "cellPadding" | "cellSpacing" | "charSet" | "challenge" | "checked" | "classID" | "cols" | "colSpan" | "controls" | "coords" | "crossOrigin" | "dateTime" | "defer" | "download" | "encType" | "formAction" | "formEncType" | "formMethod" | "formNoValidate" | "formTarget" | "frameBorder" | "headers" | "high" | "hrefLang" | "htmlFor" | "httpEquiv" | "integrity" | "keyParams" | "keyType" | "kind" | "list" | "loop" | "low" | "manifest" | "marginHeight" | "marginWidth" | "max" | "maxLength" | "method" | "min" | "minLength" | "multiple" | "muted" | "noValidate" | "optimum" | "playsInline" | "poster" | "preload" | "readOnly" | "rel" | "required" | "reversed" | "rows" | "rowSpan" | "sandbox" | "scope" | "scoped" | "scrolling" | "seamless" | "shape" | "size" | "sizes" | "src" | "srcDoc" | "srcLang" | "srcSet" | "step" | "useMap" | "wmode" | "wrap" | "defaultChecked" | "suppressContentEditableWarning" | "suppressHydrationWarning" | "contextMenu" | "spellCheck" | "is" | "radioGroup" | "role" | "about" | "datatype" | "inlist" | "resource" | "typeof" | "vocab" | "autoCapitalize" | "autoCorrect" | "autoSave" | "itemProp" | "itemScope" | "itemType" | "itemID" | "itemRef" | "results" | "security" | "unselectable" | "aria-activedescendant" | "aria-atomic" | "aria-autocomplete" | "aria-busy" | "aria-checked" | "aria-colcount" | "aria-colindex" | "aria-colspan" | "aria-controls" | "aria-current" | "aria-describedby" | "aria-details" | "aria-disabled" | "aria-dropeffect" | "aria-errormessage" | "aria-expanded" | "aria-flowto" | "aria-grabbed" | "aria-hidden" | "aria-invalid" | "aria-keyshortcuts" | "aria-labelledby" | "aria-level" | "aria-live" | "aria-modal" | "aria-multiline" | "aria-multiselectable" | "aria-orientation" | "aria-owns" | "aria-placeholder" | "aria-posinset" | "aria-pressed" | "aria-readonly" | "aria-relevant" | "aria-required" | "aria-roledescription" | "aria-rowcount" | "aria-rowindex" | "aria-rowspan" | "aria-selected" | "aria-setsize" | "aria-sort" | "aria-valuemax" | "aria-valuemin" | "aria-valuenow" | "aria-valuetext" | "dangerouslySetInnerHTML" | "onCopy" | "onCopyCapture" | "onCut" | "onCutCapture" | "onPaste" | "onPasteCapture" | "onCompositionEnd" | "onCompositionEndCapture" | "onCompositionStart" | "onCompositionStartCapture" | "onCompositionUpdate" | "onCompositionUpdateCapture" | "onFocusCapture" | "onBlurCapture" | "onChangeCapture" | "onBeforeInput" | "onBeforeInputCapture" | "onInput" | "onInputCapture" | "onReset" | "onResetCapture" | "onSubmit" | "onSubmitCapture" | "onInvalid" | "onInvalidCapture" | "onLoad" | "onLoadCapture" | "onErrorCapture" | "onKeyDown" | "onKeyDownCapture" | "onKeyPress" | "onKeyPressCapture" | "onKeyUp" | "onKeyUpCapture" | "onAbort" | "onAbortCapture" | "onCanPlay" | "onCanPlayCapture" | "onCanPlayThrough" | "onCanPlayThroughCapture" | "onDurationChange" | "onDurationChangeCapture" | "onEmptied" | "onEmptiedCapture" | "onEncrypted" | "onEncryptedCapture" | "onEnded" | "onEndedCapture" | "onLoadedData" | "onLoadedDataCapture" | "onLoadedMetadata" | "onLoadedMetadataCapture" | "onLoadStart" | "onLoadStartCapture" | "onPause" | "onPauseCapture" | "onPlay" | "onPlayCapture" | "onPlaying" | "onPlayingCapture" | "onProgress" | "onProgressCapture" | "onRateChange" | "onRateChangeCapture" | "onSeeked" | "onSeekedCapture" | "onSeeking" | "onSeekingCapture" | "onStalled" | "onStalledCapture" | "onSuspend" | "onSuspendCapture" | "onTimeUpdate" | "onTimeUpdateCapture" | "onVolumeChange" | "onVolumeChangeCapture" | "onWaiting" | "onWaitingCapture" | "onAuxClick" | "onAuxClickCapture" | "onClickCapture" | "onContextMenu" | "onContextMenuCapture" | "onDoubleClick" | "onDoubleClickCapture" | "onDrag" | "onDragCapture" | "onDragEnd" | "onDragEndCapture" | "onDragEnter" | "onDragEnterCapture" | "onDragExit" | "onDragExitCapture" | "onDragLeave" | "onDragLeaveCapture" | "onDragOver" | "onDragOverCapture" | "onDragStart" | "onDragStartCapture" | "onDrop" | "onDropCapture" | "onMouseDown" | "onMouseDownCapture" | "onMouseMove" | "onMouseMoveCapture" | "onMouseOut" | "onMouseOutCapture" | "onMouseOver" | "onMouseOverCapture" | "onMouseUp" | "onMouseUpCapture" | "onSelect" | "onSelectCapture" | "onTouchCancel" | "onTouchCancelCapture" | "onTouchEnd" | "onTouchEndCapture" | "onTouchMove" | "onTouchMoveCapture" | "onTouchStart" | "onTouchStartCapture" | "onPointerDown" | "onPointerDownCapture" | "onPointerMove" | "onPointerMoveCapture" | "onPointerUp" | "onPointerUpCapture" | "onPointerCancel" | "onPointerCancelCapture" | "onPointerEnter" | "onPointerEnterCapture" | "onPointerLeave" | "onPointerLeaveCapture" | "onPointerOver" | "onPointerOverCapture" | "onPointerOut" | "onPointerOutCapture" | "onGotPointerCapture" | "onGotPointerCaptureCapture" | "onLostPointerCapture" | "onLostPointerCaptureCapture" | "onScroll" | "onScrollCapture" | "onWheel" | "onWheelCapture" | "onAnimationStart" | "onAnimationStartCapture" | "onAnimationEnd" | "onAnimationEndCapture" | "onAnimationIteration" | "onAnimationIterationCapture" | "onTransitionEnd" | "onTransitionEndCapture" | "css"> & React.RefAttributes<HTMLDivElement>>;
12
12
  export default _default;
@@ -0,0 +1,6 @@
1
+ import React from 'react';
2
+ import type { ThemeModes } from '@atlaskit/theme/types';
3
+ export declare function PortalProviderThemeProviders(props: {
4
+ mode: ThemeModes;
5
+ children: React.ReactNode;
6
+ }): JSX.Element;
@@ -2,10 +2,12 @@ import React from 'react';
2
2
  import { EventDispatcher } from '../../event-dispatcher';
3
3
  import { FireAnalyticsCallback } from '../../plugins/analytics/fire-analytics-event';
4
4
  import { IntlShape, WrappedComponentProps } from 'react-intl-next';
5
+ import type { ThemeModes } from '@atlaskit/theme/types';
5
6
  export declare type BasePortalProviderProps = {
6
7
  render: (portalProviderAPI: PortalProviderAPI) => React.ReactChild | JSX.Element | null;
7
8
  onAnalyticsEvent?: FireAnalyticsCallback;
8
9
  useAnalyticsContext?: boolean;
10
+ themeMode?: ThemeModes;
9
11
  } & WrappedComponentProps;
10
12
  export declare type Portals = Map<HTMLElement, React.ReactChild>;
11
13
  export declare type PortalRendererState = {
@@ -22,7 +24,8 @@ export declare class PortalProviderAPI extends EventDispatcher {
22
24
  intl: IntlShape;
23
25
  onAnalyticsEvent?: FireAnalyticsCallback;
24
26
  useAnalyticsContext?: boolean;
25
- constructor(intl: IntlShape, onAnalyticsEvent?: FireAnalyticsCallback, analyticsContext?: boolean);
27
+ themeMode?: ThemeModes;
28
+ constructor(intl: IntlShape, onAnalyticsEvent?: FireAnalyticsCallback, analyticsContext?: boolean, themeMode?: ThemeModes);
26
29
  setContext: (context: any) => void;
27
30
  render(children: () => React.ReactChild | JSX.Element | null, container: HTMLElement, hasAnalyticsContext?: boolean, hasIntlContext?: boolean): void;
28
31
  forceUpdate({ intl }: {
@@ -33,6 +36,7 @@ export declare class PortalProviderAPI extends EventDispatcher {
33
36
  export declare const PortalProvider: React.FC<import("react-intl-next").WithIntlProps<BasePortalProviderProps>> & {
34
37
  WrappedComponent: React.ComponentType<BasePortalProviderProps>;
35
38
  };
39
+ export declare const PortalProviderWithThemeProviders: (props: Omit<BasePortalProviderProps, 'intl' | 'themeMode'>) => JSX.Element;
36
40
  export declare class PortalRenderer extends React.Component<{
37
41
  portalProviderAPI: PortalProviderAPI;
38
42
  }, PortalRendererState> {
@@ -0,0 +1 @@
1
+ export declare function checkIfMobileBridge(): boolean;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@atlaskit/editor-core",
3
- "version": "164.0.3",
3
+ "version": "166.0.0",
4
4
  "description": "A package contains Atlassian editor core functionality",
5
5
  "publishConfig": {
6
6
  "registry": "https://registry.npmjs.org/"
@@ -42,26 +42,26 @@
42
42
  "@atlaskit/date": "^0.9.0",
43
43
  "@atlaskit/datetime-picker": "^11.1.0",
44
44
  "@atlaskit/droplist": "^11.0.0",
45
- "@atlaskit/editor-common": "^66.0.0",
45
+ "@atlaskit/editor-common": "^67.0.0",
46
46
  "@atlaskit/editor-json-transformer": "^8.7.0",
47
47
  "@atlaskit/editor-markdown-transformer": "^4.1.0",
48
- "@atlaskit/editor-shared-styles": "^2.0.0",
48
+ "@atlaskit/editor-shared-styles": "^2.1.0",
49
49
  "@atlaskit/editor-tables": "^2.1.0",
50
- "@atlaskit/emoji": "^64.5.0",
50
+ "@atlaskit/emoji": "^64.6.0",
51
51
  "@atlaskit/empty-state": "^7.3.0",
52
52
  "@atlaskit/form": "^8.5.0",
53
53
  "@atlaskit/icon": "^21.10.0",
54
54
  "@atlaskit/icon-object": "^6.2.0",
55
55
  "@atlaskit/item": "^12.0.0",
56
56
  "@atlaskit/locale": "^2.3.0",
57
- "@atlaskit/logo": "^13.5.0",
58
- "@atlaskit/media-card": "^73.5.0",
59
- "@atlaskit/media-client": "^15.1.0",
60
- "@atlaskit/media-common": "^2.12.0",
61
- "@atlaskit/media-filmstrip": "^43.0.0",
62
- "@atlaskit/media-picker": "^61.0.0",
63
- "@atlaskit/media-ui": "^21.1.0",
64
- "@atlaskit/media-viewer": "^46.2.0",
57
+ "@atlaskit/logo": "^13.6.0",
58
+ "@atlaskit/media-card": "^73.6.0",
59
+ "@atlaskit/media-client": "^16.0.0",
60
+ "@atlaskit/media-common": "^2.13.0",
61
+ "@atlaskit/media-filmstrip": "^44.0.0",
62
+ "@atlaskit/media-picker": "^62.0.0",
63
+ "@atlaskit/media-ui": "^22.0.0",
64
+ "@atlaskit/media-viewer": "^46.3.0",
65
65
  "@atlaskit/mention": "^21.0.0",
66
66
  "@atlaskit/menu": "^1.3.0",
67
67
  "@atlaskit/modal-dialog": "^12.2.0",
@@ -127,17 +127,18 @@
127
127
  "w3c-keyname": "^2.1.0"
128
128
  },
129
129
  "peerDependencies": {
130
- "@atlaskit/media-core": "^32.3.1",
131
- "@atlaskit/smart-card": "^18.0.14",
130
+ "@atlaskit/media-core": "^33.0.0",
131
+ "@atlaskit/smart-card": "^19.1.0",
132
132
  "react": "^16.8.0",
133
133
  "react-dom": "^16.8.0",
134
- "react-intl-next": "npm:react-intl@^5.18.1"
134
+ "react-intl-next": "npm:react-intl@^5.18.1",
135
+ "styled-components": "^3.2.6"
135
136
  },
136
137
  "devDependencies": {
137
- "@atlaskit/atlassian-navigation": "^2.1.0",
138
- "@atlaskit/breadcrumbs": "11.5.7",
138
+ "@atlaskit/atlassian-navigation": "^2.2.0",
139
+ "@atlaskit/breadcrumbs": "11.6.0",
139
140
  "@atlaskit/code": "^14.3.0",
140
- "@atlaskit/collab-provider": "7.3.1",
141
+ "@atlaskit/collab-provider": "7.4.0",
141
142
  "@atlaskit/docs": "*",
142
143
  "@atlaskit/drawer": "^7.1.0",
143
144
  "@atlaskit/dropdown-menu": "^11.1.0",
@@ -147,17 +148,17 @@
147
148
  "@atlaskit/flag": "^14.5.0",
148
149
  "@atlaskit/inline-dialog": "^13.3.0",
149
150
  "@atlaskit/lozenge": "^11.1.0",
150
- "@atlaskit/media-core": "^32.3.0",
151
+ "@atlaskit/media-core": "^33.0.0",
151
152
  "@atlaskit/media-integration-test-helpers": "^2.6.0",
152
- "@atlaskit/media-test-helpers": "^29.4.0",
153
+ "@atlaskit/media-test-helpers": "^30.0.0",
153
154
  "@atlaskit/menu": "^1.3.0",
154
155
  "@atlaskit/page-layout": "^1.2.0",
155
156
  "@atlaskit/profilecard": "^16.4.0",
156
157
  "@atlaskit/pubsub": "^6.0.0",
157
- "@atlaskit/renderer": "^93.0.0",
158
+ "@atlaskit/renderer": "^95.0.0",
158
159
  "@atlaskit/section-message": "^6.1.0",
159
160
  "@atlaskit/share": "*",
160
- "@atlaskit/smart-card": "^18.0.0",
161
+ "@atlaskit/smart-card": "^19.1.0",
161
162
  "@atlaskit/smart-user-picker": "^5.0.2",
162
163
  "@atlaskit/synchrony-test-helpers": "^2.3.0",
163
164
  "@atlaskit/textarea": "^4.3.0",
@@ -167,7 +168,7 @@
167
168
  "@atlaskit/visual-regression": "*",
168
169
  "@atlaskit/webdriver-runner": "*",
169
170
  "@atlassian/atlassian-frontend-prettier-config-1.0.1": "npm:@atlassian/atlassian-frontend-prettier-config@1.0.1",
170
- "@atlassian/search-provider": "2.2.3",
171
+ "@atlassian/search-provider": "2.2.4",
171
172
  "@atlassian/ufo": "^0.1.0",
172
173
  "@emotion/jest": "^11.8.0",
173
174
  "@testing-library/dom": "^7.7.3",
@@ -1,250 +0,0 @@
1
- "use strict";
2
-
3
- var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
4
-
5
- Object.defineProperty(exports, "__esModule", {
6
- value: true
7
- });
8
- exports.EmojiNodeView = void 0;
9
- exports.default = emojiNodeView;
10
-
11
- var _regenerator = _interopRequireDefault(require("@babel/runtime/regenerator"));
12
-
13
- var _asyncToGenerator2 = _interopRequireDefault(require("@babel/runtime/helpers/asyncToGenerator"));
14
-
15
- var _classCallCheck2 = _interopRequireDefault(require("@babel/runtime/helpers/classCallCheck"));
16
-
17
- var _createClass2 = _interopRequireDefault(require("@babel/runtime/helpers/createClass"));
18
-
19
- var _defineProperty2 = _interopRequireDefault(require("@babel/runtime/helpers/defineProperty"));
20
-
21
- var _prosemirrorModel = require("prosemirror-model");
22
-
23
- var _utils = require("@atlaskit/editor-common/utils");
24
-
25
- var EmojiNodeView = /*#__PURE__*/function () {
26
- function EmojiNodeView(node, _, context) {
27
- var _this = this,
28
- _this$options;
29
-
30
- (0, _classCallCheck2.default)(this, EmojiNodeView);
31
- (0, _defineProperty2.default)(this, "hasProvider", false);
32
- (0, _defineProperty2.default)(this, "subscribe", function (_, provider) {
33
- _this.hasProvider = false;
34
- _this.emojiProvider = provider;
35
- provider === null || provider === void 0 ? void 0 : provider.then(function () {
36
- return _this.hasProvider = true;
37
- }).then(function () {
38
- return _this.findEmoji();
39
- }).then(function (emoji) {
40
- return _this.update(_this.node, null, emoji);
41
- });
42
- });
43
- this.node = node;
44
- this.providers = context.providerFactory;
45
- this.options = context.options;
46
- this.dom = EmojiNodeView.toDom(node);
47
- this.el = this.dom;
48
- this.providers.subscribe('emojiProvider', this.subscribe);
49
-
50
- if ((_this$options = this.options) !== null && _this$options !== void 0 && _this$options.allowZeroWidthSpaceAfter) {
51
- this.el.after(document.createTextNode(_utils.ZERO_WIDTH_SPACE));
52
- }
53
-
54
- this.update(this.node, null);
55
- }
56
-
57
- (0, _createClass2.default)(EmojiNodeView, [{
58
- key: "findEmoji",
59
- value: function () {
60
- var _findEmoji = (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function _callee() {
61
- var node,
62
- emojiProvider,
63
- _args = arguments;
64
- return _regenerator.default.wrap(function _callee$(_context) {
65
- while (1) {
66
- switch (_context.prev = _context.next) {
67
- case 0:
68
- node = _args.length > 0 && _args[0] !== undefined ? _args[0] : this.node;
69
- _context.next = 3;
70
- return this.emojiProvider;
71
-
72
- case 3:
73
- emojiProvider = _context.sent;
74
-
75
- if (!emojiProvider) {
76
- _context.next = 6;
77
- break;
78
- }
79
-
80
- return _context.abrupt("return", emojiProvider.findByEmojiId({
81
- id: node.attrs.id,
82
- shortName: node.attrs.shortName,
83
- fallback: node.attrs.text
84
- }));
85
-
86
- case 6:
87
- case "end":
88
- return _context.stop();
89
- }
90
- }
91
- }, _callee, this);
92
- }));
93
-
94
- function findEmoji() {
95
- return _findEmoji.apply(this, arguments);
96
- }
97
-
98
- return findEmoji;
99
- }()
100
- }, {
101
- key: "destroy",
102
- value: function destroy() {
103
- this.providers.unsubscribe('emojiProvider', this.subscribe);
104
- }
105
- }, {
106
- key: "update",
107
- value: function update(node, _) {
108
- var _this2 = this;
109
-
110
- var emoji = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : this.emoji;
111
-
112
- if (this.node.type !== node.type) {
113
- this.node = node;
114
- return false;
115
- }
116
-
117
- var prev = this.node.attrs;
118
- var next = node.attrs;
119
- var changed = false;
120
-
121
- if (prev.id !== next.id) {
122
- changed = true;
123
- this.el.dataset.emojiId = next.id;
124
- }
125
-
126
- if (prev.shortName !== next.shortName) {
127
- changed = true;
128
- this.el.dataset.emojiShortname = next.shortName;
129
- }
130
-
131
- if (changed) {
132
- this.emoji = undefined;
133
- this.node = node;
134
- this.findEmoji().then(function (emoji) {
135
- return _this2.update(_this2.node, _, emoji);
136
- });
137
- return true;
138
- }
139
-
140
- if (!this.hasProvider) {
141
- this.el.classList.add('editor-emoji-loading');
142
- this.el.style.backgroundSize = '';
143
- this.el.style.backgroundPosition = '';
144
- this.el.style.backgroundImage = '';
145
- this.node = node;
146
- this.emoji = emoji;
147
- return true;
148
- } else {
149
- this.el.classList.remove('editor-emoji-loading');
150
- }
151
-
152
- if (!emoji) {
153
- this.el.classList.add('editor-emoji-fallback');
154
- this.el.style.backgroundSize = '';
155
- this.el.style.backgroundPosition = '';
156
- this.el.style.backgroundImage = '';
157
- this.node = node;
158
- this.emoji = emoji;
159
- return true;
160
- } else {
161
- this.el.classList.remove('editor-emoji-fallback');
162
- }
163
-
164
- if (this.emoji === emoji) {
165
- return true;
166
- }
167
-
168
- var representation = emoji === null || emoji === void 0 ? void 0 : emoji.representation;
169
-
170
- if (EmojiNodeView.isSprite(representation)) {
171
- var sprite = representation.sprite,
172
- xIndex = representation.xIndex,
173
- yIndex = representation.yIndex;
174
- var row = sprite.row,
175
- column = sprite.column,
176
- url = sprite.url;
177
- var xPosition = 100 / (column - 1) * (xIndex - 0);
178
- var yPosition = 100 / (row - 1) * (yIndex - 0);
179
- this.el.style.backgroundSize = "".concat(column * 100, "% ").concat(row * 100, "%");
180
- this.el.style.backgroundPosition = "".concat(xPosition, "% ").concat(yPosition, "%");
181
- this.el.style.backgroundImage = "url(".concat(url, ")");
182
- }
183
-
184
- if (EmojiNodeView.isImage(representation) || EmojiNodeView.isMedia(representation)) {
185
- var path = EmojiNodeView.isImage(representation) ? representation.imagePath : representation.mediaPath;
186
- var rawWidth = representation.width,
187
- rawHeight = representation.height;
188
- var width = rawWidth / (rawHeight / 20);
189
- this.el.style.width = "".concat(width, "px");
190
- this.el.style.backgroundImage = "url(".concat(path, ")");
191
- }
192
-
193
- this.emoji = emoji;
194
- return true;
195
- }
196
- }, {
197
- key: "ignoreMutation",
198
- value: function ignoreMutation(_) {
199
- return true;
200
- }
201
- }], [{
202
- key: "toDomSpec",
203
- value: function toDomSpec(node) {
204
- return ['span', {
205
- 'aria-label': node.attrs.shortName,
206
- 'data-emoji-id': node.attrs.id,
207
- 'data-emoji-shortname': node.attrs.shortName,
208
- class: 'editor-emoji'
209
- }, node.attrs.shortName];
210
- }
211
- }, {
212
- key: "toDom",
213
- value: function toDom(node) {
214
- return _prosemirrorModel.DOMSerializer.renderSpec(document, EmojiNodeView.toDomSpec(node)).dom;
215
- }
216
- }, {
217
- key: "isSprite",
218
- value: function isSprite(representation) {
219
- var _representation$hasOw;
220
-
221
- return (_representation$hasOw = representation === null || representation === void 0 ? void 0 : representation.hasOwnProperty('sprite')) !== null && _representation$hasOw !== void 0 ? _representation$hasOw : false;
222
- }
223
- }, {
224
- key: "isImage",
225
- value: function isImage(representation) {
226
- var _representation$hasOw2;
227
-
228
- return (_representation$hasOw2 = representation === null || representation === void 0 ? void 0 : representation.hasOwnProperty('imagePath')) !== null && _representation$hasOw2 !== void 0 ? _representation$hasOw2 : false;
229
- }
230
- }, {
231
- key: "isMedia",
232
- value: function isMedia(representation) {
233
- var _representation$hasOw3;
234
-
235
- return (_representation$hasOw3 = representation === null || representation === void 0 ? void 0 : representation.hasOwnProperty('mediaPath')) !== null && _representation$hasOw3 !== void 0 ? _representation$hasOw3 : false;
236
- }
237
- }]);
238
- return EmojiNodeView;
239
- }();
240
-
241
- exports.EmojiNodeView = EmojiNodeView;
242
-
243
- function emojiNodeView(providerFactory, options) {
244
- return function (node, view) {
245
- return new EmojiNodeView(node, view, {
246
- providerFactory: providerFactory,
247
- options: options
248
- });
249
- };
250
- }
@@ -1,177 +0,0 @@
1
- import _defineProperty from "@babel/runtime/helpers/defineProperty";
2
- import { DOMSerializer } from 'prosemirror-model';
3
- import { ZERO_WIDTH_SPACE } from '@atlaskit/editor-common/utils';
4
- export class EmojiNodeView {
5
- constructor(node, _, context) {
6
- var _this$options;
7
-
8
- _defineProperty(this, "hasProvider", false);
9
-
10
- _defineProperty(this, "subscribe", (_, provider) => {
11
- this.hasProvider = false;
12
- this.emojiProvider = provider;
13
- provider === null || provider === void 0 ? void 0 : provider.then(() => this.hasProvider = true).then(() => this.findEmoji()).then(emoji => this.update(this.node, null, emoji));
14
- });
15
-
16
- this.node = node;
17
- this.providers = context.providerFactory;
18
- this.options = context.options;
19
- this.dom = EmojiNodeView.toDom(node);
20
- this.el = this.dom;
21
- this.providers.subscribe('emojiProvider', this.subscribe);
22
-
23
- if ((_this$options = this.options) !== null && _this$options !== void 0 && _this$options.allowZeroWidthSpaceAfter) {
24
- this.el.after(document.createTextNode(ZERO_WIDTH_SPACE));
25
- }
26
-
27
- this.update(this.node, null);
28
- }
29
-
30
- static toDomSpec(node) {
31
- return ['span', {
32
- 'aria-label': node.attrs.shortName,
33
- 'data-emoji-id': node.attrs.id,
34
- 'data-emoji-shortname': node.attrs.shortName,
35
- class: 'editor-emoji'
36
- }, node.attrs.shortName];
37
- }
38
-
39
- static toDom(node) {
40
- return DOMSerializer.renderSpec(document, EmojiNodeView.toDomSpec(node)).dom;
41
- }
42
-
43
- static isSprite(representation) {
44
- var _representation$hasOw;
45
-
46
- return (_representation$hasOw = representation === null || representation === void 0 ? void 0 : representation.hasOwnProperty('sprite')) !== null && _representation$hasOw !== void 0 ? _representation$hasOw : false;
47
- }
48
-
49
- static isImage(representation) {
50
- var _representation$hasOw2;
51
-
52
- return (_representation$hasOw2 = representation === null || representation === void 0 ? void 0 : representation.hasOwnProperty('imagePath')) !== null && _representation$hasOw2 !== void 0 ? _representation$hasOw2 : false;
53
- }
54
-
55
- static isMedia(representation) {
56
- var _representation$hasOw3;
57
-
58
- return (_representation$hasOw3 = representation === null || representation === void 0 ? void 0 : representation.hasOwnProperty('mediaPath')) !== null && _representation$hasOw3 !== void 0 ? _representation$hasOw3 : false;
59
- }
60
-
61
- async findEmoji(node = this.node) {
62
- const emojiProvider = await this.emojiProvider;
63
-
64
- if (emojiProvider) {
65
- return emojiProvider.findByEmojiId({
66
- id: node.attrs.id,
67
- shortName: node.attrs.shortName,
68
- fallback: node.attrs.text
69
- });
70
- }
71
- }
72
-
73
- destroy() {
74
- this.providers.unsubscribe('emojiProvider', this.subscribe);
75
- }
76
-
77
- update(node, _, emoji = this.emoji) {
78
- if (this.node.type !== node.type) {
79
- this.node = node;
80
- return false;
81
- }
82
-
83
- const prev = this.node.attrs;
84
- const next = node.attrs;
85
- let changed = false;
86
-
87
- if (prev.id !== next.id) {
88
- changed = true;
89
- this.el.dataset.emojiId = next.id;
90
- }
91
-
92
- if (prev.shortName !== next.shortName) {
93
- changed = true;
94
- this.el.dataset.emojiShortname = next.shortName;
95
- }
96
-
97
- if (changed) {
98
- this.emoji = undefined;
99
- this.node = node;
100
- this.findEmoji().then(emoji => this.update(this.node, _, emoji));
101
- return true;
102
- }
103
-
104
- if (!this.hasProvider) {
105
- this.el.classList.add('editor-emoji-loading');
106
- this.el.style.backgroundSize = '';
107
- this.el.style.backgroundPosition = '';
108
- this.el.style.backgroundImage = '';
109
- this.node = node;
110
- this.emoji = emoji;
111
- return true;
112
- } else {
113
- this.el.classList.remove('editor-emoji-loading');
114
- }
115
-
116
- if (!emoji) {
117
- this.el.classList.add('editor-emoji-fallback');
118
- this.el.style.backgroundSize = '';
119
- this.el.style.backgroundPosition = '';
120
- this.el.style.backgroundImage = '';
121
- this.node = node;
122
- this.emoji = emoji;
123
- return true;
124
- } else {
125
- this.el.classList.remove('editor-emoji-fallback');
126
- }
127
-
128
- if (this.emoji === emoji) {
129
- return true;
130
- }
131
-
132
- const representation = emoji === null || emoji === void 0 ? void 0 : emoji.representation;
133
-
134
- if (EmojiNodeView.isSprite(representation)) {
135
- const {
136
- sprite,
137
- xIndex,
138
- yIndex
139
- } = representation;
140
- const {
141
- row,
142
- column,
143
- url
144
- } = sprite;
145
- const xPosition = 100 / (column - 1) * (xIndex - 0);
146
- const yPosition = 100 / (row - 1) * (yIndex - 0);
147
- this.el.style.backgroundSize = `${column * 100}% ${row * 100}%`;
148
- this.el.style.backgroundPosition = `${xPosition}% ${yPosition}%`;
149
- this.el.style.backgroundImage = `url(${url})`;
150
- }
151
-
152
- if (EmojiNodeView.isImage(representation) || EmojiNodeView.isMedia(representation)) {
153
- const path = EmojiNodeView.isImage(representation) ? representation.imagePath : representation.mediaPath;
154
- const {
155
- width: rawWidth,
156
- height: rawHeight
157
- } = representation;
158
- const width = rawWidth / (rawHeight / 20);
159
- this.el.style.width = `${width}px`;
160
- this.el.style.backgroundImage = `url(${path})`;
161
- }
162
-
163
- this.emoji = emoji;
164
- return true;
165
- }
166
-
167
- ignoreMutation(_) {
168
- return true;
169
- }
170
-
171
- }
172
- export default function emojiNodeView(providerFactory, options) {
173
- return (node, view) => new EmojiNodeView(node, view, {
174
- providerFactory,
175
- options
176
- });
177
- }