π End-to-end encrypted cloud for everything.
Dart 2faandroidauthye2eeencryptionend-to-end-encryptionfluttergolanggoogle-photosgoogle-photos-alternativeiosopensourcephotosprivacyprivacy-toolstypescriptzero-knowledge
Improve accessibility and keyboard access
Manav Rathif0e467830718
diff --git a/web/apps/photos/src/components/Sidebar/SubscriptionCard.tsx b/web/apps/photos/src/components/Sidebar/SubscriptionCard.tsxindex 513a0ac994..d72c0972b9 100644--- a/web/apps/photos/src/components/Sidebar/SubscriptionCard.tsx+++ b/web/apps/photos/src/components/Sidebar/SubscriptionCard.tsx@@ -1,5 +1,6 @@import { Overlay } from "@/base/components/containers";import type { ButtonishProps } from "@/base/components/mui";+import { UnstyledButton } from "@/new/photos/components/UnstyledButton";import type { UserDetails } from "@/new/photos/services/user-details";import {familyUsage,@@ -56,7 +57,11 @@ export const SubscriptionCard: React.FC<SubscriptionCardProps> = ({const BackgroundOverlay: React.FC = () => (<img- style={{ aspectRatio: "2/1" }}+ style={{+ aspectRatio: "2/1",+ // Remove extra whitespace below the image.+ verticalAlign: "bottom",+ }}width="100%"src="/images/subscription-card-background/1x.png"srcSet="/images/subscription-card-background/2x.png 2x, /images/subscription-card-background/3x.png 3x"@@ -64,19 +69,29 @@ const BackgroundOverlay: React.FC = () => ();const ClickOverlay: React.FC<ButtonishProps> = ({ onClick }) => (- <Overlay- sx={{- display: "flex",- justifyContent: "flex-end",- alignItems: "center",- cursor: "pointer",- }}- onClick={onClick}- >+ <ClickOverlayButton onClick={onClick}><ChevronRightIcon />- </Overlay>+ </ClickOverlayButton>);+/** A mixin of UnstyledButton and {@link Overlay}, plus custom styling. */+const ClickOverlayButton = styled(UnstyledButton)`+ /* Overlay */+ position: absolute;+ width: 100%;+ height: 100%;+ top: 0;+ left: 0;++ /* Position the chevron at the middle right */+ display: flex;+ justify-content: flex-end;+ align-items: center;++ /* Reset the button color */+ color: inherit;+`;+interface SubscriptionCardContentOverlayProps {userDetails: UserDetails;}