diff --git a/lib/styles/styles.dart b/lib/styles/styles.dart index 9d6af33c..de3fef48 100644 --- a/lib/styles/styles.dart +++ b/lib/styles/styles.dart @@ -159,7 +159,7 @@ class _Sizes { double get maxContentWidth1 => 800; double get maxContentWidth2 => 600; double get maxContentWidth3 => 500; - final Size minAppSize = Size(450, 600); + final Size minAppSize = Size(380, 675); } @immutable diff --git a/lib/ui/screens/artifact/artifact_carousel/artifact_carousel_screen.dart b/lib/ui/screens/artifact/artifact_carousel/artifact_carousel_screen.dart index 65329463..49f18366 100644 --- a/lib/ui/screens/artifact/artifact_carousel/artifact_carousel_screen.dart +++ b/lib/ui/screens/artifact/artifact_carousel/artifact_carousel_screen.dart @@ -252,7 +252,7 @@ class _CarouselBottomTextWithCircle extends StatelessWidget { text: $strings.artifactsButtonBrowse, icon: AppIcons.search, expand: true, - onPressed: () {}, //_handleSearchTap, + onPressed: () => _handleSearchTap(context), ), Gap($styles.insets.lg), ], @@ -262,6 +262,10 @@ class _CarouselBottomTextWithCircle extends StatelessWidget { ); } + void _handleSearchTap(BuildContext context) { + //context.push(ScreenPaths.search(widget.type)); + } + OverflowBox _buildBgCircle() { return OverflowBox( maxWidth: 2000, diff --git a/lib/ui/screens/editorial/editorial_screen.dart b/lib/ui/screens/editorial/editorial_screen.dart index 71e03557..0ede005f 100644 --- a/lib/ui/screens/editorial/editorial_screen.dart +++ b/lib/ui/screens/editorial/editorial_screen.dart @@ -36,6 +36,10 @@ part 'widgets/_sliding_image_stack.dart'; part 'widgets/_title_text.dart'; part 'widgets/_top_illustration.dart'; +//TODO: Try and maintain 1.5 : 1 aspect ratio on the featured image +//TODO: Try and move the scrollbar all the way to the edge of the screen +//TODO: Fix arch logic (if necessary) +// or maybe remove class WonderEditorialScreen extends StatefulWidget { const WonderEditorialScreen(this.data, {Key? key, required this.onScroll}) : super(key: key); final WonderData data; diff --git a/lib/ui/screens/wonder_events/widgets/_events_list.dart b/lib/ui/screens/wonder_events/widgets/_events_list.dart index e32d80ba..8d86b3a4 100644 --- a/lib/ui/screens/wonder_events/widgets/_events_list.dart +++ b/lib/ui/screens/wonder_events/widgets/_events_list.dart @@ -56,6 +56,7 @@ class _EventsListState extends State<_EventsList> { } return Stack( children: [ + //TODO: Remove scrollbar on portrait SingleChildScrollView( controller: _scroller, child: Column( diff --git a/lib/ui/wonder_illustrations/chichen_itza_illustration.dart b/lib/ui/wonder_illustrations/chichen_itza_illustration.dart index f9eb7b4a..d5831ae7 100644 --- a/lib/ui/wonder_illustrations/chichen_itza_illustration.dart +++ b/lib/ui/wonder_illustrations/chichen_itza_illustration.dart @@ -101,71 +101,6 @@ class ChichenItzaIllustration extends StatelessWidget { zoomAmt: .1, dynamicHzOffset: -100, ), - - // Stack( - // children: [ - // Transform.scale( - // scale: 1 + config.zoom * .05, - // child: FractionalTranslation( - // translation: Offset(-.2 * (1 - curvedAnim), 0), - // child: BottomLeft( - // child: SizedBox( - // height: 500, - // child: FractionalTranslation( - // translation: Offset(-.4, .15), - // child: Image.asset('$assetPath/foreground-left.png', opacity: anim, fit: BoxFit.cover), - // ), - // ), - // ), - // ), - // ), - // Transform.scale( - // scale: 1 + config.zoom * .03, - // child: FractionalTranslation( - // translation: Offset(.2 * (1 - curvedAnim), 0), - // child: BottomRight( - // child: SizedBox( - // height: 350, - // child: FractionalTranslation( - // translation: Offset(.35, .2), - // child: Image.asset('$assetPath/foreground-right.png', opacity: anim, fit: BoxFit.cover), - // ), - // ), - // ), - // ), - // ), - // Transform.scale( - // scale: 1 + config.zoom * .25, - // child: FractionalTranslation( - // translation: Offset(-.2 * (1 - curvedAnim), 0), - // child: TopLeft( - // child: SizedBox( - // height: 600, - // child: FractionalTranslation( - // translation: Offset(-.3, -.45), - // child: Image.asset('$assetPath/top-left.png', opacity: anim, fit: BoxFit.cover), - // ), - // ), - // ), - // ), - // ), - // Transform.scale( - // scale: 1 + config.zoom * .2, - // child: FractionalTranslation( - // translation: Offset(.2 * (1 - curvedAnim), 0), - // child: TopRight( - // child: SizedBox( - // height: 700, - // child: FractionalTranslation( - // translation: Offset(.2, -.35), - // child: Image.asset('$assetPath/top-right.png', opacity: anim, fit: BoxFit.cover), - // ), - // ), - // ), - // ), - // ), - // ], - // ), ]; } } diff --git a/lib/ui/wonder_illustrations/colosseum_illustration.dart b/lib/ui/wonder_illustrations/colosseum_illustration.dart index ede4222a..cbca64d1 100644 --- a/lib/ui/wonder_illustrations/colosseum_illustration.dart +++ b/lib/ui/wonder_illustrations/colosseum_illustration.dart @@ -33,23 +33,13 @@ class ColosseumIllustration extends StatelessWidget { opacity: anim.drive(Tween(begin: 0, end: .5)), ), ), - Align( - alignment: config.shortMode ? Alignment(-.3, 1) : Alignment(-.5, -.4), - child: FractionalTranslation( - translation: Offset(0, -.5 * anim.value), - child: WonderHero( - config, - 'colosseum-sun', - child: Transform.scale( - scale: config.shortMode ? .75 : 1, - child: Image.asset( - '$assetPath/sun.png', - cacheWidth: context.widthPx.round() * 2, - opacity: anim, - ), - ), - ), - ), + IllustrationPiece( + fileName: 'sun.png', + initialOffset: Offset(0, 20), + enableHero: true, + heightFactor: .15, + minHeight: 150, + offset: config.shortMode ? Offset(70, context.heightPx * -.05) : Offset(50, context.heightPx * -.25), ), ]; } @@ -60,6 +50,7 @@ class ColosseumIllustration extends StatelessWidget { children: const [ IllustrationPiece( fileName: 'colosseum.png', + enableHero: true, heightFactor: .55, minHeight: 400, zoomAmt: .15, diff --git a/lib/ui/wonder_illustrations/common/animated_clouds.dart b/lib/ui/wonder_illustrations/common/animated_clouds.dart index 3749e1ac..44d0a94a 100644 --- a/lib/ui/wonder_illustrations/common/animated_clouds.dart +++ b/lib/ui/wonder_illustrations/common/animated_clouds.dart @@ -2,6 +2,7 @@ import 'dart:async'; import 'package:wonders/common_libs.dart'; import 'package:wonders/ui/common/utils/context_utils.dart'; +//TODO: Make the clouds fade out and in // Shows a set of clouds that animated onto stage. // When value-key is changed, a new set of clouds will animate into place and the old ones will animate out. // Uses a random seed system, to make sure we get the same set of clouds for each wonder, without actually having to hand-position them. diff --git a/lib/ui/wonder_illustrations/great_wall_illustration.dart b/lib/ui/wonder_illustrations/great_wall_illustration.dart index b9d6c78d..04aabc20 100644 --- a/lib/ui/wonder_illustrations/great_wall_illustration.dart +++ b/lib/ui/wonder_illustrations/great_wall_illustration.dart @@ -50,7 +50,7 @@ class GreatWallIllustration extends StatelessWidget { IllustrationPiece( fileName: 'great-wall.png', heightFactor: .55, - minHeight: 600, + minHeight: 500, zoomAmt: .05, enableHero: true, ), diff --git a/lib/ui/wonder_illustrations/taj_mahal_illustration.dart b/lib/ui/wonder_illustrations/taj_mahal_illustration.dart index 56e23ede..b63dde65 100644 --- a/lib/ui/wonder_illustrations/taj_mahal_illustration.dart +++ b/lib/ui/wonder_illustrations/taj_mahal_illustration.dart @@ -59,6 +59,7 @@ class TajMahalIllustration extends StatelessWidget { fileName: 'taj-mahal.png', heightFactor: heightFactor, minHeight: minHeight, + enableHero: true, zoomAmt: .05, top: config.shortMode ? null