This commit refactors how IdeSettings and ControlPlaneClient are accessed throughout
the configuration system to improve state management and reduce coupling.
Previously, ideSettingsPromise was passed down from the top-level ConfigHandler
through various profile loaders and clients. This created a rigid dependency chain
and required manual promise replacement when settings were updated. Similarly,
downstream components could hold onto stale instances of ControlPlaneClient after a
change in authentication state.
The key changes are:
- Removed ideSettingsPromise prop drilling: Components that require IDE settings
now fetch them directly from the IDE object (ide.getIdeSettings()) when
needed.
- Updated globalLocalProfileManager during every cascadeInit: This ensures it
always holds the most recent ControlPlaneClient, preventing issues with stale
client objects after re-authentication.
- Simplified constructors: The constructors for ConfigHandler, ControlPlaneClient,
and various loaders have been simplified to reflect these changes, primarily by
passing the IDE object directly instead of its derived promises.