Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
S
sevenpro-frontend
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
FAP
sevenpro-frontend
Commits
b65b76d6
Commit
b65b76d6
authored
Aug 27, 2024
by
Wellton Quirino
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
feat: add banners in categories page
parent
5d6c743c
Changes
17
Show whitespace changes
Inline
Side-by-side
Showing
17 changed files
with
74 additions
and
24 deletions
+74
-24
comunicacao-mobile.jpg
public/images/banners/comunicacao-mobile.jpg
+0
-0
comunicacao.jpg
public/images/banners/comunicacao.jpg
+0
-0
educacao-mobile.jpg
public/images/banners/educacao-mobile.jpg
+0
-0
educacao.jpg
public/images/banners/educacao.jpg
+0
-0
negocios-mobile.jpg
public/images/banners/negocios-mobile.jpg
+0
-0
negocios.jpg
public/images/banners/negocios.jpg
+0
-0
saude-mobile.jpg
public/images/banners/saude-mobile.jpg
+0
-0
saude.jpg
public/images/banners/saude.jpg
+0
-0
tecnologia-mobile.jpg
public/images/banners/tecnologia-mobile.jpg
+0
-0
tecnologia.jpg
public/images/banners/tecnologia.jpg
+0
-0
teologia-mobile.jpg
public/images/banners/teologia-mobile.jpg
+0
-0
teologia.jpg
public/images/banners/teologia.jpg
+0
-0
page.tsx
src/app/curso/[courseId]/page.tsx
+2
-6
page.tsx
src/app/empresas/page.tsx
+1
-1
page.tsx
src/app/estudantes/page.tsx
+1
-1
page.tsx
src/app/profissionais/page.tsx
+1
-1
banner-category.tsx
src/components/banner-category.tsx
+69
-15
No files found.
public/images/banners/comunicacao-mobile.jpg
0 → 100644
View file @
b65b76d6
118 KB
public/images/banners/comunicacao.jpg
0 → 100644
View file @
b65b76d6
295 KB
public/images/banners/educacao-mobile.jpg
0 → 100644
View file @
b65b76d6
109 KB
public/images/banners/educacao.jpg
0 → 100644
View file @
b65b76d6
274 KB
public/images/banners/negocios-mobile.jpg
0 → 100644
View file @
b65b76d6
117 KB
public/images/banners/negocios.jpg
0 → 100644
View file @
b65b76d6
302 KB
public/images/banners/saude-mobile.jpg
0 → 100644
View file @
b65b76d6
110 KB
public/images/banners/saude.jpg
0 → 100644
View file @
b65b76d6
236 KB
public/images/banners/tecnologia-mobile.jpg
0 → 100644
View file @
b65b76d6
133 KB
public/images/banners/tecnologia.jpg
0 → 100644
View file @
b65b76d6
340 KB
public/images/banners/teologia-mobile.jpg
0 → 100644
View file @
b65b76d6
102 KB
public/images/banners/teologia.jpg
0 → 100644
View file @
b65b76d6
260 KB
src/app/curso/[courseId]/page.tsx
View file @
b65b76d6
...
@@ -13,14 +13,10 @@ import { Button } from '@/components/ui/button'
...
@@ -13,14 +13,10 @@ import { Button } from '@/components/ui/button'
import
{
Separator
}
from
'@/components/ui/separator'
import
{
Separator
}
from
'@/components/ui/separator'
import
imageCapa
from
'../../../../public/images/banner.png'
import
imageCapa
from
'../../../../public/images/banner.png'
export
default
function
CoursePage
({
export
default
function
CoursePage
()
{
params
,
}:
{
params
:
{
courseId
:
string
}
})
{
return
(
return
(
<>
<>
<
BannerCategory
title=
{
params
.
courseId
}
/>
<
BannerCategory
/>
<
div
className=
"flex flex-col md:flex-row px-6 pt-20 gap-6"
>
<
div
className=
"flex flex-col md:flex-row px-6 pt-20 gap-6"
>
<
div
className=
"flex flex-col gap-7"
>
<
div
className=
"flex flex-col gap-7"
>
<
h1
className=
"block md:hidden text-green-400 text-3xl font-thin"
>
<
h1
className=
"block md:hidden text-green-400 text-3xl font-thin"
>
...
...
src/app/empresas/page.tsx
View file @
b65b76d6
...
@@ -14,8 +14,8 @@ import { Suspense } from 'react'
...
@@ -14,8 +14,8 @@ import { Suspense } from 'react'
export
default
function
Companies
()
{
export
default
function
Companies
()
{
return
(
return
(
<
main
>
<
main
>
<
BannerCategory
title=
"Empresas"
/>
<
Suspense
fallback=
{
<
SkeletonSerachParams
/>
}
>
<
Suspense
fallback=
{
<
SkeletonSerachParams
/>
}
>
<
BannerCategory
/>
<
NavLinkCategory
/>
<
NavLinkCategory
/>
</
Suspense
>
</
Suspense
>
<
SearchFilter
/>
<
SearchFilter
/>
...
...
src/app/estudantes/page.tsx
View file @
b65b76d6
...
@@ -14,8 +14,8 @@ import { Suspense } from 'react'
...
@@ -14,8 +14,8 @@ import { Suspense } from 'react'
export
default
function
Students
()
{
export
default
function
Students
()
{
return
(
return
(
<
main
>
<
main
>
<
BannerCategory
title=
"Estudantes"
/>
<
Suspense
fallback=
{
<
SkeletonSerachParams
/>
}
>
<
Suspense
fallback=
{
<
SkeletonSerachParams
/>
}
>
<
BannerCategory
/>
<
NavLinkCategory
/>
<
NavLinkCategory
/>
</
Suspense
>
</
Suspense
>
<
SearchFilter
/>
<
SearchFilter
/>
...
...
src/app/profissionais/page.tsx
View file @
b65b76d6
...
@@ -14,8 +14,8 @@ import { Suspense } from 'react'
...
@@ -14,8 +14,8 @@ import { Suspense } from 'react'
export
default
function
Professionals
()
{
export
default
function
Professionals
()
{
return
(
return
(
<
main
>
<
main
>
<
BannerCategory
title=
"Profissionais"
/>
<
Suspense
fallback=
{
<
SkeletonSerachParams
/>
}
>
<
Suspense
fallback=
{
<
SkeletonSerachParams
/>
}
>
<
BannerCategory
/>
<
NavLinkCategory
/>
<
NavLinkCategory
/>
</
Suspense
>
</
Suspense
>
<
SearchFilter
/>
<
SearchFilter
/>
...
...
src/components/banner-category.tsx
View file @
b65b76d6
'use client'
import
Image
from
'next/image'
import
Image
from
'next/image'
import
bannerBusiness
from
'../../public/images/banners/business_banner_01.jpg'
import
{
useSearchParams
}
from
'next/navigation'
import
bannerProfessional
from
'../../public/images/banners/professional_banner.jpg'
import
bannerComunicacao
from
'../../public/images/banners/comunicacao.jpg'
import
bannerEducacao
from
'../../public/images/banners/educacao.jpg'
import
bannerNegocios
from
'../../public/images/banners/negocios.jpg'
import
bannerSaude
from
'../../public/images/banners/saude.jpg'
import
bannerStudants
from
'../../public/images/banners/students_banner.jpg'
import
bannerStudants
from
'../../public/images/banners/students_banner.jpg'
import
bannerTecnologia
from
'../../public/images/banners/tecnologia.jpg'
import
bannerTeologia
from
'../../public/images/banners/teologia.jpg'
import
bannerComunicacaoMobile
from
'../../public/images/banners/comunicacao-mobile.jpg'
import
bannerEducacaoMobile
from
'../../public/images/banners/educacao-mobile.jpg'
import
bannerNegociosMobile
from
'../../public/images/banners/negocios-mobile.jpg'
import
bannerSaudeMobile
from
'../../public/images/banners/saude-mobile.jpg'
import
bannerTecnologiaMobile
from
'../../public/images/banners/tecnologia-mobile.jpg'
import
bannerTeologiaMobile
from
'../../public/images/banners/teologia-mobile.jpg'
export
function
BannerCategory
()
{
const
searchParams
=
useSearchParams
()
const
category
=
searchParams
.
get
(
'categoria'
)
function
desktopBannerCategory
()
{
switch
(
category
)
{
case
'tecnologia'
:
return
bannerTecnologia
case
'negocios'
:
return
bannerNegocios
case
'comunicacao'
:
return
bannerComunicacao
case
'educacao'
:
return
bannerEducacao
case
'saude'
:
return
bannerSaude
case
'teologia'
:
return
bannerTeologia
default
:
return
bannerStudants
}
}
function
mobileBannerCategory
()
{
switch
(
category
)
{
case
'tecnologia'
:
return
bannerTecnologiaMobile
case
'negocios'
:
return
bannerNegociosMobile
case
'comunicacao'
:
return
bannerComunicacaoMobile
case
'educacao'
:
return
bannerEducacaoMobile
case
'saude'
:
return
bannerSaudeMobile
case
'teologia'
:
return
bannerTeologiaMobile
default
:
return
bannerStudants
}
}
type
BannerProps
=
{
title
:
string
}
export
function
BannerCategory
({
title
}:
BannerProps
)
{
return
(
return
(
<
div
className=
"
h-[300px] flex items-center justify-end"
>
<
div
className=
"h-[300px] flex items-center justify-end"
>
<
Image
<
Image
alt=
"banner"
alt=
"banner"
className=
"w-full h-full object-cover object-left-top"
className=
"hidden md:flex w-full h-full object-cover"
src=
{
src=
{
desktopBannerCategory
()
}
title
===
'Estudantes'
unoptimized
?
bannerStudants
/>
:
title
===
'Profissionais'
<
Image
?
bannerProfessional
alt=
"banner"
:
bannerBusiness
className=
"flex md:hidden w-full h-full object-cover"
}
src=
{
mobileBannerCategory
()
}
unoptimized
/>
/>
</
div
>
</
div
>
)
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment