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

Roadmap Search Redesign (Part 1) #514

Merged
merged 24 commits into from
Jan 14, 2025
Merged

Roadmap Search Redesign (Part 1) #514

merged 24 commits into from
Jan 14, 2025

Conversation

Awesome-E
Copy link
Member

@Awesome-E Awesome-E commented Nov 17, 2024

Description

SortableJS instead of React Beautiful DND

This library makes the animations more smooth when being dragged (cloned) from the search bar and when being dropped (inserted) into a quarter in the user's roadmap.

Previously, it used to move the dragged element into the quarter, then have a sudden transition in it's shape as it re-rendered the component. Now, there's a placeholder component when dragging so there's no layout change.

Compare https://peterportal.org/roadmap vs https://staging-514.peterportal.org/roadmap

Search Layout and Desktop Year Layout

  • Quarters with one row won't take up the whole space (this looked really weird with just a fall quarter, for example).
  • When the search box is empty, the course bag is shown instead of a placeholder message.

Before (left) and after (right):

Mobile "Add Course" Menu

  • This is now a slide-in-from-bottom panel instead of a floating window that replaces the entire page content
  • The quarter is now shown on the cancel button so users have context of the quarter before they tap a course
  • When tapping a course, the full information is shown, and this serves as the confirmation instead of a popup that shows the year and quarter name

Before:

After:

Steps to verify/test this change:

  • Verify changes work as expected on staging instance
  • Verify successful deployment

Issues

Didn't find any

@Awesome-E Awesome-E temporarily deployed to staging-514 November 17, 2024 03:12 — with GitHub Actions Inactive
@Awesome-E Awesome-E temporarily deployed to staging-514 November 17, 2024 03:15 — with GitHub Actions Inactive
@Awesome-E Awesome-E temporarily deployed to staging-514 November 17, 2024 03:18 — with GitHub Actions Inactive
@Awesome-E Awesome-E temporarily deployed to staging-514 November 17, 2024 03:45 — with GitHub Actions Inactive
@Awesome-E Awesome-E temporarily deployed to staging-514 December 6, 2024 02:03 — with GitHub Actions Inactive
@Awesome-E Awesome-E temporarily deployed to staging-514 December 6, 2024 03:58 — with GitHub Actions Inactive
@Awesome-E Awesome-E temporarily deployed to staging-514 December 6, 2024 03:58 — with GitHub Actions Inactive
@Awesome-E Awesome-E temporarily deployed to staging-514 December 6, 2024 23:47 — with GitHub Actions Inactive
@Awesome-E Awesome-E temporarily deployed to staging-514 December 7, 2024 01:38 — with GitHub Actions Inactive
@Awesome-E Awesome-E temporarily deployed to staging-514 December 7, 2024 01:45 — with GitHub Actions Inactive
@Awesome-E Awesome-E temporarily deployed to staging-514 December 7, 2024 01:54 — with GitHub Actions Inactive
@Awesome-E Awesome-E requested a review from js0mmer December 7, 2024 01:59
@Awesome-E Awesome-E changed the title [Incomplete] Roadmap search redesign Roadmap Search Redesign Dec 7, 2024
@Awesome-E Awesome-E changed the title Roadmap Search Redesign Roadmap Search Redesign (Part 1) Dec 7, 2024
@Awesome-E Awesome-E marked this pull request as ready for review December 7, 2024 01:59
@Awesome-E Awesome-E temporarily deployed to staging-514 December 7, 2024 02:00 — with GitHub Actions Inactive
@Awesome-E Awesome-E temporarily deployed to staging-514 December 9, 2024 21:48 — with GitHub Actions Inactive
Copy link
Member

@js0mmer js0mmer left a comment

Choose a reason for hiding this comment

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

The grabbing cursor only shows when you first start the drag and are still hovering over the original spot which bothers me. I think the way around would have to be adding/removing the cursor: grabbing style to the document body within the onStart and onEnd listeners for dragging.

site/src/pages/RoadmapPage/AddCoursePopup.scss Outdated Show resolved Hide resolved
site/package.json Outdated Show resolved Hide resolved
site/src/component/SideBar/SideBar.tsx Outdated Show resolved Hide resolved
site/src/pages/RoadmapPage/AddCoursePopup.scss Outdated Show resolved Hide resolved
site/src/pages/RoadmapPage/CourseBag.tsx Outdated Show resolved Hide resolved
site/src/pages/RoadmapPage/CourseHitItem.tsx Outdated Show resolved Hide resolved
site/src/pages/RoadmapPage/Coursebag.scss Outdated Show resolved Hide resolved
site/src/pages/RoadmapPage/SearchSidebar.tsx Outdated Show resolved Hide resolved
site/src/pages/RoadmapPage/Quarter.tsx Outdated Show resolved Hide resolved
@js0mmer js0mmer linked an issue Dec 10, 2024 that may be closed by this pull request
@Awesome-E Awesome-E temporarily deployed to staging-514 January 6, 2025 04:13 — with GitHub Actions Inactive
@Awesome-E Awesome-E temporarily deployed to staging-514 January 6, 2025 04:17 — with GitHub Actions Inactive
@Awesome-E Awesome-E requested a review from js0mmer January 6, 2025 04:17
@Awesome-E
Copy link
Member Author

Re-requesting review. I applied the cursor style via CSS instead – still seems like it doesn't work when dragged over a scroll bar, but I don't think that's an issue we have to worry about too much.

@Awesome-E
Copy link
Member Author

Not sure if @js0mmer will review since he's graduated, so asking @timobraz for code review and @CadenLee2 for staging check

Copy link
Member

@js0mmer js0mmer left a comment

Choose a reason for hiding this comment

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

Oh, didn't see that you re-requested. LGTM

Copy link
Contributor

@CadenLee2 CadenLee2 left a comment

Choose a reason for hiding this comment

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

Tested staging instance in Firefox on desktop and on Android

  • Quarter widths look good regardless of the number of quarters included, on a wide screen there is a lot of empty space but that's better than over-stretching them so this makes sense:
    Screenshot 2025-01-08 105644
  • Saved courses show up properly when there's nothing in the search bar
  • When no courses are saved, there is a simplistic placeholder message under the search bar without the anteater illustration, as opposed to the current "Start typing in the search bar" prompt with the illustration (is this intended? It feels less polished)
  • When the search has no results, nothing shows up at all, as opposed to the current "Sorry, we couldn't find any results for that search!" message with the anteater illustration (see the staging screenshot below). I think this is a problem, since there should at least be something to show that there aren't any matching courses?
    Old:
    Screenshot 2025-01-08 110828
    New:
    Screenshot 2025-01-08 110250
  • The new mobile add course menu works (closing, opening, adding courses, viewing saved courses when there is no search bar input), but has the same behavior as the above when there are no search results/when there are no saved courses
  • Styles all look good

With the placeholder messages, I do prefer what was there before--was there a reason for the change, or is it an issue? If it's the latter, it shouldn't be too difficult to fix. Otherwise, I can approve this as well.

@Awesome-E Awesome-E temporarily deployed to staging-514 January 13, 2025 20:30 — with GitHub Actions Inactive
@Awesome-E Awesome-E requested a review from CadenLee2 January 13, 2025 20:30
Copy link
Contributor

@CadenLee2 CadenLee2 left a comment

Choose a reason for hiding this comment

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

Placeholder improvement looks good to me

@Awesome-E Awesome-E temporarily deployed to staging-514 January 14, 2025 06:33 — with GitHub Actions Inactive
@Awesome-E Awesome-E merged commit c4d9029 into main Jan 14, 2025
2 checks passed
@Awesome-E Awesome-E deleted the roadmap-search-redesign branch January 14, 2025 06:35
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.

Roadmap search is cut off
3 participants