Signed-off-by: bggRGjQaUbCoE <githubaccount56556@proton.me>
This commit is contained in:
bggRGjQaUbCoE
2025-10-13 21:26:50 +08:00
parent 019cd9fda0
commit 11edabb890
3 changed files with 250 additions and 256 deletions

View File

@@ -34,70 +34,68 @@ class SearchUserController
builder: (context) {
final theme = Theme.of(context);
return SingleChildScrollView(
child: Padding(
padding: EdgeInsets.only(
top: 20,
left: 16,
right: 16,
bottom: 100 + MediaQuery.viewPaddingOf(context).bottom,
),
child: Column(
mainAxisSize: MainAxisSize.min,
crossAxisAlignment: CrossAxisAlignment.start,
children: [
const SizedBox(height: 10),
const Text('用户粉丝数及等级排序顺序', style: TextStyle(fontSize: 16)),
const SizedBox(height: 10),
Wrap(
spacing: 8,
runSpacing: 8,
children: UserOrderType.values.map(
(e) {
final isCurr = e == userOrderType!.value;
return SearchText(
text: e.label,
onTap: (_) {
userOrderType!.value = e;
order = e.order;
onSortSearch(label: e.label);
},
bgColor: isCurr
? theme.colorScheme.secondaryContainer
: null,
textColor: isCurr
? theme.colorScheme.onSecondaryContainer
: null,
);
},
).toList(),
),
const SizedBox(height: 20),
const Text('用户分类', style: TextStyle(fontSize: 16)),
const SizedBox(height: 10),
Wrap(
spacing: 8,
runSpacing: 8,
children: UserType.values.map(
(e) {
final isCurr = e == userType!.value;
return SearchText(
text: e.label,
onTap: (_) {
userType!.value = e;
onSortSearch(label: e.label);
},
bgColor: isCurr
? theme.colorScheme.secondaryContainer
: null,
textColor: isCurr
? theme.colorScheme.onSecondaryContainer
: null,
);
},
).toList(),
),
],
),
padding: EdgeInsets.only(
top: 20,
left: 16,
right: 16,
bottom: 100 + MediaQuery.viewPaddingOf(context).bottom,
),
child: Column(
mainAxisSize: MainAxisSize.min,
crossAxisAlignment: CrossAxisAlignment.stretch,
children: [
const SizedBox(height: 10),
const Text('用户粉丝数及等级排序顺序', style: TextStyle(fontSize: 16)),
const SizedBox(height: 10),
Wrap(
spacing: 8,
runSpacing: 8,
children: UserOrderType.values.map(
(e) {
final isCurr = e == userOrderType!.value;
return SearchText(
text: e.label,
onTap: (_) {
userOrderType!.value = e;
order = e.order;
onSortSearch(label: e.label);
},
bgColor: isCurr
? theme.colorScheme.secondaryContainer
: null,
textColor: isCurr
? theme.colorScheme.onSecondaryContainer
: null,
);
},
).toList(),
),
const SizedBox(height: 20),
const Text('用户分类', style: TextStyle(fontSize: 16)),
const SizedBox(height: 10),
Wrap(
spacing: 8,
runSpacing: 8,
children: UserType.values.map(
(e) {
final isCurr = e == userType!.value;
return SearchText(
text: e.label,
onTap: (_) {
userType!.value = e;
onSortSearch(label: e.label);
},
bgColor: isCurr
? theme.colorScheme.secondaryContainer
: null,
textColor: isCurr
? theme.colorScheme.onSecondaryContainer
: null,
);
},
).toList(),
),
],
),
);
},