@pingux/astro 1.1.0-alpha.12 → 1.1.0-alpha.16
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/NavBar/NavBar.js +38 -0
- package/lib/cjs/components/NavBar/NavBar.stories.js +679 -0
- package/lib/cjs/components/NavBar/NavBar.test.js +116 -0
- package/lib/cjs/components/NavBar/index.js +18 -0
- package/lib/cjs/components/NavBarSection/NavBarItemBody.js +56 -0
- package/lib/cjs/components/NavBarSection/NavBarItemHeader.js +47 -0
- package/lib/cjs/components/NavBarSection/NavBarSection.js +82 -0
- package/lib/cjs/components/NavBarSection/index.js +18 -0
- package/lib/cjs/components/OverlayPanel/OverlayPanel.js +53 -6
- package/lib/cjs/components/OverlayPanel/OverlayPanel.stories.js +59 -47
- package/lib/cjs/components/OverlayPanel/OverlayPanel.test.js +84 -0
- package/lib/cjs/components/Separator/Separator.js +1 -1
- package/lib/cjs/hooks/useOverlayPanelState/useOverlayPanelState.js +20 -1
- package/lib/cjs/hooks/useOverlayPanelState/useOverlayPanelState.test.js +7 -3
- package/lib/cjs/index.js +74 -30
- package/lib/cjs/styles/variants/accordion.js +32 -1
- package/lib/cjs/styles/variants/boxes.js +24 -1
- package/lib/cjs/styles/variants/buttons.js +28 -0
- package/lib/cjs/styles/variants/link.js +1 -1
- package/lib/cjs/styles/variants/separator.js +46 -3
- package/lib/cjs/styles/variants/text.js +15 -0
- package/lib/components/NavBar/NavBar.js +24 -0
- package/lib/components/NavBar/NavBar.stories.js +650 -0
- package/lib/components/NavBar/NavBar.test.js +92 -0
- package/lib/components/NavBar/index.js +1 -0
- package/lib/components/NavBarSection/NavBarItemBody.js +37 -0
- package/lib/components/NavBarSection/NavBarItemHeader.js +31 -0
- package/lib/components/NavBarSection/NavBarSection.js +65 -0
- package/lib/components/NavBarSection/index.js +1 -0
- package/lib/components/OverlayPanel/OverlayPanel.js +52 -8
- package/lib/components/OverlayPanel/OverlayPanel.stories.js +59 -49
- package/lib/components/OverlayPanel/OverlayPanel.test.js +73 -1
- package/lib/components/Separator/Separator.js +1 -1
- package/lib/hooks/useOverlayPanelState/useOverlayPanelState.js +20 -1
- package/lib/hooks/useOverlayPanelState/useOverlayPanelState.test.js +7 -3
- package/lib/index.js +4 -0
- package/lib/styles/variants/accordion.js +32 -1
- package/lib/styles/variants/boxes.js +24 -1
- package/lib/styles/variants/buttons.js +28 -0
- package/lib/styles/variants/link.js +1 -1
- package/lib/styles/variants/separator.js +33 -1
- package/lib/styles/variants/text.js +15 -0
- package/package.json +2 -2
@@ -56,6 +56,36 @@ var accordionGridHeader = {
|
|
56
56
|
}
|
57
57
|
}
|
58
58
|
};
|
59
|
+
var accordionGridHeaderNav = {
|
60
|
+
padding: '10px 15px 10px 15px',
|
61
|
+
cursor: 'pointer',
|
62
|
+
minHeight: '40px',
|
63
|
+
lineHeight: '30px',
|
64
|
+
outline: 'none',
|
65
|
+
display: 'flex',
|
66
|
+
justifyContent: 'flex-start',
|
67
|
+
flexShrink: 0,
|
68
|
+
wordBreak: 'inherit',
|
69
|
+
whiteSpace: 'nowrap',
|
70
|
+
color: 'neutral.95',
|
71
|
+
flexGrow: 1,
|
72
|
+
fontWeight: 0,
|
73
|
+
fontSize: '16px',
|
74
|
+
mt: '5px',
|
75
|
+
'&.is-focused': {
|
76
|
+
outline: 'none',
|
77
|
+
boxShadow: 'focus',
|
78
|
+
WebkitBoxShadow: 'focus',
|
79
|
+
MozBoxShadow: 'focus'
|
80
|
+
},
|
81
|
+
'&.is-hovered': {
|
82
|
+
backgroundColor: 'accent.10',
|
83
|
+
boxShadow: 'inset 2px 0 0 0 white'
|
84
|
+
},
|
85
|
+
'&.is-pressed': {
|
86
|
+
backgroundColor: 'accent.10'
|
87
|
+
}
|
88
|
+
};
|
59
89
|
var accordionGridBody = {
|
60
90
|
display: 'none !important',
|
61
91
|
pl: 'sm',
|
@@ -69,5 +99,6 @@ export default {
|
|
69
99
|
accordionGridBody: accordionGridBody,
|
70
100
|
accordionTitle: accordionTitle,
|
71
101
|
accordion: accordion,
|
72
|
-
accordionBody: accordionBody
|
102
|
+
accordionBody: accordionBody,
|
103
|
+
accordionGridHeaderNav: accordionGridHeaderNav
|
73
104
|
};
|
@@ -189,6 +189,26 @@ var expandableRow = {
|
|
189
189
|
}
|
190
190
|
}
|
191
191
|
};
|
192
|
+
var navBar = {
|
193
|
+
height: '100%',
|
194
|
+
width: '230px',
|
195
|
+
position: 'absolute',
|
196
|
+
zIndex: '1',
|
197
|
+
top: '0',
|
198
|
+
left: '0',
|
199
|
+
backgroundColor: 'accent.20',
|
200
|
+
overflowY: 'hidden'
|
201
|
+
};
|
202
|
+
var navBarSectionContainer = {
|
203
|
+
height: '100%',
|
204
|
+
maxHeight: '100%',
|
205
|
+
overflowY: 'overlay !important'
|
206
|
+
};
|
207
|
+
var navBarItemHeaderContainer = {
|
208
|
+
flexGrow: 1,
|
209
|
+
alignItems: 'center',
|
210
|
+
maxWidth: '180px'
|
211
|
+
};
|
192
212
|
var datePicker = {
|
193
213
|
'.react-calendar': {
|
194
214
|
width: 280,
|
@@ -270,5 +290,8 @@ export default {
|
|
270
290
|
radioContainer: radioContainer,
|
271
291
|
scrollbox: scrollbox,
|
272
292
|
topShadowScrollbox: topShadowScrollbox,
|
273
|
-
bottomShadowScrollbox: bottomShadowScrollbox
|
293
|
+
bottomShadowScrollbox: bottomShadowScrollbox,
|
294
|
+
navBar: navBar,
|
295
|
+
navBarSectionContainer: navBarSectionContainer,
|
296
|
+
navBarItemHeaderContainer: navBarItemHeaderContainer
|
274
297
|
};
|
@@ -52,6 +52,33 @@ var defaultFocus = {
|
|
52
52
|
outline: 'none',
|
53
53
|
boxShadow: 'focus'
|
54
54
|
};
|
55
|
+
var navItemButton = {
|
56
|
+
textDecoration: 'none',
|
57
|
+
outline: 'none',
|
58
|
+
cursor: 'pointer',
|
59
|
+
borderRadius: 0,
|
60
|
+
backgroundColor: 'transparent',
|
61
|
+
paddingTop: '5px',
|
62
|
+
paddingBottom: '5px',
|
63
|
+
display: 'block',
|
64
|
+
color: 'neutral.95',
|
65
|
+
fontSize: 'sm',
|
66
|
+
fontWeight: 1,
|
67
|
+
flexGrow: '1',
|
68
|
+
width: '100%',
|
69
|
+
textAlign: 'left',
|
70
|
+
lineHeight: '16px',
|
71
|
+
whiteSpace: 'break-spaces',
|
72
|
+
overflowWrap: 'break-word',
|
73
|
+
maxWidth: '100%',
|
74
|
+
wordWrap: 'break-word',
|
75
|
+
wordBreak: 'break-word',
|
76
|
+
'&.is-focused': _objectSpread({}, defaultFocus),
|
77
|
+
'&.is-hovered': {
|
78
|
+
bg: 'accent.10',
|
79
|
+
boxShadow: 'inset 2px 0 0 0 white'
|
80
|
+
}
|
81
|
+
};
|
55
82
|
var iconButton = {
|
56
83
|
justifyContent: 'center',
|
57
84
|
appearance: 'none',
|
@@ -516,6 +543,7 @@ export default {
|
|
516
543
|
text: text,
|
517
544
|
helpHint: helpHint,
|
518
545
|
modalCloseButton: modalCloseButton,
|
546
|
+
navItemButton: navItemButton,
|
519
547
|
applicationPortalPinned: applicationPortalPinned,
|
520
548
|
applicationPortal: applicationPortal,
|
521
549
|
square: square,
|
@@ -1,4 +1,18 @@
|
|
1
|
-
|
1
|
+
import _Object$defineProperty from "@babel/runtime-corejs3/core-js-stable/object/define-property";
|
2
|
+
import _Object$defineProperties from "@babel/runtime-corejs3/core-js-stable/object/define-properties";
|
3
|
+
import _Object$getOwnPropertyDescriptors from "@babel/runtime-corejs3/core-js-stable/object/get-own-property-descriptors";
|
4
|
+
import _forEachInstanceProperty from "@babel/runtime-corejs3/core-js-stable/instance/for-each";
|
5
|
+
import _Object$getOwnPropertyDescriptor from "@babel/runtime-corejs3/core-js-stable/object/get-own-property-descriptor";
|
6
|
+
import _filterInstanceProperty from "@babel/runtime-corejs3/core-js-stable/instance/filter";
|
7
|
+
import _Object$getOwnPropertySymbols from "@babel/runtime-corejs3/core-js-stable/object/get-own-property-symbols";
|
8
|
+
import _Object$keys from "@babel/runtime-corejs3/core-js-stable/object/keys";
|
9
|
+
import _defineProperty from "@babel/runtime-corejs3/helpers/esm/defineProperty";
|
10
|
+
|
11
|
+
function ownKeys(object, enumerableOnly) { var keys = _Object$keys(object); if (_Object$getOwnPropertySymbols) { var symbols = _Object$getOwnPropertySymbols(object); if (enumerableOnly) symbols = _filterInstanceProperty(symbols).call(symbols, function (sym) { return _Object$getOwnPropertyDescriptor(object, sym).enumerable; }); keys.push.apply(keys, symbols); } return keys; }
|
12
|
+
|
13
|
+
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i] != null ? arguments[i] : {}; if (i % 2) { var _context; _forEachInstanceProperty(_context = ownKeys(Object(source), true)).call(_context, function (key) { _defineProperty(target, key, source[key]); }); } else if (_Object$getOwnPropertyDescriptors) { _Object$defineProperties(target, _Object$getOwnPropertyDescriptors(source)); } else { var _context2; _forEachInstanceProperty(_context2 = ownKeys(Object(source))).call(_context2, function (key) { _Object$defineProperty(target, key, _Object$getOwnPropertyDescriptor(source, key)); }); } } return target; }
|
14
|
+
|
15
|
+
var base = {
|
2
16
|
bg: 'neutral.80',
|
3
17
|
width: '100%',
|
4
18
|
height: '1px',
|
@@ -8,4 +22,22 @@ export default {
|
|
8
22
|
height: '100%',
|
9
23
|
mx: '5px'
|
10
24
|
}
|
25
|
+
};
|
26
|
+
|
27
|
+
var navBarSeparator = _objectSpread(_objectSpread({}, base), {}, {
|
28
|
+
width: '100%',
|
29
|
+
backgroundColor: 'neutral.60'
|
30
|
+
});
|
31
|
+
|
32
|
+
var navBarSubtitleSeparator = _objectSpread(_objectSpread({}, base), {}, {
|
33
|
+
ml: '45px',
|
34
|
+
width: 'calc(100% - 75px)',
|
35
|
+
mb: '15px',
|
36
|
+
backgroundColor: 'neutral.60'
|
37
|
+
});
|
38
|
+
|
39
|
+
export default {
|
40
|
+
base: base,
|
41
|
+
navBarSeparator: navBarSeparator,
|
42
|
+
navBarSubtitleSeparator: navBarSubtitleSeparator
|
11
43
|
};
|
@@ -119,6 +119,19 @@ var expandableRow = {
|
|
119
119
|
}
|
120
120
|
}
|
121
121
|
};
|
122
|
+
var navBarSubtitle = {
|
123
|
+
fontWeight: 3,
|
124
|
+
fontSize: '11px',
|
125
|
+
color: 'accent.80'
|
126
|
+
};
|
127
|
+
|
128
|
+
var navBarHeaderText = _objectSpread(_objectSpread({}, wordWrap), {}, {
|
129
|
+
whiteSpace: 'break-spaces',
|
130
|
+
lineHeight: '13px',
|
131
|
+
fontSize: '13px',
|
132
|
+
fontWeight: 1
|
133
|
+
});
|
134
|
+
|
122
135
|
export var text = {
|
123
136
|
base: base,
|
124
137
|
bodyStrong: _objectSpread(_objectSpread({}, wordWrap), {}, {
|
@@ -182,6 +195,8 @@ export var text = {
|
|
182
195
|
textOverflow: 'ellipsis'
|
183
196
|
}),
|
184
197
|
expandableRow: expandableRow,
|
198
|
+
navBarHeaderText: navBarHeaderText,
|
199
|
+
navBarSubtitle: navBarSubtitle,
|
185
200
|
placeholder: {
|
186
201
|
fontWeight: -1,
|
187
202
|
color: 'text.secondary',
|
package/package.json
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
{
|
2
2
|
"name": "@pingux/astro",
|
3
|
-
"version": "1.1.0-alpha.
|
3
|
+
"version": "1.1.0-alpha.16",
|
4
4
|
"description": "PingUX themeable React component library",
|
5
5
|
"author": "uxdev@pingidentity.com",
|
6
6
|
"license": "Apache-2.0",
|
@@ -78,7 +78,7 @@
|
|
78
78
|
"@react-aria/color": "^3.0.0-beta.2",
|
79
79
|
"@react-aria/combobox": "^3.0.0",
|
80
80
|
"@react-aria/dialog": "^3.1.2",
|
81
|
-
"@react-aria/focus": "^3.
|
81
|
+
"@react-aria/focus": "^3.5.0",
|
82
82
|
"@react-aria/grid": "^3.0.0-beta.1",
|
83
83
|
"@react-aria/i18n": "^3.3.0",
|
84
84
|
"@react-aria/interactions": "^3.5.0",
|