UI updates to add/update rules#93212
Conversation
|
@ShridharGoel 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] |
This comment has been minimized.
This comment has been minimized.
Reviewer Checklist
Screenshots/VideosAndroid: HybridAppAndroid: mWeb ChromeiOS: HybridAppScreen.Recording.2026-06-11.at.3.24.05.AM.moviOS: mWeb SafariMacOS: Chrome / SafariScreen.Recording.2026-06-11.at.3.15.52.AM.mov |
|
Videos for design team Screen.Recording.2026-06-11.at.3.15.52.AM.movScreen.Recording.2026-06-11.at.3.24.05.AM.mov |
| deleteRuleConfirmation: 'Are you sure you want to delete this rule?', | ||
| describeRuleTitle: 'Describe your rule', | ||
| describeRuleSubtitle: 'Describe your rule and Concierge will build it', | ||
| describeRuleTitle: 'Describe your rule and Concierge will build it.', |
There was a problem hiding this comment.
Can this not overflow to the second line and overlap with the user's prompt text (like on narrow screens in languages where the text is longer) because it is used as the floating label?
There was a problem hiding this comment.
What dimensions are you using?
There was a problem hiding this comment.
Fixed either way to be limited to one line: c3b9bae
16818f2 to
0c97b99
Compare
|
Let us know when we can run a build to review this |
…ted summaries and update prompt display logic in AIRulesSection. This change allows for a more descriptive title to be shown, improving clarity for users.
…ule.title ?? rule.prompt` to ensure a fallback to prompt when title is not available, enhancing user clarity.
Cover title/prompt fallback, whitespace normalization, sort order, pending-delete visibility online vs offline, and rule item / add button navigation paths. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
…ages to ensure consistency in punctuation.
…Label components This update introduces a new prop to control the label's behavior in multiline inputs, ensuring it can remain on a single line and ellipsize as needed. The prop has been added to the relevant types, implementations, and usage in AddAIRulePage and EditAIRulePage components.
c3b9bae to
89e38fd
Compare
Codecov Report✅ Changes either increased or maintained existing code coverage, great job!
|
|
@NicolasBonet @yuwenmemon @puneetlath I'm curious if you all are planning to address my other feedback from the original PR? Again, I set up a rule that didn't even work and it had a lot of unexpected user flows (random message from a bot, bot was added as an admin but wasn't announced as a system message in the #admins room, the rule I made for approval didn't even work, etc). I understand all of this is behind a beta - but do we have more clear guidance on what the ideal user flow is for this? |
Let's just skip this for now, we can follow up later if we feel strongly. |
|
On the contrary, can we please add a period at the end of this sentence here: @NicolasBonet all good on my end from here, just letting you know I will be away from laptop for the next 3 hours or so 🇪🇸 so feel free to get things merged without me |
Add period to AI rules section subtitle and drop trailing period from the floating label since it's not a sentence.
🦜 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/es.ts b/src/languages/es.ts
index 29adbbefdbc..609905dacfa 100644
--- a/src/languages/es.ts
+++ b/src/languages/es.ts
@@ -1753,7 +1753,6 @@ const translations: TranslationDeepObject<typeof en> = {
}
},
[CONST.NEXT_STEP.MESSAGE_KEY.WAITING_TO_MARK_AS_DONE]: (actor, actorType, _eta, _etaType) => {
- // eslint-disable-next-line default-case
switch (actorType) {
case CONST.NEXT_STEP.ACTOR_TYPE.CURRENT_USER:
return `Esperando a que <strong>tú</strong> lo marques como listo.`;
diff --git a/src/languages/fr.ts b/src/languages/fr.ts
index 1ff1bf7ca74..821cb0b1675 100644
--- a/src/languages/fr.ts
+++ b/src/languages/fr.ts
@@ -1,6 +1,7 @@
/**
* _____ __ __
* / ___/__ ___ ___ _______ _/ /____ ___/ /
+ * / (_ / -_) _ \/ -_) __/ _ \`/ __/ -_) _ /
* \___/\__/_//_/\__/_/ \_,_/\__/\__/\_,_/
*
* This file was automatically generated. Please consider these alternatives before manually editing it:
@@ -862,7 +863,7 @@ const translations: TranslationDeepObject<typeof en> = {
beginningOfChatHistory: (users: string) => `Cette discussion est avec ${users}.`,
beginningOfChatHistoryPolicyExpenseChat: (workspaceName: string, submitterDisplayName: string) =>
`C’est ici que <strong>${submitterDisplayName}</strong> soumettra des dépenses à <strong>${workspaceName}</strong>. Utilisez simplement le bouton +.`,
- beginningOfChatHistoryPolicyExpenseChatTrack: 'C\u2019est ici que vous suivrez vos dépenses',
+ beginningOfChatHistoryPolicyExpenseChatTrack: 'C’est ici que vous suivrez vos dépenses',
beginningOfChatHistorySelfDM: 'Ceci est votre espace personnel. Utilisez-le pour vos notes, tâches, brouillons et rappels.',
beginningOfChatHistorySystemDM: 'Bienvenue ! Procédons à la configuration.',
chatWithAccountManager: 'Discutez avec votre gestionnaire de compte ici',
@@ -7420,7 +7421,7 @@ Ajoutez davantage de règles de dépenses pour protéger la trésorerie de l’e
},
agentRules: {
title: 'Règles Agent',
- subtitle: 'Décrivez des règles flexibles qui s’exécutent quand vous en avez besoin.',
+ subtitle: 'Décrivez des règles flexibles qui s’exécutent lorsque vous en avez besoin.',
addRule: 'Ajouter une règle Agent',
findRule: 'Rechercher une règle Agent',
addRuleTitle: 'Ajouter une règle',
diff --git a/src/languages/it.ts b/src/languages/it.ts
index 7f1bd2f81d0..a8016a388be 100644
--- a/src/languages/it.ts
+++ b/src/languages/it.ts
@@ -7378,7 +7378,7 @@ Aggiungi altre regole di spesa per proteggere il flusso di cassa aziendale.`,
},
agentRules: {
title: 'Regole Agente',
- subtitle: 'Descrivi regole flessibili che vengono eseguite quando ne hai bisogno.',
+ subtitle: 'Descrivi regole flessibili che si attivano quando ne hai bisogno.',
addRule: 'Aggiungi regola Agente',
findRule: 'Trova regola Agente',
addRuleTitle: 'Aggiungi regola',
diff --git a/src/languages/ja.ts b/src/languages/ja.ts
index c35a517859c..cec7aa3e23c 100644
--- a/src/languages/ja.ts
+++ b/src/languages/ja.ts
@@ -7296,7 +7296,7 @@ ${reportName}
},
agentRules: {
title: 'エージェント ルール',
- subtitle: '必要なときに実行される柔軟なルールを記述します。',
+ subtitle: '必要なときに実行できる柔軟なルールについて説明します。',
addRule: 'エージェント ルールを追加',
findRule: 'エージェント ルールを検索',
addRuleTitle: 'ルールを追加',
diff --git a/src/languages/nl.ts b/src/languages/nl.ts
index 6274c4251ee..bb3329a866d 100644
--- a/src/languages/nl.ts
+++ b/src/languages/nl.ts
@@ -7353,14 +7353,14 @@ er bestedingsregels toe om de kasstroom van het bedrijf te beschermen.`,
},
agentRules: {
title: 'Agentregels',
- subtitle: 'Beschrijf flexibele regels die worden uitgevoerd wanneer je ze nodig hebt.',
+ subtitle: 'Beschrijf flexibele regels die worden uitgevoerd wanneer jij ze nodig hebt.',
addRule: 'Agentregel toevoegen',
findRule: 'Agentregel zoeken',
addRuleTitle: 'Regel toevoegen',
editRuleTitle: 'Regel bewerken',
deleteRule: 'Regel verwijderen',
deleteRuleConfirmation: 'Weet je zeker dat je deze regel wilt verwijderen?',
- describeRuleTitle: 'Beschrijf je regel en Concierge maakt hem voor je',
+ describeRuleTitle: 'Beschrijf je regel en Concierge stelt hem voor je op',
disclaimer: 'AI-agents kunnen fouten maken.',
},
},
diff --git a/src/languages/pl.ts b/src/languages/pl.ts
index b8b2ef30742..cf95d4dd117 100644
--- a/src/languages/pl.ts
+++ b/src/languages/pl.ts
@@ -7346,14 +7346,14 @@ Dodaj więcej zasad wydatków, żeby chronić płynność finansową firmy.`,
},
agentRules: {
title: 'Zasady Agenta',
- subtitle: 'Opisz elastyczne reguły, które działają wtedy, gdy ich potrzebujesz.',
+ subtitle: 'Opisuj elastyczne reguły, które uruchamiają się wtedy, gdy ich potrzebujesz.',
addRule: 'Dodaj regułę Agenta',
findRule: 'Znajdź regułę Agenta',
addRuleTitle: 'Dodaj regułę',
editRuleTitle: 'Edytuj regułę',
deleteRule: 'Usuń regułę',
deleteRuleConfirmation: 'Na pewno chcesz usunąć tę regułę?',
- describeRuleTitle: 'Opisz swoją regułę, a Concierge ją utworzy',
+ describeRuleTitle: 'Opisz swoją regułę, a Concierge ją zbuduje',
disclaimer: 'Agenci AI mogą popełniać błędy.',
},
},
diff --git a/src/languages/pt-BR.ts b/src/languages/pt-BR.ts
index 0a03d4f77ad..ab77c8cfe8b 100644
--- a/src/languages/pt-BR.ts
+++ b/src/languages/pt-BR.ts
@@ -7352,7 +7352,7 @@ Adicione mais regras de gasto para proteger o fluxo de caixa da empresa.`,
},
agentRules: {
title: 'Regras de Agente',
- subtitle: 'Descreva regras flexíveis que rodam quando você precisa.',
+ subtitle: 'Descreva regras flexíveis que sejam executadas quando você precisar.',
addRule: 'Adicionar regra de Agente',
findRule: 'Encontrar regra de Agente',
addRuleTitle: 'Adicionar regra',
diff --git a/src/languages/zh-hans.ts b/src/languages/zh-hans.ts
index d86821de609..ffad1e949a6 100644
--- a/src/languages/zh-hans.ts
+++ b/src/languages/zh-hans.ts
@@ -7164,14 +7164,14 @@ ${reportName}
},
agentRules: {
title: '代理规则',
- subtitle: '描述在你需要时运行的灵活规则。',
+ subtitle: '根据需要随时运行的灵活规则说明',
addRule: '添加代理规则',
findRule: '查找代理规则',
addRuleTitle: '添加规则',
editRuleTitle: '编辑规则',
deleteRule: '删除规则',
deleteRuleConfirmation: '确定要删除此规则吗?',
- describeRuleTitle: '描述你的规则,我们会由 Concierge 为你创建',
+ describeRuleTitle: '描述你的规则,我们会由 Concierge 来创建',
disclaimer: 'AI 智能体可能会犯错。',
},
},
Note You can apply these changes to your branch by copying the patch to your clipboard, then running |
|
Fixed the two wording ones @shawnborton, for the delete we can follow up, but Rules in general have the same pattern, so I didn't change that one |
isPerDiemRequest only checked iouRequestType, which is not always populated (e.g. for transactions reconstituted on the client without the request-type field). Fall back to the per diem customUnit name so inline edit permissions correctly disable amount and merchant fields.
|
🚧 @NicolasBonet has triggered a test Expensify/App build. You can view the workflow run here. |
This comment has been minimized.
This comment has been minimized.
Reviewer Checklist
Screenshots/VideosAndroid: HybridAppAndroid: mWeb ChromeiOS: HybridAppiOS: mWeb SafariMacOS: Chrome / Safari |
|
🚧 @yuwenmemon has triggered a test Expensify/App build. You can view the workflow run here. |
|
✋ This PR was not deployed to staging yet because QA is ongoing. It will be automatically deployed to staging after the next production release. |
|
🧪🧪 Use the links below to test this adhoc build on Android, iOS, and Web. Happy testing! 🧪🧪
|
|
🚀 Deployed to staging by https://github.com/yuwenmemon in version: 9.4.9-0 🚀
Bundle Size Analysis (Sentry): |
|
🤖 I reviewed the changes in this PR against the help site files under Why: This is a cosmetic/design-review follow-up. The changes don't alter any documented feature, workflow, button label, or behavior:
I checked the three articles that mention this feature — Since no changes are required, I did not create a draft help site PR. |
|
🚀 Deployed to production by https://github.com/puneetlath in version: 9.4.9-0 🚀
|
|
@mallenexpensify Looks like no payment issue was created for this - can you have a look? |




Explanation of Change
Follow up for #92736 due to a missing design review
Fixed Issues
$ https://github.com/Expensify/Expensify/issues/644757
PROPOSAL: https://github.com/Expensify/Expensify/issues/644757
Tests
Offline 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
MacOS: Chrome / Safari
Screen.Recording.2026-06-10.at.5.10.53.PM.mov