@atlaskit/editor-core 192.7.0 → 193.1.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 (120) hide show
  1. package/CHANGELOG.md +20 -0
  2. package/dist/cjs/CollapsedEditor/index.js +3 -3
  3. package/dist/cjs/EditorWithActions/index.js +1 -1
  4. package/dist/cjs/create-editor/ErrorBoundary.js +1 -1
  5. package/dist/cjs/create-editor/ReactEditorView.js +1 -1
  6. package/dist/cjs/create-editor/create-plugins-list.js +0 -1
  7. package/dist/cjs/create-editor/index.js +2 -2
  8. package/dist/cjs/editor.js +1 -1
  9. package/dist/cjs/messages.js +2 -2
  10. package/dist/cjs/nodeviews/context-adapter.js +1 -1
  11. package/dist/cjs/preset-universal.js +8 -1
  12. package/dist/cjs/presets/context.js +2 -2
  13. package/dist/cjs/presets/default.js +1 -2
  14. package/dist/cjs/presets/universal.js +1 -1
  15. package/dist/cjs/ui/Addon/ClickAreaBlock/index.js +5 -3
  16. package/dist/cjs/ui/Addon/ClickAreaInline/index.js +4 -3
  17. package/dist/cjs/ui/Addon/ClickAreaMobile/index.js +1 -1
  18. package/dist/cjs/ui/Addon/Dropdown/index.js +1 -1
  19. package/dist/cjs/ui/Appearance/Chromeless.js +3 -3
  20. package/dist/cjs/ui/Appearance/Comment/Comment.js +5 -5
  21. package/dist/cjs/ui/Appearance/Comment/Toolbar.js +16 -5
  22. package/dist/cjs/ui/Appearance/FullPage/FullPage.js +2 -2
  23. package/dist/cjs/ui/Appearance/FullPage/FullPageContentArea.js +2 -2
  24. package/dist/cjs/ui/Appearance/FullPage/FullPageToolbar.js +2 -2
  25. package/dist/cjs/ui/Appearance/FullPage/StyledComponents.js +2 -4
  26. package/dist/cjs/ui/AppearanceComponents/Mobile.js +4 -2
  27. package/dist/cjs/ui/ChromeCollapsed/index.js +3 -3
  28. package/dist/cjs/ui/CollapsedEditor/index.js +1 -1
  29. package/dist/cjs/ui/ContentStyles/expand.js +6 -3
  30. package/dist/cjs/ui/ContentStyles/extension.js +1 -1
  31. package/dist/cjs/ui/ContentStyles/index.js +19 -5
  32. package/dist/cjs/ui/ContentStyles/media.js +1 -0
  33. package/dist/cjs/ui/ContentStyles/panel.js +1 -0
  34. package/dist/cjs/ui/ContentStyles/tasks-and-decisions.js +1 -0
  35. package/dist/cjs/ui/ContextPanel/index.js +3 -3
  36. package/dist/cjs/ui/EditorContext/index.js +1 -1
  37. package/dist/cjs/ui/ErrorBoundary/index.js +1 -1
  38. package/dist/cjs/ui/PluginSlot/index.js +1 -1
  39. package/dist/cjs/ui/Toolbar/ToolbarInner.js +1 -1
  40. package/dist/cjs/ui/Toolbar/ToolbarWithSizeDetector.js +2 -2
  41. package/dist/cjs/ui/ToolbarFeedback/index.js +1 -1
  42. package/dist/cjs/ui/WithEditorActions/index.js +1 -1
  43. package/dist/cjs/ui/WithFlash/index.js +28 -8
  44. package/dist/cjs/ui/WithHelpTrigger/index.js +1 -1
  45. package/dist/cjs/utils/performance/instrumented-plugin.js +1 -1
  46. package/dist/cjs/version-wrapper.js +1 -1
  47. package/dist/es2019/create-editor/ReactEditorView.js +0 -1
  48. package/dist/es2019/create-editor/create-plugins-list.js +0 -1
  49. package/dist/es2019/preset-universal.js +2 -1
  50. package/dist/es2019/presets/default.js +1 -2
  51. package/dist/es2019/presets/universal.js +1 -1
  52. package/dist/es2019/ui/Addon/ClickAreaBlock/index.js +4 -4
  53. package/dist/es2019/ui/Addon/ClickAreaInline/index.js +3 -3
  54. package/dist/es2019/ui/Appearance/Comment/Comment.js +2 -3
  55. package/dist/es2019/ui/Appearance/Comment/Toolbar.js +24 -15
  56. package/dist/es2019/ui/Appearance/FullPage/StyledComponents.js +2 -4
  57. package/dist/es2019/ui/AppearanceComponents/Mobile.js +2 -0
  58. package/dist/es2019/ui/ContentStyles/expand.js +4 -3
  59. package/dist/es2019/ui/ContentStyles/extension.js +1 -1
  60. package/dist/es2019/ui/ContentStyles/index.js +13 -13
  61. package/dist/es2019/ui/ContentStyles/media.js +1 -0
  62. package/dist/es2019/ui/ContentStyles/panel.js +1 -0
  63. package/dist/es2019/ui/ContentStyles/tasks-and-decisions.js +1 -0
  64. package/dist/es2019/ui/WithFlash/index.js +29 -32
  65. package/dist/es2019/version-wrapper.js +1 -1
  66. package/dist/esm/CollapsedEditor/index.js +1 -1
  67. package/dist/esm/EditorWithActions/index.js +1 -1
  68. package/dist/esm/create-editor/ErrorBoundary.js +1 -1
  69. package/dist/esm/create-editor/ReactEditorView.js +1 -1
  70. package/dist/esm/create-editor/create-plugins-list.js +0 -1
  71. package/dist/esm/editor.js +1 -1
  72. package/dist/esm/nodeviews/context-adapter.js +1 -1
  73. package/dist/esm/preset-universal.js +2 -1
  74. package/dist/esm/presets/default.js +1 -2
  75. package/dist/esm/presets/universal.js +1 -1
  76. package/dist/esm/ui/Addon/ClickAreaBlock/index.js +4 -3
  77. package/dist/esm/ui/Addon/ClickAreaInline/index.js +3 -3
  78. package/dist/esm/ui/Addon/ClickAreaMobile/index.js +1 -1
  79. package/dist/esm/ui/Addon/Dropdown/index.js +1 -1
  80. package/dist/esm/ui/Appearance/Chromeless.js +1 -1
  81. package/dist/esm/ui/Appearance/Comment/Comment.js +3 -4
  82. package/dist/esm/ui/Appearance/Comment/Toolbar.js +14 -3
  83. package/dist/esm/ui/Appearance/FullPage/StyledComponents.js +2 -4
  84. package/dist/esm/ui/AppearanceComponents/Mobile.js +2 -0
  85. package/dist/esm/ui/ChromeCollapsed/index.js +1 -1
  86. package/dist/esm/ui/CollapsedEditor/index.js +1 -1
  87. package/dist/esm/ui/ContentStyles/expand.js +6 -3
  88. package/dist/esm/ui/ContentStyles/extension.js +1 -1
  89. package/dist/esm/ui/ContentStyles/index.js +17 -3
  90. package/dist/esm/ui/ContentStyles/media.js +1 -0
  91. package/dist/esm/ui/ContentStyles/panel.js +1 -0
  92. package/dist/esm/ui/ContentStyles/tasks-and-decisions.js +1 -0
  93. package/dist/esm/ui/ContextPanel/index.js +1 -1
  94. package/dist/esm/ui/EditorContext/index.js +1 -1
  95. package/dist/esm/ui/ErrorBoundary/index.js +1 -1
  96. package/dist/esm/ui/PluginSlot/index.js +1 -1
  97. package/dist/esm/ui/Toolbar/ToolbarInner.js +1 -1
  98. package/dist/esm/ui/ToolbarFeedback/index.js +1 -1
  99. package/dist/esm/ui/WithEditorActions/index.js +1 -1
  100. package/dist/esm/ui/WithFlash/index.js +28 -7
  101. package/dist/esm/ui/WithHelpTrigger/index.js +1 -1
  102. package/dist/esm/utils/performance/instrumented-plugin.js +1 -1
  103. package/dist/esm/version-wrapper.js +1 -1
  104. package/dist/types/create-editor/create-preset.d.ts +70 -70
  105. package/dist/types/preset-universal.d.ts +1 -0
  106. package/dist/types/presets/default.d.ts +28 -164
  107. package/dist/types/presets/universal.d.ts +70 -70
  108. package/dist/types/presets/useUniversalPreset.d.ts +70 -70
  109. package/dist/types/ui/Appearance/FullPage/StyledComponents.d.ts +2 -2
  110. package/dist/types/ui/ContentStyles/index.d.ts +2 -2
  111. package/dist/types-ts4.5/create-editor/create-preset.d.ts +82 -82
  112. package/dist/types-ts4.5/preset-universal.d.ts +1 -0
  113. package/dist/types-ts4.5/presets/default.d.ts +24 -190
  114. package/dist/types-ts4.5/presets/universal.d.ts +82 -82
  115. package/dist/types-ts4.5/presets/useUniversalPreset.d.ts +82 -82
  116. package/dist/types-ts4.5/ui/Appearance/FullPage/StyledComponents.d.ts +2 -2
  117. package/dist/types-ts4.5/ui/ContentStyles/index.d.ts +2 -2
  118. package/docs/4-annotations.tsx +1 -1
  119. package/package.json +25 -8
  120. package/docs/editor-use-only.tsx +0 -50
@@ -9,5 +9,5 @@ var _taggedTemplateLiteral2 = _interopRequireDefault(require("@babel/runtime/hel
9
9
  var _react = require("@emotion/react");
10
10
  var _editorSharedStyles = require("@atlaskit/editor-shared-styles");
11
11
  var _templateObject;
12
- // eslint-disable-next-line @atlaskit/design-system/ensure-design-token-usage
12
+ // eslint-disable-next-line @atlaskit/design-system/ensure-design-token-usage, @atlaskit/design-system/no-css-tagged-template-expression -- Needs manual remediation
13
13
  var extensionStyles = exports.extensionStyles = (0, _react.css)(_templateObject || (_templateObject = (0, _taggedTemplateLiteral2.default)(["\n .multiBodiedExtensionView-content-wrap {\n &.danger > span > .multiBodiedExtension--container {\n box-shadow: 0 0 0 ", "px\n ", ";\n background-color: ", ";\n }\n &:not(.danger).", " {\n & > span > .multiBodiedExtension--container {\n ", "\n }\n }\n .multiBodiedExtension--container {\n width: 100%;\n max-width: 100%; // ensure width can't go over 100%;\n }\n }\n\n .extensionView-content-wrap,\n .multiBodiedExtensionView-content-wrap,\n .bodiedExtensionView-content-wrap {\n margin: ", " 0;\n\n &:first-of-type {\n margin-top: 0;\n }\n\n &:last-of-type {\n margin-bottom: 0;\n }\n\n &:not(.danger).", " {\n & > span > .extension-container {\n ", "\n }\n }\n\n &.danger > span > .extension-container {\n box-shadow: 0 0 0 ", "px\n ", ";\n background-color: ", ";\n }\n\n &.inline {\n word-wrap: break-all;\n }\n }\n\n .extensionView-content-wrap .extension-container {\n overflow: hidden;\n }\n\n .bodiedExtensionView-content-wrap\n .extensionView-content-wrap\n .extension-container {\n width: 100%;\n max-width: 100%; // ensure width can't go over 100%;\n }\n\n [data-mark-type='fragment'] {\n & > .extensionView-content-wrap,\n & > .bodiedExtensionView-content-wrap {\n margin: ", " 0;\n }\n\n & > [data-mark-type='dataConsumer'] {\n & > .extensionView-content-wrap,\n & > .bodiedExtensionView-content-wrap {\n margin: ", " 0;\n }\n }\n\n &:first-child {\n & > .extensionView-content-wrap,\n & > .bodiedExtensionView-content-wrap {\n margin-top: 0;\n }\n\n & > [data-mark-type='dataConsumer'] {\n & > .extensionView-content-wrap,\n & > .bodiedExtensionView-content-wrap {\n margin-top: 0;\n }\n }\n }\n\n &:nth-last-of-type(-n + 2):not(:first-of-type) {\n & > .extensionView-content-wrap,\n & > .bodiedExtensionView-content-wrap {\n margin-bottom: 0;\n }\n\n & > [data-mark-type='dataConsumer'] {\n & > .extensionView-content-wrap,\n & > .bodiedExtensionView-content-wrap {\n margin-bottom: 0;\n }\n }\n }\n }\n"])), _editorSharedStyles.akEditorSelectedBorderSize, "var(--ds-border-danger, ".concat(_editorSharedStyles.akEditorDeleteBorder, ")"), "var(--ds-background-danger, ".concat(_editorSharedStyles.akEditorDeleteBackground, ")"), _editorSharedStyles.akEditorSelectedNodeClassName, (0, _editorSharedStyles.getSelectionStyles)([_editorSharedStyles.SelectionStyle.BoxShadow, _editorSharedStyles.SelectionStyle.Blanket]), _editorSharedStyles.blockNodesVerticalMargin, _editorSharedStyles.akEditorSelectedNodeClassName, (0, _editorSharedStyles.getSelectionStyles)([_editorSharedStyles.SelectionStyle.BoxShadow]), _editorSharedStyles.akEditorSelectedBorderSize, "var(--ds-border-danger, ".concat(_editorSharedStyles.akEditorDeleteBorder, ")"), "var(--ds-background-danger, ".concat(_editorSharedStyles.akEditorDeleteBackground, ")"), _editorSharedStyles.blockNodesVerticalMargin, _editorSharedStyles.blockNodesVerticalMargin);
@@ -32,10 +32,11 @@ var _media = require("./media");
32
32
  var _panel = require("./panel");
33
33
  var _status = require("./status");
34
34
  var _tasksAndDecisions = require("./tasks-and-decisions");
35
- var _templateObject, _templateObject2, _templateObject3, _templateObject4, _templateObject5, _templateObject6, _templateObject7;
35
+ var _templateObject, _templateObject2, _templateObject3, _templateObject4, _templateObject5, _templateObject6;
36
+ /* eslint-disable @atlaskit/design-system/no-css-tagged-template-expression -- Requires manual remediation over time due to use of unsafe nested mixins */
36
37
  /** @jsx jsx */
37
- function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
38
- function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || _typeof(obj) !== "object" && typeof obj !== "function") { return { default: obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
38
+ function _getRequireWildcardCache(e) { if ("function" != typeof WeakMap) return null; var r = new WeakMap(), t = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(e) { return e ? t : r; })(e); }
39
+ function _interopRequireWildcard(e, r) { if (!r && e && e.__esModule) return e; if (null === e || "object" != _typeof(e) && "function" != typeof e) return { default: e }; var t = _getRequireWildcardCache(r); if (t && t.has(e)) return t.get(e); var n = { __proto__: null }, a = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var u in e) if ("default" !== u && Object.prototype.hasOwnProperty.call(e, u)) { var i = a ? Object.getOwnPropertyDescriptor(e, u) : null; i && (i.get || i.set) ? Object.defineProperty(n, u, i) : n[u] = e[u]; } return n.default = e, t && t.set(e, n), n; }
39
40
  var linkStyles = exports.linkStyles = (0, _react2.css)(_templateObject || (_templateObject = (0, _taggedTemplateLiteral2.default)(["\n .ProseMirror {\n ", "\n }\n"])), _styles.linkSharedStyle);
40
41
  var ruleStyles = function ruleStyles() {
41
42
  return (0, _react2.css)(_templateObject2 || (_templateObject2 = (0, _taggedTemplateLiteral2.default)(["\n .ProseMirror {\n ", ";\n\n hr {\n cursor: pointer;\n padding: ", " 0;\n margin: ", " 0;\n background-clip: content-box;\n\n &.", " {\n outline: none;\n background-color: ", ";\n }\n }\n }\n"])), (0, _styles.ruleSharedStyles)(), "var(--ds-space-050, 4px)", "var(--ds-space-300, 24px)", _editorSharedStyles.akEditorSelectedNodeClassName, "var(--ds-border-selected, ".concat(_editorSharedStyles.akEditorSelectedBorderColor, ")"));
@@ -43,9 +44,22 @@ var ruleStyles = function ruleStyles() {
43
44
  var mentionsStyles = (0, _react2.css)(_templateObject3 || (_templateObject3 = (0, _taggedTemplateLiteral2.default)(["\n .", " {\n &.", " [data-mention-id] > span {\n ", "\n\n /* need to specify dark text colour because personal mentions\n (in dark blue) have white text by default */\n color: ", ";\n }\n }\n\n .danger {\n .", ".", "\n > span\n > span\n > span {\n box-shadow: 0 0 0 ", "px ", ";\n background-color: ", ";\n }\n .", " > span > span > span {\n background-color: ", ";\n color: ", ";\n }\n }\n"])), _mention.MentionSharedCssClassName.MENTION_CONTAINER, _editorSharedStyles.akEditorSelectedNodeClassName, (0, _editorSharedStyles.getSelectionStyles)([_editorSharedStyles.SelectionStyle.BoxShadow, _editorSharedStyles.SelectionStyle.Background]), "var(--ds-text-subtle, ".concat(_colors.N500, ")"), _mention.MentionSharedCssClassName.MENTION_CONTAINER, _editorSharedStyles.akEditorSelectedNodeClassName, _editorSharedStyles.akEditorSelectedBorderSize, _editorSharedStyles.akEditorDeleteBorder, "var(--ds-background-danger, ".concat(_editorSharedStyles.akEditorDeleteBackgroundWithOpacity, ")"), _mention.MentionSharedCssClassName.MENTION_CONTAINER, "var(--ds-background-neutral, ".concat(_colors.N30A, ")"), "var(--ds-text-subtle, ".concat(_colors.N500, ")"));
44
45
  var listsStyles = (0, _react2.css)(_templateObject4 || (_templateObject4 = (0, _taggedTemplateLiteral2.default)(["\n .ProseMirror {\n li {\n position: relative;\n\n > p:not(:first-child) {\n margin: ", " 0 0 0;\n }\n\n // In SSR the above rule will apply to all p tags because first-child would be a style tag.\n // The following rule resets the first p tag back to its original margin\n // defined in packages/editor/editor-common/src/styles/shared/paragraph.ts\n > style:first-child + p {\n margin-top: ", ";\n }\n }\n\n &:not([data-node-type='decisionList']) > li,\n // This prevents https://product-fabric.atlassian.net/browse/ED-20924\n &:not(.", ") > li {\n ", "\n }\n }\n"])), "var(--ds-space-050, 4px)", _editorSharedStyles.blockNodesVerticalMargin, _styles.SmartCardSharedCssClassName.BLOCK_CARD_CONTAINER, _utils.browser.safari ? _styles.codeBlockInListSafariFix : '');
45
46
  var emojiStyles = (0, _react2.css)(_templateObject5 || (_templateObject5 = (0, _taggedTemplateLiteral2.default)(["\n .", " {\n display: inline-block;\n\n .", " {\n cursor: pointer;\n\n &.", " > span {\n /** needed for selection style to cover custom emoji image properly */\n display: flex;\n }\n }\n\n &.", " {\n .", ",\n .", " {\n border-radius: 2px;\n ", "\n }\n }\n }\n"])), _emoji.EmojiSharedCssClassName.EMOJI_CONTAINER, _emoji.EmojiSharedCssClassName.EMOJI_NODE, _emoji.EmojiSharedCssClassName.EMOJI_IMAGE, _editorSharedStyles.akEditorSelectedNodeClassName, _emoji.EmojiSharedCssClassName.EMOJI_SPRITE, _emoji.EmojiSharedCssClassName.EMOJI_IMAGE, (0, _editorSharedStyles.getSelectionStyles)([_editorSharedStyles.SelectionStyle.Blanket, _editorSharedStyles.SelectionStyle.BoxShadow]));
46
- var placeholderStyles = exports.placeholderStyles = (0, _react2.css)(_templateObject6 || (_templateObject6 = (0, _taggedTemplateLiteral2.default)(["\n .ProseMirror .placeholder-decoration {\n color: ", ";\n width: 100%;\n pointer-events: none;\n user-select: none;\n\n .placeholder-android {\n pointer-events: none;\n outline: none;\n user-select: none;\n position: absolute;\n }\n }\n"])), "var(--ds-text-subtlest, ".concat(_colors.N200, ")"));
47
+ var placeholderStyles = exports.placeholderStyles = (0, _react2.css)({
48
+ '.ProseMirror .placeholder-decoration': {
49
+ color: "var(--ds-text-subtlest, ".concat(_colors.N200, ")"),
50
+ width: '100%',
51
+ pointerEvents: 'none',
52
+ userSelect: 'none',
53
+ '.placeholder-android': {
54
+ pointerEvents: 'none',
55
+ outline: 'none',
56
+ userSelect: 'none',
57
+ position: 'absolute'
58
+ }
59
+ }
60
+ });
47
61
  var contentStyles = function contentStyles(props) {
48
- return (0, _react2.css)(_templateObject7 || (_templateObject7 = (0, _taggedTemplateLiteral2.default)(["\n .ProseMirror {\n outline: none;\n font-size: ", "px;\n ", ";\n ", ";\n ", ";\n ", ";\n ", ";\n ", ";\n }\n\n .ProseMirror[contenteditable='false'] .taskItemView-content-wrap {\n pointer-events: none;\n opacity: 0.7;\n }\n\n .ProseMirror-hideselection *::selection {\n background: transparent;\n }\n\n .ProseMirror-hideselection *::-moz-selection {\n background: transparent;\n }\n\n .ProseMirror-selectednode {\n outline: none;\n }\n\n .ProseMirror-selectednode:empty {\n outline: 2px solid ", ";\n }\n\n ", "\n ", "\n ", "\n\n ", "\n ", "\n ", "\n ", "\n ", "\n ", "\n ", "\n ", "\n ", ";\n ", "\n ", "\n ", "\n ", "\n ", "\n ", "\n ", "\n ", "\n ", "\n ", "\n ", "\n ", "\n ", "\n ", "\n ", "\n ", "\n ", "\n ", "\n ", "\n ", "\n ", "\n ", "\n\n .panelView-content-wrap {\n box-sizing: border-box;\n }\n\n .mediaGroupView-content-wrap ul {\n padding: 0;\n }\n\n /** Needed to override any cleared floats, e.g. image wrapping */\n\n div.fabric-editor-block-mark[class^='fabric-editor-align'] {\n clear: none !important;\n }\n\n .fabric-editor-align-end {\n text-align: right;\n }\n\n .fabric-editor-align-start {\n text-align: left;\n }\n\n .fabric-editor-align-center {\n text-align: center;\n }\n\n .pm-table-header-content-wrap :not(.fabric-editor-alignment),\n .pm-table-header-content-wrap\n :not(p, .fabric-editor-block-mark)\n + div.fabric-editor-block-mark,\n .pm-table-cell-content-wrap\n :not(p, .fabric-editor-block-mark)\n + div.fabric-editor-block-mark {\n p:first-of-type {\n margin-top: 0;\n }\n }\n\n .hyperlink-floating-toolbar,\n .", " {\n padding: 0;\n }\n\n /* Link icon in the Atlaskit package\n is bigger than the others\n */\n .hyperlink-open-link {\n svg {\n max-width: 18px;\n }\n &[href] {\n padding: 0 4px;\n }\n }\n"])), (0, _editorSharedStyles.editorFontSize)({
62
+ return (0, _react2.css)(_templateObject6 || (_templateObject6 = (0, _taggedTemplateLiteral2.default)(["\n .ProseMirror {\n outline: none;\n font-size: ", "px;\n ", ";\n ", ";\n ", ";\n ", ";\n ", ";\n ", ";\n }\n\n .ProseMirror[contenteditable='false'] .taskItemView-content-wrap {\n pointer-events: none;\n opacity: 0.7;\n }\n\n .ProseMirror-hideselection *::selection {\n background: transparent;\n }\n\n .ProseMirror-hideselection *::-moz-selection {\n background: transparent;\n }\n\n .ProseMirror-selectednode {\n outline: none;\n }\n\n .ProseMirror-selectednode:empty {\n outline: 2px solid ", ";\n }\n\n ", "\n ", "\n ", "\n\n ", "\n ", "\n ", "\n ", "\n ", "\n ", "\n ", "\n ", "\n ", ";\n ", "\n ", "\n ", "\n ", "\n ", "\n ", "\n ", "\n ", "\n ", "\n ", "\n ", "\n ", "\n ", "\n ", "\n ", "\n ", "\n ", "\n ", "\n ", "\n ", "\n ", "\n ", "\n\n .panelView-content-wrap {\n box-sizing: border-box;\n }\n\n .mediaGroupView-content-wrap ul {\n padding: 0;\n }\n\n /** Needed to override any cleared floats, e.g. image wrapping */\n\n div.fabric-editor-block-mark[class^='fabric-editor-align'] {\n clear: none !important;\n }\n\n .fabric-editor-align-end {\n text-align: right;\n }\n\n .fabric-editor-align-start {\n text-align: left;\n }\n\n .fabric-editor-align-center {\n text-align: center;\n }\n\n .pm-table-header-content-wrap :not(.fabric-editor-alignment),\n .pm-table-header-content-wrap\n :not(p, .fabric-editor-block-mark)\n + div.fabric-editor-block-mark,\n .pm-table-cell-content-wrap\n :not(p, .fabric-editor-block-mark)\n + div.fabric-editor-block-mark {\n p:first-of-type {\n margin-top: 0;\n }\n }\n\n .hyperlink-floating-toolbar,\n .", " {\n padding: 0;\n }\n\n /* Link icon in the Atlaskit package\n is bigger than the others\n */\n .hyperlink-open-link {\n svg {\n max-width: 18px;\n }\n &[href] {\n padding: 0 4px;\n }\n }\n"])), (0, _editorSharedStyles.editorFontSize)({
49
63
  theme: props.theme
50
64
  }), _styles.whitespaceSharedStyles, _styles.paragraphSharedStyles, _styles.listsSharedStyles, _styles.indentationSharedStyles, _styles.shadowSharedStyle, _getInlineNodeViewProducer.InlineNodeViewSharedStyles, "var(--ds-border-focused, #8cf)", _styles5.placeholderTextStyles, placeholderStyles, (0, _codeBlock.codeBlockStyles)(), (0, _styles2.blocktypeStyles)(), (0, _styles.codeMarkSharedStyles)(), _styles.textColorStyles, listsStyles, ruleStyles(), _media.mediaStyles, _layout.layoutStyles, _collab.telepointerStyle, _selection.gapCursorStyles, (0, _commonStyles.tableStyles)(props), (0, _panel.panelStyles)(), mentionsStyles, emojiStyles, _styles.tasksAndDecisionsStyles, _styles.gridStyles, linkStyles, _styles.blockMarksSharedStyles, _styles.dateSharedStyle, _extension.extensionStyles, (0, _expand.expandStyles)(), _styles3.findReplaceStyles, _styles4.textHighlightStyle, _tasksAndDecisions.taskDecisionStyles, _status.statusStyles, (0, _styles.annotationSharedStyles)(), _styles.smartCardStyles, _styles.smartCardSharedStyles, _date.dateStyles, _styles.embedCardStyles, _styles.unsupportedStyles, _styles.resizerStyles, _styles.MediaSharedClassNames.FLOATING_TOOLBAR_COMPONENT);
51
65
  };
@@ -13,6 +13,7 @@ var _editorSharedStyles = require("@atlaskit/editor-shared-styles");
13
13
  var _mediaCard = require("@atlaskit/media-card");
14
14
  var _colors = require("@atlaskit/theme/colors");
15
15
  var _templateObject;
16
+ // eslint-disable-next-line @atlaskit/design-system/no-css-tagged-template-expression -- Needs manual remediation
16
17
  var mediaStyles = exports.mediaStyles = (0, _react.css)(_templateObject || (_templateObject = (0, _taggedTemplateLiteral2.default)(["\n .ProseMirror {\n ", " & [layout='full-width'] .", ",\n & [layout='wide'] .", " {\n margin-left: 50%;\n transform: translateX(-50%);\n }\n\n .media-extended-resize-experience[layout^='wrap-'] {\n // override 'overflow: auto' when viewport <= 410 set by mediaSingleSharedStyle\n // to prevent scroll bar\n overflow: visible !important;\n }\n\n & [layout^='wrap-'] + [layout^='wrap-'] {\n clear: none;\n & + p,\n & + div[class^='fabric-editor-align'],\n & + ul,\n & + ol,\n & + h1,\n & + h2,\n & + h3,\n & + h4,\n & + h5,\n & + h6 {\n clear: both !important;\n }\n & .", " {\n margin-left: 0;\n margin-right: 0;\n }\n }\n\n ", "\n\n .mediaSingleView-content-wrap[layout^='wrap-'] {\n max-width: 100%;\n // overwrite default Prosemirror setting making it clear: both\n clear: inherit;\n }\n\n .mediaSingleView-content-wrap[layout='wrap-left'] {\n float: left;\n }\n\n .mediaSingleView-content-wrap[layout='wrap-right'] {\n float: right;\n }\n\n .mediaSingleView-content-wrap[layout='wrap-right']\n + .mediaSingleView-content-wrap[layout='wrap-left'] {\n clear: both;\n }\n\n /* Larger margins for resize handlers when at depth 0 of the document */\n & > .mediaSingleView-content-wrap {\n .richMedia-resize-handle-right {\n margin-right: -", "px;\n }\n .richMedia-resize-handle-left {\n margin-left: -", "px;\n }\n }\n }\n\n .richMedia-resize-handle-right,\n .richMedia-resize-handle-left {\n display: flex;\n flex-direction: column;\n\n /* vertical align */\n justify-content: center;\n }\n\n .richMedia-resize-handle-right {\n align-items: flex-end;\n padding-right: ", ";\n margin-right: -", "px;\n }\n\n .richMedia-resize-handle-left {\n align-items: flex-start;\n padding-left: ", ";\n margin-left: -", "px;\n }\n\n .richMedia-resize-handle-right::after,\n .richMedia-resize-handle-left::after {\n content: ' ';\n display: flex;\n width: 3px;\n height: 64px;\n\n border-radius: 6px;\n }\n\n .", ":hover .richMedia-resize-handle-left::after,\n .", ":hover .richMedia-resize-handle-right::after {\n background: ", ";\n }\n\n .", " .richMedia-resize-handle-right::after,\n .", " .richMedia-resize-handle-left::after,\n .", " .richMedia-resize-handle-right:hover::after,\n .", " .richMedia-resize-handle-left:hover::after,\n .", ".is-resizing .richMedia-resize-handle-right::after,\n .", ".is-resizing .richMedia-resize-handle-left::after {\n background: ", ";\n }\n\n .__resizable_base__ {\n left: unset !important;\n width: auto !important;\n height: auto !important;\n }\n\n /* Danger when top level node for smart cards / inline links */\n .danger > div > div > .media-card-frame,\n .danger > span > a {\n background-color: ", ";\n box-shadow: 0px 0px 0px ", "px\n ", ";\n transition: background-color 0s, box-shadow 0s;\n }\n /* Danger when nested node or common */\n .danger {\n /* Media single */\n .", " .", "::after {\n border: 1px solid ", ";\n }\n /* Media single video player */\n .", " .", "::after {\n border: 1px solid ", ";\n }\n /* New file experience */\n .", " .", " {\n box-shadow: 0 0 0 1px\n ", " !important;\n }\n /* Media resize legacy handlers */\n .richMedia-resize-handle-right::after,\n .richMedia-resize-handle-left::after {\n background: ", " !important;\n }\n /* Media resize new handlers */\n .resizer-handle-thumb {\n background: ", " !important;\n }\n\n /* Smart cards */\n div div .media-card-frame,\n .inlineCardView-content-wrap > span > a {\n background-color: ", "; /* R75 with 50% opactiy */\n transition: background-color 0s;\n }\n\n div div .media-card-frame::after {\n box-shadow: none;\n }\n }\n\n .warning {\n /* Media single */\n .", " .", "::after {\n border: 1px solid ", ";\n }\n\n .", " .", "::after {\n border: 1px solid ", ";\n }\n\n .", " .", " {\n box-shadow: 0 0 0 1px ", " !important;\n }\n\n .resizer-handle-thumb {\n background: ", " !important;\n }\n }\n"])), _styles.mediaSingleSharedStyle, _styles.richMediaClassName, _styles.richMediaClassName, _styles.richMediaClassName, _mediaInline.mediaInlineImageStyles, _editorSharedStyles.akEditorMediaResizeHandlerPaddingWide, _editorSharedStyles.akEditorMediaResizeHandlerPaddingWide, "var(--ds-space-150, 12px)", _editorSharedStyles.akEditorMediaResizeHandlerPadding, "var(--ds-space-150, 12px)", _editorSharedStyles.akEditorMediaResizeHandlerPadding, _styles.richMediaClassName, _styles.richMediaClassName, "var(--ds-border, ".concat(_colors.N60, ")"), _editorSharedStyles.akEditorSelectedNodeClassName, _editorSharedStyles.akEditorSelectedNodeClassName, _styles.richMediaClassName, _styles.richMediaClassName, _styles.richMediaClassName, _styles.richMediaClassName, "var(--ds-border-focused, ".concat(_colors.B200, ")"), "var(--ds-background-danger, ".concat(_editorSharedStyles.akEditorDeleteBackground, ")"), _editorSharedStyles.akEditorSelectedBorderBoldSize, "var(--ds-border-danger, ".concat(_editorSharedStyles.akEditorDeleteBorder, ")"), _styles.richMediaClassName, _mediaCard.fileCardImageViewSelector, "var(--ds-border-danger, ".concat(_editorSharedStyles.akEditorDeleteIconColor, ")"), _styles.richMediaClassName, _mediaCard.inlinePlayerClassName, "var(--ds-border-danger, ".concat(_editorSharedStyles.akEditorDeleteIconColor, ")"), _styles.richMediaClassName, _mediaCard.newFileExperienceClassName, "var(--ds-border-danger, ".concat(_editorSharedStyles.akEditorDeleteIconColor, ")"), "var(--ds-icon-danger, ".concat(_editorSharedStyles.akEditorDeleteIconColor, ")"), "var(--ds-icon-danger, ".concat(_editorSharedStyles.akEditorDeleteIconColor, ")"), "var(--ds-blanket-danger, rgb(255, 189, 173, 0.5))", _styles.richMediaClassName, _mediaCard.fileCardImageViewSelector, "var(--ds-border-warning, ".concat(_colors.Y500, ")"), _styles.richMediaClassName, _mediaCard.inlinePlayerClassName, "var(--ds-border-warning, ".concat(_colors.Y500, ")"), _styles.richMediaClassName, _mediaCard.newFileExperienceClassName, "var(--ds-border-warning, ".concat(_colors.Y500, ")"), "var(--ds-icon-warning, ".concat(_colors.Y500, ")"));
17
18
 
18
19
  /* `left: unset` above is to work around Chrome bug where rendering a div with
@@ -10,6 +10,7 @@ var _react = require("@emotion/react");
10
10
  var _panel = require("@atlaskit/editor-common/panel");
11
11
  var _editorSharedStyles = require("@atlaskit/editor-shared-styles");
12
12
  var _templateObject;
13
+ // eslint-disable-next-line @atlaskit/design-system/no-css-tagged-template-expression -- Needs manual remediation due to mixin usage
13
14
  var panelStyles = exports.panelStyles = function panelStyles() {
14
15
  return (0, _react.css)(_templateObject || (_templateObject = (0, _taggedTemplateLiteral2.default)(["\n .ProseMirror {\n .", " {\n cursor: pointer;\n\n /* Danger when top level node */\n &.danger {\n box-shadow: 0 0 0 ", "px\n ", ";\n background-color: ", " !important;\n\n .", " {\n color: ", " !important;\n }\n }\n }\n\n .", " {\n cursor: text;\n }\n\n /* Danger when nested node */\n .danger .", " {\n &[data-panel-type] {\n background-color: ", ";\n\n .", " {\n color: ", ";\n }\n }\n }\n\n ", ";\n }\n\n .", ".", ":not(.danger) {\n ", "\n }\n"])), _panel.PanelSharedCssClassName.prefix, _editorSharedStyles.akEditorSelectedBorderSize, _editorSharedStyles.akEditorDeleteBorder, "var(--ds-background-danger, ".concat(_editorSharedStyles.akEditorDeleteBackground, ")"), _panel.PanelSharedCssClassName.icon, "var(--ds-icon-danger, ".concat(_editorSharedStyles.akEditorDeleteIconColor, ")"), _panel.PanelSharedCssClassName.content, _panel.PanelSharedCssClassName.prefix, "var(--ds-blanket-danger, ".concat(_editorSharedStyles.akEditorDeleteBackgroundWithOpacity, ")"), _panel.PanelSharedCssClassName.icon, "var(--ds-icon-danger, ".concat(_editorSharedStyles.akEditorDeleteIconColor, ")"), (0, _panel.panelSharedStyles)(), _panel.PanelSharedCssClassName.prefix, _editorSharedStyles.akEditorSelectedNodeClassName, (0, _editorSharedStyles.getSelectionStyles)([_editorSharedStyles.SelectionStyle.BoxShadow, _editorSharedStyles.SelectionStyle.Blanket]));
15
16
  };
@@ -10,4 +10,5 @@ var _react = require("@emotion/react");
10
10
  var _styles = require("@atlaskit/editor-common/styles");
11
11
  var _editorSharedStyles = require("@atlaskit/editor-shared-styles");
12
12
  var _templateObject;
13
+ // eslint-disable-next-line @atlaskit/design-system/no-css-tagged-template-expression -- Needs manual remediation due to `getSelectionStyles`
13
14
  var taskDecisionStyles = exports.taskDecisionStyles = (0, _react.css)(_templateObject || (_templateObject = (0, _taggedTemplateLiteral2.default)(["\n [data-decision-wrapper] {\n cursor: pointer;\n }\n\n .", " > [data-decision-wrapper],\n ol[data-node-type='decisionList'].", " {\n border-radius: 4px;\n ", "\n }\n\n .danger {\n .", ".", "\n > div {\n box-shadow: 0 0 0 ", "px\n ", ";\n background-color: ", ";\n &::after {\n content: none; /* reset the Blanket selection style */\n }\n }\n }\n"])), _editorSharedStyles.akEditorSelectedNodeClassName, _editorSharedStyles.akEditorSelectedNodeClassName, (0, _editorSharedStyles.getSelectionStyles)([_editorSharedStyles.SelectionStyle.BoxShadow, _editorSharedStyles.SelectionStyle.Blanket]), _styles.TaskDecisionSharedCssClassName.DECISION_CONTAINER, _editorSharedStyles.akEditorSelectedNodeClassName, _editorSharedStyles.akEditorSelectedBorderSize, "var(--ds-border-danger, ".concat(_editorSharedStyles.akEditorDeleteBorder, ")"), "var(--ds-blanket-danger, ".concat(_editorSharedStyles.akEditorDeleteBackgroundWithOpacity, ")"));
@@ -32,12 +32,12 @@ var _WithPluginState = _interopRequireDefault(require("../WithPluginState"));
32
32
  var _excluded = ["actions"];
33
33
  var _templateObject, _templateObject2, _templateObject3, _templateObject4;
34
34
  /** @jsx jsx */
35
- function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
36
- function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || _typeof(obj) !== "object" && typeof obj !== "function") { return { default: obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
35
+ function _getRequireWildcardCache(e) { if ("function" != typeof WeakMap) return null; var r = new WeakMap(), t = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(e) { return e ? t : r; })(e); }
36
+ function _interopRequireWildcard(e, r) { if (!r && e && e.__esModule) return e; if (null === e || "object" != _typeof(e) && "function" != typeof e) return { default: e }; var t = _getRequireWildcardCache(r); if (t && t.has(e)) return t.get(e); var n = { __proto__: null }, a = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var u in e) if ("default" !== u && Object.prototype.hasOwnProperty.call(e, u)) { var i = a ? Object.getOwnPropertyDescriptor(e, u) : null; i && (i.get || i.set) ? Object.defineProperty(n, u, i) : n[u] = e[u]; } return n.default = e, t && t.set(e, n), n; }
37
37
  function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
38
38
  function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { (0, _defineProperty2.default)(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
39
39
  function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = (0, _getPrototypeOf2.default)(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = (0, _getPrototypeOf2.default)(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return (0, _possibleConstructorReturn2.default)(this, result); }; }
40
- function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); return true; } catch (e) { return false; } }
40
+ function _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }
41
41
  var ANIM_SPEED_MS = 500;
42
42
  var EDITOR_WIDTH = _editorSharedStyles.akEditorDefaultLayoutWidth + _editorSharedStyles.akEditorBreakoutPadding;
43
43
  var WIDE_EDITOR_WIDTH = _editorSharedStyles.akEditorWideLayoutWidth + _editorSharedStyles.akEditorBreakoutPadding;
@@ -16,7 +16,7 @@ var _propTypes = _interopRequireDefault(require("prop-types"));
16
16
  var _actions = _interopRequireDefault(require("../../actions"));
17
17
  var _context = require("../../presets/context");
18
18
  function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = (0, _getPrototypeOf2.default)(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = (0, _getPrototypeOf2.default)(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return (0, _possibleConstructorReturn2.default)(this, result); }; }
19
- function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); return true; } catch (e) { return false; } }
19
+ function _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }
20
20
  var EditorContext = /*#__PURE__*/_react.default.createContext({});
21
21
  var useEditorContext = exports.useEditorContext = function useEditorContext() {
22
22
  return _react.default.useContext(EditorContext);
@@ -16,7 +16,7 @@ var _react = _interopRequireDefault(require("react"));
16
16
  var _analytics = require("@atlaskit/editor-common/analytics");
17
17
  var _monitoring = require("@atlaskit/editor-common/monitoring");
18
18
  function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = (0, _getPrototypeOf2.default)(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = (0, _getPrototypeOf2.default)(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return (0, _possibleConstructorReturn2.default)(this, result); }; }
19
- function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); return true; } catch (e) { return false; } }
19
+ function _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }
20
20
  var ErrorBoundary = exports.ErrorBoundary = /*#__PURE__*/function (_React$Component) {
21
21
  (0, _inherits2.default)(ErrorBoundary, _React$Component);
22
22
  var _super = _createSuper(ErrorBoundary);
@@ -22,7 +22,7 @@ var _mountPluginHooks = require("./mount-plugin-hooks");
22
22
  var _templateObject;
23
23
  /** @jsx jsx */
24
24
  function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = (0, _getPrototypeOf2.default)(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = (0, _getPrototypeOf2.default)(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return (0, _possibleConstructorReturn2.default)(this, result); }; }
25
- function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); return true; } catch (e) { return false; } }
25
+ function _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }
26
26
  var pluginsComponentsWrapper = (0, _react2.css)(_templateObject || (_templateObject = (0, _taggedTemplateLiteral2.default)(["\n display: flex;\n"])));
27
27
  var PluginSlot = exports.default = /*#__PURE__*/function (_React$Component) {
28
28
  (0, _inherits2.default)(PluginSlot, _React$Component);
@@ -17,7 +17,7 @@ var _editorSharedStyles = require("@atlaskit/editor-shared-styles");
17
17
  var _templateObject;
18
18
  /** @jsx jsx */
19
19
  function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = (0, _getPrototypeOf2.default)(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = (0, _getPrototypeOf2.default)(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return (0, _possibleConstructorReturn2.default)(this, result); }; }
20
- function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); return true; } catch (e) { return false; } }
20
+ function _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }
21
21
  var toolbarComponentsWrapper = (0, _react2.css)(_templateObject || (_templateObject = (0, _taggedTemplateLiteral2.default)(["\n display: flex;\n\n @media (max-width: ", "px) {\n justify-content: space-between;\n }\n"])), _editorSharedStyles.akEditorMobileMaxWidth);
22
22
  var ToolbarInner = exports.ToolbarInner = /*#__PURE__*/function (_React$Component) {
23
23
  (0, _inherits2.default)(ToolbarInner, _React$Component);
@@ -18,8 +18,8 @@ var _hooks = require("./hooks");
18
18
  var _Toolbar = require("./Toolbar");
19
19
  var _toolbarSize = require("./toolbar-size");
20
20
  var _types = require("./types");
21
- function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
22
- function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || _typeof(obj) !== "object" && typeof obj !== "function") { return { default: obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
21
+ function _getRequireWildcardCache(e) { if ("function" != typeof WeakMap) return null; var r = new WeakMap(), t = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(e) { return e ? t : r; })(e); }
22
+ function _interopRequireWildcard(e, r) { if (!r && e && e.__esModule) return e; if (null === e || "object" != _typeof(e) && "function" != typeof e) return { default: e }; var t = _getRequireWildcardCache(r); if (t && t.has(e)) return t.get(e); var n = { __proto__: null }, a = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var u in e) if ("default" !== u && Object.prototype.hasOwnProperty.call(e, u)) { var i = a ? Object.getOwnPropertyDescriptor(e, u) : null; i && (i.get || i.set) ? Object.defineProperty(n, u, i) : n[u] = e[u]; } return n.default = e, t && t.set(e, n), n; }
23
23
  /** @jsx jsx */
24
24
 
25
25
  var toolbar = (0, _react2.css)((0, _defineProperty2.default)({
@@ -34,7 +34,7 @@ var _styles = require("./styles");
34
34
  function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
35
35
  function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { (0, _defineProperty2.default)(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
36
36
  function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = (0, _getPrototypeOf2.default)(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = (0, _getPrototypeOf2.default)(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return (0, _possibleConstructorReturn2.default)(this, result); }; }
37
- function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); return true; } catch (e) { return false; } } /** @jsx jsx */
37
+ function _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); } /** @jsx jsx */
38
38
  var PopupWithOutsideListeners = (0, _withOuterListeners.default)(_ui.Popup);
39
39
  var POPUP_HEIGHT = 388;
40
40
  var POPUP_WIDTH = 280;
@@ -15,7 +15,7 @@ var _defineProperty2 = _interopRequireDefault(require("@babel/runtime/helpers/de
15
15
  var _react = _interopRequireDefault(require("react"));
16
16
  var _propTypes = _interopRequireDefault(require("prop-types"));
17
17
  function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = (0, _getPrototypeOf2.default)(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = (0, _getPrototypeOf2.default)(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return (0, _possibleConstructorReturn2.default)(this, result); }; }
18
- function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); return true; } catch (e) { return false; } }
18
+ function _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }
19
19
  var WithEditorActions = exports.default = /*#__PURE__*/function (_React$Component) {
20
20
  (0, _inherits2.default)(WithEditorActions, _React$Component);
21
21
  var _super = _createSuper(WithEditorActions);
@@ -12,18 +12,38 @@ var _inherits2 = _interopRequireDefault(require("@babel/runtime/helpers/inherits
12
12
  var _possibleConstructorReturn2 = _interopRequireDefault(require("@babel/runtime/helpers/possibleConstructorReturn"));
13
13
  var _getPrototypeOf2 = _interopRequireDefault(require("@babel/runtime/helpers/getPrototypeOf"));
14
14
  var _defineProperty2 = _interopRequireDefault(require("@babel/runtime/helpers/defineProperty"));
15
- var _taggedTemplateLiteral2 = _interopRequireDefault(require("@babel/runtime/helpers/taggedTemplateLiteral"));
16
15
  var _react = _interopRequireDefault(require("react"));
17
16
  var _react2 = require("@emotion/react");
18
17
  var _colors = require("@atlaskit/theme/colors");
19
- var _templateObject, _templateObject2, _templateObject3, _templateObject4;
20
- /** @jsx jsx */
21
18
  function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = (0, _getPrototypeOf2.default)(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = (0, _getPrototypeOf2.default)(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return (0, _possibleConstructorReturn2.default)(this, result); }; }
22
- function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); return true; } catch (e) { return false; } }
23
- var pulseBackground = (0, _react2.keyframes)(_templateObject || (_templateObject = (0, _taggedTemplateLiteral2.default)(["\n 50% {\n background-color: ", ";\n }\n"])), "var(--ds-blanket-danger, ".concat(_colors.R100, ")"));
24
- var pulseBackgroundReverse = (0, _react2.keyframes)(_templateObject2 || (_templateObject2 = (0, _taggedTemplateLiteral2.default)(["\n 0% {\n background-color: ", ";\n }\n 50% {\n background-color: auto;\n }\n 100% {\n background-color: ", ";\n }\n"])), "var(--ds-blanket-danger, ".concat(_colors.R100, ")"), "var(--ds-blanket-danger, ".concat(_colors.R100, ")"));
25
- var flashWrapper = (0, _react2.css)(_templateObject3 || (_templateObject3 = (0, _taggedTemplateLiteral2.default)(["\n &.-flash > div {\n animation: 0.25s ease-in-out ", ";\n }\n\n & > div {\n animation: 'none';\n }\n"])), pulseBackgroundReverse);
26
- var flashWrapperAnimated = (0, _react2.css)(_templateObject4 || (_templateObject4 = (0, _taggedTemplateLiteral2.default)(["\n ", "\n\n & > div {\n animation: 0.25s ease-in-out ", ";\n }\n"])), flashWrapper, pulseBackground);
19
+ function _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); } /** @jsx jsx */
20
+ var pulseBackground = (0, _react2.keyframes)({
21
+ '50%': {
22
+ backgroundColor: "var(--ds-blanket-danger, ".concat(_colors.R100, ")")
23
+ }
24
+ });
25
+ var pulseBackgroundReverse = (0, _react2.keyframes)({
26
+ '0%': {
27
+ backgroundColor: "var(--ds-blanket-danger, ".concat(_colors.R100, ")")
28
+ },
29
+ '50%': {
30
+ backgroundColor: 'auto'
31
+ },
32
+ '100%': {
33
+ backgroundColor: "var(--ds-blanket-danger, ".concat(_colors.R100, ")")
34
+ }
35
+ });
36
+ var flashWrapper = (0, _react2.css)({
37
+ '&.-flash > div': {
38
+ animation: "0.25s ease-in-out ".concat(pulseBackgroundReverse)
39
+ },
40
+ '& > div': {
41
+ animation: "'none'"
42
+ }
43
+ });
44
+ var flashWrapperAnimated = (0, _react2.css)((0, _defineProperty2.default)({}, "".concat(flashWrapper, " & > div"), {
45
+ animation: "0.25s ease-in-out ".concat(pulseBackground)
46
+ }));
27
47
  var WithFlash = exports.default = /*#__PURE__*/function (_React$Component) {
28
48
  (0, _inherits2.default)(WithFlash, _React$Component);
29
49
  var _super = _createSuper(WithFlash);
@@ -19,7 +19,7 @@ var _utils = require("@atlaskit/editor-common/utils");
19
19
  var _helpDialog = require("@atlaskit/editor-plugins/help-dialog");
20
20
  var _eventDispatcher = require("../../event-dispatcher");
21
21
  function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = (0, _getPrototypeOf2.default)(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = (0, _getPrototypeOf2.default)(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return (0, _possibleConstructorReturn2.default)(this, result); }; }
22
- function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); return true; } catch (e) { return false; } }
22
+ function _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }
23
23
  var WithHelpTrigger = exports.default = /*#__PURE__*/function (_React$Component) {
24
24
  (0, _inherits2.default)(WithHelpTrigger, _React$Component);
25
25
  var _super = _createSuper(WithHelpTrigger);
@@ -15,7 +15,7 @@ var _safePlugin = require("@atlaskit/editor-common/safe-plugin");
15
15
  var _utils = require("@atlaskit/editor-common/utils");
16
16
  var _saferTransactions = require("./safer-transactions");
17
17
  function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = (0, _getPrototypeOf2.default)(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = (0, _getPrototypeOf2.default)(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return (0, _possibleConstructorReturn2.default)(this, result); }; }
18
- function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); return true; } catch (e) { return false; } }
18
+ function _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }
19
19
  var InstrumentedPlugin = exports.InstrumentedPlugin = /*#__PURE__*/function (_SafePlugin) {
20
20
  (0, _inherits2.default)(InstrumentedPlugin, _SafePlugin);
21
21
  var _super = _createSuper(InstrumentedPlugin);
@@ -5,4 +5,4 @@ Object.defineProperty(exports, "__esModule", {
5
5
  });
6
6
  exports.version = exports.name = void 0;
7
7
  var name = exports.name = "@atlaskit/editor-core";
8
- var version = exports.version = "192.7.0";
8
+ var version = exports.version = "193.1.0";
@@ -707,7 +707,6 @@ export class ReactEditorView extends React.Component {
707
707
  this.eventDispatcher.destroy();
708
708
  // this.view will be destroyed when React unmounts in handleEditorViewRef
709
709
  }
710
-
711
710
  // Helper to allow tests to inject plugins directly
712
711
  getPlugins(preset) {
713
712
  const plugins = createPluginsList(preset, this.props.editorProps, this.pluginInjectionAPI);
@@ -65,7 +65,6 @@ export function getDefaultPresetOptionsFromEditorProps(props, createAnalyticsEve
65
65
  ...(props.textFormatting || {}),
66
66
  responsiveToolbarMenu: ((_props$textFormatting = props.textFormatting) === null || _props$textFormatting === void 0 ? void 0 : _props$textFormatting.responsiveToolbarMenu) != null ? props.textFormatting.responsiveToolbarMenu : props.allowUndoRedoButtons
67
67
  },
68
- annotationProviders: props.annotationProviders,
69
68
  submitEditor: props.onSave,
70
69
  quickInsert: {
71
70
  enableElementBrowser: props.elementBrowser && props.elementBrowser.showModal,
@@ -1 +1,2 @@
1
- export { default as useUniversalPreset } from './presets/useUniversalPreset';
1
+ export { default as useUniversalPreset } from './presets/useUniversalPreset';
2
+ export { default as createUniversalPreset } from './presets/universal';
@@ -2,7 +2,6 @@
2
2
 
3
3
  import { EditorPresetBuilder } from '@atlaskit/editor-common/preset';
4
4
  import { analyticsPlugin } from '@atlaskit/editor-plugins/analytics';
5
- import { annotationPlugin } from '@atlaskit/editor-plugins/annotation';
6
5
  import { basePlugin } from '@atlaskit/editor-plugins/base';
7
6
  import { betterTypeHistoryPlugin } from '@atlaskit/editor-plugins/better-type-history';
8
7
  import { blockTypePlugin } from '@atlaskit/editor-plugins/block-type';
@@ -48,7 +47,7 @@ export function createDefaultPreset(options) {
48
47
  contextIdentifierProvider: options.contextIdentifierProvider
49
48
  }]).add([basePlugin, options.base]).add(decorationsPlugin).add([typeAheadPlugin, options.typeAhead || {
50
49
  createAnalyticsEvent: options.createAnalyticsEvent
51
- }]).maybeAdd(historyPlugin, Boolean(isMobile || options.allowUndoRedoButtons)).maybeAdd(undoRedoPlugin, Boolean((_options$featureFlags = (_options$featureFlags2 = options.featureFlags) === null || _options$featureFlags2 === void 0 ? void 0 : _options$featureFlags2.undoRedoButtons) !== null && _options$featureFlags !== void 0 ? _options$featureFlags : options.allowUndoRedoButtons)).add([blockTypePlugin, options.blockType]).add(clearMarksOnEmptyDocPlugin).maybeAdd([annotationPlugin, options.annotationProviders], Boolean(options.annotationProviders)).maybeAdd([selectionToolbarPlugin, {
50
+ }]).maybeAdd(historyPlugin, Boolean(isMobile || options.allowUndoRedoButtons)).maybeAdd(undoRedoPlugin, Boolean((_options$featureFlags = (_options$featureFlags2 = options.featureFlags) === null || _options$featureFlags2 === void 0 ? void 0 : _options$featureFlags2.undoRedoButtons) !== null && _options$featureFlags !== void 0 ? _options$featureFlags : options.allowUndoRedoButtons)).add([blockTypePlugin, options.blockType]).add(clearMarksOnEmptyDocPlugin).maybeAdd([selectionToolbarPlugin, {
52
51
  preferenceToolbarAboveSelection: false
53
52
  }], () => {
54
53
  if (getBooleanFF('platform.editor.enable-selection-toolbar_ucdwd')) {
@@ -92,7 +92,7 @@ export default function createUniversalPreset(appearance, props, featureFlags, p
92
92
  __livePage: props.__livePage
93
93
  }], Boolean(props.allowExpand)).maybeAdd(guidelinePlugin, Boolean(!isMobile && !isComment && !isChromeless && (props.media || props.allowTables))).maybeAdd([gridPlugin, {
94
94
  shouldCalcBreakoutGridLines: isFullPage
95
- }], Boolean(props.media)).maybeAdd([mediaPlugin, {
95
+ }], Boolean(props.media)).maybeAdd([annotationPlugin, props.annotationProviders], Boolean(props.annotationProviders)).maybeAdd([mediaPlugin, {
96
96
  ...props.media,
97
97
  allowLazyLoading: !isMobile,
98
98
  allowBreakoutSnapPoints: isFullPage,
@@ -2,10 +2,10 @@
2
2
  import React from 'react';
3
3
  import { css, jsx } from '@emotion/react';
4
4
  import { clickAreaClickHandler } from '../click-area-helper';
5
- const clickWrapper = css`
6
- flex-grow: 1;
7
- height: 100%;
8
- `;
5
+ const clickWrapper = css({
6
+ flexGrow: 1,
7
+ height: '100%'
8
+ });
9
9
  export const ClickAreaBlock = ({
10
10
  editorView,
11
11
  editorDisabled,
@@ -2,9 +2,9 @@
2
2
  import React from 'react';
3
3
  import { css, jsx } from '@emotion/react';
4
4
  import { createParagraphAtEnd } from '@atlaskit/editor-common/commands';
5
- const clickArea = css`
6
- flex-grow: 1;
7
- `;
5
+ const clickArea = css({
6
+ flexGrow: 1
7
+ });
8
8
  export const ClickAreaInline = ({
9
9
  editorView,
10
10
  children
@@ -1,5 +1,4 @@
1
1
  import _defineProperty from "@babel/runtime/helpers/defineProperty";
2
- /* eslint-disable @atlaskit/design-system/ensure-design-token-usage/preview */
3
2
  /** @jsx jsx */
4
3
  import React, { Fragment, useCallback, useEffect, useMemo, useState } from 'react';
5
4
  import { css, jsx } from '@emotion/react';
@@ -48,8 +47,8 @@ const ContentArea = createEditorContentStyle(css({
48
47
  margin: "var(--ds-space-150, 12px)"
49
48
  },
50
49
  '.gridParent': {
51
- marginLeft: `${CommentEditorMargin - GRID_GUTTER}px`,
52
- marginRight: `${CommentEditorMargin - GRID_GUTTER}px`,
50
+ marginLeft: "var(--ds-space-025, 2px)",
51
+ marginRight: "var(--ds-space-025, 2px)",
53
52
  width: `calc(100% + ${CommentEditorMargin - GRID_GUTTER}px)`
54
53
  },
55
54
  padding: "var(--ds-space-250, 20px)"
@@ -5,6 +5,8 @@ import React, { useEffect, useState } from 'react';
5
5
  import { css, jsx } from '@emotion/react';
6
6
  import { akEditorMenuZIndex, akEditorToolbarKeylineHeight } from '@atlaskit/editor-shared-styles';
7
7
  const MAXIMUM_TWO_LINE_TOOLBAR_BREAKPOINT = 490;
8
+
9
+ // eslint-disable-next-line @atlaskit/design-system/no-css-tagged-template-expression -- Needs manual remediation
8
10
  const mainToolbarWrapperStyle = (isTwoLineEditorToolbar = false) => css`
9
11
  position: relative;
10
12
  align-items: center;
@@ -44,6 +46,8 @@ const mainToolbarWrapperStyle = (isTwoLineEditorToolbar = false) => css`
44
46
  padding-left: 0;
45
47
  }
46
48
  `;
49
+
50
+ // eslint-disable-next-line @atlaskit/design-system/no-css-tagged-template-expression -- Needs manual remediation
47
51
  const stickyToolbarWrapperStyle = css`
48
52
  /* stylelint-disable declaration-block-no-duplicate-properties */
49
53
  position: relative;
@@ -72,9 +76,12 @@ const StickyToolbar = props => {
72
76
  }
73
77
  }, [props.externalToolbarRef, props.offsetTop]);
74
78
  return jsx("div", {
75
- css: [mainToolbarWrapperStyle(props.twoLineEditorToolbar), stickyToolbarWrapperStyle, css`
76
- top: ${top}px;
77
- `],
79
+ css: [mainToolbarWrapperStyle(props.twoLineEditorToolbar), stickyToolbarWrapperStyle]
80
+ // eslint-disable-next-line @atlaskit/design-system/ensure-design-token-usage/preview
81
+ ,
82
+ style: {
83
+ top: `${top}px`
84
+ },
78
85
  "data-testid": "ak-editor-main-toolbar",
79
86
  className: 'show-keyline'
80
87
  }, props.children);
@@ -125,21 +132,23 @@ export const MainToolbar = ({
125
132
  twoLineEditorToolbar: twoLineEditorToolbar
126
133
  }, children);
127
134
  };
128
- export const mainToolbarCustomComponentsSlotStyle = (isTwoLineEditorToolbar = false) => css`
129
- display: flex;
130
- justify-content: flex-end;
131
- align-items: center;
132
- flex-grow: 1;
133
- padding-right: ${"var(--ds-space-250, 20px)"};
134
- ${isTwoLineEditorToolbar && `
135
+ export const mainToolbarCustomComponentsSlotStyle = (isTwoLineEditorToolbar = false) =>
136
+ // eslint-disable-next-line @atlaskit/design-system/no-css-tagged-template-expression -- Needs manual remediation
137
+ css`
138
+ display: flex;
139
+ justify-content: flex-end;
140
+ align-items: center;
141
+ flex-grow: 1;
142
+ padding-right: ${"var(--ds-space-250, 20px)"};
143
+ > div {
144
+ display: flex;
145
+ flex-shrink: 0;
146
+ }
147
+ ${isTwoLineEditorToolbar && `
135
148
  @media (max-width: ${MAXIMUM_TWO_LINE_TOOLBAR_BREAKPOINT}px) {
136
149
  {
137
150
  padding-right: 0;
138
151
  }
139
152
  }
140
153
  `}
141
- > div {
142
- display: flex;
143
- flex-shrink: 0;
144
- }
145
- `;
154
+ `;
@@ -96,10 +96,8 @@ const editorContentAreaWithLayoutWith = layoutMaxWidth => css({
96
96
  });
97
97
  const editorContentArea = css({
98
98
  lineHeight: '24px',
99
- // eslint-disable-next-line @atlaskit/design-system/ensure-design-token-usage/preview
100
- paddingTop: '50px',
101
- // eslint-disable-next-line @atlaskit/design-system/ensure-design-token-usage/preview
102
- paddingBottom: '55px',
99
+ paddingTop: "var(--ds-space-600, 48px)",
100
+ paddingBottom: "var(--ds-space-600, 48px)",
103
101
  height: 'calc( 100% - 105px )',
104
102
  width: '100%',
105
103
  margin: 'auto',
@@ -9,7 +9,9 @@ import WithFlash from '../WithFlash';
9
9
 
10
10
  // Only mobile bridge is using this appearance. We have some plans to decouple the appearances from editor-core. So it doesn't make sense to move this plugin to a separated package for now.
11
11
  // Copied packages/editor/editor-mobile-bridge/src/editor/editor-plugins/mobile-dimensions/index.ts
12
+
12
13
  // Copied from packages/editor/editor-mobile-bridge/src/editor/editor-plugins/mobile-dimensions/types.ts
14
+
13
15
  const mobileEditor = css`
14
16
  min-height: 30px;
15
17
  width: 100%;
@@ -5,13 +5,14 @@ import { sharedExpandStyles } from '@atlaskit/editor-common/ui';
5
5
  import { akEditorSelectedNodeClassName, akLayoutGutterOffset, getSelectionStyles, SelectionStyle } from '@atlaskit/editor-shared-styles';
6
6
  import { N100A, N40A, N50A, R300, R50 } from '@atlaskit/theme/colors';
7
7
  const EXPAND_SELECTED_BACKGROUND = "var(--ds-background-neutral-subtle, rgba(255, 255, 255, 0.6))";
8
- const EXPAND_ICON_COLOR = () => css`
9
- color: ${`var(--ds-icon-subtle, ${N100A})`};
10
- `;
8
+ const EXPAND_ICON_COLOR = () => css({
9
+ color: `var(--ds-icon-subtle, ${N100A})`
10
+ });
11
11
  const DANGER_STATE_BACKGROUND_COLOR = `var(--ds-background-danger, ${R50})`;
12
12
  const DANGER_STATE_BORDER_COLOR = `var(--ds-border-danger, ${R300})`;
13
13
 
14
14
  /* eslint-disable @atlaskit/design-system/ensure-design-token-usage */
15
+ // eslint-disable-next-line @atlaskit/design-system/no-css-tagged-template-expression -- Needs manual remediation
15
16
  export const expandStyles = () => css`
16
17
  .${expandClassNames.icon} > div {
17
18
  display: flex;
@@ -1,6 +1,6 @@
1
1
  import { css } from '@emotion/react';
2
2
  import { akEditorDeleteBackground, akEditorDeleteBorder, akEditorSelectedBorderSize, akEditorSelectedNodeClassName, blockNodesVerticalMargin, getSelectionStyles, SelectionStyle } from '@atlaskit/editor-shared-styles';
3
- // eslint-disable-next-line @atlaskit/design-system/ensure-design-token-usage
3
+ // eslint-disable-next-line @atlaskit/design-system/ensure-design-token-usage, @atlaskit/design-system/no-css-tagged-template-expression -- Needs manual remediation
4
4
  export const extensionStyles = css`
5
5
  .multiBodiedExtensionView-content-wrap {
6
6
  &.danger > span > .multiBodiedExtension--container {
@@ -1,3 +1,4 @@
1
+ /* eslint-disable @atlaskit/design-system/no-css-tagged-template-expression -- Requires manual remediation over time due to use of unsafe nested mixins */
1
2
  /** @jsx jsx */
2
3
  import React, { useMemo } from 'react';
3
4
  import { css, jsx, useTheme } from '@emotion/react';
@@ -119,21 +120,20 @@ const emojiStyles = css`
119
120
  }
120
121
  }
121
122
  `;
122
- export const placeholderStyles = css`
123
- .ProseMirror .placeholder-decoration {
124
- color: ${`var(--ds-text-subtlest, ${N200})`};
125
- width: 100%;
126
- pointer-events: none;
127
- user-select: none;
128
-
129
- .placeholder-android {
130
- pointer-events: none;
131
- outline: none;
132
- user-select: none;
133
- position: absolute;
123
+ export const placeholderStyles = css({
124
+ '.ProseMirror .placeholder-decoration': {
125
+ color: `var(--ds-text-subtlest, ${N200})`,
126
+ width: '100%',
127
+ pointerEvents: 'none',
128
+ userSelect: 'none',
129
+ '.placeholder-android': {
130
+ pointerEvents: 'none',
131
+ outline: 'none',
132
+ userSelect: 'none',
133
+ position: 'absolute'
134
134
  }
135
135
  }
136
- `;
136
+ });
137
137
  const contentStyles = props => css`
138
138
  .ProseMirror {
139
139
  outline: none;