mirror of
https://github.com/zarzet/SpotiFLAC-Mobile.git
synced 2026-07-29 23:38:50 +02:00
revert(ui): drop hero cover flights from home/search to detail screens
The list-to-header cover flights read as a gimmick and add per-frame cost during navigation. Removed the heroTag plumbing end to end (recents, search rows, discography cards, Album/Artist/Downloaded headers, motion banners). Kept: the mini player expand hero, the library-to-track-metadata hero, real loading headers, and the loading crossfade.
This commit is contained in:
@@ -23,7 +23,6 @@ class AlbumDetailHeader extends StatelessWidget {
|
||||
this.appBarTitle,
|
||||
this.leading,
|
||||
this.backgroundColor,
|
||||
this.heroTag,
|
||||
});
|
||||
|
||||
final String title;
|
||||
@@ -62,10 +61,6 @@ class AlbumDetailHeader extends StatelessWidget {
|
||||
|
||||
final Color? backgroundColor;
|
||||
|
||||
/// Shared-element tag: when set, the cover flies from the list item that
|
||||
/// pushed this screen (which wraps its thumbnail in a matching [Hero]).
|
||||
final Object? heroTag;
|
||||
|
||||
/// Shrinks long titles so up to three lines fit the header.
|
||||
double _titleFontSize() {
|
||||
final length = title.trim().length;
|
||||
@@ -154,7 +149,7 @@ class AlbumDetailHeader extends StatelessWidget {
|
||||
final coverSize = (constraints.maxWidth * 0.5)
|
||||
.clamp(150.0, 210.0)
|
||||
.toDouble();
|
||||
final cover = Container(
|
||||
return Container(
|
||||
width: coverSize,
|
||||
height: coverSize,
|
||||
decoration: BoxDecoration(
|
||||
@@ -174,9 +169,6 @@ class AlbumDetailHeader extends StatelessWidget {
|
||||
child: coverBuilder!(context, coverSize),
|
||||
),
|
||||
);
|
||||
return heroTag != null
|
||||
? Hero(tag: heroTag!, child: cover)
|
||||
: cover;
|
||||
},
|
||||
),
|
||||
const SizedBox(height: 20),
|
||||
|
||||
Reference in New Issue
Block a user