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

fix(Dropdown): remove extra space at the end #17751

Conversation

tekno0ryder
Copy link
Contributor

Closes #17750

Changelog

Changed

  • Changed from grid to flex so that it only add gap if there is more than 1 child element to the wrapper.
    • are there any drawbacks to this change?

Removed

  • Removed .#{$prefix}--form-requirement it seems not used since there is no reference from Dropdown.tsx

Testing / Reviewing

No other inline elements:
Screenshot 2024-10-15 at 7 29 47 PM

When there are other inline elements:
Screenshot 2024-10-15 at 7 07 10 PM

@tekno0ryder tekno0ryder requested a review from a team as a code owner October 15, 2024 16:33
Copy link
Contributor

github-actions bot commented Oct 15, 2024

All contributors have signed the DCO.
Posted by the DCO Assistant Lite bot.

@tekno0ryder
Copy link
Contributor Author

I have read the DCO document and I hereby sign the DCO.

Copy link

netlify bot commented Oct 15, 2024

Deploy Preview for carbon-elements ready!

Name Link
🔨 Latest commit 2edd95c
🔍 Latest deploy log https://app.netlify.com/sites/carbon-elements/deploys/671aa4a9834bbf000837a31f
😎 Deploy Preview https://deploy-preview-17751--carbon-elements.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

@tekno0ryder tekno0ryder force-pushed the fix/17750_dropdown_alignment branch 2 times, most recently from 82fd126 to 6760d96 Compare October 15, 2024 16:41
Copy link

netlify bot commented Oct 15, 2024

Deploy Preview for v11-carbon-react ready!

Built without sensitive environment variables

Name Link
🔨 Latest commit 1b2e16e
🔍 Latest deploy log https://app.netlify.com/sites/v11-carbon-react/deploys/670e995fefd2400008767b01
😎 Deploy Preview https://deploy-preview-17751--v11-carbon-react.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

Copy link

netlify bot commented Oct 15, 2024

Deploy Preview for v11-carbon-react ready!

Built without sensitive environment variables

Name Link
🔨 Latest commit 2edd95c
🔍 Latest deploy log https://app.netlify.com/sites/v11-carbon-react/deploys/671aa4a9418e7c00087a055f
😎 Deploy Preview https://deploy-preview-17751--v11-carbon-react.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

Copy link

codecov bot commented Oct 15, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 80.19%. Comparing base (756834c) to head (2edd95c).
Report is 48 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main   #17751      +/-   ##
==========================================
+ Coverage   79.33%   80.19%   +0.86%     
==========================================
  Files         406      406              
  Lines       14019    14040      +21     
  Branches     4388     4399      +11     
==========================================
+ Hits        11122    11260     +138     
+ Misses       2731     2613     -118     
- Partials      166      167       +1     

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

Copy link
Member

@alisonjoseph alisonjoseph left a comment

Choose a reason for hiding this comment

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

This breaks the error and warning states for the component. You can go to the playground story and set inline to true. Form requirement classes are used to display the error and warning messages, so those shouldn't be removed. Will probably need a different approach to fix this bug.

Also you'll probably want to use the hideLabel prop vs. setting the title to empty for a11y purposes. (this doesn't fix the grid gap issue however)

@tekno0ryder tekno0ryder force-pushed the fix/17750_dropdown_alignment branch from 6760d96 to 2edd95c Compare October 24, 2024 19:48
Copy link

netlify bot commented Oct 24, 2024

Deploy Preview for v11-carbon-web-components failed. Why did it fail? →

Name Link
🔨 Latest commit 2edd95c
🔍 Latest deploy log https://app.netlify.com/sites/v11-carbon-web-components/deploys/671aa4a95460e700083342b5

@tekno0ryder
Copy link
Contributor Author

@alisonjoseph Thanks for the review, have another I look I found relying on grid system to add more rows when needed works in all cases.

Screenshot 2024-10-24 at 10 42 12 PM Screenshot 2024-10-24 at 10 41 50 PM Screenshot 2024-10-24 at 10 23 30 PM

Copy link
Member

@alisonjoseph alisonjoseph left a comment

Choose a reason for hiding this comment

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

LGTM! Thanks

@ariellalgilmore ariellalgilmore added this pull request to the merge queue Oct 24, 2024
Merged via the queue into carbon-design-system:main with commit d73bd2c Oct 24, 2024
36 of 40 checks passed
@tekno0ryder tekno0ryder deleted the fix/17750_dropdown_alignment branch October 25, 2024 00:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Bug]: Dropdown extra space at the end causes mis-alignments
3 participants