Skip to content

Add Next/Prev buttons to gradient controls - #5

Open
thaedal wants to merge 1 commit into
Coffee-Nerd:mainfrom
thaedal:add-next-prev-buttons
Open

Add Next/Prev buttons to gradient controls#5
thaedal wants to merge 1 commit into
Coffee-Nerd:mainfrom
thaedal:add-next-prev-buttons

Conversation

@thaedal

@thaedal thaedal commented Jan 29, 2026

Copy link
Copy Markdown

Summary

This PR adds "Next" and "Prev" buttons to the gradient control section, allowing users to quickly cycle through the available gradient options without repeatedly opening the dropdown menu.

Changes

  • Modified index.html to include two new buttons: Prev and Next, located after the "Invert" checkbox.
  • Added JavaScript event listeners for these buttons to increment or decrement the selectedIndex of the gradient dropdown.
  • Added boundary checks to ensure the selection stops at the beginning or end of the list without errors.
  • Triggering these buttons automatically updates the gradient preview and the colourised output.

@Coffee-Nerd

Coffee-Nerd commented Jan 30, 2026

Copy link
Copy Markdown
Owner

Hey bud, did you know you can already do this by using the up/down arrows with your keyboard?

I've actually got many HUGE updates to the colorizer coming soon. (Been pending for like 6 months, got busy with my client)

AND a NEW colorizer as well!

Thanks for the commit, I'll have a look at it later today.

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.

2 participants