Animate the splash and fix the web preview hanging on the logo
The splash now raises the sun in the mark and over a painted valley, floats four feature chips around the mark, shimmers the wordmark, shows a three-beat "how it works" card, drifts light motes upward and walks a status line through the session check. A tap skips it. The web build hung on the native splash because the asset manifest could not be published: "assets/icons/splash_orb.png" is 27 characters, so its length prefix in AssetManifest.bin is an ESC byte. Renamed it to splash_mark.png and removed the unused anchor assets. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01KhQh614DMeYoQEH9SoMRUw
This commit is contained in:
@@ -26,6 +26,9 @@ class SceneArt extends StatelessWidget {
|
||||
/// Darkens the lower half so white type laid over it stays legible.
|
||||
final bool shade;
|
||||
|
||||
/// Lowers the sun behind the ridges; animate it for a sunrise.
|
||||
final double sunLift;
|
||||
|
||||
const SceneArt({
|
||||
super.key,
|
||||
required this.palette,
|
||||
@@ -34,6 +37,7 @@ class SceneArt extends StatelessWidget {
|
||||
this.figureScale = 0.5,
|
||||
this.figureAlignment = const Alignment(0.35, 0.15),
|
||||
this.shade = false,
|
||||
this.sunLift = 1,
|
||||
});
|
||||
|
||||
@override
|
||||
@@ -50,7 +54,8 @@ class SceneArt extends StatelessWidget {
|
||||
child: Stack(
|
||||
fit: StackFit.expand,
|
||||
children: [
|
||||
CustomPaint(painter: ScenePainter(palette, seed)),
|
||||
CustomPaint(
|
||||
painter: ScenePainter(palette, seed, sunLift: sunLift)),
|
||||
if (figure != null)
|
||||
Align(
|
||||
alignment: figureAlignment,
|
||||
|
||||
@@ -11,7 +11,10 @@ class ScenePainter extends CustomPainter {
|
||||
|
||||
final int seed;
|
||||
|
||||
ScenePainter(this.palette, this.seed);
|
||||
/// 1 → the sun sits in its place; 0 → it is down behind the ridges.
|
||||
final double sunLift;
|
||||
|
||||
ScenePainter(this.palette, this.seed, {this.sunLift = 1});
|
||||
|
||||
@override
|
||||
void paint(Canvas canvas, Size size) {
|
||||
@@ -36,7 +39,7 @@ class ScenePainter extends CustomPainter {
|
||||
final double radius = math.min(w, h) * (0.13 + random.nextDouble() * 0.05);
|
||||
final Offset sun = Offset(
|
||||
w * (0.18 + random.nextDouble() * 0.64),
|
||||
h * (0.26 + random.nextDouble() * 0.12),
|
||||
h * (0.26 + random.nextDouble() * 0.12) + h * 0.5 * (1 - sunLift),
|
||||
);
|
||||
canvas.drawCircle(
|
||||
sun,
|
||||
@@ -109,6 +112,8 @@ class ScenePainter extends CustomPainter {
|
||||
|
||||
@override
|
||||
bool shouldRepaint(covariant ScenePainter oldDelegate) {
|
||||
return oldDelegate.seed != seed || oldDelegate.palette != palette;
|
||||
return oldDelegate.seed != seed ||
|
||||
oldDelegate.palette != palette ||
|
||||
oldDelegate.sunLift != sunLift;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user