Merge branch 'add-toast' into 'develop'
Update toast after saving Groups See merge request soapbox-pub/soapbox!2421
This commit is contained in:
commit
3f4bbe6f55
4 changed files with 6 additions and 4 deletions
|
@ -5,6 +5,7 @@ import { Button, Column, Form, FormActions, FormGroup, Icon, Input, Spinner, Tex
|
|||
import { useAppSelector, useInstance } from 'soapbox/hooks';
|
||||
import { useGroup, useUpdateGroup } from 'soapbox/hooks/api';
|
||||
import { useImageField, useTextField } from 'soapbox/hooks/forms';
|
||||
import toast from 'soapbox/toast';
|
||||
import { isDefaultAvatar, isDefaultHeader } from 'soapbox/utils/accounts';
|
||||
|
||||
import AvatarPicker from './components/group-avatar-picker';
|
||||
|
@ -20,7 +21,7 @@ const messages = defineMessages({
|
|||
heading: { id: 'navigation_bar.edit_group', defaultMessage: 'Edit Group' },
|
||||
groupNamePlaceholder: { id: 'manage_group.fields.name_placeholder', defaultMessage: 'Group Name' },
|
||||
groupDescriptionPlaceholder: { id: 'manage_group.fields.description_placeholder', defaultMessage: 'Description' },
|
||||
success: { id: 'manage_group.success', defaultMessage: 'Group saved!' },
|
||||
groupSaved: { id: 'group.update.success', defaultMessage: 'Group successfully saved' },
|
||||
});
|
||||
|
||||
interface IEditGroup {
|
||||
|
@ -64,6 +65,7 @@ const EditGroup: React.FC<IEditGroup> = ({ params: { id: groupId } }) => {
|
|||
});
|
||||
|
||||
setIsSubmitting(false);
|
||||
toast.success(intl.formatMessage(messages.groupSaved));
|
||||
}
|
||||
|
||||
const handleAddTag = () => {
|
||||
|
|
|
@ -811,6 +811,7 @@
|
|||
"group.tabs.members": "Members",
|
||||
"group.tags.hint": "Add up to 3 keywords that will serve as core topics of discussion in the group.",
|
||||
"group.tags.label": "Tags",
|
||||
"group.update.success": "Group successfully saved",
|
||||
"group.upload_banner": "Upload photo",
|
||||
"groups.discover.popular.empty": "Unable to fetch popular groups at this time. Please check back later.",
|
||||
"groups.discover.popular.show_more": "Show More",
|
||||
|
@ -967,7 +968,6 @@
|
|||
"manage_group.privacy.private.label": "Private (Owner approval required)",
|
||||
"manage_group.privacy.public.hint": "Discoverable. Anyone can join.",
|
||||
"manage_group.privacy.public.label": "Public",
|
||||
"manage_group.success": "Group saved!",
|
||||
"manage_group.tagline": "Groups connect you with others based on shared interests.",
|
||||
"media_panel.empty_message": "No media found.",
|
||||
"media_panel.title": "Media",
|
||||
|
|
|
@ -25,7 +25,7 @@ describe('normalizeInstance()', () => {
|
|||
},
|
||||
groups: {
|
||||
max_characters_name: 50,
|
||||
max_characters_description: 100,
|
||||
max_characters_description: 160,
|
||||
},
|
||||
},
|
||||
description: '',
|
||||
|
|
|
@ -37,7 +37,7 @@ export const InstanceRecord = ImmutableRecord({
|
|||
}),
|
||||
groups: ImmutableMap<string, number>({
|
||||
max_characters_name: 50,
|
||||
max_characters_description: 100,
|
||||
max_characters_description: 160,
|
||||
}),
|
||||
}),
|
||||
description: '',
|
||||
|
|
Loading…
Reference in a new issue