@atlaskit/editor-core 208.3.5 → 208.4.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (30) hide show
  1. package/CHANGELOG.md +23 -0
  2. package/dist/cjs/ui/Appearance/FullPage/CustomToolbarWrapper.js +119 -0
  3. package/dist/cjs/ui/Appearance/FullPage/FullPage.js +6 -1
  4. package/dist/cjs/ui/Appearance/FullPage/FullPageContentArea.js +4 -28
  5. package/dist/cjs/ui/Appearance/FullPage/FullPageToolbar.js +9 -9
  6. package/dist/cjs/ui/Appearance/FullPage/MainToolbarWrapper.js +97 -0
  7. package/dist/cjs/ui/EditorContentContainer/EditorContentContainer.js +3 -7
  8. package/dist/cjs/ui/EditorContentContainer/styles/findReplaceStyles.js +44 -5
  9. package/dist/cjs/version-wrapper.js +1 -1
  10. package/dist/es2019/ui/Appearance/FullPage/CustomToolbarWrapper.js +103 -0
  11. package/dist/es2019/ui/Appearance/FullPage/FullPage.js +6 -1
  12. package/dist/es2019/ui/Appearance/FullPage/FullPageContentArea.js +6 -30
  13. package/dist/es2019/ui/Appearance/FullPage/FullPageToolbar.js +10 -10
  14. package/dist/es2019/ui/Appearance/FullPage/MainToolbarWrapper.js +92 -0
  15. package/dist/es2019/ui/EditorContentContainer/EditorContentContainer.js +5 -9
  16. package/dist/es2019/ui/EditorContentContainer/styles/findReplaceStyles.js +44 -5
  17. package/dist/es2019/version-wrapper.js +1 -1
  18. package/dist/esm/ui/Appearance/FullPage/CustomToolbarWrapper.js +111 -0
  19. package/dist/esm/ui/Appearance/FullPage/FullPage.js +6 -1
  20. package/dist/esm/ui/Appearance/FullPage/FullPageContentArea.js +6 -30
  21. package/dist/esm/ui/Appearance/FullPage/FullPageToolbar.js +10 -10
  22. package/dist/esm/ui/Appearance/FullPage/MainToolbarWrapper.js +90 -0
  23. package/dist/esm/ui/EditorContentContainer/EditorContentContainer.js +5 -9
  24. package/dist/esm/ui/EditorContentContainer/styles/findReplaceStyles.js +44 -5
  25. package/dist/esm/version-wrapper.js +1 -1
  26. package/dist/types/ui/Appearance/FullPage/CustomToolbarWrapper.d.ts +15 -0
  27. package/dist/types/ui/Appearance/FullPage/MainToolbarWrapper.d.ts +20 -0
  28. package/dist/types-ts4.5/ui/Appearance/FullPage/CustomToolbarWrapper.d.ts +15 -0
  29. package/dist/types-ts4.5/ui/Appearance/FullPage/MainToolbarWrapper.d.ts +20 -0
  30. package/package.json +4 -7
@@ -14,7 +14,7 @@ import { injectIntl } from 'react-intl-next';
14
14
  import { decisionListSelector, taskListSelector } from '@atlaskit/adf-schema';
15
15
  import { fullPageMessages as messages } from '@atlaskit/editor-common/messages';
16
16
  import { tableFullPageEditorStyles } from '@atlaskit/editor-plugins/table/ui/common-styles';
17
- import { FULL_PAGE_EDITOR_TOOLBAR_HEIGHT as FULL_PAGE_EDITOR_TOOLBAR_HEIGHT_OLD, akEditorGutterPaddingDynamic } from '@atlaskit/editor-shared-styles';
17
+ import { FULL_PAGE_EDITOR_TOOLBAR_HEIGHT, akEditorGutterPaddingDynamic } from '@atlaskit/editor-shared-styles';
18
18
  import { scrollbarStyles } from '@atlaskit/editor-shared-styles/scrollbar';
19
19
  import { fg } from '@atlaskit/platform-feature-flags';
20
20
  import { componentWithCondition } from '@atlaskit/platform-feature-flags-react';
@@ -36,8 +36,6 @@ var tableMarginFullWidthMode = 2;
36
36
  var akLayoutGutterOffset = 12;
37
37
  var SWOOP_ANIMATION = "0.5s ".concat(akEditorSwoopCubicBezier);
38
38
  var AK_NESTED_DND_GUTTER_OFFSET = 8;
39
- var FULL_PAGE_EDITOR_TOOLBAR_HEIGHT = "var(--ds-space-500, 40px)";
40
- var FULL_PAGE_EDITOR_TOOLBAR_HEIGHT_LIVE_PAGE = '2.188rem';
41
39
  var getTotalPadding = function getTotalPadding() {
42
40
  return akEditorGutterPaddingDynamic() * 2;
43
41
  };
@@ -125,7 +123,7 @@ var editorContentArea = css({
125
123
  // When the toolbar is hidden, we don't want content to jump up
126
124
  // the extra 1px is to account for the border on the toolbar
127
125
  // eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values, @atlaskit/ui-styling-standard/no-unsafe-values
128
- paddingTop: "calc(".concat("var(--ds-space-600, 48px)", " + ", FULL_PAGE_EDITOR_TOOLBAR_HEIGHT_OLD(), " + 1px)")
126
+ paddingTop: "calc(".concat("var(--ds-space-600, 48px)", " + ", FULL_PAGE_EDITOR_TOOLBAR_HEIGHT(), " + 1px)")
129
127
  },
130
128
  paddingBottom: "var(--ds-space-600, 48px)",
131
129
  height: 'calc( 100% - 105px )',
@@ -210,18 +208,6 @@ var editorContentGutterStyle = function editorContentGutterStyle() {
210
208
  };
211
209
 
212
210
  // new styles
213
- var editorContentAreaNoToolbarLivePageJumpMitigation = css({
214
- // eslint-disable-next-line @atlaskit/ui-styling-standard/no-nested-selectors, @atlaskit/ui-styling-standard/no-unsafe-selectors
215
- '.ak-editor-content-area-no-toolbar &': {
216
- paddingTop: "calc(".concat("var(--ds-space-600, 48px)", " + ", FULL_PAGE_EDITOR_TOOLBAR_HEIGHT_LIVE_PAGE, " + 1px)")
217
- }
218
- });
219
- var editorContentAreaNoToolbarControls = css({
220
- // eslint-disable-next-line @atlaskit/ui-styling-standard/no-nested-selectors, @atlaskit/ui-styling-standard/no-unsafe-selectors
221
- '.ak-editor-content-area-no-toolbar &': {
222
- paddingTop: "calc(".concat("var(--ds-space-600, 48px)", " + ", FULL_PAGE_EDITOR_TOOLBAR_HEIGHT, " + 1px)")
223
- }
224
- });
225
211
  var editorContentAreaNew = css({
226
212
  // eslint-disable-next-line @atlaskit/design-system/use-tokens-typography
227
213
  lineHeight: '24px',
@@ -230,7 +216,7 @@ var editorContentAreaNew = css({
230
216
  '.ak-editor-content-area-no-toolbar &': {
231
217
  // When the toolbar is hidden, we don't want content to jump up
232
218
  // the extra 1px is to account for the border on the toolbar
233
- paddingTop: "calc(".concat("var(--ds-space-600, 48px)", " + ", FULL_PAGE_EDITOR_TOOLBAR_HEIGHT, " + 1px)")
219
+ paddingTop: "calc(".concat("var(--ds-space-600, 48px)", " + var(--ak-editor-fullpage-toolbar-height) + 1px)")
234
220
  },
235
221
  paddingBottom: "var(--ds-space-600, 48px)",
236
222
  height: 'calc( 100% - 105px )',
@@ -320,7 +306,7 @@ var editorContentGutterStyles = css({
320
306
  var contentAreaNew = css({
321
307
  display: 'flex',
322
308
  flexDirection: 'row',
323
- height: "calc(100% - ".concat(FULL_PAGE_EDITOR_TOOLBAR_HEIGHT, ")"),
309
+ height: "calc(100% - var(--ak-editor-fullpage-toolbar-height))",
324
310
  // eslint-disable-next-line @atlaskit/ui-styling-standard/no-nested-selectors, @atlaskit/ui-styling-standard/no-unsafe-values
325
311
  '&.ak-editor-content-area-no-toolbar': {
326
312
  // The editor toolbar height is 1px off (from the border) -- so we need to add 1px to the height
@@ -332,12 +318,6 @@ var contentAreaNew = css({
332
318
  padding: 0,
333
319
  transition: "padding 0ms ".concat(akEditorSwoopCubicBezier)
334
320
  });
335
- var contentAreaHeightLivePageJumpMitigation = css({
336
- height: "calc(100% - ".concat(FULL_PAGE_EDITOR_TOOLBAR_HEIGHT_LIVE_PAGE, ")")
337
- });
338
- var contentAreaHeightControls = css({
339
- height: "calc(100% - ".concat(FULL_PAGE_EDITOR_TOOLBAR_HEIGHT, ")")
340
- });
341
321
  var contentAreaHeightNoToolbar = css({
342
322
  height: '100%'
343
323
  });
@@ -394,9 +374,7 @@ var Content = /*#__PURE__*/React.forwardRef(function (props, ref) {
394
374
  return editorExperiment('platform_editor_controls', 'variant1');
395
375
  };
396
376
  return jsx("div", {
397
- css: expValEquals('platform_editor_core_static_emotion_non_central', 'isEnabled', true) ? [contentAreaNew, fg('live_pages_content_jump_mitigation') && contentAreaHeightLivePageJumpMitigation, editorExperiment('platform_editor_controls', 'variant1', {
398
- exposure: true
399
- }) && contentAreaHeightControls, props.isEditorToolbarHidden && contentAreaHeightNoToolbar] : [
377
+ css: expValEquals('platform_editor_core_static_emotion_non_central', 'isEnabled', true) ? [contentAreaNew, props.isEditorToolbarHidden && contentAreaHeightNoToolbar] : [
400
378
  // eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values, @atlaskit/design-system/consistent-css-prop-usage -- Ignored via go/DSP-18766
401
379
  contentArea,
402
380
  // eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values
@@ -422,9 +400,7 @@ var Content = /*#__PURE__*/React.forwardRef(function (props, ref) {
422
400
  editorView: props.editorView,
423
401
  editorDisabled: props.disabled
424
402
  }, jsx("div", {
425
- css: expValEquals('platform_editor_core_static_emotion_non_central', 'isEnabled', true) ? [editorContentAreaNew, editorContentAreaProsemirrorStyle, tableFullPageEditorStylesNew, fg('live_pages_content_jump_mitigation') && editorContentAreaNoToolbarLivePageJumpMitigation, editorExperiment('platform_editor_controls', 'variant1', {
426
- exposure: true
427
- }) && editorContentAreaNoToolbarControls, fg('platform_editor_fix_table_width_inline_comment') ? fullWidthNonChromelessBreakoutBlockTableStyle : fullWidthModeBreakoutBlockTableStyle,
403
+ css: expValEquals('platform_editor_core_static_emotion_non_central', 'isEnabled', true) ? [editorContentAreaNew, editorContentAreaProsemirrorStyle, tableFullPageEditorStylesNew, fg('platform_editor_fix_table_width_inline_comment') ? fullWidthNonChromelessBreakoutBlockTableStyle : fullWidthModeBreakoutBlockTableStyle,
428
404
  // for breakout resizing, there's no need to restrict the width of codeblocks as they're always wrapped in a breakout mark
429
405
  expValEqualsNoExposure('platform_editor_breakout_resizing', 'isEnabled', true) && fg('platform_editor_breakout_resizing_width_changes') ? editorContentAreaContainerStyleExcludeCodeBlockNew : editorContentAreaContainerStyleNew, fg('platform_editor_nested_dnd_styles_changes') && editorContentAreaContainerNestedDndStyle, !fg('platform_editor_controls_no_toolbar_space') && editorExperiment('platform_editor_controls', 'variant1') && contentAreaReducedHeaderSpace, !fg('platform_editor_controls_no_toolbar_space') && props.isEditorToolbarHidden && editorExperiment('platform_editor_controls', 'variant1') && contentAreaReservedPrimaryToolbarSpace] : _toConsumableArray(editorContentAreaStyle({
430
406
  fullWidthMode: fullWidthMode,
@@ -16,7 +16,9 @@ import { editorExperiment } from '@atlaskit/tmp-editor-statsig/experiments';
16
16
  import { ToolbarPortalMountPoint, useToolbarPortal } from '../../Toolbar/ToolbarPortal';
17
17
  import { ToolbarWithSizeDetector as Toolbar } from '../../Toolbar/ToolbarWithSizeDetector';
18
18
  import { BeforePrimaryToolbarWrapper } from './BeforeWrapper';
19
- import { customToolbarWrapperStyle, mainToolbarFirstChildStyle, mainToolbarIconBeforeStyle, mainToolbarSecondChildStyle, mainToolbarStyle, MAXIMUM_TWO_LINE_TOOLBAR_BREAKPOINT, nonCustomToolbarWrapperStyle } from './MainToolbar';
19
+ import { MainToolbarForFirstChildWrapper, MainToolbarForSecondChildWrapper } from './CustomToolbarWrapper';
20
+ import { customToolbarWrapperStyle, mainToolbarIconBeforeStyle, MAXIMUM_TWO_LINE_TOOLBAR_BREAKPOINT, nonCustomToolbarWrapperStyle } from './MainToolbar';
21
+ import { MainToolbarWrapper } from './MainToolbarWrapper';
20
22
  export var EditorToolbar = /*#__PURE__*/React.memo(function (props) {
21
23
  var _props$primaryToolbar, _useToolbarPortal, _props$customPrimaryT;
22
24
  var _useState = useState(false),
@@ -121,18 +123,16 @@ export var EditorToolbar = /*#__PURE__*/React.memo(function (props) {
121
123
  isShortcutToFocusToolbar: isShortcutToFocusToolbar,
122
124
  handleEscape: handleEscape,
123
125
  intl: props.intl
124
- }, jsx(ToolbarPortal, null, jsx("div", {
125
- // eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values, @atlaskit/design-system/consistent-css-prop-usage -- Ignored via go/DSP-18766
126
- css: mainToolbarStyle(props.showKeyline || contextPanelWidth > 0, twoLineEditorToolbar),
126
+ }, jsx(ToolbarPortal, null, jsx(MainToolbarWrapper, {
127
+ showKeyline: props.showKeyline || contextPanelWidth > 0,
128
+ twoLineEditorToolbar: twoLineEditorToolbar,
127
129
  "data-testid": "ak-editor-main-toolbar"
128
- }, jsx("div", {
129
- // eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values, @atlaskit/design-system/consistent-css-prop-usage -- Ignored via go/DSP-18766
130
- css: mainToolbarFirstChildStyle(twoLineEditorToolbar),
130
+ }, jsx(MainToolbarForFirstChildWrapper, {
131
+ twoLineEditorToolbar: twoLineEditorToolbar,
131
132
  role: "toolbar",
132
133
  "aria-label": props.intl.formatMessage(messages.toolbarLabel)
133
- }, shouldSplitToolbar ? customToolbar : nonCustomToolbar), jsx("div", {
134
- // eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values, @atlaskit/design-system/consistent-css-prop-usage -- Ignored via go/DSP-18766
135
- css: mainToolbarSecondChildStyle(twoLineEditorToolbar),
134
+ }, shouldSplitToolbar ? customToolbar : nonCustomToolbar), jsx(MainToolbarForSecondChildWrapper, {
135
+ twoLineEditorToolbar: twoLineEditorToolbar,
136
136
  "data-testid": "avatar-group-outside-plugin",
137
137
  role: "region",
138
138
  "aria-label": props.intl.formatMessage(messages.pageActionsLabel)
@@ -0,0 +1,90 @@
1
+ import _defineProperty from "@babel/runtime/helpers/defineProperty";
2
+ /**
3
+ * @jsxRuntime classic
4
+ * @jsx jsx
5
+ */
6
+ import React from 'react';
7
+
8
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
9
+ import { css, jsx } from '@emotion/react';
10
+ import { akEditorFloatingDialogZIndex, akEditorSwoopCubicBezier } from '@atlaskit/editor-shared-styles';
11
+ import { fg } from '@atlaskit/platform-feature-flags';
12
+ import { componentWithCondition } from '@atlaskit/platform-feature-flags-react';
13
+ import { expValEquals } from '@atlaskit/tmp-editor-statsig/exp-val-equals';
14
+ import { mainToolbarStyle as mainToolbarStyleDynamic, MAXIMUM_TWO_LINE_TOOLBAR_BREAKPOINT } from './MainToolbar';
15
+
16
+ // Base styles that don't depend on feature flags
17
+ var baseToolbarStyles = css({
18
+ position: 'relative',
19
+ alignItems: 'center',
20
+ boxShadow: 'none',
21
+ borderBottom: "1px solid ".concat("var(--ds-border, #091E4224)"),
22
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values, @atlaskit/ui-styling-standard/no-unsafe-values
23
+ transition: "box-shadow 200ms ".concat(akEditorSwoopCubicBezier),
24
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-values, @atlaskit/ui-styling-standard/no-imported-style-values
25
+ zIndex: akEditorFloatingDialogZIndex,
26
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-values, @atlaskit/ui-styling-standard/no-imported-style-values
27
+ display: 'flex',
28
+ height: 'var(--ak-editor-fullpage-toolbar-height)',
29
+ flexShrink: 0,
30
+ backgroundColor: "var(--ds-surface, #FFFFFF)",
31
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-nested-selectors
32
+ '& object': {
33
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-important-styles
34
+ height: '0 !important'
35
+ }
36
+ });
37
+ var flexibleIconSize = css({
38
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-nested-selectors
39
+ '& span svg': {
40
+ maxWidth: '100%'
41
+ }
42
+ });
43
+ // box-shadow is overriden by the mainToolbar
44
+ var mainToolbarWithKeyline = css({
45
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values, @atlaskit/ui-styling-standard/no-unsafe-values -- Ignored via go/DSP-18766
46
+ boxShadow: "var(--ds-shadow-overflow, 0px 0px 8px #091E4228, 0px 0px 1px #091E421e)"
47
+ });
48
+ var mainToolbarTwoLineStyle = css(_defineProperty({}, "@media (max-width: ".concat(MAXIMUM_TWO_LINE_TOOLBAR_BREAKPOINT, "px)"), {
49
+ flexWrap: 'wrap',
50
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values, @atlaskit/ui-styling-standard/no-unsafe-values -- Ignored via go/DSP-18766
51
+ height: "calc(var(--ak-editor-fullpage-toolbar-height) * 2)"
52
+ }));
53
+ var MainToolbarWrapperNext = function MainToolbarWrapperNext(_ref) {
54
+ var showKeyline = _ref.showKeyline,
55
+ twoLineEditorToolbar = _ref.twoLineEditorToolbar,
56
+ children = _ref.children,
57
+ testId = _ref['data-testid'];
58
+ return jsx("div", {
59
+ // eslint-disable-next-line @atlaskit/design-system/consistent-css-prop-usage
60
+ css: [baseToolbarStyles, fg('platform-visual-refresh-icons') && flexibleIconSize, showKeyline && mainToolbarWithKeyline, twoLineEditorToolbar && mainToolbarTwoLineStyle],
61
+ "data-testid": testId
62
+ }, children);
63
+ };
64
+
65
+ /**
66
+ * Original version of the toolbar wrapper using dynamic styles
67
+ */
68
+ var MainToolbarWrapperOld = function MainToolbarWrapperOld(_ref2) {
69
+ var showKeyline = _ref2.showKeyline,
70
+ twoLineEditorToolbar = _ref2.twoLineEditorToolbar,
71
+ children = _ref2.children,
72
+ testId = _ref2['data-testid'];
73
+ return jsx("div", {
74
+ css:
75
+ // eslint-disable-next-line @atlaskit/design-system/consistent-css-prop-usage, @atlaskit/ui-styling-standard/no-imported-style-values
76
+ mainToolbarStyleDynamic(showKeyline, twoLineEditorToolbar),
77
+ "data-testid": testId
78
+ }, children);
79
+ };
80
+
81
+ /**
82
+ * Wrapper component for the main toolbar that handles feature flag based styling
83
+ * @example
84
+ * <MainToolbarWrapper showKeyline={true} twoLineEditorToolbar={false}>
85
+ * <ToolbarContent />
86
+ * </MainToolbarWrapper>
87
+ */
88
+ export var MainToolbarWrapper = componentWithCondition(function () {
89
+ return expValEquals('platform_editor_core_static_emotion_non_central', 'isEnabled', true);
90
+ }, MainToolbarWrapperNext, MainToolbarWrapperOld);
@@ -25,7 +25,7 @@ import { codeMarkStyles } from './styles/codeMarkStyles';
25
25
  import { commentEditorStyles } from './styles/commentEditorStyles';
26
26
  import { cursorStyles } from './styles/cursorStyles';
27
27
  import { dateStyles, dateVanillaStyles } from './styles/dateStyles';
28
- import { editorUGCTokensDefault, editorUGCTokensModernized, editorUGCTokensRefreshed } from './styles/editorUGCTokenStyles';
28
+ import { editorUGCTokensDefault, editorUGCTokensRefreshed } from './styles/editorUGCTokenStyles';
29
29
  import { embedCardStyles } from './styles/embedCardStyles';
30
30
  import { reactEmojiStyles, vanillaEmojiStyles } from './styles/emoji';
31
31
  import { expandStyles, expandStylesMixin_fg_platform_editor_nested_dnd_styles_changes, expandStylesMixin_fg_platform_visual_refresh_icons, expandStylesMixin_without_fg_platform_editor_nested_dnd_styles_changes } from './styles/expandStyles';
@@ -44,7 +44,7 @@ import { listsStyles, listsStylesSafariFix } from './styles/list';
44
44
  import { mediaAlignmentStyles, mediaGroupStyles, mediaStyles } from './styles/mediaStyles';
45
45
  import { mentionsStyles, mentionsSelectionStyles, mentionNodeStyles } from './styles/mentions';
46
46
  import { panelStyles, panelStylesMixin, panelStylesMixin_fg_platform_editor_add_border_for_nested_panel, panelStylesMixin_fg_platform_editor_nested_dnd_styles_changes, panelViewStyles } from './styles/panelStyles';
47
- import { paragraphStylesOld, paragraphStylesUGCModernized, paragraphStylesUGCRefreshed } from './styles/paragraphStyles';
47
+ import { paragraphStylesOld, paragraphStylesUGCRefreshed } from './styles/paragraphStyles';
48
48
  import { placeholderOverflowStyles, placeholderStyles, placeholderTextStyles, placeholderTextStylesMixin_fg_platform_editor_system_fake_text_highlight_colour, placeholderWrapStyles } from './styles/placeholderStyles';
49
49
  import { pragmaticResizerStyles, pragmaticResizerStylesNew, pragmaticStylesLayoutFirstNodeResizeHandleFix, pragmaticResizerStylesForTooltip, resizerStyles } from './styles/resizerStyles';
50
50
  import { ruleStyles } from './styles/rule';
@@ -118,11 +118,9 @@ var EditorContentContainer = /*#__PURE__*/React.forwardRef(function (props, ref)
118
118
  // eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values
119
119
  codeBlockStyles,
120
120
  // eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values
121
- !fg('platform_editor_typography_ugc') && editorUGCTokensDefault, (fg('platform-dst-jira-web-fonts') || fg('confluence_typography_refreshed') || fg('atlas_editor_typography_refreshed')) && fg('platform_editor_typography_ugc') &&
121
+ !fg('platform_editor_typography_ugc') && editorUGCTokensDefault, fg('platform_editor_typography_ugc') &&
122
122
  // eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values
123
- editorUGCTokensRefreshed, !(fg('platform-dst-jira-web-fonts') || fg('confluence_typography_refreshed') || fg('atlas_editor_typography_refreshed')) && fg('platform_editor_typography_ugc') &&
124
- // eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values
125
- editorUGCTokensModernized,
123
+ editorUGCTokensRefreshed,
126
124
  // eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values
127
125
  blocktypeStyles,
128
126
  // eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values
@@ -260,12 +258,10 @@ var EditorContentContainer = /*#__PURE__*/React.forwardRef(function (props, ref)
260
258
  // eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values
261
259
  linkingVisualRefreshV1Styles,
262
260
  // eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values
263
- dateVanillaStyles, fg('platform_editor_typography_ugc') ? fg('platform-dst-jira-web-fonts') || fg('confluence_typography_refreshed') || fg('atlas_editor_typography_refreshed') ?
261
+ dateVanillaStyles, fg('platform_editor_typography_ugc') ?
264
262
  // eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values
265
263
  paragraphStylesUGCRefreshed :
266
264
  // eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values
267
- paragraphStylesUGCModernized :
268
- // eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values
269
265
  paragraphStylesOld,
270
266
  // eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values
271
267
  fg('platform_editor_hyperlink_underline') ? linkStyles : linkStylesOld,
@@ -37,13 +37,23 @@ export var findReplaceStylesNew = css({
37
37
  // eslint-disable-next-line @atlaskit/ui-styling-standard/no-nested-selectors
38
38
  '[data-smart-link-container="true"], .loader-wrapper>div::after': {
39
39
  boxShadow: "\n\t\t\tinset 0 0 0 1px ".concat("var(--ds-background-accent-yellow-subtler-pressed, #E2B203)", ",\n\t\t\tinset 0 0 0 5px ", "var(--ds-background-accent-yellow-subtler, #F8E6A0)", "\n\t\t\t")
40
+ },
41
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-nested-selectors
42
+ '.loader-wrapper>a, .lozenge-wrapper, .editor-mention-primitive, .date-lozenger-container': {
43
+ boxShadow: "0px 0px 0px 4px ".concat("var(--ds-background-accent-yellow-subtler, #F8E6A0)", ", 0px 0px 0px 5px ", "var(--ds-background-accent-yellow-subtler-pressed, #E2B203)"),
44
+ borderRadius: '3px'
40
45
  }
41
46
  },
42
47
  // eslint-disable-next-line @atlaskit/ui-styling-standard/no-nested-selectors
43
- '.search-match-selected.search-match-block': {
48
+ '.search-match-block.search-match-block-selected': {
44
49
  // eslint-disable-next-line @atlaskit/ui-styling-standard/no-nested-selectors
45
50
  '[data-smart-link-container="true"], .loader-wrapper>div::after': {
46
51
  boxShadow: "\n\t\t\tinset 0 0 0 1px ".concat("var(--ds-background-accent-yellow-subtler-pressed, #E2B203)", ",\n\t\t\tinset 0 0 0 4px ", "var(--ds-background-accent-yellow-subtlest-pressed, #F5CD47)", "\n\t\t\t")
52
+ },
53
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-nested-selectors
54
+ '.loader-wrapper>a, .lozenge-wrapper, .editor-mention-primitive, .date-lozenger-container': {
55
+ boxShadow: "0px 0px 0px 4px ".concat("var(--ds-background-accent-yellow-subtlest-pressed, #F5CD47)", ", 0px 0px 0px 5px ", "var(--ds-background-accent-yellow-subtler-pressed, #E2B203)"),
56
+ borderRadius: '3px'
47
57
  }
48
58
  },
49
59
  /** With node selection */
@@ -52,30 +62,49 @@ export var findReplaceStylesNew = css({
52
62
  // eslint-disable-next-line @atlaskit/ui-styling-standard/no-nested-selectors
53
63
  '.loader-wrapper>div::after': {
54
64
  boxShadow: "\n\t\t\tinset 0 0 0 1px ".concat("var(--ds-background-accent-yellow-subtler-pressed, #E2B203)", ",\n\t\t\tinset 0 0 0 5px ", "var(--ds-background-accent-yellow-subtler, #F8E6A0)", ",\n\t\t\t0 0 0 1px ", "var(--ds-border-selected, #0C66E4)", "\n\t\t\t")
65
+ },
66
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-nested-selectors
67
+ '.loader-wrapper>a, .lozenge-wrapper': {
68
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-important-styles
69
+ boxShadow: "0 0 0 1px ".concat("var(--ds-border-selected, #0C66E4)", ", 0px 0px 0px 4px ", "var(--ds-background-accent-yellow-subtler, #F8E6A0)", ", 0px 0px 0px 5px ", "var(--ds-background-accent-yellow-subtler-pressed, #E2B203)", " !important")
55
70
  }
56
71
  },
57
72
  // eslint-disable-next-line @atlaskit/ui-styling-standard/no-nested-selectors
58
- '.search-match-selected.search-match-block.ak-editor-selected-node': {
73
+ '.search-match-block.search-match-block-selected.ak-editor-selected-node': {
59
74
  // eslint-disable-next-line @atlaskit/ui-styling-standard/no-nested-selectors
60
75
  '[data-smart-link-container="true"], .loader-wrapper>div::after': {
61
76
  boxShadow: "\n\t\t\tinset 0 0 0 1px ".concat("var(--ds-background-accent-yellow-subtler-pressed, #E2B203)", ",\n\t\t\tinset 0 0 0 4px ", "var(--ds-background-accent-yellow-subtlest-pressed, #F5CD47)", ",\n\t\t\t0 0 0 1px ", "var(--ds-border-selected, #0C66E4)", "\n\t\t\t")
77
+ },
78
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-nested-selectors
79
+ '.loader-wrapper>a, .lozenge-wrapper': {
80
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-important-styles
81
+ boxShadow: "0 0 0 1px ".concat("var(--ds-border-selected, #0C66E4)", ", 0px 0px 0px 4px ", "var(--ds-background-accent-yellow-subtlest-pressed, #F5CD47)", ", 0px 0px 0px 5px ", "var(--ds-background-accent-yellow-subtler-pressed, #E2B203)", " !important")
62
82
  }
63
83
  },
64
84
  /** Dark mode */
65
-
66
85
  /** Without node selection */
67
86
  // eslint-disable-next-line @atlaskit/ui-styling-standard/no-nested-selectors
68
87
  '.search-match-block.search-match-dark': {
69
88
  // eslint-disable-next-line @atlaskit/ui-styling-standard/no-nested-selectors
70
89
  '[data-smart-link-container="true"], .loader-wrapper>div::after': {
71
90
  boxShadow: "\n\t\t\tinset 0 0 0 1px ".concat("var(--ds-background-accent-yellow-bolder, #946F00)", ",\n\t\t\tinset 0 0 0 5px ", "var(--ds-background-accent-yellow-bolder-pressed, #533F04)", "\n\t\t\t")
91
+ },
92
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-nested-selectors
93
+ '.loader-wrapper>a, .lozenge-wrapper, .editor-mention-primitive, .date-lozenger-container': {
94
+ boxShadow: "0px 0px 0px 4px ".concat("var(--ds-background-accent-yellow-bolder-pressed, #533F04)", ", 0px 0px 0px 5px ", "var(--ds-background-accent-yellow-bolder, #946F00)"),
95
+ borderRadius: '3px'
72
96
  }
73
97
  },
74
98
  // eslint-disable-next-line @atlaskit/ui-styling-standard/no-nested-selectors
75
- '.search-match-selected.search-match-block.search-match-dark': {
99
+ '.search-match-block.search-match-block-selected.search-match-dark': {
76
100
  // eslint-disable-next-line @atlaskit/ui-styling-standard/no-nested-selectors
77
101
  '[data-smart-link-container="true"], .loader-wrapper>div::after': {
78
102
  boxShadow: "\n\t\t\tinset 0 0 0 1px ".concat("var(--ds-background-accent-yellow-bolder, #946F00)", ",\n\t\t\tinset 0 0 0 4px ", "var(--ds-background-accent-yellow-bolder-hovered, #7F5F01)", "\n\t\t\t")
103
+ },
104
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-nested-selectors
105
+ '.loader-wrapper>a, .lozenge-wrapper, .editor-mention-primitive, .date-lozenger-container': {
106
+ boxShadow: "0px 0px 0px 4px ".concat("var(--ds-background-accent-yellow-bolder-hovered, #7F5F01)", ", 0px 0px 0px 5px ", "var(--ds-background-accent-yellow-bolder, #946F00)"),
107
+ borderRadius: '3px'
79
108
  }
80
109
  },
81
110
  /** With node selection */
@@ -84,13 +113,23 @@ export var findReplaceStylesNew = css({
84
113
  // eslint-disable-next-line @atlaskit/ui-styling-standard/no-nested-selectors
85
114
  '.loader-wrapper>div::after': {
86
115
  boxShadow: "\n\t\t\tinset 0 0 0 1px ".concat("var(--ds-background-accent-yellow-bolder, #946F00)", ",\n\t\t\tinset 0 0 0 5px ", "var(--ds-background-accent-yellow-bolder-pressed, #533F04)", ",\n\t\t\t0 0 0 1px ", "var(--ds-border-selected, #0C66E4)", "\n\t\t\t")
116
+ },
117
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-nested-selectors
118
+ '.loader-wrapper>a, .lozenge-wrapper': {
119
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-important-styles
120
+ boxShadow: "0 0 0 1px ".concat("var(--ds-border-selected, #0C66E4)", ", 0px 0px 0px 4px ", "var(--ds-background-accent-yellow-bolder-pressed, #533F04)", ", 0px 0px 0px 5px ", "var(--ds-background-accent-yellow-bolder, #946F00)", " !important")
87
121
  }
88
122
  },
89
123
  // eslint-disable-next-line @atlaskit/ui-styling-standard/no-nested-selectors
90
- '.search-match-selected.search-match-block.search-match-dark.ak-editor-selected-node': {
124
+ '.search-match-block.search-match-block-selected.search-match-dark.ak-editor-selected-node': {
91
125
  // eslint-disable-next-line @atlaskit/ui-styling-standard/no-nested-selectors
92
126
  '[data-smart-link-container="true"], .loader-wrapper>div::after': {
93
127
  boxShadow: "\n\t\t\tinset 0 0 0 1px ".concat("var(--ds-background-accent-yellow-bolder, #946F00)", ",\n\t\t\tinset 0 0 0 4px ", "var(--ds-background-accent-yellow-bolder-hovered, #7F5F01)", ",\n\t\t\t0 0 0 1px ", "var(--ds-border-selected, #0C66E4)", "\n\t\t\t")
128
+ },
129
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-nested-selectors
130
+ '.loader-wrapper>a, .lozenge-wrapper': {
131
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-important-styles
132
+ boxShadow: "0 0 0 1px ".concat("var(--ds-border-selected, #0C66E4)", ", 0px 0px 0px 4px ", "var(--ds-background-accent-yellow-bolder-hovered, #7F5F01)", ", 0px 0px 0px 5px ", "var(--ds-background-accent-yellow-bolder, #946F00)", " !important")
94
133
  }
95
134
  }
96
135
  });
@@ -1,2 +1,2 @@
1
1
  export var name = "@atlaskit/editor-core";
2
- export var version = "208.3.4";
2
+ export var version = "208.3.6";
@@ -0,0 +1,15 @@
1
+ /**
2
+ * @jsxRuntime classic
3
+ * @jsx jsx
4
+ */
5
+ import React from 'react';
6
+ interface ChildWrapperProps {
7
+ twoLineEditorToolbar: boolean;
8
+ children: React.ReactNode;
9
+ role?: string;
10
+ 'aria-label'?: string;
11
+ 'data-testid'?: string;
12
+ }
13
+ export declare const MainToolbarForFirstChildWrapper: React.FC<ChildWrapperProps>;
14
+ export declare const MainToolbarForSecondChildWrapper: React.FC<ChildWrapperProps>;
15
+ export {};
@@ -0,0 +1,20 @@
1
+ /**
2
+ * @jsxRuntime classic
3
+ * @jsx jsx
4
+ */
5
+ import React from 'react';
6
+ interface MainToolbarWrapperProps {
7
+ showKeyline: boolean;
8
+ twoLineEditorToolbar: boolean;
9
+ children: React.ReactNode;
10
+ 'data-testid'?: string;
11
+ }
12
+ /**
13
+ * Wrapper component for the main toolbar that handles feature flag based styling
14
+ * @example
15
+ * <MainToolbarWrapper showKeyline={true} twoLineEditorToolbar={false}>
16
+ * <ToolbarContent />
17
+ * </MainToolbarWrapper>
18
+ */
19
+ export declare const MainToolbarWrapper: React.FC<MainToolbarWrapperProps>;
20
+ export {};
@@ -0,0 +1,15 @@
1
+ /**
2
+ * @jsxRuntime classic
3
+ * @jsx jsx
4
+ */
5
+ import React from 'react';
6
+ interface ChildWrapperProps {
7
+ twoLineEditorToolbar: boolean;
8
+ children: React.ReactNode;
9
+ role?: string;
10
+ 'aria-label'?: string;
11
+ 'data-testid'?: string;
12
+ }
13
+ export declare const MainToolbarForFirstChildWrapper: React.FC<ChildWrapperProps>;
14
+ export declare const MainToolbarForSecondChildWrapper: React.FC<ChildWrapperProps>;
15
+ export {};
@@ -0,0 +1,20 @@
1
+ /**
2
+ * @jsxRuntime classic
3
+ * @jsx jsx
4
+ */
5
+ import React from 'react';
6
+ interface MainToolbarWrapperProps {
7
+ showKeyline: boolean;
8
+ twoLineEditorToolbar: boolean;
9
+ children: React.ReactNode;
10
+ 'data-testid'?: string;
11
+ }
12
+ /**
13
+ * Wrapper component for the main toolbar that handles feature flag based styling
14
+ * @example
15
+ * <MainToolbarWrapper showKeyline={true} twoLineEditorToolbar={false}>
16
+ * <ToolbarContent />
17
+ * </MainToolbarWrapper>
18
+ */
19
+ export declare const MainToolbarWrapper: React.FC<MainToolbarWrapperProps>;
20
+ export {};
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@atlaskit/editor-core",
3
- "version": "208.3.5",
3
+ "version": "208.4.0",
4
4
  "description": "A package contains Atlassian editor core functionality",
5
5
  "publishConfig": {
6
6
  "registry": "https://registry.npmjs.org/"
@@ -51,7 +51,7 @@
51
51
  "@atlaskit/editor-performance-metrics": "^2.1.0",
52
52
  "@atlaskit/editor-plugin-quick-insert": "^2.6.0",
53
53
  "@atlaskit/editor-plugin-user-preferences": "^0.2.0",
54
- "@atlaskit/editor-plugins": "^9.2.0",
54
+ "@atlaskit/editor-plugins": "^9.3.0",
55
55
  "@atlaskit/editor-prosemirror": "7.0.0",
56
56
  "@atlaskit/editor-shared-styles": "^3.4.0",
57
57
  "@atlaskit/emoji": "^69.3.0",
@@ -97,7 +97,7 @@
97
97
  "@atlaskit/editor-plugin-list": "^4.2.0",
98
98
  "@atlaskit/editor-plugin-paste": "^3.3.0",
99
99
  "@atlaskit/link-provider": "^3.3.0",
100
- "@atlaskit/logo": "^19.2.0",
100
+ "@atlaskit/logo": "^19.3.0",
101
101
  "@atlaskit/media-core": "^37.0.0",
102
102
  "@atlaskit/media-integration-test-helpers": "workspace:^",
103
103
  "@atlaskit/media-test-helpers": "^37.0.0",
@@ -105,7 +105,7 @@
105
105
  "@atlaskit/primitives": "^14.9.0",
106
106
  "@atlaskit/renderer": "^119.0.0",
107
107
  "@atlaskit/section-message": "^8.2.0",
108
- "@atlaskit/smart-card": "^38.14.0",
108
+ "@atlaskit/smart-card": "^38.16.0",
109
109
  "@atlaskit/synchrony-test-helpers": "workspace:^",
110
110
  "@atlaskit/toggle": "^15.0.0",
111
111
  "@atlaskit/util-data-test": "^18.0.0",
@@ -567,9 +567,6 @@
567
567
  "platform_editor_breakout_resizing_hello_release": {
568
568
  "type": "boolean"
569
569
  },
570
- "confluence_typography_refreshed": {
571
- "type": "boolean"
572
- },
573
570
  "atlas_editor_typography_refreshed": {
574
571
  "type": "boolean"
575
572
  },