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

QoL improvement: submit/next/prev buttons on navbar #105

Open
zardus opened this issue Oct 27, 2022 · 7 comments
Open

QoL improvement: submit/next/prev buttons on navbar #105

zardus opened this issue Oct 27, 2022 · 7 comments
Labels
good first issue Good for newcomers help wanted Extra attention is needed simple

Comments

@zardus
Copy link
Contributor

zardus commented Oct 27, 2022

Aside from an internal command line tool, we could have small buttons on the navbar to pop up a modal to submit a flag, to launch the next challenge, and to launch the previous challenge.

@zardus zardus added help wanted Extra attention is needed good first issue Good for newcomers labels Oct 27, 2022
@JensHouses
Copy link
Contributor

Hey everyone,

I noticed this issue has been open for a while. I'd love to work on it.

@zardus
Copy link
Contributor Author

zardus commented Jul 17, 2024

Sure, we'd love the help!

One issue is that we're running out of space in the nav bar. However, we have this little dude:

image

We could replace it with a hamburger (https://fontawesome.com/icons/bars?s=solid) and have stuff like:

  • Hide Navbar (or Show Navbar if Navbar is hidden)
  • If challenge is started: Submit Flag Restart Challenge Next Challenge Previous Challenge
  • If challenge is not started: Start Recent Challenge
  • Maybe move Admin over here?

@JensHouses
Copy link
Contributor

Sounds like a good idea.
I see a solution for all points.
But I need some help for the start recent challenge:

How do I determine the recent challenge?
Iterate through all unsolved dojos -> modules -> challenges ? They are sorted by index I guess ?

@zardus
Copy link
Contributor Author

zardus commented Jul 17, 2024 via email

@JensHouses
Copy link
Contributor

grafik
What do you think about that layout ?

@ConnorNelson
Copy link
Member

What about a button in the middle (https://fontawesome.com/icons/rotate-left?f=classic&s=solid) with the current challege name that says "Restart current".

And then maybe just something that more closely resembles the existing flag submit line at the bottom (we wouldn't need to say Mars anymore if its on the restart button):

image

Or something closer to that (fine if we have a slightly different feel to match this popup).

I'm mildly concerned about long challenge names and what that might do to this UI though (especially with the added 3rd button). You could test for example with some of the longer challenge names like in https://github.com/pwncollege/linux-luminarium.

Another edge case to consider: what if there isn't a prev/next challenge. I assume the current idea (which is totally fine!) is to only do prev/next relative to the current module. What do you think the UI should look like then?

Overall though, this feature sounds super exciting! Thank you!

@JensHouses
Copy link
Contributor

image

image

image

I changed the layout and added the restart button.

If a challenge is the first or last the button could be display-none, invisible or just disabled 🙂

So far, starting the previous, current or next challenge works and the buttons change accordingly to the new previous, current and next challenges.
Submitting the flag also works.

image

image

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
good first issue Good for newcomers help wanted Extra attention is needed simple
Projects
None yet
Development

No branches or pull requests

3 participants