h
h copied to clipboard
Frontend: enable users to create restricted and open groups
Implement the frontend (user interface and API call) to enable users to create restricted and open groups and to change the types of existing groups between private, restricted and open.
Part of ERD: Creating Restricted and Open Groups.
Depends on the backend API: https://github.com/hypothesis/h/issues/8896
Create group page
Here's the desired new design for the create-group page:
Changes:
- [ ] The title of the Create a new private group page should be changed to Create a new group
- [ ] The tab title (
<title>element in the HTML<head>) should be changed to Create a new group - [ ] The labels Name, Description and Group type should be bolded
- [ ] The three group-type radio boxes must be added
Edit group page
Here's the desired new design for the edit-group page:
Changes:
- [ ] The labels Name, Description and Group type should be bolded
- [ ] The three group-type radio boxes must be added
API call
- [ ] When the user clicks Create group or Save changes the frontend needs to include the group type parameter in the JSON body of the API call that it makes. See https://github.com/hypothesis/h/issues/8896 for the API design
Warning when changing the type of an existing group
- [ ] When an existing private group is changed to open/restricted or vice-versa this changes the visibility of any pre-existing shared annotations in the group: annotations that were previously only visible to members of the group will now be publicly visible or vice-versa. We want to show the user a warning before letting them do this.
Design for the warning dialog (note: we might want to tweak the wording, see this Slack thread):