TF-460 Add presentation layer for implement get all identities
This commit is contained in:
@@ -102,8 +102,4 @@ abstract class ReloadableController extends BaseController {
|
||||
_clearAllCacheAction();
|
||||
goToLogin();
|
||||
}
|
||||
|
||||
void goToSettings() {
|
||||
push(AppRoutes.MANAGE_ACCOUNT);
|
||||
}
|
||||
}
|
||||
@@ -35,6 +35,7 @@ import 'package:tmail_ui_user/features/mailbox_dashboard/domain/state/remove_ema
|
||||
import 'package:tmail_ui_user/features/mailbox_dashboard/domain/usecases/get_user_profile_interactor.dart';
|
||||
import 'package:tmail_ui_user/features/mailbox_dashboard/domain/usecases/remove_email_drafts_interactor.dart';
|
||||
import 'package:tmail_ui_user/features/mailbox_dashboard/presentation/action/dashboard_action.dart';
|
||||
import 'package:tmail_ui_user/features/manage_account/presentation/model/manage_account_arguments.dart';
|
||||
import 'package:tmail_ui_user/features/thread/domain/model/search_query.dart';
|
||||
import 'package:tmail_ui_user/features/thread/domain/state/search_email_state.dart';
|
||||
import 'package:tmail_ui_user/features/thread/presentation/model/search_state.dart';
|
||||
@@ -422,6 +423,11 @@ class MailboxDashBoardController extends ReloadableController {
|
||||
dashBoardAction.value = DashBoardAction.idle;
|
||||
}
|
||||
|
||||
void goToSettings() {
|
||||
push(AppRoutes.MANAGE_ACCOUNT,
|
||||
arguments: ManageAccountArguments(accountId.value, userProfile.value));
|
||||
}
|
||||
|
||||
@override
|
||||
void onClose() {
|
||||
_emailReceiveManager.closeEmailReceiveManagerStream();
|
||||
|
||||
+5
-5
@@ -15,11 +15,11 @@ mixin UserSettingPopupMenuMixin {
|
||||
enabled: false,
|
||||
padding: EdgeInsets.zero,
|
||||
child: _userInformation(context, userProfile)),
|
||||
PopupMenuDivider(height: 0.5),
|
||||
const PopupMenuDivider(height: 0.5),
|
||||
PopupMenuItem(
|
||||
padding: EdgeInsets.zero,
|
||||
child: _settingAction(context, onSettingAction)),
|
||||
PopupMenuDivider(height: 0.5),
|
||||
const PopupMenuDivider(height: 0.5),
|
||||
PopupMenuItem(
|
||||
padding: EdgeInsets.zero,
|
||||
child: _logoutAction(context, onLogoutAction)),
|
||||
@@ -31,14 +31,14 @@ mixin UserSettingPopupMenuMixin {
|
||||
return SizedBox(
|
||||
width: 300,
|
||||
child: ListTile(
|
||||
contentPadding: EdgeInsets.symmetric(horizontal: 20),
|
||||
title: Text(userProfile.email, maxLines: 1, style: TextStyle(
|
||||
contentPadding: const EdgeInsets.symmetric(horizontal: 20),
|
||||
title: Text(userProfile.email, maxLines: 1, style: const TextStyle(
|
||||
fontSize: 15,
|
||||
color: AppColor.colorHintSearchBar,
|
||||
fontWeight: FontWeight.normal))),
|
||||
);
|
||||
}
|
||||
return SizedBox.shrink();
|
||||
return const SizedBox.shrink();
|
||||
}
|
||||
|
||||
Widget _settingAction(BuildContext context, Function? onCallBack) {
|
||||
|
||||
-31
@@ -1,31 +0,0 @@
|
||||
import 'package:get/get.dart';
|
||||
import 'package:tmail_ui_user/features/base/base_bindings.dart';
|
||||
import 'package:tmail_ui_user/features/manage_account/presentation/account_properties/profiles/identities/identities_controller.dart';
|
||||
|
||||
class IdentitiesBindings extends BaseBindings {
|
||||
|
||||
@override
|
||||
void bindingsController() {
|
||||
Get.lazyPut(() => IdentitiesController());
|
||||
}
|
||||
|
||||
@override
|
||||
void bindingsDataSource() {
|
||||
}
|
||||
|
||||
@override
|
||||
void bindingsDataSourceImpl() {
|
||||
}
|
||||
|
||||
@override
|
||||
void bindingsInteractor() {
|
||||
}
|
||||
|
||||
@override
|
||||
void bindingsRepository() {
|
||||
}
|
||||
|
||||
@override
|
||||
void bindingsRepositoryImpl() {
|
||||
}
|
||||
}
|
||||
-17
@@ -1,17 +0,0 @@
|
||||
|
||||
import 'package:core/core.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:get/get.dart';
|
||||
import 'package:tmail_ui_user/features/manage_account/presentation/account_properties/profiles/identities/identities_controller.dart';
|
||||
|
||||
class IdentitiesView extends GetWidget<IdentitiesController> {
|
||||
|
||||
final _responsiveUtils = Get.find<ResponsiveUtils>();
|
||||
|
||||
IdentitiesView({Key? key}) : super(key: key);
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
return Container(color: Colors.green);
|
||||
}
|
||||
}
|
||||
-17
@@ -1,17 +0,0 @@
|
||||
|
||||
import 'package:get/get.dart';
|
||||
import 'package:tmail_ui_user/features/base/base_controller.dart';
|
||||
import 'package:tmail_ui_user/features/manage_account/presentation/model/profiles_tab_type.dart';
|
||||
|
||||
class ProfilesController extends BaseController {
|
||||
|
||||
final tabTypeSelected = ProfilesTabType.identities.obs;
|
||||
|
||||
@override
|
||||
void onDone() {
|
||||
}
|
||||
|
||||
@override
|
||||
void onError(error) {
|
||||
}
|
||||
}
|
||||
-60
@@ -1,60 +0,0 @@
|
||||
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:get/get.dart';
|
||||
import 'package:model/model.dart';
|
||||
import 'package:package_info_plus/package_info_plus.dart';
|
||||
import 'package:tmail_ui_user/features/base/reloadable/reloadable_controller.dart';
|
||||
import 'package:tmail_ui_user/features/mailbox_dashboard/domain/state/get_user_profile_state.dart';
|
||||
import 'package:tmail_ui_user/features/mailbox_dashboard/domain/usecases/get_user_profile_interactor.dart';
|
||||
import 'package:tmail_ui_user/features/manage_account/presentation/model/account_property.dart';
|
||||
|
||||
class ManageAccountDashBoardController extends ReloadableController {
|
||||
|
||||
final GetUserProfileInteractor _getUserProfileInteractor;
|
||||
|
||||
final menuDrawerKey = GlobalKey<ScaffoldState>();
|
||||
|
||||
final appInformation = Rxn<PackageInfo>();
|
||||
final userProfile = Rxn<UserProfile>();
|
||||
final accountPropertySelected = AccountProperty.profiles.obs;
|
||||
|
||||
ManageAccountDashBoardController(
|
||||
this._getUserProfileInteractor,
|
||||
);
|
||||
|
||||
@override
|
||||
void onReady() {
|
||||
_getUserProfile();
|
||||
super.onReady();
|
||||
}
|
||||
|
||||
@override
|
||||
void onDone() {
|
||||
viewState.value.fold(
|
||||
(failure) {},
|
||||
(success) {
|
||||
if (success is GetUserProfileSuccess) {
|
||||
userProfile.value = success.userProfile;
|
||||
}
|
||||
}
|
||||
);
|
||||
}
|
||||
|
||||
@override
|
||||
void onError(error) {
|
||||
}
|
||||
|
||||
void _getUserProfile() async {
|
||||
consumeState(_getUserProfileInteractor.execute());
|
||||
}
|
||||
|
||||
void openMenuDrawer() {
|
||||
menuDrawerKey.currentState?.openDrawer();
|
||||
}
|
||||
|
||||
void closeMenuDrawer() {
|
||||
menuDrawerKey.currentState?.openEndDrawer();
|
||||
}
|
||||
|
||||
bool get isMenuDrawerOpen => menuDrawerKey.currentState?.isDrawerOpen == true;
|
||||
}
|
||||
+2
-2
@@ -2,9 +2,9 @@ import 'package:get/get.dart';
|
||||
import 'package:tmail_ui_user/features/base/base_bindings.dart';
|
||||
import 'package:tmail_ui_user/features/login/domain/repository/credential_repository.dart';
|
||||
import 'package:tmail_ui_user/features/mailbox_dashboard/domain/usecases/get_user_profile_interactor.dart';
|
||||
import 'package:tmail_ui_user/features/manage_account/presentation/account_properties/profiles/profiles_bindings.dart';
|
||||
import 'package:tmail_ui_user/features/manage_account/presentation/dashboard/manage_account_dashboard_controller.dart';
|
||||
import 'package:tmail_ui_user/features/manage_account/presentation/manage_account_dashboard_controller.dart';
|
||||
import 'package:tmail_ui_user/features/manage_account/presentation/menu/manage_account_menu_bindings.dart';
|
||||
import 'package:tmail_ui_user/features/manage_account/presentation/profiles/profiles_bindings.dart';
|
||||
|
||||
class ManageAccountDashBoardBindings extends BaseBindings {
|
||||
|
||||
@@ -0,0 +1,101 @@
|
||||
|
||||
import 'package:core/core.dart';
|
||||
import 'package:flutter/foundation.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:get/get.dart';
|
||||
import 'package:jmap_dart_client/jmap/account_id.dart';
|
||||
import 'package:jmap_dart_client/jmap/core/session/session.dart';
|
||||
import 'package:model/model.dart';
|
||||
import 'package:package_info_plus/package_info_plus.dart';
|
||||
import 'package:tmail_ui_user/features/base/reloadable/reloadable_controller.dart';
|
||||
import 'package:tmail_ui_user/features/mailbox_dashboard/domain/state/get_user_profile_state.dart';
|
||||
import 'package:tmail_ui_user/features/mailbox_dashboard/domain/usecases/get_user_profile_interactor.dart';
|
||||
import 'package:tmail_ui_user/features/manage_account/presentation/model/account_menu_item.dart';
|
||||
import 'package:tmail_ui_user/features/manage_account/presentation/model/manage_account_arguments.dart';
|
||||
import 'package:tmail_ui_user/main/routes/app_routes.dart';
|
||||
import 'package:tmail_ui_user/main/routes/route_navigation.dart';
|
||||
|
||||
class ManageAccountDashBoardController extends ReloadableController {
|
||||
|
||||
final _responsiveUtils = Get.find<ResponsiveUtils>();
|
||||
|
||||
final GetUserProfileInteractor _getUserProfileInteractor;
|
||||
|
||||
final menuDrawerKey = GlobalKey<ScaffoldState>();
|
||||
|
||||
final appInformation = Rxn<PackageInfo>();
|
||||
final userProfile = Rxn<UserProfile>();
|
||||
final accountId = Rxn<AccountId>();
|
||||
final accountMenuItemSelected = AccountMenuItem.profiles.obs;
|
||||
|
||||
ManageAccountDashBoardController(
|
||||
this._getUserProfileInteractor,
|
||||
);
|
||||
|
||||
@override
|
||||
void onReady() {
|
||||
_getArguments();
|
||||
super.onReady();
|
||||
}
|
||||
|
||||
@override
|
||||
void onDone() {
|
||||
viewState.value.fold(
|
||||
(failure) {},
|
||||
(success) {
|
||||
if (success is GetUserProfileSuccess) {
|
||||
userProfile.value = success.userProfile;
|
||||
}
|
||||
}
|
||||
);
|
||||
}
|
||||
|
||||
@override
|
||||
void onError(error) {
|
||||
}
|
||||
|
||||
@override
|
||||
void handleReloaded(Session session) {
|
||||
accountId.value = session.accounts.keys.first;
|
||||
_getUserProfile();
|
||||
}
|
||||
|
||||
void _getArguments() {
|
||||
final arguments = Get.arguments;
|
||||
log('ManageAccountDashBoardController::_getAccountIdAndUserProfile(): $arguments');
|
||||
if (arguments is ManageAccountArguments) {
|
||||
accountId.value = arguments.accountId;
|
||||
userProfile.value = arguments.userProfile;
|
||||
} else {
|
||||
if (kIsWeb) {
|
||||
reload();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
void _getUserProfile() async {
|
||||
consumeState(_getUserProfileInteractor.execute());
|
||||
}
|
||||
|
||||
void openMenuDrawer() {
|
||||
menuDrawerKey.currentState?.openDrawer();
|
||||
}
|
||||
|
||||
void closeMenuDrawer() {
|
||||
menuDrawerKey.currentState?.openEndDrawer();
|
||||
}
|
||||
|
||||
bool get isMenuDrawerOpen => menuDrawerKey.currentState?.isDrawerOpen == true;
|
||||
|
||||
void selectAccountMenuItem(AccountMenuItem newAccountMenuItem) {
|
||||
accountMenuItemSelected.value = newAccountMenuItem;
|
||||
if (currentContext != null && !_responsiveUtils.isDesktop(currentContext!)) {
|
||||
closeMenuDrawer();
|
||||
}
|
||||
}
|
||||
|
||||
void goToSettings() {
|
||||
pushAndPop(AppRoutes.MANAGE_ACCOUNT,
|
||||
arguments: ManageAccountArguments(accountId.value, userProfile.value));
|
||||
}
|
||||
}
|
||||
+10
-10
@@ -4,10 +4,10 @@ import 'package:flutter/material.dart';
|
||||
import 'package:flutter_svg/flutter_svg.dart';
|
||||
import 'package:get/get.dart';
|
||||
import 'package:tmail_ui_user/features/mailbox_dashboard/presentation/mixin/user_setting_popup_menu_mixin.dart';
|
||||
import 'package:tmail_ui_user/features/manage_account/presentation/account_properties/profiles/profiles_view.dart';
|
||||
import 'package:tmail_ui_user/features/manage_account/presentation/dashboard/manage_account_dashboard_controller.dart';
|
||||
import 'package:tmail_ui_user/features/manage_account/presentation/manage_account_dashboard_controller.dart';
|
||||
import 'package:tmail_ui_user/features/manage_account/presentation/menu/manage_account_menu_view.dart';
|
||||
import 'package:tmail_ui_user/features/manage_account/presentation/model/account_property.dart';
|
||||
import 'package:tmail_ui_user/features/manage_account/presentation/model/account_menu_item.dart';
|
||||
import 'package:tmail_ui_user/features/manage_account/presentation/profiles/profiles_view.dart';
|
||||
import 'package:tmail_ui_user/main/localizations/app_localizations.dart';
|
||||
import 'package:tmail_ui_user/main/routes/route_navigation.dart';
|
||||
|
||||
@@ -73,7 +73,7 @@ class ManageAccountDashBoardView extends GetWidget<ManageAccountDashBoardControl
|
||||
crossAxisAlignment: CrossAxisAlignment.start,
|
||||
children: [
|
||||
SizedBox(child: ManageAccountMenuView(), width: _responsiveUtils.defaultSizeMenuWidthWeb),
|
||||
Expanded(child: _manageAccountContentView())
|
||||
Expanded(child: _viewDisplayedOfAccountMenuItem())
|
||||
],
|
||||
))
|
||||
]),
|
||||
@@ -88,7 +88,7 @@ class ManageAccountDashBoardView extends GetWidget<ManageAccountDashBoardControl
|
||||
.build(),
|
||||
Expanded(child: Padding(
|
||||
padding: const EdgeInsets.only(left: 24, right: 24, bottom: 16),
|
||||
child: _manageAccountContentView()))
|
||||
child: _viewDisplayedOfAccountMenuItem()))
|
||||
])
|
||||
),
|
||||
]),
|
||||
@@ -104,7 +104,7 @@ class ManageAccountDashBoardView extends GetWidget<ManageAccountDashBoardControl
|
||||
..addOnOpenSearchViewAction(() => {}))
|
||||
.build(),
|
||||
const SizedBox(width: 16),
|
||||
(AvatarBuilder()
|
||||
Obx(() => (AvatarBuilder()
|
||||
..text(controller.userProfile.value?.getAvatarText() ?? '')
|
||||
..backgroundColor(Colors.white)
|
||||
..textColor(Colors.black)
|
||||
@@ -121,7 +121,7 @@ class ManageAccountDashBoardView extends GetWidget<ManageAccountDashBoardControl
|
||||
color: AppColor.colorShadowBgContentEmail,
|
||||
spreadRadius: 1, blurRadius: 1, offset: Offset(0, 0.5))])
|
||||
..size(48))
|
||||
.build(),
|
||||
.build()),
|
||||
const SizedBox(width: 16)
|
||||
]);
|
||||
}
|
||||
@@ -140,9 +140,9 @@ class ManageAccountDashBoardView extends GetWidget<ManageAccountDashBoardControl
|
||||
]);
|
||||
}
|
||||
|
||||
Widget _manageAccountContentView() {
|
||||
switch(controller.accountPropertySelected.value) {
|
||||
case AccountProperty.profiles:
|
||||
Widget _viewDisplayedOfAccountMenuItem() {
|
||||
switch(controller.accountMenuItemSelected.value) {
|
||||
case AccountMenuItem.profiles:
|
||||
return ProfilesView();
|
||||
default:
|
||||
return const SizedBox.shrink();
|
||||
@@ -1,15 +1,15 @@
|
||||
|
||||
import 'package:get/get.dart';
|
||||
import 'package:tmail_ui_user/features/base/base_controller.dart';
|
||||
import 'package:tmail_ui_user/features/manage_account/presentation/dashboard/manage_account_dashboard_controller.dart';
|
||||
import 'package:tmail_ui_user/features/manage_account/presentation/model/account_property.dart';
|
||||
import 'package:tmail_ui_user/features/manage_account/presentation/manage_account_dashboard_controller.dart';
|
||||
import 'package:tmail_ui_user/features/manage_account/presentation/model/account_menu_item.dart';
|
||||
|
||||
class ManageAccountMenuController extends BaseController {
|
||||
|
||||
final dashBoardController = Get.find<ManageAccountDashBoardController>();
|
||||
|
||||
final listAccountProperties = <AccountProperty>[
|
||||
AccountProperty.profiles
|
||||
final listAccountMenuItem = <AccountMenuItem>[
|
||||
AccountMenuItem.profiles
|
||||
];
|
||||
|
||||
@override
|
||||
@@ -19,4 +19,8 @@ class ManageAccountMenuController extends BaseController {
|
||||
@override
|
||||
void onError(error) {
|
||||
}
|
||||
|
||||
void selectAccountMenuItem(AccountMenuItem newAccountMenuItem) {
|
||||
dashBoardController.selectAccountMenuItem(newAccountMenuItem);
|
||||
}
|
||||
}
|
||||
@@ -65,23 +65,29 @@ class ManageAccountMenuView extends GetWidget<ManageAccountMenuController> {
|
||||
padding: const EdgeInsets.only(left: 16, right: 8),
|
||||
key: const Key('list_manage_account_property'),
|
||||
shrinkWrap: true,
|
||||
itemCount: controller.listAccountProperties.length,
|
||||
itemBuilder: (context, index) => Obx(() => AccountPropertyTileBuilder(
|
||||
itemCount: controller.listAccountMenuItem.length,
|
||||
itemBuilder: (context, index) => Obx(() => AccountMenuItemTileBuilder(
|
||||
context,
|
||||
_imagePaths,
|
||||
_responsiveUtils,
|
||||
controller.listAccountProperties[index],
|
||||
controller.dashBoardController.accountPropertySelected.value))),
|
||||
controller.listAccountMenuItem[index],
|
||||
controller.dashBoardController.accountMenuItemSelected.value,
|
||||
onSelectAccountMenuItemAction: (newAccountMenuItem) =>
|
||||
controller.selectAccountMenuItem(newAccountMenuItem)))),
|
||||
const Padding(
|
||||
padding: EdgeInsets.symmetric(vertical: 16),
|
||||
child: Divider(color: AppColor.lineItemListColor, height: 0.5, thickness: 0.2)),
|
||||
Padding(padding: const EdgeInsets.only(left: 32),
|
||||
child: InkWell(child: Row(children: [
|
||||
SvgPicture.asset(_imagePaths.icLogout, fit: BoxFit.fill),
|
||||
const SizedBox(width: 12),
|
||||
Expanded(child: Text(AppLocalizations.of(context).sign_out,
|
||||
style: const TextStyle(fontWeight: FontWeight.normal, fontSize: 15, color: Colors.black)))
|
||||
]))),
|
||||
child: InkWell(
|
||||
onTap: () => controller.dashBoardController.logoutAction(),
|
||||
child: Row(children: [
|
||||
SvgPicture.asset(_imagePaths.icLogout, fit: BoxFit.fill),
|
||||
const SizedBox(width: 12),
|
||||
Expanded(child: Text(AppLocalizations.of(context).sign_out,
|
||||
style: const TextStyle(fontWeight: FontWeight.normal, fontSize: 15, color: Colors.black)))
|
||||
])
|
||||
)
|
||||
),
|
||||
]),
|
||||
)),
|
||||
]
|
||||
|
||||
+21
-16
@@ -1,54 +1,59 @@
|
||||
import 'package:core/core.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:flutter_svg/flutter_svg.dart';
|
||||
import 'package:tmail_ui_user/features/manage_account/presentation/model/account_property.dart';
|
||||
import 'package:tmail_ui_user/features/manage_account/presentation/model/account_menu_item.dart';
|
||||
|
||||
class AccountPropertyTileBuilder extends StatelessWidget {
|
||||
typedef OnSelectAccountMenuItemAction = void Function(AccountMenuItem);
|
||||
|
||||
class AccountMenuItemTileBuilder extends StatelessWidget {
|
||||
|
||||
final BuildContext _context;
|
||||
final ImagePaths _imagePaths;
|
||||
final ResponsiveUtils _responsiveUtils;
|
||||
final AccountProperty _accountProperty;
|
||||
final AccountProperty _accountPropertySelected;
|
||||
final AccountMenuItem _menuItem;
|
||||
final AccountMenuItem _menuItemSelected;
|
||||
final OnSelectAccountMenuItemAction? onSelectAccountMenuItemAction;
|
||||
|
||||
const AccountPropertyTileBuilder(
|
||||
const AccountMenuItemTileBuilder(
|
||||
this._context,
|
||||
this._imagePaths,
|
||||
this._responsiveUtils,
|
||||
this._accountProperty,
|
||||
this._accountPropertySelected, {Key? key}
|
||||
this._menuItem,
|
||||
this._menuItemSelected,
|
||||
{Key? key, this.onSelectAccountMenuItemAction}
|
||||
) : super(key: key);
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
return Theme(
|
||||
return InkWell(
|
||||
onTap: () => onSelectAccountMenuItemAction?.call(_menuItem),
|
||||
child: Theme(
|
||||
data: ThemeData(
|
||||
splashColor: Colors.transparent,
|
||||
highlightColor: Colors.transparent),
|
||||
child: Container(
|
||||
key: const Key('account_property_tile'),
|
||||
key: const Key('account_menu_item_tile'),
|
||||
decoration: BoxDecoration(
|
||||
borderRadius: BorderRadius.circular(10),
|
||||
color: backgroundColorItem
|
||||
),
|
||||
color: backgroundColorItem),
|
||||
padding: const EdgeInsets.symmetric(horizontal: 12, vertical: 6),
|
||||
child: MediaQuery(
|
||||
data: const MediaQueryData(padding: EdgeInsets.zero),
|
||||
child: Column(children: [
|
||||
Row(children: [
|
||||
SvgPicture.asset(_accountProperty.getIcon(_imagePaths), width: 28, height: 28, fit: BoxFit.fill),
|
||||
SvgPicture.asset(_menuItem.getIcon(_imagePaths), width: 28, height: 28, fit: BoxFit.fill),
|
||||
const SizedBox(width: 12),
|
||||
Expanded(child: Text(_accountProperty.getName(context),
|
||||
style: const TextStyle(fontWeight: FontWeight.normal, fontSize: 15, color: Colors.black)))
|
||||
Expanded(child: Text(_menuItem.getName(context),
|
||||
style: const TextStyle(fontWeight: FontWeight.normal, fontSize: 15, color: Colors.black)))
|
||||
]),
|
||||
])
|
||||
)
|
||||
)
|
||||
);
|
||||
));
|
||||
}
|
||||
|
||||
Color get backgroundColorItem {
|
||||
if (_accountPropertySelected == _accountProperty) {
|
||||
if (_menuItemSelected == _menuItem) {
|
||||
return AppColor.colorBgMailboxSelected;
|
||||
}
|
||||
return _responsiveUtils.isDesktop(_context) ? AppColor.colorBgDesktop : Colors.white;
|
||||
|
||||
+4
-4
@@ -3,22 +3,22 @@ import 'package:core/core.dart';
|
||||
import 'package:flutter/cupertino.dart';
|
||||
import 'package:tmail_ui_user/main/localizations/app_localizations.dart';
|
||||
|
||||
enum AccountProperty {
|
||||
enum AccountMenuItem {
|
||||
profiles
|
||||
}
|
||||
|
||||
extension AccountPropertyExtension on AccountProperty {
|
||||
extension AccountMenuItemExtension on AccountMenuItem {
|
||||
|
||||
String getIcon(ImagePaths imagePaths) {
|
||||
switch(this) {
|
||||
case AccountProperty.profiles:
|
||||
case AccountMenuItem.profiles:
|
||||
return imagePaths.icProfiles;
|
||||
}
|
||||
}
|
||||
|
||||
String getName(BuildContext context) {
|
||||
switch(this) {
|
||||
case AccountProperty.profiles:
|
||||
case AccountMenuItem.profiles:
|
||||
return AppLocalizations.of(context).profiles;
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,15 @@
|
||||
|
||||
import 'package:equatable/equatable.dart';
|
||||
import 'package:jmap_dart_client/jmap/account_id.dart';
|
||||
import 'package:model/model.dart';
|
||||
|
||||
class ManageAccountArguments with EquatableMixin {
|
||||
|
||||
final AccountId? accountId;
|
||||
final UserProfile? userProfile;
|
||||
|
||||
ManageAccountArguments(this.accountId, this.userProfile);
|
||||
|
||||
@override
|
||||
List<Object?> get props => [accountId, userProfile];
|
||||
}
|
||||
@@ -4,21 +4,15 @@ import 'package:flutter/material.dart';
|
||||
import 'package:tmail_ui_user/main/localizations/app_localizations.dart';
|
||||
|
||||
enum ProfilesTabType {
|
||||
personalInfo,
|
||||
identities,
|
||||
follower,
|
||||
}
|
||||
|
||||
extension ProfilesTabTypeExtension on ProfilesTabType {
|
||||
|
||||
String getName(BuildContext context) {
|
||||
switch(this) {
|
||||
case ProfilesTabType.personalInfo:
|
||||
return AppLocalizations.of(context).identities;
|
||||
case ProfilesTabType.identities:
|
||||
return AppLocalizations.of(context).identities;
|
||||
case ProfilesTabType.follower:
|
||||
return AppLocalizations.of(context).identities;
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,49 @@
|
||||
import 'package:get/get.dart';
|
||||
import 'package:jmap_dart_client/http/http_client.dart' as jmap_http_client;
|
||||
import 'package:tmail_ui_user/features/base/base_bindings.dart';
|
||||
import 'package:tmail_ui_user/features/manage_account/data/datasource/manage_account_datasource.dart';
|
||||
import 'package:tmail_ui_user/features/manage_account/data/datasource_impl/manage_account_datasource_impl.dart';
|
||||
import 'package:tmail_ui_user/features/manage_account/data/network/manage_account_api.dart';
|
||||
import 'package:tmail_ui_user/features/manage_account/data/repository/manage_account_repository_impl.dart';
|
||||
import 'package:tmail_ui_user/features/manage_account/domain/repository/manage_account_repository.dart';
|
||||
import 'package:tmail_ui_user/features/manage_account/domain/usecases/get_all_identities_interactor.dart';
|
||||
import 'package:tmail_ui_user/features/manage_account/presentation/profiles/identities/identities_controller.dart';
|
||||
|
||||
class IdentitiesBindings extends BaseBindings {
|
||||
|
||||
@override
|
||||
void dependencies() {
|
||||
Get.lazyPut(() => ManageAccountAPI(Get.find<jmap_http_client.HttpClient>()));
|
||||
super.dependencies();
|
||||
}
|
||||
|
||||
@override
|
||||
void bindingsController() {
|
||||
Get.lazyPut(() => IdentitiesController(Get.find<GetAllIdentitiesInteractor>()));
|
||||
}
|
||||
|
||||
@override
|
||||
void bindingsDataSource() {
|
||||
Get.lazyPut<ManageAccountDataSource>(() => Get.find<ManageAccountDataSourceImpl>());
|
||||
}
|
||||
|
||||
@override
|
||||
void bindingsDataSourceImpl() {
|
||||
Get.lazyPut(() => ManageAccountDataSourceImpl(Get.find<ManageAccountAPI>()));
|
||||
}
|
||||
|
||||
@override
|
||||
void bindingsInteractor() {
|
||||
Get.lazyPut(() => GetAllIdentitiesInteractor(Get.find<ManageAccountRepository>()));
|
||||
}
|
||||
|
||||
@override
|
||||
void bindingsRepository() {
|
||||
Get.lazyPut<ManageAccountRepository>(() => Get.find<ManageAccountRepositoryImpl>());
|
||||
}
|
||||
|
||||
@override
|
||||
void bindingsRepositoryImpl() {
|
||||
Get.lazyPut(() => ManageAccountRepositoryImpl(Get.find<ManageAccountDataSource>()));
|
||||
}
|
||||
}
|
||||
+63
@@ -0,0 +1,63 @@
|
||||
|
||||
import 'package:core/core.dart';
|
||||
import 'package:get/get.dart';
|
||||
import 'package:jmap_dart_client/jmap/account_id.dart';
|
||||
import 'package:jmap_dart_client/jmap/identities/identity.dart';
|
||||
import 'package:tmail_ui_user/features/base/base_controller.dart';
|
||||
import 'package:tmail_ui_user/features/manage_account/domain/state/get_all_identities_state.dart';
|
||||
import 'package:tmail_ui_user/features/manage_account/domain/usecases/get_all_identities_interactor.dart';
|
||||
import 'package:tmail_ui_user/features/manage_account/presentation/manage_account_dashboard_controller.dart';
|
||||
|
||||
class IdentitiesController extends BaseController {
|
||||
|
||||
final _accountDashBoardController = Get.find<ManageAccountDashBoardController>();
|
||||
|
||||
final GetAllIdentitiesInteractor _getAllIdentitiesInteractor;
|
||||
|
||||
final identitySelected = Rxn<Identity>();
|
||||
final listIdentities = <Identity>[].obs;
|
||||
|
||||
IdentitiesController(this._getAllIdentitiesInteractor);
|
||||
|
||||
@override
|
||||
void onInit() {
|
||||
_onAccountDashBoardListener();
|
||||
super.onInit();
|
||||
}
|
||||
|
||||
@override
|
||||
void onDone() {
|
||||
viewState.value.fold(
|
||||
(failure) {},
|
||||
(success) {
|
||||
if (success is GetAllIdentitiesSuccess) {
|
||||
if (success.identities?.isNotEmpty == true) {
|
||||
listIdentities.value = success.identities ?? [];
|
||||
selectIdentity(listIdentities.first);
|
||||
}
|
||||
}
|
||||
}
|
||||
);
|
||||
}
|
||||
|
||||
@override
|
||||
void onError(error) {
|
||||
}
|
||||
|
||||
void _onAccountDashBoardListener() {
|
||||
_accountDashBoardController.accountId.listen((accountId) {
|
||||
log('IdentitiesController::_onAccountDashBoardListener(): accountId: $accountId');
|
||||
if (accountId != null) {
|
||||
_getAllIdentities(accountId);
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
void _getAllIdentities(AccountId accountId) {
|
||||
consumeState(_getAllIdentitiesInteractor.execute(accountId));
|
||||
}
|
||||
|
||||
void selectIdentity(Identity? newIdentity) {
|
||||
identitySelected.value = newIdentity;
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,119 @@
|
||||
|
||||
import 'package:core/core.dart';
|
||||
import 'package:dropdown_button2/dropdown_button2.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:flutter_svg/flutter_svg.dart';
|
||||
import 'package:get/get.dart';
|
||||
import 'package:jmap_dart_client/jmap/identities/identity.dart';
|
||||
import 'package:tmail_ui_user/features/manage_account/presentation/profiles/identities/identities_controller.dart';
|
||||
import 'package:tmail_ui_user/features/manage_account/presentation/profiles/identities/widgets/identity_info_tile_builder.dart';
|
||||
import 'package:tmail_ui_user/main/localizations/app_localizations.dart';
|
||||
|
||||
class IdentitiesView extends GetWidget<IdentitiesController> {
|
||||
|
||||
final _responsiveUtils = Get.find<ResponsiveUtils>();
|
||||
final _imagePaths = Get.find<ImagePaths>();
|
||||
|
||||
IdentitiesView({Key? key}) : super(key: key);
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
final buttonSelectIdentity = Row(children: [
|
||||
Expanded(child: Obx(() => DropdownButtonHideUnderline(
|
||||
child: DropdownButton2<Identity>(
|
||||
isExpanded: true,
|
||||
hint: Row(
|
||||
children: [
|
||||
Expanded(child: Text(
|
||||
controller.identitySelected.value?.name ?? '',
|
||||
style: const TextStyle(fontSize: 16, fontWeight: FontWeight.normal, color: Colors.black),
|
||||
maxLines: 1,
|
||||
overflow: TextOverflow.ellipsis,
|
||||
)),
|
||||
],
|
||||
),
|
||||
items: controller.listIdentities.map((item) => DropdownMenuItem<Identity>(
|
||||
value: item,
|
||||
child: Text(
|
||||
item.name ?? '',
|
||||
style: const TextStyle(fontSize: 16, fontWeight: FontWeight.normal, color: Colors.black),
|
||||
maxLines: 1,
|
||||
overflow: TextOverflow.ellipsis,
|
||||
),
|
||||
)).toList(),
|
||||
value: controller.identitySelected.value,
|
||||
onChanged: (newIdentity) => controller.selectIdentity(newIdentity),
|
||||
icon: SvgPicture.asset(_imagePaths.icDropDown),
|
||||
buttonPadding: const EdgeInsets.symmetric(horizontal: 12),
|
||||
buttonDecoration: BoxDecoration(
|
||||
borderRadius: BorderRadius.circular(10),
|
||||
border: Border.all(color: AppColor.colorInputBorderCreateMailbox, width: 0.5),
|
||||
color: AppColor.colorInputBackgroundCreateMailbox),
|
||||
itemHeight: 44,
|
||||
buttonHeight: 44,
|
||||
itemPadding: const EdgeInsets.symmetric(horizontal: 12),
|
||||
dropdownMaxHeight: 200,
|
||||
dropdownDecoration: BoxDecoration(
|
||||
borderRadius: BorderRadius.circular(10),
|
||||
color: Colors.white),
|
||||
dropdownElevation: 4,
|
||||
scrollbarRadius: const Radius.circular(40),
|
||||
scrollbarThickness: 6,
|
||||
),
|
||||
))),
|
||||
if (!_responsiveUtils.isMobile(context)) const SizedBox(width: 12),
|
||||
if (!_responsiveUtils.isMobile(context))
|
||||
(ButtonBuilder(_imagePaths.icAddIdentity)
|
||||
..key(const Key('button_new_identity'))
|
||||
..decoration(BoxDecoration(borderRadius: BorderRadius.circular(10), color: AppColor.colorTextButton))
|
||||
..paddingIcon(const EdgeInsets.only(right: 8))
|
||||
..iconColor(Colors.white)
|
||||
..maxWidth(170)
|
||||
..size(20)
|
||||
..radiusSplash(10)
|
||||
..padding(const EdgeInsets.symmetric(vertical: 12))
|
||||
..textStyle(const TextStyle(fontSize: 17, color: Colors.white, fontWeight: FontWeight.w500))
|
||||
..onPressActionClick(() => {})
|
||||
..text(AppLocalizations.of(context).new_identity, isVertical: false))
|
||||
.build()
|
||||
]);
|
||||
|
||||
return LayoutBuilder(builder: (context, constraints) => ResponsiveWidget(
|
||||
responsiveUtils: _responsiveUtils,
|
||||
mobile: Scaffold(
|
||||
body: Container(
|
||||
margin: const EdgeInsets.symmetric(vertical: 16),
|
||||
child: Column(
|
||||
crossAxisAlignment: CrossAxisAlignment.start,
|
||||
children: [
|
||||
buttonSelectIdentity,
|
||||
Obx(() => IdentityInfoTileBuilder(context,
|
||||
_imagePaths,
|
||||
controller.identitySelected.value)),
|
||||
]
|
||||
)),
|
||||
floatingActionButton: _responsiveUtils.isMobile(context)
|
||||
? FloatingActionButton(
|
||||
key: const Key('add_new_identity'),
|
||||
onPressed: () => {},
|
||||
backgroundColor: AppColor.primaryColor,
|
||||
child: SvgPicture.asset(_imagePaths.icAddIdentity, width: 24, height: 24))
|
||||
: null),
|
||||
desktop: Container(
|
||||
margin: const EdgeInsets.symmetric(vertical: 24, horizontal: 16),
|
||||
child: Column(
|
||||
crossAxisAlignment: CrossAxisAlignment.start,
|
||||
children: [
|
||||
SizedBox(
|
||||
width: constraints.maxWidth / 2,
|
||||
child: buttonSelectIdentity),
|
||||
Obx(() => IdentityInfoTileBuilder(context,
|
||||
_imagePaths,
|
||||
controller.identitySelected.value,
|
||||
maxWidth: constraints.maxWidth / 2)),
|
||||
]
|
||||
)
|
||||
)
|
||||
));
|
||||
}
|
||||
}
|
||||
+117
@@ -0,0 +1,117 @@
|
||||
import 'package:core/core.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:flutter_svg/flutter_svg.dart';
|
||||
import 'package:jmap_dart_client/jmap/identities/identity.dart';
|
||||
import 'package:model/model.dart';
|
||||
import 'package:tmail_ui_user/main/localizations/app_localizations.dart';
|
||||
|
||||
class IdentityInfoTileBuilder extends StatelessWidget {
|
||||
|
||||
final BuildContext _context;
|
||||
final ImagePaths _imagePaths;
|
||||
final Identity? _identity;
|
||||
final double? maxWidth;
|
||||
|
||||
const IdentityInfoTileBuilder(
|
||||
this._context,
|
||||
this._imagePaths,
|
||||
this._identity,
|
||||
{Key? key, this.maxWidth}
|
||||
) : super(key: key);
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
if (_identity == null) {
|
||||
return const SizedBox.shrink();
|
||||
}
|
||||
|
||||
return Container(
|
||||
key: const Key('identity_info_tile'),
|
||||
decoration: BoxDecoration(
|
||||
borderRadius: BorderRadius.circular(16),
|
||||
border: Border.all(color: AppColor.colorBorderIdentityInfo, width: 1),
|
||||
color: Colors.white),
|
||||
padding: const EdgeInsets.only(top: 12, bottom: 12),
|
||||
margin: const EdgeInsets.only(top: 12),
|
||||
width: maxWidth,
|
||||
child: Column(crossAxisAlignment: CrossAxisAlignment.start, children: [
|
||||
Padding(
|
||||
padding: const EdgeInsets.symmetric(horizontal: 12),
|
||||
child: Row(children: [
|
||||
Expanded(child: Text(_identity?.name ?? '',
|
||||
style: const TextStyle(fontWeight: FontWeight.w500, fontSize: 17, color: Colors.black))),
|
||||
buildIconWeb(
|
||||
icon: SvgPicture.asset(_imagePaths.icMoreVertical, fit: BoxFit.fill),
|
||||
onTap: () => {})
|
||||
])),
|
||||
const SizedBox(height: 10),
|
||||
const Divider(color: AppColor.colorDividerMailbox, height: 0.5, thickness: 0.2),
|
||||
const SizedBox(height: 12),
|
||||
Padding(
|
||||
padding: const EdgeInsets.symmetric(horizontal: 12),
|
||||
child: Text(_identity?.name ?? '',
|
||||
style: const TextStyle(fontWeight: FontWeight.normal, fontSize: 17, color: Colors.black))),
|
||||
if (_identity?.email != null) const SizedBox(height: 10),
|
||||
if (_identity?.email != null)
|
||||
Padding(
|
||||
padding: const EdgeInsets.symmetric(horizontal: 12),
|
||||
child: Row(children: [
|
||||
SizedBox(
|
||||
width: 40,
|
||||
child: SvgPicture.asset(_imagePaths.icEmail, width: 15, height: 15)),
|
||||
const SizedBox(width: 4),
|
||||
Expanded(child: Text(_identity?.email ?? '',
|
||||
style: const TextStyle(fontWeight: FontWeight.normal, fontSize: 15, color: AppColor.colorHintSearchBar)))
|
||||
])),
|
||||
if (_identity?.replyTo != null) const SizedBox(height: 10),
|
||||
if (_identity?.replyTo != null)
|
||||
Padding(
|
||||
padding: const EdgeInsets.symmetric(horizontal: 12),
|
||||
child: Row(children: [
|
||||
SizedBox(
|
||||
width: 40,
|
||||
child: SvgPicture.asset(_imagePaths.icReplyTo, width: 15, height: 15)),
|
||||
const SizedBox(width: 4),
|
||||
Expanded(child: Text(_identity?.replyTo?.listEmailAddressToString(isFullEmailAddress: true) ?? '',
|
||||
style: const TextStyle(fontWeight: FontWeight.normal, fontSize: 15, color: AppColor.colorHintSearchBar)))
|
||||
])),
|
||||
if (_identity?.cc != null) const SizedBox(height: 6),
|
||||
if (_identity?.cc != null)
|
||||
Padding(
|
||||
padding: const EdgeInsets.symmetric(horizontal: 12),
|
||||
child: Row(children: [
|
||||
Container(
|
||||
width: 40,
|
||||
padding: const EdgeInsets.only(left: 10),
|
||||
child: Text(AppLocalizations.of(_context).cc_email_address_prefix,
|
||||
style: const TextStyle(
|
||||
fontSize: 15,
|
||||
fontWeight: FontWeight.normal,
|
||||
decoration: TextDecoration.underline,
|
||||
color: AppColor.colorTextButton))),
|
||||
const SizedBox(width: 4),
|
||||
Expanded(child: Text(_identity?.cc?.listEmailAddressToString(isFullEmailAddress: true) ?? '',
|
||||
style: const TextStyle(fontWeight: FontWeight.normal, fontSize: 15, color: AppColor.colorHintSearchBar)))
|
||||
])),
|
||||
if (_identity?.bcc != null) const SizedBox(height: 6),
|
||||
if (_identity?.bcc != null)
|
||||
Padding(
|
||||
padding: const EdgeInsets.symmetric(horizontal: 12),
|
||||
child: Row(children: [
|
||||
Container(
|
||||
padding: const EdgeInsets.only(left: 6),
|
||||
width: 40,
|
||||
child: Text(AppLocalizations.of(_context).bcc_email_address_prefix,
|
||||
style: const TextStyle(
|
||||
fontSize: 15,
|
||||
fontWeight: FontWeight.normal,
|
||||
decoration: TextDecoration.underline,
|
||||
color: AppColor.colorTextButton))),
|
||||
const SizedBox(width: 4),
|
||||
Expanded(child: Text(_identity?.bcc?.listEmailAddressToString(isFullEmailAddress: true) ?? '',
|
||||
style: const TextStyle(fontWeight: FontWeight.normal, fontSize: 15, color: AppColor.colorHintSearchBar)))
|
||||
])),
|
||||
])
|
||||
);
|
||||
}
|
||||
}
|
||||
+3
-3
@@ -1,14 +1,14 @@
|
||||
import 'package:get/get.dart';
|
||||
import 'package:tmail_ui_user/features/base/base_bindings.dart';
|
||||
import 'package:tmail_ui_user/features/manage_account/presentation/account_properties/profiles/identities/identities_bindings.dart';
|
||||
import 'package:tmail_ui_user/features/manage_account/presentation/account_properties/profiles/profiles_controller.dart';
|
||||
import 'package:tmail_ui_user/features/manage_account/presentation/profiles/identities/identities_bindings.dart';
|
||||
import 'package:tmail_ui_user/features/manage_account/presentation/profiles/profiles_controller.dart';
|
||||
|
||||
class ProfileBindings extends BaseBindings {
|
||||
|
||||
@override
|
||||
void dependencies() {
|
||||
super.dependencies();
|
||||
IdentitiesBindings();
|
||||
IdentitiesBindings().dependencies();
|
||||
}
|
||||
|
||||
@override
|
||||
+1
-1
@@ -1,7 +1,7 @@
|
||||
|
||||
import 'package:tmail_ui_user/features/base/base_controller.dart';
|
||||
|
||||
class IdentitiesController extends BaseController {
|
||||
class ProfilesController extends BaseController {
|
||||
|
||||
@override
|
||||
void onDone() {
|
||||
+13
-10
@@ -2,9 +2,9 @@
|
||||
import 'package:core/core.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:get/get.dart';
|
||||
import 'package:tmail_ui_user/features/manage_account/presentation/account_properties/profiles/identities/identities_view.dart';
|
||||
import 'package:tmail_ui_user/features/manage_account/presentation/account_properties/profiles/profiles_controller.dart';
|
||||
import 'package:tmail_ui_user/main/localizations/app_localizations.dart';
|
||||
import 'package:tmail_ui_user/features/manage_account/presentation/model/profiles_tab_type.dart';
|
||||
import 'package:tmail_ui_user/features/manage_account/presentation/profiles/identities/identities_view.dart';
|
||||
import 'package:tmail_ui_user/features/manage_account/presentation/profiles/profiles_controller.dart';
|
||||
|
||||
class ProfilesView extends GetWidget<ProfilesController> {
|
||||
|
||||
@@ -37,7 +37,7 @@ class ProfilesView extends GetWidget<ProfilesController> {
|
||||
color: AppColor.colorTextButtonHeaderThread),
|
||||
labelStyle: const TextStyle(
|
||||
fontSize: 15,
|
||||
fontWeight: FontWeight.normal,
|
||||
fontWeight: FontWeight.w500,
|
||||
color: AppColor.primaryColor),
|
||||
labelColor: AppColor.primaryColor,
|
||||
indicatorSize: TabBarIndicatorSize.label,
|
||||
@@ -48,13 +48,16 @@ class ProfilesView extends GetWidget<ProfilesController> {
|
||||
indicatorSize: CustomIndicatorSize.full),
|
||||
onTap: (index) {},
|
||||
tabs: [
|
||||
Tab(text: AppLocalizations.of(context).identities),
|
||||
Tab(text: ProfilesTabType.identities.getName(context)),
|
||||
]),
|
||||
body: TabBarView(
|
||||
children: [
|
||||
IdentitiesView(),
|
||||
],
|
||||
),
|
||||
body: Column(children: [
|
||||
const Divider(color: AppColor.colorDividerMailbox, height: 0.5, thickness: 0.2),
|
||||
Expanded(child: TabBarView(
|
||||
children: [
|
||||
IdentitiesView(),
|
||||
],
|
||||
))
|
||||
]),
|
||||
)
|
||||
),
|
||||
),
|
||||
@@ -1,5 +1,5 @@
|
||||
{
|
||||
"@@last_modified": "2022-04-25T19:06:15.088714",
|
||||
"@@last_modified": "2022-04-26T09:31:06.288489",
|
||||
"initializing_data": "Initializing data...",
|
||||
"@initializing_data": {
|
||||
"type": "text",
|
||||
@@ -1119,5 +1119,11 @@
|
||||
"type": "text",
|
||||
"placeholders_order": [],
|
||||
"placeholders": {}
|
||||
},
|
||||
"new_identity": "New Identity",
|
||||
"@new_identity": {
|
||||
"type": "text",
|
||||
"placeholders_order": [],
|
||||
"placeholders": {}
|
||||
}
|
||||
}
|
||||
@@ -1173,4 +1173,9 @@ class AppLocalizations {
|
||||
return Intl.message('Identities',
|
||||
name: 'identities');
|
||||
}
|
||||
|
||||
String get new_identity {
|
||||
return Intl.message('New Identity',
|
||||
name: 'new_identity');
|
||||
}
|
||||
}
|
||||
@@ -14,10 +14,10 @@ import 'package:tmail_ui_user/features/mailbox_creator/presentation/mailbox_crea
|
||||
import 'package:tmail_ui_user/features/mailbox_dashboard/presentation/mailbox_dashboard_bindings.dart';
|
||||
import 'package:tmail_ui_user/features/mailbox_dashboard/presentation/mailbox_dashboard_view.dart'
|
||||
if (dart.library.html) 'package:tmail_ui_user/features/mailbox_dashboard/presentation/mailbox_dashboard_view_web.dart' deferred as mailbox_dashboard;
|
||||
import 'package:tmail_ui_user/features/manage_account/presentation/dashboard/manage_account_dashboard_bindings.dart';
|
||||
import 'package:tmail_ui_user/features/manage_account/presentation/manage_account_dashboard_bindings.dart';
|
||||
import 'package:tmail_ui_user/features/session/presentation/session_page_bindings.dart';
|
||||
import 'package:tmail_ui_user/features/session/presentation/session_view.dart' deferred as session;
|
||||
import 'package:tmail_ui_user/features/manage_account/presentation/dashboard/manage_account_dashboard_view.dart' deferred as manage_account_dashboard;
|
||||
import 'package:tmail_ui_user/features/manage_account/presentation/manage_account_dashboard_view.dart' deferred as manage_account_dashboard;
|
||||
import 'package:tmail_ui_user/main/pages/deferred_widget.dart';
|
||||
import 'package:tmail_ui_user/main/routes/app_routes.dart';
|
||||
|
||||
|
||||
@@ -9,5 +9,5 @@ abstract class AppRoutes {
|
||||
static const COMPOSER = '/composer';
|
||||
static const DESTINATION_PICKER = '/destinationPicker';
|
||||
static const MAILBOX_CREATOR = '/mailboxCreator';
|
||||
static const MANAGE_ACCOUNT = '/manage_account';
|
||||
static const MANAGE_ACCOUNT = '$MAILBOX_DASHBOARD/manage_account';
|
||||
}
|
||||
Reference in New Issue
Block a user