@atlaskit/editor-toolbar 2.8.16 → 2.8.18

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.
package/CHANGELOG.md CHANGED
@@ -1,5 +1,20 @@
1
1
  # @atlaskit/editor-toolbar
2
2
 
3
+ ## 2.8.18
4
+
5
+ ### Patch Changes
6
+
7
+ - Updated dependencies
8
+
9
+ ## 2.8.17
10
+
11
+ ### Patch Changes
12
+
13
+ - [`3902a8eba8344`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/3902a8eba8344) -
14
+ Clean up feature gate `platform_editor_return_focus_after_text_styles_2`. Size inline-rendered
15
+ toolbar dropdown menus to their content so Text styles items no longer wrap.
16
+ - Updated dependencies
17
+
3
18
  ## 2.8.16
4
19
 
5
20
  ### Patch Changes
@@ -1,3 +1,4 @@
1
1
  ._1mouv77o{margin-block:var(--ds-space-025,2px)}._18l8n7od [data-section]:first-of-type{border-block-start:unset}
2
2
  ._18m91wug{overflow-y:auto}
3
+ ._1bsb1ris{width:max-content}
3
4
  ._c71lnklw{max-height:20pc}
@@ -21,7 +21,8 @@ function _interopRequireWildcard(e, t) { if ("function" == typeof WeakMap) var r
21
21
  var styles = {
22
22
  sectionMargin: "_1mouv77o",
23
23
  firstSectionSeparator: "_18l8n7od",
24
- scrollContainer: "_c71lnklw _18m91wug"
24
+ scrollContainer: "_c71lnklw _18m91wug",
25
+ renderToParent: "_1bsb1ris"
25
26
  };
26
27
  var ToolbarDropdownMenuContent = function ToolbarDropdownMenuContent(_ref) {
27
28
  var iconBefore = _ref.iconBefore,
@@ -83,7 +84,7 @@ var ToolbarDropdownMenuContent = function ToolbarDropdownMenuContent(_ref) {
83
84
  onOpenChange: handleOpenChange,
84
85
  isOpen: menuContext === null || menuContext === void 0 ? void 0 : menuContext.isOpen,
85
86
  shouldRenderToParent: shouldRenderToParent ? true : undefined,
86
- strategy: shouldRenderToParent && (0, _fg.fg)('platform_editor_return_focus_after_text_styles_2') ? 'absolute' : undefined
87
+ strategy: shouldRenderToParent ? 'absolute' : undefined
87
88
  }, children);
88
89
  };
89
90
  var ToolbarDropdownMenu = exports.ToolbarDropdownMenu = function ToolbarDropdownMenu(_ref2) {
@@ -110,7 +111,7 @@ var ToolbarDropdownMenu = exports.ToolbarDropdownMenu = function ToolbarDropdown
110
111
  tooltipComponent: tooltipComponent,
111
112
  shouldRenderToParent: shouldRenderToParent
112
113
  }, /*#__PURE__*/_react.default.createElement(_compiled.Box, {
113
- xcss: (0, _react2.cx)(hasSectionMargin && styles.sectionMargin, enableMaxHeight && styles.scrollContainer, styles.firstSectionSeparator),
114
+ xcss: (0, _react2.cx)(hasSectionMargin && styles.sectionMargin, enableMaxHeight && styles.scrollContainer, shouldRenderToParent && (0, _fg.fg)('platform_editor_fix_text_styles_width') && styles.renderToParent, styles.firstSectionSeparator),
114
115
  "data-toolbar-component": "menu"
115
116
  }, children));
116
117
  };
@@ -1,3 +1,4 @@
1
1
  ._1mouv77o{margin-block:var(--ds-space-025,2px)}._18l8n7od [data-section]:first-of-type{border-block-start:unset}
2
2
  ._18m91wug{overflow-y:auto}
3
+ ._1bsb1ris{width:max-content}
3
4
  ._c71lnklw{max-height:20pc}
@@ -12,7 +12,8 @@ import { useToolbarDropdownMenu } from './ToolbarDropdownMenuContext';
12
12
  const styles = {
13
13
  sectionMargin: "_1mouv77o",
14
14
  firstSectionSeparator: "_18l8n7od",
15
- scrollContainer: "_c71lnklw _18m91wug"
15
+ scrollContainer: "_c71lnklw _18m91wug",
16
+ renderToParent: "_1bsb1ris"
16
17
  };
17
18
  const ToolbarDropdownMenuContent = ({
18
19
  iconBefore,
@@ -76,7 +77,7 @@ const ToolbarDropdownMenuContent = ({
76
77
  onOpenChange: handleOpenChange,
77
78
  isOpen: menuContext === null || menuContext === void 0 ? void 0 : menuContext.isOpen,
78
79
  shouldRenderToParent: shouldRenderToParent ? true : undefined,
79
- strategy: shouldRenderToParent && fg('platform_editor_return_focus_after_text_styles_2') ? 'absolute' : undefined
80
+ strategy: shouldRenderToParent ? 'absolute' : undefined
80
81
  }, children);
81
82
  };
82
83
  export const ToolbarDropdownMenu = ({
@@ -102,7 +103,7 @@ export const ToolbarDropdownMenu = ({
102
103
  tooltipComponent: tooltipComponent,
103
104
  shouldRenderToParent: shouldRenderToParent
104
105
  }, /*#__PURE__*/React.createElement(Box, {
105
- xcss: cx(hasSectionMargin && styles.sectionMargin, enableMaxHeight && styles.scrollContainer, styles.firstSectionSeparator),
106
+ xcss: cx(hasSectionMargin && styles.sectionMargin, enableMaxHeight && styles.scrollContainer, shouldRenderToParent && fg('platform_editor_fix_text_styles_width') && styles.renderToParent, styles.firstSectionSeparator),
106
107
  "data-toolbar-component": "menu"
107
108
  }, children));
108
109
  };
@@ -1,3 +1,4 @@
1
1
  ._1mouv77o{margin-block:var(--ds-space-025,2px)}._18l8n7od [data-section]:first-of-type{border-block-start:unset}
2
2
  ._18m91wug{overflow-y:auto}
3
+ ._1bsb1ris{width:max-content}
3
4
  ._c71lnklw{max-height:20pc}
@@ -12,7 +12,8 @@ import { useToolbarDropdownMenu } from './ToolbarDropdownMenuContext';
12
12
  var styles = {
13
13
  sectionMargin: "_1mouv77o",
14
14
  firstSectionSeparator: "_18l8n7od",
15
- scrollContainer: "_c71lnklw _18m91wug"
15
+ scrollContainer: "_c71lnklw _18m91wug",
16
+ renderToParent: "_1bsb1ris"
16
17
  };
17
18
  var ToolbarDropdownMenuContent = function ToolbarDropdownMenuContent(_ref) {
18
19
  var iconBefore = _ref.iconBefore,
@@ -74,7 +75,7 @@ var ToolbarDropdownMenuContent = function ToolbarDropdownMenuContent(_ref) {
74
75
  onOpenChange: handleOpenChange,
75
76
  isOpen: menuContext === null || menuContext === void 0 ? void 0 : menuContext.isOpen,
76
77
  shouldRenderToParent: shouldRenderToParent ? true : undefined,
77
- strategy: shouldRenderToParent && fg('platform_editor_return_focus_after_text_styles_2') ? 'absolute' : undefined
78
+ strategy: shouldRenderToParent ? 'absolute' : undefined
78
79
  }, children);
79
80
  };
80
81
  export var ToolbarDropdownMenu = function ToolbarDropdownMenu(_ref2) {
@@ -101,7 +102,7 @@ export var ToolbarDropdownMenu = function ToolbarDropdownMenu(_ref2) {
101
102
  tooltipComponent: tooltipComponent,
102
103
  shouldRenderToParent: shouldRenderToParent
103
104
  }, /*#__PURE__*/React.createElement(Box, {
104
- xcss: cx(hasSectionMargin && styles.sectionMargin, enableMaxHeight && styles.scrollContainer, styles.firstSectionSeparator),
105
+ xcss: cx(hasSectionMargin && styles.sectionMargin, enableMaxHeight && styles.scrollContainer, shouldRenderToParent && fg('platform_editor_fix_text_styles_width') && styles.renderToParent, styles.firstSectionSeparator),
105
106
  "data-toolbar-component": "menu"
106
107
  }, children));
107
108
  };
package/package.json CHANGED
@@ -3,7 +3,7 @@
3
3
  "publishConfig": {
4
4
  "registry": "https://registry.npmjs.org/"
5
5
  },
6
- "version": "2.8.16",
6
+ "version": "2.8.18",
7
7
  "description": "Common UI for Toolbars across the platform",
8
8
  "atlassian": {
9
9
  "website": {
@@ -45,8 +45,8 @@
45
45
  "@atlaskit/popup": "^9.0.0",
46
46
  "@atlaskit/primitives": "^22.5.0",
47
47
  "@atlaskit/react-compiler-gating": "^0.2.0",
48
- "@atlaskit/tmp-editor-statsig": "^221.0.0",
49
- "@atlaskit/tokens": "^20.1.0",
48
+ "@atlaskit/tmp-editor-statsig": "^223.0.0",
49
+ "@atlaskit/tokens": "^20.3.0",
50
50
  "@atlaskit/tooltip": "^24.4.0",
51
51
  "@babel/runtime": "^7.0.0",
52
52
  "@compiled/react": "^1.0.2",
@@ -73,7 +73,7 @@
73
73
  "platform_editor_a11y_color_palette_radiogroup": {
74
74
  "type": "boolean"
75
75
  },
76
- "platform_editor_return_focus_after_text_styles_2": {
76
+ "platform_editor_fix_text_styles_width": {
77
77
  "type": "boolean"
78
78
  }
79
79
  }