Comments (2)
@wachunei please add correct steps to reproduce
from metamask-mobile.
I have more details about the issue and an example to reproduce.
The issue is: Button components base component ButtonBase
does not have default props for accessibility, these are accessibilityRole: 'button'
and accessible: true
.
Currently a simplified snapshot of every Button of the component library would look like this:
<TouchableOpacity>
<Text
accessibilityRole="text"
>
Click me!
</Text>
</TouchableOpacity>
This won't work with tests like screen.getByRole('button', { name: 'Click me!' })
because the button does not have the props.
This is a working example snapshot:
<TouchableOpacity
accessibilityRole="button"
accessible={true}
>
<Text
accessibilityRole="text"
>
Click me!
</Text>
</TouchableOpacity>
In the branch temp/button-a11y-tests
I have added this file app/component-library/components/Buttons/Button/foundation/ButtonBase/ButtonBase.rntl.test.tsx
with examples of failing and passing tests.
The file includes a comparison with the deprecated StyledButton
component that behaves correctly regarding a11y tests.
The tests include snapshots to compare the default rendering of the props missing https://github.com/MetaMask/metamask-mobile/blob/temp/button-a11y-tests/app/component-library/components/Buttons/Button/foundation/ButtonBase/__snapshots__/ButtonBase.rntl.test.tsx.snap
from metamask-mobile.
Related Issues (20)
- AddressBookController upgrade from v4 to v6
- PhishingController upgrade from v9 to v12
- SmartTransactionsController upgrade from v11 to v13
- ControllerUtils upgrade from v10 to v11
- [Design quality]: Update the mobile header to the design system header
- Error: Must specify a valid combination of id, origin, and type.
- [Sentry] Error: KeyringController - Cannot unlock without a previous vault.
- [Sentry] Error: User rejected the request. HOT 2
- [Sentry] Error: Trouble reaching the Branch servers, please try again shortly.
- [Sentry] Error: Cannot update security alert response as no transaction metadata found
- AxiosError: Network Error
- [Bug] Unspecified error displayed when adding multiple HD path Ledger accounts into Account list HOT 3
- Error: The address: ** is not imported
- Error: No matching key. history: 1725534913171707
- onUnhandled
- Error: Permissions request with id "f_KQS32uLuf_RQfXSWJZH" not found.
- [Bug]: Some metametrics events are sent with an anonymous ID when they should have user ID HOT 1
- [Bug]: Investigate and Fix failing E2E Tests in accounts pipeline HOT 1
- E2E: Investigate API spec flakiness
- Technical research: Identify areas that affect time from Login to Wallet view on Android
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from metamask-mobile.