screm
This commit is contained in:
parent
45f720e313
commit
bc8d31ccbc
5 changed files with 28 additions and 9 deletions
|
@ -43,8 +43,8 @@ void openBrowserForAuthCode(String baseurl, App app) {
|
|||
Uri url = Uri.https(
|
||||
baseurl,
|
||||
// ignore: prefer_interpolation_to_compose_strings
|
||||
"/oauth/authorize" +
|
||||
"?client_id=" +
|
||||
"/oauth/authorize"
|
||||
"?client_id=" +
|
||||
app.clientId +
|
||||
"&scope=read+write" +
|
||||
"&redirect_uri=urn:ietf:wg:oauth:2.0:oob" +
|
||||
|
|
|
@ -17,7 +17,7 @@ String cleanUpUsername({required String name}) {
|
|||
|
||||
String urlFromUsername({required String name}) {
|
||||
name = cleanUpUsername(name: name);
|
||||
return "${name.substring(name.indexOf("@") + 1)}";
|
||||
return name.substring(name.indexOf("@") + 1);
|
||||
}
|
||||
|
||||
String userFromUsername({required String name}) {
|
||||
|
|
|
@ -1,9 +1,13 @@
|
|||
{
|
||||
"greeting": "hallo!",
|
||||
"user-id-not-valid": "Hmm... die id sieht nicht ganz richtig aus...",
|
||||
"user-id-not-valid": "hmm... die id sieht nicht ganz richtig aus...",
|
||||
"user-id": "nutzer id",
|
||||
"user-id-example": "nutzer@beispiel.de",
|
||||
"authorize-in-browser": "im browser autorisieren",
|
||||
"login-failed-snackbar-text": "login fehlgeschlagen!"
|
||||
"login-failed-snackbar-text": "login fehlgeschlagen!",
|
||||
"back-button": "zurück",
|
||||
"confirm-button": "bestätigen",
|
||||
"copy-code-from-browser": "bitte den code aus dem browser hierhin kopieren.",
|
||||
"code-hint": "code"
|
||||
}
|
||||
|
|
@ -1,9 +1,13 @@
|
|||
{
|
||||
"greeting": "hello!",
|
||||
"user-id-not-valid": "Sorry, this user id doesn't look quite right... ",
|
||||
"user-id-not-valid": "sorry, this user id doesn't look quite right... ",
|
||||
"user-id": "user id",
|
||||
"user-id-example": "user@example.com",
|
||||
"authorize-in-browser": "authorize in browser",
|
||||
"login-failed-snackbar-text": "login failed!"
|
||||
"login-failed-snackbar-text": "login failed!",
|
||||
"back-button": "back",
|
||||
"confirm-button": "confirm",
|
||||
"copy-code-from-browser": "please copy the code from your browser here!",
|
||||
"code-hint": "code"
|
||||
}
|
||||
|
|
@ -93,8 +93,19 @@ class _AuthPageState extends State<AuthPage> {
|
|||
@override
|
||||
Widget build(BuildContext context) {
|
||||
return Scaffold(
|
||||
body: Center(
|
||||
child: Text("hello"),
|
||||
body: Padding(
|
||||
padding: const EdgeInsets.all(8.0),
|
||||
child: Column(
|
||||
mainAxisAlignment: MainAxisAlignment.spaceEvenly,
|
||||
children: [
|
||||
Text("copy-code-from-browser".i18n()),
|
||||
TextFormField(
|
||||
decoration: InputDecoration(
|
||||
hintText: "123-ABC",
|
||||
icon: const Icon(Icons.password),
|
||||
labelText: "code-hint".i18n()))
|
||||
],
|
||||
),
|
||||
),
|
||||
);
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue