@atlaskit/editor-toolbar 0.19.4 → 0.19.5
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 +9 -0
- package/dist/cjs/ui/Toolbar.js +3 -3
- package/dist/cjs/ui/ToolbarKeyboardNavigationProvider.js +2 -0
- package/dist/es2019/ui/Toolbar.js +3 -3
- package/dist/es2019/ui/ToolbarKeyboardNavigationProvider.js +2 -0
- package/dist/esm/ui/Toolbar.js +3 -3
- package/dist/esm/ui/ToolbarKeyboardNavigationProvider.js +2 -0
- package/package.json +3 -3
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,14 @@
|
|
|
1
1
|
# @atlaskit/editor-toolbar
|
|
2
2
|
|
|
3
|
+
## 0.19.5
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- [`aeb74c52331de`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/aeb74c52331de) -
|
|
8
|
+
[EDITOR-4634] remove duplicated toolbar role from toolbar elements behind
|
|
9
|
+
platform_editor_aifc_remove_duplicate_role
|
|
10
|
+
- Updated dependencies
|
|
11
|
+
|
|
3
12
|
## 0.19.4
|
|
4
13
|
|
|
5
14
|
### Patch Changes
|
package/dist/cjs/ui/Toolbar.js
CHANGED
|
@@ -40,7 +40,7 @@ var Toolbar = exports.Toolbar = function Toolbar(_ref) {
|
|
|
40
40
|
var isResponsiveEnabled = (0, _expValEquals.expValEquals)('platform_editor_toolbar_aifc_responsive', 'isEnabled', true);
|
|
41
41
|
var toolbar = /*#__PURE__*/_react.default.createElement(_compiled.Box, {
|
|
42
42
|
xcss: (0, _css.cx)(styles.toolbarBase, styles.toolbar, isResponsiveEnabled && styles.toolbarResponsive, isResponsiveEnabled && styles.hiddenSelectors, (0, _expValEquals.expValEquals)('platform_editor_toolbar_aifc_patch_6', 'isEnabled', true) && styles.toolbarSeparator, (0, _expValEquals.expValEquals)('platform_editor_toolbar_aifc_patch_6', 'isEnabled', true) && styles.hiddenSelectorsPatch),
|
|
43
|
-
role:
|
|
43
|
+
role: (0, _expValEquals.expValEquals)('platform_editor_aifc_remove_duplicate_role', 'isEnabled', true) ? undefined : 'toolbar',
|
|
44
44
|
"aria-label": label,
|
|
45
45
|
testId: testId,
|
|
46
46
|
"data-toolbar-type": (0, _expValEquals.expValEquals)('platform_editor_toolbar_aifc_patch_6', 'isEnabled', true) ? 'inline' : undefined
|
|
@@ -88,14 +88,14 @@ var PrimaryToolbar = exports.PrimaryToolbar = function PrimaryToolbar(_ref2) {
|
|
|
88
88
|
reducedBreakpoints: reducedBreakpoints
|
|
89
89
|
}, /*#__PURE__*/_react.default.createElement(_compiled.Box, {
|
|
90
90
|
xcss: (0, _css.cx)(styles.toolbarBase, styles.primaryToolbar, styles.hiddenSelectors),
|
|
91
|
-
role:
|
|
91
|
+
role: (0, _expValEquals.expValEquals)('platform_editor_aifc_remove_duplicate_role', 'isEnabled', true) ? undefined : 'toolbar',
|
|
92
92
|
"aria-label": label,
|
|
93
93
|
"data-toolbar-type": (0, _expValEquals.expValEquals)('platform_editor_toolbar_aifc_patch_6', 'isEnabled', true) ? 'primary' : undefined
|
|
94
94
|
}, children));
|
|
95
95
|
}
|
|
96
96
|
return /*#__PURE__*/_react.default.createElement(_compiled.Box, {
|
|
97
97
|
xcss: (0, _css.cx)(styles.toolbarBase, styles.primaryToolbar),
|
|
98
|
-
role:
|
|
98
|
+
role: (0, _expValEquals.expValEquals)('platform_editor_aifc_remove_duplicate_role', 'isEnabled', true) ? undefined : 'toolbar',
|
|
99
99
|
"aria-label": label,
|
|
100
100
|
"data-toolbar-type": (0, _expValEquals.expValEquals)('platform_editor_toolbar_aifc_patch_6', 'isEnabled', true) ? 'primary' : undefined
|
|
101
101
|
}, children);
|
|
@@ -8,6 +8,7 @@ exports.ToolbarKeyboardNavigationProvider = void 0;
|
|
|
8
8
|
var _react = _interopRequireWildcard(require("react"));
|
|
9
9
|
var _browserApis = require("@atlaskit/browser-apis");
|
|
10
10
|
var _platformFeatureFlags = require("@atlaskit/platform-feature-flags");
|
|
11
|
+
var _expValEquals = require("@atlaskit/tmp-editor-statsig/exp-val-equals");
|
|
11
12
|
function _interopRequireWildcard(e, t) { if ("function" == typeof WeakMap) var r = new WeakMap(), n = new WeakMap(); return (_interopRequireWildcard = function _interopRequireWildcard(e, t) { if (!t && e && e.__esModule) return e; var o, i, f = { __proto__: null, default: e }; if (null === e || "object" != _typeof(e) && "function" != typeof e) return f; if (o = t ? n : r) { if (o.has(e)) return o.get(e); o.set(e, f); } for (var _t in e) "default" !== _t && {}.hasOwnProperty.call(e, _t) && ((i = (o = Object.defineProperty) && Object.getOwnPropertyDescriptor(e, _t)) && (i.get || i.set) ? o(f, _t, i) : f[_t] = e[_t]); return f; })(e, t); }
|
|
12
13
|
var ToolbarKeyboardNavigationProvider = exports.ToolbarKeyboardNavigationProvider = function ToolbarKeyboardNavigationProvider(_ref) {
|
|
13
14
|
var children = _ref.children,
|
|
@@ -151,6 +152,7 @@ var ToolbarKeyboardNavigationProvider = exports.ToolbarKeyboardNavigationProvide
|
|
|
151
152
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-classname-prop -- ignored via go/DSP-18766
|
|
152
153
|
className: "custom-key-handler-wrapper",
|
|
153
154
|
ref: wrapperRef,
|
|
155
|
+
role: (0, _expValEquals.expValEquals)('platform_editor_aifc_remove_duplicate_role', 'isEnabled', true) ? 'toolbar' : undefined,
|
|
154
156
|
"aria-label": ariaLabel,
|
|
155
157
|
"aria-controls": ariaControls
|
|
156
158
|
}, children);
|
|
@@ -34,7 +34,7 @@ export const Toolbar = ({
|
|
|
34
34
|
const isResponsiveEnabled = expValEquals('platform_editor_toolbar_aifc_responsive', 'isEnabled', true);
|
|
35
35
|
const toolbar = /*#__PURE__*/React.createElement(Box, {
|
|
36
36
|
xcss: cx(styles.toolbarBase, styles.toolbar, isResponsiveEnabled && styles.toolbarResponsive, isResponsiveEnabled && styles.hiddenSelectors, expValEquals('platform_editor_toolbar_aifc_patch_6', 'isEnabled', true) && styles.toolbarSeparator, expValEquals('platform_editor_toolbar_aifc_patch_6', 'isEnabled', true) && styles.hiddenSelectorsPatch),
|
|
37
|
-
role:
|
|
37
|
+
role: expValEquals('platform_editor_aifc_remove_duplicate_role', 'isEnabled', true) ? undefined : 'toolbar',
|
|
38
38
|
"aria-label": label,
|
|
39
39
|
testId: testId,
|
|
40
40
|
"data-toolbar-type": expValEquals('platform_editor_toolbar_aifc_patch_6', 'isEnabled', true) ? 'inline' : undefined
|
|
@@ -86,14 +86,14 @@ export const PrimaryToolbar = ({
|
|
|
86
86
|
reducedBreakpoints: reducedBreakpoints
|
|
87
87
|
}, /*#__PURE__*/React.createElement(Box, {
|
|
88
88
|
xcss: cx(styles.toolbarBase, styles.primaryToolbar, styles.hiddenSelectors),
|
|
89
|
-
role:
|
|
89
|
+
role: expValEquals('platform_editor_aifc_remove_duplicate_role', 'isEnabled', true) ? undefined : 'toolbar',
|
|
90
90
|
"aria-label": label,
|
|
91
91
|
"data-toolbar-type": expValEquals('platform_editor_toolbar_aifc_patch_6', 'isEnabled', true) ? 'primary' : undefined
|
|
92
92
|
}, children));
|
|
93
93
|
}
|
|
94
94
|
return /*#__PURE__*/React.createElement(Box, {
|
|
95
95
|
xcss: cx(styles.toolbarBase, styles.primaryToolbar),
|
|
96
|
-
role:
|
|
96
|
+
role: expValEquals('platform_editor_aifc_remove_duplicate_role', 'isEnabled', true) ? undefined : 'toolbar',
|
|
97
97
|
"aria-label": label,
|
|
98
98
|
"data-toolbar-type": expValEquals('platform_editor_toolbar_aifc_patch_6', 'isEnabled', true) ? 'primary' : undefined
|
|
99
99
|
}, children);
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import React, { useLayoutEffect, useRef } from 'react';
|
|
2
2
|
import { getDocument } from '@atlaskit/browser-apis';
|
|
3
3
|
import { fg } from '@atlaskit/platform-feature-flags';
|
|
4
|
+
import { expValEquals } from '@atlaskit/tmp-editor-statsig/exp-val-equals';
|
|
4
5
|
export const ToolbarKeyboardNavigationProvider = ({
|
|
5
6
|
children,
|
|
6
7
|
childComponentSelector,
|
|
@@ -140,6 +141,7 @@ export const ToolbarKeyboardNavigationProvider = ({
|
|
|
140
141
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-classname-prop -- ignored via go/DSP-18766
|
|
141
142
|
className: "custom-key-handler-wrapper",
|
|
142
143
|
ref: wrapperRef,
|
|
144
|
+
role: expValEquals('platform_editor_aifc_remove_duplicate_role', 'isEnabled', true) ? 'toolbar' : undefined,
|
|
143
145
|
"aria-label": ariaLabel,
|
|
144
146
|
"aria-controls": ariaControls
|
|
145
147
|
}, children);
|
package/dist/esm/ui/Toolbar.js
CHANGED
|
@@ -33,7 +33,7 @@ export var Toolbar = function Toolbar(_ref) {
|
|
|
33
33
|
var isResponsiveEnabled = expValEquals('platform_editor_toolbar_aifc_responsive', 'isEnabled', true);
|
|
34
34
|
var toolbar = /*#__PURE__*/React.createElement(Box, {
|
|
35
35
|
xcss: cx(styles.toolbarBase, styles.toolbar, isResponsiveEnabled && styles.toolbarResponsive, isResponsiveEnabled && styles.hiddenSelectors, expValEquals('platform_editor_toolbar_aifc_patch_6', 'isEnabled', true) && styles.toolbarSeparator, expValEquals('platform_editor_toolbar_aifc_patch_6', 'isEnabled', true) && styles.hiddenSelectorsPatch),
|
|
36
|
-
role:
|
|
36
|
+
role: expValEquals('platform_editor_aifc_remove_duplicate_role', 'isEnabled', true) ? undefined : 'toolbar',
|
|
37
37
|
"aria-label": label,
|
|
38
38
|
testId: testId,
|
|
39
39
|
"data-toolbar-type": expValEquals('platform_editor_toolbar_aifc_patch_6', 'isEnabled', true) ? 'inline' : undefined
|
|
@@ -81,14 +81,14 @@ export var PrimaryToolbar = function PrimaryToolbar(_ref2) {
|
|
|
81
81
|
reducedBreakpoints: reducedBreakpoints
|
|
82
82
|
}, /*#__PURE__*/React.createElement(Box, {
|
|
83
83
|
xcss: cx(styles.toolbarBase, styles.primaryToolbar, styles.hiddenSelectors),
|
|
84
|
-
role:
|
|
84
|
+
role: expValEquals('platform_editor_aifc_remove_duplicate_role', 'isEnabled', true) ? undefined : 'toolbar',
|
|
85
85
|
"aria-label": label,
|
|
86
86
|
"data-toolbar-type": expValEquals('platform_editor_toolbar_aifc_patch_6', 'isEnabled', true) ? 'primary' : undefined
|
|
87
87
|
}, children));
|
|
88
88
|
}
|
|
89
89
|
return /*#__PURE__*/React.createElement(Box, {
|
|
90
90
|
xcss: cx(styles.toolbarBase, styles.primaryToolbar),
|
|
91
|
-
role:
|
|
91
|
+
role: expValEquals('platform_editor_aifc_remove_duplicate_role', 'isEnabled', true) ? undefined : 'toolbar',
|
|
92
92
|
"aria-label": label,
|
|
93
93
|
"data-toolbar-type": expValEquals('platform_editor_toolbar_aifc_patch_6', 'isEnabled', true) ? 'primary' : undefined
|
|
94
94
|
}, children);
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import React, { useLayoutEffect, useRef } from 'react';
|
|
2
2
|
import { getDocument } from '@atlaskit/browser-apis';
|
|
3
3
|
import { fg } from '@atlaskit/platform-feature-flags';
|
|
4
|
+
import { expValEquals } from '@atlaskit/tmp-editor-statsig/exp-val-equals';
|
|
4
5
|
export var ToolbarKeyboardNavigationProvider = function ToolbarKeyboardNavigationProvider(_ref) {
|
|
5
6
|
var children = _ref.children,
|
|
6
7
|
childComponentSelector = _ref.childComponentSelector,
|
|
@@ -143,6 +144,7 @@ export var ToolbarKeyboardNavigationProvider = function ToolbarKeyboardNavigatio
|
|
|
143
144
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-classname-prop -- ignored via go/DSP-18766
|
|
144
145
|
className: "custom-key-handler-wrapper",
|
|
145
146
|
ref: wrapperRef,
|
|
147
|
+
role: expValEquals('platform_editor_aifc_remove_duplicate_role', 'isEnabled', true) ? 'toolbar' : undefined,
|
|
146
148
|
"aria-label": ariaLabel,
|
|
147
149
|
"aria-controls": ariaControls
|
|
148
150
|
}, children);
|
package/package.json
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
"publishConfig": {
|
|
4
4
|
"registry": "https://registry.npmjs.org/"
|
|
5
5
|
},
|
|
6
|
-
"version": "0.19.
|
|
6
|
+
"version": "0.19.5",
|
|
7
7
|
"description": "Common UI for Toolbars across the platform",
|
|
8
8
|
"atlassian": {
|
|
9
9
|
"team": "Editor: Jenga",
|
|
@@ -30,8 +30,8 @@
|
|
|
30
30
|
"@atlaskit/platform-feature-flags": "^1.1.0",
|
|
31
31
|
"@atlaskit/popup": "^4.13.0",
|
|
32
32
|
"@atlaskit/primitives": "^17.1.0",
|
|
33
|
-
"@atlaskit/tmp-editor-statsig": "^16.
|
|
34
|
-
"@atlaskit/tokens": "^10.
|
|
33
|
+
"@atlaskit/tmp-editor-statsig": "^16.28.0",
|
|
34
|
+
"@atlaskit/tokens": "^10.1.0",
|
|
35
35
|
"@atlaskit/tooltip": "^20.14.0",
|
|
36
36
|
"@babel/runtime": "^7.0.0",
|
|
37
37
|
"@compiled/react": "^0.18.6",
|