Skip to content

Tooltipped buttons tend to require 2 taps to trigger onClick #3205

@taneliang

Description

@taneliang

Describe the bug

Some of our buttons are wrapped with tooltips to provide additional info, e.g. the delete/hide buttons on the timetable page, as well as the nodes in the module page's prerequisite tree.

However, tooltipped buttons take 2 taps to trigger their onClick handler on iOS. Unfortunately, because the buttons still have working hover/focus/active styling, they still react visibly to users' taps, making them very misleading.

To Reproduce

Steps to reproduce the behavior:

  1. On mobile, go to or create a timetable with a selected module (or just import this timetable https://modsn.us/i3htm, but note that importing will replace your current timetable!)
  2. Try tapping either the delete or hide buttons. They will likely just turn gray momentarily, but nothing else will happen. A second tap is necessary to trigger the delete/hide action.
    image

Expected behavior

  • Single-tapping the button should call the button's onClick handler.
  • Long pressing the button should show the tooltip (which is the current behavior)

Smartphone (please complete the following information):

iOS Safari/Chrome, all versions. Didn't try on Android.

Additional context

We may want to see if upgrading @tippyjs (issue #3069) will fix this, otherwise if we can't find a solution we may want to find a replacement tooltip package.

With #3155 removing navigation tab titles on sm-width viewports, we may want to add new tooltips to nav tabs on sm and narrower in the future. Fixing this bug will unblock that.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions