@pingux/astro 2.105.0 → 2.106.0-alpha.0
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/lib/cjs/components/OverlayPanel/OverlayPanel.stories.d.ts +1 -1
- package/lib/cjs/components/OverlayPanel/OverlayPanel.stories.js +145 -335
- package/lib/cjs/components/Text/Text.styles.d.ts +6 -0
- package/lib/cjs/components/Text/Text.styles.js +2 -2
- package/lib/cjs/styles/themeOverrides/stories/OverlayPanel.chromatic.stories.d.ts +7 -0
- package/lib/cjs/styles/themeOverrides/stories/OverlayPanel.chromatic.stories.js +68 -0
- package/lib/cjs/utils/designUtils/figmaLinks.d.ts +3 -0
- package/lib/cjs/utils/designUtils/figmaLinks.js +3 -0
- package/lib/components/OverlayPanel/OverlayPanel.stories.js +143 -333
- package/lib/components/Text/Text.styles.js +2 -2
- package/lib/styles/themeOverrides/stories/OverlayPanel.chromatic.stories.js +53 -0
- package/lib/utils/designUtils/figmaLinks.js +3 -0
- package/package.json +1 -1
@@ -0,0 +1,53 @@
|
|
1
|
+
import React, { useRef } from 'react';
|
2
|
+
import AccountIcon from '@pingux/mdi-react/AccountIcon';
|
3
|
+
import { useOverlayPanelState } from '../../../hooks';
|
4
|
+
import { Box, Button, OverlayPanel, OverlayProvider, PanelHeader, PanelHeaderCloseButton, Text } from '../../../index';
|
5
|
+
import { jsx as ___EmotionJSX } from "@emotion/react";
|
6
|
+
export default {
|
7
|
+
title: 'Chromatic Only OverlayPanel',
|
8
|
+
component: OverlayPanel
|
9
|
+
};
|
10
|
+
export var Default = function Default() {
|
11
|
+
var _useOverlayPanelState = useOverlayPanelState({
|
12
|
+
isDefaultOpen: true
|
13
|
+
}),
|
14
|
+
state = _useOverlayPanelState.state,
|
15
|
+
onClose = _useOverlayPanelState.onClose;
|
16
|
+
var triggerRef = useRef(null);
|
17
|
+
return ___EmotionJSX(OverlayProvider, null, ___EmotionJSX(Box, {
|
18
|
+
sx: {
|
19
|
+
gap: '25px'
|
20
|
+
}
|
21
|
+
}, ___EmotionJSX(Text, null, "Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur."), ___EmotionJSX(Button, {
|
22
|
+
ref: triggerRef,
|
23
|
+
onPress: state.open,
|
24
|
+
"aria-expanded": state.isOpen,
|
25
|
+
sx: {
|
26
|
+
maxWidth: 'fit-content'
|
27
|
+
}
|
28
|
+
}, "Open Panel"), ___EmotionJSX(OverlayPanel, {
|
29
|
+
isOpen: true,
|
30
|
+
isTransitioning: state.isTransitioning,
|
31
|
+
state: state,
|
32
|
+
triggerRef: triggerRef,
|
33
|
+
sx: {
|
34
|
+
p: 0
|
35
|
+
}
|
36
|
+
}, ___EmotionJSX(PanelHeader, {
|
37
|
+
data: {
|
38
|
+
icon: AccountIcon,
|
39
|
+
text: 'Fons Vernall',
|
40
|
+
subtext: 'rad_developer@pingidentity.com'
|
41
|
+
}
|
42
|
+
}, ___EmotionJSX(PanelHeaderCloseButton, {
|
43
|
+
onPress: function onPress() {
|
44
|
+
onClose(state, triggerRef);
|
45
|
+
}
|
46
|
+
})), ___EmotionJSX(Box, {
|
47
|
+
sx: {
|
48
|
+
p: 25
|
49
|
+
}
|
50
|
+
}, ___EmotionJSX(Text, {
|
51
|
+
pt: "md"
|
52
|
+
}, "Children render here.")))));
|
53
|
+
};
|
@@ -148,6 +148,9 @@ export var FIGMA_LINKS = {
|
|
148
148
|
OnewayToBidirectionalArrow: {
|
149
149
|
"default": 'https://www.figma.com/file/bpbEw54gTTcdIiZs4PKK1p/Astro-Specs?type=design&node-id=43504-1214&mode=design&t=R4kdj0liRHxsqbV5-0'
|
150
150
|
},
|
151
|
+
overlayPanel: {
|
152
|
+
"default": 'https://www.figma.com/proto/bpbEw54gTTcdIiZs4PKK1p/Astro-Specs?node-id=58765-3123&t=qSq8hhXsmFeytcZL-1'
|
153
|
+
},
|
151
154
|
panelContent: {
|
152
155
|
displayPanel: 'https://www.figma.com/file/bpbEw54gTTcdIiZs4PKK1p/Astro-Specs?node-id=43431%3A4249&mode=dev',
|
153
156
|
editPanel: 'https://www.figma.com/file/bpbEw54gTTcdIiZs4PKK1p/Astro-Specs?node-id=5013%3A15377&mode=dev'
|