π End-to-end encrypted cloud for everything.
Dart 2faandroidauthye2eeencryptionend-to-end-encryptionfluttergolanggoogle-photosgoogle-photos-alternativeiosopensourcephotosprivacyprivacy-toolstypescriptzero-knowledge
fix(searchBar):adding-type-guard-for-navigate
Aswin Asokb10d255c1991
diff --git a/web/packages/new/photos/components/SearchBar.tsx b/web/packages/new/photos/components/SearchBar.tsxindex 4f517fc90c..284e220436 100644--- a/web/packages/new/photos/components/SearchBar.tsx+++ b/web/packages/new/photos/components/SearchBar.tsx@@ -181,7 +181,6 @@ const SearchInput: React.FC<Omit<SearchBarProps, "onShowSearchInput">> = ({const handleChange = (value: SearchOption | null) => {const type = value?.suggestion.type;- console.log(value, value?.suggestion.label);// Collection and people suggestions are handled differently - our// caller will switch to the corresponding view, dismissing search.if (type == "collection" || type == "person") {@@ -348,8 +347,11 @@ const createSelectStyles = (});const Control = ({ children, ...props }: ControlProps<SearchOption, false>) => {- const isMac = navigator.userAgent.toUpperCase().includes("MAC");+ const isMac =+ typeof navigator !== "undefined" &&+ navigator.userAgent.toUpperCase().includes("MAC");const shortcutKey = isMac ? "β K" : "Ctrl + K";+const hasValue =props.getValue().length > 0 || props.selectProps.inputValue;