@pingux/astro 1.31.0-alpha.0 → 1.31.0-alpha.10
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/Card/Card.stories.js +29 -2
- package/lib/cjs/components/Chip/Chip.js +37 -7
- package/lib/cjs/components/Chip/Chip.test.js +8 -0
- package/lib/cjs/components/DataTable/DataTable.test.js +0 -2
- package/lib/cjs/components/EnvironmentBreadcrumb/EnvironmentBreadcrumb.stories.js +84 -2
- package/lib/cjs/components/ListView/ListView.js +2 -0
- package/lib/cjs/components/ListView/ListView.stories.js +2 -1
- package/lib/cjs/components/ListViewItem/ListViewItem.js +5 -2
- package/lib/cjs/components/OverlayPanel/OverlayPanel.stories.js +14 -7
- package/lib/cjs/components/RequirementsList/RequirementsList.js +5 -1
- package/lib/cjs/components/RequirementsList/RequirementsList.test.js +2 -2
- package/lib/cjs/components/SearchField/SearchField.js +10 -0
- package/lib/cjs/components/SearchField/SearchField.test.js +27 -0
- package/lib/cjs/components/TabPicker/TabPicker.js +1 -0
- package/lib/cjs/components/Table/Table.stories.js +9 -27
- package/lib/cjs/components/Table/Table.test.js +9 -1
- package/lib/cjs/components/TableCaption/TableCaption.js +43 -0
- package/lib/cjs/components/TableCaption/index.js +18 -0
- package/lib/cjs/components/Tabs/Tabs.stories.js +4 -2
- package/lib/cjs/components/Tabs/Tabs.test.js +6 -4
- package/lib/cjs/recipes/LinkedListView.stories.js +424 -0
- package/lib/cjs/recipes/ListAndPanel.stories.js +32 -1
- package/lib/cjs/styles/variants/boxes.js +19 -1
- package/lib/cjs/styles/variants/table.js +6 -0
- package/lib/components/Card/Card.stories.js +29 -2
- package/lib/components/Chip/Chip.js +30 -4
- package/lib/components/Chip/Chip.test.js +8 -0
- package/lib/components/DataTable/DataTable.test.js +0 -2
- package/lib/components/EnvironmentBreadcrumb/EnvironmentBreadcrumb.stories.js +79 -0
- package/lib/components/ListView/ListView.js +2 -0
- package/lib/components/ListView/ListView.stories.js +2 -1
- package/lib/components/ListViewItem/ListViewItem.js +5 -2
- package/lib/components/OverlayPanel/OverlayPanel.stories.js +14 -7
- package/lib/components/RequirementsList/RequirementsList.js +5 -1
- package/lib/components/RequirementsList/RequirementsList.test.js +2 -2
- package/lib/components/SearchField/SearchField.js +10 -0
- package/lib/components/SearchField/SearchField.test.js +20 -1
- package/lib/components/TabPicker/TabPicker.js +1 -0
- package/lib/components/Table/Table.stories.js +7 -27
- package/lib/components/Table/Table.test.js +7 -1
- package/lib/components/TableCaption/TableCaption.js +27 -0
- package/lib/components/TableCaption/index.js +1 -0
- package/lib/components/Tabs/Tabs.stories.js +4 -2
- package/lib/components/Tabs/Tabs.test.js +6 -4
- package/lib/recipes/LinkedListView.stories.js +393 -0
- package/lib/recipes/ListAndPanel.stories.js +32 -2
- package/lib/styles/variants/boxes.js +19 -1
- package/lib/styles/variants/table.js +6 -0
- package/package.json +1 -1
@@ -0,0 +1,393 @@
|
|
1
|
+
import _concatInstanceProperty from "@babel/runtime-corejs3/core-js-stable/instance/concat";
|
2
|
+
import _slicedToArray from "@babel/runtime-corejs3/helpers/esm/slicedToArray";
|
3
|
+
import _extends from "@babel/runtime-corejs3/helpers/esm/extends";
|
4
|
+
import _spliceInstanceProperty from "@babel/runtime-corejs3/core-js-stable/instance/splice";
|
5
|
+
import _findIndexInstanceProperty from "@babel/runtime-corejs3/core-js-stable/instance/find-index";
|
6
|
+
import _forEachInstanceProperty from "@babel/runtime-corejs3/core-js-stable/instance/for-each";
|
7
|
+
import React, { useState } from 'react';
|
8
|
+
import { Item } from '@react-stately/collections';
|
9
|
+
import DotsVerticalIcon from 'mdi-react/DotsVerticalIcon';
|
10
|
+
import { ListView, Text, Box, Icon, IconButton, Chip, Separator, OverlayProvider, PopoverMenu, Menu } from '../index';
|
11
|
+
import { jsx as ___EmotionJSX } from "@emotion/react";
|
12
|
+
export default {
|
13
|
+
title: 'Recipes/LinkedListView',
|
14
|
+
argTypes: {
|
15
|
+
loadingState: {
|
16
|
+
control: {
|
17
|
+
type: 'select'
|
18
|
+
}
|
19
|
+
},
|
20
|
+
disabledKeys: {
|
21
|
+
defaultValue: []
|
22
|
+
},
|
23
|
+
items: {
|
24
|
+
control: {
|
25
|
+
type: 'none'
|
26
|
+
}
|
27
|
+
},
|
28
|
+
onSelectionChange: {
|
29
|
+
control: 'none',
|
30
|
+
// eslint-disable-next-line no-console
|
31
|
+
defaultValue: console.log
|
32
|
+
}
|
33
|
+
}
|
34
|
+
};
|
35
|
+
var testData = [{
|
36
|
+
key: 'Default Risk Policy',
|
37
|
+
name: 'Default Risk Policy',
|
38
|
+
policyId: 'sdfasdfasdf-124123asdf',
|
39
|
+
id: '1',
|
40
|
+
hasSeparator: false,
|
41
|
+
hasInsetSeparator: true,
|
42
|
+
chipText: 'default',
|
43
|
+
expirationText: 'Expiring On: 2022-12-08',
|
44
|
+
childrenObjects: [{
|
45
|
+
key: 'Staging Policy',
|
46
|
+
name: 'Staging Policy',
|
47
|
+
policyId: '23423sdfsdf-124123asdf',
|
48
|
+
id: '4',
|
49
|
+
expirationText: 'Expiring On: 2022-12-08',
|
50
|
+
hasSeparator: true
|
51
|
+
}]
|
52
|
+
}, {
|
53
|
+
key: 'Policy4',
|
54
|
+
name: 'Policy4',
|
55
|
+
policyId: '9234890324k-124123asdf',
|
56
|
+
chipText: 'default',
|
57
|
+
id: '2',
|
58
|
+
hasSeparator: true
|
59
|
+
}, {
|
60
|
+
key: 'Policy5',
|
61
|
+
name: 'Policy5',
|
62
|
+
policyId: 'asdf23zaa-124123asdf',
|
63
|
+
id: '3'
|
64
|
+
}]; // IMPORTANT PLEASE READ
|
65
|
+
// in order for the list portion of this recipe to function correctly,
|
66
|
+
// the array of objects that will be used to create
|
67
|
+
// the production and staging rows, will need to be flat and sorted.
|
68
|
+
// I.e. the staging rows will need to immediately follow the prod row that they correspond to.
|
69
|
+
// This flat, sorted array will then be passed into the listview component as the items prop.
|
70
|
+
// You may not need these functions if you are able to change the data shape on the back end
|
71
|
+
// (which is reccomended for performance reasons)
|
72
|
+
|
73
|
+
var flattenArray = function flattenArray(array) {
|
74
|
+
var newArray = array;
|
75
|
+
|
76
|
+
_forEachInstanceProperty(newArray).call(newArray, function (item) {
|
77
|
+
if (item.childrenObjects) {
|
78
|
+
var _context;
|
79
|
+
|
80
|
+
_forEachInstanceProperty(_context = item.childrenObjects).call(_context, function (obj) {
|
81
|
+
var newObj = obj;
|
82
|
+
newObj.parentId = item.id;
|
83
|
+
newArray.push(newObj);
|
84
|
+
});
|
85
|
+
}
|
86
|
+
});
|
87
|
+
|
88
|
+
return newArray;
|
89
|
+
};
|
90
|
+
|
91
|
+
var testSort = function testSort(array) {
|
92
|
+
var newArray = array;
|
93
|
+
|
94
|
+
_forEachInstanceProperty(newArray).call(newArray, function (item, i) {
|
95
|
+
if (item.parentId) {
|
96
|
+
var thisindex = _findIndexInstanceProperty(newArray).call(newArray, function (object) {
|
97
|
+
return object.id === item.parentId;
|
98
|
+
});
|
99
|
+
|
100
|
+
var element = _spliceInstanceProperty(newArray).call(newArray, i, 1)[0];
|
101
|
+
|
102
|
+
_spliceInstanceProperty(newArray).call(newArray, thisindex + 1, 0, element);
|
103
|
+
}
|
104
|
+
});
|
105
|
+
|
106
|
+
return newArray;
|
107
|
+
};
|
108
|
+
|
109
|
+
var unsorted = flattenArray(testData);
|
110
|
+
var sorted = testSort(unsorted);
|
111
|
+
export var Default = function Default(_ref) {
|
112
|
+
var _context2;
|
113
|
+
|
114
|
+
var args = _extends({}, _ref);
|
115
|
+
|
116
|
+
var _useState = useState(_concatInstanceProperty(_context2 = []).call(_context2, sorted)),
|
117
|
+
_useState2 = _slicedToArray(_useState, 1),
|
118
|
+
theseItems = _useState2[0]; // svg of the bottom portion of the bracket, the portion with the L shaped hook.
|
119
|
+
|
120
|
+
|
121
|
+
var BottomBracket = function BottomBracket() {
|
122
|
+
var color = '#CACED3';
|
123
|
+
return ___EmotionJSX(Box, {
|
124
|
+
sx: {
|
125
|
+
width: '20px',
|
126
|
+
position: 'relative'
|
127
|
+
}
|
128
|
+
}, ___EmotionJSX(Box, {
|
129
|
+
flexBasis: "50%"
|
130
|
+
}, ___EmotionJSX("svg", {
|
131
|
+
xmlns: "http://www.w3.org/2000/svg",
|
132
|
+
version: "1.1",
|
133
|
+
preserveAspectRatio: "none",
|
134
|
+
viewBox: "0 0 10 10",
|
135
|
+
style: {
|
136
|
+
flexGrow: 1
|
137
|
+
}
|
138
|
+
}, ___EmotionJSX("title", null, "bracket-fill"), ___EmotionJSX("g", null, ___EmotionJSX("title", null, "Layer 1"), ___EmotionJSX("line", {
|
139
|
+
strokeLinecap: "undefined",
|
140
|
+
strokeLinejoin: "undefined",
|
141
|
+
y2: "0",
|
142
|
+
x2: "0",
|
143
|
+
y1: "15",
|
144
|
+
x1: "0",
|
145
|
+
stroke: color,
|
146
|
+
fill: "none"
|
147
|
+
}))), ___EmotionJSX("svg", {
|
148
|
+
width: "17",
|
149
|
+
height: "9",
|
150
|
+
viewBox: "0 0 17 9",
|
151
|
+
fill: "none",
|
152
|
+
xmlns: "http://www.w3.org/2000/svg"
|
153
|
+
}, ___EmotionJSX("g", {
|
154
|
+
clipPath: "url(#clip0_1900_8817)"
|
155
|
+
}, ___EmotionJSX("g", {
|
156
|
+
mask: "url(#mask0_1900_8817)"
|
157
|
+
}, ___EmotionJSX("rect", {
|
158
|
+
x: "0.5",
|
159
|
+
y: "-54.5",
|
160
|
+
width: "20",
|
161
|
+
height: "63",
|
162
|
+
rx: "4.5",
|
163
|
+
stroke: "#CACED3"
|
164
|
+
}))), ___EmotionJSX("defs", null, ___EmotionJSX("clipPath", {
|
165
|
+
id: "clip0_1900_8817"
|
166
|
+
}, ___EmotionJSX("rect", {
|
167
|
+
width: "1600",
|
168
|
+
height: "917",
|
169
|
+
fill: "white",
|
170
|
+
transform: "translate(-280 -419)"
|
171
|
+
}))))));
|
172
|
+
}; // the top portion of the bracket svg, this is basically just a straight vertical line.
|
173
|
+
|
174
|
+
|
175
|
+
var TopBracket = function TopBracket() {
|
176
|
+
var color = '#CACED3';
|
177
|
+
return ___EmotionJSX(Box, {
|
178
|
+
width: 15,
|
179
|
+
sx: {
|
180
|
+
position: 'absolute',
|
181
|
+
bottom: 0,
|
182
|
+
left: 12,
|
183
|
+
top: 55
|
184
|
+
}
|
185
|
+
}, ___EmotionJSX("svg", {
|
186
|
+
xmlns: "http://www.w3.org/2000/svg",
|
187
|
+
version: "1.1",
|
188
|
+
preserveAspectRatio: "none",
|
189
|
+
viewBox: "0 0 10 10",
|
190
|
+
style: {
|
191
|
+
flexGrow: 1
|
192
|
+
},
|
193
|
+
"data-testid": "isLastLayer"
|
194
|
+
}, ___EmotionJSX("title", null, "bracket-fill"), ___EmotionJSX("g", null, ___EmotionJSX("title", null, "Layer 3"), ___EmotionJSX("line", {
|
195
|
+
strokeLinecap: "undefined",
|
196
|
+
strokeLinejoin: "undefined",
|
197
|
+
y2: "0",
|
198
|
+
x2: "0",
|
199
|
+
y1: "10",
|
200
|
+
x1: "0",
|
201
|
+
stroke: color,
|
202
|
+
fill: "none"
|
203
|
+
}))));
|
204
|
+
}; // the vector shield and key icon.
|
205
|
+
|
206
|
+
|
207
|
+
var ShieldVector = function ShieldVector(props) {
|
208
|
+
return ___EmotionJSX("svg", _extends({
|
209
|
+
width: "19",
|
210
|
+
height: "23",
|
211
|
+
viewBox: "0 0 19 23",
|
212
|
+
xmlns: "http://www.w3.org/2000/svg"
|
213
|
+
}, props), ___EmotionJSX("path", {
|
214
|
+
d: "M9.5 7.33342C9.77627 7.33342 10.0412 7.44316 10.2366 7.63851C10.4319 7.83386 10.5417 8.09881 10.5417 8.37508C10.5417 8.65135 10.4319 8.9163 10.2366 9.11165C10.0412 9.307 9.77627 9.41675 9.5 9.41675C9.22373 9.41675 8.95878 9.307 8.76343 9.11165C8.56808 8.9163 8.45833 8.65135 8.45833 8.37508C8.45833 8.09881 8.56808 7.83386 8.76343 7.63851C8.95878 7.44316 9.22373 7.33342 9.5 7.33342ZM18.875 10.4584C18.875 16.2397 14.875 21.6459 9.5 22.9584C4.125 21.6459 0.125 16.2397 0.125 10.4584V4.20842L9.5 0.041748L18.875 4.20842V10.4584ZM9.5 5.25008C8.6712 5.25008 7.87634 5.57932 7.29029 6.16537C6.70424 6.75142 6.375 7.54628 6.375 8.37508C6.375 9.73967 7.23958 10.8959 8.45833 11.323V17.7501H10.5417V15.6667H12.625V13.5834H10.5417V11.323C11.7604 10.8959 12.625 9.73967 12.625 8.37508C12.625 7.54628 12.2958 6.75142 11.7097 6.16537C11.1237 5.57932 10.3288 5.25008 9.5 5.25008Z"
|
215
|
+
}));
|
216
|
+
}; // reusable piece of code that handles the iconbutton and popover on the right side of the rows
|
217
|
+
|
218
|
+
|
219
|
+
var IconWithPopover = function IconWithPopover() {
|
220
|
+
return ___EmotionJSX(PopoverMenu, {
|
221
|
+
direction: "left"
|
222
|
+
}, ___EmotionJSX(Box, {
|
223
|
+
alignItems: "center",
|
224
|
+
alignSelf: "center"
|
225
|
+
}, ___EmotionJSX(IconButton, {
|
226
|
+
"aria-label": "Menu Button"
|
227
|
+
}, ___EmotionJSX(Icon, {
|
228
|
+
icon: DotsVerticalIcon,
|
229
|
+
size: 16,
|
230
|
+
color: "Neutral.40",
|
231
|
+
m: "0.61px"
|
232
|
+
}))), ___EmotionJSX(Menu, {
|
233
|
+
direction: "left",
|
234
|
+
sx: {
|
235
|
+
minWidth: '155px',
|
236
|
+
minHeight: '144px'
|
237
|
+
}
|
238
|
+
}, ___EmotionJSX(Item, {
|
239
|
+
key: "view"
|
240
|
+
}, "View"), ___EmotionJSX(Item, {
|
241
|
+
key: "edit"
|
242
|
+
}, "Edit"), ___EmotionJSX(Item, {
|
243
|
+
key: "rename"
|
244
|
+
}, "Rename"), ___EmotionJSX(Item, {
|
245
|
+
key: "delete",
|
246
|
+
textValue: "delete"
|
247
|
+
}, ___EmotionJSX(Text, {
|
248
|
+
color: "critical.bright"
|
249
|
+
}, "Delete"))));
|
250
|
+
}; // made these separate components because staging and production both use them.
|
251
|
+
|
252
|
+
|
253
|
+
var DefaultChip = function DefaultChip() {
|
254
|
+
return ___EmotionJSX(Chip, {
|
255
|
+
label: "Default",
|
256
|
+
bg: "active",
|
257
|
+
sx: {
|
258
|
+
marginLeft: '25px',
|
259
|
+
alignSelf: 'center',
|
260
|
+
alignItems: 'center',
|
261
|
+
padding: '3px 5px 2px 5px'
|
262
|
+
}
|
263
|
+
});
|
264
|
+
};
|
265
|
+
|
266
|
+
var ExprirationChip = function ExprirationChip(props) {
|
267
|
+
var expirationText = props.expirationText,
|
268
|
+
chipText = props.chipText;
|
269
|
+
return ___EmotionJSX(Box, {
|
270
|
+
sx: !chipText && {
|
271
|
+
paddingLeft: '72px'
|
272
|
+
},
|
273
|
+
flexGrow: 1,
|
274
|
+
alignItems: "center",
|
275
|
+
alignSelf: "center"
|
276
|
+
}, ___EmotionJSX(Chip, {
|
277
|
+
bg: "white",
|
278
|
+
sx: {
|
279
|
+
border: 'solid 1px',
|
280
|
+
borderColor: 'neutral.80',
|
281
|
+
alignSelf: 'center',
|
282
|
+
alignItems: 'center',
|
283
|
+
padding: '3px 5px 2px 5px'
|
284
|
+
},
|
285
|
+
textColor: "text.primary",
|
286
|
+
textProps: {
|
287
|
+
fontSize: 'xs'
|
288
|
+
},
|
289
|
+
label: expirationText
|
290
|
+
}));
|
291
|
+
}; // jsx of the production row
|
292
|
+
|
293
|
+
|
294
|
+
var Production = function Production(props) {
|
295
|
+
var chipText = props.chipText,
|
296
|
+
hasStaging = props.hasStaging,
|
297
|
+
policyId = props.policyId,
|
298
|
+
name = props.name;
|
299
|
+
return ___EmotionJSX(Box, {
|
300
|
+
isRow: true,
|
301
|
+
height: "75px"
|
302
|
+
}, ___EmotionJSX(Box, {
|
303
|
+
alignItems: "center",
|
304
|
+
justifyContent: "center",
|
305
|
+
sx: {
|
306
|
+
position: 'relative'
|
307
|
+
}
|
308
|
+
}, ___EmotionJSX(Icon, {
|
309
|
+
icon: ShieldVector,
|
310
|
+
color: hasStaging ? 'decorative.7' : 'accent.40',
|
311
|
+
size: 24,
|
312
|
+
isLinked: hasStaging
|
313
|
+
}), hasStaging && ___EmotionJSX(TopBracket, null)), ___EmotionJSX(Box, {
|
314
|
+
isRow: true,
|
315
|
+
mr: "auto",
|
316
|
+
alignSelf: "center",
|
317
|
+
justifyContent: "center",
|
318
|
+
ml: "18px",
|
319
|
+
alignItems: "center"
|
320
|
+
}, ___EmotionJSX(Box, null, ___EmotionJSX(Text, {
|
321
|
+
sx: {
|
322
|
+
fontWeight: 1,
|
323
|
+
color: 'text.primary',
|
324
|
+
fontSize: 'md'
|
325
|
+
}
|
326
|
+
}, name), ___EmotionJSX(Text, {
|
327
|
+
sx: {
|
328
|
+
fontWeight: 0,
|
329
|
+
color: 'text.secondary',
|
330
|
+
fontSize: 'sm'
|
331
|
+
}
|
332
|
+
}, "Policy Id: ", policyId)), chipText && ___EmotionJSX(DefaultChip, null)), ___EmotionJSX(IconWithPopover, null));
|
333
|
+
}; // jsx of the staging row.
|
334
|
+
|
335
|
+
|
336
|
+
var Staging = function Staging(props) {
|
337
|
+
var chipText = props.chipText,
|
338
|
+
expirationText = props.expirationText,
|
339
|
+
policyId = props.policyId,
|
340
|
+
name = props.name;
|
341
|
+
return ___EmotionJSX(Box, {
|
342
|
+
isRow: true,
|
343
|
+
height: "75px",
|
344
|
+
marginLeft: "12px"
|
345
|
+
}, ___EmotionJSX(BottomBracket, null), ___EmotionJSX(Box, {
|
346
|
+
isRow: true,
|
347
|
+
alignItems: "center",
|
348
|
+
justifyContent: "center"
|
349
|
+
}, ___EmotionJSX(Box, {
|
350
|
+
pl: "0px",
|
351
|
+
height: "30px",
|
352
|
+
flexDirection: "row",
|
353
|
+
alignItems: "center"
|
354
|
+
}, ___EmotionJSX(Separator, {
|
355
|
+
orientation: "vertical",
|
356
|
+
sx: {
|
357
|
+
width: '2px !important',
|
358
|
+
backgroundColor: 'decorative.7',
|
359
|
+
marginLeft: '2px !important'
|
360
|
+
}
|
361
|
+
})), ___EmotionJSX(Box, null, ___EmotionJSX(Text, {
|
362
|
+
sx: {
|
363
|
+
fontWeight: 1,
|
364
|
+
color: 'text.primary',
|
365
|
+
fontSize: 'md'
|
366
|
+
}
|
367
|
+
}, name), ___EmotionJSX(Text, {
|
368
|
+
sx: {
|
369
|
+
fontWeight: 0,
|
370
|
+
color: 'text.secondary',
|
371
|
+
fontSize: 'sm'
|
372
|
+
}
|
373
|
+
}, "Policy Id: ", policyId))), chipText && ___EmotionJSX(DefaultChip, null), expirationText && ___EmotionJSX(ExprirationChip, {
|
374
|
+
expirationText: expirationText
|
375
|
+
}), ___EmotionJSX(IconWithPopover, null));
|
376
|
+
};
|
377
|
+
|
378
|
+
return ___EmotionJSX(OverlayProvider, null, ___EmotionJSX(ListView, _extends({}, args, {
|
379
|
+
items: theseItems
|
380
|
+
}), function (item) {
|
381
|
+
return ___EmotionJSX(Item, _extends({}, item, {
|
382
|
+
textValue: item.name,
|
383
|
+
"data-id": item.key,
|
384
|
+
listItemProps: {
|
385
|
+
variant: 'boxes.linkedListViewItem'
|
386
|
+
}
|
387
|
+
}), item.parentId ? ___EmotionJSX(Staging, _extends({}, item, {
|
388
|
+
hasInsetSeparator: true
|
389
|
+
})) : ___EmotionJSX(Production, _extends({
|
390
|
+
hasStaging: item.childrenObjects
|
391
|
+
}, item)));
|
392
|
+
}));
|
393
|
+
};
|
@@ -7,7 +7,8 @@ import AccountIcon from 'mdi-react/AccountIcon';
|
|
7
7
|
import CloseIcon from 'mdi-react/CloseIcon';
|
8
8
|
import MoreVertIcon from 'mdi-react/MoreVertIcon';
|
9
9
|
import PencilIcon from 'mdi-react/PencilIcon';
|
10
|
-
import
|
10
|
+
import PlusIcon from 'mdi-react/PlusIcon';
|
11
|
+
import { Avatar, Box, Icon, IconButton, Link, ListView, Menu, OverlayPanel, PopoverMenu, SearchField, Separator, SwitchField, Tab, Tabs, Text } from '../index';
|
11
12
|
import { useOverlayPanelState } from '../hooks';
|
12
13
|
import { pingImg } from '../utils/devUtils/constants/images';
|
13
14
|
import { jsx as ___EmotionJSX } from "@emotion/react";
|
@@ -228,6 +229,8 @@ export var Default = function Default() {
|
|
228
229
|
onPanelClose = _useOverlayPanelState.onClose;
|
229
230
|
|
230
231
|
var panelTriggerRef = useRef();
|
232
|
+
var heading = 'Title of the Page';
|
233
|
+
var description = 'The description of the page. The description of the page. The description of the page. The description of the page. The description of the page. The description of the page. The description of the page. The description of the page. The description of the page.';
|
231
234
|
|
232
235
|
var closePanelHandler = function closePanelHandler() {
|
233
236
|
onPanelClose(panelState, panelTriggerRef);
|
@@ -249,7 +252,34 @@ export var Default = function Default() {
|
|
249
252
|
|
250
253
|
return ___EmotionJSX(Box, {
|
251
254
|
sx: sx.wrapper
|
252
|
-
}, ___EmotionJSX(
|
255
|
+
}, ___EmotionJSX(Box, {
|
256
|
+
mb: "md"
|
257
|
+
}, ___EmotionJSX(Box, {
|
258
|
+
align: "center",
|
259
|
+
isRow: true,
|
260
|
+
mb: "xs",
|
261
|
+
role: "heading",
|
262
|
+
"aria-level": "1"
|
263
|
+
}, ___EmotionJSX(Text, {
|
264
|
+
variant: "title",
|
265
|
+
fontWeight: 3
|
266
|
+
}, heading), ___EmotionJSX(IconButton, {
|
267
|
+
"aria-label": "icon button",
|
268
|
+
ml: "sm",
|
269
|
+
mt: "3px",
|
270
|
+
variant: "inverted"
|
271
|
+
}, ___EmotionJSX(Icon, {
|
272
|
+
icon: PlusIcon,
|
273
|
+
color: "white",
|
274
|
+
size: 13
|
275
|
+
}))), ___EmotionJSX(Text, {
|
276
|
+
variant: "bodyWeak"
|
277
|
+
}, description, ___EmotionJSX(Link, {
|
278
|
+
href: "https://uilibrary.ping-eng.com/",
|
279
|
+
sx: {
|
280
|
+
fontSize: '13px'
|
281
|
+
}
|
282
|
+
}, " Learn more"))), ___EmotionJSX(SearchField, {
|
253
283
|
position: "fixed",
|
254
284
|
mb: "sm",
|
255
285
|
width: "400px",
|
@@ -21,7 +21,9 @@ var card = {
|
|
21
21
|
p: 'lg',
|
22
22
|
alignItems: 'center',
|
23
23
|
justifyContent: 'center',
|
24
|
-
flex: '1 1 0'
|
24
|
+
flex: '1 1 0',
|
25
|
+
fontWeight: 1,
|
26
|
+
fontSize: 'md'
|
25
27
|
}; // Used to give a border to radio elements
|
26
28
|
|
27
29
|
var radioContainer = {
|
@@ -81,6 +83,21 @@ var listViewItem = _objectSpread(_objectSpread({}, base), {}, {
|
|
81
83
|
}
|
82
84
|
});
|
83
85
|
|
86
|
+
var linkedListViewItem = _objectSpread(_objectSpread({}, listViewItem), {}, {
|
87
|
+
minHeight: '75px',
|
88
|
+
'&.has-inset-separator': {
|
89
|
+
'&:after': {
|
90
|
+
content: '""',
|
91
|
+
position: 'absolute',
|
92
|
+
width: 'calc(100% - 43px)',
|
93
|
+
right: 0,
|
94
|
+
bottom: 0,
|
95
|
+
borderBottom: '1px solid',
|
96
|
+
borderBottomColor: 'line.hairline'
|
97
|
+
}
|
98
|
+
}
|
99
|
+
});
|
100
|
+
|
84
101
|
var listBoxSectionTitle = {
|
85
102
|
fontSize: 'sm',
|
86
103
|
fontWeight: '3',
|
@@ -361,6 +378,7 @@ export default {
|
|
361
378
|
listItem: listItem,
|
362
379
|
listBoxSectionTitle: listBoxSectionTitle,
|
363
380
|
listViewItem: listViewItem,
|
381
|
+
linkedListViewItem: linkedListViewItem,
|
364
382
|
radioCheckedContent: radioCheckedContent,
|
365
383
|
radioContainer: radioContainer,
|
366
384
|
scrollbox: scrollbox,
|
@@ -39,6 +39,11 @@ var tableRow = {
|
|
39
39
|
width: '100%',
|
40
40
|
flexDirection: 'row !important'
|
41
41
|
};
|
42
|
+
var tableCaption = {
|
43
|
+
textAlign: 'left',
|
44
|
+
marginBottom: 'xs',
|
45
|
+
lineHeight: '21px'
|
46
|
+
};
|
42
47
|
var table = {
|
43
48
|
width: '100%'
|
44
49
|
};
|
@@ -47,5 +52,6 @@ export default {
|
|
47
52
|
tableData: tableData,
|
48
53
|
tableBody: tableBody,
|
49
54
|
tableRow: tableRow,
|
55
|
+
tableCaption: tableCaption,
|
50
56
|
table: table
|
51
57
|
};
|