Skip to content
This repository has been archived by the owner on Aug 18, 2023. It is now read-only.

Re-Order Category Folders #67

Closed
mikaelacaron opened this issue Oct 2, 2021 · 14 comments
Closed

Re-Order Category Folders #67

mikaelacaron opened this issue Oct 2, 2021 · 14 comments
Assignees
Labels
feature New feature or request hacktoberfest Issues valid for Hacktoberfest participation

Comments

@mikaelacaron
Copy link
Owner

Is your feature request related to a problem? Please describe.

  • No

Describe the solution you'd like

  • Press and hold a row to reorder the categories

Describe alternatives you've considered

  • None

Additional context

  • None
@mikaelacaron mikaelacaron added feature New feature or request hacktoberfest Issues valid for Hacktoberfest participation labels Oct 2, 2021
@vcapilladeveloper
Copy link
Contributor

Hi,

I started this issue but I find a conflict. When you long press the List cell, the Edit option appears.

Simulator.Screen.Recording.-.iPhone.11.Pro.-.2021-10-13.at.20.10.20.mp4

@mikaelacaron
Copy link
Owner Author

@vcapilladeveloper Please comment on issues so that I can assign them to you, so that others don't work on the same issue and create two PRs for one issue.
Yes this is a conflict, there's two ways you could resolve this:

  1. Keep the long press for the edit functionality and instead add an edit button (maybe in the navigation bar) and then it turns the rows to have the delete function or the 3 lines to easily move around elements.
  2. Remove the edit long press and refactor it to be a swipe action and continue with how the issue is originally described

@vcapilladeveloper
Copy link
Contributor

@mikaelacaron I'm not making this issue, before start making it I normally review the task to understand and evaluate if I can make it.
Assign it to me this issue and I will try to find the best solution and explain to you before start to implement it.

@vcapilladeveloper
Copy link
Contributor

@mikaelacaron hi, How you think about this: (I will try to fix one bug because I can't make longpress on Spacer() inside CategoryRow and I don't know why.)

RPReplay_Final1634418484.MP4

:

@mikaelacaron
Copy link
Owner Author

It overall looks good, I think what could be confusing is press and hold, and then never clicking "end" and it could put the app in a weird state

@vcapilladeveloper
Copy link
Contributor

Ok, I can end the Editing Mode for each movement, what do you think about it? Other issue that I'm trying to find the best solution is how the user edit the category? Maybe inside the category list view add an Edit button at the top right?

To fix the problem on longpress inside an empty location from the row, I put this:

CategoryRow(category: category)
    .contentShape(Rectangle())
    .onLongPressGesture {
        editMode = .active
    }
}

This applye the long press gesture to the entire CategoryRow instead of the content.

@mikaelacaron
Copy link
Owner Author

Hmmm that could work!
I originally based the design off the Notes app from Apple. To make it easy to use and understand.

I'm not sure if Notes is made with SwiftUI or UIKit.

Also you could change "Edit" to "Rename" instead, cause that's what Notes uses for verbiage

@vcapilladeveloper
Copy link
Contributor

Great, I will make it and show you the result

@vcapilladeveloper
Copy link
Contributor

Sorry for not update this issue until now, I started new position on a new company and I don't have enough energy for this jajajajaja

I will make you a summary of the situation:

  • We need to add a .contentShape(Rectangle()) to the CategoryRow from tehe NAvigationLink for make the longPress work on the entire row.
  • implementing onLongPressGesture disables onTapGesture from the List row becouse we put a Rectangle() on it
  • We can not call the isActive from NavigationLink inside the onTapGesture { }
  • May be you can think about the actual design and change the design to apply the same design as in Notes app, where we have the Edit button at the top right and the Add item at the bottom Right.

@mikaelacaron
Copy link
Owner Author

That's okay! @vcapilladeveloper Do you want me to un-assign this issue from you? to allow others to contribute to this issue

@AC40
Copy link
Contributor

AC40 commented Dec 15, 2021

Hey Mikaela, could you assign me to this issue? I would like to try and continue @vcapilladeveloper`s work.

@mikaelacaron
Copy link
Owner Author

Go for it! Thanks again for the help!

@AC40
Copy link
Contributor

AC40 commented Dec 15, 2021

My pleasure. It's a great way to get to know more about the iOS world, other peoples code, conventions, etc.

@mikaelacaron
Copy link
Owner Author

Fixed with PR #111

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
feature New feature or request hacktoberfest Issues valid for Hacktoberfest participation
Projects
None yet
Development

No branches or pull requests

3 participants