RocketCommunicationsInc / astro

Astro UXDS is a collection of guidelines, patterns and components for designing space-based user interface applications.
https://astrouxds.com
Other
108 stars 25 forks source link

rux-clock component is misaligned when labels are hidden #999

Closed nortonprojects closed 1 year ago

nortonprojects commented 1 year ago

Describe the bug When labels are hidden from the rux-clock component, it stays top-aligned. The clock height should shrink to match, or the content should be center-justified.

To Reproduce Steps to reproduce the behavior:

  1. Go to 'https://astro-components.netlify.app/?path=/story/components-clock--other-variants&args=hideLabels:true'
  2. Scroll down to 'Hide Labels'
  3. See error in inspector

Environment (please complete the following information):

Additional context Add any other context about the problem here.

micahjones13 commented 1 year ago

Hey Jacob, thanks for raising this! Looks like we have a set height on clock, so that's why it's retaining it's full height rather than collapsing to fit when hide-labels is true. I'm going to address that and make a PR real quick!

As for the console error, that's Storybook related and not anything to do with our component. Only the default stories can be wired up to controls in Storybook, so if you're viewing an 'All Variants' page and have a query param string that usually toggles a control, you'll see that warning in the console.