Skip to content

fix: The Language dropdown has no role, name and state announced#80713

Merged
JS00001 merged 22 commits intoExpensify:mainfrom
nkdengineer:fix/77556
Mar 20, 2026
Merged

fix: The Language dropdown has no role, name and state announced#80713
JS00001 merged 22 commits intoExpensify:mainfrom
nkdengineer:fix/77556

Conversation

@nkdengineer
Copy link
Contributor

@nkdengineer nkdengineer commented Jan 28, 2026

Explanation of Change

fix: The Language dropdown has no role, name and state announced

Fixed Issues

$ #77556
PROPOSAL: #77556 (comment)

Tests

  • Verify that no errors appear in the JS console

Offline tests

QA Steps

// TODO: These must be filled out, or the issue title must include "[No QA]."

  • Verify that no errors appear in the JS console

PR Author Checklist

  • I linked the correct issue in the ### Fixed Issues section above
  • I wrote clear testing steps that cover the changes made in this PR
    • I added steps for local testing in the Tests section
    • I added steps for the expected offline behavior in the Offline steps section
    • I added steps for Staging and/or Production testing in the QA steps section
    • I added steps to cover failure scenarios (i.e. verify an input displays the correct error message if the entered data is not correct)
    • I turned off my network connection and tested it while offline to ensure it matches the expected behavior (i.e. verify the default avatar icon is displayed if app is offline)
    • I tested this PR with a High Traffic account against the staging or production API to ensure there are no regressions (e.g. long loading states that impact usability).
  • I included screenshots or videos for tests on all platforms
  • I ran the tests on all platforms & verified they passed on:
    • Android: Native
    • Android: mWeb Chrome
    • iOS: Native
    • iOS: mWeb Safari
    • MacOS: Chrome / Safari
  • I verified there are no console errors (if there's a console error not related to the PR, report it or open an issue for it to be fixed)
  • I verified there are no new alerts related to the canBeMissing param for useOnyx
  • I followed proper code patterns (see Reviewing the code)
    • I verified that any callback methods that were added or modified are named for what the method does and never what callback they handle (i.e. toggleReport and not onIconClick)
    • I verified that comments were added to code that is not self explanatory
    • I verified that any new or modified comments were clear, correct English, and explained "why" the code was doing something instead of only explaining "what" the code was doing.
    • I verified any copy / text shown in the product is localized by adding it to src/languages/* files and using the translation method
      • If any non-english text was added/modified, I used JaimeGPT to get English > Spanish translation. I then posted it in #expensify-open-source and it was approved by an internal Expensify engineer. Link to Slack message:
    • I verified all numbers, amounts, dates and phone numbers shown in the product are using the localization methods
    • I verified any copy / text that was added to the app is grammatically correct in English. It adheres to proper capitalization guidelines (note: only the first word of header/labels should be capitalized), and is either coming verbatim from figma or has been approved by marketing (in order to get marketing approval, ask the Bug Zero team member to add the Waiting for copy label to the issue)
    • I verified proper file naming conventions were followed for any new files or renamed files. All non-platform specific files are named after what they export and are not named "index.js". All platform-specific files are named for the platform the code supports as outlined in the README.
    • I verified the JSDocs style guidelines (in STYLE.md) were followed
  • If a new code pattern is added I verified it was agreed to be used by multiple Expensify engineers
  • I followed the guidelines as stated in the Review Guidelines
  • I tested other components that can be impacted by my changes (i.e. if the PR modifies a shared library or component like Avatar, I verified the components using Avatar are working as expected)
  • I verified all code is DRY (the PR doesn't include any logic written more than once, with the exception of tests)
  • I verified any variables that can be defined as constants (ie. in CONST.ts or at the top of the file that uses the constant) are defined as such
  • I verified that if a function's arguments changed that all usages have also been updated correctly
  • If any new file was added I verified that:
    • The file has a description of what it does and/or why is needed at the top of the file if the code is not self explanatory
  • If a new CSS style is added I verified that:
    • A similar style doesn't already exist
    • The style can't be created with an existing StyleUtils function (i.e. StyleUtils.getBackgroundAndBorderStyle(theme.componentBG))
  • If new assets were added or existing ones were modified, I verified that:
    • The assets are optimized and compressed (for SVG files, run npm run compress-svg)
    • The assets load correctly across all supported platforms.
  • If the PR modifies code that runs when editing or sending messages, I tested and verified there is no unexpected behavior for all supported markdown - URLs, single line code, code blocks, quotes, headings, bold, strikethrough, and italic.
  • If the PR modifies a generic component, I tested and verified that those changes do not break usages of that component in the rest of the App (i.e. if a shared library or component like Avatar is modified, I verified that Avatar is working as expected in all cases)
  • If the PR modifies a component related to any of the existing Storybook stories, I tested and verified all stories for that component are still working as expected.
  • If the PR modifies a component or page that can be accessed by a direct deeplink, I verified that the code functions as expected when the deeplink is used - from a logged in and logged out account.
  • If the PR modifies the UI (e.g. new buttons, new UI components, changing the padding/spacing/sizing, moving components, etc) or modifies the form input styles:
    • I verified that all the inputs inside a form are aligned with each other.
    • I added Design label and/or tagged @Expensify/design so the design team can review the changes.
  • If a new page is added, I verified it's using the ScrollView component to make it scrollable when more elements are added to the page.
  • I added unit tests for any new feature or bug fix in this PR to help automatically prevent regressions in this user flow.
  • If the main branch was merged into this PR after a review, I tested again and verified the outcome was still expected according to the Test steps.

Screenshots/Videos

Android: Native
Android: mWeb Chrome
iOS: Native
iOS: mWeb Safari
MacOS: Chrome / Safari
Screen.Recording.2026-01-28.at.23.50.02.mov

@melvin-bot
Copy link

melvin-bot bot commented Jan 28, 2026

Hey! I see that you made changes to our Form component. Make sure to update the docs in FORMS.md accordingly. Cheers!

@codecov
Copy link

codecov bot commented Jan 28, 2026

Codecov Report

✅ Changes either increased or maintained existing code coverage, great job!

Files with missing lines Coverage Δ
...Picker/getAccessibilityLabelConfig/index.native.ts 100.00% <100.00%> (ø)
src/components/Picker/BasePicker.tsx 57.95% <81.81%> (+3.40%) ⬆️
...onents/Picker/getAccessibilityLabelConfig/index.ts 0.00% <0.00%> (ø)
... and 9 files with indirect coverage changes

@nkdengineer nkdengineer marked this pull request as ready for review January 28, 2026 16:51
@nkdengineer nkdengineer requested review from a team as code owners January 28, 2026 16:51
@melvin-bot melvin-bot bot requested review from Ollyws and joekaufmanexpensify and removed request for a team January 28, 2026 16:51
@melvin-bot
Copy link

melvin-bot bot commented Jan 28, 2026

@Ollyws 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]

@melvin-bot melvin-bot bot removed the request for review from a team January 28, 2026 16:51
Copy link
Contributor

@joekaufmanexpensify joekaufmanexpensify left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fine from a product perspective

@Ollyws
Copy link
Contributor

Ollyws commented Jan 29, 2026

@nkdengineer We're we going to implement:

Compute a descriptive label that combines the field label (if present) with the currently selected value.

?

@nkdengineer
Copy link
Contributor Author

@Ollyws Here is the text reader from Voice over, when we focus on the picker, the selected Langue is already a text of the reader then we only need to add the accessibilityLabel as the Language

Screen.Recording.2026-02-03.at.13.15.46.mov

@Ollyws
Copy link
Contributor

Ollyws commented Feb 3, 2026

@nkdengineer Isn't it supposed to say the status of the dropdown too?

@nkdengineer
Copy link
Contributor Author

@Ollyws Isn't it the status of the dropdown?

Screenshot 2026-02-05 at 09 40 10

@Ollyws
Copy link
Contributor

Ollyws commented Feb 5, 2026

@nkdengineer But that behaviour only applies to web right? On mobile platforms is just anounces the title of the dropdown.

@nkdengineer
Copy link
Contributor Author

On mobile platforms is just anounces the title of the dropdown.

@Ollyws Can you share a video?

@Ollyws
Copy link
Contributor

Ollyws commented Feb 13, 2026

@nkdengineer On iOS in the accesibility inspector the value is displaying as empty and it just announces the title:

Screenshot 2026-02-13 at 12 07 48

@nkdengineer
Copy link
Contributor Author

@Ollyws You're right, I updated.

@Ollyws
Copy link
Contributor

Ollyws commented Feb 23, 2026

Thanks for the update and it's going in the right direction, but on the original issue the expected outcome is:

The control should be announced with its role, name, value and state, e.g.:
'Select Language , button, collapsed'

@nkdengineer
Copy link
Contributor Author

@Ollyws On dev testing, I can't focus on the picker on mWeb

@Ollyws
Copy link
Contributor

Ollyws commented Mar 19, 2026

@MelvinBot Why would the picker be announcing 'collapsed' on android talkback mWeb but not on native?

@MelvinBot
Copy link
Contributor

This comes down to a fundamental difference in how accessibility state is managed on mWeb vs native Android.

On mWeb (Android TalkBack in Chrome): The browser natively manages expanded/collapsed state for elements with role="combobox". This is built into the browser's accessibility tree — Chrome automatically tracks whether a combobox is open or closed and TalkBack announces it. This happens regardless of the custom accessibilityLabel text; it's a browser-level behavior baked into the ARIA combobox spec.

On native Android: React Native has no built-in "combobox" concept that automatically tracks expanded/collapsed state. Previously, the component used accessibilityState: {expanded: isHighlighted} on touchableWrapperProps — this was the native mechanism that told TalkBack about the state. This PR removed that in favor of putting "Collapsed"/"Expanded" text into the accessibilityLabel string.

The issue is that accessibilityState.expanded and label text behave differently for TalkBack:

  • accessibilityState triggers TalkBack to automatically announce state changes (e.g., "collapsed" → "expanded") when the value changes
  • Text in accessibilityLabel is typically only read when the element first receives focus, not on state transitions

So on native, TalkBack may not be re-announcing the label when the picker opens/closes, whereas on mWeb the browser handles it natively through the combobox role's built-in state management.

@Ollyws
Copy link
Contributor

Ollyws commented Mar 19, 2026

@MelvinBot What changes would you suggest to fix this discrepancy?

@MelvinBot
Copy link
Contributor

I'd suggest a two-part fix:

1. Restore accessibilityState in touchableWrapperProps

The accessibilityState: {expanded: isHighlighted} that was removed needs to come back. This is the native mechanism TalkBack/VoiceOver use to announce expanded/collapsed state. Since renderWeb() in react-native-picker-select ignores touchableWrapperProps entirely, restoring it won't affect web.

In BasePicker.tsx, the touchableWrapperProps should become:

touchableWrapperProps={{
    accessible: true,
    accessibilityRole: CONST.ROLE.COMBOBOX,
    accessibilityLabel: actualAccessibilityLabel,
    accessibilityState: {disabled: isDisabled, expanded: isHighlighted},
}}

2. Separate "state text in label" from "selected label in label"

On native, with accessibilityState.expanded restored, embedding "Collapsed"/"Expanded" text in the label becomes redundant (and would cause double-announcement). But on mWeb, the text is needed because touchableWrapperProps is ignored by the web renderer.

Add a shouldAnnounceExpandedState flag to getAccessibilityLabelConfig:

index.native.ts — set shouldAnnounceExpandedState: false (native uses accessibilityState instead):

return {
    shouldAnnounceSelectedLabel: true,
    shouldUseCustomAccessibilityLabel: true,
    shouldAnnounceExpandedState: false,
};

index.ts (web) — set shouldAnnounceExpandedState: isMobile() (mWeb needs the text since touchableWrapperProps is ignored):

return {
    shouldAnnounceSelectedLabel: false,
    shouldUseCustomAccessibilityLabel: isMobile(),
    shouldAnnounceExpandedState: isMobile(),
};

Then update enhancedAccessibilityLabel in BasePicker.tsx to only append the state text when shouldAnnounceExpandedState is true:

const enhancedAccessibilityLabel = useMemo(() => {
    if (!defaultAccessibilityLabel) {
        return selectedLabel || '';
    }
    if (selectedLabel) {
        const parts = [defaultAccessibilityLabel];
        if (shouldAnnounceSelectedLabel) {
            parts.push(selectedLabel);
        }
        if (shouldAnnounceExpandedState) {
            parts.push(translate(isHighlighted ? 'common.expanded' : 'common.collapsed'));
        }
        return parts.join(', ');
    }
    return defaultAccessibilityLabel;
}, [defaultAccessibilityLabel, selectedLabel, shouldAnnounceSelectedLabel, shouldAnnounceExpandedState, translate, isHighlighted]);

Result

Platform Expanded/collapsed via State text in label?
Native (Android/iOS) accessibilityState.expanded on touchableWrapper No
mWeb Text in label (renderWeb() ignores touchableWrapperProps) Yes
Desktop web Native <select> combobox behavior No

This way each platform uses the correct mechanism: native platforms get the semantic accessibilityState that TalkBack/VoiceOver understand natively, while mWeb gets the text-based fallback since it's the only available mechanism there.

@Ollyws
Copy link
Contributor

Ollyws commented Mar 19, 2026

@MelvinBot shouldAnnounceExpandedState: isMobile() leads to 'collapsed' being announced twice on mWeb.

@MelvinBot
Copy link
Contributor

Right — this is because of two overlapping announcements on mWeb:

  1. Browser-native: Elements with role="combobox" get their expanded/collapsed state announced automatically by the browser's accessibility tree. This is built into the ARIA spec and happens regardless of the accessibilityLabel content.
  2. Custom label text: When shouldUseCustomAccessibilityLabel is true (which isMobile() returns on mWeb), the enhancedAccessibilityLabel at BasePicker.tsx:178 appends , Collapsed or , Expanded as literal text in the label.

So TalkBack reads both — the explicit text from the label AND the browser's native state announcement.

The fix would be to add a separate flag (e.g. shouldAnnounceExpandedState) to control whether the expanded/collapsed text is included in the label, independent of shouldUseCustomAccessibilityLabel. On mWeb, you'd want shouldUseCustomAccessibilityLabel: true (for the custom label format) but shouldAnnounceExpandedState: false (since the browser handles state natively). On native, both would be true since there's no browser to handle it automatically.

@Ollyws
Copy link
Contributor

Ollyws commented Mar 19, 2026

@MelvinBot Ok so fix your proposal...

@MelvinBot
Copy link
Contributor

Updated proposal — the key insight from your feedback is that no platform needs the expanded/collapsed text in the label, so we can simplify significantly:

  • Native: accessibilityState.expanded is the correct mechanism (TalkBack/VoiceOver read it natively)
  • mWeb: Browser announces combobox state natively via ARIA
  • Desktop web: Same as mWeb — browser handles it

Changes

1. Restore accessibilityState in touchableWrapperProps (this only affects native since renderWeb() ignores touchableWrapperProps):

touchableWrapperProps={{
    accessible: true,
    accessibilityRole: CONST.ROLE.COMBOBOX,
    accessibilityLabel: actualAccessibilityLabel,
    accessibilityState: {disabled: isDisabled, expanded: isHighlighted},
}}

2. Remove the expanded/collapsed text from enhancedAccessibilityLabel entirely:

const enhancedAccessibilityLabel = useMemo(() => {
    if (!defaultAccessibilityLabel) {
        return selectedLabel || '';
    }
    if (selectedLabel) {
        return `${defaultAccessibilityLabel}${shouldAnnounceSelectedLabel ? `, ${selectedLabel}` : ''}`;
    }
    return defaultAccessibilityLabel;
}, [defaultAccessibilityLabel, selectedLabel, shouldAnnounceSelectedLabel]);

3. Remove common.collapsed / common.expanded from all language files — no longer needed.

Result

Platform State announced via Text in label?
Native accessibilityState.expanded No
mWeb Browser-native combobox behavior No
Desktop web Browser-native combobox behavior No

No double announcements on any platform, and each platform uses its proper native mechanism.

@Ollyws
Copy link
Contributor

Ollyws commented Mar 19, 2026

@MelvinBot This doesn't announce 'collapsed/expanded/ for ios safari

@MelvinBot
Copy link
Contributor

On iOS Safari, VoiceOver handles <select> elements differently from how Android TalkBack handles them on Chrome.

The root cause: On web, the picker renders as a native HTML <select> element (via @react-native-picker/picker's web implementation). The "Collapsed/Expanded" text is embedded in the accessibilityLabel (which becomes aria-label), but there is no explicit aria-expanded attribute set on the element.

  • Android TalkBack (Chrome): Reads the full aria-label string including the "Collapsed/Expanded" text, so users hear the state announcement.
  • iOS VoiceOver (Safari): Treats <select> elements as "popup buttons" and uses its own native state management. VoiceOver does not parse state information from within label text — it expects an explicit aria-expanded attribute on role="combobox" elements to announce expanded/collapsed state.

The fix would be to add an explicit aria-expanded (or accessibilityExpanded) prop to the pickerProps on web, toggled by isHighlighted:

pickerProps={{
    // ... existing props
    accessibilityExpanded: isHighlighted,
}}

This would give VoiceOver the semantic signal it needs to announce the state, rather than relying on it being embedded in the label text.

@Ollyws
Copy link
Contributor

Ollyws commented Mar 19, 2026

@MelvinBot accessibilityExpanded doesn't work on Safari with RNPickerSelect

@MelvinBot
Copy link
Contributor

That's correct — accessibilityState: {expanded} effectively never worked on Safari (or any web browser) with RNPickerSelect. There are three compounding reasons:

  1. touchableWrapperProps is ignored on web. RNPickerSelect.renderWeb() only destructures {disabled, style, pickerProps} — it does not use touchableWrapperProps at all (index.js:647-672). So the old accessibilityState: {expanded} on touchableWrapperProps was dead code on web. Compare with renderIOS() and renderAndroidHeadless() which both explicitly spread touchableWrapperProps onto a TouchableOpacity wrapper.

  2. react-native-web doesn't handle the compound accessibilityState object. The createDOMProps module in react-native-web destructures individual props like accessibilityExpanded (→ aria-expanded) but does not handle the compound accessibilityState: {expanded: boolean} object. It would fall through to rest props and be discarded or warned about as an unknown DOM attribute.

  3. Browsers ignore aria-expanded on native <select> elements anyway. On web, the Picker renders a native HTML <select> via unstable_createElement('select', ...) in Picker.web.js. Browsers fully control the expanded/collapsed state of <select> elements natively — aria-expanded has no effect on them because the browser's internal accessibility tree manages that state.

So the PR's approach of embedding "Collapsed"/"Expanded" text in the accessibilityLabel is a valid workaround, particularly for mobile web where screen readers may not reliably announce the native <select> popup state.

@Ollyws
Copy link
Contributor

Ollyws commented Mar 19, 2026

@MelvinBot is there no way to stop all web announcing collapsed/expanded?

@MelvinBot
Copy link
Contributor

No — the browser's native collapsed/expanded announcement for <select>/combobox elements cannot be suppressed on web. It's built into the ARIA combobox spec and is how screen readers convey the interactive nature of a dropdown. Suppressing it would actually be an accessibility regression.

However, the concern this raises is about double announcements on mWeb. Currently, when shouldUseCustomAccessibilityLabel is true on mWeb, the enhancedAccessibilityLabel at line 178 appends , Collapsed or , Expanded as text in the label:

return `${defaultAccessibilityLabel}${shouldAnnounceSelectedLabel ? `, ${selectedLabel}` : ''}, ${translate(isHighlighted ? 'common.expanded' : 'common.collapsed')}`;

Since the browser also natively announces collapsed/expanded for the combobox role, mWeb users would hear it twice — once from the custom label text and once from the browser's native behavior.

The fix would be to add a separate flag (e.g., shouldAnnounceExpandedState) that is true on native (where there's no browser to handle it) and false on web (where the browser handles it natively). Then conditionally include the "Collapsed/Expanded" text only when that flag is true. This way:

  • Native: custom label includes "Collapsed/Expanded" (needed, since no browser handles it)
  • mWeb: custom label omits "Collapsed/Expanded" (browser handles it natively)
  • Desktop web: shouldUseCustomAccessibilityLabel is already false, so the enhanced label isn't used at all

@Ollyws
Copy link
Contributor

Ollyws commented Mar 19, 2026

@MelvinBot mWeb: custom label omits "Collapsed/Expanded" (browser handles it natively) the problem is that only Android Chrome handles it and not iOS Safari

@MelvinBot
Copy link
Contributor

You're right — my previous answer was inaccurate. Let me correct it.

Looking at the code more carefully:

On mWeb, renderWeb() only uses pickerProps (line 647-671 of react-native-picker-select/src/index.js). textInputProps and touchableWrapperProps are ignored on web. The <Picker> renders as a native <select> element in the DOM, and pickerProps passes along accessibilityLabel: actualAccessibilityLabel and accessibilityRole: 'combobox'.

The custom label does include "Collapsed/Expanded" text on mWeb (since shouldUseCustomAccessibilityLabel: isMobile() is true), so the aria-label on the <select> element will contain that text. However, whether the screen reader actually announces it depends on the browser + screen reader pairing:

  • Android Chrome + TalkBack: Announces collapsed/expanded — likely from TalkBack's native handling of the combobox role (and possibly also reading the label text)
  • iOS Safari + VoiceOver: Does not announce collapsed/expanded — VoiceOver may ignore the state text in aria-label on <select> elements, or handle role="combobox" differently than Chrome does

The root issue is that the <select> element's expanded/collapsed state is surfaced inconsistently across browser/screen reader combinations. The aria-label text approach works on some pairings but not others. For iOS Safari, aria-expanded (mapped from accessibilityState: {expanded}) might be more reliable than embedding state text in the label string — but notably this PR removed accessibilityState from touchableWrapperProps, and touchableWrapperProps aren't even used on web anyway.

This may need a web-specific approach like explicitly setting aria-expanded on the picker's DOM element for iOS Safari VoiceOver to announce the state properly.

@Ollyws
Copy link
Contributor

Ollyws commented Mar 19, 2026

Reviewer Checklist

  • I have verified the author checklist is complete (all boxes are checked off).
  • I verified the correct issue is linked in the ### Fixed Issues section above
  • I verified testing steps are clear and they cover the changes made in this PR
    • I verified the steps for local testing are in the Tests section
    • I verified the steps for Staging and/or Production testing are in the QA steps section
    • I verified the steps cover any possible failure scenarios (i.e. verify an input displays the correct error message if the entered data is not correct)
    • I turned off my network connection and tested it while offline to ensure it matches the expected behavior (i.e. verify the default avatar icon is displayed if app is offline)
  • I checked that screenshots or videos are included for tests on all platforms
  • I included screenshots or videos for tests on all platforms
  • I verified that the composer does not automatically focus or open the keyboard on mobile unless explicitly intended. This includes checking that returning the app from the background does not unexpectedly open the keyboard.
  • I verified tests pass on all platforms & I tested again on:
    • Android: HybridApp
    • Android: mWeb Chrome
    • iOS: HybridApp
    • iOS: mWeb Safari
    • MacOS: Chrome / Safari
  • If there are any errors in the console that are unrelated to this PR, I either fixed them (preferred) or linked to where I reported them in Slack
  • I verified proper code patterns were followed (see Reviewing the code)
    • I verified that any callback methods that were added or modified are named for what the method does and never what callback they handle (i.e. toggleReport and not onIconClick).
    • I verified that comments were added to code that is not self explanatory
    • I verified that any new or modified comments were clear, correct English, and explained "why" the code was doing something instead of only explaining "what" the code was doing.
    • I verified any copy / text shown in the product is localized by adding it to src/languages/* files and using the translation method
    • I verified all numbers, amounts, dates and phone numbers shown in the product are using the localization methods
    • I verified any copy / text that was added to the app is grammatically correct in English. It adheres to proper capitalization guidelines (note: only the first word of header/labels should be capitalized), and is either coming verbatim from figma or has been approved by marketing (in order to get marketing approval, ask the Bug Zero team member to add the Waiting for copy label to the issue)
    • I verified proper file naming conventions were followed for any new files or renamed files. All non-platform specific files are named after what they export and are not named "index.js". All platform-specific files are named for the platform the code supports as outlined in the README.
    • I verified the JSDocs style guidelines (in STYLE.md) were followed
  • If a new code pattern is added I verified it was agreed to be used by multiple Expensify engineers
  • I verified that this PR follows the guidelines as stated in the Review Guidelines
  • I verified other components that can be impacted by these changes have been tested, and I retested again (i.e. if the PR modifies a shared library or component like Avatar, I verified the components using Avatar have been tested & I retested again)
  • I verified all code is DRY (the PR doesn't include any logic written more than once, with the exception of tests)
  • I verified any variables that can be defined as constants (ie. in CONST.ts or at the top of the file that uses the constant) are defined as such
  • If a new component is created I verified that:
    • A similar component doesn't exist in the codebase
    • All props are defined accurately and each prop has a /** comment above it */
    • The file is named correctly
    • The component has a clear name that is non-ambiguous and the purpose of the component can be inferred from the name alone
    • The only data being stored in the state is data necessary for rendering and nothing else
    • For Class Components, any internal methods passed to components event handlers are bound to this properly so there are no scoping issues (i.e. for onClick={this.submit} the method this.submit should be bound to this in the constructor)
    • Any internal methods bound to this are necessary to be bound (i.e. avoid this.submit = this.submit.bind(this); if this.submit is never passed to a component event handler like onClick)
    • All JSX used for rendering exists in the render method
    • The component has the minimum amount of code necessary for its purpose, and it is broken down into smaller components in order to separate concerns and functions
  • If any new file was added I verified that:
    • The file has a description of what it does and/or why is needed at the top of the file if the code is not self explanatory
  • If a new CSS style is added I verified that:
    • A similar style doesn't already exist
    • The style can't be created with an existing StyleUtils function (i.e. StyleUtils.getBackgroundAndBorderStyle(theme.componentBG)
  • If the PR modifies code that runs when editing or sending messages, I tested and verified there is no unexpected behavior for all supported markdown - URLs, single line code, code blocks, quotes, headings, bold, strikethrough, and italic.
  • If the PR modifies a generic component, I tested and verified that those changes do not break usages of that component in the rest of the App (i.e. if a shared library or component like Avatar is modified, I verified that Avatar is working as expected in all cases)
  • If the PR modifies a component related to any of the existing Storybook stories, I tested and verified all stories for that component are still working as expected.
  • If the PR modifies a component or page that can be accessed by a direct deeplink, I verified that the code functions as expected when the deeplink is used - from a logged in and logged out account.
  • If the PR modifies the UI (e.g. new buttons, new UI components, changing the padding/spacing/sizing, moving components, etc) or modifies the form input styles:
    • I verified that all the inputs inside a form are aligned with each other.
    • I added Design label and/or tagged @Expensify/design so the design team can review the changes.
  • If a new page is added, I verified it's using the ScrollView component to make it scrollable when more elements are added to the page.
  • For any bug fix or new feature in this PR, I verified that sufficient unit tests are included to prevent regressions in this flow.
  • If the main branch was merged into this PR after a review, I tested again and verified the outcome was still expected according to the Test steps.
  • I have checked off every checkbox in the PR reviewer checklist, including those that don't apply to this PR.

Screenshots/Videos

Android: HybridApp
01_Android_Native.mp4
Android: mWeb Chrome
02_Android_Chrome.mp4
iOS: HybridApp
03_iOS_Native.mp4
iOS: mWeb Safari
04_iOS_Safari.mp4
MacOS: Chrome / Safari

N/A

Copy link
Contributor

@Ollyws Ollyws left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM.
With regard to 'collapsed' being announced twice on Android mWeb this is an upstream limitation and the only alternative would be to have 'collapsed' not be anounced atall on iOS Safari so we have gone with the safest option, albeit imperfect.

@melvin-bot melvin-bot bot requested a review from JS00001 March 19, 2026 19:49
@rushatgabhane
Copy link
Member

thank you for exploring that, I agree with where we've landed

@JS00001 JS00001 merged commit b5cea63 into Expensify:main Mar 20, 2026
34 checks passed
@github-actions
Copy link
Contributor

🚧 @JS00001 has triggered a test Expensify/App build. You can view the workflow run here.

@OSBotify
Copy link
Contributor

✋ This PR was not deployed to staging yet because QA is ongoing. It will be automatically deployed to staging after the next production release.

@OSBotify
Copy link
Contributor

🚀 Deployed to staging by https://github.com/JS00001 in version: 9.3.42-0 🚀

platform result
🕸 web 🕸 success ✅
🤖 android 🤖 success ✅
🍎 iOS 🍎 success ✅

Bundle Size Analysis (Sentry):

@OSBotify
Copy link
Contributor

🚀 Deployed to production by https://github.com/grgia in version: 9.3.42-3 🚀

platform result
🕸 web 🕸 success ✅
🤖 android 🤖 success ✅
🍎 iOS 🍎 success ✅

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

7 participants