Skip to content

Commit

Permalink
mypage ui edit
Browse files Browse the repository at this point in the history
  • Loading branch information
Shimsuyeon committed Nov 8, 2023
1 parent 71a7fa4 commit e6ee0e6
Show file tree
Hide file tree
Showing 4 changed files with 231 additions and 117 deletions.
28 changes: 16 additions & 12 deletions src/app/[lng]/mypage/MypageTable.tsx
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import LazyCat from '@/assets/lazy-cat.svg';
import LazyCat from "@/assets/lazy-cat.svg";

interface Tag {
id: number;
Expand Down Expand Up @@ -27,30 +27,34 @@ interface MypageTableProps {
}

const MypageTable = ({ title, articles, link }: MypageTableProps) => {

return (
<div className="rounded-lg shadow-md bg-white w-96">
<div className="rounded-lg shadow-md bg-white w-[700px]">
<div className="w-full border border-white border-separate border-collapse border-spacing-0 rounded-lg">
<div className="m-0 flex flex-row w-full border border-separate border-collapse border-spacing-0 rounded-tl-lg rounded-tr-lg bg-primary">
<div className="m-0 flex flex-row w-full border border-separate border-collapse border-spacing-0 rounded-tl-lg rounded-tr-lg bg-primary">
<div className="w-4/5 rounded-tl-10">
<div className="text-lg text-xl m-5 text-white font-bold">
<div className="text-xl m-5 text-white font-bold">
{title}
</div>
</div>
<div className="rounded-tr-10">
<div className="flex items-center justify-center text-s text-regular text-white h-full">
전체보기
<div className="flex items-center justify-center text-s text-regular text-white h-full">
전체보기
</div>
</div>
</div>
</div>
</div>

{articles.length > 0 &&
articles.map((articleObj, index) => {
const isLastRow = index === articles.length - 1;
const borderBottomRadius = isLastRow ? "10px" : "0px";
return (
<div key={index} className={`flex items-center flex-row justify-between bg-colorless rounded-bl-${borderBottomRadius} rounded-br-${borderBottomRadius} border border-gray-200`}>
<div className={`p-10 sm:p-20 pb-0 sm:pb-0 rounded-bl-${borderBottomRadius} leading-1.5 w-70`}>
<div
key={index}
className={`flex items-center flex-row justify-between bg-colorless rounded-bl-${borderBottomRadius} rounded-br-${borderBottomRadius} border border-gray-200`}
>
<div
className={`p-10 sm:p-20 pb-0 sm:pb-0 rounded-bl-${borderBottomRadius} leading-1.5 w-70`}
>
<div className="text-regular m-5 text-white">
{articleObj.title}
</div>
Expand All @@ -65,7 +69,7 @@ const MypageTable = ({ title, articles, link }: MypageTableProps) => {
})}
{articles.length === 0 && (
<div className="flex flex-col h-full justify-center items-center p-30 bg-colorless rounded-bl-0 rounded-br-10">
<LazyCat className="w-35 h-35" />
<LazyCat className="p-5 w-50 h-50" />
<div className="text-regular m-5 text-secondayText">
아직 μ €μž₯된 글이 μ—†μŠ΅λ‹ˆλ‹€. =γ……=
</div>
Expand Down
12 changes: 6 additions & 6 deletions src/app/[lng]/mypage/page.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -6,28 +6,28 @@ import { useTranslation } from '@/app/i18next';
const MyPage = async () => {
const isSmall = false;
const isMobile = false;
const Height = "1000px";

return (
<>

<div className={`mt-10 w-full flex h-${Height} justify-center items-center ${isSmall ? 'flex-col' : 'flex-row'} gap-20`}>
<div className={`mt-10 w-full flex h-1500 xl:h-1000 justify-center items-center flex-col xl:flex-row gap-20`}>
<div className="flex flex-col relative m-10">
<MypageProfile
name={"κΉ€μ§€ν˜„"} id={"201910808"}
email={"ss@gm.gist.ac.kr"}
phone={"010-0000-0000"}/>

{!isSmall && <MypageSeperate />}
<div className="xl:flex hidden">
<MypageSeperate />
</div>
</div>
<div className={`flex justify-center items-center flex-col`}>
<div className={`w-96 mb-10 p-${isMobile ? '0' : '0'} `}>
<div className={`mb-10 p-0 xl:p-50`}>
<MypageTable
title={"λ‚΄κ°€ κ²Œμ‹œν•œ 곡지 λͺ©λ‘"}
articles={[]}
link={""} />
</div>
<div className={`p-${isMobile ? '0' : '50'} `}>
<div className={`p-0 xl:p-50 `}>
<MypageTable
title={"λ¦¬λ§ˆμΈλ“œ μ„€μ •ν•œ κ²Œμ‹œλ¬Ό λͺ©λ‘"}
articles={[]}
Expand Down
203 changes: 104 additions & 99 deletions src/app/i18next/locales/en/translation.json
Original file line number Diff line number Diff line change
@@ -1,105 +1,110 @@
{
"metadata": {
"title": "지글",
"description": "μ§€μŠ€νŠΈμ˜ λͺ¨λ“  곡지λ₯Ό ν•œλˆˆμ—"
},
"navbar": {
"all": "전체 곡지",
"query": "곡지 검색",
"login": "둜그인"
},
"footer": {
"infoteam": "μ§€μŠ€νŠΈλŒ€ν•™ μ΄ν•™μƒνšŒ μ‚°ν•˜ 정보ꡭ",
"copyright": "β“’ 2023. INFOTEAM all rights reserved.",
"sections": [
{
"title": "μ†Œκ°œ",
"links": [
{ "name": "μΈν¬νŒ€ μ†Œκ°œ", "link": "https://introduce.gistory.me" }
]
},
{
"title": "μ•½κ΄€",
"links": [
{
"name": "μ„œλΉ„μŠ€μ΄μš©μ•½κ΄€",
"link": "https://infoteam-rulrudino.notion.site/6177be6369e44280a23a65866c51b257"
},
{
"name": "κ°œμΈμ •λ³΄μ²˜λ¦¬λ°©μΉ¨",
"link": "https://infoteam-rulrudino.notion.site/ceb9340c0b514497b6d916c4a67590a1"
},
{ "name": "문의", "link": "mailto:ziggle@gistory.me" }
]
},
{
"title": "λ°”λ‘œκ°€κΈ°",
"links": [
{
"name": "μ§€μŠ€νŠΈ ν•˜μš°μŠ€",
"link": "https://sites.google.com/view/gisthouse/home"
},
{
"name": "GIST ν™ˆνŽ˜μ΄μ§€",
"link": "https://www.gist.ac.kr/kr/main.html"
},
{ "name": "지쑸", "link": "https://gijol.im" }
]
}
]
},
"zabo": {
"dateView": "{{date}}\u00a0<strong>· 쑰회수 {{views}}</strong>",
"clickPoster": "ν¬μŠ€ν„° ν΄λ¦­ν•˜μ—¬ μžμ„Ένžˆ 보기",
"downloadAll": "전체 λ‹€μš΄λ‘œλ“œν•˜κΈ°",
"close": "λ‹«κΈ°",
"author": "글쓴이 <strong>{{author}}</strong>",
"createdAt": "μž‘μ„±μΌ {{createdAt}}",
"views": "쑰회수 {{views}}",
"copyLink": {
"action": "μ£Όμ†Œ λ³΅μ‚¬ν•˜κΈ°",
"content": "{{title}}\n\nZiggleμ—μ„œ 곡지λ₯Ό ν™•μΈν•΄μ£Όμ„Έμš”\n{{- link}}",
"success": "곡지 μ£Όμ†Œκ°€ λ³΅μ‚¬λ˜μ—ˆμŠ΅λ‹ˆλ‹€!<small>μΉœκ΅¬λ“€μ—κ²Œ 곡지λ₯Ό κ³΅μœ ν•΄λ³΄μ„Έμš”</small>"
},
"share": {
"action": "κ³΅μœ ν•˜κΈ°",
"content": "{{title}}\nZiggleμ—μ„œ 곡지λ₯Ό ν™•μΈν•΄λ³΄μ„Έμš”",
"unsupported": "κ³΅μœ ν•˜κΈ°λ₯Ό μ§€μ›ν•˜μ§€ μ•ŠλŠ” λΈŒλΌμš°μ €μž…λ‹ˆλ‹€"
"metadata": {
"title": "Ziggle",
"description": "All Notices in GIST at a glance"
},
"backToMain": "메인 νŽ˜μ΄μ§€λ‘œ λŒμ•„κ°€κΈ°",
"images": "첨뢀 사진",
"howAboutThese": "🫧 이런 κ³΅μ§€λŠ” μ–΄λ– μ‹ κ°€μš”?"
},
"emptyNotices": "글이 μ—†μŠ΅λ‹ˆλ‹€. =γ……=",
"loading": "λ‘œλ”© μ€‘μž…λ‹ˆλ‹€! -γ……-",
"ddayPlus": "κΈ°ν•œ 지남",
"notices": {
"all": {
"label": "전체 곡지",
"description": "λͺ¨λ“  곡지듀이 μ‹œκ°„ 순으둜 μ •λ ¬λ˜μ–΄ μžˆμŠ΅λ‹ˆλ‹€."
"navbar": {
"all": "All Notices",
"query": "Search Notice",
"login": "Login"
},
"deadline": {
"label": "🌟 λ§ˆκ°μž„λ°•",
"description": "마감 μ‹œκ°„μ΄ 일주일도 μ•ˆ 남은 곡지λ₯Ό λͺ¨μ•„μ„œ 보여 λ“œλ €μš”"
"footer": {
"infoteam": "GIST Student Council - Information Department",
"copyright": "β“’ 2023. INFOTEAM all rights reserved.",
"sections": [
{
"title": "Introduction",
"links": [
{
"name": "Introduce Infoteam",
"link": "https://introduce.gistory.me"
}
]
},
{
"title": "Terms",
"links": [
{
"name": "Terms of Service",
"link": "https://infoteam-rulrudino.notion.site/6177be6369e44280a23a65866c51b257"
},
{
"name": "Privacy Policy",
"link": "https://infoteam-rulrudino.notion.site/ceb9340c0b514497b6d916c4a67590a1"
},
{ "name": "FAQ", "link": "mailto:ziggle@gistory.me" }
]
},
{
"title": "Shortcuts",
"links": [
{
"name": "GIST House",
"link": "https://sites.google.com/view/gisthouse/home"
},
{
"name": "GIST Homepage",
"link": "https://www.gist.ac.kr/kr/main.html"
},
{ "name": "Gijol", "link": "https://gijol.im" }
]
}
]
},
"hot": {
"label": "πŸ”₯ 였늘 λ“λŠ” 곡지",
"description": "μ§€λ‚œ 일주일 λ™μ•ˆ μ‘°νšŒμˆ˜κ°€ 150이 λ„˜μ€ 곡지듀이 μ—¬κΈ°μ„œ 지글지글 끓고 μžˆμ–΄μš”"
},
"event": {
"label": "🎈 행사",
"description": "μ§€μŠ€νŠΈλŠ” μ˜€λŠ˜λ„ λœ¨κ²μŠ΅λ‹ˆλ‹€"
},
"recruit": {
"label": "🎯 λͺ¨μ§‘",
"description": "μ–Έμ œλ‚˜ μ—¬λŸ¬λΆ„κ»˜ μ—΄λ¦° 기회"
},
"general": {
"label": "πŸ”” 일반",
"description": "μ§€μŠ€νŠΈμΈλ“€μ΄ ν•΄μ•Ό ν•˜λŠ” 일듀"
"zabo": {
"dateView": "{{date}}\u00a0<strong>Β· {{views}} views</strong>",
"clickPoster": "Click on the poster to read more",
"downloadAll": "Download All",
"close": "Close",
"author": "Author <strong>{{author}}</strong>",
"createdAt": "Created on {{createdAt}}",
"views": "{{views}} views",
"copyLink": {
"action": "copy link",
"content": "{{title}}\n\nCheck the notice in Ziggle!\n{{- link}}",
"success": "The notice link has been copied!<small>Share the notice with your friends.</small>"
},
"dueAt": "Due at {{dueAt}}",
"noContent": "No Content",
"share": {
"action": "Share",
"content": "{{title}}\nCheck the notice in Ziggle!",
"unsupported": "Your browser doesn't support sharing."
},
"backToMain": "Go back to main page",
"images": "Photos",
"howAboutThese": "🫧 How about these notices?"
},
"academic": {
"label": "πŸ“° 학사곡지"
"emptyNotices": "No content. =γ……=",
"loading": "Loading! -γ……-",
"ddayPlus": "OVERDUE",
"notices": {
"all": {
"label": "All Notices",
"description": "All notices are sorted in chronological order."
},
"deadline": {
"label": "🌟 Near Deadline",
"description": "Here's a roundup of notices that are due in less than a week."
},
"hot": {
"label": "πŸ”₯ Today's boiling notices",
"description": "Notices with over 150 views in the past week have been sizzling here."
},
"event": {
"label": "🎈 Events",
"description": "GIST is hot today."
},
"recruit": {
"label": "🎯 Recruiting",
"description": "Opportunities are always open to you"
},
"general": {
"label": "πŸ”” General",
"description": "GISTian Must-Dos"
},
"academic": {
"label": "πŸ“° Academic Notices"
}
}
}
}
}
Loading

0 comments on commit e6ee0e6

Please sign in to comment.