Parvus icon indicating copy to clipboard operation
Parvus copied to clipboard

odd behaviour when cycling through images in lightbox

Open phiw13 opened this issue 2 years ago • 2 comments

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.*

phiw13 avatar Aug 21 '23 06:08 phiw13

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 avatar Aug 26 '23 19:08 deoostfrees

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

deoostfrees avatar Jan 29 '24 18:01 deoostfrees