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

DRYD-1305: Add tooltip prop for DateInput #22

Merged
merged 3 commits into from
Jun 14, 2024

Conversation

mikejritter
Copy link
Contributor

What does this do?

  • Adds a tooltip prop to DateInput
  • Add title to LineInput to display provided tooltips

Why are we doing this? (with JIRA link)
Jira: https://collectionspace.atlassian.net/browse/DRYD-1305

This is the first PR for adding instructions for non-standard interactions. It allows a tooltip to be passed in as a prop so that it can provide instructions for use of the input container.

How should this be tested? Do these changes have associated tests?

  • Run npm run lint and npm run test to ensure nothing broke
  • Rebuild and deploy alongside the cspace-ui PR
  • Mouseover a DateInput and see that a message is provided with instructions about usage

Dependencies for merging? Releasing to production?
Requires cspace-ui PR in order to provide any functionality so that internationalization can be performed on the message if desired. I was considering adding a non-internationalized version of the tooltip here as well, which would be easy to do.

I believe we need to add something similar to the other dropdown inputs, but I need to check the audit document first to be sure.

Has the application documentation been updated for these changes?
No

Did someone actually run this code to verify it works?
@mikejritter tested locally

Copy link

codecov bot commented Jun 7, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 99.76%. Comparing base (cd5c04b) to head (554429e).

Additional details and impacted files
@@           Coverage Diff           @@
##           master      #22   +/-   ##
=======================================
  Coverage   99.76%   99.76%           
=======================================
  Files          52       52           
  Lines        2111     2111           
  Branches      478      478           
=======================================
  Hits         2106     2106           
  Misses          5        5           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Copy link
Contributor

@ray-lee ray-lee left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This looks fine. There should probably be a test to show that setting the tooltop prop results in the title attribute being set.

@mikejritter
Copy link
Contributor Author

@ray-lee I added two tests for the tooltip prop, one for DateInput and one for LineInput.

Copy link
Contributor

@ray-lee ray-lee left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good, thanks!

@ray-lee ray-lee merged commit c20d93b into collectionspace:master Jun 14, 2024
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants