diff --git a/client/src/pages/EntryPage.tsx b/client/src/pages/EntryPage.tsx index d572579..97e1c21 100644 --- a/client/src/pages/EntryPage.tsx +++ b/client/src/pages/EntryPage.tsx @@ -3,7 +3,7 @@ import { useNavigate, useParams } from 'react-router-dom'; import { fetchEntry } from '../api'; import VideoPlayer from '../components/VideoPlayer'; import { ConversationPanel, GrammarPanel, KeyPhrasePanel, VocabPanel } from '../components/ItemPanels'; -import ExpandableText from '../components/ExpandableText'; +import IgMetaBlock from '../components/IgMetaBlock'; import type { EntryDetail } from '../types'; export default function EntryPage() { @@ -39,12 +39,6 @@ export default function EntryPage() { const quizLink = `/quiz?mode=entry&id=${encodeURIComponent(entry.id)}`; const ig = entry.ig_meta; - const profileUrl = ig?.profile_url || (ig?.username ? `https://www.instagram.com/${ig.username}/` : undefined); - let postDate: string | undefined; - if (ig?.post_date) { - const parsed = new Date(ig.post_date); - postDate = isNaN(parsed.getTime()) ? ig.post_date : parsed.toLocaleString(); - } return (
@@ -60,43 +54,7 @@ export default function EntryPage() {
- {ig && ( -
- {ig.profile_pic_url ? ( - - {ig.username { - if (ig.profile_pic_url && !e.currentTarget.dataset.fallback) { - e.currentTarget.dataset.fallback = '1'; - e.currentTarget.src = ig.profile_pic_url; - } - }} - /> - - ) : ( -
- )} -
-
- {ig.username ? ( - - {ig.username} - - ) : ( - Instagram - )} - {ig.full_name && ยท {ig.full_name}} -
-
{postDate || ig.post_date || 'Date unknown'}
- {ig.description && ( - - )} -
-
- )} + {ig && }