File tree Expand file tree Collapse file tree 2 files changed +23
-0
lines changed Expand file tree Collapse file tree 2 files changed +23
-0
lines changed Original file line number Diff line number Diff line change
1
+ import * as React from 'react' ;
2
+ import Rating from '@material-ui/core/Rating' ;
3
+
4
+ export default function FocusVisibleRating ( ) {
5
+ return < Rating name = "no-value-precise" precision = { 0.5 } value = { null } /> ;
6
+ }
Original file line number Diff line number Diff line change @@ -99,6 +99,23 @@ async function main() {
99
99
await takeScreenshot ( { testcase, route : '/regression-Rating/FocusVisibleRating2' } ) ;
100
100
await page . keyboard . press ( 'ArrowLeft' ) ;
101
101
await takeScreenshot ( { testcase, route : '/regression-Rating/FocusVisibleRating3' } ) ;
102
+ await page . keyboard . press ( 'Tab' ) ;
103
+ await takeScreenshot ( { testcase, route : '/regression-Rating/FocusVisibleRating4' } ) ;
104
+ await page . keyboard . press ( 'ArrowRight' ) ;
105
+ await takeScreenshot ( { testcase, route : '/regression-Rating/FocusVisibleRating3' } ) ;
106
+ await page . keyboard . press ( 'ArrowLeft' ) ;
107
+ await takeScreenshot ( { testcase, route : '/regression-Rating/FocusVisibleRating3' } ) ;
108
+ } ) ;
109
+
110
+ it ( 'should handle focus-visible with precise ratings correctly' , async ( ) => {
111
+ const index = routes . findIndex (
112
+ ( route ) => route === '/regression-Rating/PreciseFocusVisibleRating' ,
113
+ ) ;
114
+ const testcase = await renderFixture ( index ) ;
115
+ await page . keyboard . press ( 'Tab' ) ;
116
+ await takeScreenshot ( { testcase, route : '/regression-Rating/PreciseFocusVisibleRating2' } ) ;
117
+ await page . keyboard . press ( 'ArrowRight' ) ;
118
+ await takeScreenshot ( { testcase, route : '/regression-Rating/PreciseFocusVisibleRating3' } ) ;
102
119
} ) ;
103
120
} ) ;
104
121
You can’t perform that action at this time.
0 commit comments