π End-to-end encrypted cloud for everything.
Dart 2faandroidauthye2eeencryptionend-to-end-encryptionfluttergolanggoogle-photosgoogle-photos-alternativeiosopensourcephotosprivacyprivacy-toolstypescriptzero-knowledge
Don't show two dialogs
Manav Rathif66f6ab9be24
diff --git a/web/packages/new/photos/components/SelectedFileOptions.tsx b/web/packages/new/photos/components/SelectedFileOptions.tsxindex 421140af60..d05b291f77 100644--- a/web/packages/new/photos/components/SelectedFileOptions.tsx+++ b/web/packages/new/photos/components/SelectedFileOptions.tsx@@ -201,29 +201,24 @@ export const SelectedFileOptions: React.FC<SelectedFileOptionsProps> = ({});const handleRemoveFromCollection = () => {- const action = () => onRemoveFilesFromCollection(collection!);+ const remove = () => onRemoveFilesFromCollection(collection!);- showMiniDialog(- selectedFileCount == selectedOwnFileCount- ? {- title: t("remove_from_album"),- message: t("confirm_remove_message"),- continue: {- text: t("yes_remove"),- color: "primary",- action,- },- }- : {- title: t("remove_from_album"),- message: t("confirm_remove_incl_others_message"),- continue: {- text: t("yes_remove"),- color: "critical",- action,- },- },- );+ if (collectionSummary?.attributes.has("sharedIncoming")) {+ remove();+ } else {+ const onlyUserFiles = selectedFileCount == selectedOwnFileCount;+ showMiniDialog({+ title: t("remove_from_album"),+ message: onlyUserFiles+ ? t("confirm_remove_message")+ : t("confirm_remove_incl_others_message"),+ continue: {+ text: t("yes_remove"),+ color: onlyUserFiles ? "primary" : "critical",+ action: remove,+ },+ });+ }};const handleMoveToCollection = () => {