├── android ├── gradle.properties ├── .settings │ └── org.eclipse.buildship.core.prefs ├── app │ ├── .settings │ │ └── org.eclipse.buildship.core.prefs │ ├── src │ │ └── main │ │ │ ├── res │ │ │ ├── mipmap-hdpi │ │ │ │ └── ic_launcher.png │ │ │ ├── mipmap-mdpi │ │ │ │ └── ic_launcher.png │ │ │ ├── mipmap-xhdpi │ │ │ │ └── ic_launcher.png │ │ │ ├── mipmap-xxhdpi │ │ │ │ └── ic_launcher.png │ │ │ ├── mipmap-xxxhdpi │ │ │ │ └── ic_launcher.png │ │ │ ├── values │ │ │ │ └── styles.xml │ │ │ └── drawable │ │ │ │ └── launch_background.xml │ │ │ ├── java │ │ │ └── com │ │ │ │ └── example │ │ │ │ └── fluttertodosredux │ │ │ │ └── MainActivity.java │ │ │ └── AndroidManifest.xml │ ├── .classpath │ ├── .project │ └── build.gradle ├── gradle │ └── wrapper │ │ ├── gradle-wrapper.jar │ │ └── gradle-wrapper.properties ├── .gitignore ├── .project ├── settings.gradle ├── build.gradle ├── gradlew.bat └── gradlew ├── ios ├── Flutter │ ├── Debug.xcconfig │ ├── Release.xcconfig │ └── AppFrameworkInfo.plist ├── Runner │ ├── AppDelegate.h │ ├── Assets.xcassets │ │ ├── LaunchImage.imageset │ │ │ ├── LaunchImage.png │ │ │ ├── LaunchImage@2x.png │ │ │ ├── LaunchImage@3x.png │ │ │ ├── README.md │ │ │ └── Contents.json │ │ └── AppIcon.appiconset │ │ │ ├── Icon-App-20x20@1x.png │ │ │ ├── Icon-App-20x20@2x.png │ │ │ ├── Icon-App-20x20@3x.png │ │ │ ├── Icon-App-29x29@1x.png │ │ │ ├── Icon-App-29x29@2x.png │ │ │ ├── Icon-App-29x29@3x.png │ │ │ ├── Icon-App-40x40@1x.png │ │ │ ├── Icon-App-40x40@2x.png │ │ │ ├── Icon-App-40x40@3x.png │ │ │ ├── Icon-App-60x60@2x.png │ │ │ ├── Icon-App-60x60@3x.png │ │ │ ├── Icon-App-76x76@1x.png │ │ │ ├── Icon-App-76x76@2x.png │ │ │ ├── Icon-App-1024x1024@1x.png │ │ │ ├── Icon-App-83.5x83.5@2x.png │ │ │ └── Contents.json │ ├── main.m │ ├── AppDelegate.m │ ├── Info.plist │ └── Base.lproj │ │ ├── Main.storyboard │ │ └── LaunchScreen.storyboard ├── Runner.xcworkspace │ └── contents.xcworkspacedata ├── Runner.xcodeproj │ ├── project.xcworkspace │ │ └── contents.xcworkspacedata │ ├── xcshareddata │ │ └── xcschemes │ │ │ └── Runner.xcscheme │ └── project.pbxproj └── .gitignore ├── lib ├── models │ ├── selected_day.dart │ ├── current_tab.dart │ ├── catergory_model.dart │ ├── todo_model.dart │ └── app_state.dart ├── redux │ ├── actions │ │ ├── edit_actions.dart │ │ ├── tab_actions.dart │ │ └── todo_actions.dart │ ├── reducers │ │ ├── edit_reducer.dart │ │ ├── app_reducer.dart │ │ ├── current_tabReducer.dart │ │ ├── todos_reducer.dart │ │ └── categories_reducer.dart │ └── selectors │ │ └── selectors.dart ├── appbar.dart ├── helpers │ ├── format_date.dart │ └── uuid.dart ├── all_todos_grid.dart ├── main_layer.dart ├── date_select_button.dart ├── base_select.dart ├── main.dart ├── all_todo_grid_tile.dart ├── home.dart ├── todos_list.dart ├── todo_tile.dart ├── todos_list_page.dart ├── my_radio_button.dart ├── user_info.dart ├── add_todo_button.dart ├── tasks_view.dart └── add_todo_form.dart ├── .gitignore ├── assets └── fonts │ ├── PoppinsBold.ttf │ └── PoppinsRegular.ttf ├── .idea ├── libraries │ ├── Flutter_Plugins.xml │ ├── Flutter_for_Android.xml │ ├── Dart_SDK.xml │ └── Dart_Packages.xml ├── runConfigurations │ └── main_dart.xml ├── modules.xml ├── misc.xml ├── codeStyles │ └── Project.xml └── workspace.xml ├── .metadata ├── .vscode └── launch.json ├── flutter_todos_redux.iml ├── flutter_todos_redux_android.iml ├── pubspec.yaml ├── README.md └── pubspec.lock /android/gradle.properties: -------------------------------------------------------------------------------- 1 | org.gradle.jvmargs=-Xmx1536M 2 | -------------------------------------------------------------------------------- /ios/Flutter/Debug.xcconfig: -------------------------------------------------------------------------------- 1 | #include "Generated.xcconfig" 2 | -------------------------------------------------------------------------------- /ios/Flutter/Release.xcconfig: -------------------------------------------------------------------------------- 1 | #include "Generated.xcconfig" 2 | -------------------------------------------------------------------------------- /lib/models/selected_day.dart: -------------------------------------------------------------------------------- 1 | enum SelectedDay { Today, Tommorow, Custom } 2 | -------------------------------------------------------------------------------- /lib/models/current_tab.dart: -------------------------------------------------------------------------------- 1 | enum CurrentTab { Today, Week, Month, Upcoming, Completed } 2 | -------------------------------------------------------------------------------- /android/.settings/org.eclipse.buildship.core.prefs: -------------------------------------------------------------------------------- 1 | connection.project.dir= 2 | eclipse.preferences.version=1 3 | -------------------------------------------------------------------------------- /android/app/.settings/org.eclipse.buildship.core.prefs: -------------------------------------------------------------------------------- 1 | connection.project.dir=.. 2 | eclipse.preferences.version=1 3 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | .DS_Store 2 | .dart_tool/ 3 | 4 | .packages 5 | .pub/ 6 | 7 | build/ 8 | 9 | .flutter-plugins 10 | -------------------------------------------------------------------------------- /assets/fonts/PoppinsBold.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rvamsikrishna/flutter_todos_redux/HEAD/assets/fonts/PoppinsBold.ttf -------------------------------------------------------------------------------- /assets/fonts/PoppinsRegular.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rvamsikrishna/flutter_todos_redux/HEAD/assets/fonts/PoppinsRegular.ttf -------------------------------------------------------------------------------- /android/gradle/wrapper/gradle-wrapper.jar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rvamsikrishna/flutter_todos_redux/HEAD/android/gradle/wrapper/gradle-wrapper.jar -------------------------------------------------------------------------------- /ios/Runner/AppDelegate.h: -------------------------------------------------------------------------------- 1 | #import 2 | #import 3 | 4 | @interface AppDelegate : FlutterAppDelegate 5 | 6 | @end 7 | -------------------------------------------------------------------------------- /lib/redux/actions/edit_actions.dart: -------------------------------------------------------------------------------- 1 | class ToggleEditingStatusAction { 2 | final bool editing; 3 | 4 | ToggleEditingStatusAction({this.editing}); 5 | } 6 | -------------------------------------------------------------------------------- /android/app/src/main/res/mipmap-hdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rvamsikrishna/flutter_todos_redux/HEAD/android/app/src/main/res/mipmap-hdpi/ic_launcher.png -------------------------------------------------------------------------------- /android/app/src/main/res/mipmap-mdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rvamsikrishna/flutter_todos_redux/HEAD/android/app/src/main/res/mipmap-mdpi/ic_launcher.png -------------------------------------------------------------------------------- /android/app/src/main/res/mipmap-xhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rvamsikrishna/flutter_todos_redux/HEAD/android/app/src/main/res/mipmap-xhdpi/ic_launcher.png -------------------------------------------------------------------------------- /android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rvamsikrishna/flutter_todos_redux/HEAD/android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png -------------------------------------------------------------------------------- /android/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rvamsikrishna/flutter_todos_redux/HEAD/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rvamsikrishna/flutter_todos_redux/HEAD/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage.png -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@1x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rvamsikrishna/flutter_todos_redux/HEAD/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@1x.png -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rvamsikrishna/flutter_todos_redux/HEAD/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@2x.png -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@3x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rvamsikrishna/flutter_todos_redux/HEAD/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@3x.png -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@1x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rvamsikrishna/flutter_todos_redux/HEAD/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@1x.png -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rvamsikrishna/flutter_todos_redux/HEAD/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@2x.png -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@3x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rvamsikrishna/flutter_todos_redux/HEAD/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@3x.png -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@1x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rvamsikrishna/flutter_todos_redux/HEAD/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@1x.png -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rvamsikrishna/flutter_todos_redux/HEAD/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@2x.png -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@3x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rvamsikrishna/flutter_todos_redux/HEAD/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@3x.png -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rvamsikrishna/flutter_todos_redux/HEAD/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@2x.png -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@3x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rvamsikrishna/flutter_todos_redux/HEAD/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@3x.png -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@1x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rvamsikrishna/flutter_todos_redux/HEAD/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@1x.png -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rvamsikrishna/flutter_todos_redux/HEAD/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@2x.png -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rvamsikrishna/flutter_todos_redux/HEAD/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@2x.png -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@3x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rvamsikrishna/flutter_todos_redux/HEAD/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@3x.png -------------------------------------------------------------------------------- /android/.gitignore: -------------------------------------------------------------------------------- 1 | *.iml 2 | *.class 3 | .gradle 4 | /local.properties 5 | /.idea/workspace.xml 6 | /.idea/libraries 7 | .DS_Store 8 | /build 9 | /captures 10 | GeneratedPluginRegistrant.java 11 | -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-1024x1024@1x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rvamsikrishna/flutter_todos_redux/HEAD/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-1024x1024@1x.png -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-83.5x83.5@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rvamsikrishna/flutter_todos_redux/HEAD/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-83.5x83.5@2x.png -------------------------------------------------------------------------------- /ios/Runner.xcworkspace/contents.xcworkspacedata: -------------------------------------------------------------------------------- 1 | 2 | 4 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /lib/redux/actions/tab_actions.dart: -------------------------------------------------------------------------------- 1 | import 'package:flutter_todos_redux/models/current_tab.dart'; 2 | 3 | class SetCurrentTabAction { 4 | final CurrentTab currentTab; 5 | 6 | SetCurrentTabAction(this.currentTab); 7 | } 8 | -------------------------------------------------------------------------------- /.idea/libraries/Flutter_Plugins.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | -------------------------------------------------------------------------------- /ios/Runner.xcodeproj/project.xcworkspace/contents.xcworkspacedata: -------------------------------------------------------------------------------- 1 | 2 | 4 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /ios/Runner/main.m: -------------------------------------------------------------------------------- 1 | #import 2 | #import 3 | #import "AppDelegate.h" 4 | 5 | int main(int argc, char* argv[]) { 6 | @autoreleasepool { 7 | return UIApplicationMain(argc, argv, nil, NSStringFromClass([AppDelegate class])); 8 | } 9 | } 10 | -------------------------------------------------------------------------------- /android/gradle/wrapper/gradle-wrapper.properties: -------------------------------------------------------------------------------- 1 | #Fri Jun 23 08:50:38 CEST 2017 2 | distributionBase=GRADLE_USER_HOME 3 | distributionPath=wrapper/dists 4 | zipStoreBase=GRADLE_USER_HOME 5 | zipStorePath=wrapper/dists 6 | distributionUrl=https\://services.gradle.org/distributions/gradle-4.4-all.zip 7 | -------------------------------------------------------------------------------- /.idea/runConfigurations/main_dart.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 6 | -------------------------------------------------------------------------------- /.metadata: -------------------------------------------------------------------------------- 1 | # This file tracks properties of this Flutter project. 2 | # Used by Flutter tool to assess capabilities and perform upgrades etc. 3 | # 4 | # This file should be version controlled and should not be manually edited. 5 | 6 | version: 7 | revision: 5ab9e70727d858def3a586db7fb98ee580352957 8 | channel: beta 9 | -------------------------------------------------------------------------------- /.idea/libraries/Flutter_for_Android.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /lib/redux/reducers/edit_reducer.dart: -------------------------------------------------------------------------------- 1 | import 'package:flutter_todos_redux/redux/actions/edit_actions.dart'; 2 | import 'package:redux/redux.dart'; 3 | 4 | final toggleEditingStatus = TypedReducer( 5 | (bool editing, ToggleEditingStatusAction action) { 6 | return action.editing; 7 | }); 8 | -------------------------------------------------------------------------------- /android/app/.classpath: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | -------------------------------------------------------------------------------- /.vscode/launch.json: -------------------------------------------------------------------------------- 1 | { 2 | // Use IntelliSense to learn about possible attributes. 3 | // Hover to view descriptions of existing attributes. 4 | // For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387 5 | "version": "0.2.0", 6 | "configurations": [ 7 | { 8 | "name": "Flutter", 9 | "request": "launch", 10 | "type": "dart" 11 | } 12 | ] 13 | } -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/LaunchImage.imageset/README.md: -------------------------------------------------------------------------------- 1 | # Launch Screen Assets 2 | 3 | You can customize the launch screen with your own desired assets by replacing the image files in this directory. 4 | 5 | You can also do it by opening your Flutter project's Xcode project with `open ios/Runner.xcworkspace`, selecting `Runner/Assets.xcassets` in the Project Navigator and dropping in the desired images. -------------------------------------------------------------------------------- /android/app/src/main/res/values/styles.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 8 | 9 | -------------------------------------------------------------------------------- /lib/redux/actions/todo_actions.dart: -------------------------------------------------------------------------------- 1 | import 'package:flutter_todos_redux/models/todo_model.dart'; 2 | 3 | class AddTodoAction { 4 | final Todo todo; 5 | 6 | AddTodoAction(this.todo); 7 | } 8 | 9 | class DeleteTodoAction { 10 | final Todo todo; 11 | 12 | DeleteTodoAction(this.todo); 13 | } 14 | 15 | class UpdateTodoAction { 16 | final String id; 17 | final Todo updatedTodo; 18 | 19 | UpdateTodoAction({this.id, this.updatedTodo}); 20 | } 21 | -------------------------------------------------------------------------------- /.idea/modules.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | -------------------------------------------------------------------------------- /android/app/src/main/java/com/example/fluttertodosredux/MainActivity.java: -------------------------------------------------------------------------------- 1 | package com.example.fluttertodosredux; 2 | 3 | import android.os.Bundle; 4 | import io.flutter.app.FlutterActivity; 5 | import io.flutter.plugins.GeneratedPluginRegistrant; 6 | 7 | public class MainActivity extends FlutterActivity { 8 | @Override 9 | protected void onCreate(Bundle savedInstanceState) { 10 | super.onCreate(savedInstanceState); 11 | GeneratedPluginRegistrant.registerWith(this); 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /ios/Runner/AppDelegate.m: -------------------------------------------------------------------------------- 1 | #include "AppDelegate.h" 2 | #include "GeneratedPluginRegistrant.h" 3 | 4 | @implementation AppDelegate 5 | 6 | - (BOOL)application:(UIApplication *)application 7 | didFinishLaunchingWithOptions:(NSDictionary *)launchOptions { 8 | [GeneratedPluginRegistrant registerWithRegistry:self]; 9 | // Override point for customization after application launch. 10 | return [super application:application didFinishLaunchingWithOptions:launchOptions]; 11 | } 12 | 13 | @end 14 | -------------------------------------------------------------------------------- /android/.project: -------------------------------------------------------------------------------- 1 | 2 | 3 | android 4 | Project android created by Buildship. 5 | 6 | 7 | 8 | 9 | org.eclipse.buildship.core.gradleprojectbuilder 10 | 11 | 12 | 13 | 14 | 15 | org.eclipse.buildship.core.gradleprojectnature 16 | 17 | 18 | -------------------------------------------------------------------------------- /android/app/src/main/res/drawable/launch_background.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 12 | 13 | -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/LaunchImage.imageset/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "images" : [ 3 | { 4 | "idiom" : "universal", 5 | "filename" : "LaunchImage.png", 6 | "scale" : "1x" 7 | }, 8 | { 9 | "idiom" : "universal", 10 | "filename" : "LaunchImage@2x.png", 11 | "scale" : "2x" 12 | }, 13 | { 14 | "idiom" : "universal", 15 | "filename" : "LaunchImage@3x.png", 16 | "scale" : "3x" 17 | } 18 | ], 19 | "info" : { 20 | "version" : 1, 21 | "author" : "xcode" 22 | } 23 | } 24 | -------------------------------------------------------------------------------- /android/settings.gradle: -------------------------------------------------------------------------------- 1 | include ':app' 2 | 3 | def flutterProjectRoot = rootProject.projectDir.parentFile.toPath() 4 | 5 | def plugins = new Properties() 6 | def pluginsFile = new File(flutterProjectRoot.toFile(), '.flutter-plugins') 7 | if (pluginsFile.exists()) { 8 | pluginsFile.withReader('UTF-8') { reader -> plugins.load(reader) } 9 | } 10 | 11 | plugins.each { name, path -> 12 | def pluginDirectory = flutterProjectRoot.resolve(path).resolve('android').toFile() 13 | include ":$name" 14 | project(":$name").projectDir = pluginDirectory 15 | } 16 | -------------------------------------------------------------------------------- /android/build.gradle: -------------------------------------------------------------------------------- 1 | buildscript { 2 | repositories { 3 | google() 4 | jcenter() 5 | } 6 | 7 | dependencies { 8 | classpath 'com.android.tools.build:gradle:3.1.2' 9 | } 10 | } 11 | 12 | allprojects { 13 | repositories { 14 | google() 15 | jcenter() 16 | } 17 | } 18 | 19 | rootProject.buildDir = '../build' 20 | subprojects { 21 | project.buildDir = "${rootProject.buildDir}/${project.name}" 22 | } 23 | subprojects { 24 | project.evaluationDependsOn(':app') 25 | } 26 | 27 | task clean(type: Delete) { 28 | delete rootProject.buildDir 29 | } 30 | -------------------------------------------------------------------------------- /android/app/.project: -------------------------------------------------------------------------------- 1 | 2 | 3 | app 4 | Project app created by Buildship. 5 | 6 | 7 | 8 | 9 | org.eclipse.jdt.core.javabuilder 10 | 11 | 12 | 13 | 14 | org.eclipse.buildship.core.gradleprojectbuilder 15 | 16 | 17 | 18 | 19 | 20 | org.eclipse.jdt.core.javanature 21 | org.eclipse.buildship.core.gradleprojectnature 22 | 23 | 24 | -------------------------------------------------------------------------------- /ios/.gitignore: -------------------------------------------------------------------------------- 1 | .idea/ 2 | .vagrant/ 3 | .sconsign.dblite 4 | .svn/ 5 | 6 | .DS_Store 7 | *.swp 8 | profile 9 | 10 | DerivedData/ 11 | build/ 12 | GeneratedPluginRegistrant.h 13 | GeneratedPluginRegistrant.m 14 | 15 | .generated/ 16 | 17 | *.pbxuser 18 | *.mode1v3 19 | *.mode2v3 20 | *.perspectivev3 21 | 22 | !default.pbxuser 23 | !default.mode1v3 24 | !default.mode2v3 25 | !default.perspectivev3 26 | 27 | xcuserdata 28 | 29 | *.moved-aside 30 | 31 | *.pyc 32 | *sync/ 33 | Icon? 34 | .tags* 35 | 36 | /Flutter/app.flx 37 | /Flutter/app.zip 38 | /Flutter/flutter_assets/ 39 | /Flutter/App.framework 40 | /Flutter/Flutter.framework 41 | /Flutter/Generated.xcconfig 42 | /ServiceDefinitions.json 43 | 44 | Pods/ 45 | .symlinks/ 46 | -------------------------------------------------------------------------------- /lib/redux/reducers/app_reducer.dart: -------------------------------------------------------------------------------- 1 | import 'package:flutter_todos_redux/models/app_state.dart'; 2 | import 'package:flutter_todos_redux/redux/reducers/todos_reducer.dart'; 3 | import 'package:flutter_todos_redux/redux/reducers/current_tabReducer.dart'; 4 | import 'package:flutter_todos_redux/redux/reducers/edit_reducer.dart'; 5 | import 'package:flutter_todos_redux/redux/reducers/categories_reducer.dart'; 6 | 7 | AppState appReducer(AppState state, action) { 8 | return AppState( 9 | todos: todosReducer(state.todos, action), 10 | currentTab: currentTabReducer(state.currentTab, action), 11 | editing: toggleEditingStatus(state.editing, action), 12 | // categories: state.categories, 13 | categories: categoriesReducer(state.categories, action), 14 | ); 15 | } 16 | -------------------------------------------------------------------------------- /lib/redux/reducers/current_tabReducer.dart: -------------------------------------------------------------------------------- 1 | import 'package:flutter_todos_redux/models/current_tab.dart'; 2 | import 'package:flutter_todos_redux/redux/actions/tab_actions.dart'; 3 | import 'package:redux/redux.dart'; 4 | 5 | final currentTabReducer = combineReducers( 6 | [ 7 | TypedReducer(_currentTab), 8 | ], 9 | ); 10 | 11 | CurrentTab _currentTab(CurrentTab tab, SetCurrentTabAction action) { 12 | if (action.currentTab == CurrentTab.Today) { 13 | print('debugggingggggggggggg .....today'); 14 | } 15 | if (action.currentTab == CurrentTab.Week) { 16 | print('debugggingggggggggggg .....week'); 17 | } 18 | if (action.currentTab == CurrentTab.Month) { 19 | print('debugggingggggggggggg .....month'); 20 | } 21 | return action.currentTab; 22 | } 23 | -------------------------------------------------------------------------------- /lib/models/catergory_model.dart: -------------------------------------------------------------------------------- 1 | import 'package:flutter/material.dart'; 2 | 3 | class Category { 4 | final String name; 5 | final Color color; 6 | int todosNumber; 7 | final IconData icon; 8 | 9 | Category({this.name, this.todosNumber = 0, this.color, this.icon}); 10 | } 11 | 12 | class Categories { 13 | final List categories; 14 | 15 | Categories(this.categories); 16 | 17 | factory Categories.initial() { 18 | return Categories( 19 | [ 20 | Category(name: 'College', color: Colors.red, icon: Icons.school), 21 | Category(name: 'Work', color: Colors.blue, icon: Icons.work), 22 | Category( 23 | name: 'Study', 24 | color: Colors.yellow, 25 | icon: Icons.chrome_reader_mode), 26 | Category(name: 'Sport', color: Colors.green, icon: Icons.pool), 27 | ], 28 | ); 29 | } 30 | } 31 | -------------------------------------------------------------------------------- /ios/Flutter/AppFrameworkInfo.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | CFBundleDevelopmentRegion 6 | en 7 | CFBundleExecutable 8 | App 9 | CFBundleIdentifier 10 | io.flutter.flutter.app 11 | CFBundleInfoDictionaryVersion 12 | 6.0 13 | CFBundleName 14 | App 15 | CFBundlePackageType 16 | FMWK 17 | CFBundleShortVersionString 18 | 1.0 19 | CFBundleSignature 20 | ???? 21 | CFBundleVersion 22 | 1.0 23 | MinimumOSVersion 24 | 8.0 25 | 26 | 27 | -------------------------------------------------------------------------------- /lib/appbar.dart: -------------------------------------------------------------------------------- 1 | import 'package:flutter/material.dart'; 2 | 3 | class MyAppBar extends StatelessWidget { 4 | const MyAppBar({ 5 | Key key, 6 | }) : super(key: key); 7 | 8 | Widget buildIcon(IconData icon) { 9 | return Icon( 10 | icon, 11 | color: Colors.grey, 12 | size: 35.0, 13 | ); 14 | } 15 | 16 | @override 17 | Widget build(BuildContext context) { 18 | return Padding( 19 | padding: const EdgeInsets.only(top: 40.0, bottom: 20.0), 20 | child: Row( 21 | children: [ 22 | buildIcon(Icons.menu), 23 | Expanded( 24 | child: Text( 25 | 'TODO', 26 | textAlign: TextAlign.center, 27 | style: TextStyle(fontSize: 20.0, fontWeight: FontWeight.bold), 28 | ), 29 | ), 30 | buildIcon(Icons.search), 31 | ], 32 | ), 33 | ); 34 | } 35 | } 36 | -------------------------------------------------------------------------------- /lib/redux/reducers/todos_reducer.dart: -------------------------------------------------------------------------------- 1 | import 'package:flutter_todos_redux/models/todo_model.dart'; 2 | import 'package:flutter_todos_redux/redux/actions/todo_actions.dart'; 3 | import 'package:redux/redux.dart'; 4 | 5 | final todosReducer = combineReducers>([ 6 | TypedReducer, AddTodoAction>(_addTodo), 7 | TypedReducer, DeleteTodoAction>(_deleteTodo), 8 | TypedReducer, UpdateTodoAction>(_updateTodo), 9 | ]); 10 | 11 | List _addTodo(List todos, AddTodoAction action) { 12 | return List.from(todos)..add(action.todo); 13 | } 14 | 15 | List _deleteTodo(List todos, DeleteTodoAction action) { 16 | return todos.where((todo) => todo.id != action.todo.id).toList(); 17 | } 18 | 19 | List _updateTodo(List todos, UpdateTodoAction action) { 20 | return todos 21 | .map((todo) => todo.id == action.id ? action.updatedTodo : todo) 22 | .toList(); 23 | } 24 | -------------------------------------------------------------------------------- /flutter_todos_redux.iml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | -------------------------------------------------------------------------------- /.idea/libraries/Dart_SDK.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | -------------------------------------------------------------------------------- /lib/redux/reducers/categories_reducer.dart: -------------------------------------------------------------------------------- 1 | import 'package:flutter_todos_redux/models/catergory_model.dart'; 2 | import 'package:flutter_todos_redux/redux/actions/todo_actions.dart'; 3 | import 'package:redux/redux.dart'; 4 | 5 | final categoriesReducer = combineReducers>([ 6 | TypedReducer, AddTodoAction>(_increaseCategoryTodoCount), 7 | TypedReducer, DeleteTodoAction>(_decreaseCategoryTodoCount), 8 | ]); 9 | 10 | List _increaseCategoryTodoCount( 11 | List categories, AddTodoAction action) { 12 | return categories 13 | .map((Category cat) { 14 | if (action.todo.category.name == cat.name) { 15 | cat.todosNumber++; 16 | } 17 | return cat; 18 | }) 19 | .toList() 20 | .cast(); 21 | } 22 | 23 | List _decreaseCategoryTodoCount( 24 | List categories, DeleteTodoAction action) { 25 | return categories 26 | .map((Category cat) { 27 | if (action.todo.category.name == cat.name) { 28 | cat.todosNumber--; 29 | } 30 | return cat; 31 | }) 32 | .toList() 33 | .cast(); 34 | } 35 | -------------------------------------------------------------------------------- /lib/models/todo_model.dart: -------------------------------------------------------------------------------- 1 | import 'package:flutter/material.dart'; 2 | import 'package:flutter_todos_redux/helpers/uuid.dart'; 3 | import 'package:flutter_todos_redux/models/catergory_model.dart'; 4 | 5 | class Todo { 6 | final String id; 7 | final String text; 8 | final Category category; 9 | final DateTime date; 10 | final TimeOfDay time; 11 | final bool completed; 12 | 13 | Todo({this.text, this.category, this.date, this.time, this.completed = false}) 14 | : id = Uuid().generateV4(); 15 | 16 | factory Todo.empty() { 17 | return Todo(text: '', category: null, date: null, completed: false); 18 | } 19 | 20 | factory Todo.fromMap(Map map) { 21 | return Todo( 22 | text: map['text'], 23 | category: map['category'], 24 | date: map['date'], 25 | time: map['time'], 26 | completed: map['completed'] ?? false, 27 | ); 28 | } 29 | 30 | Todo copyWith( 31 | {String text, Category category, DateTime date, bool completed}) { 32 | return Todo( 33 | text: text ?? this.text, 34 | category: category ?? this.category, 35 | date: date ?? this.date, 36 | time: time ?? this.time, 37 | completed: completed ?? this.completed, 38 | ); 39 | } 40 | } 41 | -------------------------------------------------------------------------------- /lib/helpers/format_date.dart: -------------------------------------------------------------------------------- 1 | import 'package:flutter/material.dart'; 2 | 3 | String formattedDateTime(DateTime date, TimeOfDay time, BuildContext context) { 4 | String result = ''; 5 | final now = DateTime.now(); 6 | final endOfToday = DateTime.utc(now.year, now.month, now.day, 24); 7 | if (date.isBefore(endOfToday)) { 8 | result += ''; 9 | } else { 10 | result += ' , ${date.day}-${_month(date.month)}-${date.year}'; 11 | } 12 | return result += ' , ${time.format(context)}'; 13 | } 14 | 15 | String _month(int month) { 16 | String res; 17 | switch (month) { 18 | case 1: 19 | res = 'jan'; 20 | break; 21 | case 2: 22 | res = 'feb'; 23 | break; 24 | case 3: 25 | res = 'mar'; 26 | break; 27 | case 4: 28 | res = 'apr'; 29 | break; 30 | case 5: 31 | res = 'may'; 32 | break; 33 | case 6: 34 | res = 'jun'; 35 | break; 36 | case 7: 37 | res = 'jul'; 38 | break; 39 | case 8: 40 | res = 'aug'; 41 | break; 42 | case 9: 43 | res = 'sep'; 44 | break; 45 | case 10: 46 | res = 'oct'; 47 | break; 48 | case 11: 49 | res = 'nov'; 50 | break; 51 | case 12: 52 | res = 'dec'; 53 | break; 54 | } 55 | return res; 56 | } 57 | -------------------------------------------------------------------------------- /lib/helpers/uuid.dart: -------------------------------------------------------------------------------- 1 | import 'dart:math'; 2 | 3 | /// A UUID generator, useful for generating unique IDs for your Todos. 4 | /// Shamelessly extracted from the Flutter source code. 5 | /// 6 | /// This will generate unique IDs in the format: 7 | /// 8 | /// f47ac10b-58cc-4372-a567-0e02b2c3d479 9 | /// 10 | /// ### Example 11 | /// 12 | /// final String id = new Uuid().generateV4(); 13 | class Uuid { 14 | final Random _random = new Random(); 15 | 16 | /// Generate a version 4 (random) uuid. This is a uuid scheme that only uses 17 | /// random numbers as the source of the generated uuid. 18 | String generateV4() { 19 | // Generate xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx / 8-4-4-4-12. 20 | final int special = 8 + _random.nextInt(4); 21 | 22 | return '${_bitsDigits(16, 4)}${_bitsDigits(16, 4)}-' 23 | '${_bitsDigits(16, 4)}-' 24 | '4${_bitsDigits(12, 3)}-' 25 | '${_printDigits(special, 1)}${_bitsDigits(12, 3)}-' 26 | '${_bitsDigits(16, 4)}${_bitsDigits(16, 4)}${_bitsDigits(16, 4)}'; 27 | } 28 | 29 | String _bitsDigits(int bitCount, int digitCount) => 30 | _printDigits(_generateBits(bitCount), digitCount); 31 | 32 | int _generateBits(int bitCount) => _random.nextInt(1 << bitCount); 33 | 34 | String _printDigits(int value, int count) => 35 | value.toRadixString(16).padLeft(count, '0'); 36 | } 37 | -------------------------------------------------------------------------------- /lib/models/app_state.dart: -------------------------------------------------------------------------------- 1 | import 'package:flutter/material.dart'; 2 | import 'package:flutter_todos_redux/models/catergory_model.dart'; 3 | import 'package:flutter_todos_redux/models/current_tab.dart'; 4 | import 'package:flutter_todos_redux/models/todo_model.dart'; 5 | import 'package:meta/meta.dart'; 6 | 7 | @immutable 8 | class AppState { 9 | final List todos; 10 | final CurrentTab currentTab; 11 | final bool editing; 12 | final List categories; 13 | 14 | AppState({ 15 | this.todos, 16 | this.currentTab, 17 | this.editing, 18 | this.categories, 19 | }); 20 | 21 | factory AppState.initial() { 22 | return AppState( 23 | currentTab: CurrentTab.Today, 24 | editing: false, 25 | // todos: [], 26 | todos: List.unmodifiable( 27 | [ 28 | Todo( 29 | text: 'Welcome.... ', 30 | category: Category(name: 'welcome', color: Colors.green), 31 | date: DateTime.now(), 32 | time: TimeOfDay.now(), 33 | ), 34 | Todo( 35 | text: 'Start taking down todos', 36 | category: Category(name: 'welcome', color: Colors.red), 37 | date: DateTime.now(), 38 | time: TimeOfDay.now(), 39 | ), 40 | ], 41 | ), 42 | categories: Categories.initial().categories, 43 | ); 44 | } 45 | } 46 | -------------------------------------------------------------------------------- /.idea/misc.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 17 | 27 | 28 | -------------------------------------------------------------------------------- /flutter_todos_redux_android.iml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | -------------------------------------------------------------------------------- /lib/all_todos_grid.dart: -------------------------------------------------------------------------------- 1 | import 'package:flutter/material.dart'; 2 | import 'package:flutter_redux/flutter_redux.dart'; 3 | import 'package:flutter_todos_redux/all_todo_grid_tile.dart'; 4 | import 'package:flutter_todos_redux/models/app_state.dart'; 5 | import 'package:flutter_todos_redux/models/catergory_model.dart'; 6 | import 'package:redux/redux.dart'; 7 | 8 | class AllTodosSection extends StatelessWidget { 9 | @override 10 | Widget build(BuildContext context) { 11 | return StoreConnector( 12 | converter: (Store store) => _ViewModel.create(store), 13 | builder: (BuildContext context, _ViewModel vm) { 14 | return GridView.builder( 15 | padding: EdgeInsets.symmetric(vertical: 20.0), 16 | shrinkWrap: true, 17 | itemCount: vm.categories.length, 18 | physics: ClampingScrollPhysics(), 19 | gridDelegate: SliverGridDelegateWithFixedCrossAxisCount( 20 | crossAxisCount: 2, 21 | childAspectRatio: 1.0, 22 | crossAxisSpacing: 20.0, 23 | mainAxisSpacing: 20.0, 24 | ), 25 | itemBuilder: (BuildContext context, int index) { 26 | return AllTodosGridTile(category: vm.categories[index]); 27 | }, 28 | ); 29 | }, 30 | ); 31 | } 32 | } 33 | 34 | class _ViewModel { 35 | final List categories; 36 | 37 | _ViewModel({this.categories}); 38 | 39 | factory _ViewModel.create(Store store) { 40 | return _ViewModel( 41 | categories: store.state.categories, 42 | ); 43 | } 44 | } 45 | -------------------------------------------------------------------------------- /lib/main_layer.dart: -------------------------------------------------------------------------------- 1 | import 'package:flutter/material.dart'; 2 | import 'package:flutter_todos_redux/all_todos_grid.dart'; 3 | import 'package:flutter_todos_redux/appbar.dart'; 4 | import 'package:flutter_todos_redux/tasks_view.dart'; 5 | import 'package:flutter_todos_redux/user_info.dart'; 6 | 7 | class MainLayer extends StatefulWidget { 8 | @override 9 | _MainLayerState createState() => _MainLayerState(); 10 | } 11 | 12 | class _MainLayerState extends State { 13 | @override 14 | Widget build(BuildContext context) { 15 | return Container( 16 | decoration: BoxDecoration( 17 | gradient: LinearGradient( 18 | begin: Alignment.center, 19 | end: Alignment.bottomCenter, 20 | colors: [ 21 | Colors.white, 22 | Colors.grey[200], 23 | ], 24 | ), 25 | ), 26 | child: Padding( 27 | padding: const EdgeInsets.symmetric(horizontal: 25.0), 28 | child: Column( 29 | children: [ 30 | MyAppBar(), 31 | Expanded( 32 | child: ListView( 33 | shrinkWrap: true, 34 | children: [ 35 | UserInfo(), 36 | Container(height: 380.0, child: TasksView()), 37 | Text( 38 | 'ALL TODO', 39 | style: Theme.of(context).textTheme.body2, 40 | ), 41 | AllTodosSection(), 42 | SizedBox( 43 | height: 80.0, 44 | ), 45 | ], 46 | ), 47 | ) 48 | ], 49 | ), 50 | ), 51 | ); 52 | } 53 | } 54 | -------------------------------------------------------------------------------- /ios/Runner/Info.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | CFBundleDevelopmentRegion 6 | en 7 | CFBundleExecutable 8 | $(EXECUTABLE_NAME) 9 | CFBundleIdentifier 10 | $(PRODUCT_BUNDLE_IDENTIFIER) 11 | CFBundleInfoDictionaryVersion 12 | 6.0 13 | CFBundleName 14 | flutter_todos_redux 15 | CFBundlePackageType 16 | APPL 17 | CFBundleShortVersionString 18 | $(FLUTTER_BUILD_NAME) 19 | CFBundleSignature 20 | ???? 21 | CFBundleVersion 22 | $(FLUTTER_BUILD_NUMBER) 23 | LSRequiresIPhoneOS 24 | 25 | UILaunchStoryboardName 26 | LaunchScreen 27 | UIMainStoryboardFile 28 | Main 29 | UISupportedInterfaceOrientations 30 | 31 | UIInterfaceOrientationPortrait 32 | UIInterfaceOrientationLandscapeLeft 33 | UIInterfaceOrientationLandscapeRight 34 | 35 | UISupportedInterfaceOrientations~ipad 36 | 37 | UIInterfaceOrientationPortrait 38 | UIInterfaceOrientationPortraitUpsideDown 39 | UIInterfaceOrientationLandscapeLeft 40 | UIInterfaceOrientationLandscapeRight 41 | 42 | UIViewControllerBasedStatusBarAppearance 43 | 44 | 45 | 46 | -------------------------------------------------------------------------------- /ios/Runner/Base.lproj/Main.storyboard: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | -------------------------------------------------------------------------------- /lib/date_select_button.dart: -------------------------------------------------------------------------------- 1 | import 'package:flutter/material.dart'; 2 | import 'package:flutter_todos_redux/base_select.dart'; 3 | 4 | class DateSelectButton extends StatelessWidget { 5 | final String text; 6 | final bool selected; 7 | final ValueChanged onChange; 8 | 9 | const DateSelectButton({ 10 | Key key, 11 | this.text, 12 | this.selected = false, 13 | this.onChange, 14 | }) : super(key: key); 15 | 16 | Widget _buildtext(color) { 17 | return Padding( 18 | padding: EdgeInsets.all(10.0), 19 | child: Text( 20 | text, 21 | style: TextStyle(color: color), 22 | ), 23 | ); 24 | } 25 | 26 | Widget _buildContainer(Color color, [Color fillColor]) { 27 | return Container( 28 | decoration: BoxDecoration( 29 | color: fillColor != null ? fillColor : Colors.white, 30 | border: Border.all( 31 | color: color, 32 | width: 1.0, 33 | ), 34 | ), 35 | child: fillColor != null ? _buildtext(Colors.white) : _buildtext(color), 36 | ); 37 | } 38 | 39 | @override 40 | Widget build(BuildContext context) { 41 | return BaseSelect( 42 | selected: selected, 43 | onChange: onChange, 44 | builder: (BuildContext context, Animation animation) { 45 | return Stack( 46 | alignment: Alignment.center, 47 | children: [ 48 | _buildContainer(Colors.grey), 49 | SizeTransition( 50 | sizeFactor: animation, 51 | axis: Axis.horizontal, 52 | child: _buildContainer( 53 | Colors.blue.withOpacity(0.8), Colors.blue.withOpacity(0.8)), 54 | ), 55 | ], 56 | ); 57 | }, 58 | ); 59 | } 60 | } 61 | -------------------------------------------------------------------------------- /lib/base_select.dart: -------------------------------------------------------------------------------- 1 | import 'package:flutter/material.dart'; 2 | 3 | class BaseSelect extends StatefulWidget { 4 | final bool selected; 5 | final ValueChanged onChange; 6 | final Function(BuildContext, Animation) builder; 7 | 8 | const BaseSelect( 9 | {Key key, this.selected = false, this.onChange, @required this.builder}) 10 | : super(key: key); 11 | 12 | @override 13 | _MyRadioButtonState createState() => _MyRadioButtonState(); 14 | } 15 | 16 | class _MyRadioButtonState extends State 17 | with SingleTickerProviderStateMixin { 18 | bool _checked; 19 | AnimationController _controller; 20 | 21 | initState() { 22 | super.initState(); 23 | _checked = widget.selected; 24 | _controller = AnimationController( 25 | duration: Duration(milliseconds: 200), 26 | value: _checked ? 1.0 : 0.0, 27 | vsync: this, 28 | ); 29 | } 30 | 31 | @override 32 | void didUpdateWidget(BaseSelect oldWidget) { 33 | super.didUpdateWidget(oldWidget); 34 | _checked = widget.selected; 35 | if (_checked) { 36 | _controller.forward(); 37 | } else { 38 | _controller.reverse(); 39 | } 40 | } 41 | 42 | @override 43 | dispose() { 44 | _controller.dispose(); 45 | super.dispose(); 46 | } 47 | 48 | _toggle() { 49 | setState(() { 50 | _checked = !_checked; 51 | if (widget.onChange != null && widget.onChange is Function(bool)) { 52 | widget.onChange(_checked); 53 | } 54 | if (_checked) { 55 | _controller.forward(); 56 | } else { 57 | _controller.reverse(); 58 | } 59 | }); 60 | } 61 | 62 | @override 63 | Widget build(BuildContext context) { 64 | return GestureDetector( 65 | onTap: _toggle, 66 | child: widget.builder(context, _controller), 67 | ); 68 | } 69 | } 70 | -------------------------------------------------------------------------------- /lib/redux/selectors/selectors.dart: -------------------------------------------------------------------------------- 1 | import 'package:flutter_todos_redux/models/catergory_model.dart'; 2 | import 'package:flutter_todos_redux/models/current_tab.dart'; 3 | import 'package:flutter_todos_redux/models/todo_model.dart'; 4 | 5 | int totalTodos(List todos) { 6 | return todos.length; 7 | } 8 | 9 | int completedTodos(List todos) { 10 | return todos.where((todo) => todo.completed).length; 11 | } 12 | 13 | List allCategoryTodosSelector( 14 | Category category, List todos, bool completed) { 15 | return todos.where((todo) { 16 | return todo.category.name == category.name && todo.completed == completed; 17 | }).toList(); 18 | } 19 | 20 | List upcomingTodosSelector(CurrentTab currentTab, List todos) { 21 | final now = DateTime.now(); 22 | final endOfToday = DateTime.utc(now.year, now.month, now.day, 24); 23 | final endOfWeek = 24 | DateTime.utc(now.year, now.month, now.day + (7 - now.weekday), 24); 25 | 26 | switch (currentTab) { 27 | case CurrentTab.Today: 28 | return todos 29 | .where((todo) { 30 | return todo.date.isBefore(endOfToday); 31 | }) 32 | .take(3) 33 | .toList(); 34 | break; 35 | case CurrentTab.Week: 36 | return todos 37 | .where((todo) { 38 | return todo.date.isAfter(endOfToday) && 39 | todo.date.isBefore(endOfWeek); 40 | }) 41 | .take(3) 42 | .toList(); 43 | break; 44 | case CurrentTab.Month: 45 | return todos 46 | .where((todo) { 47 | return todo.date.isAfter(endOfWeek) && 48 | todo.date.isBefore(now.add(Duration(days: 31 - now.day))); 49 | }) 50 | .take(3) 51 | .toList(); 52 | break; 53 | default: 54 | return todos; 55 | break; 56 | } 57 | } 58 | -------------------------------------------------------------------------------- /.idea/codeStyles/Project.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 15 | 16 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | -------------------------------------------------------------------------------- /android/app/build.gradle: -------------------------------------------------------------------------------- 1 | def localProperties = new Properties() 2 | def localPropertiesFile = rootProject.file('local.properties') 3 | if (localPropertiesFile.exists()) { 4 | localPropertiesFile.withReader('UTF-8') { reader -> 5 | localProperties.load(reader) 6 | } 7 | } 8 | 9 | def flutterRoot = localProperties.getProperty('flutter.sdk') 10 | if (flutterRoot == null) { 11 | throw new GradleException("Flutter SDK not found. Define location with flutter.sdk in the local.properties file.") 12 | } 13 | 14 | def flutterVersionCode = localProperties.getProperty('flutter.versionCode') 15 | if (flutterVersionCode == null) { 16 | flutterVersionCode = '1' 17 | } 18 | 19 | def flutterVersionName = localProperties.getProperty('flutter.versionName') 20 | if (flutterVersionName == null) { 21 | flutterVersionName = '1.0' 22 | } 23 | 24 | apply plugin: 'com.android.application' 25 | apply from: "$flutterRoot/packages/flutter_tools/gradle/flutter.gradle" 26 | 27 | android { 28 | compileSdkVersion 27 29 | 30 | lintOptions { 31 | disable 'InvalidPackage' 32 | } 33 | 34 | defaultConfig { 35 | // TODO: Specify your own unique Application ID (https://developer.android.com/studio/build/application-id.html). 36 | applicationId "com.example.fluttertodosredux" 37 | minSdkVersion 16 38 | targetSdkVersion 27 39 | versionCode flutterVersionCode.toInteger() 40 | versionName flutterVersionName 41 | testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner" 42 | } 43 | 44 | buildTypes { 45 | release { 46 | // TODO: Add your own signing config for the release build. 47 | // Signing with the debug keys for now, so `flutter run --release` works. 48 | signingConfig signingConfigs.debug 49 | } 50 | } 51 | } 52 | 53 | flutter { 54 | source '../..' 55 | } 56 | 57 | dependencies { 58 | testImplementation 'junit:junit:4.12' 59 | androidTestImplementation 'com.android.support.test:runner:1.0.2' 60 | androidTestImplementation 'com.android.support.test.espresso:espresso-core:3.0.2' 61 | } 62 | -------------------------------------------------------------------------------- /android/app/src/main/AndroidManifest.xml: -------------------------------------------------------------------------------- 1 | 3 | 4 | 8 | 9 | 10 | 15 | 19 | 26 | 30 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | 40 | -------------------------------------------------------------------------------- /lib/main.dart: -------------------------------------------------------------------------------- 1 | // import 'package:redux/redux.dart'; 2 | import 'package:flutter_redux/flutter_redux.dart'; 3 | 4 | import 'package:flutter/material.dart'; 5 | import 'package:flutter_todos_redux/home.dart'; 6 | import 'package:flutter_todos_redux/models/app_state.dart'; 7 | import 'package:flutter_todos_redux/redux/actions/edit_actions.dart'; 8 | import 'package:flutter_todos_redux/redux/reducers/app_reducer.dart'; 9 | import 'package:redux/redux.dart'; 10 | 11 | main(List args) { 12 | runApp(MyApp()); 13 | } 14 | 15 | class MyApp extends StatelessWidget { 16 | final Store store = 17 | Store(appReducer, initialState: AppState.initial()); 18 | 19 | @override 20 | Widget build(BuildContext context) { 21 | return StoreProvider( 22 | store: store, 23 | child: MaterialApp( 24 | title: 'Todos...', 25 | theme: _myTheme, 26 | home: WillPopScope( 27 | onWillPop: () async { 28 | if (store.state.editing) { 29 | store.dispatch(ToggleEditingStatusAction(editing: false)); 30 | } 31 | }, 32 | child: HomePage(), 33 | ), 34 | ), 35 | ); 36 | } 37 | } 38 | 39 | final ThemeData _myTheme = _buildTheme(); 40 | 41 | ThemeData _buildTheme() { 42 | final ThemeData base = ThemeData.light(); 43 | return base.copyWith( 44 | textTheme: _buildTextTheme(base.textTheme), 45 | // primaryTextTheme: _buildTextTheme(base.primaryTextTheme), 46 | // accentTextTheme: _buildTextTheme(base.accentTextTheme), 47 | ); 48 | } 49 | 50 | TextTheme _buildTextTheme(TextTheme base) { 51 | return base 52 | .copyWith( 53 | headline: base.headline.copyWith( 54 | fontSize: 30.0, 55 | fontWeight: FontWeight.bold, 56 | letterSpacing: -1.0, 57 | ), 58 | title: base.title.copyWith( 59 | fontSize: 20.0, 60 | fontWeight: FontWeight.bold, 61 | ), 62 | body2: base.body2.copyWith( 63 | fontWeight: FontWeight.w900, 64 | fontSize: 16.0, 65 | // letterSpacing: -1.0, 66 | ), 67 | ) 68 | .apply( 69 | fontFamily: 'Poppins', 70 | ); 71 | } 72 | -------------------------------------------------------------------------------- /lib/all_todo_grid_tile.dart: -------------------------------------------------------------------------------- 1 | import 'package:flutter/material.dart'; 2 | import 'package:flutter_todos_redux/models/catergory_model.dart'; 3 | import 'package:flutter_todos_redux/todos_list_page.dart'; 4 | 5 | class AllTodosGridTile extends StatelessWidget { 6 | final Category category; 7 | 8 | const AllTodosGridTile({Key key, this.category}) : super(key: key); 9 | 10 | @override 11 | Widget build(BuildContext context) { 12 | return Stack( 13 | fit: StackFit.expand, 14 | overflow: Overflow.visible, 15 | children: [ 16 | Positioned( 17 | right: 0.0, 18 | top: -5.0, 19 | child: Hero( 20 | tag: 'border-${category.name}', 21 | child: Container( 22 | color: category.color, 23 | width: 20.0, 24 | height: 5.0, 25 | ), 26 | ), 27 | ), 28 | Container( 29 | padding: EdgeInsets.all(18.0), 30 | color: Colors.white, 31 | child: Column( 32 | crossAxisAlignment: CrossAxisAlignment.start, 33 | children: [ 34 | Expanded( 35 | child: Container( 36 | padding: EdgeInsets.only(bottom: 25.0), 37 | child: Icon(category.icon, color: category.color), 38 | ), 39 | ), 40 | Hero( 41 | tag: 'name-${category.name}', 42 | child: Text( 43 | category.name, 44 | style: Theme.of(context).textTheme.body2, 45 | ), 46 | ), 47 | Padding( 48 | padding: EdgeInsets.only(top: 7.0), 49 | child: Text('${category.todosNumber.toString()} todos'), 50 | ), 51 | ], 52 | ), 53 | ), 54 | Material( 55 | color: Colors.transparent, 56 | child: InkWell( 57 | splashColor: category.color, 58 | onTap: () { 59 | Navigator.of(context).push(MaterialPageRoute( 60 | builder: (BuildContext context) { 61 | return TodosPage(category: category); 62 | }, 63 | )); 64 | }, 65 | ), 66 | ), 67 | ], 68 | ); 69 | } 70 | } 71 | -------------------------------------------------------------------------------- /pubspec.yaml: -------------------------------------------------------------------------------- 1 | name: flutter_todos_redux 2 | description: A new Flutter project. 3 | 4 | # The following defines the version and build number for your application. 5 | # A version number is three numbers separated by dots, like 1.2.43 6 | # followed by an optional build number separated by a +. 7 | # Both the version and the builder number may be overridden in flutter 8 | # build by specifying --build-name and --build-number, respectively. 9 | # Read more about versioning at semver.org. 10 | version: 1.0.0+1 11 | 12 | environment: 13 | sdk: ">=2.0.0-dev.68.0 <3.0.0" 14 | 15 | dependencies: 16 | flutter: 17 | sdk: flutter 18 | 19 | # The following adds the Cupertino Icons font to your application. 20 | # Use with the CupertinoIcons class for iOS style icons. 21 | cupertino_icons: ^0.1.2 22 | flutter_redux: ^0.5.2 23 | flutter_redux_dev_tools: ^0.3.0 24 | 25 | dev_dependencies: 26 | flutter_test: 27 | sdk: flutter 28 | 29 | # For information on the generic Dart part of this file, see the 30 | # following page: https://www.dartlang.org/tools/pub/pubspec 31 | 32 | # The following section is specific to Flutter. 33 | flutter: 34 | # The following line ensures that the Material Icons font is 35 | # included with your application, so that you can use the icons in 36 | # the material Icons class. 37 | uses-material-design: true 38 | 39 | # To add assets to your application, add an assets section, like this: 40 | # assets: 41 | # - images/a_dot_burr.jpeg 42 | # - images/a_dot_ham.jpeg 43 | 44 | # An image asset can refer to one or more resolution-specific "variants", see 45 | # https://flutter.io/assets-and-images/#resolution-aware. 46 | 47 | # For details regarding adding assets from package dependencies, see 48 | # https://flutter.io/assets-and-images/#from-packages 49 | 50 | # To add custom fonts to your application, add a fonts section here, 51 | # in this "flutter" section. Each entry in this list should have a 52 | # "family" key with the font family name, and a "fonts" key with a 53 | # list giving the asset and other descriptors for the font. For 54 | # example: 55 | fonts: 56 | - family: Poppins 57 | fonts: 58 | - asset: assets/fonts/PoppinsRegular.ttf 59 | - asset: assets/fonts/PoppinsBold.ttf 60 | # weight: 700 61 | # 62 | # For details regarding fonts from package dependencies, 63 | # see https://flutter.io/custom-fonts/#from-packages 64 | -------------------------------------------------------------------------------- /ios/Runner/Base.lproj/LaunchScreen.storyboard: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | -------------------------------------------------------------------------------- /android/gradlew.bat: -------------------------------------------------------------------------------- 1 | @if "%DEBUG%" == "" @echo off 2 | @rem ########################################################################## 3 | @rem 4 | @rem Gradle startup script for Windows 5 | @rem 6 | @rem ########################################################################## 7 | 8 | @rem Set local scope for the variables with windows NT shell 9 | if "%OS%"=="Windows_NT" setlocal 10 | 11 | @rem Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script. 12 | set DEFAULT_JVM_OPTS= 13 | 14 | set DIRNAME=%~dp0 15 | if "%DIRNAME%" == "" set DIRNAME=. 16 | set APP_BASE_NAME=%~n0 17 | set APP_HOME=%DIRNAME% 18 | 19 | @rem Find java.exe 20 | if defined JAVA_HOME goto findJavaFromJavaHome 21 | 22 | set JAVA_EXE=java.exe 23 | %JAVA_EXE% -version >NUL 2>&1 24 | if "%ERRORLEVEL%" == "0" goto init 25 | 26 | echo. 27 | echo ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH. 28 | echo. 29 | echo Please set the JAVA_HOME variable in your environment to match the 30 | echo location of your Java installation. 31 | 32 | goto fail 33 | 34 | :findJavaFromJavaHome 35 | set JAVA_HOME=%JAVA_HOME:"=% 36 | set JAVA_EXE=%JAVA_HOME%/bin/java.exe 37 | 38 | if exist "%JAVA_EXE%" goto init 39 | 40 | echo. 41 | echo ERROR: JAVA_HOME is set to an invalid directory: %JAVA_HOME% 42 | echo. 43 | echo Please set the JAVA_HOME variable in your environment to match the 44 | echo location of your Java installation. 45 | 46 | goto fail 47 | 48 | :init 49 | @rem Get command-line arguments, handling Windowz variants 50 | 51 | if not "%OS%" == "Windows_NT" goto win9xME_args 52 | if "%@eval[2+2]" == "4" goto 4NT_args 53 | 54 | :win9xME_args 55 | @rem Slurp the command line arguments. 56 | set CMD_LINE_ARGS= 57 | set _SKIP=2 58 | 59 | :win9xME_args_slurp 60 | if "x%~1" == "x" goto execute 61 | 62 | set CMD_LINE_ARGS=%* 63 | goto execute 64 | 65 | :4NT_args 66 | @rem Get arguments from the 4NT Shell from JP Software 67 | set CMD_LINE_ARGS=%$ 68 | 69 | :execute 70 | @rem Setup the command line 71 | 72 | set CLASSPATH=%APP_HOME%\gradle\wrapper\gradle-wrapper.jar 73 | 74 | @rem Execute Gradle 75 | "%JAVA_EXE%" %DEFAULT_JVM_OPTS% %JAVA_OPTS% %GRADLE_OPTS% "-Dorg.gradle.appname=%APP_BASE_NAME%" -classpath "%CLASSPATH%" org.gradle.wrapper.GradleWrapperMain %CMD_LINE_ARGS% 76 | 77 | :end 78 | @rem End local scope for the variables with windows NT shell 79 | if "%ERRORLEVEL%"=="0" goto mainEnd 80 | 81 | :fail 82 | rem Set variable GRADLE_EXIT_CONSOLE if you need the _script_ return code instead of 83 | rem the _cmd.exe /c_ return code! 84 | if not "" == "%GRADLE_EXIT_CONSOLE%" exit 1 85 | exit /b 1 86 | 87 | :mainEnd 88 | if "%OS%"=="Windows_NT" endlocal 89 | 90 | :omega 91 | -------------------------------------------------------------------------------- /lib/home.dart: -------------------------------------------------------------------------------- 1 | import 'package:flutter/material.dart'; 2 | import 'package:flutter_redux/flutter_redux.dart'; 3 | import 'package:flutter_todos_redux/add_todo_button.dart'; 4 | import 'package:flutter_todos_redux/add_todo_form.dart'; 5 | import 'package:flutter_todos_redux/main_layer.dart'; 6 | import 'package:flutter_todos_redux/models/app_state.dart'; 7 | import 'package:flutter_todos_redux/models/catergory_model.dart'; 8 | import 'package:flutter_todos_redux/models/todo_model.dart'; 9 | import 'package:flutter_todos_redux/redux/actions/edit_actions.dart'; 10 | import 'package:flutter_todos_redux/redux/actions/todo_actions.dart'; 11 | import 'package:redux/redux.dart'; 12 | 13 | class HomePage extends StatelessWidget { 14 | @override 15 | Widget build(BuildContext context) { 16 | return Scaffold( 17 | body: Stack( 18 | fit: StackFit.expand, 19 | children: [ 20 | MainLayer(), 21 | AddTodoLayer(), 22 | ], 23 | ), 24 | ); 25 | } 26 | } 27 | 28 | class AddTodoLayer extends StatelessWidget { 29 | @override 30 | Widget build(BuildContext context) { 31 | final Size size = MediaQuery.of(context).size; 32 | 33 | return StoreConnector( 34 | converter: (Store store) => _ViewModel.create(store), 35 | builder: (BuildContext context, _ViewModel vm) { 36 | return Stack( 37 | fit: StackFit.expand, 38 | children: [ 39 | AddTodoForm( 40 | editing: vm.editing, 41 | categories: vm.categories, 42 | size: size, 43 | toggleEditingStatus: vm.toggleEditingStatus, 44 | addTodo: vm.addTodo, 45 | ), 46 | AddTodoButton( 47 | editing: vm.editing, 48 | size: size, 49 | onClick: () { 50 | if (vm.editing) { 51 | vm.toggleEditingStatus(false); 52 | } else { 53 | vm.toggleEditingStatus(true); 54 | } 55 | }, 56 | // addTodo: vm.addTodo 57 | ), 58 | ], 59 | ); 60 | }, 61 | ); 62 | } 63 | } 64 | 65 | class _ViewModel { 66 | final List categories; 67 | final bool editing; 68 | final Function(bool) toggleEditingStatus; 69 | final Function(Todo) addTodo; 70 | 71 | _ViewModel({ 72 | this.categories, 73 | this.editing, 74 | this.toggleEditingStatus, 75 | this.addTodo, 76 | }); 77 | 78 | factory _ViewModel.create(Store store) { 79 | return _ViewModel( 80 | categories: store.state.categories, 81 | editing: store.state.editing, 82 | toggleEditingStatus: (bool status) => 83 | store.dispatch(ToggleEditingStatusAction(editing: status)), 84 | addTodo: (Todo todo) => store.dispatch(AddTodoAction(todo)), 85 | ); 86 | } 87 | } 88 | -------------------------------------------------------------------------------- /lib/todos_list.dart: -------------------------------------------------------------------------------- 1 | import 'package:flutter/material.dart'; 2 | import 'package:flutter_redux/flutter_redux.dart'; 3 | import 'package:flutter_todos_redux/models/app_state.dart'; 4 | import 'package:flutter_todos_redux/models/catergory_model.dart'; 5 | import 'package:flutter_todos_redux/models/current_tab.dart'; 6 | import 'package:flutter_todos_redux/models/todo_model.dart'; 7 | import 'package:flutter_todos_redux/redux/actions/todo_actions.dart'; 8 | import 'package:flutter_todos_redux/redux/selectors/selectors.dart'; 9 | import 'package:flutter_todos_redux/todo_tile.dart'; 10 | import 'package:redux/redux.dart'; 11 | 12 | class TodosList extends StatelessWidget { 13 | final Category currentCategory; 14 | final bool showCompleted; 15 | 16 | const TodosList({Key key, this.currentCategory, this.showCompleted}) 17 | : super(key: key); 18 | 19 | List _buildTodoList(List todos, _ViewModel vm) { 20 | return todos 21 | .map( 22 | (todo) => Padding( 23 | padding: const EdgeInsets.only(bottom: 30.0), 24 | child: TodoTile( 25 | todo: todo, 26 | updateTodo: vm.updateTodo, 27 | deleteTodo: vm.deleteTodo, 28 | ), 29 | ), 30 | ) 31 | .toList(); 32 | } 33 | 34 | @override 35 | Widget build(BuildContext context) { 36 | return StoreConnector( 37 | converter: (Store store) => _ViewModel.create(store), 38 | builder: (BuildContext context, _ViewModel vm) { 39 | List todos; 40 | if (currentCategory != null) { 41 | todos = allCategoryTodosSelector( 42 | currentCategory, vm.todos, showCompleted); 43 | } else { 44 | todos = upcomingTodosSelector(vm.currentTab, vm.todos); 45 | } 46 | if (todos.length == 0) { 47 | return Center(child: Text('Yeah👏!! you have no todos...')); 48 | } 49 | return Padding( 50 | padding: const EdgeInsets.only(top: 30.0), 51 | child: Column( 52 | children: _buildTodoList(todos, vm), 53 | ), 54 | ); 55 | }, 56 | ); 57 | } 58 | } 59 | 60 | class _ViewModel { 61 | final CurrentTab currentTab; 62 | final List todos; 63 | final Function(Todo) deleteTodo; 64 | final Function(String, Todo) updateTodo; 65 | 66 | _ViewModel({ 67 | this.currentTab, 68 | this.todos, 69 | this.deleteTodo, 70 | this.updateTodo, 71 | }); 72 | 73 | factory _ViewModel.create(Store store) { 74 | return _ViewModel( 75 | currentTab: store.state.currentTab, 76 | todos: store.state.todos, 77 | deleteTodo: (Todo todo) => store.dispatch(DeleteTodoAction(todo)), 78 | updateTodo: (String id, Todo todo) => 79 | store.dispatch(UpdateTodoAction(id: id, updatedTodo: todo))); 80 | } 81 | } 82 | -------------------------------------------------------------------------------- /lib/todo_tile.dart: -------------------------------------------------------------------------------- 1 | import 'package:flutter/material.dart'; 2 | import 'package:flutter_todos_redux/helpers/format_date.dart'; 3 | import 'package:flutter_todos_redux/models/todo_model.dart'; 4 | import 'package:flutter_todos_redux/my_radio_button.dart'; 5 | 6 | class TodoTile extends StatelessWidget { 7 | final Todo todo; 8 | final Function(Todo) deleteTodo; 9 | final Function(String, Todo) updateTodo; 10 | 11 | const TodoTile({Key key, this.todo, this.deleteTodo, this.updateTodo}) 12 | : super(key: key); 13 | 14 | Widget _buildTodoText(BuildContext context) { 15 | return Column( 16 | crossAxisAlignment: CrossAxisAlignment.start, 17 | children: [ 18 | Text( 19 | '${todo.text}', 20 | overflow: TextOverflow.ellipsis, 21 | style: Theme.of(context).textTheme.title, 22 | ), 23 | Padding( 24 | padding: const EdgeInsets.only(top: 12.0), 25 | child: Text( 26 | '${todo.category.name}${formattedDateTime(todo.date, todo.time, context)}'), 27 | ), 28 | ], 29 | ); 30 | } 31 | 32 | Widget _buildDismmissableBackground(Color color) { 33 | return Container( 34 | padding: EdgeInsets.symmetric(horizontal: 20.0), 35 | decoration: BoxDecoration( 36 | gradient: LinearGradient( 37 | colors: [ 38 | color, 39 | Colors.redAccent, 40 | ], 41 | ), 42 | ), 43 | child: Row( 44 | mainAxisAlignment: MainAxisAlignment.spaceBetween, 45 | children: [ 46 | Icon( 47 | Icons.check, 48 | color: Colors.white, 49 | ), 50 | Icon( 51 | Icons.delete, 52 | color: Colors.white, 53 | ), 54 | ], 55 | ), 56 | ); 57 | } 58 | 59 | @override 60 | Widget build(BuildContext context) { 61 | return Dismissible( 62 | key: Key(todo.id), 63 | onDismissed: (DismissDirection direction) { 64 | if (direction == DismissDirection.endToStart) { 65 | deleteTodo(todo); 66 | } else if (direction == DismissDirection.startToEnd) { 67 | updateTodo(todo.id, todo.copyWith(completed: true)); 68 | } 69 | }, 70 | background: _buildDismmissableBackground(todo.category.color), 71 | child: Row( 72 | children: [ 73 | Padding( 74 | padding: const EdgeInsets.only(left: 2.0, right: 30.0), 75 | child: MyRadioButton( 76 | selected: todo.completed, 77 | color: todo.category.color, 78 | onChange: (newVal) { 79 | updateTodo(todo.id, todo.copyWith(completed: newVal)); 80 | }, 81 | ), 82 | ), 83 | Expanded( 84 | child: _buildTodoText(context), 85 | ), 86 | ], 87 | ), 88 | ); 89 | } 90 | } 91 | -------------------------------------------------------------------------------- /lib/todos_list_page.dart: -------------------------------------------------------------------------------- 1 | import 'package:flutter/material.dart'; 2 | import 'package:flutter_todos_redux/models/catergory_model.dart'; 3 | import 'package:flutter_todos_redux/todos_list.dart'; 4 | 5 | class TodosPage extends StatefulWidget { 6 | const TodosPage({ 7 | Key key, 8 | @required this.category, 9 | }) : super(key: key); 10 | 11 | final Category category; 12 | 13 | @override 14 | TodosPageState createState() { 15 | return new TodosPageState(); 16 | } 17 | } 18 | 19 | class TodosPageState extends State 20 | with SingleTickerProviderStateMixin { 21 | TabController _tabControlller; 22 | final List _tabs = [ 23 | Tab( 24 | text: 'UPCOMING', 25 | ), 26 | Tab( 27 | text: 'COMPLETED', 28 | ), 29 | ]; 30 | 31 | @override 32 | void initState() { 33 | super.initState(); 34 | _tabControlller = TabController(length: _tabs.length, vsync: this); 35 | } 36 | 37 | @override 38 | void dispose() { 39 | _tabControlller.dispose(); 40 | super.dispose(); 41 | } 42 | 43 | @override 44 | Widget build(BuildContext context) { 45 | return Material( 46 | color: Colors.white, 47 | child: Column( 48 | children: [ 49 | Hero( 50 | tag: 'border-${widget.category.name}', 51 | child: Container( 52 | padding: EdgeInsets.only(top: 20.0), 53 | color: widget.category.color, 54 | width: double.infinity, 55 | height: 85.0, 56 | child: Center( 57 | child: Hero( 58 | tag: 'name-${widget.category.name}', 59 | child: Text( 60 | widget.category.name, 61 | style: Theme.of(context).textTheme.title.copyWith( 62 | color: Colors.white, 63 | ), 64 | ), 65 | ), 66 | ), 67 | ), 68 | ), 69 | TabBar( 70 | controller: _tabControlller, 71 | tabs: _tabs, 72 | indicatorColor: Colors.grey, 73 | labelColor: Colors.black, 74 | labelStyle: Theme.of(context).textTheme.body2, 75 | ), 76 | Expanded( 77 | child: Padding( 78 | padding: const EdgeInsets.symmetric(horizontal: 16.0), 79 | child: TabBarView( 80 | controller: _tabControlller, 81 | children: [ 82 | TodosList( 83 | currentCategory: widget.category, 84 | showCompleted: false, 85 | ), 86 | TodosList( 87 | currentCategory: widget.category, 88 | showCompleted: true, 89 | ), 90 | ], 91 | ), 92 | ), 93 | ), 94 | ], 95 | ), 96 | ); 97 | } 98 | } 99 | -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/AppIcon.appiconset/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "images" : [ 3 | { 4 | "size" : "20x20", 5 | "idiom" : "iphone", 6 | "filename" : "Icon-App-20x20@2x.png", 7 | "scale" : "2x" 8 | }, 9 | { 10 | "size" : "20x20", 11 | "idiom" : "iphone", 12 | "filename" : "Icon-App-20x20@3x.png", 13 | "scale" : "3x" 14 | }, 15 | { 16 | "size" : "29x29", 17 | "idiom" : "iphone", 18 | "filename" : "Icon-App-29x29@1x.png", 19 | "scale" : "1x" 20 | }, 21 | { 22 | "size" : "29x29", 23 | "idiom" : "iphone", 24 | "filename" : "Icon-App-29x29@2x.png", 25 | "scale" : "2x" 26 | }, 27 | { 28 | "size" : "29x29", 29 | "idiom" : "iphone", 30 | "filename" : "Icon-App-29x29@3x.png", 31 | "scale" : "3x" 32 | }, 33 | { 34 | "size" : "40x40", 35 | "idiom" : "iphone", 36 | "filename" : "Icon-App-40x40@2x.png", 37 | "scale" : "2x" 38 | }, 39 | { 40 | "size" : "40x40", 41 | "idiom" : "iphone", 42 | "filename" : "Icon-App-40x40@3x.png", 43 | "scale" : "3x" 44 | }, 45 | { 46 | "size" : "60x60", 47 | "idiom" : "iphone", 48 | "filename" : "Icon-App-60x60@2x.png", 49 | "scale" : "2x" 50 | }, 51 | { 52 | "size" : "60x60", 53 | "idiom" : "iphone", 54 | "filename" : "Icon-App-60x60@3x.png", 55 | "scale" : "3x" 56 | }, 57 | { 58 | "size" : "20x20", 59 | "idiom" : "ipad", 60 | "filename" : "Icon-App-20x20@1x.png", 61 | "scale" : "1x" 62 | }, 63 | { 64 | "size" : "20x20", 65 | "idiom" : "ipad", 66 | "filename" : "Icon-App-20x20@2x.png", 67 | "scale" : "2x" 68 | }, 69 | { 70 | "size" : "29x29", 71 | "idiom" : "ipad", 72 | "filename" : "Icon-App-29x29@1x.png", 73 | "scale" : "1x" 74 | }, 75 | { 76 | "size" : "29x29", 77 | "idiom" : "ipad", 78 | "filename" : "Icon-App-29x29@2x.png", 79 | "scale" : "2x" 80 | }, 81 | { 82 | "size" : "40x40", 83 | "idiom" : "ipad", 84 | "filename" : "Icon-App-40x40@1x.png", 85 | "scale" : "1x" 86 | }, 87 | { 88 | "size" : "40x40", 89 | "idiom" : "ipad", 90 | "filename" : "Icon-App-40x40@2x.png", 91 | "scale" : "2x" 92 | }, 93 | { 94 | "size" : "76x76", 95 | "idiom" : "ipad", 96 | "filename" : "Icon-App-76x76@1x.png", 97 | "scale" : "1x" 98 | }, 99 | { 100 | "size" : "76x76", 101 | "idiom" : "ipad", 102 | "filename" : "Icon-App-76x76@2x.png", 103 | "scale" : "2x" 104 | }, 105 | { 106 | "size" : "83.5x83.5", 107 | "idiom" : "ipad", 108 | "filename" : "Icon-App-83.5x83.5@2x.png", 109 | "scale" : "2x" 110 | }, 111 | { 112 | "size" : "1024x1024", 113 | "idiom" : "ios-marketing", 114 | "filename" : "Icon-App-1024x1024@1x.png", 115 | "scale" : "1x" 116 | } 117 | ], 118 | "info" : { 119 | "version" : 1, 120 | "author" : "xcode" 121 | } 122 | } 123 | -------------------------------------------------------------------------------- /lib/my_radio_button.dart: -------------------------------------------------------------------------------- 1 | import 'package:flutter/material.dart'; 2 | import 'package:flutter_todos_redux/base_select.dart'; 3 | 4 | class MyRadioButton extends StatelessWidget { 5 | final double size; 6 | final bool selected; 7 | final Color color; 8 | final ValueChanged onChange; 9 | 10 | const MyRadioButton({ 11 | Key key, 12 | this.size = 30.0, 13 | this.selected = false, 14 | this.color = Colors.grey, 15 | this.onChange, 16 | }) : super(key: key); 17 | // @override 18 | // _MyRadioButtonState createState() => _MyRadioButtonState(); 19 | // } 20 | 21 | // class _MyRadioButtonState extends State 22 | // with SingleTickerProviderStateMixin { 23 | // bool _checked; 24 | // AnimationController _controller; 25 | 26 | // initState() { 27 | // super.initState(); 28 | // _checked = widget.initialValue; 29 | // _controller = AnimationController( 30 | // duration: Duration(milliseconds: 200), 31 | // value: _checked ? 1.0 : 0.0, 32 | // vsync: this, 33 | // ); 34 | // } 35 | 36 | // @override 37 | // void didUpdateWidget(MyRadioButton oldWidget) { 38 | // super.didUpdateWidget(oldWidget); 39 | // if (widget.initialValue != oldWidget.initialValue) { 40 | // _checked = widget.initialValue; 41 | // if (_checked) { 42 | // _controller.forward(); 43 | // } else { 44 | // _controller.reverse(); 45 | // } 46 | // } 47 | // } 48 | 49 | // @override 50 | // dispose() { 51 | // _controller.dispose(); 52 | // super.dispose(); 53 | // } 54 | 55 | // _toggle() { 56 | // setState(() { 57 | // _checked = !_checked; 58 | // if (widget.onChange != null && widget.onChange is Function(bool)) { 59 | // widget.onChange(_checked); 60 | // } 61 | // if (_checked) { 62 | // _controller.forward(); 63 | // } else { 64 | // _controller.reverse(); 65 | // } 66 | // }); 67 | // } 68 | 69 | @override 70 | Widget build(BuildContext context) { 71 | return BaseSelect( 72 | selected: selected, 73 | onChange: onChange, 74 | builder: (BuildContext context, Animation animation) { 75 | return Container( 76 | width: size, 77 | height: size, 78 | child: CustomPaint( 79 | painter: MyRadioButtonPainter( 80 | animation: animation, checked: true, color: color), 81 | ), 82 | ); 83 | }, 84 | ); 85 | } 86 | } 87 | 88 | class MyRadioButtonPainter extends CustomPainter { 89 | final Animation animation; 90 | final Color color; 91 | final bool checked; 92 | 93 | MyRadioButtonPainter({this.animation, this.checked, this.color}) 94 | : super(repaint: animation); 95 | 96 | @override 97 | void paint(Canvas canvas, Size size) { 98 | // print('rebuilding radio....$checked'); 99 | final Offset center = Offset(size.width / 2, size.height / 2); 100 | final Paint borderPaint = Paint() 101 | ..color = color 102 | ..strokeWidth = 3.0 103 | ..style = PaintingStyle.stroke; 104 | 105 | final Paint innerCirclePaint = Paint() 106 | ..color = color.withOpacity(animation.value); 107 | 108 | canvas.drawCircle(center, size.width / 2, borderPaint); 109 | // if (checked) { 110 | canvas.drawCircle(center, size.width / 2 - 5.0, innerCirclePaint); 111 | // } 112 | } 113 | 114 | @override 115 | bool shouldRepaint(MyRadioButtonPainter oldDelegate) { 116 | return oldDelegate.checked != checked; 117 | } 118 | } 119 | -------------------------------------------------------------------------------- /ios/Runner.xcodeproj/xcshareddata/xcschemes/Runner.xcscheme: -------------------------------------------------------------------------------- 1 | 2 | 5 | 8 | 9 | 15 | 21 | 22 | 23 | 24 | 25 | 31 | 32 | 33 | 34 | 40 | 41 | 42 | 43 | 44 | 45 | 56 | 58 | 64 | 65 | 66 | 67 | 68 | 69 | 75 | 77 | 83 | 84 | 85 | 86 | 88 | 89 | 92 | 93 | 94 | -------------------------------------------------------------------------------- /lib/user_info.dart: -------------------------------------------------------------------------------- 1 | import 'dart:math'; 2 | 3 | import 'package:flutter/material.dart'; 4 | import 'package:flutter_redux/flutter_redux.dart'; 5 | import 'package:flutter_todos_redux/models/app_state.dart'; 6 | import 'package:flutter_todos_redux/models/todo_model.dart'; 7 | import 'package:flutter_todos_redux/redux/selectors/selectors.dart'; 8 | import 'package:redux/redux.dart'; 9 | 10 | class UserInfo extends StatelessWidget { 11 | @override 12 | Widget build(BuildContext context) { 13 | return Container( 14 | padding: EdgeInsets.only(bottom: 25.0, right: 5.0), 15 | child: StoreConnector>( 16 | converter: (Store store) => store.state.todos, 17 | builder: (BuildContext context, List todos) { 18 | final int total = totalTodos(todos); 19 | final int completed = completedTodos(todos); 20 | final double percent = completed / total; 21 | 22 | return Row( 23 | mainAxisAlignment: MainAxisAlignment.spaceBetween, 24 | children: [ 25 | Expanded( 26 | child: Column( 27 | crossAxisAlignment: CrossAxisAlignment.start, 28 | children: [ 29 | Text( 30 | 'Hey Mathew,', 31 | overflow: TextOverflow.ellipsis, 32 | style: Theme.of(context).textTheme.headline, 33 | ), 34 | Padding( 35 | padding: const EdgeInsets.only(top: 8.0), 36 | child: RichText( 37 | text: TextSpan( 38 | text: 'Hello ', 39 | style: DefaultTextStyle.of(context).style, 40 | children: [ 41 | TextSpan( 42 | text: 'Loook like feel good.\n', 43 | ), 44 | TextSpan(text: 'You have $total tasks to do.'), 45 | ], 46 | ), 47 | ), 48 | ) 49 | ], 50 | ), 51 | ), 52 | CustomPaint( 53 | size: Size(35.0, 35.0), 54 | painter: 55 | TodosProgress(percentDone: total > 0 ? percent : null), 56 | ), 57 | ], 58 | ); 59 | }, 60 | )); 61 | } 62 | } 63 | 64 | class TodosProgress extends CustomPainter { 65 | final double percentDone; 66 | 67 | TodosProgress({this.percentDone}); 68 | @override 69 | void paint(Canvas canvas, Size size) { 70 | final double radius = size.width / 2; 71 | final Rect arcRect = 72 | Rect.fromCircle(center: Offset(radius, radius), radius: radius); 73 | final Paint paint = Paint() 74 | ..style = PaintingStyle.stroke 75 | ..strokeWidth = 5.0; 76 | if (percentDone != null) { 77 | canvas 78 | ..drawArc( 79 | arcRect, 80 | -pi / 2, 81 | 2 * pi * percentDone, 82 | false, 83 | paint..color = Colors.red, 84 | ); 85 | 86 | canvas.drawArc( 87 | arcRect, 88 | -pi / 2, 89 | -2 * pi * (1.0 - percentDone), 90 | false, 91 | paint..color = Colors.grey[300], 92 | ); 93 | } 94 | } 95 | 96 | @override 97 | bool shouldRepaint(TodosProgress oldDelegate) { 98 | return oldDelegate.percentDone != percentDone; 99 | } 100 | } 101 | -------------------------------------------------------------------------------- /lib/add_todo_button.dart: -------------------------------------------------------------------------------- 1 | import 'package:flutter/material.dart'; 2 | 3 | class AddTodoButton extends StatefulWidget { 4 | final Function onClick; 5 | //screen size 6 | final Size size; 7 | final bool editing; 8 | 9 | const AddTodoButton({ 10 | Key key, 11 | this.onClick, 12 | this.size, 13 | this.editing, 14 | }) : super(key: key); 15 | 16 | @override 17 | _AddTodoButtonState createState() => _AddTodoButtonState(); 18 | } 19 | 20 | class _AddTodoButtonState extends State 21 | with SingleTickerProviderStateMixin { 22 | ButtonState buttonState = ButtonState.Small; 23 | AnimationController _controller; 24 | Animation _buttonAnimation; 25 | Animation _buttonTextAnimation; 26 | 27 | @override 28 | void initState() { 29 | super.initState(); 30 | _controller = 31 | AnimationController(duration: Duration(milliseconds: 450), vsync: this); 32 | 33 | _buttonTextAnimation = Tween(begin: 0.0, end: 1.0).animate( 34 | CurvedAnimation(curve: Interval(0.7, 1.0), parent: _controller)); 35 | } 36 | 37 | @override 38 | void didUpdateWidget(AddTodoButton oldWidget) { 39 | if (widget.editing != oldWidget.editing) { 40 | _controller.value == 1.0 ? _controller.reverse() : _controller.forward(); 41 | } 42 | super.didUpdateWidget(oldWidget); 43 | } 44 | 45 | @override 46 | void dispose() { 47 | _controller.dispose(); 48 | super.dispose(); 49 | } 50 | 51 | void _handleClick() { 52 | if (buttonState == ButtonState.Small) { 53 | _controller.forward(); 54 | buttonState = ButtonState.Enlarged; 55 | } else { 56 | buttonState = ButtonState.Small; 57 | _controller.reverse(); 58 | } 59 | widget.onClick(); 60 | } 61 | 62 | @override 63 | Widget build(BuildContext context) { 64 | final Size size = widget.size; 65 | final Size buttonSize = Size(75.0, 75.0); 66 | final double top = size.height - buttonSize.height; 67 | final double initialLeftRight = (size.width - buttonSize.width) / 2; 68 | 69 | _buttonAnimation = RelativeRectTween( 70 | begin: RelativeRect.fromLTRB( 71 | initialLeftRight, top - 25.0, initialLeftRight, 25.0), 72 | end: RelativeRect.fromLTRB(0.0, top, 0.0, 0.0), 73 | ).animate(CurvedAnimation(curve: Interval(0.0, 0.7), parent: _controller)); 74 | 75 | return PositionedTransition( 76 | rect: _buttonAnimation, 77 | child: Container( 78 | width: double.infinity, 79 | height: double.infinity, 80 | decoration: BoxDecoration( 81 | gradient: LinearGradient( 82 | colors: [ 83 | Color.fromRGBO(111, 94, 230, 1.0), 84 | Color.fromRGBO(127, 110, 235, 1.0), 85 | ], 86 | ), 87 | ), 88 | child: Material( 89 | color: Colors.transparent, 90 | child: InkWell( 91 | onTap: _handleClick, 92 | child: Row( 93 | mainAxisAlignment: MainAxisAlignment.center, 94 | children: [ 95 | Icon( 96 | Icons.add, 97 | color: Colors.white, 98 | ), 99 | SizeTransition( 100 | sizeFactor: _buttonTextAnimation, 101 | axis: Axis.horizontal, 102 | axisAlignment: -1.0, 103 | child: Center( 104 | child: Text( 105 | 'ADD TODO', 106 | style: TextStyle( 107 | color: Colors.white, 108 | ), 109 | ), 110 | ), 111 | ), 112 | ], 113 | ), 114 | ), 115 | ), 116 | ), 117 | ); 118 | } 119 | } 120 | 121 | enum ButtonState { Small, Enlarged } 122 | -------------------------------------------------------------------------------- /lib/tasks_view.dart: -------------------------------------------------------------------------------- 1 | import 'package:flutter/material.dart'; 2 | import 'package:flutter_redux/flutter_redux.dart'; 3 | import 'package:flutter_todos_redux/models/app_state.dart'; 4 | import 'package:flutter_todos_redux/models/current_tab.dart'; 5 | import 'package:flutter_todos_redux/redux/actions/tab_actions.dart'; 6 | import 'package:flutter_todos_redux/todos_list.dart'; 7 | import 'package:redux/redux.dart'; 8 | 9 | class TasksView extends StatefulWidget { 10 | @override 11 | _TasksViewState createState() => _TasksViewState(); 12 | } 13 | 14 | class _TasksViewState extends State 15 | with SingleTickerProviderStateMixin { 16 | TabController _tabController; 17 | Store _store; 18 | final List _tabs = [ 19 | Tab( 20 | child: Row(children: [Text('TODAY')]), 21 | ), 22 | Tab( 23 | child: Row(children: [Text('WEEK')]), 24 | ), 25 | Tab( 26 | child: Row(children: [Text('MONTH')]), 27 | ), 28 | ]; 29 | 30 | @override 31 | void initState() { 32 | super.initState(); 33 | _tabController = TabController(length: _tabs.length, vsync: this); 34 | } 35 | 36 | @override 37 | void didChangeDependencies() { 38 | super.didChangeDependencies(); 39 | _store = StoreProvider.of(context); 40 | _tabController.addListener(() { 41 | if (!_tabController.indexIsChanging) { 42 | switch (_tabController.index) { 43 | case 0: 44 | _store.dispatch(SetCurrentTabAction(CurrentTab.Today)); 45 | break; 46 | case 1: 47 | _store.dispatch(SetCurrentTabAction(CurrentTab.Week)); 48 | break; 49 | case 2: 50 | _store.dispatch(SetCurrentTabAction(CurrentTab.Month)); 51 | break; 52 | } 53 | } 54 | }); 55 | } 56 | 57 | @override 58 | void dispose() { 59 | _tabController.dispose(); 60 | super.dispose(); 61 | } 62 | 63 | @override 64 | Widget build(BuildContext context) { 65 | return Container( 66 | padding: const EdgeInsets.only( 67 | top: 18.0, 68 | ), 69 | child: Column( 70 | children: [ 71 | _MyTabBar(tabController: _tabController, tabs: _tabs), 72 | Expanded( 73 | child: _MyTabBarView(tabController: _tabController), 74 | ), 75 | ], 76 | ), 77 | ); 78 | } 79 | } 80 | 81 | class _MyTabBar extends StatelessWidget { 82 | const _MyTabBar({ 83 | Key key, 84 | @required TabController tabController, 85 | @required List tabs, 86 | }) : _tabController = tabController, 87 | _tabs = tabs, 88 | super(key: key); 89 | 90 | final TabController _tabController; 91 | final List _tabs; 92 | 93 | @override 94 | Widget build(BuildContext context) { 95 | return TabBar( 96 | indicator: UnderlineTabIndicator( 97 | borderSide: const BorderSide( 98 | width: 5.0, 99 | color: const Color.fromRGBO(86, 83, 195, 1.0), 100 | ), 101 | insets: const EdgeInsets.only(right: 100.0), 102 | ), 103 | controller: _tabController, 104 | tabs: _tabs.toList(), 105 | labelColor: Colors.black, 106 | labelPadding: EdgeInsets.all(0.0), 107 | labelStyle: Theme.of(context).textTheme.body2, 108 | unselectedLabelColor: Colors.grey, 109 | ); 110 | } 111 | } 112 | 113 | class _MyTabBarView extends StatelessWidget { 114 | const _MyTabBarView({ 115 | Key key, 116 | @required TabController tabController, 117 | }) : _tabController = tabController, 118 | super(key: key); 119 | 120 | final TabController _tabController; 121 | 122 | @override 123 | Widget build(BuildContext context) { 124 | return TabBarView( 125 | controller: _tabController, 126 | children: [ 127 | TodosList(key: Key('today')), 128 | TodosList(key: Key('week')), 129 | TodosList(key: Key('month')), 130 | ], 131 | ); 132 | } 133 | } 134 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # flutter_todos_redux 2 | 3 | A Flutter hobby project using redux for state management. The UI has been inspired from a [dribbble](https://dribbble.com/shots/5261578-Task-Manager-TODO-Interaction-UX) by [DhipuMathew](https://dribbble.com/DhipuMathew). 4 | 5 | ## Screenshots 6 | 7 | ![GIF](https://cdn.dribbble.com/users/673583/screenshots/5261578/dribbble1.gif) 8 | 9 | ![home page](https://i.imgur.com/u5GcRmU.png) ![add todo](https://i.imgur.com/aHdVLVG.png) 10 | 11 | I have been playing with flutter for about 3 weeks(sep 2018). This is my very first flutter app I built to check out the framework. The codebase is not well structured and also can be coded better. It is me just playing with the framework and quickly prototyping a working app. 12 | 13 | ## Architecture of the app 14 | 15 | The App's state consists of: 16 | 17 | 1. list of todos 18 | 2. current tab the user is on i.e ''today'' or ''week'' or ''month'' 19 | 3. boolean `editing` 20 | 4. list of categories 21 | 22 | The app consists of two pages: 23 | 24 | 1. **_home page_**: it displays the user info, the tab view showing the upcoming todos and the todo categoris grid view. 25 | 2. **_todos list page_**: displays all the todos belonging to a particular category. 26 | 27 | ##### The Home Page 28 | 29 | The home page is essentially a [Stack](https://docs.flutter.io/flutter/widgets/Stack-class.html) widget consisting of two layers: 30 | 31 | 1. Main Layer: This layer displays the appbar, user info, the upcoming todos(in a tabbed view) and all the todo categories. 32 | 2. AddTodo Layer: This consists of the 'ADD TODO' button and the form that appears when the button is clicked. 33 | 34 | Explanation of the add todo animation: 35 | 36 | The AddTodo layer is a Stack itself. This stack consist of two children: 37 | 38 | 1. [AddTodoForm](https://github.com/rvamsikrishna/flutter_todos_redux/blob/master/lib/add_todo_form.dart) 39 | 2. [AddTodoButton](https://github.com/rvamsikrishna/flutter_todos_redux/blob/master/lib/add_todo_button.dart) 40 | 41 | These both are [PositionedTransition](https://docs.flutter.io/flutter/widgets/PositionedTransition-class.html) widgets which is the animated version of Positioned widgets. 42 | 43 | The initial position of the form is completely pushed of the screen downwards which is derived from the RelativeRectTween as below: 44 | 45 | ```dart 46 | _rectAnimation = RelativeRectTween( 47 | begin: RelativeRect.fromLTRB(0.0, size.height, 0.0, -size.height), 48 | end: RelativeRect.fromLTRB(0.0, 0.0, 0.0, 0.0), 49 | ).animate(_animCntroller); 50 | 51 | ... 52 | ... 53 | ... 54 | 55 | @override 56 | Widget build(BuildContext context) { 57 | return PositionedTransition( 58 | rect: _rectAnimation, 59 | child: Column( 60 | ... 61 | ), 62 | ); 63 | } 64 | 65 | ``` 66 | 67 | Similarly the button also has its own animations which control its position and the button text. These animations are deferred using an [Interval](https://docs.flutter.io/flutter/animation/Interval-class.html). The button moves down and expands for the 70% of the animation and the the text animates for the remaining 30% 68 | 69 | ```dart 70 | //animation that animates the position: 0.0 -> 0.7 71 | _buttonAnimation = RelativeRectTween( 72 | begin: RelativeRect.fromLTRB( 73 | initialLeftRight, top - 25.0, initialLeftRight, 25.0), 74 | end: RelativeRect.fromLTRB(0.0, top, 0.0, 0.0), 75 | ).animate(CurvedAnimation(curve: Interval(0.0, 0.7), parent: _controller)); 76 | 77 | 78 | //animation that animates the text: 0.7 -> 1.0 79 | _buttonTextAnimation = Tween(begin: 0.0, end: 1.0).animate( 80 | CurvedAnimation(curve: Interval(0.7, 1.0), parent: _controller)); 81 | ``` 82 | 83 | When the button is pressed initially it triggers a redux action mutating the `editing` state of the store to `true`. This causes the re-render of the widgets. Both these widgets has a `didUpdateWidget` lifecycle hook. This lifecycle hook gets called when the widget's parent rebuilds and passes new properties to the widgets. In this lifecycle hook we perform the animation depending on the `editing` property. 84 | -------------------------------------------------------------------------------- /android/gradlew: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env bash 2 | 3 | ############################################################################## 4 | ## 5 | ## Gradle start up script for UN*X 6 | ## 7 | ############################################################################## 8 | 9 | # Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script. 10 | DEFAULT_JVM_OPTS="" 11 | 12 | APP_NAME="Gradle" 13 | APP_BASE_NAME=`basename "$0"` 14 | 15 | # Use the maximum available, or set MAX_FD != -1 to use that value. 16 | MAX_FD="maximum" 17 | 18 | warn ( ) { 19 | echo "$*" 20 | } 21 | 22 | die ( ) { 23 | echo 24 | echo "$*" 25 | echo 26 | exit 1 27 | } 28 | 29 | # OS specific support (must be 'true' or 'false'). 30 | cygwin=false 31 | msys=false 32 | darwin=false 33 | case "`uname`" in 34 | CYGWIN* ) 35 | cygwin=true 36 | ;; 37 | Darwin* ) 38 | darwin=true 39 | ;; 40 | MINGW* ) 41 | msys=true 42 | ;; 43 | esac 44 | 45 | # Attempt to set APP_HOME 46 | # Resolve links: $0 may be a link 47 | PRG="$0" 48 | # Need this for relative symlinks. 49 | while [ -h "$PRG" ] ; do 50 | ls=`ls -ld "$PRG"` 51 | link=`expr "$ls" : '.*-> \(.*\)$'` 52 | if expr "$link" : '/.*' > /dev/null; then 53 | PRG="$link" 54 | else 55 | PRG=`dirname "$PRG"`"/$link" 56 | fi 57 | done 58 | SAVED="`pwd`" 59 | cd "`dirname \"$PRG\"`/" >/dev/null 60 | APP_HOME="`pwd -P`" 61 | cd "$SAVED" >/dev/null 62 | 63 | CLASSPATH=$APP_HOME/gradle/wrapper/gradle-wrapper.jar 64 | 65 | # Determine the Java command to use to start the JVM. 66 | if [ -n "$JAVA_HOME" ] ; then 67 | if [ -x "$JAVA_HOME/jre/sh/java" ] ; then 68 | # IBM's JDK on AIX uses strange locations for the executables 69 | JAVACMD="$JAVA_HOME/jre/sh/java" 70 | else 71 | JAVACMD="$JAVA_HOME/bin/java" 72 | fi 73 | if [ ! -x "$JAVACMD" ] ; then 74 | die "ERROR: JAVA_HOME is set to an invalid directory: $JAVA_HOME 75 | 76 | Please set the JAVA_HOME variable in your environment to match the 77 | location of your Java installation." 78 | fi 79 | else 80 | JAVACMD="java" 81 | which java >/dev/null 2>&1 || die "ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH. 82 | 83 | Please set the JAVA_HOME variable in your environment to match the 84 | location of your Java installation." 85 | fi 86 | 87 | # Increase the maximum file descriptors if we can. 88 | if [ "$cygwin" = "false" -a "$darwin" = "false" ] ; then 89 | MAX_FD_LIMIT=`ulimit -H -n` 90 | if [ $? -eq 0 ] ; then 91 | if [ "$MAX_FD" = "maximum" -o "$MAX_FD" = "max" ] ; then 92 | MAX_FD="$MAX_FD_LIMIT" 93 | fi 94 | ulimit -n $MAX_FD 95 | if [ $? -ne 0 ] ; then 96 | warn "Could not set maximum file descriptor limit: $MAX_FD" 97 | fi 98 | else 99 | warn "Could not query maximum file descriptor limit: $MAX_FD_LIMIT" 100 | fi 101 | fi 102 | 103 | # For Darwin, add options to specify how the application appears in the dock 104 | if $darwin; then 105 | GRADLE_OPTS="$GRADLE_OPTS \"-Xdock:name=$APP_NAME\" \"-Xdock:icon=$APP_HOME/media/gradle.icns\"" 106 | fi 107 | 108 | # For Cygwin, switch paths to Windows format before running java 109 | if $cygwin ; then 110 | APP_HOME=`cygpath --path --mixed "$APP_HOME"` 111 | CLASSPATH=`cygpath --path --mixed "$CLASSPATH"` 112 | JAVACMD=`cygpath --unix "$JAVACMD"` 113 | 114 | # We build the pattern for arguments to be converted via cygpath 115 | ROOTDIRSRAW=`find -L / -maxdepth 1 -mindepth 1 -type d 2>/dev/null` 116 | SEP="" 117 | for dir in $ROOTDIRSRAW ; do 118 | ROOTDIRS="$ROOTDIRS$SEP$dir" 119 | SEP="|" 120 | done 121 | OURCYGPATTERN="(^($ROOTDIRS))" 122 | # Add a user-defined pattern to the cygpath arguments 123 | if [ "$GRADLE_CYGPATTERN" != "" ] ; then 124 | OURCYGPATTERN="$OURCYGPATTERN|($GRADLE_CYGPATTERN)" 125 | fi 126 | # Now convert the arguments - kludge to limit ourselves to /bin/sh 127 | i=0 128 | for arg in "$@" ; do 129 | CHECK=`echo "$arg"|egrep -c "$OURCYGPATTERN" -` 130 | CHECK2=`echo "$arg"|egrep -c "^-"` ### Determine if an option 131 | 132 | if [ $CHECK -ne 0 ] && [ $CHECK2 -eq 0 ] ; then ### Added a condition 133 | eval `echo args$i`=`cygpath --path --ignore --mixed "$arg"` 134 | else 135 | eval `echo args$i`="\"$arg\"" 136 | fi 137 | i=$((i+1)) 138 | done 139 | case $i in 140 | (0) set -- ;; 141 | (1) set -- "$args0" ;; 142 | (2) set -- "$args0" "$args1" ;; 143 | (3) set -- "$args0" "$args1" "$args2" ;; 144 | (4) set -- "$args0" "$args1" "$args2" "$args3" ;; 145 | (5) set -- "$args0" "$args1" "$args2" "$args3" "$args4" ;; 146 | (6) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" ;; 147 | (7) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" ;; 148 | (8) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" "$args7" ;; 149 | (9) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" "$args7" "$args8" ;; 150 | esac 151 | fi 152 | 153 | # Split up the JVM_OPTS And GRADLE_OPTS values into an array, following the shell quoting and substitution rules 154 | function splitJvmOpts() { 155 | JVM_OPTS=("$@") 156 | } 157 | eval splitJvmOpts $DEFAULT_JVM_OPTS $JAVA_OPTS $GRADLE_OPTS 158 | JVM_OPTS[${#JVM_OPTS[*]}]="-Dorg.gradle.appname=$APP_BASE_NAME" 159 | 160 | exec "$JAVACMD" "${JVM_OPTS[@]}" -classpath "$CLASSPATH" org.gradle.wrapper.GradleWrapperMain "$@" 161 | -------------------------------------------------------------------------------- /lib/add_todo_form.dart: -------------------------------------------------------------------------------- 1 | import 'dart:async'; 2 | 3 | import 'package:flutter/material.dart'; 4 | import 'package:flutter_todos_redux/date_select_button.dart'; 5 | import 'package:flutter_todos_redux/models/catergory_model.dart'; 6 | import 'package:flutter_todos_redux/models/selected_day.dart'; 7 | import 'package:flutter_todos_redux/models/todo_model.dart'; 8 | import 'package:flutter_todos_redux/my_radio_button.dart'; 9 | 10 | class AddTodoForm extends StatefulWidget { 11 | final bool editing; 12 | final List categories; 13 | //screen size 14 | final Size size; 15 | final Function(bool) toggleEditingStatus; 16 | final Function(Todo) addTodo; 17 | 18 | const AddTodoForm({ 19 | Key key, 20 | this.editing, 21 | this.categories, 22 | this.size, 23 | this.toggleEditingStatus, 24 | this.addTodo, 25 | }) : super(key: key); 26 | 27 | @override 28 | AddTodoFormState createState() { 29 | return new AddTodoFormState(); 30 | } 31 | } 32 | 33 | class AddTodoFormState extends State 34 | with SingleTickerProviderStateMixin { 35 | final GlobalKey _formKey = GlobalKey(); 36 | TextEditingController _textController; 37 | AnimationController _animCntroller; 38 | ScrollController _scrollController; 39 | Animation _rectAnimation; 40 | Map _formData = { 41 | 'text': null, 42 | 'category': null, 43 | 'date': null, 44 | 'time': null, 45 | }; 46 | SelectedDay _selectedDate; 47 | 48 | void _setInitial() { 49 | _formData['text'] = ''; 50 | _formData['category'] = widget.categories[0]; 51 | _formData['date'] = DateTime.now().add(Duration(hours: 1)); 52 | _formData['time'] = TimeOfDay.now(); 53 | _selectedDate = SelectedDay.Today; 54 | } 55 | 56 | @override 57 | void initState() { 58 | super.initState(); 59 | _setInitial(); 60 | _scrollController = ScrollController(); 61 | _textController = TextEditingController(); 62 | _animCntroller = AnimationController( 63 | duration: Duration(milliseconds: 300), value: 0.0, vsync: this); 64 | 65 | final Size size = widget.size; 66 | _rectAnimation = RelativeRectTween( 67 | begin: RelativeRect.fromLTRB(0.0, size.height, 0.0, -size.height), 68 | end: RelativeRect.fromLTRB(0.0, 0.0, 0.0, 0.0), 69 | ).animate(_animCntroller); 70 | } 71 | 72 | @override 73 | void didUpdateWidget(AddTodoForm oldWidget) { 74 | if (widget.editing != oldWidget.editing) { 75 | if (!widget.editing) { 76 | _formKey.currentState.save(); 77 | if (_formData['text'].isEmpty) { 78 | widget.toggleEditingStatus(false); 79 | } else { 80 | widget.addTodo(Todo.fromMap(_formData)); 81 | } 82 | _textController.text = ''; 83 | _setInitial(); 84 | _scrollController.animateTo(0.0, 85 | curve: Curves.ease, duration: Duration(microseconds: 100)); 86 | } 87 | _animCntroller.fling(velocity: widget.editing ? 1.0 : -1.0); 88 | } 89 | 90 | super.didUpdateWidget(oldWidget); 91 | } 92 | 93 | @override 94 | void dispose() { 95 | _textController.dispose(); 96 | _animCntroller.dispose(); 97 | _scrollController.dispose(); 98 | super.dispose(); 99 | } 100 | 101 | Widget _buildTodoTextInput() { 102 | return TextFormField( 103 | controller: _textController, 104 | decoration: InputDecoration( 105 | hintText: 'enter your todo', 106 | focusedBorder: UnderlineInputBorder( 107 | borderSide: BorderSide(color: Colors.grey), 108 | ), 109 | ), 110 | onSaved: (String text) { 111 | _formData['text'] = text; 112 | }, 113 | ); 114 | } 115 | 116 | Row _buildDateSelectionRow() { 117 | return Row( 118 | children: [ 119 | DateSelectButton( 120 | text: 'Today', 121 | selected: _selectedDate == SelectedDay.Today, 122 | onChange: (bool selected) { 123 | print('today toggled'); 124 | _handleDateChange(selected, DateTime.now(), SelectedDay.Today); 125 | }, 126 | ), 127 | SizedBox(width: 10.0), 128 | DateSelectButton( 129 | text: 'Tommorow', 130 | selected: _selectedDate == SelectedDay.Tommorow, 131 | onChange: (bool selected) { 132 | print('tommorow toggled'); 133 | _handleDateChange( 134 | selected, 135 | DateTime.now().add(Duration(days: 1)), 136 | SelectedDay.Tommorow, 137 | ); 138 | }, 139 | ), 140 | SizedBox(width: 10.0), 141 | DateSelectButton( 142 | text: 'Date', 143 | selected: _selectedDate == SelectedDay.Custom, 144 | onChange: (bool selected) async { 145 | final DateTime date = await _selectDate(); 146 | _handleDateChange(true, date, SelectedDay.Custom); 147 | }, 148 | ), 149 | ], 150 | ); 151 | } 152 | 153 | Future _selectDate() { 154 | return showDatePicker( 155 | context: context, 156 | firstDate: DateTime.now().add(Duration(days: 2)), 157 | initialDate: _selectedDate != SelectedDay.Custom 158 | ? DateTime.now().add(Duration(days: 3)) 159 | : _formData['date'], 160 | lastDate: DateTime.now().add(Duration(days: 10000)), 161 | ); 162 | } 163 | 164 | Column _buildCategorySelection() { 165 | return Column( 166 | children: widget.categories.map((Category cat) { 167 | final bool selected = _formData['category']?.name == cat.name; 168 | return ListTile( 169 | contentPadding: EdgeInsets.symmetric(vertical: 6.0, horizontal: 0.0), 170 | title: Text( 171 | '${cat.name}', 172 | style: Theme.of(context).textTheme.body2, 173 | ), 174 | leading: MyRadioButton( 175 | color: cat.color, 176 | selected: selected, 177 | onChange: (newVal) { 178 | _handleCategoryChange(newVal, cat); 179 | }, 180 | ), 181 | onTap: () { 182 | print('tapped'); 183 | if (selected) { 184 | _handleCategoryChange(false, cat); 185 | } else { 186 | _handleCategoryChange(true, cat); 187 | } 188 | }, 189 | ); 190 | }).toList(), 191 | ); 192 | } 193 | 194 | Widget _buildTimeSelection() { 195 | final TimeOfDay time = _formData['time']; 196 | return Row( 197 | children: [ 198 | DateSelectButton( 199 | text: '${time.hour} : ${time.minute}', 200 | selected: _formData['time'] != null, 201 | onChange: (bool selected) async { 202 | final TimeOfDay time = await _selectTime(); 203 | setState(() { 204 | _formData['time'] = time; 205 | }); 206 | }, 207 | ), 208 | ], 209 | ); 210 | } 211 | 212 | Future _selectTime() { 213 | return showTimePicker( 214 | context: context, 215 | initialTime: TimeOfDay.now(), 216 | ); 217 | } 218 | 219 | void _handleDateChange( 220 | bool selected, DateTime date, SelectedDay selectedDate) { 221 | setState(() { 222 | if (selected) { 223 | _formData['date'] = date; 224 | _selectedDate = selectedDate; 225 | } else { 226 | _formData['date'] = null; 227 | _selectedDate = null; 228 | } 229 | }); 230 | } 231 | 232 | void _handleCategoryChange(bool newVal, Category category) { 233 | setState(() { 234 | if (newVal) { 235 | _formData['category'] = category; 236 | } else { 237 | _formData['category'] = null; 238 | } 239 | }); 240 | } 241 | 242 | @override 243 | Widget build(BuildContext context) { 244 | return PositionedTransition( 245 | rect: _rectAnimation, 246 | child: Column( 247 | children: [ 248 | Expanded( 249 | flex: 2, 250 | child: GestureDetector( 251 | onTap: () => widget.toggleEditingStatus(false), 252 | child: Container( 253 | color: Colors.black.withOpacity(0.3), 254 | ), 255 | ), 256 | ), 257 | Expanded( 258 | flex: 3, 259 | child: Form( 260 | key: _formKey, 261 | child: Container( 262 | width: double.infinity, 263 | height: double.infinity, 264 | color: Colors.white, 265 | padding: EdgeInsets.only(bottom: 75.0), 266 | child: ListView( 267 | controller: _scrollController, 268 | padding: EdgeInsets.all(25.0), 269 | shrinkWrap: true, 270 | children: [ 271 | Text( 272 | 'Create new todo', 273 | style: Theme.of(context).textTheme.headline, 274 | ), 275 | _buildTodoTextInput(), 276 | SizedBox(height: 25.0), 277 | _buildDateSelectionRow(), 278 | SizedBox(height: 25.0), 279 | _buildTimeSelection(), 280 | SizedBox(height: 25.0), 281 | _buildCategorySelection(), 282 | ], 283 | ), 284 | ), 285 | ), 286 | ), 287 | ], 288 | ), 289 | ); 290 | } 291 | } 292 | -------------------------------------------------------------------------------- /pubspec.lock: -------------------------------------------------------------------------------- 1 | # Generated by pub 2 | # See https://www.dartlang.org/tools/pub/glossary#lockfile 3 | packages: 4 | analyzer: 5 | dependency: transitive 6 | description: 7 | name: analyzer 8 | url: "https://pub.dartlang.org" 9 | source: hosted 10 | version: "0.32.4" 11 | args: 12 | dependency: transitive 13 | description: 14 | name: args 15 | url: "https://pub.dartlang.org" 16 | source: hosted 17 | version: "1.5.0" 18 | async: 19 | dependency: transitive 20 | description: 21 | name: async 22 | url: "https://pub.dartlang.org" 23 | source: hosted 24 | version: "2.0.8" 25 | boolean_selector: 26 | dependency: transitive 27 | description: 28 | name: boolean_selector 29 | url: "https://pub.dartlang.org" 30 | source: hosted 31 | version: "1.0.4" 32 | charcode: 33 | dependency: transitive 34 | description: 35 | name: charcode 36 | url: "https://pub.dartlang.org" 37 | source: hosted 38 | version: "1.1.2" 39 | collection: 40 | dependency: transitive 41 | description: 42 | name: collection 43 | url: "https://pub.dartlang.org" 44 | source: hosted 45 | version: "1.14.11" 46 | convert: 47 | dependency: transitive 48 | description: 49 | name: convert 50 | url: "https://pub.dartlang.org" 51 | source: hosted 52 | version: "2.0.2" 53 | crypto: 54 | dependency: transitive 55 | description: 56 | name: crypto 57 | url: "https://pub.dartlang.org" 58 | source: hosted 59 | version: "2.0.6" 60 | csslib: 61 | dependency: transitive 62 | description: 63 | name: csslib 64 | url: "https://pub.dartlang.org" 65 | source: hosted 66 | version: "0.14.5" 67 | cupertino_icons: 68 | dependency: "direct main" 69 | description: 70 | name: cupertino_icons 71 | url: "https://pub.dartlang.org" 72 | source: hosted 73 | version: "0.1.2" 74 | flutter: 75 | dependency: "direct main" 76 | description: flutter 77 | source: sdk 78 | version: "0.0.0" 79 | flutter_redux: 80 | dependency: "direct main" 81 | description: 82 | name: flutter_redux 83 | url: "https://pub.dartlang.org" 84 | source: hosted 85 | version: "0.5.2" 86 | flutter_redux_dev_tools: 87 | dependency: "direct main" 88 | description: 89 | name: flutter_redux_dev_tools 90 | url: "https://pub.dartlang.org" 91 | source: hosted 92 | version: "0.3.0" 93 | flutter_test: 94 | dependency: "direct dev" 95 | description: flutter 96 | source: sdk 97 | version: "0.0.0" 98 | front_end: 99 | dependency: transitive 100 | description: 101 | name: front_end 102 | url: "https://pub.dartlang.org" 103 | source: hosted 104 | version: "0.1.4" 105 | glob: 106 | dependency: transitive 107 | description: 108 | name: glob 109 | url: "https://pub.dartlang.org" 110 | source: hosted 111 | version: "1.1.7" 112 | html: 113 | dependency: transitive 114 | description: 115 | name: html 116 | url: "https://pub.dartlang.org" 117 | source: hosted 118 | version: "0.13.3+3" 119 | http: 120 | dependency: transitive 121 | description: 122 | name: http 123 | url: "https://pub.dartlang.org" 124 | source: hosted 125 | version: "0.11.3+17" 126 | http_multi_server: 127 | dependency: transitive 128 | description: 129 | name: http_multi_server 130 | url: "https://pub.dartlang.org" 131 | source: hosted 132 | version: "2.0.5" 133 | http_parser: 134 | dependency: transitive 135 | description: 136 | name: http_parser 137 | url: "https://pub.dartlang.org" 138 | source: hosted 139 | version: "3.1.3" 140 | io: 141 | dependency: transitive 142 | description: 143 | name: io 144 | url: "https://pub.dartlang.org" 145 | source: hosted 146 | version: "0.3.3" 147 | js: 148 | dependency: transitive 149 | description: 150 | name: js 151 | url: "https://pub.dartlang.org" 152 | source: hosted 153 | version: "0.6.1+1" 154 | json_rpc_2: 155 | dependency: transitive 156 | description: 157 | name: json_rpc_2 158 | url: "https://pub.dartlang.org" 159 | source: hosted 160 | version: "2.0.9" 161 | kernel: 162 | dependency: transitive 163 | description: 164 | name: kernel 165 | url: "https://pub.dartlang.org" 166 | source: hosted 167 | version: "0.3.4" 168 | logging: 169 | dependency: transitive 170 | description: 171 | name: logging 172 | url: "https://pub.dartlang.org" 173 | source: hosted 174 | version: "0.11.3+2" 175 | matcher: 176 | dependency: transitive 177 | description: 178 | name: matcher 179 | url: "https://pub.dartlang.org" 180 | source: hosted 181 | version: "0.12.3+1" 182 | meta: 183 | dependency: transitive 184 | description: 185 | name: meta 186 | url: "https://pub.dartlang.org" 187 | source: hosted 188 | version: "1.1.6" 189 | mime: 190 | dependency: transitive 191 | description: 192 | name: mime 193 | url: "https://pub.dartlang.org" 194 | source: hosted 195 | version: "0.9.6+2" 196 | multi_server_socket: 197 | dependency: transitive 198 | description: 199 | name: multi_server_socket 200 | url: "https://pub.dartlang.org" 201 | source: hosted 202 | version: "1.0.2" 203 | node_preamble: 204 | dependency: transitive 205 | description: 206 | name: node_preamble 207 | url: "https://pub.dartlang.org" 208 | source: hosted 209 | version: "1.4.4" 210 | package_config: 211 | dependency: transitive 212 | description: 213 | name: package_config 214 | url: "https://pub.dartlang.org" 215 | source: hosted 216 | version: "1.0.5" 217 | package_resolver: 218 | dependency: transitive 219 | description: 220 | name: package_resolver 221 | url: "https://pub.dartlang.org" 222 | source: hosted 223 | version: "1.0.4" 224 | path: 225 | dependency: transitive 226 | description: 227 | name: path 228 | url: "https://pub.dartlang.org" 229 | source: hosted 230 | version: "1.6.2" 231 | plugin: 232 | dependency: transitive 233 | description: 234 | name: plugin 235 | url: "https://pub.dartlang.org" 236 | source: hosted 237 | version: "0.2.0+3" 238 | pool: 239 | dependency: transitive 240 | description: 241 | name: pool 242 | url: "https://pub.dartlang.org" 243 | source: hosted 244 | version: "1.3.6" 245 | pub_semver: 246 | dependency: transitive 247 | description: 248 | name: pub_semver 249 | url: "https://pub.dartlang.org" 250 | source: hosted 251 | version: "1.4.2" 252 | quiver: 253 | dependency: transitive 254 | description: 255 | name: quiver 256 | url: "https://pub.dartlang.org" 257 | source: hosted 258 | version: "2.0.0+1" 259 | redux: 260 | dependency: transitive 261 | description: 262 | name: redux 263 | url: "https://pub.dartlang.org" 264 | source: hosted 265 | version: "3.0.0" 266 | redux_dev_tools: 267 | dependency: transitive 268 | description: 269 | name: redux_dev_tools 270 | url: "https://pub.dartlang.org" 271 | source: hosted 272 | version: "0.4.0" 273 | shelf: 274 | dependency: transitive 275 | description: 276 | name: shelf 277 | url: "https://pub.dartlang.org" 278 | source: hosted 279 | version: "0.7.3+3" 280 | shelf_packages_handler: 281 | dependency: transitive 282 | description: 283 | name: shelf_packages_handler 284 | url: "https://pub.dartlang.org" 285 | source: hosted 286 | version: "1.0.4" 287 | shelf_static: 288 | dependency: transitive 289 | description: 290 | name: shelf_static 291 | url: "https://pub.dartlang.org" 292 | source: hosted 293 | version: "0.2.8" 294 | shelf_web_socket: 295 | dependency: transitive 296 | description: 297 | name: shelf_web_socket 298 | url: "https://pub.dartlang.org" 299 | source: hosted 300 | version: "0.2.2+4" 301 | sky_engine: 302 | dependency: transitive 303 | description: flutter 304 | source: sdk 305 | version: "0.0.99" 306 | source_map_stack_trace: 307 | dependency: transitive 308 | description: 309 | name: source_map_stack_trace 310 | url: "https://pub.dartlang.org" 311 | source: hosted 312 | version: "1.1.5" 313 | source_maps: 314 | dependency: transitive 315 | description: 316 | name: source_maps 317 | url: "https://pub.dartlang.org" 318 | source: hosted 319 | version: "0.10.7" 320 | source_span: 321 | dependency: transitive 322 | description: 323 | name: source_span 324 | url: "https://pub.dartlang.org" 325 | source: hosted 326 | version: "1.4.1" 327 | stack_trace: 328 | dependency: transitive 329 | description: 330 | name: stack_trace 331 | url: "https://pub.dartlang.org" 332 | source: hosted 333 | version: "1.9.3" 334 | stream_channel: 335 | dependency: transitive 336 | description: 337 | name: stream_channel 338 | url: "https://pub.dartlang.org" 339 | source: hosted 340 | version: "1.6.8" 341 | string_scanner: 342 | dependency: transitive 343 | description: 344 | name: string_scanner 345 | url: "https://pub.dartlang.org" 346 | source: hosted 347 | version: "1.0.4" 348 | term_glyph: 349 | dependency: transitive 350 | description: 351 | name: term_glyph 352 | url: "https://pub.dartlang.org" 353 | source: hosted 354 | version: "1.0.1" 355 | test: 356 | dependency: transitive 357 | description: 358 | name: test 359 | url: "https://pub.dartlang.org" 360 | source: hosted 361 | version: "1.3.0" 362 | typed_data: 363 | dependency: transitive 364 | description: 365 | name: typed_data 366 | url: "https://pub.dartlang.org" 367 | source: hosted 368 | version: "1.1.6" 369 | utf: 370 | dependency: transitive 371 | description: 372 | name: utf 373 | url: "https://pub.dartlang.org" 374 | source: hosted 375 | version: "0.9.0+5" 376 | vector_math: 377 | dependency: transitive 378 | description: 379 | name: vector_math 380 | url: "https://pub.dartlang.org" 381 | source: hosted 382 | version: "2.0.8" 383 | vm_service_client: 384 | dependency: transitive 385 | description: 386 | name: vm_service_client 387 | url: "https://pub.dartlang.org" 388 | source: hosted 389 | version: "0.2.6" 390 | watcher: 391 | dependency: transitive 392 | description: 393 | name: watcher 394 | url: "https://pub.dartlang.org" 395 | source: hosted 396 | version: "0.9.7+10" 397 | web_socket_channel: 398 | dependency: transitive 399 | description: 400 | name: web_socket_channel 401 | url: "https://pub.dartlang.org" 402 | source: hosted 403 | version: "1.0.9" 404 | yaml: 405 | dependency: transitive 406 | description: 407 | name: yaml 408 | url: "https://pub.dartlang.org" 409 | source: hosted 410 | version: "2.1.15" 411 | sdks: 412 | dart: ">=2.0.0-dev.68.0 <3.0.0" 413 | -------------------------------------------------------------------------------- /.idea/workspace.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 34 | 35 | 36 | 41 | 42 | 43 | 44 | 45 | 46 | 47 | 48 | 49 | 50 | 51 | 52 | 53 | 54 | 55 | 56 | 57 | 58 | 59 | 60 | 61 | 63 | 64 | 65 | 66 | 67 | 68 | 69 | 70 | 71 | 72 | 82 | 83 | 84 | 85 | 86 | 87 | 101 | 102 | 103 | 104 | 105 | 106 | 118 | 119 | 125 | 126 | 127 | 128 | 146 | 152 | 153 | 161 | 162 | 167 | 168 | 170 | 171 | 172 | 174 | 175 | 176 | 177 | 178 | 179 | 180 | 1537697823899 181 | 185 | 186 | 187 | 188 | 189 | 190 | 191 | 192 | 193 | 194 | 195 | 196 | 197 | 198 | 199 | 200 | 201 | 202 | 203 | 204 | 205 | 206 | 207 | 208 | 209 | 210 | 211 | 212 | 213 | 214 | 215 | 216 | 217 | 218 | 219 | 220 | 221 | 222 | 223 | 225 | 226 | 227 | 228 | 229 | 230 | 231 | 232 | 233 | 234 | 235 | 236 | 237 | 238 | 239 | 240 | 241 | 242 | 243 | 244 | 245 | 246 | 247 | 248 | 249 | 250 | 251 | 252 | 253 | 254 | 255 | 256 | 257 | 258 | 259 | 260 | 261 | 262 | 263 | -------------------------------------------------------------------------------- /ios/Runner.xcodeproj/project.pbxproj: -------------------------------------------------------------------------------- 1 | // !$*UTF8*$! 2 | { 3 | archiveVersion = 1; 4 | classes = { 5 | }; 6 | objectVersion = 46; 7 | objects = { 8 | 9 | /* Begin PBXBuildFile section */ 10 | 1498D2341E8E89220040F4C2 /* GeneratedPluginRegistrant.m in Sources */ = {isa = PBXBuildFile; fileRef = 1498D2331E8E89220040F4C2 /* GeneratedPluginRegistrant.m */; }; 11 | 2D5378261FAA1A9400D5DBA9 /* flutter_assets in Resources */ = {isa = PBXBuildFile; fileRef = 2D5378251FAA1A9400D5DBA9 /* flutter_assets */; }; 12 | 3B3967161E833CAA004F5970 /* AppFrameworkInfo.plist in Resources */ = {isa = PBXBuildFile; fileRef = 3B3967151E833CAA004F5970 /* AppFrameworkInfo.plist */; }; 13 | 3B80C3941E831B6300D905FE /* App.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 3B80C3931E831B6300D905FE /* App.framework */; }; 14 | 3B80C3951E831B6300D905FE /* App.framework in Embed Frameworks */ = {isa = PBXBuildFile; fileRef = 3B80C3931E831B6300D905FE /* App.framework */; settings = {ATTRIBUTES = (CodeSignOnCopy, RemoveHeadersOnCopy, ); }; }; 15 | 9705A1C61CF904A100538489 /* Flutter.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 9740EEBA1CF902C7004384FC /* Flutter.framework */; }; 16 | 9705A1C71CF904A300538489 /* Flutter.framework in Embed Frameworks */ = {isa = PBXBuildFile; fileRef = 9740EEBA1CF902C7004384FC /* Flutter.framework */; settings = {ATTRIBUTES = (CodeSignOnCopy, RemoveHeadersOnCopy, ); }; }; 17 | 9740EEB41CF90195004384FC /* Debug.xcconfig in Resources */ = {isa = PBXBuildFile; fileRef = 9740EEB21CF90195004384FC /* Debug.xcconfig */; }; 18 | 978B8F6F1D3862AE00F588F7 /* AppDelegate.m in Sources */ = {isa = PBXBuildFile; fileRef = 7AFFD8EE1D35381100E5BB4D /* AppDelegate.m */; }; 19 | 97C146F31CF9000F007C117D /* main.m in Sources */ = {isa = PBXBuildFile; fileRef = 97C146F21CF9000F007C117D /* main.m */; }; 20 | 97C146FC1CF9000F007C117D /* Main.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 97C146FA1CF9000F007C117D /* Main.storyboard */; }; 21 | 97C146FE1CF9000F007C117D /* Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 97C146FD1CF9000F007C117D /* Assets.xcassets */; }; 22 | 97C147011CF9000F007C117D /* LaunchScreen.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 97C146FF1CF9000F007C117D /* LaunchScreen.storyboard */; }; 23 | /* End PBXBuildFile section */ 24 | 25 | /* Begin PBXCopyFilesBuildPhase section */ 26 | 9705A1C41CF9048500538489 /* Embed Frameworks */ = { 27 | isa = PBXCopyFilesBuildPhase; 28 | buildActionMask = 2147483647; 29 | dstPath = ""; 30 | dstSubfolderSpec = 10; 31 | files = ( 32 | 3B80C3951E831B6300D905FE /* App.framework in Embed Frameworks */, 33 | 9705A1C71CF904A300538489 /* Flutter.framework in Embed Frameworks */, 34 | ); 35 | name = "Embed Frameworks"; 36 | runOnlyForDeploymentPostprocessing = 0; 37 | }; 38 | /* End PBXCopyFilesBuildPhase section */ 39 | 40 | /* Begin PBXFileReference section */ 41 | 1498D2321E8E86230040F4C2 /* GeneratedPluginRegistrant.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = GeneratedPluginRegistrant.h; sourceTree = ""; }; 42 | 1498D2331E8E89220040F4C2 /* GeneratedPluginRegistrant.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = GeneratedPluginRegistrant.m; sourceTree = ""; }; 43 | 2D5378251FAA1A9400D5DBA9 /* flutter_assets */ = {isa = PBXFileReference; lastKnownFileType = folder; name = flutter_assets; path = Flutter/flutter_assets; sourceTree = SOURCE_ROOT; }; 44 | 3B3967151E833CAA004F5970 /* AppFrameworkInfo.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; name = AppFrameworkInfo.plist; path = Flutter/AppFrameworkInfo.plist; sourceTree = ""; }; 45 | 3B80C3931E831B6300D905FE /* App.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = App.framework; path = Flutter/App.framework; sourceTree = ""; }; 46 | 7AFA3C8E1D35360C0083082E /* Release.xcconfig */ = {isa = PBXFileReference; lastKnownFileType = text.xcconfig; name = Release.xcconfig; path = Flutter/Release.xcconfig; sourceTree = ""; }; 47 | 7AFFD8ED1D35381100E5BB4D /* AppDelegate.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = AppDelegate.h; sourceTree = ""; }; 48 | 7AFFD8EE1D35381100E5BB4D /* AppDelegate.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = AppDelegate.m; sourceTree = ""; }; 49 | 9740EEB21CF90195004384FC /* Debug.xcconfig */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.xcconfig; name = Debug.xcconfig; path = Flutter/Debug.xcconfig; sourceTree = ""; }; 50 | 9740EEB31CF90195004384FC /* Generated.xcconfig */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.xcconfig; name = Generated.xcconfig; path = Flutter/Generated.xcconfig; sourceTree = ""; }; 51 | 9740EEBA1CF902C7004384FC /* Flutter.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Flutter.framework; path = Flutter/Flutter.framework; sourceTree = ""; }; 52 | 97C146EE1CF9000F007C117D /* Runner.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = Runner.app; sourceTree = BUILT_PRODUCTS_DIR; }; 53 | 97C146F21CF9000F007C117D /* main.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = main.m; sourceTree = ""; }; 54 | 97C146FB1CF9000F007C117D /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/Main.storyboard; sourceTree = ""; }; 55 | 97C146FD1CF9000F007C117D /* Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Assets.xcassets; sourceTree = ""; }; 56 | 97C147001CF9000F007C117D /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/LaunchScreen.storyboard; sourceTree = ""; }; 57 | 97C147021CF9000F007C117D /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; 58 | /* End PBXFileReference section */ 59 | 60 | /* Begin PBXFrameworksBuildPhase section */ 61 | 97C146EB1CF9000F007C117D /* Frameworks */ = { 62 | isa = PBXFrameworksBuildPhase; 63 | buildActionMask = 2147483647; 64 | files = ( 65 | 9705A1C61CF904A100538489 /* Flutter.framework in Frameworks */, 66 | 3B80C3941E831B6300D905FE /* App.framework in Frameworks */, 67 | ); 68 | runOnlyForDeploymentPostprocessing = 0; 69 | }; 70 | /* End PBXFrameworksBuildPhase section */ 71 | 72 | /* Begin PBXGroup section */ 73 | 9740EEB11CF90186004384FC /* Flutter */ = { 74 | isa = PBXGroup; 75 | children = ( 76 | 2D5378251FAA1A9400D5DBA9 /* flutter_assets */, 77 | 3B80C3931E831B6300D905FE /* App.framework */, 78 | 3B3967151E833CAA004F5970 /* AppFrameworkInfo.plist */, 79 | 9740EEBA1CF902C7004384FC /* Flutter.framework */, 80 | 9740EEB21CF90195004384FC /* Debug.xcconfig */, 81 | 7AFA3C8E1D35360C0083082E /* Release.xcconfig */, 82 | 9740EEB31CF90195004384FC /* Generated.xcconfig */, 83 | ); 84 | name = Flutter; 85 | sourceTree = ""; 86 | }; 87 | 97C146E51CF9000F007C117D = { 88 | isa = PBXGroup; 89 | children = ( 90 | 9740EEB11CF90186004384FC /* Flutter */, 91 | 97C146F01CF9000F007C117D /* Runner */, 92 | 97C146EF1CF9000F007C117D /* Products */, 93 | CF3B75C9A7D2FA2A4C99F110 /* Frameworks */, 94 | ); 95 | sourceTree = ""; 96 | }; 97 | 97C146EF1CF9000F007C117D /* Products */ = { 98 | isa = PBXGroup; 99 | children = ( 100 | 97C146EE1CF9000F007C117D /* Runner.app */, 101 | ); 102 | name = Products; 103 | sourceTree = ""; 104 | }; 105 | 97C146F01CF9000F007C117D /* Runner */ = { 106 | isa = PBXGroup; 107 | children = ( 108 | 7AFFD8ED1D35381100E5BB4D /* AppDelegate.h */, 109 | 7AFFD8EE1D35381100E5BB4D /* AppDelegate.m */, 110 | 97C146FA1CF9000F007C117D /* Main.storyboard */, 111 | 97C146FD1CF9000F007C117D /* Assets.xcassets */, 112 | 97C146FF1CF9000F007C117D /* LaunchScreen.storyboard */, 113 | 97C147021CF9000F007C117D /* Info.plist */, 114 | 97C146F11CF9000F007C117D /* Supporting Files */, 115 | 1498D2321E8E86230040F4C2 /* GeneratedPluginRegistrant.h */, 116 | 1498D2331E8E89220040F4C2 /* GeneratedPluginRegistrant.m */, 117 | ); 118 | path = Runner; 119 | sourceTree = ""; 120 | }; 121 | 97C146F11CF9000F007C117D /* Supporting Files */ = { 122 | isa = PBXGroup; 123 | children = ( 124 | 97C146F21CF9000F007C117D /* main.m */, 125 | ); 126 | name = "Supporting Files"; 127 | sourceTree = ""; 128 | }; 129 | /* End PBXGroup section */ 130 | 131 | /* Begin PBXNativeTarget section */ 132 | 97C146ED1CF9000F007C117D /* Runner */ = { 133 | isa = PBXNativeTarget; 134 | buildConfigurationList = 97C147051CF9000F007C117D /* Build configuration list for PBXNativeTarget "Runner" */; 135 | buildPhases = ( 136 | 9740EEB61CF901F6004384FC /* Run Script */, 137 | 97C146EA1CF9000F007C117D /* Sources */, 138 | 97C146EB1CF9000F007C117D /* Frameworks */, 139 | 97C146EC1CF9000F007C117D /* Resources */, 140 | 9705A1C41CF9048500538489 /* Embed Frameworks */, 141 | 3B06AD1E1E4923F5004D2608 /* Thin Binary */, 142 | ); 143 | buildRules = ( 144 | ); 145 | dependencies = ( 146 | ); 147 | name = Runner; 148 | productName = Runner; 149 | productReference = 97C146EE1CF9000F007C117D /* Runner.app */; 150 | productType = "com.apple.product-type.application"; 151 | }; 152 | /* End PBXNativeTarget section */ 153 | 154 | /* Begin PBXProject section */ 155 | 97C146E61CF9000F007C117D /* Project object */ = { 156 | isa = PBXProject; 157 | attributes = { 158 | LastUpgradeCheck = 0910; 159 | ORGANIZATIONNAME = "The Chromium Authors"; 160 | TargetAttributes = { 161 | 97C146ED1CF9000F007C117D = { 162 | CreatedOnToolsVersion = 7.3.1; 163 | }; 164 | }; 165 | }; 166 | buildConfigurationList = 97C146E91CF9000F007C117D /* Build configuration list for PBXProject "Runner" */; 167 | compatibilityVersion = "Xcode 3.2"; 168 | developmentRegion = English; 169 | hasScannedForEncodings = 0; 170 | knownRegions = ( 171 | en, 172 | Base, 173 | ); 174 | mainGroup = 97C146E51CF9000F007C117D; 175 | productRefGroup = 97C146EF1CF9000F007C117D /* Products */; 176 | projectDirPath = ""; 177 | projectRoot = ""; 178 | targets = ( 179 | 97C146ED1CF9000F007C117D /* Runner */, 180 | ); 181 | }; 182 | /* End PBXProject section */ 183 | 184 | /* Begin PBXResourcesBuildPhase section */ 185 | 97C146EC1CF9000F007C117D /* Resources */ = { 186 | isa = PBXResourcesBuildPhase; 187 | buildActionMask = 2147483647; 188 | files = ( 189 | 97C147011CF9000F007C117D /* LaunchScreen.storyboard in Resources */, 190 | 3B3967161E833CAA004F5970 /* AppFrameworkInfo.plist in Resources */, 191 | 9740EEB41CF90195004384FC /* Debug.xcconfig in Resources */, 192 | 97C146FE1CF9000F007C117D /* Assets.xcassets in Resources */, 193 | 2D5378261FAA1A9400D5DBA9 /* flutter_assets in Resources */, 194 | 97C146FC1CF9000F007C117D /* Main.storyboard in Resources */, 195 | ); 196 | runOnlyForDeploymentPostprocessing = 0; 197 | }; 198 | /* End PBXResourcesBuildPhase section */ 199 | 200 | /* Begin PBXShellScriptBuildPhase section */ 201 | 3B06AD1E1E4923F5004D2608 /* Thin Binary */ = { 202 | isa = PBXShellScriptBuildPhase; 203 | buildActionMask = 2147483647; 204 | files = ( 205 | ); 206 | inputPaths = ( 207 | ); 208 | name = "Thin Binary"; 209 | outputPaths = ( 210 | ); 211 | runOnlyForDeploymentPostprocessing = 0; 212 | shellPath = /bin/sh; 213 | shellScript = "/bin/sh \"$FLUTTER_ROOT/packages/flutter_tools/bin/xcode_backend.sh\" thin"; 214 | }; 215 | 9740EEB61CF901F6004384FC /* Run Script */ = { 216 | isa = PBXShellScriptBuildPhase; 217 | buildActionMask = 2147483647; 218 | files = ( 219 | ); 220 | inputPaths = ( 221 | ); 222 | name = "Run Script"; 223 | outputPaths = ( 224 | ); 225 | runOnlyForDeploymentPostprocessing = 0; 226 | shellPath = /bin/sh; 227 | shellScript = "/bin/sh \"$FLUTTER_ROOT/packages/flutter_tools/bin/xcode_backend.sh\" build"; 228 | }; 229 | /* End PBXShellScriptBuildPhase section */ 230 | 231 | /* Begin PBXSourcesBuildPhase section */ 232 | 97C146EA1CF9000F007C117D /* Sources */ = { 233 | isa = PBXSourcesBuildPhase; 234 | buildActionMask = 2147483647; 235 | files = ( 236 | 978B8F6F1D3862AE00F588F7 /* AppDelegate.m in Sources */, 237 | 97C146F31CF9000F007C117D /* main.m in Sources */, 238 | 1498D2341E8E89220040F4C2 /* GeneratedPluginRegistrant.m in Sources */, 239 | ); 240 | runOnlyForDeploymentPostprocessing = 0; 241 | }; 242 | /* End PBXSourcesBuildPhase section */ 243 | 244 | /* Begin PBXVariantGroup section */ 245 | 97C146FA1CF9000F007C117D /* Main.storyboard */ = { 246 | isa = PBXVariantGroup; 247 | children = ( 248 | 97C146FB1CF9000F007C117D /* Base */, 249 | ); 250 | name = Main.storyboard; 251 | sourceTree = ""; 252 | }; 253 | 97C146FF1CF9000F007C117D /* LaunchScreen.storyboard */ = { 254 | isa = PBXVariantGroup; 255 | children = ( 256 | 97C147001CF9000F007C117D /* Base */, 257 | ); 258 | name = LaunchScreen.storyboard; 259 | sourceTree = ""; 260 | }; 261 | /* End PBXVariantGroup section */ 262 | 263 | /* Begin XCBuildConfiguration section */ 264 | 97C147031CF9000F007C117D /* Debug */ = { 265 | isa = XCBuildConfiguration; 266 | baseConfigurationReference = 9740EEB21CF90195004384FC /* Debug.xcconfig */; 267 | buildSettings = { 268 | ALWAYS_SEARCH_USER_PATHS = NO; 269 | CLANG_ANALYZER_NONNULL = YES; 270 | CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; 271 | CLANG_CXX_LIBRARY = "libc++"; 272 | CLANG_ENABLE_MODULES = YES; 273 | CLANG_ENABLE_OBJC_ARC = YES; 274 | CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; 275 | CLANG_WARN_BOOL_CONVERSION = YES; 276 | CLANG_WARN_COMMA = YES; 277 | CLANG_WARN_CONSTANT_CONVERSION = YES; 278 | CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; 279 | CLANG_WARN_EMPTY_BODY = YES; 280 | CLANG_WARN_ENUM_CONVERSION = YES; 281 | CLANG_WARN_INFINITE_RECURSION = YES; 282 | CLANG_WARN_INT_CONVERSION = YES; 283 | CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; 284 | CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; 285 | CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; 286 | CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; 287 | CLANG_WARN_STRICT_PROTOTYPES = YES; 288 | CLANG_WARN_SUSPICIOUS_MOVE = YES; 289 | CLANG_WARN_UNREACHABLE_CODE = YES; 290 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; 291 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; 292 | COPY_PHASE_STRIP = NO; 293 | DEBUG_INFORMATION_FORMAT = dwarf; 294 | ENABLE_STRICT_OBJC_MSGSEND = YES; 295 | ENABLE_TESTABILITY = YES; 296 | GCC_C_LANGUAGE_STANDARD = gnu99; 297 | GCC_DYNAMIC_NO_PIC = NO; 298 | GCC_NO_COMMON_BLOCKS = YES; 299 | GCC_OPTIMIZATION_LEVEL = 0; 300 | GCC_PREPROCESSOR_DEFINITIONS = ( 301 | "DEBUG=1", 302 | "$(inherited)", 303 | ); 304 | GCC_WARN_64_TO_32_BIT_CONVERSION = YES; 305 | GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; 306 | GCC_WARN_UNDECLARED_SELECTOR = YES; 307 | GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; 308 | GCC_WARN_UNUSED_FUNCTION = YES; 309 | GCC_WARN_UNUSED_VARIABLE = YES; 310 | IPHONEOS_DEPLOYMENT_TARGET = 8.0; 311 | MTL_ENABLE_DEBUG_INFO = YES; 312 | ONLY_ACTIVE_ARCH = YES; 313 | SDKROOT = iphoneos; 314 | TARGETED_DEVICE_FAMILY = "1,2"; 315 | }; 316 | name = Debug; 317 | }; 318 | 97C147041CF9000F007C117D /* Release */ = { 319 | isa = XCBuildConfiguration; 320 | baseConfigurationReference = 7AFA3C8E1D35360C0083082E /* Release.xcconfig */; 321 | buildSettings = { 322 | ALWAYS_SEARCH_USER_PATHS = NO; 323 | CLANG_ANALYZER_NONNULL = YES; 324 | CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; 325 | CLANG_CXX_LIBRARY = "libc++"; 326 | CLANG_ENABLE_MODULES = YES; 327 | CLANG_ENABLE_OBJC_ARC = YES; 328 | CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; 329 | CLANG_WARN_BOOL_CONVERSION = YES; 330 | CLANG_WARN_COMMA = YES; 331 | CLANG_WARN_CONSTANT_CONVERSION = YES; 332 | CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; 333 | CLANG_WARN_EMPTY_BODY = YES; 334 | CLANG_WARN_ENUM_CONVERSION = YES; 335 | CLANG_WARN_INFINITE_RECURSION = YES; 336 | CLANG_WARN_INT_CONVERSION = YES; 337 | CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; 338 | CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; 339 | CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; 340 | CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; 341 | CLANG_WARN_STRICT_PROTOTYPES = YES; 342 | CLANG_WARN_SUSPICIOUS_MOVE = YES; 343 | CLANG_WARN_UNREACHABLE_CODE = YES; 344 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; 345 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; 346 | COPY_PHASE_STRIP = NO; 347 | DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; 348 | ENABLE_NS_ASSERTIONS = NO; 349 | ENABLE_STRICT_OBJC_MSGSEND = YES; 350 | GCC_C_LANGUAGE_STANDARD = gnu99; 351 | GCC_NO_COMMON_BLOCKS = YES; 352 | GCC_WARN_64_TO_32_BIT_CONVERSION = YES; 353 | GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; 354 | GCC_WARN_UNDECLARED_SELECTOR = YES; 355 | GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; 356 | GCC_WARN_UNUSED_FUNCTION = YES; 357 | GCC_WARN_UNUSED_VARIABLE = YES; 358 | IPHONEOS_DEPLOYMENT_TARGET = 8.0; 359 | MTL_ENABLE_DEBUG_INFO = NO; 360 | SDKROOT = iphoneos; 361 | TARGETED_DEVICE_FAMILY = "1,2"; 362 | VALIDATE_PRODUCT = YES; 363 | }; 364 | name = Release; 365 | }; 366 | 97C147061CF9000F007C117D /* Debug */ = { 367 | isa = XCBuildConfiguration; 368 | baseConfigurationReference = 9740EEB21CF90195004384FC /* Debug.xcconfig */; 369 | buildSettings = { 370 | ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; 371 | CURRENT_PROJECT_VERSION = "$(FLUTTER_BUILD_NUMBER)"; 372 | ENABLE_BITCODE = NO; 373 | FRAMEWORK_SEARCH_PATHS = ( 374 | "$(inherited)", 375 | "$(PROJECT_DIR)/Flutter", 376 | ); 377 | INFOPLIST_FILE = Runner/Info.plist; 378 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; 379 | LIBRARY_SEARCH_PATHS = ( 380 | "$(inherited)", 381 | "$(PROJECT_DIR)/Flutter", 382 | ); 383 | PRODUCT_BUNDLE_IDENTIFIER = com.example.flutterTodosRedux; 384 | PRODUCT_NAME = "$(TARGET_NAME)"; 385 | VERSIONING_SYSTEM = "apple-generic"; 386 | }; 387 | name = Debug; 388 | }; 389 | 97C147071CF9000F007C117D /* Release */ = { 390 | isa = XCBuildConfiguration; 391 | baseConfigurationReference = 7AFA3C8E1D35360C0083082E /* Release.xcconfig */; 392 | buildSettings = { 393 | ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; 394 | CURRENT_PROJECT_VERSION = "$(FLUTTER_BUILD_NUMBER)"; 395 | ENABLE_BITCODE = NO; 396 | FRAMEWORK_SEARCH_PATHS = ( 397 | "$(inherited)", 398 | "$(PROJECT_DIR)/Flutter", 399 | ); 400 | INFOPLIST_FILE = Runner/Info.plist; 401 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; 402 | LIBRARY_SEARCH_PATHS = ( 403 | "$(inherited)", 404 | "$(PROJECT_DIR)/Flutter", 405 | ); 406 | PRODUCT_BUNDLE_IDENTIFIER = com.example.flutterTodosRedux; 407 | PRODUCT_NAME = "$(TARGET_NAME)"; 408 | VERSIONING_SYSTEM = "apple-generic"; 409 | }; 410 | name = Release; 411 | }; 412 | /* End XCBuildConfiguration section */ 413 | 414 | /* Begin XCConfigurationList section */ 415 | 97C146E91CF9000F007C117D /* Build configuration list for PBXProject "Runner" */ = { 416 | isa = XCConfigurationList; 417 | buildConfigurations = ( 418 | 97C147031CF9000F007C117D /* Debug */, 419 | 97C147041CF9000F007C117D /* Release */, 420 | ); 421 | defaultConfigurationIsVisible = 0; 422 | defaultConfigurationName = Release; 423 | }; 424 | 97C147051CF9000F007C117D /* Build configuration list for PBXNativeTarget "Runner" */ = { 425 | isa = XCConfigurationList; 426 | buildConfigurations = ( 427 | 97C147061CF9000F007C117D /* Debug */, 428 | 97C147071CF9000F007C117D /* Release */, 429 | ); 430 | defaultConfigurationIsVisible = 0; 431 | defaultConfigurationName = Release; 432 | }; 433 | /* End XCConfigurationList section */ 434 | }; 435 | rootObject = 97C146E61CF9000F007C117D /* Project object */; 436 | } 437 | -------------------------------------------------------------------------------- /.idea/libraries/Dart_Packages.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 419 | 420 | 421 | 422 | 423 | 424 | 425 | 426 | 427 | 428 | 429 | 430 | 431 | 432 | 433 | 434 | 435 | 436 | 437 | 438 | 439 | 440 | 441 | 442 | 443 | 444 | 445 | 446 | 447 | 448 | 449 | 450 | 451 | 452 | 453 | 454 | 455 | 456 | 457 | 458 | 459 | 460 | 461 | 462 | 463 | 464 | 465 | 466 | 467 | 468 | 469 | 470 | 471 | 472 | 473 | 474 | 475 | 476 | 477 | 478 | 479 | 480 | 481 | 482 | 483 | 484 | --------------------------------------------------------------------------------