From: Sean Spade Date: Thu, 8 Jun 2023 23:42:39 +0000 (-0400) Subject: fix: Adds ability to hide language warning X-Git-Url: http://these/git/%7BmarkdownHelpUrl%7D?a=commitdiff_plain;h=9d45b4afe3834305e7c91396f9dcfeec7c5190aa;p=lemmy-ui.git fix: Adds ability to hide language warning --- 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} />