Resolves #421 Manual long-lived token

This commit is contained in:
estevez-dev
2019-08-26 18:04:40 +03:00
parent 37155901ef
commit fadfefd836
3 changed files with 71 additions and 4 deletions

View File

@ -155,14 +155,23 @@ class HAClientApp extends StatelessWidget {
"/configuration": (context) => PanelPage(title: "Configuration"),
"/putchase": (context) => PurchasePage(title: "Support app development"),
"/log-view": (context) => LogViewPage(title: "Log"),
"/login": (_) => WebviewScaffold(
"/login": (context) => WebviewScaffold(
url: "${Connection().oauthUrl}",
appBar: new AppBar(
leading: IconButton(
icon: Icon(Icons.help),
onPressed: () => HAUtils.launchURLInCustomTab(context: context, url: "http://ha-client.homemade.systems/docs#authentication")
),
title: new Text("Login to your Home Assistant"),
title: new Text("Login with HA"),
actions: <Widget>[
FlatButton(
child: Text("Manual", style: TextStyle(color: Colors.white)),
onPressed: () {
Navigator.of(context).pop();
Navigator.of(context).pushNamed("/connection-settings");
},
)
],
),
)
},