Skip to content

Commit

Permalink
Merge pull request #49826 from Expensify/Rory-FixTypes
Browse files Browse the repository at this point in the history
[No QA] Fix types
  • Loading branch information
aldo-expensify authored Sep 26, 2024
2 parents 70a8a16 + a5ff556 commit a935a15
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 3 deletions.
3 changes: 2 additions & 1 deletion src/languages/en.ts
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,7 @@ import type {
DefaultVendorDescriptionParams,
DelegateRoleParams,
DelegateSubmitParams,
DelegatorParams,
DeleteActionParams,
DeleteConfirmationParams,
DeleteExpenseTranslationParams,
Expand Down Expand Up @@ -4818,7 +4819,7 @@ const translations = {
}
},
genericError: 'Oops, something went wrong. Please try again.',
onBehalfOfMessage: (delegator: string) => `on behalf of ${delegator}`,
onBehalfOfMessage: ({delegator}: DelegatorParams) => `on behalf of ${delegator}`,
accessLevel: 'Access level',
confirmCopilot: 'Confirm your copilot below.',
accessLevelDescription: 'Choose an access level below. Both Full and Limited access allow copilots to view all conversations and expenses.',
Expand Down
3 changes: 2 additions & 1 deletion src/languages/es.ts
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,7 @@ import type {
DefaultVendorDescriptionParams,
DelegateRoleParams,
DelegateSubmitParams,
DelegatorParams,
DeleteActionParams,
DeleteConfirmationParams,
DeleteExpenseTranslationParams,
Expand Down Expand Up @@ -5338,7 +5339,7 @@ const translations = {
}
},
genericError: '¡Ups! Ha ocurrido un error. Por favor, inténtalo de nuevo.',
onBehalfOfMessage: (delegator: string) => `en nombre de ${delegator}`,
onBehalfOfMessage: ({delegator}: DelegatorParams) => `en nombre de ${delegator}`,
accessLevel: 'Nivel de acceso',
confirmCopilot: 'Confirma tu copiloto a continuación.',
accessLevelDescription: 'Elige un nivel de acceso a continuación. Tanto el acceso Completo como el Limitado permiten a los copilotos ver todas las conversaciones y gastos.',
Expand Down
3 changes: 3 additions & 0 deletions src/languages/params.ts
Original file line number Diff line number Diff line change
Expand Up @@ -469,6 +469,8 @@ type ReconciliationWorksParams = {lastFourPAN: string};

type DelegateRoleParams = {role: DelegateRole};

type DelegatorParams = {delegator: string};

type RoleNamesParams = {role: string};

type AssignCardParams = {
Expand Down Expand Up @@ -565,6 +567,7 @@ export type {
AssignedYouCardParams,
SpreadCategoriesParams,
DelegateRoleParams,
DelegatorParams,
ReconciliationWorksParams,
LastSyncAccountingParams,
SyncStageNameConnectionsParams,
Expand Down
2 changes: 1 addition & 1 deletion src/pages/home/report/ReportActionItemSingle.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -375,7 +375,7 @@ function ReportActionItemSingle({
</View>
) : null}
{action?.delegateAccountID && !isReportPreviewAction && (
<Text style={[styles.chatDelegateMessage]}>{translate('delegate.onBehalfOfMessage', accountOwnerDetails?.displayName ?? '')}</Text>
<Text style={[styles.chatDelegateMessage]}>{translate('delegate.onBehalfOfMessage', {delegator: accountOwnerDetails?.displayName ?? ''})}</Text>
)}
<View style={hasBeenFlagged ? styles.blockquote : {}}>{children}</View>
</View>
Expand Down

0 comments on commit a935a15

Please sign in to comment.