Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feat/auto group #162

Merged
merged 12 commits into from
Mar 17, 2025
Merged

Feat/auto group #162

merged 12 commits into from
Mar 17, 2025

Conversation

ryanlinjui
Copy link
Contributor

This pull request introduces several new features and improvements related to group management and waitlist functionality in the session component. The most important changes include adding waitlist management, implementing auto-grouping functionality, and updating session settings to support these features.

Waitlist Management:

  • Added new waitlist-related messages in messages/en.json and messages/zh.json [1] [2].
  • Implemented waitlist join and leave functionality in ParticipantView.svelte [1] [2].

Auto-grouping Functionality:

  • Added auto-grouping settings and logic in HostView.svelte to automatically assign participants to groups based on the number of groups specified [1] [2].
  • Updated session schema to include autoGroup settings and waitlist array in session.ts.
  • Added server-side handling for auto-grouping in auto_group/+server.ts (src/routes/api/session/[id]/group/auto_group/+server.tsR1-R104).

Session Settings:

Miscellaneous:

  • Imported necessary components and methods in HostView.svelte and ParticipantView.svelte [1] [2].
  • Added logic to enable or disable group management based on session settings in ParticipantView.svelte [1] [2].

ryanlinjui and others added 10 commits March 15, 2025 17:17
Waitlist
Make a wait list let the participants are able to join.
The host can auto group participants in waitlist
leave waiting list
auto group api
auto group from host

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature.
Copy link

github-actions bot commented Mar 17, 2025

🥷 Ninja i18n – 🛎️ Translations need to be updated

Project /project.inlang

lint rule new reports level link
Missing translation 7 warning contribute (via Fink 🐦)

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot encountered an error and was unable to review this pull request. You can try again by re-requesting a review.

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature.
@ryanlinjui ryanlinjui requested a review from Copilot March 17, 2025 15:26
Copy link
Contributor

@Copilot Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This pull request introduces new features to enhance session group management and waitlist functionality.

  • Implements new waitlist endpoints and messaging.
  • Adds auto-grouping functionality for dynamically assigning participants to groups.
  • Updates session schema and settings to support the new features.

Reviewed Changes

Copilot reviewed 9 out of 9 changed files in this pull request and generated 4 comments.

Show a summary per file
File Description
src/routes/api/session/[id]/settings/+server.ts Adds GET and POST endpoints to update and fetch session settings.
src/routes/api/session/[id]/action/[action]/+server.ts Implements waitlist join and leave actions with permission checks.
src/lib/schema/session.ts Updates session schema to include autoGroup settings and waitlist.
src/routes/api/session/+server.ts Updates session initialization to include autoGroup settings.
src/routes/api/session/[id]/group/auto_group/+server.ts Creates auto-grouping logic including group creation and member join.
Comments suppressed due to low confidence (1)

src/routes/api/session/[id]/group/auto_group/+server.ts:81

  • The error thrown when no members are provided uses the members array as the error message, which is unclear. Consider using a descriptive message like 'No members provided for group creation'.
if (members.length === 0) { throw error(400, members); }

@ryanlinjui ryanlinjui merged commit 8af68c7 into main Mar 17, 2025
5 checks passed
@ryanlinjui ryanlinjui deleted the feat/auto-group branch March 17, 2025 15:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants