@atlaskit/navigation-system 2.14.1 → 2.15.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.
- package/CHANGELOG.md +16 -0
- package/dist/cjs/ui/page-layout/side-nav/toggle-button.js +24 -3
- package/dist/cjs/ui/top-nav-items/app-switcher.js +3 -1
- package/dist/cjs/ui/top-nav-items/end-item.js +3 -1
- package/dist/cjs/ui/top-nav-items/help.js +4 -2
- package/dist/cjs/ui/top-nav-items/notifications.js +4 -2
- package/dist/es2019/ui/page-layout/side-nav/toggle-button.js +20 -3
- package/dist/es2019/ui/top-nav-items/app-switcher.js +2 -1
- package/dist/es2019/ui/top-nav-items/end-item.js +2 -1
- package/dist/es2019/ui/top-nav-items/help.js +4 -2
- package/dist/es2019/ui/top-nav-items/notifications.js +4 -2
- package/dist/esm/ui/page-layout/side-nav/toggle-button.js +24 -3
- package/dist/esm/ui/top-nav-items/app-switcher.js +3 -1
- package/dist/esm/ui/top-nav-items/end-item.js +3 -1
- package/dist/esm/ui/top-nav-items/help.js +4 -2
- package/dist/esm/ui/top-nav-items/notifications.js +4 -2
- package/dist/types/ui/page-layout/side-nav/toggle-button.d.ts +6 -1
- package/dist/types/ui/top-nav-items/app-switcher.d.ts +5 -0
- package/dist/types/ui/top-nav-items/end-item.d.ts +5 -0
- package/dist/types/ui/top-nav-items/help.d.ts +5 -0
- package/dist/types/ui/top-nav-items/notifications.d.ts +5 -0
- package/dist/types/ui/top-nav-items/settings.d.ts +5 -0
- package/dist/types-ts4.5/ui/page-layout/side-nav/toggle-button.d.ts +6 -1
- package/dist/types-ts4.5/ui/top-nav-items/app-switcher.d.ts +5 -0
- package/dist/types-ts4.5/ui/top-nav-items/end-item.d.ts +5 -0
- package/dist/types-ts4.5/ui/top-nav-items/help.d.ts +5 -0
- package/dist/types-ts4.5/ui/top-nav-items/notifications.d.ts +5 -0
- package/dist/types-ts4.5/ui/top-nav-items/settings.d.ts +5 -0
- package/package.json +6 -3
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,21 @@
|
|
|
1
1
|
# @atlassian/navigation-system
|
|
2
2
|
|
|
3
|
+
## 2.15.0
|
|
4
|
+
|
|
5
|
+
### Minor Changes
|
|
6
|
+
|
|
7
|
+
- [`71f5e9dd549f3`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/71f5e9dd549f3) -
|
|
8
|
+
Adds a fix for the flyout breaking due to stale element references behind the
|
|
9
|
+
`platform_dst_nav4_side_nav_toggle_ref_fix` feature gate.
|
|
10
|
+
|
|
11
|
+
## 2.14.2
|
|
12
|
+
|
|
13
|
+
### Patch Changes
|
|
14
|
+
|
|
15
|
+
- [`c2a513589de1c`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/c2a513589de1c) -
|
|
16
|
+
Pass isTooltipDisabled as prop when render IconButton
|
|
17
|
+
- Updated dependencies
|
|
18
|
+
|
|
3
19
|
## 2.14.1
|
|
4
20
|
|
|
5
21
|
### Patch Changes
|
|
@@ -50,6 +50,8 @@ var SideNavToggleButton = exports.SideNavToggleButton = function SideNavToggleBu
|
|
|
50
50
|
collapseLabel = _ref.collapseLabel,
|
|
51
51
|
testId = _ref.testId,
|
|
52
52
|
interactionName = _ref.interactionName,
|
|
53
|
+
_ref$UNSAFE_isTooltip = _ref.UNSAFE_isTooltipDisabled,
|
|
54
|
+
UNSAFE_isTooltipDisabled = _ref$UNSAFE_isTooltip === void 0 ? false : _ref$UNSAFE_isTooltip,
|
|
53
55
|
onClick = _ref.onClick,
|
|
54
56
|
shortcut = _ref.shortcut;
|
|
55
57
|
var _useSideNavVisibility = (0, _useSideNavVisibility2.useSideNavVisibility)({
|
|
@@ -66,8 +68,27 @@ var SideNavToggleButton = exports.SideNavToggleButton = function SideNavToggleBu
|
|
|
66
68
|
setIsSideNavExpanded = _useState2[1];
|
|
67
69
|
var ref = (0, _react.useContext)(_toggleButtonContext.SideNavToggleButtonAttachRef);
|
|
68
70
|
var elementRef = (0, _react.useRef)(null);
|
|
71
|
+
|
|
72
|
+
/**
|
|
73
|
+
* Attempts to address HOT-121458 by ensuring that the toggle button element
|
|
74
|
+
* in context is always up to date.
|
|
75
|
+
*
|
|
76
|
+
* My theory is that something to do with SSR, hydration and suspense was causing the
|
|
77
|
+
* underlying HTML element to change but without causing the toggle button to remount.
|
|
78
|
+
*
|
|
79
|
+
* This meant the effect calling `ref()` did not re-run, and the value in context became stale.
|
|
80
|
+
*/
|
|
81
|
+
var _useState3 = (0, _react.useState)(null),
|
|
82
|
+
_useState4 = (0, _slicedToArray2.default)(_useState3, 2),
|
|
83
|
+
element = _useState4[0],
|
|
84
|
+
setElement = _useState4[1];
|
|
85
|
+
(0, _react.useEffect)(function () {
|
|
86
|
+
if ((0, _platformFeatureFlags.fg)('platform_dst_nav4_side_nav_toggle_ref_fix')) {
|
|
87
|
+
ref(element);
|
|
88
|
+
}
|
|
89
|
+
}, [element, ref]);
|
|
69
90
|
(0, _react.useEffect)(function () {
|
|
70
|
-
if ((0, _platformFeatureFlags.fg)('
|
|
91
|
+
if (!(0, _platformFeatureFlags.fg)('platform_dst_nav4_side_nav_toggle_ref_fix')) {
|
|
71
92
|
ref(elementRef.current);
|
|
72
93
|
}
|
|
73
94
|
}, [elementRef, ref]);
|
|
@@ -129,9 +150,9 @@ var SideNavToggleButton = exports.SideNavToggleButton = function SideNavToggleBu
|
|
|
129
150
|
icon: icon,
|
|
130
151
|
onClick: handleClick,
|
|
131
152
|
testId: testId,
|
|
132
|
-
isTooltipDisabled:
|
|
153
|
+
isTooltipDisabled: UNSAFE_isTooltipDisabled,
|
|
133
154
|
interactionName: interactionName,
|
|
134
|
-
ref: (0, _platformFeatureFlags.fg)('
|
|
155
|
+
ref: (0, _platformFeatureFlags.fg)('platform_dst_nav4_side_nav_toggle_ref_fix') ? setElement : elementRef,
|
|
135
156
|
tooltip: tooltipProps
|
|
136
157
|
});
|
|
137
158
|
var isInsideSlot = (0, _react.useContext)(_toggleButtonContext.SideNavToggleButtonSlotContext);
|
|
@@ -27,6 +27,8 @@ var AppSwitcher = exports.AppSwitcher = /*#__PURE__*/(0, _react.forwardRef)(func
|
|
|
27
27
|
onMouseEnter = _ref.onMouseEnter,
|
|
28
28
|
interactionName = _ref.interactionName,
|
|
29
29
|
isSelected = _ref.isSelected,
|
|
30
|
+
_ref$UNSAFE_isTooltip = _ref.UNSAFE_isTooltipDisabled,
|
|
31
|
+
UNSAFE_isTooltipDisabled = _ref$UNSAFE_isTooltip === void 0 ? false : _ref$UNSAFE_isTooltip,
|
|
30
32
|
ariaControls = _ref['aria-controls'],
|
|
31
33
|
ariaExpanded = _ref['aria-expanded'],
|
|
32
34
|
ariaHasPopup = _ref['aria-haspopup'];
|
|
@@ -41,7 +43,7 @@ var AppSwitcher = exports.AppSwitcher = /*#__PURE__*/(0, _react.forwardRef)(func
|
|
|
41
43
|
onClick: onClick,
|
|
42
44
|
onMouseEnter: onMouseEnter,
|
|
43
45
|
interactionName: interactionName,
|
|
44
|
-
isTooltipDisabled:
|
|
46
|
+
isTooltipDisabled: UNSAFE_isTooltipDisabled,
|
|
45
47
|
tooltip: toggleButtonTooltipOptions,
|
|
46
48
|
isSelected: isSelected
|
|
47
49
|
});
|
|
@@ -24,6 +24,8 @@ var EndItem = exports.EndItem = /*#__PURE__*/(0, _react.forwardRef)(function (_r
|
|
|
24
24
|
isSelected = _ref.isSelected,
|
|
25
25
|
testId = _ref.testId,
|
|
26
26
|
interactionName = _ref.interactionName,
|
|
27
|
+
_ref$UNSAFE_isTooltip = _ref.UNSAFE_isTooltipDisabled,
|
|
28
|
+
UNSAFE_isTooltipDisabled = _ref$UNSAFE_isTooltip === void 0 ? false : _ref$UNSAFE_isTooltip,
|
|
27
29
|
ariaControls = _ref['aria-controls'],
|
|
28
30
|
ariaExpanded = _ref['aria-expanded'],
|
|
29
31
|
ariaHasPopup = _ref['aria-haspopup'],
|
|
@@ -38,7 +40,7 @@ var EndItem = exports.EndItem = /*#__PURE__*/(0, _react.forwardRef)(function (_r
|
|
|
38
40
|
onMouseEnter: onMouseEnter,
|
|
39
41
|
appearance: "subtle",
|
|
40
42
|
isSelected: isSelected,
|
|
41
|
-
isTooltipDisabled:
|
|
43
|
+
isTooltipDisabled: UNSAFE_isTooltipDisabled,
|
|
42
44
|
testId: testId,
|
|
43
45
|
interactionName: interactionName,
|
|
44
46
|
"aria-controls": ariaControls,
|
|
@@ -30,7 +30,8 @@ var Help = exports.Help = /*#__PURE__*/(0, _react.forwardRef)(function Help(_ref
|
|
|
30
30
|
testId = _ref.testId,
|
|
31
31
|
interactionName = _ref.interactionName,
|
|
32
32
|
isListItem = _ref.isListItem,
|
|
33
|
-
badge = _ref.badge
|
|
33
|
+
badge = _ref.badge,
|
|
34
|
+
UNSAFE_isTooltipDisabled = _ref.UNSAFE_isTooltipDisabled;
|
|
34
35
|
var sharedProps = {
|
|
35
36
|
icon: _questionCircle.default,
|
|
36
37
|
label: label,
|
|
@@ -39,7 +40,8 @@ var Help = exports.Help = /*#__PURE__*/(0, _react.forwardRef)(function Help(_ref
|
|
|
39
40
|
isSelected: isSelected,
|
|
40
41
|
testId: testId,
|
|
41
42
|
interactionName: interactionName,
|
|
42
|
-
ref: ref
|
|
43
|
+
ref: ref,
|
|
44
|
+
UNSAFE_isTooltipDisabled: UNSAFE_isTooltipDisabled
|
|
43
45
|
};
|
|
44
46
|
if (!badge) {
|
|
45
47
|
return /*#__PURE__*/_react.default.createElement(_endItem.EndItem, (0, _extends2.default)({}, sharedProps, {
|
|
@@ -28,7 +28,8 @@ var Notifications = exports.Notifications = /*#__PURE__*/(0, _react.forwardRef)(
|
|
|
28
28
|
ariaExpanded = _ref['aria-expanded'],
|
|
29
29
|
ariaHasPopup = _ref['aria-haspopup'],
|
|
30
30
|
isListItem = _ref.isListItem,
|
|
31
|
-
badge = _ref.badge
|
|
31
|
+
badge = _ref.badge,
|
|
32
|
+
UNSAFE_isTooltipDisabled = _ref.UNSAFE_isTooltipDisabled;
|
|
32
33
|
return /*#__PURE__*/_react.default.createElement(_badgeContainer.BadgeContainer, {
|
|
33
34
|
id: NOTIFICATIONS_BADGE_ID,
|
|
34
35
|
badge: badge
|
|
@@ -50,6 +51,7 @@ var Notifications = exports.Notifications = /*#__PURE__*/(0, _react.forwardRef)(
|
|
|
50
51
|
// We explicitly set the EndItem to not be a list item,
|
|
51
52
|
// because the BadgeContainer already has a list item role (if `isListItem` is true)
|
|
52
53
|
,
|
|
53
|
-
isListItem: false
|
|
54
|
+
isListItem: false,
|
|
55
|
+
UNSAFE_isTooltipDisabled: UNSAFE_isTooltipDisabled
|
|
54
56
|
}));
|
|
55
57
|
});
|
|
@@ -36,6 +36,7 @@ export const SideNavToggleButton = ({
|
|
|
36
36
|
collapseLabel,
|
|
37
37
|
testId,
|
|
38
38
|
interactionName,
|
|
39
|
+
UNSAFE_isTooltipDisabled = false,
|
|
39
40
|
onClick,
|
|
40
41
|
shortcut
|
|
41
42
|
}) => {
|
|
@@ -51,8 +52,24 @@ export const SideNavToggleButton = ({
|
|
|
51
52
|
const [isSideNavExpanded, setIsSideNavExpanded] = useState(fg('platform_dst_nav4_full_height_sidebar_api_changes') ? isSideNavExpandedOnDesktop : !defaultCollapsed);
|
|
52
53
|
const ref = useContext(SideNavToggleButtonAttachRef);
|
|
53
54
|
const elementRef = useRef(null);
|
|
55
|
+
|
|
56
|
+
/**
|
|
57
|
+
* Attempts to address HOT-121458 by ensuring that the toggle button element
|
|
58
|
+
* in context is always up to date.
|
|
59
|
+
*
|
|
60
|
+
* My theory is that something to do with SSR, hydration and suspense was causing the
|
|
61
|
+
* underlying HTML element to change but without causing the toggle button to remount.
|
|
62
|
+
*
|
|
63
|
+
* This meant the effect calling `ref()` did not re-run, and the value in context became stale.
|
|
64
|
+
*/
|
|
65
|
+
const [element, setElement] = useState(null);
|
|
66
|
+
useEffect(() => {
|
|
67
|
+
if (fg('platform_dst_nav4_side_nav_toggle_ref_fix')) {
|
|
68
|
+
ref(element);
|
|
69
|
+
}
|
|
70
|
+
}, [element, ref]);
|
|
54
71
|
useEffect(() => {
|
|
55
|
-
if (fg('
|
|
72
|
+
if (!fg('platform_dst_nav4_side_nav_toggle_ref_fix')) {
|
|
56
73
|
ref(elementRef.current);
|
|
57
74
|
}
|
|
58
75
|
}, [elementRef, ref]);
|
|
@@ -114,9 +131,9 @@ export const SideNavToggleButton = ({
|
|
|
114
131
|
icon: icon,
|
|
115
132
|
onClick: handleClick,
|
|
116
133
|
testId: testId,
|
|
117
|
-
isTooltipDisabled:
|
|
134
|
+
isTooltipDisabled: UNSAFE_isTooltipDisabled,
|
|
118
135
|
interactionName: interactionName,
|
|
119
|
-
ref: fg('
|
|
136
|
+
ref: fg('platform_dst_nav4_side_nav_toggle_ref_fix') ? setElement : elementRef,
|
|
120
137
|
tooltip: tooltipProps
|
|
121
138
|
});
|
|
122
139
|
const isInsideSlot = useContext(SideNavToggleButtonSlotContext);
|
|
@@ -18,6 +18,7 @@ export const AppSwitcher = /*#__PURE__*/forwardRef(({
|
|
|
18
18
|
onMouseEnter,
|
|
19
19
|
interactionName,
|
|
20
20
|
isSelected,
|
|
21
|
+
UNSAFE_isTooltipDisabled = false,
|
|
21
22
|
'aria-controls': ariaControls,
|
|
22
23
|
'aria-expanded': ariaExpanded,
|
|
23
24
|
'aria-haspopup': ariaHasPopup
|
|
@@ -32,7 +33,7 @@ export const AppSwitcher = /*#__PURE__*/forwardRef(({
|
|
|
32
33
|
onClick: onClick,
|
|
33
34
|
onMouseEnter: onMouseEnter,
|
|
34
35
|
interactionName: interactionName,
|
|
35
|
-
isTooltipDisabled:
|
|
36
|
+
isTooltipDisabled: UNSAFE_isTooltipDisabled,
|
|
36
37
|
tooltip: toggleButtonTooltipOptions,
|
|
37
38
|
isSelected: isSelected
|
|
38
39
|
}));
|
|
@@ -16,6 +16,7 @@ export const EndItem = /*#__PURE__*/forwardRef(({
|
|
|
16
16
|
isSelected,
|
|
17
17
|
testId,
|
|
18
18
|
interactionName,
|
|
19
|
+
UNSAFE_isTooltipDisabled = false,
|
|
19
20
|
'aria-controls': ariaControls,
|
|
20
21
|
'aria-expanded': ariaExpanded,
|
|
21
22
|
'aria-haspopup': ariaHasPopup,
|
|
@@ -30,7 +31,7 @@ export const EndItem = /*#__PURE__*/forwardRef(({
|
|
|
30
31
|
onMouseEnter: onMouseEnter,
|
|
31
32
|
appearance: "subtle",
|
|
32
33
|
isSelected: isSelected,
|
|
33
|
-
isTooltipDisabled:
|
|
34
|
+
isTooltipDisabled: UNSAFE_isTooltipDisabled,
|
|
34
35
|
testId: testId,
|
|
35
36
|
interactionName: interactionName,
|
|
36
37
|
"aria-controls": ariaControls,
|
|
@@ -20,7 +20,8 @@ export const Help = /*#__PURE__*/forwardRef(function Help({
|
|
|
20
20
|
testId,
|
|
21
21
|
interactionName,
|
|
22
22
|
isListItem,
|
|
23
|
-
badge
|
|
23
|
+
badge,
|
|
24
|
+
UNSAFE_isTooltipDisabled
|
|
24
25
|
}, ref) {
|
|
25
26
|
const sharedProps = {
|
|
26
27
|
icon: HelpIcon,
|
|
@@ -30,7 +31,8 @@ export const Help = /*#__PURE__*/forwardRef(function Help({
|
|
|
30
31
|
isSelected,
|
|
31
32
|
testId,
|
|
32
33
|
interactionName,
|
|
33
|
-
ref
|
|
34
|
+
ref,
|
|
35
|
+
UNSAFE_isTooltipDisabled
|
|
34
36
|
};
|
|
35
37
|
if (!badge) {
|
|
36
38
|
return /*#__PURE__*/React.createElement(EndItem, _extends({}, sharedProps, {
|
|
@@ -19,7 +19,8 @@ export const Notifications = /*#__PURE__*/forwardRef(function Notifications({
|
|
|
19
19
|
'aria-expanded': ariaExpanded,
|
|
20
20
|
'aria-haspopup': ariaHasPopup,
|
|
21
21
|
isListItem,
|
|
22
|
-
badge
|
|
22
|
+
badge,
|
|
23
|
+
UNSAFE_isTooltipDisabled
|
|
23
24
|
}, ref) {
|
|
24
25
|
return /*#__PURE__*/React.createElement(BadgeContainer, {
|
|
25
26
|
id: NOTIFICATIONS_BADGE_ID,
|
|
@@ -42,6 +43,7 @@ export const Notifications = /*#__PURE__*/forwardRef(function Notifications({
|
|
|
42
43
|
// We explicitly set the EndItem to not be a list item,
|
|
43
44
|
// because the BadgeContainer already has a list item role (if `isListItem` is true)
|
|
44
45
|
,
|
|
45
|
-
isListItem: false
|
|
46
|
+
isListItem: false,
|
|
47
|
+
UNSAFE_isTooltipDisabled: UNSAFE_isTooltipDisabled
|
|
46
48
|
}));
|
|
47
49
|
});
|
|
@@ -41,6 +41,8 @@ export var SideNavToggleButton = function SideNavToggleButton(_ref) {
|
|
|
41
41
|
collapseLabel = _ref.collapseLabel,
|
|
42
42
|
testId = _ref.testId,
|
|
43
43
|
interactionName = _ref.interactionName,
|
|
44
|
+
_ref$UNSAFE_isTooltip = _ref.UNSAFE_isTooltipDisabled,
|
|
45
|
+
UNSAFE_isTooltipDisabled = _ref$UNSAFE_isTooltip === void 0 ? false : _ref$UNSAFE_isTooltip,
|
|
44
46
|
onClick = _ref.onClick,
|
|
45
47
|
shortcut = _ref.shortcut;
|
|
46
48
|
var _useSideNavVisibility = useSideNavVisibility({
|
|
@@ -57,8 +59,27 @@ export var SideNavToggleButton = function SideNavToggleButton(_ref) {
|
|
|
57
59
|
setIsSideNavExpanded = _useState2[1];
|
|
58
60
|
var ref = useContext(SideNavToggleButtonAttachRef);
|
|
59
61
|
var elementRef = useRef(null);
|
|
62
|
+
|
|
63
|
+
/**
|
|
64
|
+
* Attempts to address HOT-121458 by ensuring that the toggle button element
|
|
65
|
+
* in context is always up to date.
|
|
66
|
+
*
|
|
67
|
+
* My theory is that something to do with SSR, hydration and suspense was causing the
|
|
68
|
+
* underlying HTML element to change but without causing the toggle button to remount.
|
|
69
|
+
*
|
|
70
|
+
* This meant the effect calling `ref()` did not re-run, and the value in context became stale.
|
|
71
|
+
*/
|
|
72
|
+
var _useState3 = useState(null),
|
|
73
|
+
_useState4 = _slicedToArray(_useState3, 2),
|
|
74
|
+
element = _useState4[0],
|
|
75
|
+
setElement = _useState4[1];
|
|
76
|
+
useEffect(function () {
|
|
77
|
+
if (fg('platform_dst_nav4_side_nav_toggle_ref_fix')) {
|
|
78
|
+
ref(element);
|
|
79
|
+
}
|
|
80
|
+
}, [element, ref]);
|
|
60
81
|
useEffect(function () {
|
|
61
|
-
if (fg('
|
|
82
|
+
if (!fg('platform_dst_nav4_side_nav_toggle_ref_fix')) {
|
|
62
83
|
ref(elementRef.current);
|
|
63
84
|
}
|
|
64
85
|
}, [elementRef, ref]);
|
|
@@ -120,9 +141,9 @@ export var SideNavToggleButton = function SideNavToggleButton(_ref) {
|
|
|
120
141
|
icon: icon,
|
|
121
142
|
onClick: handleClick,
|
|
122
143
|
testId: testId,
|
|
123
|
-
isTooltipDisabled:
|
|
144
|
+
isTooltipDisabled: UNSAFE_isTooltipDisabled,
|
|
124
145
|
interactionName: interactionName,
|
|
125
|
-
ref: fg('
|
|
146
|
+
ref: fg('platform_dst_nav4_side_nav_toggle_ref_fix') ? setElement : elementRef,
|
|
126
147
|
tooltip: tooltipProps
|
|
127
148
|
});
|
|
128
149
|
var isInsideSlot = useContext(SideNavToggleButtonSlotContext);
|
|
@@ -18,6 +18,8 @@ export var AppSwitcher = /*#__PURE__*/forwardRef(function (_ref, ref) {
|
|
|
18
18
|
onMouseEnter = _ref.onMouseEnter,
|
|
19
19
|
interactionName = _ref.interactionName,
|
|
20
20
|
isSelected = _ref.isSelected,
|
|
21
|
+
_ref$UNSAFE_isTooltip = _ref.UNSAFE_isTooltipDisabled,
|
|
22
|
+
UNSAFE_isTooltipDisabled = _ref$UNSAFE_isTooltip === void 0 ? false : _ref$UNSAFE_isTooltip,
|
|
21
23
|
ariaControls = _ref['aria-controls'],
|
|
22
24
|
ariaExpanded = _ref['aria-expanded'],
|
|
23
25
|
ariaHasPopup = _ref['aria-haspopup'];
|
|
@@ -32,7 +34,7 @@ export var AppSwitcher = /*#__PURE__*/forwardRef(function (_ref, ref) {
|
|
|
32
34
|
onClick: onClick,
|
|
33
35
|
onMouseEnter: onMouseEnter,
|
|
34
36
|
interactionName: interactionName,
|
|
35
|
-
isTooltipDisabled:
|
|
37
|
+
isTooltipDisabled: UNSAFE_isTooltipDisabled,
|
|
36
38
|
tooltip: toggleButtonTooltipOptions,
|
|
37
39
|
isSelected: isSelected
|
|
38
40
|
});
|
|
@@ -16,6 +16,8 @@ export var EndItem = /*#__PURE__*/forwardRef(function (_ref, forwardedRef) {
|
|
|
16
16
|
isSelected = _ref.isSelected,
|
|
17
17
|
testId = _ref.testId,
|
|
18
18
|
interactionName = _ref.interactionName,
|
|
19
|
+
_ref$UNSAFE_isTooltip = _ref.UNSAFE_isTooltipDisabled,
|
|
20
|
+
UNSAFE_isTooltipDisabled = _ref$UNSAFE_isTooltip === void 0 ? false : _ref$UNSAFE_isTooltip,
|
|
19
21
|
ariaControls = _ref['aria-controls'],
|
|
20
22
|
ariaExpanded = _ref['aria-expanded'],
|
|
21
23
|
ariaHasPopup = _ref['aria-haspopup'],
|
|
@@ -30,7 +32,7 @@ export var EndItem = /*#__PURE__*/forwardRef(function (_ref, forwardedRef) {
|
|
|
30
32
|
onMouseEnter: onMouseEnter,
|
|
31
33
|
appearance: "subtle",
|
|
32
34
|
isSelected: isSelected,
|
|
33
|
-
isTooltipDisabled:
|
|
35
|
+
isTooltipDisabled: UNSAFE_isTooltipDisabled,
|
|
34
36
|
testId: testId,
|
|
35
37
|
interactionName: interactionName,
|
|
36
38
|
"aria-controls": ariaControls,
|
|
@@ -20,7 +20,8 @@ export var Help = /*#__PURE__*/forwardRef(function Help(_ref, ref) {
|
|
|
20
20
|
testId = _ref.testId,
|
|
21
21
|
interactionName = _ref.interactionName,
|
|
22
22
|
isListItem = _ref.isListItem,
|
|
23
|
-
badge = _ref.badge
|
|
23
|
+
badge = _ref.badge,
|
|
24
|
+
UNSAFE_isTooltipDisabled = _ref.UNSAFE_isTooltipDisabled;
|
|
24
25
|
var sharedProps = {
|
|
25
26
|
icon: HelpIcon,
|
|
26
27
|
label: label,
|
|
@@ -29,7 +30,8 @@ export var Help = /*#__PURE__*/forwardRef(function Help(_ref, ref) {
|
|
|
29
30
|
isSelected: isSelected,
|
|
30
31
|
testId: testId,
|
|
31
32
|
interactionName: interactionName,
|
|
32
|
-
ref: ref
|
|
33
|
+
ref: ref,
|
|
34
|
+
UNSAFE_isTooltipDisabled: UNSAFE_isTooltipDisabled
|
|
33
35
|
};
|
|
34
36
|
if (!badge) {
|
|
35
37
|
return /*#__PURE__*/React.createElement(EndItem, _extends({}, sharedProps, {
|
|
@@ -19,7 +19,8 @@ export var Notifications = /*#__PURE__*/forwardRef(function Notifications(_ref,
|
|
|
19
19
|
ariaExpanded = _ref['aria-expanded'],
|
|
20
20
|
ariaHasPopup = _ref['aria-haspopup'],
|
|
21
21
|
isListItem = _ref.isListItem,
|
|
22
|
-
badge = _ref.badge
|
|
22
|
+
badge = _ref.badge,
|
|
23
|
+
UNSAFE_isTooltipDisabled = _ref.UNSAFE_isTooltipDisabled;
|
|
23
24
|
return /*#__PURE__*/React.createElement(BadgeContainer, {
|
|
24
25
|
id: NOTIFICATIONS_BADGE_ID,
|
|
25
26
|
badge: badge
|
|
@@ -41,6 +42,7 @@ export var Notifications = /*#__PURE__*/forwardRef(function Notifications(_ref,
|
|
|
41
42
|
// We explicitly set the EndItem to not be a list item,
|
|
42
43
|
// because the BadgeContainer already has a list item role (if `isListItem` is true)
|
|
43
44
|
,
|
|
44
|
-
isListItem: false
|
|
45
|
+
isListItem: false,
|
|
46
|
+
UNSAFE_isTooltipDisabled: UNSAFE_isTooltipDisabled
|
|
45
47
|
}));
|
|
46
48
|
});
|
|
@@ -12,7 +12,7 @@ export type SideNavVisibilityChangeAnalyticsAttributes = {
|
|
|
12
12
|
*
|
|
13
13
|
* Button for toggling the side nav. It should be used in the top bar.
|
|
14
14
|
*/
|
|
15
|
-
export declare const SideNavToggleButton: ({ defaultCollapsed, expandLabel, collapseLabel, testId, interactionName, onClick, shortcut, }: {
|
|
15
|
+
export declare const SideNavToggleButton: ({ defaultCollapsed, expandLabel, collapseLabel, testId, interactionName, UNSAFE_isTooltipDisabled, onClick, shortcut, }: {
|
|
16
16
|
/**
|
|
17
17
|
* @deprecated
|
|
18
18
|
*
|
|
@@ -45,6 +45,11 @@ export declare const SideNavToggleButton: ({ defaultCollapsed, expandLabel, coll
|
|
|
45
45
|
* An optional name used to identify events for [React UFO (Unified Frontend Observability) press interactions](https://developer.atlassian.com/platform/ufo/react-ufo/react-ufo/getting-started/#quick-start--press-interactions). For more information, see [React UFO integration into Design System components](https://go.atlassian.com/react-ufo-dst-integration).
|
|
46
46
|
*/
|
|
47
47
|
interactionName?: string;
|
|
48
|
+
/**
|
|
49
|
+
* Experimental, do not use. May be removed at any time.
|
|
50
|
+
* Whether the tooltip should be disabled.
|
|
51
|
+
*/
|
|
52
|
+
UNSAFE_isTooltipDisabled?: boolean;
|
|
48
53
|
/**
|
|
49
54
|
* The callback function that is called when the toggle button is clicked.
|
|
50
55
|
*/
|
|
@@ -22,6 +22,11 @@ interface AppSwitcherProps extends Partial<Omit<TriggerProps, 'ref' | 'data-ds--
|
|
|
22
22
|
* Indicates that the button is selected.
|
|
23
23
|
*/
|
|
24
24
|
isSelected?: boolean;
|
|
25
|
+
/**
|
|
26
|
+
* Experimental, do not use. May be removed at any time.
|
|
27
|
+
* Whether the tooltip should be disabled.
|
|
28
|
+
*/
|
|
29
|
+
UNSAFE_isTooltipDisabled?: boolean;
|
|
25
30
|
}
|
|
26
31
|
/**
|
|
27
32
|
* __App switcher__
|
|
@@ -35,6 +35,11 @@ export interface EndItemProps extends Partial<Pick<TriggerProps, 'aria-controls'
|
|
|
35
35
|
* An optional name used to identify events for [React UFO (Unified Frontend Observability) press interactions](https://developer.atlassian.com/platform/ufo/react-ufo/react-ufo/getting-started/#quick-start--press-interactions). For more information, see [React UFO integration into Design System components](https://go.atlassian.com/react-ufo-dst-integration).
|
|
36
36
|
*/
|
|
37
37
|
interactionName?: string;
|
|
38
|
+
/**
|
|
39
|
+
* Experimental, do not use. May be removed at any time.
|
|
40
|
+
* Whether the tooltip should be disabled.
|
|
41
|
+
*/
|
|
42
|
+
UNSAFE_isTooltipDisabled?: boolean;
|
|
38
43
|
/**
|
|
39
44
|
* Can be used to disable the default `listitem` role.
|
|
40
45
|
*
|
|
@@ -9,6 +9,11 @@ interface HelpProps extends Omit<EndItemProps, 'icon' | 'aria-controls' | 'aria-
|
|
|
9
9
|
* You are recommended to use the Badge component from `@atlaskit/badge`.
|
|
10
10
|
*/
|
|
11
11
|
badge?: ComponentType;
|
|
12
|
+
/**
|
|
13
|
+
* Experimental, do not use. May be removed at any time.
|
|
14
|
+
* Whether the tooltip should be disabled.
|
|
15
|
+
*/
|
|
16
|
+
UNSAFE_isTooltipDisabled?: boolean;
|
|
12
17
|
}
|
|
13
18
|
/**
|
|
14
19
|
* __Help__
|
|
@@ -6,6 +6,11 @@ interface NotificationsProps extends Omit<EndItemProps, 'icon'> {
|
|
|
6
6
|
* You are recommended to use the Badge component from `@atlaskit/badge`.
|
|
7
7
|
*/
|
|
8
8
|
badge: ComponentType;
|
|
9
|
+
/**
|
|
10
|
+
* Experimental, do not use. May be removed at any time.
|
|
11
|
+
* Whether the tooltip should be disabled.
|
|
12
|
+
*/
|
|
13
|
+
UNSAFE_isTooltipDisabled?: boolean;
|
|
9
14
|
}
|
|
10
15
|
/**
|
|
11
16
|
* __Notifications__
|
|
@@ -1,6 +1,11 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import { type EndItemProps } from './end-item';
|
|
3
3
|
interface SettingsProps extends Omit<EndItemProps, 'icon'> {
|
|
4
|
+
/**
|
|
5
|
+
* Experimental, do not use. May be removed at any time.
|
|
6
|
+
* Whether the tooltip should be disabled.
|
|
7
|
+
*/
|
|
8
|
+
UNSAFE_isTooltipDisabled?: boolean;
|
|
4
9
|
}
|
|
5
10
|
/**
|
|
6
11
|
* __Settings__
|
|
@@ -12,7 +12,7 @@ export type SideNavVisibilityChangeAnalyticsAttributes = {
|
|
|
12
12
|
*
|
|
13
13
|
* Button for toggling the side nav. It should be used in the top bar.
|
|
14
14
|
*/
|
|
15
|
-
export declare const SideNavToggleButton: ({ defaultCollapsed, expandLabel, collapseLabel, testId, interactionName, onClick, shortcut, }: {
|
|
15
|
+
export declare const SideNavToggleButton: ({ defaultCollapsed, expandLabel, collapseLabel, testId, interactionName, UNSAFE_isTooltipDisabled, onClick, shortcut, }: {
|
|
16
16
|
/**
|
|
17
17
|
* @deprecated
|
|
18
18
|
*
|
|
@@ -45,6 +45,11 @@ export declare const SideNavToggleButton: ({ defaultCollapsed, expandLabel, coll
|
|
|
45
45
|
* An optional name used to identify events for [React UFO (Unified Frontend Observability) press interactions](https://developer.atlassian.com/platform/ufo/react-ufo/react-ufo/getting-started/#quick-start--press-interactions). For more information, see [React UFO integration into Design System components](https://go.atlassian.com/react-ufo-dst-integration).
|
|
46
46
|
*/
|
|
47
47
|
interactionName?: string;
|
|
48
|
+
/**
|
|
49
|
+
* Experimental, do not use. May be removed at any time.
|
|
50
|
+
* Whether the tooltip should be disabled.
|
|
51
|
+
*/
|
|
52
|
+
UNSAFE_isTooltipDisabled?: boolean;
|
|
48
53
|
/**
|
|
49
54
|
* The callback function that is called when the toggle button is clicked.
|
|
50
55
|
*/
|
|
@@ -22,6 +22,11 @@ interface AppSwitcherProps extends Partial<Omit<TriggerProps, 'ref' | 'data-ds--
|
|
|
22
22
|
* Indicates that the button is selected.
|
|
23
23
|
*/
|
|
24
24
|
isSelected?: boolean;
|
|
25
|
+
/**
|
|
26
|
+
* Experimental, do not use. May be removed at any time.
|
|
27
|
+
* Whether the tooltip should be disabled.
|
|
28
|
+
*/
|
|
29
|
+
UNSAFE_isTooltipDisabled?: boolean;
|
|
25
30
|
}
|
|
26
31
|
/**
|
|
27
32
|
* __App switcher__
|
|
@@ -35,6 +35,11 @@ export interface EndItemProps extends Partial<Pick<TriggerProps, 'aria-controls'
|
|
|
35
35
|
* An optional name used to identify events for [React UFO (Unified Frontend Observability) press interactions](https://developer.atlassian.com/platform/ufo/react-ufo/react-ufo/getting-started/#quick-start--press-interactions). For more information, see [React UFO integration into Design System components](https://go.atlassian.com/react-ufo-dst-integration).
|
|
36
36
|
*/
|
|
37
37
|
interactionName?: string;
|
|
38
|
+
/**
|
|
39
|
+
* Experimental, do not use. May be removed at any time.
|
|
40
|
+
* Whether the tooltip should be disabled.
|
|
41
|
+
*/
|
|
42
|
+
UNSAFE_isTooltipDisabled?: boolean;
|
|
38
43
|
/**
|
|
39
44
|
* Can be used to disable the default `listitem` role.
|
|
40
45
|
*
|
|
@@ -9,6 +9,11 @@ interface HelpProps extends Omit<EndItemProps, 'icon' | 'aria-controls' | 'aria-
|
|
|
9
9
|
* You are recommended to use the Badge component from `@atlaskit/badge`.
|
|
10
10
|
*/
|
|
11
11
|
badge?: ComponentType;
|
|
12
|
+
/**
|
|
13
|
+
* Experimental, do not use. May be removed at any time.
|
|
14
|
+
* Whether the tooltip should be disabled.
|
|
15
|
+
*/
|
|
16
|
+
UNSAFE_isTooltipDisabled?: boolean;
|
|
12
17
|
}
|
|
13
18
|
/**
|
|
14
19
|
* __Help__
|
|
@@ -6,6 +6,11 @@ interface NotificationsProps extends Omit<EndItemProps, 'icon'> {
|
|
|
6
6
|
* You are recommended to use the Badge component from `@atlaskit/badge`.
|
|
7
7
|
*/
|
|
8
8
|
badge: ComponentType;
|
|
9
|
+
/**
|
|
10
|
+
* Experimental, do not use. May be removed at any time.
|
|
11
|
+
* Whether the tooltip should be disabled.
|
|
12
|
+
*/
|
|
13
|
+
UNSAFE_isTooltipDisabled?: boolean;
|
|
9
14
|
}
|
|
10
15
|
/**
|
|
11
16
|
* __Notifications__
|
|
@@ -1,6 +1,11 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import { type EndItemProps } from './end-item';
|
|
3
3
|
interface SettingsProps extends Omit<EndItemProps, 'icon'> {
|
|
4
|
+
/**
|
|
5
|
+
* Experimental, do not use. May be removed at any time.
|
|
6
|
+
* Whether the tooltip should be disabled.
|
|
7
|
+
*/
|
|
8
|
+
UNSAFE_isTooltipDisabled?: boolean;
|
|
4
9
|
}
|
|
5
10
|
/**
|
|
6
11
|
* __Settings__
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@atlaskit/navigation-system",
|
|
3
|
-
"version": "2.
|
|
3
|
+
"version": "2.15.0",
|
|
4
4
|
"description": "The latest navigation system for Atlassian apps.",
|
|
5
5
|
"repository": "https://bitbucket.org/atlassian/atlassian-frontend-mirror",
|
|
6
6
|
"author": "Atlassian Pty Ltd",
|
|
@@ -71,9 +71,9 @@
|
|
|
71
71
|
"@atlaskit/button": "^23.5.0",
|
|
72
72
|
"@atlaskit/css": "^0.14.0",
|
|
73
73
|
"@atlaskit/ds-lib": "^5.1.0",
|
|
74
|
-
"@atlaskit/icon": "^28.
|
|
74
|
+
"@atlaskit/icon": "^28.4.0",
|
|
75
75
|
"@atlaskit/layering": "^3.0.0",
|
|
76
|
-
"@atlaskit/logo": "^19.
|
|
76
|
+
"@atlaskit/logo": "^19.9.0",
|
|
77
77
|
"@atlaskit/platform-feature-flags": "^1.1.0",
|
|
78
78
|
"@atlaskit/popup": "^4.4.0",
|
|
79
79
|
"@atlaskit/pragmatic-drag-and-drop": "^1.7.0",
|
|
@@ -146,6 +146,9 @@
|
|
|
146
146
|
}
|
|
147
147
|
},
|
|
148
148
|
"platform-feature-flags": {
|
|
149
|
+
"platform_dst_nav4_side_nav_toggle_ref_fix": {
|
|
150
|
+
"type": "boolean"
|
|
151
|
+
},
|
|
149
152
|
"platform-component-visual-refresh": {
|
|
150
153
|
"type": "boolean",
|
|
151
154
|
"referenceOnly": true
|