mirror of
https://github.com/flutter/samples.git
synced 2025-11-10 23:08:59 +00:00
Flutter 3.29 beta (#2571)
This commit is contained in:
@@ -11,10 +11,7 @@ import '../page_content/pages_flow.dart';
|
||||
import '../styles.dart';
|
||||
|
||||
class PageAscenderDescender extends SinglePage {
|
||||
const PageAscenderDescender({
|
||||
super.key,
|
||||
required super.pageConfig,
|
||||
});
|
||||
const PageAscenderDescender({super.key, required super.pageConfig});
|
||||
@override
|
||||
State<SinglePage> createState() => _PageAscenderDescenderState();
|
||||
}
|
||||
@@ -82,10 +79,7 @@ class _PageAscenderDescenderState extends SinglePageState {
|
||||
to: PageConfig.baseWeight,
|
||||
curve: Curves.easeInOut,
|
||||
),
|
||||
WonkyAnimPalette.descenderDepth(
|
||||
from: -500,
|
||||
to: -138,
|
||||
)
|
||||
WonkyAnimPalette.descenderDepth(from: -500, to: -138),
|
||||
],
|
||||
),
|
||||
),
|
||||
@@ -126,10 +120,7 @@ class _PageAscenderDescenderState extends SinglePageState {
|
||||
from: PageConfig.baseWeight,
|
||||
to: PageConfig.baseWeight,
|
||||
),
|
||||
WonkyAnimPalette.ascenderHt(
|
||||
from: 600,
|
||||
to: 980,
|
||||
),
|
||||
WonkyAnimPalette.ascenderHt(from: 600, to: 980),
|
||||
],
|
||||
),
|
||||
),
|
||||
@@ -184,10 +175,7 @@ class _PageAscenderDescenderState extends SinglePageState {
|
||||
from: PageConfig.baseWeight,
|
||||
to: PageConfig.baseWeight,
|
||||
),
|
||||
WonkyAnimPalette.descenderDepth(
|
||||
from: -200,
|
||||
to: -500,
|
||||
)
|
||||
WonkyAnimPalette.descenderDepth(from: -200, to: -500),
|
||||
],
|
||||
),
|
||||
),
|
||||
@@ -204,10 +192,11 @@ class _PageAscenderDescenderState extends SinglePageState {
|
||||
shaderDuration: 2000,
|
||||
tileShadedString: 'fyd',
|
||||
tileShadedStringPadding: EdgeInsets.only(
|
||||
top: 0.233 * widget.pageConfig.puzzleSize,
|
||||
bottom: 0,
|
||||
left: 0.465 * widget.pageConfig.puzzleSize,
|
||||
right: 0.465 * widget.pageConfig.puzzleSize),
|
||||
top: 0.233 * widget.pageConfig.puzzleSize,
|
||||
bottom: 0,
|
||||
left: 0.465 * widget.pageConfig.puzzleSize,
|
||||
right: 0.465 * widget.pageConfig.puzzleSize,
|
||||
),
|
||||
tileShadedStringSize: 1.86 * widget.pageConfig.puzzleSize,
|
||||
tileScaleModifier: 2.7,
|
||||
tileShadedStringAnimDuration: 2000,
|
||||
|
||||
@@ -8,10 +8,7 @@ import '../page_content/pages_flow.dart';
|
||||
import '../styles.dart';
|
||||
|
||||
class PageNarrativePost extends NarrativePage {
|
||||
const PageNarrativePost({
|
||||
super.key,
|
||||
required super.pageConfig,
|
||||
});
|
||||
const PageNarrativePost({super.key, required super.pageConfig});
|
||||
|
||||
@override
|
||||
State<NarrativePage> createState() => _PageNarrativePostState();
|
||||
@@ -32,12 +29,8 @@ class _PageNarrativePostState extends NarrativePageState {
|
||||
style: TextStyles.bodyStyle(),
|
||||
textAlign: TextAlign.left,
|
||||
),
|
||||
const SizedBox(
|
||||
height: 8,
|
||||
),
|
||||
const Image(
|
||||
image: AssetImage('assets/images/specimen-1.png'),
|
||||
),
|
||||
const SizedBox(height: 8),
|
||||
const Image(image: AssetImage('assets/images/specimen-1.png')),
|
||||
Text(
|
||||
'As a reward, please enjoy the FontCo wallpapers on the next screen. Congratulations!',
|
||||
style: TextStyles.bodyStyle(),
|
||||
|
||||
@@ -8,10 +8,7 @@ import '../page_content/pages_flow.dart';
|
||||
import '../styles.dart';
|
||||
|
||||
class PageNarrativePre extends NarrativePage {
|
||||
const PageNarrativePre({
|
||||
super.key,
|
||||
required super.pageConfig,
|
||||
});
|
||||
const PageNarrativePre({super.key, required super.pageConfig});
|
||||
|
||||
@override
|
||||
State<NarrativePage> createState() => _PageNarrativePreState();
|
||||
@@ -32,12 +29,8 @@ class _PageNarrativePreState extends NarrativePageState {
|
||||
style: TextStyles.bodyStyle(),
|
||||
textAlign: TextAlign.left,
|
||||
),
|
||||
const SizedBox(
|
||||
height: 8,
|
||||
),
|
||||
const Image(
|
||||
image: AssetImage('assets/images/specimen-1.png'),
|
||||
),
|
||||
const SizedBox(height: 8),
|
||||
const Image(image: AssetImage('assets/images/specimen-1.png')),
|
||||
],
|
||||
),
|
||||
LightboxedPanel(
|
||||
@@ -58,18 +51,14 @@ class _PageNarrativePreState extends NarrativePageState {
|
||||
textAlign: TextAlign.left,
|
||||
),
|
||||
),
|
||||
const SizedBox(
|
||||
height: 8,
|
||||
),
|
||||
const SizedBox(height: 8),
|
||||
Transform.scale(
|
||||
scaleX: -1,
|
||||
child: const Image(
|
||||
image: AssetImage('assets/images/specimen-1-glitch.png'),
|
||||
),
|
||||
),
|
||||
const SizedBox(
|
||||
height: 56,
|
||||
),
|
||||
const SizedBox(height: 56),
|
||||
],
|
||||
),
|
||||
LightboxedPanel(
|
||||
@@ -93,9 +82,7 @@ class _PageNarrativePreState extends NarrativePageState {
|
||||
),
|
||||
),
|
||||
),
|
||||
const SizedBox(
|
||||
height: 8,
|
||||
),
|
||||
const SizedBox(height: 8),
|
||||
Transform.scale(
|
||||
scaleX: -1,
|
||||
child: Transform.translate(
|
||||
@@ -105,9 +92,7 @@ class _PageNarrativePreState extends NarrativePageState {
|
||||
),
|
||||
),
|
||||
),
|
||||
const SizedBox(
|
||||
height: 56,
|
||||
),
|
||||
const SizedBox(height: 56),
|
||||
],
|
||||
),
|
||||
LightboxedPanel(
|
||||
@@ -128,18 +113,14 @@ class _PageNarrativePreState extends NarrativePageState {
|
||||
textAlign: TextAlign.left,
|
||||
),
|
||||
),
|
||||
const SizedBox(
|
||||
height: 8,
|
||||
),
|
||||
const SizedBox(height: 8),
|
||||
Transform.scale(
|
||||
scaleX: -1,
|
||||
child: const Image(
|
||||
image: AssetImage('assets/images/specimen-1-glitch.png'),
|
||||
),
|
||||
),
|
||||
const SizedBox(
|
||||
height: 56,
|
||||
),
|
||||
const SizedBox(height: 56),
|
||||
],
|
||||
),
|
||||
LightboxedPanel(
|
||||
@@ -153,12 +134,8 @@ class _PageNarrativePreState extends NarrativePageState {
|
||||
style: TextStyles.bodyStyle(),
|
||||
textAlign: TextAlign.left,
|
||||
),
|
||||
const SizedBox(
|
||||
height: 8,
|
||||
),
|
||||
const Image(
|
||||
image: AssetImage('assets/images/specimen-2.png'),
|
||||
),
|
||||
const SizedBox(height: 8),
|
||||
const Image(image: AssetImage('assets/images/specimen-2.png')),
|
||||
],
|
||||
),
|
||||
];
|
||||
|
||||
@@ -11,10 +11,7 @@ import '../page_content/pages_flow.dart';
|
||||
import '../styles.dart';
|
||||
|
||||
class PageOpticalSize extends SinglePage {
|
||||
const PageOpticalSize({
|
||||
super.key,
|
||||
required super.pageConfig,
|
||||
});
|
||||
const PageOpticalSize({super.key, required super.pageConfig});
|
||||
|
||||
@override
|
||||
State<SinglePage> createState() => _PageOpticalSizeState();
|
||||
@@ -60,10 +57,7 @@ class _PageOpticalSizeState extends SinglePageState {
|
||||
to: PageConfig.baseWeight,
|
||||
curve: Curves.easeInOut,
|
||||
),
|
||||
WonkyAnimPalette.opticalSize(
|
||||
from: 70,
|
||||
to: 144,
|
||||
)
|
||||
WonkyAnimPalette.opticalSize(from: 70, to: 144),
|
||||
],
|
||||
),
|
||||
),
|
||||
@@ -81,10 +75,7 @@ class _PageOpticalSizeState extends SinglePageState {
|
||||
to: PageConfig.baseWeight,
|
||||
curve: Curves.easeInOut,
|
||||
),
|
||||
WonkyAnimPalette.opticalSize(
|
||||
from: 78,
|
||||
to: 8,
|
||||
),
|
||||
WonkyAnimPalette.opticalSize(from: 78, to: 8),
|
||||
],
|
||||
),
|
||||
),
|
||||
@@ -95,12 +86,7 @@ class _PageOpticalSizeState extends SinglePageState {
|
||||
text: 'r',
|
||||
size: widget.pageConfig.wonkyCharSmallSize,
|
||||
baseRotation: -0.15 * pi,
|
||||
animationSettings: [
|
||||
WonkyAnimPalette.opticalSize(
|
||||
from: 32,
|
||||
to: 106,
|
||||
)
|
||||
],
|
||||
animationSettings: [WonkyAnimPalette.opticalSize(from: 32, to: 106)],
|
||||
),
|
||||
),
|
||||
Positioned(
|
||||
@@ -111,12 +97,7 @@ class _PageOpticalSizeState extends SinglePageState {
|
||||
size: widget.pageConfig.wonkyCharLargeSize,
|
||||
baseRotation: -0.15 * pi,
|
||||
animDurationMillis: 5000,
|
||||
animationSettings: [
|
||||
WonkyAnimPalette.opticalSize(
|
||||
from: 70,
|
||||
to: 144,
|
||||
)
|
||||
],
|
||||
animationSettings: [WonkyAnimPalette.opticalSize(from: 70, to: 144)],
|
||||
),
|
||||
),
|
||||
// lower half --------------------------------------
|
||||
@@ -127,12 +108,7 @@ class _PageOpticalSizeState extends SinglePageState {
|
||||
text: 'i',
|
||||
size: widget.pageConfig.wonkyCharLargeSize,
|
||||
baseRotation: -0.04 * pi,
|
||||
animationSettings: [
|
||||
WonkyAnimPalette.opticalSize(
|
||||
from: 40,
|
||||
to: 8,
|
||||
),
|
||||
],
|
||||
animationSettings: [WonkyAnimPalette.opticalSize(from: 40, to: 8)],
|
||||
),
|
||||
),
|
||||
Positioned(
|
||||
@@ -142,12 +118,7 @@ class _PageOpticalSizeState extends SinglePageState {
|
||||
text: 'Z',
|
||||
size: widget.pageConfig.wonkyCharSmallSize,
|
||||
baseRotation: -0.15 * pi,
|
||||
animationSettings: [
|
||||
WonkyAnimPalette.opticalSize(
|
||||
from: 8,
|
||||
to: 60,
|
||||
),
|
||||
],
|
||||
animationSettings: [WonkyAnimPalette.opticalSize(from: 8, to: 60)],
|
||||
),
|
||||
),
|
||||
Positioned(
|
||||
@@ -159,14 +130,8 @@ class _PageOpticalSizeState extends SinglePageState {
|
||||
baseRotation: 0.15 * pi,
|
||||
animDurationMillis: 12000,
|
||||
animationSettings: [
|
||||
WonkyAnimPalette.opticalSize(
|
||||
from: 80,
|
||||
to: 20,
|
||||
),
|
||||
WonkyAnimPalette.rotation(
|
||||
from: -0.01 * pi,
|
||||
to: 0.01 * pi,
|
||||
),
|
||||
WonkyAnimPalette.opticalSize(from: 80, to: 20),
|
||||
WonkyAnimPalette.rotation(from: -0.01 * pi, to: 0.01 * pi),
|
||||
],
|
||||
),
|
||||
),
|
||||
@@ -182,15 +147,16 @@ class _PageOpticalSizeState extends SinglePageState {
|
||||
shader: Shader.wavy,
|
||||
shaderDuration: 5000,
|
||||
tileShadedString: 'Z',
|
||||
tileShadedStringPadding:
|
||||
EdgeInsets.only(bottom: 0.349 * widget.pageConfig.puzzleSize),
|
||||
tileShadedStringPadding: EdgeInsets.only(
|
||||
bottom: 0.349 * widget.pageConfig.puzzleSize,
|
||||
),
|
||||
tileScaleModifier: 2.6,
|
||||
tileShadedStringSize: 2.79 * widget.pageConfig.puzzleSize,
|
||||
tileShadedStringAnimDuration: 3000,
|
||||
tileShadedStringAnimSettings: [
|
||||
WonkyAnimPalette.weight(from: 1000, to: 1000),
|
||||
WonkyAnimPalette.width(from: 125, to: 125),
|
||||
WonkyAnimPalette.opticalSize(from: 8, to: 144)
|
||||
WonkyAnimPalette.opticalSize(from: 8, to: 144),
|
||||
],
|
||||
);
|
||||
}
|
||||
|
||||
@@ -11,10 +11,7 @@ import '../page_content/pages_flow.dart';
|
||||
import '../styles.dart';
|
||||
|
||||
class PageWeight extends SinglePage {
|
||||
const PageWeight({
|
||||
super.key,
|
||||
required super.pageConfig,
|
||||
});
|
||||
const PageWeight({super.key, required super.pageConfig});
|
||||
|
||||
@override
|
||||
State<SinglePage> createState() => _PageWeightState();
|
||||
@@ -88,12 +85,7 @@ class _PageWeightState extends SinglePageState {
|
||||
size: widget.pageConfig.wonkyCharLargeSize,
|
||||
baseRotation: -0.15 * pi,
|
||||
animDurationMillis: 5000,
|
||||
animationSettings: [
|
||||
WonkyAnimPalette.weight(
|
||||
from: 200,
|
||||
to: 500,
|
||||
),
|
||||
],
|
||||
animationSettings: [WonkyAnimPalette.weight(from: 200, to: 500)],
|
||||
),
|
||||
),
|
||||
Positioned(
|
||||
@@ -103,12 +95,7 @@ class _PageWeightState extends SinglePageState {
|
||||
text: '*',
|
||||
size: widget.pageConfig.wonkyCharSmallSize,
|
||||
baseRotation: -0.15 * pi,
|
||||
animationSettings: [
|
||||
WonkyAnimPalette.weight(
|
||||
from: 100,
|
||||
to: 400,
|
||||
),
|
||||
],
|
||||
animationSettings: [WonkyAnimPalette.weight(from: 100, to: 400)],
|
||||
),
|
||||
),
|
||||
// lower half --------------------------------------
|
||||
@@ -120,12 +107,7 @@ class _PageWeightState extends SinglePageState {
|
||||
size: widget.pageConfig.wonkyCharLargeSize,
|
||||
baseRotation: -0.15 * pi,
|
||||
animDurationMillis: 7000,
|
||||
animationSettings: [
|
||||
WonkyAnimPalette.weight(
|
||||
from: 1000,
|
||||
to: 700,
|
||||
),
|
||||
],
|
||||
animationSettings: [WonkyAnimPalette.weight(from: 1000, to: 700)],
|
||||
),
|
||||
),
|
||||
Positioned(
|
||||
@@ -136,12 +118,7 @@ class _PageWeightState extends SinglePageState {
|
||||
size: widget.pageConfig.wonkyCharSmallSize,
|
||||
baseRotation: -0.15 * pi,
|
||||
animDurationMillis: 4000,
|
||||
animationSettings: [
|
||||
WonkyAnimPalette.weight(
|
||||
from: 100,
|
||||
to: 200,
|
||||
),
|
||||
],
|
||||
animationSettings: [WonkyAnimPalette.weight(from: 100, to: 200)],
|
||||
),
|
||||
),
|
||||
Positioned(
|
||||
@@ -152,12 +129,7 @@ class _PageWeightState extends SinglePageState {
|
||||
size: widget.pageConfig.wonkyCharLargeSize,
|
||||
baseRotation: -1.15 * pi,
|
||||
animDurationMillis: 2000,
|
||||
animationSettings: [
|
||||
WonkyAnimPalette.weight(
|
||||
from: 700,
|
||||
to: 900,
|
||||
),
|
||||
],
|
||||
animationSettings: [WonkyAnimPalette.weight(from: 700, to: 900)],
|
||||
),
|
||||
),
|
||||
];
|
||||
@@ -173,8 +145,9 @@ class _PageWeightState extends SinglePageState {
|
||||
shaderDuration: 3000,
|
||||
tileShadedString: 'W',
|
||||
tileShadedStringPadding: EdgeInsets.only(
|
||||
left: 0.698 * widget.pageConfig.puzzleSize,
|
||||
right: 0.698 * widget.pageConfig.puzzleSize),
|
||||
left: 0.698 * widget.pageConfig.puzzleSize,
|
||||
right: 0.698 * widget.pageConfig.puzzleSize,
|
||||
),
|
||||
tileShadedStringSize: 2.79 * widget.pageConfig.puzzleSize,
|
||||
tileScaleModifier: 2.4,
|
||||
tileShadedStringAnimDuration: 1000,
|
||||
|
||||
@@ -11,10 +11,7 @@ import '../page_content/pages_flow.dart';
|
||||
import '../styles.dart';
|
||||
|
||||
class PageWidth extends SinglePage {
|
||||
const PageWidth({
|
||||
super.key,
|
||||
required super.pageConfig,
|
||||
});
|
||||
const PageWidth({super.key, required super.pageConfig});
|
||||
@override
|
||||
State<SinglePage> createState() => _PageWidthState();
|
||||
}
|
||||
@@ -56,10 +53,7 @@ class _PageWidthState extends SinglePageState {
|
||||
from: PageConfig.baseWeight,
|
||||
to: PageConfig.baseWeight,
|
||||
),
|
||||
WonkyAnimPalette.width(
|
||||
from: 120,
|
||||
to: 125,
|
||||
)
|
||||
WonkyAnimPalette.width(from: 120, to: 125),
|
||||
],
|
||||
),
|
||||
),
|
||||
@@ -77,19 +71,9 @@ class _PageWidthState extends SinglePageState {
|
||||
to: PageConfig.baseWeight,
|
||||
curve: Curves.easeInOut,
|
||||
),
|
||||
WonkyAnimPalette.width(
|
||||
from: 70,
|
||||
to: 50,
|
||||
),
|
||||
WonkyAnimPalette.offsetY(
|
||||
from: -6,
|
||||
to: 2,
|
||||
curve: Curves.easeInOut,
|
||||
),
|
||||
WonkyAnimPalette.rotation(
|
||||
from: -0.04 * pi,
|
||||
to: 0.005 * pi,
|
||||
),
|
||||
WonkyAnimPalette.width(from: 70, to: 50),
|
||||
WonkyAnimPalette.offsetY(from: -6, to: 2, curve: Curves.easeInOut),
|
||||
WonkyAnimPalette.rotation(from: -0.04 * pi, to: 0.005 * pi),
|
||||
],
|
||||
),
|
||||
),
|
||||
@@ -102,10 +86,7 @@ class _PageWidthState extends SinglePageState {
|
||||
baseRotation: 0.15 * pi,
|
||||
animDurationMillis: 3200,
|
||||
animationSettings: [
|
||||
WonkyAnimPalette.width(
|
||||
from: 120,
|
||||
to: 125,
|
||||
),
|
||||
WonkyAnimPalette.width(from: 120, to: 125),
|
||||
WonkyAnimPalette.weight(
|
||||
from: PageConfig.baseWeight,
|
||||
to: PageConfig.baseWeight,
|
||||
@@ -128,10 +109,7 @@ class _PageWidthState extends SinglePageState {
|
||||
from: PageConfig.baseWeight,
|
||||
to: PageConfig.baseWeight,
|
||||
),
|
||||
WonkyAnimPalette.width(
|
||||
from: 75,
|
||||
to: 50,
|
||||
),
|
||||
WonkyAnimPalette.width(from: 75, to: 50),
|
||||
],
|
||||
),
|
||||
),
|
||||
@@ -147,10 +125,7 @@ class _PageWidthState extends SinglePageState {
|
||||
from: PageConfig.baseWeight,
|
||||
to: PageConfig.baseWeight,
|
||||
),
|
||||
WonkyAnimPalette.width(
|
||||
from: 90,
|
||||
to: 115,
|
||||
)
|
||||
WonkyAnimPalette.width(from: 90, to: 115),
|
||||
],
|
||||
),
|
||||
),
|
||||
@@ -167,12 +142,7 @@ class _PageWidthState extends SinglePageState {
|
||||
from: PageConfig.baseWeight,
|
||||
to: PageConfig.baseWeight,
|
||||
),
|
||||
WonkyAnimPalette.width(
|
||||
from: 125,
|
||||
to: 90,
|
||||
startAt: 0.3,
|
||||
endAt: 0.7,
|
||||
),
|
||||
WonkyAnimPalette.width(from: 125, to: 90, startAt: 0.3, endAt: 0.7),
|
||||
],
|
||||
),
|
||||
),
|
||||
@@ -188,10 +158,7 @@ class _PageWidthState extends SinglePageState {
|
||||
from: PageConfig.baseWeight,
|
||||
to: PageConfig.baseWeight,
|
||||
),
|
||||
WonkyAnimPalette.width(
|
||||
from: 110,
|
||||
to: 60,
|
||||
)
|
||||
WonkyAnimPalette.width(from: 110, to: 60),
|
||||
],
|
||||
),
|
||||
),
|
||||
@@ -208,8 +175,9 @@ class _PageWidthState extends SinglePageState {
|
||||
shaderDuration: 2000,
|
||||
tileShadedString: 'S',
|
||||
tileShadedStringPadding: EdgeInsets.only(
|
||||
left: 0.349 * widget.pageConfig.puzzleSize,
|
||||
right: 0.349 * widget.pageConfig.puzzleSize),
|
||||
left: 0.349 * widget.pageConfig.puzzleSize,
|
||||
right: 0.349 * widget.pageConfig.puzzleSize,
|
||||
),
|
||||
tileShadedStringSize: 3.256 * widget.pageConfig.puzzleSize,
|
||||
tileScaleModifier: 2.34,
|
||||
tileShadedStringAnimDuration: 2000,
|
||||
|
||||
@@ -47,24 +47,12 @@ class _PagesFlowState extends State<PagesFlow> {
|
||||
physics: const NeverScrollableScrollPhysics(),
|
||||
scrollDirection: Axis.vertical,
|
||||
children: [
|
||||
PageNarrativePre(
|
||||
pageConfig: pageConfig,
|
||||
),
|
||||
PageWeight(
|
||||
pageConfig: pageConfig,
|
||||
),
|
||||
PageAscenderDescender(
|
||||
pageConfig: pageConfig,
|
||||
),
|
||||
PageOpticalSize(
|
||||
pageConfig: pageConfig,
|
||||
),
|
||||
PageWidth(
|
||||
pageConfig: pageConfig,
|
||||
),
|
||||
PageNarrativePost(
|
||||
pageConfig: pageConfig,
|
||||
),
|
||||
PageNarrativePre(pageConfig: pageConfig),
|
||||
PageWeight(pageConfig: pageConfig),
|
||||
PageAscenderDescender(pageConfig: pageConfig),
|
||||
PageOpticalSize(pageConfig: pageConfig),
|
||||
PageWidth(pageConfig: pageConfig),
|
||||
PageNarrativePost(pageConfig: pageConfig),
|
||||
const WallpapersFlow(),
|
||||
],
|
||||
);
|
||||
@@ -94,10 +82,7 @@ class PageConfig {
|
||||
|
||||
class SinglePage extends StatefulWidget {
|
||||
final PageConfig pageConfig;
|
||||
const SinglePage({
|
||||
super.key,
|
||||
required this.pageConfig,
|
||||
});
|
||||
const SinglePage({super.key, required this.pageConfig});
|
||||
|
||||
@override
|
||||
State<SinglePage> createState() => SinglePageState();
|
||||
@@ -113,10 +98,7 @@ class SinglePageState extends State<SinglePage> with TickerProviderStateMixin {
|
||||
}
|
||||
|
||||
Widget createTopicIntro() {
|
||||
return LightboxedPanel(
|
||||
pageConfig: widget.pageConfig,
|
||||
content: const [],
|
||||
);
|
||||
return LightboxedPanel(pageConfig: widget.pageConfig, content: const []);
|
||||
}
|
||||
|
||||
@override
|
||||
@@ -125,9 +107,7 @@ class SinglePageState extends State<SinglePage> with TickerProviderStateMixin {
|
||||
c.add(createPuzzle());
|
||||
c += buildWonkyChars();
|
||||
c.add(createTopicIntro());
|
||||
return Stack(
|
||||
children: c,
|
||||
);
|
||||
return Stack(children: c);
|
||||
}
|
||||
|
||||
void puzzleDone() {}
|
||||
@@ -135,10 +115,7 @@ class SinglePageState extends State<SinglePage> with TickerProviderStateMixin {
|
||||
|
||||
class NarrativePage extends StatefulWidget {
|
||||
final PageConfig pageConfig;
|
||||
const NarrativePage({
|
||||
super.key,
|
||||
required this.pageConfig,
|
||||
});
|
||||
const NarrativePage({super.key, required this.pageConfig});
|
||||
|
||||
@override
|
||||
State<NarrativePage> createState() => NarrativePageState();
|
||||
@@ -154,8 +131,9 @@ class NarrativePageState extends State<NarrativePage>
|
||||
setState(() {
|
||||
if (panelIndex == panels.length - 1) {
|
||||
widget.pageConfig.pageController.nextPage(
|
||||
duration:
|
||||
const Duration(milliseconds: PagesFlow.pageScrollDuration),
|
||||
duration: const Duration(
|
||||
milliseconds: PagesFlow.pageScrollDuration,
|
||||
),
|
||||
curve: Curves.easeOut,
|
||||
);
|
||||
} else {
|
||||
|
||||
@@ -18,18 +18,18 @@ class _WallpapersFlowState extends State<WallpapersFlow> {
|
||||
|
||||
@override
|
||||
void initState() {
|
||||
LicenseRegistry.addLicense(() => Stream<LicenseEntry>.value(
|
||||
LicenseEntryWithLineBreaks(
|
||||
<String>['roboto_font'],
|
||||
robotoLicense,
|
||||
),
|
||||
));
|
||||
LicenseRegistry.addLicense(() => Stream<LicenseEntry>.value(
|
||||
LicenseEntryWithLineBreaks(
|
||||
<String>['amstelvar_font'],
|
||||
amstelvarLicense,
|
||||
),
|
||||
));
|
||||
LicenseRegistry.addLicense(
|
||||
() => Stream<LicenseEntry>.value(
|
||||
LicenseEntryWithLineBreaks(<String>['roboto_font'], robotoLicense),
|
||||
),
|
||||
);
|
||||
LicenseRegistry.addLicense(
|
||||
() => Stream<LicenseEntry>.value(
|
||||
LicenseEntryWithLineBreaks(<String>[
|
||||
'amstelvar_font',
|
||||
], amstelvarLicense),
|
||||
),
|
||||
);
|
||||
super.initState();
|
||||
}
|
||||
|
||||
@@ -45,9 +45,7 @@ class _WallpapersFlowState extends State<WallpapersFlow> {
|
||||
},
|
||||
children: const [
|
||||
DecoratedBox(
|
||||
decoration: BoxDecoration(
|
||||
color: Colors.black,
|
||||
),
|
||||
decoration: BoxDecoration(color: Colors.black),
|
||||
child: Center(
|
||||
child: Image(
|
||||
image: AssetImage('assets/images/wallpaper3.png'),
|
||||
@@ -56,9 +54,7 @@ class _WallpapersFlowState extends State<WallpapersFlow> {
|
||||
),
|
||||
),
|
||||
DecoratedBox(
|
||||
decoration: BoxDecoration(
|
||||
color: Colors.black,
|
||||
),
|
||||
decoration: BoxDecoration(color: Colors.black),
|
||||
child: Center(
|
||||
child: Image(
|
||||
image: AssetImage('assets/images/wallpaper1.png'),
|
||||
@@ -67,9 +63,7 @@ class _WallpapersFlowState extends State<WallpapersFlow> {
|
||||
),
|
||||
),
|
||||
DecoratedBox(
|
||||
decoration: BoxDecoration(
|
||||
color: Colors.black,
|
||||
),
|
||||
decoration: BoxDecoration(color: Colors.black),
|
||||
child: Center(
|
||||
child: Image(
|
||||
image: AssetImage('assets/images/wallpaper2.png'),
|
||||
@@ -107,9 +101,10 @@ class _WallpapersFlowState extends State<WallpapersFlow> {
|
||||
List<Widget> _buildScrollDots() {
|
||||
List<Widget> dots = [];
|
||||
for (int i = 0; i < numPages; i++) {
|
||||
Color dotColor = i == pageNum
|
||||
? const Color.fromARGB(255, 255, 255, 255)
|
||||
: const Color.fromARGB(255, 105, 105, 105);
|
||||
Color dotColor =
|
||||
i == pageNum
|
||||
? const Color.fromARGB(255, 255, 255, 255)
|
||||
: const Color.fromARGB(255, 105, 105, 105);
|
||||
Widget d = Container(
|
||||
width: 16,
|
||||
height: 16,
|
||||
|
||||
Reference in New Issue
Block a user