From 9d45b4afe3834305e7c91396f9dcfeec7c5190aa Mon Sep 17 00:00:00 2001 From: Sean Spade Date: Thu, 8 Jun 2023 19:42:39 -0400 Subject: [PATCH] fix: Adds ability to hide language warning --- src/shared/components/common/language-select.tsx | 3 ++- src/shared/components/community/community-form.tsx | 1 + 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/src/shared/components/common/language-select.tsx b/src/shared/components/common/language-select.tsx index 372d372..a82d651 100644 --- a/src/shared/components/common/language-select.tsx +++ b/src/shared/components/common/language-select.tsx @@ -16,6 +16,7 @@ interface LanguageSelectProps { showSite?: boolean; iconVersion?: boolean; disabled?: boolean; + hideLanguageWarning?: boolean; } export class LanguageSelect extends Component { @@ -49,7 +50,7 @@ export class LanguageSelect extends Component { this.selectBtn ) : (
- {this.props.multiple && ( + {this.props.multiple && !this.props.hideLanguageWarning && (
{i18n.t("undetermined_language_warning")}
diff --git a/src/shared/components/community/community-form.tsx b/src/shared/components/community/community-form.tsx index 372e66a..25fd82f 100644 --- a/src/shared/components/community/community-form.tsx +++ b/src/shared/components/community/community-form.tsx @@ -265,6 +265,7 @@ export class CommunityForm extends Component< showSite selectedLanguageIds={this.state.form.discussion_languages} multiple={true} + hideLanguageWarning={true} onChange={this.handleDiscussionLanguageChange} />
-- 2.44.1