An open-source cross-platform alternative to AirDrop
fix: adjust width depending on OS
Tien Do Nambcd7dede07e5
diff --git a/app/assets/CHANGELOG.md b/app/assets/CHANGELOG.mdindex 5cc408a0..01dcbdf6 100644--- a/app/assets/CHANGELOG.md+++ b/app/assets/CHANGELOG.md@@ -1,6 +1,7 @@## 1.14.0 (unreleased)- feat: add option to automatically accept requests when sharing via link (@MisterChangRay, @Tienisto)+- feat: use fix button width for all buttons in the selection row (only noticeable in Russian) (@Tienisto)- fix: picking many files should not freeze the UI (@Tienisto)- fix: do not create a new session for the same IP when sharing via link (@MisterChangRay)- i18n: add Danish (@Limfjorden)diff --git a/app/lib/theme.dart b/app/lib/theme.dartindex 4dbe4303..6bfb65d0 100644--- a/app/lib/theme.dart+++ b/app/lib/theme.dart@@ -10,6 +10,9 @@ import 'package:yaru/yaru.dart' as yaru;final _borderRadius = BorderRadius.circular(5);+/// On desktop, we need to add additional padding to achieve the same visual appearance as on mobile+double get desktopPaddingFix => checkPlatformIsDesktop() ? 8 : 0;+ThemeData getTheme(ColorMode colorMode, Brightness brightness, DynamicColors? dynamicColors) {if (colorMode == ColorMode.yaru) {return _getYaruTheme(brightness);@@ -60,12 +63,12 @@ ThemeData getTheme(ColorMode colorMode, Brightness brightness, DynamicColors? dyelevatedButtonTheme: ElevatedButtonThemeData(style: ElevatedButton.styleFrom(foregroundColor: colorScheme.brightness == Brightness.dark ? Colors.white : null,- padding: checkPlatformIsDesktop() ? const EdgeInsets.all(16) : const EdgeInsets.symmetric(horizontal: 16, vertical: 8),+ padding: EdgeInsets.symmetric(horizontal: 16, vertical: 8 + desktopPaddingFix),),),textButtonTheme: TextButtonThemeData(style: TextButton.styleFrom(- padding: checkPlatformIsDesktop() ? const EdgeInsets.all(16) : const EdgeInsets.symmetric(horizontal: 16, vertical: 8),+ padding: EdgeInsets.symmetric(horizontal: 16, vertical: 8 + desktopPaddingFix),),),fontFamily: fontFamily,diff --git a/app/lib/widget/big_button.dart b/app/lib/widget/big_button.dartindex 09d440dd..3b4b3c1a 100644--- a/app/lib/widget/big_button.dart+++ b/app/lib/widget/big_button.dart@@ -35,7 +35,7 @@ class BigButton extends StatelessWidget {shape: RoundedRectangleBorder(borderRadius: BorderRadius.circular(10),),- padding: const EdgeInsets.only(left: 2, right: 2, top: 18, bottom: 16),+ padding: EdgeInsets.only(left: 2, right: 2, top: 10 + desktopPaddingFix, bottom: 8 + desktopPaddingFix),),onPressed: onTap,child: Column(