├── .fvm ├── flutter_sdk └── fvm_config.json ├── ios ├── Runner │ ├── Runner-Bridging-Header.h │ ├── Assets.xcassets │ │ ├── LaunchImage.imageset │ │ │ ├── LaunchImage.png │ │ │ ├── LaunchImage@2x.png │ │ │ ├── LaunchImage@3x.png │ │ │ ├── README.md │ │ │ └── Contents.json │ │ └── AppIcon.appiconset │ │ │ ├── Icon-App-20x20@1x.png │ │ │ ├── Icon-App-20x20@2x.png │ │ │ ├── Icon-App-20x20@3x.png │ │ │ ├── Icon-App-29x29@1x.png │ │ │ ├── Icon-App-29x29@2x.png │ │ │ ├── Icon-App-29x29@3x.png │ │ │ ├── Icon-App-40x40@1x.png │ │ │ ├── Icon-App-40x40@2x.png │ │ │ ├── Icon-App-40x40@3x.png │ │ │ ├── Icon-App-60x60@2x.png │ │ │ ├── Icon-App-60x60@3x.png │ │ │ ├── Icon-App-76x76@1x.png │ │ │ ├── Icon-App-76x76@2x.png │ │ │ ├── Icon-App-1024x1024@1x.png │ │ │ ├── Icon-App-83.5x83.5@2x.png │ │ │ └── Contents.json │ ├── AppDelegate.swift │ ├── Base.lproj │ │ ├── Main.storyboard │ │ └── LaunchScreen.storyboard │ └── Info.plist ├── Flutter │ ├── Debug.xcconfig │ ├── Release.xcconfig │ └── AppFrameworkInfo.plist ├── Runner.xcworkspace │ ├── contents.xcworkspacedata │ └── xcshareddata │ │ ├── WorkspaceSettings.xcsettings │ │ └── IDEWorkspaceChecks.plist ├── Runner.xcodeproj │ ├── project.xcworkspace │ │ ├── contents.xcworkspacedata │ │ └── xcshareddata │ │ │ ├── WorkspaceSettings.xcsettings │ │ │ └── IDEWorkspaceChecks.plist │ ├── xcshareddata │ │ └── xcschemes │ │ │ └── Runner.xcscheme │ └── project.pbxproj ├── .gitignore └── Podfile ├── images ├── camel.png ├── sand.png ├── sky.png ├── image0.jpg ├── image1.jpg ├── image2.jpg ├── image3.jpg ├── image4.jpg ├── image5.jpg ├── pharaon.png └── pyramid.png ├── web ├── favicon.png ├── icons │ ├── Icon-192.png │ └── Icon-512.png ├── manifest.json └── index.html ├── fonts ├── OPTIDeligne-Normal.otf └── Ibarra_Real_Nova │ ├── IbarraRealNova-Bold.ttf │ ├── IbarraRealNova-Italic.ttf │ ├── IbarraRealNova-Regular.ttf │ ├── IbarraRealNova-SemiBold.ttf │ ├── IbarraRealNova-BoldItalic.ttf │ ├── IbarraRealNova-SemiBoldItalic.ttf │ └── OFL.txt ├── android ├── gradle.properties ├── app │ ├── src │ │ ├── main │ │ │ ├── res │ │ │ │ ├── mipmap-hdpi │ │ │ │ │ └── ic_launcher.png │ │ │ │ ├── mipmap-mdpi │ │ │ │ │ └── ic_launcher.png │ │ │ │ ├── mipmap-xhdpi │ │ │ │ │ └── ic_launcher.png │ │ │ │ ├── mipmap-xxhdpi │ │ │ │ │ └── ic_launcher.png │ │ │ │ ├── mipmap-xxxhdpi │ │ │ │ │ └── ic_launcher.png │ │ │ │ ├── drawable │ │ │ │ │ └── launch_background.xml │ │ │ │ ├── values │ │ │ │ │ └── styles.xml │ │ │ │ └── values-night │ │ │ │ │ └── styles.xml │ │ │ ├── kotlin │ │ │ │ └── com │ │ │ │ │ └── example │ │ │ │ │ └── scroll_to_perfection │ │ │ │ │ └── MainActivity.kt │ │ │ └── AndroidManifest.xml │ │ ├── debug │ │ │ └── AndroidManifest.xml │ │ └── profile │ │ │ └── AndroidManifest.xml │ └── build.gradle ├── gradle │ └── wrapper │ │ └── gradle-wrapper.properties ├── .gitignore ├── settings.gradle └── build.gradle ├── .metadata ├── README.md ├── .gitignore ├── .github └── workflows │ └── gh-pages.yaml ├── test └── widget_test.dart ├── lib ├── egipt │ ├── main_text.dart │ ├── page2.dart │ ├── page1.dart │ ├── page3.dart │ └── egypt.dart ├── whatsapp_images.dart ├── main.dart ├── vgv.dart ├── zoom_in.dart ├── cuberto.dart └── blocked_animation.dart ├── pubspec.yaml └── pubspec.lock /.fvm/flutter_sdk: -------------------------------------------------------------------------------- 1 | /Users/mszalek/fvm/versions/beta -------------------------------------------------------------------------------- /.fvm/fvm_config.json: -------------------------------------------------------------------------------- 1 | { 2 | "flutterSdkVersion": "beta" 3 | } -------------------------------------------------------------------------------- /ios/Runner/Runner-Bridging-Header.h: -------------------------------------------------------------------------------- 1 | #import "GeneratedPluginRegistrant.h" 2 | -------------------------------------------------------------------------------- /images/camel.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MarcinusX/scroll_to_perfection/HEAD/images/camel.png -------------------------------------------------------------------------------- /images/sand.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MarcinusX/scroll_to_perfection/HEAD/images/sand.png -------------------------------------------------------------------------------- /images/sky.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MarcinusX/scroll_to_perfection/HEAD/images/sky.png -------------------------------------------------------------------------------- /web/favicon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MarcinusX/scroll_to_perfection/HEAD/web/favicon.png -------------------------------------------------------------------------------- /images/image0.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MarcinusX/scroll_to_perfection/HEAD/images/image0.jpg -------------------------------------------------------------------------------- /images/image1.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MarcinusX/scroll_to_perfection/HEAD/images/image1.jpg -------------------------------------------------------------------------------- /images/image2.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MarcinusX/scroll_to_perfection/HEAD/images/image2.jpg -------------------------------------------------------------------------------- /images/image3.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MarcinusX/scroll_to_perfection/HEAD/images/image3.jpg -------------------------------------------------------------------------------- /images/image4.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MarcinusX/scroll_to_perfection/HEAD/images/image4.jpg -------------------------------------------------------------------------------- /images/image5.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MarcinusX/scroll_to_perfection/HEAD/images/image5.jpg -------------------------------------------------------------------------------- /images/pharaon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MarcinusX/scroll_to_perfection/HEAD/images/pharaon.png -------------------------------------------------------------------------------- /images/pyramid.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MarcinusX/scroll_to_perfection/HEAD/images/pyramid.png -------------------------------------------------------------------------------- /web/icons/Icon-192.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MarcinusX/scroll_to_perfection/HEAD/web/icons/Icon-192.png -------------------------------------------------------------------------------- /web/icons/Icon-512.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MarcinusX/scroll_to_perfection/HEAD/web/icons/Icon-512.png -------------------------------------------------------------------------------- /fonts/OPTIDeligne-Normal.otf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MarcinusX/scroll_to_perfection/HEAD/fonts/OPTIDeligne-Normal.otf -------------------------------------------------------------------------------- /ios/Flutter/Debug.xcconfig: -------------------------------------------------------------------------------- 1 | #include "Pods/Target Support Files/Pods-Runner/Pods-Runner.debug.xcconfig" 2 | #include "Generated.xcconfig" 3 | -------------------------------------------------------------------------------- /android/gradle.properties: -------------------------------------------------------------------------------- 1 | org.gradle.jvmargs=-Xmx1536M 2 | android.useAndroidX=true 3 | android.enableJetifier=true 4 | android.enableR8=true 5 | -------------------------------------------------------------------------------- /ios/Flutter/Release.xcconfig: -------------------------------------------------------------------------------- 1 | #include "Pods/Target Support Files/Pods-Runner/Pods-Runner.release.xcconfig" 2 | #include "Generated.xcconfig" 3 | -------------------------------------------------------------------------------- /fonts/Ibarra_Real_Nova/IbarraRealNova-Bold.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MarcinusX/scroll_to_perfection/HEAD/fonts/Ibarra_Real_Nova/IbarraRealNova-Bold.ttf -------------------------------------------------------------------------------- /fonts/Ibarra_Real_Nova/IbarraRealNova-Italic.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MarcinusX/scroll_to_perfection/HEAD/fonts/Ibarra_Real_Nova/IbarraRealNova-Italic.ttf -------------------------------------------------------------------------------- /fonts/Ibarra_Real_Nova/IbarraRealNova-Regular.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MarcinusX/scroll_to_perfection/HEAD/fonts/Ibarra_Real_Nova/IbarraRealNova-Regular.ttf -------------------------------------------------------------------------------- /fonts/Ibarra_Real_Nova/IbarraRealNova-SemiBold.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MarcinusX/scroll_to_perfection/HEAD/fonts/Ibarra_Real_Nova/IbarraRealNova-SemiBold.ttf -------------------------------------------------------------------------------- /android/app/src/main/res/mipmap-hdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MarcinusX/scroll_to_perfection/HEAD/android/app/src/main/res/mipmap-hdpi/ic_launcher.png -------------------------------------------------------------------------------- /android/app/src/main/res/mipmap-mdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MarcinusX/scroll_to_perfection/HEAD/android/app/src/main/res/mipmap-mdpi/ic_launcher.png -------------------------------------------------------------------------------- /android/app/src/main/res/mipmap-xhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MarcinusX/scroll_to_perfection/HEAD/android/app/src/main/res/mipmap-xhdpi/ic_launcher.png -------------------------------------------------------------------------------- /fonts/Ibarra_Real_Nova/IbarraRealNova-BoldItalic.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MarcinusX/scroll_to_perfection/HEAD/fonts/Ibarra_Real_Nova/IbarraRealNova-BoldItalic.ttf -------------------------------------------------------------------------------- /android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MarcinusX/scroll_to_perfection/HEAD/android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png -------------------------------------------------------------------------------- /android/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MarcinusX/scroll_to_perfection/HEAD/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png -------------------------------------------------------------------------------- /fonts/Ibarra_Real_Nova/IbarraRealNova-SemiBoldItalic.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MarcinusX/scroll_to_perfection/HEAD/fonts/Ibarra_Real_Nova/IbarraRealNova-SemiBoldItalic.ttf -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MarcinusX/scroll_to_perfection/HEAD/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage.png -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MarcinusX/scroll_to_perfection/HEAD/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@2x.png -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@3x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MarcinusX/scroll_to_perfection/HEAD/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@3x.png -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@1x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MarcinusX/scroll_to_perfection/HEAD/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@1x.png -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MarcinusX/scroll_to_perfection/HEAD/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@2x.png -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@3x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MarcinusX/scroll_to_perfection/HEAD/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@3x.png -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@1x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MarcinusX/scroll_to_perfection/HEAD/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@1x.png -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MarcinusX/scroll_to_perfection/HEAD/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@2x.png -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@3x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MarcinusX/scroll_to_perfection/HEAD/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@3x.png -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@1x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MarcinusX/scroll_to_perfection/HEAD/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@1x.png -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MarcinusX/scroll_to_perfection/HEAD/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@2x.png -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@3x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MarcinusX/scroll_to_perfection/HEAD/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@3x.png -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MarcinusX/scroll_to_perfection/HEAD/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@2x.png -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@3x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MarcinusX/scroll_to_perfection/HEAD/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@3x.png -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@1x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MarcinusX/scroll_to_perfection/HEAD/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@1x.png -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MarcinusX/scroll_to_perfection/HEAD/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@2x.png -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-1024x1024@1x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MarcinusX/scroll_to_perfection/HEAD/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-1024x1024@1x.png -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-83.5x83.5@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MarcinusX/scroll_to_perfection/HEAD/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-83.5x83.5@2x.png -------------------------------------------------------------------------------- /ios/Runner.xcworkspace/contents.xcworkspacedata: -------------------------------------------------------------------------------- 1 | 2 | 4 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /android/app/src/main/kotlin/com/example/scroll_to_perfection/MainActivity.kt: -------------------------------------------------------------------------------- 1 | package com.example.scroll_to_perfection 2 | 3 | import io.flutter.embedding.android.FlutterActivity 4 | 5 | class MainActivity: FlutterActivity() { 6 | } 7 | -------------------------------------------------------------------------------- /ios/Runner.xcodeproj/project.xcworkspace/contents.xcworkspacedata: -------------------------------------------------------------------------------- 1 | 2 | 4 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /android/gradle/wrapper/gradle-wrapper.properties: -------------------------------------------------------------------------------- 1 | #Fri Jun 23 08:50:38 CEST 2017 2 | distributionBase=GRADLE_USER_HOME 3 | distributionPath=wrapper/dists 4 | zipStoreBase=GRADLE_USER_HOME 5 | zipStorePath=wrapper/dists 6 | distributionUrl=https\://services.gradle.org/distributions/gradle-5.6.2-all.zip 7 | -------------------------------------------------------------------------------- /ios/Runner.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | PreviewsEnabled 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /ios/Runner.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | IDEDidComputeMac32BitWarning 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /android/.gitignore: -------------------------------------------------------------------------------- 1 | gradle-wrapper.jar 2 | /.gradle 3 | /captures/ 4 | /gradlew 5 | /gradlew.bat 6 | /local.properties 7 | GeneratedPluginRegistrant.java 8 | 9 | # Remember to never publicly share your keystore. 10 | # See https://flutter.dev/docs/deployment/android#reference-the-keystore-from-the-app 11 | key.properties 12 | -------------------------------------------------------------------------------- /ios/Runner.xcodeproj/project.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | PreviewsEnabled 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /ios/Runner.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | IDEDidComputeMac32BitWarning 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /.metadata: -------------------------------------------------------------------------------- 1 | # This file tracks properties of this Flutter project. 2 | # Used by Flutter tool to assess capabilities and perform upgrades etc. 3 | # 4 | # This file should be version controlled and should not be manually edited. 5 | 6 | version: 7 | revision: 8874f21e79d7ec66d0457c7ab338348e31b17f1d 8 | channel: stable 9 | 10 | project_type: app 11 | -------------------------------------------------------------------------------- /android/app/src/debug/AndroidManifest.xml: -------------------------------------------------------------------------------- 1 | 3 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /android/app/src/profile/AndroidManifest.xml: -------------------------------------------------------------------------------- 1 | 3 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/LaunchImage.imageset/README.md: -------------------------------------------------------------------------------- 1 | # Launch Screen Assets 2 | 3 | You can customize the launch screen with your own desired assets by replacing the image files in this directory. 4 | 5 | You can also do it by opening your Flutter project's Xcode project with `open ios/Runner.xcworkspace`, selecting `Runner/Assets.xcassets` in the Project Navigator and dropping in the desired images. -------------------------------------------------------------------------------- /ios/Runner/AppDelegate.swift: -------------------------------------------------------------------------------- 1 | import UIKit 2 | import Flutter 3 | 4 | @UIApplicationMain 5 | @objc class AppDelegate: FlutterAppDelegate { 6 | override func application( 7 | _ application: UIApplication, 8 | didFinishLaunchingWithOptions launchOptions: [UIApplication.LaunchOptionsKey: Any]? 9 | ) -> Bool { 10 | GeneratedPluginRegistrant.register(with: self) 11 | return super.application(application, didFinishLaunchingWithOptions: launchOptions) 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /android/settings.gradle: -------------------------------------------------------------------------------- 1 | include ':app' 2 | 3 | def localPropertiesFile = new File(rootProject.projectDir, "local.properties") 4 | def properties = new Properties() 5 | 6 | assert localPropertiesFile.exists() 7 | localPropertiesFile.withReader("UTF-8") { reader -> properties.load(reader) } 8 | 9 | def flutterSdkPath = properties.getProperty("flutter.sdk") 10 | assert flutterSdkPath != null, "flutter.sdk not set in local.properties" 11 | apply from: "$flutterSdkPath/packages/flutter_tools/gradle/app_plugin_loader.gradle" 12 | -------------------------------------------------------------------------------- /android/app/src/main/res/drawable/launch_background.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 12 | 13 | -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/LaunchImage.imageset/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "images" : [ 3 | { 4 | "idiom" : "universal", 5 | "filename" : "LaunchImage.png", 6 | "scale" : "1x" 7 | }, 8 | { 9 | "idiom" : "universal", 10 | "filename" : "LaunchImage@2x.png", 11 | "scale" : "2x" 12 | }, 13 | { 14 | "idiom" : "universal", 15 | "filename" : "LaunchImage@3x.png", 16 | "scale" : "3x" 17 | } 18 | ], 19 | "info" : { 20 | "version" : 1, 21 | "author" : "xcode" 22 | } 23 | } 24 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # scroll_to_perfection 2 | 3 | A new Flutter project. 4 | 5 | ## Getting Started 6 | 7 | This project is a starting point for a Flutter application. 8 | 9 | A few resources to get you started if this is your first Flutter project: 10 | 11 | - [Lab: Write your first Flutter app](https://flutter.dev/docs/get-started/codelab) 12 | - [Cookbook: Useful Flutter samples](https://flutter.dev/docs/cookbook) 13 | 14 | For help getting started with Flutter, view our 15 | [online documentation](https://flutter.dev/docs), which offers tutorials, 16 | samples, guidance on mobile development, and a full API reference. 17 | -------------------------------------------------------------------------------- /ios/.gitignore: -------------------------------------------------------------------------------- 1 | *.mode1v3 2 | *.mode2v3 3 | *.moved-aside 4 | *.pbxuser 5 | *.perspectivev3 6 | **/*sync/ 7 | .sconsign.dblite 8 | .tags* 9 | **/.vagrant/ 10 | **/DerivedData/ 11 | Icon? 12 | **/Pods/ 13 | **/.symlinks/ 14 | profile 15 | xcuserdata 16 | **/.generated/ 17 | Flutter/App.framework 18 | Flutter/Flutter.framework 19 | Flutter/Flutter.podspec 20 | Flutter/Generated.xcconfig 21 | Flutter/app.flx 22 | Flutter/app.zip 23 | Flutter/flutter_assets/ 24 | Flutter/flutter_export_environment.sh 25 | ServiceDefinitions.json 26 | Runner/GeneratedPluginRegistrant.* 27 | 28 | # Exceptions to above rules. 29 | !default.mode1v3 30 | !default.mode2v3 31 | !default.pbxuser 32 | !default.perspectivev3 33 | -------------------------------------------------------------------------------- /web/manifest.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "scroll_to_perfection", 3 | "short_name": "scroll_to_perfection", 4 | "start_url": ".", 5 | "display": "standalone", 6 | "background_color": "#0175C2", 7 | "theme_color": "#0175C2", 8 | "description": "A new Flutter project.", 9 | "orientation": "portrait-primary", 10 | "prefer_related_applications": false, 11 | "icons": [ 12 | { 13 | "src": "icons/Icon-192.png", 14 | "sizes": "192x192", 15 | "type": "image/png" 16 | }, 17 | { 18 | "src": "icons/Icon-512.png", 19 | "sizes": "512x512", 20 | "type": "image/png" 21 | } 22 | ] 23 | } 24 | -------------------------------------------------------------------------------- /android/build.gradle: -------------------------------------------------------------------------------- 1 | buildscript { 2 | ext.kotlin_version = '1.3.50' 3 | repositories { 4 | google() 5 | jcenter() 6 | } 7 | 8 | dependencies { 9 | classpath 'com.android.tools.build:gradle:3.5.0' 10 | classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version" 11 | } 12 | } 13 | 14 | allprojects { 15 | repositories { 16 | google() 17 | jcenter() 18 | } 19 | } 20 | 21 | rootProject.buildDir = '../build' 22 | subprojects { 23 | project.buildDir = "${rootProject.buildDir}/${project.name}" 24 | } 25 | subprojects { 26 | project.evaluationDependsOn(':app') 27 | } 28 | 29 | task clean(type: Delete) { 30 | delete rootProject.buildDir 31 | } 32 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | # Miscellaneous 2 | *.class 3 | *.log 4 | *.pyc 5 | *.swp 6 | .DS_Store 7 | .atom/ 8 | .buildlog/ 9 | .history 10 | .svn/ 11 | 12 | # IntelliJ related 13 | *.iml 14 | *.ipr 15 | *.iws 16 | .idea/ 17 | 18 | # The .vscode folder contains launch configuration and tasks you configure in 19 | # VS Code which you may wish to be included in version control, so this line 20 | # is commented out by default. 21 | #.vscode/ 22 | 23 | # Flutter/Dart/Pub related 24 | **/doc/api/ 25 | **/ios/Flutter/.last_build_id 26 | .dart_tool/ 27 | .flutter-plugins 28 | .flutter-plugins-dependencies 29 | .packages 30 | .pub-cache/ 31 | .pub/ 32 | /build/ 33 | 34 | # Web related 35 | lib/generated_plugin_registrant.dart 36 | 37 | # Symbolication related 38 | app.*.symbols 39 | 40 | # Obfuscation related 41 | app.*.map.json 42 | -------------------------------------------------------------------------------- /ios/Flutter/AppFrameworkInfo.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | CFBundleDevelopmentRegion 6 | $(DEVELOPMENT_LANGUAGE) 7 | CFBundleExecutable 8 | App 9 | CFBundleIdentifier 10 | io.flutter.flutter.app 11 | CFBundleInfoDictionaryVersion 12 | 6.0 13 | CFBundleName 14 | App 15 | CFBundlePackageType 16 | FMWK 17 | CFBundleShortVersionString 18 | 1.0 19 | CFBundleSignature 20 | ???? 21 | CFBundleVersion 22 | 1.0 23 | MinimumOSVersion 24 | 9.0 25 | 26 | 27 | -------------------------------------------------------------------------------- /android/app/src/main/res/values/styles.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 9 | 15 | 18 | 19 | -------------------------------------------------------------------------------- /.github/workflows/gh-pages.yaml: -------------------------------------------------------------------------------- 1 | name: Github Pages 2 | on: 3 | push: 4 | branches: 5 | - master 6 | 7 | jobs: 8 | build: 9 | name: Github Pages 10 | env: 11 | my_secret: ${{secrets.commit_secret}} 12 | runs-on: ubuntu-latest 13 | steps: 14 | - uses: actions/checkout@v1 15 | - uses: subosito/flutter-action@v1.4.0 16 | with: 17 | channel: 'dev' 18 | - run: flutter config --enable-web 19 | - run: flutter pub get 20 | - run: flutter build web --release --dart-define=FLUTTER_WEB_USE_SKIA=true 21 | - run: | 22 | cd build/web 23 | git init 24 | git config --global user.email marcin.szalek1@gmail.com 25 | git config --global user.name MarcinusX 26 | git status 27 | git remote add origin https://${{secrets.commit_secret}}@github.com/MarcinusX/scroll_to_perfection.git 28 | git checkout -b gh-pages 29 | git add --all 30 | git commit -m "github pages CI deploy" 31 | git push origin gh-pages -f -------------------------------------------------------------------------------- /android/app/src/main/res/values-night/styles.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 9 | 15 | 18 | 19 | -------------------------------------------------------------------------------- /test/widget_test.dart: -------------------------------------------------------------------------------- 1 | // This is a basic Flutter widget test. 2 | // 3 | // To perform an interaction with a widget in your test, use the WidgetTester 4 | // utility that Flutter provides. For example, you can send tap and scroll 5 | // gestures. You can also use WidgetTester to find child widgets in the widget 6 | // tree, read text, and verify that the values of widget properties are correct. 7 | 8 | import 'package:flutter/material.dart'; 9 | import 'package:flutter_test/flutter_test.dart'; 10 | 11 | import 'package:scroll_to_perfection/main.dart'; 12 | 13 | void main() { 14 | testWidgets('Counter increments smoke test', (WidgetTester tester) async { 15 | // Build our app and trigger a frame. 16 | await tester.pumpWidget(MyApp()); 17 | 18 | // Verify that our counter starts at 0. 19 | expect(find.text('0'), findsOneWidget); 20 | expect(find.text('1'), findsNothing); 21 | 22 | // Tap the '+' icon and trigger a frame. 23 | await tester.tap(find.byIcon(Icons.add)); 24 | await tester.pump(); 25 | 26 | // Verify that our counter has incremented. 27 | expect(find.text('0'), findsNothing); 28 | expect(find.text('1'), findsOneWidget); 29 | }); 30 | } 31 | -------------------------------------------------------------------------------- /lib/egipt/main_text.dart: -------------------------------------------------------------------------------- 1 | import 'package:flutter/material.dart'; 2 | import 'package:line_icons/line_icons.dart'; 3 | import 'package:scroll_to_perfection/egipt/egypt.dart'; 4 | 5 | class MainText extends StatelessWidget { 6 | @override 7 | Widget build(BuildContext context) { 8 | return Column( 9 | children: [ 10 | Text( 11 | 'THE ANCIENT WORLD', 12 | style: TextStyle(color: backgroundColor), 13 | ), 14 | SizedBox(height: 16), 15 | Container( 16 | height: 1, 17 | width: 64, 18 | color: backgroundColor, 19 | ), 20 | SizedBox(height: 32), 21 | Text( 22 | 'Discover the awe-inspiring\nPyramids of Fize and ancient Egypt\'s', 23 | textAlign: TextAlign.center, 24 | style: TextStyle( 25 | fontSize: MediaQuery.of(context).size.shortestSide > 400 ? 60 : 40, 26 | ), 27 | ), 28 | SizedBox(height: 32), 29 | RotatedBox( 30 | quarterTurns: 2, 31 | child: Icon(LineIcons.angle_double_up, color: Colors.grey), 32 | ), 33 | SizedBox(height: 16), 34 | Text('SCROLL DOWN', style: TextStyle(color: Colors.grey)), 35 | ], 36 | ); 37 | } 38 | } 39 | -------------------------------------------------------------------------------- /ios/Podfile: -------------------------------------------------------------------------------- 1 | # Uncomment this line to define a global platform for your project 2 | # platform :ios, '9.0' 3 | 4 | # CocoaPods analytics sends network stats synchronously affecting flutter build latency. 5 | ENV['COCOAPODS_DISABLE_STATS'] = 'true' 6 | 7 | project 'Runner', { 8 | 'Debug' => :debug, 9 | 'Profile' => :release, 10 | 'Release' => :release, 11 | } 12 | 13 | def flutter_root 14 | generated_xcode_build_settings_path = File.expand_path(File.join('..', 'Flutter', 'Generated.xcconfig'), __FILE__) 15 | unless File.exist?(generated_xcode_build_settings_path) 16 | raise "#{generated_xcode_build_settings_path} must exist. If you're running pod install manually, make sure flutter pub get is executed first" 17 | end 18 | 19 | File.foreach(generated_xcode_build_settings_path) do |line| 20 | matches = line.match(/FLUTTER_ROOT\=(.*)/) 21 | return matches[1].strip if matches 22 | end 23 | raise "FLUTTER_ROOT not found in #{generated_xcode_build_settings_path}. Try deleting Generated.xcconfig, then run flutter pub get" 24 | end 25 | 26 | require File.expand_path(File.join('packages', 'flutter_tools', 'bin', 'podhelper'), flutter_root) 27 | 28 | flutter_ios_podfile_setup 29 | 30 | target 'Runner' do 31 | use_frameworks! 32 | use_modular_headers! 33 | 34 | flutter_install_all_ios_pods File.dirname(File.realpath(__FILE__)) 35 | end 36 | 37 | post_install do |installer| 38 | installer.pods_project.targets.each do |target| 39 | flutter_additional_ios_build_settings(target) 40 | end 41 | end 42 | -------------------------------------------------------------------------------- /ios/Runner/Base.lproj/Main.storyboard: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | -------------------------------------------------------------------------------- /web/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | scroll_to_perfection 30 | 31 | 32 | 33 | 36 | 43 | 44 | 45 | 46 | -------------------------------------------------------------------------------- /ios/Runner/Info.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | CFBundleDevelopmentRegion 6 | $(DEVELOPMENT_LANGUAGE) 7 | CFBundleExecutable 8 | $(EXECUTABLE_NAME) 9 | CFBundleIdentifier 10 | $(PRODUCT_BUNDLE_IDENTIFIER) 11 | CFBundleInfoDictionaryVersion 12 | 6.0 13 | CFBundleName 14 | scroll_to_perfection 15 | CFBundlePackageType 16 | APPL 17 | CFBundleShortVersionString 18 | $(FLUTTER_BUILD_NAME) 19 | CFBundleSignature 20 | ???? 21 | CFBundleVersion 22 | $(FLUTTER_BUILD_NUMBER) 23 | LSRequiresIPhoneOS 24 | 25 | UILaunchStoryboardName 26 | LaunchScreen 27 | UIMainStoryboardFile 28 | Main 29 | UISupportedInterfaceOrientations 30 | 31 | UIInterfaceOrientationPortrait 32 | UIInterfaceOrientationLandscapeLeft 33 | UIInterfaceOrientationLandscapeRight 34 | 35 | UISupportedInterfaceOrientations~ipad 36 | 37 | UIInterfaceOrientationPortrait 38 | UIInterfaceOrientationPortraitUpsideDown 39 | UIInterfaceOrientationLandscapeLeft 40 | UIInterfaceOrientationLandscapeRight 41 | 42 | UIViewControllerBasedStatusBarAppearance 43 | 44 | 45 | 46 | -------------------------------------------------------------------------------- /android/app/build.gradle: -------------------------------------------------------------------------------- 1 | def localProperties = new Properties() 2 | def localPropertiesFile = rootProject.file('local.properties') 3 | if (localPropertiesFile.exists()) { 4 | localPropertiesFile.withReader('UTF-8') { reader -> 5 | localProperties.load(reader) 6 | } 7 | } 8 | 9 | def flutterRoot = localProperties.getProperty('flutter.sdk') 10 | if (flutterRoot == null) { 11 | throw new GradleException("Flutter SDK not found. Define location with flutter.sdk in the local.properties file.") 12 | } 13 | 14 | def flutterVersionCode = localProperties.getProperty('flutter.versionCode') 15 | if (flutterVersionCode == null) { 16 | flutterVersionCode = '1' 17 | } 18 | 19 | def flutterVersionName = localProperties.getProperty('flutter.versionName') 20 | if (flutterVersionName == null) { 21 | flutterVersionName = '1.0' 22 | } 23 | 24 | apply plugin: 'com.android.application' 25 | apply plugin: 'kotlin-android' 26 | apply from: "$flutterRoot/packages/flutter_tools/gradle/flutter.gradle" 27 | 28 | android { 29 | compileSdkVersion 29 30 | 31 | sourceSets { 32 | main.java.srcDirs += 'src/main/kotlin' 33 | } 34 | 35 | lintOptions { 36 | disable 'InvalidPackage' 37 | } 38 | 39 | defaultConfig { 40 | // TODO: Specify your own unique Application ID (https://developer.android.com/studio/build/application-id.html). 41 | applicationId "com.example.scroll_to_perfection" 42 | minSdkVersion 16 43 | targetSdkVersion 29 44 | versionCode flutterVersionCode.toInteger() 45 | versionName flutterVersionName 46 | } 47 | 48 | buildTypes { 49 | release { 50 | // TODO: Add your own signing config for the release build. 51 | // Signing with the debug keys for now, so `flutter run --release` works. 52 | signingConfig signingConfigs.debug 53 | } 54 | } 55 | } 56 | 57 | flutter { 58 | source '../..' 59 | } 60 | 61 | dependencies { 62 | implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlin_version" 63 | } 64 | -------------------------------------------------------------------------------- /lib/whatsapp_images.dart: -------------------------------------------------------------------------------- 1 | import 'package:flutter/gestures.dart'; 2 | import 'package:flutter/material.dart'; 3 | import 'package:flutter/rendering.dart'; 4 | 5 | class WhatsappImages extends StatefulWidget { 6 | @override 7 | _WhatsappImagesState createState() => _WhatsappImagesState(); 8 | } 9 | 10 | class _WhatsappImagesState extends State { 11 | ScrollController scrollController = ScrollController(); 12 | 13 | @override 14 | Widget build(BuildContext context) { 15 | return Scaffold( 16 | appBar: AppBar( 17 | title: Text('Whatsapp Parallax'), 18 | ), 19 | body: ListView.builder( 20 | controller: scrollController, 21 | itemBuilder: (context, index) { 22 | final imagePath = 'images/image${index % 6}.jpg'; 23 | return AnimatedBuilder( 24 | animation: scrollController, 25 | builder: (context, child) => SingleImage( 26 | imagePath: imagePath, 27 | ), 28 | ); 29 | }, 30 | ), 31 | ); 32 | } 33 | } 34 | 35 | class SingleImage extends StatelessWidget { 36 | final String imagePath; 37 | 38 | const SingleImage({Key key, this.imagePath}) : super(key: key); 39 | 40 | @override 41 | Widget build(BuildContext context) { 42 | final renderObject = context.findRenderObject() as RenderBox; 43 | final offsetY = renderObject?.localToGlobal(Offset.zero)?.dy ?? 0; 44 | final deviceHeight = MediaQuery.of(context).size.height; 45 | final relativePosition = offsetY / deviceHeight; 46 | 47 | return Center( 48 | child: Container( 49 | width: 800, 50 | height: 300, 51 | margin: const EdgeInsets.all(16), 52 | decoration: BoxDecoration( 53 | borderRadius: BorderRadius.circular(8), 54 | border: Border.all(color: Colors.black, width: 2), 55 | image: DecorationImage( 56 | fit: BoxFit.cover, 57 | alignment: Alignment(0, relativePosition - 0.5), 58 | image: AssetImage(imagePath), 59 | ), 60 | ), 61 | ), 62 | ); 63 | } 64 | } 65 | -------------------------------------------------------------------------------- /ios/Runner/Base.lproj/LaunchScreen.storyboard: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | -------------------------------------------------------------------------------- /android/app/src/main/AndroidManifest.xml: -------------------------------------------------------------------------------- 1 | 3 | 8 | 12 | 19 | 23 | 27 | 32 | 36 | 37 | 38 | 39 | 40 | 41 | 43 | 46 | 47 | 48 | -------------------------------------------------------------------------------- /lib/main.dart: -------------------------------------------------------------------------------- 1 | import 'package:flutter/material.dart'; 2 | import 'package:font_awesome_flutter/font_awesome_flutter.dart'; 3 | import 'package:scroll_to_perfection/blocked_animation.dart'; 4 | import 'package:scroll_to_perfection/cuberto.dart'; 5 | import 'package:scroll_to_perfection/egipt/egypt.dart'; 6 | import 'package:scroll_to_perfection/vgv.dart'; 7 | import 'package:scroll_to_perfection/whatsapp_images.dart'; 8 | import 'package:scroll_to_perfection/zoom_in.dart'; 9 | import 'package:url_launcher/url_launcher.dart'; 10 | 11 | void main() { 12 | runApp(MyApp()); 13 | } 14 | 15 | class MyApp extends StatelessWidget { 16 | @override 17 | Widget build(BuildContext context) { 18 | return MaterialApp( 19 | routes: { 20 | '/': (_) => HomePage(), 21 | '/whatsapp': (_) => WhatsappImages(), 22 | '/egypt': (_) => EgyptPage(), 23 | '/verygood': (_) => VeryGood(), 24 | '/blockedAnimation': (_) => BlockedAnimation(), 25 | '/zoom_in': (_) => ZoomIn(), 26 | '/cuberto': (_) => Cuberto(), 27 | }, 28 | ); 29 | } 30 | } 31 | 32 | class HomePage extends StatelessWidget { 33 | @override 34 | Widget build(BuildContext context) { 35 | return Scaffold( 36 | appBar: AppBar( 37 | title: Text('Flutter: Scroll to perfection'), 38 | actions: [ 39 | IconButton( 40 | icon: FaIcon(FontAwesomeIcons.github), 41 | onPressed: () => 42 | launch('https://github.com/MarcinusX/scroll_to_perfection'), 43 | ) 44 | ], 45 | ), 46 | body: ListView( 47 | children: [ 48 | DemoOptionButton( 49 | name: 'What\'sApp paralax images', 50 | path: '/whatsapp', 51 | ), 52 | DemoOptionButton( 53 | name: 'Egypt', 54 | path: '/egypt', 55 | ), 56 | DemoOptionButton( 57 | name: 'VeryGood', 58 | path: '/verygood', 59 | ), 60 | DemoOptionButton( 61 | name: 'Blocked animation', 62 | path: '/blockedAnimation', 63 | ), 64 | DemoOptionButton( 65 | name: 'Zoom in', 66 | path: '/zoom_in', 67 | ), 68 | DemoOptionButton( 69 | name: 'Cuberto', 70 | path: '/cuberto', 71 | ), 72 | ], 73 | ), 74 | ); 75 | } 76 | } 77 | 78 | class DemoOptionButton extends StatelessWidget { 79 | final String name; 80 | final String path; 81 | 82 | const DemoOptionButton({Key key, this.name, this.path}) : super(key: key); 83 | 84 | @override 85 | Widget build(BuildContext context) { 86 | return ListTile( 87 | title: Text(name), 88 | onTap: () => Navigator.of(context).pushNamed(path), 89 | ); 90 | } 91 | } 92 | -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/AppIcon.appiconset/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "images" : [ 3 | { 4 | "size" : "20x20", 5 | "idiom" : "iphone", 6 | "filename" : "Icon-App-20x20@2x.png", 7 | "scale" : "2x" 8 | }, 9 | { 10 | "size" : "20x20", 11 | "idiom" : "iphone", 12 | "filename" : "Icon-App-20x20@3x.png", 13 | "scale" : "3x" 14 | }, 15 | { 16 | "size" : "29x29", 17 | "idiom" : "iphone", 18 | "filename" : "Icon-App-29x29@1x.png", 19 | "scale" : "1x" 20 | }, 21 | { 22 | "size" : "29x29", 23 | "idiom" : "iphone", 24 | "filename" : "Icon-App-29x29@2x.png", 25 | "scale" : "2x" 26 | }, 27 | { 28 | "size" : "29x29", 29 | "idiom" : "iphone", 30 | "filename" : "Icon-App-29x29@3x.png", 31 | "scale" : "3x" 32 | }, 33 | { 34 | "size" : "40x40", 35 | "idiom" : "iphone", 36 | "filename" : "Icon-App-40x40@2x.png", 37 | "scale" : "2x" 38 | }, 39 | { 40 | "size" : "40x40", 41 | "idiom" : "iphone", 42 | "filename" : "Icon-App-40x40@3x.png", 43 | "scale" : "3x" 44 | }, 45 | { 46 | "size" : "60x60", 47 | "idiom" : "iphone", 48 | "filename" : "Icon-App-60x60@2x.png", 49 | "scale" : "2x" 50 | }, 51 | { 52 | "size" : "60x60", 53 | "idiom" : "iphone", 54 | "filename" : "Icon-App-60x60@3x.png", 55 | "scale" : "3x" 56 | }, 57 | { 58 | "size" : "20x20", 59 | "idiom" : "ipad", 60 | "filename" : "Icon-App-20x20@1x.png", 61 | "scale" : "1x" 62 | }, 63 | { 64 | "size" : "20x20", 65 | "idiom" : "ipad", 66 | "filename" : "Icon-App-20x20@2x.png", 67 | "scale" : "2x" 68 | }, 69 | { 70 | "size" : "29x29", 71 | "idiom" : "ipad", 72 | "filename" : "Icon-App-29x29@1x.png", 73 | "scale" : "1x" 74 | }, 75 | { 76 | "size" : "29x29", 77 | "idiom" : "ipad", 78 | "filename" : "Icon-App-29x29@2x.png", 79 | "scale" : "2x" 80 | }, 81 | { 82 | "size" : "40x40", 83 | "idiom" : "ipad", 84 | "filename" : "Icon-App-40x40@1x.png", 85 | "scale" : "1x" 86 | }, 87 | { 88 | "size" : "40x40", 89 | "idiom" : "ipad", 90 | "filename" : "Icon-App-40x40@2x.png", 91 | "scale" : "2x" 92 | }, 93 | { 94 | "size" : "76x76", 95 | "idiom" : "ipad", 96 | "filename" : "Icon-App-76x76@1x.png", 97 | "scale" : "1x" 98 | }, 99 | { 100 | "size" : "76x76", 101 | "idiom" : "ipad", 102 | "filename" : "Icon-App-76x76@2x.png", 103 | "scale" : "2x" 104 | }, 105 | { 106 | "size" : "83.5x83.5", 107 | "idiom" : "ipad", 108 | "filename" : "Icon-App-83.5x83.5@2x.png", 109 | "scale" : "2x" 110 | }, 111 | { 112 | "size" : "1024x1024", 113 | "idiom" : "ios-marketing", 114 | "filename" : "Icon-App-1024x1024@1x.png", 115 | "scale" : "1x" 116 | } 117 | ], 118 | "info" : { 119 | "version" : 1, 120 | "author" : "xcode" 121 | } 122 | } 123 | -------------------------------------------------------------------------------- /pubspec.yaml: -------------------------------------------------------------------------------- 1 | name: scroll_to_perfection 2 | description: A new Flutter project. 3 | 4 | # The following line prevents the package from being accidentally published to 5 | # pub.dev using `pub publish`. This is preferred for private packages. 6 | publish_to: 'none' # Remove this line if you wish to publish to pub.dev 7 | 8 | # The following defines the version and build number for your application. 9 | # A version number is three numbers separated by dots, like 1.2.43 10 | # followed by an optional build number separated by a +. 11 | # Both the version and the builder number may be overridden in flutter 12 | # build by specifying --build-name and --build-number, respectively. 13 | # In Android, build-name is used as versionName while build-number used as versionCode. 14 | # Read more about Android versioning at https://developer.android.com/studio/publish/versioning 15 | # In iOS, build-name is used as CFBundleShortVersionString while build-number used as CFBundleVersion. 16 | # Read more about iOS versioning at 17 | # https://developer.apple.com/library/archive/documentation/General/Reference/InfoPlistKeyReference/Articles/CoreFoundationKeys.html 18 | version: 1.0.0+1 19 | 20 | environment: 21 | sdk: ">=2.7.0 <3.0.0" 22 | 23 | dependencies: 24 | flutter: 25 | sdk: flutter 26 | line_icons: ^0.2.0 27 | provider: ^4.3.2+2 28 | flutter_hooks: ^0.14.1 29 | font_awesome_flutter: ^8.10.0 30 | url_launcher: ^5.7.10 31 | # The following adds the Cupertino Icons font to your application. 32 | # Use with the CupertinoIcons class for iOS style icons. 33 | cupertino_icons: ^1.0.0 34 | 35 | dev_dependencies: 36 | flutter_test: 37 | sdk: flutter 38 | 39 | # For information on the generic Dart part of this file, see the 40 | # following page: https://dart.dev/tools/pub/pubspec 41 | 42 | # The following section is specific to Flutter. 43 | flutter: 44 | 45 | # The following line ensures that the Material Icons font is 46 | # included with your application, so that you can use the icons in 47 | # the material Icons class. 48 | uses-material-design: true 49 | assets: 50 | - images/ 51 | fonts: 52 | - family: IbarraRealNova 53 | fonts: 54 | - asset: fonts/Ibarra_Real_Nova/IbarraRealNova-Regular.ttf 55 | - family: Deligne 56 | fonts: 57 | - asset: fonts/OPTIDeligne-Normal.otf 58 | 59 | # An image asset can refer to one or more resolution-specific "variants", see 60 | # https://flutter.dev/assets-and-images/#resolution-aware. 61 | 62 | # For details regarding adding assets from package dependencies, see 63 | # https://flutter.dev/assets-and-images/#from-packages 64 | 65 | # To add custom fonts to your application, add a fonts section here, 66 | # in this "flutter" section. Each entry in this list should have a 67 | # "family" key with the font family name, and a "fonts" key with a 68 | # list giving the asset and other descriptors for the font. For 69 | # example: 70 | # fonts: 71 | # - family: Schyler 72 | # fonts: 73 | # - asset: fonts/Schyler-Regular.ttf 74 | # - asset: fonts/Schyler-Italic.ttf 75 | # style: italic 76 | # - family: Trajan Pro 77 | # fonts: 78 | # - asset: fonts/TrajanPro.ttf 79 | # - asset: fonts/TrajanPro_Bold.ttf 80 | # weight: 700 81 | # 82 | # For details regarding fonts from package dependencies, 83 | # see https://flutter.dev/custom-fonts/#from-packages 84 | -------------------------------------------------------------------------------- /lib/egipt/page2.dart: -------------------------------------------------------------------------------- 1 | import 'package:flutter/material.dart'; 2 | import 'package:scroll_to_perfection/egipt/egypt.dart'; 3 | 4 | class Page2 extends StatefulWidget { 5 | @override 6 | _Page2State createState() => _Page2State(); 7 | } 8 | 9 | class _Page2State extends State with SingleTickerProviderStateMixin { 10 | AnimationController _animationController; 11 | Animation _animation; 12 | 13 | @override 14 | void initState() { 15 | super.initState(); 16 | _animationController = AnimationController( 17 | vsync: this, 18 | duration: Duration(seconds: 1), 19 | ); 20 | _animation = CurvedAnimation( 21 | curve: Curves.easeOutCubic, 22 | parent: _animationController, 23 | ); 24 | } 25 | 26 | @override 27 | void dispose() { 28 | _animationController.dispose(); 29 | super.dispose(); 30 | } 31 | 32 | @override 33 | Widget build(BuildContext context) { 34 | double height = MediaQuery.of(context).size.height; 35 | double width = MediaQuery.of(context).size.width; 36 | return Container( 37 | color: backgroundColor, 38 | height: height > width ? height * 0.5 : height * 0.8, 39 | width: double.infinity, 40 | child: Stack( 41 | children: [ 42 | Positioned( 43 | left: 0, 44 | right: 0, 45 | bottom: height * 0.4, 46 | child: FittedBox( 47 | fit: BoxFit.fitWidth, 48 | child: AnimatedBuilder( 49 | animation: _animationController, 50 | builder: (context, child) => Transform.translate( 51 | offset: Offset((width / 4) * (1 - _animation.value), 0), 52 | child: child, 53 | ), 54 | child: Text( 55 | 'CIVILIZATION', 56 | style: TextStyle( 57 | color: darkerColor, 58 | fontWeight: FontWeight.bold, 59 | ), 60 | ), 61 | ), 62 | ), 63 | ), 64 | Positioned( 65 | left: 0, 66 | right: 0, 67 | bottom: 0, 68 | height: height * 0.4, 69 | child: Container( 70 | color: darkerColor, 71 | ), 72 | ), 73 | Positioned.fill( 74 | child: AnimatedBuilder( 75 | animation: _animationController, 76 | builder: (context, child) => Transform.translate( 77 | offset: Offset( 78 | 0, 79 | height * 0.4 * (1 - _animation.value), 80 | ), 81 | child: child, 82 | ), 83 | child: WhenShownListener( 84 | onWidgetShown: () => _animationController.forward(), 85 | child: Stack( 86 | alignment: Alignment.center, 87 | children: [ 88 | Image.asset( 89 | 'images/camel.png', 90 | fit: BoxFit.fitWidth, 91 | ), 92 | Icon( 93 | Icons.play_circle_outline, 94 | size: 100, 95 | ), 96 | ], 97 | ), 98 | ), 99 | ), 100 | ), 101 | ], 102 | ), 103 | ); 104 | } 105 | } 106 | -------------------------------------------------------------------------------- /ios/Runner.xcodeproj/xcshareddata/xcschemes/Runner.xcscheme: -------------------------------------------------------------------------------- 1 | 2 | 5 | 8 | 9 | 15 | 21 | 22 | 23 | 24 | 25 | 30 | 31 | 32 | 33 | 39 | 40 | 41 | 42 | 43 | 44 | 54 | 56 | 62 | 63 | 64 | 65 | 66 | 67 | 73 | 75 | 81 | 82 | 83 | 84 | 86 | 87 | 90 | 91 | 92 | -------------------------------------------------------------------------------- /fonts/Ibarra_Real_Nova/OFL.txt: -------------------------------------------------------------------------------- 1 | Copyright (c) 2007 The Ibarra Real Authors. 2 | 3 | This Font Software is licensed under the SIL Open Font License, Version 1.1. 4 | This license is copied below, and is also available with a FAQ at: 5 | http://scripts.sil.org/OFL 6 | 7 | 8 | ----------------------------------------------------------- 9 | SIL OPEN FONT LICENSE Version 1.1 - 26 February 2007 10 | ----------------------------------------------------------- 11 | 12 | PREAMBLE 13 | The goals of the Open Font License (OFL) are to stimulate worldwide 14 | development of collaborative font projects, to support the font creation 15 | efforts of academic and linguistic communities, and to provide a free and 16 | open framework in which fonts may be shared and improved in partnership 17 | with others. 18 | 19 | The OFL allows the licensed fonts to be used, studied, modified and 20 | redistributed freely as long as they are not sold by themselves. The 21 | fonts, including any derivative works, can be bundled, embedded, 22 | redistributed and/or sold with any software provided that any reserved 23 | names are not used by derivative works. The fonts and derivatives, 24 | however, cannot be released under any other type of license. The 25 | requirement for fonts to remain under this license does not apply 26 | to any document created using the fonts or their derivatives. 27 | 28 | DEFINITIONS 29 | "Font Software" refers to the set of files released by the Copyright 30 | Holder(s) under this license and clearly marked as such. This may 31 | include source files, build scripts and documentation. 32 | 33 | "Reserved Font Name" refers to any names specified as such after the 34 | copyright statement(s). 35 | 36 | "Original Version" refers to the collection of Font Software components as 37 | distributed by the Copyright Holder(s). 38 | 39 | "Modified Version" refers to any derivative made by adding to, deleting, 40 | or substituting -- in part or in whole -- any of the components of the 41 | Original Version, by changing formats or by porting the Font Software to a 42 | new environment. 43 | 44 | "Author" refers to any designer, engineer, programmer, technical 45 | writer or other person who contributed to the Font Software. 46 | 47 | PERMISSION & CONDITIONS 48 | Permission is hereby granted, free of charge, to any person obtaining 49 | a copy of the Font Software, to use, study, copy, merge, embed, modify, 50 | redistribute, and sell modified and unmodified copies of the Font 51 | Software, subject to the following conditions: 52 | 53 | 1) Neither the Font Software nor any of its individual components, 54 | in Original or Modified Versions, may be sold by itself. 55 | 56 | 2) Original or Modified Versions of the Font Software may be bundled, 57 | redistributed and/or sold with any software, provided that each copy 58 | contains the above copyright notice and this license. These can be 59 | included either as stand-alone text files, human-readable headers or 60 | in the appropriate machine-readable metadata fields within text or 61 | binary files as long as those fields can be easily viewed by the user. 62 | 63 | 3) No Modified Version of the Font Software may use the Reserved Font 64 | Name(s) unless explicit written permission is granted by the corresponding 65 | Copyright Holder. This restriction only applies to the primary font name as 66 | presented to the users. 67 | 68 | 4) The name(s) of the Copyright Holder(s) or the Author(s) of the Font 69 | Software shall not be used to promote, endorse or advertise any 70 | Modified Version, except to acknowledge the contribution(s) of the 71 | Copyright Holder(s) and the Author(s) or with their explicit written 72 | permission. 73 | 74 | 5) The Font Software, modified or unmodified, in part or in whole, 75 | must be distributed entirely under this license, and must not be 76 | distributed under any other license. The requirement for fonts to 77 | remain under this license does not apply to any document created 78 | using the Font Software. 79 | 80 | TERMINATION 81 | This license becomes null and void if any of the above conditions are 82 | not met. 83 | 84 | DISCLAIMER 85 | THE FONT SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, 86 | EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OF 87 | MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT 88 | OF COPYRIGHT, PATENT, TRADEMARK, OR OTHER RIGHT. IN NO EVENT SHALL THE 89 | COPYRIGHT HOLDER BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, 90 | INCLUDING ANY GENERAL, SPECIAL, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL 91 | DAMAGES, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING 92 | FROM, OUT OF THE USE OR INABILITY TO USE THE FONT SOFTWARE OR FROM 93 | OTHER DEALINGS IN THE FONT SOFTWARE. 94 | -------------------------------------------------------------------------------- /lib/vgv.dart: -------------------------------------------------------------------------------- 1 | import 'package:flutter/material.dart'; 2 | import 'package:flutter_hooks/flutter_hooks.dart'; 3 | import 'package:provider/provider.dart'; 4 | 5 | class VeryGood extends HookWidget { 6 | @override 7 | Widget build(BuildContext context) { 8 | final scrollController = useScrollController(); 9 | return Scaffold( 10 | appBar: AppBar( 11 | title: Text('Very good gentle animations'), 12 | ), 13 | body: ChangeNotifierProvider.value( 14 | value: scrollController, 15 | child: Center( 16 | child: Container( 17 | constraints: BoxConstraints(maxWidth: 800), 18 | alignment: Alignment.center, 19 | child: ListView.builder( 20 | controller: scrollController, 21 | itemBuilder: (context, index) { 22 | final moduloIndex = index % 3; 23 | if (moduloIndex == 0) { 24 | return AspectRatio( 25 | aspectRatio: 2, 26 | child: VeryGoodImage( 27 | 'images/image0.jpg', 28 | ), 29 | ); 30 | } else if (moduloIndex == 1) { 31 | return Row( 32 | children: [ 33 | Expanded( 34 | child: VeryGoodImage( 35 | 'images/image1.jpg', 36 | ), 37 | ), 38 | Expanded( 39 | child: VeryGoodImage( 40 | 'images/image2.jpg', 41 | ), 42 | ) 43 | ], 44 | ); 45 | } else { 46 | return Row( 47 | children: [ 48 | Expanded( 49 | child: AspectRatio( 50 | aspectRatio: 1, 51 | child: VeryGoodImage( 52 | 'images/image3.jpg', 53 | ), 54 | ), 55 | ), 56 | Expanded( 57 | child: AspectRatio( 58 | aspectRatio: 1, 59 | child: VeryGoodImage( 60 | 'images/image4.jpg', 61 | ), 62 | ), 63 | ), 64 | Expanded( 65 | child: AspectRatio( 66 | aspectRatio: 1, 67 | child: VeryGoodImage( 68 | 'images/image5.jpg', 69 | ), 70 | ), 71 | ) 72 | ], 73 | ); 74 | } 75 | }, 76 | ), 77 | ), 78 | ), 79 | ), 80 | ); 81 | } 82 | } 83 | 84 | class VeryGoodImage extends StatelessWidget { 85 | final String imagePath; 86 | 87 | const VeryGoodImage(this.imagePath); 88 | 89 | @override 90 | Widget build(BuildContext context) { 91 | return VeryGoodWrapper( 92 | child: Padding( 93 | padding: const EdgeInsets.all(8.0), 94 | child: Image.asset( 95 | imagePath, 96 | fit: BoxFit.cover, 97 | ), 98 | ), 99 | ); 100 | } 101 | } 102 | 103 | class VeryGoodWrapper extends StatelessWidget { 104 | final Widget child; 105 | 106 | const VeryGoodWrapper({Key key, this.child}) : super(key: key); 107 | 108 | @override 109 | Widget build(BuildContext context) { 110 | return Consumer( 111 | builder: (context, scrollController, child) { 112 | final renderObject = context.findRenderObject() as RenderBox; 113 | final offsetY = renderObject?.localToGlobal(Offset.zero)?.dy ?? 0; 114 | if (offsetY <= 0) { 115 | return child; 116 | } 117 | final deviceHeight = MediaQuery.of(context).size.height; 118 | final size = renderObject.size; 119 | final heightVisible = deviceHeight - offsetY; 120 | final howMuchSown = (heightVisible / size.height).clamp(0.0, 1.0); 121 | final scale = 0.8 + howMuchSown * 0.2; 122 | final opacity = 0.25 + howMuchSown * 0.75; 123 | return Transform.scale( 124 | scale: scale, 125 | alignment: Alignment.center, 126 | child: Opacity( 127 | opacity: opacity, 128 | child: child, 129 | ), 130 | ); 131 | }, 132 | child: child, 133 | ); 134 | } 135 | } 136 | -------------------------------------------------------------------------------- /lib/egipt/page1.dart: -------------------------------------------------------------------------------- 1 | import 'package:flutter/material.dart'; 2 | import 'package:scroll_to_perfection/egipt/egypt.dart'; 3 | 4 | class Page1 extends StatefulWidget { 5 | @override 6 | _Page1State createState() => _Page1State(); 7 | } 8 | 9 | class _Page1State extends State with SingleTickerProviderStateMixin { 10 | AnimationController _animationController; 11 | Animation _animation; 12 | 13 | @override 14 | void initState() { 15 | super.initState(); 16 | _animationController = AnimationController( 17 | vsync: this, 18 | duration: Duration(seconds: 1), 19 | )..addListener(() => setState(() {})); 20 | _animation = CurvedAnimation( 21 | curve: Curves.easeOutCubic, 22 | parent: _animationController, 23 | ); 24 | } 25 | 26 | @override 27 | void dispose() { 28 | _animationController.dispose(); 29 | super.dispose(); 30 | } 31 | 32 | @override 33 | Widget build(BuildContext context) { 34 | double height = MediaQuery.of(context).size.height; 35 | double width = MediaQuery.of(context).size.width; 36 | return FractionallySizedBox( 37 | widthFactor: 0.7, 38 | child: AnimatedBuilder( 39 | animation: _animation, 40 | builder: (context, child) => Transform.translate( 41 | offset: Offset(0, (1 - _animation.value) * height * 0.25), 42 | child: child, 43 | ), 44 | child: Column( 45 | children: [ 46 | WhenShownListener( 47 | onWidgetShown: () => _animationController.forward(), 48 | child: Text( 49 | 'THE ANCIENT', 50 | style: TextStyle( 51 | fontFamily: 'Roboto', 52 | color: Colors.black, 53 | fontSize: 16, 54 | fontWeight: FontWeight.w500, 55 | ), 56 | ), 57 | ), 58 | SizedBox(height: 12), 59 | Row( 60 | mainAxisSize: MainAxisSize.min, 61 | mainAxisAlignment: MainAxisAlignment.center, 62 | children: [ 63 | Text( 64 | 'Egyptian', 65 | style: TextStyle(fontWeight: FontWeight.bold, fontSize: 30), 66 | ), 67 | Text( 68 | ' civilization', 69 | style: TextStyle(color: Colors.black, fontSize: 30), 70 | ) 71 | ], 72 | ), 73 | SizedBox(height: height * 0.1), 74 | if (width > 440) 75 | Row( 76 | children: [ 77 | Expanded( 78 | child: Text( 79 | 'The ancient Egyptian civilization, famous for its pyramids, pharaohs, mummies, and tombs, flourished for thousands for thousands of yers. But what was its lasting impact?', 80 | ), 81 | ), 82 | SizedBox(width: 64), 83 | Expanded( 84 | child: Text( 85 | 'Watch the video below to learn how ancient Egypt contributed to modern-day society with its many cultural developments, particularly in language & mathematics', 86 | ), 87 | ) 88 | ], 89 | ) 90 | else ...[ 91 | Text( 92 | 'The ancient Egyptian civilization, famous for its pyramids, pharaohs, mummies, and tombs, flourished for thousands for thousands of yers. But what was its lasting impact?', 93 | ), 94 | SizedBox(height: 16), 95 | Text( 96 | 'Watch the video below to learn how ancient Egypt contributed to modern-day society with its many cultural developments, particularly in language & mathematics', 97 | ) 98 | ], 99 | SizedBox(height: height * 0.1), 100 | ], 101 | ), 102 | ), 103 | ); 104 | } 105 | } 106 | 107 | class EgiptPage extends StatefulWidget { 108 | final Widget child; 109 | final ScrollController scrollController; 110 | 111 | const EgiptPage({Key key, this.scrollController, this.child}) 112 | : super(key: key); 113 | 114 | @override 115 | _EgiptPageState createState() => _EgiptPageState(); 116 | } 117 | 118 | class _EgiptPageState extends State 119 | with SingleTickerProviderStateMixin { 120 | AnimationController _animationController; 121 | 122 | @override 123 | void initState() { 124 | super.initState(); 125 | _animationController = AnimationController( 126 | vsync: this, 127 | duration: Duration(seconds: 1), 128 | ); 129 | } 130 | 131 | @override 132 | Widget build(BuildContext context) { 133 | return AnimatedBuilder( 134 | animation: widget.scrollController, 135 | builder: (context, child) { 136 | final renderObject = context.findRenderObject() as RenderBox; 137 | final offsetY = renderObject?.localToGlobal(Offset.zero)?.dy ?? 0; 138 | final deviceHeight = MediaQuery.of(context).size.height; 139 | if (renderObject != null && 140 | offsetY < deviceHeight && 141 | _animationController.isDismissed) { 142 | _animationController.forward(); 143 | } 144 | return child; 145 | }, 146 | child: AnimatedBuilder( 147 | animation: _animationController, 148 | builder: (context, child) => Transform.translate( 149 | offset: Offset(0, 100 * (1 - _animationController.value)), 150 | child: child, 151 | ), 152 | child: widget.child, 153 | ), 154 | ); 155 | } 156 | } 157 | 158 | class MyAwesomeWidget extends StatelessWidget { 159 | @override 160 | Widget build(BuildContext context) { 161 | return Container(); 162 | } 163 | } 164 | -------------------------------------------------------------------------------- /lib/zoom_in.dart: -------------------------------------------------------------------------------- 1 | import 'dart:math' as math; 2 | 3 | import 'package:flutter/material.dart'; 4 | 5 | class ZoomIn extends StatefulWidget { 6 | @override 7 | _ZoomInState createState() => _ZoomInState(); 8 | } 9 | 10 | class _ZoomInState extends State { 11 | PageController pageController; 12 | 13 | @override 14 | void initState() { 15 | super.initState(); 16 | pageController = PageController(); 17 | pageController.addListener(() => setState(() {})); 18 | } 19 | 20 | @override 21 | void dispose() { 22 | pageController.dispose(); 23 | super.dispose(); 24 | } 25 | 26 | double get pageOffset => pageController.hasClients ? pageController.page : 0; 27 | 28 | @override 29 | Widget build(BuildContext context) { 30 | return Scaffold( 31 | appBar: AppBar( 32 | title: Text('Zoom in'), 33 | ), 34 | body: Stack( 35 | children: [ 36 | Page( 37 | color: Colors.yellow, 38 | text: 'The master fisherman', 39 | imagePath: 'images/image2.jpg', 40 | transitionPercentage: pageOffset < 1.1 ? null : 0, 41 | ), 42 | Page( 43 | color: Colors.deepOrange, 44 | text: 'What the deer are telling us', 45 | imagePath: 'images/image1.jpg', 46 | transitionPercentage: 47 | pageOffset < 0.1 ? null : (pageOffset - 1).clamp(0.0, 1.0), 48 | ), 49 | Page( 50 | color: Colors.orangeAccent, 51 | text: 'The elephant queen', 52 | imagePath: 'images/image0.jpg', 53 | transitionPercentage: 54 | pageController.hasClients ? pageOffset.clamp(0.0, 1.0) : null, 55 | ), 56 | NotificationListener( 57 | onNotification: (not) { 58 | print(not); 59 | return true; 60 | }, 61 | child: PageView( 62 | controller: pageController, 63 | scrollDirection: Axis.vertical, 64 | children: [ 65 | Container(width: double.infinity), 66 | Container(width: double.infinity), 67 | Container(width: double.infinity), 68 | ], 69 | ), 70 | ), 71 | ], 72 | ), 73 | ); 74 | } 75 | } 76 | 77 | class Page extends StatefulWidget { 78 | final Color color; 79 | final String text; 80 | final String imagePath; 81 | final double transitionPercentage; 82 | 83 | const Page({ 84 | this.text, 85 | this.imagePath, 86 | Key key, 87 | this.color, 88 | this.transitionPercentage, 89 | }) : super(key: key); 90 | 91 | @override 92 | _PageState createState() => _PageState(); 93 | } 94 | 95 | class _PageState extends State with SingleTickerProviderStateMixin { 96 | AnimationController animationController; 97 | 98 | @override 99 | void initState() { 100 | super.initState(); 101 | animationController = AnimationController( 102 | duration: Duration(milliseconds: 2000), 103 | vsync: this, 104 | upperBound: 0.05, 105 | ); 106 | } 107 | 108 | @override 109 | void dispose() { 110 | animationController.dispose(); 111 | super.dispose(); 112 | } 113 | 114 | @override 115 | void didUpdateWidget(covariant Page oldWidget) { 116 | if (oldWidget.transitionPercentage == null && 117 | widget.transitionPercentage != null) { 118 | animationController.forward(from: 0); 119 | } 120 | super.didUpdateWidget(oldWidget); 121 | } 122 | 123 | @override 124 | Widget build(BuildContext context) { 125 | return ClipPath( 126 | clipper: 127 | InvertedCircleClipper(percentage: widget.transitionPercentage ?? 0), 128 | child: AnimatedBuilder( 129 | animation: animationController, 130 | builder: (context, child) { 131 | return Transform.scale( 132 | scale: 1 + 133 | animationController.value + 134 | (widget.transitionPercentage ?? 0), 135 | child: child, 136 | ); 137 | }, 138 | child: Container( 139 | color: widget.color, 140 | width: double.infinity, 141 | height: double.infinity, 142 | child: Column( 143 | mainAxisAlignment: MainAxisAlignment.spaceEvenly, 144 | children: [ 145 | Row( 146 | mainAxisAlignment: MainAxisAlignment.spaceEvenly, 147 | children: [ 148 | Text(widget.text), 149 | Image.asset( 150 | widget.imagePath, 151 | height: MediaQuery.of(context).size.height / 2, 152 | width: MediaQuery.of(context).size.height / 2, 153 | fit: BoxFit.cover, 154 | ) 155 | ], 156 | ), 157 | TextButton( 158 | child: Text('Scroll down'), 159 | onPressed: () {}, 160 | ), 161 | ], 162 | ), 163 | ), 164 | ), 165 | ); 166 | } 167 | } 168 | 169 | class InvertedCircleClipper extends CustomClipper { 170 | final double percentage; 171 | 172 | InvertedCircleClipper({this.percentage}); 173 | 174 | @override 175 | Path getClip(Size size) { 176 | return Path() 177 | ..addRect(Rect.fromLTWH(0.0, 0.0, size.width, size.height)) 178 | ..addOval( 179 | Rect.fromCircle( 180 | center: Offset(size.width / 2, size.height / 2), 181 | radius: math.sqrt(size.longestSide * size.longestSide + 182 | size.shortestSide * size.shortestSide) * 183 | percentage * 184 | 0.5, 185 | ), 186 | ) 187 | ..fillType = PathFillType.evenOdd; 188 | } 189 | 190 | @override 191 | bool shouldReclip(CustomClipper oldClipper) => true; 192 | } 193 | -------------------------------------------------------------------------------- /lib/egipt/page3.dart: -------------------------------------------------------------------------------- 1 | import 'dart:math'; 2 | 3 | import 'package:flutter/material.dart'; 4 | import 'package:scroll_to_perfection/egipt/egypt.dart'; 5 | 6 | class Page3 extends StatefulWidget { 7 | @override 8 | _Page3State createState() => _Page3State(); 9 | } 10 | 11 | class _Page3State extends State with SingleTickerProviderStateMixin { 12 | AnimationController _animationController; 13 | Animation _animation; 14 | 15 | @override 16 | void initState() { 17 | super.initState(); 18 | _animationController = AnimationController( 19 | vsync: this, 20 | duration: Duration(seconds: 1), 21 | ); 22 | _animation = CurvedAnimation( 23 | curve: Curves.easeOutCubic, parent: _animationController); 24 | } 25 | 26 | @override 27 | void dispose() { 28 | _animationController.dispose(); 29 | super.dispose(); 30 | } 31 | 32 | @override 33 | Widget build(BuildContext context) { 34 | double height = MediaQuery.of(context).size.height; 35 | double width = MediaQuery.of(context).size.width; 36 | return Container( 37 | color: darkerColor, 38 | child: FractionallySizedBox( 39 | widthFactor: 0.7, 40 | child: Column( 41 | children: [ 42 | SizedBox(height: height * 0.1), 43 | Text('10 THINGS', style: TextStyle(color: Colors.black)), 44 | SizedBox(height: height * 0.05), 45 | _header(), 46 | WhenShownListener( 47 | initOffset: 200, 48 | onWidgetShown: () => _animationController.forward(), 49 | child: SizedBox(height: height * 0.1), 50 | ), 51 | if (width > height) 52 | Row( 53 | children: [ 54 | Expanded(child: _leftSide(width)), 55 | SizedBox(width: width * 0.1), 56 | Expanded(child: _rightSide(height, width)) 57 | ], 58 | ) 59 | else ...[ 60 | _leftSide(width), 61 | _rightSide(height, width), 62 | ], 63 | SizedBox(height: height * 0.1), 64 | ], 65 | ), 66 | ), 67 | ); 68 | } 69 | 70 | RichText _header() { 71 | return RichText( 72 | textAlign: TextAlign.center, 73 | text: TextSpan( 74 | style: TextStyle( 75 | color: Colors.white, 76 | fontSize: 40, 77 | fontFamily: 'IbarraRealNova', 78 | ), 79 | children: [ 80 | TextSpan( 81 | text: 'You probably didn\'t know\n', 82 | ), 83 | TextSpan( 84 | text: 'about ', 85 | ), 86 | TextSpan( 87 | text: 'ancient Egypt', 88 | style: TextStyle( 89 | color: Colors.black, 90 | fontFamily: 'IbarraRealNova', 91 | ), 92 | ) 93 | ], 94 | ), 95 | ); 96 | } 97 | 98 | Widget _rightSide(double height, double width) { 99 | return AnimatedBuilder( 100 | animation: _animationController, 101 | builder: (context, child) { 102 | return Transform.translate( 103 | offset: Offset((width / 2) * (1 - _animation.value), 0), 104 | child: child, 105 | ); 106 | }, 107 | child: Container( 108 | height: height / 2, 109 | child: Stack( 110 | alignment: Alignment(0, 0.5), 111 | children: [ 112 | AnimatedBuilder( 113 | animation: _animationController, 114 | builder: (context, child) { 115 | return Transform.rotate( 116 | angle: _animation.value * 0.5 * pi - pi * 0.7, 117 | child: child, 118 | ); 119 | }, 120 | child: Container( 121 | width: 360, 122 | height: 360, 123 | decoration: BoxDecoration( 124 | gradient: LinearGradient( 125 | colors: [ 126 | Colors.white.withOpacity(0.7), 127 | Colors.white.withOpacity(0), 128 | ], 129 | begin: Alignment.topCenter, 130 | end: Alignment.bottomCenter, 131 | ), 132 | ), 133 | ), 134 | ), 135 | Image.asset('images/pharaon.png'), 136 | ], 137 | ), 138 | ), 139 | ); 140 | } 141 | 142 | Widget _leftSide(double width) { 143 | return AnimatedBuilder( 144 | animation: _animationController, 145 | builder: (context, child) { 146 | return Transform.translate( 147 | offset: Offset((-width / 2) * (1 - _animation.value), 0), 148 | child: child, 149 | ); 150 | }, 151 | child: Column( 152 | crossAxisAlignment: CrossAxisAlignment.start, 153 | mainAxisAlignment: MainAxisAlignment.center, 154 | children: [ 155 | Text( 156 | 'His original name was\nNot Tutankhamun', 157 | style: TextStyle( 158 | fontWeight: FontWeight.bold, 159 | fontSize: 38, 160 | ), 161 | ), 162 | SizedBox(height: 32), 163 | Text( 164 | 'Tutankhamun was originally named Tutanhaten. This name, whic literally means "living image of the Aten", reflected the fact that Tutankhaten\'s parents worshipped a sun god known as "the Aten". After a few years on the throne the young king.', 165 | style: TextStyle(fontSize: 24), 166 | ), 167 | SizedBox(height: 32), 168 | Text( 169 | 'Read More', 170 | style: TextStyle( 171 | decoration: TextDecoration.underline, 172 | color: Colors.black, 173 | fontSize: 24, 174 | ), 175 | ), 176 | ], 177 | ), 178 | ); 179 | } 180 | } 181 | -------------------------------------------------------------------------------- /lib/cuberto.dart: -------------------------------------------------------------------------------- 1 | import 'dart:math'; 2 | 3 | import 'package:flutter/material.dart'; 4 | 5 | class Cuberto extends StatefulWidget { 6 | @override 7 | _CubertoState createState() => _CubertoState(); 8 | } 9 | 10 | class _CubertoState extends State { 11 | PageController pageController; 12 | 13 | @override 14 | void initState() { 15 | super.initState(); 16 | pageController = PageController() 17 | ..addListener(() { 18 | setState(() {}); 19 | }); 20 | } 21 | 22 | @override 23 | void dispose() { 24 | pageController.dispose(); 25 | super.dispose(); 26 | } 27 | 28 | @override 29 | Widget build(BuildContext context) { 30 | return Scaffold( 31 | appBar: AppBar( 32 | title: Text('Cuberto'), 33 | ), 34 | body: Scrollbar( 35 | controller: pageController, 36 | isAlwaysShown: true, 37 | thickness: 6, 38 | child: Stack( 39 | children: [ 40 | PageView( 41 | controller: pageController, 42 | pageSnapping: false, 43 | scrollDirection: Axis.vertical, 44 | children: [ 45 | SizedBox(), 46 | Page(index: 0, pageController: pageController), 47 | Page(index: 1), 48 | Page(index: 2), 49 | Page(index: 3), 50 | Page(index: 4, pageController: pageController), 51 | SizedBox(), 52 | ], 53 | ), 54 | if (pageController.hasClients && 55 | pageController.page != null && 56 | pageController.page > 1 && 57 | pageController.page < 5) 58 | Align( 59 | alignment: Alignment(0.5, 0), 60 | child: IgnorePointer( 61 | child: SizedBox( 62 | width: MediaQuery.of(context).size.width / 3, 63 | height: MediaQuery.of(context).size.height * 0.8, 64 | child: Stack( 65 | children: [ 66 | _StackImage(pageController: pageController, index: 4), 67 | _StackImage(pageController: pageController, index: 3), 68 | _StackImage(pageController: pageController, index: 2), 69 | _StackImage(pageController: pageController, index: 1), 70 | _StackImage(pageController: pageController, index: 0), 71 | ], 72 | ), 73 | ), 74 | ), 75 | ), 76 | ], 77 | ), 78 | ), 79 | ); 80 | } 81 | } 82 | 83 | class _StackImage extends StatelessWidget { 84 | const _StackImage({ 85 | Key key, 86 | @required this.pageController, 87 | @required this.index, 88 | }) : super(key: key); 89 | 90 | final PageController pageController; 91 | final int index; 92 | 93 | @override 94 | Widget build(BuildContext context) { 95 | final page = pageController.hasClients ? (pageController.page ?? 0) : 0; 96 | final percentageMoved = (page - index - 1).clamp(0.0, 1.0); 97 | return Positioned.fill( 98 | child: ClipPath( 99 | clipper: percentageMoved > 0 ? WaveClipper(percentageMoved) : null, 100 | child: Image.asset( 101 | 'images/image$index.jpg', 102 | fit: BoxFit.cover, 103 | ), 104 | ), 105 | ); 106 | } 107 | } 108 | 109 | class Page extends StatelessWidget { 110 | final int index; 111 | final PageController pageController; 112 | 113 | const Page({Key key, this.index, this.pageController}) : super(key: key); 114 | 115 | @override 116 | Widget build(BuildContext context) { 117 | final shouldShowImageOnFirstPage = index == 0 && 118 | pageController.hasClients && 119 | pageController.page != null && 120 | pageController.page <= 1; 121 | final shouldShowImageOnLastPage = index == 4 && 122 | pageController.hasClients && 123 | pageController.page != null && 124 | pageController.page >= 5; 125 | return Row( 126 | children: [ 127 | Expanded( 128 | child: Center( 129 | child: Text( 130 | 'Page $index', 131 | style: TextStyle(fontSize: 30, fontWeight: FontWeight.w600), 132 | ), 133 | ), 134 | ), 135 | Expanded( 136 | child: shouldShowImageOnFirstPage || shouldShowImageOnLastPage 137 | ? Container( 138 | alignment: Alignment.centerLeft, 139 | child: Image.asset( 140 | 'images/image$index.jpg', 141 | width: MediaQuery.of(context).size.width / 3, 142 | height: MediaQuery.of(context).size.height * 0.8, 143 | fit: BoxFit.cover, 144 | ), 145 | ) 146 | : SizedBox(), 147 | ), 148 | ], 149 | ); 150 | } 151 | } 152 | 153 | class WaveClipper extends CustomClipper { 154 | final double percentage; 155 | 156 | WaveClipper(this.percentage); 157 | 158 | @override 159 | Path getClip(Size size) { 160 | Path path = Path(); 161 | final height = size.height * (1 - percentage); 162 | path.lineTo(0, height); 163 | path.quadraticBezierTo( 164 | size.width * 1 / 8, 165 | height - 40 * sin(20 * percentage).abs(), 166 | size.width * 1 / 4, 167 | height - 20 * sin(20 * percentage).abs(), 168 | ); 169 | path.quadraticBezierTo( 170 | size.width * 3 / 8, 171 | height - 10 * sin(10 * percentage).abs(), 172 | size.width * 2 / 4, 173 | height - 30 * sin(10 * percentage).abs(), 174 | ); 175 | path.quadraticBezierTo( 176 | size.width * 5 / 8, 177 | height - 50 * sin(20 * percentage).abs(), 178 | size.width * 3 / 4, 179 | height - 25 * sin(20 * percentage).abs(), 180 | ); 181 | path.quadraticBezierTo( 182 | size.width * 7 / 8, 183 | height - 15 * sin(15 * percentage).abs(), 184 | size.width * 4 / 4, 185 | height - 30 * sin(15 * percentage).abs(), 186 | ); 187 | path.lineTo(size.width, 0); 188 | path.close(); 189 | return path; 190 | } 191 | 192 | @override 193 | bool shouldReclip(WaveClipper oldClipper) => true; 194 | } 195 | -------------------------------------------------------------------------------- /lib/egipt/egypt.dart: -------------------------------------------------------------------------------- 1 | import 'package:flutter/material.dart'; 2 | import 'package:scroll_to_perfection/egipt/main_text.dart'; 3 | import 'package:scroll_to_perfection/egipt/page2.dart'; 4 | import 'package:scroll_to_perfection/egipt/page3.dart'; 5 | 6 | import 'page1.dart'; 7 | 8 | class EgyptPage extends StatefulWidget { 9 | EgyptPage({Key key}) : super(key: key); 10 | 11 | @override 12 | _EgyptPageState createState() => _EgyptPageState(); 13 | } 14 | 15 | Color backgroundColor = Color.fromRGBO(216, 177, 136, 1); 16 | Color darkerColor = Color.fromRGBO(200, 162, 122, 1); 17 | 18 | class _EgyptPageState extends State { 19 | ScrollController _scrollController; 20 | 21 | double get screenHeight => MediaQuery.of(context).size.height; 22 | 23 | double get screenWidth => MediaQuery.of(context).size.width; 24 | 25 | @override 26 | void initState() { 27 | super.initState(); 28 | _scrollController = ScrollController()..addListener(() => setState(() {})); 29 | } 30 | 31 | @override 32 | void dispose() { 33 | _scrollController.dispose(); 34 | super.dispose(); 35 | } 36 | 37 | double get offset => 38 | _scrollController.hasClients ? _scrollController.offset : 0.0; 39 | 40 | @override 41 | Widget build(BuildContext context) { 42 | return Theme( 43 | data: ThemeData( 44 | brightness: Brightness.dark, 45 | fontFamily: 'Deligne', 46 | textTheme: TextTheme(body1: TextStyle(fontSize: 28)), 47 | ), 48 | child: Scaffold( 49 | backgroundColor: backgroundColor, 50 | body: Stack( 51 | children: [ 52 | Positioned( 53 | top: -0.3 * offset, 54 | left: 0, 55 | right: 0, 56 | height: screenHeight, 57 | child: RepaintBoundary( 58 | child: Image.asset( 59 | 'images/sky.png', 60 | fit: BoxFit.cover, 61 | ), 62 | ), 63 | ), 64 | Positioned( 65 | top: 0.2 * screenHeight, 66 | left: 0, 67 | right: 0, 68 | child: MainText(), 69 | ), 70 | Positioned( 71 | top: screenHeight * 0.55 - 0.65 * offset, 72 | right: 0, 73 | left: 0, 74 | height: screenHeight * 0.4, 75 | child: RepaintBoundary( 76 | child: Image.asset( 77 | 'images/pyramid.png', 78 | fit: BoxFit.cover, 79 | alignment: Alignment(0, -0.2), 80 | ), 81 | ), 82 | ), 83 | Header(), 84 | Positioned( 85 | top: screenHeight * 0.8 - 1 * offset, 86 | left: 0, 87 | right: 0, 88 | height: screenHeight / 3, 89 | child: RepaintBoundary( 90 | child: Image.asset( 91 | 'images/sand.png', 92 | fit: BoxFit.fill, 93 | ), 94 | ), 95 | ), 96 | Positioned( 97 | top: screenHeight * 0.8 - 1 * offset, 98 | left: 0, 99 | right: 0, 100 | height: screenHeight * 0.3, 101 | child: Container( 102 | width: double.infinity, 103 | decoration: BoxDecoration( 104 | gradient: LinearGradient( 105 | begin: Alignment.topCenter, 106 | end: Alignment.bottomCenter, 107 | stops: [0, 1], 108 | colors: [backgroundColor.withOpacity(0), backgroundColor], 109 | ), 110 | ), 111 | ), 112 | ), 113 | Scrollbar( 114 | child: ListView( 115 | controller: _scrollController, 116 | cacheExtent: screenHeight * 1, 117 | children: [ 118 | Container(height: screenHeight), 119 | Container( 120 | height: 100, 121 | color: backgroundColor, 122 | ), 123 | Container( 124 | color: backgroundColor, 125 | child: Page1(), 126 | ), 127 | Page2(), 128 | Page3(), 129 | Container( 130 | height: 100, 131 | color: darkerColor, 132 | ), 133 | ], 134 | ), 135 | ), 136 | ], 137 | ), 138 | ), 139 | ); 140 | } 141 | } 142 | 143 | class Header extends StatelessWidget { 144 | @override 145 | Widget build(BuildContext context) { 146 | return Padding( 147 | padding: const EdgeInsets.all(64), 148 | child: Row( 149 | children: [ 150 | Text('GOTOEGYPT'), 151 | Spacer(), 152 | if (MediaQuery.of(context).size.width > 900) ...[ 153 | Text('Home'), 154 | SizedBox(width: 32), 155 | Text('Explore'), 156 | SizedBox(width: 32), 157 | Text('Articles'), 158 | SizedBox(width: 32), 159 | Text('Galries'), 160 | SizedBox(width: 32), 161 | Text('Contact'), 162 | SizedBox(width: 64), 163 | ], 164 | Icon( 165 | Icons.apps, 166 | color: backgroundColor, 167 | size: 32, 168 | ), 169 | ], 170 | ), 171 | ); 172 | } 173 | } 174 | 175 | class WhenShownListener extends StatefulWidget { 176 | final VoidCallback onWidgetShown; 177 | final Widget child; 178 | final double initOffset; 179 | 180 | const WhenShownListener( 181 | {Key key, this.onWidgetShown, this.child, this.initOffset = 0}) 182 | : super(key: key); 183 | 184 | @override 185 | _WhenShownListenerState createState() => _WhenShownListenerState(); 186 | } 187 | 188 | class _WhenShownListenerState extends State { 189 | bool hasEmitted = false; 190 | 191 | @override 192 | Widget build(BuildContext context) { 193 | final renderObject = context.findRenderObject() as RenderBox; 194 | final offsetY = renderObject?.localToGlobal(Offset.zero)?.dy ?? 0; 195 | final deviceHeight = MediaQuery.of(context).size.height; 196 | if (renderObject != null && 197 | offsetY < deviceHeight - widget.initOffset && 198 | !hasEmitted) { 199 | hasEmitted = true; 200 | widget.onWidgetShown(); 201 | } 202 | return widget.child; 203 | } 204 | } 205 | -------------------------------------------------------------------------------- /pubspec.lock: -------------------------------------------------------------------------------- 1 | # Generated by pub 2 | # See https://dart.dev/tools/pub/glossary#lockfile 3 | packages: 4 | async: 5 | dependency: transitive 6 | description: 7 | name: async 8 | url: "https://pub.dartlang.org" 9 | source: hosted 10 | version: "2.5.0-nullsafety.3" 11 | boolean_selector: 12 | dependency: transitive 13 | description: 14 | name: boolean_selector 15 | url: "https://pub.dartlang.org" 16 | source: hosted 17 | version: "2.1.0-nullsafety.3" 18 | characters: 19 | dependency: transitive 20 | description: 21 | name: characters 22 | url: "https://pub.dartlang.org" 23 | source: hosted 24 | version: "1.1.0-nullsafety.5" 25 | charcode: 26 | dependency: transitive 27 | description: 28 | name: charcode 29 | url: "https://pub.dartlang.org" 30 | source: hosted 31 | version: "1.2.0-nullsafety.3" 32 | clock: 33 | dependency: transitive 34 | description: 35 | name: clock 36 | url: "https://pub.dartlang.org" 37 | source: hosted 38 | version: "1.1.0-nullsafety.3" 39 | collection: 40 | dependency: transitive 41 | description: 42 | name: collection 43 | url: "https://pub.dartlang.org" 44 | source: hosted 45 | version: "1.15.0-nullsafety.5" 46 | cupertino_icons: 47 | dependency: "direct main" 48 | description: 49 | name: cupertino_icons 50 | url: "https://pub.dartlang.org" 51 | source: hosted 52 | version: "1.0.0" 53 | fake_async: 54 | dependency: transitive 55 | description: 56 | name: fake_async 57 | url: "https://pub.dartlang.org" 58 | source: hosted 59 | version: "1.2.0-nullsafety.3" 60 | flutter: 61 | dependency: "direct main" 62 | description: flutter 63 | source: sdk 64 | version: "0.0.0" 65 | flutter_hooks: 66 | dependency: "direct main" 67 | description: 68 | name: flutter_hooks 69 | url: "https://pub.dartlang.org" 70 | source: hosted 71 | version: "0.14.1" 72 | flutter_test: 73 | dependency: "direct dev" 74 | description: flutter 75 | source: sdk 76 | version: "0.0.0" 77 | flutter_web_plugins: 78 | dependency: transitive 79 | description: flutter 80 | source: sdk 81 | version: "0.0.0" 82 | font_awesome_flutter: 83 | dependency: "direct main" 84 | description: 85 | name: font_awesome_flutter 86 | url: "https://pub.dartlang.org" 87 | source: hosted 88 | version: "8.10.0" 89 | js: 90 | dependency: transitive 91 | description: 92 | name: js 93 | url: "https://pub.dartlang.org" 94 | source: hosted 95 | version: "0.6.3-nullsafety.3" 96 | line_icons: 97 | dependency: "direct main" 98 | description: 99 | name: line_icons 100 | url: "https://pub.dartlang.org" 101 | source: hosted 102 | version: "0.2.0" 103 | matcher: 104 | dependency: transitive 105 | description: 106 | name: matcher 107 | url: "https://pub.dartlang.org" 108 | source: hosted 109 | version: "0.12.10-nullsafety.3" 110 | meta: 111 | dependency: transitive 112 | description: 113 | name: meta 114 | url: "https://pub.dartlang.org" 115 | source: hosted 116 | version: "1.3.0-nullsafety.6" 117 | nested: 118 | dependency: transitive 119 | description: 120 | name: nested 121 | url: "https://pub.dartlang.org" 122 | source: hosted 123 | version: "0.0.4" 124 | path: 125 | dependency: transitive 126 | description: 127 | name: path 128 | url: "https://pub.dartlang.org" 129 | source: hosted 130 | version: "1.8.0-nullsafety.3" 131 | plugin_platform_interface: 132 | dependency: transitive 133 | description: 134 | name: plugin_platform_interface 135 | url: "https://pub.dartlang.org" 136 | source: hosted 137 | version: "1.0.3" 138 | provider: 139 | dependency: "direct main" 140 | description: 141 | name: provider 142 | url: "https://pub.dartlang.org" 143 | source: hosted 144 | version: "4.3.2+2" 145 | sky_engine: 146 | dependency: transitive 147 | description: flutter 148 | source: sdk 149 | version: "0.0.99" 150 | source_span: 151 | dependency: transitive 152 | description: 153 | name: source_span 154 | url: "https://pub.dartlang.org" 155 | source: hosted 156 | version: "1.8.0-nullsafety.4" 157 | stack_trace: 158 | dependency: transitive 159 | description: 160 | name: stack_trace 161 | url: "https://pub.dartlang.org" 162 | source: hosted 163 | version: "1.10.0-nullsafety.6" 164 | stream_channel: 165 | dependency: transitive 166 | description: 167 | name: stream_channel 168 | url: "https://pub.dartlang.org" 169 | source: hosted 170 | version: "2.1.0-nullsafety.3" 171 | string_scanner: 172 | dependency: transitive 173 | description: 174 | name: string_scanner 175 | url: "https://pub.dartlang.org" 176 | source: hosted 177 | version: "1.1.0-nullsafety.3" 178 | term_glyph: 179 | dependency: transitive 180 | description: 181 | name: term_glyph 182 | url: "https://pub.dartlang.org" 183 | source: hosted 184 | version: "1.2.0-nullsafety.3" 185 | test_api: 186 | dependency: transitive 187 | description: 188 | name: test_api 189 | url: "https://pub.dartlang.org" 190 | source: hosted 191 | version: "0.2.19-nullsafety.6" 192 | typed_data: 193 | dependency: transitive 194 | description: 195 | name: typed_data 196 | url: "https://pub.dartlang.org" 197 | source: hosted 198 | version: "1.3.0-nullsafety.5" 199 | url_launcher: 200 | dependency: "direct main" 201 | description: 202 | name: url_launcher 203 | url: "https://pub.dartlang.org" 204 | source: hosted 205 | version: "5.7.10" 206 | url_launcher_linux: 207 | dependency: transitive 208 | description: 209 | name: url_launcher_linux 210 | url: "https://pub.dartlang.org" 211 | source: hosted 212 | version: "0.0.1+4" 213 | url_launcher_macos: 214 | dependency: transitive 215 | description: 216 | name: url_launcher_macos 217 | url: "https://pub.dartlang.org" 218 | source: hosted 219 | version: "0.0.1+9" 220 | url_launcher_platform_interface: 221 | dependency: transitive 222 | description: 223 | name: url_launcher_platform_interface 224 | url: "https://pub.dartlang.org" 225 | source: hosted 226 | version: "1.0.9" 227 | url_launcher_web: 228 | dependency: transitive 229 | description: 230 | name: url_launcher_web 231 | url: "https://pub.dartlang.org" 232 | source: hosted 233 | version: "0.1.5+1" 234 | url_launcher_windows: 235 | dependency: transitive 236 | description: 237 | name: url_launcher_windows 238 | url: "https://pub.dartlang.org" 239 | source: hosted 240 | version: "0.0.1+3" 241 | vector_math: 242 | dependency: transitive 243 | description: 244 | name: vector_math 245 | url: "https://pub.dartlang.org" 246 | source: hosted 247 | version: "2.1.0-nullsafety.5" 248 | sdks: 249 | dart: ">=2.12.0-0.0 <3.0.0" 250 | flutter: ">=1.22.0 <2.0.0" 251 | -------------------------------------------------------------------------------- /lib/blocked_animation.dart: -------------------------------------------------------------------------------- 1 | import 'package:flutter/material.dart'; 2 | import 'package:flutter/rendering.dart'; 3 | import 'package:flutter_hooks/flutter_hooks.dart'; 4 | 5 | class BlockedAnimation extends HookWidget { 6 | @override 7 | Widget build(BuildContext context) { 8 | final scrollController = useScrollController(); 9 | final screenHeight = MediaQuery.of(context).size.height - 10 | MediaQuery.of(context).padding.top - 11 | kToolbarHeight; 12 | return Scaffold( 13 | appBar: AppBar( 14 | title: Text('Animate on scroll'), 15 | ), 16 | body: Scrollbar( 17 | controller: scrollController, 18 | isAlwaysShown: true, 19 | child: CustomScrollView( 20 | controller: scrollController, 21 | slivers: [ 22 | _SimplePage(screenHeight: screenHeight, text: 'Scroll down'), 23 | SliverPersistentHeader( 24 | delegate: MyHeaderDelegate(screenHeight: screenHeight), 25 | ), 26 | _SimplePage(screenHeight: screenHeight, text: 'Scroll up'), 27 | ], 28 | ), 29 | ), 30 | ); 31 | } 32 | } 33 | 34 | class _SimplePage extends StatelessWidget { 35 | const _SimplePage({ 36 | Key key, 37 | @required this.screenHeight, 38 | @required this.text, 39 | }) : super(key: key); 40 | 41 | final double screenHeight; 42 | final String text; 43 | 44 | @override 45 | Widget build(BuildContext context) { 46 | return SliverToBoxAdapter( 47 | child: Container( 48 | alignment: Alignment.center, 49 | height: screenHeight, 50 | color: Color.fromARGB(255, 241, 241, 241), 51 | child: Text( 52 | text, 53 | style: TextStyle(fontSize: 26, fontWeight: FontWeight.bold), 54 | ), 55 | ), 56 | ); 57 | } 58 | } 59 | 60 | class MyHeaderDelegate extends SliverPersistentHeaderDelegate { 61 | final double screenHeight; 62 | 63 | MyHeaderDelegate({@required this.screenHeight}); 64 | 65 | @override 66 | double get maxExtent => 2 * screenHeight; 67 | 68 | @override 69 | double get minExtent => screenHeight; 70 | 71 | @override 72 | Widget build( 73 | BuildContext context, double shrinkOffset, bool overlapsContent) { 74 | final screenWidth = MediaQuery.of(context).size.width; 75 | final percentageDone = 76 | (shrinkOffset / (maxExtent - minExtent)).clamp(0.0, 1.0); 77 | 78 | return Container( 79 | height: double.infinity, 80 | alignment: Alignment.topCenter, 81 | child: SizedBox( 82 | height: screenHeight, 83 | child: Stack( 84 | children: [ 85 | Image1( 86 | percentageDone: percentageDone, 87 | screenHeight: screenHeight, 88 | screenWidth: screenWidth, 89 | ), 90 | Text1( 91 | percentageDone: percentageDone, 92 | screenWidth: screenWidth, 93 | ), 94 | Image2( 95 | percentageDone: percentageDone, 96 | screenHeight: screenHeight, 97 | screenWidth: screenWidth, 98 | ), 99 | Square( 100 | percentageDone: percentageDone, 101 | screenHeight: screenHeight, 102 | ), 103 | ], 104 | ), 105 | ), 106 | ); 107 | } 108 | 109 | @override 110 | bool shouldRebuild(covariant SliverPersistentHeaderDelegate oldDelegate) { 111 | return true; 112 | } 113 | } 114 | 115 | class Square extends StatelessWidget { 116 | const Square({ 117 | Key key, 118 | @required this.percentageDone, 119 | @required this.screenHeight, 120 | }) : super(key: key); 121 | 122 | final double percentageDone; 123 | final double screenHeight; 124 | 125 | @override 126 | Widget build(BuildContext context) { 127 | final squareStep1 = (percentageDone * 2).clamp(0.0, 1.0); 128 | final squareStep2 = ((percentageDone - 0.67) * 3).clamp(0.0, 1.0); 129 | return Align( 130 | alignment: Alignment(0.16 * squareStep2, 0), 131 | child: Container( 132 | width: 133 | squareStep1 * screenHeight * 0.1 + squareStep2 * screenHeight * 0.1, 134 | height: 135 | squareStep1 * screenHeight * 0.1 + squareStep2 * screenHeight * 0.1, 136 | decoration: BoxDecoration( 137 | border: Border.all( 138 | width: 4 + 8 * squareStep2, 139 | color: Color.lerp(Colors.white, Colors.grey, squareStep2) 140 | .withOpacity(squareStep1), 141 | ), 142 | ), 143 | ), 144 | ); 145 | } 146 | } 147 | 148 | class Image2 extends StatelessWidget { 149 | const Image2({ 150 | Key key, 151 | @required this.percentageDone, 152 | @required this.screenHeight, 153 | @required this.screenWidth, 154 | }) : super(key: key); 155 | 156 | final double percentageDone; 157 | final double screenHeight; 158 | final double screenWidth; 159 | 160 | @override 161 | Widget build(BuildContext context) { 162 | final bottomImagePercentage = ((percentageDone - 0.5) * 2).clamp(0.0, 1.0); 163 | return Align( 164 | alignment: Alignment(0.35 - 0.4 * bottomImagePercentage, 0.6), 165 | child: Opacity( 166 | opacity: bottomImagePercentage, 167 | child: Image.asset( 168 | 'images/image1.jpg', 169 | height: screenHeight / 3.5, 170 | width: screenWidth / 4.5, 171 | fit: BoxFit.cover, 172 | ), 173 | ), 174 | ); 175 | } 176 | } 177 | 178 | class Text1 extends StatelessWidget { 179 | const Text1({ 180 | Key key, 181 | @required this.screenWidth, 182 | @required this.percentageDone, 183 | }) : super(key: key); 184 | 185 | final double screenWidth; 186 | final double percentageDone; 187 | 188 | @override 189 | Widget build(BuildContext context) { 190 | final textPercentage = (percentageDone * 2).clamp(0.0, 1.0); 191 | 192 | return Align( 193 | alignment: Alignment(-0.3 - 0.5 * textPercentage, -0.25), 194 | child: Opacity( 195 | opacity: textPercentage, 196 | child: Column( 197 | mainAxisSize: MainAxisSize.min, 198 | crossAxisAlignment: CrossAxisAlignment.start, 199 | children: [ 200 | Text( 201 | '"You should totally subscribe to my\nchannel now"', 202 | style: TextStyle(fontSize: 40), 203 | ), 204 | const SizedBox(height: 16), 205 | Container( 206 | width: screenWidth * 0.4 * percentageDone, 207 | height: 8, 208 | color: Colors.red, 209 | ) 210 | ], 211 | ), 212 | ), 213 | ); 214 | } 215 | } 216 | 217 | class Image1 extends StatelessWidget { 218 | const Image1({ 219 | Key key, 220 | @required this.percentageDone, 221 | @required this.screenHeight, 222 | @required this.screenWidth, 223 | }) : super(key: key); 224 | 225 | final num percentageDone; 226 | final double screenHeight; 227 | final double screenWidth; 228 | 229 | @override 230 | Widget build(BuildContext context) { 231 | return Align( 232 | alignment: Alignment(0.9 * percentageDone, -0.4), 233 | child: Opacity( 234 | opacity: percentageDone, 235 | child: Image.asset( 236 | 'images/image2.jpg', 237 | height: screenHeight / 2.2, 238 | width: screenWidth / 2.5, 239 | fit: BoxFit.cover, 240 | ), 241 | ), 242 | ); 243 | } 244 | } 245 | -------------------------------------------------------------------------------- /ios/Runner.xcodeproj/project.pbxproj: -------------------------------------------------------------------------------- 1 | // !$*UTF8*$! 2 | { 3 | archiveVersion = 1; 4 | classes = { 5 | }; 6 | objectVersion = 46; 7 | objects = { 8 | 9 | /* Begin PBXBuildFile section */ 10 | 1498D2341E8E89220040F4C2 /* GeneratedPluginRegistrant.m in Sources */ = {isa = PBXBuildFile; fileRef = 1498D2331E8E89220040F4C2 /* GeneratedPluginRegistrant.m */; }; 11 | 3B3967161E833CAA004F5970 /* AppFrameworkInfo.plist in Resources */ = {isa = PBXBuildFile; fileRef = 3B3967151E833CAA004F5970 /* AppFrameworkInfo.plist */; }; 12 | 74858FAF1ED2DC5600515810 /* AppDelegate.swift in Sources */ = {isa = PBXBuildFile; fileRef = 74858FAE1ED2DC5600515810 /* AppDelegate.swift */; }; 13 | 97C146FC1CF9000F007C117D /* Main.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 97C146FA1CF9000F007C117D /* Main.storyboard */; }; 14 | 97C146FE1CF9000F007C117D /* Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 97C146FD1CF9000F007C117D /* Assets.xcassets */; }; 15 | 97C147011CF9000F007C117D /* LaunchScreen.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 97C146FF1CF9000F007C117D /* LaunchScreen.storyboard */; }; 16 | /* End PBXBuildFile section */ 17 | 18 | /* Begin PBXCopyFilesBuildPhase section */ 19 | 9705A1C41CF9048500538489 /* Embed Frameworks */ = { 20 | isa = PBXCopyFilesBuildPhase; 21 | buildActionMask = 2147483647; 22 | dstPath = ""; 23 | dstSubfolderSpec = 10; 24 | files = ( 25 | ); 26 | name = "Embed Frameworks"; 27 | runOnlyForDeploymentPostprocessing = 0; 28 | }; 29 | /* End PBXCopyFilesBuildPhase section */ 30 | 31 | /* Begin PBXFileReference section */ 32 | 1498D2321E8E86230040F4C2 /* GeneratedPluginRegistrant.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = GeneratedPluginRegistrant.h; sourceTree = ""; }; 33 | 1498D2331E8E89220040F4C2 /* GeneratedPluginRegistrant.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = GeneratedPluginRegistrant.m; sourceTree = ""; }; 34 | 3B3967151E833CAA004F5970 /* AppFrameworkInfo.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; name = AppFrameworkInfo.plist; path = Flutter/AppFrameworkInfo.plist; sourceTree = ""; }; 35 | 74858FAD1ED2DC5600515810 /* Runner-Bridging-Header.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = "Runner-Bridging-Header.h"; sourceTree = ""; }; 36 | 74858FAE1ED2DC5600515810 /* AppDelegate.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = AppDelegate.swift; sourceTree = ""; }; 37 | 7AFA3C8E1D35360C0083082E /* Release.xcconfig */ = {isa = PBXFileReference; lastKnownFileType = text.xcconfig; name = Release.xcconfig; path = Flutter/Release.xcconfig; sourceTree = ""; }; 38 | 9740EEB21CF90195004384FC /* Debug.xcconfig */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.xcconfig; name = Debug.xcconfig; path = Flutter/Debug.xcconfig; sourceTree = ""; }; 39 | 9740EEB31CF90195004384FC /* Generated.xcconfig */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.xcconfig; name = Generated.xcconfig; path = Flutter/Generated.xcconfig; sourceTree = ""; }; 40 | 97C146EE1CF9000F007C117D /* Runner.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = Runner.app; sourceTree = BUILT_PRODUCTS_DIR; }; 41 | 97C146FB1CF9000F007C117D /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/Main.storyboard; sourceTree = ""; }; 42 | 97C146FD1CF9000F007C117D /* Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Assets.xcassets; sourceTree = ""; }; 43 | 97C147001CF9000F007C117D /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/LaunchScreen.storyboard; sourceTree = ""; }; 44 | 97C147021CF9000F007C117D /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; 45 | /* End PBXFileReference section */ 46 | 47 | /* Begin PBXFrameworksBuildPhase section */ 48 | 97C146EB1CF9000F007C117D /* Frameworks */ = { 49 | isa = PBXFrameworksBuildPhase; 50 | buildActionMask = 2147483647; 51 | files = ( 52 | ); 53 | runOnlyForDeploymentPostprocessing = 0; 54 | }; 55 | /* End PBXFrameworksBuildPhase section */ 56 | 57 | /* Begin PBXGroup section */ 58 | 9740EEB11CF90186004384FC /* Flutter */ = { 59 | isa = PBXGroup; 60 | children = ( 61 | 3B3967151E833CAA004F5970 /* AppFrameworkInfo.plist */, 62 | 9740EEB21CF90195004384FC /* Debug.xcconfig */, 63 | 7AFA3C8E1D35360C0083082E /* Release.xcconfig */, 64 | 9740EEB31CF90195004384FC /* Generated.xcconfig */, 65 | ); 66 | name = Flutter; 67 | sourceTree = ""; 68 | }; 69 | 97C146E51CF9000F007C117D = { 70 | isa = PBXGroup; 71 | children = ( 72 | 9740EEB11CF90186004384FC /* Flutter */, 73 | 97C146F01CF9000F007C117D /* Runner */, 74 | 97C146EF1CF9000F007C117D /* Products */, 75 | ); 76 | sourceTree = ""; 77 | }; 78 | 97C146EF1CF9000F007C117D /* Products */ = { 79 | isa = PBXGroup; 80 | children = ( 81 | 97C146EE1CF9000F007C117D /* Runner.app */, 82 | ); 83 | name = Products; 84 | sourceTree = ""; 85 | }; 86 | 97C146F01CF9000F007C117D /* Runner */ = { 87 | isa = PBXGroup; 88 | children = ( 89 | 97C146FA1CF9000F007C117D /* Main.storyboard */, 90 | 97C146FD1CF9000F007C117D /* Assets.xcassets */, 91 | 97C146FF1CF9000F007C117D /* LaunchScreen.storyboard */, 92 | 97C147021CF9000F007C117D /* Info.plist */, 93 | 1498D2321E8E86230040F4C2 /* GeneratedPluginRegistrant.h */, 94 | 1498D2331E8E89220040F4C2 /* GeneratedPluginRegistrant.m */, 95 | 74858FAE1ED2DC5600515810 /* AppDelegate.swift */, 96 | 74858FAD1ED2DC5600515810 /* Runner-Bridging-Header.h */, 97 | ); 98 | path = Runner; 99 | sourceTree = ""; 100 | }; 101 | /* End PBXGroup section */ 102 | 103 | /* Begin PBXNativeTarget section */ 104 | 97C146ED1CF9000F007C117D /* Runner */ = { 105 | isa = PBXNativeTarget; 106 | buildConfigurationList = 97C147051CF9000F007C117D /* Build configuration list for PBXNativeTarget "Runner" */; 107 | buildPhases = ( 108 | 9740EEB61CF901F6004384FC /* Run Script */, 109 | 97C146EA1CF9000F007C117D /* Sources */, 110 | 97C146EB1CF9000F007C117D /* Frameworks */, 111 | 97C146EC1CF9000F007C117D /* Resources */, 112 | 9705A1C41CF9048500538489 /* Embed Frameworks */, 113 | 3B06AD1E1E4923F5004D2608 /* Thin Binary */, 114 | ); 115 | buildRules = ( 116 | ); 117 | dependencies = ( 118 | ); 119 | name = Runner; 120 | productName = Runner; 121 | productReference = 97C146EE1CF9000F007C117D /* Runner.app */; 122 | productType = "com.apple.product-type.application"; 123 | }; 124 | /* End PBXNativeTarget section */ 125 | 126 | /* Begin PBXProject section */ 127 | 97C146E61CF9000F007C117D /* Project object */ = { 128 | isa = PBXProject; 129 | attributes = { 130 | LastUpgradeCheck = 1020; 131 | ORGANIZATIONNAME = ""; 132 | TargetAttributes = { 133 | 97C146ED1CF9000F007C117D = { 134 | CreatedOnToolsVersion = 7.3.1; 135 | LastSwiftMigration = 1100; 136 | }; 137 | }; 138 | }; 139 | buildConfigurationList = 97C146E91CF9000F007C117D /* Build configuration list for PBXProject "Runner" */; 140 | compatibilityVersion = "Xcode 9.3"; 141 | developmentRegion = en; 142 | hasScannedForEncodings = 0; 143 | knownRegions = ( 144 | en, 145 | Base, 146 | ); 147 | mainGroup = 97C146E51CF9000F007C117D; 148 | productRefGroup = 97C146EF1CF9000F007C117D /* Products */; 149 | projectDirPath = ""; 150 | projectRoot = ""; 151 | targets = ( 152 | 97C146ED1CF9000F007C117D /* Runner */, 153 | ); 154 | }; 155 | /* End PBXProject section */ 156 | 157 | /* Begin PBXResourcesBuildPhase section */ 158 | 97C146EC1CF9000F007C117D /* Resources */ = { 159 | isa = PBXResourcesBuildPhase; 160 | buildActionMask = 2147483647; 161 | files = ( 162 | 97C147011CF9000F007C117D /* LaunchScreen.storyboard in Resources */, 163 | 3B3967161E833CAA004F5970 /* AppFrameworkInfo.plist in Resources */, 164 | 97C146FE1CF9000F007C117D /* Assets.xcassets in Resources */, 165 | 97C146FC1CF9000F007C117D /* Main.storyboard in Resources */, 166 | ); 167 | runOnlyForDeploymentPostprocessing = 0; 168 | }; 169 | /* End PBXResourcesBuildPhase section */ 170 | 171 | /* Begin PBXShellScriptBuildPhase section */ 172 | 3B06AD1E1E4923F5004D2608 /* Thin Binary */ = { 173 | isa = PBXShellScriptBuildPhase; 174 | buildActionMask = 2147483647; 175 | files = ( 176 | ); 177 | inputPaths = ( 178 | ); 179 | name = "Thin Binary"; 180 | outputPaths = ( 181 | ); 182 | runOnlyForDeploymentPostprocessing = 0; 183 | shellPath = /bin/sh; 184 | shellScript = "/bin/sh \"$FLUTTER_ROOT/packages/flutter_tools/bin/xcode_backend.sh\" embed_and_thin"; 185 | }; 186 | 9740EEB61CF901F6004384FC /* Run Script */ = { 187 | isa = PBXShellScriptBuildPhase; 188 | buildActionMask = 2147483647; 189 | files = ( 190 | ); 191 | inputPaths = ( 192 | ); 193 | name = "Run Script"; 194 | outputPaths = ( 195 | ); 196 | runOnlyForDeploymentPostprocessing = 0; 197 | shellPath = /bin/sh; 198 | shellScript = "/bin/sh \"$FLUTTER_ROOT/packages/flutter_tools/bin/xcode_backend.sh\" build"; 199 | }; 200 | /* End PBXShellScriptBuildPhase section */ 201 | 202 | /* Begin PBXSourcesBuildPhase section */ 203 | 97C146EA1CF9000F007C117D /* Sources */ = { 204 | isa = PBXSourcesBuildPhase; 205 | buildActionMask = 2147483647; 206 | files = ( 207 | 74858FAF1ED2DC5600515810 /* AppDelegate.swift in Sources */, 208 | 1498D2341E8E89220040F4C2 /* GeneratedPluginRegistrant.m in Sources */, 209 | ); 210 | runOnlyForDeploymentPostprocessing = 0; 211 | }; 212 | /* End PBXSourcesBuildPhase section */ 213 | 214 | /* Begin PBXVariantGroup section */ 215 | 97C146FA1CF9000F007C117D /* Main.storyboard */ = { 216 | isa = PBXVariantGroup; 217 | children = ( 218 | 97C146FB1CF9000F007C117D /* Base */, 219 | ); 220 | name = Main.storyboard; 221 | sourceTree = ""; 222 | }; 223 | 97C146FF1CF9000F007C117D /* LaunchScreen.storyboard */ = { 224 | isa = PBXVariantGroup; 225 | children = ( 226 | 97C147001CF9000F007C117D /* Base */, 227 | ); 228 | name = LaunchScreen.storyboard; 229 | sourceTree = ""; 230 | }; 231 | /* End PBXVariantGroup section */ 232 | 233 | /* Begin XCBuildConfiguration section */ 234 | 249021D3217E4FDB00AE95B9 /* Profile */ = { 235 | isa = XCBuildConfiguration; 236 | buildSettings = { 237 | ALWAYS_SEARCH_USER_PATHS = NO; 238 | CLANG_ANALYZER_NONNULL = YES; 239 | CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; 240 | CLANG_CXX_LIBRARY = "libc++"; 241 | CLANG_ENABLE_MODULES = YES; 242 | CLANG_ENABLE_OBJC_ARC = YES; 243 | CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; 244 | CLANG_WARN_BOOL_CONVERSION = YES; 245 | CLANG_WARN_COMMA = YES; 246 | CLANG_WARN_CONSTANT_CONVERSION = YES; 247 | CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; 248 | CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; 249 | CLANG_WARN_EMPTY_BODY = YES; 250 | CLANG_WARN_ENUM_CONVERSION = YES; 251 | CLANG_WARN_INFINITE_RECURSION = YES; 252 | CLANG_WARN_INT_CONVERSION = YES; 253 | CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; 254 | CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES; 255 | CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; 256 | CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; 257 | CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; 258 | CLANG_WARN_STRICT_PROTOTYPES = YES; 259 | CLANG_WARN_SUSPICIOUS_MOVE = YES; 260 | CLANG_WARN_UNREACHABLE_CODE = YES; 261 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; 262 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; 263 | COPY_PHASE_STRIP = NO; 264 | DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; 265 | ENABLE_NS_ASSERTIONS = NO; 266 | ENABLE_STRICT_OBJC_MSGSEND = YES; 267 | GCC_C_LANGUAGE_STANDARD = gnu99; 268 | GCC_NO_COMMON_BLOCKS = YES; 269 | GCC_WARN_64_TO_32_BIT_CONVERSION = YES; 270 | GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; 271 | GCC_WARN_UNDECLARED_SELECTOR = YES; 272 | GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; 273 | GCC_WARN_UNUSED_FUNCTION = YES; 274 | GCC_WARN_UNUSED_VARIABLE = YES; 275 | IPHONEOS_DEPLOYMENT_TARGET = 9.0; 276 | MTL_ENABLE_DEBUG_INFO = NO; 277 | SDKROOT = iphoneos; 278 | SUPPORTED_PLATFORMS = iphoneos; 279 | TARGETED_DEVICE_FAMILY = "1,2"; 280 | VALIDATE_PRODUCT = YES; 281 | }; 282 | name = Profile; 283 | }; 284 | 249021D4217E4FDB00AE95B9 /* Profile */ = { 285 | isa = XCBuildConfiguration; 286 | baseConfigurationReference = 7AFA3C8E1D35360C0083082E /* Release.xcconfig */; 287 | buildSettings = { 288 | ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; 289 | CLANG_ENABLE_MODULES = YES; 290 | CURRENT_PROJECT_VERSION = "$(FLUTTER_BUILD_NUMBER)"; 291 | ENABLE_BITCODE = NO; 292 | FRAMEWORK_SEARCH_PATHS = ( 293 | "$(inherited)", 294 | "$(PROJECT_DIR)/Flutter", 295 | ); 296 | INFOPLIST_FILE = Runner/Info.plist; 297 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; 298 | LIBRARY_SEARCH_PATHS = ( 299 | "$(inherited)", 300 | "$(PROJECT_DIR)/Flutter", 301 | ); 302 | PRODUCT_BUNDLE_IDENTIFIER = com.example.scrollToPerfection; 303 | PRODUCT_NAME = "$(TARGET_NAME)"; 304 | SWIFT_OBJC_BRIDGING_HEADER = "Runner/Runner-Bridging-Header.h"; 305 | SWIFT_VERSION = 5.0; 306 | VERSIONING_SYSTEM = "apple-generic"; 307 | }; 308 | name = Profile; 309 | }; 310 | 97C147031CF9000F007C117D /* Debug */ = { 311 | isa = XCBuildConfiguration; 312 | buildSettings = { 313 | ALWAYS_SEARCH_USER_PATHS = NO; 314 | CLANG_ANALYZER_NONNULL = YES; 315 | CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; 316 | CLANG_CXX_LIBRARY = "libc++"; 317 | CLANG_ENABLE_MODULES = YES; 318 | CLANG_ENABLE_OBJC_ARC = YES; 319 | CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; 320 | CLANG_WARN_BOOL_CONVERSION = YES; 321 | CLANG_WARN_COMMA = YES; 322 | CLANG_WARN_CONSTANT_CONVERSION = YES; 323 | CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; 324 | CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; 325 | CLANG_WARN_EMPTY_BODY = YES; 326 | CLANG_WARN_ENUM_CONVERSION = YES; 327 | CLANG_WARN_INFINITE_RECURSION = YES; 328 | CLANG_WARN_INT_CONVERSION = YES; 329 | CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; 330 | CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES; 331 | CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; 332 | CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; 333 | CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; 334 | CLANG_WARN_STRICT_PROTOTYPES = YES; 335 | CLANG_WARN_SUSPICIOUS_MOVE = YES; 336 | CLANG_WARN_UNREACHABLE_CODE = YES; 337 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; 338 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; 339 | COPY_PHASE_STRIP = NO; 340 | DEBUG_INFORMATION_FORMAT = dwarf; 341 | ENABLE_STRICT_OBJC_MSGSEND = YES; 342 | ENABLE_TESTABILITY = YES; 343 | GCC_C_LANGUAGE_STANDARD = gnu99; 344 | GCC_DYNAMIC_NO_PIC = NO; 345 | GCC_NO_COMMON_BLOCKS = YES; 346 | GCC_OPTIMIZATION_LEVEL = 0; 347 | GCC_PREPROCESSOR_DEFINITIONS = ( 348 | "DEBUG=1", 349 | "$(inherited)", 350 | ); 351 | GCC_WARN_64_TO_32_BIT_CONVERSION = YES; 352 | GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; 353 | GCC_WARN_UNDECLARED_SELECTOR = YES; 354 | GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; 355 | GCC_WARN_UNUSED_FUNCTION = YES; 356 | GCC_WARN_UNUSED_VARIABLE = YES; 357 | IPHONEOS_DEPLOYMENT_TARGET = 9.0; 358 | MTL_ENABLE_DEBUG_INFO = YES; 359 | ONLY_ACTIVE_ARCH = YES; 360 | SDKROOT = iphoneos; 361 | TARGETED_DEVICE_FAMILY = "1,2"; 362 | }; 363 | name = Debug; 364 | }; 365 | 97C147041CF9000F007C117D /* Release */ = { 366 | isa = XCBuildConfiguration; 367 | buildSettings = { 368 | ALWAYS_SEARCH_USER_PATHS = NO; 369 | CLANG_ANALYZER_NONNULL = YES; 370 | CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; 371 | CLANG_CXX_LIBRARY = "libc++"; 372 | CLANG_ENABLE_MODULES = YES; 373 | CLANG_ENABLE_OBJC_ARC = YES; 374 | CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; 375 | CLANG_WARN_BOOL_CONVERSION = YES; 376 | CLANG_WARN_COMMA = YES; 377 | CLANG_WARN_CONSTANT_CONVERSION = YES; 378 | CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; 379 | CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; 380 | CLANG_WARN_EMPTY_BODY = YES; 381 | CLANG_WARN_ENUM_CONVERSION = YES; 382 | CLANG_WARN_INFINITE_RECURSION = YES; 383 | CLANG_WARN_INT_CONVERSION = YES; 384 | CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; 385 | CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES; 386 | CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; 387 | CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; 388 | CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; 389 | CLANG_WARN_STRICT_PROTOTYPES = YES; 390 | CLANG_WARN_SUSPICIOUS_MOVE = YES; 391 | CLANG_WARN_UNREACHABLE_CODE = YES; 392 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; 393 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; 394 | COPY_PHASE_STRIP = NO; 395 | DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; 396 | ENABLE_NS_ASSERTIONS = NO; 397 | ENABLE_STRICT_OBJC_MSGSEND = YES; 398 | GCC_C_LANGUAGE_STANDARD = gnu99; 399 | GCC_NO_COMMON_BLOCKS = YES; 400 | GCC_WARN_64_TO_32_BIT_CONVERSION = YES; 401 | GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; 402 | GCC_WARN_UNDECLARED_SELECTOR = YES; 403 | GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; 404 | GCC_WARN_UNUSED_FUNCTION = YES; 405 | GCC_WARN_UNUSED_VARIABLE = YES; 406 | IPHONEOS_DEPLOYMENT_TARGET = 9.0; 407 | MTL_ENABLE_DEBUG_INFO = NO; 408 | SDKROOT = iphoneos; 409 | SUPPORTED_PLATFORMS = iphoneos; 410 | SWIFT_OPTIMIZATION_LEVEL = "-Owholemodule"; 411 | TARGETED_DEVICE_FAMILY = "1,2"; 412 | VALIDATE_PRODUCT = YES; 413 | }; 414 | name = Release; 415 | }; 416 | 97C147061CF9000F007C117D /* Debug */ = { 417 | isa = XCBuildConfiguration; 418 | baseConfigurationReference = 9740EEB21CF90195004384FC /* Debug.xcconfig */; 419 | buildSettings = { 420 | ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; 421 | CLANG_ENABLE_MODULES = YES; 422 | CURRENT_PROJECT_VERSION = "$(FLUTTER_BUILD_NUMBER)"; 423 | ENABLE_BITCODE = NO; 424 | FRAMEWORK_SEARCH_PATHS = ( 425 | "$(inherited)", 426 | "$(PROJECT_DIR)/Flutter", 427 | ); 428 | INFOPLIST_FILE = Runner/Info.plist; 429 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; 430 | LIBRARY_SEARCH_PATHS = ( 431 | "$(inherited)", 432 | "$(PROJECT_DIR)/Flutter", 433 | ); 434 | PRODUCT_BUNDLE_IDENTIFIER = com.example.scrollToPerfection; 435 | PRODUCT_NAME = "$(TARGET_NAME)"; 436 | SWIFT_OBJC_BRIDGING_HEADER = "Runner/Runner-Bridging-Header.h"; 437 | SWIFT_OPTIMIZATION_LEVEL = "-Onone"; 438 | SWIFT_VERSION = 5.0; 439 | VERSIONING_SYSTEM = "apple-generic"; 440 | }; 441 | name = Debug; 442 | }; 443 | 97C147071CF9000F007C117D /* Release */ = { 444 | isa = XCBuildConfiguration; 445 | baseConfigurationReference = 7AFA3C8E1D35360C0083082E /* Release.xcconfig */; 446 | buildSettings = { 447 | ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; 448 | CLANG_ENABLE_MODULES = YES; 449 | CURRENT_PROJECT_VERSION = "$(FLUTTER_BUILD_NUMBER)"; 450 | ENABLE_BITCODE = NO; 451 | FRAMEWORK_SEARCH_PATHS = ( 452 | "$(inherited)", 453 | "$(PROJECT_DIR)/Flutter", 454 | ); 455 | INFOPLIST_FILE = Runner/Info.plist; 456 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; 457 | LIBRARY_SEARCH_PATHS = ( 458 | "$(inherited)", 459 | "$(PROJECT_DIR)/Flutter", 460 | ); 461 | PRODUCT_BUNDLE_IDENTIFIER = com.example.scrollToPerfection; 462 | PRODUCT_NAME = "$(TARGET_NAME)"; 463 | SWIFT_OBJC_BRIDGING_HEADER = "Runner/Runner-Bridging-Header.h"; 464 | SWIFT_VERSION = 5.0; 465 | VERSIONING_SYSTEM = "apple-generic"; 466 | }; 467 | name = Release; 468 | }; 469 | /* End XCBuildConfiguration section */ 470 | 471 | /* Begin XCConfigurationList section */ 472 | 97C146E91CF9000F007C117D /* Build configuration list for PBXProject "Runner" */ = { 473 | isa = XCConfigurationList; 474 | buildConfigurations = ( 475 | 97C147031CF9000F007C117D /* Debug */, 476 | 97C147041CF9000F007C117D /* Release */, 477 | 249021D3217E4FDB00AE95B9 /* Profile */, 478 | ); 479 | defaultConfigurationIsVisible = 0; 480 | defaultConfigurationName = Release; 481 | }; 482 | 97C147051CF9000F007C117D /* Build configuration list for PBXNativeTarget "Runner" */ = { 483 | isa = XCConfigurationList; 484 | buildConfigurations = ( 485 | 97C147061CF9000F007C117D /* Debug */, 486 | 97C147071CF9000F007C117D /* Release */, 487 | 249021D4217E4FDB00AE95B9 /* Profile */, 488 | ); 489 | defaultConfigurationIsVisible = 0; 490 | defaultConfigurationName = Release; 491 | }; 492 | /* End XCConfigurationList section */ 493 | }; 494 | rootObject = 97C146E61CF9000F007C117D /* Project object */; 495 | } 496 | --------------------------------------------------------------------------------