@@ -4,27 +4,17 @@ import {
4
4
BrandDerivLogoCoralIcon ,
5
5
IconTypes ,
6
6
LegacyAccountLimitsIcon ,
7
- // LegacyAssessmentIcon,
8
7
LegacyCashierIcon ,
9
8
LegacyChartsIcon ,
10
- // LegacyChevronRight1pxIcon,
11
- // LegacyDepositIcon,
12
9
LegacyHelpCentreIcon ,
13
10
LegacyHomeOldIcon ,
14
- // LegacyLiveChatOutlineIcon,
15
11
LegacyLogout1pxIcon ,
16
12
LegacyProfileSmIcon ,
17
13
LegacyResponsibleTradingIcon ,
18
- // LegacySecurityIcon,
19
- // LegacyTheme1pxIcon,
20
- // LegacyTransferIcon,
21
- // LegacyVerificationIcon,
22
14
LegacyWhatsappIcon ,
23
- // LegacyWithdrawalIcon,
24
15
} from '@deriv/quill-icons' ;
25
16
import { useAuthData } from '@deriv-com/api-hooks' ;
26
17
import { useTranslations } from '@deriv-com/translations' ;
27
- // import { ToggleSwitch } from '@deriv-com/ui';
28
18
import { URLConstants } from '@deriv-com/utils' ;
29
19
30
20
export type TSubmenuSection = 'accountSettings' | 'cashier' ;
@@ -41,26 +31,6 @@ type TMenuConfig = {
41
31
target ?: ComponentProps < 'a' > [ 'target' ] ;
42
32
} [ ] ;
43
33
44
- // type TSubmenu = {
45
- // items: {
46
- // Icon: IconTypes;
47
- // href?: string;
48
- // label: string;
49
- // subItems?: {
50
- // href?: string;
51
- // onClick?: ComponentProps<'button'>['onClick'];
52
- // text: string;
53
- // }[];
54
- // }[];
55
- // section: string;
56
- // title: string;
57
- // };
58
-
59
- // type TSubmenuConfig = {
60
- // accountSettings: TSubmenu;
61
- // cashier: TSubmenu;
62
- // };
63
-
64
34
export const MobileMenuConfig = ( ) => {
65
35
const { localize } = useTranslations ( ) ;
66
36
const { logout } = useAuthData ( ) ;
@@ -86,22 +56,16 @@ export const MobileMenuConfig = () => {
86
56
LeftComponent : LegacyChartsIcon ,
87
57
} ,
88
58
{
89
- // as: 'button',
90
59
as : 'a' ,
91
60
href : `${ URLConstants . derivAppProduction } /account/personal-details` ,
92
61
label : localize ( 'Account Settings' ) ,
93
62
LeftComponent : LegacyProfileSmIcon ,
94
- // RightComponent: <LegacyChevronRight1pxIcon iconSize='xs' />,
95
- // submenu: 'accountSettings',
96
63
} ,
97
64
{
98
- // as: 'button',
99
65
as : 'a' ,
100
66
href : `${ URLConstants . derivAppProduction } /cashier/deposit` ,
101
67
label : localize ( 'Cashier' ) ,
102
68
LeftComponent : LegacyCashierIcon ,
103
- // RightComponent: <LegacyChevronRight1pxIcon iconSize='xs' />,
104
- // submenu: 'cashier',
105
69
} ,
106
70
// TODO add theme logic
107
71
// {
@@ -155,130 +119,5 @@ export const MobileMenuConfig = () => {
155
119
] ,
156
120
] ;
157
121
158
- // const submenuConfig: TSubmenuConfig = {
159
- // TODO add disable/enable conditions to the accountsettings menu
160
- // accountSettings: {
161
- // items: [
162
- // {
163
- // Icon: LegacyProfileSmIcon,
164
- // label: localize('Profile'),
165
- // subItems: [
166
- // {
167
- // href: `${URLConstants.derivAppProduction}/account/personal-details`,
168
- // text: localize('Personal details'),
169
- // },
170
- // {
171
- // TODO add OpenLanguageSetting onClick
172
- // text: localize('Languages'),
173
- // },
174
- // ],
175
- // },
176
- // {
177
- // Icon: LegacyAssessmentIcon,
178
- // label: localize('Assessments'),
179
- // subItems: [
180
- // {
181
- // href: `${URLConstants.derivAppProduction}/account/trading-assessment`,
182
- // text: localize('Trading assessment'),
183
- // },
184
- // {
185
- // href: `${URLConstants.derivAppProduction}/account/financial-assessment`,
186
- // text: localize('Financial assessment'),
187
- // },
188
- // ],
189
- // },
190
- // {
191
- // Icon: LegacyVerificationIcon,
192
- // label: localize('Verification'),
193
- // subItems: [
194
- // {
195
- // href: `${URLConstants.derivAppProduction}/account/proof-of-identity`,
196
- // text: localize('Proof of identity'),
197
- // },
198
- // {
199
- // href: `${URLConstants.derivAppProduction}/account/proof-of-address`,
200
- // text: localize('Proof of address'),
201
- // },
202
- // {
203
- // href: `${URLConstants.derivAppProduction}/account/proof-of-ownership`,
204
- // text: localize('Proof of ownership'),
205
- // },
206
- // {
207
- // href: `${URLConstants.derivAppProduction}/account/proof-of-income`,
208
- // text: localize('Proof of income'),
209
- // },
210
- // ],
211
- // },
212
- // {
213
- // Icon: LegacySecurityIcon,
214
- // label: localize('Security and safety'),
215
- // subItems: [
216
- // {
217
- // href: `${URLConstants.derivAppProduction}/account/passwords`,
218
- // text: localize('Email and passwords'),
219
- // },
220
- // {
221
- // TODO add new badge for passkey
222
- // href: `${URLConstants.derivAppProduction}/account/passkeys`,
223
- // text: localize('Passkeys'),
224
- // },
225
- // {
226
- // href: `${URLConstants.derivAppProduction}/account/self-exclusion`,
227
- // text: localize('Self exclusion'),
228
- // },
229
- // {
230
- // href: `${URLConstants.derivAppProduction}/account/account-limits`,
231
- // text: localize('Account limits'),
232
- // },
233
- // {
234
- // href: `${URLConstants.derivAppProduction}/account/login-history`,
235
- // text: localize('Login history'),
236
- // },
237
- // {
238
- // href: `${URLConstants.derivAppProduction}/account/api-token`,
239
- // text: localize('API token'),
240
- // },
241
- // {
242
- // href: `${URLConstants.derivAppProduction}/account/connected-apps`,
243
- // text: localize('Connected apps'),
244
- // },
245
- // {
246
- // href: `${URLConstants.derivAppProduction}/account/two-factor-authentication`,
247
- // text: localize('Two-factor authentication'),
248
- // },
249
- // {
250
- // href: `${URLConstants.derivAppProduction}/account/closing-account`,
251
- // text: localize('Close your account'),
252
- // },
253
- // ],
254
- // },
255
- // ],
256
- // section: 'account',
257
- // title: localize('Account Settings'),
258
- // },
259
- // cashier: {
260
- // items: [
261
- // {
262
- // href: `${URLConstants.derivAppProduction}/cashier/deposit`,
263
- // Icon: LegacyDepositIcon,
264
- // label: localize('Deposit'),
265
- // },
266
- // {
267
- // href: `${URLConstants.derivAppProduction}/cashier/withdrawal`,
268
- // Icon: LegacyWithdrawalIcon,
269
- // label: localize('Withdrawal'),
270
- // },
271
- // {
272
- // href: `${URLConstants.derivAppProduction}/cashier/account-transfer`,
273
- // Icon: LegacyTransferIcon,
274
- // label: localize('Transfer'),
275
- // },
276
- // ],
277
- // section: 'cashier',
278
- // title: localize('Cashier'),
279
- // },
280
- // };
281
-
282
- // return { menuConfig, submenuConfig };
283
- return { menuConfig } ;
122
+ return menuConfig ;
284
123
} ;
0 commit comments