Skip to content

Commit a0ee9bf

Browse files
authored
Merge pull request #163 from toggle-corp/feature/add-work-pdf
Add works page, update members
2 parents dc8a3bf + 61b2ffb commit a0ee9bf

12 files changed

Lines changed: 112 additions & 309 deletions

File tree

pages/works/index.tsx

Lines changed: 39 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -1,22 +1,21 @@
1-
import React, {
2-
useMemo,
3-
useState,
4-
} from 'react';
1+
import React from 'react';
52
import { GetStaticProps } from 'next';
63
// import { unique } from '@togglecorp/fujs';
74

8-
import { ProjectType, getProjectType } from 'data/projectTypes';
9-
import { getProjectCoverImage } from 'data/projectImages';
5+
import { ProjectType } from 'data/projectTypes';
6+
// import { getProjectCoverImage } from 'data/projectImages';
107
import staticProjects, { Project } from 'data/projects';
118

129
import Page from 'components/general/Page';
13-
import Card from 'components/general/Card';
14-
import Container from 'components/general/Container';
1510
import BannerWithImage from 'components/general/BannerWithImage';
1611
import KeyFigure from 'components/general/KeyFigure';
12+
import Container from 'components/general/Container';
13+
import Card from 'components/general/Card';
14+
/*
1715
import Separator from 'components/general/Separator';
1816
import Tabs from 'components/general/Tabs';
1917
import { selfSelector } from 'utils/common';
18+
*/
2019

2120
import bannerImage from 'resources/works/banner.jpeg';
2221

@@ -33,22 +32,19 @@ interface Props {
3332
projects: Project[];
3433
}
3534

36-
function WorksPage(props: Props) {
37-
const {
38-
projects,
39-
} = props;
40-
41-
const [
42-
filteredProjectType,
43-
setFilteredProjectType,
44-
] = useState<ProjectType | 'all'>('all');
45-
35+
function WorksPage() {
4636
// const totalProjects = projects.length;
4737
const totalProjects = '250+';
4838

4939
// const totalOrganizations = unique(projects.map((project) => project.client)).length;
5040
const totalOrganizations = '20+';
5141

42+
/*
43+
const [
44+
filteredProjectType,
45+
setFilteredProjectType,
46+
] = useState<ProjectType | 'all'>('all');
47+
5248
const filteredProjects = useMemo(() => {
5349
if (filteredProjectType === 'all') {
5450
return projects;
@@ -61,6 +57,7 @@ function WorksPage(props: Props) {
6157
const labelSelector = React.useCallback((projectType: ProjectType | 'all') => (
6258
projectType === 'all' ? 'All Works' : getProjectType(projectType).title
6359
), []);
60+
*/
6461

6562
return (
6663
<Page
@@ -86,6 +83,7 @@ function WorksPage(props: Props) {
8683
/>
8784
)}
8885
>
86+
{/*
8987
<Container contentClassName={styles.workContent}>
9088
<Tabs
9189
options={projectTypeOptions}
@@ -109,6 +107,29 @@ function WorksPage(props: Props) {
109107
))}
110108
</div>
111109
</Container>
110+
*/}
111+
<Container contentClassName={styles.portfolioCard}>
112+
<Card
113+
title="Development Team Portfolio"
114+
href="https://drive.google.com/file/d/1vXXxd5oWWRvTkMSlDO92NUzpf6gHknt1/view?usp=sharing"
115+
description={(
116+
<div>
117+
Click here to download
118+
</div>
119+
)}
120+
openExternal
121+
/>
122+
<Card
123+
title="Analysis Team Portfolio"
124+
href="https://drive.google.com/file/d/1T6gHiY27jlpxJ4jpci1Af-JQ9Iev553X/view?usp=sharing"
125+
description={(
126+
<div>
127+
Click here to download
128+
</div>
129+
)}
130+
openExternal
131+
/>
132+
</Container>
112133
</Page>
113134
);
114135
}

pages/works/styles.module.css

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@
66
padding: 3rem 0 0 0;
77
}
88

9+
/*
910
.workContent {
1011
display: flex;
1112
flex-direction: column;
@@ -29,4 +30,10 @@
2930
}
3031
}
3132
}
32-
}
33+
*/
34+
.portfolioCard {
35+
display: grid;
36+
grid-gap: 2rem;
37+
grid-template-columns: repeat(auto-fit, minmax(28rem, 1fr));
38+
}
39+
}

src/components/general/Card/index.tsx

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -9,9 +9,10 @@ interface Props {
99
variant?: 'mini' | 'normal';
1010
className?: string;
1111
href?: string;
12+
openExternal?: Boolean;
1213
imageSrc?: string | StaticImageData;
1314
title?: string;
14-
description?: string;
15+
description?: string | React.ReactNode;
1516
tags?: string[];
1617
}
1718

@@ -22,6 +23,7 @@ function Card(props: Props) {
2223
imageSrc,
2324
title,
2425
description,
26+
openExternal,
2527
tags,
2628
href,
2729
} = props;
@@ -49,7 +51,7 @@ function Card(props: Props) {
4951
{description && (
5052
<div
5153
className={styles.description}
52-
title={description}
54+
title={typeof description === 'string' ? description : undefined}
5355
>
5456
{description}
5557
</div>
@@ -84,7 +86,10 @@ function Card(props: Props) {
8486
passHref
8587
>
8688
{/* eslint-disable-next-line jsx-a11y/anchor-is-valid */}
87-
<a className={className}>
89+
<a
90+
className={className}
91+
target={openExternal ? '_blank' : undefined}
92+
>
8893
{children}
8994
</a>
9095
</Link>

src/components/general/Footer/index.tsx

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -77,6 +77,9 @@ function Footer(props: Props) {
7777
<Link href="/" passHref>
7878
<span className={styles.linkHover}>Home</span>
7979
</Link>
80+
<Link href="/works" passHref>
81+
<span className={styles.linkHover}>Works</span>
82+
</Link>
8083
<Link href="/about-us" passHref>
8184
<span className={styles.linkHover}>About</span>
8285
</Link>

src/components/general/Navbar/index.tsx

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -142,6 +142,9 @@ function Navbar(props: NavProps) {
142142
>
143143
Blogs
144144
</a>
145+
<NavLink href="/works">
146+
Works
147+
</NavLink>
145148
<NavLink href="/about-us">
146149
About
147150
</NavLink>

src/data/employeeImages.ts

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -10,11 +10,9 @@ import keyurKhadka from 'resources/employee/keyur.jpeg';
1010
import kishanPahari from 'resources/employee/nishan.jpeg';
1111
import navinAyer from 'resources/employee/navin.jpeg';
1212
import nikaShakya from 'resources/employee/nika.jpeg';
13-
import poojaSharma from 'resources/employee/pooja.jpeg';
1413
import prinishaBaidya from 'resources/employee/prinisha.jpeg';
1514
import puranBan from 'resources/employee/puran.jpeg';
1615
import ranjanShrestha from 'resources/employee/ranjan.jpeg';
17-
import rishiKhatri from 'resources/employee/rishi.jpeg';
1816
import rubyThapaliya from 'resources/employee/ruby.jpeg';
1917
import safarLigal from 'resources/employee/safar.jpeg';
2018
import sadikshyaHamal from 'resources/employee/sadikshya.jpeg';
@@ -32,9 +30,7 @@ import pratikshyaBhattarai from 'resources/employee/pratikshya-bhattarai.jpeg';
3230
import sudanBhandari from 'resources/employee/sudan-bhandari.jpeg';
3331
import babinKarmacharya from 'resources/employee/babin-karmacharya.jpeg';
3432
import shreyaBhattarai from 'resources/employee/shreya-bhattarai.jpeg';
35-
import supriyaRana from 'resources/employee/supriyaRana.jpg';
3633
import sushilTiwari from 'resources/employee/sushilTiwari.jpg';
37-
import sauravSapkota from 'resources/employee/sauravSapkota.jpg';
3834
import roshaniPoudel from 'resources/employee/roshaniPoudel.jpg';
3935

4036
import champaDevi from 'resources/employee/champa.jpeg';
@@ -58,7 +54,6 @@ const employeeImages: {
5854
'tc-063': bimalSaud,
5955
'tc-017': kishanPahari,
6056
'tc-030': nikaShakya,
61-
'tc-034': poojaSharma,
6257
'tc-028': prinishaBaidya,
6358
'tc-056': puranBan,
6459
'tc-042': ranjanShrestha,
@@ -69,7 +64,6 @@ const employeeImages: {
6964
'tc-021': shristiManandhar,
7065
'tc-055': rup,
7166
'tc-047': sushmaAdhikari,
72-
'tc-018': rishiKhatri,
7367
'tc-010': kanchiTamang,
7468
'tc-065': praneshShrestha,
7569
'tc-066': pratikshyaBhattarai,
@@ -78,9 +72,7 @@ const employeeImages: {
7872
'tc-070': babinKarmacharya,
7973
'tc-071': shreyaBhattarai,
8074
'tc-072': sushilTiwari,
81-
'tc-073': sauravSapkota,
8275
'tc-074': roshaniPoudel,
83-
'tc-075': supriyaRana,
8476
};
8577

8678
// eslint-disable-next-line import/prefer-default-export

0 commit comments

Comments
 (0)