fix: loading animation of update buttons (#13131)
* fixed loading animation of update buttons * Update BookerLayoutSelector.tsx * fix: update button animation in settings appearance page * Update appearance.tsx * Update appearance.tsx --------- Co-authored-by: Joe Au-Yeung <[email protected]> Co-authored-by: Keith Williams <[email protected]> Co-authored-by: Udit Takkar <[email protected]>
This commit is contained in:
2 files changed
+9
-2
No files matched your search
@@ -139,6 +139,9 @@ const AppearanceView = ({
|
||||
showToast(t("error_updating_settings"), "error");
|
||||
}
|
||||
},
|
||||
onSettled: async () => {
|
||||
await utils.viewer.me.invalidate();
|
||||
},
|
||||
});
|
||||
|
||||
return (
|
||||
@@ -184,6 +187,7 @@ const AppearanceView = ({
|
||||
</div>
|
||||
<SectionBottomActions className="mb-6" align="end">
|
||||
<Button
|
||||
loading={mutation.isPending}
|
||||
disabled={isUserThemeSubmitting || !isUserThemeDirty}
|
||||
type="submit"
|
||||
data-testid="update-theme-btn"
|
||||
@@ -210,6 +214,7 @@ const AppearanceView = ({
|
||||
title={t("bookerlayout_user_settings_title")}
|
||||
description={t("bookerlayout_user_settings_description")}
|
||||
isDisabled={isBookerLayoutFormSubmitting || !isBookerLayoutFormDirty}
|
||||
isLoading={mutation.isPending}
|
||||
/>
|
||||
</Form>
|
||||
|
||||
@@ -295,6 +300,7 @@ const AppearanceView = ({
|
||||
</div>
|
||||
<SectionBottomActions align="end">
|
||||
<Button
|
||||
loading={mutation.isPending}
|
||||
disabled={isBrandColorsFormSubmitting || !isBrandColorsFormDirty}
|
||||
color="primary"
|
||||
type="submit">
|
||||
|
||||
Reference in new issue
Block a user