Skip to content

Commit

Permalink
apply dark mode in privacy
Browse files Browse the repository at this point in the history
  • Loading branch information
jongwony committed Feb 1, 2025
1 parent 8bd5548 commit 5f1c16a
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 20 deletions.
16 changes: 2 additions & 14 deletions src/app/form/success/Info.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -76,25 +76,13 @@ const GetInfo: React.FC = () => {
<p className="text-lg font-bold text-center text-red-400 mb-4">이미지가 첨부되지 않았어요!</p>
)}

<div>
<p className="text-sm font-medium">이메일</p>
<p className="text-sm text-gray-500">{profileData.email}</p>
</div>

<div>
<p className="text-sm font-medium">QR Code</p>
<a href={profileData.code} target="_blank" rel="noopener noreferrer" className="text-sm text-gray-500 hover:underline">
<span className="truncate">{profileData.code}</span>
</a>
</div>

{/* code, email, thumbnail 키를 제외한 나머지 키-값을 순회 */}
{Object.entries(profileData)
.filter(([key]) => !['code', 'email', 'thumbnail', 'issue_code', 'type', 'timestamp'].includes(key))
.filter(([key]) => !['thumbnail', 'issue_code', 'type', 'timestamp'].includes(key))
.map(([key, value]) => (
<div key={key}>
<p className="text-sm font-medium">{key}</p>
<code className="text-sm text-gray-500">{String(value) || "<비어 있음>"}</code>
<code className="text-sm text-gray-500 hover:underline">{String(value) || "<비어 있음>"}</code>
</div>
))}
</div>
Expand Down
12 changes: 6 additions & 6 deletions src/app/privacy/page.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -40,9 +40,9 @@ export default function PrivacyPolicy() {

return (
<div className="max-w-2xl mx-auto p-6">
<h1 className="text-2xl font-bold mb-6 text-center">개인정보 처리방침</h1>
<h1 className="text-2xl font-bold m-12 text-center">개인정보 처리방침</h1>
{privacyPolicy.map((item, index) => (
<div key={index} className="mb-4 border border-gray-200 rounded-lg shadow-sm">
<div key={index} className="mb-8 border border-zinc-200 dark:border-zinc-800 rounded-lg shadow-sm">
<button
className="flex justify-between items-center w-full p-4 rounded-t-lg focus:outline-none"
onClick={() => toggleAccordion(index)}
Expand All @@ -51,15 +51,15 @@ export default function PrivacyPolicy() {
{openIndex === index ? <ChevronUp /> : <ChevronDown />}
</button>
{openIndex === index && (
<div className="p-4 border-t">
<p className="text-gray-400 whitespace-pre-line">{item.content}</p>
<div className="p-4 border-t border-zinc-200 dark:border-zinc-800">
<p className="text-zinc-600 dark:text-zinc-400 whitespace-pre-line">{item.content}</p>
</div>
)}
</div>
))}
<div className="mt-6 flex justify-center">
<div className="m-12 flex justify-center">
<button onClick={() => router.back()} className="bg-blue-600 text-white px-6 py-2 rounded-lg hover:bg-blue-700 transition">
홈으로 돌아가기
돌아가기
</button>
</div>
</div>
Expand Down

0 comments on commit 5f1c16a

Please sign in to comment.