├── .gitignore ├── assets ├── icons │ ├── delete.png │ ├── down.png │ ├── info.png │ ├── add_Icon.png │ ├── approve.png │ ├── closeBtn.png │ ├── editIcon.png │ ├── homeIcon.png │ ├── ideaIcon.png │ ├── likeIcon.png │ ├── moreIcon.png │ ├── sendIcon.png │ ├── sendPost.png │ ├── dslr-camera.png │ ├── home_Icon.png │ ├── myPostIcon.png │ ├── searchIcon.png │ ├── search_Icon.png │ ├── approve-dark.png │ ├── birthDayIcon.png │ ├── bookmark_Icon.png │ ├── decline_dark.png │ ├── profilePicReg.png │ ├── notificationIcon.png │ ├── reloadNotification.png │ ├── notificationIcon │ │ ├── approved.png │ │ ├── deleted.png │ │ ├── inspiration.png │ │ └── system_update.png │ └── readmeIcon │ │ └── SE10-Readme-Logo.png ├── image │ ├── 550px.png │ ├── 950px.png │ ├── SE10.png │ ├── back.png │ ├── cover.jpeg │ ├── dots.png │ ├── image.png │ ├── CoverPic.png │ ├── mobilebg.png │ ├── profilePic.png │ ├── profileBanner.png │ ├── Learn by Doing.png │ ├── defaultprofile.jpg │ ├── registrationBg.png │ ├── Error404pageImage.png │ ├── cover-background.jpeg │ ├── defaultProfileImage.png │ ├── registrationMobileBg.png │ ├── pikaso_texttoimage_adorable-cartoon-style-A-smiling-sloth-with-large-.jpeg │ └── serene-sloth-hangs-leisurely-amongst-green-leaves-eyes-closed-contentment 3.png ├── css │ ├── styles.css │ ├── postMoreOptionsPopUp.css │ ├── notificationPageMobile.css │ ├── searchPopup.css │ ├── birthdayPopup.css │ ├── error404Page.css │ ├── birthdayPageMobile.css │ ├── SearchPageMobile.css │ ├── postInfoPopup.css │ ├── deleteConfirmationPopup.css │ └── homePage.css └── tostify │ ├── toastify.min.css │ └── toastify-js.js ├── components ├── css │ ├── wall │ │ ├── HomeWallComponent.css │ │ └── MyPostWallComponent.css │ ├── PostCardComponent.css │ ├── AdminApprovePostCardComponent.css │ └── CreatePostCardComponent.css ├── pages │ └── wall │ │ ├── adminApproveWallComponent.html │ │ ├── myFriendPostWallComponent.html │ │ ├── homeWallComponent.html │ │ └── myPostWallComponent.html └── js │ └── wall │ └── AdminApproveWallComponent.js ├── controller ├── AdminApprovePageMobileController.js ├── BirthdaysPageMobileController.js ├── ForgotPasswordFormController.js ├── NotificationPageMobileController.js ├── LoginPageController.js ├── forgotPasswordOtpVerifyPageController.js ├── RegistrationFormController.js ├── RegistrationOtpVerifyPageController.js ├── SearchPageMobileController.js ├── Registrationform2Controller.js └── SearchPopupController.js ├── model ├── VerificationFormModel.js ├── LoginFormModel.js ├── SearchPopupModel.js ├── RegistrationFormModel.js ├── NotificationModel.js ├── InspireModel.js ├── HomePageModel.js ├── UserProfileModel.js └── PostCardModel.js ├── LICENSE ├── pages ├── searchPageMobile.html ├── birthdayPageMobile.html ├── notificationPageMobile.html ├── error404Page.html ├── adminApprovePageMobile.html ├── registrationOtpVerifyPage.html ├── forgotPasswordOtpVerifyPage.html ├── forgotPasswordForm.html ├── mobileHomePage.html ├── registrationForm.html ├── registrationForm2.html └── homePage.html ├── CODE_OF_CONDUCT.md ├── index.html └── README.md /.gitignore: -------------------------------------------------------------------------------- 1 | /.idea/ 2 | /.vscode/ 3 | -------------------------------------------------------------------------------- /assets/icons/delete.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SE10-IJSE/SE10-NETWORK-FRONTEND/HEAD/assets/icons/delete.png -------------------------------------------------------------------------------- /assets/icons/down.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SE10-IJSE/SE10-NETWORK-FRONTEND/HEAD/assets/icons/down.png -------------------------------------------------------------------------------- /assets/icons/info.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SE10-IJSE/SE10-NETWORK-FRONTEND/HEAD/assets/icons/info.png -------------------------------------------------------------------------------- /assets/image/550px.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SE10-IJSE/SE10-NETWORK-FRONTEND/HEAD/assets/image/550px.png -------------------------------------------------------------------------------- /assets/image/950px.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SE10-IJSE/SE10-NETWORK-FRONTEND/HEAD/assets/image/950px.png -------------------------------------------------------------------------------- /assets/image/SE10.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SE10-IJSE/SE10-NETWORK-FRONTEND/HEAD/assets/image/SE10.png -------------------------------------------------------------------------------- /assets/image/back.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SE10-IJSE/SE10-NETWORK-FRONTEND/HEAD/assets/image/back.png -------------------------------------------------------------------------------- /assets/image/cover.jpeg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SE10-IJSE/SE10-NETWORK-FRONTEND/HEAD/assets/image/cover.jpeg -------------------------------------------------------------------------------- /assets/image/dots.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SE10-IJSE/SE10-NETWORK-FRONTEND/HEAD/assets/image/dots.png -------------------------------------------------------------------------------- /assets/image/image.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SE10-IJSE/SE10-NETWORK-FRONTEND/HEAD/assets/image/image.png -------------------------------------------------------------------------------- /assets/icons/add_Icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SE10-IJSE/SE10-NETWORK-FRONTEND/HEAD/assets/icons/add_Icon.png -------------------------------------------------------------------------------- /assets/icons/approve.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SE10-IJSE/SE10-NETWORK-FRONTEND/HEAD/assets/icons/approve.png -------------------------------------------------------------------------------- /assets/icons/closeBtn.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SE10-IJSE/SE10-NETWORK-FRONTEND/HEAD/assets/icons/closeBtn.png -------------------------------------------------------------------------------- /assets/icons/editIcon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SE10-IJSE/SE10-NETWORK-FRONTEND/HEAD/assets/icons/editIcon.png -------------------------------------------------------------------------------- /assets/icons/homeIcon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SE10-IJSE/SE10-NETWORK-FRONTEND/HEAD/assets/icons/homeIcon.png -------------------------------------------------------------------------------- /assets/icons/ideaIcon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SE10-IJSE/SE10-NETWORK-FRONTEND/HEAD/assets/icons/ideaIcon.png -------------------------------------------------------------------------------- /assets/icons/likeIcon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SE10-IJSE/SE10-NETWORK-FRONTEND/HEAD/assets/icons/likeIcon.png -------------------------------------------------------------------------------- /assets/icons/moreIcon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SE10-IJSE/SE10-NETWORK-FRONTEND/HEAD/assets/icons/moreIcon.png -------------------------------------------------------------------------------- /assets/icons/sendIcon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SE10-IJSE/SE10-NETWORK-FRONTEND/HEAD/assets/icons/sendIcon.png -------------------------------------------------------------------------------- /assets/icons/sendPost.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SE10-IJSE/SE10-NETWORK-FRONTEND/HEAD/assets/icons/sendPost.png -------------------------------------------------------------------------------- /assets/image/CoverPic.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SE10-IJSE/SE10-NETWORK-FRONTEND/HEAD/assets/image/CoverPic.png -------------------------------------------------------------------------------- /assets/image/mobilebg.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SE10-IJSE/SE10-NETWORK-FRONTEND/HEAD/assets/image/mobilebg.png -------------------------------------------------------------------------------- /assets/icons/dslr-camera.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SE10-IJSE/SE10-NETWORK-FRONTEND/HEAD/assets/icons/dslr-camera.png -------------------------------------------------------------------------------- /assets/icons/home_Icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SE10-IJSE/SE10-NETWORK-FRONTEND/HEAD/assets/icons/home_Icon.png -------------------------------------------------------------------------------- /assets/icons/myPostIcon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SE10-IJSE/SE10-NETWORK-FRONTEND/HEAD/assets/icons/myPostIcon.png -------------------------------------------------------------------------------- /assets/icons/searchIcon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SE10-IJSE/SE10-NETWORK-FRONTEND/HEAD/assets/icons/searchIcon.png -------------------------------------------------------------------------------- /assets/icons/search_Icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SE10-IJSE/SE10-NETWORK-FRONTEND/HEAD/assets/icons/search_Icon.png -------------------------------------------------------------------------------- /assets/image/profilePic.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SE10-IJSE/SE10-NETWORK-FRONTEND/HEAD/assets/image/profilePic.png -------------------------------------------------------------------------------- /assets/icons/approve-dark.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SE10-IJSE/SE10-NETWORK-FRONTEND/HEAD/assets/icons/approve-dark.png -------------------------------------------------------------------------------- /assets/icons/birthDayIcon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SE10-IJSE/SE10-NETWORK-FRONTEND/HEAD/assets/icons/birthDayIcon.png -------------------------------------------------------------------------------- /assets/icons/bookmark_Icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SE10-IJSE/SE10-NETWORK-FRONTEND/HEAD/assets/icons/bookmark_Icon.png -------------------------------------------------------------------------------- /assets/icons/decline_dark.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SE10-IJSE/SE10-NETWORK-FRONTEND/HEAD/assets/icons/decline_dark.png -------------------------------------------------------------------------------- /assets/icons/profilePicReg.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SE10-IJSE/SE10-NETWORK-FRONTEND/HEAD/assets/icons/profilePicReg.png -------------------------------------------------------------------------------- /assets/image/profileBanner.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SE10-IJSE/SE10-NETWORK-FRONTEND/HEAD/assets/image/profileBanner.png -------------------------------------------------------------------------------- /assets/icons/notificationIcon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SE10-IJSE/SE10-NETWORK-FRONTEND/HEAD/assets/icons/notificationIcon.png -------------------------------------------------------------------------------- /assets/image/Learn by Doing.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SE10-IJSE/SE10-NETWORK-FRONTEND/HEAD/assets/image/Learn by Doing.png -------------------------------------------------------------------------------- /assets/image/defaultprofile.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SE10-IJSE/SE10-NETWORK-FRONTEND/HEAD/assets/image/defaultprofile.jpg -------------------------------------------------------------------------------- /assets/image/registrationBg.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SE10-IJSE/SE10-NETWORK-FRONTEND/HEAD/assets/image/registrationBg.png -------------------------------------------------------------------------------- /assets/icons/reloadNotification.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SE10-IJSE/SE10-NETWORK-FRONTEND/HEAD/assets/icons/reloadNotification.png -------------------------------------------------------------------------------- /assets/image/Error404pageImage.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SE10-IJSE/SE10-NETWORK-FRONTEND/HEAD/assets/image/Error404pageImage.png -------------------------------------------------------------------------------- /assets/image/cover-background.jpeg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SE10-IJSE/SE10-NETWORK-FRONTEND/HEAD/assets/image/cover-background.jpeg -------------------------------------------------------------------------------- /assets/image/defaultProfileImage.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SE10-IJSE/SE10-NETWORK-FRONTEND/HEAD/assets/image/defaultProfileImage.png -------------------------------------------------------------------------------- /assets/image/registrationMobileBg.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SE10-IJSE/SE10-NETWORK-FRONTEND/HEAD/assets/image/registrationMobileBg.png -------------------------------------------------------------------------------- /assets/icons/notificationIcon/approved.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SE10-IJSE/SE10-NETWORK-FRONTEND/HEAD/assets/icons/notificationIcon/approved.png -------------------------------------------------------------------------------- /assets/icons/notificationIcon/deleted.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SE10-IJSE/SE10-NETWORK-FRONTEND/HEAD/assets/icons/notificationIcon/deleted.png -------------------------------------------------------------------------------- /assets/icons/notificationIcon/inspiration.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SE10-IJSE/SE10-NETWORK-FRONTEND/HEAD/assets/icons/notificationIcon/inspiration.png -------------------------------------------------------------------------------- /assets/icons/readmeIcon/SE10-Readme-Logo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SE10-IJSE/SE10-NETWORK-FRONTEND/HEAD/assets/icons/readmeIcon/SE10-Readme-Logo.png -------------------------------------------------------------------------------- /assets/icons/notificationIcon/system_update.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SE10-IJSE/SE10-NETWORK-FRONTEND/HEAD/assets/icons/notificationIcon/system_update.png -------------------------------------------------------------------------------- /assets/image/pikaso_texttoimage_adorable-cartoon-style-A-smiling-sloth-with-large-.jpeg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SE10-IJSE/SE10-NETWORK-FRONTEND/HEAD/assets/image/pikaso_texttoimage_adorable-cartoon-style-A-smiling-sloth-with-large-.jpeg -------------------------------------------------------------------------------- /assets/image/serene-sloth-hangs-leisurely-amongst-green-leaves-eyes-closed-contentment 3.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SE10-IJSE/SE10-NETWORK-FRONTEND/HEAD/assets/image/serene-sloth-hangs-leisurely-amongst-green-leaves-eyes-closed-contentment 3.png -------------------------------------------------------------------------------- /components/css/wall/HomeWallComponent.css: -------------------------------------------------------------------------------- 1 | #FormSwitch h1 { 2 | font-size: 24px; 3 | font-family: "Poppins", sans-serif; 4 | font-weight: 700; 5 | } 6 | 7 | #FormSwitch h2 { 8 | font-size: 13px; 9 | font-family: "Poppins", sans-serif; 10 | font-weight: 700; 11 | color: #948e8e; 12 | } 13 | -------------------------------------------------------------------------------- /controller/AdminApprovePageMobileController.js: -------------------------------------------------------------------------------- 1 | $(document).on("click", "#FormSwitch h2", function () { 2 | const subtitleText = $(this).text().trim(); 3 | 4 | if (subtitleText === "Approve") { 5 | $(parent.document) 6 | .find("#homePage .homeWallComponent iframe") 7 | .attr("src", "/pages/adminApprovePageMobile.html"); 8 | } else { 9 | $(parent.document) 10 | .find("#homePage .homeWallComponent iframe") 11 | .attr("src", "mobileHomePage.html"); 12 | } 13 | }); 14 | -------------------------------------------------------------------------------- /assets/css/styles.css: -------------------------------------------------------------------------------- 1 | @import url("https://fonts.googleapis.com/css2?family=Poppins:ital,wght@0,100;0,200;0,300;0,400;0,500;0,600;0,700;0,800;0,900;1,100;1,200;1,300;1,400;1,500;1,600;1,700;1,800;1,900&display=swap"); 2 | 3 | * { 4 | margin: 0; 5 | padding: 0; 6 | box-sizing: border-box; 7 | text-decoration: none; 8 | } 9 | 10 | :root { 11 | --bg-color: #fffafa; 12 | --text-color: #000; 13 | --second-bg-color: #f1eded; 14 | --btn-bg-color: #ea1717; 15 | --btn-hover-color: #c00707; 16 | } 17 | -------------------------------------------------------------------------------- /model/VerificationFormModel.js: -------------------------------------------------------------------------------- 1 | export const postDataForOtp = (name, email) => { 2 | let config = { 3 | method: "post", 4 | maxBodyLength: Infinity, 5 | url: `http://localhost:8080/api/v1/auth/request_otp?name=${name}&email=${email}`, 6 | }; 7 | 8 | return axios(config) 9 | .then((response) => { 10 | console.log("Otp sent successfully:", response.status); 11 | return response; 12 | }) 13 | .catch((error) => { 14 | console.error("Otp sent failed:", error); 15 | throw error; 16 | }); 17 | }; 18 | -------------------------------------------------------------------------------- /model/LoginFormModel.js: -------------------------------------------------------------------------------- 1 | export const postLoginData = (data) => { 2 | let config = { 3 | method: "post", 4 | maxBodyLength: Infinity, 5 | url: `http://localhost:8080/api/v1/auth/sign_in`, 6 | headers: { 7 | "Content-Type": "application/json", 8 | }, 9 | data: JSON.stringify(data), 10 | }; 11 | 12 | return axios(config) 13 | .then((response) => { 14 | console.log("Login successful:", response.status); 15 | return response; 16 | }) 17 | .catch((error) => { 18 | console.error("Login failed:", error); 19 | throw error; 20 | }); 21 | }; 22 | -------------------------------------------------------------------------------- /model/SearchPopupModel.js: -------------------------------------------------------------------------------- 1 | export const searchUsers = (searchTerm, pageNo) => { 2 | let config = { 3 | method: "get", 4 | maxBodyLength: Infinity, 5 | url: `http://localhost:8080/api/v1/user/search?name=${searchTerm}&pageNo=${pageNo}`, 6 | headers: { 7 | "Content-Type": "application/json", 8 | }, 9 | }; 10 | 11 | return axios(config) 12 | .then((response) => { 13 | console.log("Search successful:", response.status); 14 | return response.data; 15 | }) 16 | .catch((error) => { 17 | console.error("Search failed:", error); 18 | throw error; 19 | }); 20 | }; 21 | -------------------------------------------------------------------------------- /model/RegistrationFormModel.js: -------------------------------------------------------------------------------- 1 | export const postRegisterData = (formDataToSend) => { 2 | let config = { 3 | method: "post", 4 | maxBodyLength: Infinity, 5 | url: `http://localhost:8080/api/v1/auth/sign_up`, 6 | data: formDataToSend, 7 | headers: { 8 | "Content-Type": "multipart/form-data", 9 | }, 10 | }; 11 | 12 | return axios(config) 13 | .then((response) => { 14 | console.log("Registration successful:", response.status); 15 | return response; 16 | }) 17 | .catch((error) => { 18 | console.error("Registration failed:", error); 19 | throw error; 20 | }); 21 | }; 22 | -------------------------------------------------------------------------------- /assets/css/postMoreOptionsPopUp.css: -------------------------------------------------------------------------------- 1 | .list-group { 2 | width: 130px; 3 | border-radius: 5px; 4 | border: 1px solid #f4f4f4; 5 | color: #ffffff; 6 | position: absolute; 7 | right: 4.7vw; 8 | margin-top: 6vh; 9 | overflow: hidden; 10 | margin-right: 70px; 11 | animation: animation 0.5s; 12 | } 13 | 14 | .list-group a { 15 | border: none; 16 | border-radius: 0; 17 | display: flex; 18 | color: black; 19 | text-decoration: none; 20 | line-height: 15px; 21 | padding-top: 8px; 22 | padding-left: 20px; 23 | } 24 | 25 | .list-group .option { 26 | padding-left: 12px; 27 | font-family: "Poppins", sans-serif; 28 | font-size: 10px; 29 | font-weight: bold; 30 | color: black; 31 | } 32 | 33 | .list-group img { 34 | margin-left: 2px; 35 | width: 13px !important; 36 | height: 13px !important; 37 | } 38 | 39 | @keyframes animation { 40 | 0% { 41 | height: 0; 42 | } 43 | 100% { 44 | height: 100px; 45 | } 46 | } 47 | -------------------------------------------------------------------------------- /model/NotificationModel.js: -------------------------------------------------------------------------------- 1 | export const getNotifications = (id) => { 2 | let config = { 3 | method: "get", 4 | maxBodyLength: Infinity, 5 | url: `http://localhost:8080/api/v1/notification/user/${id}`, 6 | params: { 7 | pageNo: 0, 8 | notificationCount: 10, 9 | }, 10 | }; 11 | 12 | return axios(config) 13 | .then((response) => { 14 | console.log("Data Retrieved successfully:", response.status); 15 | return response.data; 16 | }) 17 | .catch((error) => { 18 | if (error.response) { 19 | if (error.response.status === 404) { 20 | console.warn("No notifications found for user ID:", id); 21 | return []; 22 | } else { 23 | console.error( 24 | "Error occurred:", 25 | error.response.status, 26 | error.response.data 27 | ); 28 | } 29 | } else { 30 | console.error("Network or unknown error occurred:", error.message); 31 | } 32 | }); 33 | }; 34 | -------------------------------------------------------------------------------- /model/InspireModel.js: -------------------------------------------------------------------------------- 1 | export const saveInspiration = (data) => { 2 | let config = { 3 | method: "post", 4 | maxBodyLength: Infinity, 5 | url: `http://localhost:8080/api/v1/inspire`, 6 | data: data, 7 | }; 8 | 9 | return axios(config) 10 | .then((response) => { 11 | console.log("Inspiration saved successfully:", response.code); 12 | return response; 13 | }) 14 | .catch((error) => { 15 | console.error("Unable to save inspiration:", error); 16 | throw error; 17 | }); 18 | }; 19 | 20 | export const deleteInspiration = (postId) => { 21 | let config = { 22 | method: "delete", 23 | maxBodyLength: Infinity, 24 | url: `http://localhost:8080/api/v1/inspire/post/${postId}`, 25 | }; 26 | 27 | return axios(config) 28 | .then((response) => { 29 | console.log("Inspiration deleted successfully:", response.code); 30 | }) 31 | .catch((error) => { 32 | console.error("Unable to delete inspiration:", error); 33 | throw error; 34 | }); 35 | }; 36 | -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | MIT License 2 | 3 | Copyright (c) 2024 SE10-IJSE 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in all 13 | copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 21 | SOFTWARE. 22 | -------------------------------------------------------------------------------- /pages/searchPageMobile.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | SE10 NETWORK 7 | 8 | 9 | 10 | 11 | 12 |
13 | 19 |
20 |
21 |

Recent

22 |
23 |
24 | 25 | 26 | 27 | 28 | 32 | 33 | 34 | -------------------------------------------------------------------------------- /pages/birthdayPageMobile.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | SE10 NETWORK 6 | 7 | 8 | 9 | 10 | 11 |
12 |
13 |
14 |
15 |

Birthdays

16 |

Notifications

17 |
18 | 19 |
    20 | 21 |
22 |
23 |
24 |
25 | 26 | 27 | 28 | 29 | 33 | 34 | 35 | -------------------------------------------------------------------------------- /assets/css/notificationPageMobile.css: -------------------------------------------------------------------------------- 1 | body { 2 | overflow-y: hidden; 3 | background-color: #fffafa; 4 | } 5 | 6 | .recent-list { 7 | list-style: none; 8 | padding: 8px; 9 | gap: 10px; 10 | } 11 | 12 | .data-notify { 13 | font-family: "Poppins", sans-serif; 14 | font-size: 12px; 15 | color: #505050; 16 | margin-top: 5px; 17 | font-weight: 600; 18 | } 19 | 20 | .recent-list { 21 | height: auto; 22 | max-height: 80vh; 23 | overflow: scroll; 24 | } 25 | 26 | .recent-list::-webkit-scrollbar { 27 | width: 0 !important; 28 | } 29 | 30 | .title { 31 | font-family: "Poppins", sans-serif; 32 | font-size: 24px; 33 | font-weight: 700; 34 | cursor: alias; 35 | } 36 | 37 | .subtitle { 38 | font-size: 13px; 39 | font-weight: 700; 40 | color: #948e8e; 41 | letter-spacing: 0.5px; 42 | cursor: pointer; 43 | } 44 | 45 | .notification-item { 46 | display: flex; 47 | align-items: center; 48 | border: 1px solid #e8e8e8; 49 | border-radius: 15px; 50 | padding: 15px; 51 | background-color: #ffffff; 52 | } 53 | 54 | .avatar { 55 | width: 25px; 56 | height: 25px; 57 | margin-right: 10px; 58 | object-fit: cover; 59 | } 60 | 61 | .text { 62 | flex: 1; 63 | } 64 | 65 | .text p { 66 | font-family: "Poppins", sans-serif; 67 | margin: 0; 68 | font-size: 10px; 69 | color: #7a7a7a; 70 | } 71 | -------------------------------------------------------------------------------- /pages/notificationPageMobile.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | SE10 NETWORK 7 | 8 | 9 | 10 | 11 | 12 |
13 |
14 |
15 |
16 |

Notifications

17 |

Birthdays

18 |
19 | 20 |
    21 | 22 |
23 |
24 |
25 |
26 | 27 | 28 | 29 | 30 | 34 | 35 | 36 | 37 | -------------------------------------------------------------------------------- /assets/css/searchPopup.css: -------------------------------------------------------------------------------- 1 | .avatar { 2 | border-radius: 50%; 3 | width: 35px; 4 | height: 35px; 5 | object-fit: cover; 6 | } 7 | 8 | .search-popup { 9 | height: 100%; 10 | display: flex; 11 | flex-direction: column; 12 | } 13 | 14 | .search-result { 15 | cursor: pointer; 16 | } 17 | 18 | .recent-list { 19 | list-style: none; 20 | padding: 0; 21 | margin: 0; 22 | overflow-y: auto; 23 | flex-grow: 1; 24 | scrollbar-width: none; 25 | -ms-overflow-style: none; 26 | } 27 | 28 | .recent-list::-webkit-scrollbar { 29 | display: none; 30 | } 31 | 32 | .recent-box { 33 | height: 100%; 34 | display: flex; 35 | flex-direction: column; 36 | } 37 | 38 | .recent-box > div:first-child { 39 | flex-shrink: 0; 40 | } 41 | 42 | .recent-box h3 { 43 | font-family: "Poppins", sans-serif; 44 | font-size: 14px; 45 | margin-left: 20px; 46 | color: #000000; 47 | } 48 | 49 | .searchPopupList { 50 | width: 25vw; 51 | z-index: 10; 52 | padding: 10px; 53 | box-shadow: 0 0 36px -20px rgba(0, 0, 0, 0.25); 54 | background: #fff; 55 | border-radius: 5px; 56 | position: relative; 57 | left: 25px; 58 | transition: height 0.3s ease-out; 59 | overflow: hidden; 60 | } 61 | 62 | @keyframes dropdown { 63 | 0% { 64 | height: 0; 65 | opacity: 0; 66 | } 67 | 100% { 68 | opacity: 1; 69 | } 70 | } 71 | 72 | .search-popup .recent-list span { 73 | font-family: "Poppins", sans-serif; 74 | font-size: 13px; 75 | font-weight: 600; 76 | color: #505050; 77 | } 78 | -------------------------------------------------------------------------------- /model/HomePageModel.js: -------------------------------------------------------------------------------- 1 | export const getTokenValidation = () => { 2 | let config = { 3 | method: "get", 4 | maxBodyLength: Infinity, 5 | url: "http://localhost:8080/api/v1/user/validate", 6 | }; 7 | 8 | return axios(config) 9 | .then((response) => { 10 | console.log("Validation successful:", response.status); 11 | return response; 12 | }) 13 | .catch((error) => { 14 | console.error("Validation failed:", error); 15 | throw error; 16 | }); 17 | }; 18 | 19 | export const getBirthdayNames = () => { 20 | let config = { 21 | method: "get", 22 | maxBodyLength: Infinity, 23 | url: "http://localhost:8080/api/v1/user/birthday/names", 24 | }; 25 | 26 | return axios(config) 27 | .then((response) => { 28 | console.log("Birthday names retrieved successfully:", response.status); 29 | return response; 30 | }) 31 | .catch((error) => { 32 | console.error("Request failed:", error); 33 | throw error; 34 | }); 35 | }; 36 | 37 | export const getBirthdayData = () => { 38 | let config = { 39 | method: "get", 40 | maxBodyLength: Infinity, 41 | url: "http://localhost:8080/api/v1/user/birthday/data", 42 | }; 43 | 44 | return axios(config) 45 | .then((response) => { 46 | console.log("Birthday data retrieved successfully:", response.status); 47 | return response; 48 | }) 49 | .catch((error) => { 50 | console.error("Request failed:", error); 51 | throw error; 52 | }); 53 | }; 54 | -------------------------------------------------------------------------------- /assets/tostify/toastify.min.css: -------------------------------------------------------------------------------- 1 | /** 2 | * Minified by jsDelivr using clean-css v5.3.2. 3 | * Original file: /npm/toastify-js@1.12.0/src/toastify.css 4 | * 5 | * Do NOT use SRI with dynamically generated files! More information: https://www.jsdelivr.com/using-sri-with-dynamic-files 6 | */ 7 | /*! 8 | * Toastify js 1.12.0 9 | * https://github.com/apvarun/toastify-js 10 | * @license MIT licensed 11 | * 12 | * Copyright (C) 2018 Varun A P 13 | */ 14 | .toastify{padding:12px 20px;color:#fff;display:inline-block;box-shadow:0 3px 6px -1px rgba(0,0,0,.12),0 10px 36px -4px rgba(77,96,232,.3);background:-webkit-linear-gradient(315deg,#73a5ff,#5477f5);background:linear-gradient(135deg,#73a5ff,#5477f5);position:fixed;opacity:0;transition:all .4s cubic-bezier(.215, .61, .355, 1);border-radius:2px;cursor:pointer;text-decoration:none;max-width:calc(50% - 20px);z-index:2147483647}.toastify.on{opacity:1}.toast-close{background:0 0;border:0;color:#fff;cursor:pointer;font-family:inherit;font-size:1em;opacity:.4;padding:0 5px}.toastify-right{right:15px}.toastify-left{left:15px}.toastify-top{top:-150px}.toastify-bottom{bottom:-150px}.toastify-rounded{border-radius:25px}.toastify-avatar{width:1.5em;height:1.5em;margin:-7px 5px;border-radius:2px}.toastify-center{margin-left:auto;margin-right:auto;left:0;right:0;max-width:fit-content;max-width:-moz-fit-content}@media only screen and (max-width:360px){.toastify-left,.toastify-right{margin-left:auto;margin-right:auto;left:0;right:0;max-width:fit-content}} 15 | /*# sourceMappingURL=/sm/cb4335d1b03e933ed85cb59fffa60cf51f07567ed09831438c60f59afd166464.map */ -------------------------------------------------------------------------------- /assets/css/birthdayPopup.css: -------------------------------------------------------------------------------- 1 | .birthdayPopup { 2 | display: none; 3 | position: fixed; 4 | top: 50%; 5 | left: 50%; 6 | transform: translate(-50%, -50%); 7 | z-index: 1000; 8 | } 9 | 10 | #birthday-container { 11 | background-color: #fff; 12 | width: 34vw; 13 | padding: 24px 32px; 14 | border-radius: 15px; 15 | border: 1px solid rgba(236, 236, 236, 1); 16 | text-align: left; 17 | box-shadow: 0px 4px 18.3px rgba(0, 0, 0, 0.25); 18 | opacity: 0; 19 | transform: scale(0); 20 | transition: opacity 300ms ease-in-out, transform 300ms ease-in-out; 21 | } 22 | 23 | #birthday-list { 24 | margin-bottom: 10px; 25 | max-height: 20vh; 26 | overflow-y: auto; 27 | } 28 | 29 | .birthdayPopup h3 img { 30 | height: 32px; 31 | width: auto; 32 | margin-left: 10px; 33 | } 34 | 35 | .bp-head h3 { 36 | color: #000; 37 | font-family: "Poppins", sans-serif; 38 | font-size: 26px; 39 | font-weight: 700; 40 | } 41 | 42 | #birthday-txt { 43 | color: #000; 44 | font-family: "Poppins", sans-serif; 45 | font-size: 14px; 46 | font-weight: 500; 47 | } 48 | 49 | #close-birthday-icon { 50 | object-fit: cover; 51 | width: 12px; 52 | height: 12px; 53 | cursor: pointer; 54 | } 55 | 56 | .bp-head { 57 | display: flex; 58 | flex-direction: row; 59 | justify-content: space-between; 60 | } 61 | 62 | .scrollable-list { 63 | scrollbar-width: thin; 64 | scrollbar-color: #888 #e0e0e0; 65 | } 66 | 67 | .profile-img { 68 | width: 50px; 69 | height: 50px; 70 | border-radius: 50%; 71 | object-fit: cover; /* Ensures the image covers the entire area */ 72 | } -------------------------------------------------------------------------------- /assets/css/error404Page.css: -------------------------------------------------------------------------------- 1 | .custom-btn { 2 | background-color: var(--btn-bg-color); 3 | color: var(--bg-color); 4 | border-color: var(--btn-bg-color); 5 | } 6 | 7 | .custom-btn:hover { 8 | background-color: var(--btn-hover-color); 9 | border-color: var(--btn-hover-color); 10 | color: var(--bg-color); 11 | } 12 | 13 | .img-fluid { 14 | width: 100%; 15 | height: auto; 16 | } 17 | 18 | .content-container { 19 | text-align: left; 20 | } 21 | 22 | @media (max-width: 991px) { 23 | .col-lg-6 { 24 | flex-direction: column; 25 | align-items: center; 26 | justify-content: center; 27 | text-align: center; 28 | } 29 | 30 | .content-container { 31 | text-align: center; 32 | } 33 | 34 | .content-container h1 { 35 | font-size: 3rem; 36 | } 37 | 38 | .content-container h3 { 39 | font-size: 1.5rem; 40 | } 41 | 42 | .content-container p { 43 | font-size: 1rem; 44 | } 45 | 46 | .custom-btn { 47 | font-size: 1rem; 48 | padding: 10px 20px; 49 | } 50 | 51 | .img-fluid { 52 | max-width: 90%; 53 | height: auto; 54 | } 55 | 56 | .row { 57 | margin: 0; 58 | padding: 0; 59 | } 60 | } 61 | 62 | @media (max-width: 450px) { 63 | .content-container h1 { 64 | font-size: 2.5rem; 65 | } 66 | .content-container { 67 | text-align: center; 68 | } 69 | 70 | .content-container h3 { 71 | font-size: 1.2rem; 72 | } 73 | 74 | .content-container p { 75 | font-size: 0.8rem; 76 | } 77 | 78 | .custom-btn { 79 | font-size: 0.675rem; 80 | padding: 8px 16px; 81 | } 82 | 83 | .img-fluid { 84 | max-width: 80%; 85 | height: auto; 86 | } 87 | } 88 | -------------------------------------------------------------------------------- /pages/error404Page.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | Page Not Found - Error 404 10 | 11 | 12 |
13 |
14 | 15 |
16 |
17 |

404

18 |

Page Not Found!

19 |

20 | It looks like the page you're trying to reach doesn't 21 |
22 | exist or has been moved. 23 |

24 | Back to Home 27 |
28 |
29 | 30 |
33 | Error 404 38 |
39 |
40 |
41 | 42 | 43 | -------------------------------------------------------------------------------- /assets/css/birthdayPageMobile.css: -------------------------------------------------------------------------------- 1 | body { 2 | overflow-y: hidden; 3 | background-color: #fffafa; 4 | } 5 | 6 | .title { 7 | font-family: "Poppins", sans-serif; 8 | font-size: 24px; 9 | font-weight: 700; 10 | cursor: alias; 11 | } 12 | 13 | .subtitle { 14 | font-size: 13px; 15 | font-weight: 700; 16 | color: #948e8e; 17 | letter-spacing: 0.5px; 18 | cursor: pointer; 19 | } 20 | 21 | .recent-list { 22 | list-style: none; 23 | padding: 8px; 24 | gap: 10px; 25 | height: auto; 26 | max-height: 80vh; 27 | overflow: scroll; 28 | } 29 | 30 | .recent-list::-webkit-scrollbar { 31 | width: 0 !important; 32 | } 33 | 34 | .birthday-item { 35 | display: flex; 36 | align-items: center; 37 | border: 1px solid hsla(0, 0%, 91%, 1); 38 | border-radius: 15px; 39 | padding: 8px; 40 | background-color: hsla(0, 0%, 100%, 1); 41 | box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1); 42 | justify-content: space-between; 43 | } 44 | 45 | .profilepic-container { 46 | display: flex; 47 | align-items: center; 48 | } 49 | 50 | .profilepic { 51 | border-radius: 50%; 52 | border: 3px solid #c0c0c0; 53 | width: 42px; 54 | height: 42px; 55 | margin-right: 10px; 56 | object-fit: cover; 57 | } 58 | 59 | .text { 60 | display: flex; 61 | align-items: end; 62 | justify-content: space-between; 63 | } 64 | 65 | .text p { 66 | font-family: "Poppins", sans-serif; 67 | margin: 0; 68 | font-size: 12px; 69 | color: #797979; 70 | font-weight: 500; 71 | } 72 | 73 | .username { 74 | overflow: hidden; 75 | white-space: nowrap; 76 | text-overflow: ellipsis; /* Show ellipsis (...) when text overflows */ 77 | max-width: 180px; 78 | } 79 | 80 | @media (max-width: 350px) { 81 | .username { 82 | max-width: 140px; 83 | } 84 | } 85 | -------------------------------------------------------------------------------- /assets/css/SearchPageMobile.css: -------------------------------------------------------------------------------- 1 | body { 2 | font-family: Arial, sans-serif; 3 | background-color: #f9f9f9; 4 | margin: 0; 5 | padding: 0; 6 | } 7 | 8 | .search-container { 9 | padding: 10px; 10 | background-color: #fff; 11 | border-bottom: 1px solid #ddd; 12 | } 13 | 14 | .search-bar { 15 | display: flex; 16 | align-items: center; 17 | border: 2px solid #f25d5d; 18 | border-radius: 25px; 19 | padding: 5px 10px; 20 | background-color: #fff; 21 | } 22 | 23 | .search-bar input { 24 | border: none; 25 | outline: none; 26 | flex-grow: 1; 27 | font-size: 16px; 28 | padding: 5px; 29 | } 30 | 31 | .search-bar .back-button { 32 | border: none; 33 | background: none; 34 | font-size: 20px; 35 | color: #f25d5d; 36 | cursor: pointer; 37 | } 38 | 39 | #back { 40 | height: 20px; 41 | width: 25px; 42 | display: flex; 43 | justify-content: center; 44 | } 45 | 46 | .recent-container { 47 | padding: 10px; 48 | background-color: #fff; 49 | } 50 | 51 | .recent-container h2 { 52 | margin: 0 0 10px 0; 53 | font-size: 18px; 54 | color: #333; 55 | } 56 | 57 | .recent-list { 58 | display: flex; 59 | flex-direction: column; 60 | height: 83vh; 61 | overflow-y: scroll; 62 | } 63 | 64 | .recent-list::-webkit-scrollbar { 65 | width: 5px; 66 | } 67 | 68 | .recent-item { 69 | display: flex; 70 | align-items: center; 71 | margin-bottom: 10px; 72 | } 73 | 74 | .recent-item img { 75 | width: 40px; 76 | height: 40px; 77 | border-radius: 50%; 78 | margin-right: 10px; 79 | object-fit: cover; 80 | } 81 | 82 | .recent-item span { 83 | flex-grow: 1; 84 | font-size: 16px; 85 | color: #333; 86 | } 87 | 88 | .recent-item .remove-btn { 89 | border: none; 90 | background: none; 91 | font-size: 20px; 92 | color: #999; 93 | cursor: pointer; 94 | padding: 0; 95 | } 96 | 97 | .recent-item .remove-btn:hover { 98 | color: #f25d5d; 99 | } 100 | 101 | .remove-btn { 102 | background: none; 103 | border: none; 104 | color: red; 105 | font-size: 18px; 106 | cursor: pointer; 107 | margin-left: 10px; 108 | } 109 | 110 | .remove-btn:hover { 111 | text-decoration: underline; 112 | } 113 | -------------------------------------------------------------------------------- /components/pages/wall/adminApproveWallComponent.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 13 | ADMIN-APPROVE-WALL 14 | 15 | 16 |
17 | 18 |
19 |
Post Something
20 |
21 | Profile Image 26 |
27 | 34 | 38 | Send Post Icon 42 | 43 |
44 |
45 |
46 |
47 |
48 | 49 | 50 | 51 | 52 | 56 | 57 | 58 | -------------------------------------------------------------------------------- /controller/BirthdaysPageMobileController.js: -------------------------------------------------------------------------------- 1 | import { getBirthdayData } from "../model/HomePageModel.js"; 2 | 3 | $(document).ready(function () { 4 | const jwtToken = getJwtToken(); 5 | 6 | if (jwtToken) { 7 | axios.defaults.headers.common["Authorization"] = `Bearer ${jwtToken}`; 8 | 9 | retriveBirthdayData(); 10 | 11 | $(document).on("click", "#Notifications .subtitle", function () { 12 | const subtitleText = $(this).text().trim(); 13 | const iframe = $("#homePage .homeWallComponent iframe"); 14 | 15 | if (subtitleText === "Birthdays") { 16 | $(parent.document) 17 | .find("#homePage .homeWallComponent iframe") 18 | .attr("src", "/pages/birthdayPageMobile.html"); 19 | } else { 20 | $(parent.document) 21 | .find("#homePage .homeWallComponent iframe") 22 | .attr("src", "/pages/notificationPageMobile.html"); 23 | } 24 | 25 | iframe.css({ 26 | "border-radius": "0", 27 | "box-shadow": "none", 28 | }); 29 | }); 30 | } else console.error("User token not found in cookies"); 31 | }); 32 | 33 | const retriveBirthdayData = async () => { 34 | const birthdayData = await getBirthdayData(); 35 | if (birthdayData.data.length > 0) { 36 | setBirthdayData(birthdayData.data); 37 | } 38 | }; 39 | 40 | const setBirthdayData = (birthdayData) => { 41 | for (let i = 0; i < birthdayData.length; i++) { 42 | $("#birthday-list").append(BirthdayCard(birthdayData[i])); 43 | } 44 | }; 45 | 46 | const BirthdayCard = (user) => { 47 | const profileImage = user.profileImg 48 | ? `data:image/png;base64,${user.profileImg}` 49 | : "/assets/image/profilePic.png"; 50 | 51 | return ` 52 |
  • 53 |
    54 |
    55 |
    56 | Profile Image 57 |
    58 |

    ${user.name}

    59 |
    60 |
    61 |
    62 |

    ${user.batch}

    63 |
    64 |
    65 |
    66 |
  • 67 | `; 68 | }; 69 | 70 | function getJwtToken() { 71 | const cookies = document.cookie.split("; "); 72 | for (let cookie of cookies) { 73 | if (cookie.startsWith("jwt=")) { 74 | return cookie.split("=")[1]; 75 | } 76 | } 77 | return null; 78 | } 79 | -------------------------------------------------------------------------------- /pages/adminApprovePageMobile.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 14 | SE10 NETWORK 15 | 16 | 17 |
    18 |

    Approve

    19 |

    Home

    20 |
    21 | 22 |
    23 | 24 |
    25 |
    Post Something
    26 |
    27 | Profile Image 32 |
    33 | 40 | 44 | Send Post Icon 48 | 49 |
    50 |
    51 |
    52 |
    53 |
    54 | 55 | 56 | 57 | 61 | 62 | 66 | 67 | 68 | 69 | -------------------------------------------------------------------------------- /controller/ForgotPasswordFormController.js: -------------------------------------------------------------------------------- 1 | $(document).ready(function () { 2 | //Validations 3 | $("#password").attr({ 4 | minlength: "8", 5 | required: true, 6 | }); 7 | 8 | $("#confirm-password").attr("required", true); 9 | 10 | const $togglePassword = $("#togglePassword"); 11 | const $togglePasswordConfirm = $("#togglePasswordConfirm"); 12 | const $passwordInput = $("#password"); 13 | const $passwordInputConfirm = $("#confirm-password"); 14 | 15 | $togglePassword.on("click", function () { 16 | // Toggle the type attribute 17 | const type = 18 | $passwordInput.attr("type") === "password" ? "text" : "password"; 19 | $passwordInput.attr("type", type); 20 | 21 | // Toggle the icon 22 | $(this).toggleClass("ri-eye-line ri-eye-off-line"); 23 | }); 24 | 25 | $togglePasswordConfirm.on("click", function () { 26 | // Toggle the type attribute 27 | const type = 28 | $passwordInputConfirm.attr("type") === "password" ? "text" : "password"; 29 | $passwordInputConfirm.attr("type", type); 30 | 31 | // Toggle the icon 32 | $(this).toggleClass("ri-eye-line ri-eye-off-line"); 33 | }); 34 | 35 | // Handle Enter key press 36 | $("input").keydown(function (e) { 37 | if (e.key === "Enter") { 38 | e.preventDefault(); 39 | if (this.checkValidity()) { 40 | const $inputs = $("input"); 41 | const nextInput = $inputs.get($inputs.index(this) + 1); 42 | if (nextInput) { 43 | nextInput.focus(); 44 | } 45 | } else { 46 | this.reportValidity(); 47 | } 48 | } 49 | }); 50 | 51 | $("#login-btn").on("click", function () { 52 | window.location.href = "/index.html"; 53 | }); 54 | 55 | $("#login").on("submit", function (event) { 56 | event.preventDefault(); 57 | if (this.checkValidity() & validatePasswords()) { 58 | if ($passwordInput.val() === $passwordInputConfirm.val()) { 59 | localStorage.setItem("newPassword", $passwordInput.val()); 60 | window.location.href = "/pages/forgotPasswordOtpVerifyPage.html"; 61 | } 62 | } else { 63 | this.reportValidity(); 64 | } 65 | }); 66 | 67 | $("#password").on("input", function () { 68 | this.setCustomValidity(""); 69 | }); 70 | 71 | $("#confirm-password").on("input", function () { 72 | this.setCustomValidity(""); 73 | }); 74 | }); 75 | 76 | function validatePasswords() { 77 | const password = $("#password").val(); 78 | const confirmPassword = $("#confirm-password").val(); 79 | 80 | if (password !== confirmPassword) { 81 | $("#confirm-password")[0].setCustomValidity("Passwords do not match"); 82 | return false; 83 | } else { 84 | $("#confirm-password")[0].setCustomValidity(""); 85 | return true; 86 | } 87 | } 88 | -------------------------------------------------------------------------------- /CODE_OF_CONDUCT.md: -------------------------------------------------------------------------------- 1 | # Code of Conduct for SE10 Social Media Site 2 | 3 | ## 1. Respect and Inclusion 4 | - **Respect Everyone:** Treat all team members with respect. Understand that everyone comes from different backgrounds and experiences. 5 | - **No Discrimination:** Discrimination based on race, gender, religion, sexual orientation, or any other personal attribute will not be tolerated. 6 | - **Inclusive Environment:** Foster an inclusive environment where everyone feels comfortable to share ideas and contribute. 7 | 8 | ## 2. Collaboration and Communication 9 | - **Effective Communication:** Maintain open and clear communication with your team members. Use designated communication channels (e.g., Discord, Google Meet) for project-related discussions. 10 | - **Constructive Feedback:** Provide feedback that is constructive and aimed at improving the project. Avoid personal attacks or unproductive criticism. 11 | - **Active Participation:** Participate actively in meetings and discussions. Make sure your contributions are timely and relevant. 12 | 13 | ## 3. Responsibility and Accountability 14 | - **Meet Deadlines:** Complete your tasks on time. If you foresee a delay, communicate it early and seek help if needed. 15 | - **Ownership:** Take ownership of your work. If you encounter a problem, attempt to solve it but don’t hesitate to ask for assistance. 16 | - **Reliable Contributions:** Ensure that the code and features you contribute are well-tested and documented. 17 | 18 | ## 4. Ethical Coding Practices 19 | - **Original Work:** Only contribute original work or properly attributed open-source code. Do not plagiarize or use code that violates copyright. 20 | - **Best Practices:** Follow coding best practices such as code reviews, writing clean code, and adhering to project conventions and standards. 21 | - **Security Awareness:** Ensure that your contributions do not introduce security vulnerabilities. If you find a security issue, report it immediately to the project leaders. 22 | 23 | ## 5. Conflict Resolution 24 | - **Address Issues Early:** If a conflict arises, address it as soon as possible through open discussion. Try to resolve conflicts with mutual respect and understanding. 25 | - **Escalation:** If a conflict cannot be resolved within the team, escalate it to the project leaders or instructors for mediation. 26 | 27 | ## 6. Learning and Growth 28 | - **Continuous Learning:** Take this project as an opportunity to learn and grow. Share knowledge and resources with your peers. 29 | - **Mentorship:** Support and mentor less experienced team members when possible. Encourage a learning atmosphere where everyone can grow. 30 | 31 | ## 7. Consequences 32 | - **Violations:** Any violation of this Code of Conduct may result in a discussion with the project leaders or instructors. Repeated violations may result in reduced project contributions, grade penalties, or removal from the project. 33 | - **Appeal:** If you feel that any action taken against you is unjust, you have the right to appeal to the instructors. 34 | 35 | -------------------------------------------------------------------------------- /assets/css/postInfoPopup.css: -------------------------------------------------------------------------------- 1 | .modal { 2 | display: none; 3 | position: fixed; 4 | top: 50%; 5 | left: 50%; 6 | transform: translate(-50%, -50%); 7 | z-index: 1000; 8 | } 9 | 10 | .modal-content { 11 | background-color: #fff; 12 | width: 90%; 13 | max-width: 480px; 14 | height: 185px; 15 | padding: 20px; 16 | border-radius: 15px; 17 | border: 1px solid rgba(236, 236, 236, 1); 18 | text-align: left; 19 | box-shadow: 0px 4px 18.3px rgba(0, 0, 0, 0.25); 20 | opacity: 0; 21 | transform: translate(-50%, -50%) scale(0); 22 | transition: transform 300ms ease-in-out, opacity 300ms ease-in-out; 23 | position: absolute; 24 | top: 50%; 25 | left: 50%; 26 | } 27 | 28 | .modal.active .modal-content { 29 | transform: translate(-50%, -50%) scale(1); 30 | opacity: 1; 31 | } 32 | 33 | .modal-info { 34 | display: flex; 35 | justify-content: space-between; 36 | margin-bottom: 10px; 37 | } 38 | 39 | .modal-info p { 40 | margin: 0; 41 | flex: 1; 42 | } 43 | 44 | .modal-header { 45 | width: 267px; 46 | height: 30px; 47 | font-size: 16px; 48 | font-weight: 700; 49 | line-height: 24px; 50 | text-align: left; 51 | margin-bottom: 10px; 52 | } 53 | 54 | .modal-subheader { 55 | font-size: 12px; 56 | font-weight: 500; 57 | line-height: 10px; 58 | color: #939393; 59 | padding: 2px 4px; 60 | border-radius: 3px; 61 | margin-left: 22px; 62 | } 63 | 64 | .modal-actions { 65 | position: absolute; 66 | bottom: 20px; 67 | right: 20px; 68 | width: auto; 69 | display: flex; 70 | justify-content: flex-end; 71 | } 72 | 73 | .btn-cancel { 74 | width: 91px; 75 | height: 30px; 76 | background-color: rgba(234, 23, 23, 0.28); 77 | color: #ea1717; 78 | border: none; 79 | border-radius: 5px; 80 | cursor: pointer; 81 | font-size: 12px; 82 | font-weight: 450; 83 | } 84 | 85 | .btn-cancel:hover { 86 | background-color: #f5c6cb; 87 | } 88 | 89 | @media (max-width: 768px) { 90 | .modal-content { 91 | width: 80%; 92 | max-width: 400px; 93 | height: 163px; 94 | padding: 15px; 95 | } 96 | 97 | .modal-header { 98 | font-size: 16px; 99 | } 100 | 101 | .modal-info p { 102 | font-size: 13px; 103 | } 104 | } 105 | 106 | @media (max-width: 576px) { 107 | .modal-content { 108 | width: 60%; 109 | max-width: 300px; 110 | padding: 10px; 111 | } 112 | 113 | .modal-header { 114 | font-size: 15px; 115 | } 116 | 117 | .modal-info p { 118 | font-size: 12px; 119 | } 120 | 121 | .btn-cancel { 122 | font-size: 13px; 123 | } 124 | } 125 | 126 | @media (max-width: 400px) { 127 | .modal-content { 128 | width: 50%; 129 | max-width: 300px; 130 | padding: 10px; 131 | height: 154px; 132 | } 133 | 134 | .modal-header { 135 | font-size: 14px; 136 | } 137 | .modal-info { 138 | flex-direction: column; 139 | margin-bottom: 0px; 140 | } 141 | 142 | .modal-info p { 143 | font-size: 11px; 144 | } 145 | 146 | .btn-cancel { 147 | font-size: 12px; 148 | padding: 6px 12px; 149 | } 150 | 151 | .modal-actions { 152 | position: static; 153 | justify-content: center; 154 | } 155 | .modal-subheader { 156 | margin-bottom: 18px; 157 | } 158 | .modal-content > .modal-info:nth-child(3) { 159 | margin-bottom: 7px; 160 | } 161 | } 162 | -------------------------------------------------------------------------------- /assets/css/deleteConfirmationPopup.css: -------------------------------------------------------------------------------- 1 | /* General Modal Styling */ 2 | .modal { 3 | display: none; /* Hidden by default */ 4 | position: fixed; 5 | top: 50%; 6 | left: 50%; 7 | transform: translate(-50%, -50%); 8 | z-index: 1000; 9 | width: 100vw; 10 | height: 100vh; 11 | overflow: auto; 12 | } 13 | 14 | /* Modal Content Styling */ 15 | .modal-content { 16 | background-color: #fff; 17 | width: 90%; 18 | max-width: 483px; /* Limit the maximum width */ 19 | padding: 20px; 20 | border-radius: 15px; 21 | border: 1px solid rgba(236, 236, 236, 1); 22 | box-shadow: 0px 4px 18.3px rgba(0, 0, 0, 0.25); 23 | opacity: 0; 24 | transform: translate(-50%, -50%) scale(0); 25 | transition: transform 300ms ease-in-out, opacity 300ms ease-in-out; 26 | position: absolute; 27 | top: 50%; 28 | left: 50%; 29 | } 30 | 31 | /* Show Modal When Active */ 32 | .modal.active .modal-content { 33 | transform: translate(-50%, -50%) scale(1); 34 | opacity: 1; 35 | } 36 | 37 | /* Modal Header Styling */ 38 | .modal-header { 39 | font-family: "Poppins", sans-serif; 40 | font-size: 16px; 41 | font-weight: 700; 42 | margin-bottom: 10px; 43 | color: #333; 44 | } 45 | 46 | /* Modal Subheader Styling */ 47 | .modal-subheader { 48 | font-family: "Poppins", sans-serif; 49 | font-size: 14px; 50 | color: #a8a8a8; 51 | font-weight: 400; 52 | margin-left: 16px; 53 | } 54 | 55 | /* Modal Actions Styling */ 56 | .modal-actions { 57 | display: flex; 58 | justify-content: flex-end; 59 | margin-top: 20px; 60 | } 61 | 62 | /* Button Styles */ 63 | button { 64 | font-family: "Poppins", sans-serif; 65 | font-size: 14px; 66 | font-weight: 600; 67 | border: none; 68 | border-radius: 5px; 69 | cursor: pointer; 70 | } 71 | 72 | /* Cancel Button */ 73 | .cancel-btn { 74 | background-color: #f8d7da; 75 | color: #d9534f; 76 | padding: 10px 20px; 77 | } 78 | 79 | .cancel-btn:hover { 80 | background-color: #f5c6cb; 81 | } 82 | 83 | /* Delete Button */ 84 | .delete-btn { 85 | background-color: #d9534f; 86 | color: #fff; 87 | padding: 7px 20px; 88 | } 89 | 90 | .delete-btn:hover { 91 | background-color: #c9302c; 92 | } 93 | 94 | /* Responsive Adjustments */ 95 | @media (max-width: 768px) { 96 | .modal-content { 97 | width: 95%; 98 | padding: 15px; 99 | } 100 | 101 | .modal-header { 102 | font-size: 16px; 103 | } 104 | 105 | button { 106 | font-size: 12px; 107 | } 108 | } 109 | 110 | @media (max-width: 576px) { 111 | .modal-content { 112 | width: 95%; 113 | padding: 10px; 114 | } 115 | 116 | .modal-header { 117 | font-size: 15px; 118 | } 119 | 120 | .modal-subheader { 121 | font-size: 12px; 122 | } 123 | 124 | button { 125 | font-size: 13px; 126 | } 127 | } 128 | 129 | @media (max-width: 400px) { 130 | .modal-content { 131 | width: 100%; 132 | max-width: 255px; 133 | padding: 0px 10px 10px 10px; 134 | } 135 | 136 | .modal-header { 137 | padding-bottom: 10px; 138 | font-size: 12px; 139 | } 140 | 141 | .delete-header { 142 | margin-top: 15px; 143 | padding-bottom: 22px; 144 | } 145 | 146 | .modal-subheader { 147 | margin-top: 2px; 148 | font-size: 11px; 149 | } 150 | 151 | .modal-actions { 152 | margin-top: 4px; 153 | justify-content: space-around; 154 | } 155 | 156 | button { 157 | font-size: 12px; 158 | padding: 8px 16px; 159 | } 160 | } 161 | -------------------------------------------------------------------------------- /index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | SE10-NETWORK LOGIN 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 |
    18 |
    19 |
    20 |
    21 |
    22 |

    Login Form

    23 |
    24 | 25 |

    Where ideas meet execution

    26 |

    Login to access the portal

    27 | 28 |
    29 | 30 | 31 |
    32 | 33 |
    34 |
    35 | 36 | 37 | 38 |
    39 | 40 |
    41 | 45 | 46 | 49 |
    50 |
    51 | 52 |
    53 | 54 |

    55 | Don't have an account ? Register Now. 56 |

    57 |


    58 |
    59 |
    60 |
    61 | 62 |
    63 | 70 | 71 | Small Image 72 |
    73 | 74 | 75 | 76 | 77 | 78 | 79 | 80 | 81 | -------------------------------------------------------------------------------- /components/pages/wall/myFriendPostWallComponent.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | FRIEND-SEARCH-WALL 7 | 8 | 9 | 10 | 11 | 15 | 16 | 17 | 21 | 25 | 26 | 27 | 28 | 29 |
    30 |
    31 |
    32 | Cover Photo 37 |
    38 | 39 |
    43 |
    44 | Profile Picture 49 |
    50 |
    53 |

    54 |

    55 |

    56 |
    57 |
    58 |
    59 | 60 |
    61 |
    62 | 63 |
    64 |
    65 |
    66 |
    67 | 68 | 69 | 84 |
    85 | 86 | 87 | 88 | 89 | 93 | 94 | 95 | -------------------------------------------------------------------------------- /components/pages/wall/homeWallComponent.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 14 | HOME-WALL 15 | 16 | 17 | 18 |
    19 | 20 |
    21 |
    Post Something
    22 |
    23 | Profile Image 28 |
    29 | 36 | 40 | Send Post Icon 44 | 45 |
    46 |
    47 |
    48 | 49 |
    50 |
    Post Something
    51 |
    54 | Profile Image 60 | 61 |
    62 | 70 | 74 | Send Post Icon 79 | 80 |
    81 |
    82 |
    83 | 84 |
    85 |
    86 | 87 | 88 | 89 | 90 | 94 | 95 | 96 | -------------------------------------------------------------------------------- /pages/registrationOtpVerifyPage.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | SE10 NETWORK 7 | 8 | 9 | 13 | 17 | 18 | 19 | 20 | 21 | 22 |
    26 |
    27 |
    28 | 29 |
    30 |
    31 |

    Registration Verify

    32 |
    33 | 34 | 35 |

    verify your email to complete

    36 |

    verify email

    37 | 38 |
    39 |

    40 | An OTP has been sent to your email. Please enter it in the text 41 | field. 42 |

    43 |
    44 | 45 | 46 | 47 | 48 | 49 | 50 |
    51 |
    52 |

    53 | Did not receive an email? 54 | Resend now. 55 |

    56 |
    57 |
    58 | 61 |
    62 |
    63 |
    64 |
    65 |
    66 | Registrationform background 71 |
    72 | 73 | 84 | 85 | Small Image 86 |
    87 | 88 | 89 | 90 | 91 | 92 | 96 | 97 | 98 | -------------------------------------------------------------------------------- /pages/forgotPasswordOtpVerifyPage.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | SE10 NETWORK 7 | 8 | 9 | 13 | 17 | 18 | 22 | 23 | 24 | 25 |
    26 |
    27 |
    28 |
    29 |
    30 |

    Reset Password

    31 |
    32 | 33 |
    34 |

    Lost password? Let's recover it!

    35 |

    Reset your password

    36 |
    37 | 38 |
    39 |

    40 | An OTP has been sent to your email. Please enter it in the text 41 | field. 42 |

    43 | 44 |
    45 | 46 | 47 | 48 | 49 | 50 | 51 |
    52 |
    53 | 54 |
    55 |

    56 | Didn't receive an email? 57 | Resend Now. 58 |

    59 |
    60 | 61 |
    62 | 63 |

    64 | Got password ? Login Now. 65 |

    66 |
    67 |
    68 |
    69 | 70 |
    71 | Registrationform background 76 |
    77 | 78 | 89 | 90 | Small Image 95 |
    96 | 97 | 98 | 99 | 100 | 101 | 105 | 106 | 107 | -------------------------------------------------------------------------------- /components/css/PostCardComponent.css: -------------------------------------------------------------------------------- 1 | #postCard { 2 | background-color: #ffffff; 3 | box-shadow: 0 4px 18.3px 0 rgba(0, 0, 0, 0.05); 4 | } 5 | 6 | #postCard .profileImage { 7 | width: 55px; 8 | height: 55px; 9 | border: 2px solid #c0c0c0 !important; 10 | border-radius: 50%; 11 | object-fit: cover; 12 | } 13 | 14 | #postCard img { 15 | width: 21px; 16 | } 17 | 18 | #postCard h5 { 19 | color: #505050; 20 | font-family: "Poppins", sans-serif; 21 | font-size: 20px; 22 | font-weight: 600; 23 | } 24 | 25 | #postCard h6 { 26 | color: #ccc; 27 | font-family: "Poppins", sans-serif; 28 | font-size: 13px; 29 | font-weight: 600; 30 | } 31 | 32 | #postCard p { 33 | color: #000; 34 | font-family: "Poppins", sans-serif; 35 | font-size: 13px; 36 | font-weight: 500; 37 | } 38 | 39 | #postCard > div > :last-child img { 40 | width: 18px; 41 | height: 18px; 42 | } 43 | 44 | #postCard > div > :last-child span { 45 | color: rgba(0, 0, 0, 0.5); 46 | font-family: "Poppins", sans-serif; 47 | font-size: 13px; 48 | font-weight: 400; 49 | } 50 | 51 | #postCard > div > :last-child button span { 52 | color: #000; 53 | font-family: "Poppins", sans-serif; 54 | font-size: 12px; 55 | font-weight: 700; 56 | } 57 | 58 | /*-------------------------------Post card mobile view--------------------------------- */ 59 | #createPostMobile { 60 | display: none; 61 | } 62 | 63 | #postCardMobile { 64 | background-color: #ffffff; 65 | box-shadow: 0 4px 18.3px 0 rgba(0, 0, 0, 0.05); 66 | display: none; 67 | } 68 | 69 | #postCardMobile .profileImage { 70 | width: 45px; 71 | height: 45px; 72 | border: 2px solid #c0c0c0; 73 | border-radius: 50%; 74 | } 75 | 76 | #postCardMobile img { 77 | width: 21px; 78 | } 79 | 80 | #postCardMobile h5 { 81 | color: #505050; 82 | font-family: "Poppins", sans-serif; 83 | font-size: 16px; 84 | font-weight: 600; 85 | margin-left: -10px; 86 | } 87 | 88 | #postCardMobile h6 { 89 | color: #ccc; 90 | font-family: "Poppins", sans-serif; 91 | font-size: 10px; 92 | font-weight: 600; 93 | margin-top: -10px; 94 | margin-left: -10px; 95 | } 96 | 97 | #postCardMobile i { 98 | margin-bottom: 20px; 99 | } 100 | 101 | #postCardMobile p { 102 | color: #000; 103 | font-family: "Poppins", sans-serif; 104 | font-size: 12px; 105 | font-weight: 500; 106 | text-align: justify; 107 | } 108 | 109 | #postCardMobile > div > :last-child img { 110 | width: 18px; 111 | height: 18px; 112 | } 113 | 114 | #postCardMobile > div > :last-child span { 115 | color: rgba(0, 0, 0, 0.5); 116 | font-family: "Poppins", sans-serif; 117 | font-size: 8px; 118 | font-weight: 400; 119 | } 120 | 121 | #postCardMobile > div > :last-child button span { 122 | color: #000; 123 | font-family: "Poppins", sans-serif; 124 | font-size: 8px; 125 | font-weight: 700; 126 | } 127 | 128 | #createPostWeb { 129 | margin-top: 0px; 130 | } 131 | 132 | /* Responsive Adjustments */ 133 | @media screen and (max-width: 400px) { 134 | #edit-info-btn { 135 | padding: 5px !important; 136 | } 137 | } 138 | 139 | @media screen and (min-width: 768px) and (max-width: 992px) { 140 | #createPostWeb { 141 | margin: 10px; 142 | } 143 | 144 | #postCard { 145 | margin: 0px; 146 | margin-left: 10px; 147 | margin-right: 10px; 148 | } 149 | 150 | #postCardContent { 151 | padding-left: 0px !important; 152 | } 153 | } 154 | 155 | @media screen and (max-width: 767px) { 156 | #createPostWeb { 157 | display: block; 158 | } 159 | 160 | #postCard { 161 | display: none; 162 | } 163 | 164 | #postCardMobile { 165 | display: block; 166 | } 167 | 168 | #postCardMobile > div > :last-child button { 169 | width: auto; 170 | margin: 0; 171 | } 172 | } 173 | 174 | @media screen and (max-width: 1323px) { 175 | #postCardContent { 176 | padding-left: 72px !important; 177 | } 178 | 179 | .postMore { 180 | font-size: 20px; 181 | } 182 | 183 | .inspiration-count { 184 | font-size: 11px !important; 185 | } 186 | } 187 | -------------------------------------------------------------------------------- /pages/forgotPasswordForm.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | SE10 NETWORK 7 | 8 | 9 | 13 | 14 | 18 | 19 | 20 | 21 |
    25 |
    26 |
    30 |
    31 |
    32 |

    Reset Password

    33 |
    34 | 35 |

    Lost password? Let's recover it!

    36 |

    Reset your password

    37 | 38 |
    39 |
    43 | 49 | 50 | 51 |
    52 |
    53 | 54 |
    55 |
    59 | 65 | 66 | 67 |
    68 |
    69 | 70 |
    73 | 74 |

    75 | Got password ? Login Now. 76 |

    77 |
    78 |

    79 |
    80 |
    81 |
    82 | 87 |
    88 | 89 | 100 | 101 | Small Image 102 |
    103 | 104 | 105 | 106 | 107 | 108 | 109 | 110 | -------------------------------------------------------------------------------- /controller/NotificationPageMobileController.js: -------------------------------------------------------------------------------- 1 | import { getNotifications } from "../model/NotificationModel.js"; 2 | import { getUserData } from "../model/UserProfileModel.js"; 3 | import { getTokenValidation } from "../model/HomePageModel.js"; 4 | 5 | $(document).ready(async function () { 6 | let jwtToken = getJwtToken(); 7 | 8 | if (jwtToken) { 9 | axios.defaults.headers.common["Authorization"] = `Bearer ${jwtToken}`; 10 | 11 | try { 12 | const response = await getTokenValidation(); 13 | if (response.data === true) { 14 | try { 15 | const userData = await getUserData(); 16 | setNotificationData(userData.data); 17 | } catch (error) { 18 | console.error("Error fetching user data:", error); 19 | } 20 | } else { 21 | document.cookie = 22 | "jwt=; expires=Thu, 01 Jan 1970 00:00:00 UTC; path=/;"; 23 | window.location.href = "/index.html"; 24 | } 25 | } catch (error) { 26 | document.cookie = "jwt=; expires=Thu, 01 Jan 1970 00:00:00 UTC; path=/;"; 27 | console.error("Token validation failed:", error); 28 | window.location.href = "/index.html"; 29 | } 30 | } else { 31 | document.cookie = "jwt=; expires=Thu, 01 Jan 1970 00:00:00 UTC; path=/;"; 32 | window.location.href = "/index.html"; 33 | } 34 | }); 35 | 36 | function getJwtToken() { 37 | const cookies = document.cookie.split("; "); 38 | for (let cookie of cookies) { 39 | if (cookie.startsWith("jwt=")) { 40 | return cookie.split("=")[1]; 41 | } 42 | } 43 | return null; 44 | } 45 | 46 | async function setNotificationData(user) { 47 | try { 48 | const notificationData = await getNotifications(user.userId); 49 | if (notificationData.length === 0) { 50 | $(".recent-list").html( 51 | "
    You haven't any notifications
    " 52 | ); 53 | } else { 54 | setNotifications(notificationData); 55 | } 56 | } catch (error) { 57 | console.error("Error fetching user data:", error); 58 | } 59 | } 60 | 61 | function setNotifications(notificationData) { 62 | for (let notification of notificationData) { 63 | let notificationElement = createNotificationElement(notification); 64 | $(".recent-list").append(notificationElement); 65 | } 66 | } 67 | 68 | function createNotificationElement(notification) { 69 | let notificationIcon = $(""); 70 | notificationIcon.addClass("avatar"); 71 | if (notification.type === "APPROVED") { 72 | notificationIcon 73 | .attr("src", "/assets/icons/notificationIcon/approved.png") 74 | .attr("alt", "Post Approved Icon"); 75 | } else if (notification.type === "upgrade") { 76 | notificationIcon 77 | .attr("src", "/assets/icons/notificationIcon/system_update.png") 78 | .attr("alt", "System Update Icon"); 79 | } else if (notification.type === "deleted") { 80 | notificationIcon 81 | .attr("src", "/assets/icons/notificationIcon/deleted.png") 82 | .attr("alt", "Post Deleted Icon"); 83 | } else if (notification.type === "inspirations") { 84 | notificationIcon 85 | .attr("src", "/assets/icons/notificationIcon/inspiration.png") 86 | .attr("alt", "Inspiration Icon"); 87 | } else if (notification.type === "pendingApproval") { 88 | } else if (notification.type === "friendRequestRejected") { 89 | } else { 90 | } 91 | 92 | let imageElement = $("
    ") 93 | .addClass("avatar d-flex justify-content-center") 94 | .append(notificationIcon); 95 | 96 | let notificationText = $("
    ") 97 | .addClass("text") 98 | .append($("

    ").css("font-size", "11px").text(notification.content)); 99 | let notificationElement = $("

    ") 100 | .addClass("notification") 101 | .append( 102 | $("
    ") 103 | .addClass("notification-item border-0") 104 | .append(imageElement, notificationText) 105 | ); 106 | 107 | return $("
  • ") 108 | .addClass("notification") 109 | .append(notificationElement) 110 | .css("box-shadow", "0 4px 18.3px 0 rgba(0, 0, 0, 0.05)"); 111 | } 112 | -------------------------------------------------------------------------------- /pages/mobileHomePage.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 15 | SE10 NETWORK 16 | 17 | 18 | 19 |
    20 |
    21 |

    Home

    22 |

    Approve

    23 |
    24 | 25 | 26 |
    27 |
    Post Something
    28 |
    29 | Profile Image 34 |
    35 | 42 | 46 | Send Post Icon 50 | 51 |
    52 |
    53 |
    54 | 55 |
    56 |
    Post Something
    57 |
    60 | Profile Image 66 | 67 |
    68 | 76 | 80 | Send Post Icon 85 | 86 |
    87 |
    88 |
    89 | 90 |
    91 |
    92 | 93 | 94 | 95 | 96 | 97 | 101 | 102 | 106 | 107 | 108 | -------------------------------------------------------------------------------- /components/css/wall/MyPostWallComponent.css: -------------------------------------------------------------------------------- 1 | body { 2 | background-color: var(--bg-color); 3 | margin: 0; 4 | padding: 0; 5 | border-radius: 15px; 6 | background-clip: content-box; 7 | box-shadow: 0px 4px 18.3px 0px rgba(0, 0, 0, 0.1); 8 | } 9 | 10 | body::-webkit-scrollbar { 11 | width: 0; 12 | } 13 | 14 | .profile-wall * { 15 | font-family: "Poppins", sans-serif; 16 | } 17 | 18 | .profile-banner { 19 | height: 35vh; 20 | min-height: 200px; 21 | max-height: 400px; 22 | position: relative; 23 | border-radius: 10px; 24 | } 25 | 26 | .profile-wall { 27 | padding-bottom: 2%; 28 | border-radius: 15px; 29 | background: var(--bg-color); 30 | box-sizing: border-box; 31 | } 32 | 33 | .profile-banner .img-fluid { 34 | width: 100%; 35 | height: 100%; 36 | object-fit: cover; 37 | } 38 | 39 | .profile-banner .btn-edit-cover { 40 | position: absolute; 41 | bottom: 30px; 42 | right: 30px; 43 | padding: 8px 15px; 44 | background-color: rgba(255, 255, 255, 0.8); 45 | border: none; 46 | border-radius: 5px; 47 | cursor: pointer; 48 | transition: background-color 0.3s ease; 49 | font-size: 14px; 50 | color: #000; 51 | } 52 | 53 | #btn-Edit { 54 | border-radius: 100%; 55 | } 56 | 57 | .details-container { 58 | bottom: 30px; 59 | position: relative; 60 | } 61 | 62 | .profile-pic { 63 | width: 150px; 64 | height: 150px; 65 | object-fit: cover; 66 | border: 5px solid white; 67 | border-radius: 50%; 68 | } 69 | 70 | .profile-info h1 { 71 | font-size: 25px; 72 | font-weight: 700; 73 | margin: 0; 74 | margin-top: 10%; 75 | } 76 | 77 | .profile-info h3 { 78 | font-size: 15px; 79 | margin: 0; 80 | } 81 | 82 | .profile-info h4 { 83 | font-size: 18px; 84 | color: var(--text-color); 85 | margin: 10px 0 0 0; 86 | } 87 | 88 | .btn-light { 89 | background-color: rgba(241, 235, 235, 0.8); 90 | border: 1px solid rgb(187, 186, 186); 91 | border-radius: 5px; 92 | padding: 8px 15px; 93 | cursor: pointer; 94 | transition: background-color 0.3s ease; 95 | } 96 | 97 | .btn-light:hover { 98 | background-color: rgba(255, 255, 255, 1); 99 | } 100 | 101 | #edit-info-btn { 102 | font-size: 0.8rem; 103 | gap: 20px; 104 | } 105 | 106 | .information-container { 107 | margin: 0 3%; 108 | } 109 | 110 | .info-box { 111 | background-color: white; 112 | border-radius: 8px; 113 | box-shadow: 0 0 22.9px -6px rgba(0, 0, 0, 0.1); 114 | } 115 | 116 | .form-control:focus { 117 | box-shadow: none !important; 118 | } 119 | 120 | .info-box h5 { 121 | font-size: 16px; 122 | font-weight: bold; 123 | } 124 | 125 | .profile-wall input { 126 | color: #000; 127 | } 128 | 129 | #popupModal { 130 | transition: opacity 0.3s ease, top 0.3s ease; 131 | opacity: 0; 132 | } 133 | 134 | #popupModal.active { 135 | opacity: 1; 136 | } 137 | 138 | @media screen and (max-width: 576px) { 139 | .profile-info h4 { 140 | font-size: 15px; 141 | margin-top: 5px; 142 | padding-right: 30px; 143 | } 144 | 145 | #edit-info-btn { 146 | margin-left: 20px; 147 | margin-top: 15px; 148 | width: 100%; 149 | } 150 | } 151 | 152 | @media screen and (max-width: 768px) { 153 | .profile-banner { 154 | height: 25vh; 155 | } 156 | 157 | .btn-edit-cover { 158 | display: none; 159 | } 160 | 161 | .flex-column { 162 | flex-direction: column !important; 163 | align-items: flex-start !important; 164 | } 165 | 166 | .profile-pic { 167 | margin-top: -60px; 168 | } 169 | 170 | .profile-info { 171 | text-align: left !important; 172 | width: 100%; 173 | margin-top: 10px; 174 | } 175 | 176 | .profile-info h1, 177 | .profile-info h3, 178 | .profile-info h4 { 179 | width: 100%; 180 | margin-left: 20px; 181 | } 182 | 183 | .profile-info h1 { 184 | font-size: 25px; 185 | margin-top: 5px; 186 | } 187 | 188 | .profile-info h3 { 189 | font-size: 13px; 190 | margin-top: 5px; 191 | } 192 | 193 | .profile-info h4 { 194 | font-size: 16px; 195 | margin-top: 5px; 196 | } 197 | 198 | #edit-info-btn { 199 | margin-left: 20px; 200 | margin-top: 15px; 201 | width: 100%; 202 | } 203 | } 204 | 205 | @media screen and (min-width: 992px) { 206 | #edit-info-btn { 207 | margin-left: auto; 208 | margin-right: 15px; 209 | display: block; 210 | } 211 | } 212 | -------------------------------------------------------------------------------- /components/pages/wall/myPostWallComponent.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | MY-POST-PAGE 7 | 8 | 9 | 10 | 11 | 12 | 16 | 17 | 18 | 22 | 26 | 27 | 28 | 29 | 30 |
    31 |
    32 |
    33 | Cover Photo 38 |
    39 | 40 |
    44 |
    45 | Profile Picture 50 |
    51 |
    54 |

    55 |

    56 |

    57 |
    58 |
    59 |
    60 | 61 |
    62 |
    63 | 64 |
    65 |
    66 |
    67 |
    68 | 69 | 70 | 85 | 86 | 87 | 99 |
    100 | 101 | 102 | 103 | 104 | 105 | 109 | 110 | 111 | -------------------------------------------------------------------------------- /controller/LoginPageController.js: -------------------------------------------------------------------------------- 1 | import { postLoginData } from "../model/LoginFormModel.js"; 2 | 3 | document.addEventListener("DOMContentLoaded", function () { 4 | 5 | //Validations checks 6 | $("#email").attr({ 7 | type: "email", 8 | required: true, 9 | }); 10 | 11 | $("#password").attr({ 12 | minlength: "8", 13 | required: true, 14 | }); 15 | 16 | localStorage.removeItem("email"); 17 | localStorage.removeItem("newPassword"); 18 | const jwtToken = getJwtToken(); 19 | 20 | if (jwtToken) { 21 | axios.defaults.headers.common["Authorization"] = `Bearer ${jwtToken}`; 22 | window.location.href = "/pages/homePage.html"; 23 | } else { 24 | // No token found, load the login page 25 | loadLoginPage(); 26 | } 27 | }); 28 | 29 | function getJwtToken() { 30 | const cookies = document.cookie.split("; "); 31 | for (let cookie of cookies) { 32 | if (cookie.startsWith("jwt=")) { 33 | return cookie.split("=")[1]; 34 | } 35 | } 36 | return null; 37 | } 38 | 39 | function loadLoginPage() { 40 | const passwordInput = document.getElementById("password"); 41 | const togglePassword = document.getElementById("togglePassword"); 42 | const loginForm = document.getElementById("login"); 43 | const emailField = document.getElementById("email"); 44 | 45 | togglePassword.addEventListener("click", function () { 46 | // Toggle the type attribute 47 | const type = 48 | passwordInput.getAttribute("type") === "password" ? "text" : "password"; 49 | passwordInput.setAttribute("type", type); 50 | 51 | // Toggle the icon 52 | this.classList.toggle("ri-eye-line"); 53 | this.classList.toggle("ri-eye-off-line"); 54 | }); 55 | 56 | document.getElementById("register").addEventListener("click", function () { 57 | window.location.href = "pages/registrationForm.html"; 58 | }); 59 | 60 | loginForm.addEventListener("submit", async function (event) { 61 | event.preventDefault(); 62 | const email = emailField.value; 63 | const password = passwordInput.value; 64 | 65 | try { 66 | const response = await postLoginData({ email, password }); 67 | if (response.status === 200) { 68 | document.cookie = `jwt=${response.data.data.token}; path=/`; 69 | window.location.href = "pages/homePage.html"; 70 | } else { 71 | Toastify({ 72 | text: "Login failed. Please check your email and password.", 73 | duration: 3000, 74 | gravity: "top", 75 | position: "right", 76 | backgroundColor: "#ff0000", 77 | close: true, 78 | stopOnFocus: true, 79 | }).showToast(); 80 | } 81 | } catch (error) { 82 | console.error("Login error:", error); 83 | if (error.response.status === 401) { 84 | Toastify({ 85 | text: "Login failed. Please check your email and password.", 86 | duration: 3000, 87 | gravity: "top", 88 | position: "right", 89 | backgroundColor: "#ff0000", 90 | close: true, 91 | stopOnFocus: true, 92 | }).showToast(); 93 | } else { 94 | Toastify({ 95 | text: "An error occurred during login. Please try again later.", 96 | duration: 3000, 97 | gravity: "top", 98 | position: "right", 99 | backgroundColor: "#ff0000", 100 | close: true, 101 | stopOnFocus: true, 102 | }).showToast(); 103 | } 104 | } 105 | }); 106 | 107 | document 108 | .getElementById("forgot-password-link") 109 | .addEventListener("click", function () { 110 | if (!emailField.value) { 111 | Toastify({ 112 | text: "Please enter your email address.", 113 | duration: 3000, 114 | gravity: "top", 115 | position: "right", 116 | backgroundColor: "#ff0000", 117 | close: true, 118 | stopOnFocus: true, 119 | }).showToast(); 120 | return; 121 | } else if (!emailField.checkValidity()) { 122 | Toastify({ 123 | text: "Please enter a valid email address.", 124 | duration: 3000, 125 | gravity: "top", 126 | position: "right", 127 | backgroundColor: "#ff0000", 128 | close: true, 129 | stopOnFocus: true, 130 | }).showToast(); 131 | return; 132 | } else { 133 | localStorage.setItem("email", emailField.value); 134 | window.location.href = "/pages/forgotPasswordForm.html"; 135 | } 136 | }); 137 | } 138 | -------------------------------------------------------------------------------- /model/UserProfileModel.js: -------------------------------------------------------------------------------- 1 | export const getUserData = () => { 2 | let config = { 3 | method: "get", 4 | maxBodyLength: Infinity, 5 | url: `http://localhost:8080/api/v1/user`, 6 | }; 7 | 8 | return axios(config) 9 | .then((response) => { 10 | console.log("Data Retrieved successfully:", response.status); 11 | return response; 12 | }) 13 | .catch((error) => { 14 | console.error("Data Retrieval failed:", error); 15 | throw error; 16 | }); 17 | }; 18 | 19 | export const getUserProfilePhoto = () => { 20 | let config = { 21 | method: "get", 22 | maxBodyLength: Infinity, 23 | url: "http://localhost:8080/api/v1/user/profileImg", 24 | }; 25 | 26 | return axios(config) 27 | .then((response) => { 28 | console.log("Data Retrieved successfully"); 29 | return response.data; 30 | }) 31 | .catch((error) => { 32 | console.error("Data Retrieval failed:", error); 33 | throw error; 34 | }); 35 | }; 36 | 37 | export const updateUserData = (data) => { 38 | let config = { 39 | method: "put", 40 | maxBodyLength: Infinity, 41 | url: "http://localhost:8080/api/v1/user", 42 | data: data, 43 | }; 44 | 45 | return axios(config) 46 | .then((response) => { 47 | console.log("Update successful:", response.status); 48 | return response; 49 | }) 50 | .catch((error) => { 51 | if (error.response && error.response.data) { 52 | return Promise.reject({ 53 | code: error.response.data.code, 54 | message: error.response.data.message, 55 | }); 56 | } else { 57 | return Promise.reject(error); 58 | } 59 | }); 60 | }; 61 | 62 | export const deleteUser = (id) => { 63 | let config = { 64 | method: "delete", 65 | maxBodyLength: Infinity, 66 | url: `http://localhost:8080/api/v1/user/${id}`, 67 | }; 68 | 69 | return axios(config) 70 | .then((response) => { 71 | console.log("Delete successful!"); 72 | return response; 73 | }) 74 | .catch((error) => { 75 | console.error("Delete failed:", error); 76 | throw error; 77 | }); 78 | }; 79 | 80 | export const updateUserPhoto = (formData) => { 81 | let config = { 82 | method: "put", 83 | maxBodyLength: Infinity, 84 | url: "http://localhost:8080/api/v1/user/image", 85 | data: formData, 86 | }; 87 | 88 | return axios(config) 89 | .then((response) => { 90 | console.log("Update successful:", response.status); 91 | return response; 92 | }) 93 | .catch((error) => { 94 | console.error("Update failed:", error); 95 | throw error; 96 | }); 97 | }; 98 | 99 | export const updateUserPassword = (email, newPassword, otp) => { 100 | let config = { 101 | method: "put", 102 | maxBodyLength: Infinity, 103 | url: `http://localhost:8080/api/v1/auth/update_password`, 104 | data: { email, newPassword, otp }, 105 | }; 106 | 107 | return axios(config) 108 | .then((response) => { 109 | console.log("Password update successful:", response.status); 110 | return response; 111 | }) 112 | .catch((error) => { 113 | console.error("Password update failed:", error); 114 | throw error; 115 | }); 116 | }; 117 | 118 | export const deleteUserData = (id) => { 119 | let config = { 120 | method: "delete", 121 | maxBodyLength: Infinity, 122 | url: `http://localhost:8080/api/v1/user/${id}`, 123 | }; 124 | 125 | return axios(config) 126 | .then((response) => { 127 | console.log("Delete successful:", response.status); 128 | return response; 129 | }) 130 | .catch((error) => { 131 | console.error("Delete failed:", error); 132 | throw error; 133 | }); 134 | }; 135 | 136 | export const deleteUserPhoto = (data) => { 137 | let config = { 138 | method: "delete", 139 | maxBodyLength: Infinity, 140 | url: "http://localhost:8080/api/v1/user/image", 141 | data: data, 142 | }; 143 | 144 | return axios(config) 145 | .then((response) => { 146 | console.log("Delete successful:", response.status); 147 | return response; 148 | }) 149 | .catch((error) => { 150 | console.error("Delete failed:", error); 151 | throw error; 152 | }); 153 | }; 154 | 155 | export const getFriendData = (email) => { 156 | let config = { 157 | method: "get", 158 | maxBodyLength: Infinity, 159 | url: `http://localhost:8080/api/v1/user/${email}`, 160 | }; 161 | 162 | return axios(config) 163 | .then((response) => { 164 | console.log("Data Retrieved successfully:", response.status); 165 | return response; 166 | }) 167 | .catch((error) => { 168 | console.error("Data Retrieval failed:", error); 169 | throw error; 170 | }); 171 | }; 172 | -------------------------------------------------------------------------------- /controller/forgotPasswordOtpVerifyPageController.js: -------------------------------------------------------------------------------- 1 | import { postDataForOtp } from "../model/VerificationFormModel.js"; 2 | import { updateUserPassword } from "../model/UserProfileModel.js"; 3 | 4 | $(document).ready(function () { 5 | //Add validation 6 | $(".otp-input").each(function () { 7 | $(this).attr("required", true); 8 | }); 9 | 10 | const email = localStorage.getItem("email"); 11 | const newPassword = localStorage.getItem("newPassword"); 12 | 13 | if (!postData("", email)) 14 | Toastify({ 15 | text: "Failed to send data. Please try again.", 16 | duration: 3000, 17 | gravity: "top", 18 | position: "right", 19 | backgroundColor: "#ff0000", 20 | close: true, 21 | stopOnFocus: true, 22 | }).showToast(); 23 | 24 | $(".otp-input").each(function (index, input) { 25 | $(input).on("input", function () { 26 | if ($(input).val().length >= 1 && index < $(".otp-input").length - 1) { 27 | $($(".otp-input")[index + 1]).focus(); 28 | } 29 | 30 | if ($(input).val().length === 0 && index > 0) { 31 | $($(".otp-input")[index - 1]).focus(); 32 | } 33 | }); 34 | }); 35 | 36 | $(".Reset-Password").submit(async function (event) { 37 | event.preventDefault(); 38 | 39 | if (this.checkValidity()) { 40 | let otpValues = []; 41 | $(".otp-input").each(function () { 42 | otpValues.push($(this).val().trim()); 43 | }); 44 | 45 | if (otpValues.length > 0) { 46 | const combinedOtp = otpValues.join(""); 47 | const isUpdated = await updatePassword(email, newPassword, combinedOtp); 48 | if (isUpdated) { 49 | Toastify({ 50 | text: "Password updated successfully!", 51 | duration: 3000, 52 | gravity: "top", 53 | position: "center", 54 | backgroundColor: "#00b09b", 55 | close: true, 56 | stopOnFocus: true, 57 | }).showToast(); 58 | localStorage.removeItem("email"); 59 | localStorage.removeItem("newPassword"); 60 | window.location.href = "/index.html"; 61 | } 62 | 63 | $(".otp-field").each(function () { 64 | $(this).val(""); 65 | }); 66 | } else { 67 | Toastify({ 68 | text: "No OTP values entered.", 69 | duration: 3000, 70 | gravity: "top", 71 | position: "right", 72 | backgroundColor: "#ff0000", 73 | close: true, 74 | stopOnFocus: true, 75 | }).showToast(); 76 | } 77 | } else { 78 | this.reportValidity(); 79 | } 80 | }); 81 | 82 | $("#resend").on("click", function (event) { 83 | event.preventDefault(); 84 | 85 | if (!postData("", email)) 86 | Toastify({ 87 | text: "Failed to send data. Please try again.", 88 | duration: 3000, 89 | gravity: "top", 90 | position: "right", 91 | backgroundColor: "#ff0000", 92 | close: true, 93 | stopOnFocus: true, 94 | }).showToast(); 95 | else { 96 | $(".otp-input").each(function () { 97 | $(this).val(""); 98 | }); 99 | } 100 | }); 101 | }); 102 | 103 | const updatePassword = async (email, password, otp) => { 104 | try { 105 | const response = await updateUserPassword(email, password, otp); 106 | return response.status === 204 ? true : false; 107 | } catch (error) { 108 | console.error("Error updating password:", error); 109 | if (error.response.status === 400) 110 | Toastify({ 111 | text: "Invalid OTP. Please try again.", 112 | duration: 3000, 113 | gravity: "top", 114 | position: "right", 115 | backgroundColor: "#ff0000", 116 | close: true, 117 | stopOnFocus: true, 118 | }).showToast(); 119 | else if (error.response.status === 404) 120 | Toastify({ 121 | text: "User not found.", 122 | duration: 3000, 123 | gravity: "top", 124 | position: "right", 125 | backgroundColor: "#ff0000", 126 | close: true, 127 | stopOnFocus: true, 128 | }).showToast(); 129 | else 130 | Toastify({ 131 | text: "Error updating password", 132 | duration: 3000, 133 | gravity: "top", 134 | position: "right", 135 | backgroundColor: "#ff0000", 136 | close: true, 137 | stopOnFocus: true, 138 | }).showToast(); 139 | return false; 140 | } 141 | }; 142 | 143 | const postData = async (name, email) => { 144 | try { 145 | const otpResponse = await postDataForOtp(name, email); 146 | return otpResponse.status === 200 ? true : false; 147 | } catch (error) { 148 | console.error("Error sending data:", error); 149 | return false; 150 | } 151 | }; 152 | -------------------------------------------------------------------------------- /components/css/AdminApprovePostCardComponent.css: -------------------------------------------------------------------------------- 1 | #buttonAdmin { 2 | margin-left: 100%; 3 | } 4 | 5 | #postCard { 6 | background-color: #ffffff; 7 | box-shadow: 0 4px 18.3px 0 rgba(0, 0, 0, 0.05); 8 | border-radius: 10px; 9 | display: flex; 10 | flex-direction: column; 11 | justify-content: space-between; 12 | height: auto; 13 | padding: 20px; 14 | } 15 | 16 | #postCard .content { 17 | flex-grow: 1; 18 | } 19 | 20 | #postCard .actions { 21 | display: flex; 22 | justify-content: flex-end; 23 | gap: 10px; 24 | margin-top: 10px; 25 | } 26 | 27 | #postCard .profileImage { 28 | width: 55px; 29 | height: 55px; 30 | border: 2px solid #c0c0c0; 31 | border-radius: 50%; 32 | } 33 | 34 | #postCard img { 35 | width: 21px; 36 | } 37 | 38 | #postCard h5 { 39 | color: #505050; 40 | font-family: "Poppins", sans-serif; 41 | font-size: 20px; 42 | font-weight: 600; 43 | } 44 | 45 | #postCard h6 { 46 | color: #ccc; 47 | font-family: "Poppins", sans-serif; 48 | font-size: 13px; 49 | font-weight: 600; 50 | } 51 | 52 | #postCard p { 53 | color: #000; 54 | font-family: "Poppins", sans-serif; 55 | font-size: 13px; 56 | font-weight: 500; 57 | } 58 | 59 | #postCard > div > :last-child img { 60 | width: 18px; 61 | height: 18px; 62 | } 63 | 64 | #postCard > div > :last-child span { 65 | color: rgba(0, 0, 0, 0.5); 66 | font-family: "Poppins", sans-serif; 67 | font-size: 13px; 68 | font-weight: 400; 69 | } 70 | 71 | #postCard > div > :last-child button span { 72 | color: #000; 73 | font-family: "Poppins", sans-serif; 74 | font-size: 12px; 75 | font-weight: 700; 76 | } 77 | 78 | #more-icon img { 79 | transition: transform 0.3s ease; 80 | } 81 | 82 | @media (max-width: 320px) { 83 | #decline { 84 | height: 25px; 85 | } 86 | 87 | #approve { 88 | height: 25px; 89 | } 90 | 91 | #approve { 92 | right: 5px; 93 | } 94 | 95 | #profile-img { 96 | width: 10px; 97 | } 98 | 99 | #postCard .profileImage { 100 | width: 30px; 101 | height: 30px; 102 | border: 1px solid #c0c0c0; 103 | } 104 | 105 | #postCard p { 106 | font-size: 10px; 107 | } 108 | 109 | #postCard h6 { 110 | font-size: 9px; 111 | } 112 | 113 | #postCard h5 { 114 | font-size: 16px; 115 | } 116 | 117 | #postCard > div > :last-child button span { 118 | font-size: 9px; 119 | font-weight: 700; 120 | } 121 | } 122 | 123 | @media (max-width: 375px) { 124 | #decline { 125 | width: 90px; 126 | height: 35px; 127 | } 128 | 129 | #approve { 130 | width: 90px; 131 | height: 35px; 132 | } 133 | 134 | #approve { 135 | right: 80px; 136 | } 137 | 138 | #profile-img { 139 | width: 15px; 140 | } 141 | 142 | #postCard .profileImage { 143 | width: 45px; 144 | height: 45px; 145 | border: 1px solid #c0c0c0; 146 | } 147 | 148 | #postCard p { 149 | font-size: 12px; 150 | } 151 | 152 | #postCard h6 { 153 | font-size: 12px; 154 | } 155 | 156 | #postCard h5 { 157 | font-size: 18px; 158 | } 159 | 160 | #postCard > div > :last-child button span { 161 | font-size: 12px; 162 | font-weight: 700; 163 | } 164 | } 165 | 166 | @media (max-width: 425px) { 167 | #decline { 168 | width: 90px; 169 | height: 35px; 170 | } 171 | 172 | #approve { 173 | width: 90px; 174 | height: 35px; 175 | } 176 | 177 | #approve { 178 | right: 80px; 179 | } 180 | 181 | #profile-img { 182 | width: 15px; 183 | } 184 | 185 | #postCard .profileImage { 186 | width: 45px; 187 | height: 45px; 188 | border: 1px solid #c0c0c0; 189 | } 190 | 191 | #postCard p { 192 | font-size: 12px; 193 | } 194 | 195 | #postCard h6 { 196 | font-size: 12px; 197 | } 198 | 199 | #postCard h5 { 200 | font-size: 18px; 201 | } 202 | 203 | #postCard > div > :last-child button span { 204 | font-size: 12px; 205 | font-weight: 700; 206 | } 207 | 208 | #more-icon img { 209 | transform: rotate(90deg); 210 | } 211 | } 212 | 213 | @media (min-width: 426px) { 214 | #decline { 215 | width: 90px; 216 | height: 35px; 217 | } 218 | 219 | #approve { 220 | width: 90px; 221 | height: 35px; 222 | right: 80px; 223 | } 224 | 225 | #profile-img { 226 | width: 15px; 227 | } 228 | 229 | #postCard .profileImage { 230 | width: 45px; 231 | height: 45px; 232 | border: 1px solid #c0c0c0; 233 | } 234 | 235 | #postCard p { 236 | font-size: 12px; 237 | } 238 | 239 | #postCard h6 { 240 | font-size: 12px; 241 | } 242 | 243 | #postCard h5 { 244 | font-size: 18px; 245 | } 246 | 247 | #postCard > div > :last-child button span { 248 | font-size: 12px; 249 | font-weight: 700; 250 | } 251 | } 252 | 253 | @media (min-width: 2559px) { 254 | #decline { 255 | position: absolute; 256 | right: 190px; 257 | } 258 | 259 | #approve { 260 | position: absolute; 261 | right: 58px; 262 | } 263 | } 264 | -------------------------------------------------------------------------------- /pages/registrationForm.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | SE10 NETWORK 7 | 8 | 9 | 13 | 14 | 15 | 16 |
    20 |
    21 |
    22 |
    23 |
    24 |
    25 |

    Registration Form 01

    26 |
    27 | 28 | 33 |
    34 | 35 |

    Where ideas meet execution

    36 |

    Fill the form to access the portal

    37 | 38 |
    39 | 45 | 46 |
    47 | 48 |
    49 | 50 | 51 |
    52 | 53 |
    54 | 55 | 56 |
    57 | 58 |
    59 | 67 | 68 |
    69 | 70 | 71 |
    72 | 77 |
    78 | 79 |
    80 |
    81 | 87 | 88 | 89 |
    90 |
    91 | 97 | 98 | 99 |
    100 |
    101 | 102 |
    103 | 104 |

    105 | Have an account ? Login Now. 106 |

    107 |
    108 |
    109 |
    110 | 111 |
    112 | 113 | 118 | 119 |
    120 | 121 |
    122 | 123 | 124 |
    125 |
    126 |
    127 | 128 | Small Image 133 |
    134 | 135 | 136 | 137 | 138 | 139 | 140 | -------------------------------------------------------------------------------- /model/PostCardModel.js: -------------------------------------------------------------------------------- 1 | // --- save post (create-post-card) --- 2 | export const savePost = (data) => { 3 | let config = { 4 | method: "post", 5 | maxBodyLength: Infinity, 6 | url: "http://localhost:8080/api/v1/post", 7 | headers: { 8 | "Content-Type": "application/json", 9 | }, 10 | data: data, 11 | }; 12 | 13 | return axios(config) 14 | .then((response) => { 15 | console.log("Post saved successfully:", response.status); 16 | return response; 17 | }) 18 | .catch((error) => { 19 | console.error("Unable to save the post:", error); 20 | throw error; 21 | }); 22 | }; 23 | 24 | // --- update post --- 25 | export const updatePost = (id, content) => { 26 | let config = { 27 | method: "put", 28 | maxBodyLength: Infinity, 29 | url: `http://localhost:8080/api/v1/post/${id}`, 30 | headers: { 31 | "Content-Type": "text/plain", 32 | }, 33 | data: content, 34 | }; 35 | 36 | return axios(config) 37 | .then((response) => { 38 | console.log("Post update successfully:", response.status); 39 | return response; 40 | }) 41 | .catch((error) => { 42 | console.error("Unable to update the post:", error); 43 | throw error; 44 | }); 45 | }; 46 | 47 | // --- approve or decline a post --- 48 | export const approveOrDeclinePost = (postId, status) => { 49 | let config = { 50 | method: "put", 51 | maxBodyLength: Infinity, 52 | url: `http://localhost:8080/api/v1/post/${postId}/status?status=${status}`, 53 | }; 54 | 55 | return axios(config) 56 | .then((response) => { 57 | console.log("Post status changed successfully:", response.status); 58 | return response; 59 | }) 60 | .catch((error) => { 61 | console.error("Unable to change staus of the post:", error); 62 | throw error; 63 | }); 64 | }; 65 | 66 | // --- get post data --- 67 | export const getPostData = (postId) => { 68 | let config = { 69 | method: "get", 70 | maxBodyLength: Infinity, 71 | url: `http://localhost:8080/api/v1/post/${postId}`, 72 | }; 73 | 74 | return axios(config) 75 | .then((response) => { 76 | console.log("Post fetched successfully:", response.status); 77 | return response; 78 | }) 79 | .catch((error) => { 80 | console.error("Unable to find the post:", error); 81 | throw error; 82 | }); 83 | }; 84 | 85 | // --- get all posts --- 86 | export const getAllPosts = (pageNo) => { 87 | let config = { 88 | method: "get", 89 | maxBodyLength: Infinity, 90 | url: `http://localhost:8080/api/v1/post?pageNo=${pageNo}&postCount=10`, 91 | }; 92 | 93 | return axios(config) 94 | .then((response) => { 95 | console.log("Posts fetched successfully:", response.status); 96 | return response; 97 | }) 98 | .catch((error) => { 99 | console.error("Unable to find the posts:", error); 100 | throw error; 101 | }); 102 | }; 103 | 104 | // --- get all posts of a user --- 105 | export const getAllPostsOfUser = (pageNo) => { 106 | let config = { 107 | method: "get", 108 | maxBodyLength: Infinity, 109 | url: `http://localhost:8080/api/v1/post/user?pageNo=${pageNo}&postCount=10`, 110 | }; 111 | 112 | return axios(config) 113 | .then((response) => { 114 | console.log("Posts fetched successfully:", response.status); 115 | return response; 116 | }) 117 | .catch((error) => { 118 | console.error("Unable to find the posts:", error); 119 | throw error; 120 | }); 121 | }; 122 | 123 | // --- get all unapproved posts --- 124 | export const getUnapprovedPosts = (pageNo) => { 125 | let config = { 126 | method: "get", 127 | maxBodyLength: Infinity, 128 | url: `http://localhost:8080/api/v1/post/unapproved?pageNo=${pageNo}&postCount=10`, 129 | }; 130 | 131 | return axios(config) 132 | .then((response) => { 133 | console.log("Unapproved posts fetched successfully:", response.status); 134 | return response; 135 | }) 136 | .catch((error) => { 137 | console.error("Unable to find the unapproved posts:", error); 138 | throw error; 139 | }); 140 | }; 141 | 142 | // --- delete post --- 143 | export const deletePost = (postId) => { 144 | let config = { 145 | method: "delete", 146 | maxBodyLength: Infinity, 147 | url: `http://localhost:8080/api/v1/post/${postId}`, 148 | }; 149 | 150 | return axios(config) 151 | .then((response) => { 152 | console.log("Post deleted successfully:", response.status); 153 | return response; 154 | }) 155 | .catch((error) => { 156 | console.log("Post delete failed:", error); 157 | return error; 158 | }); 159 | }; 160 | 161 | // --- get all posts of a friend --- 162 | export const getAllFriendPosts = (pageNo, email) => { 163 | let config = { 164 | method: "get", 165 | maxBodyLength: Infinity, 166 | url: `http://localhost:8080/api/v1/post/userPosts?pageNo=${pageNo}&postCount=10&email=${email}`, 167 | }; 168 | 169 | return axios(config) 170 | .then((response) => { 171 | console.log("Posts fetched successfully:", response.status); 172 | return response; 173 | }) 174 | .catch((error) => { 175 | console.error("Unable to find the posts:", error); 176 | throw error; 177 | }); 178 | }; 179 | -------------------------------------------------------------------------------- /controller/RegistrationFormController.js: -------------------------------------------------------------------------------- 1 | $(document).ready(function () { 2 | // Array of batch options 3 | const batches = [ 4 | "GDSE 67", 5 | "GDSE 68", 6 | "GDSE 69", 7 | "GDSE 70", 8 | "GDSE 71", 9 | "GDSE 72", 10 | "GDSE 73", 11 | "GDSE 74", 12 | ]; 13 | 14 | // Populate the select element with batch options(Desktop) 15 | $("#batchSelect").append( 16 | $("
  • ").addClass( 113 | "d-flex justify-content-between align-items-center" 114 | ).html(` 115 |
    116 | 121 | ${user.name} 122 |
    123 | 124 | `); 125 | listItem.data("user", user); 126 | $recentList.append(listItem); 127 | }); 128 | } 129 | 130 | function displayNoResults() { 131 | $recentList.html('
  • No results found
  • '); 132 | } 133 | 134 | function displayError() { 135 | $recentList.html( 136 | '
  • An error occurred. Please try again.
  • ' 137 | ); 138 | } 139 | 140 | function clearResults() { 141 | $recentList.empty(); 142 | } 143 | 144 | function handleScroll() { 145 | const scrollTop = $recentList.scrollTop(); 146 | const scrollHeight = $recentList[0].scrollHeight; 147 | const clientHeight = $recentList.height(); 148 | 149 | if ( 150 | scrollTop + clientHeight >= scrollHeight - 5 && 151 | !isLoading && 152 | hasMoreResults 153 | ) { 154 | console.log("Loading more results"); 155 | fetchAndDisplayResults(); 156 | } 157 | } 158 | 159 | function adjustPopupHeight(resultCount) { 160 | const baseHeight = 100; 161 | const itemHeight = 50; 162 | const maxHeight = 400; 163 | 164 | let newHeight = baseHeight + resultCount * itemHeight; 165 | newHeight = Math.min(newHeight, maxHeight); 166 | 167 | $searchPopupList.css("height", `${newHeight}px`); 168 | } 169 | 170 | function handleResultClick(event) { 171 | const $clickedItem = $(event.currentTarget).closest("li"); 172 | const userData = $clickedItem.data("user"); 173 | 174 | if (userData) { 175 | saveRecentSearch(userData); 176 | 177 | localStorage.setItem("selectedFriendEmail", userData.email); 178 | const $iframe = $("#homePage .homeWallComponent iframe"); 179 | $iframe.attr( 180 | "src", 181 | "../components/pages/wall/myFriendPostWallComponent.html" 182 | ); 183 | } 184 | } 185 | 186 | function handleRemoveClick(event) { 187 | event.stopPropagation(); 188 | const $clickedItem = $(event.target).closest("li"); 189 | const userData = $clickedItem.data("user"); 190 | 191 | if (userData) { 192 | removeRecentSearch(userData); 193 | $clickedItem.remove(); 194 | } 195 | } 196 | 197 | // Add click event listener 198 | $(document).on("click", ".remove-btn", handleRemoveClick); 199 | function removeRecentSearch(userData) { 200 | let recentSearches = JSON.parse( 201 | localStorage.getItem("recentSearches") || "[]" 202 | ); 203 | recentSearches = recentSearches.filter( 204 | (user) => user.name !== userData.name 205 | ); 206 | localStorage.setItem("recentSearches", JSON.stringify(recentSearches)); 207 | } 208 | 209 | function saveRecentSearch(userData) { 210 | let recentSearches = JSON.parse( 211 | localStorage.getItem("recentSearches") || "[]" 212 | ); 213 | 214 | const idExists = recentSearches.some((user) => user.name === userData.name); 215 | 216 | if (!idExists) { 217 | if (recentSearches.length === 5) { 218 | recentSearches.shift(); 219 | } 220 | recentSearches.push(userData); 221 | localStorage.setItem("recentSearches", JSON.stringify(recentSearches)); 222 | } 223 | } 224 | 225 | function showRecentSearches() { 226 | const recentSearches = JSON.parse( 227 | localStorage.getItem("recentSearches") || "[]" 228 | ); 229 | clearResults(); 230 | if (recentSearches.length > 0) { 231 | $searchTitle.text("Recent"); 232 | displayResults(recentSearches.reverse()); 233 | adjustPopupHeight(recentSearches.length); 234 | } else { 235 | displayNoResults(); 236 | adjustPopupHeight(1); 237 | } 238 | } 239 | 240 | initEventListeners(); 241 | }); 242 | -------------------------------------------------------------------------------- /components/css/CreatePostCardComponent.css: -------------------------------------------------------------------------------- 1 | #homeWallComponent .card { 2 | box-shadow: 0 4px 18.3px 0 rgba(0, 0, 0, 0.05); 3 | } 4 | 5 | #homeWallComponent .card .card-header { 6 | color: #000; 7 | font-family: "Poppins", sans-serif; 8 | font-size: 16px; 9 | font-weight: 600; 10 | padding: 18px 26px 14px 26px; 11 | border-bottom: 2px solid #f4f4f4; 12 | background-color: #ffffff; 13 | } 14 | 15 | #homeWallComponent .card .card-body { 16 | background-color: #ffffff; 17 | } 18 | 19 | #homeWallComponent .card .card-body > img { 20 | width: 63px; 21 | height: 63px; 22 | border: 3px solid #c0c0c0; 23 | border-radius: 50%; 24 | object-fit: cover; 25 | aspect-ratio: 1 / 1; 26 | } 27 | 28 | #homeWallComponent .input-group { 29 | border-radius: 8px; 30 | border: 1.5px solid #d5d5d5; 31 | background: #fff; 32 | box-shadow: 0 0 22.9px -6px rgba(0, 0, 0, 0.1); 33 | padding-right: 15px; 34 | } 35 | 36 | #homeWallComponent .input-group input { 37 | padding: 18px 22px; 38 | color: #949494; 39 | font-family: "Poppins", sans-serif; 40 | font-size: 13px; 41 | font-weight: 500; 42 | } 43 | 44 | #homeWallComponent .input-group input:focus{ 45 | box-shadow: none !important; 46 | } 47 | 48 | #homeWallComponent .input-group img { 49 | width: 17px; 50 | height: 17px; 51 | } 52 | 53 | body::-webkit-scrollbar { 54 | width: 0; 55 | } 56 | 57 | .menu { 58 | display: flex; 59 | align-items: center; 60 | padding: 10px; 61 | } 62 | 63 | .home-text { 64 | font-family: Arial, sans-serif; 65 | margin: 0; 66 | padding: 0; 67 | font-size: 14px; 68 | font-weight: normal; 69 | color: #7a7a7a; 70 | margin-right: 10px; 71 | } 72 | 73 | .approve-text { 74 | font-size: 30px; 75 | font-weight: bold; 76 | color: black; 77 | } 78 | 79 | .feed-text { 80 | font-family: Arial, sans-serif; 81 | margin: 0; 82 | padding: 0; 83 | font-size: 18px; 84 | font-weight: bold; 85 | color: #6b6b6b; 86 | padding: 8px; 87 | } 88 | 89 | @media (max-width: 320px) { 90 | #homeWallComponent .card .card-body > img { 91 | width: 30px; 92 | height: 30px; 93 | float: left; 94 | margin-right: 1px; 95 | } 96 | 97 | #homeWallComponent .card .card-header { 98 | font-size: 12px; 99 | font-weight: 600; 100 | padding: 18px 26px 14px 13px; 101 | border-bottom: 2px solid #f4f4f4; 102 | background-color: #ffffff; 103 | } 104 | 105 | #homeWallComponent .card .card-body { 106 | padding: 22px 10px; 107 | background-color: #ffffff; 108 | } 109 | 110 | #addon-wrapping-search { 111 | width: 2px; 112 | height: 4px; 113 | } 114 | 115 | #homeWallComponent .input-group input { 116 | padding: 10px 10px; 117 | color: #949494; 118 | font-family: "Poppins", sans-serif; 119 | font-size: 10px; 120 | font-weight: 500; 121 | } 122 | 123 | #addon-wrapping { 124 | width: 20px; 125 | height: 30px; 126 | } 127 | 128 | .home-text { 129 | font-family: Arial, sans-serif; 130 | display: flex; 131 | align-items: center; 132 | font-size: 14px; 133 | font-weight: normal; 134 | color: #7a7a7a; 135 | margin-right: 10px; 136 | } 137 | 138 | .approve-text { 139 | font-family: Arial, sans-serif; 140 | display: flex; 141 | align-items: center; 142 | font-size: 24px; 143 | font-weight: 800; 144 | color: black; 145 | } 146 | 147 | .feed-text { 148 | font-size: 15px; 149 | font-weight: 600px; 150 | } 151 | } 152 | 153 | @media (max-width: 375px) { 154 | #homeWallComponent .card .card-body > img { 155 | width: 50px; 156 | height: 50px; 157 | float: left; 158 | margin-right: 1px; 159 | } 160 | 161 | #homeWallComponent .card .card-header { 162 | font-size: 16px; 163 | font-weight: 600; 164 | padding: 18px 26px 14px 13px; 165 | border-bottom: 2px solid #f4f4f4; 166 | background-color: #ffffff; 167 | } 168 | 169 | #homeWallComponent .card .card-body { 170 | padding: 22px 10px; 171 | background-color: #ffffff; 172 | } 173 | 174 | #addon-wrapping-search { 175 | width: 6px; 176 | height: 7px; 177 | } 178 | 179 | #homeWallComponent .input-group input { 180 | padding: 10px 10px; 181 | color: #949494; 182 | font-family: "Poppins", sans-serif; 183 | font-size: 12px; 184 | font-weight: 500; 185 | } 186 | 187 | #addon-wrapping { 188 | width: 25px; 189 | height: 35px; 190 | } 191 | 192 | .home-text { 193 | font-family: Arial, sans-serif; 194 | display: flex; 195 | align-items: center; 196 | font-size: 14px; 197 | font-weight: normal; 198 | color: #7a7a7a; 199 | margin-right: 10px; 200 | } 201 | 202 | .approve-text { 203 | font-family: Arial, sans-serif; 204 | display: flex; 205 | align-items: center; 206 | font-size: 24px; 207 | font-weight: 800; 208 | color: black; 209 | } 210 | 211 | .feed-text { 212 | font-size: 15px; 213 | font-weight: 600px; 214 | } 215 | } 216 | 217 | @media (max-width: 375px) { 218 | #homeWallComponent .card .card-body > img { 219 | width: 50px; 220 | height: 50px; 221 | float: left; 222 | margin-right: 1px; 223 | } 224 | 225 | #homeWallComponent .card .card-header { 226 | font-size: 16px; 227 | font-weight: 600; 228 | padding: 18px 26px 14px 13px; 229 | border-bottom: 2px solid #f4f4f4; 230 | background-color: #ffffff; 231 | } 232 | 233 | #homeWallComponent .card .card-body { 234 | padding: 22px 10px; 235 | background-color: #ffffff; 236 | } 237 | 238 | #addon-wrapping-search { 239 | width: 6px; 240 | height: 7px; 241 | } 242 | 243 | #homeWallComponent .input-group input { 244 | padding: 10px 10px; 245 | color: #949494; 246 | font-family: "Poppins", sans-serif; 247 | font-size: 12px; 248 | font-weight: 500; 249 | } 250 | 251 | #addon-wrapping { 252 | width: 25px; 253 | height: 35px; 254 | } 255 | 256 | .home-text { 257 | font-family: Arial, sans-serif; 258 | display: flex; 259 | align-items: center; 260 | font-size: 16px; 261 | font-weight: normal; 262 | color: #7a7a7a; 263 | margin-right: 10px; 264 | } 265 | 266 | .approve-text { 267 | font-family: Arial, sans-serif; 268 | display: flex; 269 | align-items: center; 270 | font-size: 26px; 271 | font-weight: 800; 272 | color: black; 273 | } 274 | 275 | .feed-text { 276 | font-size: 17px; 277 | font-weight: 600px; 278 | } 279 | } 280 | 281 | @media (max-width: 425px) { 282 | #homeWallComponent .card .card-body > img { 283 | width: 50px; 284 | height: 50px; 285 | float: left; 286 | margin-right: 1px; 287 | } 288 | 289 | #homeWallComponent .card .card-header { 290 | font-size: 16px; 291 | font-weight: 600; 292 | padding: 18px 26px 14px 13px; 293 | border-bottom: 2px solid #f4f4f4; 294 | background-color: #ffffff; 295 | } 296 | 297 | #homeWallComponent .card .card-body { 298 | padding: 22px 10px; 299 | background-color: #ffffff; 300 | } 301 | 302 | #addon-wrapping-search { 303 | width: 6px; 304 | height: 7px; 305 | } 306 | 307 | #homeWallComponent .input-group input { 308 | padding: 10px 10px; 309 | color: #949494; 310 | font-family: "Poppins", sans-serif; 311 | font-size: 12px; 312 | font-weight: 500; 313 | } 314 | 315 | #addon-wrapping { 316 | width: 25px; 317 | height: 35px; 318 | } 319 | 320 | .home-text { 321 | font-family: Arial, sans-serif; 322 | display: flex; 323 | align-items: center; 324 | font-size: 16px; 325 | font-weight: normal; 326 | color: #7a7a7a; 327 | margin-right: 10px; 328 | } 329 | 330 | .approve-text { 331 | font-family: Arial, sans-serif; 332 | display: flex; 333 | align-items: center; 334 | font-size: 26px; 335 | font-weight: 800; 336 | color: black; 337 | } 338 | 339 | .feed-text { 340 | font-size: 17px; 341 | font-weight: 600px; 342 | } 343 | } 344 | -------------------------------------------------------------------------------- /pages/homePage.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | SE10 NETWORK 18 | 19 | 20 | 21 |
    25 |
    26 |
    27 |
    28 |
    29 |

    Recent

    30 |
    31 |
    32 |
      36 |
      37 |
      38 |
      39 |
      40 | 41 | 71 |
      75 |
      76 |
      77 | 80 |
      81 | Profile Image 82 |
      83 |
      84 |

      85 |
      86 |
      87 |
      88 |
      89 | 90 |
      91 |
      92 |
      93 | 97 |
      98 |
      99 | 103 |
      104 |
      105 | 109 |
      110 |
      111 | 112 |
      113 | 114 |
      115 | 116 | 117 |
      118 |
      119 |
      120 |

      121 | Birthdays 122 | Birth Day Icon 123 |

      124 |
      125 |

      No one has birthdays today

      126 |
      127 | 128 | 129 |
      130 |
      131 |
      134 |

      135 | Birthdays 136 | Birth Day Icon 141 |

      142 | Close Birthday Popup 148 |
      149 |
      150 |
      151 |

      No one has birthday today

      152 |
      153 |
      154 |
      155 |
      156 |
      157 | 158 | 159 |

      Notifications

      160 |
      161 |
      162 |
      163 | 164 |
      167 |
      170 | 176 |
      177 | 178 |
      181 | 187 |
      188 | 189 |
      192 | 198 |
      199 | 200 |
      203 | 209 |
      210 | 211 |
      214 | 220 |
      221 |
      222 | 223 | 224 | 225 | 226 | 227 | 228 | 229 | 230 | 231 | 232 | -------------------------------------------------------------------------------- /assets/css/homePage.css: -------------------------------------------------------------------------------- 1 | body { 2 | background: var(--bg-color); 3 | } 4 | 5 | #navBar { 6 | background: #fff; 7 | box-shadow: 0 -8px 80px 0 rgba(0, 0, 0, 0.1); 8 | padding: 25px 100px; 9 | } 10 | 11 | #navBar h1 { 12 | color: var(--btn-bg-color); 13 | font-family: "Poppins", sans-serif; 14 | font-size: 32px; 15 | font-style: normal; 16 | font-weight: 700; 17 | line-height: normal; 18 | margin: 0; 19 | } 20 | 21 | #navBar input { 22 | width: 25vw; 23 | border-radius: 41px; 24 | border: 1px solid rgba(233, 7, 8, 0.33); 25 | background: #fffafa; 26 | padding: 12px 12px 12px 62px; 27 | font-family: "Poppins", sans-serif; 28 | color: rgba(233, 7, 8, 0.5); 29 | font-weight: 500; 30 | } 31 | 32 | #navBar input::placeholder { 33 | color: rgba(233, 7, 8, 0.5); 34 | } 35 | 36 | #navBar input:focus { 37 | outline: none; 38 | border: 1px solid var(--btn-bg-color); 39 | color: var(--btn-bg-color); 40 | } 41 | 42 | #navBar .searchIcon { 43 | left: 45px; 44 | } 45 | 46 | #navBar .profile { 47 | width: 40px; 48 | height: 40px; 49 | border-radius: 50%; 50 | } 51 | 52 | #navBar .profile img { 53 | width: 100%; 54 | height: 100%; 55 | border-radius: 50%; 56 | border: 2px #fff; 57 | background-size: cover; 58 | } 59 | 60 | #navBar .notification { 61 | width: 20px; 62 | height: 20px; 63 | display: flex; 64 | } 65 | 66 | #navBar .notification img { 67 | width: 100%; 68 | height: 100%; 69 | } 70 | 71 | #homePage { 72 | padding: 34px 100px 0 100px; 73 | } 74 | 75 | #homePage > :first-child { 76 | width: 15vw; 77 | } 78 | 79 | #homePage .profile { 80 | border-radius: 15px; 81 | background: #fff; 82 | box-shadow: 0 4px 18.3px 0 rgba(0, 0, 0, 0.05); 83 | } 84 | 85 | #homePage .profile .banner { 86 | width: 100%; 87 | height: 100%; 88 | border-radius: 15px 15px 0 0; 89 | } 90 | 91 | #homePage .profile img { 92 | width: 100%; 93 | height: 100%; 94 | } 95 | 96 | #homePage .profile .profileImage { 97 | width: 100%; 98 | display: flex; 99 | justify-content: center; 100 | position: relative; 101 | bottom: 30px; 102 | } 103 | 104 | #homePage .profile img { 105 | width: 100%; 106 | height: 100%; 107 | } 108 | 109 | #homePage .profile .profileImage img { 110 | width: 63px; 111 | height: 100%; 112 | border-radius: 50%; 113 | border: 2px solid #fff; 114 | object-fit: cover; 115 | } 116 | 117 | #homePage .profile * { 118 | text-align: center; 119 | line-height: 10px; 120 | } 121 | 122 | #homePage .profile h4 { 123 | color: #000; 124 | font-family: "Poppins", sans-serif; 125 | font-size: 18px; 126 | font-weight: 700; 127 | line-height: 18px; 128 | } 129 | 130 | #homePage .profile h5 { 131 | color: #9e9e9e; 132 | font-family: "Poppins", sans-serif; 133 | font-size: 14px; 134 | font-weight: 500; 135 | margin-bottom: 14px; 136 | } 137 | 138 | #homePage .profile h6 { 139 | color: #000; 140 | font-family: "Poppins", sans-serif; 141 | font-size: 13px; 142 | padding: 0 15px; 143 | font-weight: 500; 144 | line-height: 18px; 145 | } 146 | 147 | #homePage .profile .profileDetails { 148 | position: relative; 149 | bottom: 10px; 150 | } 151 | 152 | #homePage .profile button { 153 | padding: 18px 0; 154 | border-radius: 0 0 15px 15px; 155 | border: 0; 156 | border-top: 2px solid #ebebeb; 157 | background: #fff; 158 | color: #e90708; 159 | text-align: center; 160 | font-family: "Poppins", sans-serif; 161 | font-size: 14px; 162 | font-weight: 500; 163 | } 164 | 165 | #homePage .homeButton button, 166 | #homePage .myPostButton button, 167 | #homePage .approveButton button { 168 | margin-top: 40px; 169 | border-radius: 15px; 170 | border: 1px solid transparent; 171 | background: transparent; 172 | display: flex; 173 | padding: 12px 27px; 174 | gap: 16px; 175 | align-items: center; 176 | color: #000; 177 | font-family: "Poppins", sans-serif; 178 | font-size: 16px; 179 | font-weight: 600; 180 | } 181 | 182 | #homePage .homeButton button img, 183 | #homePage .myPostButton button img, 184 | #homePage .approveButton button img { 185 | width: 20px; 186 | height: 20px; 187 | } 188 | 189 | #homePage .myPostButton button, 190 | #homePage .approveButton button { 191 | margin-top: 5px; 192 | } 193 | 194 | #homePage .active button { 195 | border: 1px solid #e7e7e7; 196 | background: #fff; 197 | } 198 | 199 | #homePage > .homeWallComponent { 200 | width: 58vw; 201 | height: 83vh; 202 | } 203 | 204 | #homePage .homeWallComponent > iframe { 205 | width: 100%; 206 | height: 100%; 207 | max-height: 100%; 208 | overflow-x: hidden; 209 | overflow-y: scroll; 210 | } 211 | 212 | #homePage .homeWallComponent > iframe::-webkit-scrollbar { 213 | width: 0 !important; 214 | } 215 | 216 | #homePage > :last-child { 217 | width: 15vw; 218 | } 219 | 220 | #homePage .birthDays { 221 | width: 100%; 222 | height: auto; 223 | background-color: #fff; 224 | border-radius: 15px; 225 | padding: 16px 18px; 226 | box-shadow: 0 4px 18.3px 0 rgba(0, 0, 0, 0.05); 227 | cursor: pointer; 228 | } 229 | 230 | #homePage .birthDays h3 { 231 | color: #000; 232 | font-family: "Poppins", sans-serif; 233 | font-size: 18px; 234 | font-weight: 700; 235 | } 236 | 237 | #homePage .birthDays h3 img { 238 | height: 23px; 239 | width: auto; 240 | margin-left: 10px; 241 | } 242 | 243 | #homePage .birthDays img { 244 | width: 14px; 245 | height: 14px; 246 | } 247 | 248 | #homePage .birthDays p { 249 | color: #797979; 250 | font-family: "Poppins", sans-serif; 251 | font-size: 14px; 252 | font-weight: 500; 253 | margin-top: 5px; 254 | } 255 | 256 | #homePage .birthDays + h1 { 257 | color: #000; 258 | font-family: "Poppins", sans-serif; 259 | font-size: 24px; 260 | font-weight: 700; 261 | margin-top: 40px; 262 | margin-bottom: 26px; 263 | } 264 | 265 | #homePage > :last-child button { 266 | border-radius: 15px; 267 | border: 1px solid #e7e7e7; 268 | background: #fff; 269 | display: flex; 270 | padding: 12px 27px; 271 | align-items: center; 272 | gap: 14px; 273 | width: 100%; 274 | } 275 | 276 | #homePage > :last-child button img { 277 | width: 23px; 278 | height: 23px; 279 | } 280 | 281 | #homePage > :last-child button span { 282 | color: #797979; 283 | font-family: "Poppins", sans-serif; 284 | font-size: 12px; 285 | font-weight: 500; 286 | text-align: start; 287 | } 288 | 289 | .searchPopUp { 290 | top: 84px; 291 | display: none; 292 | } 293 | 294 | #notifications { 295 | height: 60vh; 296 | overflow-x: hidden; 297 | overflow-y: scroll; 298 | } 299 | 300 | #notifications::-webkit-scrollbar { 301 | width: 0 !important; 302 | } 303 | 304 | /* bottom nav bar mobile css start */ 305 | .img-box { 306 | border-bottom: 3px solid transparent; 307 | padding: 1px !important; 308 | height: 30px; 309 | } 310 | 311 | .red-border-bottom { 312 | border-bottom: 3px solid var(--btn-bg-color); 313 | } 314 | /* bottom nav bar mobile css end */ 315 | 316 | @media screen and (max-width: 1440px) { 317 | #homePage { 318 | padding: 34px 75px 0 75px; 319 | } 320 | 321 | #navBar { 322 | padding: 25px 75px; 323 | } 324 | } 325 | 326 | @media screen and (max-width: 991px) { 327 | #navBar { 328 | padding: 0; 329 | } 330 | 331 | #homePage { 332 | padding: 0; 333 | } 334 | 335 | #navBar nav { 336 | justify-content: space-between !important; 337 | padding: 32px 30px 12px 30px; 338 | } 339 | 340 | #navBar h1 { 341 | color: #000; 342 | font-size: 20px; 343 | font-weight: 700; 344 | } 345 | 346 | #homePage > .homeWallComponent { 347 | width: 100%; 348 | margin: 0; 349 | } 350 | } 351 | 352 | @media (min-width: 992px) and (max-width: 1800px) { 353 | #homePage .wall { 354 | margin-right: 70px; 355 | } 356 | 357 | #homePage .notifi { 358 | margin-left: 60px; 359 | } 360 | 361 | #homePage .profile h5 { 362 | line-height: 20px; 363 | } 364 | 365 | #homePage .homeButton button, 366 | #homePage .myPostButton button, 367 | #homePage .approveButton button { 368 | font-size: 14px; 369 | } 370 | 371 | .profile { 372 | width: 130%; 373 | } 374 | 375 | #homePage .myPostButton, 376 | #homePage .homeButton, 377 | #homePage .approveButton { 378 | width: 130%; 379 | } 380 | 381 | #homePage .homeButton button, 382 | #homePage .myPostButton button, 383 | #homePage .approveButton button { 384 | padding-left: 25%; 385 | } 386 | 387 | #homePage .birthDays { 388 | width: 130%; 389 | margin-left: -24%; 390 | } 391 | 392 | #notifications { 393 | width: 130%; 394 | margin-left: -24%; 395 | } 396 | 397 | .notify-title { 398 | margin-left: -20%; 399 | } 400 | } 401 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | 2 | 3 | [![Contributors][contributors-shield]][contributors-url] 4 | [![Closed Pull Requests][closed-pull-requests-shield]][closed-pull-requests-url] 5 | [![Stargazers][stars-shield]][stars-url] 6 | [![Issues][issues-shield]][issues-url] 7 | [![MIT License][license-shield]][license-url] 8 | 9 | 10 | 11 |
      12 |
      13 | 14 | SE10 Logo 15 | 16 | 17 |

      SE10 NETWORK FRONTEND

      18 | 19 |

      20 | Welcome to the SE10 NETWORK frontend repository! This frontend application serves as the user interface for a social media platform specifically designed for students of IJSE (Institute of Software Engineering). It enables students to create and share posts, view updates from others, and receive notifications about important events like birthdays and 21 | campus-related activities. 22 |
      23 | Explore the project » 24 |
      25 |
      26 | View Design 27 | · 28 | Report Bug 29 | · 30 | Request Feature 31 |

      32 |
      33 | 34 | 35 | 36 |
      37 | Table of Contents 38 |
        39 |
      1. 40 | About The Project 41 | 44 |
      2. 45 |
      3. 46 | Getting Started 47 | 51 |
      4. 52 |
      5. 53 | API Documentation 54 |
      6. 55 |
      7. 56 | Figma Design 57 |
      8. 58 |
      9. 59 | Backend Repository 60 |
      10. 61 |
      11. Top contributors
      12. 62 |
      13. License
      14. 63 |
      64 |
      65 | 66 | 67 | 68 | 69 | ## About The Project 70 | 71 | 72 | ![Desktop - 1](https://github.com/user-attachments/assets/d1e909a3-f3fd-4338-8a0e-4abb1cdf9451) 73 | 74 | 75 | 76 | **User Interface**: 77 | - Clean and responsive interface built with **HTML**, **CSS**, and **Bootstrap**. 78 | - Dynamic elements for user interaction powered by **JavaScript** and **JQuary**. 79 | 80 | **Post Management**: 81 | - Users can create, view, and delete posts. 82 | - Live updates of posts for a seamless user experience. 83 | 84 | **Notifications**: 85 | - Birthday reminders and event notifications. 86 | - Visual indicators for new updates. 87 | 88 | **Axios Integration**: 89 | - Used for communicating with the backend API to handle requests and responses. 90 | 91 |

      (back to top)

      92 | 93 | 94 | 95 | ### Built With 96 | 97 | This project was developed using a variety of modern web technologies and libraries to ensure a responsive and dynamic user experience. 98 | 99 | * [![HTML][HTML.com]][HTML-url] 100 | * [![CSS][CSS.com]][CSS-url] 101 | * [![JavaScript][JavaScript.com]][JavaScript-url] 102 | * [![JQuery][JQuery.com]][JQuery-url] 103 | * [![Axios][Axios.com]][Axios-url] 104 | * [![Bootstrap][Bootstrap.com]][Bootstrap-url] 105 | 106 |

      (back to top)

      107 | 108 | 109 | 110 | 111 | ## Getting Started 112 | 113 | Follow these steps to set up the project locally and get it running on your machine. The instructions will guide you through the process of cloning the repository, installing dependencies, and configuring any required settings. 114 | 115 | ### Prerequisites 116 | 117 | Before setting up the project, make sure you have the following tools and libraries installed or configured as needed: 118 | 119 | * **Axios** 120 | Axios is already included in the project. No additional installation is required. 121 | 122 | * **Bootstrap** 123 | Bootstrap has already been downloaded and set up for the project. 124 | 125 | 126 | ### Installation 127 | 128 | Follow these steps to install and set up the project on your local machine: 129 | 130 | 1. **Clone the repository** 131 | ```sh 132 | git clone https://github.com/SE10-IJSE/SE10-NETWORK-FRONTEND.git 133 | 134 | 2. Change git remote url to avoid accidental pushes to base project 135 | ```sh 136 | git remote set-url origin github_username/repo_name 137 | git remote -v # confirm the changes 138 | ``` 139 | 140 |

      (back to top)

      141 | 142 | 143 | ## API Documentation 144 | 145 | Refer to the [Postman API Documentation](https://documenter.getpostman.com/view/39303999/2sAY4sjQPn) for detailed API endpoints and usage instructions. 146 | 147 | ## Figma Design 148 | 149 | Check out the Figma design for the frontend [here](https://www.figma.com/design/5PdKIjEzJCegZ8EMcPSQxw/SE10---Galle-Branch?node-id=1669-162202&node-type=canvas&t=7zzsFOiX0p3oQuxe-0). 150 | 151 | ## Backend Repository 152 | 153 | Access the backend repository on GitHub [here](https://github.com/SE10-IJSE/SE10-NETWORK-BACKEND). 154 | 155 | 156 |

      (back to top)

      157 | 158 | 159 | ## Top contributors: 160 | 161 | 162 | contrib.rocks image 163 | 164 | 165 |

      (back to top)

      166 | 167 | 168 | 169 | ## License 170 | 171 | Distributed under the MIT License. See [LICENSE](LICENSE) for more information. 172 | 173 |

      (back to top)

      174 | 175 | ## 176 | 177 |

      178 | © 2024 SE10 NETWORK 179 |

      180 | 181 | 182 | 183 | [contributors-shield]: https://img.shields.io/github/contributors/SE10-IJSE/SE10-NETWORK-FRONTEND.svg?style=for-the-badge 184 | [contributors-url]: https://github.com/SE10-IJSE/SE10-NETWORK-FRONTEND/graphs/contributors 185 | [closed-pull-requests-shield]: https://img.shields.io/github/issues-pr-closed/SE10-IJSE/SE10-NETWORK-FRONTEND.svg?style=for-the-badge 186 | [closed-pull-requests-url]: https://github.com/SE10-IJSE/SE10-NETWORK-FRONTEND/pulls?q=is%3Apr+is%3Aclosed 187 | [stars-shield]: https://img.shields.io/github/stars/SE10-IJSE/SE10-NETWORK-FRONTEND.svg?style=for-the-badge 188 | [stars-url]: https://github.com/othneildrew/Best-README-Template/stargazers 189 | [issues-shield]: https://img.shields.io/github/issues/SE10-IJSE/SE10-NETWORK-FRONTEND.svg?style=for-the-badge 190 | [issues-url]: https://github.com/SE10-IJSE/SE10-NETWORK-FRONTEND/issues 191 | [license-shield]: https://img.shields.io/github/license/SE10-IJSE/SE10-NETWORK-FRONTEND.svg?style=for-the-badge 192 | [license-url]: https://github.com/SE10-IJSE/SE10-NETWORK-FRONTEND/blob/main/LICENSE 193 | [HTML.com]: https://img.shields.io/badge/HTML-E34F26?style=for-the-badge&logo=html5&logoColor=white 194 | [HTML-url]: https://developer.mozilla.org/en-US/docs/Web/HTML 195 | [CSS.com]: https://img.shields.io/badge/CSS-1572B6?style=for-the-badge&logo=css3&logoColor=white 196 | [CSS-url]: https://developer.mozilla.org/en-US/docs/Web/CSS 197 | [JavaScript.com]: https://img.shields.io/badge/JavaScript-F7DF1E?style=for-the-badge&logo=javascript&logoColor=black 198 | [JavaScript-url]: https://developer.mozilla.org/en-US/docs/Web/JavaScript 199 | [Axios.com]: https://img.shields.io/badge/Axios-5A29E4?style=for-the-badge&logo=axios&logoColor=white 200 | [Axios-url]: https://axios-http.com/ 201 | [Bootstrap.com]: https://img.shields.io/badge/Bootstrap-563D7C?style=for-the-badge&logo=bootstrap&logoColor=white 202 | [Bootstrap-url]: https://getbootstrap.com 203 | [JQuery.com]: https://img.shields.io/badge/jQuery-0769AD?style=for-the-badge&logo=jquery&logoColor=white 204 | [JQuery-url]: https://jquery.com --------------------------------------------------------------------------------