├── .gitignore ├── .metadata ├── README.md ├── analysis_options.yaml ├── android ├── .gitignore ├── app │ ├── build.gradle │ └── src │ │ ├── debug │ │ └── AndroidManifest.xml │ │ ├── main │ │ ├── AndroidManifest.xml │ │ ├── kotlin │ │ │ └── io │ │ │ │ └── appwrite │ │ │ │ └── netflix_clone │ │ │ │ └── MainActivity.kt │ │ └── res │ │ │ ├── drawable-v21 │ │ │ └── launch_background.xml │ │ │ ├── drawable │ │ │ └── launch_background.xml │ │ │ ├── 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 │ │ │ ├── values-night │ │ │ └── styles.xml │ │ │ └── values │ │ │ └── styles.xml │ │ └── profile │ │ └── AndroidManifest.xml ├── build.gradle ├── gradle.properties ├── gradle │ └── wrapper │ │ └── gradle-wrapper.properties └── settings.gradle ├── assets ├── bg.png ├── logo.png ├── logo.svg ├── netflix_logo0.png └── netflix_logo1.png ├── ios ├── .gitignore ├── Flutter │ ├── AppFrameworkInfo.plist │ ├── Debug.xcconfig │ └── Release.xcconfig ├── Podfile ├── Podfile.lock ├── Runner.xcodeproj │ ├── project.pbxproj │ ├── project.xcworkspace │ │ ├── contents.xcworkspacedata │ │ └── xcshareddata │ │ │ ├── IDEWorkspaceChecks.plist │ │ │ └── WorkspaceSettings.xcsettings │ └── xcshareddata │ │ └── xcschemes │ │ └── Runner.xcscheme ├── Runner.xcworkspace │ ├── contents.xcworkspacedata │ └── xcshareddata │ │ ├── IDEWorkspaceChecks.plist │ │ └── WorkspaceSettings.xcsettings └── Runner │ ├── AppDelegate.swift │ ├── Assets.xcassets │ ├── AppIcon.appiconset │ │ ├── Contents.json │ │ ├── Icon-App-1024x1024@1x.png │ │ ├── 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-83.5x83.5@2x.png │ └── LaunchImage.imageset │ │ ├── Contents.json │ │ ├── LaunchImage.png │ │ ├── LaunchImage@2x.png │ │ ├── LaunchImage@3x.png │ │ └── README.md │ ├── Base.lproj │ ├── LaunchScreen.storyboard │ └── Main.storyboard │ ├── Info.plist │ └── Runner-Bridging-Header.h ├── lib ├── api │ └── client.dart ├── assets.dart ├── data │ ├── entry.dart │ ├── store.dart │ └── watchlist.dart ├── extensions │ ├── color.dart │ ├── datetime.dart │ ├── list.dart │ └── num.dart ├── main.dart ├── providers │ ├── account.dart │ ├── entry.dart │ └── watchlist.dart ├── screens │ ├── details.dart │ ├── home.dart │ ├── navigation.dart │ ├── onboarding.dart │ └── watchlist.dart └── widgets │ ├── buttons │ └── icon.dart │ ├── content │ ├── bar.dart │ ├── header.dart │ └── list.dart │ └── previews.dart ├── pubspec.lock ├── pubspec.yaml ├── readme_banner.png └── test └── widget_test.dart /.gitignore: -------------------------------------------------------------------------------- 1 | # Miscellaneous 2 | *.class 3 | *.log 4 | *.pyc 5 | *.swp 6 | .DS_Store 7 | .atom/ 8 | .buildlog/ 9 | .history 10 | .svn/ 11 | .vscode 12 | 13 | # IntelliJ related 14 | *.iml 15 | *.ipr 16 | *.iws 17 | .idea/ 18 | 19 | # The .vscode folder contains launch configuration and tasks you configure in 20 | # VS Code which you may wish to be included in version control, so this line 21 | # is commented out by default. 22 | #.vscode/ 23 | 24 | # Flutter/Dart/Pub related 25 | **/doc/api/ 26 | **/ios/Flutter/.last_build_id 27 | .dart_tool/ 28 | .flutter-plugins 29 | .flutter-plugins-dependencies 30 | .packages 31 | .pub-cache/ 32 | .pub/ 33 | /build/ 34 | 35 | # Web related 36 | lib/generated_plugin_registrant.dart 37 | 38 | # Symbolication related 39 | app.*.symbols 40 | 41 | # Obfuscation related 42 | app.*.map.json 43 | 44 | # Android Studio will place build artifacts here 45 | /android/app/debug 46 | /android/app/profile 47 | /android/app/release 48 | 49 | ### Flutter ### 50 | # Flutter/Dart/Pub related 51 | **/doc/api/ 52 | .dart_tool/ 53 | .flutter-plugins 54 | .flutter-plugins-dependencies 55 | .fvm/ 56 | .packages 57 | .pub-cache/ 58 | .pub/ 59 | build/ 60 | coverage/ 61 | lib/generated_plugin_registrant.dart 62 | 63 | # Android related 64 | **/android/**/gradle-wrapper.jar 65 | **/android/.gradle 66 | **/android/captures/ 67 | **/android/gradlew 68 | **/android/gradlew.bat 69 | **/android/key.properties 70 | **/android/local.properties 71 | **/android/**/GeneratedPluginRegistrant.java 72 | 73 | # iOS/XCode related 74 | **/ios/**/*.mode1v3 75 | **/ios/**/*.mode2v3 76 | **/ios/**/*.moved-aside 77 | **/ios/**/*.pbxuser 78 | **/ios/**/*.perspectivev3 79 | **/ios/**/*sync/ 80 | **/ios/**/.sconsign.dblite 81 | **/ios/**/.tags* 82 | **/ios/**/.vagrant/ 83 | **/ios/**/DerivedData/ 84 | **/ios/**/Icon? 85 | **/ios/**/Pods/ 86 | **/ios/**/.symlinks/ 87 | **/ios/**/profile 88 | **/ios/**/xcuserdata 89 | **/ios/.generated/ 90 | **/ios/Flutter/.last_build_id 91 | **/ios/Flutter/App.framework 92 | **/ios/Flutter/Flutter.framework 93 | **/ios/Flutter/Flutter.podspec 94 | **/ios/Flutter/Generated.xcconfig 95 | **/ios/Flutter/app.flx 96 | **/ios/Flutter/app.zip 97 | **/ios/Flutter/flutter_assets/ 98 | **/ios/Flutter/flutter_export_environment.sh 99 | **/ios/ServiceDefinitions.json 100 | **/ios/Runner/GeneratedPluginRegistrant.* 101 | 102 | # Exceptions to above rules. 103 | !**/ios/**/default.mode1v3 104 | !**/ios/**/default.mode2v3 105 | !**/ios/**/default.pbxuser 106 | !**/ios/**/default.perspectivev3 107 | !/packages/flutter_tools/test/data/dart_dependencies_test/**/.packages 108 | 109 | 110 | 111 | -------------------------------------------------------------------------------- /.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: 77d935af4db863f6abd0b9c31c7e6df2a13de57b 8 | channel: stable 9 | 10 | project_type: app 11 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # Almost Netflix - Flutter 2 | 3 | 4 | ![Banner](readme_banner.png) 5 | 6 | ## Requirements 7 | 8 | Before using this project, you will need to have Appwrite instance with Almost Netflix project ready. You can visit Project setup [GitHub repository](https://github.com/Meldiron/almost-netflix-project-setup) or [Dev.to post](https://dev.to/appwrite/did-we-just-build-a-netflix-clone-with-appwrite-28ok). 9 | 10 | ## Usage 11 | 12 | ```bash 13 | $ git clone https://github.com/appwrite/demo-almost-netflix-for-flutter.git 14 | $ cd demo-almost-netflix-for-flutter 15 | $ open -a Simulator.app 16 | $ flutter run 17 | ``` 18 | 19 | Make sure to update Endpoint and ProjectID in `lib/api/client.dart`. 20 | 21 | The application will be listening on port `3000`. You can visit in on URL `http://localhost:3000`. 22 | 23 | 24 | ### `assets` 25 | 26 | The assets directory contains your images such as logos as well as anything else you would like your project to use, be sure to update `pubspec.yaml` with any addition folders. 27 | 28 | More information about assets can be found in [the documentation](https://docs.flutter.dev/development/ui/assets-and-images). 29 | 30 | ### `lib/api` 31 | 32 | The `lib/api` folder contains our API request client that is used for communicating with Appwrite endpoints. 33 | 34 | ### `lib/data` 35 | 36 | The `lib/data` folder is where we put anything that represents data such as our models 37 | 38 | ### `lib/extensions` 39 | 40 | We use the `lib/extensions` folder to extend the Dart language with helpers for convience methods. 41 | 42 | ### `lib/providers` 43 | 44 | Our `lib/providers` folder is where we create our `ChangeNotifiers` that allow observation and access across our app. 45 | 46 | For more information about Provider library we used can be found in the [documentation](https://pub.dev/packages/provider) 47 | 48 | ### `lib/screens` 49 | 50 | Directory `lib/screens` is where we place all of our top level views and responsible for laying out how we present to our users. 51 | 52 | ### `lib/widgets` 53 | 54 | The `lib/widgets` directory contains all of our Flutter widgets. Widgets are the main component of Flutter and can make up different pars of your screen. 55 | 56 | For more information on Widgets can be found in the [documentation](https://docs.flutter.dev/reference/widgets) 57 | -------------------------------------------------------------------------------- /analysis_options.yaml: -------------------------------------------------------------------------------- 1 | # This file configures the analyzer, which statically analyzes Dart code to 2 | # check for errors, warnings, and lints. 3 | # 4 | # The issues identified by the analyzer are surfaced in the UI of Dart-enabled 5 | # IDEs (https://dart.dev/tools#ides-and-editors). The analyzer can also be 6 | # invoked from the command line by running `flutter analyze`. 7 | 8 | # The following line activates a set of recommended lints for Flutter apps, 9 | # packages, and plugins designed to encourage good coding practices. 10 | include: package:flutter_lints/flutter.yaml 11 | 12 | linter: 13 | # The lint rules applied to this project can be customized in the 14 | # section below to disable rules from the `package:flutter_lints/flutter.yaml` 15 | # included above or to enable additional rules. A list of all available lints 16 | # and their documentation is published at 17 | # https://dart-lang.github.io/linter/lints/index.html. 18 | # 19 | # Instead of disabling a lint rule for the entire project in the 20 | # section below, it can also be suppressed for a single line of code 21 | # or a specific dart file by using the `// ignore: name_of_lint` and 22 | # `// ignore_for_file: name_of_lint` syntax on the line or in the file 23 | # producing the lint. 24 | rules: 25 | # avoid_print: false # Uncomment to disable the `avoid_print` rule 26 | # prefer_single_quotes: true # Uncomment to enable the `prefer_single_quotes` rule 27 | 28 | # Additional information about this file can be found at 29 | # https://dart.dev/guides/language/analysis-options 30 | -------------------------------------------------------------------------------- /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 | **/*.keystore 13 | **/*.jks 14 | -------------------------------------------------------------------------------- /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 flutter.compileSdkVersion 30 | 31 | compileOptions { 32 | sourceCompatibility JavaVersion.VERSION_1_8 33 | targetCompatibility JavaVersion.VERSION_1_8 34 | } 35 | 36 | kotlinOptions { 37 | jvmTarget = '1.8' 38 | } 39 | 40 | sourceSets { 41 | main.java.srcDirs += 'src/main/kotlin' 42 | } 43 | 44 | defaultConfig { 45 | // TODO: Specify your own unique Application ID (https://developer.android.com/studio/build/application-id.html). 46 | applicationId "io.appwrite.netflix_clone" 47 | minSdkVersion flutter.minSdkVersion 48 | targetSdkVersion flutter.targetSdkVersion 49 | versionCode flutterVersionCode.toInteger() 50 | versionName flutterVersionName 51 | } 52 | 53 | buildTypes { 54 | release { 55 | // TODO: Add your own signing config for the release build. 56 | // Signing with the debug keys for now, so `flutter run --release` works. 57 | signingConfig signingConfigs.debug 58 | } 59 | } 60 | } 61 | 62 | flutter { 63 | source '../..' 64 | } 65 | 66 | dependencies { 67 | implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlin_version" 68 | } 69 | -------------------------------------------------------------------------------- /android/app/src/debug/AndroidManifest.xml: -------------------------------------------------------------------------------- 1 | 3 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /android/app/src/main/AndroidManifest.xml: -------------------------------------------------------------------------------- 1 | 3 | 7 | 15 | 19 | 23 | 24 | 25 | 26 | 27 | 28 | 30 | 33 | 34 | 35 | -------------------------------------------------------------------------------- /android/app/src/main/kotlin/io/appwrite/netflix_clone/MainActivity.kt: -------------------------------------------------------------------------------- 1 | package io.appwrite.netflix_clone 2 | 3 | import io.flutter.embedding.android.FlutterActivity 4 | 5 | class MainActivity: FlutterActivity() { 6 | } 7 | -------------------------------------------------------------------------------- /android/app/src/main/res/drawable-v21/launch_background.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 12 | 13 | -------------------------------------------------------------------------------- /android/app/src/main/res/drawable/launch_background.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 12 | 13 | -------------------------------------------------------------------------------- /android/app/src/main/res/mipmap-hdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/appwrite/demo-almost-netflix-for-flutter/6d703dc36c725bc34ac4e1addb0a5649034da99e/android/app/src/main/res/mipmap-hdpi/ic_launcher.png -------------------------------------------------------------------------------- /android/app/src/main/res/mipmap-mdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/appwrite/demo-almost-netflix-for-flutter/6d703dc36c725bc34ac4e1addb0a5649034da99e/android/app/src/main/res/mipmap-mdpi/ic_launcher.png -------------------------------------------------------------------------------- /android/app/src/main/res/mipmap-xhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/appwrite/demo-almost-netflix-for-flutter/6d703dc36c725bc34ac4e1addb0a5649034da99e/android/app/src/main/res/mipmap-xhdpi/ic_launcher.png -------------------------------------------------------------------------------- /android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/appwrite/demo-almost-netflix-for-flutter/6d703dc36c725bc34ac4e1addb0a5649034da99e/android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png -------------------------------------------------------------------------------- /android/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/appwrite/demo-almost-netflix-for-flutter/6d703dc36c725bc34ac4e1addb0a5649034da99e/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png -------------------------------------------------------------------------------- /android/app/src/main/res/values-night/styles.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 9 | 15 | 18 | 19 | -------------------------------------------------------------------------------- /android/app/src/main/res/values/styles.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 9 | 15 | 18 | 19 | -------------------------------------------------------------------------------- /android/app/src/profile/AndroidManifest.xml: -------------------------------------------------------------------------------- 1 | 3 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /android/build.gradle: -------------------------------------------------------------------------------- 1 | buildscript { 2 | ext.kotlin_version = '1.7.20' 3 | repositories { 4 | google() 5 | mavenCentral() 6 | } 7 | 8 | dependencies { 9 | classpath 'com.android.tools.build:gradle:7.1.2' 10 | classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version" 11 | } 12 | } 13 | 14 | allprojects { 15 | repositories { 16 | google() 17 | mavenCentral() 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 | -------------------------------------------------------------------------------- /android/gradle.properties: -------------------------------------------------------------------------------- 1 | org.gradle.jvmargs=-Xmx1536M 2 | android.useAndroidX=true 3 | android.enableJetifier=true 4 | -------------------------------------------------------------------------------- /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-7.2-all.zip 7 | -------------------------------------------------------------------------------- /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 | -------------------------------------------------------------------------------- /assets/bg.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/appwrite/demo-almost-netflix-for-flutter/6d703dc36c725bc34ac4e1addb0a5649034da99e/assets/bg.png -------------------------------------------------------------------------------- /assets/logo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/appwrite/demo-almost-netflix-for-flutter/6d703dc36c725bc34ac4e1addb0a5649034da99e/assets/logo.png -------------------------------------------------------------------------------- /assets/logo.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /assets/netflix_logo0.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/appwrite/demo-almost-netflix-for-flutter/6d703dc36c725bc34ac4e1addb0a5649034da99e/assets/netflix_logo0.png -------------------------------------------------------------------------------- /assets/netflix_logo1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/appwrite/demo-almost-netflix-for-flutter/6d703dc36c725bc34ac4e1addb0a5649034da99e/assets/netflix_logo1.png -------------------------------------------------------------------------------- /ios/.gitignore: -------------------------------------------------------------------------------- 1 | **/dgph 2 | *.mode1v3 3 | *.mode2v3 4 | *.moved-aside 5 | *.pbxuser 6 | *.perspectivev3 7 | **/*sync/ 8 | .sconsign.dblite 9 | .tags* 10 | **/.vagrant/ 11 | **/DerivedData/ 12 | Icon? 13 | **/Pods/ 14 | **/.symlinks/ 15 | profile 16 | xcuserdata 17 | **/.generated/ 18 | Flutter/App.framework 19 | Flutter/Flutter.framework 20 | Flutter/Flutter.podspec 21 | Flutter/Generated.xcconfig 22 | Flutter/ephemeral/ 23 | Flutter/app.flx 24 | Flutter/app.zip 25 | Flutter/flutter_assets/ 26 | Flutter/flutter_export_environment.sh 27 | ServiceDefinitions.json 28 | Runner/GeneratedPluginRegistrant.* 29 | 30 | # Exceptions to above rules. 31 | !default.mode1v3 32 | !default.mode2v3 33 | !default.pbxuser 34 | !default.perspectivev3 35 | -------------------------------------------------------------------------------- /ios/Flutter/AppFrameworkInfo.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | CFBundleDevelopmentRegion 6 | en 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 | -------------------------------------------------------------------------------- /ios/Flutter/Debug.xcconfig: -------------------------------------------------------------------------------- 1 | #include? "Pods/Target Support Files/Pods-Runner/Pods-Runner.debug.xcconfig" 2 | #include "Generated.xcconfig" 3 | -------------------------------------------------------------------------------- /ios/Flutter/Release.xcconfig: -------------------------------------------------------------------------------- 1 | #include? "Pods/Target Support Files/Pods-Runner/Pods-Runner.release.xcconfig" 2 | #include "Generated.xcconfig" 3 | -------------------------------------------------------------------------------- /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/Podfile.lock: -------------------------------------------------------------------------------- 1 | PODS: 2 | - device_info_plus (0.0.1): 3 | - Flutter 4 | - Flutter (1.0.0) 5 | - flutter_web_auth (0.4.0): 6 | - Flutter 7 | - package_info_plus (0.4.5): 8 | - Flutter 9 | - path_provider_ios (0.0.1): 10 | - Flutter 11 | - shared_preferences_ios (0.0.1): 12 | - Flutter 13 | 14 | DEPENDENCIES: 15 | - device_info_plus (from `.symlinks/plugins/device_info_plus/ios`) 16 | - Flutter (from `Flutter`) 17 | - flutter_web_auth (from `.symlinks/plugins/flutter_web_auth/ios`) 18 | - package_info_plus (from `.symlinks/plugins/package_info_plus/ios`) 19 | - path_provider_ios (from `.symlinks/plugins/path_provider_ios/ios`) 20 | - shared_preferences_ios (from `.symlinks/plugins/shared_preferences_ios/ios`) 21 | 22 | EXTERNAL SOURCES: 23 | device_info_plus: 24 | :path: ".symlinks/plugins/device_info_plus/ios" 25 | Flutter: 26 | :path: Flutter 27 | flutter_web_auth: 28 | :path: ".symlinks/plugins/flutter_web_auth/ios" 29 | package_info_plus: 30 | :path: ".symlinks/plugins/package_info_plus/ios" 31 | path_provider_ios: 32 | :path: ".symlinks/plugins/path_provider_ios/ios" 33 | shared_preferences_ios: 34 | :path: ".symlinks/plugins/shared_preferences_ios/ios" 35 | 36 | SPEC CHECKSUMS: 37 | device_info_plus: e5c5da33f982a436e103237c0c85f9031142abed 38 | Flutter: 50d75fe2f02b26cc09d224853bb45737f8b3214a 39 | flutter_web_auth: fd071763f61703882adbb2524f5cd5251883118c 40 | package_info_plus: 6c92f08e1f853dc01228d6f553146438dafcd14e 41 | path_provider_ios: 7d7ce634493af4477d156294792024ec3485acd5 42 | shared_preferences_ios: aef470a42dc4675a1cdd50e3158b42e3d1232b32 43 | 44 | PODFILE CHECKSUM: aafe91acc616949ddb318b77800a7f51bffa2a4c 45 | 46 | COCOAPODS: 1.11.2 47 | -------------------------------------------------------------------------------- /ios/Runner.xcodeproj/project.pbxproj: -------------------------------------------------------------------------------- 1 | // !$*UTF8*$! 2 | { 3 | archiveVersion = 1; 4 | classes = { 5 | }; 6 | objectVersion = 50; 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 | B84CA9673E4B334192BA211D /* Pods_Runner.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 5325480C5C32B1FC2D34C3CD /* Pods_Runner.framework */; }; 17 | /* End PBXBuildFile section */ 18 | 19 | /* Begin PBXCopyFilesBuildPhase section */ 20 | 9705A1C41CF9048500538489 /* Embed Frameworks */ = { 21 | isa = PBXCopyFilesBuildPhase; 22 | buildActionMask = 2147483647; 23 | dstPath = ""; 24 | dstSubfolderSpec = 10; 25 | files = ( 26 | ); 27 | name = "Embed Frameworks"; 28 | runOnlyForDeploymentPostprocessing = 0; 29 | }; 30 | /* End PBXCopyFilesBuildPhase section */ 31 | 32 | /* Begin PBXFileReference section */ 33 | 06B6A557A00EF287B9549B96 /* Pods-Runner.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-Runner.debug.xcconfig"; path = "Target Support Files/Pods-Runner/Pods-Runner.debug.xcconfig"; sourceTree = ""; }; 34 | 1498D2321E8E86230040F4C2 /* GeneratedPluginRegistrant.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = GeneratedPluginRegistrant.h; sourceTree = ""; }; 35 | 1498D2331E8E89220040F4C2 /* GeneratedPluginRegistrant.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = GeneratedPluginRegistrant.m; sourceTree = ""; }; 36 | 3B3967151E833CAA004F5970 /* AppFrameworkInfo.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; name = AppFrameworkInfo.plist; path = Flutter/AppFrameworkInfo.plist; sourceTree = ""; }; 37 | 5325480C5C32B1FC2D34C3CD /* Pods_Runner.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = Pods_Runner.framework; sourceTree = BUILT_PRODUCTS_DIR; }; 38 | 74858FAD1ED2DC5600515810 /* Runner-Bridging-Header.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = "Runner-Bridging-Header.h"; sourceTree = ""; }; 39 | 74858FAE1ED2DC5600515810 /* AppDelegate.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = AppDelegate.swift; sourceTree = ""; }; 40 | 7AB751788441F660E23177FF /* Pods-Runner.profile.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-Runner.profile.xcconfig"; path = "Target Support Files/Pods-Runner/Pods-Runner.profile.xcconfig"; sourceTree = ""; }; 41 | 7AFA3C8E1D35360C0083082E /* Release.xcconfig */ = {isa = PBXFileReference; lastKnownFileType = text.xcconfig; name = Release.xcconfig; path = Flutter/Release.xcconfig; sourceTree = ""; }; 42 | 9740EEB21CF90195004384FC /* Debug.xcconfig */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.xcconfig; name = Debug.xcconfig; path = Flutter/Debug.xcconfig; sourceTree = ""; }; 43 | 9740EEB31CF90195004384FC /* Generated.xcconfig */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.xcconfig; name = Generated.xcconfig; path = Flutter/Generated.xcconfig; sourceTree = ""; }; 44 | 97C146EE1CF9000F007C117D /* Runner.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = Runner.app; sourceTree = BUILT_PRODUCTS_DIR; }; 45 | 97C146FB1CF9000F007C117D /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/Main.storyboard; sourceTree = ""; }; 46 | 97C146FD1CF9000F007C117D /* Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Assets.xcassets; sourceTree = ""; }; 47 | 97C147001CF9000F007C117D /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/LaunchScreen.storyboard; sourceTree = ""; }; 48 | 97C147021CF9000F007C117D /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; 49 | B1752080FE1379B47FB4DBB0 /* Pods-Runner.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-Runner.release.xcconfig"; path = "Target Support Files/Pods-Runner/Pods-Runner.release.xcconfig"; sourceTree = ""; }; 50 | /* End PBXFileReference section */ 51 | 52 | /* Begin PBXFrameworksBuildPhase section */ 53 | 97C146EB1CF9000F007C117D /* Frameworks */ = { 54 | isa = PBXFrameworksBuildPhase; 55 | buildActionMask = 2147483647; 56 | files = ( 57 | B84CA9673E4B334192BA211D /* Pods_Runner.framework in Frameworks */, 58 | ); 59 | runOnlyForDeploymentPostprocessing = 0; 60 | }; 61 | /* End PBXFrameworksBuildPhase section */ 62 | 63 | /* Begin PBXGroup section */ 64 | 53E9FC5F021FF735435DBEA3 /* Frameworks */ = { 65 | isa = PBXGroup; 66 | children = ( 67 | 5325480C5C32B1FC2D34C3CD /* Pods_Runner.framework */, 68 | ); 69 | name = Frameworks; 70 | sourceTree = ""; 71 | }; 72 | 9740EEB11CF90186004384FC /* Flutter */ = { 73 | isa = PBXGroup; 74 | children = ( 75 | 3B3967151E833CAA004F5970 /* AppFrameworkInfo.plist */, 76 | 9740EEB21CF90195004384FC /* Debug.xcconfig */, 77 | 7AFA3C8E1D35360C0083082E /* Release.xcconfig */, 78 | 9740EEB31CF90195004384FC /* Generated.xcconfig */, 79 | ); 80 | name = Flutter; 81 | sourceTree = ""; 82 | }; 83 | 97C146E51CF9000F007C117D = { 84 | isa = PBXGroup; 85 | children = ( 86 | 9740EEB11CF90186004384FC /* Flutter */, 87 | 97C146F01CF9000F007C117D /* Runner */, 88 | 97C146EF1CF9000F007C117D /* Products */, 89 | CCE84D5448141CE99C05C16E /* Pods */, 90 | 53E9FC5F021FF735435DBEA3 /* Frameworks */, 91 | ); 92 | sourceTree = ""; 93 | }; 94 | 97C146EF1CF9000F007C117D /* Products */ = { 95 | isa = PBXGroup; 96 | children = ( 97 | 97C146EE1CF9000F007C117D /* Runner.app */, 98 | ); 99 | name = Products; 100 | sourceTree = ""; 101 | }; 102 | 97C146F01CF9000F007C117D /* Runner */ = { 103 | isa = PBXGroup; 104 | children = ( 105 | 97C146FA1CF9000F007C117D /* Main.storyboard */, 106 | 97C146FD1CF9000F007C117D /* Assets.xcassets */, 107 | 97C146FF1CF9000F007C117D /* LaunchScreen.storyboard */, 108 | 97C147021CF9000F007C117D /* Info.plist */, 109 | 1498D2321E8E86230040F4C2 /* GeneratedPluginRegistrant.h */, 110 | 1498D2331E8E89220040F4C2 /* GeneratedPluginRegistrant.m */, 111 | 74858FAE1ED2DC5600515810 /* AppDelegate.swift */, 112 | 74858FAD1ED2DC5600515810 /* Runner-Bridging-Header.h */, 113 | ); 114 | path = Runner; 115 | sourceTree = ""; 116 | }; 117 | CCE84D5448141CE99C05C16E /* Pods */ = { 118 | isa = PBXGroup; 119 | children = ( 120 | 06B6A557A00EF287B9549B96 /* Pods-Runner.debug.xcconfig */, 121 | B1752080FE1379B47FB4DBB0 /* Pods-Runner.release.xcconfig */, 122 | 7AB751788441F660E23177FF /* Pods-Runner.profile.xcconfig */, 123 | ); 124 | name = Pods; 125 | path = Pods; 126 | sourceTree = ""; 127 | }; 128 | /* End PBXGroup section */ 129 | 130 | /* Begin PBXNativeTarget section */ 131 | 97C146ED1CF9000F007C117D /* Runner */ = { 132 | isa = PBXNativeTarget; 133 | buildConfigurationList = 97C147051CF9000F007C117D /* Build configuration list for PBXNativeTarget "Runner" */; 134 | buildPhases = ( 135 | B4B9198388F9DEF9DDB1B9BB /* [CP] Check Pods Manifest.lock */, 136 | 9740EEB61CF901F6004384FC /* Run Script */, 137 | 97C146EA1CF9000F007C117D /* Sources */, 138 | 97C146EB1CF9000F007C117D /* Frameworks */, 139 | 97C146EC1CF9000F007C117D /* Resources */, 140 | 9705A1C41CF9048500538489 /* Embed Frameworks */, 141 | 3B06AD1E1E4923F5004D2608 /* Thin Binary */, 142 | 71BD8450CC6C1AE41F9B6CE1 /* [CP] Embed Pods Frameworks */, 143 | ); 144 | buildRules = ( 145 | ); 146 | dependencies = ( 147 | ); 148 | name = Runner; 149 | productName = Runner; 150 | productReference = 97C146EE1CF9000F007C117D /* Runner.app */; 151 | productType = "com.apple.product-type.application"; 152 | }; 153 | /* End PBXNativeTarget section */ 154 | 155 | /* Begin PBXProject section */ 156 | 97C146E61CF9000F007C117D /* Project object */ = { 157 | isa = PBXProject; 158 | attributes = { 159 | LastUpgradeCheck = 1300; 160 | ORGANIZATIONNAME = ""; 161 | TargetAttributes = { 162 | 97C146ED1CF9000F007C117D = { 163 | CreatedOnToolsVersion = 7.3.1; 164 | LastSwiftMigration = 1100; 165 | }; 166 | }; 167 | }; 168 | buildConfigurationList = 97C146E91CF9000F007C117D /* Build configuration list for PBXProject "Runner" */; 169 | compatibilityVersion = "Xcode 9.3"; 170 | developmentRegion = en; 171 | hasScannedForEncodings = 0; 172 | knownRegions = ( 173 | en, 174 | Base, 175 | ); 176 | mainGroup = 97C146E51CF9000F007C117D; 177 | productRefGroup = 97C146EF1CF9000F007C117D /* Products */; 178 | projectDirPath = ""; 179 | projectRoot = ""; 180 | targets = ( 181 | 97C146ED1CF9000F007C117D /* Runner */, 182 | ); 183 | }; 184 | /* End PBXProject section */ 185 | 186 | /* Begin PBXResourcesBuildPhase section */ 187 | 97C146EC1CF9000F007C117D /* Resources */ = { 188 | isa = PBXResourcesBuildPhase; 189 | buildActionMask = 2147483647; 190 | files = ( 191 | 97C147011CF9000F007C117D /* LaunchScreen.storyboard in Resources */, 192 | 3B3967161E833CAA004F5970 /* AppFrameworkInfo.plist in Resources */, 193 | 97C146FE1CF9000F007C117D /* Assets.xcassets in Resources */, 194 | 97C146FC1CF9000F007C117D /* Main.storyboard in Resources */, 195 | ); 196 | runOnlyForDeploymentPostprocessing = 0; 197 | }; 198 | /* End PBXResourcesBuildPhase section */ 199 | 200 | /* Begin PBXShellScriptBuildPhase section */ 201 | 3B06AD1E1E4923F5004D2608 /* Thin Binary */ = { 202 | isa = PBXShellScriptBuildPhase; 203 | buildActionMask = 2147483647; 204 | files = ( 205 | ); 206 | inputPaths = ( 207 | ); 208 | name = "Thin Binary"; 209 | outputPaths = ( 210 | ); 211 | runOnlyForDeploymentPostprocessing = 0; 212 | shellPath = /bin/sh; 213 | shellScript = "/bin/sh \"$FLUTTER_ROOT/packages/flutter_tools/bin/xcode_backend.sh\" embed_and_thin"; 214 | }; 215 | 71BD8450CC6C1AE41F9B6CE1 /* [CP] Embed Pods Frameworks */ = { 216 | isa = PBXShellScriptBuildPhase; 217 | buildActionMask = 2147483647; 218 | files = ( 219 | ); 220 | inputFileListPaths = ( 221 | "${PODS_ROOT}/Target Support Files/Pods-Runner/Pods-Runner-frameworks-${CONFIGURATION}-input-files.xcfilelist", 222 | ); 223 | name = "[CP] Embed Pods Frameworks"; 224 | outputFileListPaths = ( 225 | "${PODS_ROOT}/Target Support Files/Pods-Runner/Pods-Runner-frameworks-${CONFIGURATION}-output-files.xcfilelist", 226 | ); 227 | runOnlyForDeploymentPostprocessing = 0; 228 | shellPath = /bin/sh; 229 | shellScript = "\"${PODS_ROOT}/Target Support Files/Pods-Runner/Pods-Runner-frameworks.sh\"\n"; 230 | showEnvVarsInLog = 0; 231 | }; 232 | 9740EEB61CF901F6004384FC /* Run Script */ = { 233 | isa = PBXShellScriptBuildPhase; 234 | buildActionMask = 2147483647; 235 | files = ( 236 | ); 237 | inputPaths = ( 238 | ); 239 | name = "Run Script"; 240 | outputPaths = ( 241 | ); 242 | runOnlyForDeploymentPostprocessing = 0; 243 | shellPath = /bin/sh; 244 | shellScript = "/bin/sh \"$FLUTTER_ROOT/packages/flutter_tools/bin/xcode_backend.sh\" build"; 245 | }; 246 | B4B9198388F9DEF9DDB1B9BB /* [CP] Check Pods Manifest.lock */ = { 247 | isa = PBXShellScriptBuildPhase; 248 | buildActionMask = 2147483647; 249 | files = ( 250 | ); 251 | inputFileListPaths = ( 252 | ); 253 | inputPaths = ( 254 | "${PODS_PODFILE_DIR_PATH}/Podfile.lock", 255 | "${PODS_ROOT}/Manifest.lock", 256 | ); 257 | name = "[CP] Check Pods Manifest.lock"; 258 | outputFileListPaths = ( 259 | ); 260 | outputPaths = ( 261 | "$(DERIVED_FILE_DIR)/Pods-Runner-checkManifestLockResult.txt", 262 | ); 263 | runOnlyForDeploymentPostprocessing = 0; 264 | shellPath = /bin/sh; 265 | shellScript = "diff \"${PODS_PODFILE_DIR_PATH}/Podfile.lock\" \"${PODS_ROOT}/Manifest.lock\" > /dev/null\nif [ $? != 0 ] ; then\n # print error to STDERR\n echo \"error: The sandbox is not in sync with the Podfile.lock. Run 'pod install' or update your CocoaPods installation.\" >&2\n exit 1\nfi\n# This output is used by Xcode 'outputs' to avoid re-running this script phase.\necho \"SUCCESS\" > \"${SCRIPT_OUTPUT_FILE_0}\"\n"; 266 | showEnvVarsInLog = 0; 267 | }; 268 | /* End PBXShellScriptBuildPhase section */ 269 | 270 | /* Begin PBXSourcesBuildPhase section */ 271 | 97C146EA1CF9000F007C117D /* Sources */ = { 272 | isa = PBXSourcesBuildPhase; 273 | buildActionMask = 2147483647; 274 | files = ( 275 | 74858FAF1ED2DC5600515810 /* AppDelegate.swift in Sources */, 276 | 1498D2341E8E89220040F4C2 /* GeneratedPluginRegistrant.m in Sources */, 277 | ); 278 | runOnlyForDeploymentPostprocessing = 0; 279 | }; 280 | /* End PBXSourcesBuildPhase section */ 281 | 282 | /* Begin PBXVariantGroup section */ 283 | 97C146FA1CF9000F007C117D /* Main.storyboard */ = { 284 | isa = PBXVariantGroup; 285 | children = ( 286 | 97C146FB1CF9000F007C117D /* Base */, 287 | ); 288 | name = Main.storyboard; 289 | sourceTree = ""; 290 | }; 291 | 97C146FF1CF9000F007C117D /* LaunchScreen.storyboard */ = { 292 | isa = PBXVariantGroup; 293 | children = ( 294 | 97C147001CF9000F007C117D /* Base */, 295 | ); 296 | name = LaunchScreen.storyboard; 297 | sourceTree = ""; 298 | }; 299 | /* End PBXVariantGroup section */ 300 | 301 | /* Begin XCBuildConfiguration section */ 302 | 249021D3217E4FDB00AE95B9 /* Profile */ = { 303 | isa = XCBuildConfiguration; 304 | buildSettings = { 305 | ALWAYS_SEARCH_USER_PATHS = NO; 306 | CLANG_ANALYZER_NONNULL = YES; 307 | CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; 308 | CLANG_CXX_LIBRARY = "libc++"; 309 | CLANG_ENABLE_MODULES = YES; 310 | CLANG_ENABLE_OBJC_ARC = YES; 311 | CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; 312 | CLANG_WARN_BOOL_CONVERSION = YES; 313 | CLANG_WARN_COMMA = YES; 314 | CLANG_WARN_CONSTANT_CONVERSION = YES; 315 | CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; 316 | CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; 317 | CLANG_WARN_EMPTY_BODY = YES; 318 | CLANG_WARN_ENUM_CONVERSION = YES; 319 | CLANG_WARN_INFINITE_RECURSION = YES; 320 | CLANG_WARN_INT_CONVERSION = YES; 321 | CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; 322 | CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES; 323 | CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; 324 | CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; 325 | CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; 326 | CLANG_WARN_STRICT_PROTOTYPES = YES; 327 | CLANG_WARN_SUSPICIOUS_MOVE = YES; 328 | CLANG_WARN_UNREACHABLE_CODE = YES; 329 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; 330 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; 331 | COPY_PHASE_STRIP = NO; 332 | DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; 333 | ENABLE_NS_ASSERTIONS = NO; 334 | ENABLE_STRICT_OBJC_MSGSEND = YES; 335 | GCC_C_LANGUAGE_STANDARD = gnu99; 336 | GCC_NO_COMMON_BLOCKS = YES; 337 | GCC_WARN_64_TO_32_BIT_CONVERSION = YES; 338 | GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; 339 | GCC_WARN_UNDECLARED_SELECTOR = YES; 340 | GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; 341 | GCC_WARN_UNUSED_FUNCTION = YES; 342 | GCC_WARN_UNUSED_VARIABLE = YES; 343 | IPHONEOS_DEPLOYMENT_TARGET = 9.0; 344 | MTL_ENABLE_DEBUG_INFO = NO; 345 | SDKROOT = iphoneos; 346 | SUPPORTED_PLATFORMS = iphoneos; 347 | TARGETED_DEVICE_FAMILY = "1,2"; 348 | VALIDATE_PRODUCT = YES; 349 | }; 350 | name = Profile; 351 | }; 352 | 249021D4217E4FDB00AE95B9 /* Profile */ = { 353 | isa = XCBuildConfiguration; 354 | baseConfigurationReference = 7AFA3C8E1D35360C0083082E /* Release.xcconfig */; 355 | buildSettings = { 356 | ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; 357 | CLANG_ENABLE_MODULES = YES; 358 | CURRENT_PROJECT_VERSION = "$(FLUTTER_BUILD_NUMBER)"; 359 | ENABLE_BITCODE = NO; 360 | INFOPLIST_FILE = Runner/Info.plist; 361 | LD_RUNPATH_SEARCH_PATHS = ( 362 | "$(inherited)", 363 | "@executable_path/Frameworks", 364 | ); 365 | PRODUCT_BUNDLE_IDENTIFIER = io.appwrite.netflixClone; 366 | PRODUCT_NAME = "$(TARGET_NAME)"; 367 | SWIFT_OBJC_BRIDGING_HEADER = "Runner/Runner-Bridging-Header.h"; 368 | SWIFT_VERSION = 5.0; 369 | VERSIONING_SYSTEM = "apple-generic"; 370 | }; 371 | name = Profile; 372 | }; 373 | 97C147031CF9000F007C117D /* Debug */ = { 374 | isa = XCBuildConfiguration; 375 | buildSettings = { 376 | ALWAYS_SEARCH_USER_PATHS = NO; 377 | CLANG_ANALYZER_NONNULL = YES; 378 | CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; 379 | CLANG_CXX_LIBRARY = "libc++"; 380 | CLANG_ENABLE_MODULES = YES; 381 | CLANG_ENABLE_OBJC_ARC = YES; 382 | CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; 383 | CLANG_WARN_BOOL_CONVERSION = YES; 384 | CLANG_WARN_COMMA = YES; 385 | CLANG_WARN_CONSTANT_CONVERSION = YES; 386 | CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; 387 | CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; 388 | CLANG_WARN_EMPTY_BODY = YES; 389 | CLANG_WARN_ENUM_CONVERSION = YES; 390 | CLANG_WARN_INFINITE_RECURSION = YES; 391 | CLANG_WARN_INT_CONVERSION = YES; 392 | CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; 393 | CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES; 394 | CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; 395 | CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; 396 | CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; 397 | CLANG_WARN_STRICT_PROTOTYPES = YES; 398 | CLANG_WARN_SUSPICIOUS_MOVE = YES; 399 | CLANG_WARN_UNREACHABLE_CODE = YES; 400 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; 401 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; 402 | COPY_PHASE_STRIP = NO; 403 | DEBUG_INFORMATION_FORMAT = dwarf; 404 | ENABLE_STRICT_OBJC_MSGSEND = YES; 405 | ENABLE_TESTABILITY = YES; 406 | GCC_C_LANGUAGE_STANDARD = gnu99; 407 | GCC_DYNAMIC_NO_PIC = NO; 408 | GCC_NO_COMMON_BLOCKS = YES; 409 | GCC_OPTIMIZATION_LEVEL = 0; 410 | GCC_PREPROCESSOR_DEFINITIONS = ( 411 | "DEBUG=1", 412 | "$(inherited)", 413 | ); 414 | GCC_WARN_64_TO_32_BIT_CONVERSION = YES; 415 | GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; 416 | GCC_WARN_UNDECLARED_SELECTOR = YES; 417 | GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; 418 | GCC_WARN_UNUSED_FUNCTION = YES; 419 | GCC_WARN_UNUSED_VARIABLE = YES; 420 | IPHONEOS_DEPLOYMENT_TARGET = 9.0; 421 | MTL_ENABLE_DEBUG_INFO = YES; 422 | ONLY_ACTIVE_ARCH = YES; 423 | SDKROOT = iphoneos; 424 | TARGETED_DEVICE_FAMILY = "1,2"; 425 | }; 426 | name = Debug; 427 | }; 428 | 97C147041CF9000F007C117D /* Release */ = { 429 | isa = XCBuildConfiguration; 430 | buildSettings = { 431 | ALWAYS_SEARCH_USER_PATHS = NO; 432 | CLANG_ANALYZER_NONNULL = YES; 433 | CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; 434 | CLANG_CXX_LIBRARY = "libc++"; 435 | CLANG_ENABLE_MODULES = YES; 436 | CLANG_ENABLE_OBJC_ARC = YES; 437 | CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; 438 | CLANG_WARN_BOOL_CONVERSION = YES; 439 | CLANG_WARN_COMMA = YES; 440 | CLANG_WARN_CONSTANT_CONVERSION = YES; 441 | CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; 442 | CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; 443 | CLANG_WARN_EMPTY_BODY = YES; 444 | CLANG_WARN_ENUM_CONVERSION = YES; 445 | CLANG_WARN_INFINITE_RECURSION = YES; 446 | CLANG_WARN_INT_CONVERSION = YES; 447 | CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; 448 | CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES; 449 | CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; 450 | CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; 451 | CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; 452 | CLANG_WARN_STRICT_PROTOTYPES = YES; 453 | CLANG_WARN_SUSPICIOUS_MOVE = YES; 454 | CLANG_WARN_UNREACHABLE_CODE = YES; 455 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; 456 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; 457 | COPY_PHASE_STRIP = NO; 458 | DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; 459 | ENABLE_NS_ASSERTIONS = NO; 460 | ENABLE_STRICT_OBJC_MSGSEND = YES; 461 | GCC_C_LANGUAGE_STANDARD = gnu99; 462 | GCC_NO_COMMON_BLOCKS = YES; 463 | GCC_WARN_64_TO_32_BIT_CONVERSION = YES; 464 | GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; 465 | GCC_WARN_UNDECLARED_SELECTOR = YES; 466 | GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; 467 | GCC_WARN_UNUSED_FUNCTION = YES; 468 | GCC_WARN_UNUSED_VARIABLE = YES; 469 | IPHONEOS_DEPLOYMENT_TARGET = 9.0; 470 | MTL_ENABLE_DEBUG_INFO = NO; 471 | SDKROOT = iphoneos; 472 | SUPPORTED_PLATFORMS = iphoneos; 473 | SWIFT_COMPILATION_MODE = wholemodule; 474 | SWIFT_OPTIMIZATION_LEVEL = "-O"; 475 | TARGETED_DEVICE_FAMILY = "1,2"; 476 | VALIDATE_PRODUCT = YES; 477 | }; 478 | name = Release; 479 | }; 480 | 97C147061CF9000F007C117D /* Debug */ = { 481 | isa = XCBuildConfiguration; 482 | baseConfigurationReference = 9740EEB21CF90195004384FC /* Debug.xcconfig */; 483 | buildSettings = { 484 | ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; 485 | CLANG_ENABLE_MODULES = YES; 486 | CURRENT_PROJECT_VERSION = "$(FLUTTER_BUILD_NUMBER)"; 487 | ENABLE_BITCODE = NO; 488 | INFOPLIST_FILE = Runner/Info.plist; 489 | LD_RUNPATH_SEARCH_PATHS = ( 490 | "$(inherited)", 491 | "@executable_path/Frameworks", 492 | ); 493 | PRODUCT_BUNDLE_IDENTIFIER = io.appwrite.netflixClone; 494 | PRODUCT_NAME = "$(TARGET_NAME)"; 495 | SWIFT_OBJC_BRIDGING_HEADER = "Runner/Runner-Bridging-Header.h"; 496 | SWIFT_OPTIMIZATION_LEVEL = "-Onone"; 497 | SWIFT_VERSION = 5.0; 498 | VERSIONING_SYSTEM = "apple-generic"; 499 | }; 500 | name = Debug; 501 | }; 502 | 97C147071CF9000F007C117D /* Release */ = { 503 | isa = XCBuildConfiguration; 504 | baseConfigurationReference = 7AFA3C8E1D35360C0083082E /* Release.xcconfig */; 505 | buildSettings = { 506 | ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; 507 | CLANG_ENABLE_MODULES = YES; 508 | CURRENT_PROJECT_VERSION = "$(FLUTTER_BUILD_NUMBER)"; 509 | ENABLE_BITCODE = NO; 510 | INFOPLIST_FILE = Runner/Info.plist; 511 | LD_RUNPATH_SEARCH_PATHS = ( 512 | "$(inherited)", 513 | "@executable_path/Frameworks", 514 | ); 515 | PRODUCT_BUNDLE_IDENTIFIER = io.appwrite.netflixClone; 516 | PRODUCT_NAME = "$(TARGET_NAME)"; 517 | SWIFT_OBJC_BRIDGING_HEADER = "Runner/Runner-Bridging-Header.h"; 518 | SWIFT_VERSION = 5.0; 519 | VERSIONING_SYSTEM = "apple-generic"; 520 | }; 521 | name = Release; 522 | }; 523 | /* End XCBuildConfiguration section */ 524 | 525 | /* Begin XCConfigurationList section */ 526 | 97C146E91CF9000F007C117D /* Build configuration list for PBXProject "Runner" */ = { 527 | isa = XCConfigurationList; 528 | buildConfigurations = ( 529 | 97C147031CF9000F007C117D /* Debug */, 530 | 97C147041CF9000F007C117D /* Release */, 531 | 249021D3217E4FDB00AE95B9 /* Profile */, 532 | ); 533 | defaultConfigurationIsVisible = 0; 534 | defaultConfigurationName = Release; 535 | }; 536 | 97C147051CF9000F007C117D /* Build configuration list for PBXNativeTarget "Runner" */ = { 537 | isa = XCConfigurationList; 538 | buildConfigurations = ( 539 | 97C147061CF9000F007C117D /* Debug */, 540 | 97C147071CF9000F007C117D /* Release */, 541 | 249021D4217E4FDB00AE95B9 /* Profile */, 542 | ); 543 | defaultConfigurationIsVisible = 0; 544 | defaultConfigurationName = Release; 545 | }; 546 | /* End XCConfigurationList section */ 547 | }; 548 | rootObject = 97C146E61CF9000F007C117D /* Project object */; 549 | } 550 | -------------------------------------------------------------------------------- /ios/Runner.xcodeproj/project.xcworkspace/contents.xcworkspacedata: -------------------------------------------------------------------------------- 1 | 2 | 4 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /ios/Runner.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | IDEDidComputeMac32BitWarning 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /ios/Runner.xcodeproj/project.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | PreviewsEnabled 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /ios/Runner.xcodeproj/xcshareddata/xcschemes/Runner.xcscheme: -------------------------------------------------------------------------------- 1 | 2 | 5 | 8 | 9 | 15 | 21 | 22 | 23 | 24 | 25 | 30 | 31 | 37 | 38 | 39 | 40 | 41 | 42 | 52 | 54 | 60 | 61 | 62 | 63 | 69 | 71 | 77 | 78 | 79 | 80 | 82 | 83 | 86 | 87 | 88 | -------------------------------------------------------------------------------- /ios/Runner.xcworkspace/contents.xcworkspacedata: -------------------------------------------------------------------------------- 1 | 2 | 4 | 6 | 7 | 9 | 10 | 11 | -------------------------------------------------------------------------------- /ios/Runner.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | IDEDidComputeMac32BitWarning 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /ios/Runner.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | PreviewsEnabled 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /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 | -------------------------------------------------------------------------------- /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 | -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-1024x1024@1x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/appwrite/demo-almost-netflix-for-flutter/6d703dc36c725bc34ac4e1addb0a5649034da99e/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-1024x1024@1x.png -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@1x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/appwrite/demo-almost-netflix-for-flutter/6d703dc36c725bc34ac4e1addb0a5649034da99e/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/appwrite/demo-almost-netflix-for-flutter/6d703dc36c725bc34ac4e1addb0a5649034da99e/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/appwrite/demo-almost-netflix-for-flutter/6d703dc36c725bc34ac4e1addb0a5649034da99e/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/appwrite/demo-almost-netflix-for-flutter/6d703dc36c725bc34ac4e1addb0a5649034da99e/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/appwrite/demo-almost-netflix-for-flutter/6d703dc36c725bc34ac4e1addb0a5649034da99e/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/appwrite/demo-almost-netflix-for-flutter/6d703dc36c725bc34ac4e1addb0a5649034da99e/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/appwrite/demo-almost-netflix-for-flutter/6d703dc36c725bc34ac4e1addb0a5649034da99e/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/appwrite/demo-almost-netflix-for-flutter/6d703dc36c725bc34ac4e1addb0a5649034da99e/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/appwrite/demo-almost-netflix-for-flutter/6d703dc36c725bc34ac4e1addb0a5649034da99e/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/appwrite/demo-almost-netflix-for-flutter/6d703dc36c725bc34ac4e1addb0a5649034da99e/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/appwrite/demo-almost-netflix-for-flutter/6d703dc36c725bc34ac4e1addb0a5649034da99e/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/appwrite/demo-almost-netflix-for-flutter/6d703dc36c725bc34ac4e1addb0a5649034da99e/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/appwrite/demo-almost-netflix-for-flutter/6d703dc36c725bc34ac4e1addb0a5649034da99e/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@2x.png -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-83.5x83.5@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/appwrite/demo-almost-netflix-for-flutter/6d703dc36c725bc34ac4e1addb0a5649034da99e/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-83.5x83.5@2x.png -------------------------------------------------------------------------------- /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 | -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/appwrite/demo-almost-netflix-for-flutter/6d703dc36c725bc34ac4e1addb0a5649034da99e/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage.png -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/appwrite/demo-almost-netflix-for-flutter/6d703dc36c725bc34ac4e1addb0a5649034da99e/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@2x.png -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@3x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/appwrite/demo-almost-netflix-for-flutter/6d703dc36c725bc34ac4e1addb0a5649034da99e/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@3x.png -------------------------------------------------------------------------------- /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/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 | -------------------------------------------------------------------------------- /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 | -------------------------------------------------------------------------------- /ios/Runner/Info.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | CFBundleDevelopmentRegion 6 | $(DEVELOPMENT_LANGUAGE) 7 | CFBundleDisplayName 8 | Netflix Clone 9 | CFBundleExecutable 10 | $(EXECUTABLE_NAME) 11 | CFBundleIdentifier 12 | $(PRODUCT_BUNDLE_IDENTIFIER) 13 | CFBundleInfoDictionaryVersion 14 | 6.0 15 | CFBundleName 16 | netflix_clone 17 | CFBundlePackageType 18 | APPL 19 | CFBundleShortVersionString 20 | $(FLUTTER_BUILD_NAME) 21 | CFBundleSignature 22 | ???? 23 | CFBundleVersion 24 | $(FLUTTER_BUILD_NUMBER) 25 | LSRequiresIPhoneOS 26 | 27 | UILaunchStoryboardName 28 | LaunchScreen 29 | UIMainStoryboardFile 30 | Main 31 | UISupportedInterfaceOrientations 32 | 33 | UIInterfaceOrientationPortrait 34 | UIInterfaceOrientationLandscapeLeft 35 | UIInterfaceOrientationLandscapeRight 36 | 37 | UISupportedInterfaceOrientations~ipad 38 | 39 | UIInterfaceOrientationPortrait 40 | UIInterfaceOrientationPortraitUpsideDown 41 | UIInterfaceOrientationLandscapeLeft 42 | UIInterfaceOrientationLandscapeRight 43 | 44 | UIViewControllerBasedStatusBarAppearance 45 | 46 | 47 | 48 | -------------------------------------------------------------------------------- /ios/Runner/Runner-Bridging-Header.h: -------------------------------------------------------------------------------- 1 | #import "GeneratedPluginRegistrant.h" 2 | -------------------------------------------------------------------------------- /lib/api/client.dart: -------------------------------------------------------------------------------- 1 | // 2 | // provider.dart 3 | // figures 4 | // 5 | // Author: Wess Cope (me@wess.io) 6 | // Created: 06/15/2021 7 | // 8 | // Copywrite (c) 2021 Wess.io 9 | // 10 | 11 | import 'package:appwrite/appwrite.dart'; 12 | 13 | class ApiClient { 14 | Client get _client { 15 | Client client = Client(); 16 | 17 | client 18 | .setEndpoint('https://demo.appwrite.io/v1') 19 | .setProject('almostNetflix2') 20 | .setSelfSigned(); 21 | 22 | return client; 23 | } 24 | 25 | static Account get account => Account(_instance._client); 26 | static Databases get database => 27 | Databases(_instance._client); 28 | static Storage get storage => Storage(_instance._client); 29 | 30 | static final ApiClient _instance = ApiClient._internal(); 31 | ApiClient._internal(); 32 | factory ApiClient() => _instance; 33 | } 34 | -------------------------------------------------------------------------------- /lib/assets.dart: -------------------------------------------------------------------------------- 1 | // 2 | // assets.dart 3 | // appflix 4 | // 5 | // Author: wess (me@wess.io) 6 | // Created: 01/03/2022 7 | // 8 | // Copywrite (c) 2022 Wess.io 9 | // 10 | 11 | class Assets { 12 | static const String _images = 'assets/'; 13 | 14 | static const String netflixLogo = '${_images}logo.png'; 15 | static const String netflixLogo0 = '${_images}netflix_logo0.png'; 16 | static const String netflixLogo1 = '${_images}netflix_logo1.png'; 17 | } 18 | -------------------------------------------------------------------------------- /lib/data/entry.dart: -------------------------------------------------------------------------------- 1 | // 2 | // entry.dart 3 | // appflix 4 | // 5 | // Author: wess (me@wess.io) 6 | // Created: 01/03/2022 7 | // 8 | // Copywrite (c) 2022 Wess.io 9 | // 10 | 11 | import 'package:netflix_clone/extensions/datetime.dart'; 12 | 13 | class Entry { 14 | final String id; 15 | final String name; 16 | final String? description; 17 | final String ageRestriction; 18 | final Duration durationMinutes; 19 | final String thumbnailImageId; 20 | final List genres; 21 | final List tags; 22 | final DateTime? netflixReleaseDate; 23 | final DateTime? releaseDate; 24 | final double trendingIndex; 25 | final bool isOriginal; 26 | final List cast; 27 | 28 | bool isEmpty() { 29 | if(id.isEmpty || name.isEmpty) { 30 | return true; 31 | } 32 | 33 | return false; 34 | } 35 | 36 | Entry({ 37 | required this.id, 38 | required this.name, 39 | this.description, 40 | required this.ageRestriction, 41 | required this.durationMinutes, 42 | required this.thumbnailImageId, 43 | required this.genres, 44 | required this.tags, 45 | this.netflixReleaseDate, 46 | this.releaseDate, 47 | required this.trendingIndex, 48 | required this.isOriginal, 49 | required this.cast, 50 | }); 51 | 52 | static Entry empty() { 53 | return Entry( 54 | id: '', 55 | name: '', 56 | description: '', 57 | ageRestriction: '', 58 | durationMinutes: const Duration(minutes: -1), 59 | thumbnailImageId: '', 60 | genres: [], 61 | tags: [], 62 | trendingIndex: -1, 63 | isOriginal: false, 64 | cast: [], 65 | ); 66 | } 67 | 68 | static Entry fromJson(Map data) { 69 | return Entry( 70 | id: data['\$id'], 71 | name: data['name'], 72 | description: data['description'], 73 | ageRestriction: data['ageRestriction'], 74 | durationMinutes: Duration(minutes: data['durationMinutes']), 75 | thumbnailImageId: data['thumbnailImageId'], 76 | genres: data['genres'].cast(), 77 | tags: data['tags'].cast(), 78 | netflixReleaseDate: data['netflixReleaseDate'] != null ? DateTimeExt.fromUnixTimestampInt(data['netflixReleaseDate']) : null, 79 | releaseDate: data['releaseDate'] != null ? DateTimeExt.fromUnixTimestampInt(data['releaseDate']) : null, 80 | trendingIndex: data['trendingIndex'], 81 | isOriginal: data['isOriginal'], 82 | cast: data['cast'].cast(), 83 | ); 84 | } 85 | } 86 | -------------------------------------------------------------------------------- /lib/data/store.dart: -------------------------------------------------------------------------------- 1 | // 2 | // store.dart 3 | // appflix 4 | // 5 | // Author: wess (me@wess.io) 6 | // Created: 01/07/2022 7 | // 8 | // Copywrite (c) 2022 Wess.io 9 | // 10 | 11 | import 'dart:convert'; 12 | 13 | import 'package:shared_preferences/shared_preferences.dart'; 14 | 15 | class Store { 16 | SharedPreferences? _prefs; 17 | 18 | static final Store _instance = Store._internal(); 19 | 20 | factory Store() => _instance; 21 | 22 | Store._internal(); 23 | 24 | Future _insert(Map data) async { 25 | _prefs ??= await SharedPreferences.getInstance(); 26 | 27 | data.forEach((key, value) { 28 | _prefs?.setString(key, value.toString()); 29 | }); 30 | } 31 | 32 | Future _set(String key, dynamic value) async { 33 | _prefs ??= await SharedPreferences.getInstance(); 34 | 35 | Map data = { 36 | "value": value, 37 | "type": "${value.runtimeType}", 38 | }; 39 | 40 | _prefs?.setString(key, json.encode(data)); 41 | } 42 | 43 | Future _get(String key) async { 44 | _prefs ??= await SharedPreferences.getInstance(); 45 | 46 | Map data = json.decode(_prefs?.getString(key) ?? "{\"type\":\"Null\",\"value\":null}"); 47 | 48 | switch(data["type"]) { 49 | case "String": 50 | return data["value"]; 51 | case "int": 52 | return int.tryParse(data["value"]); 53 | case "double": 54 | return double.tryParse(data["value"]); 55 | case "bool": 56 | return data["value"] == "true" ? true : false; 57 | default: 58 | return null; 59 | } 60 | } 61 | 62 | Future _remove(String key) async { 63 | _prefs ??= await SharedPreferences.getInstance(); 64 | _prefs?.remove(key); 65 | } 66 | 67 | static Future insert(Map data) async => _instance._insert(data); 68 | static Future set(String key, dynamic value) async => Store._instance._set(key, value); 69 | static Future get(String key) async => Store._instance._get(key); 70 | static Future remove(String key) async => Store._instance._remove(key); 71 | } -------------------------------------------------------------------------------- /lib/data/watchlist.dart: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/appwrite/demo-almost-netflix-for-flutter/6d703dc36c725bc34ac4e1addb0a5649034da99e/lib/data/watchlist.dart -------------------------------------------------------------------------------- /lib/extensions/color.dart: -------------------------------------------------------------------------------- 1 | // 2 | // color.dart 3 | // Bastion 4 | // 5 | // Author: Wess Cope (wess@frenzylabs.com) 6 | // Created: 03/18/2021 7 | // 8 | // Copywrite (c) 2021 FrenzyLabs, LLC. 9 | // 10 | import 'package:flutter/material.dart'; 11 | 12 | 13 | Color _colorFromHex(String hex) { 14 | hex = hex.replaceAll('#', ''); 15 | 16 | switch(hex.length) { 17 | case 3: 18 | hex = "FF$hex$hex"; 19 | break; 20 | case 6: 21 | hex = "FF$hex"; 22 | break; 23 | case 8: 24 | break; 25 | default: 26 | throw Exception("Color hex code can only be 3, 6 or 8 characters long (not counting #)"); 27 | } 28 | 29 | 30 | return Color( 31 | int.parse("0x$hex") 32 | ); 33 | } 34 | 35 | extension ColorExt on Color { 36 | static Color from(String hexString) { 37 | return _colorFromHex(hexString); 38 | } 39 | } 40 | 41 | extension StringColorExt on String { 42 | toColor() { 43 | return _colorFromHex(this); 44 | } 45 | } -------------------------------------------------------------------------------- /lib/extensions/datetime.dart: -------------------------------------------------------------------------------- 1 | // 2 | // datetime.dart 3 | // appflix 4 | // 5 | // Author: wess (me@wess.io) 6 | // Created: 01/11/2022 7 | // 8 | // Copywrite (c) 2022 Wess.io 9 | // 10 | 11 | extension DateTimeExt on DateTime { 12 | static DateTime fromUnixTimestampInt(int timestamp) { 13 | return DateTime.fromMillisecondsSinceEpoch(timestamp); 14 | } 15 | 16 | static DateTime fromUnixTimestampString(String timestamp) { 17 | return DateTime.fromMillisecondsSinceEpoch(int.parse(timestamp)); 18 | } 19 | 20 | String toUnixTimestampString() { 21 | return millisecondsSinceEpoch.toString(); 22 | } 23 | } -------------------------------------------------------------------------------- /lib/extensions/list.dart: -------------------------------------------------------------------------------- 1 | // 2 | // list.dart 3 | // Bastion 4 | // 5 | // Author: Wess Cope (wess@frenzylabs.com) 6 | // Created: 03/25/2021 7 | // 8 | // Copywrite (c) 2021 FrenzyLabs, LLC. 9 | // 10 | 11 | extension ListExt on List { 12 | T? find(bool Function(T index) predicate) { 13 | try { 14 | return firstWhere(predicate); 15 | } on StateError { 16 | return null; 17 | } 18 | } 19 | } 20 | 21 | -------------------------------------------------------------------------------- /lib/extensions/num.dart: -------------------------------------------------------------------------------- 1 | // 2 | // num.dart 3 | // Bastion 4 | // 5 | // Author: Wess Cope (wess@frenzylabs.com) 6 | // Created: 03/25/2021 7 | // 8 | // Copywrite (c) 2021 FrenzyLabs, LLC. 9 | // 10 | 11 | import 'dart:math' as math; 12 | 13 | extension NumExt on num { 14 | double root(num exp) => (math.pow(this, 1 / exp) * 1E+9).round() / 1E+9; 15 | double sqrt() => math.sqrt(this); 16 | double cbrt() => root(3); 17 | 18 | double pow(int exp) => math.pow(this, exp).toDouble(); 19 | double squared() => pow(2); 20 | double cubed() => pow(3); 21 | } -------------------------------------------------------------------------------- /lib/main.dart: -------------------------------------------------------------------------------- 1 | // 2 | // main.dart 3 | // appflix 4 | // 5 | // Author: wess (me@wess.io) 6 | // Created: 12/29/2021 7 | // 8 | // Copywrite (c) 2022 Wess.io 9 | // 10 | 11 | import 'package:netflix_clone/providers/account.dart'; 12 | import 'package:netflix_clone/providers/entry.dart'; 13 | import 'package:netflix_clone/providers/watchlist.dart'; 14 | import 'package:netflix_clone/screens/navigation.dart'; 15 | import 'package:netflix_clone/screens/onboarding.dart'; 16 | import 'package:flutter/material.dart'; 17 | import 'package:provider/provider.dart'; 18 | 19 | Future main() async { 20 | WidgetsFlutterBinding.ensureInitialized(); 21 | 22 | runApp( 23 | MultiProvider( 24 | providers: [ 25 | ChangeNotifierProvider(create: (context) => AccountProvider()), 26 | ChangeNotifierProvider(create: (context) => EntryProvider()), 27 | ChangeNotifierProvider(create: (context) => WatchListProvider()), 28 | ], 29 | child: const Main(), 30 | ) 31 | ); 32 | } 33 | 34 | class Main extends StatelessWidget { 35 | const Main({Key? key}) : super(key: key); 36 | 37 | @override 38 | Widget build(BuildContext context) { 39 | return MaterialApp( 40 | title: 'Appflix', 41 | theme: ThemeData( 42 | scaffoldBackgroundColor: Colors.black, 43 | primarySwatch: Colors.blue, 44 | visualDensity: VisualDensity.adaptivePlatformDensity, 45 | ), 46 | home: FutureBuilder( 47 | future: context.read().isValid(), 48 | builder: (context, snapshot) => context.watch().session == null ? const OnboardingScreen() : const NavScreen(), 49 | ) 50 | ); 51 | } 52 | } -------------------------------------------------------------------------------- /lib/providers/account.dart: -------------------------------------------------------------------------------- 1 | // 2 | // account.dart 3 | // appflix 4 | // 5 | // Author: wess (me@wess.io) 6 | // Created: 01/03/2022 7 | // 8 | // Copywrite (c) 2022 Wess.io 9 | // 10 | 11 | import 'dart:convert'; 12 | 13 | import 'package:appwrite/appwrite.dart' as appwrite; 14 | import 'package:netflix_clone/api/client.dart'; 15 | import 'package:appwrite/models.dart'; 16 | import 'package:flutter/material.dart'; 17 | import 'package:netflix_clone/data/store.dart'; 18 | 19 | class AccountProvider extends ChangeNotifier { 20 | Account? _current; 21 | Account? get current => _current; 22 | 23 | Session? _session; 24 | Session? get session => _session; 25 | 26 | Future get _cachedSession async { 27 | final cached = await Store.get("session"); 28 | 29 | if (cached == null) { 30 | return null; 31 | } 32 | 33 | return Session.fromMap(json.decode(cached)); 34 | } 35 | 36 | Future isValid() async { 37 | if (session == null) { 38 | final cached = await _cachedSession; 39 | 40 | if (cached == null) { 41 | return false; 42 | } 43 | 44 | _session = cached; 45 | } 46 | 47 | return _session != null; 48 | } 49 | 50 | Future register(String email, String password, String? name) async { 51 | try { 52 | final result = await ApiClient.account.create( 53 | userId: appwrite.ID.unique(), email: email, password: password, name: name); 54 | 55 | _current = result; 56 | 57 | notifyListeners(); 58 | } catch (e) { 59 | throw Exception("Failed to register"); 60 | } 61 | } 62 | 63 | Future login(String email, String password) async { 64 | try { 65 | final result = await ApiClient.account.createEmailSession( 66 | email: email, 67 | password: password, 68 | ); 69 | _session = result; 70 | 71 | Store.set("session", json.encode(result.toMap())); 72 | 73 | notifyListeners(); 74 | } catch (e) { 75 | _session = null; 76 | } 77 | } 78 | } 79 | -------------------------------------------------------------------------------- /lib/providers/entry.dart: -------------------------------------------------------------------------------- 1 | // 2 | // entry.dart 3 | // appflix 4 | // 5 | // Author: wess (me@wess.io) 6 | // Created: 01/03/2022 7 | // 8 | // Copywrite (c) 2022 Wess.io 9 | // 10 | 11 | import 'dart:async'; 12 | import 'dart:typed_data'; 13 | 14 | import 'package:appwrite/appwrite.dart'; 15 | import 'package:netflix_clone/api/client.dart'; 16 | import 'package:netflix_clone/data/entry.dart'; 17 | import 'package:flutter/material.dart'; 18 | 19 | class EntryProvider extends ChangeNotifier { 20 | final Map _imageCache = {}; 21 | 22 | static final String _databaseId = ID.custom("default2"); 23 | static final String _collectionId = ID.custom("movies"); 24 | static final String _bucketId = ID.custom("default1"); 25 | 26 | Entry? _selected; 27 | Entry? get selected => _selected; 28 | 29 | Entry _featured = Entry.empty(); 30 | Entry get featured => _featured; 31 | 32 | List _entries = []; 33 | List get entries => _entries; 34 | List get originals => _entries.where((e) => e.isOriginal).toList(); 35 | List get animations => _entries 36 | .where((e) => e.genres.contains('animation')) 37 | .toList(); 38 | List get newReleases => _entries 39 | .where((e) => 40 | e.releaseDate != null && 41 | e.releaseDate!.isAfter(DateTime.parse('2018-01-01'))) 42 | .toList(); 43 | 44 | List get trending { 45 | var trending = _entries; 46 | 47 | trending.sort((a, b) => b.trendingIndex.compareTo(a.trendingIndex)); 48 | 49 | return trending; 50 | } 51 | 52 | void setSelected(Entry entry) { 53 | _selected = entry; 54 | 55 | notifyListeners(); 56 | } 57 | 58 | Future list() async { 59 | var result = 60 | await ApiClient.database.listDocuments(databaseId: _databaseId, collectionId: _collectionId); 61 | 62 | _entries = result.documents 63 | .map((document) => Entry.fromJson(document.data)) 64 | .toList(); 65 | _featured = _entries.isEmpty ? Entry.empty() : _entries[0]; 66 | 67 | notifyListeners(); 68 | } 69 | 70 | Future imageFor(Entry entry) async { 71 | if (_imageCache.containsKey(entry.thumbnailImageId)) { 72 | return _imageCache[entry.thumbnailImageId]!; 73 | } 74 | 75 | final result = await ApiClient.storage.getFileView( 76 | bucketId: _bucketId, 77 | fileId: entry.thumbnailImageId, 78 | ); 79 | 80 | _imageCache[entry.thumbnailImageId] = result; 81 | 82 | return result; 83 | } 84 | } 85 | -------------------------------------------------------------------------------- /lib/providers/watchlist.dart: -------------------------------------------------------------------------------- 1 | // 2 | // watchlist.dart 3 | // Netflix Clone 4 | // 5 | // Author: wess (wess@appwrite.io) 6 | // Created: 01/19/2022 7 | // 8 | // Copywrite (c) 2022 Appwrite.io 9 | // 10 | 11 | import 'dart:async'; 12 | import 'dart:typed_data'; 13 | import 'package:appwrite/appwrite.dart' as appwrite; 14 | import 'package:appwrite/models.dart'; 15 | import 'package:netflix_clone/api/client.dart'; 16 | import 'package:netflix_clone/data/entry.dart'; 17 | import 'package:flutter/material.dart'; 18 | 19 | class WatchListProvider extends ChangeNotifier { 20 | 21 | static final String _databaseId = appwrite.ID.custom("default2"); 22 | final String _collectionId = appwrite.ID.custom("watchlists"); 23 | static final String _bucketId = appwrite.ID.custom("default1"); 24 | 25 | List _entries = []; 26 | List get entries => _entries; 27 | 28 | Future get user { 29 | return ApiClient.account.get(); 30 | } 31 | 32 | Future> list() async { 33 | final user = await this.user; 34 | 35 | final watchlist = await ApiClient.database.listDocuments( 36 | databaseId: _databaseId, 37 | collectionId: _collectionId, 38 | ); 39 | 40 | final movieIds = watchlist.documents 41 | .map((document) => document.data["movieId"]) 42 | .toList(); 43 | final entries = 44 | (await ApiClient.database.listDocuments(databaseId: _databaseId, collectionId: appwrite.ID.custom('movies'))) 45 | .documents 46 | .map((document) => Entry.fromJson(document.data)) 47 | .toList(); 48 | final filtered = 49 | entries.where((entry) => movieIds.contains(entry.id)).toList(); 50 | 51 | _entries = filtered; 52 | 53 | notifyListeners(); 54 | 55 | return _entries; 56 | } 57 | 58 | Future add(Entry entry) async { 59 | final user = await this.user; 60 | 61 | var result = await ApiClient.database.createDocument( 62 | databaseId: _databaseId, 63 | collectionId: _collectionId, 64 | documentId: appwrite.ID.unique(), 65 | data: { 66 | "userId": user.$id, 67 | "movieId": entry.id, 68 | }); 69 | 70 | // _entries.add(Entry.fromJson(result.data)); 71 | 72 | list(); 73 | } 74 | 75 | Future remove(Entry entry) async { 76 | final user = await this.user; 77 | 78 | final result = await ApiClient.database.listDocuments( 79 | databaseId: _databaseId, 80 | collectionId: _collectionId, 81 | queries: [ 82 | appwrite.Query.equal("userId", user.$id), 83 | appwrite.Query.equal("movieId", entry.id) 84 | ]); 85 | 86 | final id = result.documents.first.$id; 87 | 88 | await ApiClient.database 89 | .deleteDocument(databaseId: _databaseId, collectionId: _collectionId, documentId: id); 90 | 91 | list(); 92 | } 93 | 94 | Future imageFor(Entry entry) async { 95 | return await ApiClient.storage.getFileView( 96 | bucketId: _bucketId, 97 | fileId: entry.thumbnailImageId, 98 | ); 99 | } 100 | 101 | bool isOnList(Entry entry) => _entries.any((e) => e.id == entry.id); 102 | } 103 | -------------------------------------------------------------------------------- /lib/screens/details.dart: -------------------------------------------------------------------------------- 1 | // 2 | // detail.dart 3 | // Netflix Clone 4 | // 5 | // Author: wess (wess@appwrite.io) 6 | // Created: 01/19/2022 7 | // 8 | // Copywrite (c) 2022 Appwrite.io 9 | // 10 | 11 | import 'dart:typed_data'; 12 | import 'dart:ui'; 13 | 14 | import 'package:flutter/material.dart'; 15 | import 'package:netflix_clone/providers/watchlist.dart'; 16 | import 'package:netflix_clone/widgets/buttons/icon.dart'; 17 | import 'package:provider/provider.dart'; 18 | import 'package:netflix_clone/data/entry.dart'; 19 | import 'package:netflix_clone/providers/entry.dart'; 20 | 21 | 22 | class DetailsScreen extends StatefulWidget { 23 | final Entry _entry; 24 | 25 | const DetailsScreen({Key? key, required Entry entry,}) : _entry = entry, super(key: key); 26 | 27 | @override 28 | State createState() => _DetailsScreenState(); 29 | } 30 | 31 | class _DetailsScreenState extends State { 32 | 33 | @override 34 | void initState() { 35 | super.initState(); 36 | } 37 | 38 | @override 39 | void dispose() { 40 | super.dispose(); 41 | } 42 | 43 | @override 44 | Widget build(BuildContext context) { 45 | return Scaffold( 46 | body: Column( 47 | mainAxisAlignment: MainAxisAlignment.start, 48 | crossAxisAlignment: CrossAxisAlignment.stretch, 49 | children: [ 50 | _DetailHeader(featured: widget._entry), 51 | const SizedBox(height: 20,), 52 | 53 | Expanded( 54 | child: Padding( 55 | padding: const EdgeInsets.fromLTRB(20, 0, 20, 0), 56 | child: Text( 57 | widget._entry.description ?? "", 58 | style: const TextStyle( 59 | fontSize: 14, 60 | color: Colors.white 61 | ) 62 | ), 63 | ) 64 | ), 65 | const SizedBox(height: 20), 66 | Expanded( 67 | child: Padding( 68 | padding: const EdgeInsets.fromLTRB(20, 0, 20, 0), 69 | child: Text( 70 | "Starring: ${widget._entry.cast.join(",")}", 71 | style: const TextStyle( 72 | fontSize: 12, 73 | color: Colors.white 74 | ) 75 | ), 76 | ) 77 | ), 78 | const Spacer(), 79 | Expanded( 80 | child: Row( 81 | mainAxisAlignment: MainAxisAlignment.center, 82 | crossAxisAlignment: CrossAxisAlignment.start, 83 | children: [ 84 | const Spacer(), 85 | VerticalIconButton( 86 | icon: context.read().isOnList(widget._entry) ? Icons.check : Icons.add, 87 | title: "My List", 88 | tap: () { 89 | 90 | if(context.read().isOnList(widget._entry)){ 91 | context.read().remove(widget._entry); 92 | } else { 93 | context.read().add(widget._entry); 94 | } 95 | 96 | Navigator.of(context).pop(); 97 | } 98 | ), 99 | const Spacer(), 100 | VerticalIconButton( 101 | icon: Icons.thumb_up, 102 | title: "Rate", 103 | tap: () {} 104 | ), 105 | const Spacer(), 106 | VerticalIconButton( 107 | icon: Icons.share, 108 | title: "Share", 109 | tap: () {} 110 | ), 111 | const Spacer(), 112 | ], 113 | ) 114 | ), 115 | const Spacer(), 116 | ], 117 | ) 118 | ); 119 | } 120 | } 121 | 122 | 123 | class _DetailHeader extends StatelessWidget { 124 | final Entry featured; 125 | 126 | const _DetailHeader({Key? key, required this.featured}) : super(key: key); 127 | 128 | @override 129 | Widget build(BuildContext context) { 130 | return FutureBuilder( 131 | future: context.read().imageFor(featured), 132 | builder: (context, snapshot) { 133 | if(snapshot.hasData == false || snapshot.data == null) { 134 | return const SizedBox( 135 | height: 500, 136 | child: Center(child: CircularProgressIndicator(),), 137 | ); 138 | } 139 | 140 | return Stack( 141 | fit: StackFit.passthrough, 142 | alignment: Alignment.center, 143 | children: [ 144 | Container( 145 | height: 500, 146 | decoration: BoxDecoration( 147 | image: DecorationImage( 148 | fit: BoxFit.cover, 149 | image: Image.memory((snapshot.data! as Uint8List)).image, 150 | ), 151 | ), 152 | child: BackdropFilter( 153 | filter: ImageFilter.blur(sigmaX: 20, sigmaY: 20), 154 | child: Container( 155 | height: 500, 156 | decoration: BoxDecoration( 157 | color: Colors.black.withOpacity(0.6) 158 | ), 159 | ), 160 | ), 161 | ), 162 | Positioned( 163 | top: 1, 164 | left: 10, 165 | child: IconButton( 166 | icon: const Icon(Icons.close, color: Colors.white, size: 30,), 167 | onPressed: () => Navigator.of(context).pop(), 168 | ) 169 | ), 170 | 171 | Positioned( 172 | bottom: 160, 173 | child: Container( 174 | height: 300, 175 | width: 200, 176 | decoration: BoxDecoration( 177 | image: DecorationImage( 178 | fit: BoxFit.cover, 179 | image: Image.memory((snapshot.data! as Uint8List)).image, 180 | ), 181 | ), 182 | ) 183 | ), 184 | Positioned( 185 | bottom: 120, 186 | child: Row( 187 | mainAxisAlignment: MainAxisAlignment.start, 188 | crossAxisAlignment: CrossAxisAlignment.start, 189 | children: [ 190 | const Padding( 191 | padding: EdgeInsets.all(5.0), 192 | child: Text( 193 | "96% Match", 194 | style: TextStyle( 195 | fontSize: 12, 196 | fontWeight: FontWeight.bold, 197 | color: Colors.green 198 | ), 199 | ), 200 | ), 201 | const SizedBox(width: 10,), 202 | Padding( 203 | padding: const EdgeInsets.all(5.0), 204 | child: Text( 205 | featured.releaseDate == null 206 | ? "2020" 207 | : featured.netflixReleaseDate!.year.toString(), 208 | style: const TextStyle( 209 | fontSize: 12, 210 | fontWeight: FontWeight.bold, 211 | color: Colors.white 212 | ), 213 | ), 214 | ), 215 | const SizedBox(width: 10,), 216 | Container( 217 | color: Colors.black.withAlpha(180), 218 | padding: const EdgeInsets.all(5), 219 | child: Text( 220 | featured.ageRestriction == "AR13" 221 | ? "13+" 222 | : "18+", 223 | style: const TextStyle( 224 | fontSize: 12, 225 | fontWeight: FontWeight.bold, 226 | color: Colors.white 227 | ), 228 | ), 229 | ), 230 | const SizedBox(width: 10,), 231 | Padding( 232 | padding: const EdgeInsets.all(5), 233 | child: Text( 234 | "${(featured.durationMinutes.inMinutes / 60).floor().toStringAsFixed(2).replaceAll('.', 'h')}m", 235 | style: const TextStyle( 236 | fontSize: 12, 237 | fontWeight: FontWeight.bold, 238 | color: Colors.white 239 | ), 240 | ), 241 | ), 242 | ], 243 | ) 244 | ), 245 | 246 | Positioned( 247 | bottom: 10, 248 | right: 10, 249 | left: 10, 250 | child: Column( 251 | mainAxisAlignment: MainAxisAlignment.start, 252 | crossAxisAlignment: CrossAxisAlignment.start, 253 | 254 | children: [ 255 | MaterialButton( 256 | color: Colors.white, 257 | onPressed: () {}, 258 | child: Row( 259 | mainAxisAlignment: MainAxisAlignment.center, 260 | children: const [ 261 | Icon(Icons.play_arrow), 262 | SizedBox(width: 8), 263 | Text("Play") 264 | ], 265 | ) 266 | ), 267 | MaterialButton( 268 | color: Colors.white.withAlpha(40), 269 | onPressed: () {}, 270 | child: Row( 271 | mainAxisAlignment: MainAxisAlignment.center, 272 | children: const [ 273 | Icon(Icons.download, color: Colors.white,), 274 | SizedBox(width: 8), 275 | Text( 276 | "Download", 277 | style: TextStyle( 278 | color: Colors.white 279 | ), 280 | ) 281 | ], 282 | ) 283 | ), 284 | ], 285 | ) 286 | ) 287 | ] 288 | ); 289 | } 290 | ); 291 | } 292 | } -------------------------------------------------------------------------------- /lib/screens/home.dart: -------------------------------------------------------------------------------- 1 | // 2 | // home.dart 3 | // appflix 4 | // 5 | // Author: wess (me@wess.io) 6 | // Created: 01/03/2022 7 | // 8 | // Copywrite (c) 2022 Wess.io 9 | // 10 | 11 | import 'package:netflix_clone/providers/entry.dart'; 12 | import 'package:netflix_clone/widgets/content/bar.dart'; 13 | import 'package:netflix_clone/widgets/content/header.dart'; 14 | import 'package:netflix_clone/widgets/content/list.dart'; 15 | import 'package:netflix_clone/widgets/previews.dart'; 16 | import 'package:flutter/material.dart'; 17 | import 'package:provider/provider.dart'; 18 | 19 | 20 | 21 | class HomeScreen extends StatefulWidget { 22 | 23 | const HomeScreen({required Key key}) : super(key: key); 24 | 25 | @override 26 | State createState() => _HomeScreenState(); 27 | } 28 | 29 | class _HomeScreenState extends State { 30 | double _scrollOffset = 0.0; 31 | ScrollController _scrollController = 32 | ScrollController(initialScrollOffset: 0.0); 33 | 34 | @override 35 | void initState() { 36 | _scrollController = ScrollController() 37 | ..addListener(() { 38 | setState(() { 39 | _scrollOffset = _scrollController.offset; 40 | }); 41 | }); 42 | 43 | 44 | super.initState(); 45 | } 46 | 47 | @override 48 | void dispose() { 49 | _scrollController.dispose(); 50 | super.dispose(); 51 | } 52 | 53 | @override 54 | Widget build(BuildContext context) { 55 | final Size screenSize = MediaQuery.of(context).size; 56 | 57 | return Scaffold( 58 | extendBodyBehindAppBar: true, 59 | appBar: PreferredSize( 60 | preferredSize: Size(screenSize.width, 70.0), 61 | child: ContentBar( 62 | scrollOffset: _scrollOffset, 63 | ), 64 | ), 65 | body: CustomScrollView( 66 | controller: _scrollController, 67 | slivers: [ 68 | SliverToBoxAdapter( 69 | child: ContentHeader(featured: context.watch().featured), 70 | ), 71 | const SliverPadding( 72 | padding: EdgeInsets.only(top: 20), 73 | sliver: SliverToBoxAdapter( 74 | child: Previews( 75 | key: PageStorageKey('previews'), 76 | title: 'Previews', 77 | ), 78 | ), 79 | ), 80 | SliverToBoxAdapter( 81 | child: Container( 82 | padding: const EdgeInsets.all(10), 83 | child: ContentList( 84 | title: 'Only on Almost Netflix', 85 | contentList: context.watch().entries, 86 | isOriginal: false, 87 | ), 88 | ), 89 | ), 90 | SliverToBoxAdapter( 91 | child: ContentList( 92 | title: 'New releases', 93 | contentList: context.watch().originals, 94 | isOriginal: true, 95 | ), 96 | ), 97 | SliverPadding( 98 | padding: const EdgeInsets.only(bottom: 20), 99 | sliver: SliverToBoxAdapter( 100 | child: ContentList( 101 | title: 'Animation', 102 | contentList: context.watch().animations, 103 | isOriginal: false, 104 | ), 105 | ), 106 | ), 107 | ], 108 | ), 109 | ); 110 | } 111 | } 112 | -------------------------------------------------------------------------------- /lib/screens/navigation.dart: -------------------------------------------------------------------------------- 1 | // 2 | // navigation.dart 3 | // appflix 4 | // 5 | // Author: wess (me@wess.io) 6 | // Created: 01/03/2022 7 | // 8 | // Copywrite (c) 2022 Wess.io 9 | // 10 | 11 | import 'package:flutter/material.dart'; 12 | import 'package:netflix_clone/data/entry.dart'; 13 | import 'package:netflix_clone/screens/watchlist.dart'; 14 | import 'package:provider/provider.dart'; 15 | import 'package:netflix_clone/providers/entry.dart'; 16 | import 'package:netflix_clone/Screens/home.dart'; 17 | 18 | 19 | class NavScreen extends StatefulWidget { 20 | const NavScreen({Key? key}) : super(key: key); 21 | 22 | @override 23 | State createState() => _NavScreenState(); 24 | } 25 | 26 | class _NavScreenState extends State { 27 | 28 | Widget home() => const HomeScreen(key: PageStorageKey('homescreen')); 29 | 30 | @override 31 | Widget build(BuildContext context) { 32 | Entry? selected = context.watch().selected; 33 | 34 | return FutureBuilder( 35 | future: context.read().list(), 36 | builder: (context, snapshot) { 37 | return Scaffold( 38 | body: home(), 39 | bottomNavigationBar: BottomNavigationBar( 40 | backgroundColor: Colors.transparent, 41 | unselectedItemColor: Colors.white, 42 | currentIndex: 0, 43 | onTap: (index) async { 44 | if(index == 1) { 45 | await showDialog( 46 | context: context, 47 | builder: (context) => const WatchlistScreen() 48 | ); 49 | 50 | } 51 | }, 52 | items: const [ 53 | BottomNavigationBarItem( 54 | icon: Icon(Icons.home), 55 | label: 'Home', 56 | ), 57 | BottomNavigationBarItem( 58 | icon: Icon(Icons.list), 59 | label: 'Watchlist', 60 | ), 61 | ], 62 | ), 63 | ); 64 | } 65 | ); 66 | } 67 | } 68 | -------------------------------------------------------------------------------- /lib/screens/onboarding.dart: -------------------------------------------------------------------------------- 1 | // 2 | // onboarding.dart 3 | // appflix 4 | // 5 | // Author: wess (me@wess.io) 6 | // Created: 01/03/2022 7 | // 8 | // Copywrite (c) 2022 Wess.io 9 | // 10 | 11 | import 'package:netflix_clone/providers/account.dart'; 12 | import 'package:flutter/material.dart'; 13 | import 'package:provider/provider.dart'; 14 | 15 | class OnboardingScreen extends StatefulWidget { 16 | 17 | const OnboardingScreen({Key? key}) : super(key: key); 18 | 19 | @override 20 | State createState() => _OnboardingScreenState(); 21 | } 22 | 23 | class _OnboardingScreenState extends State { 24 | final TextEditingController _nameController = TextEditingController(); 25 | final TextEditingController _emailController = TextEditingController(); 26 | final TextEditingController _passwordController = TextEditingController(); 27 | 28 | int _selectedIndex = 0; 29 | 30 | @override 31 | void initState() { 32 | super.initState(); 33 | } 34 | 35 | @override 36 | void dispose() { 37 | super.dispose(); 38 | } 39 | 40 | 41 | Widget _renderSignIn() { 42 | return Container( 43 | padding: const EdgeInsets.fromLTRB(60, 0, 60, 0), 44 | child: Column( 45 | crossAxisAlignment: CrossAxisAlignment.center, 46 | mainAxisAlignment: MainAxisAlignment.center, 47 | children: [ 48 | Center( 49 | child: Image.asset('assets/logo.png', width: 200), 50 | ), 51 | const SizedBox(height: 60), 52 | TextField( 53 | controller: _emailController, 54 | autofocus: false, 55 | autocorrect: false, 56 | enableSuggestions: false, 57 | decoration: const InputDecoration( 58 | filled: true, 59 | fillColor: Colors.grey, 60 | labelText: 'Email', 61 | floatingLabelStyle: TextStyle(color: Colors.black), 62 | focusedBorder: InputBorder.none, 63 | border: InputBorder.none, 64 | ), 65 | ), 66 | Container( 67 | height: 0.1, 68 | color: Colors.black, 69 | ), 70 | TextField( 71 | controller: _passwordController, 72 | obscureText: true, 73 | autofocus: false, 74 | autocorrect: false, 75 | enableSuggestions: false, 76 | decoration: const InputDecoration( 77 | filled: true, 78 | fillColor: Colors.grey, 79 | labelText: 'Password', 80 | floatingLabelStyle: TextStyle(color: Colors.black), 81 | focusedBorder: InputBorder.none, 82 | border: InputBorder.none, 83 | ), 84 | ), 85 | const SizedBox(height: 20.0), 86 | SizedBox( 87 | width: double.infinity, 88 | child: OutlinedButton( 89 | style: OutlinedButton.styleFrom( 90 | padding: const EdgeInsets.fromLTRB(0, 10, 0, 10), 91 | side: const BorderSide(width: 1.0, color: Colors.grey), 92 | ), 93 | child: const Text( 94 | "Sign in", 95 | style: TextStyle( 96 | color: Colors.white, 97 | fontWeight: FontWeight.bold, 98 | fontSize: 22.0 99 | ), 100 | ), 101 | onPressed: () async { 102 | final api = context.read(); 103 | final email = _emailController.text; 104 | final password = _passwordController.text; 105 | 106 | if (email.isEmpty || password.isEmpty) { 107 | showDialog(context: context, builder: (_) => AlertDialog( 108 | title: const Text('Error'), 109 | content: const Text('Please enter your email and password'), 110 | actions: [ 111 | TextButton( 112 | child: const Text('OK'), 113 | onPressed: () => Navigator.of(context).pop(), 114 | ) 115 | ], 116 | )); 117 | 118 | return; 119 | } 120 | 121 | await api.login(email, password); 122 | 123 | }, 124 | ), 125 | ), 126 | const SizedBox(height: 40.0), 127 | MaterialButton( 128 | child: const Text( 129 | "Don't have an account? Sign up", 130 | style: TextStyle(color: Colors.white), 131 | ), 132 | onPressed: () { 133 | setState(() { 134 | _selectedIndex = 1; 135 | }); 136 | }, 137 | ), 138 | const SizedBox(height: 10.0), 139 | MaterialButton( 140 | child: const Text( 141 | "Forgot your password?", 142 | style: TextStyle(color: Colors.white), 143 | ), 144 | onPressed: () {}, 145 | ), 146 | ], 147 | ), 148 | ); 149 | } 150 | 151 | Widget _renderSignUp() { 152 | return Container( 153 | padding: const EdgeInsets.fromLTRB(40, 0, 40, 0), 154 | child: Column( 155 | crossAxisAlignment: CrossAxisAlignment.center, 156 | mainAxisAlignment: MainAxisAlignment.center, 157 | children: [ 158 | Center( 159 | child: Image.asset('assets/logo.png', width: 200), 160 | ), 161 | const SizedBox(height: 60), 162 | TextField( 163 | controller: _nameController, 164 | autofocus: false, 165 | autocorrect: false, 166 | enableSuggestions: false, 167 | decoration: const InputDecoration( 168 | filled: true, 169 | fillColor: Colors.grey, 170 | labelText: 'Your name', 171 | floatingLabelStyle: TextStyle(color: Colors.black), 172 | focusedBorder: InputBorder.none, 173 | border: InputBorder.none, 174 | ), 175 | ), 176 | Container( 177 | height: 0.1, 178 | color: Colors.black, 179 | ), 180 | TextField( 181 | controller: _emailController, 182 | autofocus: false, 183 | autocorrect: false, 184 | enableSuggestions: false, 185 | decoration: const InputDecoration( 186 | filled: true, 187 | fillColor: Colors.grey, 188 | labelText: 'Email address', 189 | floatingLabelStyle: TextStyle(color: Colors.black), 190 | focusedBorder: InputBorder.none, 191 | border: InputBorder.none, 192 | ), 193 | ), 194 | Container( 195 | height: 0.1, 196 | color: Colors.black, 197 | ), 198 | TextField( 199 | controller: _passwordController, 200 | obscureText: true, 201 | autofocus: false, 202 | autocorrect: false, 203 | enableSuggestions: false, 204 | decoration: const InputDecoration( 205 | filled: true, 206 | fillColor: Colors.grey, 207 | labelText: 'Password', 208 | floatingLabelStyle: TextStyle(color: Colors.black), 209 | focusedBorder: InputBorder.none, 210 | border: InputBorder.none, 211 | ), 212 | ), 213 | const SizedBox(height: 20.0), 214 | SizedBox( 215 | width: double.infinity, 216 | child: OutlinedButton( 217 | style: OutlinedButton.styleFrom( 218 | padding: const EdgeInsets.fromLTRB(0, 10, 0, 10), 219 | side: const BorderSide(width: 1.0, color: Colors.grey), 220 | ), 221 | child: const Text( 222 | "Sign up", 223 | style: TextStyle( 224 | color: Colors.white, 225 | fontWeight: FontWeight.bold, 226 | fontSize: 22.0 227 | ), 228 | ), 229 | onPressed: () async { 230 | final api = context.read(); 231 | final name = _nameController.text; 232 | final email = _emailController.text; 233 | final password = _passwordController.text; 234 | 235 | if (email.isEmpty || password.isEmpty) { 236 | showDialog(context: context, builder: (_) => AlertDialog( 237 | title: const Text('Error'), 238 | content: const Text('Please enter your email and password'), 239 | actions: [ 240 | TextButton( 241 | child: const Text('OK'), 242 | onPressed: () => Navigator.of(context).pop(), 243 | ) 244 | ], 245 | )); 246 | 247 | return; 248 | } 249 | 250 | await api.register(email, password, name); 251 | 252 | }, 253 | ), 254 | ), 255 | const SizedBox(height: 10.0), 256 | MaterialButton( 257 | child: const Text( 258 | "Forgot your password?", 259 | style: TextStyle(color: Colors.white), 260 | ), 261 | onPressed: () {}, 262 | ), 263 | const SizedBox(height: 40.0), 264 | MaterialButton( 265 | child: const Text( 266 | "Already have an account? Sign in", 267 | style: TextStyle(color: Colors.white), 268 | ), 269 | onPressed: () { 270 | setState(() { 271 | _selectedIndex = 0; 272 | }); 273 | }, 274 | ), 275 | ], 276 | ), 277 | ); 278 | } 279 | 280 | @override 281 | Widget build(BuildContext context) { 282 | final Size screenSize = MediaQuery.of(context).size; 283 | 284 | final current = context.watch().current; 285 | 286 | _emailController.text = current?.email ?? ""; 287 | 288 | return Scaffold( 289 | extendBodyBehindAppBar: true, 290 | body: IndexedStack( 291 | index: _selectedIndex, 292 | children: [ 293 | _renderSignIn(), 294 | _renderSignUp(), 295 | ], 296 | ) 297 | ); 298 | } 299 | } 300 | 301 | 302 | -------------------------------------------------------------------------------- /lib/screens/watchlist.dart: -------------------------------------------------------------------------------- 1 | // 2 | // watchlist.dart 3 | // Netflix Clone 4 | // 5 | // Author: wess (wess@appwrite.io) 6 | // Created: 01/19/2022 7 | // 8 | // Copywrite (c) 2022 Appwrite.io 9 | // 10 | 11 | import 'dart:typed_data'; 12 | 13 | import 'package:flutter/material.dart'; 14 | import 'package:netflix_clone/providers/watchlist.dart'; 15 | import 'package:netflix_clone/screens/details.dart'; 16 | import 'package:netflix_clone/widgets/buttons/icon.dart'; 17 | import 'package:provider/provider.dart'; 18 | import 'package:netflix_clone/data/entry.dart'; 19 | import 'package:netflix_clone/providers/entry.dart'; 20 | 21 | 22 | class WatchlistScreen extends StatefulWidget { 23 | const WatchlistScreen({Key? key}) : super(key: key); 24 | 25 | @override 26 | State createState() => _WatchlistScreenState(); 27 | } 28 | 29 | class _WatchlistScreenState extends State { 30 | 31 | @override 32 | void initState() { 33 | super.initState(); 34 | } 35 | 36 | @override 37 | void dispose() { 38 | super.dispose(); 39 | } 40 | 41 | Widget _row(Entry entry) { 42 | return Row( 43 | mainAxisAlignment: MainAxisAlignment.start, 44 | crossAxisAlignment: CrossAxisAlignment.start, 45 | children: [ 46 | FutureBuilder( 47 | future: context.read().imageFor(entry), 48 | builder: (context, snapshot) => snapshot.hasData && snapshot.data != null 49 | ? Container( 50 | width: 80, 51 | height: 80, 52 | decoration: BoxDecoration( 53 | image: DecorationImage( 54 | fit: BoxFit.contain, 55 | image: Image.memory(snapshot.data!).image, 56 | ), 57 | ), 58 | ) 59 | : Container(), 60 | ), 61 | const SizedBox(width: 10,), 62 | Expanded( 63 | child: Column( 64 | crossAxisAlignment: CrossAxisAlignment.start, 65 | children: [ 66 | Text( 67 | entry.name, 68 | style: const TextStyle( 69 | color: Colors.white, 70 | fontSize: 16, 71 | fontWeight: FontWeight.w500, 72 | ), 73 | ), 74 | Text( 75 | ((entry.description ?? "").length < 51) ? (entry.description ?? "") : "${(entry.description ?? "").substring(0, 50)}...", 76 | style: const TextStyle( 77 | color: Colors.grey, 78 | fontSize: 14, 79 | fontWeight: FontWeight.w500, 80 | ), 81 | ), 82 | ], 83 | ) 84 | ), 85 | 86 | Padding( 87 | padding: const EdgeInsets.fromLTRB(20, 20, 30, 20), 88 | child: VerticalIconButton( 89 | icon: Icons.delete, 90 | title: '', 91 | tap: () async { 92 | await context.read().remove(entry); 93 | setState(() {}); 94 | } 95 | ), 96 | ), 97 | ], 98 | ); 99 | } 100 | 101 | @override 102 | Widget build(BuildContext context) { 103 | return Scaffold( 104 | appBar: AppBar( 105 | backgroundColor: Colors.transparent, 106 | title: const Text('Watchlist'), 107 | actions: [ 108 | IconButton( 109 | icon: const Icon(Icons.close), 110 | onPressed: () { 111 | Navigator.pop(context); 112 | }, 113 | ), 114 | ], 115 | ), 116 | body: FutureBuilder>( 117 | future: context.read().list(), 118 | builder: (context, snapshot) { 119 | return snapshot.hasData == false || snapshot.data == null 120 | ? const Padding( 121 | padding: EdgeInsets.all(60), 122 | child: Center( 123 | child: CircularProgressIndicator() 124 | ) 125 | ) 126 | : ListView( 127 | children: snapshot.data!.map((entry) => GestureDetector( 128 | child: _row(entry), 129 | onTap:() async { 130 | await showDialog( 131 | context: context, 132 | builder: (context) => DetailsScreen(entry: entry) 133 | ); 134 | } 135 | )).toList(), 136 | ); 137 | } 138 | ) 139 | ); 140 | } 141 | } 142 | -------------------------------------------------------------------------------- /lib/widgets/buttons/icon.dart: -------------------------------------------------------------------------------- 1 | // 2 | // icon.dart 3 | // appflix 4 | // 5 | // Author: wess (me@wess.io) 6 | // Created: 01/03/2022 7 | // 8 | // Copywrite (c) 2022 Wess.io 9 | // 10 | 11 | import 'package:flutter/material.dart'; 12 | 13 | class VerticalIconButton extends StatelessWidget { 14 | final IconData icon; 15 | final String title; 16 | final Function tap; 17 | 18 | const VerticalIconButton( 19 | {Key? key, required this.icon, required this.title, required this.tap}) 20 | : super(key: key); 21 | 22 | @override 23 | Widget build(BuildContext context) { 24 | return GestureDetector( 25 | onTapUp: (_) { tap(); }, 26 | child: Column( 27 | mainAxisAlignment: MainAxisAlignment.center, 28 | children: [ 29 | Icon( 30 | icon, 31 | color: Colors.white, 32 | ), 33 | const SizedBox( 34 | height: 2.0, 35 | ), 36 | Text( 37 | title, 38 | style: const TextStyle(color: Colors.white), 39 | ), 40 | ], 41 | ), 42 | ); 43 | } 44 | } 45 | -------------------------------------------------------------------------------- /lib/widgets/content/bar.dart: -------------------------------------------------------------------------------- 1 | // 2 | // bar.dart 3 | // appflix 4 | // 5 | // Author: wess (me@wess.io) 6 | // Created: 01/03/2022 7 | // 8 | // Copywrite (c) 2022 Wess.io 9 | // 10 | 11 | import 'package:flutter/material.dart'; 12 | import 'package:netflix_clone/assets.dart'; 13 | import 'package:netflix_clone/screens/watchlist.dart'; 14 | 15 | class ContentBar extends StatelessWidget { 16 | final double scrollOffset; 17 | 18 | const ContentBar({Key? key, this.scrollOffset = 0.0}) : super(key: key); 19 | 20 | @override 21 | Widget build(BuildContext context) { 22 | return Container( 23 | padding: const EdgeInsets.symmetric(vertical: 10, horizontal: 24.0), 24 | color: Colors.black.withOpacity((scrollOffset / 350).clamp(0, 1)), 25 | child: SafeArea( 26 | child: Row( 27 | children: [ 28 | Image.asset(Assets.netflixLogo0), 29 | const SizedBox( 30 | width: 12.0, 31 | ), 32 | Expanded( 33 | child: Row( 34 | mainAxisAlignment: MainAxisAlignment.spaceEvenly, 35 | children: [ 36 | const Spacer(), 37 | _AppBarButton("TV Shows", () {}), 38 | const Spacer(), 39 | _AppBarButton("Movies", () {}), 40 | const Spacer(), 41 | _AppBarButton('My List', () async { 42 | await showDialog( 43 | context: context, 44 | builder: (context) => const WatchlistScreen() 45 | ); 46 | }), 47 | ], 48 | ), 49 | ), 50 | ], 51 | ), 52 | ), 53 | ); 54 | } 55 | } 56 | 57 | class _AppBarButton extends StatelessWidget { 58 | final String title; 59 | final Function function; 60 | 61 | const _AppBarButton(this.title, this.function); 62 | 63 | @override 64 | Widget build(BuildContext context) { 65 | return GestureDetector( 66 | onTap: () { function(); }, 67 | child: Text( 68 | title, 69 | style: const TextStyle( 70 | color: Colors.white, fontSize: 16.0, fontWeight: FontWeight.w500), 71 | ), 72 | ); 73 | } 74 | } 75 | -------------------------------------------------------------------------------- /lib/widgets/content/header.dart: -------------------------------------------------------------------------------- 1 | // 2 | // header.dart 3 | // appflix 4 | // 5 | // Author: wess (me@wess.io) 6 | // Created: 01/03/2022 7 | // 8 | // Copywrite (c) 2022 Wess.io 9 | // 10 | 11 | import 'dart:typed_data'; 12 | 13 | import 'package:netflix_clone/data/entry.dart'; 14 | import 'package:netflix_clone/providers/entry.dart'; 15 | import 'package:netflix_clone/providers/watchlist.dart'; 16 | import 'package:netflix_clone/screens/details.dart'; 17 | import 'package:netflix_clone/widgets/buttons/icon.dart'; 18 | import 'package:flutter/material.dart'; 19 | import 'package:provider/provider.dart'; 20 | 21 | class ContentHeader extends StatelessWidget { 22 | final Entry featured; 23 | 24 | const ContentHeader({Key? key, required this.featured}) : super(key: key); 25 | 26 | @override 27 | Widget build(BuildContext context) { 28 | 29 | return FutureBuilder( 30 | future: context.read().imageFor(featured), 31 | builder: (context, snapshot) { 32 | if(snapshot.hasData == false || snapshot.data == null) { 33 | return const SizedBox( 34 | height: 500, 35 | child: Center(child: CircularProgressIndicator(),), 36 | ); 37 | } 38 | 39 | return Stack( 40 | alignment: Alignment.center, 41 | children: [ 42 | Container( 43 | height: 500, 44 | decoration: BoxDecoration( 45 | image: DecorationImage( 46 | fit: BoxFit.cover, 47 | image: Image.memory((snapshot.data! as Uint8List)).image, 48 | ), 49 | ), 50 | ), 51 | Container( 52 | height: 500, 53 | decoration: const BoxDecoration( 54 | gradient: LinearGradient( 55 | colors: [Colors.black, Colors.transparent], 56 | begin: Alignment.bottomCenter, 57 | end: Alignment.topCenter, 58 | ), 59 | ), 60 | ), 61 | Positioned( 62 | bottom: 120, 63 | child: SizedBox( 64 | width: 250, 65 | child: Text( 66 | featured.name, 67 | textAlign: TextAlign.center, 68 | style: const TextStyle( 69 | color: Colors.white, 70 | fontSize: 24, 71 | fontWeight: FontWeight.bold, 72 | ), 73 | ) 74 | ), 75 | ), 76 | Positioned( 77 | bottom: 88, 78 | child: SizedBox( 79 | width: 250, 80 | child: Text( 81 | featured.tags.join(" • "), 82 | textAlign: TextAlign.center, 83 | style: const TextStyle( 84 | color: Colors.white, 85 | fontSize: 10, 86 | fontWeight: FontWeight.normal, 87 | ), 88 | ) 89 | ), 90 | ), 91 | Positioned( 92 | right: 0, 93 | left: 0, 94 | bottom: 20, 95 | child: Row( 96 | mainAxisAlignment: MainAxisAlignment.spaceEvenly, 97 | children: [ 98 | const Spacer(), 99 | VerticalIconButton( 100 | icon: context.read().isOnList(featured) ? Icons.check : Icons.add, 101 | title: 'Watchlist', 102 | tap: () { 103 | if(context.read().isOnList(featured)){ 104 | context.read().remove(featured); 105 | } else { 106 | context.read().add(featured); 107 | } 108 | }, 109 | ), 110 | 111 | const SizedBox(width: 40), 112 | 113 | MaterialButton( 114 | color: Colors.white, 115 | child: Row( 116 | children: const [ 117 | Icon(Icons.play_arrow), 118 | Text("Play") 119 | ], 120 | ), 121 | onPressed: (){} 122 | ), 123 | 124 | const SizedBox(width: 40), 125 | 126 | VerticalIconButton( 127 | icon: Icons.info, 128 | title: 'Info', 129 | tap: () async { 130 | await showDialog( 131 | context: context, 132 | builder: (context) => DetailsScreen(entry: featured) 133 | ); 134 | }, 135 | ), 136 | const Spacer(), 137 | ], 138 | ), 139 | ) 140 | ] 141 | ); 142 | } 143 | ); 144 | } 145 | } -------------------------------------------------------------------------------- /lib/widgets/content/list.dart: -------------------------------------------------------------------------------- 1 | // 2 | // list.dart 3 | // appflix 4 | // 5 | // Author: wess (me@wess.io) 6 | // Created: 01/03/2022 7 | // 8 | // Copywrite (c) 2022 Wess.io 9 | // 10 | 11 | import 'dart:typed_data'; 12 | 13 | import 'package:flutter/material.dart'; 14 | import 'package:netflix_clone/screens/details.dart'; 15 | import 'package:provider/provider.dart'; 16 | import 'package:netflix_clone/data/entry.dart'; 17 | import 'package:netflix_clone/providers/entry.dart'; 18 | 19 | 20 | class ContentList extends StatelessWidget { 21 | final String title; 22 | final List contentList; 23 | bool isOriginal; 24 | final bool _rounded; 25 | 26 | ContentList({ 27 | Key? key, 28 | required this.title, 29 | required this.contentList, 30 | required this.isOriginal, 31 | bool rounded = false, 32 | }) : _rounded = rounded, super(key: key); 33 | 34 | @override 35 | Widget build(BuildContext context) { 36 | return Column( 37 | crossAxisAlignment: CrossAxisAlignment.start, 38 | children: [ 39 | Padding( 40 | padding: const EdgeInsets.only(left: 30.0, bottom: 10, top: 20), 41 | child: Text( 42 | title, 43 | style: const TextStyle( 44 | color: Colors.white, 45 | fontWeight: FontWeight.bold, 46 | fontSize: 20.0 47 | ), 48 | ), 49 | ), 50 | SizedBox( 51 | height: 200, 52 | child: ListView.builder( 53 | scrollDirection: Axis.horizontal, 54 | itemCount: contentList.length, 55 | itemBuilder: (context, int count) { 56 | final Entry current = contentList[count]; 57 | return GestureDetector( 58 | onTap: () async { 59 | await showDialog( 60 | context: context, 61 | builder: (context) => DetailsScreen(entry: current) 62 | ); 63 | }, 64 | child: Container( 65 | height: 100, 66 | margin: const EdgeInsets.symmetric(vertical: 8, horizontal: 4), 67 | child: FutureBuilder( 68 | future: context.read().imageFor(current), 69 | builder: (context, snapshot) => snapshot.hasData 70 | ? Image.memory( 71 | snapshot.data!, 72 | fit: BoxFit.cover, 73 | ) 74 | : Container( 75 | color: Colors.black, 76 | ), 77 | ) 78 | ), 79 | ); 80 | }, 81 | ), 82 | ) 83 | ], 84 | ); 85 | } 86 | } 87 | -------------------------------------------------------------------------------- /lib/widgets/previews.dart: -------------------------------------------------------------------------------- 1 | // 2 | // previews.dart 3 | // appflix 4 | // 5 | // Author: wess (me@wess.io) 6 | // Created: 01/03/2022 7 | // 8 | // Copywrite (c) 2022 Wess.io 9 | // 10 | 11 | import 'dart:typed_data'; 12 | 13 | import 'package:flutter/material.dart'; 14 | import 'package:provider/provider.dart'; 15 | 16 | import 'package:netflix_clone/data/entry.dart'; 17 | import 'package:netflix_clone/providers/entry.dart'; 18 | import 'package:netflix_clone/screens/details.dart'; 19 | 20 | class Previews extends StatefulWidget { 21 | final String title; 22 | 23 | const Previews({ 24 | Key? key, 25 | required this.title, 26 | }) : super(key: key); 27 | 28 | @override 29 | State createState() => _PreviewsState(); 30 | } 31 | 32 | class _PreviewsState extends State { 33 | 34 | Widget _renderStack(Entry entry) { 35 | return FutureBuilder( 36 | future: context.read().imageFor(entry), 37 | builder: (context, snapshot) { 38 | if(snapshot.connectionState == ConnectionState.waiting) { 39 | return const SizedBox( 40 | height: 130, 41 | width: 130, 42 | child: Center(child: CircularProgressIndicator(),), 43 | ); 44 | } 45 | 46 | return Stack( 47 | alignment: Alignment.center, 48 | children: [ 49 | snapshot.hasData && snapshot.data != null 50 | ? Container( 51 | margin: const EdgeInsets.symmetric( 52 | horizontal: 16.0, vertical: 8.0), 53 | height: 130, 54 | width: 130, 55 | decoration: BoxDecoration( 56 | image: DecorationImage( 57 | image: Image.memory((snapshot.data! as Uint8List)).image, 58 | fit: BoxFit.cover, 59 | ), 60 | shape: BoxShape.circle, 61 | border: 62 | Border.all(color: Colors.white.withAlpha(40), width: 4.0)), 63 | ) 64 | : const CircularProgressIndicator(), 65 | Container( 66 | height: 130, 67 | width: 130, 68 | decoration: BoxDecoration( 69 | gradient: const LinearGradient( 70 | colors: [ 71 | Colors.black87, 72 | Colors.black45, 73 | Colors.transparent 74 | ], 75 | stops: [ 76 | 0, 77 | 0.25, 78 | 1 79 | ], 80 | begin: Alignment.bottomCenter, 81 | end: Alignment.topCenter), 82 | shape: BoxShape.circle, 83 | border: Border.all(color: Colors.white.withAlpha(40), width: 4.0), 84 | ), 85 | ), 86 | Positioned( 87 | bottom: 0, 88 | right: 0, 89 | left: 0, 90 | child: SizedBox( 91 | height: 60, 92 | child: Text( 93 | entry.name.length > 14 94 | ? entry.name.substring(0, 14) 95 | : entry.name, 96 | textAlign: TextAlign.center, 97 | style: const TextStyle( 98 | color: Colors.white, 99 | fontSize: 12, 100 | fontWeight: FontWeight.bold, 101 | ), 102 | ) 103 | ), 104 | ), 105 | ], 106 | ); 107 | } 108 | ); 109 | } 110 | 111 | @override 112 | Widget build(BuildContext context) { 113 | var entries = context.read().entries; 114 | 115 | return Column( 116 | crossAxisAlignment: CrossAxisAlignment.start, 117 | children: [ 118 | const Padding( 119 | padding: EdgeInsets.only(left: 30.0), 120 | child: Text( 121 | 'Popular this week', 122 | style: TextStyle( 123 | color: Colors.white, 124 | fontWeight: FontWeight.bold, 125 | fontSize: 20.0 126 | ), 127 | ), 128 | ), 129 | SizedBox( 130 | height: 165.0, 131 | child: ListView.builder( 132 | scrollDirection: Axis.horizontal, 133 | itemCount: entries.length, 134 | itemBuilder: (BuildContext context, int index) { 135 | final Entry entry = entries[index]; 136 | 137 | return GestureDetector( 138 | onTap: () async { 139 | await showDialog( 140 | context: context, 141 | builder: (context) => DetailsScreen(entry: entry) 142 | ); 143 | }, 144 | child: _renderStack(entry), 145 | ); 146 | }), 147 | ), 148 | ], 149 | ); 150 | } 151 | } 152 | -------------------------------------------------------------------------------- /pubspec.lock: -------------------------------------------------------------------------------- 1 | # Generated by pub 2 | # See https://dart.dev/tools/pub/glossary#lockfile 3 | packages: 4 | adaptive_dialog: 5 | dependency: "direct main" 6 | description: 7 | name: adaptive_dialog 8 | url: "https://pub.dartlang.org" 9 | source: hosted 10 | version: "1.6.4+2" 11 | animations: 12 | dependency: transitive 13 | description: 14 | name: animations 15 | url: "https://pub.dartlang.org" 16 | source: hosted 17 | version: "2.0.3" 18 | appwrite: 19 | dependency: "direct main" 20 | description: 21 | name: appwrite 22 | url: "https://pub.dartlang.org" 23 | source: hosted 24 | version: "6.0.0" 25 | async: 26 | dependency: transitive 27 | description: 28 | name: async 29 | url: "https://pub.dartlang.org" 30 | source: hosted 31 | version: "2.8.2" 32 | boolean_selector: 33 | dependency: transitive 34 | description: 35 | name: boolean_selector 36 | url: "https://pub.dartlang.org" 37 | source: hosted 38 | version: "2.1.0" 39 | characters: 40 | dependency: transitive 41 | description: 42 | name: characters 43 | url: "https://pub.dartlang.org" 44 | source: hosted 45 | version: "1.2.0" 46 | charcode: 47 | dependency: transitive 48 | description: 49 | name: charcode 50 | url: "https://pub.dartlang.org" 51 | source: hosted 52 | version: "1.3.1" 53 | clock: 54 | dependency: transitive 55 | description: 56 | name: clock 57 | url: "https://pub.dartlang.org" 58 | source: hosted 59 | version: "1.1.0" 60 | collection: 61 | dependency: transitive 62 | description: 63 | name: collection 64 | url: "https://pub.dartlang.org" 65 | source: hosted 66 | version: "1.16.0" 67 | cookie_jar: 68 | dependency: transitive 69 | description: 70 | name: cookie_jar 71 | url: "https://pub.dartlang.org" 72 | source: hosted 73 | version: "3.0.1" 74 | crypto: 75 | dependency: transitive 76 | description: 77 | name: crypto 78 | url: "https://pub.dartlang.org" 79 | source: hosted 80 | version: "3.0.2" 81 | cupertino_icons: 82 | dependency: "direct main" 83 | description: 84 | name: cupertino_icons 85 | url: "https://pub.dartlang.org" 86 | source: hosted 87 | version: "1.0.5" 88 | device_info_plus: 89 | dependency: transitive 90 | description: 91 | name: device_info_plus 92 | url: "https://pub.dartlang.org" 93 | source: hosted 94 | version: "3.2.4" 95 | device_info_plus_linux: 96 | dependency: transitive 97 | description: 98 | name: device_info_plus_linux 99 | url: "https://pub.dartlang.org" 100 | source: hosted 101 | version: "2.1.1" 102 | device_info_plus_macos: 103 | dependency: transitive 104 | description: 105 | name: device_info_plus_macos 106 | url: "https://pub.dartlang.org" 107 | source: hosted 108 | version: "2.2.3" 109 | device_info_plus_platform_interface: 110 | dependency: transitive 111 | description: 112 | name: device_info_plus_platform_interface 113 | url: "https://pub.dartlang.org" 114 | source: hosted 115 | version: "2.3.0+1" 116 | device_info_plus_web: 117 | dependency: transitive 118 | description: 119 | name: device_info_plus_web 120 | url: "https://pub.dartlang.org" 121 | source: hosted 122 | version: "2.1.0" 123 | device_info_plus_windows: 124 | dependency: transitive 125 | description: 126 | name: device_info_plus_windows 127 | url: "https://pub.dartlang.org" 128 | source: hosted 129 | version: "2.1.1" 130 | dynamic_color: 131 | dependency: transitive 132 | description: 133 | name: dynamic_color 134 | url: "https://pub.dartlang.org" 135 | source: hosted 136 | version: "1.4.0" 137 | fake_async: 138 | dependency: transitive 139 | description: 140 | name: fake_async 141 | url: "https://pub.dartlang.org" 142 | source: hosted 143 | version: "1.3.0" 144 | ffi: 145 | dependency: transitive 146 | description: 147 | name: ffi 148 | url: "https://pub.dartlang.org" 149 | source: hosted 150 | version: "1.2.1" 151 | file: 152 | dependency: transitive 153 | description: 154 | name: file 155 | url: "https://pub.dartlang.org" 156 | source: hosted 157 | version: "6.1.2" 158 | fluro: 159 | dependency: "direct main" 160 | description: 161 | name: fluro 162 | url: "https://pub.dartlang.org" 163 | source: hosted 164 | version: "2.0.3" 165 | flutter: 166 | dependency: "direct main" 167 | description: flutter 168 | source: sdk 169 | version: "0.0.0" 170 | flutter_lints: 171 | dependency: "direct dev" 172 | description: 173 | name: flutter_lints 174 | url: "https://pub.dartlang.org" 175 | source: hosted 176 | version: "2.0.1" 177 | flutter_test: 178 | dependency: "direct dev" 179 | description: flutter 180 | source: sdk 181 | version: "0.0.0" 182 | flutter_web_auth: 183 | dependency: transitive 184 | description: 185 | name: flutter_web_auth 186 | url: "https://pub.dartlang.org" 187 | source: hosted 188 | version: "0.4.1" 189 | flutter_web_plugins: 190 | dependency: transitive 191 | description: flutter 192 | source: sdk 193 | version: "0.0.0" 194 | http: 195 | dependency: transitive 196 | description: 197 | name: http 198 | url: "https://pub.dartlang.org" 199 | source: hosted 200 | version: "0.13.4" 201 | http_parser: 202 | dependency: transitive 203 | description: 204 | name: http_parser 205 | url: "https://pub.dartlang.org" 206 | source: hosted 207 | version: "4.0.1" 208 | intersperse: 209 | dependency: transitive 210 | description: 211 | name: intersperse 212 | url: "https://pub.dartlang.org" 213 | source: hosted 214 | version: "2.0.0" 215 | js: 216 | dependency: transitive 217 | description: 218 | name: js 219 | url: "https://pub.dartlang.org" 220 | source: hosted 221 | version: "0.6.4" 222 | lints: 223 | dependency: transitive 224 | description: 225 | name: lints 226 | url: "https://pub.dartlang.org" 227 | source: hosted 228 | version: "2.0.0" 229 | macos_ui: 230 | dependency: transitive 231 | description: 232 | name: macos_ui 233 | url: "https://pub.dartlang.org" 234 | source: hosted 235 | version: "1.7.0" 236 | matcher: 237 | dependency: transitive 238 | description: 239 | name: matcher 240 | url: "https://pub.dartlang.org" 241 | source: hosted 242 | version: "0.12.11" 243 | material_color_utilities: 244 | dependency: transitive 245 | description: 246 | name: material_color_utilities 247 | url: "https://pub.dartlang.org" 248 | source: hosted 249 | version: "0.1.4" 250 | meta: 251 | dependency: transitive 252 | description: 253 | name: meta 254 | url: "https://pub.dartlang.org" 255 | source: hosted 256 | version: "1.7.0" 257 | nested: 258 | dependency: transitive 259 | description: 260 | name: nested 261 | url: "https://pub.dartlang.org" 262 | source: hosted 263 | version: "1.0.0" 264 | package_info_plus: 265 | dependency: transitive 266 | description: 267 | name: package_info_plus 268 | url: "https://pub.dartlang.org" 269 | source: hosted 270 | version: "1.4.2" 271 | package_info_plus_linux: 272 | dependency: transitive 273 | description: 274 | name: package_info_plus_linux 275 | url: "https://pub.dartlang.org" 276 | source: hosted 277 | version: "1.0.5" 278 | package_info_plus_macos: 279 | dependency: transitive 280 | description: 281 | name: package_info_plus_macos 282 | url: "https://pub.dartlang.org" 283 | source: hosted 284 | version: "1.3.0" 285 | package_info_plus_platform_interface: 286 | dependency: transitive 287 | description: 288 | name: package_info_plus_platform_interface 289 | url: "https://pub.dartlang.org" 290 | source: hosted 291 | version: "1.0.2" 292 | package_info_plus_web: 293 | dependency: transitive 294 | description: 295 | name: package_info_plus_web 296 | url: "https://pub.dartlang.org" 297 | source: hosted 298 | version: "1.0.5" 299 | package_info_plus_windows: 300 | dependency: transitive 301 | description: 302 | name: package_info_plus_windows 303 | url: "https://pub.dartlang.org" 304 | source: hosted 305 | version: "1.0.5" 306 | path: 307 | dependency: transitive 308 | description: 309 | name: path 310 | url: "https://pub.dartlang.org" 311 | source: hosted 312 | version: "1.8.1" 313 | path_provider: 314 | dependency: transitive 315 | description: 316 | name: path_provider 317 | url: "https://pub.dartlang.org" 318 | source: hosted 319 | version: "2.0.11" 320 | path_provider_android: 321 | dependency: transitive 322 | description: 323 | name: path_provider_android 324 | url: "https://pub.dartlang.org" 325 | source: hosted 326 | version: "2.0.16" 327 | path_provider_ios: 328 | dependency: transitive 329 | description: 330 | name: path_provider_ios 331 | url: "https://pub.dartlang.org" 332 | source: hosted 333 | version: "2.0.10" 334 | path_provider_linux: 335 | dependency: transitive 336 | description: 337 | name: path_provider_linux 338 | url: "https://pub.dartlang.org" 339 | source: hosted 340 | version: "2.1.7" 341 | path_provider_macos: 342 | dependency: transitive 343 | description: 344 | name: path_provider_macos 345 | url: "https://pub.dartlang.org" 346 | source: hosted 347 | version: "2.0.6" 348 | path_provider_platform_interface: 349 | dependency: transitive 350 | description: 351 | name: path_provider_platform_interface 352 | url: "https://pub.dartlang.org" 353 | source: hosted 354 | version: "2.0.4" 355 | path_provider_windows: 356 | dependency: transitive 357 | description: 358 | name: path_provider_windows 359 | url: "https://pub.dartlang.org" 360 | source: hosted 361 | version: "2.0.7" 362 | platform: 363 | dependency: transitive 364 | description: 365 | name: platform 366 | url: "https://pub.dartlang.org" 367 | source: hosted 368 | version: "3.1.0" 369 | plugin_platform_interface: 370 | dependency: transitive 371 | description: 372 | name: plugin_platform_interface 373 | url: "https://pub.dartlang.org" 374 | source: hosted 375 | version: "2.1.2" 376 | process: 377 | dependency: transitive 378 | description: 379 | name: process 380 | url: "https://pub.dartlang.org" 381 | source: hosted 382 | version: "4.2.4" 383 | provider: 384 | dependency: "direct main" 385 | description: 386 | name: provider 387 | url: "https://pub.dartlang.org" 388 | source: hosted 389 | version: "6.0.3" 390 | shared_preferences: 391 | dependency: "direct main" 392 | description: 393 | name: shared_preferences 394 | url: "https://pub.dartlang.org" 395 | source: hosted 396 | version: "2.0.15" 397 | shared_preferences_android: 398 | dependency: transitive 399 | description: 400 | name: shared_preferences_android 401 | url: "https://pub.dartlang.org" 402 | source: hosted 403 | version: "2.0.12" 404 | shared_preferences_ios: 405 | dependency: transitive 406 | description: 407 | name: shared_preferences_ios 408 | url: "https://pub.dartlang.org" 409 | source: hosted 410 | version: "2.1.1" 411 | shared_preferences_linux: 412 | dependency: transitive 413 | description: 414 | name: shared_preferences_linux 415 | url: "https://pub.dartlang.org" 416 | source: hosted 417 | version: "2.1.1" 418 | shared_preferences_macos: 419 | dependency: transitive 420 | description: 421 | name: shared_preferences_macos 422 | url: "https://pub.dartlang.org" 423 | source: hosted 424 | version: "2.0.4" 425 | shared_preferences_platform_interface: 426 | dependency: transitive 427 | description: 428 | name: shared_preferences_platform_interface 429 | url: "https://pub.dartlang.org" 430 | source: hosted 431 | version: "2.0.0" 432 | shared_preferences_web: 433 | dependency: transitive 434 | description: 435 | name: shared_preferences_web 436 | url: "https://pub.dartlang.org" 437 | source: hosted 438 | version: "2.0.4" 439 | shared_preferences_windows: 440 | dependency: transitive 441 | description: 442 | name: shared_preferences_windows 443 | url: "https://pub.dartlang.org" 444 | source: hosted 445 | version: "2.1.1" 446 | sky_engine: 447 | dependency: transitive 448 | description: flutter 449 | source: sdk 450 | version: "0.0.99" 451 | source_span: 452 | dependency: transitive 453 | description: 454 | name: source_span 455 | url: "https://pub.dartlang.org" 456 | source: hosted 457 | version: "1.8.2" 458 | stack_trace: 459 | dependency: transitive 460 | description: 461 | name: stack_trace 462 | url: "https://pub.dartlang.org" 463 | source: hosted 464 | version: "1.10.0" 465 | stream_channel: 466 | dependency: transitive 467 | description: 468 | name: stream_channel 469 | url: "https://pub.dartlang.org" 470 | source: hosted 471 | version: "2.1.0" 472 | string_scanner: 473 | dependency: transitive 474 | description: 475 | name: string_scanner 476 | url: "https://pub.dartlang.org" 477 | source: hosted 478 | version: "1.1.0" 479 | term_glyph: 480 | dependency: transitive 481 | description: 482 | name: term_glyph 483 | url: "https://pub.dartlang.org" 484 | source: hosted 485 | version: "1.2.0" 486 | test_api: 487 | dependency: transitive 488 | description: 489 | name: test_api 490 | url: "https://pub.dartlang.org" 491 | source: hosted 492 | version: "0.4.9" 493 | typed_data: 494 | dependency: transitive 495 | description: 496 | name: typed_data 497 | url: "https://pub.dartlang.org" 498 | source: hosted 499 | version: "1.3.1" 500 | vector_math: 501 | dependency: transitive 502 | description: 503 | name: vector_math 504 | url: "https://pub.dartlang.org" 505 | source: hosted 506 | version: "2.1.2" 507 | web_socket_channel: 508 | dependency: transitive 509 | description: 510 | name: web_socket_channel 511 | url: "https://pub.dartlang.org" 512 | source: hosted 513 | version: "2.2.0" 514 | win32: 515 | dependency: transitive 516 | description: 517 | name: win32 518 | url: "https://pub.dartlang.org" 519 | source: hosted 520 | version: "2.6.1" 521 | xdg_directories: 522 | dependency: transitive 523 | description: 524 | name: xdg_directories 525 | url: "https://pub.dartlang.org" 526 | source: hosted 527 | version: "0.2.0+1" 528 | sdks: 529 | dart: ">=2.17.0 <3.0.0" 530 | flutter: ">=3.0.0" 531 | -------------------------------------------------------------------------------- /pubspec.yaml: -------------------------------------------------------------------------------- 1 | name: netflix_clone 2 | description: A new Flutter project. 3 | 4 | # The following line prevents the package from being accidentally published to 5 | # pub.dev using `flutter 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.15.1 <3.0.0" 22 | 23 | # Dependencies specify other packages that your package needs in order to work. 24 | # To automatically upgrade your package dependencies to the latest versions 25 | # consider running `flutter pub upgrade --major-versions`. Alternatively, 26 | # dependencies can be manually updated by changing the version numbers below to 27 | # the latest version available on pub.dev. To see which dependencies have newer 28 | # versions available, run `flutter pub outdated`. 29 | dependencies: 30 | flutter: 31 | sdk: flutter 32 | 33 | 34 | # The following adds the Cupertino Icons font to your application. 35 | # Use with the CupertinoIcons class for iOS style icons. 36 | cupertino_icons: ^1.0.2 37 | provider: ^6.0.1 38 | fluro: ^2.0.3 39 | shared_preferences: ^2.0.11 40 | adaptive_dialog: ^1.3.0 41 | appwrite: ^8.1.0 42 | 43 | dev_dependencies: 44 | flutter_test: 45 | sdk: flutter 46 | 47 | # The "flutter_lints" package below contains a set of recommended lints to 48 | # encourage good coding practices. The lint set provided by the package is 49 | # activated in the `analysis_options.yaml` file located at the root of your 50 | # package. See that file for information about deactivating specific lint 51 | # rules and activating additional ones. 52 | flutter_lints: ^2.0.0 53 | 54 | # For information on the generic Dart part of this file, see the 55 | # following page: https://dart.dev/tools/pub/pubspec 56 | 57 | # The following section is specific to Flutter. 58 | flutter: 59 | 60 | # The following line ensures that the Material Icons font is 61 | # included with your application, so that you can use the icons in 62 | # the material Icons class. 63 | uses-material-design: true 64 | 65 | # To add assets to your application, add an assets section, like this: 66 | assets: 67 | - assets/ 68 | 69 | # An image asset can refer to one or more resolution-specific "variants", see 70 | # https://flutter.dev/assets-and-images/#resolution-aware. 71 | 72 | # For details regarding adding assets from package dependencies, see 73 | # https://flutter.dev/assets-and-images/#from-packages 74 | 75 | # To add custom fonts to your application, add a fonts section here, 76 | # in this "flutter" section. Each entry in this list should have a 77 | # "family" key with the font family name, and a "fonts" key with a 78 | # list giving the asset and other descriptors for the font. For 79 | # example: 80 | # fonts: 81 | # - family: Schyler 82 | # fonts: 83 | # - asset: fonts/Schyler-Regular.ttf 84 | # - asset: fonts/Schyler-Italic.ttf 85 | # style: italic 86 | # - family: Trajan Pro 87 | # fonts: 88 | # - asset: fonts/TrajanPro.ttf 89 | # - asset: fonts/TrajanPro_Bold.ttf 90 | # weight: 700 91 | # 92 | # For details regarding fonts from package dependencies, 93 | # see https://flutter.dev/custom-fonts/#from-packages 94 | -------------------------------------------------------------------------------- /readme_banner.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/appwrite/demo-almost-netflix-for-flutter/6d703dc36c725bc34ac4e1addb0a5649034da99e/readme_banner.png -------------------------------------------------------------------------------- /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:netflix_clone/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(const Main()); 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 | --------------------------------------------------------------------------------