Solian/lib/widgets/navigation/app_navigation.dart

43 lines
988 B
Dart
Raw Normal View History

2024-05-18 18:17:16 +08:00
import 'package:flutter/material.dart';
import 'package:get/utils.dart';
abstract class AppNavigation {
static List<AppNavigationDestination> destinations = [
AppNavigationDestination(
2024-05-23 20:00:26 +08:00
icon: const Icon(Icons.public),
label: 'social'.tr,
page: 'social',
2024-05-18 18:17:16 +08:00
),
2024-05-23 21:12:47 +08:00
AppNavigationDestination(
icon: const Icon(Icons.forum),
label: 'chat'.tr,
page: 'chat',
2024-05-23 21:12:47 +08:00
),
2024-05-28 22:13:23 +08:00
AppNavigationDestination(
icon: const Icon(Icons.workspaces),
label: 'realms'.tr,
page: 'realms',
),
2024-05-18 18:17:16 +08:00
AppNavigationDestination(
icon: const Icon(Icons.account_circle),
label: 'account'.tr,
page: 'account',
),
];
2024-06-27 15:50:13 +08:00
static List<String> get destinationPages =>
AppNavigation.destinations.map((x) => x.page).toList();
2024-05-18 18:17:16 +08:00
}
class AppNavigationDestination {
final Widget icon;
final String label;
final String page;
2024-05-28 22:13:23 +08:00
AppNavigationDestination({
required this.icon,
required this.label,
required this.page,
});
2024-05-18 18:17:16 +08:00
}