Commit b79e771252f1bb2f0fbe5993c86e4f2ba968f2cb
1 parent
44989c2a
feat:update header
Showing
12 changed files
with
386 additions
and
151 deletions
next.config.js
package.json
@@ -11,16 +11,21 @@ | @@ -11,16 +11,21 @@ | ||
11 | "dependencies": { | 11 | "dependencies": { |
12 | "@emotion/react": "^11.11.1", | 12 | "@emotion/react": "^11.11.1", |
13 | "@emotion/styled": "^11.11.0", | 13 | "@emotion/styled": "^11.11.0", |
14 | + "@mui/icons-material": "^5.14.16", | ||
14 | "@mui/material": "^5.14.16", | 15 | "@mui/material": "^5.14.16", |
16 | + "lodash": "^4.17.21", | ||
15 | "next": "14.0.1", | 17 | "next": "14.0.1", |
16 | "react": "^18", | 18 | "react": "^18", |
17 | - "react-dom": "^18" | 19 | + "react-dom": "^18", |
20 | + "react-material-ui-carousel": "^3.4.2", | ||
21 | + "zustand": "^4.4.5" | ||
18 | }, | 22 | }, |
19 | "devDependencies": { | 23 | "devDependencies": { |
20 | "@types/node": "^20", | 24 | "@types/node": "^20", |
21 | "@types/react": "^18", | 25 | "@types/react": "^18", |
22 | "@types/react-dom": "^18", | 26 | "@types/react-dom": "^18", |
23 | "autoprefixer": "^10.0.1", | 27 | "autoprefixer": "^10.0.1", |
28 | + "babel-plugin-import": "^1.13.8", | ||
24 | "eslint": "^8", | 29 | "eslint": "^8", |
25 | "eslint-config-next": "14.0.1", | 30 | "eslint-config-next": "14.0.1", |
26 | "postcss": "^8", | 31 | "postcss": "^8", |
pnpm-lock.yaml
@@ -11,9 +11,15 @@ dependencies: | @@ -11,9 +11,15 @@ dependencies: | ||
11 | '@emotion/styled': | 11 | '@emotion/styled': |
12 | specifier: ^11.11.0 | 12 | specifier: ^11.11.0 |
13 | version: 11.11.0(@emotion/react@11.11.1)(@types/react@18.2.33)(react@18.2.0) | 13 | version: 11.11.0(@emotion/react@11.11.1)(@types/react@18.2.33)(react@18.2.0) |
14 | + '@mui/icons-material': | ||
15 | + specifier: ^5.14.16 | ||
16 | + version: 5.14.16(@mui/material@5.14.16)(@types/react@18.2.33)(react@18.2.0) | ||
14 | '@mui/material': | 17 | '@mui/material': |
15 | specifier: ^5.14.16 | 18 | specifier: ^5.14.16 |
16 | version: 5.14.16(@emotion/react@11.11.1)(@emotion/styled@11.11.0)(@types/react@18.2.33)(react-dom@18.2.0)(react@18.2.0) | 19 | version: 5.14.16(@emotion/react@11.11.1)(@emotion/styled@11.11.0)(@types/react@18.2.33)(react-dom@18.2.0)(react@18.2.0) |
20 | + lodash: | ||
21 | + specifier: ^4.17.21 | ||
22 | + version: 4.17.21 | ||
17 | next: | 23 | next: |
18 | specifier: 14.0.1 | 24 | specifier: 14.0.1 |
19 | version: 14.0.1(react-dom@18.2.0)(react@18.2.0) | 25 | version: 14.0.1(react-dom@18.2.0)(react@18.2.0) |
@@ -23,6 +29,12 @@ dependencies: | @@ -23,6 +29,12 @@ dependencies: | ||
23 | react-dom: | 29 | react-dom: |
24 | specifier: ^18 | 30 | specifier: ^18 |
25 | version: 18.2.0(react@18.2.0) | 31 | version: 18.2.0(react@18.2.0) |
32 | + react-material-ui-carousel: | ||
33 | + specifier: ^3.4.2 | ||
34 | + version: 3.4.2(@emotion/react@11.11.1)(@emotion/styled@11.11.0)(@mui/icons-material@5.14.16)(@mui/material@5.14.16)(@mui/system@5.14.16)(react-dom@18.2.0)(react@18.2.0) | ||
35 | + zustand: | ||
36 | + specifier: ^4.4.5 | ||
37 | + version: 4.4.5(@types/react@18.2.33)(react@18.2.0) | ||
26 | 38 | ||
27 | devDependencies: | 39 | devDependencies: |
28 | '@types/node': | 40 | '@types/node': |
@@ -37,6 +49,9 @@ devDependencies: | @@ -37,6 +49,9 @@ devDependencies: | ||
37 | autoprefixer: | 49 | autoprefixer: |
38 | specifier: ^10.0.1 | 50 | specifier: ^10.0.1 |
39 | version: 10.4.16(postcss@8.4.31) | 51 | version: 10.4.16(postcss@8.4.31) |
52 | + babel-plugin-import: | ||
53 | + specifier: ^1.13.8 | ||
54 | + version: 1.13.8 | ||
40 | eslint: | 55 | eslint: |
41 | specifier: ^8 | 56 | specifier: ^8 |
42 | version: 8.52.0 | 57 | version: 8.52.0 |
@@ -78,17 +93,14 @@ packages: | @@ -78,17 +93,14 @@ packages: | ||
78 | engines: {node: '>=6.9.0'} | 93 | engines: {node: '>=6.9.0'} |
79 | dependencies: | 94 | dependencies: |
80 | '@babel/types': 7.23.0 | 95 | '@babel/types': 7.23.0 |
81 | - dev: false | ||
82 | 96 | ||
83 | /@babel/helper-string-parser@7.22.5: | 97 | /@babel/helper-string-parser@7.22.5: |
84 | resolution: {integrity: sha512-mM4COjgZox8U+JcXQwPijIZLElkgEpO5rsERVDJTc2qfCDfERyob6k5WegS14SX18IIjv+XD+GrqNumY5JRCDw==} | 98 | resolution: {integrity: sha512-mM4COjgZox8U+JcXQwPijIZLElkgEpO5rsERVDJTc2qfCDfERyob6k5WegS14SX18IIjv+XD+GrqNumY5JRCDw==} |
85 | engines: {node: '>=6.9.0'} | 99 | engines: {node: '>=6.9.0'} |
86 | - dev: false | ||
87 | 100 | ||
88 | /@babel/helper-validator-identifier@7.22.20: | 101 | /@babel/helper-validator-identifier@7.22.20: |
89 | resolution: {integrity: sha512-Y4OZ+ytlatR8AI+8KZfKuL5urKp7qey08ha31L8b3BwewJAoJamTzyvxPR/5D+KkdJCGPq/+8TukHBlY10FX9A==} | 102 | resolution: {integrity: sha512-Y4OZ+ytlatR8AI+8KZfKuL5urKp7qey08ha31L8b3BwewJAoJamTzyvxPR/5D+KkdJCGPq/+8TukHBlY10FX9A==} |
90 | engines: {node: '>=6.9.0'} | 103 | engines: {node: '>=6.9.0'} |
91 | - dev: false | ||
92 | 104 | ||
93 | /@babel/highlight@7.22.20: | 105 | /@babel/highlight@7.22.20: |
94 | resolution: {integrity: sha512-dkdMCN3py0+ksCgYmGG8jKeGA/8Tk+gJwSYYlFGxG5lmhfKNoAy004YpLxpS1W2J8m/EK2Ew+yOs9pVRwO89mg==} | 106 | resolution: {integrity: sha512-dkdMCN3py0+ksCgYmGG8jKeGA/8Tk+gJwSYYlFGxG5lmhfKNoAy004YpLxpS1W2J8m/EK2Ew+yOs9pVRwO89mg==} |
@@ -112,7 +124,6 @@ packages: | @@ -112,7 +124,6 @@ packages: | ||
112 | '@babel/helper-string-parser': 7.22.5 | 124 | '@babel/helper-string-parser': 7.22.5 |
113 | '@babel/helper-validator-identifier': 7.22.20 | 125 | '@babel/helper-validator-identifier': 7.22.20 |
114 | to-fast-properties: 2.0.0 | 126 | to-fast-properties: 2.0.0 |
115 | - dev: false | ||
116 | 127 | ||
117 | /@emotion/babel-plugin@11.11.0: | 128 | /@emotion/babel-plugin@11.11.0: |
118 | resolution: {integrity: sha512-m4HEDZleaaCH+XgDDsPF15Ht6wTLsgDTeR3WYj9Q/k76JtWhrJjcP4+/XlG8LGT/Rol9qUfOIztXeA84ATpqPQ==} | 129 | resolution: {integrity: sha512-m4HEDZleaaCH+XgDDsPF15Ht6wTLsgDTeR3WYj9Q/k76JtWhrJjcP4+/XlG8LGT/Rol9qUfOIztXeA84ATpqPQ==} |
@@ -144,12 +155,26 @@ packages: | @@ -144,12 +155,26 @@ packages: | ||
144 | resolution: {integrity: sha512-gJB6HLm5rYwSLI6PQa+X1t5CFGrv1J1TWG+sOyMCeKz2ojaj6Fnl/rZEspogG+cvqbt4AE/2eIyD2QfLKTBNlQ==} | 155 | resolution: {integrity: sha512-gJB6HLm5rYwSLI6PQa+X1t5CFGrv1J1TWG+sOyMCeKz2ojaj6Fnl/rZEspogG+cvqbt4AE/2eIyD2QfLKTBNlQ==} |
145 | dev: false | 156 | dev: false |
146 | 157 | ||
158 | + /@emotion/is-prop-valid@0.8.8: | ||
159 | + resolution: {integrity: sha512-u5WtneEAr5IDG2Wv65yhunPSMLIpuKsbuOktRojfrEiEvRyC85LgPMZI63cr7NUqT8ZIGdSVg8ZKGxIug4lXcA==} | ||
160 | + requiresBuild: true | ||
161 | + dependencies: | ||
162 | + '@emotion/memoize': 0.7.4 | ||
163 | + dev: false | ||
164 | + optional: true | ||
165 | + | ||
147 | /@emotion/is-prop-valid@1.2.1: | 166 | /@emotion/is-prop-valid@1.2.1: |
148 | resolution: {integrity: sha512-61Mf7Ufx4aDxx1xlDeOm8aFFigGHE4z+0sKCa+IHCeZKiyP9RLD0Mmx7m8b9/Cf37f7NAvQOOJAbQQGVr5uERw==} | 167 | resolution: {integrity: sha512-61Mf7Ufx4aDxx1xlDeOm8aFFigGHE4z+0sKCa+IHCeZKiyP9RLD0Mmx7m8b9/Cf37f7NAvQOOJAbQQGVr5uERw==} |
149 | dependencies: | 168 | dependencies: |
150 | '@emotion/memoize': 0.8.1 | 169 | '@emotion/memoize': 0.8.1 |
151 | dev: false | 170 | dev: false |
152 | 171 | ||
172 | + /@emotion/memoize@0.7.4: | ||
173 | + resolution: {integrity: sha512-Ja/Vfqe3HpuzRsG1oBtWTHk2PGZ7GR+2Vz5iYGelAw8dx32K0y7PjVuxK6z1nMpZOqAFsRUPCkK1YjJ56qJlgw==} | ||
174 | + requiresBuild: true | ||
175 | + dev: false | ||
176 | + optional: true | ||
177 | + | ||
153 | /@emotion/memoize@0.8.1: | 178 | /@emotion/memoize@0.8.1: |
154 | resolution: {integrity: sha512-W2P2c/VRW1/1tLox0mVUalvnWXxavmv/Oum2aPsRcoDJuob75FC3Y8FbpfLwUegRcxINtGUMPq0tFCvYNTBXNA==} | 179 | resolution: {integrity: sha512-W2P2c/VRW1/1tLox0mVUalvnWXxavmv/Oum2aPsRcoDJuob75FC3Y8FbpfLwUegRcxINtGUMPq0tFCvYNTBXNA==} |
155 | dev: false | 180 | dev: false |
@@ -372,6 +397,23 @@ packages: | @@ -372,6 +397,23 @@ packages: | ||
372 | resolution: {integrity: sha512-97isBjzH2v1K7oB4UH2f4NOkBShOynY6dhnoR2XlUk/g6bb7ZBv2I3D1hvvqPtpEigKu93e7f/jAYr5d9LOc5w==} | 397 | resolution: {integrity: sha512-97isBjzH2v1K7oB4UH2f4NOkBShOynY6dhnoR2XlUk/g6bb7ZBv2I3D1hvvqPtpEigKu93e7f/jAYr5d9LOc5w==} |
373 | dev: false | 398 | dev: false |
374 | 399 | ||
400 | + /@mui/icons-material@5.14.16(@mui/material@5.14.16)(@types/react@18.2.33)(react@18.2.0): | ||
401 | + resolution: {integrity: sha512-wmOgslMEGvbHZjFLru8uH5E+pif/ciXAvKNw16q6joK6EWVWU5rDYWFknDaZhCvz8ZE/K8ZnJQ+lMG6GgHzXbg==} | ||
402 | + engines: {node: '>=12.0.0'} | ||
403 | + peerDependencies: | ||
404 | + '@mui/material': ^5.0.0 | ||
405 | + '@types/react': ^17.0.0 || ^18.0.0 | ||
406 | + react: ^17.0.0 || ^18.0.0 | ||
407 | + peerDependenciesMeta: | ||
408 | + '@types/react': | ||
409 | + optional: true | ||
410 | + dependencies: | ||
411 | + '@babel/runtime': 7.23.2 | ||
412 | + '@mui/material': 5.14.16(@emotion/react@11.11.1)(@emotion/styled@11.11.0)(@types/react@18.2.33)(react-dom@18.2.0)(react@18.2.0) | ||
413 | + '@types/react': 18.2.33 | ||
414 | + react: 18.2.0 | ||
415 | + dev: false | ||
416 | + | ||
375 | /@mui/material@5.14.16(@emotion/react@11.11.1)(@emotion/styled@11.11.0)(@types/react@18.2.33)(react-dom@18.2.0)(react@18.2.0): | 417 | /@mui/material@5.14.16(@emotion/react@11.11.1)(@emotion/styled@11.11.0)(@types/react@18.2.33)(react-dom@18.2.0)(react@18.2.0): |
376 | resolution: {integrity: sha512-W4zZ4vnxgGk6/HqBwgsDHKU7x2l2NhX+r8gAwfg58Rhu3ikfY7NkIS6y8Gl3NkATc4GG1FNaGjjpQKfJx3U6Jw==} | 418 | resolution: {integrity: sha512-W4zZ4vnxgGk6/HqBwgsDHKU7x2l2NhX+r8gAwfg58Rhu3ikfY7NkIS6y8Gl3NkATc4GG1FNaGjjpQKfJx3U6Jw==} |
377 | engines: {node: '>=12.0.0'} | 419 | engines: {node: '>=12.0.0'} |
@@ -925,6 +967,12 @@ packages: | @@ -925,6 +967,12 @@ packages: | ||
925 | dequal: 2.0.3 | 967 | dequal: 2.0.3 |
926 | dev: true | 968 | dev: true |
927 | 969 | ||
970 | + /babel-plugin-import@1.13.8: | ||
971 | + resolution: {integrity: sha512-36babpjra5m3gca44V6tSTomeBlPA7cHUynrE2WiQIm3rEGD9xy28MKsx5IdO45EbnpJY7Jrgd00C6Dwt/l/2Q==} | ||
972 | + dependencies: | ||
973 | + '@babel/helper-module-imports': 7.22.15 | ||
974 | + dev: true | ||
975 | + | ||
928 | /babel-plugin-macros@3.1.0: | 976 | /babel-plugin-macros@3.1.0: |
929 | resolution: {integrity: sha512-Cg7TFGpIr01vOQNODXOOaGz2NpCU5gl8x1qJFbb6hbZxR7XrcE2vtbAsTAbJ7/xwJtUuJEw8K8Zr/AE0LHlesg==} | 977 | resolution: {integrity: sha512-Cg7TFGpIr01vOQNODXOOaGz2NpCU5gl8x1qJFbb6hbZxR7XrcE2vtbAsTAbJ7/xwJtUuJEw8K8Zr/AE0LHlesg==} |
930 | engines: {node: '>=10', npm: '>=6'} | 978 | engines: {node: '>=10', npm: '>=6'} |
@@ -1666,6 +1714,29 @@ packages: | @@ -1666,6 +1714,29 @@ packages: | ||
1666 | resolution: {integrity: sha512-ZsDfxO51wGAXREY55a7la9LScWpwv9RxIrYABrlvOFBlH/ShPnrtsXeuUIfXKKOVicNxQ+o8JTbJvjS4M89yew==} | 1714 | resolution: {integrity: sha512-ZsDfxO51wGAXREY55a7la9LScWpwv9RxIrYABrlvOFBlH/ShPnrtsXeuUIfXKKOVicNxQ+o8JTbJvjS4M89yew==} |
1667 | dev: true | 1715 | dev: true |
1668 | 1716 | ||
1717 | + /framer-motion@4.1.17(react-dom@18.2.0)(react@18.2.0): | ||
1718 | + resolution: {integrity: sha512-thx1wvKzblzbs0XaK2X0G1JuwIdARcoNOW7VVwjO8BUltzXPyONGAElLu6CiCScsOQRI7FIk/45YTFtJw5Yozw==} | ||
1719 | + peerDependencies: | ||
1720 | + react: '>=16.8 || ^17.0.0' | ||
1721 | + react-dom: '>=16.8 || ^17.0.0' | ||
1722 | + dependencies: | ||
1723 | + framesync: 5.3.0 | ||
1724 | + hey-listen: 1.0.8 | ||
1725 | + popmotion: 9.3.6 | ||
1726 | + react: 18.2.0 | ||
1727 | + react-dom: 18.2.0(react@18.2.0) | ||
1728 | + style-value-types: 4.1.4 | ||
1729 | + tslib: 2.6.2 | ||
1730 | + optionalDependencies: | ||
1731 | + '@emotion/is-prop-valid': 0.8.8 | ||
1732 | + dev: false | ||
1733 | + | ||
1734 | + /framesync@5.3.0: | ||
1735 | + resolution: {integrity: sha512-oc5m68HDO/tuK2blj7ZcdEBRx3p1PjrgHazL8GYEpvULhrtGIFbQArN6cQS2QhW8mitffaB+VYzMjDqBxxQeoA==} | ||
1736 | + dependencies: | ||
1737 | + tslib: 2.6.2 | ||
1738 | + dev: false | ||
1739 | + | ||
1669 | /fs.realpath@1.0.0: | 1740 | /fs.realpath@1.0.0: |
1670 | resolution: {integrity: sha512-OO0pH2lK6a0hZnAdau5ItzHPI6pUlvI7jMVnxUQRtw4owF2wk8lOSabtGDCTP4Ggrg2MbGnWO9X8K1t4+fGMDw==} | 1741 | resolution: {integrity: sha512-OO0pH2lK6a0hZnAdau5ItzHPI6pUlvI7jMVnxUQRtw4owF2wk8lOSabtGDCTP4Ggrg2MbGnWO9X8K1t4+fGMDw==} |
1671 | dev: true | 1742 | dev: true |
@@ -1856,6 +1927,10 @@ packages: | @@ -1856,6 +1927,10 @@ packages: | ||
1856 | dependencies: | 1927 | dependencies: |
1857 | function-bind: 1.1.2 | 1928 | function-bind: 1.1.2 |
1858 | 1929 | ||
1930 | + /hey-listen@1.0.8: | ||
1931 | + resolution: {integrity: sha512-COpmrF2NOg4TBWUJ5UVyaCU2A88wEMkUPK4hNqyCkqHbxT92BbvfjoSozkAIIm6XhicGlJHhFdullInrdhwU8Q==} | ||
1932 | + dev: false | ||
1933 | + | ||
1859 | /hoist-non-react-statics@3.3.2: | 1934 | /hoist-non-react-statics@3.3.2: |
1860 | resolution: {integrity: sha512-/gGivxi8JPKWNm/W0jSmzcMPpfpPLc3dY/6GxhX2hQ9iGj3aDfklV4ET7NjKpSinLpJ5vafa9iiGIEZg10SfBw==} | 1935 | resolution: {integrity: sha512-/gGivxi8JPKWNm/W0jSmzcMPpfpPLc3dY/6GxhX2hQ9iGj3aDfklV4ET7NjKpSinLpJ5vafa9iiGIEZg10SfBw==} |
1861 | dependencies: | 1936 | dependencies: |
@@ -2172,6 +2247,10 @@ packages: | @@ -2172,6 +2247,10 @@ packages: | ||
2172 | resolution: {integrity: sha512-0KpjqXRVvrYyCsX1swR/XTK0va6VQkQM6MNo7PqW77ByjAhoARA8EfrP1N4+KlKj8YS0ZUCtRT/YUuhyYDujIQ==} | 2247 | resolution: {integrity: sha512-0KpjqXRVvrYyCsX1swR/XTK0va6VQkQM6MNo7PqW77ByjAhoARA8EfrP1N4+KlKj8YS0ZUCtRT/YUuhyYDujIQ==} |
2173 | dev: true | 2248 | dev: true |
2174 | 2249 | ||
2250 | + /lodash@4.17.21: | ||
2251 | + resolution: {integrity: sha512-v2kDEe57lecTulaDIuNTPy3Ry4gLGJ6Z1O3vE1krgXZNrsQ+LFTGHVxVjcXPs17LhbZVGedAJv8XZ1tvj5FvSg==} | ||
2252 | + dev: false | ||
2253 | + | ||
2175 | /loose-envify@1.4.0: | 2254 | /loose-envify@1.4.0: |
2176 | resolution: {integrity: sha512-lyuxPGr/Wfhrlem2CL/UcnUc1zcqKAImBDzukY7Y5F/yQiNdko6+fRLevlw1HgMySw7f611UIY408EtxRSoK3Q==} | 2255 | resolution: {integrity: sha512-lyuxPGr/Wfhrlem2CL/UcnUc1zcqKAImBDzukY7Y5F/yQiNdko6+fRLevlw1HgMySw7f611UIY408EtxRSoK3Q==} |
2177 | hasBin: true | 2256 | hasBin: true |
@@ -2445,6 +2524,15 @@ packages: | @@ -2445,6 +2524,15 @@ packages: | ||
2445 | engines: {node: '>= 6'} | 2524 | engines: {node: '>= 6'} |
2446 | dev: true | 2525 | dev: true |
2447 | 2526 | ||
2527 | + /popmotion@9.3.6: | ||
2528 | + resolution: {integrity: sha512-ZTbXiu6zIggXzIliMi8LGxXBF5ST+wkpXGEjeTUDUOCdSQ356hij/xjeUdv0F8zCQNeqB1+PR5/BB+gC+QLAPw==} | ||
2529 | + dependencies: | ||
2530 | + framesync: 5.3.0 | ||
2531 | + hey-listen: 1.0.8 | ||
2532 | + style-value-types: 4.1.4 | ||
2533 | + tslib: 2.6.2 | ||
2534 | + dev: false | ||
2535 | + | ||
2448 | /postcss-import@15.1.0(postcss@8.4.31): | 2536 | /postcss-import@15.1.0(postcss@8.4.31): |
2449 | resolution: {integrity: sha512-hpr+J05B2FVYUAXHeK1YyI267J/dDDhMU6B6civm8hSY1jYJnBXxzKDKDswzJmtLHryrjhnDjqqp/49t8FALew==} | 2537 | resolution: {integrity: sha512-hpr+J05B2FVYUAXHeK1YyI267J/dDDhMU6B6civm8hSY1jYJnBXxzKDKDswzJmtLHryrjhnDjqqp/49t8FALew==} |
2450 | engines: {node: '>=14.0.0'} | 2538 | engines: {node: '>=14.0.0'} |
@@ -2552,6 +2640,27 @@ packages: | @@ -2552,6 +2640,27 @@ packages: | ||
2552 | resolution: {integrity: sha512-xWGDIW6x921xtzPkhiULtthJHoJvBbF3q26fzloPCK0hsvxtPVelvftw3zjbHWSkR2km9Z+4uxbDDK/6Zw9B8w==} | 2640 | resolution: {integrity: sha512-xWGDIW6x921xtzPkhiULtthJHoJvBbF3q26fzloPCK0hsvxtPVelvftw3zjbHWSkR2km9Z+4uxbDDK/6Zw9B8w==} |
2553 | dev: false | 2641 | dev: false |
2554 | 2642 | ||
2643 | + /react-material-ui-carousel@3.4.2(@emotion/react@11.11.1)(@emotion/styled@11.11.0)(@mui/icons-material@5.14.16)(@mui/material@5.14.16)(@mui/system@5.14.16)(react-dom@18.2.0)(react@18.2.0): | ||
2644 | + resolution: {integrity: sha512-jUbC5aBWqbbbUOOdUe3zTVf4kMiZFwKJqwhxzHgBfklaXQbSopis4iWAHvEOLcZtSIJk4JAGxKE0CmxDoxvUuw==} | ||
2645 | + peerDependencies: | ||
2646 | + '@emotion/react': ^11.4.1 | ||
2647 | + '@emotion/styled': ^11.3.0 | ||
2648 | + '@mui/icons-material': ^5.0.0 | ||
2649 | + '@mui/material': ^5.0.0 | ||
2650 | + '@mui/system': ^5.0.0 | ||
2651 | + react: ^17.0.1 || ^18.0.0 | ||
2652 | + react-dom: ^17.0.2 || ^18.0.0 | ||
2653 | + dependencies: | ||
2654 | + '@emotion/react': 11.11.1(@types/react@18.2.33)(react@18.2.0) | ||
2655 | + '@emotion/styled': 11.11.0(@emotion/react@11.11.1)(@types/react@18.2.33)(react@18.2.0) | ||
2656 | + '@mui/icons-material': 5.14.16(@mui/material@5.14.16)(@types/react@18.2.33)(react@18.2.0) | ||
2657 | + '@mui/material': 5.14.16(@emotion/react@11.11.1)(@emotion/styled@11.11.0)(@types/react@18.2.33)(react-dom@18.2.0)(react@18.2.0) | ||
2658 | + '@mui/system': 5.14.16(@emotion/react@11.11.1)(@emotion/styled@11.11.0)(@types/react@18.2.33)(react@18.2.0) | ||
2659 | + framer-motion: 4.1.17(react-dom@18.2.0)(react@18.2.0) | ||
2660 | + react: 18.2.0 | ||
2661 | + react-dom: 18.2.0(react@18.2.0) | ||
2662 | + dev: false | ||
2663 | + | ||
2555 | /react-transition-group@4.4.5(react-dom@18.2.0)(react@18.2.0): | 2664 | /react-transition-group@4.4.5(react-dom@18.2.0)(react@18.2.0): |
2556 | resolution: {integrity: sha512-pZcd1MCJoiKiBR2NRxeCRg13uCXbydPnmB4EOeRrY7480qNWO8IIgQG6zlDkm6uRMsURXPuKq0GWtiM59a5Q6g==} | 2665 | resolution: {integrity: sha512-pZcd1MCJoiKiBR2NRxeCRg13uCXbydPnmB4EOeRrY7480qNWO8IIgQG6zlDkm6uRMsURXPuKq0GWtiM59a5Q6g==} |
2557 | peerDependencies: | 2666 | peerDependencies: |
@@ -2804,6 +2913,13 @@ packages: | @@ -2804,6 +2913,13 @@ packages: | ||
2804 | engines: {node: '>=8'} | 2913 | engines: {node: '>=8'} |
2805 | dev: true | 2914 | dev: true |
2806 | 2915 | ||
2916 | + /style-value-types@4.1.4: | ||
2917 | + resolution: {integrity: sha512-LCJL6tB+vPSUoxgUBt9juXIlNJHtBMy8jkXzUJSBzeHWdBu6lhzHqCvLVkXFGsFIlNa2ln1sQHya/gzaFmB2Lg==} | ||
2918 | + dependencies: | ||
2919 | + hey-listen: 1.0.8 | ||
2920 | + tslib: 2.6.2 | ||
2921 | + dev: false | ||
2922 | + | ||
2807 | /styled-jsx@5.1.1(react@18.2.0): | 2923 | /styled-jsx@5.1.1(react@18.2.0): |
2808 | resolution: {integrity: sha512-pW7uC1l4mBZ8ugbiZrcIsiIvVx1UmTfw7UkC3Um2tmfUq9Bhk8IiyEIPl6F8agHgjzku6j0xQEZbfA5uSgSaCw==} | 2924 | resolution: {integrity: sha512-pW7uC1l4mBZ8ugbiZrcIsiIvVx1UmTfw7UkC3Um2tmfUq9Bhk8IiyEIPl6F8agHgjzku6j0xQEZbfA5uSgSaCw==} |
2809 | engines: {node: '>= 12.0.0'} | 2925 | engines: {node: '>= 12.0.0'} |
@@ -2913,7 +3029,6 @@ packages: | @@ -2913,7 +3029,6 @@ packages: | ||
2913 | /to-fast-properties@2.0.0: | 3029 | /to-fast-properties@2.0.0: |
2914 | resolution: {integrity: sha512-/OaKK0xYrs3DmxRYqL/yDc+FxFUVYhDlXMhRmv3z915w2HF1tnN1omB354j8VUGO/hbRzyD6Y3sA7v7GS/ceog==} | 3030 | resolution: {integrity: sha512-/OaKK0xYrs3DmxRYqL/yDc+FxFUVYhDlXMhRmv3z915w2HF1tnN1omB354j8VUGO/hbRzyD6Y3sA7v7GS/ceog==} |
2915 | engines: {node: '>=4'} | 3031 | engines: {node: '>=4'} |
2916 | - dev: false | ||
2917 | 3032 | ||
2918 | /to-regex-range@5.0.1: | 3033 | /to-regex-range@5.0.1: |
2919 | resolution: {integrity: sha512-65P7iz6X5yEr1cwcgvQxbbIw7Uk3gOy5dIdtZ4rDveLqhrdJP+Li/Hx6tyK0NEb+2GCyneCMJiGqrADCSNk8sQ==} | 3034 | resolution: {integrity: sha512-65P7iz6X5yEr1cwcgvQxbbIw7Uk3gOy5dIdtZ4rDveLqhrdJP+Li/Hx6tyK0NEb+2GCyneCMJiGqrADCSNk8sQ==} |
@@ -3034,6 +3149,14 @@ packages: | @@ -3034,6 +3149,14 @@ packages: | ||
3034 | punycode: 2.3.1 | 3149 | punycode: 2.3.1 |
3035 | dev: true | 3150 | dev: true |
3036 | 3151 | ||
3152 | + /use-sync-external-store@1.2.0(react@18.2.0): | ||
3153 | + resolution: {integrity: sha512-eEgnFxGQ1Ife9bzYs6VLi8/4X6CObHMw9Qr9tPY43iKwsPw8xE8+EFsf/2cFZ5S3esXgpWgtSCtLNS41F+sKPA==} | ||
3154 | + peerDependencies: | ||
3155 | + react: ^16.8.0 || ^17.0.0 || ^18.0.0 | ||
3156 | + dependencies: | ||
3157 | + react: 18.2.0 | ||
3158 | + dev: false | ||
3159 | + | ||
3037 | /util-deprecate@1.0.2: | 3160 | /util-deprecate@1.0.2: |
3038 | resolution: {integrity: sha512-EPD5q1uXyFxJpCrLnCc1nHnq3gOa6DZBocAIiI2TaSCA7VCJ1UJDMagCzIkXNsUYfD1daK//LTEQ8xiIbrHtcw==} | 3161 | resolution: {integrity: sha512-EPD5q1uXyFxJpCrLnCc1nHnq3gOa6DZBocAIiI2TaSCA7VCJ1UJDMagCzIkXNsUYfD1daK//LTEQ8xiIbrHtcw==} |
3039 | dev: true | 3162 | dev: true |
@@ -3124,3 +3247,23 @@ packages: | @@ -3124,3 +3247,23 @@ packages: | ||
3124 | resolution: {integrity: sha512-rVksvsnNCdJ/ohGc6xgPwyN8eheCxsiLM8mxuE/t/mOVqJewPuO1miLpTHQiRgTKCLexL4MeAFVagts7HmNZ2Q==} | 3247 | resolution: {integrity: sha512-rVksvsnNCdJ/ohGc6xgPwyN8eheCxsiLM8mxuE/t/mOVqJewPuO1miLpTHQiRgTKCLexL4MeAFVagts7HmNZ2Q==} |
3125 | engines: {node: '>=10'} | 3248 | engines: {node: '>=10'} |
3126 | dev: true | 3249 | dev: true |
3250 | + | ||
3251 | + /zustand@4.4.5(@types/react@18.2.33)(react@18.2.0): | ||
3252 | + resolution: {integrity: sha512-jgIrBBLKncQW74PA2Lclct3gwD4aPughwGE4FqlXrv3rDqQox7JCn8rwUiFK6ygJcbBAvfTf8fF+ICg7HLD2FQ==} | ||
3253 | + engines: {node: '>=12.7.0'} | ||
3254 | + peerDependencies: | ||
3255 | + '@types/react': '>=16.8' | ||
3256 | + immer: '>=9.0' | ||
3257 | + react: '>=16.8' | ||
3258 | + peerDependenciesMeta: | ||
3259 | + '@types/react': | ||
3260 | + optional: true | ||
3261 | + immer: | ||
3262 | + optional: true | ||
3263 | + react: | ||
3264 | + optional: true | ||
3265 | + dependencies: | ||
3266 | + '@types/react': 18.2.33 | ||
3267 | + react: 18.2.0 | ||
3268 | + use-sync-external-store: 1.2.0(react@18.2.0) | ||
3269 | + dev: false |
public/icon/logo.jpg
0 → 100644
38.2 KB
src/app/globals.css
1 | @tailwind base; | 1 | @tailwind base; |
2 | @tailwind components; | 2 | @tailwind components; |
3 | @tailwind utilities; | 3 | @tailwind utilities; |
4 | - | ||
5 | -:root { | ||
6 | - --foreground-rgb: 0, 0, 0; | ||
7 | - --background-start-rgb: 214, 219, 220; | ||
8 | - --background-end-rgb: 255, 255, 255; | ||
9 | -} | ||
10 | - | ||
11 | -@media (prefers-color-scheme: dark) { | ||
12 | - :root { | ||
13 | - --foreground-rgb: 255, 255, 255; | ||
14 | - --background-start-rgb: 0, 0, 0; | ||
15 | - --background-end-rgb: 0, 0, 0; | ||
16 | - } | ||
17 | -} | ||
18 | - | ||
19 | -body { | ||
20 | - color: rgb(var(--foreground-rgb)); | ||
21 | - background: linear-gradient( | ||
22 | - to bottom, | ||
23 | - transparent, | ||
24 | - rgb(var(--background-end-rgb)) | ||
25 | - ) | ||
26 | - rgb(var(--background-start-rgb)); | ||
27 | -} |
src/app/home/page.tsx
0 → 100644
1 | +import React, { useState, useEffect } from 'react'; | ||
2 | +import MainTitleList from '@/components/MainTitleList'; // 确保你有相应的React版本 | ||
3 | +import MainTitleListOdd from '@/components/MainTitleListOdd'; // 确保你有相应的React版本 | ||
4 | +import { useCategoryStore } from '@/stores/category'; // 确保你有相应的React版本 | ||
5 | +import { isMobile } from '@/utils'; // 确保你有相应的React版本 | ||
6 | +import { Carousel } from '@mui/material'; | ||
7 | + | ||
8 | +const HomePage = () => { | ||
9 | + const store = useCategoryStore(); | ||
10 | + const [lab, setLab] = useState({ categoryDisplayName: '', list: [] }); | ||
11 | + | ||
12 | + useEffect(() => { | ||
13 | + if (store?.list?.[3]) { | ||
14 | + setLab(store.list[3]); | ||
15 | + } | ||
16 | + }, [store]); | ||
17 | + | ||
18 | + const banners = [ | ||
19 | + '/banner/banner1.jpg', | ||
20 | + '/banner/banner2.jpg', | ||
21 | + '/banner/banner3.jpg', | ||
22 | + '/banner/banner4.jpg', | ||
23 | + ]; | ||
24 | + | ||
25 | + const mobileBanners = [ | ||
26 | + '/mobile/banner-index1.png', | ||
27 | + '/mobile/banner-index2.png', | ||
28 | + '/mobile/banner-index3.png', | ||
29 | + ]; | ||
30 | + | ||
31 | + // ... 其他数据如 materials, tests, batteries, packs 保持不变 | ||
32 | + | ||
33 | + console.log( | ||
34 | + '%c [ banners ]-111', | ||
35 | + 'font-size:13px; background:pink; color:#bf2c9f;', | ||
36 | + banners | ||
37 | + ); | ||
38 | + | ||
39 | + return ( | ||
40 | + <div className="tw-w-full"> | ||
41 | + <Carousel hideDelimiterBackground showArrowsOnHover height="auto"> | ||
42 | + {banners.map((banner) => ( | ||
43 | + <CarouselItem src={banner} cover alt="canrud" key={banner} /> | ||
44 | + ))} | ||
45 | + </Carousel> | ||
46 | + {/* 其他部分 */} | ||
47 | + {/* ... 其他代码保持不变,只是将Vue特有的语法替换成React的语法 */} | ||
48 | + </div> | ||
49 | + ); | ||
50 | +}; | ||
51 | + | ||
52 | +export default HomePage; |
src/app/layout.tsx
1 | -import type { Metadata } from 'next' | ||
2 | -import { Inter } from 'next/font/google' | ||
3 | -import './globals.css' | 1 | +import type { Metadata } from 'next'; |
2 | +import { Inter } from 'next/font/google'; | ||
3 | +import { ThemeProvider, createTheme } from '@mui/material/styles'; | ||
4 | +import { theme } from '../style/theme'; | ||
4 | 5 | ||
5 | -const inter = Inter({ subsets: ['latin'] }) | 6 | +import './globals.css'; |
7 | + | ||
8 | +const inter = Inter({ subsets: ['latin'] }); | ||
6 | 9 | ||
7 | export const metadata: Metadata = { | 10 | export const metadata: Metadata = { |
8 | title: 'Create Next App', | 11 | title: 'Create Next App', |
9 | description: 'Generated by create next app', | 12 | description: 'Generated by create next app', |
10 | -} | 13 | +}; |
11 | 14 | ||
12 | export default function RootLayout({ | 15 | export default function RootLayout({ |
13 | children, | 16 | children, |
14 | }: { | 17 | }: { |
15 | - children: React.ReactNode | 18 | + children: React.ReactNode; |
16 | }) { | 19 | }) { |
17 | return ( | 20 | return ( |
18 | <html lang="en"> | 21 | <html lang="en"> |
19 | - <body className={inter.className}>{children}</body> | 22 | + <ThemeProvider theme={theme}> |
23 | + <body className={inter.className}>{children}</body> | ||
24 | + </ThemeProvider> | ||
20 | </html> | 25 | </html> |
21 | - ) | 26 | + ); |
22 | } | 27 | } |
src/app/page.tsx
1 | -import Image from 'next/image' | 1 | +import Header from '@/components/Header'; |
2 | +import Image from 'next/image'; | ||
2 | 3 | ||
3 | export default function Home() { | 4 | export default function Home() { |
4 | - return ( | ||
5 | - <main className="flex min-h-screen flex-col items-center justify-between p-24"> | ||
6 | - <div className="z-10 max-w-5xl w-full items-center justify-between font-mono text-sm lg:flex"> | ||
7 | - <p className="fixed left-0 top-0 flex w-full justify-center border-b border-gray-300 bg-gradient-to-b from-zinc-200 pb-6 pt-8 backdrop-blur-2xl dark:border-neutral-800 dark:bg-zinc-800/30 dark:from-inherit lg:static lg:w-auto lg:rounded-xl lg:border lg:bg-gray-200 lg:p-4 lg:dark:bg-zinc-800/30"> | ||
8 | - Get started by editing | ||
9 | - <code className="font-mono font-bold">src/app/page.tsx</code> | ||
10 | - </p> | ||
11 | - <div className="fixed bottom-0 left-0 flex h-48 w-full items-end justify-center bg-gradient-to-t from-white via-white dark:from-black dark:via-black lg:static lg:h-auto lg:w-auto lg:bg-none"> | ||
12 | - <a | ||
13 | - className="pointer-events-none flex place-items-center gap-2 p-8 lg:pointer-events-auto lg:p-0" | ||
14 | - href="https://vercel.com?utm_source=create-next-app&utm_medium=appdir-template&utm_campaign=create-next-app" | ||
15 | - target="_blank" | ||
16 | - rel="noopener noreferrer" | ||
17 | - > | ||
18 | - By{' '} | ||
19 | - <Image | ||
20 | - src="/vercel.svg" | ||
21 | - alt="Vercel Logo" | ||
22 | - className="dark:invert" | ||
23 | - width={100} | ||
24 | - height={24} | ||
25 | - priority | ||
26 | - /> | ||
27 | - </a> | ||
28 | - </div> | ||
29 | - </div> | ||
30 | - | ||
31 | - <div className="relative flex place-items-center before:absolute before:h-[300px] before:w-[480px] before:-translate-x-1/2 before:rounded-full before:bg-gradient-radial before:from-white before:to-transparent before:blur-2xl before:content-[''] after:absolute after:-z-20 after:h-[180px] after:w-[240px] after:translate-x-1/3 after:bg-gradient-conic after:from-sky-200 after:via-blue-200 after:blur-2xl after:content-[''] before:dark:bg-gradient-to-br before:dark:from-transparent before:dark:to-blue-700 before:dark:opacity-10 after:dark:from-sky-900 after:dark:via-[#0141ff] after:dark:opacity-40 before:lg:h-[360px] z-[-1]"> | ||
32 | - <Image | ||
33 | - className="relative dark:drop-shadow-[0_0_0.3rem_#ffffff70] dark:invert" | ||
34 | - src="/next.svg" | ||
35 | - alt="Next.js Logo" | ||
36 | - width={180} | ||
37 | - height={37} | ||
38 | - priority | ||
39 | - /> | ||
40 | - </div> | ||
41 | - | ||
42 | - <div className="mb-32 grid text-center lg:max-w-5xl lg:w-full lg:mb-0 lg:grid-cols-4 lg:text-left"> | ||
43 | - <a | ||
44 | - href="https://nextjs.org/docs?utm_source=create-next-app&utm_medium=appdir-template&utm_campaign=create-next-app" | ||
45 | - className="group rounded-lg border border-transparent px-5 py-4 transition-colors hover:border-gray-300 hover:bg-gray-100 hover:dark:border-neutral-700 hover:dark:bg-neutral-800/30" | ||
46 | - target="_blank" | ||
47 | - rel="noopener noreferrer" | ||
48 | - > | ||
49 | - <h2 className={`mb-3 text-2xl font-semibold`}> | ||
50 | - Docs{' '} | ||
51 | - <span className="inline-block transition-transform group-hover:translate-x-1 motion-reduce:transform-none"> | ||
52 | - -> | ||
53 | - </span> | ||
54 | - </h2> | ||
55 | - <p className={`m-0 max-w-[30ch] text-sm opacity-50`}> | ||
56 | - Find in-depth information about Next.js features and API. | ||
57 | - </p> | ||
58 | - </a> | ||
59 | - | ||
60 | - <a | ||
61 | - href="https://nextjs.org/learn?utm_source=create-next-app&utm_medium=appdir-template-tw&utm_campaign=create-next-app" | ||
62 | - className="group rounded-lg border border-transparent px-5 py-4 transition-colors hover:border-gray-300 hover:bg-gray-100 hover:dark:border-neutral-700 hover:dark:bg-neutral-800/30" | ||
63 | - target="_blank" | ||
64 | - rel="noopener noreferrer" | ||
65 | - > | ||
66 | - <h2 className={`mb-3 text-2xl font-semibold`}> | ||
67 | - Learn{' '} | ||
68 | - <span className="inline-block transition-transform group-hover:translate-x-1 motion-reduce:transform-none"> | ||
69 | - -> | ||
70 | - </span> | ||
71 | - </h2> | ||
72 | - <p className={`m-0 max-w-[30ch] text-sm opacity-50`}> | ||
73 | - Learn about Next.js in an interactive course with quizzes! | ||
74 | - </p> | ||
75 | - </a> | ||
76 | - | ||
77 | - <a | ||
78 | - href="https://vercel.com/templates?framework=next.js&utm_source=create-next-app&utm_medium=appdir-template&utm_campaign=create-next-app" | ||
79 | - className="group rounded-lg border border-transparent px-5 py-4 transition-colors hover:border-gray-300 hover:bg-gray-100 hover:dark:border-neutral-700 hover:dark:bg-neutral-800/30" | ||
80 | - target="_blank" | ||
81 | - rel="noopener noreferrer" | ||
82 | - > | ||
83 | - <h2 className={`mb-3 text-2xl font-semibold`}> | ||
84 | - Templates{' '} | ||
85 | - <span className="inline-block transition-transform group-hover:translate-x-1 motion-reduce:transform-none"> | ||
86 | - -> | ||
87 | - </span> | ||
88 | - </h2> | ||
89 | - <p className={`m-0 max-w-[30ch] text-sm opacity-50`}> | ||
90 | - Explore the Next.js 13 playground. | ||
91 | - </p> | ||
92 | - </a> | ||
93 | - | ||
94 | - <a | ||
95 | - href="https://vercel.com/new?utm_source=create-next-app&utm_medium=appdir-template&utm_campaign=create-next-app" | ||
96 | - className="group rounded-lg border border-transparent px-5 py-4 transition-colors hover:border-gray-300 hover:bg-gray-100 hover:dark:border-neutral-700 hover:dark:bg-neutral-800/30" | ||
97 | - target="_blank" | ||
98 | - rel="noopener noreferrer" | ||
99 | - > | ||
100 | - <h2 className={`mb-3 text-2xl font-semibold`}> | ||
101 | - Deploy{' '} | ||
102 | - <span className="inline-block transition-transform group-hover:translate-x-1 motion-reduce:transform-none"> | ||
103 | - -> | ||
104 | - </span> | ||
105 | - </h2> | ||
106 | - <p className={`m-0 max-w-[30ch] text-sm opacity-50`}> | ||
107 | - Instantly deploy your Next.js site to a shareable URL with Vercel. | ||
108 | - </p> | ||
109 | - </a> | ||
110 | - </div> | ||
111 | - </main> | ||
112 | - ) | 5 | + return <Header />; |
113 | } | 6 | } |
src/components/Header/index.tsx
0 → 100644
1 | +'use client'; // This is a client component 👈🏽 | ||
2 | + | ||
3 | +import React, { useState, useEffect } from 'react'; | ||
4 | +import { Button, TextField, Tabs, Tab, Container, Grid } from '@mui/material'; | ||
5 | +import SearchIcon from '@mui/icons-material/Search'; | ||
6 | + | ||
7 | +import { useRouter } from 'next/navigation'; | ||
8 | + | ||
9 | +import Link from 'next/link'; | ||
10 | +import Image from 'next/image'; | ||
11 | + | ||
12 | +// import { useStore } from '../store'; // Adjust the path according to your file structure | ||
13 | +// import ContactDialog from './ContactDialog'; // Adjust the path according to your file structure | ||
14 | + | ||
15 | +function Header() { | ||
16 | + const [input, setInput] = useState(''); | ||
17 | + const [tab, setTab] = useState(0); | ||
18 | + const { | ||
19 | + keyword, | ||
20 | + updateKeyword, | ||
21 | + updateDialogOpen, | ||
22 | + updateDisplay, | ||
23 | + updatePageNo, | ||
24 | + } = {}; | ||
25 | + | ||
26 | + const router = useRouter(); | ||
27 | + | ||
28 | + useEffect(() => { | ||
29 | + setInput(keyword); | ||
30 | + }, [keyword]); | ||
31 | + | ||
32 | + const handleKeyDown = (e) => { | ||
33 | + if (e.keyCode === 13) { | ||
34 | + handleClick(); | ||
35 | + } | ||
36 | + }; | ||
37 | + | ||
38 | + const handleClick = () => { | ||
39 | + updateDisplay(!input); | ||
40 | + updateKeyword(input); | ||
41 | + updatePageNo(1); | ||
42 | + router.push('/products'); | ||
43 | + }; | ||
44 | + | ||
45 | + const handleTabClick = () => { | ||
46 | + updateDisplay(true); | ||
47 | + updateKeyword(''); | ||
48 | + }; | ||
49 | + | ||
50 | + useEffect(() => { | ||
51 | + const currentPath = router.pathname; | ||
52 | + const tabValue = | ||
53 | + currentPath === '/' | ||
54 | + ? 0 | ||
55 | + : currentPath === '/products' | ||
56 | + ? 1 | ||
57 | + : currentPath === '/about' | ||
58 | + ? 2 | ||
59 | + : 0; | ||
60 | + setTab(tabValue); | ||
61 | + }, [router.pathname]); | ||
62 | + | ||
63 | + return ( | ||
64 | + <> | ||
65 | + <Container className="pt-2"> | ||
66 | + <Grid container alignItems="center"> | ||
67 | + <Grid item xs={1} sx={{ p: 0, height: '64px' }}> | ||
68 | + <Link href="/"> | ||
69 | + <Image src="icon/logo.jpg" alt="canrud" width={64} height={64} /> | ||
70 | + </Link> | ||
71 | + </Grid> | ||
72 | + <Grid item xs={6} md={8} sx={{ px: 0 }}> | ||
73 | + <TextField | ||
74 | + label="Search keyword" | ||
75 | + variant="outlined" | ||
76 | + onKeyDown={handleKeyDown} | ||
77 | + value={input} | ||
78 | + onChange={(e) => setInput(e.target.value)} | ||
79 | + append-inner-icon="mdi-magnify" | ||
80 | + InputProps={{ | ||
81 | + endAdornment: <SearchIcon onClick={handleClick} />, | ||
82 | + }} | ||
83 | + fullWidth | ||
84 | + /> | ||
85 | + </Grid> | ||
86 | + <Grid item xs={4} md={2} className="ml-3"> | ||
87 | + <Button color="primary" onClick={() => updateDialogOpen(true)}> | ||
88 | + Contact Us | ||
89 | + </Button> | ||
90 | + </Grid> | ||
91 | + </Grid> | ||
92 | + </Container> | ||
93 | + <Tabs | ||
94 | + value={tab} | ||
95 | + onChange={(e, newVal) => setTab(newVal)} | ||
96 | + textColor="inherit" | ||
97 | + variant="fullWidth" | ||
98 | + className="bg-primary-blue text-white" | ||
99 | + > | ||
100 | + <Tab | ||
101 | + label="Home" | ||
102 | + className="text-grey-lighten-3 tw-font-bold" | ||
103 | + component={Link} | ||
104 | + href="/" | ||
105 | + onClick={handleTabClick} | ||
106 | + /> | ||
107 | + <Tab | ||
108 | + label="Products" | ||
109 | + component={Link} | ||
110 | + href="/products" | ||
111 | + className="text-grey-lighten-3 tw-font-bold" | ||
112 | + onClick={handleTabClick} | ||
113 | + /> | ||
114 | + <Tab | ||
115 | + label="About" | ||
116 | + component={Link} | ||
117 | + href="/about" | ||
118 | + className="text-grey-lighten-3 tw-font-bold" | ||
119 | + onClick={handleTabClick} | ||
120 | + /> | ||
121 | + </Tabs> | ||
122 | + {/* <ContactDialog /> */} | ||
123 | + </> | ||
124 | + ); | ||
125 | +} | ||
126 | + | ||
127 | +export default Header; |
src/store/index.ts
0 → 100644
1 | +// store.js | ||
2 | +import create from 'zustand'; | ||
3 | + | ||
4 | +export const useStore = create((set) => ({ | ||
5 | + keyword: '', | ||
6 | + updateKeyword: (keyword) => set({ keyword }), | ||
7 | + dialogOpen: false, | ||
8 | + updateDialogOpen: (open) => set({ dialogOpen: open }), | ||
9 | + display: true, | ||
10 | + updateDisplay: (display) => set({ display }), | ||
11 | + pageNo: 1, | ||
12 | + updatePageNo: (pageNo) => set({ pageNo }), | ||
13 | +})); |
src/style/theme.js
0 → 100644
tailwind.config.ts
1 | -import type { Config } from 'tailwindcss' | 1 | +import type { Config } from 'tailwindcss'; |
2 | 2 | ||
3 | const config: Config = { | 3 | const config: Config = { |
4 | content: [ | 4 | content: [ |
@@ -13,8 +13,14 @@ const config: Config = { | @@ -13,8 +13,14 @@ const config: Config = { | ||
13 | 'gradient-conic': | 13 | 'gradient-conic': |
14 | 'conic-gradient(from 180deg at 50% 50%, var(--tw-gradient-stops))', | 14 | 'conic-gradient(from 180deg at 50% 50%, var(--tw-gradient-stops))', |
15 | }, | 15 | }, |
16 | + colors: { | ||
17 | + 'primary-blue': '#1f88e5', | ||
18 | + }, | ||
16 | }, | 19 | }, |
17 | }, | 20 | }, |
18 | plugins: [], | 21 | plugins: [], |
19 | -} | ||
20 | -export default config | 22 | + corePlugins: { |
23 | + preflight: false, | ||
24 | + }, | ||
25 | +}; | ||
26 | +export default config; |