@pingux/astro 1.32.1 → 1.33.0-alpha.1
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/AccordionGridItem/AccordionGridItem.js +4 -1
- package/lib/cjs/components/PasswordField/PasswordField.js +1 -1
- package/lib/cjs/components/Text/Text.stories.js +395 -74
- package/lib/cjs/styles/variants/accordion.js +27 -6
- package/lib/cjs/styles/variants/text.js +44 -18
- package/lib/components/AccordionGridItem/AccordionGridItem.js +4 -1
- package/lib/components/PasswordField/PasswordField.js +1 -1
- package/lib/components/Text/Text.stories.js +391 -63
- package/lib/styles/variants/accordion.js +17 -6
- package/lib/styles/variants/text.js +44 -18
- package/package.json +1 -1
- package/NOTICE.html +0 -4665
@@ -101,9 +101,12 @@ var AccordionGridItem = function AccordionGridItem(props) {
|
|
101
101
|
delete rowProps.onPointerDown;
|
102
102
|
delete rowProps.onClick;
|
103
103
|
return (0, _react2.jsx)(_Box["default"], (0, _extends2["default"])({
|
104
|
-
as: "div"
|
104
|
+
as: "div",
|
105
|
+
role: "row",
|
106
|
+
tabindex: "0"
|
105
107
|
}, (0, _utils.mergeProps)(rowProps, others), {
|
106
108
|
"aria-selected": isSelected,
|
109
|
+
"aria-expanded": isSelected,
|
107
110
|
className: classNames,
|
108
111
|
variant: "accordion.accordionGridItem",
|
109
112
|
ref: rowRef
|
@@ -118,7 +118,7 @@ var PasswordField = /*#__PURE__*/(0, _react.forwardRef)(function (props, ref) {
|
|
118
118
|
return inputRef.current;
|
119
119
|
});
|
120
120
|
|
121
|
-
var _hooks$useProgressive = hooks.useProgressiveState(isVisibleProp,
|
121
|
+
var _hooks$useProgressive = hooks.useProgressiveState(isVisibleProp, isVisibleProp),
|
122
122
|
_hooks$useProgressive2 = (0, _slicedToArray2["default"])(_hooks$useProgressive, 2),
|
123
123
|
isVisible = _hooks$useProgressive2[0],
|
124
124
|
setIsShown = _hooks$useProgressive2[1]; // Measure the width of the input to inform the width of the menu (below).
|
@@ -10,109 +10,430 @@ _Object$defineProperty(exports, "__esModule", {
|
|
10
10
|
|
11
11
|
exports["default"] = exports.WithCustomWidth = exports.TypographyStyleProps = exports.Default = void 0;
|
12
12
|
|
13
|
-
var _extends2 = _interopRequireDefault(require("@babel/runtime-corejs3/helpers/extends"));
|
14
|
-
|
15
|
-
var _objectWithoutProperties2 = _interopRequireDefault(require("@babel/runtime-corejs3/helpers/objectWithoutProperties"));
|
16
|
-
|
17
13
|
var _slicedToArray2 = _interopRequireDefault(require("@babel/runtime-corejs3/helpers/slicedToArray"));
|
18
14
|
|
19
|
-
var
|
20
|
-
|
21
|
-
var _concat = _interopRequireDefault(require("@babel/runtime-corejs3/core-js-stable/instance/concat"));
|
15
|
+
var _entries = _interopRequireDefault(require("@babel/runtime-corejs3/core-js-stable/object/entries"));
|
22
16
|
|
23
|
-
var
|
17
|
+
var _map = _interopRequireDefault(require("@babel/runtime-corejs3/core-js-stable/instance/map"));
|
24
18
|
|
25
19
|
var _react = _interopRequireDefault(require("react"));
|
26
20
|
|
27
|
-
var _themeUi = require("theme-ui");
|
28
|
-
|
29
|
-
var _Text = _interopRequireDefault(require("./Text"));
|
30
|
-
|
31
|
-
var _variants = require("../../utils/devUtils/constants/variants.js");
|
32
|
-
|
33
|
-
var _colors = require("../../styles/colors.js");
|
34
|
-
|
35
21
|
var _index = require("../../index");
|
36
22
|
|
37
23
|
var _react2 = require("@emotion/react");
|
38
24
|
|
39
|
-
var _excluded = ["children", "bg"];
|
40
|
-
|
41
|
-
var _context;
|
42
|
-
|
43
25
|
var _default = {
|
44
26
|
title: 'Text',
|
45
|
-
component:
|
27
|
+
component: _index.Text,
|
46
28
|
argTypes: {
|
47
29
|
variant: {
|
48
30
|
control: {
|
49
|
-
type: '
|
50
|
-
options: (0, _values["default"])(_variants.textVariants)
|
31
|
+
type: 'none'
|
51
32
|
},
|
52
|
-
description: 'Text variant.'
|
53
|
-
defaultValue: (0, _values["default"])(_variants.textVariants)[0]
|
33
|
+
description: 'Text variant.'
|
54
34
|
},
|
55
35
|
children: {
|
56
36
|
control: {
|
57
|
-
type: '
|
58
|
-
},
|
59
|
-
table: {
|
60
|
-
type: {
|
61
|
-
summary: 'string'
|
62
|
-
}
|
37
|
+
type: 'none'
|
63
38
|
},
|
64
|
-
description: 'Text value.'
|
65
|
-
defaultValue: 'Hi, this is some text!'
|
39
|
+
description: 'Text value.'
|
66
40
|
},
|
67
41
|
color: {
|
68
42
|
control: {
|
69
|
-
type: '
|
70
|
-
options: (0, _concat["default"])(_context = [undefined]).call(_context, (0, _map["default"])(_colors.flatColorList).call(_colors.flatColorList, function (_ref) {
|
71
|
-
var _ref2 = (0, _slicedToArray2["default"])(_ref, 1),
|
72
|
-
colorName = _ref2[0];
|
73
|
-
|
74
|
-
return colorName;
|
75
|
-
}))
|
76
|
-
},
|
77
|
-
table: {
|
78
|
-
type: {
|
79
|
-
summary: 'string'
|
80
|
-
}
|
43
|
+
type: 'none'
|
81
44
|
},
|
82
|
-
description: 'Text color.'
|
83
|
-
defaultValue: undefined
|
45
|
+
description: 'Text color.'
|
84
46
|
},
|
85
47
|
bg: {
|
86
48
|
control: {
|
87
|
-
type: '
|
88
|
-
options: (0, _map["default"])(_colors.flatColorList).call(_colors.flatColorList, function (_ref3) {
|
89
|
-
var _ref4 = (0, _slicedToArray2["default"])(_ref3, 1),
|
90
|
-
colorName = _ref4[0];
|
91
|
-
|
92
|
-
return colorName;
|
93
|
-
})
|
94
|
-
},
|
95
|
-
table: {
|
96
|
-
type: {
|
97
|
-
summary: 'string'
|
98
|
-
}
|
49
|
+
type: 'none'
|
99
50
|
},
|
100
|
-
description: 'Background color.'
|
101
|
-
defaultValue: 'white'
|
51
|
+
description: 'Background color.'
|
102
52
|
}
|
103
53
|
}
|
104
54
|
};
|
105
55
|
exports["default"] = _default;
|
56
|
+
var sx = {
|
57
|
+
cell: {
|
58
|
+
wordWrap: 'break-word',
|
59
|
+
wordBreak: 'break-word'
|
60
|
+
},
|
61
|
+
tableBody: {
|
62
|
+
borderBottom: 'unset'
|
63
|
+
}
|
64
|
+
};
|
106
65
|
|
107
|
-
var
|
108
|
-
var
|
109
|
-
|
110
|
-
|
111
|
-
|
112
|
-
|
113
|
-
|
114
|
-
|
115
|
-
}),
|
66
|
+
var TableHeading = function TableHeading(_ref) {
|
67
|
+
var title = _ref.title;
|
68
|
+
return (0, _react2.jsx)(_index.TableHead, null, (0, _react2.jsx)(_index.TableRow, {
|
69
|
+
key: "head"
|
70
|
+
}, (0, _react2.jsx)(_index.TableCell, {
|
71
|
+
sx: sx.cell,
|
72
|
+
isHeading: true,
|
73
|
+
width: "30%"
|
74
|
+
}, title), (0, _react2.jsx)(_index.TableCell, {
|
75
|
+
sx: sx.cell,
|
76
|
+
isHeading: true,
|
77
|
+
width: "30%"
|
78
|
+
}, "Weight"), (0, _react2.jsx)(_index.TableCell, {
|
79
|
+
sx: sx.cell,
|
80
|
+
isHeading: true,
|
81
|
+
width: "30%"
|
82
|
+
}, "Size"), (0, _react2.jsx)(_index.TableCell, {
|
83
|
+
sx: sx.cell,
|
84
|
+
isHeading: true
|
85
|
+
}, "Example")));
|
86
|
+
};
|
87
|
+
|
88
|
+
var TableData = function TableData(_ref2) {
|
89
|
+
var variant = _ref2.variant,
|
90
|
+
value = _ref2.value;
|
91
|
+
return (0, _react2.jsx)(_index.TableRow, {
|
92
|
+
sx: {
|
93
|
+
backgroundColor: 'transparent !important',
|
94
|
+
alignItems: 'center'
|
95
|
+
}
|
96
|
+
}, (0, _react2.jsx)(_index.TableCell, {
|
97
|
+
sx: sx.cell,
|
98
|
+
width: "30%"
|
99
|
+
}, (0, _react2.jsx)(_index.Text, null, variant)), (0, _react2.jsx)(_index.TableCell, {
|
100
|
+
sx: sx.cell,
|
101
|
+
width: "30%"
|
102
|
+
}, (0, _react2.jsx)(_index.Text, null, value.weight)), (0, _react2.jsx)(_index.TableCell, {
|
103
|
+
sx: sx.cell,
|
104
|
+
width: "30%"
|
105
|
+
}, (0, _react2.jsx)(_index.Text, null, value.fontSize)), (0, _react2.jsx)(_index.TableCell, {
|
106
|
+
sx: sx.cell
|
107
|
+
}, (0, _react2.jsx)(_index.Text, null, value.example)));
|
108
|
+
};
|
109
|
+
|
110
|
+
var Default = function Default() {
|
111
|
+
var _context, _context2, _context3, _context4, _context5, _context6;
|
112
|
+
|
113
|
+
var fontSizes = {
|
114
|
+
xx: '23px (xx)',
|
115
|
+
lg: '17px (lg)',
|
116
|
+
md: '15px (md)',
|
117
|
+
sm: '13px (sm)',
|
118
|
+
xs: '11px (xs)'
|
119
|
+
};
|
120
|
+
var fontWeights = {
|
121
|
+
'-1': '300 (-1)',
|
122
|
+
'0': '400 (0)',
|
123
|
+
'1': '500 (1)',
|
124
|
+
'3': '700 (3)'
|
125
|
+
};
|
126
|
+
var headingVariants = {
|
127
|
+
H1: {
|
128
|
+
weight: fontWeights[3],
|
129
|
+
fontSize: fontSizes.xx,
|
130
|
+
example: (0, _react2.jsx)(_index.Text, {
|
131
|
+
variant: "H1",
|
132
|
+
as: "H1"
|
133
|
+
}, '<Text variant="H1" as="H1"/>')
|
134
|
+
},
|
135
|
+
H2: {
|
136
|
+
weight: fontWeights[3],
|
137
|
+
fontSize: fontSizes.lg,
|
138
|
+
example: (0, _react2.jsx)(_index.Text, {
|
139
|
+
variant: "H2",
|
140
|
+
as: "H2"
|
141
|
+
}, '<Text variant="H2" as="H2"/>')
|
142
|
+
},
|
143
|
+
H3: {
|
144
|
+
weight: fontWeights[3],
|
145
|
+
fontSize: fontSizes.md,
|
146
|
+
example: (0, _react2.jsx)(_index.Text, {
|
147
|
+
variant: "H3",
|
148
|
+
as: "H3"
|
149
|
+
}, '<Text variant="H3" as="H3"/>')
|
150
|
+
},
|
151
|
+
H4: {
|
152
|
+
weight: fontWeights[3],
|
153
|
+
fontSize: fontSizes.sm,
|
154
|
+
example: (0, _react2.jsx)(_index.Text, {
|
155
|
+
variant: "H4",
|
156
|
+
as: "H4"
|
157
|
+
}, '<Text variant="H4" as="H4"/>')
|
158
|
+
}
|
159
|
+
};
|
160
|
+
var baseAndSubtitleVariants = {
|
161
|
+
'Base (default variant of Text)': {
|
162
|
+
weight: fontWeights[1],
|
163
|
+
fontSize: fontSizes.md,
|
164
|
+
color: 'text.primary',
|
165
|
+
example: (0, _react2.jsx)(_index.Text, {
|
166
|
+
variant: "base"
|
167
|
+
}, '<Text variant="base"/>')
|
168
|
+
},
|
169
|
+
Subtitle: {
|
170
|
+
weight: fontWeights[0],
|
171
|
+
fontSize: fontSizes.sm,
|
172
|
+
color: 'text.secondary',
|
173
|
+
example: (0, _react2.jsx)(_index.Text, {
|
174
|
+
variant: "subtitle"
|
175
|
+
}, '<Text variant="subtitle"/>')
|
176
|
+
}
|
177
|
+
};
|
178
|
+
var largeVariants = {
|
179
|
+
Bold: {
|
180
|
+
weight: fontWeights[3],
|
181
|
+
fontSize: fontSizes.lg,
|
182
|
+
example: (0, _react2.jsx)(_index.Text, {
|
183
|
+
fontSize: "lg",
|
184
|
+
fontWeight: "3"
|
185
|
+
}, '<Text fontSize="lg" fontWeight="3">')
|
186
|
+
},
|
187
|
+
Medium: {
|
188
|
+
weight: fontWeights[1],
|
189
|
+
fontSize: fontSizes.lg,
|
190
|
+
example: (0, _react2.jsx)(_index.Text, {
|
191
|
+
fontSize: "lg",
|
192
|
+
fontWeight: "1"
|
193
|
+
}, '<Text fontSize="lg" fontWeight="1">')
|
194
|
+
},
|
195
|
+
Regular: {
|
196
|
+
weight: fontWeights[0],
|
197
|
+
fontSize: fontSizes.lg,
|
198
|
+
example: (0, _react2.jsx)(_index.Text, {
|
199
|
+
fontSize: "lg",
|
200
|
+
fontWeight: "0"
|
201
|
+
}, '<Text fontSize="lg" fontWeight="0">')
|
202
|
+
}
|
203
|
+
};
|
204
|
+
var mediumVariants = {
|
205
|
+
Bold: {
|
206
|
+
weight: fontWeights[3],
|
207
|
+
fontSize: fontSizes.md,
|
208
|
+
example: (0, _react2.jsx)(_index.Text, {
|
209
|
+
fontSize: "md",
|
210
|
+
fontWeight: "3"
|
211
|
+
}, '<Text fontSize="md" fontWeight="3">')
|
212
|
+
},
|
213
|
+
Medium: {
|
214
|
+
weight: fontWeights[1],
|
215
|
+
fontSize: fontSizes.md,
|
216
|
+
example: (0, _react2.jsx)(_index.Text, {
|
217
|
+
fontSize: "md",
|
218
|
+
fontWeight: "1"
|
219
|
+
}, '<Text fontSize="md" fontWeight="1">')
|
220
|
+
},
|
221
|
+
Regular: {
|
222
|
+
weight: fontWeights[0],
|
223
|
+
fontSize: fontSizes.md,
|
224
|
+
example: (0, _react2.jsx)(_index.Text, {
|
225
|
+
fontSize: "md",
|
226
|
+
fontWeight: "0"
|
227
|
+
}, '<Text fontSize="md" fontWeight="0">')
|
228
|
+
},
|
229
|
+
Light: {
|
230
|
+
weight: fontWeights[-1],
|
231
|
+
fontSize: fontSizes.md,
|
232
|
+
example: (0, _react2.jsx)(_index.Text, {
|
233
|
+
fontSize: "md",
|
234
|
+
fontWeight: "-1"
|
235
|
+
}, '<Text fontSize="md" fontWeight="-1">')
|
236
|
+
}
|
237
|
+
};
|
238
|
+
var smallVariants = {
|
239
|
+
Bold: {
|
240
|
+
weight: fontWeights[3],
|
241
|
+
fontSize: fontSizes.sm,
|
242
|
+
example: (0, _react2.jsx)(_index.Text, {
|
243
|
+
fontSize: "sm",
|
244
|
+
fontWeight: "3"
|
245
|
+
}, '<Text fontSize="sm" fontWeight="3">')
|
246
|
+
},
|
247
|
+
Medium: {
|
248
|
+
weight: fontWeights[1],
|
249
|
+
fontSize: fontSizes.sm,
|
250
|
+
example: (0, _react2.jsx)(_index.Text, {
|
251
|
+
fontSize: "sm",
|
252
|
+
fontWeight: "1"
|
253
|
+
}, '<Text fontSize="sm" fontWeight="1">')
|
254
|
+
},
|
255
|
+
Regular: {
|
256
|
+
weight: fontWeights[0],
|
257
|
+
fontSize: fontSizes.sm,
|
258
|
+
example: (0, _react2.jsx)(_index.Text, {
|
259
|
+
fontSize: "sm",
|
260
|
+
fontWeight: "0"
|
261
|
+
}, '<Text fontSize="sm" fontWeight="0">')
|
262
|
+
},
|
263
|
+
Light: {
|
264
|
+
weight: fontWeights[-1],
|
265
|
+
fontSize: fontSizes.sm,
|
266
|
+
example: (0, _react2.jsx)(_index.Text, {
|
267
|
+
fontSize: "sm",
|
268
|
+
fontWeight: "-1"
|
269
|
+
}, '<Text fontSize="sm" fontWeight="-1">')
|
270
|
+
}
|
271
|
+
};
|
272
|
+
var xsmallVariants = {
|
273
|
+
Bold: {
|
274
|
+
weight: fontWeights[3],
|
275
|
+
fontSize: fontSizes.xs,
|
276
|
+
example: (0, _react2.jsx)(_index.Text, {
|
277
|
+
fontSize: "xs",
|
278
|
+
fontWeight: "3"
|
279
|
+
}, '<Text fontSize="xs" fontWeight="3">')
|
280
|
+
},
|
281
|
+
Medium: {
|
282
|
+
weight: fontWeights[1],
|
283
|
+
fontSize: fontSizes.xs,
|
284
|
+
example: (0, _react2.jsx)(_index.Text, {
|
285
|
+
fontSize: "xs",
|
286
|
+
fontWeight: "1"
|
287
|
+
}, '<Text fontSize="xs" fontWeight="1">')
|
288
|
+
},
|
289
|
+
Regular: {
|
290
|
+
weight: fontWeights[0],
|
291
|
+
fontSize: fontSizes.xs,
|
292
|
+
example: (0, _react2.jsx)(_index.Text, {
|
293
|
+
fontSize: "xs",
|
294
|
+
fontWeight: "0"
|
295
|
+
}, '<Text fontSize="xs" fontWeight="0">')
|
296
|
+
},
|
297
|
+
Light: {
|
298
|
+
weight: fontWeights[-1],
|
299
|
+
fontSize: fontSizes.xs,
|
300
|
+
example: (0, _react2.jsx)(_index.Text, {
|
301
|
+
fontSize: "xs",
|
302
|
+
fontWeight: "-1"
|
303
|
+
}, '<Text fontSize="xs" fontWeight="-1">')
|
304
|
+
}
|
305
|
+
};
|
306
|
+
return (0, _react2.jsx)(_react["default"].Fragment, null, (0, _react2.jsx)(_index.Table, {
|
307
|
+
mb: "xx"
|
308
|
+
}, (0, _react2.jsx)(TableHeading, {
|
309
|
+
title: "Heading"
|
310
|
+
}), (0, _react2.jsx)(_index.TableBody, {
|
311
|
+
sx: sx.tableBody
|
312
|
+
}, (0, _map["default"])(_context = (0, _entries["default"])(headingVariants)).call(_context, function (_ref3) {
|
313
|
+
var _ref4 = (0, _slicedToArray2["default"])(_ref3, 2),
|
314
|
+
key = _ref4[0],
|
315
|
+
value = _ref4[1];
|
316
|
+
|
317
|
+
return (0, _react2.jsx)(TableData, {
|
318
|
+
variant: key,
|
319
|
+
value: value,
|
320
|
+
key: key
|
321
|
+
});
|
322
|
+
}))), (0, _react2.jsx)(_index.Table, {
|
323
|
+
mb: "xx"
|
324
|
+
}, (0, _react2.jsx)(_index.TableHead, null, (0, _react2.jsx)(_index.TableRow, {
|
325
|
+
key: "head"
|
326
|
+
}, (0, _react2.jsx)(_index.TableCell, {
|
327
|
+
sx: sx.cell,
|
328
|
+
isHeading: true,
|
329
|
+
width: "60%"
|
330
|
+
}, "Base and Subtitle"), (0, _react2.jsx)(_index.TableCell, {
|
331
|
+
sx: sx.cell,
|
332
|
+
isHeading: true,
|
333
|
+
width: "20%"
|
334
|
+
}, "Weight"), (0, _react2.jsx)(_index.TableCell, {
|
335
|
+
sx: sx.cell,
|
336
|
+
isHeading: true,
|
337
|
+
width: "30%"
|
338
|
+
}, "Size"), (0, _react2.jsx)(_index.TableCell, {
|
339
|
+
sx: sx.cell,
|
340
|
+
isHeading: true,
|
341
|
+
width: "40%"
|
342
|
+
}, "Color"), (0, _react2.jsx)(_index.TableCell, {
|
343
|
+
sx: sx.cell,
|
344
|
+
isHeading: true
|
345
|
+
}, "Example"))), (0, _react2.jsx)(_index.TableBody, {
|
346
|
+
sx: sx.tableBody
|
347
|
+
}, (0, _map["default"])(_context2 = (0, _entries["default"])(baseAndSubtitleVariants)).call(_context2, function (_ref5) {
|
348
|
+
var _ref6 = (0, _slicedToArray2["default"])(_ref5, 2),
|
349
|
+
key = _ref6[0],
|
350
|
+
value = _ref6[1];
|
351
|
+
|
352
|
+
return (0, _react2.jsx)(_index.TableRow, {
|
353
|
+
sx: {
|
354
|
+
backgroundColor: 'transparent !important'
|
355
|
+
},
|
356
|
+
key: key
|
357
|
+
}, (0, _react2.jsx)(_index.TableCell, {
|
358
|
+
sx: sx.cell,
|
359
|
+
width: "60%"
|
360
|
+
}, (0, _react2.jsx)(_index.Text, null, key)), (0, _react2.jsx)(_index.TableCell, {
|
361
|
+
sx: sx.cell,
|
362
|
+
width: "25%"
|
363
|
+
}, (0, _react2.jsx)(_index.Text, null, value.weight)), (0, _react2.jsx)(_index.TableCell, {
|
364
|
+
sx: sx.cell,
|
365
|
+
width: "35%"
|
366
|
+
}, (0, _react2.jsx)(_index.Text, null, value.fontSize)), (0, _react2.jsx)(_index.TableCell, {
|
367
|
+
sx: sx.cell,
|
368
|
+
width: "45%"
|
369
|
+
}, (0, _react2.jsx)(_index.Text, null, value.color)), (0, _react2.jsx)(_index.TableCell, {
|
370
|
+
sx: sx.cell
|
371
|
+
}, value.example));
|
372
|
+
}))), (0, _react2.jsx)(_index.Table, {
|
373
|
+
mb: "xx"
|
374
|
+
}, (0, _react2.jsx)(TableHeading, {
|
375
|
+
title: "Large"
|
376
|
+
}), (0, _react2.jsx)(_index.TableBody, {
|
377
|
+
sx: sx.tableBody
|
378
|
+
}, (0, _map["default"])(_context3 = (0, _entries["default"])(largeVariants)).call(_context3, function (_ref7) {
|
379
|
+
var _ref8 = (0, _slicedToArray2["default"])(_ref7, 2),
|
380
|
+
key = _ref8[0],
|
381
|
+
value = _ref8[1];
|
382
|
+
|
383
|
+
return (0, _react2.jsx)(TableData, {
|
384
|
+
variant: key,
|
385
|
+
value: value,
|
386
|
+
key: key
|
387
|
+
});
|
388
|
+
}))), (0, _react2.jsx)(_index.Table, {
|
389
|
+
mb: "xx"
|
390
|
+
}, (0, _react2.jsx)(TableHeading, {
|
391
|
+
title: "Medium"
|
392
|
+
}), (0, _react2.jsx)(_index.TableBody, {
|
393
|
+
sx: sx.tableBody
|
394
|
+
}, (0, _map["default"])(_context4 = (0, _entries["default"])(mediumVariants)).call(_context4, function (_ref9) {
|
395
|
+
var _ref10 = (0, _slicedToArray2["default"])(_ref9, 2),
|
396
|
+
key = _ref10[0],
|
397
|
+
value = _ref10[1];
|
398
|
+
|
399
|
+
return (0, _react2.jsx)(TableData, {
|
400
|
+
variant: key,
|
401
|
+
value: value,
|
402
|
+
key: key
|
403
|
+
});
|
404
|
+
}))), (0, _react2.jsx)(_index.Table, {
|
405
|
+
mb: "xx"
|
406
|
+
}, (0, _react2.jsx)(TableHeading, {
|
407
|
+
title: "Small"
|
408
|
+
}), (0, _react2.jsx)(_index.TableBody, {
|
409
|
+
sx: sx.tableBody
|
410
|
+
}, (0, _map["default"])(_context5 = (0, _entries["default"])(smallVariants)).call(_context5, function (_ref11) {
|
411
|
+
var _ref12 = (0, _slicedToArray2["default"])(_ref11, 2),
|
412
|
+
key = _ref12[0],
|
413
|
+
value = _ref12[1];
|
414
|
+
|
415
|
+
return (0, _react2.jsx)(TableData, {
|
416
|
+
variant: key,
|
417
|
+
value: value,
|
418
|
+
key: key
|
419
|
+
});
|
420
|
+
}))), (0, _react2.jsx)(_index.Table, {
|
421
|
+
mb: "xx"
|
422
|
+
}, (0, _react2.jsx)(TableHeading, {
|
423
|
+
title: "XSmall"
|
424
|
+
}), (0, _react2.jsx)(_index.TableBody, {
|
425
|
+
sx: sx.tableBody
|
426
|
+
}, (0, _map["default"])(_context6 = (0, _entries["default"])(xsmallVariants)).call(_context6, function (_ref13) {
|
427
|
+
var _ref14 = (0, _slicedToArray2["default"])(_ref13, 2),
|
428
|
+
key = _ref14[0],
|
429
|
+
value = _ref14[1];
|
430
|
+
|
431
|
+
return (0, _react2.jsx)(TableData, {
|
432
|
+
variant: key,
|
433
|
+
value: value,
|
434
|
+
key: key
|
435
|
+
});
|
436
|
+
}))));
|
116
437
|
};
|
117
438
|
|
118
439
|
exports.Default = Default;
|
@@ -120,7 +441,7 @@ exports.Default = Default;
|
|
120
441
|
var WithCustomWidth = function WithCustomWidth() {
|
121
442
|
return (0, _react2.jsx)(_index.Box, {
|
122
443
|
width: 200
|
123
|
-
}, (0, _react2.jsx)(
|
444
|
+
}, (0, _react2.jsx)(_index.Text, {
|
124
445
|
p: "xl"
|
125
446
|
}, "superlongtextinonelinewithnowhitespacessoitcanbelongerthatanywidth"));
|
126
447
|
};
|
@@ -141,11 +462,11 @@ var TypographyStyleProps = function TypographyStyleProps() {
|
|
141
462
|
return (0, _react2.jsx)(_index.Box, {
|
142
463
|
p: "xx",
|
143
464
|
gap: "md"
|
144
|
-
}, (0, _react2.jsx)(
|
465
|
+
}, (0, _react2.jsx)(_index.Text, {
|
145
466
|
variant: "title"
|
146
|
-
}, "The Text component allows typography style props to be passed in directly."), (0, _react2.jsx)(
|
467
|
+
}, "The Text component allows typography style props to be passed in directly."), (0, _react2.jsx)(_index.Text, textProps, loremText), (0, _react2.jsx)(_index.Separator, null), (0, _react2.jsx)(_index.Text, {
|
147
468
|
variant: "title"
|
148
|
-
}, "Typography styles can also be passed in through the sx prop for the same result."), (0, _react2.jsx)(
|
469
|
+
}, "Typography styles can also be passed in through the sx prop for the same result."), (0, _react2.jsx)(_index.Text, {
|
149
470
|
sx: textProps
|
150
471
|
}, loremText));
|
151
472
|
};
|
@@ -1,12 +1,37 @@
|
|
1
1
|
"use strict";
|
2
2
|
|
3
|
+
var _interopRequireDefault = require("@babel/runtime-corejs3/helpers/interopRequireDefault");
|
4
|
+
|
3
5
|
var _Object$defineProperty = require("@babel/runtime-corejs3/core-js-stable/object/define-property");
|
4
6
|
|
7
|
+
var _Object$defineProperties = require("@babel/runtime-corejs3/core-js-stable/object/define-properties");
|
8
|
+
|
9
|
+
var _Object$getOwnPropertyDescriptors = require("@babel/runtime-corejs3/core-js-stable/object/get-own-property-descriptors");
|
10
|
+
|
11
|
+
var _forEachInstanceProperty = require("@babel/runtime-corejs3/core-js-stable/instance/for-each");
|
12
|
+
|
13
|
+
var _Object$getOwnPropertyDescriptor = require("@babel/runtime-corejs3/core-js-stable/object/get-own-property-descriptor");
|
14
|
+
|
15
|
+
var _filterInstanceProperty = require("@babel/runtime-corejs3/core-js-stable/instance/filter");
|
16
|
+
|
17
|
+
var _Object$getOwnPropertySymbols = require("@babel/runtime-corejs3/core-js-stable/object/get-own-property-symbols");
|
18
|
+
|
19
|
+
var _Object$keys = require("@babel/runtime-corejs3/core-js-stable/object/keys");
|
20
|
+
|
5
21
|
_Object$defineProperty(exports, "__esModule", {
|
6
22
|
value: true
|
7
23
|
});
|
8
24
|
|
9
25
|
exports["default"] = void 0;
|
26
|
+
|
27
|
+
var _defineProperty2 = _interopRequireDefault(require("@babel/runtime-corejs3/helpers/defineProperty"));
|
28
|
+
|
29
|
+
var _buttons = require("../variants/buttons");
|
30
|
+
|
31
|
+
function ownKeys(object, enumerableOnly) { var keys = _Object$keys(object); if (_Object$getOwnPropertySymbols) { var symbols = _Object$getOwnPropertySymbols(object); enumerableOnly && (symbols = _filterInstanceProperty(symbols).call(symbols, function (sym) { return _Object$getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
|
32
|
+
|
33
|
+
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var _context, _context2; var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? _forEachInstanceProperty(_context = ownKeys(Object(source), !0)).call(_context, function (key) { (0, _defineProperty2["default"])(target, key, source[key]); }) : _Object$getOwnPropertyDescriptors ? _Object$defineProperties(target, _Object$getOwnPropertyDescriptors(source)) : _forEachInstanceProperty(_context2 = ownKeys(Object(source))).call(_context2, function (key) { _Object$defineProperty(target, key, _Object$getOwnPropertyDescriptor(source, key)); }); } return target; }
|
34
|
+
|
10
35
|
var accordionTitle = {
|
11
36
|
display: 'inline-block !important',
|
12
37
|
overflowWrap: 'break-word',
|
@@ -48,13 +73,9 @@ var accordionGridHeader = {
|
|
48
73
|
color: 'neutral.10',
|
49
74
|
flexGrow: 1,
|
50
75
|
fontWeight: 700,
|
51
|
-
'&.is-focused': {
|
52
|
-
outline: 'none',
|
53
|
-
boxShadow: 'focus',
|
54
|
-
WebkitBoxShadow: 'focus',
|
55
|
-
MozBoxShadow: 'focus',
|
76
|
+
'&.is-focused': _objectSpread(_objectSpread({}, _buttons.defaultFocus), {}, {
|
56
77
|
zIndex: '10'
|
57
|
-
},
|
78
|
+
}),
|
58
79
|
minHeight: '64px',
|
59
80
|
'&.is-hovered': {
|
60
81
|
backgroundColor: 'accent.99'
|
@@ -249,6 +249,28 @@ var timeZone = {
|
|
249
249
|
}
|
250
250
|
}
|
251
251
|
};
|
252
|
+
|
253
|
+
var title = _objectSpread(_objectSpread({}, wordWrap), {}, {
|
254
|
+
fontSize: 'xx',
|
255
|
+
fontWeight: 1,
|
256
|
+
color: 'text.primary',
|
257
|
+
fontFamily: 'standard'
|
258
|
+
});
|
259
|
+
|
260
|
+
var sectionTitle = _objectSpread(_objectSpread({}, wordWrap), {}, {
|
261
|
+
fontSize: 'lg',
|
262
|
+
fontWeight: 2,
|
263
|
+
color: 'text.primary',
|
264
|
+
fontFamily: 'standard'
|
265
|
+
});
|
266
|
+
|
267
|
+
var itemTitle = _objectSpread(_objectSpread({}, wordWrap), {}, {
|
268
|
+
fontSize: 'md',
|
269
|
+
fontWeight: 1,
|
270
|
+
color: 'text.primary',
|
271
|
+
fontFamily: 'standard'
|
272
|
+
});
|
273
|
+
|
252
274
|
var text = {
|
253
275
|
base: base,
|
254
276
|
bodyStrong: _objectSpread(_objectSpread({}, wordWrap), {}, {
|
@@ -290,17 +312,31 @@ var text = {
|
|
290
312
|
}),
|
291
313
|
environmentBreadcrumb: environmentBreadcrumb,
|
292
314
|
fieldHelperText: fieldHelperText,
|
315
|
+
H1: _objectSpread(_objectSpread({}, title), {}, {
|
316
|
+
fontWeight: 3,
|
317
|
+
lineHeight: '28px'
|
318
|
+
}),
|
319
|
+
H2: _objectSpread(_objectSpread({}, sectionTitle), {}, {
|
320
|
+
fontWeight: 3,
|
321
|
+
lineHeight: '21px'
|
322
|
+
}),
|
323
|
+
H3: _objectSpread(_objectSpread({}, itemTitle), {}, {
|
324
|
+
fontWeight: 3,
|
325
|
+
lineHeight: '18px'
|
326
|
+
}),
|
327
|
+
H4: _objectSpread(_objectSpread({}, wordWrap), {}, {
|
328
|
+
fontSize: 'sm',
|
329
|
+
fontWeight: 3,
|
330
|
+
color: 'text.primary',
|
331
|
+
fontFamily: 'standard',
|
332
|
+
lineHeight: '16px'
|
333
|
+
}),
|
293
334
|
inputValue: {
|
294
335
|
fontWeight: 1,
|
295
336
|
color: 'text.primary',
|
296
337
|
fontFamily: 'standard'
|
297
338
|
},
|
298
|
-
itemTitle:
|
299
|
-
fontSize: 'md',
|
300
|
-
fontWeight: 1,
|
301
|
-
color: 'text.primary',
|
302
|
-
fontFamily: 'standard'
|
303
|
-
}),
|
339
|
+
itemTitle: itemTitle,
|
304
340
|
itemSubtitle: _objectSpread(_objectSpread({}, wordWrap), {}, {
|
305
341
|
fontSize: 'sm',
|
306
342
|
fontWeight: 0,
|
@@ -340,12 +376,7 @@ var text = {
|
|
340
376
|
color: 'text.secondary',
|
341
377
|
fontFamily: 'standard'
|
342
378
|
},
|
343
|
-
sectionTitle:
|
344
|
-
fontSize: 'lg',
|
345
|
-
fontWeight: 2,
|
346
|
-
color: 'text.primary',
|
347
|
-
fontFamily: 'standard'
|
348
|
-
}),
|
379
|
+
sectionTitle: sectionTitle,
|
349
380
|
subtitle: _objectSpread(_objectSpread({}, wordWrap), {}, {
|
350
381
|
fontWeight: 0,
|
351
382
|
color: 'text.secondary',
|
@@ -363,12 +394,7 @@ var text = {
|
|
363
394
|
overflow: 'hidden',
|
364
395
|
textOverflow: 'ellipsis'
|
365
396
|
},
|
366
|
-
title:
|
367
|
-
fontSize: 'xx',
|
368
|
-
fontWeight: 1,
|
369
|
-
color: 'text.primary',
|
370
|
-
fontFamily: 'standard'
|
371
|
-
}),
|
397
|
+
title: title,
|
372
398
|
tooltipContent: tooltipContent,
|
373
399
|
timeZone: timeZone
|
374
400
|
};
|