@hyphen/hyphen-components 7.3.5 → 7.4.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/dist/css/index.css +876 -876
- package/dist/css/utilities.css +1 -1
- package/dist/css/variables.css +3 -3
- package/dist/hyphen-components.cjs.development.js +322 -463
- package/dist/hyphen-components.cjs.development.js.map +1 -1
- package/dist/hyphen-components.cjs.production.min.js +2 -2
- package/dist/hyphen-components.cjs.production.min.js.map +1 -1
- package/dist/hyphen-components.esm.js +322 -485
- package/dist/hyphen-components.esm.js.map +1 -1
- package/package.json +3 -2
- package/src/components/Sidebar/Sidebar.stories.tsx +11 -2
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@hyphen/hyphen-components",
|
|
3
|
-
"version": "7.
|
|
3
|
+
"version": "7.4.0",
|
|
4
4
|
"license": "MIT",
|
|
5
5
|
"author": {
|
|
6
6
|
"name": "@hyphen"
|
|
@@ -58,7 +58,7 @@
|
|
|
58
58
|
],
|
|
59
59
|
"dependencies": {
|
|
60
60
|
"@emotion/react": "^11.14.0",
|
|
61
|
-
"@hyphen/hyphen-design-tokens": "^7.0
|
|
61
|
+
"@hyphen/hyphen-design-tokens": "^7.2.0",
|
|
62
62
|
"@radix-ui/react-aspect-ratio": "^1.1.8",
|
|
63
63
|
"@radix-ui/react-collapsible": "^1.1.12",
|
|
64
64
|
"@radix-ui/react-dropdown-menu": "^2.1.16",
|
|
@@ -120,6 +120,7 @@
|
|
|
120
120
|
"jest-preview": "^0.3.1",
|
|
121
121
|
"mini-css-extract-plugin": "^2.9.1",
|
|
122
122
|
"postcss-loader": "^7.3.4",
|
|
123
|
+
"postcss-modules": "^6.0.0",
|
|
123
124
|
"react": "^18.3.1",
|
|
124
125
|
"react-dom": "^18.3.1",
|
|
125
126
|
"react-is": "^18.3.1",
|
|
@@ -238,11 +238,20 @@ export const SidebarBothSides = () => {
|
|
|
238
238
|
const [activeTeam, setActiveTeam] = React.useState(data.teams[0]);
|
|
239
239
|
const isMobile = useIsMobile();
|
|
240
240
|
|
|
241
|
-
const
|
|
241
|
+
const RIGHT_KEY = 'sidebar_dual_expanded_storybook_right';
|
|
242
|
+
const LEFT_KEY = 'sidebar_dual_expanded_storybook_left';
|
|
243
|
+
|
|
244
|
+
const defaultOpen = {
|
|
245
|
+
left: localStorage.getItem(LEFT_KEY) !== 'false',
|
|
246
|
+
right: localStorage.getItem(RIGHT_KEY) !== 'false',
|
|
247
|
+
};
|
|
242
248
|
|
|
243
249
|
return (
|
|
244
250
|
<ResponsiveProvider>
|
|
245
|
-
<SidebarProvider
|
|
251
|
+
<SidebarProvider
|
|
252
|
+
storageKey={{ left: LEFT_KEY, right: RIGHT_KEY }}
|
|
253
|
+
defaultOpen={defaultOpen}
|
|
254
|
+
>
|
|
246
255
|
<Sidebar side="left" collapsible="icon">
|
|
247
256
|
<NavHeader activeTeam={activeTeam} setActiveTeam={setActiveTeam} />
|
|
248
257
|
<SidebarContent>
|