Change profile basic disposition
This commit is contained in:
parent
1893502e6b
commit
16e9f79e14
|
@ -7,9 +7,11 @@ import 'package:sentry/sentry.dart' as sentry;
|
||||||
import 'package:qrscan/qrscan.dart' as scanner;
|
import 'package:qrscan/qrscan.dart' as scanner;
|
||||||
import 'dart:math';
|
import 'dart:math';
|
||||||
import 'package:intl/intl.dart';
|
import 'package:intl/intl.dart';
|
||||||
|
import 'package:truncate/truncate.dart';
|
||||||
|
|
||||||
class HistoryProvider with ChangeNotifier {
|
class HistoryProvider with ChangeNotifier {
|
||||||
String pubkey = '';
|
String pubkey = '';
|
||||||
|
String pubkeyShort = '';
|
||||||
HistoryProvider(this.pubkey);
|
HistoryProvider(this.pubkey);
|
||||||
final TextEditingController outputPubkey = TextEditingController();
|
final TextEditingController outputPubkey = TextEditingController();
|
||||||
List transBC;
|
List transBC;
|
||||||
|
@ -54,6 +56,10 @@ class HistoryProvider with ChangeNotifier {
|
||||||
print("C'est une pubkey !!!");
|
print("C'est une pubkey !!!");
|
||||||
|
|
||||||
this.pubkey = pubkey;
|
this.pubkey = pubkey;
|
||||||
|
pubkeyShort = truncate(pubkey, 5,
|
||||||
|
omission: ":", position: TruncatePosition.end) +
|
||||||
|
truncate(pubkey, 4, omission: "", position: TruncatePosition.start) +
|
||||||
|
':aaa';
|
||||||
this.outputPubkey.text = pubkey;
|
this.outputPubkey.text = pubkey;
|
||||||
notifyListeners();
|
notifyListeners();
|
||||||
|
|
||||||
|
|
|
@ -193,10 +193,11 @@ class HistoryScreen extends StatelessWidget with ChangeNotifier {
|
||||||
'/default_avatar.png'),
|
'/default_avatar.png'),
|
||||||
height: 65);
|
height: 65);
|
||||||
})),
|
})),
|
||||||
if (_isFirstExec)
|
Text(_historyProvider.pubkeyShort,
|
||||||
Text(balance.toString() + ' Ğ1',
|
style: TextStyle(
|
||||||
textAlign: TextAlign.center,
|
fontSize: 22,
|
||||||
style: TextStyle(fontSize: 30.0)),
|
fontWeight: FontWeight.w800,
|
||||||
|
fontFamily: 'Monospace')),
|
||||||
Container(
|
Container(
|
||||||
padding: const EdgeInsets.fromLTRB(
|
padding: const EdgeInsets.fromLTRB(
|
||||||
30, 0, 15, 0), // .only(right: 15),
|
30, 0, 15, 0), // .only(right: 15),
|
||||||
|
@ -212,7 +213,7 @@ class HistoryScreen extends StatelessWidget with ChangeNotifier {
|
||||||
iconSize: 30,
|
iconSize: 30,
|
||||||
color: Color(0xFFB16E16)))
|
color: Color(0xFFB16E16)))
|
||||||
]),
|
]),
|
||||||
SizedBox(height: 10),
|
SizedBox(height: 15),
|
||||||
if (_isFirstExec)
|
if (_isFirstExec)
|
||||||
Row(
|
Row(
|
||||||
mainAxisAlignment: MainAxisAlignment.spaceAround,
|
mainAxisAlignment: MainAxisAlignment.spaceAround,
|
||||||
|
@ -225,9 +226,15 @@ class HistoryScreen extends StatelessWidget with ChangeNotifier {
|
||||||
.getName(_historyProvider.pubkey),
|
.getName(_historyProvider.pubkey),
|
||||||
initialData: '',
|
initialData: '',
|
||||||
builder: (context, snapshot) {
|
builder: (context, snapshot) {
|
||||||
return Text(snapshot.data);
|
return Text(snapshot.data,
|
||||||
|
style: TextStyle(fontSize: 16));
|
||||||
}))
|
}))
|
||||||
]),
|
]),
|
||||||
|
SizedBox(height: 15),
|
||||||
|
if (_isFirstExec)
|
||||||
|
Text(balance.toString() + ' Ğ1',
|
||||||
|
textAlign: TextAlign.center,
|
||||||
|
style: TextStyle(fontSize: 20.0)),
|
||||||
SizedBox(height: 20),
|
SizedBox(height: 20),
|
||||||
const Divider(
|
const Divider(
|
||||||
color: Colors.grey,
|
color: Colors.grey,
|
||||||
|
|
Loading…
Reference in New Issue