From 40b46a4366acd453120a4d6fd314f6f211aa5ef3 Mon Sep 17 00:00:00 2001 From: Jeff Sieu Date: Thu, 20 Oct 2022 14:46:22 +0800 Subject: [PATCH] [ui][typeahead] add label defaultProp --- .../src/components/questions/ContributeQuestionForm.tsx | 1 - apps/portal/src/components/shared/CompaniesTypeahead.tsx | 5 +++-- apps/portal/src/pages/index.tsx | 1 - apps/portal/src/pages/offers/index.tsx | 1 - 4 files changed, 3 insertions(+), 5 deletions(-) diff --git a/apps/portal/src/components/questions/ContributeQuestionForm.tsx b/apps/portal/src/components/questions/ContributeQuestionForm.tsx index 54fad19b..a0e4d0b6 100644 --- a/apps/portal/src/components/questions/ContributeQuestionForm.tsx +++ b/apps/portal/src/components/questions/ContributeQuestionForm.tsx @@ -84,7 +84,6 @@ export default function ContributeQuestionForm({ name="company" render={({ field }) => ( { field.onChange(id); }} diff --git a/apps/portal/src/components/shared/CompaniesTypeahead.tsx b/apps/portal/src/components/shared/CompaniesTypeahead.tsx index 3732751c..d283c1d4 100644 --- a/apps/portal/src/components/shared/CompaniesTypeahead.tsx +++ b/apps/portal/src/components/shared/CompaniesTypeahead.tsx @@ -8,9 +8,9 @@ type TypeaheadProps = ComponentProps; type Props = Omit< TypeaheadProps, - 'noResultsMessage' | 'onQueryChange' | 'options' | 'query' + 'label' | 'noResultsMessage' | 'onQueryChange' | 'options' | 'query' > & - Partial> & + Partial> & ( | Required> | { @@ -39,6 +39,7 @@ export default function CompaniesTypeahead({ return ( setSelectedCompany(option)} />
{JSON.stringify(selectedCompany, null, 2)}
diff --git a/apps/portal/src/pages/offers/index.tsx b/apps/portal/src/pages/offers/index.tsx index e96d3fe4..cc35ed68 100644 --- a/apps/portal/src/pages/offers/index.tsx +++ b/apps/portal/src/pages/offers/index.tsx @@ -46,7 +46,6 @@ export default function OffersHomePage() {
setCompanyFilter(value)} />