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

Limited context menu improvements on mobile #2734

Closed
stickz opened this issue Oct 13, 2024 · 3 comments
Closed

Limited context menu improvements on mobile #2734

stickz opened this issue Oct 13, 2024 · 3 comments

Comments

@stickz
Copy link
Collaborator

stickz commented Oct 13, 2024

What would you like changed about the web client?

I would like the expandable context menu for mobile to be improved for the next release.

Describe the solution you'd like and propose possible alternatives.

  1. I would recommend placing Start, Pause and Stop on the same line on mobile (if feasible) to create extra room.
  2. I would recommend dropping the Plugins... main context on mobile. Then bring the sub contexts to main context on mobile using the Plugins icon. (It should also support custom plugins as required)
    • URL Replacement in RSS
    • Ratio Rules
    • Bulk Loading

Provide information and resources about the environment hosting the web client.

Server: ruTorrent v5.0-Stable on Ubuntu 24.04 LTS
Web Client: Google Chrome 129.0.6668.59
Installation Method: zip source from version release

Additional context

ruTorrent_context_menu_improvements

@stickz
Copy link
Collaborator Author

stickz commented Oct 13, 2024

@jevenski What are your thoughts on this suggested improvement for the next release?

@jevenski
Copy link
Contributor

Yes, we can definitely bring the three brothers and sisters (Start, Pause, Stop) onto one line. There is plenty of room horizontally for them.

As for the Plugins submenu, I was thinking about adopting Bootstrap's dropdowns to fit the navbar. The old dropdown menu on the navbar shares the same mechanism with the context menu in the torrent list, the file list, etc. I think this is inefficient because the submenu items are static on the navbar, while the menu items on the context menus are dynamic, depending on what users are right-clicking on. Look at the init check for the theContextMenu object at Line 302 - Line 307: that looks like an if-else nightmare.

ruTorrent/js/objects.js

Lines 302 to 307 in b125b69

if(!ele.hasClass("top-menu-item") && !ele.parent().hasClass("top-menu-item") &&
!ele.hasClass("exp") &&
!ele.hasClass("CMenu") &&
!(ele.hasClass("menu-cmd") && ele.hasClass("dis")) &&
!ele.hasClass("menuitem") &&
!ele.hasClass("menu-line"))

So for the navbar sub-menus, we can add the sub-menu items directly to the DOM, and make the containing icon a dropdown item. The same goes for the search button on the navbar.

@stickz
Copy link
Collaborator Author

stickz commented Oct 13, 2024

Okay sounds good @jevenski! Let's going with the plan of Bootstraps dropdowns!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants