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

[FC-131196]: Add optional tooltip for input field to support AMB device capabilities #960

Merged
merged 2 commits into from
Jan 15, 2025

Conversation

shalini-venkat
Copy link
Collaborator

@shalini-venkat shalini-venkat commented Jan 7, 2025

Business usecase: For AMB Device Capabilities field, need to add tooltip to show the expanded content of the field on hover of the input field value.

Solution: Add provision to show tooltip on hover of the input fields --> Added support for an optional tooltip feature in crayons. Passed props from unity_frontend to the crayons repo, during the form schema construction, for the AMB device capabilities field.

FR link - https://freshworks.freshrelease.com/ws/FC/tasks/FC-131196
User story - https://freshworks.freshrelease.com/ws/FC/tasks/FC-109926

Checklist:

  • My code follows the code style of this project.
  • My change requires a change to the documentation.
  • I have updated the documentation accordingly.
  • I have added tests to cover my changes.
  • All new and existing tests passed.
  • My commits have standard messages as mentioned in Contributing Guidelines

How Has This Been Tested?

1. Tooltip with header and mapped values:

Screenshot 2025-01-10 at 11 31 18 AM

2. Ellipsis shown for overflowing text:

Screen.Recording.2025-01-07.at.10.25.12.AM.mov

…ow tooltip for AMB fields

Based on the properties passed from unity_
@shalini-venkat shalini-venkat changed the title feat(component): Add optional tooltip for input field to support AMB device capabilities [FC-131196]: Add optional tooltip for input field to support AMB device capabilities Jan 9, 2025
Copy link
Collaborator

@srivatsan7 srivatsan7 left a comment

Choose a reason for hiding this comment

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

LGTM
@prasanna-vijayan Please check this!

@@ -119,6 +119,10 @@ $warning-color: $color-casablanca-300;
background-color: $input-disabled-bg;
pointer-events: none;
}

&.truncate {

Choose a reason for hiding this comment

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

Shouldnt we add overflow: hidden and white-space: nowrap to show the ellipsis?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Ellipsis is working, without the overflow: hidden and white-space: nowrap styles being added explicitly.

packages/crayons-core/src/components.d.ts Outdated Show resolved Hide resolved
@shalini-venkat shalini-venkat merged commit 589f482 into next Jan 15, 2025
1 of 2 checks passed
@shalini-venkat shalini-venkat deleted the amb_device_capabilities branch January 15, 2025 08:26
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.

4 participants