-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
2 changed files
with
90 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,85 @@ | ||
import React, { useState } from 'react'; | ||
import { useMediaQuery } from 'react-responsive'; | ||
|
||
const About = () => { | ||
|
||
const isSmallScreen = useMediaQuery({ maxDeviceWidth: 575.98 }) | ||
|
||
const [data, setData] = useState([ | ||
{ | ||
title: "ระดับเริ่มต้น (Aging society)", | ||
text: "สังคมที่มีประชากรอายุ 60 ปีขึ้นไปมากกว่าร้อยละ 10 ของประชากรทั้งประเทศ", | ||
subtext: "หรือมีประชากรอายุตั้งแต่ 65 ปีมากกว่าร้อยละ 7 ของประชากรทั้งประเทศ" | ||
}, | ||
{ | ||
title: "ระดับสมบูรณ์ (Aged society)", | ||
text: "สังคมที่มีประชากรอายุ 60 ปีขึ้นไป มากกว่าร้อยละ 20 ของประชากรทั้งประเทศ", | ||
subtext: "หรือมีประชากรอายุตั้งแต่ 65 ปี มากกว่าร้อยละ 14 ของประชากรทั้งประเทศ" | ||
}, | ||
{ | ||
title: "ระดับสูง (Super-aged society)", | ||
text: "สังคมที่มีประชากรอายุ 65 ปีขึ้นไปมากกว่า ร้อยละ 20 ของประชากรทั้งประเทศ", | ||
subtext: "" | ||
}, | ||
]) | ||
|
||
return ( | ||
<div className="warp-about"> | ||
<div className="page-content"> | ||
{ | ||
isSmallScreen ? | ||
<div className="container-fluid"> | ||
<div className="head-content"> | ||
<h4>สังคมผู้สูงอายุ <br />และระดับของการเข้าสู่สังคมผู้สูงอายุ</h4> | ||
<h5> ถูกแบ่งออกเป็น 3 ระดับ</h5> | ||
</div> | ||
|
||
<div className="detail-content"> | ||
<img src="/static/trstcover2.gif" /> | ||
<div className="data-detail-content"> | ||
{ | ||
data.map((item, index) => ( | ||
<div className="title-content" key={index}> | ||
<h6 className="header-title-content">{item.title}</h6> | ||
<h6>{item.text}</h6> | ||
<h6>{item.subtext}</h6> | ||
</div> | ||
)) | ||
} | ||
</div> | ||
</div> | ||
</div> | ||
: | ||
<div className="container-fluid"> | ||
<div className="head-content"> | ||
<h3>สังคมผู้สูงอายุ และระดับของการเข้าสู่สังคมผู้สูงอายุ</h3> | ||
<h3> ถูกแบ่งออกเป็น 3 ระดับ</h3> | ||
</div> | ||
|
||
<div className="detail-content"> | ||
<img src="/static/trstcover2.gif" /> | ||
<div className="data-detail-content"> | ||
{ | ||
data.map((item, index) => ( | ||
<div className="title-content" key={index}> | ||
<h6 className="header-title-content">{item.title}</h6> | ||
<h6>{item.text}</h6> | ||
<h6>{item.subtext}</h6> | ||
</div> | ||
)) | ||
} | ||
<div className="more-content"> | ||
<h6>อ่านต่อ</h6> | ||
<img className="hvr-wobble-horizontal" src="/static/arrow.svg" alt="arrow-icon" /> | ||
</div> | ||
|
||
</div> | ||
</div> | ||
</div> | ||
} | ||
|
||
</div> | ||
</div> | ||
) | ||
} | ||
export default About; |
abb2dd1
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Successfully deployed to following URLs: