-
Notifications
You must be signed in to change notification settings - Fork 219
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add compose accessibility support #702
Conversation
3060379
to
51e434f
Compare
gradlew.bat
Outdated
@@ -1,92 +1,92 @@ | |||
@rem |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nit: not sure why this is in here. contents are exactly the same.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This likely needs a rebase after this PR merging: #721
9642d40
to
5c0bee1
Compare
paparazzi/paparazzi/src/main/java/app/cash/paparazzi/accessibility/AccessibilityState.kt
Outdated
Show resolved
Hide resolved
...zzi/paparazzi/src/main/java/app/cash/paparazzi/accessibility/AccessibilityRenderExtension.kt
Show resolved
Hide resolved
...c/test/projects/complex-a11y/src/test/java/app/cash/paparazzi/plugin/test/ComplexA11yTest.kt
Outdated
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
Thanks for taking this over, much better solution.
|
||
if (this is AbstractComposeView) { | ||
// ComposeView creates a child view `AndroidComposeView` for view root for test. | ||
val viewRoot = getChildAt(0) as? ViewRootForTest |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice. This is a much better solution.
gradlew.bat
Outdated
@@ -1,92 +1,92 @@ | |||
@rem |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This likely needs a rebase after this PR merging: #721
...i/paparazzi-gradle-plugin/src/test/projects/complex-a11y/src/test/resources/complex_a11y.png
Outdated
Show resolved
Hide resolved
d8ef57a
to
822dcdd
Compare
d59c3d1
to
b31e883
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Mind addressing feedback, squashing, and pinging for another review?
sample/src/test/java/app/cash/paparazzi/sample/ComposeA11yTest.kt
Outdated
Show resolved
Hide resolved
...paparazzi/src/test/java/app/cash/paparazzi/accessibility/AccessibilityRenderExtensionTest.kt
Outdated
Show resolved
Hide resolved
paparazzi/paparazzi/src/main/java/app/cash/paparazzi/accessibility/AccessibilityRowView.kt
Outdated
Show resolved
Hide resolved
paparazzi/paparazzi/src/main/java/app/cash/paparazzi/accessibility/AccessibilityRowView.kt
Outdated
Show resolved
Hide resolved
...zzi/paparazzi/src/main/java/app/cash/paparazzi/accessibility/AccessibilityRenderExtension.kt
Outdated
Show resolved
Hide resolved
paparazzi/paparazzi/src/main/java/app/cash/paparazzi/Paparazzi.kt
Outdated
Show resolved
Hide resolved
paparazzi/paparazzi/src/main/java/app/cash/paparazzi/RenderExtension.kt
Outdated
Show resolved
Hide resolved
.../paparazzi/src/main/java/app/cash/paparazzi/accessibility/AccessibilityOverlayDetailsView.kt
Outdated
Show resolved
Hide resolved
...parazzi/src/test/snapshots/images/app.cash.paparazzi_InstantAnimationsRuleTest_happyPath.png
Outdated
Show resolved
Hide resolved
fdf5c6f
to
d2fd878
Compare
paparazzi/paparazzi/src/main/java/app/cash/paparazzi/Paparazzi.kt
Outdated
Show resolved
Hide resolved
paparazzi/paparazzi/src/main/java/app/cash/paparazzi/Paparazzi.kt
Outdated
Show resolved
Hide resolved
paparazzi/paparazzi/src/main/java/app/cash/paparazzi/Paparazzi.kt
Outdated
Show resolved
Hide resolved
paparazzi/paparazzi/src/main/java/app/cash/paparazzi/Paparazzi.kt
Outdated
Show resolved
Hide resolved
paparazzi/paparazzi/src/main/java/app/cash/paparazzi/Paparazzi.kt
Outdated
Show resolved
Hide resolved
paparazzi/paparazzi/src/main/java/app/cash/paparazzi/Paparazzi.kt
Outdated
Show resolved
Hide resolved
paparazzi/paparazzi/src/main/java/app/cash/paparazzi/Paparazzi.kt
Outdated
Show resolved
Hide resolved
paparazzi/paparazzi/src/main/java/app/cash/paparazzi/Paparazzi.kt
Outdated
Show resolved
Hide resolved
d1c99d7
to
8275ecb
Compare
paparazzi/paparazzi/src/main/java/app/cash/paparazzi/accessibility/AccessibilityOverlayView.kt
Outdated
Show resolved
Hide resolved
.../paparazzi/src/main/java/app/cash/paparazzi/accessibility/AccessibilityOverlayDetailsView.kt
Outdated
Show resolved
Hide resolved
8275ecb
to
995e3aa
Compare
b52c80d
to
3c944b1
Compare
...zzi/paparazzi/src/main/java/app/cash/paparazzi/accessibility/AccessibilityRenderExtension.kt
Outdated
Show resolved
Hide resolved
...zzi/paparazzi/src/main/java/app/cash/paparazzi/accessibility/AccessibilityRenderExtension.kt
Outdated
Show resolved
Hide resolved
...zzi/paparazzi/src/main/java/app/cash/paparazzi/accessibility/AccessibilityRenderExtension.kt
Outdated
Show resolved
Hide resolved
...zzi/paparazzi/src/main/java/app/cash/paparazzi/accessibility/AccessibilityRenderExtension.kt
Outdated
Show resolved
Hide resolved
...zzi/paparazzi/src/main/java/app/cash/paparazzi/accessibility/AccessibilityRenderExtension.kt
Outdated
Show resolved
Hide resolved
...razzi/paparazzi-gradle-plugin/src/test/java/app/cash/paparazzi/gradle/PaparazziPluginTest.kt
Outdated
Show resolved
Hide resolved
...razzi/paparazzi-gradle-plugin/src/test/java/app/cash/paparazzi/gradle/PaparazziPluginTest.kt
Outdated
Show resolved
Hide resolved
...razzi/paparazzi-gradle-plugin/src/test/java/app/cash/paparazzi/gradle/PaparazziPluginTest.kt
Outdated
Show resolved
Hide resolved
sample/src/test/java/app/cash/paparazzi/sample/ComposeA11yTest.kt
Outdated
Show resolved
Hide resolved
paparazzi/paparazzi/src/test/resources/accessibility-new-view.png
Outdated
Show resolved
Hide resolved
Awesome stuff, thanks for sticking with this and seeing it through! |
ce34a72
to
7464ad7
Compare
8b66ffc
to
dee6fb1
Compare
dee6fb1
to
e526406
Compare
* Add compose accessibility support * Cleanup accessibility colors for compose snapshot * Fix view lifecycle owner issue * Cleanup * Fix compose artifacts included in paparazzi module * Cleanup + simplification * More cleanup from feedback --------- Co-authored-by: Yuri Schimke <yuri@schimke.ee>
cc yschimke
This is a little simpler implementation of compose support for the AccessibilityRenderExtension. Added plugin test the ensures that this works for fully compose ui views, fully legacy views, and a mix of both.
Most of this work is modeled off of #555 with a simplification of API surface.