From 057599d82fa1a003d39750dfc393508fd6cd1a2a Mon Sep 17 00:00:00 2001 From: Mark Bouslog Date: Thu, 5 Oct 2023 10:36:05 -0500 Subject: [PATCH] Add user group stats page, user stats page, and logged-in user homepage ADRs (#5316) * Add user group stats page ADR * Add user stats page ADR * Add logged-in user homepage ADR * Apply suggestions from code review Co-authored-by: Delilah C. <23665803+goplayoutside3@users.noreply.github.com> * Update docs/arch/adr-51.md --------- Co-authored-by: Delilah C. <23665803+goplayoutside3@users.noreply.github.com> --- docs/arch/README.md | 3 +++ docs/arch/adr-51.md | 37 +++++++++++++++++++++++++++++++++++++ docs/arch/adr-52.md | 31 +++++++++++++++++++++++++++++++ docs/arch/adr-53.md | 31 +++++++++++++++++++++++++++++++ 4 files changed, 102 insertions(+) create mode 100644 docs/arch/adr-51.md create mode 100644 docs/arch/adr-52.md create mode 100644 docs/arch/adr-53.md diff --git a/docs/arch/README.md b/docs/arch/README.md index 589270658a..f26e8027cb 100644 --- a/docs/arch/README.md +++ b/docs/arch/README.md @@ -50,3 +50,6 @@ - [ADR 48: JSONData subject location type and viewer](adr-48.md) - [ADR 49: Flipbook Viewer](adr-49.md) - [ADR 50: Separate Frames Viewer](adr-50.md) +- [ADR 51: User Group Stats Page](adr-51.md) +- [ADR 52: User Stats Page](adr-52.md) +- [ADR 53: Logged-In User Homepage](adr-53.md) diff --git a/docs/arch/adr-51.md b/docs/arch/adr-51.md new file mode 100644 index 0000000000..f3c446e750 --- /dev/null +++ b/docs/arch/adr-51.md @@ -0,0 +1,37 @@ +# ADR 51: User Group Stats Page + +September 2023 + +## Context + +We will create a user group stats page to provide statistical insights and data visualization of a user group’s Zooniverse activity. The user group stats page will utilize the new Zooniverse stats service - [ERAS](https://github.com/zooniverse/eras) (Enhanced Running Average Stats Service) - in addition to existing [Panoptes](https://github.com/zooniverse/panoptes) resources (notably `users`, `user_groups`, and `projects`). + +### Features + +The user group stats page will show statistical information based on user group member role and user group `stats_visibility` property. + +Statistical information will include a bar chart of classification counts or hours (changeable by period and filterable by project), top projects, and could include top individual contributors and all user group members’ statistics. + +User groups with the appropriate `stats_visibility` property will support a CSV export of user group member statistics. + +A group admin will create and manage a user group with related modals. + +## Decision + +Create a user group stats page at `www.zooniverse.org/groups/[group ID]`. + +Users will join a user group using a “Join Link” similar to the existing process with [classroom](https://github.com/zooniverse/classroom) and [education-api](https://github.com/zooniverse/education-api). + +Create ERAS client. + +Create shared stats components (i.e. bar chart) in lib-react-components. + +Create export member statistics to CSV functionality for applicable user groups. + +## Status + +Proposed + +## Consequences + +Create client, components, and features noted. Create user group stats page in new library `lib-user` per [FEM packages structure discussion](https://github.com/zooniverse/front-end-monorepo/discussions/5089). diff --git a/docs/arch/adr-52.md b/docs/arch/adr-52.md new file mode 100644 index 0000000000..abebabf65b --- /dev/null +++ b/docs/arch/adr-52.md @@ -0,0 +1,31 @@ +# ADR 52: User Stats Page + +September 2023 + +## Context + +We will create a user stats page to show a user statistical insights and data visualization of their Zooniverse activity. The user group stats page will utilize the new Zooniverse stats service - [ERAS](https://github.com/zooniverse/eras) (Enhanced Running Average Stats Service) - in addition to existing [Panoptes](https://github.com/zooniverse/panoptes) resources (notably `users` and `projects`). + +### Features + +The user stats page will include the functionality to generate a Volunteer Certificate detailing Zooniverse participation hours. + +Statistical information will include a bar chart of classification counts or hours - changeable by period and filterable by project. + +## Decision + +Create a user stats page at `www.zooniverse.org/users/[user login]/stats`. + +Create ERAS client. + +Create shared stats components (i.e. bar chart) in lib-react-components. + +Create PDF generation feature to document user contributions. + +## Status + +Proposed + +## Consequences + +Create client, components, and features noted. Create user stats page in new library `lib-user` per [FEM packages structure discussion](https://github.com/zooniverse/front-end-monorepo/discussions/5089). diff --git a/docs/arch/adr-53.md b/docs/arch/adr-53.md new file mode 100644 index 0000000000..8a78f34ad2 --- /dev/null +++ b/docs/arch/adr-53.md @@ -0,0 +1,31 @@ +# ADR 53: Logged-In User Homepage + +September 2023 + +## Context + +We will redesign the logged-in user homepage to provide a user with recent participation statistics, recent projects, recent classifications, and a list of linked user groups (if applicable). The logged-in user homepage will utilize the new Zooniverse stats service - [ERAS](https://github.com/zooniverse/eras) (Enhanced Running Average Stats Service) - in addition to existing [Panoptes](https://github.com/zooniverse/panoptes) and [Talk](https://github.com/zooniverse/talk-api) resources (notably `users`, `projects`, and `comments`). + +### Features + +The logged-in user homepage will include stats on recent classifications, hours, projects, and comments. + +The logged-in user homepage will list recent projects, classifications, and user groups. + +## Decision + +Create ERAS client. + +Create shared stats components in lib-react-components. + +Refactor profile ribbon from Panoptes `project_preferences` request(s) to ERAS user stats request. + +Refactor recent classifications cards for redesigned logged-in user homepage. + +## Status + +Proposed + +## Consequences + +Create client, components, and features noted. Create logged-in user homepage in `app-root` per [FEM packages structure discussion](https://github.com/zooniverse/front-end-monorepo/discussions/5089).