Skip to content

fix: filter out bookmarked courses from @ mention - #1441

Open
qianqiang-del wants to merge 2 commits into
THU-MAIC:mainfrom
qianqiang-del:fix/filter-mention-courses
Open

fix: filter out bookmarked courses from @ mention#1441
qianqiang-del wants to merge 2 commits into
THU-MAIC:mainfrom
qianqiang-del:fix/filter-mention-courses

Conversation

@qianqiang-del

@qianqiang-del qianqiang-del commented Sep 10, 2026

Copy link
Copy Markdown

Problem Description

The original @ feature displays all courses, including:

  • Courses created by the user (isOwner: true)
  • Courses bookmarked from other users (isOwner: false)

Original Drawbacks

  1. Poor User Experience:
    → Bookmarked courses cannot be modified
    → Selecting them leads to confusion as they cannot be edited

  2. Inconsistent Functionality:
    → Displays non-operable options
    → Violates the "only show operable content" design principle

  3. Low Efficiency:
    → Users need to manually identify which courses can be modified
    → Increases cognitive burden

Fix

Added filter condition in courseOptions calculation:
.filter((course) => course.isOwner !== false)

Filters out courses where isOwner is false,
only displays courses created by the user.

User Benefits

  1. Clearer:
    → Only shows modifiable courses
    → Reduces user confusion

  2. More Efficient:
    → Users don't need to identify course types
    → Can directly select and operate

  3. More Consistent:
    → All displayed courses can be modified
    → Meets user expectations

Modified File

components/workbench/workspace/WorkspaceShell.tsx

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.

1 participant