Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Sign in / Register
Toggle navigation
O
official
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
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Commits
Issue Boards
Open sidebar
吕祺
official
Commits
c0ba39ba
Commit
c0ba39ba
authored
Jul 24, 2023
by
吕祺
⛹🏽
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix
parent
aeabcb13
Changes
3
Pipelines
1
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
274 additions
and
222 deletions
+274
-222
portfolioChi.md
content/portfolioChi.md
+96
-71
portfolioEN.md
content/portfolioEN.md
+166
-148
portfolio.js
pages/portfolio.js
+12
-3
No files found.
content/portfolioChi.md
View file @
c0ba39ba
This diff is collapsed.
Click to expand it.
content/portfolioEN.md
View file @
c0ba39ba
This diff is collapsed.
Click to expand it.
pages/portfolio.js
View file @
c0ba39ba
import
React
,
{
Component
}
from
'react'
import
classnames
from
'classnames'
import
portfolioPage
from
'../content/portfolioPage.md'
import
portfolioChi
from
'../content/portfolioChi.md'
import
portfolioEnglish
from
'../content/portfolioEN.md'
import
{
ThemeContext
}
from
'./_app.js'
import
Header
from
'../components/Header'
import
Footer
from
'../components/Footer'
...
...
@@ -91,7 +93,6 @@ export default class PortfolioPage extends Component {
newTechEN
,
health
,
healthEN
,
portfolio
,
subTitle
,
subTitleEN
,
officialSite
,
...
...
@@ -102,6 +103,8 @@ export default class PortfolioPage extends Component {
dayEN
}
}
=
portfolioPage
const
{
attributes
:
portfolio
}
=
portfolioChi
const
{
attributes
:
portfolioEN
}
=
portfolioEnglish
const
{
showType
,
selected
,
mounted
}
=
this
.
state
return
(
<
ThemeContext
.
Consumer
>
...
...
@@ -177,12 +180,18 @@ export default class PortfolioPage extends Component {
<
/div
>
<
/div
>
<
div
className
=
"portfolio"
>
{
portfolio
{
en
===
null
||
!
en
&&
(
portfolio
.
filter
((
p
)
=>
{
if
(
showType
===
'all'
)
return
true
return
p
.
type
===
showType
})
.
map
((
p
,
idx
)
=>
this
.
renderPortfolio
(
p
,
idx
,
mounted
))}
.
map
((
p
,
idx
)
=>
this
.
renderPortfolio
(
p
,
idx
,
mounted
)))}
{
en
&&
(
portfolioEN
.
filter
((
p
)
=>
{
if
(
showType
===
'all'
)
return
true
return
p
.
type
===
showType
})
.
map
((
p
,
idx
)
=>
this
.
renderPortfolio
(
p
,
idx
,
mounted
)))}
<
/div
>
<
/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