@lotte-innovate/ui-component-test 0.2.68 → 0.2.70
Sign up to get free protection for your applications and to get access to all the features.
- package/dist/lib/components/SideBar/index.js +1 -3
- package/dist/lib/components/SideBar/index.mjs +1 -1
- package/dist/lib/tsconfig.tsbuildinfo +1 -1
- package/dist/lib/utils/useWindowSize.d.ts +0 -1
- package/dist/lib/utils/useWindowSize.js +18 -17
- package/dist/tsconfig.tsbuildinfo +1 -1
- package/package.json +1 -1
- package/dist/lib/utils/useWindowSize.mjs +0 -2
- package/dist/lib/utils/useWindowSize.mjs.map +0 -1
@@ -1 +0,0 @@
|
|
1
|
-
export declare function useWindowSize(): number;
|
@@ -1,17 +1,18 @@
|
|
1
|
-
|
2
|
-
|
3
|
-
|
4
|
-
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
|
11
|
-
|
12
|
-
|
13
|
-
|
14
|
-
|
15
|
-
|
16
|
-
|
17
|
-
|
1
|
+
"use strict";
|
2
|
+
// import { useState, useEffect } from 'react';
|
3
|
+
// const MIN_SIZE = 250;
|
4
|
+
// export function useWindowSize() {
|
5
|
+
// const [size, setSize] = useState(MIN_SIZE);
|
6
|
+
// useEffect(() => {
|
7
|
+
// function handleResize() {
|
8
|
+
// let width = 130 + window.innerWidth * 0.15;
|
9
|
+
// width = Math.max(width, MIN_SIZE);
|
10
|
+
// width = Math.min(width, 300);
|
11
|
+
// setSize(width);
|
12
|
+
// }
|
13
|
+
// window.addEventListener('resize', handleResize);
|
14
|
+
// handleResize();
|
15
|
+
// return () => window.removeEventListener('resize', handleResize);
|
16
|
+
// }, []);
|
17
|
+
// return size;
|
18
|
+
// }
|