From e5c2082bf23c2b04cff99fdd5977a30970937c92 Mon Sep 17 00:00:00 2001 From: Zhang Ziqing <69516975+ziqing26@users.noreply.github.com> Date: Mon, 24 Oct 2022 22:00:48 +0800 Subject: [PATCH] [offers][feat] add landing page and fix comment bugs (#422) * [offers][fix] fix create commnet and update title * [offers][fix] update tab name * [offers][feat] add landing page --- .../src/components/offers/OffersNavigation.ts | 5 +- .../src/components/offers/OffersTitle.tsx | 4 +- .../offers/landing/LeftTextCard.tsx | 54 ++++ .../offers/landing/RightTextCard.tsx | 54 ++++ .../offers/profile/ProfileComments.tsx | 39 ++- .../offers/profile/comments/CommentCard.tsx | 6 +- apps/portal/src/pages/offers/home.tsx | 48 ++++ apps/portal/src/pages/offers/index.tsx | 272 +++++++++++++++--- .../pages/offers/profile/[offerProfileId].tsx | 4 +- apps/portal/src/utils/offers/time.tsx | 6 +- 10 files changed, 443 insertions(+), 49 deletions(-) create mode 100644 apps/portal/src/components/offers/landing/LeftTextCard.tsx create mode 100644 apps/portal/src/components/offers/landing/RightTextCard.tsx create mode 100644 apps/portal/src/pages/offers/home.tsx diff --git a/apps/portal/src/components/offers/OffersNavigation.ts b/apps/portal/src/components/offers/OffersNavigation.ts index cfa314dc..9b340cec 100644 --- a/apps/portal/src/components/offers/OffersNavigation.ts +++ b/apps/portal/src/components/offers/OffersNavigation.ts @@ -1,13 +1,14 @@ import type { ProductNavigationItems } from '~/components/global/ProductNavigation'; const navigation: ProductNavigationItems = [ - { href: '/offers/submit', name: 'Benchmark your offer' }, + { href: '/offers/home', name: 'Home' }, + { href: '/offers/submit', name: 'Analyse your offers' }, ]; const config = { navigation, showGlobalNav: false, - title: 'Tech Offers Repo', + title: 'Offer Profile Repository', titleHref: '/offers', }; diff --git a/apps/portal/src/components/offers/OffersTitle.tsx b/apps/portal/src/components/offers/OffersTitle.tsx index 2668ac4e..52798611 100644 --- a/apps/portal/src/components/offers/OffersTitle.tsx +++ b/apps/portal/src/components/offers/OffersTitle.tsx @@ -3,14 +3,14 @@ export default function OffersTitle() { <>