diff --git a/examples/starwars/.gitignore b/examples/starwars/.gitignore deleted file mode 100644 index 50ce5ca85..000000000 --- a/examples/starwars/.gitignore +++ /dev/null @@ -1,102 +0,0 @@ -# Miscellaneous -*.class -*.lock -*.log -*.pyc -*.swp -.DS_Store -.atom/ -.buildlog/ -.history -.svn/ - -# IntelliJ related -*.iml -*.ipr -*.iws -.idea/ - -# Visual Studio Code related -.vscode/ -.project - -# Flutter repo-specific -/bin/cache/ -/bin/mingit/ -/dev/benchmarks/mega_gallery/ -/dev/bots/.recipe_deps -/dev/bots/android_tools/ -/dev/docs/doc/ -/dev/docs/flutter.docs.zip -/dev/docs/lib/ -/dev/docs/pubspec.yaml -/dev/integration_tests/**/xcuserdata -/dev/integration_tests/**/Pods -/packages/flutter/coverage/ -version - -# packages file containing multi-root paths -.packages.generated - -# Flutter/Dart/Pub related -**/doc/api/ -.dart_tool/ -.flutter-plugins -.packages -.pub-cache/ -.pub/ -build/ -flutter_*.png -linked_*.ds -unlinked.ds -unlinked_spec.ds - -# Android related -**/android/**/gradle-wrapper.jar -**/android/.gradle -**/android/captures/ -**/android/gradlew -**/android/gradlew.bat -**/android/local.properties -**/android/**/GeneratedPluginRegistrant.java -**/android/key.properties -*.jks - -# iOS/XCode related -**/ios/**/*.mode1v3 -**/ios/**/*.mode2v3 -**/ios/**/*.moved-aside -**/ios/**/*.pbxuser -**/ios/**/*.perspectivev3 -**/ios/**/*sync/ -**/ios/**/.sconsign.dblite -**/ios/**/.tags* -**/ios/**/.vagrant/ -**/ios/**/DerivedData/ -**/ios/**/Icon? -**/ios/**/Pods/ -**/ios/**/.symlinks/ -**/ios/**/profile -**/ios/**/xcuserdata -**/ios/.generated/ -**/ios/Flutter/App.framework -**/ios/Flutter/Flutter.framework -**/ios/Flutter/Flutter.podspec -**/ios/Flutter/Generated.xcconfig -**/ios/Flutter/app.flx -**/ios/Flutter/app.zip -**/ios/Flutter/flutter_assets/ -**/ios/Flutter/flutter_export_environment.sh -**/ios/ServiceDefinitions.json -**/ios/Runner/GeneratedPluginRegistrant.* - -# Coverage -coverage/ - -# Exceptions to above rules. -!**/ios/**/default.mode1v3 -!**/ios/**/default.mode2v3 -!**/ios/**/default.pbxuser -!**/ios/**/default.perspectivev3 -!/packages/flutter_tools/test/data/dart_dependencies_test/**/.packages -!/dev/ci/**/Gemfile.lock \ No newline at end of file diff --git a/examples/starwars/Makefile b/examples/starwars/Makefile deleted file mode 100644 index 67c06b7f8..000000000 --- a/examples/starwars/Makefile +++ /dev/null @@ -1,21 +0,0 @@ -CC=dart -CC_UI=flutter - - -default: fmt dep - @echo "Please run \"make server !&\" to run the server" - - -dep: - cd server; $(CC) pub get - $(CC_UI) pub get - -server: - $(CC) pub run graphql_starwars_test_server - -fmt: - $(CC_UI) format . - $(CC_UI) analyze . - -clean: - $(CC_UI) clean diff --git a/examples/starwars/README.md b/examples/starwars/README.md deleted file mode 100644 index 7a2970445..000000000 --- a/examples/starwars/README.md +++ /dev/null @@ -1,19 +0,0 @@ -# Star Wars Demo - -### Server side - -To start the server you need to run the following command: -```bash -make && make server !& -``` - -### Client side - -To consume the API of the server you can run the server with the following command - -- `flutter run` to run it on the ios device -- `flutter run -d chrome` for web support: - -### Screenshots - -![flutter for web image](./for_web.png) diff --git a/examples/starwars/android/app/build.gradle b/examples/starwars/android/app/build.gradle deleted file mode 100644 index ad9de98a2..000000000 --- a/examples/starwars/android/app/build.gradle +++ /dev/null @@ -1,61 +0,0 @@ -def localProperties = new Properties() -def localPropertiesFile = rootProject.file('local.properties') -if (localPropertiesFile.exists()) { - localPropertiesFile.withReader('UTF-8') { reader -> - localProperties.load(reader) - } -} - -def flutterRoot = localProperties.getProperty('flutter.sdk') -if (flutterRoot == null) { - throw new GradleException("Flutter SDK not found. Define location with flutter.sdk in the local.properties file.") -} - -def flutterVersionCode = localProperties.getProperty('flutter.versionCode') -if (flutterVersionCode == null) { - flutterVersionCode = '1' -} - -def flutterVersionName = localProperties.getProperty('flutter.versionName') -if (flutterVersionName == null) { - flutterVersionName = '1.0' -} - -apply plugin: 'com.android.application' -apply from: "$flutterRoot/packages/flutter_tools/gradle/flutter.gradle" - -android { - compileSdkVersion 28 - - lintOptions { - disable 'InvalidPackage' - } - - defaultConfig { - // TODO: Specify your own unique Application ID (https://developer.android.com/studio/build/application-id.html). - applicationId "com.example.starwars" - minSdkVersion 19 - targetSdkVersion 30 - versionCode flutterVersionCode.toInteger() - versionName flutterVersionName - testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner" - } - - buildTypes { - release { - // TODO: Add your own signing config for the release build. - // Signing with the debug keys for now, so `flutter run --release` works. - signingConfig signingConfigs.debug - } - } -} - -flutter { - source '../..' -} - -dependencies { - testImplementation 'junit:junit:4.12' - androidTestImplementation 'com.android.support.test:runner:1.0.2' - androidTestImplementation 'com.android.support.test.espresso:espresso-core:3.0.2' -} diff --git a/examples/starwars/android/app/src/debug/AndroidManifest.xml b/examples/starwars/android/app/src/debug/AndroidManifest.xml deleted file mode 100644 index 94f183474..000000000 --- a/examples/starwars/android/app/src/debug/AndroidManifest.xml +++ /dev/null @@ -1,7 +0,0 @@ - - - - diff --git a/examples/starwars/android/app/src/main/AndroidManifest.xml b/examples/starwars/android/app/src/main/AndroidManifest.xml deleted file mode 100644 index 2685c8883..000000000 --- a/examples/starwars/android/app/src/main/AndroidManifest.xml +++ /dev/null @@ -1,33 +0,0 @@ - - - - - - - - - - - - - - diff --git a/examples/starwars/android/app/src/main/java/com/example/starwars/MainActivity.java b/examples/starwars/android/app/src/main/java/com/example/starwars/MainActivity.java deleted file mode 100644 index 9ff1f9f52..000000000 --- a/examples/starwars/android/app/src/main/java/com/example/starwars/MainActivity.java +++ /dev/null @@ -1,5 +0,0 @@ -package com.example.starwars; - -import io.flutter.embedding.android.FlutterActivity; - -public class MainActivity extends FlutterActivity { } diff --git a/examples/starwars/android/app/src/main/res/drawable/launch_background.xml b/examples/starwars/android/app/src/main/res/drawable/launch_background.xml deleted file mode 100644 index 304732f88..000000000 --- a/examples/starwars/android/app/src/main/res/drawable/launch_background.xml +++ /dev/null @@ -1,12 +0,0 @@ - - - - - - - - diff --git a/examples/starwars/android/app/src/main/res/mipmap-hdpi/ic_launcher.png b/examples/starwars/android/app/src/main/res/mipmap-hdpi/ic_launcher.png deleted file mode 100644 index db77bb4b7..000000000 Binary files a/examples/starwars/android/app/src/main/res/mipmap-hdpi/ic_launcher.png and /dev/null differ diff --git a/examples/starwars/android/app/src/main/res/mipmap-mdpi/ic_launcher.png b/examples/starwars/android/app/src/main/res/mipmap-mdpi/ic_launcher.png deleted file mode 100644 index 17987b79b..000000000 Binary files a/examples/starwars/android/app/src/main/res/mipmap-mdpi/ic_launcher.png and /dev/null differ diff --git a/examples/starwars/android/app/src/main/res/mipmap-xhdpi/ic_launcher.png b/examples/starwars/android/app/src/main/res/mipmap-xhdpi/ic_launcher.png deleted file mode 100644 index 09d439148..000000000 Binary files a/examples/starwars/android/app/src/main/res/mipmap-xhdpi/ic_launcher.png and /dev/null differ diff --git a/examples/starwars/android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png b/examples/starwars/android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png deleted file mode 100644 index d5f1c8d34..000000000 Binary files a/examples/starwars/android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png and /dev/null differ diff --git a/examples/starwars/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png b/examples/starwars/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png deleted file mode 100644 index 4d6372eeb..000000000 Binary files a/examples/starwars/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png and /dev/null differ diff --git a/examples/starwars/android/app/src/main/res/values/styles.xml b/examples/starwars/android/app/src/main/res/values/styles.xml deleted file mode 100644 index 7f287b04b..000000000 --- a/examples/starwars/android/app/src/main/res/values/styles.xml +++ /dev/null @@ -1,9 +0,0 @@ - - - - - diff --git a/examples/starwars/android/app/src/profile/AndroidManifest.xml b/examples/starwars/android/app/src/profile/AndroidManifest.xml deleted file mode 100644 index 94f183474..000000000 --- a/examples/starwars/android/app/src/profile/AndroidManifest.xml +++ /dev/null @@ -1,7 +0,0 @@ - - - - diff --git a/examples/starwars/android/build.gradle b/examples/starwars/android/build.gradle deleted file mode 100644 index bb8a30389..000000000 --- a/examples/starwars/android/build.gradle +++ /dev/null @@ -1,29 +0,0 @@ -buildscript { - repositories { - google() - jcenter() - } - - dependencies { - classpath 'com.android.tools.build:gradle:3.2.1' - } -} - -allprojects { - repositories { - google() - jcenter() - } -} - -rootProject.buildDir = '../build' -subprojects { - project.buildDir = "${rootProject.buildDir}/${project.name}" -} -subprojects { - project.evaluationDependsOn(':app') -} - -task clean(type: Delete) { - delete rootProject.buildDir -} diff --git a/examples/starwars/android/gradle.properties b/examples/starwars/android/gradle.properties deleted file mode 100644 index 8bd86f680..000000000 --- a/examples/starwars/android/gradle.properties +++ /dev/null @@ -1 +0,0 @@ -org.gradle.jvmargs=-Xmx1536M diff --git a/examples/starwars/android/gradle/wrapper/gradle-wrapper.properties b/examples/starwars/android/gradle/wrapper/gradle-wrapper.properties deleted file mode 100644 index 2819f022f..000000000 --- a/examples/starwars/android/gradle/wrapper/gradle-wrapper.properties +++ /dev/null @@ -1,6 +0,0 @@ -#Fri Jun 23 08:50:38 CEST 2017 -distributionBase=GRADLE_USER_HOME -distributionPath=wrapper/dists -zipStoreBase=GRADLE_USER_HOME -zipStorePath=wrapper/dists -distributionUrl=https\://services.gradle.org/distributions/gradle-4.10.2-all.zip diff --git a/examples/starwars/android/settings.gradle b/examples/starwars/android/settings.gradle deleted file mode 100644 index 5a2f14fb1..000000000 --- a/examples/starwars/android/settings.gradle +++ /dev/null @@ -1,15 +0,0 @@ -include ':app' - -def flutterProjectRoot = rootProject.projectDir.parentFile.toPath() - -def plugins = new Properties() -def pluginsFile = new File(flutterProjectRoot.toFile(), '.flutter-plugins') -if (pluginsFile.exists()) { - pluginsFile.withReader('UTF-8') { reader -> plugins.load(reader) } -} - -plugins.each { name, path -> - def pluginDirectory = flutterProjectRoot.resolve(path).resolve('android').toFile() - include ":$name" - project(":$name").projectDir = pluginDirectory -} diff --git a/examples/starwars/for_web.png b/examples/starwars/for_web.png deleted file mode 100644 index 3b3ae3bad..000000000 Binary files a/examples/starwars/for_web.png and /dev/null differ diff --git a/examples/starwars/ios/Flutter/AppFrameworkInfo.plist b/examples/starwars/ios/Flutter/AppFrameworkInfo.plist deleted file mode 100644 index 9367d483e..000000000 --- a/examples/starwars/ios/Flutter/AppFrameworkInfo.plist +++ /dev/null @@ -1,26 +0,0 @@ - - - - - CFBundleDevelopmentRegion - en - CFBundleExecutable - App - CFBundleIdentifier - io.flutter.flutter.app - CFBundleInfoDictionaryVersion - 6.0 - CFBundleName - App - CFBundlePackageType - FMWK - CFBundleShortVersionString - 1.0 - CFBundleSignature - ???? - CFBundleVersion - 1.0 - MinimumOSVersion - 8.0 - - diff --git a/examples/starwars/ios/Flutter/Debug.xcconfig b/examples/starwars/ios/Flutter/Debug.xcconfig deleted file mode 100644 index e8efba114..000000000 --- a/examples/starwars/ios/Flutter/Debug.xcconfig +++ /dev/null @@ -1,2 +0,0 @@ -#include "Pods/Target Support Files/Pods-Runner/Pods-Runner.debug.xcconfig" -#include "Generated.xcconfig" diff --git a/examples/starwars/ios/Flutter/Release.xcconfig b/examples/starwars/ios/Flutter/Release.xcconfig deleted file mode 100644 index 399e9340e..000000000 --- a/examples/starwars/ios/Flutter/Release.xcconfig +++ /dev/null @@ -1,2 +0,0 @@ -#include "Pods/Target Support Files/Pods-Runner/Pods-Runner.release.xcconfig" -#include "Generated.xcconfig" diff --git a/examples/starwars/ios/Podfile b/examples/starwars/ios/Podfile deleted file mode 100644 index f7d6a5e68..000000000 --- a/examples/starwars/ios/Podfile +++ /dev/null @@ -1,38 +0,0 @@ -# Uncomment this line to define a global platform for your project -# platform :ios, '9.0' - -# CocoaPods analytics sends network stats synchronously affecting flutter build latency. -ENV['COCOAPODS_DISABLE_STATS'] = 'true' - -project 'Runner', { - 'Debug' => :debug, - 'Profile' => :release, - 'Release' => :release, -} - -def flutter_root - generated_xcode_build_settings_path = File.expand_path(File.join('..', 'Flutter', 'Generated.xcconfig'), __FILE__) - unless File.exist?(generated_xcode_build_settings_path) - raise "#{generated_xcode_build_settings_path} must exist. If you're running pod install manually, make sure flutter pub get is executed first" - end - - File.foreach(generated_xcode_build_settings_path) do |line| - matches = line.match(/FLUTTER_ROOT\=(.*)/) - return matches[1].strip if matches - end - raise "FLUTTER_ROOT not found in #{generated_xcode_build_settings_path}. Try deleting Generated.xcconfig, then run flutter pub get" -end - -require File.expand_path(File.join('packages', 'flutter_tools', 'bin', 'podhelper'), flutter_root) - -flutter_ios_podfile_setup - -target 'Runner' do - flutter_install_all_ios_pods File.dirname(File.realpath(__FILE__)) -end - -post_install do |installer| - installer.pods_project.targets.each do |target| - flutter_additional_ios_build_settings(target) - end -end diff --git a/examples/starwars/ios/Runner.xcodeproj/project.pbxproj b/examples/starwars/ios/Runner.xcodeproj/project.pbxproj deleted file mode 100644 index 52f552cf0..000000000 --- a/examples/starwars/ios/Runner.xcodeproj/project.pbxproj +++ /dev/null @@ -1,540 +0,0 @@ -// !$*UTF8*$! -{ - archiveVersion = 1; - classes = { - }; - objectVersion = 46; - objects = { - -/* Begin PBXBuildFile section */ - 1498D2341E8E89220040F4C2 /* GeneratedPluginRegistrant.m in Sources */ = {isa = PBXBuildFile; fileRef = 1498D2331E8E89220040F4C2 /* GeneratedPluginRegistrant.m */; }; - 3B3967161E833CAA004F5970 /* AppFrameworkInfo.plist in Resources */ = {isa = PBXBuildFile; fileRef = 3B3967151E833CAA004F5970 /* AppFrameworkInfo.plist */; }; - 9740EEB41CF90195004384FC /* Debug.xcconfig in Resources */ = {isa = PBXBuildFile; fileRef = 9740EEB21CF90195004384FC /* Debug.xcconfig */; }; - 978B8F6F1D3862AE00F588F7 /* AppDelegate.m in Sources */ = {isa = PBXBuildFile; fileRef = 7AFFD8EE1D35381100E5BB4D /* AppDelegate.m */; }; - 97C146F31CF9000F007C117D /* main.m in Sources */ = {isa = PBXBuildFile; fileRef = 97C146F21CF9000F007C117D /* main.m */; }; - 97C146FC1CF9000F007C117D /* Main.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 97C146FA1CF9000F007C117D /* Main.storyboard */; }; - 97C146FE1CF9000F007C117D /* Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 97C146FD1CF9000F007C117D /* Assets.xcassets */; }; - 97C147011CF9000F007C117D /* LaunchScreen.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 97C146FF1CF9000F007C117D /* LaunchScreen.storyboard */; }; - CBDD155917C1692EC4F78B55 /* libPods-Runner.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 8BF82C04C3273D555FFF0D32 /* libPods-Runner.a */; }; -/* End PBXBuildFile section */ - -/* Begin PBXCopyFilesBuildPhase section */ - 9705A1C41CF9048500538489 /* Embed Frameworks */ = { - isa = PBXCopyFilesBuildPhase; - buildActionMask = 2147483647; - dstPath = ""; - dstSubfolderSpec = 10; - files = ( - ); - name = "Embed Frameworks"; - runOnlyForDeploymentPostprocessing = 0; - }; -/* End PBXCopyFilesBuildPhase section */ - -/* Begin PBXFileReference section */ - 1498D2321E8E86230040F4C2 /* GeneratedPluginRegistrant.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = GeneratedPluginRegistrant.h; sourceTree = ""; }; - 1498D2331E8E89220040F4C2 /* GeneratedPluginRegistrant.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = GeneratedPluginRegistrant.m; sourceTree = ""; }; - 3B3967151E833CAA004F5970 /* AppFrameworkInfo.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; name = AppFrameworkInfo.plist; path = Flutter/AppFrameworkInfo.plist; sourceTree = ""; }; - 78BC9F830CF1BC2D0D3115CC /* 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 = ""; }; - 7AFA3C8E1D35360C0083082E /* Release.xcconfig */ = {isa = PBXFileReference; lastKnownFileType = text.xcconfig; name = Release.xcconfig; path = Flutter/Release.xcconfig; sourceTree = ""; }; - 7AFFD8ED1D35381100E5BB4D /* AppDelegate.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = AppDelegate.h; sourceTree = ""; }; - 7AFFD8EE1D35381100E5BB4D /* AppDelegate.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = AppDelegate.m; sourceTree = ""; }; - 8BF82C04C3273D555FFF0D32 /* libPods-Runner.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = "libPods-Runner.a"; sourceTree = BUILT_PRODUCTS_DIR; }; - 9740EEB21CF90195004384FC /* Debug.xcconfig */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.xcconfig; name = Debug.xcconfig; path = Flutter/Debug.xcconfig; sourceTree = ""; }; - 9740EEB31CF90195004384FC /* Generated.xcconfig */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.xcconfig; name = Generated.xcconfig; path = Flutter/Generated.xcconfig; sourceTree = ""; }; - 97C146EE1CF9000F007C117D /* Runner.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = Runner.app; sourceTree = BUILT_PRODUCTS_DIR; }; - 97C146F21CF9000F007C117D /* main.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = main.m; sourceTree = ""; }; - 97C146FB1CF9000F007C117D /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/Main.storyboard; sourceTree = ""; }; - 97C146FD1CF9000F007C117D /* Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Assets.xcassets; sourceTree = ""; }; - 97C147001CF9000F007C117D /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/LaunchScreen.storyboard; sourceTree = ""; }; - 97C147021CF9000F007C117D /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; - C93EF51D6E349EFD8C75D0FD /* 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 = ""; }; - D872E1B18A40136E516F1ABC /* 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 = ""; }; -/* End PBXFileReference section */ - -/* Begin PBXFrameworksBuildPhase section */ - 97C146EB1CF9000F007C117D /* Frameworks */ = { - isa = PBXFrameworksBuildPhase; - buildActionMask = 2147483647; - files = ( - CBDD155917C1692EC4F78B55 /* libPods-Runner.a in Frameworks */, - ); - runOnlyForDeploymentPostprocessing = 0; - }; -/* End PBXFrameworksBuildPhase section */ - -/* Begin PBXGroup section */ - 277F0233D0FB314B2D8685A3 /* Pods */ = { - isa = PBXGroup; - children = ( - D872E1B18A40136E516F1ABC /* Pods-Runner.debug.xcconfig */, - 78BC9F830CF1BC2D0D3115CC /* Pods-Runner.release.xcconfig */, - C93EF51D6E349EFD8C75D0FD /* Pods-Runner.profile.xcconfig */, - ); - name = Pods; - path = Pods; - sourceTree = ""; - }; - 79E42AFF773B845DF87E0080 /* Frameworks */ = { - isa = PBXGroup; - children = ( - 8BF82C04C3273D555FFF0D32 /* libPods-Runner.a */, - ); - name = Frameworks; - sourceTree = ""; - }; - 9740EEB11CF90186004384FC /* Flutter */ = { - isa = PBXGroup; - children = ( - 3B3967151E833CAA004F5970 /* AppFrameworkInfo.plist */, - 9740EEB21CF90195004384FC /* Debug.xcconfig */, - 7AFA3C8E1D35360C0083082E /* Release.xcconfig */, - 9740EEB31CF90195004384FC /* Generated.xcconfig */, - ); - name = Flutter; - sourceTree = ""; - }; - 97C146E51CF9000F007C117D = { - isa = PBXGroup; - children = ( - 9740EEB11CF90186004384FC /* Flutter */, - 97C146F01CF9000F007C117D /* Runner */, - 97C146EF1CF9000F007C117D /* Products */, - 277F0233D0FB314B2D8685A3 /* Pods */, - 79E42AFF773B845DF87E0080 /* Frameworks */, - ); - sourceTree = ""; - }; - 97C146EF1CF9000F007C117D /* Products */ = { - isa = PBXGroup; - children = ( - 97C146EE1CF9000F007C117D /* Runner.app */, - ); - name = Products; - sourceTree = ""; - }; - 97C146F01CF9000F007C117D /* Runner */ = { - isa = PBXGroup; - children = ( - 7AFFD8ED1D35381100E5BB4D /* AppDelegate.h */, - 7AFFD8EE1D35381100E5BB4D /* AppDelegate.m */, - 97C146FA1CF9000F007C117D /* Main.storyboard */, - 97C146FD1CF9000F007C117D /* Assets.xcassets */, - 97C146FF1CF9000F007C117D /* LaunchScreen.storyboard */, - 97C147021CF9000F007C117D /* Info.plist */, - 97C146F11CF9000F007C117D /* Supporting Files */, - 1498D2321E8E86230040F4C2 /* GeneratedPluginRegistrant.h */, - 1498D2331E8E89220040F4C2 /* GeneratedPluginRegistrant.m */, - ); - path = Runner; - sourceTree = ""; - }; - 97C146F11CF9000F007C117D /* Supporting Files */ = { - isa = PBXGroup; - children = ( - 97C146F21CF9000F007C117D /* main.m */, - ); - name = "Supporting Files"; - sourceTree = ""; - }; -/* End PBXGroup section */ - -/* Begin PBXNativeTarget section */ - 97C146ED1CF9000F007C117D /* Runner */ = { - isa = PBXNativeTarget; - buildConfigurationList = 97C147051CF9000F007C117D /* Build configuration list for PBXNativeTarget "Runner" */; - buildPhases = ( - E713952B12A73E808568155D /* [CP] Check Pods Manifest.lock */, - 9740EEB61CF901F6004384FC /* Run Script */, - 97C146EA1CF9000F007C117D /* Sources */, - 97C146EB1CF9000F007C117D /* Frameworks */, - 97C146EC1CF9000F007C117D /* Resources */, - 9705A1C41CF9048500538489 /* Embed Frameworks */, - 3B06AD1E1E4923F5004D2608 /* Thin Binary */, - ); - buildRules = ( - ); - dependencies = ( - ); - name = Runner; - productName = Runner; - productReference = 97C146EE1CF9000F007C117D /* Runner.app */; - productType = "com.apple.product-type.application"; - }; -/* End PBXNativeTarget section */ - -/* Begin PBXProject section */ - 97C146E61CF9000F007C117D /* Project object */ = { - isa = PBXProject; - attributes = { - LastUpgradeCheck = 0910; - ORGANIZATIONNAME = "The Chromium Authors"; - TargetAttributes = { - 97C146ED1CF9000F007C117D = { - CreatedOnToolsVersion = 7.3.1; - }; - }; - }; - buildConfigurationList = 97C146E91CF9000F007C117D /* Build configuration list for PBXProject "Runner" */; - compatibilityVersion = "Xcode 3.2"; - developmentRegion = English; - hasScannedForEncodings = 0; - knownRegions = ( - en, - Base, - ); - mainGroup = 97C146E51CF9000F007C117D; - productRefGroup = 97C146EF1CF9000F007C117D /* Products */; - projectDirPath = ""; - projectRoot = ""; - targets = ( - 97C146ED1CF9000F007C117D /* Runner */, - ); - }; -/* End PBXProject section */ - -/* Begin PBXResourcesBuildPhase section */ - 97C146EC1CF9000F007C117D /* Resources */ = { - isa = PBXResourcesBuildPhase; - buildActionMask = 2147483647; - files = ( - 97C147011CF9000F007C117D /* LaunchScreen.storyboard in Resources */, - 3B3967161E833CAA004F5970 /* AppFrameworkInfo.plist in Resources */, - 9740EEB41CF90195004384FC /* Debug.xcconfig in Resources */, - 97C146FE1CF9000F007C117D /* Assets.xcassets in Resources */, - 97C146FC1CF9000F007C117D /* Main.storyboard in Resources */, - ); - runOnlyForDeploymentPostprocessing = 0; - }; -/* End PBXResourcesBuildPhase section */ - -/* Begin PBXShellScriptBuildPhase section */ - 3B06AD1E1E4923F5004D2608 /* Thin Binary */ = { - isa = PBXShellScriptBuildPhase; - buildActionMask = 2147483647; - files = ( - ); - inputPaths = ( - ); - name = "Thin Binary"; - outputPaths = ( - ); - runOnlyForDeploymentPostprocessing = 0; - shellPath = /bin/sh; - shellScript = "/bin/sh \"$FLUTTER_ROOT/packages/flutter_tools/bin/xcode_backend.sh\" embed_and_thin"; - }; - 9740EEB61CF901F6004384FC /* Run Script */ = { - isa = PBXShellScriptBuildPhase; - buildActionMask = 2147483647; - files = ( - ); - inputPaths = ( - ); - name = "Run Script"; - outputPaths = ( - ); - runOnlyForDeploymentPostprocessing = 0; - shellPath = /bin/sh; - shellScript = "/bin/sh \"$FLUTTER_ROOT/packages/flutter_tools/bin/xcode_backend.sh\" build"; - }; - E713952B12A73E808568155D /* [CP] Check Pods Manifest.lock */ = { - isa = PBXShellScriptBuildPhase; - buildActionMask = 2147483647; - files = ( - ); - inputFileListPaths = ( - ); - inputPaths = ( - "${PODS_PODFILE_DIR_PATH}/Podfile.lock", - "${PODS_ROOT}/Manifest.lock", - ); - name = "[CP] Check Pods Manifest.lock"; - outputFileListPaths = ( - ); - outputPaths = ( - "$(DERIVED_FILE_DIR)/Pods-Runner-checkManifestLockResult.txt", - ); - runOnlyForDeploymentPostprocessing = 0; - shellPath = /bin/sh; - 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"; - showEnvVarsInLog = 0; - }; -/* End PBXShellScriptBuildPhase section */ - -/* Begin PBXSourcesBuildPhase section */ - 97C146EA1CF9000F007C117D /* Sources */ = { - isa = PBXSourcesBuildPhase; - buildActionMask = 2147483647; - files = ( - 978B8F6F1D3862AE00F588F7 /* AppDelegate.m in Sources */, - 97C146F31CF9000F007C117D /* main.m in Sources */, - 1498D2341E8E89220040F4C2 /* GeneratedPluginRegistrant.m in Sources */, - ); - runOnlyForDeploymentPostprocessing = 0; - }; -/* End PBXSourcesBuildPhase section */ - -/* Begin PBXVariantGroup section */ - 97C146FA1CF9000F007C117D /* Main.storyboard */ = { - isa = PBXVariantGroup; - children = ( - 97C146FB1CF9000F007C117D /* Base */, - ); - name = Main.storyboard; - sourceTree = ""; - }; - 97C146FF1CF9000F007C117D /* LaunchScreen.storyboard */ = { - isa = PBXVariantGroup; - children = ( - 97C147001CF9000F007C117D /* Base */, - ); - name = LaunchScreen.storyboard; - sourceTree = ""; - }; -/* End PBXVariantGroup section */ - -/* Begin XCBuildConfiguration section */ - 249021D3217E4FDB00AE95B9 /* Profile */ = { - isa = XCBuildConfiguration; - buildSettings = { - ALWAYS_SEARCH_USER_PATHS = NO; - CLANG_ANALYZER_NONNULL = YES; - CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; - CLANG_CXX_LIBRARY = "libc++"; - CLANG_ENABLE_MODULES = YES; - CLANG_ENABLE_OBJC_ARC = YES; - CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; - CLANG_WARN_BOOL_CONVERSION = YES; - CLANG_WARN_COMMA = YES; - CLANG_WARN_CONSTANT_CONVERSION = YES; - CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; - CLANG_WARN_EMPTY_BODY = YES; - CLANG_WARN_ENUM_CONVERSION = YES; - CLANG_WARN_INFINITE_RECURSION = YES; - CLANG_WARN_INT_CONVERSION = YES; - CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; - CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; - CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; - CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; - CLANG_WARN_STRICT_PROTOTYPES = YES; - CLANG_WARN_SUSPICIOUS_MOVE = YES; - CLANG_WARN_UNREACHABLE_CODE = YES; - CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; - "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; - COPY_PHASE_STRIP = NO; - DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; - ENABLE_NS_ASSERTIONS = NO; - ENABLE_STRICT_OBJC_MSGSEND = YES; - GCC_C_LANGUAGE_STANDARD = gnu99; - GCC_NO_COMMON_BLOCKS = YES; - GCC_WARN_64_TO_32_BIT_CONVERSION = YES; - GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; - GCC_WARN_UNDECLARED_SELECTOR = YES; - GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; - GCC_WARN_UNUSED_FUNCTION = YES; - GCC_WARN_UNUSED_VARIABLE = YES; - IPHONEOS_DEPLOYMENT_TARGET = 8.0; - MTL_ENABLE_DEBUG_INFO = NO; - SDKROOT = iphoneos; - TARGETED_DEVICE_FAMILY = "1,2"; - VALIDATE_PRODUCT = YES; - }; - name = Profile; - }; - 249021D4217E4FDB00AE95B9 /* Profile */ = { - isa = XCBuildConfiguration; - baseConfigurationReference = 7AFA3C8E1D35360C0083082E /* Release.xcconfig */; - buildSettings = { - ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; - CURRENT_PROJECT_VERSION = "$(FLUTTER_BUILD_NUMBER)"; - DEVELOPMENT_TEAM = S8QB4VV633; - ENABLE_BITCODE = NO; - FRAMEWORK_SEARCH_PATHS = ( - "$(inherited)", - "$(PROJECT_DIR)/Flutter", - ); - INFOPLIST_FILE = Runner/Info.plist; - LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; - LIBRARY_SEARCH_PATHS = ( - "$(inherited)", - "$(PROJECT_DIR)/Flutter", - ); - PRODUCT_BUNDLE_IDENTIFIER = com.example.starwars; - PRODUCT_NAME = "$(TARGET_NAME)"; - VERSIONING_SYSTEM = "apple-generic"; - }; - name = Profile; - }; - 97C147031CF9000F007C117D /* Debug */ = { - isa = XCBuildConfiguration; - buildSettings = { - ALWAYS_SEARCH_USER_PATHS = NO; - CLANG_ANALYZER_NONNULL = YES; - CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; - CLANG_CXX_LIBRARY = "libc++"; - CLANG_ENABLE_MODULES = YES; - CLANG_ENABLE_OBJC_ARC = YES; - CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; - CLANG_WARN_BOOL_CONVERSION = YES; - CLANG_WARN_COMMA = YES; - CLANG_WARN_CONSTANT_CONVERSION = YES; - CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; - CLANG_WARN_EMPTY_BODY = YES; - CLANG_WARN_ENUM_CONVERSION = YES; - CLANG_WARN_INFINITE_RECURSION = YES; - CLANG_WARN_INT_CONVERSION = YES; - CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; - CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; - CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; - CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; - CLANG_WARN_STRICT_PROTOTYPES = YES; - CLANG_WARN_SUSPICIOUS_MOVE = YES; - CLANG_WARN_UNREACHABLE_CODE = YES; - CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; - "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; - COPY_PHASE_STRIP = NO; - DEBUG_INFORMATION_FORMAT = dwarf; - ENABLE_STRICT_OBJC_MSGSEND = YES; - ENABLE_TESTABILITY = YES; - GCC_C_LANGUAGE_STANDARD = gnu99; - GCC_DYNAMIC_NO_PIC = NO; - GCC_NO_COMMON_BLOCKS = YES; - GCC_OPTIMIZATION_LEVEL = 0; - GCC_PREPROCESSOR_DEFINITIONS = ( - "DEBUG=1", - "$(inherited)", - ); - GCC_WARN_64_TO_32_BIT_CONVERSION = YES; - GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; - GCC_WARN_UNDECLARED_SELECTOR = YES; - GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; - GCC_WARN_UNUSED_FUNCTION = YES; - GCC_WARN_UNUSED_VARIABLE = YES; - IPHONEOS_DEPLOYMENT_TARGET = 8.0; - MTL_ENABLE_DEBUG_INFO = YES; - ONLY_ACTIVE_ARCH = YES; - SDKROOT = iphoneos; - TARGETED_DEVICE_FAMILY = "1,2"; - }; - name = Debug; - }; - 97C147041CF9000F007C117D /* Release */ = { - isa = XCBuildConfiguration; - buildSettings = { - ALWAYS_SEARCH_USER_PATHS = NO; - CLANG_ANALYZER_NONNULL = YES; - CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; - CLANG_CXX_LIBRARY = "libc++"; - CLANG_ENABLE_MODULES = YES; - CLANG_ENABLE_OBJC_ARC = YES; - CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; - CLANG_WARN_BOOL_CONVERSION = YES; - CLANG_WARN_COMMA = YES; - CLANG_WARN_CONSTANT_CONVERSION = YES; - CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; - CLANG_WARN_EMPTY_BODY = YES; - CLANG_WARN_ENUM_CONVERSION = YES; - CLANG_WARN_INFINITE_RECURSION = YES; - CLANG_WARN_INT_CONVERSION = YES; - CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; - CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; - CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; - CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; - CLANG_WARN_STRICT_PROTOTYPES = YES; - CLANG_WARN_SUSPICIOUS_MOVE = YES; - CLANG_WARN_UNREACHABLE_CODE = YES; - CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; - "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; - COPY_PHASE_STRIP = NO; - DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; - ENABLE_NS_ASSERTIONS = NO; - ENABLE_STRICT_OBJC_MSGSEND = YES; - GCC_C_LANGUAGE_STANDARD = gnu99; - GCC_NO_COMMON_BLOCKS = YES; - GCC_WARN_64_TO_32_BIT_CONVERSION = YES; - GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; - GCC_WARN_UNDECLARED_SELECTOR = YES; - GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; - GCC_WARN_UNUSED_FUNCTION = YES; - GCC_WARN_UNUSED_VARIABLE = YES; - IPHONEOS_DEPLOYMENT_TARGET = 8.0; - MTL_ENABLE_DEBUG_INFO = NO; - SDKROOT = iphoneos; - TARGETED_DEVICE_FAMILY = "1,2"; - VALIDATE_PRODUCT = YES; - }; - name = Release; - }; - 97C147061CF9000F007C117D /* Debug */ = { - isa = XCBuildConfiguration; - baseConfigurationReference = 9740EEB21CF90195004384FC /* Debug.xcconfig */; - buildSettings = { - ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; - CURRENT_PROJECT_VERSION = "$(FLUTTER_BUILD_NUMBER)"; - ENABLE_BITCODE = NO; - FRAMEWORK_SEARCH_PATHS = ( - "$(inherited)", - "$(PROJECT_DIR)/Flutter", - ); - INFOPLIST_FILE = Runner/Info.plist; - LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; - LIBRARY_SEARCH_PATHS = ( - "$(inherited)", - "$(PROJECT_DIR)/Flutter", - ); - PRODUCT_BUNDLE_IDENTIFIER = com.example.starwars; - PRODUCT_NAME = "$(TARGET_NAME)"; - VERSIONING_SYSTEM = "apple-generic"; - }; - name = Debug; - }; - 97C147071CF9000F007C117D /* Release */ = { - isa = XCBuildConfiguration; - baseConfigurationReference = 7AFA3C8E1D35360C0083082E /* Release.xcconfig */; - buildSettings = { - ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; - CURRENT_PROJECT_VERSION = "$(FLUTTER_BUILD_NUMBER)"; - ENABLE_BITCODE = NO; - FRAMEWORK_SEARCH_PATHS = ( - "$(inherited)", - "$(PROJECT_DIR)/Flutter", - ); - INFOPLIST_FILE = Runner/Info.plist; - LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; - LIBRARY_SEARCH_PATHS = ( - "$(inherited)", - "$(PROJECT_DIR)/Flutter", - ); - PRODUCT_BUNDLE_IDENTIFIER = com.example.starwars; - PRODUCT_NAME = "$(TARGET_NAME)"; - VERSIONING_SYSTEM = "apple-generic"; - }; - name = Release; - }; -/* End XCBuildConfiguration section */ - -/* Begin XCConfigurationList section */ - 97C146E91CF9000F007C117D /* Build configuration list for PBXProject "Runner" */ = { - isa = XCConfigurationList; - buildConfigurations = ( - 97C147031CF9000F007C117D /* Debug */, - 97C147041CF9000F007C117D /* Release */, - 249021D3217E4FDB00AE95B9 /* Profile */, - ); - defaultConfigurationIsVisible = 0; - defaultConfigurationName = Release; - }; - 97C147051CF9000F007C117D /* Build configuration list for PBXNativeTarget "Runner" */ = { - isa = XCConfigurationList; - buildConfigurations = ( - 97C147061CF9000F007C117D /* Debug */, - 97C147071CF9000F007C117D /* Release */, - 249021D4217E4FDB00AE95B9 /* Profile */, - ); - defaultConfigurationIsVisible = 0; - defaultConfigurationName = Release; - }; -/* End XCConfigurationList section */ - }; - rootObject = 97C146E61CF9000F007C117D /* Project object */; -} diff --git a/examples/starwars/ios/Runner.xcodeproj/project.xcworkspace/contents.xcworkspacedata b/examples/starwars/ios/Runner.xcodeproj/project.xcworkspace/contents.xcworkspacedata deleted file mode 100644 index 919434a62..000000000 --- a/examples/starwars/ios/Runner.xcodeproj/project.xcworkspace/contents.xcworkspacedata +++ /dev/null @@ -1,7 +0,0 @@ - - - - - diff --git a/examples/starwars/ios/Runner.xcodeproj/xcshareddata/xcschemes/Runner.xcscheme b/examples/starwars/ios/Runner.xcodeproj/xcshareddata/xcschemes/Runner.xcscheme deleted file mode 100644 index 786d6aad5..000000000 --- a/examples/starwars/ios/Runner.xcodeproj/xcshareddata/xcschemes/Runner.xcscheme +++ /dev/null @@ -1,93 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/examples/starwars/ios/Runner.xcworkspace/contents.xcworkspacedata b/examples/starwars/ios/Runner.xcworkspace/contents.xcworkspacedata deleted file mode 100644 index 21a3cc14c..000000000 --- a/examples/starwars/ios/Runner.xcworkspace/contents.xcworkspacedata +++ /dev/null @@ -1,10 +0,0 @@ - - - - - - - diff --git a/examples/starwars/ios/Runner/AppDelegate.h b/examples/starwars/ios/Runner/AppDelegate.h deleted file mode 100644 index 36e21bbf9..000000000 --- a/examples/starwars/ios/Runner/AppDelegate.h +++ /dev/null @@ -1,6 +0,0 @@ -#import -#import - -@interface AppDelegate : FlutterAppDelegate - -@end diff --git a/examples/starwars/ios/Runner/AppDelegate.m b/examples/starwars/ios/Runner/AppDelegate.m deleted file mode 100644 index 59a72e90b..000000000 --- a/examples/starwars/ios/Runner/AppDelegate.m +++ /dev/null @@ -1,13 +0,0 @@ -#include "AppDelegate.h" -#include "GeneratedPluginRegistrant.h" - -@implementation AppDelegate - -- (BOOL)application:(UIApplication *)application - didFinishLaunchingWithOptions:(NSDictionary *)launchOptions { - [GeneratedPluginRegistrant registerWithRegistry:self]; - // Override point for customization after application launch. - return [super application:application didFinishLaunchingWithOptions:launchOptions]; -} - -@end diff --git a/examples/starwars/ios/Runner/Assets.xcassets/AppIcon.appiconset/Contents.json b/examples/starwars/ios/Runner/Assets.xcassets/AppIcon.appiconset/Contents.json deleted file mode 100644 index d36b1fab2..000000000 --- a/examples/starwars/ios/Runner/Assets.xcassets/AppIcon.appiconset/Contents.json +++ /dev/null @@ -1,122 +0,0 @@ -{ - "images" : [ - { - "size" : "20x20", - "idiom" : "iphone", - "filename" : "Icon-App-20x20@2x.png", - "scale" : "2x" - }, - { - "size" : "20x20", - "idiom" : "iphone", - "filename" : "Icon-App-20x20@3x.png", - "scale" : "3x" - }, - { - "size" : "29x29", - "idiom" : "iphone", - "filename" : "Icon-App-29x29@1x.png", - "scale" : "1x" - }, - { - "size" : "29x29", - "idiom" : "iphone", - "filename" : "Icon-App-29x29@2x.png", - "scale" : "2x" - }, - { - "size" : "29x29", - "idiom" : "iphone", - "filename" : "Icon-App-29x29@3x.png", - "scale" : "3x" - }, - { - "size" : "40x40", - "idiom" : "iphone", - "filename" : "Icon-App-40x40@2x.png", - "scale" : "2x" - }, - { - "size" : "40x40", - "idiom" : "iphone", - "filename" : "Icon-App-40x40@3x.png", - "scale" : "3x" - }, - { - "size" : "60x60", - "idiom" : "iphone", - "filename" : "Icon-App-60x60@2x.png", - "scale" : "2x" - }, - { - "size" : "60x60", - "idiom" : "iphone", - "filename" : "Icon-App-60x60@3x.png", - "scale" : "3x" - }, - { - "size" : "20x20", - "idiom" : "ipad", - "filename" : "Icon-App-20x20@1x.png", - "scale" : "1x" - }, - { - "size" : "20x20", - "idiom" : "ipad", - "filename" : "Icon-App-20x20@2x.png", - "scale" : "2x" - }, - { - "size" : "29x29", - "idiom" : "ipad", - "filename" : "Icon-App-29x29@1x.png", - "scale" : "1x" - }, - { - "size" : "29x29", - "idiom" : "ipad", - "filename" : "Icon-App-29x29@2x.png", - "scale" : "2x" - }, - { - "size" : "40x40", - "idiom" : "ipad", - "filename" : "Icon-App-40x40@1x.png", - "scale" : "1x" - }, - { - "size" : "40x40", - "idiom" : "ipad", - "filename" : "Icon-App-40x40@2x.png", - "scale" : "2x" - }, - { - "size" : "76x76", - "idiom" : "ipad", - "filename" : "Icon-App-76x76@1x.png", - "scale" : "1x" - }, - { - "size" : "76x76", - "idiom" : "ipad", - "filename" : "Icon-App-76x76@2x.png", - "scale" : "2x" - }, - { - "size" : "83.5x83.5", - "idiom" : "ipad", - "filename" : "Icon-App-83.5x83.5@2x.png", - "scale" : "2x" - }, - { - "size" : "1024x1024", - "idiom" : "ios-marketing", - "filename" : "Icon-App-1024x1024@1x.png", - "scale" : "1x" - } - ], - "info" : { - "version" : 1, - "author" : "xcode" - } -} diff --git a/examples/starwars/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-1024x1024@1x.png b/examples/starwars/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-1024x1024@1x.png deleted file mode 100644 index 3d43d11e6..000000000 Binary files a/examples/starwars/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-1024x1024@1x.png and /dev/null differ diff --git a/examples/starwars/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@1x.png b/examples/starwars/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@1x.png deleted file mode 100644 index 28c6bf030..000000000 Binary files a/examples/starwars/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@1x.png and /dev/null differ diff --git a/examples/starwars/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@2x.png b/examples/starwars/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@2x.png deleted file mode 100644 index 2ccbfd967..000000000 Binary files a/examples/starwars/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@2x.png and /dev/null differ diff --git a/examples/starwars/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@3x.png b/examples/starwars/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@3x.png deleted file mode 100644 index f091b6b0b..000000000 Binary files a/examples/starwars/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@3x.png and /dev/null differ diff --git a/examples/starwars/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@1x.png b/examples/starwars/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@1x.png deleted file mode 100644 index 4cde12118..000000000 Binary files a/examples/starwars/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@1x.png and /dev/null differ diff --git a/examples/starwars/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@2x.png b/examples/starwars/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@2x.png deleted file mode 100644 index d0ef06e7e..000000000 Binary files a/examples/starwars/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@2x.png and /dev/null differ diff --git a/examples/starwars/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@3x.png b/examples/starwars/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@3x.png deleted file mode 100644 index dcdc2306c..000000000 Binary files a/examples/starwars/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@3x.png and /dev/null differ diff --git a/examples/starwars/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@1x.png b/examples/starwars/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@1x.png deleted file mode 100644 index 2ccbfd967..000000000 Binary files a/examples/starwars/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@1x.png and /dev/null differ diff --git a/examples/starwars/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@2x.png b/examples/starwars/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@2x.png deleted file mode 100644 index c8f9ed8f5..000000000 Binary files a/examples/starwars/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@2x.png and /dev/null differ diff --git a/examples/starwars/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@3x.png b/examples/starwars/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@3x.png deleted file mode 100644 index a6d6b8609..000000000 Binary files a/examples/starwars/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@3x.png and /dev/null differ diff --git a/examples/starwars/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@2x.png b/examples/starwars/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@2x.png deleted file mode 100644 index a6d6b8609..000000000 Binary files a/examples/starwars/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@2x.png and /dev/null differ diff --git a/examples/starwars/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@3x.png b/examples/starwars/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@3x.png deleted file mode 100644 index 75b2d164a..000000000 Binary files a/examples/starwars/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@3x.png and /dev/null differ diff --git a/examples/starwars/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@1x.png b/examples/starwars/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@1x.png deleted file mode 100644 index c4df70d39..000000000 Binary files a/examples/starwars/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@1x.png and /dev/null differ diff --git a/examples/starwars/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@2x.png b/examples/starwars/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@2x.png deleted file mode 100644 index 6a84f41e1..000000000 Binary files a/examples/starwars/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@2x.png and /dev/null differ diff --git a/examples/starwars/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-83.5x83.5@2x.png b/examples/starwars/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-83.5x83.5@2x.png deleted file mode 100644 index d0e1f5853..000000000 Binary files a/examples/starwars/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-83.5x83.5@2x.png and /dev/null differ diff --git a/examples/starwars/ios/Runner/Assets.xcassets/LaunchImage.imageset/Contents.json b/examples/starwars/ios/Runner/Assets.xcassets/LaunchImage.imageset/Contents.json deleted file mode 100644 index 0bedcf2fd..000000000 --- a/examples/starwars/ios/Runner/Assets.xcassets/LaunchImage.imageset/Contents.json +++ /dev/null @@ -1,23 +0,0 @@ -{ - "images" : [ - { - "idiom" : "universal", - "filename" : "LaunchImage.png", - "scale" : "1x" - }, - { - "idiom" : "universal", - "filename" : "LaunchImage@2x.png", - "scale" : "2x" - }, - { - "idiom" : "universal", - "filename" : "LaunchImage@3x.png", - "scale" : "3x" - } - ], - "info" : { - "version" : 1, - "author" : "xcode" - } -} diff --git a/examples/starwars/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage.png b/examples/starwars/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage.png deleted file mode 100644 index 9da19eaca..000000000 Binary files a/examples/starwars/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage.png and /dev/null differ diff --git a/examples/starwars/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@2x.png b/examples/starwars/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@2x.png deleted file mode 100644 index 9da19eaca..000000000 Binary files a/examples/starwars/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@2x.png and /dev/null differ diff --git a/examples/starwars/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@3x.png b/examples/starwars/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@3x.png deleted file mode 100644 index 9da19eaca..000000000 Binary files a/examples/starwars/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@3x.png and /dev/null differ diff --git a/examples/starwars/ios/Runner/Assets.xcassets/LaunchImage.imageset/README.md b/examples/starwars/ios/Runner/Assets.xcassets/LaunchImage.imageset/README.md deleted file mode 100644 index 89c2725b7..000000000 --- a/examples/starwars/ios/Runner/Assets.xcassets/LaunchImage.imageset/README.md +++ /dev/null @@ -1,5 +0,0 @@ -# Launch Screen Assets - -You can customize the launch screen with your own desired assets by replacing the image files in this directory. - -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. \ No newline at end of file diff --git a/examples/starwars/ios/Runner/Base.lproj/LaunchScreen.storyboard b/examples/starwars/ios/Runner/Base.lproj/LaunchScreen.storyboard deleted file mode 100644 index f2e259c7c..000000000 --- a/examples/starwars/ios/Runner/Base.lproj/LaunchScreen.storyboard +++ /dev/null @@ -1,37 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/examples/starwars/ios/Runner/Base.lproj/Main.storyboard b/examples/starwars/ios/Runner/Base.lproj/Main.storyboard deleted file mode 100644 index f3c28516f..000000000 --- a/examples/starwars/ios/Runner/Base.lproj/Main.storyboard +++ /dev/null @@ -1,26 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/examples/starwars/ios/Runner/Info.plist b/examples/starwars/ios/Runner/Info.plist deleted file mode 100644 index 14ed19a4c..000000000 --- a/examples/starwars/ios/Runner/Info.plist +++ /dev/null @@ -1,45 +0,0 @@ - - - - - CFBundleDevelopmentRegion - en - CFBundleExecutable - $(EXECUTABLE_NAME) - CFBundleIdentifier - $(PRODUCT_BUNDLE_IDENTIFIER) - CFBundleInfoDictionaryVersion - 6.0 - CFBundleName - starwars - CFBundlePackageType - APPL - CFBundleShortVersionString - $(FLUTTER_BUILD_NAME) - CFBundleSignature - ???? - CFBundleVersion - $(FLUTTER_BUILD_NUMBER) - LSRequiresIPhoneOS - - UILaunchStoryboardName - LaunchScreen - UIMainStoryboardFile - Main - UISupportedInterfaceOrientations - - UIInterfaceOrientationPortrait - UIInterfaceOrientationLandscapeLeft - UIInterfaceOrientationLandscapeRight - - UISupportedInterfaceOrientations~ipad - - UIInterfaceOrientationPortrait - UIInterfaceOrientationPortraitUpsideDown - UIInterfaceOrientationLandscapeLeft - UIInterfaceOrientationLandscapeRight - - UIViewControllerBasedStatusBarAppearance - - - diff --git a/examples/starwars/ios/Runner/main.m b/examples/starwars/ios/Runner/main.m deleted file mode 100644 index dff6597e4..000000000 --- a/examples/starwars/ios/Runner/main.m +++ /dev/null @@ -1,9 +0,0 @@ -#import -#import -#import "AppDelegate.h" - -int main(int argc, char* argv[]) { - @autoreleasepool { - return UIApplicationMain(argc, argv, nil, NSStringFromClass([AppDelegate class])); - } -} diff --git a/examples/starwars/lib/generated_plugin_registrant.dart b/examples/starwars/lib/generated_plugin_registrant.dart deleted file mode 100644 index 533f1704b..000000000 --- a/examples/starwars/lib/generated_plugin_registrant.dart +++ /dev/null @@ -1,17 +0,0 @@ -// -// Generated file. Do not edit. -// - -// ignore_for_file: directives_ordering -// ignore_for_file: lines_longer_than_80_chars -// ignore_for_file: depend_on_referenced_packages - -import 'package:connectivity_plus_web/connectivity_plus_web.dart'; - -import 'package:flutter_web_plugins/flutter_web_plugins.dart'; - -// ignore: public_member_api_docs -void registerPlugins(Registrar registrar) { - ConnectivityPlusPlugin.registerWith(registrar); - registrar.registerMessageHandler(); -} diff --git a/examples/starwars/lib/main.dart b/examples/starwars/lib/main.dart deleted file mode 100644 index b8a5bb114..000000000 --- a/examples/starwars/lib/main.dart +++ /dev/null @@ -1,80 +0,0 @@ -import 'package:flutter/material.dart'; -import 'package:graphql_flutter/graphql_flutter.dart'; -import 'package:starwars_app/view/client/graphql_view.dart'; -import 'package:universal_platform/universal_platform.dart'; - -import 'view/episode/episode_page.dart'; -import 'view/review/review_page.dart'; -import 'view/review/review_page_list.dart'; - -String get host { -// https://github.com/flutter/flutter/issues/36126#issuecomment-596215587 - if (UniversalPlatform.isAndroid) { - return '10.0.2.2'; - } else { - return '127.0.0.1'; - } -} - -final graphqlEndpoint = 'http://$host:3000/graphql'; -final subscriptionEndpoint = 'ws://$host:3000/subscriptions'; - -void main() async { - await initHiveForFlutter(); - runApp(MyApp()); -} - -class MyApp extends StatelessWidget { - @override - Widget build(BuildContext context) { - return ClientProvider( - uri: graphqlEndpoint, - subscriptionUri: subscriptionEndpoint, - child: MaterialApp( - title: 'Graphql Starwars Demo', - theme: ThemeData( - primarySwatch: Colors.blue, - ), - home: MyHomePage(title: 'Graphql Starwars Demo'), - ), - ); - } -} - -class MyHomePage extends StatefulWidget { - MyHomePage({Key key, this.title}) : super(key: key); - final String title; - - @override - _MyHomePageState createState() => _MyHomePageState(); -} - -class _MyHomePageState extends State { - int _selectedIndex = 0; - - void _navigateTo(int index) { - setState(() { - _selectedIndex = index; - }); - } - - @override - Widget build(BuildContext context) { - return Scaffold( - appBar: AppBar( - title: Text(widget.title), - ), - body: [EpisodePage(), ReviewsPage(), PagingReviews()][_selectedIndex], - bottomNavigationBar: BottomNavigationBar( - items: const [ - EpisodePage.navItem, - ReviewsPage.navItem, - PagingReviews.navItem, - ], - currentIndex: _selectedIndex, - selectedItemColor: Colors.amber[800], - onTap: _navigateTo, - ), - ); - } -} diff --git a/examples/starwars/lib/model/episode/episode.dart b/examples/starwars/lib/model/episode/episode.dart deleted file mode 100644 index 5e84d8bc9..000000000 --- a/examples/starwars/lib/model/episode/episode.dart +++ /dev/null @@ -1,51 +0,0 @@ -import 'dart:convert'; - -/// The episodes in the Star Wars trilogy -enum Episode { - NEWHOPE, - EMPIRE, - JEDI, -} - -String episodeToJson(Episode e) { - switch (e) { - case Episode.NEWHOPE: - return 'NEWHOPE'; - case Episode.EMPIRE: - return 'EMPIRE'; - case Episode.JEDI: - return 'JEDI'; - default: - return null; - } -} - -String episodeToDisplay(Episode e) { - switch (e) { - case Episode.NEWHOPE: - return 'EP. IV: A NEW HOPE'; - case Episode.EMPIRE: - return 'EP. V: THE EMPIRE STRIKES BACK'; - case Episode.JEDI: - return 'EP. VI: RETURN OF THE JEDI'; - default: - return null; - } -} - -Episode episodeFromJson(String e) { - switch (e) { - case 'NEWHOPE': - return Episode.NEWHOPE; - case 'EMPIRE': - return Episode.EMPIRE; - case 'JEDI': - return Episode.JEDI; - default: - return null; - } -} - -String getPrettyJSONString(Object jsonObject) { - return const JsonEncoder.withIndent(' ').convert(jsonObject); -} diff --git a/examples/starwars/lib/model/review/review.dart b/examples/starwars/lib/model/review/review.dart deleted file mode 100644 index 2771d07ab..000000000 --- a/examples/starwars/lib/model/review/review.dart +++ /dev/null @@ -1,49 +0,0 @@ -import 'package:flutter/material.dart'; - -import 'package:starwars_app/model/episode/episode.dart'; - -class Review { - Review({ - @required this.episode, - @required this.stars, - @required this.id, - this.commentary, - }); - - String id; - Episode episode; - int stars; - String commentary; - - Review copyWith({ - Episode episode, - int stars, - String commentary, - }) { - return Review( - id: id, - episode: episode ?? this.episode, - stars: stars ?? this.stars, - commentary: commentary ?? this.commentary, - ); - } - - Map toJson() { - assert(episode != null && stars != null); - - return { - 'episode': episodeToJson(episode), - 'stars': stars, - 'commentary': commentary, - }; - } - - static Review fromJson(Map map) => Review( - id: map['id'], - episode: episodeFromJson(map['episode'] as String), - stars: map['stars'] as int, - commentary: map['commentary'] as String, - ); -} - -const String Function(Object jsonObject) displayReview = getPrettyJSONString; diff --git a/examples/starwars/lib/utils/graphql_provider.dart b/examples/starwars/lib/utils/graphql_provider.dart deleted file mode 100644 index f22593d87..000000000 --- a/examples/starwars/lib/utils/graphql_provider.dart +++ /dev/null @@ -1,34 +0,0 @@ -import 'package:graphql_flutter/graphql_flutter.dart'; -import 'package:flutter/material.dart'; - -String uuidFromObject(Object object) { - if (object is Map) { - final String typeName = object['__typename']; - final String id = object['id'].toString(); - if (typeName != null && id != null) { - return [typeName, id].join('/'); - } - } - return null; -} - -ValueNotifier clientFor({ - @required String uri, - String subscriptionUri, -}) { - Link link = HttpLink(uri); - if (subscriptionUri != null) { - final WebSocketLink websocketLink = WebSocketLink( - subscriptionUri, - ); - - link = Link.split((request) => request.isSubscription, websocketLink, link); - } - - return ValueNotifier( - GraphQLClient( - cache: GraphQLCache(store: HiveStore()), - link: link, - ), - ); -} diff --git a/examples/starwars/lib/view/client/graphql_view.dart b/examples/starwars/lib/view/client/graphql_view.dart deleted file mode 100644 index e65343678..000000000 --- a/examples/starwars/lib/view/client/graphql_view.dart +++ /dev/null @@ -1,27 +0,0 @@ -import 'package:flutter/material.dart'; -import 'package:graphql_flutter/graphql_flutter.dart'; -import 'package:starwars_app/utils/graphql_provider.dart'; - -/// Wraps the root application with the `graphql_flutter` client. -/// We use the cache for all state management. -class ClientProvider extends StatelessWidget { - ClientProvider({ - @required this.child, - @required String uri, - String subscriptionUri, - }) : client = clientFor( - uri: uri, - subscriptionUri: subscriptionUri, - ); - - final Widget child; - final ValueNotifier client; - - @override - Widget build(BuildContext context) { - return GraphQLProvider( - client: client, - child: child, - ); - } -} diff --git a/examples/starwars/lib/view/episode/episode_page.dart b/examples/starwars/lib/view/episode/episode_page.dart deleted file mode 100644 index c7de2b280..000000000 --- a/examples/starwars/lib/view/episode/episode_page.dart +++ /dev/null @@ -1,71 +0,0 @@ -import 'package:flutter/material.dart'; - -import '../../model/episode/episode.dart'; -import 'hero_query.dart'; - -class EpisodePage extends StatefulWidget { - static const BottomNavigationBarItem navItem = BottomNavigationBarItem( - icon: Icon(Icons.movie_filter), - label: 'Episodes', - ); - - @override - _EpisodePageState createState() => _EpisodePageState(); -} - -class _EpisodePageState extends State { - Episode currentEpisode = Episode.EMPIRE; - - void _selectEpisode(Episode ep) { - setState(() { - currentEpisode = ep; - }); - } - - @override - Widget build(BuildContext context) { - return Center( - child: Column( - mainAxisAlignment: MainAxisAlignment.center, - children: [ - EpisodeSelect( - selected: currentEpisode, - onSelect: _selectEpisode, - ), - const Text( - 'Hero for this episode:', - ), - HeroForEpisode( - episode: currentEpisode, - ) - ], - ), - ); - } -} - -typedef OnSelect = void Function(Episode episode); - -class EpisodeSelect extends StatelessWidget { - const EpisodeSelect({ - @required this.onSelect, - @required this.selected, - }); - - final OnSelect onSelect; - final Episode selected; - - @override - Widget build(BuildContext context) { - return DropdownButton( - value: selected, - onChanged: onSelect, - items: Episode.values.map>((Episode value) { - return DropdownMenuItem( - value: value, - child: Text(value.toString()), - ); - }).toList(), - ); - } -} diff --git a/examples/starwars/lib/view/episode/hero_query.dart b/examples/starwars/lib/view/episode/hero_query.dart deleted file mode 100644 index 7ee9ec3a6..000000000 --- a/examples/starwars/lib/view/episode/hero_query.dart +++ /dev/null @@ -1,69 +0,0 @@ -import 'package:flutter/material.dart'; -import 'package:graphql_flutter/graphql_flutter.dart'; - -import '../../model/episode/episode.dart'; - -class HeroForEpisode extends StatelessWidget { - const HeroForEpisode({@required this.episode}); - - final Episode episode; - - @override - Widget build(BuildContext context) { - return Query( - options: QueryOptions( - document: gql(r''' - query HeroForEpisode($ep: Episode!) { - hero(episode: $ep) { - __typename - name - ... on Droid { - primaryFunction - } - ... on Human { - height - homePlanet - } - } - } - '''), - variables: { - 'ep': episodeToJson(episode), - }, - ), - builder: ( - QueryResult result, { - Future Function() refetch, - FetchMore fetchMore, - }) { - // NOTE: a loading message is always sent, but if you're developing locally, - // the network result might be returned so fast that - // flutter rebuilds again too quickly for you don't see the loading result on the stream - // print([ - // result.source, - // if (result.data != null) result.data['hero']['name'] - // ]); - if (result.hasException) { - return Text(result.exception.toString()); - } - - return Column( - children: [ - if (result.isLoading) - const Center( - child: CircularProgressIndicator(), - ), - if (result.data != null) - Text( - getPrettyJSONString(result.data), - ), - ElevatedButton( - onPressed: result.isNotLoading ? refetch : null, - child: const Text('REFETCH'), - ), - ], - ); - }, - ); - } -} diff --git a/examples/starwars/lib/view/review/review_page.dart b/examples/starwars/lib/view/review/review_page.dart deleted file mode 100644 index 4038bd842..000000000 --- a/examples/starwars/lib/view/review/review_page.dart +++ /dev/null @@ -1,22 +0,0 @@ -import 'package:flutter/material.dart'; - -import 'review_subscription.dart'; - -class ReviewsPage extends StatelessWidget { - static const BottomNavigationBarItem navItem = BottomNavigationBarItem( - icon: Icon(Icons.star), - label: 'Reviews', - ); - - @override - Widget build(BuildContext context) { - return Column( - mainAxisAlignment: MainAxisAlignment.start, - crossAxisAlignment: CrossAxisAlignment.start, - children: [ - const ListTile(title: Text('Live Stream of Reviews')), - Expanded(child: ReviewFeed()), - ], - ); - } -} diff --git a/examples/starwars/lib/view/review/review_page_list.dart b/examples/starwars/lib/view/review/review_page_list.dart deleted file mode 100644 index 23aab63ec..000000000 --- a/examples/starwars/lib/view/review/review_page_list.dart +++ /dev/null @@ -1,85 +0,0 @@ -import 'package:flutter/material.dart'; -import 'package:graphql_flutter/graphql_flutter.dart'; -import 'package:starwars_app/view/review/review_view.dart'; - -class PagingReviews extends StatelessWidget { - static const BottomNavigationBarItem navItem = BottomNavigationBarItem( - icon: Icon(Icons.description), - label: 'Paging', - ); - - @override - Widget build(BuildContext context) { - return Query( - options: QueryOptions( - // if we have cached results, don't clobber them - fetchPolicy: FetchPolicy.cacheFirst, - document: gql(r''' - query Reviews($page: Int!) { - reviews(page: $page) { - page - reviews { - id - episode - stars - commentary - } - } - } - '''), - variables: {'page': 0}, - ), - builder: ( - QueryResult result, { - Refetch refetch, - FetchMore fetchMore, - }) { - if (result.hasException) { - return Text(result.exception.toString()); - } - - if (result.isLoading && result.data == null) { - return const Center( - child: CircularProgressIndicator(), - ); - } - - final nextPage = result.data['reviews']['page'] + 1; - - return Column( - children: [ - Expanded( - child: DisplayReviews( - reviews: result.data['reviews']['reviews'] - .cast>(), - ), - ), - (result.isLoading) - ? Center( - child: CircularProgressIndicator(), - ) - : ElevatedButton( - onPressed: () { - fetchMore( - FetchMoreOptions.partial( - variables: {'page': nextPage}, - updateQuery: (existing, newReviews) => ({ - 'reviews': { - 'page': newReviews['reviews']['page'], - 'reviews': [ - ...existing['reviews']['reviews'], - ...newReviews['reviews']['reviews'] - ], - } - }), - ), - ); - }, - child: Text('LOAD PAGE ${nextPage + 1}'), - ), - ], - ); - }, - ); - } -} diff --git a/examples/starwars/lib/view/review/review_subscription.dart b/examples/starwars/lib/view/review/review_subscription.dart deleted file mode 100644 index 3b510c4eb..000000000 --- a/examples/starwars/lib/view/review/review_subscription.dart +++ /dev/null @@ -1,39 +0,0 @@ -import 'package:flutter/material.dart'; -import 'package:graphql_flutter/graphql_flutter.dart'; -import 'package:starwars_app/view/review/review_view.dart'; - -class ReviewFeed extends StatelessWidget { - @override - Widget build(BuildContext context) { - return Subscription( - options: SubscriptionOptions( - document: gql( - r''' - subscription reviewAdded { - reviewAdded { - stars, commentary, episode - } - } - ''', - ), - ), - builder: (result) { - if (result.hasException) { - return Text(result.exception.toString()); - } - - if (result.isLoading) { - return Center( - child: const CircularProgressIndicator(), - ); - } - return ResultAccumulator.appendUniqueEntries( - latest: result.data, - builder: (context, {results}) => DisplayReviews( - reviews: results.reversed.toList(), - ), - ); - }, - ); - } -} diff --git a/examples/starwars/lib/view/review/review_view.dart b/examples/starwars/lib/view/review/review_view.dart deleted file mode 100644 index ab3f924b2..000000000 --- a/examples/starwars/lib/view/review/review_view.dart +++ /dev/null @@ -1,56 +0,0 @@ -import 'package:flutter/material.dart'; -import 'package:starwars_app/model/review/review.dart'; - -class DisplayReviews extends StatefulWidget { - const DisplayReviews({ - Key key, - @required this.reviews, - }) : super(key: key); - - final List> reviews; - - @override - _DisplayReviewsState createState() => _DisplayReviewsState(); -} - -class _DisplayReviewsState extends State { - List> get reviews => widget.reviews; - - Widget displayRaw(Map raw) => Card( - child: Container( - padding: const EdgeInsets.all(15.0), - //height: 150, - child: Text(displayReview(raw)), - ), - ); - - /* - // for debugging - @override - initState() { - super.initState(); - print( - 'DisplayReviews.initState() called on $this.\n' - 'this should only happen ONCE on this page, regardless of fetchMore calls, etc.', - ); - } - @override - didUpdateWidget(old) { - super.didUpdateWidget(old); - print( - 'DisplayReviews.didUpdateWidget() called on $this.\n' - 'this can happen REPEATEDLY due to fetchMore, etc.', - ); - } - */ - - @override - Widget build(BuildContext context) { - return Container( - padding: const EdgeInsets.fromLTRB(8.0, 8.0, 8.0, 0.0), - child: ListView( - children: reviews.map(displayRaw).toList(), - ), - ); - } -} diff --git a/examples/starwars/pubspec.yaml b/examples/starwars/pubspec.yaml deleted file mode 100644 index c8a3aa07c..000000000 --- a/examples/starwars/pubspec.yaml +++ /dev/null @@ -1,20 +0,0 @@ -name: starwars_app -description: An example graphql_flutter application utilizing graphql_starwars_test_server - -publish_to: none - -environment: - sdk: ">=2.10.0 <3.0.0" - -dependencies: - flutter: - sdk: flutter - graphql_flutter: - path: ../../packages/graphql_flutter - graphql: ^5.1.2-beta.1 - universal_platform: - ^0.1.3 - # https://github.com/flutter/flutter/issues/36126#issuecomment-596215587 - -flutter: - uses-material-design: true \ No newline at end of file diff --git a/examples/starwars/server/pubspec.yaml b/examples/starwars/server/pubspec.yaml deleted file mode 100644 index 63a9e1669..000000000 --- a/examples/starwars/server/pubspec.yaml +++ /dev/null @@ -1,20 +0,0 @@ -name: starwars_server - -publish_to: none - -environment: - sdk: ">=2.10.0 <3.0.0" - -dependencies: - graphql_starwars_test_server: ^0.1.0 - -dependency_overrides: - graphql_server: - git: - url: git@github.com:micimize/angel.git - ref: typeerror2.8-fix - path: packages/graphql/graphql_server - graphql_parser: - git: - url: git@github.com:micimize/angel.git - path: packages/graphql/graphql_parser diff --git a/examples/starwars/web/favicon.png b/examples/starwars/web/favicon.png deleted file mode 100644 index 8aaa46ac1..000000000 Binary files a/examples/starwars/web/favicon.png and /dev/null differ diff --git a/examples/starwars/web/icons/Icon-192.png b/examples/starwars/web/icons/Icon-192.png deleted file mode 100644 index b749bfef0..000000000 Binary files a/examples/starwars/web/icons/Icon-192.png and /dev/null differ diff --git a/examples/starwars/web/icons/Icon-512.png b/examples/starwars/web/icons/Icon-512.png deleted file mode 100644 index 88cfd48df..000000000 Binary files a/examples/starwars/web/icons/Icon-512.png and /dev/null differ diff --git a/examples/starwars/web/index.html b/examples/starwars/web/index.html deleted file mode 100644 index 3fa8f76a9..000000000 --- a/examples/starwars/web/index.html +++ /dev/null @@ -1,33 +0,0 @@ - - - - - - - - - - - - - - - - - starwars_app - - - - - - - - diff --git a/examples/starwars/web/manifest.json b/examples/starwars/web/manifest.json deleted file mode 100644 index d35da53e7..000000000 --- a/examples/starwars/web/manifest.json +++ /dev/null @@ -1,23 +0,0 @@ -{ - "name": "starwars_app", - "short_name": "starwars_app", - "start_url": ".", - "display": "minimal-ui", - "background_color": "#0175C2", - "theme_color": "#0175C2", - "description": "A new Flutter project.", - "orientation": "portrait-primary", - "prefer_related_applications": false, - "icons": [ - { - "src": "icons/Icon-192.png", - "sizes": "192x192", - "type": "image/png" - }, - { - "src": "icons/Icon-512.png", - "sizes": "512x512", - "type": "image/png" - } - ] -} diff --git a/packages/graphql/example/README.md b/packages/graphql/example/README.md deleted file mode 100644 index a4e286290..000000000 --- a/packages/graphql/example/README.md +++ /dev/null @@ -1,25 +0,0 @@ -# `graphql/client.dart` Example Application - -This is a simple command line application to showcase how you can use the Dart GraphQL Client, without flutter. - -To run this application: - -## Setup: - -1. First clone this repository and navigate to this directory -2. Install all dart dependencies -3. replace `` in `lib/local.dart` with your GitHub token -## Usage: - -```sh -# List repositories -pub run example - -# Star Repository (you can get repository ids from `pub run example`) -pub run example -a star --id $REPOSITORY_ID - -# Unstar Repository -pub run example -a unstar --id $REPOSITORY_ID -``` - -**NB:** Replace repository id in the last two commands with a real Github Repository ID. You can get by running the first command, IDs are printed on the console. diff --git a/packages/graphql/example/bin/example.dart b/packages/graphql/example/bin/example.dart deleted file mode 100644 index 3fb9cf2b3..000000000 --- a/packages/graphql/example/bin/example.dart +++ /dev/null @@ -1,40 +0,0 @@ -import 'package:args/args.dart'; -import 'package:example/main.dart'; - -late ArgResults argResults; - -/// CLI fro executing github actions -/// -/// Usage: -/// ```sh -/// # List repositories -/// pub run example -/// -/// # Star Repository -/// pub run example -a star --id $REPOSITORY_ID_HERE -/// -/// # Unstar Repository -/// pub run example -a unstar --id $REPOSITORY_ID_HERE -/// ``` -void main(List arguments) { - final ArgParser parser = ArgParser() - ..addOption('action', abbr: 'a', defaultsTo: 'fetch') - ..addOption('id', defaultsTo: ''); - - argResults = parser.parse(arguments); - - final String? action = argResults['action'] as String?; - final String? id = argResults['id'] as String?; - - switch (action) { - case 'star': - starRepository(id); - break; - case 'unstar': - removeStarFromRepository(id); - break; - default: - readRepositories(); - break; - } -} diff --git a/packages/graphql/example/lib/local.dart b/packages/graphql/example/lib/local.dart deleted file mode 100644 index 6d40e426a..000000000 --- a/packages/graphql/example/lib/local.dart +++ /dev/null @@ -1 +0,0 @@ -const String YOUR_PERSONAL_ACCESS_TOKEN = ''; diff --git a/packages/graphql/example/lib/main.dart b/packages/graphql/example/lib/main.dart deleted file mode 100644 index 9a9b5db80..000000000 --- a/packages/graphql/example/lib/main.dart +++ /dev/null @@ -1,171 +0,0 @@ -/// Example functions for calling the Github GraphQL API -/// -/// ### Queries -/// * [readRepositories()] -/// -/// ### Mutations: -/// * [starRepository(id)] -/// * [removeStarFromRepository(id)] -/// -/// To run the example, create a file `lib/local.dart` with the content: -/// ```dart -/// const String YOUR_PERSONAL_ACCESS_TOKEN = -/// ''; -/// ``` -import 'dart:io' show stdout, stderr, exit; -import 'package:graphql/client.dart'; - -// to run the example, replace with your GitHub token in ./local.dart -import './local.dart'; - -/// Get an authenticated [GraphQLClient] for the github api -/// -/// `graphql/client.dart` leverages the [gql_link][1] interface, -/// re-exporting [HttpLink], [WebsocketLink], [ErrorLink], and [DedupeLink], -/// in addition to the links we define ourselves (`AuthLink`) -/// -/// [1]: https://pub.dev/packages/gql_link -GraphQLClient getGithubGraphQLClient() { - final Link _link = HttpLink( - 'https://api.github.com/graphql', - defaultHeaders: { - 'Authorization': 'Bearer $YOUR_PERSONAL_ACCESS_TOKEN', - }, - ); - - return GraphQLClient( - cache: GraphQLCache(), - link: _link, - ); -} - -/// query example - fetch all your github repositories -void readRepositories() async { - final GraphQLClient _client = getGithubGraphQLClient(); - - const int nRepositories = 50; - - final QueryOptions options = QueryOptions( - document: gql( - r''' - query ReadRepositories($nRepositories: Int!) { - viewer { - repositories(last: $nRepositories) { - nodes { - __typename - id - name - viewerHasStarred - } - } - } - } - ''', - ), - variables: { - 'nRepositories': nRepositories, - }, - ); - - final QueryResult result = await _client.query(options); - - if (result.hasException) { - stderr.writeln(result.exception.toString()); - exit(2); - } - - final List repositories = - result.data!['viewer']['repositories']['nodes'] as List; - - repositories.forEach( - (dynamic f) => {stdout.writeln('Id: ${f['id']} Name: ${f['name']}')}, - ); - - exit(0); -} - -// mutation example - add star to repository -void starRepository(String? repositoryID) async { - if (repositoryID == '') { - stderr.writeln('The ID of the Repository is Required!'); - exit(2); - } - - final GraphQLClient _client = getGithubGraphQLClient(); - - final options = MutationOptions( - document: gql( - r''' - mutation AddStar($starrableId: ID!) { - action: addStar(input: {starrableId: $starrableId}) { - starrable { - viewerHasStarred - } - } - } - ''', - ), - variables: { - 'starrableId': repositoryID, - }, - ); - - final QueryResult result = await _client.mutate(options); - - if (result.hasException) { - stderr.writeln(result.exception.toString()); - exit(2); - } - - final bool isStarrred = - result.data!['action']['starrable']['viewerHasStarred'] as bool; - - if (isStarrred) { - stdout.writeln('Thanks for your star!'); - } - - exit(0); -} - -// mutation example - remove star from repository -void removeStarFromRepository(String? repositoryID) async { - if (repositoryID == '') { - stderr.writeln('The ID of the Repository is Required!'); - exit(2); - } - - final GraphQLClient _client = getGithubGraphQLClient(); - - final MutationOptions options = MutationOptions( - document: gql( - r''' - mutation RemoveStar($starrableId: ID!) { - action: removeStar(input: {starrableId: $starrableId}) { - starrable { - viewerHasStarred - } - } - } - ''', - ), - variables: { - 'starrableId': repositoryID, - }, - ); - - final QueryResult result = await _client.mutate(options); - - if (result.hasException) { - stderr.writeln(result.exception.toString()); - exit(2); - } - - final bool isStarrred = - result.data!['action']['starrable']['viewerHasStarred'] as bool; - - if (!isStarrred) { - stdout.writeln('Sorry you changed your mind!'); - } - - exit(0); -} diff --git a/packages/graphql/example/pubspec.yaml b/packages/graphql/example/pubspec.yaml deleted file mode 100644 index 24a215420..000000000 --- a/packages/graphql/example/pubspec.yaml +++ /dev/null @@ -1,16 +0,0 @@ -name: example -description: Example for using GraphQL Dart -version: 1.0.0+1 - -publish_to: none - -environment: - sdk: '>=2.12.0 <3.0.0' - -dependencies: - args: - graphql: - path: .. - -executables: - example: example diff --git a/packages/graphql_flutter/example/README.md b/packages/graphql_flutter/example/README.md deleted file mode 100644 index 3608e1745..000000000 --- a/packages/graphql_flutter/example/README.md +++ /dev/null @@ -1,7 +0,0 @@ -# graphql_flutter example - -A Github API wrapper example where you need to specify you token in the `local.dart` file - -## Getting Started - -Just run `flutter pub get` and run your flutter app diff --git a/packages/graphql_flutter/example/analysis_options.yaml b/packages/graphql_flutter/example/analysis_options.yaml deleted file mode 100644 index 90816a657..000000000 --- a/packages/graphql_flutter/example/analysis_options.yaml +++ /dev/null @@ -1,6 +0,0 @@ -include: package:pedantic/analysis_options.yaml - -linter: - rules: - avoid_as: false - flutter_style_todos: false diff --git a/packages/graphql_flutter/example/android/.gitignore b/packages/graphql_flutter/example/android/.gitignore deleted file mode 100644 index 6f568019d..000000000 --- a/packages/graphql_flutter/example/android/.gitignore +++ /dev/null @@ -1,13 +0,0 @@ -gradle-wrapper.jar -/.gradle -/captures/ -/gradlew -/gradlew.bat -/local.properties -GeneratedPluginRegistrant.java - -# Remember to never publicly share your keystore. -# See https://flutter.dev/docs/deployment/android#reference-the-keystore-from-the-app -key.properties -**/*.keystore -**/*.jks diff --git a/packages/graphql_flutter/example/android/app/build.gradle b/packages/graphql_flutter/example/android/app/build.gradle deleted file mode 100644 index 69f8d594f..000000000 --- a/packages/graphql_flutter/example/android/app/build.gradle +++ /dev/null @@ -1,68 +0,0 @@ -def localProperties = new Properties() -def localPropertiesFile = rootProject.file('local.properties') -if (localPropertiesFile.exists()) { - localPropertiesFile.withReader('UTF-8') { reader -> - localProperties.load(reader) - } -} - -def flutterRoot = localProperties.getProperty('flutter.sdk') -if (flutterRoot == null) { - throw new GradleException("Flutter SDK not found. Define location with flutter.sdk in the local.properties file.") -} - -def flutterVersionCode = localProperties.getProperty('flutter.versionCode') -if (flutterVersionCode == null) { - flutterVersionCode = '1' -} - -def flutterVersionName = localProperties.getProperty('flutter.versionName') -if (flutterVersionName == null) { - flutterVersionName = '1.0' -} - -apply plugin: 'com.android.application' -apply plugin: 'kotlin-android' -apply from: "$flutterRoot/packages/flutter_tools/gradle/flutter.gradle" - -android { - compileSdkVersion flutter.compileSdkVersion - - compileOptions { - sourceCompatibility JavaVersion.VERSION_1_8 - targetCompatibility JavaVersion.VERSION_1_8 - } - - kotlinOptions { - jvmTarget = '1.8' - } - - sourceSets { - main.java.srcDirs += 'src/main/kotlin' - } - - defaultConfig { - // TODO: Specify your own unique Application ID (https://developer.android.com/studio/build/application-id.html). - applicationId "com.example.demo_migaration" - minSdkVersion flutter.minSdkVersion - targetSdkVersion flutter.targetSdkVersion - versionCode flutterVersionCode.toInteger() - versionName flutterVersionName - } - - buildTypes { - release { - // TODO: Add your own signing config for the release build. - // Signing with the debug keys for now, so `flutter run --release` works. - signingConfig signingConfigs.debug - } - } -} - -flutter { - source '../..' -} - -dependencies { - implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlin_version" -} diff --git a/packages/graphql_flutter/example/android/app/src/debug/AndroidManifest.xml b/packages/graphql_flutter/example/android/app/src/debug/AndroidManifest.xml deleted file mode 100644 index b15a3d5fb..000000000 --- a/packages/graphql_flutter/example/android/app/src/debug/AndroidManifest.xml +++ /dev/null @@ -1,7 +0,0 @@ - - - - diff --git a/packages/graphql_flutter/example/android/app/src/main/AndroidManifest.xml b/packages/graphql_flutter/example/android/app/src/main/AndroidManifest.xml deleted file mode 100644 index f153f1bf5..000000000 --- a/packages/graphql_flutter/example/android/app/src/main/AndroidManifest.xml +++ /dev/null @@ -1,34 +0,0 @@ - - - - - - - - - - - - - - diff --git a/packages/graphql_flutter/example/android/app/src/main/kotlin/com/example/demo_migaration/MainActivity.kt b/packages/graphql_flutter/example/android/app/src/main/kotlin/com/example/demo_migaration/MainActivity.kt deleted file mode 100644 index 762f551b5..000000000 --- a/packages/graphql_flutter/example/android/app/src/main/kotlin/com/example/demo_migaration/MainActivity.kt +++ /dev/null @@ -1,6 +0,0 @@ -package com.example.demo_migaration - -import io.flutter.embedding.android.FlutterActivity - -class MainActivity: FlutterActivity() { -} diff --git a/packages/graphql_flutter/example/android/app/src/main/res/drawable-v21/launch_background.xml b/packages/graphql_flutter/example/android/app/src/main/res/drawable-v21/launch_background.xml deleted file mode 100644 index f74085f3f..000000000 --- a/packages/graphql_flutter/example/android/app/src/main/res/drawable-v21/launch_background.xml +++ /dev/null @@ -1,12 +0,0 @@ - - - - - - - - diff --git a/packages/graphql_flutter/example/android/app/src/main/res/drawable/launch_background.xml b/packages/graphql_flutter/example/android/app/src/main/res/drawable/launch_background.xml deleted file mode 100644 index 304732f88..000000000 --- a/packages/graphql_flutter/example/android/app/src/main/res/drawable/launch_background.xml +++ /dev/null @@ -1,12 +0,0 @@ - - - - - - - - diff --git a/packages/graphql_flutter/example/android/app/src/main/res/mipmap-hdpi/ic_launcher.png b/packages/graphql_flutter/example/android/app/src/main/res/mipmap-hdpi/ic_launcher.png deleted file mode 100644 index db77bb4b7..000000000 Binary files a/packages/graphql_flutter/example/android/app/src/main/res/mipmap-hdpi/ic_launcher.png and /dev/null differ diff --git a/packages/graphql_flutter/example/android/app/src/main/res/mipmap-mdpi/ic_launcher.png b/packages/graphql_flutter/example/android/app/src/main/res/mipmap-mdpi/ic_launcher.png deleted file mode 100644 index 17987b79b..000000000 Binary files a/packages/graphql_flutter/example/android/app/src/main/res/mipmap-mdpi/ic_launcher.png and /dev/null differ diff --git a/packages/graphql_flutter/example/android/app/src/main/res/mipmap-xhdpi/ic_launcher.png b/packages/graphql_flutter/example/android/app/src/main/res/mipmap-xhdpi/ic_launcher.png deleted file mode 100644 index 09d439148..000000000 Binary files a/packages/graphql_flutter/example/android/app/src/main/res/mipmap-xhdpi/ic_launcher.png and /dev/null differ diff --git a/packages/graphql_flutter/example/android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png b/packages/graphql_flutter/example/android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png deleted file mode 100644 index d5f1c8d34..000000000 Binary files a/packages/graphql_flutter/example/android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png and /dev/null differ diff --git a/packages/graphql_flutter/example/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png b/packages/graphql_flutter/example/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png deleted file mode 100644 index 4d6372eeb..000000000 Binary files a/packages/graphql_flutter/example/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png and /dev/null differ diff --git a/packages/graphql_flutter/example/android/app/src/main/res/values-night/styles.xml b/packages/graphql_flutter/example/android/app/src/main/res/values-night/styles.xml deleted file mode 100644 index 3db14bb53..000000000 --- a/packages/graphql_flutter/example/android/app/src/main/res/values-night/styles.xml +++ /dev/null @@ -1,18 +0,0 @@ - - - - - - - diff --git a/packages/graphql_flutter/example/android/app/src/main/res/values/styles.xml b/packages/graphql_flutter/example/android/app/src/main/res/values/styles.xml deleted file mode 100644 index d460d1e92..000000000 --- a/packages/graphql_flutter/example/android/app/src/main/res/values/styles.xml +++ /dev/null @@ -1,18 +0,0 @@ - - - - - - - diff --git a/packages/graphql_flutter/example/android/app/src/profile/AndroidManifest.xml b/packages/graphql_flutter/example/android/app/src/profile/AndroidManifest.xml deleted file mode 100644 index b15a3d5fb..000000000 --- a/packages/graphql_flutter/example/android/app/src/profile/AndroidManifest.xml +++ /dev/null @@ -1,7 +0,0 @@ - - - - diff --git a/packages/graphql_flutter/example/android/build.gradle b/packages/graphql_flutter/example/android/build.gradle deleted file mode 100644 index 24047dce5..000000000 --- a/packages/graphql_flutter/example/android/build.gradle +++ /dev/null @@ -1,31 +0,0 @@ -buildscript { - ext.kotlin_version = '1.3.50' - repositories { - google() - mavenCentral() - } - - dependencies { - classpath 'com.android.tools.build:gradle:4.1.0' - classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version" - } -} - -allprojects { - repositories { - google() - mavenCentral() - } -} - -rootProject.buildDir = '../build' -subprojects { - project.buildDir = "${rootProject.buildDir}/${project.name}" -} -subprojects { - project.evaluationDependsOn(':app') -} - -task clean(type: Delete) { - delete rootProject.buildDir -} diff --git a/packages/graphql_flutter/example/android/gradle.properties b/packages/graphql_flutter/example/android/gradle.properties deleted file mode 100644 index 94adc3a3f..000000000 --- a/packages/graphql_flutter/example/android/gradle.properties +++ /dev/null @@ -1,3 +0,0 @@ -org.gradle.jvmargs=-Xmx1536M -android.useAndroidX=true -android.enableJetifier=true diff --git a/packages/graphql_flutter/example/android/gradle/wrapper/gradle-wrapper.properties b/packages/graphql_flutter/example/android/gradle/wrapper/gradle-wrapper.properties deleted file mode 100644 index bc6a58afd..000000000 --- a/packages/graphql_flutter/example/android/gradle/wrapper/gradle-wrapper.properties +++ /dev/null @@ -1,6 +0,0 @@ -#Fri Jun 23 08:50:38 CEST 2017 -distributionBase=GRADLE_USER_HOME -distributionPath=wrapper/dists -zipStoreBase=GRADLE_USER_HOME -zipStorePath=wrapper/dists -distributionUrl=https\://services.gradle.org/distributions/gradle-6.7-all.zip diff --git a/packages/graphql_flutter/example/android/settings.gradle b/packages/graphql_flutter/example/android/settings.gradle deleted file mode 100644 index 44e62bcf0..000000000 --- a/packages/graphql_flutter/example/android/settings.gradle +++ /dev/null @@ -1,11 +0,0 @@ -include ':app' - -def localPropertiesFile = new File(rootProject.projectDir, "local.properties") -def properties = new Properties() - -assert localPropertiesFile.exists() -localPropertiesFile.withReader("UTF-8") { reader -> properties.load(reader) } - -def flutterSdkPath = properties.getProperty("flutter.sdk") -assert flutterSdkPath != null, "flutter.sdk not set in local.properties" -apply from: "$flutterSdkPath/packages/flutter_tools/gradle/app_plugin_loader.gradle" diff --git a/packages/graphql_flutter/example/ios/.gitignore b/packages/graphql_flutter/example/ios/.gitignore deleted file mode 100644 index 7a7f9873a..000000000 --- a/packages/graphql_flutter/example/ios/.gitignore +++ /dev/null @@ -1,34 +0,0 @@ -**/dgph -*.mode1v3 -*.mode2v3 -*.moved-aside -*.pbxuser -*.perspectivev3 -**/*sync/ -.sconsign.dblite -.tags* -**/.vagrant/ -**/DerivedData/ -Icon? -**/Pods/ -**/.symlinks/ -profile -xcuserdata -**/.generated/ -Flutter/App.framework -Flutter/Flutter.framework -Flutter/Flutter.podspec -Flutter/Generated.xcconfig -Flutter/ephemeral/ -Flutter/app.flx -Flutter/app.zip -Flutter/flutter_assets/ -Flutter/flutter_export_environment.sh -ServiceDefinitions.json -Runner/GeneratedPluginRegistrant.* - -# Exceptions to above rules. -!default.mode1v3 -!default.mode2v3 -!default.pbxuser -!default.perspectivev3 diff --git a/packages/graphql_flutter/example/ios/Flutter/AppFrameworkInfo.plist b/packages/graphql_flutter/example/ios/Flutter/AppFrameworkInfo.plist deleted file mode 100644 index 8d4492f97..000000000 --- a/packages/graphql_flutter/example/ios/Flutter/AppFrameworkInfo.plist +++ /dev/null @@ -1,26 +0,0 @@ - - - - - CFBundleDevelopmentRegion - en - CFBundleExecutable - App - CFBundleIdentifier - io.flutter.flutter.app - CFBundleInfoDictionaryVersion - 6.0 - CFBundleName - App - CFBundlePackageType - FMWK - CFBundleShortVersionString - 1.0 - CFBundleSignature - ???? - CFBundleVersion - 1.0 - MinimumOSVersion - 9.0 - - diff --git a/packages/graphql_flutter/example/ios/Flutter/Debug.xcconfig b/packages/graphql_flutter/example/ios/Flutter/Debug.xcconfig deleted file mode 100644 index ec97fc6f3..000000000 --- a/packages/graphql_flutter/example/ios/Flutter/Debug.xcconfig +++ /dev/null @@ -1,2 +0,0 @@ -#include? "Pods/Target Support Files/Pods-Runner/Pods-Runner.debug.xcconfig" -#include "Generated.xcconfig" diff --git a/packages/graphql_flutter/example/ios/Flutter/Release.xcconfig b/packages/graphql_flutter/example/ios/Flutter/Release.xcconfig deleted file mode 100644 index c4855bfe2..000000000 --- a/packages/graphql_flutter/example/ios/Flutter/Release.xcconfig +++ /dev/null @@ -1,2 +0,0 @@ -#include? "Pods/Target Support Files/Pods-Runner/Pods-Runner.release.xcconfig" -#include "Generated.xcconfig" diff --git a/packages/graphql_flutter/example/ios/Podfile b/packages/graphql_flutter/example/ios/Podfile deleted file mode 100644 index 1e8c3c90a..000000000 --- a/packages/graphql_flutter/example/ios/Podfile +++ /dev/null @@ -1,41 +0,0 @@ -# Uncomment this line to define a global platform for your project -# platform :ios, '9.0' - -# CocoaPods analytics sends network stats synchronously affecting flutter build latency. -ENV['COCOAPODS_DISABLE_STATS'] = 'true' - -project 'Runner', { - 'Debug' => :debug, - 'Profile' => :release, - 'Release' => :release, -} - -def flutter_root - generated_xcode_build_settings_path = File.expand_path(File.join('..', 'Flutter', 'Generated.xcconfig'), __FILE__) - unless File.exist?(generated_xcode_build_settings_path) - raise "#{generated_xcode_build_settings_path} must exist. If you're running pod install manually, make sure flutter pub get is executed first" - end - - File.foreach(generated_xcode_build_settings_path) do |line| - matches = line.match(/FLUTTER_ROOT\=(.*)/) - return matches[1].strip if matches - end - raise "FLUTTER_ROOT not found in #{generated_xcode_build_settings_path}. Try deleting Generated.xcconfig, then run flutter pub get" -end - -require File.expand_path(File.join('packages', 'flutter_tools', 'bin', 'podhelper'), flutter_root) - -flutter_ios_podfile_setup - -target 'Runner' do - use_frameworks! - use_modular_headers! - - flutter_install_all_ios_pods File.dirname(File.realpath(__FILE__)) -end - -post_install do |installer| - installer.pods_project.targets.each do |target| - flutter_additional_ios_build_settings(target) - end -end diff --git a/packages/graphql_flutter/example/ios/Runner.xcodeproj/project.pbxproj b/packages/graphql_flutter/example/ios/Runner.xcodeproj/project.pbxproj deleted file mode 100644 index 9e093b833..000000000 --- a/packages/graphql_flutter/example/ios/Runner.xcodeproj/project.pbxproj +++ /dev/null @@ -1,481 +0,0 @@ -// !$*UTF8*$! -{ - archiveVersion = 1; - classes = { - }; - objectVersion = 50; - objects = { - -/* Begin PBXBuildFile section */ - 1498D2341E8E89220040F4C2 /* GeneratedPluginRegistrant.m in Sources */ = {isa = PBXBuildFile; fileRef = 1498D2331E8E89220040F4C2 /* GeneratedPluginRegistrant.m */; }; - 3B3967161E833CAA004F5970 /* AppFrameworkInfo.plist in Resources */ = {isa = PBXBuildFile; fileRef = 3B3967151E833CAA004F5970 /* AppFrameworkInfo.plist */; }; - 74858FAF1ED2DC5600515810 /* AppDelegate.swift in Sources */ = {isa = PBXBuildFile; fileRef = 74858FAE1ED2DC5600515810 /* AppDelegate.swift */; }; - 97C146FC1CF9000F007C117D /* Main.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 97C146FA1CF9000F007C117D /* Main.storyboard */; }; - 97C146FE1CF9000F007C117D /* Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 97C146FD1CF9000F007C117D /* Assets.xcassets */; }; - 97C147011CF9000F007C117D /* LaunchScreen.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 97C146FF1CF9000F007C117D /* LaunchScreen.storyboard */; }; -/* End PBXBuildFile section */ - -/* Begin PBXCopyFilesBuildPhase section */ - 9705A1C41CF9048500538489 /* Embed Frameworks */ = { - isa = PBXCopyFilesBuildPhase; - buildActionMask = 2147483647; - dstPath = ""; - dstSubfolderSpec = 10; - files = ( - ); - name = "Embed Frameworks"; - runOnlyForDeploymentPostprocessing = 0; - }; -/* End PBXCopyFilesBuildPhase section */ - -/* Begin PBXFileReference section */ - 1498D2321E8E86230040F4C2 /* GeneratedPluginRegistrant.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = GeneratedPluginRegistrant.h; sourceTree = ""; }; - 1498D2331E8E89220040F4C2 /* GeneratedPluginRegistrant.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = GeneratedPluginRegistrant.m; sourceTree = ""; }; - 3B3967151E833CAA004F5970 /* AppFrameworkInfo.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; name = AppFrameworkInfo.plist; path = Flutter/AppFrameworkInfo.plist; sourceTree = ""; }; - 74858FAD1ED2DC5600515810 /* Runner-Bridging-Header.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = "Runner-Bridging-Header.h"; sourceTree = ""; }; - 74858FAE1ED2DC5600515810 /* AppDelegate.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = AppDelegate.swift; sourceTree = ""; }; - 7AFA3C8E1D35360C0083082E /* Release.xcconfig */ = {isa = PBXFileReference; lastKnownFileType = text.xcconfig; name = Release.xcconfig; path = Flutter/Release.xcconfig; sourceTree = ""; }; - 9740EEB21CF90195004384FC /* Debug.xcconfig */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.xcconfig; name = Debug.xcconfig; path = Flutter/Debug.xcconfig; sourceTree = ""; }; - 9740EEB31CF90195004384FC /* Generated.xcconfig */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.xcconfig; name = Generated.xcconfig; path = Flutter/Generated.xcconfig; sourceTree = ""; }; - 97C146EE1CF9000F007C117D /* Runner.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = Runner.app; sourceTree = BUILT_PRODUCTS_DIR; }; - 97C146FB1CF9000F007C117D /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/Main.storyboard; sourceTree = ""; }; - 97C146FD1CF9000F007C117D /* Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Assets.xcassets; sourceTree = ""; }; - 97C147001CF9000F007C117D /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/LaunchScreen.storyboard; sourceTree = ""; }; - 97C147021CF9000F007C117D /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; -/* End PBXFileReference section */ - -/* Begin PBXFrameworksBuildPhase section */ - 97C146EB1CF9000F007C117D /* Frameworks */ = { - isa = PBXFrameworksBuildPhase; - buildActionMask = 2147483647; - files = ( - ); - runOnlyForDeploymentPostprocessing = 0; - }; -/* End PBXFrameworksBuildPhase section */ - -/* Begin PBXGroup section */ - 9740EEB11CF90186004384FC /* Flutter */ = { - isa = PBXGroup; - children = ( - 3B3967151E833CAA004F5970 /* AppFrameworkInfo.plist */, - 9740EEB21CF90195004384FC /* Debug.xcconfig */, - 7AFA3C8E1D35360C0083082E /* Release.xcconfig */, - 9740EEB31CF90195004384FC /* Generated.xcconfig */, - ); - name = Flutter; - sourceTree = ""; - }; - 97C146E51CF9000F007C117D = { - isa = PBXGroup; - children = ( - 9740EEB11CF90186004384FC /* Flutter */, - 97C146F01CF9000F007C117D /* Runner */, - 97C146EF1CF9000F007C117D /* Products */, - ); - sourceTree = ""; - }; - 97C146EF1CF9000F007C117D /* Products */ = { - isa = PBXGroup; - children = ( - 97C146EE1CF9000F007C117D /* Runner.app */, - ); - name = Products; - sourceTree = ""; - }; - 97C146F01CF9000F007C117D /* Runner */ = { - isa = PBXGroup; - children = ( - 97C146FA1CF9000F007C117D /* Main.storyboard */, - 97C146FD1CF9000F007C117D /* Assets.xcassets */, - 97C146FF1CF9000F007C117D /* LaunchScreen.storyboard */, - 97C147021CF9000F007C117D /* Info.plist */, - 1498D2321E8E86230040F4C2 /* GeneratedPluginRegistrant.h */, - 1498D2331E8E89220040F4C2 /* GeneratedPluginRegistrant.m */, - 74858FAE1ED2DC5600515810 /* AppDelegate.swift */, - 74858FAD1ED2DC5600515810 /* Runner-Bridging-Header.h */, - ); - path = Runner; - sourceTree = ""; - }; -/* End PBXGroup section */ - -/* Begin PBXNativeTarget section */ - 97C146ED1CF9000F007C117D /* Runner */ = { - isa = PBXNativeTarget; - buildConfigurationList = 97C147051CF9000F007C117D /* Build configuration list for PBXNativeTarget "Runner" */; - buildPhases = ( - 9740EEB61CF901F6004384FC /* Run Script */, - 97C146EA1CF9000F007C117D /* Sources */, - 97C146EB1CF9000F007C117D /* Frameworks */, - 97C146EC1CF9000F007C117D /* Resources */, - 9705A1C41CF9048500538489 /* Embed Frameworks */, - 3B06AD1E1E4923F5004D2608 /* Thin Binary */, - ); - buildRules = ( - ); - dependencies = ( - ); - name = Runner; - productName = Runner; - productReference = 97C146EE1CF9000F007C117D /* Runner.app */; - productType = "com.apple.product-type.application"; - }; -/* End PBXNativeTarget section */ - -/* Begin PBXProject section */ - 97C146E61CF9000F007C117D /* Project object */ = { - isa = PBXProject; - attributes = { - LastUpgradeCheck = 1300; - ORGANIZATIONNAME = ""; - TargetAttributes = { - 97C146ED1CF9000F007C117D = { - CreatedOnToolsVersion = 7.3.1; - LastSwiftMigration = 1100; - }; - }; - }; - buildConfigurationList = 97C146E91CF9000F007C117D /* Build configuration list for PBXProject "Runner" */; - compatibilityVersion = "Xcode 9.3"; - developmentRegion = en; - hasScannedForEncodings = 0; - knownRegions = ( - en, - Base, - ); - mainGroup = 97C146E51CF9000F007C117D; - productRefGroup = 97C146EF1CF9000F007C117D /* Products */; - projectDirPath = ""; - projectRoot = ""; - targets = ( - 97C146ED1CF9000F007C117D /* Runner */, - ); - }; -/* End PBXProject section */ - -/* Begin PBXResourcesBuildPhase section */ - 97C146EC1CF9000F007C117D /* Resources */ = { - isa = PBXResourcesBuildPhase; - buildActionMask = 2147483647; - files = ( - 97C147011CF9000F007C117D /* LaunchScreen.storyboard in Resources */, - 3B3967161E833CAA004F5970 /* AppFrameworkInfo.plist in Resources */, - 97C146FE1CF9000F007C117D /* Assets.xcassets in Resources */, - 97C146FC1CF9000F007C117D /* Main.storyboard in Resources */, - ); - runOnlyForDeploymentPostprocessing = 0; - }; -/* End PBXResourcesBuildPhase section */ - -/* Begin PBXShellScriptBuildPhase section */ - 3B06AD1E1E4923F5004D2608 /* Thin Binary */ = { - isa = PBXShellScriptBuildPhase; - buildActionMask = 2147483647; - files = ( - ); - inputPaths = ( - ); - name = "Thin Binary"; - outputPaths = ( - ); - runOnlyForDeploymentPostprocessing = 0; - shellPath = /bin/sh; - shellScript = "/bin/sh \"$FLUTTER_ROOT/packages/flutter_tools/bin/xcode_backend.sh\" embed_and_thin"; - }; - 9740EEB61CF901F6004384FC /* Run Script */ = { - isa = PBXShellScriptBuildPhase; - buildActionMask = 2147483647; - files = ( - ); - inputPaths = ( - ); - name = "Run Script"; - outputPaths = ( - ); - runOnlyForDeploymentPostprocessing = 0; - shellPath = /bin/sh; - shellScript = "/bin/sh \"$FLUTTER_ROOT/packages/flutter_tools/bin/xcode_backend.sh\" build"; - }; -/* End PBXShellScriptBuildPhase section */ - -/* Begin PBXSourcesBuildPhase section */ - 97C146EA1CF9000F007C117D /* Sources */ = { - isa = PBXSourcesBuildPhase; - buildActionMask = 2147483647; - files = ( - 74858FAF1ED2DC5600515810 /* AppDelegate.swift in Sources */, - 1498D2341E8E89220040F4C2 /* GeneratedPluginRegistrant.m in Sources */, - ); - runOnlyForDeploymentPostprocessing = 0; - }; -/* End PBXSourcesBuildPhase section */ - -/* Begin PBXVariantGroup section */ - 97C146FA1CF9000F007C117D /* Main.storyboard */ = { - isa = PBXVariantGroup; - children = ( - 97C146FB1CF9000F007C117D /* Base */, - ); - name = Main.storyboard; - sourceTree = ""; - }; - 97C146FF1CF9000F007C117D /* LaunchScreen.storyboard */ = { - isa = PBXVariantGroup; - children = ( - 97C147001CF9000F007C117D /* Base */, - ); - name = LaunchScreen.storyboard; - sourceTree = ""; - }; -/* End PBXVariantGroup section */ - -/* Begin XCBuildConfiguration section */ - 249021D3217E4FDB00AE95B9 /* Profile */ = { - isa = XCBuildConfiguration; - buildSettings = { - ALWAYS_SEARCH_USER_PATHS = NO; - CLANG_ANALYZER_NONNULL = YES; - CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; - CLANG_CXX_LIBRARY = "libc++"; - CLANG_ENABLE_MODULES = YES; - CLANG_ENABLE_OBJC_ARC = YES; - CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; - CLANG_WARN_BOOL_CONVERSION = YES; - CLANG_WARN_COMMA = YES; - CLANG_WARN_CONSTANT_CONVERSION = YES; - CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; - CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; - CLANG_WARN_EMPTY_BODY = YES; - CLANG_WARN_ENUM_CONVERSION = YES; - CLANG_WARN_INFINITE_RECURSION = YES; - CLANG_WARN_INT_CONVERSION = YES; - CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; - CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES; - CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; - CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; - CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; - CLANG_WARN_STRICT_PROTOTYPES = YES; - CLANG_WARN_SUSPICIOUS_MOVE = YES; - CLANG_WARN_UNREACHABLE_CODE = YES; - CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; - "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; - COPY_PHASE_STRIP = NO; - DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; - ENABLE_NS_ASSERTIONS = NO; - ENABLE_STRICT_OBJC_MSGSEND = YES; - GCC_C_LANGUAGE_STANDARD = gnu99; - GCC_NO_COMMON_BLOCKS = YES; - GCC_WARN_64_TO_32_BIT_CONVERSION = YES; - GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; - GCC_WARN_UNDECLARED_SELECTOR = YES; - GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; - GCC_WARN_UNUSED_FUNCTION = YES; - GCC_WARN_UNUSED_VARIABLE = YES; - IPHONEOS_DEPLOYMENT_TARGET = 9.0; - MTL_ENABLE_DEBUG_INFO = NO; - SDKROOT = iphoneos; - SUPPORTED_PLATFORMS = iphoneos; - TARGETED_DEVICE_FAMILY = "1,2"; - VALIDATE_PRODUCT = YES; - }; - name = Profile; - }; - 249021D4217E4FDB00AE95B9 /* Profile */ = { - isa = XCBuildConfiguration; - baseConfigurationReference = 7AFA3C8E1D35360C0083082E /* Release.xcconfig */; - buildSettings = { - ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; - CLANG_ENABLE_MODULES = YES; - CURRENT_PROJECT_VERSION = "$(FLUTTER_BUILD_NUMBER)"; - ENABLE_BITCODE = NO; - INFOPLIST_FILE = Runner/Info.plist; - LD_RUNPATH_SEARCH_PATHS = ( - "$(inherited)", - "@executable_path/Frameworks", - ); - PRODUCT_BUNDLE_IDENTIFIER = com.example.demoMigaration; - PRODUCT_NAME = "$(TARGET_NAME)"; - SWIFT_OBJC_BRIDGING_HEADER = "Runner/Runner-Bridging-Header.h"; - SWIFT_VERSION = 5.0; - VERSIONING_SYSTEM = "apple-generic"; - }; - name = Profile; - }; - 97C147031CF9000F007C117D /* Debug */ = { - isa = XCBuildConfiguration; - buildSettings = { - ALWAYS_SEARCH_USER_PATHS = NO; - CLANG_ANALYZER_NONNULL = YES; - CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; - CLANG_CXX_LIBRARY = "libc++"; - CLANG_ENABLE_MODULES = YES; - CLANG_ENABLE_OBJC_ARC = YES; - CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; - CLANG_WARN_BOOL_CONVERSION = YES; - CLANG_WARN_COMMA = YES; - CLANG_WARN_CONSTANT_CONVERSION = YES; - CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; - CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; - CLANG_WARN_EMPTY_BODY = YES; - CLANG_WARN_ENUM_CONVERSION = YES; - CLANG_WARN_INFINITE_RECURSION = YES; - CLANG_WARN_INT_CONVERSION = YES; - CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; - CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES; - CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; - CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; - CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; - CLANG_WARN_STRICT_PROTOTYPES = YES; - CLANG_WARN_SUSPICIOUS_MOVE = YES; - CLANG_WARN_UNREACHABLE_CODE = YES; - CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; - "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; - COPY_PHASE_STRIP = NO; - DEBUG_INFORMATION_FORMAT = dwarf; - ENABLE_STRICT_OBJC_MSGSEND = YES; - ENABLE_TESTABILITY = YES; - GCC_C_LANGUAGE_STANDARD = gnu99; - GCC_DYNAMIC_NO_PIC = NO; - GCC_NO_COMMON_BLOCKS = YES; - GCC_OPTIMIZATION_LEVEL = 0; - GCC_PREPROCESSOR_DEFINITIONS = ( - "DEBUG=1", - "$(inherited)", - ); - GCC_WARN_64_TO_32_BIT_CONVERSION = YES; - GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; - GCC_WARN_UNDECLARED_SELECTOR = YES; - GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; - GCC_WARN_UNUSED_FUNCTION = YES; - GCC_WARN_UNUSED_VARIABLE = YES; - IPHONEOS_DEPLOYMENT_TARGET = 9.0; - MTL_ENABLE_DEBUG_INFO = YES; - ONLY_ACTIVE_ARCH = YES; - SDKROOT = iphoneos; - TARGETED_DEVICE_FAMILY = "1,2"; - }; - name = Debug; - }; - 97C147041CF9000F007C117D /* Release */ = { - isa = XCBuildConfiguration; - buildSettings = { - ALWAYS_SEARCH_USER_PATHS = NO; - CLANG_ANALYZER_NONNULL = YES; - CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; - CLANG_CXX_LIBRARY = "libc++"; - CLANG_ENABLE_MODULES = YES; - CLANG_ENABLE_OBJC_ARC = YES; - CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; - CLANG_WARN_BOOL_CONVERSION = YES; - CLANG_WARN_COMMA = YES; - CLANG_WARN_CONSTANT_CONVERSION = YES; - CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; - CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; - CLANG_WARN_EMPTY_BODY = YES; - CLANG_WARN_ENUM_CONVERSION = YES; - CLANG_WARN_INFINITE_RECURSION = YES; - CLANG_WARN_INT_CONVERSION = YES; - CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; - CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES; - CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; - CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; - CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; - CLANG_WARN_STRICT_PROTOTYPES = YES; - CLANG_WARN_SUSPICIOUS_MOVE = YES; - CLANG_WARN_UNREACHABLE_CODE = YES; - CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; - "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; - COPY_PHASE_STRIP = NO; - DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; - ENABLE_NS_ASSERTIONS = NO; - ENABLE_STRICT_OBJC_MSGSEND = YES; - GCC_C_LANGUAGE_STANDARD = gnu99; - GCC_NO_COMMON_BLOCKS = YES; - GCC_WARN_64_TO_32_BIT_CONVERSION = YES; - GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; - GCC_WARN_UNDECLARED_SELECTOR = YES; - GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; - GCC_WARN_UNUSED_FUNCTION = YES; - GCC_WARN_UNUSED_VARIABLE = YES; - IPHONEOS_DEPLOYMENT_TARGET = 9.0; - MTL_ENABLE_DEBUG_INFO = NO; - SDKROOT = iphoneos; - SUPPORTED_PLATFORMS = iphoneos; - SWIFT_COMPILATION_MODE = wholemodule; - SWIFT_OPTIMIZATION_LEVEL = "-O"; - TARGETED_DEVICE_FAMILY = "1,2"; - VALIDATE_PRODUCT = YES; - }; - name = Release; - }; - 97C147061CF9000F007C117D /* Debug */ = { - isa = XCBuildConfiguration; - baseConfigurationReference = 9740EEB21CF90195004384FC /* Debug.xcconfig */; - buildSettings = { - ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; - CLANG_ENABLE_MODULES = YES; - CURRENT_PROJECT_VERSION = "$(FLUTTER_BUILD_NUMBER)"; - ENABLE_BITCODE = NO; - INFOPLIST_FILE = Runner/Info.plist; - LD_RUNPATH_SEARCH_PATHS = ( - "$(inherited)", - "@executable_path/Frameworks", - ); - PRODUCT_BUNDLE_IDENTIFIER = com.example.demoMigaration; - PRODUCT_NAME = "$(TARGET_NAME)"; - SWIFT_OBJC_BRIDGING_HEADER = "Runner/Runner-Bridging-Header.h"; - SWIFT_OPTIMIZATION_LEVEL = "-Onone"; - SWIFT_VERSION = 5.0; - VERSIONING_SYSTEM = "apple-generic"; - }; - name = Debug; - }; - 97C147071CF9000F007C117D /* Release */ = { - isa = XCBuildConfiguration; - baseConfigurationReference = 7AFA3C8E1D35360C0083082E /* Release.xcconfig */; - buildSettings = { - ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; - CLANG_ENABLE_MODULES = YES; - CURRENT_PROJECT_VERSION = "$(FLUTTER_BUILD_NUMBER)"; - ENABLE_BITCODE = NO; - INFOPLIST_FILE = Runner/Info.plist; - LD_RUNPATH_SEARCH_PATHS = ( - "$(inherited)", - "@executable_path/Frameworks", - ); - PRODUCT_BUNDLE_IDENTIFIER = com.example.demoMigaration; - PRODUCT_NAME = "$(TARGET_NAME)"; - SWIFT_OBJC_BRIDGING_HEADER = "Runner/Runner-Bridging-Header.h"; - SWIFT_VERSION = 5.0; - VERSIONING_SYSTEM = "apple-generic"; - }; - name = Release; - }; -/* End XCBuildConfiguration section */ - -/* Begin XCConfigurationList section */ - 97C146E91CF9000F007C117D /* Build configuration list for PBXProject "Runner" */ = { - isa = XCConfigurationList; - buildConfigurations = ( - 97C147031CF9000F007C117D /* Debug */, - 97C147041CF9000F007C117D /* Release */, - 249021D3217E4FDB00AE95B9 /* Profile */, - ); - defaultConfigurationIsVisible = 0; - defaultConfigurationName = Release; - }; - 97C147051CF9000F007C117D /* Build configuration list for PBXNativeTarget "Runner" */ = { - isa = XCConfigurationList; - buildConfigurations = ( - 97C147061CF9000F007C117D /* Debug */, - 97C147071CF9000F007C117D /* Release */, - 249021D4217E4FDB00AE95B9 /* Profile */, - ); - defaultConfigurationIsVisible = 0; - defaultConfigurationName = Release; - }; -/* End XCConfigurationList section */ - }; - rootObject = 97C146E61CF9000F007C117D /* Project object */; -} diff --git a/packages/graphql_flutter/example/ios/Runner.xcodeproj/project.xcworkspace/contents.xcworkspacedata b/packages/graphql_flutter/example/ios/Runner.xcodeproj/project.xcworkspace/contents.xcworkspacedata deleted file mode 100644 index 919434a62..000000000 --- a/packages/graphql_flutter/example/ios/Runner.xcodeproj/project.xcworkspace/contents.xcworkspacedata +++ /dev/null @@ -1,7 +0,0 @@ - - - - - diff --git a/packages/graphql_flutter/example/ios/Runner.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist b/packages/graphql_flutter/example/ios/Runner.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist deleted file mode 100644 index 18d981003..000000000 --- a/packages/graphql_flutter/example/ios/Runner.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist +++ /dev/null @@ -1,8 +0,0 @@ - - - - - IDEDidComputeMac32BitWarning - - - diff --git a/packages/graphql_flutter/example/ios/Runner.xcodeproj/project.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings b/packages/graphql_flutter/example/ios/Runner.xcodeproj/project.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings deleted file mode 100644 index f9b0d7c5e..000000000 --- a/packages/graphql_flutter/example/ios/Runner.xcodeproj/project.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings +++ /dev/null @@ -1,8 +0,0 @@ - - - - - PreviewsEnabled - - - diff --git a/packages/graphql_flutter/example/ios/Runner.xcodeproj/xcshareddata/xcschemes/Runner.xcscheme b/packages/graphql_flutter/example/ios/Runner.xcodeproj/xcshareddata/xcschemes/Runner.xcscheme deleted file mode 100644 index c87d15a33..000000000 --- a/packages/graphql_flutter/example/ios/Runner.xcodeproj/xcshareddata/xcschemes/Runner.xcscheme +++ /dev/null @@ -1,87 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/packages/graphql_flutter/example/ios/Runner.xcworkspace/contents.xcworkspacedata b/packages/graphql_flutter/example/ios/Runner.xcworkspace/contents.xcworkspacedata deleted file mode 100644 index 1d526a16e..000000000 --- a/packages/graphql_flutter/example/ios/Runner.xcworkspace/contents.xcworkspacedata +++ /dev/null @@ -1,7 +0,0 @@ - - - - - diff --git a/packages/graphql_flutter/example/ios/Runner.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist b/packages/graphql_flutter/example/ios/Runner.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist deleted file mode 100644 index 18d981003..000000000 --- a/packages/graphql_flutter/example/ios/Runner.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist +++ /dev/null @@ -1,8 +0,0 @@ - - - - - IDEDidComputeMac32BitWarning - - - diff --git a/packages/graphql_flutter/example/ios/Runner.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings b/packages/graphql_flutter/example/ios/Runner.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings deleted file mode 100644 index f9b0d7c5e..000000000 --- a/packages/graphql_flutter/example/ios/Runner.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings +++ /dev/null @@ -1,8 +0,0 @@ - - - - - PreviewsEnabled - - - diff --git a/packages/graphql_flutter/example/ios/Runner/AppDelegate.swift b/packages/graphql_flutter/example/ios/Runner/AppDelegate.swift deleted file mode 100644 index 70693e4a8..000000000 --- a/packages/graphql_flutter/example/ios/Runner/AppDelegate.swift +++ /dev/null @@ -1,13 +0,0 @@ -import UIKit -import Flutter - -@UIApplicationMain -@objc class AppDelegate: FlutterAppDelegate { - override func application( - _ application: UIApplication, - didFinishLaunchingWithOptions launchOptions: [UIApplication.LaunchOptionsKey: Any]? - ) -> Bool { - GeneratedPluginRegistrant.register(with: self) - return super.application(application, didFinishLaunchingWithOptions: launchOptions) - } -} diff --git a/packages/graphql_flutter/example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Contents.json b/packages/graphql_flutter/example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Contents.json deleted file mode 100644 index d36b1fab2..000000000 --- a/packages/graphql_flutter/example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Contents.json +++ /dev/null @@ -1,122 +0,0 @@ -{ - "images" : [ - { - "size" : "20x20", - "idiom" : "iphone", - "filename" : "Icon-App-20x20@2x.png", - "scale" : "2x" - }, - { - "size" : "20x20", - "idiom" : "iphone", - "filename" : "Icon-App-20x20@3x.png", - "scale" : "3x" - }, - { - "size" : "29x29", - "idiom" : "iphone", - "filename" : "Icon-App-29x29@1x.png", - "scale" : "1x" - }, - { - "size" : "29x29", - "idiom" : "iphone", - "filename" : "Icon-App-29x29@2x.png", - "scale" : "2x" - }, - { - "size" : "29x29", - "idiom" : "iphone", - "filename" : "Icon-App-29x29@3x.png", - "scale" : "3x" - }, - { - "size" : "40x40", - "idiom" : "iphone", - "filename" : "Icon-App-40x40@2x.png", - "scale" : "2x" - }, - { - "size" : "40x40", - "idiom" : "iphone", - "filename" : "Icon-App-40x40@3x.png", - "scale" : "3x" - }, - { - "size" : "60x60", - "idiom" : "iphone", - "filename" : "Icon-App-60x60@2x.png", - "scale" : "2x" - }, - { - "size" : "60x60", - "idiom" : "iphone", - "filename" : "Icon-App-60x60@3x.png", - "scale" : "3x" - }, - { - "size" : "20x20", - "idiom" : "ipad", - "filename" : "Icon-App-20x20@1x.png", - "scale" : "1x" - }, - { - "size" : "20x20", - "idiom" : "ipad", - "filename" : "Icon-App-20x20@2x.png", - "scale" : "2x" - }, - { - "size" : "29x29", - "idiom" : "ipad", - "filename" : "Icon-App-29x29@1x.png", - "scale" : "1x" - }, - { - "size" : "29x29", - "idiom" : "ipad", - "filename" : "Icon-App-29x29@2x.png", - "scale" : "2x" - }, - { - "size" : "40x40", - "idiom" : "ipad", - "filename" : "Icon-App-40x40@1x.png", - "scale" : "1x" - }, - { - "size" : "40x40", - "idiom" : "ipad", - "filename" : "Icon-App-40x40@2x.png", - "scale" : "2x" - }, - { - "size" : "76x76", - "idiom" : "ipad", - "filename" : "Icon-App-76x76@1x.png", - "scale" : "1x" - }, - { - "size" : "76x76", - "idiom" : "ipad", - "filename" : "Icon-App-76x76@2x.png", - "scale" : "2x" - }, - { - "size" : "83.5x83.5", - "idiom" : "ipad", - "filename" : "Icon-App-83.5x83.5@2x.png", - "scale" : "2x" - }, - { - "size" : "1024x1024", - "idiom" : "ios-marketing", - "filename" : "Icon-App-1024x1024@1x.png", - "scale" : "1x" - } - ], - "info" : { - "version" : 1, - "author" : "xcode" - } -} diff --git a/packages/graphql_flutter/example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-1024x1024@1x.png b/packages/graphql_flutter/example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-1024x1024@1x.png deleted file mode 100644 index dc9ada472..000000000 Binary files a/packages/graphql_flutter/example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-1024x1024@1x.png and /dev/null differ diff --git a/packages/graphql_flutter/example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@1x.png b/packages/graphql_flutter/example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@1x.png deleted file mode 100644 index 28c6bf030..000000000 Binary files a/packages/graphql_flutter/example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@1x.png and /dev/null differ diff --git a/packages/graphql_flutter/example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@2x.png b/packages/graphql_flutter/example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@2x.png deleted file mode 100644 index 2ccbfd967..000000000 Binary files a/packages/graphql_flutter/example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@2x.png and /dev/null differ diff --git a/packages/graphql_flutter/example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@3x.png b/packages/graphql_flutter/example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@3x.png deleted file mode 100644 index f091b6b0b..000000000 Binary files a/packages/graphql_flutter/example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@3x.png and /dev/null differ diff --git a/packages/graphql_flutter/example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@1x.png b/packages/graphql_flutter/example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@1x.png deleted file mode 100644 index 4cde12118..000000000 Binary files a/packages/graphql_flutter/example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@1x.png and /dev/null differ diff --git a/packages/graphql_flutter/example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@2x.png b/packages/graphql_flutter/example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@2x.png deleted file mode 100644 index d0ef06e7e..000000000 Binary files a/packages/graphql_flutter/example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@2x.png and /dev/null differ diff --git a/packages/graphql_flutter/example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@3x.png b/packages/graphql_flutter/example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@3x.png deleted file mode 100644 index dcdc2306c..000000000 Binary files a/packages/graphql_flutter/example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@3x.png and /dev/null differ diff --git a/packages/graphql_flutter/example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@1x.png b/packages/graphql_flutter/example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@1x.png deleted file mode 100644 index 2ccbfd967..000000000 Binary files a/packages/graphql_flutter/example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@1x.png and /dev/null differ diff --git a/packages/graphql_flutter/example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@2x.png b/packages/graphql_flutter/example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@2x.png deleted file mode 100644 index c8f9ed8f5..000000000 Binary files a/packages/graphql_flutter/example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@2x.png and /dev/null differ diff --git a/packages/graphql_flutter/example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@3x.png b/packages/graphql_flutter/example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@3x.png deleted file mode 100644 index a6d6b8609..000000000 Binary files a/packages/graphql_flutter/example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@3x.png and /dev/null differ diff --git a/packages/graphql_flutter/example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@2x.png b/packages/graphql_flutter/example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@2x.png deleted file mode 100644 index a6d6b8609..000000000 Binary files a/packages/graphql_flutter/example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@2x.png and /dev/null differ diff --git a/packages/graphql_flutter/example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@3x.png b/packages/graphql_flutter/example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@3x.png deleted file mode 100644 index 75b2d164a..000000000 Binary files a/packages/graphql_flutter/example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@3x.png and /dev/null differ diff --git a/packages/graphql_flutter/example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@1x.png b/packages/graphql_flutter/example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@1x.png deleted file mode 100644 index c4df70d39..000000000 Binary files a/packages/graphql_flutter/example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@1x.png and /dev/null differ diff --git a/packages/graphql_flutter/example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@2x.png b/packages/graphql_flutter/example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@2x.png deleted file mode 100644 index 6a84f41e1..000000000 Binary files a/packages/graphql_flutter/example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@2x.png and /dev/null differ diff --git a/packages/graphql_flutter/example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-83.5x83.5@2x.png b/packages/graphql_flutter/example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-83.5x83.5@2x.png deleted file mode 100644 index d0e1f5853..000000000 Binary files a/packages/graphql_flutter/example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-83.5x83.5@2x.png and /dev/null differ diff --git a/packages/graphql_flutter/example/ios/Runner/Assets.xcassets/LaunchImage.imageset/Contents.json b/packages/graphql_flutter/example/ios/Runner/Assets.xcassets/LaunchImage.imageset/Contents.json deleted file mode 100644 index 0bedcf2fd..000000000 --- a/packages/graphql_flutter/example/ios/Runner/Assets.xcassets/LaunchImage.imageset/Contents.json +++ /dev/null @@ -1,23 +0,0 @@ -{ - "images" : [ - { - "idiom" : "universal", - "filename" : "LaunchImage.png", - "scale" : "1x" - }, - { - "idiom" : "universal", - "filename" : "LaunchImage@2x.png", - "scale" : "2x" - }, - { - "idiom" : "universal", - "filename" : "LaunchImage@3x.png", - "scale" : "3x" - } - ], - "info" : { - "version" : 1, - "author" : "xcode" - } -} diff --git a/packages/graphql_flutter/example/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage.png b/packages/graphql_flutter/example/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage.png deleted file mode 100644 index 9da19eaca..000000000 Binary files a/packages/graphql_flutter/example/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage.png and /dev/null differ diff --git a/packages/graphql_flutter/example/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@2x.png b/packages/graphql_flutter/example/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@2x.png deleted file mode 100644 index 9da19eaca..000000000 Binary files a/packages/graphql_flutter/example/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@2x.png and /dev/null differ diff --git a/packages/graphql_flutter/example/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@3x.png b/packages/graphql_flutter/example/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@3x.png deleted file mode 100644 index 9da19eaca..000000000 Binary files a/packages/graphql_flutter/example/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@3x.png and /dev/null differ diff --git a/packages/graphql_flutter/example/ios/Runner/Assets.xcassets/LaunchImage.imageset/README.md b/packages/graphql_flutter/example/ios/Runner/Assets.xcassets/LaunchImage.imageset/README.md deleted file mode 100644 index 89c2725b7..000000000 --- a/packages/graphql_flutter/example/ios/Runner/Assets.xcassets/LaunchImage.imageset/README.md +++ /dev/null @@ -1,5 +0,0 @@ -# Launch Screen Assets - -You can customize the launch screen with your own desired assets by replacing the image files in this directory. - -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. \ No newline at end of file diff --git a/packages/graphql_flutter/example/ios/Runner/Base.lproj/LaunchScreen.storyboard b/packages/graphql_flutter/example/ios/Runner/Base.lproj/LaunchScreen.storyboard deleted file mode 100644 index f2e259c7c..000000000 --- a/packages/graphql_flutter/example/ios/Runner/Base.lproj/LaunchScreen.storyboard +++ /dev/null @@ -1,37 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/packages/graphql_flutter/example/ios/Runner/Base.lproj/Main.storyboard b/packages/graphql_flutter/example/ios/Runner/Base.lproj/Main.storyboard deleted file mode 100644 index f3c28516f..000000000 --- a/packages/graphql_flutter/example/ios/Runner/Base.lproj/Main.storyboard +++ /dev/null @@ -1,26 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/packages/graphql_flutter/example/ios/Runner/Info.plist b/packages/graphql_flutter/example/ios/Runner/Info.plist deleted file mode 100644 index a2a66afa5..000000000 --- a/packages/graphql_flutter/example/ios/Runner/Info.plist +++ /dev/null @@ -1,47 +0,0 @@ - - - - - CFBundleDevelopmentRegion - $(DEVELOPMENT_LANGUAGE) - CFBundleDisplayName - Demo Migaration - CFBundleExecutable - $(EXECUTABLE_NAME) - CFBundleIdentifier - $(PRODUCT_BUNDLE_IDENTIFIER) - CFBundleInfoDictionaryVersion - 6.0 - CFBundleName - demo_migaration - CFBundlePackageType - APPL - CFBundleShortVersionString - $(FLUTTER_BUILD_NAME) - CFBundleSignature - ???? - CFBundleVersion - $(FLUTTER_BUILD_NUMBER) - LSRequiresIPhoneOS - - UILaunchStoryboardName - LaunchScreen - UIMainStoryboardFile - Main - UISupportedInterfaceOrientations - - UIInterfaceOrientationPortrait - UIInterfaceOrientationLandscapeLeft - UIInterfaceOrientationLandscapeRight - - UISupportedInterfaceOrientations~ipad - - UIInterfaceOrientationPortrait - UIInterfaceOrientationPortraitUpsideDown - UIInterfaceOrientationLandscapeLeft - UIInterfaceOrientationLandscapeRight - - UIViewControllerBasedStatusBarAppearance - - - diff --git a/packages/graphql_flutter/example/ios/Runner/Runner-Bridging-Header.h b/packages/graphql_flutter/example/ios/Runner/Runner-Bridging-Header.h deleted file mode 100644 index 308a2a560..000000000 --- a/packages/graphql_flutter/example/ios/Runner/Runner-Bridging-Header.h +++ /dev/null @@ -1 +0,0 @@ -#import "GeneratedPluginRegistrant.h" diff --git a/packages/graphql_flutter/example/lib/fetchmore/main.dart b/packages/graphql_flutter/example/lib/fetchmore/main.dart deleted file mode 100644 index ea9863fb9..000000000 --- a/packages/graphql_flutter/example/lib/fetchmore/main.dart +++ /dev/null @@ -1,175 +0,0 @@ -import 'package:flutter/material.dart'; -import 'package:graphql_flutter/graphql_flutter.dart'; - -import '../graphql_operation/queries/readRepositories.dart' as queries; - -// to run the example, replace with your GitHub token in ../local.dart -import '../local.dart'; - -class FetchMoreWidgetScreen extends StatelessWidget { - const FetchMoreWidgetScreen() : super(); - - @override - Widget build(BuildContext context) { - final httpLink = - HttpLink('https://api.github.com/graphql', defaultHeaders: { - 'Authorization': 'Bearer $YOUR_PERSONAL_ACCESS_TOKEN', - }); - - final client = ValueNotifier( - GraphQLClient( - cache: GraphQLCache(), - link: httpLink, - ), - ); - - return GraphQLProvider( - client: client, - child: const CacheProvider( - child: MyHomePage(title: 'GraphQL Pagination'), - ), - ); - } -} - -class MyHomePage extends StatefulWidget { - const MyHomePage({ - Key? key, - this.title, - }) : super(key: key); - - final String? title; - - @override - _MyHomePageState createState() => _MyHomePageState(); -} - -class _MyHomePageState extends State { - String _searchQuery = 'flutter'; - int nRepositories = 10; - - void changeQuery(String query) { - setState(() { - print(query); - _searchQuery = query; - }); - } - - @override - Widget build(BuildContext context) { - return Scaffold( - appBar: AppBar( - title: Text(widget.title!), - ), - body: Container( - padding: const EdgeInsets.symmetric(horizontal: 8.0), - child: Column( - mainAxisAlignment: MainAxisAlignment.start, - mainAxisSize: MainAxisSize.max, - children: [ - TextField( - decoration: const InputDecoration( - labelText: 'Search Query', - ), - keyboardType: TextInputType.text, - onSubmitted: changeQuery, - ), - Query( - options: QueryOptions( - document: gql(queries.searchRepositories), - variables: { - 'nRepositories': nRepositories, - 'query': _searchQuery, - // set cursor to null so as to start at the beginning - 'cursor': null - }, - //pollInterval: 10, - ), - builder: (QueryResult result, {refetch, FetchMore? fetchMore}) { - if (result.hasException) { - return Text(result.exception.toString()); - } - - if (result.isLoading && result.data == null) { - return const Center( - child: CircularProgressIndicator(), - ); - } - - if (result.data == null && !result.hasException) { - return const Text( - 'Both data and errors are null, this is a known bug after refactoring, you might have forgotten to set Github token'); - } - - // result.data can be either a [List] or a [Map] - final repositories = - (result.data!['search']['nodes'] as List); - - final Map pageInfo = result.data!['search']['pageInfo']; - final String? fetchMoreCursor = pageInfo['endCursor']; - final opts = FetchMoreOptions( - variables: {'cursor': fetchMoreCursor}, - updateQuery: (previousResultData, fetchMoreResultData) { - // this is where you combine your previous data and response - // in this case, we want to display previous repos plus next repos - // so, we combine data in both into a single list of repos - final repos = [ - ...previousResultData!['search']['nodes'] - as List, - ...fetchMoreResultData!['search']['nodes'] - as List - ]; - - // to avoid alot of work, lets just update the list of repos in returned - // data with new data, this also ensure we have the endCursor already set - // correctlty - fetchMoreResultData['search']['nodes'] = repos; - - return fetchMoreResultData; - }, - ); - - return Expanded( - child: ListView( - children: [ - for (var repository in repositories) - ListTile( - leading: (repository['viewerHasStarred'] as bool) - ? const Icon( - Icons.star, - color: Colors.amber, - ) - : const Icon(Icons.star_border), - title: Text(repository['name'] as String), - ), - if (result.isLoading) - Row( - mainAxisAlignment: MainAxisAlignment.center, - children: [ - CircularProgressIndicator(), - ], - ), - Text('note: this example has no mutations', - style: Theme.of(context).textTheme.caption), - ElevatedButton( - onPressed: () { - fetchMore!(opts); - }, - child: Row( - mainAxisAlignment: MainAxisAlignment.center, - children: [ - Text('Load More'), - ], - ), - ) - ], - ), - ); - }, - ), - ], - ), - ), - ); - } -} diff --git a/packages/graphql_flutter/example/lib/generated_plugin_registrant.dart b/packages/graphql_flutter/example/lib/generated_plugin_registrant.dart deleted file mode 100644 index 3c36ef502..000000000 --- a/packages/graphql_flutter/example/lib/generated_plugin_registrant.dart +++ /dev/null @@ -1,16 +0,0 @@ -// -// Generated file. Do not edit. -// - -// ignore_for_file: directives_ordering -// ignore_for_file: lines_longer_than_80_chars - -import 'package:connectivity_plus_web/connectivity_plus_web.dart'; - -import 'package:flutter_web_plugins/flutter_web_plugins.dart'; - -// ignore: public_member_api_docs -void registerPlugins(Registrar registrar) { - ConnectivityPlusPlugin.registerWith(registrar); - registrar.registerMessageHandler(); -} diff --git a/packages/graphql_flutter/example/lib/graphql_bloc/bloc.dart b/packages/graphql_flutter/example/lib/graphql_bloc/bloc.dart deleted file mode 100644 index 395e3bcf6..000000000 --- a/packages/graphql_flutter/example/lib/graphql_bloc/bloc.dart +++ /dev/null @@ -1,106 +0,0 @@ -import 'package:graphql_flutter/graphql_flutter.dart'; -import 'package:rxdart/rxdart.dart'; - -import '../graphql_operation/mutations/mutations.dart' as mutations; -import '../graphql_operation/queries/readRepositories.dart' as queries; - -// to run the example, replace with your GitHub token in ../local.dart -import '../local.dart'; - -class Repo { - const Repo({this.id, this.name, this.viewerHasStarred}); - final String? id; - final String? name; - final bool? viewerHasStarred; -} - -class Bloc { - Bloc() { - _queryRepo(); - _updateNumberOfRepo.listen((int n) async => _queryRepo(nRepositories: n)); - _toggleStarSubject.listen((Repo t) async { - _toggleStarLoadingSubject.add(t.id); - // @todo handle error - final _ = await _mutateToggleStar(t); - - _repoSubject.add(_repoSubject.value!.map((Repo e) { - if (e.id != t.id) { - return e; - } - return Repo( - id: t.id, name: t.name, viewerHasStarred: !t.viewerHasStarred!); - }).toList()); - _toggleStarLoadingSubject.add(null); - }); - } - - final BehaviorSubject?> _repoSubject = - BehaviorSubject?>(); - Stream?> get repoStream => _repoSubject.stream; - - final ReplaySubject _toggleStarSubject = ReplaySubject(); - Sink get toggleStarSink => _toggleStarSubject; - - /// The repo currently loading, if any - final BehaviorSubject _toggleStarLoadingSubject = - BehaviorSubject(); - - Stream get toggleStarLoadingStream => - _toggleStarLoadingSubject.stream; - - final BehaviorSubject _updateNumberOfRepo = BehaviorSubject(); - - Sink get updateNumberOfRepoSink => _updateNumberOfRepo; - - final GraphQLClient _client = GraphQLClient( - cache: GraphQLCache(), - link: HttpLink('https://api.github.com/graphql', defaultHeaders: { - 'Authorization': 'Bearer $YOUR_PERSONAL_ACCESS_TOKEN', - }), - ); - - Future _mutateToggleStar(Repo repo) async { - final _options = MutationOptions( - document: gql( - repo.viewerHasStarred! ? mutations.removeStar : mutations.addStar), - variables: { - 'starrableId': repo.id, - }, - ); - - final result = await _client.mutate(_options); - return result; - } - - Future _queryRepo({int nRepositories = 50}) async { - // null is loading - _repoSubject.add(null); - final _options = WatchQueryOptions( - document: gql(queries.readRepositories), - variables: { - 'nRepositories': nRepositories, - }, - pollInterval: Duration(seconds: 4), - fetchResults: true, - ); - - final result = await _client.query(_options); - - if (result.hasException) { - _repoSubject.addError(result.exception!); - return; - } - - // result.data can be either a [List] or a [Map] - final repositories = - result.data!['viewer']['repositories']['nodes'] as List; - - _repoSubject.add(repositories - .map((dynamic e) => Repo( - id: e['id'] as String?, - name: e['name'] as String?, - viewerHasStarred: e['viewerHasStarred'] as bool?, - )) - .toList()); - } -} diff --git a/packages/graphql_flutter/example/lib/graphql_bloc/main.dart b/packages/graphql_flutter/example/lib/graphql_bloc/main.dart deleted file mode 100644 index c6e3eaada..000000000 --- a/packages/graphql_flutter/example/lib/graphql_bloc/main.dart +++ /dev/null @@ -1,120 +0,0 @@ -import 'package:flutter/material.dart'; - -import 'bloc.dart' show Bloc, Repo; - -class GraphQLBlocPatternScreen extends StatefulWidget { - GraphQLBlocPatternScreen({ - Key? key, - this.title = 'GraphQL Widget', - }) : bloc = Bloc(), - super(key: key); - - final String title; - final Bloc bloc; - - @override - _MyHomePageState createState() => _MyHomePageState(bloc); -} - -class _MyHomePageState extends State { - _MyHomePageState(this.bloc); - final Bloc bloc; - - @override - Widget build(BuildContext context) { - return Scaffold( - appBar: AppBar( - title: Text(widget.title), - ), - body: Container( - padding: const EdgeInsets.symmetric(horizontal: 8.0), - child: Column( - mainAxisAlignment: MainAxisAlignment.start, - mainAxisSize: MainAxisSize.max, - children: [ - TextField( - decoration: const InputDecoration( - labelText: 'Number of repositories (default 50)', - ), - keyboardType: TextInputType.number, - onChanged: (String n) => - bloc.updateNumberOfRepoSink.add(int.parse(n)), - ), - StreamBuilder?>( - stream: bloc.repoStream, - builder: - (BuildContext context, AsyncSnapshot?> snapshot) { - if (snapshot.hasError) { - return Text('\nErrors: ${snapshot.error.toString()}'); - } - if (snapshot.data == null) { - return const Center( - child: CircularProgressIndicator(), - ); - } - - final repositories = snapshot.data!; - - return Expanded( - child: ListView.builder( - itemCount: repositories.length, - itemBuilder: (BuildContext context, int index) => - StarrableRepository( - repository: repositories[index], bloc: bloc), - ), - ); - }, - ), - ], - ), - ), - ); - } -} - -class StarrableRepository extends StatelessWidget { - const StarrableRepository({ - Key? key, - required this.repository, - required this.bloc, - }) : super(key: key); - - final Bloc bloc; - final Repo repository; - - Map? extractRepositoryData(Map data) { - final action = data['action'] as Map?; - - if (action == null) { - return null; - } - - return action['starrable'] as Map?; - } - - bool? get viewerHasStarred => repository.viewerHasStarred; - - @override - Widget build(BuildContext context) { - return StreamBuilder( - stream: bloc.toggleStarLoadingStream, - initialData: null, - builder: (BuildContext context, AsyncSnapshot result) { - final loading = repository.id == result.data; - return ListTile( - leading: viewerHasStarred! - ? const Icon( - Icons.star, - color: Colors.amber, - ) - : const Icon(Icons.star_border), - trailing: loading ? const CircularProgressIndicator() : null, - title: Text(repository.name!), - onTap: () { - bloc.toggleStarSink.add(repository); - }, - ); - }, - ); - } -} diff --git a/packages/graphql_flutter/example/lib/graphql_operation/mutations/addStar.dart b/packages/graphql_flutter/example/lib/graphql_operation/mutations/addStar.dart deleted file mode 100644 index e44616e05..000000000 --- a/packages/graphql_flutter/example/lib/graphql_operation/mutations/addStar.dart +++ /dev/null @@ -1,11 +0,0 @@ -const String addStar = r''' - mutation AddStar($starrableId: ID!) { - action: addStar(input: {starrableId: $starrableId}) { - starrable { - __typename - id - viewerHasStarred - } - } - } -'''; diff --git a/packages/graphql_flutter/example/lib/graphql_operation/mutations/mutations.dart b/packages/graphql_flutter/example/lib/graphql_operation/mutations/mutations.dart deleted file mode 100644 index 19ec2b51e..000000000 --- a/packages/graphql_flutter/example/lib/graphql_operation/mutations/mutations.dart +++ /dev/null @@ -1,2 +0,0 @@ -export './addStar.dart'; -export './removeStar.dart'; diff --git a/packages/graphql_flutter/example/lib/graphql_operation/mutations/removeStar.dart b/packages/graphql_flutter/example/lib/graphql_operation/mutations/removeStar.dart deleted file mode 100644 index 9d08b6594..000000000 --- a/packages/graphql_flutter/example/lib/graphql_operation/mutations/removeStar.dart +++ /dev/null @@ -1,11 +0,0 @@ -const String removeStar = r''' - mutation RemoveStar($starrableId: ID!) { - action: removeStar(input: {starrableId: $starrableId}) { - starrable { - __typename - id - viewerHasStarred - } - } - } -'''; diff --git a/packages/graphql_flutter/example/lib/graphql_operation/queries/readRepositories.dart b/packages/graphql_flutter/example/lib/graphql_operation/queries/readRepositories.dart deleted file mode 100644 index 225384e58..000000000 --- a/packages/graphql_flutter/example/lib/graphql_operation/queries/readRepositories.dart +++ /dev/null @@ -1,50 +0,0 @@ -const String readRepositories = r''' - query ReadRepositories($nRepositories: Int!) { - viewer { - repositories(last: $nRepositories) { - nodes { - __typename - id - name - viewerHasStarred - } - } - } - } -'''; - -const String searchRepositories = r''' - query SearchRepositories($nRepositories: Int!, $query: String!, $cursor: String) { - search(last: $nRepositories, query: $query, type: REPOSITORY, after: $cursor) { - nodes { - __typename - ... on Repository { - name - shortDescriptionHTML - viewerHasStarred - stargazers { - totalCount - } - forks { - totalCount - } - updatedAt - } - } - pageInfo { - endCursor - hasNextPage - } - } - } -'''; - -const String testSubscription = r''' - subscription test { - deviceChanged(id: 2) { - __typename - id - name - } - } -'''; diff --git a/packages/graphql_flutter/example/lib/graphql_widget/main.dart b/packages/graphql_flutter/example/lib/graphql_widget/main.dart deleted file mode 100644 index 70a42e154..000000000 --- a/packages/graphql_flutter/example/lib/graphql_widget/main.dart +++ /dev/null @@ -1,286 +0,0 @@ -import 'package:flutter/material.dart'; -import 'package:graphql_flutter/graphql_flutter.dart'; - -import '../graphql_operation/mutations/mutations.dart' as mutations; -import '../graphql_operation/queries/readRepositories.dart' as queries; -import '../helpers.dart' show withGenericHandling; - -// to run the example, replace with your GitHub token in ../local.dart -import '../local.dart'; - -class GraphQLWidgetScreen extends StatelessWidget { - const GraphQLWidgetScreen() : super(); - - @override - Widget build(BuildContext context) { - var httpLink = HttpLink('https://api.github.com/graphql', defaultHeaders: { - 'Authorization': 'Bearer $YOUR_PERSONAL_ACCESS_TOKEN', - }); - - final client = ValueNotifier( - GraphQLClient( - cache: GraphQLCache(), - link: httpLink, - ), - ); - - return GraphQLProvider( - client: client, - child: const CacheProvider( - child: MyHomePage(title: 'GraphQL Widget'), - ), - ); - } -} - -class MyHomePage extends StatefulWidget { - const MyHomePage({ - Key? key, - this.title, - }) : super(key: key); - - final String? title; - - @override - _MyHomePageState createState() => _MyHomePageState(); -} - -class _MyHomePageState extends State { - int nRepositories = 50; - - void changeQuery(String number) { - setState(() { - nRepositories = int.parse(number); - }); - } - - @override - Widget build(BuildContext context) { - return Scaffold( - appBar: AppBar( - title: Text(widget.title!), - ), - body: Container( - padding: const EdgeInsets.symmetric(horizontal: 8.0), - child: Column( - mainAxisAlignment: MainAxisAlignment.start, - mainAxisSize: MainAxisSize.max, - children: [ - TextField( - decoration: const InputDecoration( - labelText: 'Number of repositories (default 50)', - ), - keyboardType: TextInputType.number, - onSubmitted: changeQuery, - ), - Query( - options: QueryOptions( - document: gql(queries.readRepositories), - variables: { - 'nRepositories': nRepositories, - }, - //pollInterval: 10, - ), - builder: withGenericHandling( - (QueryResult result, {refetch, fetchMore}) { - if (result.data == null && !result.hasException) { - return const Text( - 'Loading has completed, but both data and errors are null. ' - 'This should never be the case – please open an issue', - ); - } - - // result.data can be either a [List] or a [Map] - final repositories = (result.data!['viewer']['repositories'] - ['nodes'] as List); - - return Expanded( - child: ListView.builder( - itemCount: repositories.length, - itemBuilder: (BuildContext context, int index) { - return StarrableRepository( - repository: repositories[index], - optimistic: result.source == - QueryResultSource.optimisticResult, - ); - }, - ), - ); - }, - ), - ), - ], - ), - ), - ); - } -} - -class StarrableRepository extends StatelessWidget { - const StarrableRepository({ - Key? key, - required this.repository, - required this.optimistic, - }) : super(key: key); - - final Map repository; - final bool optimistic; - - /// Extract the repository data for updating the fragment - Map? extractRepositoryData(Map data) { - final action = data['action'] as Map?; - if (action == null) { - return null; - } - return action['starrable'] as Map?; - } - - /// Get whether the repository is currently starred, according to the current Query - bool? get starred => repository['viewerHasStarred'] as bool?; - - /// Build an optimisticResult based on whether [viewerIsStarrring] - Map expectedResult(bool viewerIsStarrring) => - { - 'action': { - 'starrable': { - '__typename': 'Repository', - 'id': repository['id'], - 'viewerHasStarred': viewerIsStarrring, - } - } - }; - - OnMutationUpdate get update => (cache, result) { - if (result!.hasException) { - print(result.exception); - } else { - final updated = { - ...repository, - ...extractRepositoryData(result.data!)!, - }; - cache.writeFragment( - Fragment( - document: gql( - ''' - fragment fields on Repository { - id - name - viewerHasStarred - } - ''', - ), - ).asRequest(idFields: { - '__typename': updated['__typename'], - 'id': updated['id'], - }), - data: updated, - ); - } - }; - - @override - Widget build(BuildContext context) { - /// While we could toggle between the addStar and removeStar mutations conditionally, - /// this would discard and rebuild each associated [ObservableQuery]. The side effects would still execute, - /// but we would not have a way to inspect the mutation results, such as with [_debugLatestResults]. - return Mutation( - options: MutationOptions( - document: gql(mutations.addStar), - update: update, - onError: (OperationException? error) => - _simpleAlert(context, error.toString()), - onCompleted: (dynamic resultData) => - _simpleAlert(context, 'Thanks for your star!'), - // 'Sorry you changed your mind!', - ), - builder: (RunMutation _addStar, QueryResult? addResult) { - final addStar = () => _addStar({'starrableId': repository['id']}, - optimisticResult: expectedResult(true)); - return Mutation( - options: MutationOptions( - document: gql(mutations.removeStar), - update: update, - onError: (OperationException? error) => - _simpleAlert(context, error.toString()), - onCompleted: (dynamic resultData) => - _simpleAlert(context, 'Sorry you changed your mind!'), - ), - builder: (RunMutation _removeStar, QueryResult? removeResult) { - final removeStar = () => _removeStar( - {'starrableId': repository['id']}, - optimisticResult: expectedResult(false)); - - final anyLoading = - addResult!.isLoading || removeResult!.isLoading || optimistic; - - return ListTile( - leading: starred! - ? Icon( - Icons.star, - color: Colors.amber, - ) - : Icon(Icons.star_border), - trailing: anyLoading ? CircularProgressIndicator() : null, - title: Text(repository['name'] as String), - - /// uncomment this line to see the actual mutation results - subtitle: _debugLatestResults(addResult, removeResult!), - onTap: anyLoading - ? null - : starred! - ? removeStar - : addStar, - ); - }, - ); - }, - ); - } - - // TODO extract these details into better docs on [Policies] - /// Used for inspecting the mutation results. - /// - /// Can be used to observe the behavior in https://github.com/zino-app/graphql-flutter/issues/774, - /// patched in https://github.com/zino-app/graphql-flutter/pull/795 with the addition of [CacheRereadPolicy]. - /// - /// To behavior, add the following to the `Mutations` above: - /// ```dart - /// fetchPolicy: FetchPolicy.networkOnly, - /// cacheRereadPolicy: CacheRereadPolicy.mergeOptimistic, - /// ``` - /// This will cause the mutation results to be rebroadcast from the cache, - /// merging in the new `Repository.viewerHasStarred` state. - /// This can be desirable when a mutation result is used merely as a follow-up query. - Widget? _debugLatestResults(QueryResult add, QueryResult remove) { - //return null; - var latestResults = ''; - if (add.data != null) { - latestResults += 'addResultRepo: ${extractRepositoryData(add.data!)}; '; - } - if (remove.data != null) { - latestResults += - 'removeResultRepo: ${extractRepositoryData(remove.data!)}; '; - } - if (latestResults.isEmpty) { - return null; - } - return Text(latestResults); - } -} - -void _simpleAlert(BuildContext context, String text) => showDialog( - context: context, - builder: (BuildContext context) { - return AlertDialog( - title: Text(text), - actions: [ - SimpleDialogOption( - onPressed: () { - Navigator.of(context).pop(); - }, - child: const Text('DISMISS'), - ) - ], - ); - }, - ); diff --git a/packages/graphql_flutter/example/lib/helpers.dart b/packages/graphql_flutter/example/lib/helpers.dart deleted file mode 100644 index c0c2528eb..000000000 --- a/packages/graphql_flutter/example/lib/helpers.dart +++ /dev/null @@ -1,30 +0,0 @@ -import 'package:flutter/material.dart'; -import 'package:graphql_flutter/graphql_flutter.dart'; - -/// boilerplate `result.loading` and `result.hasException` handling -/// -/// ```dart -/// if (result.loading) { -/// return const Center( -/// child: CircularProgressIndicator(), -/// ); -/// } -/// if (result.hasException) { -/// return Text(result.exception.toString()); -/// } -/// ``` -QueryBuilder withGenericHandling(QueryBuilder builder) { - return (result, {fetchMore, refetch}) { - if (result.hasException) { - return Text(result.exception.toString()); - } - - if (result.isLoading) { - return const Center( - child: CircularProgressIndicator(), - ); - } - - return builder(result, fetchMore: fetchMore, refetch: refetch); - }; -} diff --git a/packages/graphql_flutter/example/lib/local.dart b/packages/graphql_flutter/example/lib/local.dart deleted file mode 100644 index 8e5891184..000000000 --- a/packages/graphql_flutter/example/lib/local.dart +++ /dev/null @@ -1 +0,0 @@ -const String YOUR_PERSONAL_ACCESS_TOKEN = ''; diff --git a/packages/graphql_flutter/example/lib/main.dart b/packages/graphql_flutter/example/lib/main.dart deleted file mode 100644 index 9a27ead63..000000000 --- a/packages/graphql_flutter/example/lib/main.dart +++ /dev/null @@ -1,72 +0,0 @@ -import 'package:flutter/material.dart'; -import 'package:trash_themes/themes.dart'; -import './graphql_bloc/main.dart' show GraphQLBlocPatternScreen; -import './graphql_widget/main.dart' show GraphQLWidgetScreen; -import 'fetchmore/main.dart'; - -void main() => runApp(MyApp()); - -class MyApp extends StatelessWidget { - @override - Widget build(BuildContext context) { - return MaterialApp( - title: 'GraphQL Flutter Demo', - theme: DraculaTheme().makeDarkTheme(context: context), - home: Builder( - builder: (BuildContext context) => Scaffold( - appBar: AppBar( - title: const Text('GraphQL Demo App'), - ), - body: Center( - child: Column( - children: [ - Spacer(), - Flexible( - child: ElevatedButton( - onPressed: () { - Navigator.push( - context, - MaterialPageRoute( - builder: (BuildContext context) => - GraphQLBlocPatternScreen(), - ), - ); - }, - child: const Text('GraphQL BloC pattern'), - )), - Spacer(), - Flexible( - child: ElevatedButton( - onPressed: () { - Navigator.push( - context, - MaterialPageRoute( - builder: (BuildContext context) => - const GraphQLWidgetScreen(), - ), - ); - }, - child: const Text('GraphQL Widget'), - )), - Spacer(), - Flexible( - child: ElevatedButton( - onPressed: () { - Navigator.push( - context, - MaterialPageRoute( - builder: (BuildContext context) => - const FetchMoreWidgetScreen(), - ), - ); - }, - child: const Text('Fetchmore (Pagination) Example'), - )), - ], - ), - ), - ), - ), - ); - } -} diff --git a/packages/graphql_flutter/example/pubspec.yaml b/packages/graphql_flutter/example/pubspec.yaml deleted file mode 100644 index e26db97df..000000000 --- a/packages/graphql_flutter/example/pubspec.yaml +++ /dev/null @@ -1,31 +0,0 @@ -name: app -description: A new Flutter project. - -publish_to: none - -module: - androidX: true - -dependencies: - flutter: - sdk: flutter - cupertino_icons: ^0.1.3 - graphql_flutter: - path: .. - trash_themes: ^0.0.1 - -dev_dependencies: - pedantic: ^1.8.0+1 - flutter_test: - sdk: flutter - test: ^1.17.12 - -flutter: - uses-material-design: true - -dependency_overrides: - graphql: - path: ../../graphql - -environment: - sdk: '>=2.12.0 <3.0.0' diff --git a/packages/graphql_flutter/example/web/favicon.png b/packages/graphql_flutter/example/web/favicon.png deleted file mode 100644 index 8aaa46ac1..000000000 Binary files a/packages/graphql_flutter/example/web/favicon.png and /dev/null differ diff --git a/packages/graphql_flutter/example/web/icons/Icon-192.png b/packages/graphql_flutter/example/web/icons/Icon-192.png deleted file mode 100644 index b749bfef0..000000000 Binary files a/packages/graphql_flutter/example/web/icons/Icon-192.png and /dev/null differ diff --git a/packages/graphql_flutter/example/web/icons/Icon-512.png b/packages/graphql_flutter/example/web/icons/Icon-512.png deleted file mode 100644 index 88cfd48df..000000000 Binary files a/packages/graphql_flutter/example/web/icons/Icon-512.png and /dev/null differ diff --git a/packages/graphql_flutter/example/web/icons/Icon-maskable-192.png b/packages/graphql_flutter/example/web/icons/Icon-maskable-192.png deleted file mode 100644 index eb9b4d76e..000000000 Binary files a/packages/graphql_flutter/example/web/icons/Icon-maskable-192.png and /dev/null differ diff --git a/packages/graphql_flutter/example/web/icons/Icon-maskable-512.png b/packages/graphql_flutter/example/web/icons/Icon-maskable-512.png deleted file mode 100644 index d69c56691..000000000 Binary files a/packages/graphql_flutter/example/web/icons/Icon-maskable-512.png and /dev/null differ diff --git a/packages/graphql_flutter/example/web/index.html b/packages/graphql_flutter/example/web/index.html deleted file mode 100644 index 60109c1bc..000000000 --- a/packages/graphql_flutter/example/web/index.html +++ /dev/null @@ -1,104 +0,0 @@ - - - - - - - - - - - - - - - - - - - - demo_migaration - - - - - - - diff --git a/packages/graphql_flutter/example/web/manifest.json b/packages/graphql_flutter/example/web/manifest.json deleted file mode 100644 index fa0b5a9f2..000000000 --- a/packages/graphql_flutter/example/web/manifest.json +++ /dev/null @@ -1,35 +0,0 @@ -{ - "name": "demo_migaration", - "short_name": "demo_migaration", - "start_url": ".", - "display": "standalone", - "background_color": "#0175C2", - "theme_color": "#0175C2", - "description": "A new Flutter project.", - "orientation": "portrait-primary", - "prefer_related_applications": false, - "icons": [ - { - "src": "icons/Icon-192.png", - "sizes": "192x192", - "type": "image/png" - }, - { - "src": "icons/Icon-512.png", - "sizes": "512x512", - "type": "image/png" - }, - { - "src": "icons/Icon-maskable-192.png", - "sizes": "192x192", - "type": "image/png", - "purpose": "maskable" - }, - { - "src": "icons/Icon-maskable-512.png", - "sizes": "512x512", - "type": "image/png", - "purpose": "maskable" - } - ] -}