From f25cae0513f72c10c177fb51e93bc42832bb4db6 Mon Sep 17 00:00:00 2001 From: Diljit Date: Mon, 1 Jul 2024 12:57:36 +0530 Subject: [PATCH] chore: Change the default value of isLoading in settings reducer to true (#34490) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit ## Description This PR makes sure that the initial value of `isLoading` in the settings reducer is set to true. This flag is used to conditionally render the loading component and the AdminSettings component in `app/client/src/pages/AdminSettings/index.tsx`. This change makes sure that the Admin Page components are not mounted and unmounted on initial render. The mouting and unmounting used to happen earlier because the flag switched from false => true => false. Fixes #`Issue Number` _or_ Fixes `Issue URL` > [!WARNING] > _If no issue exists, please create an issue first, and check with the maintainers if the issue is valid._ ## Automation /ok-to-test tags="@tag.Sanity" ### :mag: Cypress test results > [!TIP] > 🟢 🟢 🟢 All cypress tests have passed! 🎉 🎉 🎉 > Workflow run: > Commit: 553b867bfa7a72d97bd54d4ef10f5ce9fee665e4 > Cypress dashboard. > Tags: `@tag.Sanity` ## Communication Should the DevRel and Marketing teams inform users about this change? - [ ] Yes - [x] No ## Summary by CodeRabbit - **Bug Fixes** - Improved initial loading state of settings to enhance user experience during app startup. --- app/client/src/ce/reducers/settingsReducer.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/client/src/ce/reducers/settingsReducer.ts b/app/client/src/ce/reducers/settingsReducer.ts index 19d4e084a3fb..63331637e32b 100644 --- a/app/client/src/ce/reducers/settingsReducer.ts +++ b/app/client/src/ce/reducers/settingsReducer.ts @@ -8,7 +8,7 @@ import type { TenantReduxState } from "@appsmith/reducers/tenantReducer"; import { tenantConfigConnection } from "@appsmith/constants/tenantConstants"; export const initialState: SettingsReduxState = { - isLoading: false, + isLoading: true, isSaving: false, isRestarting: false, showReleaseNotes: false,