Add padding for progress bar in Preferences
Signed-off-by: dab246 <tdvu@linagora.com>
This commit is contained in:
@@ -124,6 +124,20 @@ class SettingsUtils {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
static EdgeInsetsGeometry getSettingProgressBarPadding(
|
||||||
|
BuildContext context,
|
||||||
|
ResponsiveUtils responsiveUtils,
|
||||||
|
) {
|
||||||
|
if (responsiveUtils.isWebDesktop(context)) {
|
||||||
|
return const EdgeInsetsDirectional.only(end: 16, top: 16);
|
||||||
|
} else if (responsiveUtils.isTablet(context) ||
|
||||||
|
responsiveUtils.isTabletLarge(context)) {
|
||||||
|
return const EdgeInsetsDirectional.only(start: 32, end: 32, top: 16);
|
||||||
|
} else {
|
||||||
|
return const EdgeInsetsDirectional.only(start: 16, end: 16, top: 16);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
static EdgeInsetsGeometry? getMarginSettingDetailsView(
|
static EdgeInsetsGeometry? getMarginSettingDetailsView(
|
||||||
BuildContext context,
|
BuildContext context,
|
||||||
ResponsiveUtils responsiveUtils,
|
ResponsiveUtils responsiveUtils,
|
||||||
|
|||||||
@@ -21,9 +21,10 @@ class PreferencesView extends GetWidget<PreferencesController> with AppLoaderMix
|
|||||||
return const SizedBox.shrink();
|
return const SizedBox.shrink();
|
||||||
}
|
}
|
||||||
return Padding(
|
return Padding(
|
||||||
padding: controller.responsiveUtils.isTablet(context)
|
padding: SettingsUtils.getSettingProgressBarPadding(
|
||||||
? const EdgeInsetsDirectional.only(start: 32, end: 32, top: 16)
|
context,
|
||||||
: const EdgeInsetsDirectional.only(start: 16, end: 16, top: 16),
|
controller.responsiveUtils,
|
||||||
|
),
|
||||||
child: horizontalLoadingWidget,
|
child: horizontalLoadingWidget,
|
||||||
);
|
);
|
||||||
}),
|
}),
|
||||||
@@ -43,7 +44,9 @@ class PreferencesView extends GetWidget<PreferencesController> with AppLoaderMix
|
|||||||
controller.responsiveUtils,
|
controller.responsiveUtils,
|
||||||
),
|
),
|
||||||
width: double.infinity,
|
width: double.infinity,
|
||||||
padding: const EdgeInsets.symmetric(vertical: 30, horizontal: 22),
|
padding: controller.responsiveUtils.isDesktop(context)
|
||||||
|
? const EdgeInsets.symmetric(vertical: 30, horizontal: 22)
|
||||||
|
: null,
|
||||||
child: Column(
|
child: Column(
|
||||||
crossAxisAlignment: CrossAxisAlignment.start,
|
crossAxisAlignment: CrossAxisAlignment.start,
|
||||||
children: [
|
children: [
|
||||||
@@ -70,7 +73,7 @@ class PreferencesView extends GetWidget<PreferencesController> with AppLoaderMix
|
|||||||
onTapSettingOptionAction: controller.updateStateSettingOption,
|
onTapSettingOptionAction: controller.updateStateSettingOption,
|
||||||
);
|
);
|
||||||
},
|
},
|
||||||
separatorBuilder: (_, __) => const SizedBox(height: 60),
|
separatorBuilder: (_, __) => const SizedBox(height: 49),
|
||||||
),
|
),
|
||||||
);
|
);
|
||||||
}),
|
}),
|
||||||
|
|||||||
+1
-1
@@ -42,7 +42,7 @@ class SettingOptionItem extends StatelessWidget {
|
|||||||
),
|
),
|
||||||
),
|
),
|
||||||
Padding(
|
Padding(
|
||||||
padding: const EdgeInsets.symmetric(vertical: 8),
|
padding: const EdgeInsets.symmetric(vertical: 12),
|
||||||
child: Text(
|
child: Text(
|
||||||
optionType.getExplanation(appLocalizations),
|
optionType.getExplanation(appLocalizations),
|
||||||
style: ThemeUtils.textStyleInter400.copyWith(
|
style: ThemeUtils.textStyleInter400.copyWith(
|
||||||
|
|||||||
Reference in New Issue
Block a user