orcs-design-system 3.2.13 → 3.2.14
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.
|
@@ -108,7 +108,8 @@ const NavItem = _ref => {
|
|
|
108
108
|
Component,
|
|
109
109
|
isActive,
|
|
110
110
|
handleItemClick,
|
|
111
|
-
navItemRefs
|
|
111
|
+
navItemRefs,
|
|
112
|
+
isSmallScreen
|
|
112
113
|
} = _ref;
|
|
113
114
|
// Use the ternary operator to render the appropriate component based on actionType
|
|
114
115
|
const accessibilityProps = {
|
|
@@ -120,8 +121,9 @@ const NavItem = _ref => {
|
|
|
120
121
|
return /*#__PURE__*/_jsx(SideNavItemPopover, {
|
|
121
122
|
className: item.bottomAligned && "bottom-aligned",
|
|
122
123
|
text: item.name,
|
|
124
|
+
direction: isSmallScreen ? "top" : "right",
|
|
123
125
|
textAlign: "center",
|
|
124
|
-
width: "
|
|
126
|
+
width: "fit-content",
|
|
125
127
|
active: isActive,
|
|
126
128
|
bottomAligned: item.bottomAligned,
|
|
127
129
|
children: item.actionType === "link" ? /*#__PURE__*/_jsx(SideNavItemLink, {
|
|
@@ -154,7 +156,8 @@ NavItem.propTypes = {
|
|
|
154
156
|
Component: PropTypes.elementType,
|
|
155
157
|
isActive: PropTypes.bool,
|
|
156
158
|
handleItemClick: PropTypes.func,
|
|
157
|
-
navItemRefs: PropTypes.object
|
|
159
|
+
navItemRefs: PropTypes.object,
|
|
160
|
+
isSmallScreen: PropTypes.bool
|
|
158
161
|
};
|
|
159
162
|
NavItem.__docgenInfo = {
|
|
160
163
|
"description": "",
|
|
@@ -195,6 +198,13 @@ NavItem.__docgenInfo = {
|
|
|
195
198
|
"name": "object"
|
|
196
199
|
},
|
|
197
200
|
"required": false
|
|
201
|
+
},
|
|
202
|
+
"isSmallScreen": {
|
|
203
|
+
"description": "",
|
|
204
|
+
"type": {
|
|
205
|
+
"name": "bool"
|
|
206
|
+
},
|
|
207
|
+
"required": false
|
|
198
208
|
}
|
|
199
209
|
}
|
|
200
210
|
};
|
|
@@ -196,6 +196,7 @@ const SideNav = _ref => {
|
|
|
196
196
|
const Component = item.component;
|
|
197
197
|
const Item = /*#__PURE__*/_jsx(NavItem, {
|
|
198
198
|
item: item,
|
|
199
|
+
isSmallScreen: isSmallScreen,
|
|
199
200
|
Component: Component,
|
|
200
201
|
isActive: item.actionType === "link" ? item.isActive : expandedItem == item.index,
|
|
201
202
|
handleItemClick: handleItemClick,
|