Merge branch 'group-improvements' into 'develop'

Improve Group UX

See merge request soapbox-pub/soapbox!2494
This commit is contained in:
Chewbacca
2023-05-05 13:13:37 +00:00
7 changed files with 44 additions and 26 deletions

View File

@@ -40,7 +40,7 @@ const GroupMediaPanel: React.FC<IGroupMediaPanel> = ({ group }) => {
useEffect(() => {
setLoading(true);
if (group && (isMember || !isPrivate)) {
if (group && !group.deleted_at && (isMember || !isPrivate)) {
dispatch(expandGroupMediaTimeline(group.id))
// @ts-ignore
.then(() => setLoading(false))
@@ -72,7 +72,7 @@ const GroupMediaPanel: React.FC<IGroupMediaPanel> = ({ group }) => {
}
};
if (isPrivate && !isMember) {
if ((isPrivate && !isMember) || group?.deleted_at) {
return null;
}

View File

@@ -19,7 +19,7 @@ const ConfirmationStep: React.FC<IConfirmationStep> = ({ group }) => {
const intl = useIntl();
const handleCopyLink = () => {
copy(`${window.location.origin}/group/${group?.slug}`, () => {
copy(group?.url as string, () => {
toast.success(intl.formatMessage(messages.copied));
});
};