From 28f41cf346b2d3a0a287e5ade9115fe38c87b22f Mon Sep 17 00:00:00 2001 From: Web-serfer Date: Tue, 14 Apr 2026 23:50:27 +0500 Subject: [PATCH] =?UTF-8?q?=D0=9D=D0=BE=D0=B2=D1=8B=D0=B5=20=D0=B8=D0=B7?= =?UTF-8?q?=D0=BC=D0=B5=D0=BD=D0=B5=D0=BD=D0=B8=D1=8F=20=D0=B2=20=D1=84?= =?UTF-8?q?=D0=B0=D0=B9=D0=BB=D0=B0=D1=85?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- frontend/src/components/base/AuthLockBlock.astro | 2 +- .../src/components/blog/PostReactionButtons.astro | 4 ++-- frontend/src/pages/blog/index.astro | 15 ++++++++------- frontend/src/pages/faq.astro | 8 ++++---- 4 files changed, 15 insertions(+), 14 deletions(-) diff --git a/frontend/src/components/base/AuthLockBlock.astro b/frontend/src/components/base/AuthLockBlock.astro index 4562933..b9198cd 100644 --- a/frontend/src/components/base/AuthLockBlock.astro +++ b/frontend/src/components/base/AuthLockBlock.astro @@ -24,7 +24,7 @@ const {

{title}

-

{description}

+

{description}

{buttonText} diff --git a/frontend/src/components/blog/PostReactionButtons.astro b/frontend/src/components/blog/PostReactionButtons.astro index 062122a..47d22a0 100644 --- a/frontend/src/components/blog/PostReactionButtons.astro +++ b/frontend/src/components/blog/PostReactionButtons.astro @@ -108,7 +108,7 @@ const { initialLikes = 0, initialDislikes = 0, postId } = Astro.props; } else { if (userAction === 'dislike') { dislikes--; - dislikeBtn.classList.remove('active'); + dislikeBtn?.classList.remove('active'); } likes++; userAction = 'like'; @@ -126,7 +126,7 @@ const { initialLikes = 0, initialDislikes = 0, postId } = Astro.props; } else { if (userAction === 'like') { likes--; - likeBtn.classList.remove('active'); + likeBtn?.classList.remove('active'); } dislikes++; userAction = 'dislike'; diff --git a/frontend/src/pages/blog/index.astro b/frontend/src/pages/blog/index.astro index 9b3c681..aabeb46 100644 --- a/frontend/src/pages/blog/index.astro +++ b/frontend/src/pages/blog/index.astro @@ -182,17 +182,18 @@ const categories = ['Все', ...new Set(posts.map((post: any) => post.data.cate // Фильтруем карточки cards.forEach((card) => { const cardCategory = card.getAttribute('data-category'); + const el = card as HTMLElement; if (category === 'Все' || cardCategory === category) { - card.style.display = ''; - card.style.opacity = '0'; - card.style.transform = 'translateY(20px)'; + el.style.display = ''; + el.style.opacity = '0'; + el.style.transform = 'translateY(20px)'; requestAnimationFrame(() => { - card.style.transition = 'opacity 0.4s ease, transform 0.4s ease'; - card.style.opacity = '1'; - card.style.transform = 'translateY(0)'; + el.style.transition = 'opacity 0.4s ease, transform 0.4s ease'; + el.style.opacity = '1'; + el.style.transform = 'translateY(0)'; }); } else { - card.style.display = 'none'; + el.style.display = 'none'; } }); }); diff --git a/frontend/src/pages/faq.astro b/frontend/src/pages/faq.astro index 83bfda0..9464644 100644 --- a/frontend/src/pages/faq.astro +++ b/frontend/src/pages/faq.astro @@ -2,8 +2,8 @@ import Layout from '@layouts/Layout.astro'; import { SITE_URL } from '@constants'; import PageHero from '@components/base/PageHero.astro'; -import Faq from '@components/faq/FaqItem.astro'; -import Pagination from '@components/base/Pagination.astro'; +import FaqSection from '@components/faq/FaqItem.astro'; +import PaginationComp from '@components/base/Pagination.astro'; const ITEMS_PER_PAGE = 10; @@ -120,14 +120,14 @@ const currentFaqItems = allFaqItems.slice(startIndex, endIndex); />
- {totalPages > 1 && (
-