Skip to content

Commit 908bf05

Browse files
committed
feat(dashboard): update quick actions card
Refactors the `_QuickActionsCard` to include only "Create Headline", "Create Category", and "Create Source" actions. All actions are now represented by `ElevatedButton` widgets for a consistent appearance and navigate to their respective creation pages.
1 parent cb4874c commit 908bf05

File tree

1 file changed

+19
-20
lines changed

1 file changed

+19
-20
lines changed

lib/dashboard/view/dashboard_page.dart

Lines changed: 19 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -234,34 +234,33 @@ class _QuickActionsCard extends StatelessWidget {
234234
child: Padding(
235235
padding: const EdgeInsets.all(AppSpacing.lg),
236236
child: Column(
237-
crossAxisAlignment: CrossAxisAlignment.start,
237+
crossAxisAlignment: CrossAxisAlignment.stretch,
238238
children: [
239239
Text(l10n.quickActions, style: theme.textTheme.titleLarge),
240240
const SizedBox(height: AppSpacing.md),
241-
SizedBox(
242-
width: double.infinity,
243-
child: ElevatedButton.icon(
244-
icon: const Icon(Icons.add_circle_outline),
245-
label: Text(l10n.createHeadlineAction),
246-
onPressed: () => context.goNamed(Routes.createHeadlineName),
247-
),
241+
ElevatedButton.icon(
242+
icon: const Icon(Icons.add_circle_outline),
243+
label: Text(l10n.createHeadlineAction),
244+
onPressed: () => context.goNamed(Routes.createHeadlineName),
248245
),
249246
const SizedBox(height: AppSpacing.sm),
250-
SizedBox(
251-
width: double.infinity,
252-
child: OutlinedButton.icon(
253-
icon: const Icon(Icons.folder_open_outlined),
254-
label: Text(l10n.manageContentAction),
255-
onPressed: () => context.goNamed(Routes.contentManagementName),
247+
ElevatedButton.icon(
248+
icon: const Icon(Icons.create_new_folder_outlined),
249+
label: Text(l10n.createCategory),
250+
onPressed: () => context.goNamed(Routes.createCategoryName),
251+
style: ElevatedButton.styleFrom(
252+
backgroundColor: theme.colorScheme.secondaryContainer,
253+
foregroundColor: theme.colorScheme.onSecondaryContainer,
256254
),
257255
),
258256
const SizedBox(height: AppSpacing.sm),
259-
SizedBox(
260-
width: double.infinity,
261-
child: OutlinedButton.icon(
262-
icon: const Icon(Icons.settings_applications_outlined),
263-
label: Text(l10n.appConfigAction),
264-
onPressed: () => context.goNamed(Routes.appConfigurationName),
257+
ElevatedButton.icon(
258+
icon: const Icon(Icons.add_to_photos_outlined),
259+
label: Text(l10n.createSource),
260+
onPressed: () => context.goNamed(Routes.createSourceName),
261+
style: ElevatedButton.styleFrom(
262+
backgroundColor: theme.colorScheme.secondaryContainer,
263+
foregroundColor: theme.colorScheme.onSecondaryContainer,
265264
),
266265
),
267266
],

0 commit comments

Comments
 (0)