Skip to content
This repository has been archived by the owner on Nov 29, 2023. It is now read-only.

feat/landing-fourth-step #15

Merged
merged 51 commits into from
Sep 11, 2023
Merged
Show file tree
Hide file tree
Changes from 5 commits
Commits
Show all changes
51 commits
Select commit Hold shift + click to select a range
2b9b944
refactor: remove needless wrapper in item component in process sectio…
Mirved64 Aug 13, 2023
7307bba
feat: add radii in theme, add border radius props in ui/button, add b…
Mirved64 Aug 13, 2023
8eac678
refactor: rework box IT in hero section
Mirved64 Aug 14, 2023
1015838
Merge branch 'feat/landing-third-step' into feat/landing-fourth-step
Mirved64 Aug 14, 2023
8287803
fix: rework social component
Mirved64 Aug 14, 2023
bd7535a
feat: add borders
Mirved64 Aug 14, 2023
8433f85
feat: add toolbars in slider section
Mirved64 Aug 14, 2023
612b43e
Merge branch 'feat/landing-third-step' into feat/landing-fourth-step
Mirved64 Aug 15, 2023
e0c0446
feat: add background color gradient
Mirved64 Aug 15, 2023
3fe5f91
feat: add border radius to sections
Mirved64 Aug 15, 2023
84b8d98
fix: sections match the design
Mirved64 Aug 16, 2023
50395c5
Merge branch 'feat/landing-third-step' into feat/landing-fourth-step
Mirved64 Aug 21, 2023
e19ad66
fix: tune top props in index page
Mirved64 Aug 21, 2023
15e82bb
feat: add ui/accordion, ui/drawer, hover hook, rework faq section
Mirved64 Aug 21, 2023
6f76555
feat: add hover to accordion
Mirved64 Aug 22, 2023
6c62e00
fix: resolve console warning, fix hover in faq section
Mirved64 Aug 22, 2023
e5b23f9
feat: add ui/slider, rework process to steps component, rework slider…
Mirved64 Aug 23, 2023
eaa455c
feat: add hover to ui/card
Mirved64 Aug 23, 2023
5a374b8
fix: check framer-motion versions, check layout of ui/accordion
Mirved64 Aug 23, 2023
3dd9b8a
feat: add hover to links in navigation section
Mirved64 Aug 23, 2023
365d8fe
feat: add ui/navbar with scrollspy in project
Mirved64 Aug 24, 2023
17b9fe9
feat: add drawer to navigation section, rework navigation section, ad…
Mirved64 Aug 24, 2023
4e3d8dc
feat: add cards to drawer in navigation section, rework ui/card
Mirved64 Aug 24, 2023
9811852
fix: create items for drawer in navigation section, check layout of c…
Mirved64 Aug 24, 2023
ab0b22b
feat: add hover and pressed props and styles in ui/button
Mirved64 Aug 25, 2023
e6dd03e
refactor: check layout in faq, navigation sections and ui/accordion
Mirved64 Aug 25, 2023
0115f1b
refactor: remove needless layout, check layout in project
Mirved64 Aug 29, 2023
d4d47dd
chore: replace divider.color to background.color
Mirved64 Aug 29, 2023
6a0d360
chore: replace lineHeight in px to lineHeight in percents
Mirved64 Aug 29, 2023
ea19453
refactor: change width of answer box in accordion
Mirved64 Aug 29, 2023
0d3b702
refactor: rework ui/condition
Mirved64 Aug 29, 2023
64727e3
refactor: add text color of answer in mobile
Mirved64 Aug 29, 2023
7bfa4c6
refactor: change indent in card desktop
Mirved64 Aug 29, 2023
58acd6d
refactor: check background color in hero and delimiter in about section
Mirved64 Aug 29, 2023
5ed22c8
refactor: change font color and text in cards mobile
Mirved64 Aug 30, 2023
cb2f12c
refactor: check font size and line height in hero section
Mirved64 Aug 30, 2023
8bf112f
refactor: swap inline to flex in courses section
Mirved64 Aug 31, 2023
7060877
feat: add necessary interfaces
Mirved64 Sep 1, 2023
041779f
refactor: change "Column width='100%'" to "Column fill", replace ()=>…
Mirved64 Sep 1, 2023
7c9a7ea
refactor: check dependencies in packages
Mirved64 Sep 1, 2023
f0b54d0
refactor: use enum in cards interface
Mirved64 Sep 1, 2023
5d2cb5f
refactor: chande string to enum in filter function in courses section
Mirved64 Sep 4, 2023
ca76bec
refactor: remove isDesktop, rework handleClose and handleOpen in navi…
Mirved64 Sep 7, 2023
ddcfdb5
refactor: check type of props
Mirved64 Sep 7, 2023
b055fff
refactor: rework drawer and navigation section
Mirved64 Sep 7, 2023
b0e7428
refactor: use DRY pattern
Mirved64 Sep 7, 2023
ed67fb7
refactor: devide some components
Mirved64 Sep 8, 2023
4d55719
refactor: rename item to navlink in navigation section
Mirved64 Sep 11, 2023
a2c8a9e
refactor: rename item to step in process section, rename items to que…
Mirved64 Sep 11, 2023
62d1933
refactor: remove needless types of props
Mirved64 Sep 11, 2023
95680bb
refactor: rename navlink to navlinkitem in navigation section
Mirved64 Sep 11, 2023
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2,396 changes: 726 additions & 1,670 deletions .pnp.cjs

Large diffs are not rendered by default.

1 change: 1 addition & 0 deletions landing/entrypoints/renderer/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@
"start": "yarn next start src"
},
"dependencies": {
"@emotion/css": "11.11.0",
"@emotion/react": "11.11.1",
"@emotion/styled": "11.11.0",
"next": "12.3.4",
Expand Down
4 changes: 2 additions & 2 deletions landing/fragments/landing-about/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,8 @@
"@ui/utils": "workspace: 0.0.1"
},
"devDependencies": {
"@types/react": "18.2.9",
"@types/react-dom": "18.2.4",
"react": "18.2.0",
"react-dom": "18.2.0",
"react-intl": "6.0.8"
},
"peerDependencies": {
Expand Down
4 changes: 2 additions & 2 deletions landing/fragments/landing-courses/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,8 @@
"@ui/utils": "workspace: 0.0.1"
},
"devDependencies": {
"@types/react": "18.2.9",
"@types/react-dom": "18.2.4",
"react": "18.2.0",
"react-dom": "18.2.0",
"react-intl": "6.0.8"
},
"peerDependencies": {
Expand Down
29 changes: 22 additions & 7 deletions landing/fragments/landing-courses/src/cards-list/cards-list.ts
Original file line number Diff line number Diff line change
@@ -1,8 +1,23 @@
export const CadrsList = [
export enum CardCategory { // eslint-disable-line
Teach = 'обучение',
MiniCourse = 'мини-курс',
EducationalMaterial = 'учебный материал',
}

interface CardProps {
id: number
isMobileOnly?: boolean
category: CardCategory
title: string
descriptionMobile?: string
descriptionDesktop?: string
}

export const CadrsList: CardProps[] = [
{
id: 0,
isMobileOnly: false,
category: 'обучение',
category: CardCategory.Teach,
title: 'Frontend Engineer',
descriptionMobile:
'Вы изучите фундаментальные знания в ИТ и прокачаетесь в направлении программирования. Получите востребованную профессию и возможность открыть бизнес в сфере информационных технологий',
Expand All @@ -12,7 +27,7 @@ export const CadrsList = [
{
id: 1,
isMobileOnly: false,
category: 'мини-курс',
category: CardCategory.MiniCourse,
title: 'Основы разработки',
descriptionMobile:
'Вы изучите фундаментальные знания в ИТ и прокачаетесь в направлении программирования. Получите востребованную профессию и возможность открыть бизнес в сфере информационных технологий',
Expand All @@ -22,25 +37,25 @@ export const CadrsList = [
{
id: 2,
isMobileOnly: false,
category: 'учебный материал',
category: CardCategory.EducationalMaterial,
title: 'Как использовать библиотеки',
},
{
id: 3,
isMobileOnly: false,
category: 'учебный материал',
category: CardCategory.EducationalMaterial,
title: 'Дизайн, Figma, Математика',
},
{
id: 4,
isMobileOnly: true,
category: 'учебный материал',
category: CardCategory.EducationalMaterial,
title: 'Как использовать библиотеки',
},
{
id: 5,
isMobileOnly: true,
category: 'учебный материал',
category: CardCategory.EducationalMaterial,
title: 'Дизайн, Figma, Математика',
},
]
27 changes: 12 additions & 15 deletions landing/fragments/landing-courses/src/cards/cards.component.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ import { Swiper } from '@ui/swiper'
import { SwiperSlide } from '@ui/swiper'
import { useWindowWidth } from '@ui/utils'

import { CardCategory } from '../cards-list'
import { CadrsList } from '../cards-list'

export const CardsLearning = () => {
Expand All @@ -19,10 +20,10 @@ export const CardsLearning = () => {
return (
<Column>
{CadrsList.filter(
(card) => card.category === 'обучение' || card.category === 'мини-курс'
(card) => card.category === CardCategory.Teach || card.category === CardCategory.MiniCourse
).map((card) => (
<Column key={card.id}>
<Condition match={card.category === 'обучение' && isDesktop}>
<Condition match={card.category === CardCategory.Teach && isDesktop}>
<Card
category={card.category}
titleDesktop={card.title}
Expand All @@ -32,7 +33,7 @@ export const CardsLearning = () => {
/>
</Condition>

<Condition match={card.category === 'обучение' && isMobile}>
<Condition match={card.category === CardCategory.Teach && isMobile}>
<Card
category={card.category}
titleDesktop={card.title}
Expand All @@ -42,7 +43,7 @@ export const CardsLearning = () => {
/>
</Condition>

<Condition match={card.category === 'мини-курс' && isDesktop}>
<Condition match={card.category === CardCategory.MiniCourse && isDesktop}>
<Card
category={card.category}
titleDesktop={card.title}
Expand All @@ -52,7 +53,7 @@ export const CardsLearning = () => {
/>
</Condition>

<Condition match={card.category === 'мини-курс' && isMobile}>
<Condition match={card.category === CardCategory.MiniCourse && isMobile}>
<Card
category={card.category}
titleDesktop={card.title}
Expand All @@ -71,11 +72,9 @@ export const CardsLearning = () => {

export const CardsMaterials = () => (
<Row>
{CadrsList.filter((card) => card.category === 'учебный материал' && !card.isMobileOnly).map((
card,
index,
array
) => (
{CadrsList.filter(
(card) => card.category === CardCategory.EducationalMaterial && !card.isMobileOnly
).map((card, index, array) => (
<Row key={card.id}>
<Condition match={index !== 0 && index !== array.length - 1}>
<Layout flexBasis={[10, 20]} flexShrink='0' />
Expand Down Expand Up @@ -106,11 +105,9 @@ export const CardsMaterials = () => (

export const CardsSwiper: FC<SwiperProps> = ({ spaceBetween, slidesPerView, className }) => (
<Swiper spaceBetween={spaceBetween} slidesPerView={slidesPerView} className={className}>
{CadrsList.filter((card) => card.category === 'учебный материал' && card.isMobileOnly).map((
card,
index,
array
) => (
{CadrsList.filter(
(card) => card.category === CardCategory.EducationalMaterial && card.isMobileOnly
).map((card, index, array) => (
<SwiperSlide key={card.id}>
<Row>
<Condition match={index === 0}>
Expand Down
4 changes: 2 additions & 2 deletions landing/fragments/landing-faq/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,8 @@
"@ui/utils": "workspace: 0.0.1"
},
"devDependencies": {
"@types/react": "18.2.9",
"@types/react-dom": "18.2.4",
"react": "18.2.0",
"react-dom": "18.2.0",
"react-intl": "6.0.8"
},
"peerDependencies": {
Expand Down
8 changes: 7 additions & 1 deletion landing/fragments/landing-faq/src/data/data-question.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,10 @@
export const Question = {
interface QuestionProps {
id: number
question: string
answer: string
}

export const Question: QuestionProps = {
id: 0,
question: 'Подойдёт ли мне профессия?',
answer:
Expand Down
5 changes: 2 additions & 3 deletions landing/fragments/landing-faq/src/faq.component.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,7 @@ import { Question } from './data'
export const Faq = () => {
const { isMobile, isDesktop } = useWindowWidth()

const Items = () =>
Array.from({ length: 6 }, () => Question).map((el, index) => ({ ...el, id: index }))
const Items = Array.from({ length: 6 }, () => Question).map((el, index) => ({ ...el, id: index }))

return (
<Row>
Expand Down Expand Up @@ -68,7 +67,7 @@ export const Faq = () => {
<Layout flexBasis={40} />
</Condition>

{Items().map((item, index, array) => (
{Items.map((item, index, array) => (
<Column key={item.id}>
<Condition match={index !== 0}>
<Layout flexBasis={[16, 40]} />
Expand Down
4 changes: 2 additions & 2 deletions landing/fragments/landing-hero/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,8 @@
"@ui/utils": "workspace: 0.0.1"
},
"devDependencies": {
"@types/react": "18.2.9",
"@types/react-dom": "18.2.4",
"react": "18.2.0",
"react-dom": "18.2.0",
"react-intl": "6.0.8"
},
"peerDependencies": {
Expand Down
4 changes: 2 additions & 2 deletions landing/fragments/landing-navigation/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -18,9 +18,9 @@
"react-scroll": "1.8.9"
},
"devDependencies": {
"@types/react": "18.2.9",
"@types/react-dom": "18.2.4",
"@types/react-scroll": "1.8.7",
"react": "18.2.0",
"react-dom": "18.2.0",
"react-intl": "6.0.8"
},
"peerDependencies": {
Expand Down
11 changes: 9 additions & 2 deletions landing/fragments/landing-navigation/src/data/data-card.ts
Original file line number Diff line number Diff line change
@@ -1,11 +1,18 @@
export const CardDataDesktop = {
interface CardProp {
id: number
category: string
title: string
description?: string
}

export const CardDataDesktop: CardProp = {
id: 0,
category: 'обучение',
title: 'Frontend Engineer',
description:
'Вы изучите фундаментальные знания в ИТ и прокачаетесь в направлении программирования. Получите востребованную профессию и возможность открыть бизнес в сфере информационных технологий',
}
export const CardDataMobile = [
export const CardDataMobile: CardProp[] = [
{
id: 0,
category: 'базовый',
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,10 @@
export const NavLinks = [
interface NavLinksProps {
id: string | number
name: string
path: string
}

export const NavLinks: NavLinksProps[] = [
{
id: 'academy',
name: 'Academy',
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
import { Scrollspy } from '@makotot/ghostui'

import React from 'react'
import { FC } from 'react'
import { FormattedMessage } from 'react-intl'

import { Background } from '@ui/background'
Expand All @@ -22,12 +23,15 @@ import { CardDataDesktop } from '../data'
import { CardDataMobile } from '../data'
import { NavLinks } from '../data'
import { ItemDrawer } from '../item'
import { DrawerProps } from './drawer.interfaces'

export const Drawer = ({ active, onClose, sectionRefs }) => {
export const Drawer: FC<DrawerProps> = ({ active, onClose, sectionRefs }) => {
const { isMobile, isDesktop } = useWindowWidth()

const cardsList = () =>
Array.from({ length: 3 }, () => CardDataDesktop).map((el, index) => ({ ...el, id: index }))
const cardsList = Array.from({ length: 3 }, () => CardDataDesktop).map((el, index) => ({
TorinAsakura marked this conversation as resolved.
Show resolved Hide resolved
...el,
id: index,
}))

return (
<DrawerContainer heightDrawer='100%' active={active}>
Expand Down Expand Up @@ -89,7 +93,7 @@ export const Drawer = ({ active, onClose, sectionRefs }) => {
<Layout flexBasis={50} />
<Row>
<Layout flexBasis={40} flexShrink='0' />
{cardsList().map((card, index, array) => (
{cardsList.map((card, index, array) => (
<Row key={card.id}>
<Condition match={index === array.length - 1}>
<Layout flexBasis={20} flexShrink='0' />
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
export interface DrawerProps {
active: boolean
onClose: () => void
sectionRefs: React.RefObject<HTMLDivElement>[]
}
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
import React from 'react'
import { FC } from 'react'
TorinAsakura marked this conversation as resolved.
Show resolved Hide resolved
import { FormattedMessage } from 'react-intl'
import { useState } from 'react'

Expand All @@ -15,14 +16,18 @@ import { useWindowWidth } from '@ui/utils'
import { NavLinks } from './data'
import { Drawer } from './drawer'
import { Item } from './item'
import { NavigationProps } from './navigation.interfaces'

export const Navigation = ({ sectionRefs }) => {
export const Navigation: FC<NavigationProps> = ({ sectionRefs }) => {
const { isMobile, isDesktop } = useWindowWidth()
const [active, setActive] = useState<boolean>(false)

const handleClose = () => setActive(false)
const handleOpen = () => setActive(true)

return (
<>
<Drawer active={active} onClose={() => setActive(false)} sectionRefs={sectionRefs} />
<Drawer active={active} onClose={handleClose} sectionRefs={sectionRefs} />
<Row height={[80, 120]} alignItems='center' justifyContent='center'>
<Condition match={isMobile}>
<Layout flexBasis={20} />
Expand All @@ -35,7 +40,7 @@ export const Navigation = ({ sectionRefs }) => {

<Box width={100}>
<Button
onClick={() => setActive(true)}
onClick={handleOpen}
variant='ghostBackgroundWhiteText'
size='smallSizeLittleRadii'
icon={<ArrowDownIcon width={9} height={5} />}
Expand Down Expand Up @@ -74,7 +79,7 @@ export const Navigation = ({ sectionRefs }) => {

<Box width={136}>
<Button
onClick={() => setActive(true)}
onClick={handleOpen}
variant='ghostBackgroundWhiteText'
size='bigSizeNormalRadiiBigPadding'
icon={<ArrowDownIcon width={12} height={6} />}
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
export interface NavigationProps {
sectionRefs: React.RefObject<HTMLDivElement>[]
}
4 changes: 2 additions & 2 deletions landing/fragments/landing-process/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,8 @@
"@ui/utils": "workspace: 0.0.1"
},
"devDependencies": {
"@types/react": "18.2.9",
"@types/react-dom": "18.2.4",
"react": "18.2.0",
"react-dom": "18.2.0",
"react-intl": "6.0.8"
},
"peerDependencies": {
Expand Down
4 changes: 2 additions & 2 deletions landing/fragments/landing-steps/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,8 @@
"@ui/utils": "workspace: 0.0.1"
},
"devDependencies": {
"@types/react": "18.2.9",
"@types/react-dom": "18.2.4",
"react": "18.2.0",
"react-dom": "18.2.0",
"react-intl": "6.0.8"
},
"peerDependencies": {
Expand Down
Loading