Skip to content

Commit

Permalink
feat(first-section): added first section
Browse files Browse the repository at this point in the history
  • Loading branch information
TigMart committed Apr 9, 2024
2 parents 310cd7d + 9468f12 commit 45fe360
Show file tree
Hide file tree
Showing 18 changed files with 370 additions and 52 deletions.
18 changes: 13 additions & 5 deletions public/locales/am/translation.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,14 @@
{
"header":{
"nav":["Հիմնական", "Իմ մասին", "Պորտֆոլիո", "Կապ"],
"button": "Ընդունիր ինձ"
}
}
"header": {
"nav": ["Հիմնական", "Իմ մասին", "Պորտֆոլիո", "Կապ"],
"button": "Դիմել ինձ"
},
"intro": {
"sayHi": "Բարև, ես",
"fullName": "Տիգրան Մարտիրոսյան",
"profession": "Front-End Ծրագրավորող",
"buttonHire": "Դիմել ինձ",
"buttonCV": "Բեռնել CV",
"info": ["Փորձ", "Կատարված պրոյեկտներ"]
}
}
18 changes: 13 additions & 5 deletions public/locales/en/translation.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,14 @@
{
"header":{
"nav":["Home", "About me", "Portfolio", "Contact me"],
"button": "Hire me"
}
}
"header": {
"nav": ["Home", "About me", "Portfolio", "Contact me"],
"button": "Hire me"
},
"intro": {
"sayHi": "Hi I am",
"fullName": "Tigran Martirosyan",
"profession": "Front-End Developer",
"buttonHire": "Hire Me",
"buttonCV": "Download CV",
"info": ["Experiences", "Project done"]
}
}
Binary file added src/assets/Tigran-Martirosyan-CV.pdf
Binary file not shown.
Binary file added src/assets/images/photo.webp
Binary file not shown.
Binary file added src/assets/images/vector.webp
Binary file not shown.
8 changes: 8 additions & 0 deletions src/assets/styles/colors.ts
Original file line number Diff line number Diff line change
Expand Up @@ -23,17 +23,21 @@ const colors = {
'--dark-bg-tint-1': '#FD6F00',
'--dark-bg-tint-2': '#1E1E1E',
'--dark-bg-tint-3': '#959595',
'--dark-bg-tint-4': 'rgba(255,255,255,0.04)',

// Text

'--dark-text-color-tint-1': '#ffffff',
'--dark-text-color-tint-2': '#959595',
'--dark-text-color-tint-3': '#FD6F00',
'--dark-text-color-tint-4': '#707070',
'--dark-text-color-tint-5': '#DFDFDF',

// Gradients

'--dark-bg-gradient-1': 'linear-gradient(90deg, rgba(253,111,0,1) 0%, rgba(228,100,0,1) 100%)',
'--dark-bg-gradient-2': 'linear-gradient(90deg, rgba(228,100,0,1) 0%, rgba(253,111,0,1) 100%)',
'--dark-bg-gradient-3': 'linear-gradient(100deg, rgba(152,67,0,1) 0%, rgba(253,111,0,1) 46%, rgba(202,89,0,1) 100%)',
},

/// ////////////// Light ////////////////
Expand All @@ -59,16 +63,20 @@ const colors = {
'--light-bg-tint-1': '#FD6F00',
'--light-bg-tint-2': '#ffffff',
'--light-bg-tint-3': '#959595',
'--light-bg-tint-4': 'rgba(255,255,255,0.04)',

// Text

'--light-text-color-tint-1': '#ffffff',
'--light-text-color-tint-2': '#959595',
'--light-text-color-tint-3': '#FD6F00',
'--light-text-color-tint-4': '#707070',
'--light-text-color-tint-5': '#DFDFDF',

// Gradients
'--light-bg-gradient-1': 'linear-gradient(90deg, rgba(253,111,0,1) 0%, rgba(228,100,0,1) 100%)',
'--light-bg-gradient-2': 'linear-gradient(90deg, rgba(228,100,0,1) 0%, rgba(253,111,0,1) 100%)',
'--light-bg-gradient-3': 'linear-gradient(100deg, rgba(152,67,0,1) 0%, rgba(253,111,0,1) 46%, rgba(202,89,0,1) 100%)',
},
},
},
Expand Down
33 changes: 30 additions & 3 deletions src/assets/styles/fonts.ts
Original file line number Diff line number Diff line change
Expand Up @@ -15,10 +15,18 @@ export enum FontWeight {
export const typography = {
H1: {
fontSize: '64px',
lineHeight: 'normal',
[mediaQueryMax(themeDark.breakpoints.mobile)]: {
lineHeight: '77px',
[mediaQueryMax(668)]: {
fontSize: '44px',
lineHeight: 'normal',
lineHeight: '53px',
},
[mediaQueryMax(450)]: {
fontSize: '36px',
lineHeight: '44px',
},
[mediaQueryMax(376)]: {
fontSize: '32px',
lineHeight: '40px',
},
},
H2: {
Expand All @@ -29,6 +37,25 @@ export const typography = {
lineHeight: 'normal',
},
},
t1: {
fontSize: '16px',
lineHeight: '26px',
letterSpacing: '0.5px',
},
t2: {
fontSize: '20px',
lineHeight: '24px',
letterSpacing: '0.5px',
},
t3: {
fontSize: '20px',
lineHeight: '32px',
letterSpacing: '0.5px',
[mediaQueryMax(themeDark.breakpoints.mobile)]: {
fontSize: '16px',
lineHeight: '26px',
},
},
};

export enum FontStyle {
Expand Down
2 changes: 1 addition & 1 deletion src/assets/styles/resets.ts
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ const resets = {
// WebkitUserSelect: 'none',
WebkitTapHighlightColor: 'rgba(0, 0, 0, .05)',
lineHeight: 1,
overflow: 'hidden',
overflowX: 'hidden',
},
'ol, ul': {
listStyle: 'none',
Expand Down
10 changes: 10 additions & 0 deletions src/assets/styles/theme.ts
Original file line number Diff line number Diff line change
Expand Up @@ -45,11 +45,15 @@ const DarkColors: IColors = {
background: {
tint1: 'var(--dark-bg-tint-1)',
tint2: 'var(--dark-bg-tint-2)',
tint3: 'var(--dark-bg-tint-3)',
tint4: 'var(--dark-bg-tint-4)',
},
text: {
tint1: 'var(--dark-text-color-tint-1)',
tint2: 'var(--dark-text-color-tint-2)',
tint3: 'var(--dark-text-color-tint-3)',
tint4: 'var(--dark-text-color-tint-4)',
tint5: 'var(--dark-text-color-tint-5)',
},
border: {
tint1: 'var(--dark-border-tint-1)',
Expand All @@ -66,6 +70,7 @@ const DarkColors: IColors = {
gradient: {
tint1: 'var(--dark-bg-gradient-1)',
tint2: 'var(--dark-bg-gradient-2)',
tint3: 'var(--dark-bg-gradient-3)',
},
};

Expand All @@ -76,11 +81,15 @@ const LightColors: IColors = {
background: {
tint1: 'var(--light-bg-tint-1)',
tint2: 'var(--light-bg-tint-2)',
tint3: 'var(--light-bg-tint-3)',
tint4: 'var(--light-bg-tint-4)',
},
text: {
tint1: 'var(--light-text-color-tint-1)',
tint2: 'var(--light-text-color-tint-2)',
tint3: 'var(--light-text-color-tint-3)',
tint4: 'var(--light-text-color-tint-4)',
tint5: 'var(--light-text-color-tint-5)',
},
border: {
tint1: 'var(--light-border-tint-1)',
Expand All @@ -96,6 +105,7 @@ const LightColors: IColors = {
gradient: {
tint1: 'var(--light-bg-gradient-1)',
tint2: 'var(--light-bg-gradient-2)',
tint3: 'var(--light-bg-gradient-3)',
},
};

Expand Down
14 changes: 7 additions & 7 deletions src/components/common/Button/styles.ts
Original file line number Diff line number Diff line change
Expand Up @@ -19,10 +19,10 @@ const useStyles = createUseStyles<string, IButtonProps, ITheme>(
},
secondary: {
regular: colors.transparent,
hover: colors.gradient.tint2,
textColorRegular: colors.text.tint1,
textColorHover: colors.text.tint1,
borderColor: colors.gradient.tint2,
hover: colors.background.tint2,
textColorRegular: colors.text.tint2,
textColorHover: colors.text.tint2,
borderColor: colors.border.tint1,
},
};

Expand All @@ -44,7 +44,7 @@ const useStyles = createUseStyles<string, IButtonProps, ITheme>(
return '';
}
},
fontWeight: FontWeight.Medium,
fontWeight: FontWeight.Bold,
lineHeight: 'normal',
transition: 'all .3s ease',

Expand All @@ -71,8 +71,8 @@ const useStyles = createUseStyles<string, IButtonProps, ITheme>(
},
// backgroundColor: ({ styleType = 'primary' }) => (styleType ? typeColors[styleType]?.regular : ''),
background: ({ styleType = 'primary' }) => (styleType ? typeColors[styleType]?.regular : ''),
border: ({ styleType = 'primary' }) => (styleType === 'secondary' ? '1px solid transparent' : 'none'),
borderColor: ({ styleType = 'primary' }) => (styleType !== 'secondary' ? typeColors[styleType].borderColor : ''),
border: ({ styleType = 'primary' }) => (styleType === 'secondary' ? '2px solid transparent' : 'none'),
borderColor: ({ styleType = 'primary' }) => typeColors[styleType].borderColor,
color: ({ styleType = 'primary' }) => (styleType ? typeColors[styleType]?.textColorRegular : ''),

padding: ({ size, padding, icon, iconLeft, iconRight }: IButtonProps) => {
Expand Down
32 changes: 7 additions & 25 deletions src/components/helpers/SvgIcon/SvgIcon.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -58,43 +58,25 @@ export const SvgIconTypes: {
viewBoxW: 14,
viewBoxH: 14,
},
icon_facebook: {
icon_github: {
svg: (
<>
<g clipPath="url(#clip0_4329_14080)">
<path
fillRule="evenodd"
clipRule="evenodd"
d="M12 23C18.0751 23 23 18.0751 23 12C23 5.92487 18.0751 1 12 1C5.92487 1 1 5.92487 1 12C1 18.0751 5.92487 23 12 23ZM12 24C18.6274 24 24 18.6274 24 12C24 5.37258 18.6274 0 12 0C5.37258 0 0 5.37258 0 12C0 18.6274 5.37258 24 12 24Z"
/>
<path d="M10.5731 15.167C10.5116 14.3677 10.5116 13.5684 10.4501 12.7076C10.4501 12.2772 10.2656 11.9698 9.77376 11.9698C9.46633 11.9698 9.15891 12.0312 9.09742 11.6008C9.03594 11.0475 8.91297 10.4326 9.09742 9.87926C9.09742 9.81777 9.34336 9.69481 9.46633 9.69481C10.3886 9.87927 10.5731 9.38738 10.5731 8.64956C10.5731 6.68203 12.2332 5.63677 14.3851 5.75974C15 5.82123 15 6.31311 15 6.74351C14.9385 7.17391 15.1845 7.78877 14.3851 7.78877C13.7088 7.72728 13.2169 7.97323 13.2169 8.77253C13.2169 9.3259 13.2784 9.75628 13.9548 9.81777C14.9385 9.87925 14.7541 10.5556 14.7541 11.2319C14.8155 11.9698 14.4466 12.2157 13.7703 12.2157C13.094 12.2157 12.971 12.5846 12.971 13.1995C12.971 14.5521 12.971 15.8433 12.9095 17.196C12.848 18.0568 12.6636 18.1183 11.4953 18.0568C10.696 18.0568 10.5731 17.6879 10.6346 17.0115C10.5116 16.4582 10.5116 15.8433 10.5731 15.167Z" />
</g>
<defs>
<clipPath id="clip0_4329_14080">
<rect width="24" height="24" />
</clipPath>
</defs>
</>
<path d="M12.001 2c-5.525 0-10 4.475-10 10a9.994 9.994 0 0 0 6.837 9.488c.5.087.688-.213.688-.476c0-.237-.013-1.024-.013-1.862c-2.512.463-3.162-.612-3.362-1.175c-.113-.288-.6-1.175-1.025-1.413c-.35-.187-.85-.65-.013-.662c.788-.013 1.35.725 1.538 1.025c.9 1.512 2.337 1.087 2.912.825c.088-.65.35-1.087.638-1.337c-2.225-.25-4.55-1.113-4.55-4.938c0-1.088.387-1.987 1.025-2.687c-.1-.25-.45-1.275.1-2.65c0 0 .837-.263 2.75 1.024a9.28 9.28 0 0 1 2.5-.337c.85 0 1.7.112 2.5.337c1.913-1.3 2.75-1.024 2.75-1.024c.55 1.375.2 2.4.1 2.65c.637.7 1.025 1.587 1.025 2.687c0 3.838-2.337 4.688-4.562 4.938c.362.312.675.912.675 1.85c0 1.337-.013 2.412-.013 2.75c0 .262.188.574.688.474A10.016 10.016 0 0 0 22 12c0-5.525-4.475-10-10-10" />
),
viewBoxW: 24,
viewBoxH: 24,
},
icon_linkedin: {
svg: (
<>
<g clipPath="url(#clip0_4329_14090)">
<g clipPath="url(#clip0_587_669)">
<path
fillRule="evenodd"
clipRule="evenodd"
d="M12 23C18.0751 23 23 18.0751 23 12C23 5.92487 18.0751 1 12 1C5.92487 1 1 5.92487 1 12C1 18.0751 5.92487 23 12 23ZM12 24C18.6274 24 24 18.6274 24 12C24 5.37258 18.6274 0 12 0C5.37258 0 0 5.37258 0 12C0 18.6274 5.37258 24 12 24Z"
d="M18 3C18.7956 3 19.5587 3.31607 20.1213 3.87868C20.6839 4.44129 21 5.20435 21 6V18C21 18.7956 20.6839 19.5587 20.1213 20.1213C19.5587 20.6839 18.7956 21 18 21H6C5.20435 21 4.44129 20.6839 3.87868 20.1213C3.31607 19.5587 3 18.7956 3 18V6C3 5.20435 3.31607 4.44129 3.87868 3.87868C4.44129 3.31607 5.20435 3 6 3H18ZM18 5H6C5.73478 5 5.48043 5.10536 5.29289 5.29289C5.10536 5.48043 5 5.73478 5 6V18C5 18.2652 5.10536 18.5196 5.29289 18.7071C5.48043 18.8946 5.73478 19 6 19H18C18.2652 19 18.5196 18.8946 18.7071 18.7071C18.8946 18.5196 19 18.2652 19 18V6C19 5.73478 18.8946 5.48043 18.7071 5.29289C18.5196 5.10536 18.2652 5 18 5ZM8 10C8.24493 10 8.48134 10.09 8.66437 10.2527C8.84741 10.4155 8.96434 10.6397 8.993 10.883L9 11V16C8.99972 16.2549 8.90212 16.5 8.72715 16.6854C8.55218 16.8707 8.31305 16.9822 8.05861 16.9972C7.80416 17.0121 7.55362 16.9293 7.35817 16.7657C7.16271 16.6021 7.0371 16.3701 7.007 16.117L7 16V11C7 10.7348 7.10536 10.4804 7.29289 10.2929C7.48043 10.1054 7.73478 10 8 10ZM11 9C11.2342 8.99996 11.461 9.08213 11.6408 9.23216C11.8206 9.3822 11.9421 9.59059 11.984 9.821C12.1852 9.70431 12.3933 9.59979 12.607 9.508C13.274 9.223 14.273 9.066 15.175 9.349C15.648 9.499 16.123 9.779 16.475 10.256C16.79 10.681 16.96 11.198 16.994 11.779L17 12V16C16.9997 16.2549 16.9021 16.5 16.7272 16.6854C16.5522 16.8707 16.313 16.9822 16.0586 16.9972C15.8042 17.0121 15.5536 16.9293 15.3582 16.7657C15.1627 16.6021 15.0371 16.3701 15.007 16.117L15 16V12C15 11.67 14.92 11.516 14.868 11.445C14.7934 11.3522 14.6905 11.2862 14.575 11.257C14.227 11.147 13.726 11.205 13.393 11.347C12.893 11.561 12.435 11.897 12.123 12.208L12 12.34V16C11.9997 16.2549 11.9021 16.5 11.7272 16.6854C11.5522 16.8707 11.313 16.9822 11.0586 16.9972C10.8042 17.0121 10.5536 16.9293 10.3582 16.7657C10.1627 16.6021 10.0371 16.3701 10.007 16.117L10 16V10C10 9.73478 10.1054 9.48043 10.2929 9.29289C10.4804 9.10536 10.7348 9 11 9ZM8 7C8.26522 7 8.51957 7.10536 8.70711 7.29289C8.89464 7.48043 9 7.73478 9 8C9 8.26522 8.89464 8.51957 8.70711 8.70711C8.51957 8.89464 8.26522 9 8 9C7.73478 9 7.48043 8.89464 7.29289 8.70711C7.10536 8.51957 7 8.26522 7 8C7 7.73478 7.10536 7.48043 7.29289 7.29289C7.48043 7.10536 7.73478 7 8 7Z"
fill="#BABABA"
/>
<path d="M10.3613 13.6243C10.3613 12.7107 10.3613 11.8623 10.3613 10.9487C10.4265 9.774 11.0791 9.18667 12.1233 9.64348C12.6454 9.83926 12.9717 9.90452 13.3632 9.70874C14.3421 9.18667 15.1905 9.57822 16.1041 9.90451C16.6914 10.1003 17.0177 10.5571 17.2135 11.1444C17.7356 12.8412 17.7356 14.5379 17.6703 16.2347C17.6703 16.6915 17.4745 17.0178 16.9525 17.083C16.822 17.083 16.7567 17.083 16.6262 17.1483C14.7989 17.4746 14.6031 17.3441 14.7989 15.5168C14.8642 14.7337 14.9947 13.9506 14.7989 13.1675C14.6684 12.7759 14.5379 12.3191 14.0158 12.2539C13.559 12.1886 13.2327 12.5149 12.9717 12.8412C12.7106 13.1675 12.6454 13.559 12.6454 14.0158C12.6454 14.6684 12.6454 15.2558 12.6454 15.9084C12.6454 17.2136 12.5801 17.2788 11.4054 17.2136C10.296 17.2136 10.296 17.2136 10.296 16.1041C10.3613 15.321 10.3613 14.4727 10.3613 13.6243Z" />
<path d="M6.77229 13.4939C6.77229 12.5802 6.77229 11.7319 6.77229 10.8182C6.77229 10.0351 7.22912 9.90461 7.88171 9.83936C8.59956 9.83936 8.73007 10.2309 8.73007 10.8182C8.86059 12.515 8.8606 14.2117 8.79534 15.9085C8.79534 16.4958 8.79534 17.2137 7.88171 17.2137C7.0986 17.2789 6.70703 16.9526 6.70703 16.1695C6.70703 15.2559 6.70703 14.277 6.70703 13.3634C6.70703 13.4939 6.77229 13.4939 6.77229 13.4939Z" />
<path d="M7.3594 6.25C8.33828 6.25 8.86037 6.64156 8.86037 7.22889C8.86037 7.94674 8.01199 8.79511 7.3594 8.79511C6.7068 8.79511 6.25 8.27304 6.25 7.55519C6.31526 6.70682 6.7068 6.25 7.3594 6.25Z" />
</g>
<defs>
<clipPath id="clip0_4329_14090">
<rect width="24" height="24" />
<clipPath id="clip0_587_669">
<rect width="24" height="24" fill="white" />
</clipPath>
</defs>
</>
Expand Down
2 changes: 1 addition & 1 deletion src/components/helpers/SvgIcon/types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ export type IconTypes =
| 'icon_moon'
| 'icon_sun'
| 'icon_AmFlag'
| 'icon_facebook'
| 'icon_github'
| 'icon_linkedin'
| 'icon_instagram';

Expand Down
67 changes: 67 additions & 0 deletions src/components/landing/IntroSection/IntroSection.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,67 @@
import classNames from 'classnames';
import { useTranslation } from 'react-i18next';

import myImage from '@assets/images/photo.webp';
import SvgIcon from '@components/helpers/SvgIcon';
import Button from '@components/common/Button';
import useGapSupport from '@hooks/useGapSupport';
import myCV from '@assets/Tigran-Martirosyan-CV.pdf';

import useStyles from './styles';

function IntroSection() {
const { t } = useTranslation();
const isGapSupport = useGapSupport();
const classes = useStyles({ isGapSupport });
const handleDownloadCV = () => {
const link = document.createElement('a');
link.href = myCV;
link.setAttribute('download', 'Tigran_Martirosyan_CV.pdf');
document.body.appendChild(link);
link.click();
document.body.removeChild(link);
};
const handleHireMe = () => {
window.location.href = 'mailto:tigran.v.mart@gmail.com?subject=Job%20Application&body=Hello%20Tigran';
};
return (
<section className={classes.root}>
<div className={classNames(classes.inner, 'container')}>
<div className={classes.left}>
<div className={classes.leftInner}>
<p className={classes.sayHi}>{t('intro.sayHi')}</p>
<p className={classes.fullName}>{t('intro.fullName')}</p>
<h1 className={classes.profession}>{t('intro.profession')}</h1>
<div className={classes.socialButtonsGroup}>
<a target="_blank" href="https://www.linkedin.com/in/tigran-martirosyan-b261591ab" className={classes.socialBtn} aria-label="go to Linkedin page" rel="noreferrer">
<SvgIcon icon="icon_linkedin" fill="#BABABA" width={24} height={24} />
</a>
<a target="_blank" href="https://github.com/TigMart" className={classes.socialBtn} aria-label="go to Github profile" rel="noreferrer">
<SvgIcon icon="icon_github" fill="#BABABA" width={24} height={24} />
</a>
</div>
<div className={classes.actionButtonGroup}>
<Button styleType="primary" name={t('intro.buttonHire')} size="large" onClick={handleHireMe} />
<Button styleType="secondary" name={t('intro.buttonCV')} size="large" onClick={handleDownloadCV} />
</div>
<div className={classes.infoGroup}>
<div className={classes.infoItem}>
<span className={classes.count}>3+</span>
<p className={classes.text}>{t('intro.info.0')}</p>
</div>
<div className={classes.infoItem}>
<span className={classes.count}>10+</span>
<p className={classes.text}>{t('intro.info.1')}</p>
</div>
</div>
</div>
</div>
<div className={classes.right}>
<img className={classes.myImg} src={myImage} alt="Tigran Martirosyan" width={560} height={675} />
</div>
</div>
</section>
);
}

export default IntroSection;
1 change: 1 addition & 0 deletions src/components/landing/IntroSection/index.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
export { default } from './IntroSection';
Loading

0 comments on commit 45fe360

Please sign in to comment.