getodk / central-frontend

Vue.js based frontend for ODK Central
https://docs.getodk.org/central-intro/
Apache License 2.0
32 stars 57 forks source link

Do not show conflicting property explanation in tooltip of property name #920

Closed matthew-white closed 8 months ago

matthew-white commented 9 months ago

In the diff shown on the entity detail page, if a property name is long, then it is truncated with a tooltip. However, right now, if the property is a conflicting property, then the tooltip includes the text of the .sr-only element next to the property name. The tooltip should only show the property name: the text of the .sr-only element is shown in a different tooltip.

What has been done to verify that this works as intended?

The fix involved moving the v-tooltip.text from the <td> element to a new <span> element wrapping the property name. With the introduction of the <span>, the selector for the tooltip element had to change in an existing test. Beyond that, I think it's hard to write a meaningful test for this fix, as any test of a tooltip already has to select the specific element that has the tooltip. Here, that element is the new <span>, which we know doesn't contain an .sr-only element.

I also viewed this change locally and was able to verify it that way.

Before submitting this PR, please make sure you have: