GithubHelp home page GithubHelp logo

rodydavis / flutter_login Goto Github PK

View Code? Open in Web Editor NEW
711.0 35.0 200.0 50.89 MB

100% Shared Code Android/iOS Login Example - JSON API

Home Page: https://rodydavis.github.io/flutter_login/

Kotlin 1.00% Swift 3.08% Objective-C 4.34% Dart 71.77% Ruby 14.54% Java 2.77% HTML 2.50%
flutter json json-api dart android ios opensource touchid faceid fingerprint-reader crossplatform material-design

flutter_login's Introduction

Flutter Login Example

This example uses a ScrollView, JSON Rest API, Navigation, Alert Pop Up, Progress Indicator, Globals, Images in a shared asset folder, and 100% Shared Code. Now with the ability to login with FaceID, TouchID, and Fingerprint Reader on Android.

Online Demo: https://rodydavis.github.io/flutter_login/

New Features

  • Auto Login
  • Enhanced Security with Bio
  • Menu and Logout
  • Dark Mode and True Black
  • Settings Page
  • Auth Service
  • What's New Page
  • Remember Me Toggle
  • Custom Theme
  • Scoped Model
  • Automatic Json using json_serializable

Getting Started

Clone or Fork Project to get started.

Prerequisites

Flutter SDK, Android Studio or Other Compatible IDE.

iOS Integration

Note that this plugin works with both TouchID and FaceID. However, to use the latter, you need to also add:

<key>NSFaceIDUsageDescription</key>
<string>Why is my app authenticating using face id?</string>

to your Info.plist file. Failure to do so results in a dialog that tells the user your app has not been updated to use TouchID.

Android Integration

Update your project's AndroidManifest.xml file to include the USE_FINGERPRINT permissions:

<manifest xmlns:android="http://schemas.android.com/apk/res/android"
          package="com.example.app">
  <uses-permission android:name="android.permission.USE_FINGERPRINT"/>
<manifest>

Sticky Auth

You can set the stickyAuth option on the plugin to true so that plugin does not return failure if the app is put to background by the system. This might happen if the user receives a phone call before they get a chance to authenticate. With stickyAuth set to false, this would result in plugin returning failure result to the Dart app. If set to true, the plugin will retry authenticating when the app resumes.

screenshots

 

Settings Page and Menu (Including Dark Mode)

Built With

  • Flutter - Crossplatform App Development Framework

Contributing

Please submit a pull request if you want to help the project grow. The goal is to be able to fork the project and have a login module for your app complete so that a new project can be started quickly and customized to the user's needs.

Please read CONTRIBUTING.md for details on our code of conduct, and the process for submitting pull requests to us.

Versioning

We use SemVer for versioning. For the versions available, see the tags on this repository.

Authors

License

This project is licensed under the MIT License - see the LICENSE.md file for details

Acknowledgments

flutter_login's People

Contributors

icesvz avatar rodydavis avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

flutter_login's Issues

I am getting Kotlin Gradle plugin version error

  • Error running Gradle:
    ProcessException: Process "/Users/niyazitoros/IdeaProjects/capital_face/android/gradlew" exited abnormally:

FAILURE: Build failed with an exception.

  • What went wrong:
    The Android Gradle plugin supports only Kotlin Gradle plugin version 1.2.51 and higher. Project 'get_version' is using version 1.1.51.

  • Try:
    Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full insights.

  • Get more help at https://help.gradle.org

BUİLD FAILED in 2s
Command: /Users/niyazitoros/IdeaProjects/capital_face/android/gradlew app:properties

Finished with error: Please review your Gradle project setup in the android/ folder.

How to modify UI when using local auth plugin in flutter ?

Hello,

I wanted to check if there is a way to modify the UI that appears for the local authentications. Say for example, below is how the screen would look when the finger print auth appears in the flutter app.

image

Below is an example of how the same would look like in other native apps like Walnut, for example.

image

Is there a way to dig in to the native layer and easily modify the UI to at least make it a bit better ?

Project won't build with dev 0.6.0

Not sure it built before either for that matter :) But I just forked this and tried to build and I get:

  • Error running Gradle:
    Exit code 1 from: /Users/sjm/play/flutter_login/android/gradlew app:properties:

FAILURE: Build failed with an exception.

  • Where:
    Build file '/Users/sjm/play/flutter_login/android/app/build.gradle' line: 16

  • What went wrong:
    A problem occurred evaluating project ':app'.

versionCode not found. Define flutter.versionCode in the local.properties file.

  • Try:
    Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output.

  • Get more help at https://help.gradle.org

BUILD FAILED in 0s

Please review your Gradle project setup in the android/ folder.

Error thrown while return ScopedModel in main.dart file

@OverRide
Widget build(BuildContext context) {
return ScopedModel(
model: _model,
child: new ScopedModelDescendant(
builder: (context, child, theme) => ScopedModel(
model: _auth,
child: MaterialApp(
theme: theme.theme,
home: new ScopedModelDescendant(
builder: (context, child, model) {
if (model?.user != null) return Home();
return LoginPage();
}),
routes: <String, WidgetBuilder>{
"/login": (BuildContext context) => LoginPage(),
"/menu": (BuildContext context) => Home(),
"/home": (BuildContext context) => Home(),
"/settings": (BuildContext context) => SettingsPage(),
"/create": (BuildContext context) => CreateAccount(),
},
),
),
));
}

'ThemeModel' doesn't extend 'Model'.
Try using a type that is or is a subclass of 'Model'.dart(type_argument_not_matching_bounds)

Exception thrown when logging out

Hey,

first of all thx for this great Scaffold for a flutter app.

I've noticed an issue though, when using the App just after git cloning it... If I hit logout it get the following exception on the console:

flutter: no-action
flutter: ══╡ EXCEPTION CAUGHT BY WIDGETS LIBRARY ╞═══════════════════════════════════════════════════════════
flutter: The following assertion was thrown while finalizing the widget tree:
flutter: setState() or markNeedsBuild() called when widget tree was locked.
flutter: This _ModalScope<dynamic> widget cannot be marked as needing to build because the framework is
flutter: locked.
flutter: The widget on which setState() or markNeedsBuild() was called was:
flutter:   _ModalScope<dynamic>-[LabeledGlobalKey<_ModalScopeState<dynamic>>#2de24](state:
flutter:   _ModalScopeState<dynamic>#e79f0)
flutter:
flutter: When the exception was thrown, this was the stack:
flutter: #0      Element.markNeedsBuild.<anonymous closure> 
flutter: #1      Element.markNeedsBuild 
flutter: #2      State.setState 
flutter: #3      _ModalScopeState._routeSetState 
flutter: #4      ModalRoute.setState 
flutter: #5      ModalRoute.changedInternalState 
flutter: #6      _ModalRoute&TransitionRoute&LocalHistoryRoute.removeLocalHistoryEntry 
flutter: #7      LocalHistoryEntry.remove 
flutter: #8      DrawerControllerState.dispose 
flutter: #9      StatefulElement.unmount 
flutter: #10     _InactiveElements._unmount 
flutter: #11     _InactiveElements._unmount.<anonymous closure> 
flutter: #12     ComponentElement.visitChildren 
flutter: #13     _InactiveElements._unmount 
flutter: #14     _InactiveElements._unmount.<anonymous closure> 
flutter: #15     ComponentElement.visitChildren 
flutter: #16     _InactiveElements._unmount 
flutter: #17     _InactiveElements._unmount.<anonymous closure> 
flutter: #18     MultiChildRenderObjectElement.visitChildren 
flutter: #19     _InactiveElements._unmount 
flutter: #20     _InactiveElements._unmount.<anonymous closure> 
flutter: #21     ComponentElement.visitChildren 
flutter: #22     _InactiveElements._unmount 
flutter: #23     _InactiveElements._unmount.<anonymous closure> 
flutter: #24     ComponentElement.visitChildren 
flutter: #25     _InactiveElements._unmount 
flutter: #26     _InactiveElements._unmount.<anonymous closure> 
flutter: #27     ComponentElement.visitChildren 
flutter: #28     _InactiveElements._unmount 
flutter: #29     _InactiveElements._unmount.<anonymous closure> 
flutter: #30     SingleChildRenderObjectElement.visitChildren 
flutter: #31     _InactiveElements._unmount 
flutter: #32     _InactiveElements._unmount.<anonymous closure> 
flutter: #33     ComponentElement.visitChildren 
flutter: #34     _InactiveElements._unmount 
flutter: #35     _InactiveElements._unmount.<anonymous closure> 
flutter: #36     SingleChildRenderObjectElement.visitChildren 
flutter: #37     _InactiveElements._unmount 
flutter: #38     _InactiveElements._unmount.<anonymous closure> 
flutter: #39     ComponentElement.visitChildren 
flutter: #40     _InactiveElements._unmount 
flutter: #41     _InactiveElements._unmount.<anonymous closure> 
flutter: #42     ComponentElement.visitChildren 
flutter: #43     _InactiveElements._unmount 
flutter: #44     _InactiveElements._unmount.<anonymous closure> 
flutter: #45     ComponentElement.visitChildren 
flutter: #46     _InactiveElements._unmount 
flutter: #47     _InactiveElements._unmount.<anonymous closure> 
flutter: #48     ComponentElement.visitChildren 
flutter: #49     _InactiveElements._unmount 
flutter: #50     _InactiveElements._unmount.<anonymous closure> 
flutter: #51     ComponentElement.visitChildren 
flutter: #52     _InactiveElements._unmount 
flutter: #53     _InactiveElements._unmount.<anonymous closure> 
flutter: #54     ComponentElement.visitChildren 
flutter: #55     _InactiveElements._unmount 
flutter: #56     ListIterable.forEach (dart:_internal/iterable.dart:39:13)
flutter: #57     _InactiveElements._unmountAll 
flutter: #58     BuildOwner.finalizeTree.<anonymous closure> 
flutter: #59     BuildOwner.lockState 
flutter: #60     BuildOwner.finalizeTree 
flutter: #61     _WidgetsFlutterBinding&BindingBase&GestureBinding&ServicesBinding&SchedulerBinding&PaintingBinding&SemanticsBinding&RendererBinding&WidgetsBinding.drawFrame 
flutter: #62     _WidgetsFlutterBinding&BindingBase&GestureBinding&ServicesBinding&SchedulerBinding&PaintingBinding&SemanticsBinding&RendererBinding._handlePersistentFrameCallback 
flutter: #63     _WidgetsFlutterBinding&BindingBase&GestureBinding&ServicesBinding&SchedulerBinding._invokeFrameCallback 
flutter: #64     _WidgetsFlutterBinding&BindingBase&GestureBinding&ServicesBinding&SchedulerBinding.handleDrawFrame 
flutter: #65     _WidgetsFlutterBinding&BindingBase&GestureBinding&ServicesBinding&SchedulerBinding._handleDrawFrame 
flutter: #69     _invoke (dart:ui/hooks.dart:209:10)
flutter: #70     _drawFrame (dart:ui/hooks.dart:168:3)
flutter: (elided 3 frames from package dart:async)
flutter: ════════════════════════════════════════════════════════════════════════════════════════════════════
flutter: Another exception was thrown: 'package:flutter/src/widgets/framework.dart': Failed assertion: line 3485 pos 12: '_debugLifecycleState != _ElementLifecycle.defunct': is not true.
flutter: Another exception was thrown: 'package:flutter/src/widgets/framework.dart': Failed assertion: line 3485 pos 12: '_debugLifecycleState != _ElementLifecycle.defunct': is not true.

those last two lines repeat several more times.

Any Ideas?

From the UI perspective it seems that there isn't any issue at all.

let me know if I could further help tackling this...

Desktop

biometric plugin wont work on desktop.

is there a way to compile for desktop then ?

Or create two flutter apps and:

  • then at runtime detect if you on mobile and then use it.
  • Or do condition compilation strategy.

not sure what architectural strategy to employ. Maybe IOC ( inversion of control) pattern with something like dio ?

The plugins `get_version, local_auth` use a deprecated version of the Android embedding.

I guess this is because of the new flutter updates.
How do I fix it?

The pluginsget_version, local_auth` use a deprecated version of the Android embedding.
To avoid unexpected runtime failures, or future build failures, try to see if these plugins support the Android V2 embedding. Otherwise, consider removing them since a future release of Flutter will remove these deprecated APIs.
If you are plugin author, take a look at the docs for migrating the plugin to the V2 embedding: https://flutter.dev/go/android-plugin-migration.
Launching lib\main.dart on sdk gphone x86 64 arm64 in debug mode...
../../../Documents/flutter/.pub-cache/hosted/pub.dartlang.org/flutter_markdown-0.2.0/lib/src/builder.dart:326:49: Error: The getter 'children' isn't defined for the class 'InlineSpan'.

  • 'InlineSpan' is from 'package:flutter/src/painting/inline_span.dart' ('../../../Documents/flutter/packages/flutter/lib/src/painting/inline_span.dart').
    Try correcting the name to the name of an existing getter, or defining a getter or field named 'children'.
    List children = previous.text.children != null

                                             ^^^^^^^^
    

../../../Documents/flutter/.pub-cache/hosted/pub.dartlang.org/flutter_markdown-0.2.0/lib/src/builder.dart:327:41: Error: The getter 'children' isn't defined for the class 'InlineSpan'.

  • 'InlineSpan' is from 'package:flutter/src/painting/inline_span.dart' ('../../../Documents/flutter/packages/flutter/lib/src/painting/inline_span.dart').
    Try correcting the name to the name of an existing getter, or defining a getter or field named 'children'.
    ? new List.from(previous.text.children)

                                     ^^^^^^^^
    

../../../Documents/flutter/.pub-cache/hosted/pub.dartlang.org/flutter_markdown-0.2.0/lib/src/style_sheet.dart:51:30: Error: The getter 'body1' isn't defined for the class 'TextTheme'.

  • 'TextTheme' is from 'package:flutter/src/material/text_theme.dart' ('../../../Documents/flutter/packages/flutter/lib/src/material/text_theme.dart').
    Try correcting the name to the name of an existing getter, or defining a getter or field named 'body1'.
    assert(theme?.textTheme?.body1?.fontSize != null);
    ^^^^^

../../../Documents/flutter/.pub-cache/hosted/pub.dartlang.org/flutter_markdown-0.2.0/lib/src/style_sheet.dart:54:26: Error: The getter 'body1' isn't defined for the class 'TextTheme'.

  • 'TextTheme' is from 'package:flutter/src/material/text_theme.dart' ('../../../Documents/flutter/packages/flutter/lib/src/material/text_theme.dart').
    Try correcting the name to the name of an existing getter, or defining a getter or field named 'body1'.
    p: theme.textTheme.body1,
    ^^^^^
    ../../../Documents/flutter/.pub-cache/hosted/pub.dartlang.org/flutter_markdown-0.2.0/lib/src/style_sheet.dart:58:35: Error: The getter 'body1' isn't defined for the class 'TextTheme'.

  • 'TextTheme' is from 'package:flutter/src/material/text_theme.dart' ('../../../Documents/flutter/packages/flutter/lib/src/material/text_theme.dart').
    Try correcting the name to the name of an existing getter, or defining a getter or field named 'body1'.
    fontSize: theme.textTheme.body1.fontSize * 0.85
    ^^^^^
    ../../../Documents/flutter/.pub-cache/hosted/pub.dartlang.org/flutter_markdown-0.2.0/lib/src/style_sheet.dart:60:27: Error: The getter 'headline' isn't defined for the class 'TextTheme'.

  • 'TextTheme' is from 'package:flutter/src/material/text_theme.dart' ('../../../Documents/flutter/packages/flutter/lib/src/material/text_theme.dart').
    Try correcting the name to the name of an existing getter, or defining a getter or field named 'headline'.
    h1: theme.textTheme.headline,
    ^^^^^^^^
    ../../../Documents/flutter/.pub-cache/hosted/pub.dartlang.org/flutter_markdown-0.2.0/lib/src/style_sheet.dart:61:27: Error: The getter 'title' isn't defined for the class 'TextTheme'.

  • 'TextTheme' is from 'package:flutter/src/material/text_theme.dart' ('../../../Documents/flutter/packages/flutter/lib/src/material/text_theme.dart').
    Try correcting the name to the name of an existing getter, or defining a getter or field named 'title'.
    h2: theme.textTheme.title,
    ^^^^^
    ../../../Documents/flutter/.pub-cache/hosted/pub.dartlang.org/flutter_markdown-0.2.0/lib/src/style_sheet.dart:62:27: Error: The getter 'subhead' isn't defined for the class 'TextTheme'.

  • 'TextTheme' is from 'package:flutter/src/material/text_theme.dart' ('../../../Documents/flutter/packages/flutter/lib/src/material/text_theme.dart').
    Try correcting the name to the name of an existing getter, or defining a getter or field named 'subhead'.
    h3: theme.textTheme.subhead,
    ^^^^^^^
    ../../../Documents/flutter/.pub-cache/hosted/pub.dartlang.org/flutter_markdown-0.2.0/lib/src/style_sheet.dart:63:27: Error: The getter 'body2' isn't defined for the class 'TextTheme'.

  • 'TextTheme' is from 'package:flutter/src/material/text_theme.dart' ('../../../Documents/flutter/packages/flutter/lib/src/material/text_theme.dart').
    Try correcting the name to the name of an existing getter, or defining a getter or field named 'body2'.
    h4: theme.textTheme.body2,

                       ^^^^^
    

../../../Documents/flutter/.pub-cache/hosted/pub.dartlang.org/flutter_markdown-0.2.0/lib/src/style_sheet.dart:64:27: Error: The getter 'body2' isn't defined for the class 'TextTheme'.

  • 'TextTheme' is from 'package:flutter/src/material/text_theme.dart' ('../../../Documents/flutter/packages/flutter/lib/src/material/text_theme.dart').
    Try correcting the name to the name of an existing getter, or defining a getter or field named 'body2'.
    h5: theme.textTheme.body2,
    ^^^^^
    ../../../Documents/flutter/.pub-cache/hosted/pub.dartlang.org/flutter_markdown-0.2.0/lib/src/style_sheet.dart:65:27: Error: The getter 'body2' isn't defined for the class 'TextTheme'.
  • 'TextTheme' is from 'package:flutter/src/material/text_theme.dart' ('../../../Documents/flutter/packages/flutter/lib/src/material/text_theme.dart').
    Try correcting the name to the name of an existing getter, or defining a getter or field named 'body2'.
    h6: theme.textTheme.body2,
    ^^^^^
    ../../../Documents/flutter/.pub-cache/hosted/pub.dartlang.org/flutter_markdown-0.2.0/lib/src/style_sheet.dart:68:35: Error: The getter 'body1' isn't defined for the class 'TextTheme'.
  • 'TextTheme' is from 'package:flutter/src/material/text_theme.dart' ('../../../Documents/flutter/packages/flutter/lib/src/material/text_theme.dart').

Try correcting the name to the name of an existing getter, or defining a getter or field named 'body1'.
blockquote: theme.textTheme.body1,
^^^^^
../../../Documents/flutter/.pub-cache/hosted/pub.dartlang.org/flutter_markdown-0.2.0/lib/src/style_sheet.dart:69:28: Error: The getter 'body1' isn't defined for the class 'TextTheme'.

  • 'TextTheme' is from 'package:flutter/src/material/text_theme.dart' ('../../../Documents/flutter/packages/flutter/lib/src/material/text_theme.dart').
    Try correcting the name to the name of an existing getter, or defining a getter or field named 'body1'.
    img: theme.textTheme.body1,
    ^^^^^
    ../../../Documents/flutter/.pub-cache/hosted/pub.dartlang.org/flutter_markdown-0.2.0/lib/src/style_sheet.dart:97:26: Error: The getter 'body1' isn't defined for the class 'TextTheme'.
  • 'TextTheme' is from 'package:flutter/src/material/text_theme.dart' ('../../../Documents/flutter/packages/flutter/lib/src/material/text_theme.dart').

Try correcting the name to the name of an existing getter, or defining a getter or field named 'body1'.
p: theme.textTheme.body1,
^^^^^
../../../Documents/flutter/.pub-cache/hosted/pub.dartlang.org/flutter_markdown-0.2.0/lib/src/style_sheet.dart:101:35: Error: The getter 'body1' isn't defined for the class 'TextTheme'.

  • 'TextTheme' is from 'package:flutter/src/material/text_theme.dart' ('../../../Documents/flutter/packages/flutter/lib/src/material/text_theme.dart').
    Try correcting the name to the name of an existing getter, or defining a getter or field named 'body1'.
    fontSize: theme.textTheme.body1.fontSize * 0.85

                               ^^^^^
    

../../../Documents/flutter/.pub-cache/hosted/pub.dartlang.org/flutter_markdown-0.2.0/lib/src/style_sheet.dart:103:27: Error: The getter 'display3' isn't defined for the class 'TextTheme'.

  • 'TextTheme' is from 'package:flutter/src/material/text_theme.dart' ('../../../Documents/flutter/packages/flutter/lib/src/material/text_theme.dart').
    Try correcting the name to the name of an existing getter, or defining a getter or field named 'display3'.
    h1: theme.textTheme.display3,

                       ^^^^^^^^
    

../../../Documents/flutter/.pub-cache/hosted/pub.dartlang.org/flutter_markdown-0.2.0/lib/src/style_sheet.dart:104:27: Error: The getter 'display2' isn't defined for the class 'TextTheme'.

  • 'TextTheme' is from 'package:flutter/src/material/text_theme.dart' ('../../../Documents/flutter/packages/flutter/lib/src/material/text_theme.dart').

Try correcting the name to the name of an existing getter, or defining a getter or field named 'display2'.
h2: theme.textTheme.display2,
^^^^^^^^
../../../Documents/flutter/.pub-cache/hosted/pub.dartlang.org/flutter_markdown-0.2.0/lib/src/style_sheet.dart:105:27: Error: The getter 'display1' isn't defined for the class 'TextTheme'.

  • 'TextTheme' is from 'package:flutter/src/material/text_theme.dart' ('../../../Documents/flutter/packages/flutter/lib/src/material/text_theme.dart').
    Try correcting the name to the name of an existing getter, or defining a getter or field named 'display1'.
    h3: theme.textTheme.display1,

                       ^^^^^^^^
    

../../../Documents/flutter/.pub-cache/hosted/pub.dartlang.org/flutter_markdown-0.2.0/lib/src/style_sheet.dart:106:27: Error: The getter 'headline' isn't defined for the class 'TextTheme'.

  • 'TextTheme' is from 'package:flutter/src/material/text_theme.dart' ('../../../Documents/flutter/packages/flutter/lib/src/material/text_theme.dart').
    Try correcting the name to the name of an existing getter, or defining a getter or field named 'headline'.
    h4: theme.textTheme.headline,
    ^^^^^^^^
    ../../../Documents/flutter/.pub-cache/hosted/pub.dartlang.org/flutter_markdown-0.2.0/lib/src/style_sheet.dart:107:27: Error: The getter 'title' isn't defined for the class 'TextTheme'.
  • 'TextTheme' is from 'package:flutter/src/material/text_theme.dart' ('../../../Documents/flutter/packages/flutter/lib/src/material/text_theme.dart').
    Try correcting the name to the name of an existing getter, or defining a getter or field named 'title'.
    h5: theme.textTheme.title,
    ^^^^^
    ../../../Documents/flutter/.pub-cache/hosted/pub.dartlang.org/flutter_markdown-0.2.0/lib/src/style_sheet.dart:108:27: Error: The getter 'subhead' isn't defined for the class 'TextTheme'.
  • 'TextTheme' is from 'package:flutter/src/material/text_theme.dart' ('../../../Documents/flutter/packages/flutter/lib/src/material/text_theme.dart').
    Try correcting the name to the name of an existing getter, or defining a getter or field named 'subhead'.
    h6: theme.textTheme.subhead,
    ^^^^^^^
    ../../../Documents/flutter/.pub-cache/hosted/pub.dartlang.org/flutter_markdown-0.2.0/lib/src/style_sheet.dart:111:35: Error: The getter 'body1' isn't defined for the class 'TextTheme'.
  • 'TextTheme' is from 'package:flutter/src/material/text_theme.dart' ('../../../Documents/flutter/packages/flutter/lib/src/material/text_theme.dart').
    Try correcting the name to the name of an existing getter, or defining a getter or field named 'body1'.
    blockquote: theme.textTheme.body1,
    ^^^^^
    ../../../Documents/flutter/.pub-cache/hosted/pub.dartlang.org/flutter_markdown-0.2.0/lib/src/style_sheet.dart:112:28: Error: The getter 'body1' isn't defined for the class 'TextTheme'.
  • 'TextTheme' is from 'package:flutter/src/material/text_theme.dart' ('../../../Documents/flutter/packages/flutter/lib/src/material/text_theme.dart').
    Try correcting the name to the name of an existing getter, or defining a getter or field named 'body1'.
    img: theme.textTheme.body1,
    ^^^^^

FAILURE: Build failed with an exception.

  • Where:
    Script 'C:\Users\user\Documents\flutter\packages\flutter_tools\gradle\flutter.gradle' line: 1005

  • What went wrong:
    Execution failed for task ':app:compileFlutterBuildDebug'.

Process 'command 'C:\Users\user\Documents\flutter\bin\flutter.bat'' finished with non-zero exit value 1

  • Try:
    Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full insights.

  • Get more help at https://help.gradle.org

BUILD FAILED in 51s
Exception: Gradle task assembleDebug failed with exit code 1
Exited (sigterm)

`

FaceID for Android Phone

Hi,

I need FaceID for Login but seems there isn't any FaceID for android. When you will be able to provide Android Support?

Error once moved the theme color slider Flutter 1.2.1

The package runs normally during first start. Once tried to move the theme color slider, it keeps throwing the following error. Restart app does not help.

'package:flutter/src/widgets/title.dart': Failed assertion: line 24 pos 15: 'color != null &&
color.alpha == 0xFF': is not true.

Compiler failed

Compiler message:
file:///home/antonio/flutter-sdk/flutter/.pub-cache/hosted/pub.dartlang.org/flutter_sticky_header-0.3.4/lib/src/widgets/sticky_header_layout_builder.dart:147:16: Error: The argument type 'String' can't be assigned to the parameter type 'DiagnosticsNode'.
 - 'DiagnosticsNode' is from 'package:flutter/src/foundation/diagnostics.dart' ('file:///home/antonio/flutter-sdk/flutter/packages/flutter/lib/src/foundation/diagnostics.dart').
Try changing the type of the parameter, or casting the argument to 'DiagnosticsNode'.
      context: context);
               ^
Compiler failed on /home/antonio/workspace-flutter/repo-gcloud/flutter_login/lib/main.dart

FAILURE: Build failed with an exception.

* Where:
Script '/home/antonio/flutter-sdk/flutter/packages/flutter_tools/gradle/flutter.gradle' line: 665

* What went wrong:
Execution failed for task ':app:compileflutterBuildDebugArm'.
> Process 'command '/home/antonio/flutter-sdk/flutter/bin/flutter'' finished with non-zero exit value 1

* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full insights.

* Get more help at https://help.gradle.org

BUILD FAILED in 21s
Finished with error: Gradle task assembleDebug failed with exit code 1

FAILURE: Build failed with an exception.

hi, i am new on flutter. i try clone your project but cant run in my emulator and phone.

this the message:
FAILURE: Build failed with an exception.

  • What went wrong:
    Execution failed for task ':local_auth:parseDebugLibraryResources'.

Could not resolve all files for configuration ':local_auth:androidApis'.
Failed to transform file 'android.jar' to match attributes {artifactType=android-platform-attr, org.gradle.libraryelements=jar, org.gradle.usage=java-runtime}
> Execution failed for PlatformAttrTransform: C:\Users\rahmat.nugroho\AppData\Local\Android\sdk\platforms\android-29\android.jar.
> C:\Users\rahmat.nugroho\AppData\Local\Android\sdk\platforms\android-29\android.jar (The system cannot find the file specified)

  • Try:
    Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full insights.

  • Get more help at https://help.gradle.org

BUILD FAILED in 24s
Exception: Gradle task assembleDebug failed with exit code 1

System can not find key.properties

Hello, thank you for your work.

I tried to build this project, but I face this problem with key.properties:

* Error running Gradle:
ProcessException: Process ".\flutter_login-master\android\gradlew.bat" exited abnormally:

> Configure project :app

Project evaluation failed including an error in afterEvaluate {}. Run with --stacktrace for details of the afterEvaluate {} error.

FAILURE: Build failed with an exception.

* Where:
Build file '.\flutter_login-master\android\app\build.gradle' line: 31

* What went wrong:
A problem occurred evaluating project ':app'.
> .\flutter_login-master\android\key.properties (Systém nemůže nalézt uvedený soubor)

* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full insights.

* Get more help at https://help.gradle.org

BUILD FAILED in 1s
  Command: .\flutter_login-master\android\gradlew.bat app:properties

Finished with error: Please review your Gradle project setup in the android/ folder.

\flutter_login-master>flutter doctor
Doctor summary (to see all details, run flutter doctor -v):
[√] Flutter (Channel beta, v0.11.3, on Microsoft Windows [Version 10.0.14393], locale cs-CZ)
[√] Android toolchain - develop for Android devices (Android SDK 28.0.3)
[√] Android Studio (version 3.2)
[√] VS Code, 64-bit edition (version 1.29.1)
[√] Connected device (1 available)
• No issues found!

Could you help me, please?

Thank you in advance.
Vojtech Pohl

Generated files under VCS

After building the project for Android on my system (Windows) there are some files modified in Git which I think shouldn''t be under VCs as they get modified for different contributors and/or builds.
I'm new to Flutter and have some experience with Android projects, so I'm not sure exactly what files might be safely skipped. These are the files and dirs I suspect:

android/.gradle
pubspec.lock
local.properties

also might be ios/Pods/Manifest.lock and *.lock files in general

best way to make this "my own"?

this might be useful in the Readme too

I will create a PR for this if needed once the informations are collected.

my current observations are, that search and replace "flutter_login" -> "your_project" works in a way.

I'm not sure though if it's everything that is needed because of two things:

  1. if you git clone again flutter_login and build the app, it gets overwritten and it feels like it shares some data with the renamed project
  2. if you create a flutter project from scratch and just copy lib and pubspec.yaml over, it print build errors for me from cocoapods which are rather cryptic...

thx in advance

Unhandled Exception: Failed assertion: boolean expression must not be null

@AppleEducate Great Example.

I am trying to run your project locally, however, I notice this exception is thrown.
Any idea why?

1.)

Xcode build done. 15.1s
flutter: no-action
flutter: Error Loading App State => FileSystemException: Cannot open file, path = '/Users/Developer/CoreSimulator/Devices/D0B4986D-7605-4907
-B75E-C1E307D46C72/data/Containers/Data/Application/C5505F86-1BBD-4538-B827-49D5071CF8DA/Documents/custom_theme.json' (OS Error: No such file or directory, errno
= 2)
Syncing files to device iPhone XR... 1,967ms

🔥 To hot reload changes while running, press "r". To hot restart (and rebuild state), press "R".
An Observatory debugger and profiler on iPhone XR is available at: http://127.0.0.1:57140/
For a more detailed help message, press "h". To detach, press "d"; to quit, press "q".
[VERBOSE-2:ui_dart_state.cc(148)] Unhandled Exception: Failed assertion: boolean expression must not be null
#0 LoginPageState.build.. (package:flutter_login/ui/signin/signin.dart:186:37)
#1 _rootRunUnary (dart:async/zone.dart:1132:38)
#2 _CustomZone.runUnary (dart:async/zone.dart:1029:19)
#3 _FutureListener.handleValue (dart:async/future_impl.dart:126:18)
#4 Future._propagateToListeners.handleValueCallback (dart:async/future_impl.dart:639:45)
#5 Future._propagateToListeners (dart:async/future_impl.dart:668:32)
#6 Future._completeWithValue (dart:async/future_impl.dart:483:5)
#7 Future._asyncComplete. (dart:async/future_impl.dart:513:7)
#8 _rootRun (dart:async/zone.dart:1124:13)
#9 _CustomZone.run (dart:async/zone.dart:1021:19)
#10 _CustomZone.runGuarded (dart:async/zone.dart:923:7)
#11 _CustomZone.bindCallbackGuarded. (dart:async/zone.dart:963:23)
#12 _microtaskLoo<…>

DiagnosticsNode

Compiler message:
/C:/flutter/.pub-cache/hosted/pub.dartlang.org/flutter_sticky_header-0.3.4/lib/src/widgets/sticky_header_layout_builder.dart:147:16: Error: The argument type 'String' can't be assigned to the parameter type 'DiagnosticsNode'.

  • 'DiagnosticsNode' is from 'package:flutter/src/foundation/diagnostics.dart' ('/C:/flutter/packages/flutter/lib/src/foundation/diagnostics.dart').
    Try changing the type of the parameter, or casting the argument to 'DiagnosticsNode'.
    context: context);
    ^
    Compiler failed on C:\xampp\htdocs\kalyan\flutter_login\lib\main.dart

flutter pub get - Failed - Invalid argument(s): Minimum version ("1.0.0") must be less than maximum ("1.0.0-0")

flutter pub get

Invalid argument(s): Minimum version ("1.0.0") must be less than maximum ("1.0.0-0").
package:pub_semver/src/version_range.dart 67:7 new VersionRange
package:pub/src/solver/reformat_ranges.dart 56:27 _reformatTerm
package:pub/src/solver/reformat_ranges.dart 34:26 reformatRanges.
dart:_internal ListIterable.toList
package:pub/src/solver/reformat_ranges.dart 35:12 reformatRanges
package:pub/src/solver/reformat_ranges.dart 134:13 _reformatCause
package:pub/src/solver/reformat_ranges.dart 36:7 reformatRanges
package:pub/src/solver/reformat_ranges.dart 134:13 _reformatCause
package:pub/src/solver/reformat_ranges.dart 36:7 reformatRanges
package:pub/src/solver/reformat_ranges.dart 133:25 _reformatCause
package:pub/src/solver/reformat_ranges.dart 36:7 reformatRanges
package:pub/src/solver/reformat_ranges.dart 133:25 _reformatCause
package:pub/src/solver/reformat_ranges.dart 36:7 reformatRanges
package:pub/src/solver/reformat_ranges.dart 133:25 _reformatCause
package:pub/src/solver/reformat_ranges.dart 36:7 reformatRanges
package:pub/src/solver/version_solver.dart 312:24 VersionSolver._resolveConflict
package:pub/src/solver/version_solver.dart 133:27 VersionSolver._propagate
package:pub/src/solver/version_solver.dart 97:11 VersionSolver.solve.
===== asynchronous gap ===========================
package:pub/src/source/hosted.dart 504:14 BoundHostedSource.withPrefetching.
===== asynchronous gap ===========================
package:pub/src/rate_limited_scheduler.dart 106:14 RateLimitedScheduler.withPrescheduling
===== asynchronous gap ===========================
package:pub/src/source/hosted.dart 503:12 BoundHostedSource.withPrefetching
===== asynchronous gap ===========================
package:pub/src/solver/version_solver.dart 94:14 VersionSolver.solve
This is an unexpected error. Please run

pub --trace pub get --no-precompile

and include the logs in an issue on https://github.com/dart-lang/pub/issues/new
Running "flutter pub get" in flutter_login...
pub get failed (1; and include the logs in an issue on https://github.com/dart-lang/pub/issues/new)

The exception is for the persist_theme plugin. When you first launch the

The exception is for the persist_theme plugin. When you first launch the
file doesn’t exist so it creates one. I’ll update the plugin then up date
Flutter_login

On Sat, Apr 6, 2019 at 9:09 AM Arivu Labs [email protected] wrote:

@AppleEducate https://github.com/AppleEducate Great Example.

I am trying to run your project locally, however, I notice this exception
is thrown.
Any idea why?

1.)

Xcode build done. 15.1s
flutter: no-action
flutter: Error Loading App State => FileSystemException: Cannot open file,
path =
'/Users/Library/Developer/CoreSimulator/Devices/D0B4986D-7605-4907
-B75E-C1E307D46C72/data/Containers/Data/Application/C5505F86-1BBD-4538-B827-49D5071CF8DA/Documents/custom_theme.json'
(OS Error: No such file or directory, errno
= 2)
Syncing files to device iPhone XR... 1,967ms

🔥 To hot reload changes while running, press "r". To hot restart (and
rebuild state), press "R".
An Observatory debugger and profiler on iPhone XR is available at:
http://127.0.0.1:57140/
For a more detailed help message, press "h". To detach, press "d"; to
quit, press "q".
[VERBOSE-2:ui_dart_state.cc(148)] Unhandled Exception: Failed assertion:
boolean expression must not be null
#0 LoginPageState.build..
(package:flutter_login/ui/signin/signin.dart:186:37)
#1 #1 _rootRunUnary
(dart:async/zone.dart:1132:38)
#2 #2
_CustomZone.runUnary (dart:async/zone.dart:1029:19)
#3 #3
_FutureListener.handleValue (dart:async/future_impl.dart:126:18)
#4 #4
Future._propagateToListeners.handleValueCallback
(dart:async/future_impl.dart:639:45)
#5 #5
Future._propagateToListeners (dart:async/future_impl.dart:668:32)
#6 #6
Future._completeWithValue (dart:async/future_impl.dart:483:5)
#7 #7
Future._asyncComplete. (dart:async/future_impl.dart:513:7)
#8 #8 _rootRun
(dart:async/zone.dart:1124:13)
#9 #9
_CustomZone.run (dart:async/zone.dart:1021:19)
#10 #10
_CustomZone.runGuarded (dart:async/zone.dart:923:7)
#11 #11
_CustomZone.bindCallbackGuarded. (dart:async/zone.dart:963:23)
#12 #12
_microtaskLoo<…>


You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
#21, or mute the
thread
https://github.com/notifications/unsubscribe-auth/Adzi3xmH8dIMoBcmYUh6hyP_IH0-w8Hsks5veJyhgaJpZM4cgMS0
.

--
Rody Davis Jr

Originally posted by @AppleEducate in #21 (comment)

Future<String> getData(Map params) / token questions

https://github.com/AppleEducate/flutter_login/blob/5a04073845988613cf7e576362966512bec2a6d2/lib/globals.dart#L82

  1. can you show how you'd use the params that this method takes in?
  2. when would its response ever contain 'Invalid Token' ? i noticed Future checkToken() calls it.
    https://github.com/AppleEducate/flutter_login/blob/5a04073845988613cf7e576362966512bec2a6d2/lib/signin/auth_service.dart#L97
  3. i don't see the token getting checked. could you give a sample or point me to where it is?
  4. how is the mapData expected to be used? i couldn't see what the expected usage from the assignment alone: https://github.com/AppleEducate/flutter_login/blob/5a04073845988613cf7e576362966512bec2a6d2/lib/signin/auth_service.dart#L26
  5. how is the code below this comment involved in getting a token? https://github.com/AppleEducate/flutter_login/blob/5a04073845988613cf7e576362966512bec2a6d2/lib/signin/auth_service.dart#L24
    from looking at the uuid package, i guess the only part of this code that's involved in getting a token is:
    var uuid = new Uuid();
    String ..., _token;
    _token = uuid.v4().toString();
    is that right?
  6. when would validToken ever be false? it seems there's nothing that would prevent uuid from creating the token, as it's doing? https://github.com/AppleEducate/flutter_login/blob/5a04073845988613cf7e576362966512bec2a6d2/lib/signin/auth_service.dart#L55

thank you!

Server side

This is really awesome security package.
Could you publish the server side code it expects ?

My intention is to integrate this with golang server and use grpc for networking.
Would be happy to publish it.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.