Conversation
There was a problem hiding this comment.
Pull Request Overview
This PR implements a size prop for the Drawer component, allowing consumers to specify predefined sizes (small, medium, large, extraLarge) for both sidebar and tray drawer types. The changes refactor the size handling to separate user-controllable sizes from the fullscreen state, which is now managed independently via a boolean flag.
Key Changes:
- Added a
sizeprop with four predefined size options: 'small', 'medium', 'large', and 'extraLarge' - Refactored fullscreen functionality to use
isFullscreenstate instead of mixing it with size values - Updated default size from 'normal' to 'medium', with specific width/height values for each size option
Reviewed Changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 2 comments.
| File | Description |
|---|---|
| packages/utah-design-system/src/components/Drawer.tsx | Implements size prop with compound variants for sidebar widths and tray heights; refactors fullscreen state management |
| packages/utah-design-system/src/components/Drawer.stories.tsx | Adds Storybook examples demonstrating the new size prop with 'extraLarge' and 'large' options |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
|
Visit the preview URL for this PR (updated for commit 53604f3): |
There was a problem hiding this comment.
Pull Request Overview
Copilot reviewed 3 out of 4 changed files in this pull request and generated 1 comment.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
steveoh
left a comment
There was a problem hiding this comment.
nice idea. Was screen size a consideration for when to show what size?
If you are referring to raster, no, I'm not dynamically determining the size based on the screen size. |
|
No I'm not referring to raster but sizing in general. |
I just tried to come up with some consistent ranges. |
3a2fb1a to
e4fa24a
Compare
My use case is I want more room in the side bar for raster. Passing the size class directly to the component got complicated with the varients so I went with a set of predefined sizes.