diff --git a/src/pages/GuestReviewPage.tsx b/src/pages/GuestReviewPage.tsx index abbc835..d4e3ef4 100644 --- a/src/pages/GuestReviewPage.tsx +++ b/src/pages/GuestReviewPage.tsx @@ -48,7 +48,7 @@ const DEFAULT_CONFIG: HotelConfig = { export function GuestReviewPage() { const { slug } = useParams<{ slug: string }>() - const hotel = (slug && MOCK_HOTELS[slug]) ?? DEFAULT_CONFIG + const hotel: HotelConfig = (slug ? MOCK_HOTELS[slug] : null) ?? DEFAULT_CONFIG const [rating, setRating] = useState(0) const [hover, setHover] = useState(0) diff --git a/src/pages/PosPage.tsx b/src/pages/PosPage.tsx index e2db39d..320cd55 100644 --- a/src/pages/PosPage.tsx +++ b/src/pages/PosPage.tsx @@ -56,7 +56,7 @@ const PURPOSE_LABELS: Record = { extra: 'Доп. услуга', } -const QUICK_CHARGES: { purpose: ChargePurpose; label: string; amount: number | null; Icon: React.ComponentType<{ size?: number }> }[] = [ +const QUICK_CHARGES: { purpose: ChargePurpose; label: string; amount: number | null; Icon: React.ElementType }[] = [ { purpose: 'stay', label: 'Проживание', amount: null, Icon: Building2 }, { purpose: 'breakfast', label: 'Завтрак', amount: 650, Icon: Coffee }, { purpose: 'transfer', label: 'Трансфер', amount: 2500, Icon: Car }, @@ -193,7 +193,7 @@ export function PosPage() { const balance = selectedRoom ? Math.max(0, selectedRoom.totalAmount - selectedRoom.paidAmount) : 0 const isPaid = selectedRoom ? selectedRoom.paidAmount >= selectedRoom.totalAmount : false - const TABS: { key: PosTab; label: string; Icon: React.ComponentType<{ size?: number }> }[] = [ + const TABS: { key: PosTab; label: string; Icon: React.ElementType }[] = [ { key: 'main', label: 'Касса', Icon: Receipt }, { key: 'report', label: 'X/Z-отчёт', Icon: BarChart2 }, { key: 'atol', label: 'АТОЛ', Icon: Settings2 }, diff --git a/src/pages/ReviewsPage.tsx b/src/pages/ReviewsPage.tsx index 671ce16..cc8f3bf 100644 --- a/src/pages/ReviewsPage.tsx +++ b/src/pages/ReviewsPage.tsx @@ -220,7 +220,7 @@ export function ReviewsPage() { return null } - const TABS: { key: Tab; label: string; count?: number; colorCls?: string; Icon?: React.ComponentType<{ size?: number }> }[] = [ + const TABS: { key: Tab; label: string; count?: number; colorCls?: string; Icon?: React.ElementType }[] = [ { key: 'pending', label: 'Требуют ответа', count: pending.length, colorCls: 'bg-red-500 text-white' }, { key: 'published', label: 'Архив', count: published.length }, { key: 'all', label: 'Все' },