This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import 'package:flutter/material.dart'; | |
import 'package:flutter/physics.dart'; | |
void main() => runApp(MaterialApp(home: GravityDemo())); | |
class GravityDemo extends StatelessWidget { | |
@override | |
Widget build(BuildContext context) { | |
return MaterialApp(home: Scaffold(body: GravitySimulationDemo())); | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import 'package:flutter/material.dart'; | |
void main() { | |
runApp(const MaterialApp(home: FirstPage())); | |
} | |
class FirstPage extends StatelessWidget { | |
const FirstPage({super.key}); | |
@override |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import 'dart:math' as math; | |
import 'package:flutter/material.dart'; | |
import 'package:flutter/scheduler.dart' show timeDilation; | |
void main() => runApp(const MaterialApp(home: RadialExpansionDemo())); | |
class Photo extends StatelessWidget { | |
const Photo({super.key, required this.color, this.onTap}); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import 'package:flutter/material.dart'; | |
void main() => runApp(DemoApp()); | |
class DemoApp extends StatelessWidget { | |
@override | |
Widget build(BuildContext context) { | |
return MaterialApp( | |
home: AnimatedListDemo(), | |
debugShowCheckedModeBanner: false, |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// The expectations are: | |
// 1. When pressing "Shuffle Data", the list shuffles but each | |
// item preservers their color | |
// 2. When pressing the refresh icon on each item, the color of | |
// that item must change, but the others remain the same | |
import 'package:flutter/material.dart'; | |
import 'dart:math'; | |
void main() { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import 'package:flutter/material.dart'; | |
void main() => runApp(MyApp()); | |
class MyApp extends StatelessWidget { | |
@override | |
Widget build(BuildContext context) { | |
return MaterialApp(home: Home()); | |
} | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Questions: | |
// | |
// 1. In the `BooksListPage`, replace the body of the `Scaffold` with a | |
// `ListView` that displays each one of the books injected in the constructor | |
// | |
// 2. In the new `ListView` created, add the ability on each item to navigate | |
// to `BookDetailsPage` when the item is pressed. | |
// | |
// 3. Modify `BookDetailsPage` to receive a single `Book` as an argument, and | |
// replace the different widgets with the injected `Book` properties. |