From 8def66f53e5b8ae1f745ad418ca4e0b8e47b6381 Mon Sep 17 00:00:00 2001 From: aialok Date: Sun, 31 Dec 2023 00:49:41 +0530 Subject: [PATCH 1/5] Feature: Social Icons Integration on Login and Signup Page --- INSTALLATION.md | 5 +- src/screens/LoginPage/LoginPage.module.css | 21 +++++++ src/screens/LoginPage/LoginPage.tsx | 55 +++++++++++++++++++ .../UserLoginPage/UserLoginPage.module.css | 17 ++++++ .../UserLoginPage/UserLoginPage.tsx | 52 ++++++++++++++++++ 5 files changed, 148 insertions(+), 2 deletions(-) diff --git a/INSTALLATION.md b/INSTALLATION.md index 1a7028dfab..a628a75d28 100644 --- a/INSTALLATION.md +++ b/INSTALLATION.md @@ -10,6 +10,7 @@ This document provides instructions on how to set up and start a running instanc - [Installation](#installation) - [Setting up this repository](#setting-up-this-repository) - [Setting up npm](#setting-up-npm) + - [Setting up Typescript](#setting-up-typescript) - [Installing required packages/dependencies](#installing-required-packagesdependencies) - [Configuration](#configuration) - [Creating .env file](#creating-env-file) @@ -25,8 +26,8 @@ This document provides instructions on how to set up and start a running instanc - [Debugging tests](#debugging-tests) - [Linting code files](#linting-code-files) - [Husky for Git Hooks](#husky-for-git-hooks) - - [pre-commit hook](#pre-commit-hook) - - [post-merge hook](#post-merge-hook) + - [pre-commit hook](#pre-commit-hook) + - [post-merge hook](#post-merge-hook) diff --git a/src/screens/LoginPage/LoginPage.module.css b/src/screens/LoginPage/LoginPage.module.css index 8e8e314ba9..968ecc9ec2 100644 --- a/src/screens/LoginPage/LoginPage.module.css +++ b/src/screens/LoginPage/LoginPage.module.css @@ -102,6 +102,10 @@ margin-bottom: 0; padding: 1rem; } + + .socialIcons { + margin-bottom: 1rem; + } } @media (max-width: 577px) { @@ -124,6 +128,10 @@ height: 120px; margin: 0 auto 2rem auto; } + + .socialIcons { + margin-bottom: 1rem; + } } .active_tab { @@ -186,3 +194,16 @@ transform: translateY(0); } } + +.socialIcons { + display: flex; + gap: 16px; + justify-content: center; +} + +.socialIcon { + font-size: 24px; + color: #555; + transition: color 0.3s ease; + cursor: pointer; +} diff --git a/src/screens/LoginPage/LoginPage.tsx b/src/screens/LoginPage/LoginPage.tsx index b81b9c809c..2e1c6c71b3 100644 --- a/src/screens/LoginPage/LoginPage.tsx +++ b/src/screens/LoginPage/LoginPage.tsx @@ -9,6 +9,13 @@ import ReCAPTCHA from 'react-google-recaptcha'; import { useTranslation } from 'react-i18next'; import { Link } from 'react-router-dom'; import { toast } from 'react-toastify'; +import { + FaFacebook, + FaTwitter, + FaLinkedin, + FaGithub, + FaYoutube, +} from 'react-icons/fa'; import { REACT_APP_USE_RECAPTCHA, RECAPTCHA_SITE_KEY } from 'Constant/constant'; import { @@ -223,6 +230,54 @@ function loginPage(): JSX.Element {

{t('fromPalisadoes')}

+ +
+ + + + + + + + + + + + + + + +
diff --git a/src/screens/UserPortal/UserLoginPage/UserLoginPage.module.css b/src/screens/UserPortal/UserLoginPage/UserLoginPage.module.css index 840ceb8a0b..aec437e006 100644 --- a/src/screens/UserPortal/UserLoginPage/UserLoginPage.module.css +++ b/src/screens/UserPortal/UserLoginPage/UserLoginPage.module.css @@ -45,4 +45,21 @@ body::before { .leftPane { width: 100%; } + + .socialIcons { + margin-bottom: 1rem; + } +} + +.socialIcons { + display: flex; + gap: 16px; + justify-content: center; +} + +.socialIcon { + font-size: 24px; + color: #555; + transition: color 0.3s ease; + cursor: pointer; } diff --git a/src/screens/UserPortal/UserLoginPage/UserLoginPage.tsx b/src/screens/UserPortal/UserLoginPage/UserLoginPage.tsx index ca4915d691..9117b7d020 100644 --- a/src/screens/UserPortal/UserLoginPage/UserLoginPage.tsx +++ b/src/screens/UserPortal/UserLoginPage/UserLoginPage.tsx @@ -7,6 +7,13 @@ import ChangeLanguageDropDown from 'components/ChangeLanguageDropdown/ChangeLang import Login from 'components/UserPortal/Login/Login'; import Register from 'components/UserPortal/Register/Register'; import styles from './UserLoginPage.module.css'; +import { + FaFacebook, + FaTwitter, + FaLinkedin, + FaGithub, + FaYoutube, +} from 'react-icons/fa'; export default function userLoginPage(): JSX.Element { const { t } = useTranslation('translation', { keyPrefix: 'loginPage' }); @@ -27,6 +34,51 @@ export default function userLoginPage(): JSX.Element {

{t('fromPalisadoes')}

+
+ + + + + + + + + + + + + + + +
From 352ed377bf4a5dbeb3785e7ebf5bba75841002fb Mon Sep 17 00:00:00 2001 From: aialok Date: Sun, 31 Dec 2023 14:11:06 +0530 Subject: [PATCH 2/5] Changes social icons color --- src/screens/LoginPage/LoginPage.module.css | 24 ++++++++++++++++--- src/screens/LoginPage/LoginPage.tsx | 12 +++++----- .../UserLoginPage/UserLoginPage.module.css | 24 ++++++++++++++++--- .../UserLoginPage/UserLoginPage.tsx | 12 +++++----- 4 files changed, 54 insertions(+), 18 deletions(-) diff --git a/src/screens/LoginPage/LoginPage.module.css b/src/screens/LoginPage/LoginPage.module.css index 968ecc9ec2..60f213cbac 100644 --- a/src/screens/LoginPage/LoginPage.module.css +++ b/src/screens/LoginPage/LoginPage.module.css @@ -202,8 +202,26 @@ } .socialIcon { - font-size: 24px; - color: #555; - transition: color 0.3s ease; + font-size: 30px; cursor: pointer; } + +.twitterIcon { + color: #1da1f2; +} + +.facebookIcon { + color: #1877f2; +} + +.linkedinIcon { + color: #0a66c2; +} + +.githubIcon { + color: #211f1f; +} + +.youtubeIcon { + color: #ff0000; +} diff --git a/src/screens/LoginPage/LoginPage.tsx b/src/screens/LoginPage/LoginPage.tsx index 2e1c6c71b3..e7286adbf9 100644 --- a/src/screens/LoginPage/LoginPage.tsx +++ b/src/screens/LoginPage/LoginPage.tsx @@ -233,21 +233,21 @@ function loginPage(): JSX.Element {
- -
- - Date: Mon, 1 Jan 2024 01:04:51 +0530 Subject: [PATCH 3/5] Added Instagram and Slack Icon --- src/assets/svgs/Slack-mark.svg | 35 +++++++++++++++++++ src/screens/LoginPage/LoginPage.module.css | 9 +++++ src/screens/LoginPage/LoginPage.tsx | 24 +++++++++++-- .../UserLoginPage/UserLoginPage.module.css | 11 +++++- .../UserLoginPage/UserLoginPage.tsx | 22 ++++++++++-- 5 files changed, 96 insertions(+), 5 deletions(-) create mode 100644 src/assets/svgs/Slack-mark.svg diff --git a/src/assets/svgs/Slack-mark.svg b/src/assets/svgs/Slack-mark.svg new file mode 100644 index 0000000000..cb36bb990a --- /dev/null +++ b/src/assets/svgs/Slack-mark.svg @@ -0,0 +1,35 @@ + + + + + + + + + + + + + + + + + + + + + + + diff --git a/src/screens/LoginPage/LoginPage.module.css b/src/screens/LoginPage/LoginPage.module.css index 60f213cbac..cf923627a3 100644 --- a/src/screens/LoginPage/LoginPage.module.css +++ b/src/screens/LoginPage/LoginPage.module.css @@ -225,3 +225,12 @@ .youtubeIcon { color: #ff0000; } + +.slackIcon { + width: 30px; + height: 30px; +} + +.instagramIcon { + color: #e4405f; +} diff --git a/src/screens/LoginPage/LoginPage.tsx b/src/screens/LoginPage/LoginPage.tsx index e7286adbf9..a4b290a7b6 100644 --- a/src/screens/LoginPage/LoginPage.tsx +++ b/src/screens/LoginPage/LoginPage.tsx @@ -11,11 +11,12 @@ import { Link } from 'react-router-dom'; import { toast } from 'react-toastify'; import { FaFacebook, - FaTwitter, FaLinkedin, FaGithub, FaYoutube, + FaInstagram, } from 'react-icons/fa'; +import { FaXTwitter } from 'react-icons/fa6'; import { REACT_APP_USE_RECAPTCHA, RECAPTCHA_SITE_KEY } from 'Constant/constant'; import { @@ -25,6 +26,7 @@ import { } from 'GraphQl/Mutations/mutations'; import { ReactComponent as TalawaLogo } from 'assets/svgs/talawa.svg'; import { ReactComponent as PalisadoesLogo } from 'assets/svgs/palisadoes.svg'; +import { ReactComponent as SlackLogo } from 'assets/svgs/Slack-mark.svg'; import ChangeLanguageDropDown from 'components/ChangeLanguageDropdown/ChangeLanguageDropDown'; import Loader from 'components/Loader/Loader'; import { errorHandler } from 'utils/errorHandler'; @@ -246,7 +248,7 @@ function loginPage(): JSX.Element { target="_blank" rel="noopener noreferrer" > - @@ -277,6 +279,24 @@ function loginPage(): JSX.Element { className={`${styles.socialIcon} ${styles.youtubeIcon}`} /> + + + + + +
diff --git a/src/screens/UserPortal/UserLoginPage/UserLoginPage.module.css b/src/screens/UserPortal/UserLoginPage/UserLoginPage.module.css index 27ef4d5d78..db36a01b2e 100644 --- a/src/screens/UserPortal/UserLoginPage/UserLoginPage.module.css +++ b/src/screens/UserPortal/UserLoginPage/UserLoginPage.module.css @@ -63,7 +63,7 @@ body::before { } .twitterIcon { - color: #1da1f2; + color: #000000; } .facebookIcon { @@ -81,3 +81,12 @@ body::before { .youtubeIcon { color: #ff0000; } + +.slackIcon { + width: 30px; + height: 30px; +} + +.instagramIcon { + color: #e4405f; +} diff --git a/src/screens/UserPortal/UserLoginPage/UserLoginPage.tsx b/src/screens/UserPortal/UserLoginPage/UserLoginPage.tsx index b5f695784b..ff9c0b8f62 100644 --- a/src/screens/UserPortal/UserLoginPage/UserLoginPage.tsx +++ b/src/screens/UserPortal/UserLoginPage/UserLoginPage.tsx @@ -7,13 +7,15 @@ import ChangeLanguageDropDown from 'components/ChangeLanguageDropdown/ChangeLang import Login from 'components/UserPortal/Login/Login'; import Register from 'components/UserPortal/Register/Register'; import styles from './UserLoginPage.module.css'; +import { ReactComponent as SlackLogo } from '../../../assets/svgs/Slack-mark.svg'; import { FaFacebook, - FaTwitter, FaLinkedin, FaGithub, FaYoutube, + FaInstagram, } from 'react-icons/fa'; +import { FaXTwitter } from 'react-icons/fa6'; export default function userLoginPage(): JSX.Element { const { t } = useTranslation('translation', { keyPrefix: 'loginPage' }); @@ -49,7 +51,7 @@ export default function userLoginPage(): JSX.Element { target="_blank" rel="noopener noreferrer" > - @@ -78,6 +80,22 @@ export default function userLoginPage(): JSX.Element { className={`${styles.socialIcon} ${styles.youtubeIcon}`} /> + + + + + +
From 0ae9d688b7111ace65446bbbda3e912d2efd9d88 Mon Sep 17 00:00:00 2001 From: aialok Date: Mon, 1 Jan 2024 01:13:28 +0530 Subject: [PATCH 4/5] Fixes Color of Twitter Icon --- src/screens/LoginPage/LoginPage.module.css | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/screens/LoginPage/LoginPage.module.css b/src/screens/LoginPage/LoginPage.module.css index cf923627a3..0ddc086f44 100644 --- a/src/screens/LoginPage/LoginPage.module.css +++ b/src/screens/LoginPage/LoginPage.module.css @@ -207,7 +207,7 @@ } .twitterIcon { - color: #1da1f2; + color: #000000; } .facebookIcon { From b18592e2475f48ca5974e5b63d40cb63dd095fe6 Mon Sep 17 00:00:00 2001 From: aialok Date: Tue, 2 Jan 2024 16:17:55 +0530 Subject: [PATCH 5/5] Added Social Icons from figma design --- src/assets/svgs/Slack-mark.svg | 35 -------------- .../svgs/social-icons/Facebook-Logo.svg | 4 ++ src/assets/svgs/social-icons/Github-Logo.svg | 4 ++ .../svgs/social-icons/Instagram-Logo.svg | 23 +++++++++ .../svgs/social-icons/Linkedin-Logo.svg | 4 ++ src/assets/svgs/social-icons/Reddit-Logo.svg | 11 +++++ src/assets/svgs/social-icons/Slack-Logo.svg | 14 ++++++ src/assets/svgs/social-icons/Twitter-Logo.svg | 4 ++ src/assets/svgs/social-icons/Youtube-Logo.svg | 4 ++ src/assets/svgs/social-icons/index.tsx | 17 +++++++ src/screens/LoginPage/LoginPage.module.css | 34 -------------- src/screens/LoginPage/LoginPage.tsx | 47 +++++++------------ .../UserLoginPage/UserLoginPage.module.css | 34 -------------- .../UserLoginPage/UserLoginPage.tsx | 43 +++++++---------- 14 files changed, 119 insertions(+), 159 deletions(-) delete mode 100644 src/assets/svgs/Slack-mark.svg create mode 100644 src/assets/svgs/social-icons/Facebook-Logo.svg create mode 100644 src/assets/svgs/social-icons/Github-Logo.svg create mode 100644 src/assets/svgs/social-icons/Instagram-Logo.svg create mode 100644 src/assets/svgs/social-icons/Linkedin-Logo.svg create mode 100644 src/assets/svgs/social-icons/Reddit-Logo.svg create mode 100644 src/assets/svgs/social-icons/Slack-Logo.svg create mode 100644 src/assets/svgs/social-icons/Twitter-Logo.svg create mode 100644 src/assets/svgs/social-icons/Youtube-Logo.svg create mode 100644 src/assets/svgs/social-icons/index.tsx diff --git a/src/assets/svgs/Slack-mark.svg b/src/assets/svgs/Slack-mark.svg deleted file mode 100644 index cb36bb990a..0000000000 --- a/src/assets/svgs/Slack-mark.svg +++ /dev/null @@ -1,35 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - diff --git a/src/assets/svgs/social-icons/Facebook-Logo.svg b/src/assets/svgs/social-icons/Facebook-Logo.svg new file mode 100644 index 0000000000..a70f112dc7 --- /dev/null +++ b/src/assets/svgs/social-icons/Facebook-Logo.svg @@ -0,0 +1,4 @@ + + + + diff --git a/src/assets/svgs/social-icons/Github-Logo.svg b/src/assets/svgs/social-icons/Github-Logo.svg new file mode 100644 index 0000000000..7679af859c --- /dev/null +++ b/src/assets/svgs/social-icons/Github-Logo.svg @@ -0,0 +1,4 @@ + + + + diff --git a/src/assets/svgs/social-icons/Instagram-Logo.svg b/src/assets/svgs/social-icons/Instagram-Logo.svg new file mode 100644 index 0000000000..cbf278ae75 --- /dev/null +++ b/src/assets/svgs/social-icons/Instagram-Logo.svg @@ -0,0 +1,23 @@ + + + + + + + + + + + + + + + + + + + + + + + diff --git a/src/assets/svgs/social-icons/Linkedin-Logo.svg b/src/assets/svgs/social-icons/Linkedin-Logo.svg new file mode 100644 index 0000000000..998dd1b826 --- /dev/null +++ b/src/assets/svgs/social-icons/Linkedin-Logo.svg @@ -0,0 +1,4 @@ + + + + diff --git a/src/assets/svgs/social-icons/Reddit-Logo.svg b/src/assets/svgs/social-icons/Reddit-Logo.svg new file mode 100644 index 0000000000..8111415030 --- /dev/null +++ b/src/assets/svgs/social-icons/Reddit-Logo.svg @@ -0,0 +1,11 @@ + + + + + + + + + + + diff --git a/src/assets/svgs/social-icons/Slack-Logo.svg b/src/assets/svgs/social-icons/Slack-Logo.svg new file mode 100644 index 0000000000..29a9087d21 --- /dev/null +++ b/src/assets/svgs/social-icons/Slack-Logo.svg @@ -0,0 +1,14 @@ + + + + + + + + + + + + + + diff --git a/src/assets/svgs/social-icons/Twitter-Logo.svg b/src/assets/svgs/social-icons/Twitter-Logo.svg new file mode 100644 index 0000000000..efa659339d --- /dev/null +++ b/src/assets/svgs/social-icons/Twitter-Logo.svg @@ -0,0 +1,4 @@ + + + + diff --git a/src/assets/svgs/social-icons/Youtube-Logo.svg b/src/assets/svgs/social-icons/Youtube-Logo.svg new file mode 100644 index 0000000000..112b9c2d3b --- /dev/null +++ b/src/assets/svgs/social-icons/Youtube-Logo.svg @@ -0,0 +1,4 @@ + + + + diff --git a/src/assets/svgs/social-icons/index.tsx b/src/assets/svgs/social-icons/index.tsx new file mode 100644 index 0000000000..d698fc1376 --- /dev/null +++ b/src/assets/svgs/social-icons/index.tsx @@ -0,0 +1,17 @@ +import FacebookLogo from './Facebook-Logo.svg'; +import GithubLogo from './Github-Logo.svg'; +import InstagramLogo from './Instagram-Logo.svg'; +import LinkedInLogo from './Linkedin-Logo.svg'; +import SlackLogo from './Slack-Logo.svg'; +import TwitterLogo from './Twitter-Logo.svg'; +import YoutubeLogo from './Youtube-Logo.svg'; + +export { + FacebookLogo, + GithubLogo, + InstagramLogo, + LinkedInLogo, + SlackLogo, + TwitterLogo, + YoutubeLogo, +}; diff --git a/src/screens/LoginPage/LoginPage.module.css b/src/screens/LoginPage/LoginPage.module.css index 0ddc086f44..02cd04032a 100644 --- a/src/screens/LoginPage/LoginPage.module.css +++ b/src/screens/LoginPage/LoginPage.module.css @@ -200,37 +200,3 @@ gap: 16px; justify-content: center; } - -.socialIcon { - font-size: 30px; - cursor: pointer; -} - -.twitterIcon { - color: #000000; -} - -.facebookIcon { - color: #1877f2; -} - -.linkedinIcon { - color: #0a66c2; -} - -.githubIcon { - color: #211f1f; -} - -.youtubeIcon { - color: #ff0000; -} - -.slackIcon { - width: 30px; - height: 30px; -} - -.instagramIcon { - color: #e4405f; -} diff --git a/src/screens/LoginPage/LoginPage.tsx b/src/screens/LoginPage/LoginPage.tsx index a4b290a7b6..ab63fb72f8 100644 --- a/src/screens/LoginPage/LoginPage.tsx +++ b/src/screens/LoginPage/LoginPage.tsx @@ -9,14 +9,16 @@ import ReCAPTCHA from 'react-google-recaptcha'; import { useTranslation } from 'react-i18next'; import { Link } from 'react-router-dom'; import { toast } from 'react-toastify'; + import { - FaFacebook, - FaLinkedin, - FaGithub, - FaYoutube, - FaInstagram, -} from 'react-icons/fa'; -import { FaXTwitter } from 'react-icons/fa6'; + FacebookLogo, + LinkedInLogo, + GithubLogo, + InstagramLogo, + SlackLogo, + TwitterLogo, + YoutubeLogo, +} from 'assets/svgs/social-icons'; import { REACT_APP_USE_RECAPTCHA, RECAPTCHA_SITE_KEY } from 'Constant/constant'; import { @@ -26,7 +28,6 @@ import { } from 'GraphQl/Mutations/mutations'; import { ReactComponent as TalawaLogo } from 'assets/svgs/talawa.svg'; import { ReactComponent as PalisadoesLogo } from 'assets/svgs/palisadoes.svg'; -import { ReactComponent as SlackLogo } from 'assets/svgs/Slack-mark.svg'; import ChangeLanguageDropDown from 'components/ChangeLanguageDropdown/ChangeLanguageDropDown'; import Loader from 'components/Loader/Loader'; import { errorHandler } from 'utils/errorHandler'; @@ -239,63 +240,49 @@ function loginPage(): JSX.Element { target="_blank" rel="noopener noreferrer" > - + - + - + - + - + - + - +
diff --git a/src/screens/UserPortal/UserLoginPage/UserLoginPage.module.css b/src/screens/UserPortal/UserLoginPage/UserLoginPage.module.css index db36a01b2e..32858723ef 100644 --- a/src/screens/UserPortal/UserLoginPage/UserLoginPage.module.css +++ b/src/screens/UserPortal/UserLoginPage/UserLoginPage.module.css @@ -56,37 +56,3 @@ body::before { gap: 16px; justify-content: center; } - -.socialIcon { - font-size: 30px; - cursor: pointer; -} - -.twitterIcon { - color: #000000; -} - -.facebookIcon { - color: #1877f2; -} - -.linkedinIcon { - color: #0a66c2; -} - -.githubIcon { - color: #211f1f; -} - -.youtubeIcon { - color: #ff0000; -} - -.slackIcon { - width: 30px; - height: 30px; -} - -.instagramIcon { - color: #e4405f; -} diff --git a/src/screens/UserPortal/UserLoginPage/UserLoginPage.tsx b/src/screens/UserPortal/UserLoginPage/UserLoginPage.tsx index ff9c0b8f62..559d088a9e 100644 --- a/src/screens/UserPortal/UserLoginPage/UserLoginPage.tsx +++ b/src/screens/UserPortal/UserLoginPage/UserLoginPage.tsx @@ -7,15 +7,16 @@ import ChangeLanguageDropDown from 'components/ChangeLanguageDropdown/ChangeLang import Login from 'components/UserPortal/Login/Login'; import Register from 'components/UserPortal/Register/Register'; import styles from './UserLoginPage.module.css'; -import { ReactComponent as SlackLogo } from '../../../assets/svgs/Slack-mark.svg'; + import { - FaFacebook, - FaLinkedin, - FaGithub, - FaYoutube, - FaInstagram, -} from 'react-icons/fa'; -import { FaXTwitter } from 'react-icons/fa6'; + FacebookLogo, + LinkedInLogo, + GithubLogo, + InstagramLogo, + SlackLogo, + TwitterLogo, + YoutubeLogo, +} from 'assets/svgs/social-icons'; export default function userLoginPage(): JSX.Element { const { t } = useTranslation('translation', { keyPrefix: 'loginPage' }); @@ -42,59 +43,49 @@ export default function userLoginPage(): JSX.Element { target="_blank" rel="noopener noreferrer" > - + - + - + - + - + - + - +