(index: number, mode: 'flat' | 'elevated')
| 18 | const elevationValues = isV3 ? Array.from({ length: 6 }) : v2Elevation; |
| 19 | |
| 20 | const renderSurface = (index: number, mode: 'flat' | 'elevated') => ( |
| 21 | <Surface |
| 22 | key={index} |
| 23 | style={[ |
| 24 | styles.surface, |
| 25 | isV3 ? styles.v3Surface : { elevation: v2Elevation[index] }, |
| 26 | ]} |
| 27 | mode={mode} |
| 28 | {...(isV3 && { elevation: index as MD3Elevation })} |
| 29 | > |
| 30 | <Text variant="bodyLarge"> |
| 31 | {isV3 |
| 32 | ? `Elevation ${index === 1 ? '(default)' : ''} ${index}` |
| 33 | : `${elevationValues[index]}`} |
| 34 | </Text> |
| 35 | </Surface> |
| 36 | ); |
| 37 | |
| 38 | return ( |
| 39 | <ScreenWrapper> |
no outgoing calls
no test coverage detected
searching dependent graphs…