From 6f098dc5351d9d62b39b26d7046a062584c3e0e6 Mon Sep 17 00:00:00 2001 From: ABHIRUP Date: Wed, 9 Aug 2023 10:35:41 +0530 Subject: [PATCH] moved assets to static content, added metadata for different pages --- client/app/events/layout.js | 9 ++++ client/app/events/page.js | 2 +- client/app/layout.js | 4 +- client/app/page.js | 2 +- client/app/register/layout.js | 7 ++- client/app/team/layout.js | 9 ++++ client/app/team/page.js | 2 - client/component/Header/index.jsx | 2 +- client/component/Hod/index.jsx | 2 +- client/component/TeamCards/index.jsx | 8 ---- client/component/Teams/index.jsx | 5 +- client/package-lock.json | 43 ++++++++++++++++++ client/package.json | 1 + .../static}/assets/1118134925115466530975.pdf | Bin .../{ => public/static}/assets/Aratrik.webp | Bin client/{ => public/static}/assets/Arnab.webp | Bin .../{ => public/static}/assets/ArnabKr.webp | Bin client/{ => public/static}/assets/Dhriti.webp | Bin .../{ => public/static}/assets/abhraneel.webp | Bin client/{ => public/static}/assets/avatar.png | Bin .../{ => public/static}/assets/cardimg.webp | Bin client/{ => public/static}/assets/data.js | 40 ++++++++-------- .../{ => public/static}/assets/debdeep.webp | Bin .../{ => public/static}/assets/diptanshu.webp | Bin .../{ => public/static}/assets/hod_img.webp | Bin client/{ => public/static}/assets/irshit.webp | Bin .../{ => public/static}/assets/joydeep.webp | Bin client/{ => public/static}/assets/mayukh.webp | Bin .../{ => public/static}/assets/moulendu.webp | Bin .../{ => public/static}/assets/nabajit.webp | Bin .../{ => public/static}/assets/neelakshi.webp | Bin client/{ => public/static}/assets/neogi.webp | Bin client/{ => public/static}/assets/prasun.webp | Bin client/{ => public/static}/assets/prit.webp | Bin client/{ => public/static}/assets/rohitP.webp | Bin client/{ => public/static}/assets/rohitc.webp | Bin client/{ => public/static}/assets/soumit.webp | Bin .../public/{ => static}/fonts/Qaz-ZV74m.ttf | Bin .../{ => static}/fonts/QazItalic-3zyWL.ttf | Bin client/styles/globals.css | 2 +- 40 files changed, 94 insertions(+), 44 deletions(-) create mode 100644 client/app/events/layout.js create mode 100644 client/app/team/layout.js rename client/{ => public/static}/assets/1118134925115466530975.pdf (100%) rename client/{ => public/static}/assets/Aratrik.webp (100%) rename client/{ => public/static}/assets/Arnab.webp (100%) rename client/{ => public/static}/assets/ArnabKr.webp (100%) rename client/{ => public/static}/assets/Dhriti.webp (100%) rename client/{ => public/static}/assets/abhraneel.webp (100%) rename client/{ => public/static}/assets/avatar.png (100%) rename client/{ => public/static}/assets/cardimg.webp (100%) rename client/{ => public/static}/assets/data.js (93%) rename client/{ => public/static}/assets/debdeep.webp (100%) rename client/{ => public/static}/assets/diptanshu.webp (100%) rename client/{ => public/static}/assets/hod_img.webp (100%) rename client/{ => public/static}/assets/irshit.webp (100%) rename client/{ => public/static}/assets/joydeep.webp (100%) rename client/{ => public/static}/assets/mayukh.webp (100%) rename client/{ => public/static}/assets/moulendu.webp (100%) rename client/{ => public/static}/assets/nabajit.webp (100%) rename client/{ => public/static}/assets/neelakshi.webp (100%) rename client/{ => public/static}/assets/neogi.webp (100%) rename client/{ => public/static}/assets/prasun.webp (100%) rename client/{ => public/static}/assets/prit.webp (100%) rename client/{ => public/static}/assets/rohitP.webp (100%) rename client/{ => public/static}/assets/rohitc.webp (100%) rename client/{ => public/static}/assets/soumit.webp (100%) rename client/public/{ => static}/fonts/Qaz-ZV74m.ttf (100%) rename client/public/{ => static}/fonts/QazItalic-3zyWL.ttf (100%) diff --git a/client/app/events/layout.js b/client/app/events/layout.js new file mode 100644 index 0000000..a1853d6 --- /dev/null +++ b/client/app/events/layout.js @@ -0,0 +1,9 @@ +import '../../styles/globals.css'; +export const metadata = { + title: 'Events', + description: "Students' Chapter CSE events" +} + +export default function Layout({ children }) { + return
{children}
; +} \ No newline at end of file diff --git a/client/app/events/page.js b/client/app/events/page.js index 981aa73..b69151f 100644 --- a/client/app/events/page.js +++ b/client/app/events/page.js @@ -3,7 +3,7 @@ import styles from '../../styles/Event.module.css'; import Event from '../../component/Event'; -import { eventsData } from '../../assets/data'; +import { eventsData } from '../../public/static/assets/data'; const events = () => { return ( <> diff --git a/client/app/layout.js b/client/app/layout.js index 6a9e6a6..38b52cf 100644 --- a/client/app/layout.js +++ b/client/app/layout.js @@ -1,8 +1,8 @@ import { LayoutProvider } from '../component/LayoutProvider'; export const metadata = { - title: 'Next.js', - description: 'Generated by Next.js', + title: "Students' Chapter CSE", + description: "The ofiicial website of IEI Students' Chapter CSE", }; export default function RootLayout({ children }) { diff --git a/client/app/page.js b/client/app/page.js index 9bec324..2d4ce26 100644 --- a/client/app/page.js +++ b/client/app/page.js @@ -2,7 +2,7 @@ import { lazy, Suspense } from 'react'; import styles from '../styles/Home.module.css'; -import { upcomingEvents } from '../assets/data'; +import { upcomingEvents } from '../public/static/assets/data'; import Loading from './loading'; import About from '../component/About'; import Counter from '../component/Counter'; diff --git a/client/app/register/layout.js b/client/app/register/layout.js index 7615c5b..2da76b7 100644 --- a/client/app/register/layout.js +++ b/client/app/register/layout.js @@ -1,10 +1,9 @@ import '../../styles/globals.css'; -import styles from '../../styles/Home.module.css'; export const metadata = { - title: 'Next.js', - description: 'Generated by Next.js', + title: 'Register', + description: 'Register to become a Member', }; export default function Layout({ children }) { - return
{children}
; + return
{children}
; } diff --git a/client/app/team/layout.js b/client/app/team/layout.js new file mode 100644 index 0000000..b5015dc --- /dev/null +++ b/client/app/team/layout.js @@ -0,0 +1,9 @@ +import '../../styles/globals.css'; +export const metadata = { + title: 'Teams', + description: "Team of Students' Chapter CSE" +} + +export default function Layout({ children }) { + return
{children}
; +} \ No newline at end of file diff --git a/client/app/team/page.js b/client/app/team/page.js index e7f8e0c..b40b5e1 100644 --- a/client/app/team/page.js +++ b/client/app/team/page.js @@ -1,8 +1,6 @@ 'use client'; -import Navbar from '../../component/Navbar'; import Teams from '../../component/Teams'; - import Footer from '../../component/Footer'; const team = () => { diff --git a/client/component/Header/index.jsx b/client/component/Header/index.jsx index 65bfb3f..77ae717 100644 --- a/client/component/Header/index.jsx +++ b/client/component/Header/index.jsx @@ -1,5 +1,5 @@ import styles from '../../styles/Header.module.css'; -import CardImg from '../../assets/cardimg.webp'; +import CardImg from '../../public/static/assets/cardimg.webp'; import Image from 'next/image'; import { useTypewriter, Cursor } from 'react-simple-typewriter' diff --git a/client/component/Hod/index.jsx b/client/component/Hod/index.jsx index 2285d56..e53a526 100644 --- a/client/component/Hod/index.jsx +++ b/client/component/Hod/index.jsx @@ -1,6 +1,6 @@ import styles from '../../styles/Hod.module.css'; import Image from 'next/image'; -import Avatar from '../../assets/hod_img.webp' +import Avatar from '../../public/static/assets/hod_img.webp' const Hod = () => { return ( diff --git a/client/component/TeamCards/index.jsx b/client/component/TeamCards/index.jsx index d21073f..9691f12 100644 --- a/client/component/TeamCards/index.jsx +++ b/client/component/TeamCards/index.jsx @@ -37,14 +37,6 @@ export default function TeamCards({ img, name, desg, socials }) { - {/*
-
-
- -
-
example@gmail.com
-
-
*/} diff --git a/client/component/Teams/index.jsx b/client/component/Teams/index.jsx index fe1155c..573776d 100644 --- a/client/component/Teams/index.jsx +++ b/client/component/Teams/index.jsx @@ -1,9 +1,8 @@ import styles from '../../styles/Team.module.css'; import TeamCards from '../TeamCards'; -import { teams } from '../../assets/data'; -import { lazy, Suspense } from 'react'; +import { teams } from '../../public/static/assets/data'; import { forwardRef } from 'react'; -const Footer = lazy(() => import('../Footer/index')) + export default function Teams() { return ( diff --git a/client/package-lock.json b/client/package-lock.json index 93796a3..c59c5dd 100644 --- a/client/package-lock.json +++ b/client/package-lock.json @@ -18,6 +18,7 @@ "react-dom": "18.2.0", "react-hook-form": "^7.45.4", "react-icons": "^4.10.1", + "react-lazy-load-image-component": "^1.6.0", "react-simple-typewriter": "^5.0.1" }, "devDependencies": { @@ -3742,6 +3743,11 @@ "integrity": "sha512-v2kDEe57lecTulaDIuNTPy3Ry4gLGJ6Z1O3vE1krgXZNrsQ+LFTGHVxVjcXPs17LhbZVGedAJv8XZ1tvj5FvSg==", "dev": true }, + "node_modules/lodash.debounce": { + "version": "4.0.8", + "resolved": "https://registry.npmjs.org/lodash.debounce/-/lodash.debounce-4.0.8.tgz", + "integrity": "sha512-FT1yDzDYEoYWhnSGnpE/4Kj1fLZkDFyqRb7fNt6FdYOSxlUWAtp42Eh6Wb0rGIv/m9Bgo7x4GhQbm5Ys4SG5ow==" + }, "node_modules/lodash.merge": { "version": "4.6.2", "resolved": "https://registry.npmjs.org/lodash.merge/-/lodash.merge-4.6.2.tgz", @@ -3753,6 +3759,11 @@ "integrity": "sha512-Sb487aTOCr9drQVL8pIxOzVhafOjZN9UU54hiN8PU3uAiSV7lx1yYNpbNmex2PK6dSJoNTSJUUswT651yww3Mg==", "dev": true }, + "node_modules/lodash.throttle": { + "version": "4.1.1", + "resolved": "https://registry.npmjs.org/lodash.throttle/-/lodash.throttle-4.1.1.tgz", + "integrity": "sha512-wIkUCfVKpVsWo3JSZlc+8MB5it+2AN5W8J7YVMST30UrvcQNZ1Okbj+rbVniijTWE6FGYy4XJq/rHkas8qJMLQ==" + }, "node_modules/log-symbols": { "version": "4.1.0", "resolved": "https://registry.npmjs.org/log-symbols/-/log-symbols-4.1.0.tgz", @@ -4526,6 +4537,19 @@ "resolved": "https://registry.npmjs.org/react-is/-/react-is-16.13.1.tgz", "integrity": "sha512-24e6ynE2H+OKt4kqsOvNd8kBpV65zoxbA4BVsEOB3ARVWQki/DHzaUoC5KuON/BiccDaCCTZBuOcfZs70kR8bQ==" }, + "node_modules/react-lazy-load-image-component": { + "version": "1.6.0", + "resolved": "https://registry.npmjs.org/react-lazy-load-image-component/-/react-lazy-load-image-component-1.6.0.tgz", + "integrity": "sha512-8KFkDTgjh+0+PVbH+cx0AgxLGbdTsxWMnxXzU5HEUztqewk9ufQAu8cstjZhyvtMIPsdMcPZfA0WAa7HtjQbBQ==", + "dependencies": { + "lodash.debounce": "^4.0.8", + "lodash.throttle": "^4.1.1" + }, + "peerDependencies": { + "react": "^15.x.x || ^16.x.x || ^17.x.x || ^18.x.x", + "react-dom": "^15.x.x || ^16.x.x || ^17.x.x || ^18.x.x" + } + }, "node_modules/react-simple-typewriter": { "version": "5.0.1", "resolved": "https://registry.npmjs.org/react-simple-typewriter/-/react-simple-typewriter-5.0.1.tgz", @@ -8398,6 +8422,11 @@ "integrity": "sha512-v2kDEe57lecTulaDIuNTPy3Ry4gLGJ6Z1O3vE1krgXZNrsQ+LFTGHVxVjcXPs17LhbZVGedAJv8XZ1tvj5FvSg==", "dev": true }, + "lodash.debounce": { + "version": "4.0.8", + "resolved": "https://registry.npmjs.org/lodash.debounce/-/lodash.debounce-4.0.8.tgz", + "integrity": "sha512-FT1yDzDYEoYWhnSGnpE/4Kj1fLZkDFyqRb7fNt6FdYOSxlUWAtp42Eh6Wb0rGIv/m9Bgo7x4GhQbm5Ys4SG5ow==" + }, "lodash.merge": { "version": "4.6.2", "resolved": "https://registry.npmjs.org/lodash.merge/-/lodash.merge-4.6.2.tgz", @@ -8409,6 +8438,11 @@ "integrity": "sha512-Sb487aTOCr9drQVL8pIxOzVhafOjZN9UU54hiN8PU3uAiSV7lx1yYNpbNmex2PK6dSJoNTSJUUswT651yww3Mg==", "dev": true }, + "lodash.throttle": { + "version": "4.1.1", + "resolved": "https://registry.npmjs.org/lodash.throttle/-/lodash.throttle-4.1.1.tgz", + "integrity": "sha512-wIkUCfVKpVsWo3JSZlc+8MB5it+2AN5W8J7YVMST30UrvcQNZ1Okbj+rbVniijTWE6FGYy4XJq/rHkas8qJMLQ==" + }, "log-symbols": { "version": "4.1.0", "resolved": "https://registry.npmjs.org/log-symbols/-/log-symbols-4.1.0.tgz", @@ -8931,6 +8965,15 @@ "resolved": "https://registry.npmjs.org/react-is/-/react-is-16.13.1.tgz", "integrity": "sha512-24e6ynE2H+OKt4kqsOvNd8kBpV65zoxbA4BVsEOB3ARVWQki/DHzaUoC5KuON/BiccDaCCTZBuOcfZs70kR8bQ==" }, + "react-lazy-load-image-component": { + "version": "1.6.0", + "resolved": "https://registry.npmjs.org/react-lazy-load-image-component/-/react-lazy-load-image-component-1.6.0.tgz", + "integrity": "sha512-8KFkDTgjh+0+PVbH+cx0AgxLGbdTsxWMnxXzU5HEUztqewk9ufQAu8cstjZhyvtMIPsdMcPZfA0WAa7HtjQbBQ==", + "requires": { + "lodash.debounce": "^4.0.8", + "lodash.throttle": "^4.1.1" + } + }, "react-simple-typewriter": { "version": "5.0.1", "resolved": "https://registry.npmjs.org/react-simple-typewriter/-/react-simple-typewriter-5.0.1.tgz", diff --git a/client/package.json b/client/package.json index 1e0eae6..dd855b6 100644 --- a/client/package.json +++ b/client/package.json @@ -22,6 +22,7 @@ "react-dom": "18.2.0", "react-hook-form": "^7.45.4", "react-icons": "^4.10.1", + "react-lazy-load-image-component": "^1.6.0", "react-simple-typewriter": "^5.0.1" }, "devDependencies": { diff --git a/client/assets/1118134925115466530975.pdf b/client/public/static/assets/1118134925115466530975.pdf similarity index 100% rename from client/assets/1118134925115466530975.pdf rename to client/public/static/assets/1118134925115466530975.pdf diff --git a/client/assets/Aratrik.webp b/client/public/static/assets/Aratrik.webp similarity index 100% rename from client/assets/Aratrik.webp rename to client/public/static/assets/Aratrik.webp diff --git a/client/assets/Arnab.webp b/client/public/static/assets/Arnab.webp similarity index 100% rename from client/assets/Arnab.webp rename to client/public/static/assets/Arnab.webp diff --git a/client/assets/ArnabKr.webp b/client/public/static/assets/ArnabKr.webp similarity index 100% rename from client/assets/ArnabKr.webp rename to client/public/static/assets/ArnabKr.webp diff --git a/client/assets/Dhriti.webp b/client/public/static/assets/Dhriti.webp similarity index 100% rename from client/assets/Dhriti.webp rename to client/public/static/assets/Dhriti.webp diff --git a/client/assets/abhraneel.webp b/client/public/static/assets/abhraneel.webp similarity index 100% rename from client/assets/abhraneel.webp rename to client/public/static/assets/abhraneel.webp diff --git a/client/assets/avatar.png b/client/public/static/assets/avatar.png similarity index 100% rename from client/assets/avatar.png rename to client/public/static/assets/avatar.png diff --git a/client/assets/cardimg.webp b/client/public/static/assets/cardimg.webp similarity index 100% rename from client/assets/cardimg.webp rename to client/public/static/assets/cardimg.webp diff --git a/client/assets/data.js b/client/public/static/assets/data.js similarity index 93% rename from client/assets/data.js rename to client/public/static/assets/data.js index b4de9c6..5a06291 100644 --- a/client/assets/data.js +++ b/client/public/static/assets/data.js @@ -1,23 +1,23 @@ -import avatar from '../assets/avatar.png'; -import Bishakh from '../assets/neogi.webp'; -import Irshit from '../assets/irshit.webp'; -import Soumit from '../assets/soumit.webp'; -import Abhraneel from '../assets/abhraneel.webp'; -import Prasun from '../assets/prasun.webp'; -import Mayukh from '../assets/mayukh.webp'; -import Neelakshi from '../assets/neelakshi.webp'; -import RohitC from '../assets/rohitc.webp'; -import Moulendu from '../assets/moulendu.webp'; -import ArnabKr from '../assets/ArnabKr.webp'; -import Nabajit from '../assets/nabajit.webp'; -import Aratrik from '../assets/Aratrik.webp'; -import Arnab from '../assets/Arnab.webp'; -import pritanshu from '../assets/prit.webp'; -import joydeep from '../assets/joydeep.webp'; -import dhriti from '../assets/Dhriti.webp'; -import rohitp from '../assets/rohitP.webp'; -import diptanshu from '../assets/diptanshu.webp'; -import debdeep from '../assets/debdeep.webp'; +import avatar from './avatar.png'; +import Bishakh from './neogi.webp'; +import Irshit from './irshit.webp'; +import Soumit from './soumit.webp'; +import Abhraneel from './abhraneel.webp'; +import Prasun from './prasun.webp'; +import Mayukh from './mayukh.webp'; +import Neelakshi from './neelakshi.webp'; +import RohitC from './rohitc.webp'; +import Moulendu from './moulendu.webp'; +import ArnabKr from './ArnabKr.webp'; +import Nabajit from './nabajit.webp'; +import Aratrik from './Aratrik.webp'; +import Arnab from './Arnab.webp'; +import pritanshu from './prit.webp'; +import joydeep from './joydeep.webp'; +import dhriti from './Dhriti.webp'; +import rohitp from './rohitP.webp'; +import diptanshu from './diptanshu.webp'; +import debdeep from './debdeep.webp'; export const testimonialCards = [ { diff --git a/client/assets/debdeep.webp b/client/public/static/assets/debdeep.webp similarity index 100% rename from client/assets/debdeep.webp rename to client/public/static/assets/debdeep.webp diff --git a/client/assets/diptanshu.webp b/client/public/static/assets/diptanshu.webp similarity index 100% rename from client/assets/diptanshu.webp rename to client/public/static/assets/diptanshu.webp diff --git a/client/assets/hod_img.webp b/client/public/static/assets/hod_img.webp similarity index 100% rename from client/assets/hod_img.webp rename to client/public/static/assets/hod_img.webp diff --git a/client/assets/irshit.webp b/client/public/static/assets/irshit.webp similarity index 100% rename from client/assets/irshit.webp rename to client/public/static/assets/irshit.webp diff --git a/client/assets/joydeep.webp b/client/public/static/assets/joydeep.webp similarity index 100% rename from client/assets/joydeep.webp rename to client/public/static/assets/joydeep.webp diff --git a/client/assets/mayukh.webp b/client/public/static/assets/mayukh.webp similarity index 100% rename from client/assets/mayukh.webp rename to client/public/static/assets/mayukh.webp diff --git a/client/assets/moulendu.webp b/client/public/static/assets/moulendu.webp similarity index 100% rename from client/assets/moulendu.webp rename to client/public/static/assets/moulendu.webp diff --git a/client/assets/nabajit.webp b/client/public/static/assets/nabajit.webp similarity index 100% rename from client/assets/nabajit.webp rename to client/public/static/assets/nabajit.webp diff --git a/client/assets/neelakshi.webp b/client/public/static/assets/neelakshi.webp similarity index 100% rename from client/assets/neelakshi.webp rename to client/public/static/assets/neelakshi.webp diff --git a/client/assets/neogi.webp b/client/public/static/assets/neogi.webp similarity index 100% rename from client/assets/neogi.webp rename to client/public/static/assets/neogi.webp diff --git a/client/assets/prasun.webp b/client/public/static/assets/prasun.webp similarity index 100% rename from client/assets/prasun.webp rename to client/public/static/assets/prasun.webp diff --git a/client/assets/prit.webp b/client/public/static/assets/prit.webp similarity index 100% rename from client/assets/prit.webp rename to client/public/static/assets/prit.webp diff --git a/client/assets/rohitP.webp b/client/public/static/assets/rohitP.webp similarity index 100% rename from client/assets/rohitP.webp rename to client/public/static/assets/rohitP.webp diff --git a/client/assets/rohitc.webp b/client/public/static/assets/rohitc.webp similarity index 100% rename from client/assets/rohitc.webp rename to client/public/static/assets/rohitc.webp diff --git a/client/assets/soumit.webp b/client/public/static/assets/soumit.webp similarity index 100% rename from client/assets/soumit.webp rename to client/public/static/assets/soumit.webp diff --git a/client/public/fonts/Qaz-ZV74m.ttf b/client/public/static/fonts/Qaz-ZV74m.ttf similarity index 100% rename from client/public/fonts/Qaz-ZV74m.ttf rename to client/public/static/fonts/Qaz-ZV74m.ttf diff --git a/client/public/fonts/QazItalic-3zyWL.ttf b/client/public/static/fonts/QazItalic-3zyWL.ttf similarity index 100% rename from client/public/fonts/QazItalic-3zyWL.ttf rename to client/public/static/fonts/QazItalic-3zyWL.ttf diff --git a/client/styles/globals.css b/client/styles/globals.css index 0d39d33..aca83cc 100644 --- a/client/styles/globals.css +++ b/client/styles/globals.css @@ -41,7 +41,7 @@ a { @font-face { font-family: 'quaz'; - src: url('/fonts/Qaz-ZV74m.ttf'); + src: url('/static/fonts/Qaz-ZV74m.ttf'); font-display: swap; }