diff --git a/app/src/pages/StoriesListPage.jsx b/app/src/pages/StoriesListPage.jsx new file mode 100644 index 0000000..6c7f421 --- /dev/null +++ b/app/src/pages/StoriesListPage.jsx @@ -0,0 +1,53 @@ +import { TeknavData } from '../../teknav-data.js'; +import { useNav } from '../../teknav-ui.jsx'; + +export function StoriesListPage() { + const { navigate } = useNav(); + const today = new Date().toISOString().slice(0, 10); + const stories = (TeknavData.articles ?? []).filter((a) => { + if (a.status !== 'منتشرشده' && a.status) return false; + const d = String(a.dateEn || '').slice(0, 10); + return /^\d{4}-\d{2}-\d{2}$/.test(d) && d <= today; + }); + + return ( +
+ +

استوری‌های تکناو

+

+ مقالات تکناو در قالب استوری‌های بصری — سریع، قابل اسوایپ و بهینه برای موبایل. +

+
+ {stories.map((a) => { + const img = a.ogImage || `/images/og/${a.slug}.jpg`; + return ( +
{ window.open(`/stories/${a.slug}`, '_blank'); }} + style={{ borderRadius: 14, overflow: 'hidden', cursor: 'pointer', position: 'relative', paddingBottom: '177%', background: '#0C1E22' }} + onMouseEnter={(e) => { e.currentTarget.style.transform = 'scale(1.03)'; e.currentTarget.style.boxShadow = '0 8px 24px rgba(0,0,0,0.25)'; }} + onMouseLeave={(e) => { e.currentTarget.style.transform = ''; e.currentTarget.style.boxShadow = ''; }} + > + {a.title} +
+
{a.categoryName}
+
{a.title.slice(0, 55)}{a.title.length > 55 ? '…' : ''}
+
+
+ ▶ استوری +
+
+ ); + })} +
+
+ ); +}