From 14e73fe8d03bb877c0306bf1fa96d994791b36be Mon Sep 17 00:00:00 2001 From: Chirag Ghosh Date: Wed, 15 Nov 2023 00:18:51 +0530 Subject: [PATCH 01/16] feat: add user image in navbar --- src/components/Navbar.tsx | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/components/Navbar.tsx b/src/components/Navbar.tsx index c10ed31e..5f7c9f1d 100644 --- a/src/components/Navbar.tsx +++ b/src/components/Navbar.tsx @@ -67,7 +67,10 @@ function LoginButton({ isMobile }: { isMobile: boolean }) { } > {authContext.isAuthenticated ? ( - + ) : ( "MENTOR REGISTRATION" )} From f2a855747e92b503e4383aa96559abfacd0ed719 Mon Sep 17 00:00:00 2001 From: Chirag Ghosh Date: Wed, 15 Nov 2023 00:41:42 +0530 Subject: [PATCH 02/16] feat: update mentor dashboard design --- src/pages/MentorDashboard.tsx | 18 +++++++++++------- 1 file changed, 11 insertions(+), 7 deletions(-) diff --git a/src/pages/MentorDashboard.tsx b/src/pages/MentorDashboard.tsx index 9e8fcdfa..bb521cee 100644 --- a/src/pages/MentorDashboard.tsx +++ b/src/pages/MentorDashboard.tsx @@ -59,8 +59,12 @@ function MentorDashboard() { /> -

- {authContext.userData.name} (@{authContext.userData.username}) +

+ {authContext.userData.name} +
+ + (@{authContext.userData.username}) +

@@ -80,16 +84,13 @@ function MentorDashboard() {
-

- Projects +

+ PROJECTS

{isLoading ? ( ) : dashboard !== null ? (
- {dashboard.projects.map((project, i) => ( - - ))} Add Project + {dashboard.projects.map((project, i) => ( + + ))}
) : (

{error}

From ecfd61bda854fb700894b35876ce1e594048400f Mon Sep 17 00:00:00 2001 From: Chirag Ghosh Date: Wed, 15 Nov 2023 00:55:41 +0530 Subject: [PATCH 03/16] fix: navbar spacing --- src/components/Navbar.tsx | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/src/components/Navbar.tsx b/src/components/Navbar.tsx index 5f7c9f1d..070d9709 100644 --- a/src/components/Navbar.tsx +++ b/src/components/Navbar.tsx @@ -29,13 +29,11 @@ function BrandLogo() { function LinksList(isLinkActive: (link: string) => boolean, isMobile: boolean) { return LINKS.map((link) => ( -
  • +
  • Date: Wed, 15 Nov 2023 01:09:45 +0530 Subject: [PATCH 04/16] fix: for the love of God --- src/pages/Home.tsx | 28 +++++++++++++++------------- 1 file changed, 15 insertions(+), 13 deletions(-) diff --git a/src/pages/Home.tsx b/src/pages/Home.tsx index 46fb189d..2559b699 100644 --- a/src/pages/Home.tsx +++ b/src/pages/Home.tsx @@ -32,19 +32,21 @@ function Home() { return ( <>
    - + {process.env.NODE_ENV === "production" && ( + + )}
    From 8cc78712618a9e15430cb9a8f25ca2eb29c9e5cb Mon Sep 17 00:00:00 2001 From: Chirag Ghosh Date: Wed, 15 Nov 2023 01:13:43 +0530 Subject: [PATCH 05/16] feat: remove footer from global layout --- src/main.tsx | 2 - src/pages/FAQ.tsx | 96 ++++++++++++++++++----------------- src/pages/Home.tsx | 2 + src/pages/MentorDashboard.tsx | 4 +- 4 files changed, 54 insertions(+), 50 deletions(-) diff --git a/src/main.tsx b/src/main.tsx index af271276..ec33a857 100644 --- a/src/main.tsx +++ b/src/main.tsx @@ -2,11 +2,9 @@ import React from "react"; import ReactDOM from "react-dom/client"; import App from "./App.tsx"; import "./main.css"; -import FooterSection from "./components/FooterSection.tsx"; ReactDOM.createRoot(document.getElementById("root")!).render( - , ); diff --git a/src/pages/FAQ.tsx b/src/pages/FAQ.tsx index 35200180..b15fe937 100644 --- a/src/pages/FAQ.tsx +++ b/src/pages/FAQ.tsx @@ -1,6 +1,7 @@ import Fuse from "fuse.js"; import React, { useState } from "react"; import { FAQs } from "../data/FAQs"; +import FooterSection from "../components/FooterSection"; export default function FAQ() { const [query, setQuery] = useState(""); @@ -18,56 +19,59 @@ export default function FAQ() { const searchResults = query ? results.map((result) => result.item) : FAQs; return ( -
    -
    -
    -

    - Frequently Asked Questions -

    -

    - Wanna ask us a question? Check these first. -

    -
    + <> +
    +
    +
    +

    + Frequently Asked Questions +

    +

    + Wanna ask us a question? Check these first. +

    +
    -
    -
    - +
    +
    + +
    -
    -
    -
      - {searchResults.map((FAQ, i) => { - const { question, answer } = FAQ; - return ( -
    • -
      - {question} -
      -
      -
        - {answer.map((item) => { - return ( -
      • - ); - })} -
      -
      -
    • - ); - })} -
    +
    +
      + {searchResults.map((FAQ, i) => { + const { question, answer } = FAQ; + return ( +
    • +
      + {question} +
      +
      +
        + {answer.map((item) => { + return ( +
      • + ); + })} +
      +
      +
    • + ); + })} +
    +
    -
    + + ); } diff --git a/src/pages/Home.tsx b/src/pages/Home.tsx index 2559b699..cf5f2e53 100644 --- a/src/pages/Home.tsx +++ b/src/pages/Home.tsx @@ -9,6 +9,7 @@ import snowflake_particle3 from "../assets/snowflake3.svg"; import JoinOurCommunity from "../components/JoinOurCommunity"; import Timeline from "../components/Timeline"; import Testimonials from "../components/Testimonials"; +import FooterSection from "../components/FooterSection"; const snowflake_images = [ snowflake_particle1, @@ -55,6 +56,7 @@ function Home() { +
    ); diff --git a/src/pages/MentorDashboard.tsx b/src/pages/MentorDashboard.tsx index bb521cee..671f816e 100644 --- a/src/pages/MentorDashboard.tsx +++ b/src/pages/MentorDashboard.tsx @@ -109,7 +109,7 @@ function MentorDashboard() {
  • -
    + {/*

    Merged Pull Requests

    @@ -118,7 +118,7 @@ function MentorDashboard() { ? pulls.map((pull) => {pull}) : "No Pull Requests."}
    -
    +
    */}

    Mentor Resources

    From 22ce7882f31bd9fadb97d0e7514f783955ace22e Mon Sep 17 00:00:00 2001 From: Chirag Ghosh Date: Wed, 15 Nov 2023 01:16:33 +0530 Subject: [PATCH 06/16] refactor: remove unused import --- src/components/Navbar.tsx | 1 - 1 file changed, 1 deletion(-) diff --git a/src/components/Navbar.tsx b/src/components/Navbar.tsx index 070d9709..affbe63d 100644 --- a/src/components/Navbar.tsx +++ b/src/components/Navbar.tsx @@ -2,7 +2,6 @@ import { useEffect, useState } from "react"; import { Link, useLocation } from "react-router-dom"; import { CiMenuBurger } from "react-icons/ci"; import { RiCloseLine } from "react-icons/ri"; -import { CgProfile } from "react-icons/cg"; import { IconContext } from "react-icons"; import kwoc_logo from "../assets/kwoc_logo.png"; import { ROUTER_PATHS, GH_OAUTH_URL } from "../util/constants"; From f5fa14a82c518b6ad4bda53f994bab3786761fe2 Mon Sep 17 00:00:00 2001 From: Rohan Barsagade Date: Wed, 15 Nov 2023 01:22:15 +0530 Subject: [PATCH 07/16] feat: scrollToTop on route change --- src/App.tsx | 40 +++++++++++++++++++++++----------------- src/util/scrollToTop.tsx | 14 ++++++++++++++ 2 files changed, 37 insertions(+), 17 deletions(-) create mode 100644 src/util/scrollToTop.tsx diff --git a/src/App.tsx b/src/App.tsx index 6b80a466..24400d8f 100644 --- a/src/App.tsx +++ b/src/App.tsx @@ -11,31 +11,37 @@ import { AuthProvider } from "./util/auth"; import { ROUTER_PATHS } from "./util/constants"; import MentorDashboard from "./pages/MentorDashboard"; import ProjectForm from "./pages/ProjectForm"; +import ScrollToTop from "./util/scrollToTop"; function App() { return (
    - - - - } /> - } /> - {/* } /> */} - {/* } /> */} - } /> - } /> - {/* + + + + } /> + } /> + {/* } /> */} + {/* } /> */} + } + /> + } /> + {/* } /> */} - } /> - } - /> - - + } /> + } + /> + + +
    ); diff --git a/src/util/scrollToTop.tsx b/src/util/scrollToTop.tsx new file mode 100644 index 00000000..018206b2 --- /dev/null +++ b/src/util/scrollToTop.tsx @@ -0,0 +1,14 @@ +import React, { useEffect } from "react"; +import { useLocation } from "react-router-dom"; + +function ScrollToTop({ children }: { children: React.ReactNode }) { + const { pathname } = useLocation(); + + useEffect(() => { + window.scrollTo(0, 0); + }, [pathname]); + + return <>{children}; +} + +export default ScrollToTop; From bd016a1d6806b76fc3229f38311544cc3b695d49 Mon Sep 17 00:00:00 2001 From: Chirag Ghosh Date: Wed, 15 Nov 2023 01:31:36 +0530 Subject: [PATCH 08/16] feat: dashboard sidebars ui change --- src/pages/MentorDashboard.tsx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/pages/MentorDashboard.tsx b/src/pages/MentorDashboard.tsx index 671f816e..80927b60 100644 --- a/src/pages/MentorDashboard.tsx +++ b/src/pages/MentorDashboard.tsx @@ -51,7 +51,7 @@ function MentorDashboard() { return ( <>
    -
    +
    -
    +
    {/*

    Merged Pull Requests From 0f270f867d15d4041357b591fadb95b5f7353243 Mon Sep 17 00:00:00 2001 From: Rohan Barsagade Date: Wed, 15 Nov 2023 02:14:02 +0530 Subject: [PATCH 09/16] fix: change default font color --- src/main.css | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/main.css b/src/main.css index cb015171..e8a184db 100644 --- a/src/main.css +++ b/src/main.css @@ -6,7 +6,7 @@ * { scroll-behavior: smooth; - color: #f3f6f6; + color: #c1c1c1; font-family: "Ubuntu", sans-serif; font-weight: 500; } From ce736161fb486840bcaa462e11bcecf6ce513466 Mon Sep 17 00:00:00 2001 From: Rohan Barsagade Date: Wed, 15 Nov 2023 02:14:29 +0530 Subject: [PATCH 10/16] feat: mentor dashboard project card added again :) --- src/components/MentorProjectCard.tsx | 145 +++++++++++++++------------ 1 file changed, 83 insertions(+), 62 deletions(-) diff --git a/src/components/MentorProjectCard.tsx b/src/components/MentorProjectCard.tsx index 52074540..588e6294 100644 --- a/src/components/MentorProjectCard.tsx +++ b/src/components/MentorProjectCard.tsx @@ -1,81 +1,102 @@ import { BiGitCommit, BiGitPullRequest } from "react-icons/bi"; +import { useMemo } from "react"; import { IProjectDashboardInfo } from "../util/types"; function MentorProjectCard({ name, - description, - commit_count, - pull_count, - lines_added, - lines_removed, - project_status, + lines_added = 0, + lines_removed = 0, + commit_count = 0, + pull_count = 0, repo_link, }: IProjectDashboardInfo) { + const totalLinesChanged = useMemo( + () => lines_added + lines_removed, + [lines_added, lines_removed], + ); + const addedPercentage = useMemo( + () => + totalLinesChanged === 0 ? 0 : (lines_added / totalLinesChanged) * 100, + [lines_added, totalLinesChanged], + ); + const removedPercentage = useMemo( + () => + totalLinesChanged === 0 ? 0 : (lines_removed / totalLinesChanged) * 100, + [lines_removed, totalLinesChanged], + ); + return ( <> -
    +
    -

    - {name} ({project_status ? "Approved" : "Awaiting Approval"}) -

    +

    {name}

    -

    {description}

    - -
    -
    - {commit_count > 0 && project_status && ( -
    -
    - - Commit Count: -
    -

    {commit_count}

    -
    - )} - {pull_count > 0 && project_status && ( -
    -
    - Pull Count: -
    -

    {pull_count}

    -
    - )} +
    +
    +
    + + Commit Count: +
    +

    {commit_count}

    - {project_status && (lines_added > 0 || lines_removed > 0) && ( -
    -

    Lines Added / Removed

    -
    - - + {lines_added} - -
    -
    -
    -
    - - - {lines_removed} - -
    +
    +
    + Pull Count:
    - )} +

    {pull_count}

    +
    +
    +
    +

    Lines Added / Removed

    +
    + + + {lines_added} + +
    +
    +
    +
    + + - {lines_removed} + +
    +
    + - window.open(repo_link, "_blank")} + className="text-center font-semibold text-lg w-full p-2 bg-blue-950 rounded-md hover:bg-blue-900" > View Project - +
    ); From 8d3b2c0d3e93b9ec72fb01310de90583bc67406f Mon Sep 17 00:00:00 2001 From: Rohan Barsagade Date: Wed, 15 Nov 2023 02:14:47 +0530 Subject: [PATCH 11/16] feat: Project page cards new ui --- src/components/ProjectCard.tsx | 56 ++++++++++-- src/data/projectTags.json | 152 ++++++++++++++++----------------- src/pages/Projects.tsx | 4 +- 3 files changed, 127 insertions(+), 85 deletions(-) diff --git a/src/components/ProjectCard.tsx b/src/components/ProjectCard.tsx index d41ad9b6..b9db942c 100644 --- a/src/components/ProjectCard.tsx +++ b/src/components/ProjectCard.tsx @@ -1,6 +1,28 @@ -import { IProject } from "../util/types"; +import { IProject, IProjectTags } from "../util/types"; +import projectTags from "../data/projectTags.json"; -function ProjectCard({ name, description, tags, mentor }: IProject) { +function ProjectCard({ + name, + description, + tags, + mentor, + comm_channel, + repo_link, + isStudentView, +}: IProject & { isStudentView: boolean }) { + function getColor(tag: string) { + if (tag in projectTags) { + return (projectTags as IProjectTags)[tag]; + } else { + const randomColorIndex = Math.floor( + Math.random() * Object.keys(projectTags as IProjectTags).length, + ); + const randomKey = Object.keys(projectTags as IProjectTags)[ + randomColorIndex + ]; + return (projectTags as IProjectTags)[randomKey]; + } + } return ( <>
    @@ -24,19 +46,39 @@ function ProjectCard({ name, description, tags, mentor }: IProject) { .map((tag, i) => ( {tag} ))}
    - - + {isStudentView ? ( + + ) : ( + + )}
    diff --git a/src/data/projectTags.json b/src/data/projectTags.json index 3e32d6f6..3af84d3f 100644 --- a/src/data/projectTags.json +++ b/src/data/projectTags.json @@ -1,78 +1,78 @@ { - "OCaml": "#229e54", - "Perl": "#186c33", - "LLVM": "#d35400", - "Quantum Mechanics": "#a04000", - "CMake": "#8e44ad", - "Shell": "#552566", - "HTML+ERB": "#1f4788", - "Artificial Intelligence": "#2980b9", - "Matlab": "#229e54", - "Julia": "#186c33", - "Pascal": "#d35400", - "TeX": "#a04000", - "Rust": "#8e44ad", - "HTTP": "#552566", - "Blockchain": "#1f4788", - "C#": "#2980b9", - "Kotlin": "#229e54", - "Ada": "#186c33", - "HTML+Django": "#d35400", - "SQL": "#a04000", - "XML": "#8e44ad", - "Deep Learning": "#552566", - "Assembly": "#1f4788", - "Nginx": "#2980b9", - "Arduino": "#229e54", - "Dev Ops": "#186c33", - "C++": "#d35400", - "Visual Basic": "#a04000", - "Brainfuck": "#8e44ad", - "Lua": "#552566", - "NumPy": "#1f4788", - "Markdown": "#2980b9", - "Objective-C": "#229e54", - "Python traceback": "#186c33", - "xBase": "#d35400", - "CSS": "#a04000", - "C": "#8e44ad", - "HTML+PHP": "#552566", - "ApacheConf": "#1f4788", - "TypeScript": "#2980b9", - "Scala": "#229e54", - "VimL": "#186c33", - "Clojure": "#d35400", - "Cython": "#a04000", - "Cuda": "#8e44ad", - "Elm": "#552566", - "CoffeeScript": "#1f4788", - "Sage": "#2980b9", - "Haskell": "#229e54", - "reStructuredText": "#186c33", - "Java Server Pages": "#d35400", - "PHP": "#a04000", - "Ruby": "#8e44ad", - "Quantum Computing": "#552566", - "Java": "#1f4788", - "JavaScript": "#2980b9", - "Io": "#229e54", - "Machine Learning": "#186c33", - "Emacs Lisp": "#d35400", - "Cryptocurrency": "#a04000", - "Common Lisp": "#8e44ad", - "HTML": "#552566", - "Diff": "#1f4788", - "Python": "#2980b9", - "YAML": "#229e54", - "ASP": "#186c33", - "Makefile": "#d35400", - "JSON": "#a04000", - "FORTRAN": "#8e44ad", - "SCSS": "#552566", - "Automation": "#1f4788", - "R": "#2980b9", - "Sass": "#229e54", - "AppleScript": "#186c33", - "Go": "#d35400", - "Less": "#a04000" + "ocaml": "#229e54", + "perl": "#186c33", + "llvm": "#d35400", + "quantum mechanics": "#a04000", + "cmake": "#8e44ad", + "shell": "#552566", + "html+erb": "#1f4788", + "artificial intelligence": "#2980b9", + "matlab": "#229e54", + "julia": "#186c33", + "pascal": "#d35400", + "tex": "#a04000", + "rust": "#8e44ad", + "http": "#552566", + "blockchain": "#1f4788", + "c#": "#2980b9", + "kotlin": "#229e54", + "ada": "#186c33", + "html+django": "#d35400", + "sql": "#a04000", + "xml": "#8e44ad", + "deep learning": "#552566", + "assembly": "#1f4788", + "nginx": "#2980b9", + "arduino": "#229e54", + "dev ops": "#186c33", + "c++": "#d35400", + "visual basic": "#a04000", + "brainfuck": "#8e44ad", + "lua": "#552566", + "numpy": "#1f4788", + "markdown": "#2980b9", + "objective-c": "#229e54", + "python traceback": "#186c33", + "xbase": "#d35400", + "css": "#a04000", + "c": "#8e44ad", + "html+php": "#552566", + "apacheconf": "#1f4788", + "typescript": "#2980b9", + "scala": "#229e54", + "viml": "#186c33", + "clojure": "#d35400", + "cython": "#a04000", + "cuda": "#8e44ad", + "elm": "#552566", + "coffeescript": "#1f4788", + "sage": "#2980b9", + "haskell": "#229e54", + "restructuredtext": "#186c33", + "java server pages": "#d35400", + "php": "#a04000", + "ruby": "#8e44ad", + "quantum computing": "#552566", + "java": "#1f4788", + "javascript": "#2980b9", + "io": "#229e54", + "machine learning": "#186c33", + "emacs lisp": "#d35400", + "cryptocurrency": "#a04000", + "common lisp": "#8e44ad", + "html": "#552566", + "diff": "#1f4788", + "python": "#2980b9", + "yaml": "#229e54", + "asp": "#186c33", + "makefile": "#d35400", + "json": "#a04000", + "fortran": "#8e44ad", + "scss": "#552566", + "automation": "#1f4788", + "r": "#2980b9", + "sass": "#229e54", + "applescript": "#186c33", + "go": "#d35400", + "less": "#a04000" } diff --git a/src/pages/Projects.tsx b/src/pages/Projects.tsx index fe716152..fa27aaf1 100644 --- a/src/pages/Projects.tsx +++ b/src/pages/Projects.tsx @@ -59,9 +59,9 @@ function Projects() {
    {error &&

    {error}

    } -
    +
    {searchResults.map((project, i) => ( - + ))}
    From 951d6a1791e3b7ffa1267eab8ba8a34ef2424be4 Mon Sep 17 00:00:00 2001 From: Chirag Ghosh Date: Wed, 15 Nov 2023 02:16:28 +0530 Subject: [PATCH 12/16] feat: resources spacing change --- src/pages/MentorDashboard.tsx | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/src/pages/MentorDashboard.tsx b/src/pages/MentorDashboard.tsx index 80927b60..904d2dca 100644 --- a/src/pages/MentorDashboard.tsx +++ b/src/pages/MentorDashboard.tsx @@ -121,7 +121,7 @@ function MentorDashboard() {
    */}
    -

    Mentor Resources

    +

    Mentor Resources

    {MentorResources.map((resource) => ( -
  • +
  • -
    {resource.message}
    +
    + {resource.message} +
  • ))} From 2cb23094f9fe59f3db637537d7326dd0c52bcaf9 Mon Sep 17 00:00:00 2001 From: Chirag Ghosh Date: Wed, 15 Nov 2023 03:05:43 +0530 Subject: [PATCH 13/16] feat: changed the blues and styles of mentor dashboard --- src/components/Form.tsx | 2 +- src/components/MentorProjectCard.tsx | 22 +++++++++++----------- src/components/Navbar.tsx | 6 +++--- src/components/ProjectCard.tsx | 8 ++++---- src/components/SpinnerLoader.tsx | 2 +- src/components/TestimonialPageCard.tsx | 2 +- src/components/WhyKWoC.tsx | 2 +- src/data/FAQs.ts | 16 ++++++++-------- src/pages/MentorDashboard.tsx | 24 ++++++++++++------------ tailwind.config.js | 19 ++++++++++++++++++- 10 files changed, 60 insertions(+), 43 deletions(-) diff --git a/src/components/Form.tsx b/src/components/Form.tsx index 6b78727d..521b7980 100644 --- a/src/components/Form.tsx +++ b/src/components/Form.tsx @@ -68,7 +68,7 @@ function Form(props: IFormProps) { >

    {props.title}

    {props.error &&

    {props.error}

    } - {props.info &&

    {props.info}

    } + {props.info &&

    {props.info}

    } {Object.values(inputs)}
    diff --git a/src/components/MentorProjectCard.tsx b/src/components/MentorProjectCard.tsx index 588e6294..48117109 100644 --- a/src/components/MentorProjectCard.tsx +++ b/src/components/MentorProjectCard.tsx @@ -27,11 +27,11 @@ function MentorProjectCard({ return ( <> -
    +
    -

    {name}

    +

    {name}

    -
    +
    @@ -46,8 +46,8 @@ function MentorProjectCard({

    {pull_count}

    -
    -

    Lines Added / Removed

    +
    +

    Lines Added / Removed

    + {lines_added} @@ -59,10 +59,10 @@ function MentorProjectCard({ >
    - + - {lines_removed}
    @@ -72,28 +72,28 @@ function MentorProjectCard({ onClick={() => { // TODO }} - className="text-base text-blue-500 cursor-pointer hover:text-blue-600" + className="text-base text-primary-500 cursor-pointer hover:text-primary-600" > Edit Issues PRs
    diff --git a/src/components/Navbar.tsx b/src/components/Navbar.tsx index affbe63d..a8fd3355 100644 --- a/src/components/Navbar.tsx +++ b/src/components/Navbar.tsx @@ -34,8 +34,8 @@ function LinksList(isLinkActive: (link: string) => boolean, isMobile: boolean) { className={ (isMobile ? "block p-2 text-sm font-semibold " : "font-semibold ") + (isLinkActive(link.link) - ? "text-blue-500 hover:drop-shadow-glow duration-500" - : "text-white opacity-80 hover:drop-shadow-glow duration-500 active:text-blue-700") + ? "text-primary hover:drop-shadow-glow duration-500" + : "text-white opacity-80 hover:drop-shadow-glow duration-500 active:text-primary-700") } > {link.name} @@ -112,7 +112,7 @@ function Navbar() {
    @@ -65,7 +65,7 @@ function ProjectCard({ onClick={() => { window.open(comm_channel, "_blank"); }} - className="px-4 py-2 rounded-md bg-blue-950 hover:bg-blue-900 text-lg font-bold flex justify-center items-center" + className="px-4 py-2 rounded-md bg-primary-950 hover:bg-primary-900 text-lg font-bold flex justify-center items-center" > Join Channel @@ -74,7 +74,7 @@ function ProjectCard({ onClick={() => { // TODO }} - className="px-4 py-2 rounded-md bg-blue-950 hover:bg-blue-900 text-lg font-bold flex justify-center items-center" + className="px-4 py-2 rounded-md bg-primary-950 hover:bg-primary-900 text-lg font-bold flex justify-center items-center" > Edit Project diff --git a/src/components/SpinnerLoader.tsx b/src/components/SpinnerLoader.tsx index 2f7271fd..202ec1b1 100644 --- a/src/components/SpinnerLoader.tsx +++ b/src/components/SpinnerLoader.tsx @@ -4,7 +4,7 @@ function SpinnerLoader() {
    -
    +

    Read Full Blog

    diff --git a/src/components/WhyKWoC.tsx b/src/components/WhyKWoC.tsx index 8e379d26..7935cb64 100644 --- a/src/components/WhyKWoC.tsx +++ b/src/components/WhyKWoC.tsx @@ -46,7 +46,7 @@ export default function WhyKWoC() { Top performers in KWoC also have the opportunity to win fantastic prizes and rewards from{" "} diff --git a/src/data/FAQs.ts b/src/data/FAQs.ts index 28f693eb..1458f2ee 100644 --- a/src/data/FAQs.ts +++ b/src/data/FAQs.ts @@ -7,7 +7,7 @@ export const FAQs = [ "I do not have any prior knowledge of git and/or any programming language. Can I do this?", answer: [ "Absolutely. This program is specifically catered to the growth and smooth transition of people like you who want to learn. KOSS and the mentors will help you wherever possible.", - "To learn more about git and github, check these.", + "To learn more about git and github, check these.", ], }, { @@ -29,7 +29,7 @@ export const FAQs = [ question: "What is the purpose of this program? Is this some kind of internship?", answer: [ - "No, KWoC is a program which aims at helping participants learn how to contribute in the open-source world. This activity prepares you for various open source opportunities such as Google Summer of Code, Rail Girl's Summer of Code and Outreachy.", + "No, KWoC is a program which aims at helping participants learn how to contribute in the open-source world. This activity prepares you for various open source opportunities such as Google Summer of Code, Rail Girl's Summer of Code and Outreachy.", ], }, { @@ -39,7 +39,7 @@ export const FAQs = [ { question: "What can I do to help spread the word about KWoC?", answer: [ - "Nothing makes us happier than people spreading words about open-source; to begin, you can connect with our Facebook, Linkedin, Twitter handles and increase awareness about KWoC in your college; nothing works better than word of mouth.", + "Nothing makes us happier than people spreading words about open-source; to begin, you can connect with our Facebook, Linkedin, Twitter handles and increase awareness about KWoC in your college; nothing works better than word of mouth.", ], }, { @@ -57,7 +57,7 @@ export const FAQs = [ { question: "My mentor is not replying, What should I do?", answer: [ - `Please be patient with your mentor(s). If you do not get a response on the communication channel, contact the mentor on their email id. If no response for 3 days, inform us at ${KOSS_CONTACT_EMAIL}.`, + `Please be patient with your mentor(s). If you do not get a response on the communication channel, contact the mentor on their email id. If no response for 3 days, inform us at ${KOSS_CONTACT_EMAIL}.`, ], }, { @@ -78,14 +78,14 @@ export const FAQs = [ question: "Can you provide me any advice so that I can start preparing for it beforehand?", answer: [ - "Get familiar with Git and Github. Check this Open Source guide. Also, practice git here. You can also begin by following Codecademy's git interactive tutorial.", + "Get familiar with Git and Github. Check this Open Source guide. Also, practice git here. You can also begin by following Codecademy's git interactive tutorial.", ], }, { question: "Is there any other similar kind of program that I might find interesting?", answer: [ - "Other programs similar to KWoC are GirlScript Summer of Code organised by GirlScript India. If you meant similar to GSoC, then check out this awesome list of programs.", + "Other programs similar to KWoC are GirlScript Summer of Code organised by GirlScript India. If you meant similar to GSoC, then check out this awesome list of programs.", ], }, { @@ -122,7 +122,7 @@ export const FAQs = [ question: "What if I am unable to meet the deadlines due to some unavoidable reasons?", answer: [ - `Contact us via ${KOSS_CONTACT_EMAIL}.`, + `Contact us via ${KOSS_CONTACT_EMAIL}.`, ], }, { @@ -149,7 +149,7 @@ export const FAQs = [ { question: "What to do,if my stats are not being updated?", answer: [ - `Stats are only counted once coding period starts. They are updated periodically and it may take a few hours for them to update. If your stats do not update in a day, contact us at ${KOSS_CONTACT_EMAIL}.`, + `Stats are only counted once coding period starts. They are updated periodically and it may take a few hours for them to update. If your stats do not update in a day, contact us at ${KOSS_CONTACT_EMAIL}.`, ], }, ]; diff --git a/src/pages/MentorDashboard.tsx b/src/pages/MentorDashboard.tsx index 904d2dca..a8fa8607 100644 --- a/src/pages/MentorDashboard.tsx +++ b/src/pages/MentorDashboard.tsx @@ -2,7 +2,7 @@ import { useEffect, useState } from "react"; import MentorResources from "../data/mentorResources.json"; import MentorProjectCard from "../components/MentorProjectCard"; import { IEndpointTypes } from "../util/types"; -import { BiPlus } from "react-icons/bi"; +import { HiOutlineViewGridAdd } from "react-icons/hi"; import { Link, useNavigate } from "react-router-dom"; import { useAuthContext } from "../util/auth"; import { ROUTER_PATHS } from "../util/constants"; @@ -52,7 +52,7 @@ function MentorDashboard() { <>
    -
    +
    Edit Info - {isStudentView ? ( - - ) : ( - - )} +
    diff --git a/src/pages/MentorDashboard.tsx b/src/pages/MentorDashboard.tsx index a8fa8607..2a6957f7 100644 --- a/src/pages/MentorDashboard.tsx +++ b/src/pages/MentorDashboard.tsx @@ -96,7 +96,7 @@ function MentorDashboard() { ))}
    Add Project
    diff --git a/src/pages/Projects.tsx b/src/pages/Projects.tsx index fa27aaf1..10b43c8b 100644 --- a/src/pages/Projects.tsx +++ b/src/pages/Projects.tsx @@ -61,7 +61,7 @@ function Projects() { {error &&

    {error}

    }
    {searchResults.map((project, i) => ( - + ))}
    From 618a2de9aafdb3b2db04643d0db61f3f22693634 Mon Sep 17 00:00:00 2001 From: Chirag Ghosh Date: Wed, 15 Nov 2023 03:13:21 +0530 Subject: [PATCH 15/16] refactor: hide unfulfilled dreams --- src/components/MentorProjectCard.tsx | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/components/MentorProjectCard.tsx b/src/components/MentorProjectCard.tsx index 48117109..75930716 100644 --- a/src/components/MentorProjectCard.tsx +++ b/src/components/MentorProjectCard.tsx @@ -68,14 +68,14 @@ function MentorProjectCard({
    - { - // TODO + // TODO: complete edit project }} className="text-base text-primary-500 cursor-pointer hover:text-primary-600" > Edit - + */} Date: Wed, 15 Nov 2023 03:23:46 +0530 Subject: [PATCH 16/16] feat: approval status visible --- src/components/MentorProjectCard.tsx | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/src/components/MentorProjectCard.tsx b/src/components/MentorProjectCard.tsx index 75930716..c1364a58 100644 --- a/src/components/MentorProjectCard.tsx +++ b/src/components/MentorProjectCard.tsx @@ -4,6 +4,7 @@ import { IProjectDashboardInfo } from "../util/types"; function MentorProjectCard({ name, + project_status, lines_added = 0, lines_removed = 0, commit_count = 0, @@ -28,8 +29,14 @@ function MentorProjectCard({ return ( <>
    -
    +

    {name}

    + + {project_status ? ( +

    Approved

    + ) : ( +

    Waiting Approval

    + )}