diff --git a/lib/app/views/action_list.dart b/lib/app/views/action_list.dart index 7274ebe1..3c5f4034 100644 --- a/lib/app/views/action_list.dart +++ b/lib/app/views/action_list.dart @@ -53,7 +53,7 @@ class ActionListItem extends StatelessWidget { // }; return ListTile( - shape: RoundedRectangleBorder(borderRadius: BorderRadius.circular(30)), + shape: RoundedRectangleBorder(borderRadius: BorderRadius.circular(48)), title: Text(title), subtitle: subtitle != null ? Text(subtitle!) : null, leading: Opacity( diff --git a/lib/app/views/app_list_item.dart b/lib/app/views/app_list_item.dart index 0ef48e27..cb288662 100644 --- a/lib/app/views/app_list_item.dart +++ b/lib/app/views/app_list_item.dart @@ -77,7 +77,7 @@ class _AppListItemState extends ConsumerState { item: widget.item, child: InkWell( focusNode: _focusNode, - borderRadius: BorderRadius.circular(30), + borderRadius: BorderRadius.circular(48), onSecondaryTapDown: buildPopupActions == null ? null : (details) { diff --git a/lib/app/views/app_page.dart b/lib/app/views/app_page.dart index 5d22267e..75889379 100755 --- a/lib/app/views/app_page.dart +++ b/lib/app/views/app_page.dart @@ -41,6 +41,7 @@ final _mainContentGlobalKey = GlobalKey(); class AppPage extends StatefulWidget { final String? title; + final String? alternativeTitle; final String? footnote; final Widget Function(BuildContext context, bool expanded) builder; final Widget Function(BuildContext context)? detailViewBuilder; @@ -58,6 +59,7 @@ class AppPage extends StatefulWidget { const AppPage( {super.key, this.title, + this.alternativeTitle, this.footnote, required this.builder, this.centered = false, @@ -215,31 +217,38 @@ class _AppPageState extends State { AnimatedOpacity( opacity: !_isSliverTitleScrolledUnder ? 1 : 0, duration: const Duration(milliseconds: 300), - child: Wrap( - alignment: WrapAlignment.spaceBetween, - crossAxisAlignment: WrapCrossAlignment.center, - spacing: 2.0, - runSpacing: 8.0, - children: [ - Text( + child: Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + Flexible( + child: Text( key: _sliverTitleGlobalKey, - widget.title!, + widget.alternativeTitle ?? widget.title!, style: Theme.of(context).textTheme.displaySmall!.copyWith( - color: Theme.of(context) - .colorScheme - .primary - .withOpacity(0.9), + color: widget.alternativeTitle != null + ? Theme.of(context) + .colorScheme + .onSurfaceVariant + .withOpacity(0.4) + : Theme.of(context) + .colorScheme + .primary + .withOpacity(0.9), ), + overflow: TextOverflow.ellipsis, ), - if (widget.capabilities != null) - Wrap( - spacing: 4.0, - runSpacing: 8.0, - children: [ - ...widget.capabilities!.map((c) => CapabilityBadge(c)) - ], - ) - ]), + ), + if (widget.capabilities != null && + widget.alternativeTitle == null) + Wrap( + spacing: 4.0, + runSpacing: 8.0, + children: [ + ...widget.capabilities!.map((c) => CapabilityBadge(c)) + ], + ) + ], + ), ) ], ); @@ -267,7 +276,7 @@ class _AppPageState extends State { child: AnimatedOpacity( duration: const Duration(milliseconds: 300), opacity: _isSliverTitleScrolledUnder ? 1 : 0, - child: Text(widget.title!), + child: Text(widget.alternativeTitle ?? widget.title!), ), ); } diff --git a/lib/oath/views/oath_screen.dart b/lib/oath/views/oath_screen.dart index 484a578e..9f0afaba 100755 --- a/lib/oath/views/oath_screen.dart +++ b/lib/oath/views/oath_screen.dart @@ -144,6 +144,7 @@ class _UnlockedViewState extends ConsumerState<_UnlockedView> { .select((value) => value?.length)); final hasFeature = ref.watch(featureProvider); final hasActions = hasFeature(features.actions); + final searchText = searchController.text; Future onFileDropped(File file) async { final qrScanner = ref.read(qrScannerProvider); @@ -262,6 +263,7 @@ class _UnlockedViewState extends ConsumerState<_UnlockedView> { }, builder: (context) => AppPage( title: l10n.s_accounts, + alternativeTitle: searchText != '' ? 'Results for "$searchText"' : null, capabilities: const [Capability.oath], keyActionsBuilder: hasActions ? (context) => oathBuildActions( @@ -381,7 +383,7 @@ class _UnlockedViewState extends ConsumerState<_UnlockedView> { ?.copyWith(fontSize: textTheme.titleSmall?.fontSize), decoration: AppInputDecoration( border: OutlineInputBorder( - borderRadius: BorderRadius.circular(32), + borderRadius: BorderRadius.circular(48), borderSide: BorderSide( width: 0, style: searchFocus.hasFocus