Skip to content

armgit / ente

Public Imported from GitHub
0

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

[photos][web] Check changelog when gallery loads

AswinAsok45f65f7aa003
diff --git a/web/apps/photos/src/components/DesktopWhatsNew.tsx b/web/apps/photos/src/components/DesktopWhatsNew.tsx
index 7adfcbebb8..051cb158ca 100644
--- a/web/apps/photos/src/components/DesktopWhatsNew.tsx
+++ b/web/apps/photos/src/components/DesktopWhatsNew.tsx
@@ -4,14 +4,12 @@ import log from "ente-base/log";
import { useEffect } from "react";
import { WhatsNew } from "./WhatsNew";
-export const DesktopWhatsNew: React.FC<{ enabled: boolean }> = ({
- enabled,
-}) => {
+export const DesktopWhatsNew: React.FC = () => {
const { show, props } = useModalVisibility();
useEffect(() => {
const electron = globalThis.electron;
- if (!enabled || !electron) return;
+ if (!electron) return;
let cancelled = false;
@@ -26,7 +24,7 @@ export const DesktopWhatsNew: React.FC<{ enabled: boolean }> = ({
return () => {
cancelled = true;
};
- }, [enabled, show]);
+ }, [show]);
- return <WhatsNew {...props} open={enabled && props.open} />;
+ return <WhatsNew {...props} />;
};
diff --git a/web/apps/photos/src/pages/gallery.tsx b/web/apps/photos/src/pages/gallery.tsx
index 15338350db..1bb51af01a 100644
--- a/web/apps/photos/src/pages/gallery.tsx
+++ b/web/apps/photos/src/pages/gallery.tsx
@@ -207,7 +207,6 @@ const Page: React.FC = () => {
>();
const isCleanupViewOpen = cleanupView !== undefined;
const [isFirstLoad, setIsFirstLoad] = useState(false);
- const [isWhatsNewReady, setIsWhatsNewReady] = useState(false);
const [isContextMenuOpen, setIsContextMenuOpen] = useState(false);
const [suppressContextSelectionBar, setSuppressContextSelectionBar] =
useState(false);
@@ -771,7 +770,6 @@ const Page: React.FC = () => {
void remotePull({ silent: true, source: "desktop-focus" });
void watcher.checkAccessibility();
});
- setIsWhatsNewReady(true);
}
})();
@@ -2583,7 +2581,7 @@ const Page: React.FC = () => {
renderSubscriptionDialogs(onRootClose)
}
</Sidebar>
- <DesktopWhatsNew enabled={isWhatsNewReady} />
+ <DesktopWhatsNew />
<PeopleConsentDialog
{...peopleConsentVisibilityProps}
onClose={() => {