`); _push(ssrRenderComponent(_component_NuxtLink, { to: article.link }, null, _parent)); _push(`
${highlightText(article.excerpt, searchTerm.value) ?? ""}
import { defineComponent, ref, computed, watch, withCtx, createTextVNode, createVNode, useSSRContext } from 'vue'; import { ssrRenderComponent, ssrRenderStyle, ssrRenderAttr, ssrIncludeBooleanAttr, ssrInterpolate, ssrRenderList, ssrRenderClass } from 'vue/server-renderer'; import { _ as __nuxt_component_0 } from './nuxt-link-DNSfp6ul.mjs'; import { _ as _imports_0 } from './logo-1-CUpaHlTZ.mjs'; import { useRoute } from 'vue-router'; import { _ as _export_sfc } from './_plugin-vue_export-helper-1tPrXgE0.mjs'; import { u as useSeoMeta } from './composables-Coz3KJnj.mjs'; import '../nitro/nitro.mjs'; import 'node:http'; import 'node:https'; import 'node:events'; import 'node:buffer'; import 'node:fs'; import 'node:path'; import 'node:crypto'; import 'node:url'; import 'consola'; import './server.mjs'; import 'pinia'; import 'dayjs'; import 'dayjs/plugin/updateLocale.js'; import 'dayjs/plugin/relativeTime.js'; import 'dayjs/plugin/utc.js'; import '../routes/renderer.mjs'; import 'vue-bundle-renderer/runtime'; import 'unhead/server'; import 'devalue'; import 'unhead/plugins'; import 'unhead/utils'; const itemsPerPage = 4; const _sfc_main$1 = /* @__PURE__ */ defineComponent({ __name: "BlogPage", __ssrInlineRender: true, setup(__props) { const route = useRoute(); const backgroundStyle = { background: ` radial-gradient(circle at 20% 30%, rgba(35, 63, 146, 0.4) 0%, transparent 50%), radial-gradient(circle at 80% 70%, rgba(100, 116, 162, 0.3) 0%, transparent 50%), linear-gradient(135deg, #0d1530 0%, #1a1f3a 25%, #233f92 50%, #1a1a1c 75%, #0a0a0c 100%) ` }; const currentPage = ref(1); const activeCategory = ref(""); const searchTerm = ref(""); const allArticles = [ { id: 1, title: "هزینه طراحی سایت در ۱۴۰۵ — راهنمای کامل قیمتگذاری", category: "طراحی سایت", categoryId: "web-design", image: "/assets/img/weblog/cost-to-build-a-wordpress-website.webp", link: "/blog/hazine-tarahi-site-1405", excerpt: "راهنمای کامل هزینه و قیمت طراحی سایت در سال ۱۴۰۵. عوامل مؤثر بر قیمت، محدوده هزینه سایت با قالب آماده، شرکتی، فروشگاهی و پرتال. هزینه نگهداری و نحوه دریافت پیشفاکتور دقیق از اپ کو." }, { id: 2, title: "چطور برندینگ تخصصی میتواند کسبوکار شما را از رقبا متمایز کند؟", category: "طراحی سایت", categoryId: "web-design", image: "/assets/img/weblog/Brand-Strategy-1.webp", link: "/blog/chetor-branding-takhasosi-mitavanad-kasbokar-ra-motamayez-konad", excerpt: "برندینگ تخصصی یکی از مهمترین عوامل موفقیت در دنیای کسبوکار امروز است. در این مقاله به بررسی راهکارهای برندینگ تخصصی میپردازیم و نشان میدهیم که چگونه یک برند قوی میتواند کسبوکار شما را از رقبا متمایز کند و در ذهن مشتریان ماندگار شود." }, { id: 3, title: "مزایای طراحی سایت اختصاصی", category: "طراحی سایت", categoryId: "web-design", image: "/assets/img/weblog/Exclusive website design.webp", link: "/blog/mazaye-tarahi-site-ekhtesasi", excerpt: "طراحی سایت اختصاصی یکی از مهمترین تصمیمهای کسبوکارها در دنیای دیجیتال است. در این مقاله به بررسی مزایای طراحی سایت اختصاصی میپردازیم و تفاوت آن با سایتهای آماده را بررسی میکنیم. یک سایت اختصاصی میتواند به رشد کسبوکار شما کمک کند و تجربه کاربری بهتری ارائه دهد." }, { id: 4, title: "وردپرس یا طراحی اختصاصی؟ راهنمای انتخاب برای استارتاپها", category: "طراحی سایت", categoryId: "web-design", image: "/assets/img/weblog/coding&wordpress.webp", link: "/blog/wordpress-ya-tarahi-ekhtesasi-estartap", excerpt: "مقایسه وردپرس و طراحی سایت اختصاصی برای استارتاپها. هزینه، زمان، انعطاف و امنیت. چه زمانی وردپرس و چه زمانی سایت اختصاصی انتخاب کنیم؟ راهنمای عملی انتخاب." } ]; const categories = [ { id: "", label: "همه مقالات" }, { id: "web-design", label: "طراحی سایت" }, { id: "app-development", label: "توسعه اپلیکیشن" }, { id: "seo", label: "سئو و بازاریابی" }, { id: "graphic-design", label: "طراحی گرافیک" }, { id: "messaging-bots", label: "ربات پیامرسان و اینستاگرام" } ]; const filteredArticles = computed(() => { let filtered = allArticles; if (activeCategory.value) { filtered = filtered.filter((a) => a.categoryId === activeCategory.value); } if (searchTerm.value.trim()) { const term = searchTerm.value.trim().toLowerCase(); filtered = filtered.filter((a) => { return a.title.toLowerCase().includes(term) || a.excerpt.toLowerCase().includes(term) || a.category.toLowerCase().includes(term); }); } return filtered; }); const totalPages = computed(() => Math.ceil(filteredArticles.value.length / itemsPerPage)); const currentPageArticles = computed(() => { const start = (currentPage.value - 1) * itemsPerPage; const end = start + itemsPerPage; return filteredArticles.value.slice(start, end); }); const validCategoryIds = ["web-design", "app-development", "seo", "graphic-design", "messaging-bots"]; function applyCategoryFromRoute() { const q = route.query?.category; const cat = typeof q === "string" && validCategoryIds.includes(q) ? q : ""; activeCategory.value = cat; currentPage.value = 1; } watch(() => route.query?.category, applyCategoryFromRoute); const pageNumbers = computed(() => { const pages = []; for (let i = 1; i <= totalPages.value; i++) { pages.push(i); } return pages; }); const highlightText = (text, searchTerm2) => { if (!searchTerm2.trim()) return text; const term = searchTerm2.trim(); const regex = new RegExp(`(${term.replace(/[.*+?^${}()|[\]\\]/g, "\\$&")})`, "gi"); return text.replace(regex, '$1'); }; return (_ctx, _push, _parent, _attrs) => { const _component_NuxtLink = __nuxt_component_0; _push(`
هیچ مقالهای با عبارت "${ssrInterpolate(searchTerm.value)}" یافت نشد.
`); } else { _push(`در این دستهبندی هنوز مقالهای منتشر نشده است.
`); } _push(`${highlightText(article.excerpt, searchTerm.value) ?? ""}