@loadsmart/loadsmart-ui 5.6.1 → 5.6.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@loadsmart/loadsmart-ui",
3
- "version": "5.6.1",
3
+ "version": "5.6.2",
4
4
  "description": "Miranda UI, a React UI library",
5
5
  "main": "dist",
6
6
  "files": [
@@ -52,3 +52,32 @@ export const Playground: Story<DrawerProps> = ({ open, ...others }: DrawerProps)
52
52
  Playground.args = {
53
53
  open: false,
54
54
  }
55
+
56
+ export const SmallerContentPlayground: Story<DrawerProps> = ({ open, ...others }: DrawerProps) => {
57
+ const { open: isOpen, show, hide } = useDrawer({ open: open })
58
+
59
+ return (
60
+ <div className="flex flex-col space-y-2">
61
+ <div className="flex items-center">
62
+ <Button onClick={show}>Open Drawer</Button>
63
+ <Drawer {...others} open={isOpen} onClose={hide}>
64
+ <Drawer.Header>Drawer Header</Drawer.Header>
65
+ <Drawer.Body>
66
+ {TWENTY_SIZE_ARR.slice(0, 3).map((_, index) => (
67
+ <h1 key={index} className="mb-6">
68
+ Drawer Body...
69
+ </h1>
70
+ ))}
71
+ </Drawer.Body>
72
+ <Drawer.Footer className="justify-end">
73
+ <Button onClick={hide}>Close Drawer</Button>
74
+ </Drawer.Footer>
75
+ </Drawer>
76
+ </div>
77
+ </div>
78
+ )
79
+ }
80
+
81
+ SmallerContentPlayground.args = {
82
+ open: false,
83
+ }
@@ -95,6 +95,7 @@ const StyledHeader = styled.header`
95
95
  const StyledBody = styled.div`
96
96
  display: flex;
97
97
  flex-direction: column;
98
+ height: 100%;
98
99
 
99
100
  padding: ${token('space-xl')};
100
101