π End-to-end encrypted cloud for everything.
Dart 2faandroidauthye2eeencryptionend-to-end-encryptionfluttergolanggoogle-photosgoogle-photos-alternativeiosopensourcephotosprivacyprivacy-toolstypescriptzero-knowledge
Revert "[web][photos] Apply global scrollbar style to all scroll areas"
Aswin Asok95362bf4837c
diff --git a/web/apps/photos/src/styles/global.css b/web/apps/photos/src/styles/global.cssindex 61852886f0..c1ef2319f7 100644--- a/web/apps/photos/src/styles/global.css+++ b/web/apps/photos/src/styles/global.css@@ -13,12 +13,15 @@ body {height: 100%;}-:where(*) {+:where(:not([data-custom-scrollbar], [data-custom-scrollbar] *)) {scrollbar-width: thin;scrollbar-color: transparent transparent;}-:where(*:hover, *:focus-within) {+:where(:not([data-custom-scrollbar], [data-custom-scrollbar] *)):is(+ :hover,+ :focus-within+) {scrollbar-color: color-mix(in srgb,var(--mui-palette-text-base) 20%,@@ -27,27 +30,44 @@ body {transparent;}+:where([data-custom-scrollbar]) {+ scrollbar-color: auto;+}+@supports selector(::-webkit-scrollbar) {- :where(*) {+ :where(:not([data-custom-scrollbar], [data-custom-scrollbar] *)),+ :where(:not([data-custom-scrollbar], [data-custom-scrollbar] *)):is(+ :hover,+ :focus-within+ ) {scrollbar-width: auto;scrollbar-color: auto;}- :where(*)::-webkit-scrollbar {+ :where(+ :not([data-custom-scrollbar], [data-custom-scrollbar] *)+ )::-webkit-scrollbar {width: 4px;height: 4px;}- :where(*)::-webkit-scrollbar-track {+ :where(+ :not([data-custom-scrollbar], [data-custom-scrollbar] *)+ )::-webkit-scrollbar-track {background-color: transparent;}- :where(*)::-webkit-scrollbar-thumb {+ :where(+ :not([data-custom-scrollbar], [data-custom-scrollbar] *)+ )::-webkit-scrollbar-thumb {background-color: transparent;border-radius: 4px;}- :where(*:hover, *:focus-within)::-webkit-scrollbar-thumb {+ :where(:not([data-custom-scrollbar], [data-custom-scrollbar] *)):is(+ :hover,+ :focus-within+ )::-webkit-scrollbar-thumb {background-color: color-mix(in srgb,var(--mui-palette-text-base) 20%,@@ -55,7 +75,9 @@ body {);}- :where(*)::-webkit-scrollbar-button {+ :where(+ :not([data-custom-scrollbar], [data-custom-scrollbar] *)+ )::-webkit-scrollbar-button {display: none;}}diff --git a/web/packages/gallery/components/upload-progress/UploadProgressDetails.tsx b/web/packages/gallery/components/upload-progress/UploadProgressDetails.tsxindex 4419961fe5..b1f8a89189 100644--- a/web/packages/gallery/components/upload-progress/UploadProgressDetails.tsx+++ b/web/packages/gallery/components/upload-progress/UploadProgressDetails.tsx@@ -1,6 +1,5 @@import { Box, Button, Stack, Typography, type Theme } from "@mui/material";import type { SystemStyleObject } from "@mui/system";-import { appName } from "ente-base/app";import { basename } from "ente-base/file-name";import { t } from "i18next";import { useState } from "react";@@ -161,7 +160,7 @@ export function UploadProgressDetails() {{t("failed_uploads_hint")}</Typography>)}- <Box sx={uploadRowsSx(isDone)}>+ <Box sx={uploadRowsSx(isDone)} data-custom-scrollbar>{activeStat == "inProgress" ? (inProgressUploads.length ? (inProgressUploads.map(@@ -376,25 +375,23 @@ const uploadRowsSx =minHeight: minRowsListHeight,maxHeight: isDone ? doneRowsListHeight : maxRowsListHeight,overflowY: "auto",- ...(appName !== "photos" && {+ "&, & .upload-file-list": {+ scrollbarWidth: "thin",+ scrollbarColor: "rgba(0 0 0 / 0.2) transparent",+ },+ "&::-webkit-scrollbar, & .upload-file-list::-webkit-scrollbar": {+ width: 6,+ },+ "&::-webkit-scrollbar-track, & .upload-file-list::-webkit-scrollbar-track":+ { background: "transparent" },+ "&::-webkit-scrollbar-thumb, & .upload-file-list::-webkit-scrollbar-thumb":+ { borderRadius: "8px", backgroundColor: "rgba(0 0 0 / 0.2)" },+ ...theme.applyStyles("dark", {"&, & .upload-file-list": {- scrollbarWidth: "thin",- scrollbarColor: "rgba(0 0 0 / 0.2) transparent",+ scrollbarColor: "rgba(255 255 255 / 0.2) transparent",},- "&::-webkit-scrollbar, & .upload-file-list::-webkit-scrollbar": {- width: 6,- },- "&::-webkit-scrollbar-track, & .upload-file-list::-webkit-scrollbar-track":- { background: "transparent" },"&::-webkit-scrollbar-thumb, & .upload-file-list::-webkit-scrollbar-thumb":- { borderRadius: "8px", backgroundColor: "rgba(0 0 0 / 0.2)" },- ...theme.applyStyles("dark", {- "&, & .upload-file-list": {- scrollbarColor: "rgba(255 255 255 / 0.2) transparent",- },- "&::-webkit-scrollbar-thumb, & .upload-file-list::-webkit-scrollbar-thumb":- { backgroundColor: "rgba(255 255 255 / 0.2)" },- }),+ { backgroundColor: "rgba(255 255 255 / 0.2)" },}),});const failedUploadsHintSx = { mt: 2, px: 1.5, ...mutedCaptionSx };diff --git a/web/packages/gallery/components/viewer/CommentsSidebar.tsx b/web/packages/gallery/components/viewer/CommentsSidebar.tsxindex ba02314e00..5d197aa696 100644--- a/web/packages/gallery/components/viewer/CommentsSidebar.tsx+++ b/web/packages/gallery/components/viewer/CommentsSidebar.tsx@@ -12,7 +12,6 @@ import {TextField,Typography,} from "@mui/material";-import { appName } from "ente-base/app";import type { ModalVisibilityProps } from "ente-base/components/utils/modal";import log from "ente-base/log";import {@@ -1151,7 +1150,10 @@ export const CommentsSidebar: React.FC<CommentsSidebarProps> = ({</CloseButton></Header>- <CommentsContainer ref={commentsContainerRef}>+ <CommentsContainer+ ref={commentsContainerRef}+ data-custom-scrollbar+ >{loading ? (<LoadingContainer><CircularProgress size={32} />@@ -1457,7 +1459,7 @@ export const CommentsSidebar: React.FC<CommentsSidebarProps> = ({</ReplyingToContent></ReplyingToBar>)}- <InputWrapper>+ <InputWrapper data-custom-scrollbar><StyledTextFieldfullWidthmultiline@@ -1658,21 +1660,19 @@ const CommentsContainer = styled(Box)(({ theme }) => ({position: "relative",display: "flex",flexDirection: "column-reverse",- ...(appName !== "photos" && {- "&::-webkit-scrollbar": { width: "6px" },- "&::-webkit-scrollbar-track": { background: "transparent" },+ "&::-webkit-scrollbar": { width: "6px" },+ "&::-webkit-scrollbar-track": { background: "transparent" },+ "&::-webkit-scrollbar-thumb": {+ background: "rgba(0, 0, 0, 0.2)",+ borderRadius: "3px",+ },+ scrollbarWidth: "thin",+ scrollbarColor: "rgba(0, 0, 0, 0.2) transparent",+ ...theme.applyStyles("dark", {"&::-webkit-scrollbar-thumb": {- background: "rgba(0, 0, 0, 0.2)",- borderRadius: "3px",+ background: "rgba(255, 255, 255, 0.2)",},- scrollbarWidth: "thin",- scrollbarColor: "rgba(0, 0, 0, 0.2) transparent",- ...theme.applyStyles("dark", {- "&::-webkit-scrollbar-thumb": {- background: "rgba(255, 255, 255, 0.2)",- },- scrollbarColor: "rgba(255, 255, 255, 0.2) transparent",- }),+ scrollbarColor: "rgba(255, 255, 255, 0.2) transparent",}),}));@@ -1802,27 +1802,23 @@ const InputWrapper = styled(Box)(({ theme }) => ({padding: "8px 48px 8px 16px",maxHeight: "300px",overflow: "auto",- ...(appName !== "photos" && {- "&::-webkit-scrollbar": { width: "8px" },- "&::-webkit-scrollbar-track": { background: "transparent" },+ "&::-webkit-scrollbar": { width: "8px" },+ "&::-webkit-scrollbar-track": { background: "transparent" },+ "&::-webkit-scrollbar-thumb": {+ background: "rgba(0, 0, 0, 0.3)",+ borderRadius: "4px",+ },+ "&::-webkit-scrollbar-thumb:hover": { background: "rgba(0, 0, 0, 0.5)" },+ scrollbarWidth: "thin",+ scrollbarColor: "rgba(0, 0, 0, 0.3) transparent",+ ...theme.applyStyles("dark", {"&::-webkit-scrollbar-thumb": {- background: "rgba(0, 0, 0, 0.3)",- borderRadius: "4px",+ background: "rgba(255, 255, 255, 0.3)",},"&::-webkit-scrollbar-thumb:hover": {- background: "rgba(0, 0, 0, 0.5)",+ background: "rgba(255, 255, 255, 0.5)",},- scrollbarWidth: "thin",- scrollbarColor: "rgba(0, 0, 0, 0.3) transparent",- ...theme.applyStyles("dark", {- "&::-webkit-scrollbar-thumb": {- background: "rgba(255, 255, 255, 0.3)",- },- "&::-webkit-scrollbar-thumb:hover": {- background: "rgba(255, 255, 255, 0.5)",- },- scrollbarColor: "rgba(255, 255, 255, 0.3) transparent",- }),+ scrollbarColor: "rgba(255, 255, 255, 0.3) transparent",}),}));diff --git a/web/packages/gallery/components/viewer/LikeAlbumSelectorModal.tsx b/web/packages/gallery/components/viewer/LikeAlbumSelectorModal.tsxindex b896dd2e76..f8ee4d4de8 100644--- a/web/packages/gallery/components/viewer/LikeAlbumSelectorModal.tsx+++ b/web/packages/gallery/components/viewer/LikeAlbumSelectorModal.tsx@@ -1,6 +1,5 @@import CloseIcon from "@mui/icons-material/Close";import { Box, Dialog, IconButton, styled, Typography } from "@mui/material";-import { appName } from "ente-base/app";import type { ModalVisibilityProps } from "ente-base/components/utils/modal";import { t } from "i18next";import React from "react";@@ -193,7 +192,7 @@ export const LikeAlbumSelectorModal: React.FC<LikeAlbumSelectorModalProps> = ({</LikeAllButton></AlbumsHeader>- <AlbumsList>+ <AlbumsList data-custom-scrollbar>{albums.map((album) => {const isLiked = likedAlbumIDs.has(album.id);return (@@ -353,18 +352,16 @@ const AlbumsList = styled(Box)(({ theme }) => ({padding: "0 12px 12px 12px",overflowY: "auto",maxHeight: 241,- ...(appName !== "photos" && {- "&::-webkit-scrollbar": { width: 6 },- "&::-webkit-scrollbar-track": { background: "transparent" },+ "&::-webkit-scrollbar": { width: 6 },+ "&::-webkit-scrollbar-track": { background: "transparent" },+ "&::-webkit-scrollbar-thumb": {+ background: "rgba(0, 0, 0, 0.2)",+ borderRadius: 3,+ },+ ...theme.applyStyles("dark", {"&::-webkit-scrollbar-thumb": {- background: "rgba(0, 0, 0, 0.2)",- borderRadius: 3,+ background: "rgba(255, 255, 255, 0.2)",},- ...theme.applyStyles("dark", {- "&::-webkit-scrollbar-thumb": {- background: "rgba(255, 255, 255, 0.2)",- },- }),}),}));diff --git a/web/packages/gallery/components/viewer/LikesSidebar.tsx b/web/packages/gallery/components/viewer/LikesSidebar.tsxindex b580497d16..ecdbdd157c 100644--- a/web/packages/gallery/components/viewer/LikesSidebar.tsx+++ b/web/packages/gallery/components/viewer/LikesSidebar.tsx@@ -9,7 +9,6 @@ import {styled,Typography,} from "@mui/material";-import { appName } from "ente-base/app";import type { ModalVisibilityProps } from "ente-base/components/utils/modal";import log from "ente-base/log";import { useResolvedContactAvatar } from "ente-contacts";@@ -550,7 +549,7 @@ export const LikesSidebar: React.FC<LikesSidebarProps> = ({</CloseButton></Header>- <LikersContainer>+ <LikersContainer data-custom-scrollbar>{loading ? (<LoadingContainer><CircularProgress size={32} />@@ -714,21 +713,19 @@ const LikersContainer = styled(Box)(({ theme }) => ({overflow: "auto",marginRight: -24,paddingRight: 24,- ...(appName !== "photos" && {- "&::-webkit-scrollbar": { width: "6px" },- "&::-webkit-scrollbar-track": { background: "transparent" },+ "&::-webkit-scrollbar": { width: "6px" },+ "&::-webkit-scrollbar-track": { background: "transparent" },+ "&::-webkit-scrollbar-thumb": {+ background: "rgba(0, 0, 0, 0.2)",+ borderRadius: "3px",+ },+ scrollbarWidth: "thin",+ scrollbarColor: "rgba(0, 0, 0, 0.2) transparent",+ ...theme.applyStyles("dark", {"&::-webkit-scrollbar-thumb": {- background: "rgba(0, 0, 0, 0.2)",- borderRadius: "3px",+ background: "rgba(255, 255, 255, 0.2)",},- scrollbarWidth: "thin",- scrollbarColor: "rgba(0, 0, 0, 0.2) transparent",- ...theme.applyStyles("dark", {- "&::-webkit-scrollbar-thumb": {- background: "rgba(255, 255, 255, 0.2)",- },- scrollbarColor: "rgba(255, 255, 255, 0.2) transparent",- }),+ scrollbarColor: "rgba(255, 255, 255, 0.2) transparent",}),}));