Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
24 changes: 14 additions & 10 deletions src/ROUTES.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3004,25 +3004,29 @@ const ROUTES = {
route: 'workspaces/:policyID/rules/spend-rules/new',
getRoute: (policyID: string) => `workspaces/${policyID}/rules/spend-rules/new` as const,
},
RULES_SPEND_EDIT: {
route: 'workspaces/:policyID/rules/spend-rules/:ruleID',
getRoute: (policyID: string, ruleID: string) => `workspaces/${policyID}/rules/spend-rules/${ruleID}` as const,
},
RULES_SPEND_CARD: {
route: 'workspaces/:policyID/rules/spend-rules/new/card',
getRoute: (policyID: string) => `workspaces/${policyID}/rules/spend-rules/new/card` as const,
route: 'workspaces/:policyID/rules/spend-rules/:ruleID/card',
getRoute: (policyID: string, ruleID?: string) => `workspaces/${policyID}/rules/spend-rules/${ruleID ?? ROUTES.NEW}/card` as const,
},
RULES_SPEND_CATEGORY: {
route: 'workspaces/:policyID/rules/spend-rules/new/category',
getRoute: (policyID: string) => `workspaces/${policyID}/rules/spend-rules/new/category` as const,
route: 'workspaces/:policyID/rules/spend-rules/:ruleID/category',
getRoute: (policyID: string, ruleID?: string) => `workspaces/${policyID}/rules/spend-rules/${ruleID ?? ROUTES.NEW}/category` as const,
},
RULES_SPEND_MAX_AMOUNT: {
route: 'workspaces/:policyID/rules/spend-rules/new/max-amount',
getRoute: (policyID: string) => `workspaces/${policyID}/rules/spend-rules/new/max-amount` as const,
route: 'workspaces/:policyID/rules/spend-rules/:ruleID/max-amount',
getRoute: (policyID: string, ruleID?: string) => `workspaces/${policyID}/rules/spend-rules/${ruleID ?? ROUTES.NEW}/max-amount` as const,
},
RULES_SPEND_MERCHANTS: {
route: 'workspaces/:policyID/rules/spend-rules/new/merchants',
getRoute: (policyID: string) => `workspaces/${policyID}/rules/spend-rules/new/merchants` as const,
route: 'workspaces/:policyID/rules/spend-rules/:ruleID/merchants',
getRoute: (policyID: string, ruleID?: string) => `workspaces/${policyID}/rules/spend-rules/${ruleID ?? ROUTES.NEW}/merchants` as const,
},
RULES_SPEND_MERCHANT_EDIT: {
route: 'workspaces/:policyID/rules/spend-rules/new/merchants/:merchantIndex',
getRoute: (policyID: string, merchantIndex: string) => `workspaces/${policyID}/rules/spend-rules/new/merchants/${merchantIndex}` as const,
route: 'workspaces/:policyID/rules/spend-rules/:ruleID/merchants/:merchantIndex',
getRoute: (policyID: string, ruleID: string, merchantIndex: string) => `workspaces/${policyID}/rules/spend-rules/${ruleID}/merchants/${merchantIndex}` as const,
},
RULES_MERCHANT_MERCHANT_TO_MATCH: {
route: 'workspaces/:policyID/rules/merchant-rules/:ruleID/merchant-to-match',
Expand Down
1 change: 1 addition & 0 deletions src/SCREENS.ts
Original file line number Diff line number Diff line change
Expand Up @@ -825,6 +825,7 @@ const SCREENS = {
RULES_PROHIBITED_DEFAULT: 'Rules_Prohibited_Default',
RULES_MERCHANT_NEW: 'Rules_Merchant_New',
RULES_SPEND_NEW: 'Rules_Spend_New',
RULES_SPEND_EDIT: 'Rules_Spend_Edit',
RULES_SPEND_CARD: 'Rules_Spend_Card',
RULES_SPEND_CATEGORY: 'Rules_Spend_Category',
RULES_SPEND_MAX_AMOUNT: 'Rules_Spend_Max_Amount',
Expand Down
25 changes: 3 additions & 22 deletions src/languages/de.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1701,17 +1701,13 @@ const translations: TranslationDeepObject<typeof en> = {
backdropLabel: 'Modal-Hintergrund',
},
nextStep: {
// All nextStep.message functions share a common positional signature (actor, actorType, eta, etaType) for type compatibility, so unused params are expected
/* eslint-disable @typescript-eslint/no-unused-vars */
message: {
[CONST.NEXT_STEP.MESSAGE_KEY.WAITING_TO_ADD_TRANSACTIONS]: (
actor: string,
actorType: ValueOf<typeof CONST.NEXT_STEP.ACTOR_TYPE>,
_eta?: string,
_etaType?: ValueOf<typeof CONST.NEXT_STEP.ETA_TYPE>,
) => {
// Disabling the default-case lint rule here is actually safer as this forces us to make the switch cases exhaustive
// eslint-disable-next-line default-case
switch (actorType) {
case CONST.NEXT_STEP.ACTOR_TYPE.CURRENT_USER:
return `Warte darauf, dass <strong>Sie</strong> Spesen hinzufügen.`;
Expand All @@ -1727,8 +1723,6 @@ const translations: TranslationDeepObject<typeof en> = {
_eta?: string,
_etaType?: ValueOf<typeof CONST.NEXT_STEP.ETA_TYPE>,
) => {
// Disabling the default-case lint rule here is actually safer as this forces us to make the switch cases exhaustive
// eslint-disable-next-line default-case
switch (actorType) {
case CONST.NEXT_STEP.ACTOR_TYPE.CURRENT_USER:
return `Wartet darauf, dass <strong>Sie</strong> Spesen einreichen.`;
Expand All @@ -1750,8 +1744,6 @@ const translations: TranslationDeepObject<typeof en> = {
_eta?: string,
_etaType?: ValueOf<typeof CONST.NEXT_STEP.ETA_TYPE>,
) => {
// Disabling the default-case lint rule here is actually safer as this forces us to make the switch cases exhaustive
// eslint-disable-next-line default-case
switch (actorType) {
case CONST.NEXT_STEP.ACTOR_TYPE.CURRENT_USER:
return `Warten darauf, dass <strong>Sie</strong> ein Bankkonto hinzufügen.`;
Expand All @@ -1771,8 +1763,6 @@ const translations: TranslationDeepObject<typeof en> = {
if (eta) {
formattedETA = etaType === CONST.NEXT_STEP.ETA_TYPE.DATE_TIME ? `am ${eta} eines jeden Monats` : ` ${eta}`;
}
// Disabling the default-case lint rule here is actually safer as this forces us to make the switch cases exhaustive
// eslint-disable-next-line default-case
switch (actorType) {
case CONST.NEXT_STEP.ACTOR_TYPE.CURRENT_USER:
return `Warten darauf, dass <strong>Ihre</strong> Ausgaben automatisch eingereicht werden${formattedETA}.`;
Expand All @@ -1788,8 +1778,6 @@ const translations: TranslationDeepObject<typeof en> = {
_eta?: string,
_etaType?: ValueOf<typeof CONST.NEXT_STEP.ETA_TYPE>,
) => {
// Disabling the default-case lint rule here is actually safer as this forces us to make the switch cases exhaustive
// eslint-disable-next-line default-case
switch (actorType) {
case CONST.NEXT_STEP.ACTOR_TYPE.CURRENT_USER:
return `Warten auf <strong>Sie</strong>, um die Probleme zu beheben.`;
Expand All @@ -1805,8 +1793,6 @@ const translations: TranslationDeepObject<typeof en> = {
_eta?: string,
_etaType?: ValueOf<typeof CONST.NEXT_STEP.ETA_TYPE>,
) => {
// Disabling the default-case lint rule here is actually safer as this forces us to make the switch cases exhaustive
// eslint-disable-next-line default-case
switch (actorType) {
case CONST.NEXT_STEP.ACTOR_TYPE.CURRENT_USER:
return `Es wird darauf gewartet, dass <strong>Sie</strong> Spesen genehmigen.`;
Expand All @@ -1822,8 +1808,6 @@ const translations: TranslationDeepObject<typeof en> = {
_eta?: string,
_etaType?: ValueOf<typeof CONST.NEXT_STEP.ETA_TYPE>,
) => {
// Disabling the default-case lint rule here is actually safer as this forces us to make the switch cases exhaustive
// eslint-disable-next-line default-case
switch (actorType) {
case CONST.NEXT_STEP.ACTOR_TYPE.CURRENT_USER:
return `Warte darauf, dass <strong>Sie</strong> diesen Bericht exportieren.`;
Expand All @@ -1839,8 +1823,6 @@ const translations: TranslationDeepObject<typeof en> = {
_eta?: string,
_etaType?: ValueOf<typeof CONST.NEXT_STEP.ETA_TYPE>,
) => {
// Disabling the default-case lint rule here is actually safer as this forces us to make the switch cases exhaustive
// eslint-disable-next-line default-case
switch (actorType) {
case CONST.NEXT_STEP.ACTOR_TYPE.CURRENT_USER:
return `Wartet darauf, dass <strong>Sie</strong> Spesen bezahlen.`;
Expand All @@ -1856,8 +1838,6 @@ const translations: TranslationDeepObject<typeof en> = {
_eta?: string,
_etaType?: ValueOf<typeof CONST.NEXT_STEP.ETA_TYPE>,
) => {
// Disabling the default-case lint rule here is actually safer as this forces us to make the switch cases exhaustive
// eslint-disable-next-line default-case
switch (actorType) {
case CONST.NEXT_STEP.ACTOR_TYPE.CURRENT_USER:
return `Warten darauf, dass <strong>Sie</strong> die Einrichtung eines Geschäftskontos abschließen.`;
Expand Down Expand Up @@ -6879,6 +6859,9 @@ Fügen Sie weitere Ausgabelimits hinzu, um den Cashflow Ihres Unternehmens zu sc
[CONST.SPEND_RULES.CATEGORIES.TRANSIT_AND_RIDESHARE]: 'Öffentlicher Nahverkehr und Fahrgemeinschaften',
[CONST.SPEND_RULES.CATEGORIES.TRAVEL_AGENCIES]: 'Reisebüros',
},
editRuleTitle: 'Regel bearbeiten',
deleteRule: 'Regel löschen',
deleteRuleConfirmation: 'Sind Sie sicher, dass Sie diese Regel löschen möchten?',
},
},
planTypePage: {
Expand Down Expand Up @@ -7378,8 +7361,6 @@ Fügen Sie weitere Ausgabelimits hinzu, um den Cashflow Ihres Unternehmens zu sc
updatedDefaultTitle: (newDefaultTitle: string, oldDefaultTitle: string) => `benutzerdefinierte Berichtstitelformel in „${newDefaultTitle}“ geändert (zuvor „${oldDefaultTitle}“)`,
updatedOwnership: (oldOwnerEmail: string, oldOwnerName: string, policyName: string) => `hat die Inhaberschaft von ${policyName} von ${oldOwnerName} (${oldOwnerEmail}) übernommen`,
updatedAutoHarvesting: (enabled: boolean) => `${enabled ? 'aktiviert' : 'deaktiviert'} geplante Einreichung`,
// This function requires 11 params to match the budget notification data model; reducing further would hurt readability
// eslint-disable-next-line @typescript-eslint/max-params
updatedIndividualBudgetNotification: (
budgetAmount: string,
budgetFrequency: string,
Expand Down
3 changes: 3 additions & 0 deletions src/languages/en.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6783,10 +6783,13 @@ const translations = {
description: `Expensify always declines these charges:\n\n • Adult services\n • ATMs\n • Gambling\n • Money transfers\n\nAdd more spend rules to protect company cash flow.`,
},
addSpendRule: 'Add spend rule',
editRuleTitle: 'Edit rule',
cardPageTitle: 'Card',
cardsSectionTitle: 'Cards',
chooseCards: 'Choose cards',
saveRule: 'Save rule',
deleteRule: 'Delete rule',
deleteRuleConfirmation: 'Are you sure you want to delete this rule?',
allow: 'Allow',
spendRuleSectionTitle: 'Spend rule',
restrictionType: 'Restriction type',
Expand Down
3 changes: 3 additions & 0 deletions src/languages/es.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6658,10 +6658,13 @@ ${amount} para ${merchant} - ${date}`,
description: `Expensify siempre rechaza estos cargos:\n\n • Servicios para adultos\n • Cajeros automáticos\n • Juegos de azar\n • Transferencias de dinero\n\nAgregue más reglas de gasto para proteger el flujo de caja de la empresa.`,
},
addSpendRule: 'Añadir regla de gastos',
editRuleTitle: 'Editar regla',
cardPageTitle: 'Tarjeta',
cardsSectionTitle: 'Tarjetas',
chooseCards: 'Elegir tarjetas',
saveRule: 'Guardar regla',
deleteRule: 'Eliminar regla',
deleteRuleConfirmation: '¿Estás seguro de que quieres eliminar esta regla?',
allow: 'Permitir',
spendRuleSectionTitle: 'Regla de gastos',
restrictionType: 'Tipo de restricción',
Expand Down
25 changes: 3 additions & 22 deletions src/languages/fr.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1706,17 +1706,13 @@ const translations: TranslationDeepObject<typeof en> = {
backdropLabel: 'Arrière-plan de la fenêtre modale',
},
nextStep: {
// All nextStep.message functions share a common positional signature (actor, actorType, eta, etaType) for type compatibility, so unused params are expected
/* eslint-disable @typescript-eslint/no-unused-vars */
message: {
[CONST.NEXT_STEP.MESSAGE_KEY.WAITING_TO_ADD_TRANSACTIONS]: (
actor: string,
actorType: ValueOf<typeof CONST.NEXT_STEP.ACTOR_TYPE>,
_eta?: string,
_etaType?: ValueOf<typeof CONST.NEXT_STEP.ETA_TYPE>,
) => {
// Disabling the default-case lint rule here is actually safer as this forces us to make the switch cases exhaustive
// eslint-disable-next-line default-case
switch (actorType) {
case CONST.NEXT_STEP.ACTOR_TYPE.CURRENT_USER:
return `En attente que <strong>vous</strong> ajoutiez des dépenses.`;
Expand All @@ -1732,8 +1728,6 @@ const translations: TranslationDeepObject<typeof en> = {
_eta?: string,
_etaType?: ValueOf<typeof CONST.NEXT_STEP.ETA_TYPE>,
) => {
// Disabling the default-case lint rule here is actually safer as this forces us to make the switch cases exhaustive
// eslint-disable-next-line default-case
switch (actorType) {
case CONST.NEXT_STEP.ACTOR_TYPE.CURRENT_USER:
return `En attente que <strong>vous</strong> soumettiez des dépenses.`;
Expand All @@ -1755,8 +1749,6 @@ const translations: TranslationDeepObject<typeof en> = {
_eta?: string,
_etaType?: ValueOf<typeof CONST.NEXT_STEP.ETA_TYPE>,
) => {
// Disabling the default-case lint rule here is actually safer as this forces us to make the switch cases exhaustive
// eslint-disable-next-line default-case
switch (actorType) {
case CONST.NEXT_STEP.ACTOR_TYPE.CURRENT_USER:
return `En attente que <strong>vous</strong> ajoutiez un compte bancaire.`;
Expand All @@ -1776,8 +1768,6 @@ const translations: TranslationDeepObject<typeof en> = {
if (eta) {
formattedETA = etaType === CONST.NEXT_STEP.ETA_TYPE.DATE_TIME ? `le ${eta} de chaque mois` : ` ${eta}`;
}
// Disabling the default-case lint rule here is actually safer as this forces us to make the switch cases exhaustive
// eslint-disable-next-line default-case
switch (actorType) {
case CONST.NEXT_STEP.ACTOR_TYPE.CURRENT_USER:
return `En attente que <strong>vos</strong> dépenses soient automatiquement soumises${formattedETA}.`;
Expand All @@ -1793,8 +1783,6 @@ const translations: TranslationDeepObject<typeof en> = {
_eta?: string,
_etaType?: ValueOf<typeof CONST.NEXT_STEP.ETA_TYPE>,
) => {
// Disabling the default-case lint rule here is actually safer as this forces us to make the switch cases exhaustive
// eslint-disable-next-line default-case
switch (actorType) {
case CONST.NEXT_STEP.ACTOR_TYPE.CURRENT_USER:
return `En attente que <strong>vous</strong> corrigiez les problèmes.`;
Expand All @@ -1810,8 +1798,6 @@ const translations: TranslationDeepObject<typeof en> = {
_eta?: string,
_etaType?: ValueOf<typeof CONST.NEXT_STEP.ETA_TYPE>,
) => {
// Disabling the default-case lint rule here is actually safer as this forces us to make the switch cases exhaustive
// eslint-disable-next-line default-case
switch (actorType) {
case CONST.NEXT_STEP.ACTOR_TYPE.CURRENT_USER:
return `En attente de <strong>votre</strong> approbation des dépenses.`;
Expand All @@ -1827,8 +1813,6 @@ const translations: TranslationDeepObject<typeof en> = {
_eta?: string,
_etaType?: ValueOf<typeof CONST.NEXT_STEP.ETA_TYPE>,
) => {
// Disabling the default-case lint rule here is actually safer as this forces us to make the switch cases exhaustive
// eslint-disable-next-line default-case
switch (actorType) {
case CONST.NEXT_STEP.ACTOR_TYPE.CURRENT_USER:
return `En attente que <strong>vous</strong> exportiez cette note de frais.`;
Expand All @@ -1844,8 +1828,6 @@ const translations: TranslationDeepObject<typeof en> = {
_eta?: string,
_etaType?: ValueOf<typeof CONST.NEXT_STEP.ETA_TYPE>,
) => {
// Disabling the default-case lint rule here is actually safer as this forces us to make the switch cases exhaustive
// eslint-disable-next-line default-case
switch (actorType) {
case CONST.NEXT_STEP.ACTOR_TYPE.CURRENT_USER:
return `En attente que <strong>vous</strong> payiez les dépenses.`;
Expand All @@ -1861,8 +1843,6 @@ const translations: TranslationDeepObject<typeof en> = {
_eta?: string,
_etaType?: ValueOf<typeof CONST.NEXT_STEP.ETA_TYPE>,
) => {
// Disabling the default-case lint rule here is actually safer as this forces us to make the switch cases exhaustive
// eslint-disable-next-line default-case
switch (actorType) {
case CONST.NEXT_STEP.ACTOR_TYPE.CURRENT_USER:
return `En attente que <strong>vous</strong> terminiez la configuration d’un compte bancaire professionnel.`;
Expand Down Expand Up @@ -6902,6 +6882,9 @@ Ajoutez davantage de règles de dépenses pour protéger la trésorerie de l’e
[CONST.SPEND_RULES.CATEGORIES.TRANSIT_AND_RIDESHARE]: 'Transports en commun et VTC',
[CONST.SPEND_RULES.CATEGORIES.TRAVEL_AGENCIES]: 'Agences de voyages',
},
editRuleTitle: 'Modifier la règle',
deleteRule: 'Supprimer la règle',
deleteRuleConfirmation: 'Êtes-vous sûr de vouloir supprimer cette règle ?',
},
},
planTypePage: {
Expand Down Expand Up @@ -7402,8 +7385,6 @@ Ajoutez davantage de règles de dépenses pour protéger la trésorerie de l’e
`a modifié la formule du nom de note de frais personnalisée en « ${newDefaultTitle} » (précédemment « ${oldDefaultTitle} »)`,
updatedOwnership: (oldOwnerEmail: string, oldOwnerName: string, policyName: string) => `a pris la responsabilité de ${policyName} à la place de ${oldOwnerName} (${oldOwnerEmail})`,
updatedAutoHarvesting: (enabled: boolean) => `Soumission planifiée pour ${enabled ? 'activé' : 'désactivé'}`,
// This function requires 11 params to match the budget notification data model; reducing further would hurt readability
// eslint-disable-next-line @typescript-eslint/max-params
updatedIndividualBudgetNotification: (
budgetAmount: string,
budgetFrequency: string,
Expand Down
Loading
Loading