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

odd behaviour when cycling through images in lightbox #52

Closed
phiw13 opened this issue Aug 21, 2023 · 2 comments
Closed

odd behaviour when cycling through images in lightbox #52

phiw13 opened this issue Aug 21, 2023 · 2 comments
Milestone

Comments

@phiw13
Copy link

phiw13 commented Aug 21, 2023

Tested with Safari / Firefox / Brave + iPhone.
(use the demo to play along)

  1. cycle through the images by either clicking/tapping the buttons or using the left/right arrows on the keyboard
  2. reach the first or last image in the series
  3. press the arrow keys once more or press the button again

Observed behaviour or actual result: the first/last image gives the impression of (briefly) sliding away to make place for the next one. Nothing happens however

Expected behaviour:
the button is disabled (and hidden or greyed out), pressing the arrow keys does nothing.

Note: the buttons have the aria-disabled attribute set (true), but the buttons are not actually disabled.

This worked as expected in Parvus 2.3.*

@deoostfrees
Copy link
Owner

Hey @phiw13,

this is the new behavior. Unlike disabled, a button with an aria-disabled attribute is still included in the tab sequence. I may have to remove the animation if it's irritating. You can hide or grey out the disabled buttons with CSS:

.parvus__btn[aria-disabled='true'] {
    // ...
}

but I don't recommend it.

@deoostfrees
Copy link
Owner

I'll remove the animation when there is no slide and adjust the style of the "disabled" buttons.

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

No branches or pull requests

2 participants