Fix: TabBar overflow on mode change

This commit is contained in:
Manan Gandhi
2025-11-27 19:33:43 +05:30
parent 69fba11078
commit 5af87725eb
2 changed files with 7 additions and 2 deletions

View File

@@ -13,9 +13,13 @@ class EditAIRequestPane extends ConsumerWidget {
Widget build(BuildContext context, WidgetRef ref) {
final selectedId = ref.watch(selectedIdStateProvider);
final codePaneVisible = ref.watch(codePaneVisibleStateProvider);
final tabIndex = ref.watch(
var tabIndex = ref.watch(
selectedRequestModelProvider.select((value) => value?.requestTabIndex));
if (tabIndex >= 3) {
tabIndex = 0;
}
return RequestPane(
selectedId: selectedId,
codePaneVisible: codePaneVisible,

View File

@@ -34,9 +34,10 @@ class EditGraphQLRequestPane extends ConsumerWidget {
final hasAuth = ref.watch(selectedRequestModelProvider.select((value) =>
value?.httpRequestModel?.authModel?.type != APIAuthType.none));
if (tabIndex >= 3) {
if (tabIndex >= 4) {
tabIndex = 0;
}
return RequestPane(
selectedId: selectedId,
codePaneVisible: codePaneVisible,