Skip to content

armgit / ente

Public Imported from GitHub
0

πŸ’š End-to-end encrypted cloud for everything.

[photos][web] Expose current place to screen readers

AswinAsok53ff3f18e7cb
diff --git a/web/apps/photos/src/components/gallery/PlacesList.tsx b/web/apps/photos/src/components/gallery/PlacesList.tsx
index f48243f050..a5245bc68e 100644
--- a/web/apps/photos/src/components/gallery/PlacesList.tsx
+++ b/web/apps/photos/src/components/gallery/PlacesList.tsx
@@ -55,6 +55,7 @@ export const PlacesList = ({
<Stack sx={{ flex: 1, minHeight: 0, gap: "8px" }}>
<ListItemButton
selected={!selectedPlace}
+ aria-current={!selectedPlace ? "true" : undefined}
onClick={() => onSelectPlace(undefined)}
sx={{
...placeRowSx,
@@ -111,6 +112,12 @@ export const PlacesList = ({
selectedPlace?.latitude === city.latitude &&
selectedPlace.longitude === city.longitude
}
+ aria-current={
+ selectedPlace?.latitude === city.latitude &&
+ selectedPlace.longitude === city.longitude
+ ? "true"
+ : undefined
+ }
onClick={() =>
onSelectPlace({
latitude: city.latitude,