From 83d1faaa389a28ece1f7e9d7888afe66f6ac9171 Mon Sep 17 00:00:00 2001 From: "dev.daminik00" Date: Tue, 28 Oct 2025 06:02:25 +0100 Subject: [PATCH] lint:fix --- .../AddConsultantButton.tsx | 2 +- .../AddConsultantPage/AddConsultantPage.tsx | 6 +++--- .../AddGuidesButton/AddGuidesButton.tsx | 2 +- .../AddGuidesPage/AddGuidesPage.tsx | 6 +++--- .../Progress/Progress.tsx | 16 +++++++-------- .../VideoGuidesButton/VideoGuidesButton.tsx | 2 +- .../VideoGuidesPage/VideoGuidesPage.tsx | 8 ++++---- .../cards/VideoGuideCard/VideoGuideCard.tsx | 2 +- .../VideoGuidesSection/VideoGuidesSection.tsx | 8 ++++---- .../VideoGuideView/VideoGuideView.tsx | 4 ++-- src/entities/dashboard/loaders.ts | 2 +- .../video-guides/useVideoGuidePurchase.ts | 20 +++++++++---------- 12 files changed, 39 insertions(+), 39 deletions(-) diff --git a/src/components/domains/additional-purchases/AddConsultantButton/AddConsultantButton.tsx b/src/components/domains/additional-purchases/AddConsultantButton/AddConsultantButton.tsx index 88b1459..9f799db 100644 --- a/src/components/domains/additional-purchases/AddConsultantButton/AddConsultantButton.tsx +++ b/src/components/domains/additional-purchases/AddConsultantButton/AddConsultantButton.tsx @@ -26,7 +26,7 @@ export default function AddConsultantButton() { onSuccess: async () => { // Устанавливаем флаг навигации чтобы заблокировать повторные нажатия setIsNavigating(true); - + // Переходим на следующую страницу или на главную if (navigation.hasNext) { await navigation.goToNext(); diff --git a/src/components/domains/additional-purchases/AddConsultantPage/AddConsultantPage.tsx b/src/components/domains/additional-purchases/AddConsultantPage/AddConsultantPage.tsx index 80b5f61..bb4b65c 100644 --- a/src/components/domains/additional-purchases/AddConsultantPage/AddConsultantPage.tsx +++ b/src/components/domains/additional-purchases/AddConsultantPage/AddConsultantPage.tsx @@ -23,9 +23,9 @@ export default function AddConsultantPage() { return ( <> - {t("title")} diff --git a/src/components/domains/additional-purchases/AddGuidesButton/AddGuidesButton.tsx b/src/components/domains/additional-purchases/AddGuidesButton/AddGuidesButton.tsx index 65b3319..ac0693f 100644 --- a/src/components/domains/additional-purchases/AddGuidesButton/AddGuidesButton.tsx +++ b/src/components/domains/additional-purchases/AddGuidesButton/AddGuidesButton.tsx @@ -25,7 +25,7 @@ export default function AddGuidesButton() { onSuccess: async () => { // Устанавливаем флаг навигации чтобы заблокировать повторные нажатия setIsNavigating(true); - + // Переходим на следующую страницу или на главную if (navigation.hasNext) { await navigation.goToNext(); diff --git a/src/components/domains/additional-purchases/AddGuidesPage/AddGuidesPage.tsx b/src/components/domains/additional-purchases/AddGuidesPage/AddGuidesPage.tsx index ee4e5df..cec2d27 100644 --- a/src/components/domains/additional-purchases/AddGuidesPage/AddGuidesPage.tsx +++ b/src/components/domains/additional-purchases/AddGuidesPage/AddGuidesPage.tsx @@ -26,9 +26,9 @@ export default function AddGuidesPage() { return ( - {t("title")} diff --git a/src/components/domains/additional-purchases/Progress/Progress.tsx b/src/components/domains/additional-purchases/Progress/Progress.tsx index 4019ce0..2ac81e1 100644 --- a/src/components/domains/additional-purchases/Progress/Progress.tsx +++ b/src/components/domains/additional-purchases/Progress/Progress.tsx @@ -30,11 +30,11 @@ export default function Progress({ items, activeItemIndex }: IProgressProps) { // Фиксированные отступы от краев (центр кружочка = 50px от края) const edgeOffset = 50; // 50px от края до центра кружочка const totalItems = allItems.length; - + // Рассчитываем позицию каждого элемента с равными отступами const calculateItemPosition = (index: number) => { if (totalItems === 1) return 50; // Центрируем если один элемент - + // Распределяем элементы равномерно между краями const availableWidth = containerWidth - (edgeOffset * 2); const spacing = availableWidth / (totalItems - 1); @@ -47,14 +47,14 @@ export default function Progress({ items, activeItemIndex }: IProgressProps) { // Находим все элементы прогресс бара const items = elementRef.current.querySelectorAll(`.${styles.item}`); let maxHeight = 0; - + items.forEach((item) => { const height = (item as HTMLElement).offsetHeight; if (height > maxHeight) { maxHeight = height; } }); - + setContainerHeight(maxHeight); } }, [allItems, containerWidth]); @@ -79,12 +79,12 @@ export default function Progress({ items, activeItemIndex }: IProgressProps) { }, []); return ( -
-
0 ? `${containerHeight}px` : undefined, diff --git a/src/components/domains/additional-purchases/VideoGuidesButton/VideoGuidesButton.tsx b/src/components/domains/additional-purchases/VideoGuidesButton/VideoGuidesButton.tsx index fd5139a..d6b9a5a 100644 --- a/src/components/domains/additional-purchases/VideoGuidesButton/VideoGuidesButton.tsx +++ b/src/components/domains/additional-purchases/VideoGuidesButton/VideoGuidesButton.tsx @@ -25,7 +25,7 @@ export default function VideoGuidesButton() { onSuccess: async () => { // Устанавливаем флаг навигации чтобы заблокировать повторные нажатия setIsNavigating(true); - + // Переходим на следующую страницу или на главную if (navigation.hasNext) { await navigation.goToNext(); diff --git a/src/components/domains/additional-purchases/VideoGuidesPage/VideoGuidesPage.tsx b/src/components/domains/additional-purchases/VideoGuidesPage/VideoGuidesPage.tsx index 338358f..14201e2 100644 --- a/src/components/domains/additional-purchases/VideoGuidesPage/VideoGuidesPage.tsx +++ b/src/components/domains/additional-purchases/VideoGuidesPage/VideoGuidesPage.tsx @@ -7,10 +7,10 @@ import { AdditionalPurchaseBanner, ProductSelectionProvider, Progress, + useMultiPageNavigationContext, VideoGuidesButton, VideoGuidesOffers, VideoGuidesOffersSkeleton, - useMultiPageNavigationContext, } from "@/components/domains/additional-purchases"; import { Typography } from "@/components/ui"; @@ -27,9 +27,9 @@ export default function VideoGuidesPage() { return ( - diff --git a/src/components/domains/dashboard/cards/VideoGuideCard/VideoGuideCard.tsx b/src/components/domains/dashboard/cards/VideoGuideCard/VideoGuideCard.tsx index b0b5d00..1fe2fdb 100644 --- a/src/components/domains/dashboard/cards/VideoGuideCard/VideoGuideCard.tsx +++ b/src/components/domains/dashboard/cards/VideoGuideCard/VideoGuideCard.tsx @@ -101,7 +101,7 @@ export default function VideoGuideCard(props: VideoGuideCardProps) {
-