Update copy#87419
Conversation
This comment has been minimized.
This comment has been minimized.
Codecov Report✅ Changes either increased or maintained existing code coverage, great job!
|
|
@shawnborton since you wanted to change the illustration too |
|
I'm thinking something like this (Figma link): Would it make sense to also:
Thoughts @Expensify/design @Expensify/product ? |
|
Looks great! |
|
Agree with all your thoughts! 👍 |
|
Looks good. Which illustration do we want to use? Can we get that exported if we don't have it in App yet please? |
|
I think we already have both in App. So only thing left is to decide which one we want to go with |
|
No strong feelings, maybe the card icon if I had to pick between them? Let's see if anyone from @Expensify/design feels strongly. |
|
No strong feelings from me either - both make sense and look good. Down to roll with card illustration because this is a card-related screen and we use the thumbs up elsewhere? |
|
Sweet, I would say this is super low stakes, so let's roll with the card illustration and call it a day 🔨 |
|
Ok, thanks! Updated. Hiding the search bar and changing the button copy are already being handled separately in this PR #87678. So this PR is only changing the icon and blocking view copy
|
🦜 Polyglot Parrot! 🦜Squawk! Looks like you added some shiny new English strings. Allow me to parrot them back to you in other tongues: View the translation diffdiff --git a/src/languages/de.ts b/src/languages/de.ts
index c441ad62..6f506400 100644
--- a/src/languages/de.ts
+++ b/src/languages/de.ts
@@ -5291,7 +5291,7 @@ _Für ausführlichere Anweisungen [besuchen Sie unsere Hilfeseite](${CONST.NETSU
chooseTheCardholder: 'Wähle den Karteninhaber',
chooseCard: 'Wähle eine Karte',
chooseCardFor: (assignee: string) => `Wähle eine Karte für <strong>${assignee}</strong>. Du findest die gesuchte Karte nicht? <concierge-link>Gib uns Bescheid.</concierge-link>`,
- noAvailableCards: 'Keine aktiven Karten in diesem Feed',
+ noAvailableCards: 'Alle Karten haben bereits eine Regel',
somethingMightBeBroken:
'<muted-text><centered-text>Oder es ist etwas kaputt. Wie auch immer, wenn du Fragen hast, <concierge-link>wende dich einfach an Concierge</concierge-link>.</centered-text></muted-text>',
chooseTransactionStartDate: 'Wähle ein Startdatum für Transaktionen',
@@ -5327,6 +5327,7 @@ _Für ausführlichere Anweisungen [besuchen Sie unsere Hilfeseite](${CONST.NETSU
},
deletedCard: 'Gelöschte Karte',
assignNewCards: {title: 'Neue Karten zuweisen', description: 'Holen Sie die neuesten Karten zum Zuweisen von Ihrer Bank'},
+ noAvailableCardsSubtitle: 'Bearbeiten Sie eine bestehende Kartenregel, um Änderungen vorzunehmen',
},
expensifyCard: {
issueAndManageCards: 'Geben Sie Expensify Karten aus und verwalten Sie sie',
diff --git a/src/languages/fr.ts b/src/languages/fr.ts
index 6212949e..eb6cdfeb 100644
--- a/src/languages/fr.ts
+++ b/src/languages/fr.ts
@@ -5300,7 +5300,7 @@ _Pour des instructions plus détaillées, [visitez notre site d’aide](${CONST.
chooseCard: 'Choisir une carte',
chooseCardFor: (assignee: string) =>
`Choisissez une carte pour <strong>${assignee}</strong>. Vous ne trouvez pas la carte que vous cherchez ? <concierge-link>Dites-le-nous.</concierge-link>`,
- noAvailableCards: 'Aucune carte active dans ce flux',
+ noAvailableCards: 'Toutes les cartes ont déjà une règle',
somethingMightBeBroken:
'<muted-text><centered-text>Ou quelque chose est peut-être cassé. Dans tous les cas, si vous avez des questions, il vous suffit de <concierge-link>contacter Concierge</concierge-link>.</centered-text></muted-text>',
chooseTransactionStartDate: 'Choisissez une date de début de transaction',
@@ -5336,6 +5336,7 @@ _Pour des instructions plus détaillées, [visitez notre site d’aide](${CONST.
},
deletedCard: 'Carte supprimée',
assignNewCards: {title: 'Assigner de nouvelles cartes', description: 'Obtenez les dernières cartes à assigner depuis votre banque'},
+ noAvailableCardsSubtitle: 'Modifier une règle de carte existante pour effectuer des changements',
},
expensifyCard: {
issueAndManageCards: 'Émettre et gérer vos Cartes Expensify',
diff --git a/src/languages/it.ts b/src/languages/it.ts
index 1877f697..efb2e4d9 100644
--- a/src/languages/it.ts
+++ b/src/languages/it.ts
@@ -5273,7 +5273,7 @@ _Per istruzioni più dettagliate, [visita il nostro sito di assistenza](${CONST.
chooseCard: 'Scegli una carta',
chooseCardFor: (assignee: string) =>
`Scegli una carta per <strong>${assignee}</strong>. Non riesci a trovare la carta che stai cercando? <concierge-link>Facci sapere.</concierge-link>`,
- noAvailableCards: 'Nessuna carta attiva in questo feed',
+ noAvailableCards: 'Tutte le carte hanno già una regola',
somethingMightBeBroken:
'<muted-text><centered-text>Oppure potrebbe esserci un problema. In ogni caso, se hai domande, <concierge-link>contatta Concierge</concierge-link>.</centered-text></muted-text>',
chooseTransactionStartDate: 'Scegli una data di inizio transazione',
@@ -5307,6 +5307,7 @@ _Per istruzioni più dettagliate, [visita il nostro sito di assistenza](${CONST.
},
deletedCard: 'Carta eliminata',
assignNewCards: {title: 'Assegna nuove carte', description: 'Ottieni le ultime carte da assegnare dalla tua banca'},
+ noAvailableCardsSubtitle: 'Modifica una regola della carta esistente per apportare modifiche',
},
expensifyCard: {
issueAndManageCards: 'Emetti e gestisci le tue Carte Expensify',
diff --git a/src/languages/ja.ts b/src/languages/ja.ts
index 7ef612fc..37e2f3a2 100644
--- a/src/languages/ja.ts
+++ b/src/languages/ja.ts
@@ -5224,7 +5224,7 @@ _詳しい手順については、[ヘルプサイトをご覧ください](${CO
chooseCard: 'カードを選択',
chooseCardFor: (assignee: string) =>
`<strong>${assignee}</strong> に割り当てるカードを選択してください。お探しのカードが見つかりませんか?<concierge-link>お知らせください。</concierge-link>`,
- noAvailableCards: 'このフィードには有効なカードがありません',
+ noAvailableCards: 'すべてのカードにはすでにルールがあります',
somethingMightBeBroken:
'<muted-text><centered-text>もしくは不具合が発生している可能性があります。いずれにせよ、ご不明な点があれば、<concierge-link>Concierge にお問い合わせください</concierge-link>。</centered-text></muted-text>',
chooseTransactionStartDate: '取引の開始日を選択',
@@ -5258,6 +5258,7 @@ _詳しい手順については、[ヘルプサイトをご覧ください](${CO
},
deletedCard: '削除されたカード',
assignNewCards: {title: '新しいカードを割り当てる', description: '銀行から割り当て可能な最新のカードを取得します'},
+ noAvailableCardsSubtitle: '既存のカードルールを編集して変更します',
},
expensifyCard: {
issueAndManageCards: 'Expensify カードを発行して管理する',
diff --git a/src/languages/nl.ts b/src/languages/nl.ts
index 28d033c4..6d95f167 100644
--- a/src/languages/nl.ts
+++ b/src/languages/nl.ts
@@ -5265,7 +5265,7 @@ _Voor meer gedetailleerde instructies, [bezoek onze help-site](${CONST.NETSUITE_
chooseCard: 'Kies een kaart',
chooseCardFor: (assignee: string) =>
`Kies een kaart voor <strong>${assignee}</strong>. Kun je de kaart die je zoekt niet vinden? <concierge-link>Laat het ons weten.</concierge-link>`,
- noAvailableCards: 'Geen actieve kaarten in deze feed',
+ noAvailableCards: 'Alle kaarten hebben al een regel',
somethingMightBeBroken:
'<muted-text><centered-text>Of er er is iets kapot. Hoe dan ook, als je vragen hebt, <concierge-link>neem dan contact op met Concierge</concierge-link>.</centered-text></muted-text>',
chooseTransactionStartDate: 'Kies een startdatum voor transacties',
@@ -5300,6 +5300,7 @@ _Voor meer gedetailleerde instructies, [bezoek onze help-site](${CONST.NETSUITE_
},
deletedCard: 'Verwijderde kaart',
assignNewCards: {title: 'Nieuwe kaarten toewijzen', description: 'Haal de nieuwste kaarten op om toe te wijzen vanuit je bank'},
+ noAvailableCardsSubtitle: 'Bewerk een bestaande kaartregel om wijzigingen aan te brengen',
},
expensifyCard: {
issueAndManageCards: 'Geef Expensify Kaarten uit en beheer ze',
diff --git a/src/languages/pl.ts b/src/languages/pl.ts
index fba5a795..ad78d159 100644
--- a/src/languages/pl.ts
+++ b/src/languages/pl.ts
@@ -5254,7 +5254,7 @@ _Aby uzyskać bardziej szczegółowe instrukcje, [odwiedź naszą stronę pomocy
chooseTheCardholder: 'Wybierz posiadacza karty',
chooseCard: 'Wybierz kartę',
chooseCardFor: (assignee: string) => `Wybierz kartę dla <strong>${assignee}</strong>. Nie możesz znaleźć karty, której szukasz? <concierge-link>Daj nam znać.</concierge-link>`,
- noAvailableCards: 'Brak aktywnych kart w tym kanale',
+ noAvailableCards: 'Wszystkie karty mają już regułę',
somethingMightBeBroken:
'<muted-text><centered-text>Albo coś może być zepsute. Tak czy inaczej, jeśli masz jakieś pytania, po prostu <concierge-link>skontaktuj się z Concierge</concierge-link>.</centered-text></muted-text>',
chooseTransactionStartDate: 'Wybierz datę początkową transakcji',
@@ -5288,6 +5288,7 @@ _Aby uzyskać bardziej szczegółowe instrukcje, [odwiedź naszą stronę pomocy
},
deletedCard: 'Usunięta karta',
assignNewCards: {title: 'Przydziel nowe karty', description: 'Pobierz z banku najnowsze karty do przypisania'},
+ noAvailableCardsSubtitle: 'Edytuj istniejącą regułę karty, aby wprowadzić zmiany',
},
expensifyCard: {
issueAndManageCards: 'Wydawaj i zarządzaj Kartami Expensify',
diff --git a/src/languages/pt-BR.ts b/src/languages/pt-BR.ts
index 3d2be03f..e4c6eace 100644
--- a/src/languages/pt-BR.ts
+++ b/src/languages/pt-BR.ts
@@ -5257,7 +5257,7 @@ _Para instruções mais detalhadas, [visite nossa central de ajuda](${CONST.NETS
chooseCard: 'Escolha um cartão',
chooseCardFor: (assignee: string) =>
`Escolha um cartão para <strong>${assignee}</strong>. Não encontra o cartão que está procurando? <concierge-link>Conte para a gente.</concierge-link>`,
- noAvailableCards: 'Nenhum cartão ativo neste feed',
+ noAvailableCards: 'Todos os cartões já têm uma regra',
somethingMightBeBroken:
'<muted-text><centered-text>Ou talvez algo esteja com problema. De qualquer forma, se tiver alguma dúvida, é só <concierge-link>entrar em contato com a Concierge</concierge-link>.</centered-text></muted-text>',
chooseTransactionStartDate: 'Escolha uma data de início da transação',
@@ -5291,6 +5291,7 @@ _Para instruções mais detalhadas, [visite nossa central de ajuda](${CONST.NETS
},
deletedCard: 'Cartão excluído',
assignNewCards: {title: 'Atribuir novos cartões', description: 'Obtenha do seu banco os cartões mais recentes para atribuir'},
+ noAvailableCardsSubtitle: 'Edite uma regra de cartão existente para fazer alterações',
},
expensifyCard: {
issueAndManageCards: 'Emita e gerencie seus Cartões Expensify',
diff --git a/src/languages/zh-hans.ts b/src/languages/zh-hans.ts
index b1e55f9d..c17f9f01 100644
--- a/src/languages/zh-hans.ts
+++ b/src/languages/zh-hans.ts
@@ -5131,7 +5131,7 @@ _如需更详细的说明,请[访问我们的帮助网站](${CONST.NETSUITE_IM
chooseTheCardholder: '选择持卡人',
chooseCard: '选择一张卡片',
chooseCardFor: (assignee: string) => `为 <strong>${assignee}</strong> 选择一张卡片。找不到需要的卡片?<concierge-link>告诉我们。</concierge-link>`,
- noAvailableCards: '此订阅源中没有可用的卡片',
+ noAvailableCards: '所有卡片都已有规则',
somethingMightBeBroken:
'<muted-text><centered-text>或者可能出了点问题。不管怎样,如果你有任何疑问,请<concierge-link>联系 Concierge</concierge-link>。</centered-text></muted-text>',
chooseTransactionStartDate: '选择交易开始日期',
@@ -5165,6 +5165,7 @@ _如需更详细的说明,请[访问我们的帮助网站](${CONST.NETSUITE_IM
},
deletedCard: '已删除的卡片',
assignNewCards: {title: '分配新卡', description: '从您的银行获取可分配的最新银行卡'},
+ noAvailableCardsSubtitle: '编辑现有卡规则以进行更改',
},
expensifyCard: {
issueAndManageCards: '发放并管理您的 Expensify 卡',
Note You can apply these changes to your branch by copying the patch to your clipboard, then running |
|
@cretadn22 Please copy/paste the Reviewer Checklist from here into a new comment on this PR and complete it. If you have the K2 extension, you can simply click: [this button] |
Reviewer Checklist
Screenshots/Videos |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 1f588a9e47
ℹ️ About Codex in GitHub
Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".
| height={168} | ||
| /> | ||
| <Text style={[styles.textHeadlineLineHeightXXL, styles.mt3]}>{translate('workspace.companyCards.noActiveCards')}</Text> | ||
| <Text style={[styles.textHeadlineLineHeightXXL, styles.mt3]}>{translate('workspace.companyCards.noAvailableCards')}</Text> |
There was a problem hiding this comment.
Restore assign-card empty-state copy
This empty state is rendered in the card assignment flow (headerTitle is workspace.companyCards.assignCard), but it now uses workspace.companyCards.noAvailableCards (“All cards already have a rule”). In this context, cards can be missing because there are no active/unassigned cards in the feed, not because spend rules exist, so users are shown incorrect guidance whenever the assign-card list is empty.
Useful? React with 👍 / 👎.
| title={inputValue.trim() ? translate('common.noResultsFound') : translate('workspace.companyCards.noAvailableCards')} | ||
| titleStyles={styles.mb2} | ||
| subtitle={translate('workspace.companyCards.noAvailableCardsSubtitle')} |
There was a problem hiding this comment.
Make spend-rule subtitle conditional on no-card state
The empty-state title already distinguishes search misses (common.noResultsFound) from the no-available-cards case, but the new subtitle is always shown. When a user types a query that matches nothing, they now see “No results found” together with “Edit an existing card rule to make changes,” which is misleading because cards may still exist. This subtitle should only appear in the true no-available-cards branch.
Useful? React with 👍 / 👎.
There was a problem hiding this comment.
It displays like that. @shawnborton Do you think if we need to change?
There was a problem hiding this comment.
Given the current requirements, I think the existing display is fine
|
Sounds good, send it! |
|
🚧 @luacmartins has triggered a test Expensify/App build. You can view the workflow run here. |
|
🧪🧪 Use the links below to test this adhoc build on Android, iOS, and Web. Happy testing! 🧪🧪
|
|
✋ This PR was not deployed to staging yet because QA is ongoing. It will be automatically deployed to staging after the next production release. |
|
🚀 Deployed to staging by https://github.com/luacmartins in version: 9.3.59-0 🚀
Bundle Size Analysis (Sentry): |
|
No help site changes are required for this PR. The changes update an empty state message in the spend rule card selection flow ( |
|
Deploy Blocker #87800 was identified to be related to this PR. |
|
🚀 Deployed to production by https://github.com/AndrewGable in version: 9.3.59-4 🚀
|
| @@ -235,10 +235,13 @@ function SpendRuleCardPage({route}: SpendRuleCardPageProps) { | |||
| shouldPreventDefaultFocusOnSelectRow={!canUseTouchScreen()} | |||
| listEmptyContent={ | |||
| <BlockingView | |||
| icon={illustrations.Telescope} | |||
| iconWidth={variables.emptyListIconWidth} | |||
| iconHeight={variables.emptyListIconHeight} | |||
| title={inputValue.trim() ? translate('common.noResultsFound') : translate('workspace.companyCards.noActiveCards')} | |||
| icon={illustrations.HandCard} | |||
| iconWidth={variables.iconSection} | |||
| iconHeight={variables.iconSection} | |||
| title={inputValue.trim() ? translate('common.noResultsFound') : translate('workspace.companyCards.noAvailableCards')} | |||
| titleStyles={styles.mb2} | |||
| subtitle={translate('workspace.companyCards.noAvailableCardsSubtitle')} | |||
| subtitleStyle={styles.textSupporting} | |||
| /> | |||
| } | |||
| footerContent={ | |||
There was a problem hiding this comment.
This will always display "All cards already have a rule," even when no cards exist in the workspace. We have a fix in this PR: #88256.
For more details, please refer to: #87800 (comment).
| icon={illustrations.HandCard} | ||
| iconWidth={variables.iconSection} | ||
| iconHeight={variables.iconSection} | ||
| title={inputValue.trim() ? translate('common.noResultsFound') : translate('workspace.companyCards.noAvailableCards')} |
There was a problem hiding this comment.
This will always display "All cards already have a rule" — even when no cards exist in the workspace. We have a fix in this PR #88256
More details: #87800 (comment)










Explanation of Change
Updates the copy when all cards already have rules assigned.
Fixed Issues
$ #87421
Tests
Pre-condition:
Workspaces > Rules > Spend ruleOffline tests
N/A
QA Steps
Same as tests
PR Author Checklist
### Fixed Issuessection aboveTestssectionOffline stepssectionQA stepssectiontoggleReportand notonIconClick)src/languages/*files and using the translation methodSTYLE.md) were followedAvatar, I verified the components usingAvatarare working as expected)StyleUtils.getBackgroundAndBorderStyle(theme.componentBG))npm run compress-svg)Avataris modified, I verified thatAvataris working as expected in all cases)Designlabel and/or tagged@Expensify/designso the design team can review the changes.ScrollViewcomponent to make it scrollable when more elements are added to the page.mainbranch was merged into this PR after a review, I tested again and verified the outcome was still expected according to theTeststeps.Screenshots/Videos
Android: Native
Android: mWeb Chrome
iOS: Native
iOS: mWeb Safari
MacOS: Chrome / Safari