1
0
mirror of https://github.com/laurent22/joplin.git synced 2024-12-24 10:27:10 +02:00

Mobile: Accessibility: Search screen: Hide the progress bar from accessibility tools when invisible (#11431)

This commit is contained in:
Henry Heino 2024-11-22 02:48:08 -08:00 committed by GitHub
parent 81ec3eb5e2
commit 1dd02f1746
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -100,10 +100,11 @@ const SearchResults: React.FC<Props> = props => {
// Don't show the progress bar immediately, only show if the search // Don't show the progress bar immediately, only show if the search
// is taking some time. // is taking some time.
const longRunning = useIsLongRunning(isPending); const longRunning = useIsLongRunning(isPending);
const progressVisible = longRunning;
// To have the correct height on web, the progress bar needs to be wrapped: // To have the correct height on web, the progress bar needs to be wrapped:
const progressBar = <View> const progressBar = <View aria-hidden={!progressVisible}>
<ProgressBar indeterminate={true} visible={longRunning}/> <ProgressBar indeterminate={true} visible={progressVisible}/>
</View>; </View>;
return ( return (