From 5e2d5dfabb4f20d2c518599bf9489acd79a5303f Mon Sep 17 00:00:00 2001 From: aramesh-site deploy Date: Fri, 9 Oct 2026 14:27:30 +0000 Subject: [PATCH] =?UTF-8?q?feat(contact):=20=DB=8C=DA=A9=20=D8=AA=D8=B5?= =?UTF-8?q?=D9=88=DB=8C=D8=B1=20=D9=BE=DB=8C=D9=88=D8=B3=D8=AA=D9=87=20?= =?UTF-8?q?=D8=A8=D8=B1=D8=A7=DB=8C=20=DA=A9=D9=84=20=D8=B5=D9=81=D8=AD?= =?UTF-8?q?=D9=87=D9=94=20=D8=AA=D9=85=D8=A7=D8=B3=20=E2=80=94=20=D9=87?= =?UTF-8?q?=DB=8C=D8=B1=D9=88=20=D9=88=20=D9=81=D8=B1=D9=85=20=D8=B1=D9=88?= =?UTF-8?q?=DB=8C=20=D9=87=D9=85=D8=A7=D9=86=20=D9=BE=D8=B3=E2=80=8C=D8=B2?= =?UTF-8?q?=D9=85=DB=8C=D9=86=D9=87=D8=9B=20=D8=AD=D8=B0=D9=81=20=D8=AA?= =?UTF-8?q?=DA=A9=D8=B1=D8=A7=D8=B1=20=D8=B9=DA=A9=D8=B3=20(=D9=87=D9=88?= =?UTF-8?q?=D9=85=20=D8=AF=D8=B3=D8=AA=E2=80=8C=D9=86=D8=AE=D9=88=D8=B1?= =?UTF-8?q?=D8=AF=D9=87)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- frontend/src/components/ContactSection.tsx | 20 +++++++----- frontend/src/components/PageHero.tsx | 6 ++-- frontend/src/pages/ContactPage.tsx | 38 ++++++++++++++++++---- 3 files changed, 48 insertions(+), 16 deletions(-) diff --git a/frontend/src/components/ContactSection.tsx b/frontend/src/components/ContactSection.tsx index 0d71e09..3e45210 100644 --- a/frontend/src/components/ContactSection.tsx +++ b/frontend/src/components/ContactSection.tsx @@ -10,7 +10,7 @@ import { InlineEdit } from './admin/InlineEdit' import { SingletonPill } from '../admin/Editable' import { API_URL } from '../config' -export function ContactSection() { +export function ContactSection({ bare = false }: { bare?: boolean } = {}) { const { brand, contact_section: content } = useSite() const { t } = useLang() const save = useFieldSaver() @@ -100,13 +100,17 @@ export function ContactSection() { return (
- -
+ {!bare && ( + <> + +
+ + )}
diff --git a/frontend/src/components/PageHero.tsx b/frontend/src/components/PageHero.tsx index cfd822e..9be7bb4 100644 --- a/frontend/src/components/PageHero.tsx +++ b/frontend/src/components/PageHero.tsx @@ -12,9 +12,11 @@ import { ImageField } from './admin/ImageField' type PageHeroProps = { /** کلید هیرو صفحه در دیتابیس — عنوان/توضیح درجا ویرایش‌پذیر می‌شوند */ pageKey: string + /** تصویر پس‌زمینه را رندر نکن — صفحه تصویر پیوستهٔ خودش را دارد */ + hideImage?: boolean } -export function PageHero({ pageKey }: PageHeroProps) { +export function PageHero({ pageKey, hideImage = false }: PageHeroProps) { const hero = usePageHero(pageKey) const { t, href } = useLang() const save = useFieldSaver() @@ -27,7 +29,7 @@ export function PageHero({ pageKey }: PageHeroProps) { return (
- {hero.image && } + {hero.image && !hideImage && }