Skip to content

Refactor section backend#40

Open
azpi-arte wants to merge 20 commits intomainfrom
refactor-section-backend
Open

Refactor section backend#40
azpi-arte wants to merge 20 commits intomainfrom
refactor-section-backend

Conversation

@azpi-arte
Copy link
Contributor

@azpi-arte azpi-arte commented Mar 10, 2026

Tracking Info

Resolves #30

Changes

  • Created create SectionFlow form
  • Created MultiStepForm component
  • Created edit Section form
  • Created success popup component
  • Created MultiSelect dropdown component
  • Added section api calls
  • MODIFIED Sections backend to inherent these props from Program:
    startDate: string
    endDate: string
    archived: boolean, default: False
    color: string
  • MODIFIED Sections backend to accept FIREBASE id instead of mongodb id.
  • Added a 'fit content' optional prop to modal
  • TODO
  • fix spawn 'close dialog' logic on escape button. right now it instantly closes the modal instead of showing 'close dialog?' dialog.

Testing

  • positive test cases for regular inputs
  • Went through and created multiple regular sections

Checked Mongodb Compass app

  • TODO
  • check form responsiveness
  • check cross-session local storage functionality for multi step form state management

Confirmation of Change

Screenshot 2026-03-10 141735 Screenshot 2026-03-10 141811 Screenshot 2026-03-10 141826 Screenshot 2026-03-10 141843 Screenshot 2026-03-10 141536 Screenshot 2026-03-10 141548 Screenshot 2026-03-10 141610 Screenshot 2026-03-10 141619 Screenshot 2026-03-10 141625 Screenshot 2026-03-10 141634 Screenshot 2026-03-10 141651 Screenshot 2026-03-10 141558

@github-actions
Copy link

github-actions bot commented Mar 10, 2026

Visit the preview URL for this PR (updated for commit e8fc166):

https://meemli-dev--pr40-refactor-section-bac-ncc7i78p.web.app

(expires Sat, 21 Mar 2026 01:51:41 GMT)

🔥 via Firebase Hosting GitHub Action 🌎

Sign: 633a893569aee98f762f025e27aa080a469727e1

@mraysu mraysu requested a review from thomas-rocha March 11, 2026 04:52
Copy link
Collaborator

@mraysu mraysu left a comment

Choose a reason for hiding this comment

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

Functionality wise, great work. The forms work really well, and I appreciate the modular file structure and compatibility with react form hooks.

Please address the code quality comments below

Copy link
Contributor

@thomas-rocha thomas-rocha left a comment

Choose a reason for hiding this comment

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

Looks pretty good, I have one concern about functionality and a few about styling.

No error messages appear for the start and end-time if they are not filled out when trying to proceed.
image

The error message for the day selection appears to the right instead of underneath which throws off the UI imo since the rest gets pushed to the right.
image

Selecting many days expands the main bar to contain all of the entries at once, which messes up the layout. I'd recommend fixing the width, hiding excess elements on overflow, and allowing the user to scroll through the main bar to look at all the entries.
image

This one might be a little nitpicky, but the user has to uncheck a selected time before they can select a new one if they misclick. This feels a bit clunky imo, so maybe allowing them to switch to whichever one they click automatically could work out.
image

Not sure if this was intended or not, but I thought I'd point it out. The cancel button when creating a class resets the progress, but clicking outside the modal doesn't.

Other than these, the code looks good to me.

@azpi-arte
Copy link
Contributor Author

azpi-arte commented Mar 14, 2026

Selecting multiple days:
Screenshot 2026-03-13 184113

Error output:
Screenshot 2026-03-13 183947

Didn't change escape behavior

Copy link
Contributor

@thomas-rocha thomas-rocha left a comment

Choose a reason for hiding this comment

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

LGTM

Copy link
Collaborator

@mraysu mraysu left a comment

Choose a reason for hiding this comment

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

LGTM 🚀

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.

Sections refactor and Add/Edit forms

3 participants