Files
Montech_Landing/apps/landing/pages/blog/index.vue
T
MahdiandCursor c33a757af4 Sync admin settings and media with the public landing site.
Show logo in the navbar, add image upload fields for logo/team/work/blog/gallery, and drive site chrome from settings everywhere.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-09-30 22:10:45 +03:30

39 lines
1.5 KiB
Vue
Raw Blame History

This file contains invisible Unicode characters
This file contains invisible Unicode characters that are indistinguishable to humans but may be processed differently by a computer. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
<template>
<div class="min-h-screen px-6 pb-24 pt-28 md:px-10">
<SiteNavbar
:brand="chrome.brand"
:logo-url="chrome.logoUrl"
:timezone="chrome.timezone"
/>
<div class="mx-auto max-w-[1100px]">
<h1 class="font-display text-4xl font-extrabold md:text-6xl">بلاگ</h1>
<p class="mt-4 max-w-xl text-ash">یادداشت‌هایی درباره محصول، مهندسی و ساخت نرم‌افزار.</p>
<ul class="mt-16 divide-y divide-white/[0.07] border-y border-white/[0.07]">
<li v-for="post in posts" :key="post.id" class="py-8">
<NuxtLink :to="`/blog/${post.slug}`" class="group block">
<p class="text-sm text-ash">
{{ post.publishedAt ? new Date(post.publishedAt).toLocaleDateString("fa-IR") : "" }}
</p>
<h2 class="mt-2 font-display text-2xl font-bold group-hover:text-volt md:text-3xl">
{{ post.title }}
</h2>
<p class="mt-3 max-w-2xl text-sm text-ash">{{ post.excerpt }}</p>
</NuxtLink>
</li>
</ul>
<p v-if="!posts?.length" class="mt-10 text-ash">هنوز پستی منتشر نشده است.</p>
</div>
</div>
</template>
<script setup lang="ts">
const chrome = await useSiteChrome();
const { data: posts } = await useAsyncData("blog-list", () => fetchPublicBlog(), {
getCachedData: () => undefined,
});
const { data: page } = await useAsyncData("page-blog", () => fetchPage("blog"), {
getCachedData: () => undefined,
});
applyPageSeo(page.value?.seo);
</script>