]> Untitled Git - lemmy-ui.git/commitdiff
update prop name
authorAlec Armbruster <alectrocute@gmail.com>
Wed, 14 Jun 2023 13:39:19 +0000 (09:39 -0400)
committerAlec Armbruster <alectrocute@gmail.com>
Wed, 14 Jun 2023 13:39:19 +0000 (09:39 -0400)
src/shared/components/community/community-form.tsx
src/shared/components/community/create-community.tsx

index 1d32f6f7660fbd0bf2c77c4bbaba133af6350b25..4eed4645d461c358f5bb2a84cc4e6f26d87a9aa9 100644 (file)
@@ -21,7 +21,7 @@ interface CommunityFormProps {
   onCancel?(): any;
   onUpsertCommunity(form: CreateCommunity | EditCommunity): void;
   enableNsfw?: boolean;
-  isLoading?: boolean;
+  loading?: boolean;
 }
 
 interface CommunityFormState {
@@ -88,7 +88,7 @@ export class CommunityForm extends Component<
       <form onSubmit={linkEvent(this, this.handleCreateCommunitySubmit)}>
         <NavigationPrompt
           when={
-            !this.props.isLoading &&
+            !this.props.loading &&
             !!(
               this.state.form.name ||
               this.state.form.title ||
@@ -241,9 +241,9 @@ export class CommunityForm extends Component<
             <button
               type="submit"
               className="btn btn-secondary mr-2"
-              disabled={this.props.isLoading}
+              disabled={this.props.loading}
             >
-              {this.props.isLoading ? (
+              {this.props.loading ? (
                 <Spinner />
               ) : this.props.community_view ? (
                 capitalizeFirstLetter(i18n.t("save"))
index ecadd3a1a51a9beffcb14c2d5a2622b74fdc4751..ff31b839edc9cb1c968ca68bd7dba73cc6b32742 100644 (file)
@@ -47,7 +47,7 @@ export class CreateCommunity extends Component<any, CreateCommunityState> {
               allLanguages={this.state.siteRes.all_languages}
               siteLanguages={this.state.siteRes.discussion_languages}
               communityLanguages={this.state.siteRes.discussion_languages}
-              isLoading={this.state.loading}
+              loading={this.state.loading}
             />
           </div>
         </div>