feat: Migrations, new saved views interface

This commit is contained in:
Anton Stubenbord
2023-09-19 01:50:02 +02:00
parent 2e8144700f
commit f3560f00ea
31 changed files with 1745 additions and 376 deletions

View File

@@ -55,9 +55,17 @@ class _LandingPageState extends State<LandingPage> {
SliverPadding(
padding: const EdgeInsets.fromLTRB(16, 16, 0, 8),
sliver: SliverToBoxAdapter(
child: Text(
"Saved Views",
style: Theme.of(context).textTheme.titleMedium,
child: Row(
children: [
Icon(
Icons.saved_search,
color: Theme.of(context).colorScheme.primary,
).paddedOnly(right: 8),
Text(
S.of(context)!.views,
style: Theme.of(context).textTheme.titleMedium,
),
],
),
),
),
@@ -75,7 +83,7 @@ class _LandingPageState extends State<LandingPage> {
children: [
Text(
"There are no saved views to show on your dashboard.", //TODO: INTL
),
).padded(),
TextButton.icon(
onPressed: () {},
icon: const Icon(Icons.add),
@@ -89,6 +97,7 @@ class _LandingPageState extends State<LandingPage> {
itemBuilder: (context, index) {
return SavedViewPreview(
savedView: dashboardViews.elementAt(index),
expanded: index == 0,
);
},
itemCount: dashboardViews.length,

View File

@@ -29,7 +29,7 @@ class ExpansionCard extends StatelessWidget {
),
),
child: ExpansionTile(
backgroundColor: Theme.of(context).colorScheme.surface,
backgroundColor: Theme.of(context).colorScheme.surfaceVariant,
initiallyExpanded: initiallyExpanded,
title: title,
children: [content],