clean up search page design
This commit is contained in:
parent
2029c55e95
commit
52151dab7c
|
@ -1,5 +1,4 @@
|
|||
import 'package:flutter/material.dart';
|
||||
import 'package:flutter_markdown/flutter_markdown.dart';
|
||||
import 'package:loris/business_logic/notifications/notifs.dart';
|
||||
import 'package:loris/dialogues/profile_view.dart';
|
||||
import 'package:loris/partials/name.dart';
|
||||
|
|
|
@ -53,17 +53,51 @@ class _SearchPageState extends State<SearchPage> {
|
|||
}
|
||||
},
|
||||
);
|
||||
return Container(
|
||||
decoration: BoxDecoration(
|
||||
border: Border(
|
||||
bottom: BorderSide(
|
||||
color: Theme.of(context).colorScheme.primary,
|
||||
width: 2,
|
||||
))),
|
||||
child: Material(
|
||||
child: Column(
|
||||
children: [
|
||||
Column(
|
||||
return Material(
|
||||
child: Column(
|
||||
children: [
|
||||
Expanded(
|
||||
child: ListView.builder(
|
||||
shrinkWrap: true,
|
||||
itemCount: accountModels.length + postModels.length,
|
||||
itemBuilder: (context, index) {
|
||||
if (index < accountModels.length) {
|
||||
final model = accountModels[index];
|
||||
return Container(
|
||||
width: global.getWidth(context),
|
||||
constraints: global.getConstraints(context),
|
||||
child: Padding(
|
||||
padding: themes.defaultMargins,
|
||||
child: Column(
|
||||
children: [
|
||||
SelectableText(model.identity),
|
||||
DisplayName(account: model)
|
||||
],
|
||||
),
|
||||
),
|
||||
);
|
||||
}
|
||||
final model = postModels[index - accountModels.length];
|
||||
return Padding(
|
||||
padding: const EdgeInsets.all(8.0),
|
||||
child: Column(
|
||||
children: [
|
||||
SelectableText(model.identity),
|
||||
Post(
|
||||
model: model,
|
||||
)
|
||||
],
|
||||
),
|
||||
);
|
||||
}),
|
||||
),
|
||||
Container(
|
||||
decoration: BoxDecoration(
|
||||
border: Border(
|
||||
top: BorderSide(
|
||||
color: Theme.of(context).colorScheme.primary,
|
||||
width: 2))),
|
||||
child: Column(
|
||||
children: [
|
||||
TextField(
|
||||
style: Theme.of(context).textTheme.bodyMedium,
|
||||
|
@ -93,45 +127,8 @@ class _SearchPageState extends State<SearchPage> {
|
|||
),
|
||||
],
|
||||
),
|
||||
Expanded(
|
||||
child: Container(
|
||||
width: global.getWidth(context),
|
||||
constraints: BoxConstraints(
|
||||
maxWidth: global.getConstraints(context).maxWidth,
|
||||
),
|
||||
child: ListView.builder(
|
||||
shrinkWrap: true,
|
||||
itemCount: accountModels.length + postModels.length,
|
||||
itemBuilder: (context, index) {
|
||||
if (index < accountModels.length) {
|
||||
final model = accountModels[index];
|
||||
return Padding(
|
||||
padding: themes.defaultMargins,
|
||||
child: Column(
|
||||
children: [
|
||||
SelectableText(model.identity),
|
||||
DisplayName(account: model)
|
||||
],
|
||||
),
|
||||
);
|
||||
}
|
||||
final model = postModels[index - accountModels.length];
|
||||
return Padding(
|
||||
padding: const EdgeInsets.all(8.0),
|
||||
child: Column(
|
||||
children: [
|
||||
SelectableText(model.identity),
|
||||
Post(
|
||||
model: model,
|
||||
)
|
||||
],
|
||||
),
|
||||
);
|
||||
}),
|
||||
),
|
||||
),
|
||||
],
|
||||
),
|
||||
),
|
||||
],
|
||||
),
|
||||
);
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue