style(list): highlighted area of items is not entirely clickable #3172

Open
opened 3 weeks ago by WofWca · 5 comments
WofWca commented 3 weeks ago

Description

That is, nothing happens if you click the area outside of the blue rectangle (see the screenshot), which makes it seem like it's just not working.

What I would suggest as a fix is to set position: absolute; top: 0; bottom: 0; right: 0; left: 0; for the <a element such that it fills the wrapper element, and put the other buttons below it in HTML such that they're above it clickable-wise.
Or look up a solution somewhere else, there's plenty of similar code written.

Vikunja Frontend Version

f4c568e961

Vikunja API Version

v1

Browser and version

Gecko 110

Can you reproduce the bug on the Vikunja demo site?

Yes

Screenshots

image

### Description That is, nothing happens if you click the area outside of the blue rectangle (see the screenshot), which makes it seem like it's just not working. What I would suggest as a fix is to set `position: absolute; top: 0; bottom: 0; right: 0; left: 0;` for the `<a` element such that it fills the wrapper element, and put the other buttons below it in HTML such that they're above it clickable-wise. Or look up a solution somewhere else, there's plenty of similar code written. ### Vikunja Frontend Version f4c568e9610398e9504589cc953001b38e42f70b ### Vikunja API Version v1 ### Browser and version Gecko 110 ### Can you reproduce the bug on the Vikunja demo site? Yes ### Screenshots ![image](/attachments/db5c1ceb-50d1-44de-9264-03fcd7d51644)
5.2 KiB
WofWca added the kind/bug label 3 weeks ago
konrad closed this issue 3 weeks ago
konrad commented 3 weeks ago
Owner

Fixed in fe764a46e9. Please check with the next unstable build (~30 min) if the problem went away.

Fixed in https://kolaente.dev/vikunja/frontend/commit/fe764a46e931ae79f1651f4a669a8c777e260f16. Please check with the next unstable build (~30 min) if the problem went away.
WofWca commented 3 weeks ago
Poster
I'm afraid [it's not ok to put buttons inside `<a`s](https://stackoverflow.com/a/6393863/10406353).
konrad commented 3 weeks ago
Owner

The alternative would be to use a div and attach a click handler to it so that the user will be redirected to the task detail page on click. That would work but would loose all meaning of a link which this is. I feel like the position hack you suggested might work but may create other problems.

Not sure what to do instead? @dpschen do you have an idea?

The alternative would be to use a div and attach a `click` handler to it so that the user will be redirected to the task detail page on click. That would work but would loose all meaning of a link which this is. I feel like the position hack you suggested might work but may create other problems. Not sure what to do instead? @dpschen do you have an idea?
Collaborator

The suggested solution from @WofWca goes in a good direction.
See also https://css-tricks.com/block-links-the-search-for-a-perfect-solution/

The suggested solution from @WofWca goes in a good direction. See also https://css-tricks.com/block-links-the-search-for-a-perfect-solution/
konrad commented 3 weeks ago
Owner

PR is up: #3176

PR is up: https://kolaente.dev/vikunja/frontend/pulls/3176
konrad reopened this issue 3 weeks ago
Sign in to join this conversation.
No Milestone
No Assignees
3 Participants
Notifications
Due Date

No due date set.

Dependencies

No dependencies set.

Reference: vikunja/frontend#3172
Loading…
There is no content yet.