joshwcomeau / guppy

🐠A friendly application manager and task runner for React.js
ISC License
3.27k stars 154 forks source link

Reorder projects in sidebar #310

Closed beyer-martin closed 5 years ago

beyer-martin commented 5 years ago

Related Issue: #195

Summary: Its a work in progress beacause I am having issues between the sidebar scrollbar and the drag and drop (see gif below)

I followed the directions on the issue, made a REARRANGE_PROJECTS_IN_SIDEBAR action and a reducer for the order. It stores the an array of projects ids in the desired order which is the used for the selector to sort the projects.

First time working with Redux so feedback is much appreciated!

Screenshots/GIFs: guppydnd

AWolf81 commented 5 years ago

@beyersito have you seen my PR to your fork? I really like your work and I think it's almost ready. After merging my PR & merging/rebasing master just one flow type should be updated to use new flow type Dispatch<typeof actions.rearrangeProjectsInSidebar>.

Do you need help with this? Or busy with other stuff? If you like I could finalize your work.

beyer-martin commented 5 years ago

Thanks for the help, I am now trying to deal with some scroll issues, dragging down when main windows is scrolled down works weirdly.

AWolf81 commented 5 years ago

@beyersito You can fix the scrolling issue by wrapping <ProjectPage/> in App.js with react-custom-scrollbars.

  <Scrollbars>
     <ProjectPage />
  </Scrollbars>

Not sure what was causing the issue but with this it's working.

AWolf81 commented 5 years ago

@beyersito I'll commandeer this as the pending changes are small and I'd like to finalize this. I hope this is OK. I'll create a separate PR with a branch based on yours. Thanks for your work and I appreciate your support.

beyer-martin commented 5 years ago

Sorry I abandoned this 😔. Please do go ahead

On Sat, Mar 30, 2019 at 9:55 AM Alexander Wolf notifications@github.com wrote:

@beyersito https://github.com/beyersito I'll commandeer this as the pending changes are small and I'd like to finalize this. I hope this is OK. I'll create a separate PR with a branch based on yours. Thanks for your work and I appreciate your support.

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/joshwcomeau/guppy/pull/310#issuecomment-478228778, or mute the thread https://github.com/notifications/unsubscribe-auth/AJgkdzxiw4xWoztJKNRoS0ODnpA-1Mfpks5vbzSEgaJpZM4X9vn8 .

melanieseltzer commented 5 years ago

This has been moved to #375.