@carbon-labs/react-ui-shell 0.22.0 → 0.24.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/es/components/SideNav.js +6 -2
- package/es/components/SideNavLinkPopover.js +2 -0
- package/es/node_modules/@carbon/icons-react/es/Icon.js +1 -1
- package/es/node_modules/@carbon/icons-react/es/generated/bucket-15.js +935 -939
- package/es/node_modules/@carbon/icons-react/es/generated/bucket-3.js +803 -719
- package/lib/components/SideNav.js +6 -2
- package/lib/components/SideNavLinkPopover.js +2 -0
- package/lib/node_modules/@carbon/icons-react/es/Icon.js +1 -1
- package/lib/node_modules/@carbon/icons-react/es/generated/bucket-15.js +966 -970
- package/lib/node_modules/@carbon/icons-react/es/generated/bucket-3.js +811 -727
- package/package.json +2 -2
- package/scss/styles/_side-nav.scss +5 -0
- /package/es/node_modules/@carbon/{icon-helpers → icons-react/node_modules/@carbon/icon-helpers}/es/index.js +0 -0
- /package/lib/node_modules/@carbon/{icon-helpers → icons-react/node_modules/@carbon/icon-helpers}/es/index.js +0 -0
package/es/components/SideNav.js
CHANGED
|
@@ -144,12 +144,16 @@ function SideNavRenderFunction(_ref, ref) {
|
|
|
144
144
|
}
|
|
145
145
|
});
|
|
146
146
|
resetNodeTabIndices();
|
|
147
|
+
}
|
|
148
|
+
}, [prefix, internalIsTreeview]);
|
|
149
|
+
useEffect(() => {
|
|
150
|
+
if (sideNavRef.current) {
|
|
147
151
|
const firstElement = sideNavRef?.current?.querySelector('a, button');
|
|
148
|
-
if (firstElement) {
|
|
152
|
+
if (firstElement && (navType == SIDE_NAV_TYPE.PANEL || expanded)) {
|
|
149
153
|
firstElement.tabIndex = 0;
|
|
150
154
|
}
|
|
151
155
|
}
|
|
152
|
-
}, [
|
|
156
|
+
}, [expanded]);
|
|
153
157
|
|
|
154
158
|
/**
|
|
155
159
|
* Returns the parent SideNavMenu, if node is actually inside one.
|
|
@@ -21,6 +21,8 @@ function SideNavLinkPopover(_ref) {
|
|
|
21
21
|
const prefix = usePrefix();
|
|
22
22
|
return /*#__PURE__*/React.createElement(IconButton, _extends({
|
|
23
23
|
className: cx(className, `${prefix}--side-nav-link-popover`),
|
|
24
|
+
dropShadow: true,
|
|
25
|
+
highContrast: false,
|
|
24
26
|
kind: "ghost"
|
|
25
27
|
}, rest), children);
|
|
26
28
|
}
|
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
* LICENSE file in the root directory of this source tree.
|
|
6
6
|
*/
|
|
7
7
|
|
|
8
|
-
import { getAttributes } from '
|
|
8
|
+
import { getAttributes } from '../node_modules/@carbon/icon-helpers/es/index.js';
|
|
9
9
|
import PropTypes from 'prop-types';
|
|
10
10
|
import React from 'react';
|
|
11
11
|
|