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

The whole calendar tile is not clickable #15445

Open
Rafi993 opened this issue Jun 16, 2024 · 2 comments · May be fixed by #15446
Open

The whole calendar tile is not clickable #15445

Rafi993 opened this issue Jun 16, 2024 · 2 comments · May be fixed by #15446
Labels
🐛 bug Something isn't working ui area: UI, frontend, button, form, input

Comments

@Rafi993
Copy link

Rafi993 commented Jun 16, 2024

Issue Summary

  • The whole tile is not clickable. There is a spacing around the link where it shows the hover state but it is not clickable
  • This seems to be happening because of extra padding in the div surrounding the a tag ideally the padding should be present in the a tag instead of the div to solve this issue

Steps to Reproduce

  1. Visit a calendar
  2. Try clicking on the edges of the meeting tile nothing will happen

Expected Results

Clicking anywhere on the tile should open the link not just in the center

Evidence

Screenshot 2024-06-16 at 10 53 06 AM
  • I was able to recreate this bug in Firefox 127, Chrome 125
@dosubot dosubot bot added ui area: UI, frontend, button, form, input 🐛 bug Something isn't working labels Jun 16, 2024
@Rafi993
Copy link
Author

Rafi993 commented Jun 16, 2024

This is a very minor issue. I can help with it to get it solved quickly it was really bothering me 😅

Copy link

dosubot bot commented Jun 16, 2024

Hey @Rafi993! 👋 I'm a bot that can help you with bugs, questions, and becoming a contributor. Let's tackle this issue together!

To make the entire calendar tile clickable, you can move the padding from the div to the a tag. Here’s how you can adjust the HTML and CSS:

  1. HTML Structure:
    Ensure the a tag is inside the div and remove any padding from the div.

    <div class="calendar-tile">
      <a href="#" class="calendar-link">Event</a>
    </div>
  2. CSS Adjustments:
    Remove the padding from the div and add it to the a tag.

    .calendar-tile {
      padding: 0; /* Remove padding from the div */
    }
    
    .calendar-link {
      display: block; /* Make the a tag a block element */
      padding: 1rem; /* Add padding to the a tag */
    }

This way, the entire area of the a tag will be clickable, making the calendar tile fully interactive [1].

Additionally, ensure that any existing CSS classes or styles applied to the div and a tags are adjusted accordingly. The a tag inherits styles from global CSS rules, such as:

a {
  color: inherit;
  text-decoration: inherit;
}

These styles ensure that the a tag inherits the color and text-decoration properties from its parent elements [1].

Be aware that there is a JavaScript onClick event listener associated with the calendar tile. Changing the padding from the div to the a tag could potentially affect the layout and the area where the onClick event is triggered [2].

If you need further assistance, @keithwillcode might be able to provide additional guidance.

To continue talking to Dosu, mention @dosu.

@Rafi993 Rafi993 linked a pull request Jun 16, 2024 that will close this issue
3 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
🐛 bug Something isn't working ui area: UI, frontend, button, form, input
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant