π End-to-end encrypted cloud for everything.
Dart 2faandroidauthye2eeencryptionend-to-end-encryptionfluttergolanggoogle-photosgoogle-photos-alternativeiosopensourcephotosprivacyprivacy-toolstypescriptzero-knowledge
Move
Manav Rathi21c6e1eae214
diff --git a/web/apps/photos/src/pages/_app.tsx b/web/apps/photos/src/pages/_app.tsxindex 67f5fb4a4a..72c86fe2a6 100644--- a/web/apps/photos/src/pages/_app.tsx+++ b/web/apps/photos/src/pages/_app.tsx@@ -15,7 +15,6 @@ import {updateAvailableForDownloadDialogAttributes,updateReadyToInstallDialogAttributes,} from "@/new/photos/components/utils/download";-import { useIsOffline } from "@/new/photos/components/utils/use-is-offline";import { useLoadingBar } from "@/new/photos/components/utils/use-loading-bar";import { photosDialogZIndex } from "@/new/photos/components/utils/z-index";import { runMigrations } from "@/new/photos/services/migration";@@ -59,7 +58,6 @@ const App: React.FC<AppProps> = ({ Component, pageProps }) => {const [notificationAttributes, setNotificationAttributes] =useState<NotificationAttributes>(null);- const isOffline = useIsOffline();const isI18nReady = useSetupI18n();const { showMiniDialog, miniDialogProps } = useAttributedMiniDialog();const { loadingBarRef, showLoadingBar, hideLoadingBar } = useLoadingBar();@@ -203,9 +201,6 @@ const App: React.FC<AppProps> = ({ Component, pageProps }) => {<ThemeProvider theme={getTheme(themeColor, "photos")}><CssBaseline enableColorScheme />- <OfflineMessageContainer>- {isI18nReady && isOffline && t("offline_message")}- </OfflineMessageContainer><LoadingBar color="#51cd7c" ref={loadingBarRef} /><AttributedMiniDialog@@ -230,14 +225,6 @@ const App: React.FC<AppProps> = ({ Component, pageProps }) => {export default App;-const OfflineMessageContainer = styled("div")`- background-color: #111;- padding: 0;- font-size: 14px;- text-align: center;- line-height: 32px;-`;-const redirectToFamilyPortal = () =>void getFamilyPortalRedirectURL().then((url) => {window.location.href = url;diff --git a/web/apps/photos/src/pages/gallery.tsx b/web/apps/photos/src/pages/gallery.tsxindex 2cfa437bb3..6b9c35f287 100644--- a/web/apps/photos/src/pages/gallery.tsx+++ b/web/apps/photos/src/pages/gallery.tsx@@ -27,6 +27,7 @@ import {useGalleryReducer,type GalleryBarMode,} from "@/new/photos/components/gallery/reducer";+import { useIsOffline } from "@/new/photos/components/utils/use-is-offline";import { usePeopleStateSnapshot } from "@/new/photos/components/utils/use-snapshot";import { shouldShowWhatsNew } from "@/new/photos/services/changelog";import {@@ -183,6 +184,7 @@ const Page: React.FC = () => {logout,} = useAppContext();+ const isOffline = useIsOffline();const [state, dispatch] = useGalleryReducer();const [isFirstLoad, setIsFirstLoad] = useState(false);@@ -965,6 +967,7 @@ const Page: React.FC = () => {/>)}</NavbarBase>+ {isOffline && <OfflineMessage />}<GalleryBarAndListHeader{...{@@ -1134,6 +1137,15 @@ const Page: React.FC = () => {export default Page;+const OfflineMessage: React.FC = () => (+ <Typography+ variant="small"+ sx={{ bgcolor: "background.paper", p: 2, mb: 1, textAlign: "center" }}+ >+ {t("offline_message")}+ </Typography>+);+/*** Preload all three variants of a responsive image.*/