mirror of
https://github.com/cypherstack/stack_wallet.git
synced 2024-12-23 20:09:23 +00:00
desktop paynym card clean up
This commit is contained in:
parent
d957cad4ba
commit
21cc545251
3 changed files with 70 additions and 66 deletions
|
@ -439,6 +439,11 @@ class _AddNewPaynymFollowViewState
|
||||||
if (_didSearch && _searchResult != null)
|
if (_didSearch && _searchResult != null)
|
||||||
RoundedWhiteContainer(
|
RoundedWhiteContainer(
|
||||||
padding: const EdgeInsets.all(0),
|
padding: const EdgeInsets.all(0),
|
||||||
|
borderColor: isDesktop
|
||||||
|
? Theme.of(context)
|
||||||
|
.extension<StackColors>()!
|
||||||
|
.backgroundAppBar
|
||||||
|
: null,
|
||||||
child: PaynymCard(
|
child: PaynymCard(
|
||||||
label: _searchResult!.nymName,
|
label: _searchResult!.nymName,
|
||||||
paymentCodeString: _searchResult!.codes.first.code,
|
paymentCodeString: _searchResult!.codes.first.code,
|
||||||
|
|
|
@ -41,11 +41,21 @@ class FeaturedPaynymsWidget extends StatelessWidget {
|
||||||
.backgroundAppBar,
|
.backgroundAppBar,
|
||||||
height: 1,
|
height: 1,
|
||||||
),
|
),
|
||||||
PaynymCard(
|
ConditionalParent(
|
||||||
|
condition: isDesktop,
|
||||||
|
builder: (child) => RoundedWhiteContainer(
|
||||||
|
padding: const EdgeInsets.all(0),
|
||||||
|
borderColor: Theme.of(context)
|
||||||
|
.extension<StackColors>()!
|
||||||
|
.backgroundAppBar,
|
||||||
|
child: child,
|
||||||
|
),
|
||||||
|
child: PaynymCard(
|
||||||
walletId: walletId,
|
walletId: walletId,
|
||||||
label: entries[i].key,
|
label: entries[i].key,
|
||||||
paymentCodeString: entries[i].value,
|
paymentCodeString: entries[i].value,
|
||||||
),
|
),
|
||||||
|
),
|
||||||
],
|
],
|
||||||
),
|
),
|
||||||
],
|
],
|
||||||
|
|
|
@ -4,9 +4,7 @@ import 'package:stackwallet/utilities/format.dart';
|
||||||
import 'package:stackwallet/utilities/text_styles.dart';
|
import 'package:stackwallet/utilities/text_styles.dart';
|
||||||
import 'package:stackwallet/utilities/theme/stack_colors.dart';
|
import 'package:stackwallet/utilities/theme/stack_colors.dart';
|
||||||
import 'package:stackwallet/utilities/util.dart';
|
import 'package:stackwallet/utilities/util.dart';
|
||||||
import 'package:stackwallet/widgets/conditional_parent.dart';
|
|
||||||
import 'package:stackwallet/widgets/custom_buttons/paynym_follow_toggle_button.dart';
|
import 'package:stackwallet/widgets/custom_buttons/paynym_follow_toggle_button.dart';
|
||||||
import 'package:stackwallet/widgets/rounded_white_container.dart';
|
|
||||||
|
|
||||||
class PaynymCard extends StatefulWidget {
|
class PaynymCard extends StatefulWidget {
|
||||||
const PaynymCard({
|
const PaynymCard({
|
||||||
|
@ -29,15 +27,7 @@ class _PaynymCardState extends State<PaynymCard> {
|
||||||
|
|
||||||
@override
|
@override
|
||||||
Widget build(BuildContext context) {
|
Widget build(BuildContext context) {
|
||||||
return ConditionalParent(
|
return Padding(
|
||||||
condition: isDesktop,
|
|
||||||
builder: (child) => RoundedWhiteContainer(
|
|
||||||
padding: const EdgeInsets.all(0),
|
|
||||||
borderColor:
|
|
||||||
Theme.of(context).extension<StackColors>()!.backgroundAppBar,
|
|
||||||
child: child,
|
|
||||||
),
|
|
||||||
child: Padding(
|
|
||||||
padding: isDesktop
|
padding: isDesktop
|
||||||
? const EdgeInsets.symmetric(
|
? const EdgeInsets.symmetric(
|
||||||
vertical: 16,
|
vertical: 16,
|
||||||
|
@ -90,7 +80,6 @@ class _PaynymCardState extends State<PaynymCard> {
|
||||||
),
|
),
|
||||||
],
|
],
|
||||||
),
|
),
|
||||||
),
|
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue