@pingux/astro 2.25.0 → 2.26.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/AccordionGroup/Accordion.styles.js +8 -5
- package/lib/cjs/components/AccordionGroup/AccordionGroup.js +8 -4
- package/lib/cjs/components/AccordionGroup/AccordionGroup.stories.js +44 -7
- package/lib/cjs/components/AccordionGroup/AccordionGroup.test.js +52 -0
- package/lib/cjs/components/AccordionItem/AccordionItem.js +18 -3
- package/lib/cjs/components/ColorField/ColorField.js +1 -1
- package/lib/cjs/components/ColorField/ColorField.mdx +3 -2
- package/lib/cjs/components/Text/Text.styles.d.ts +138 -94
- package/lib/cjs/components/Text/Text.styles.js +35 -22
- package/lib/cjs/utils/designUtils/figmaLinks.js +2 -1
- package/lib/components/AccordionGroup/Accordion.styles.js +6 -4
- package/lib/components/AccordionGroup/AccordionGroup.js +8 -4
- package/lib/components/AccordionGroup/AccordionGroup.stories.js +42 -6
- package/lib/components/AccordionGroup/AccordionGroup.test.js +52 -0
- package/lib/components/AccordionItem/AccordionItem.js +16 -2
- package/lib/components/ColorField/ColorField.js +2 -2
- package/lib/components/ColorField/ColorField.mdx +3 -2
- package/lib/components/Text/Text.styles.js +35 -22
- package/lib/utils/designUtils/figmaLinks.js +2 -1
- package/package.json +1 -1
@@ -13,25 +13,25 @@ export declare const wordWrap: {
|
|
13
13
|
wordBreak: string;
|
14
14
|
};
|
15
15
|
export declare const text: {
|
16
|
-
|
17
|
-
|
18
|
-
fontSize: string;
|
16
|
+
inputValue: {
|
17
|
+
fontWeight: number;
|
19
18
|
color: string;
|
20
19
|
fontFamily: string;
|
21
|
-
overflowWrap: string;
|
22
20
|
};
|
23
|
-
|
21
|
+
itemTitle: {
|
22
|
+
fontSize: string;
|
23
|
+
fontWeight: number;
|
24
24
|
color: string;
|
25
25
|
fontFamily: string;
|
26
|
-
fontWeight: number;
|
27
26
|
display: string;
|
28
27
|
overflowWrap: string;
|
29
28
|
maxWidth: string;
|
30
29
|
wordWrap: string;
|
31
30
|
wordBreak: string;
|
32
31
|
};
|
33
|
-
|
32
|
+
itemSubtitle: {
|
34
33
|
fontSize: string;
|
34
|
+
fontWeight: number;
|
35
35
|
color: string;
|
36
36
|
fontFamily: string;
|
37
37
|
display: string;
|
@@ -40,125 +40,150 @@ export declare const text: {
|
|
40
40
|
wordWrap: string;
|
41
41
|
wordBreak: string;
|
42
42
|
};
|
43
|
-
|
43
|
+
label: {
|
44
44
|
fontSize: string;
|
45
|
-
fontWeight: number;
|
46
45
|
color: string;
|
47
46
|
fontFamily: string;
|
47
|
+
fontWeight: number;
|
48
48
|
display: string;
|
49
49
|
overflowWrap: string;
|
50
50
|
maxWidth: string;
|
51
51
|
wordWrap: string;
|
52
52
|
wordBreak: string;
|
53
53
|
};
|
54
|
-
|
54
|
+
listTitle: {
|
55
|
+
textOverflow: string;
|
56
|
+
overflow: string;
|
57
|
+
whiteSpace: string;
|
55
58
|
fontSize: string;
|
56
59
|
fontWeight: number;
|
57
60
|
color: string;
|
58
|
-
fontFamily: string;
|
59
|
-
lineHeight: string;
|
60
61
|
display: string;
|
61
62
|
overflowWrap: string;
|
62
63
|
maxWidth: string;
|
63
64
|
wordWrap: string;
|
64
65
|
wordBreak: string;
|
65
66
|
};
|
66
|
-
|
67
|
+
listSubtitle: {
|
68
|
+
textOverflow: string;
|
69
|
+
overflow: string;
|
70
|
+
whiteSpace: string;
|
67
71
|
fontSize: string;
|
68
72
|
fontWeight: number;
|
69
73
|
color: string;
|
70
|
-
fontFamily: string;
|
71
|
-
lineHeight: string;
|
72
74
|
display: string;
|
73
75
|
overflowWrap: string;
|
74
76
|
maxWidth: string;
|
75
77
|
wordWrap: string;
|
76
78
|
wordBreak: string;
|
77
79
|
};
|
78
|
-
|
80
|
+
listViewItemSubtext: {
|
81
|
+
textOverflow: string;
|
82
|
+
overflow: string;
|
83
|
+
whiteSpace: string;
|
84
|
+
alignSelf: string;
|
85
|
+
fontSize: string;
|
86
|
+
mt: string;
|
79
87
|
color: string;
|
80
|
-
textTransform: string;
|
81
88
|
fontFamily: string;
|
89
|
+
fontWeight: number;
|
82
90
|
display: string;
|
83
91
|
overflowWrap: string;
|
84
92
|
maxWidth: string;
|
85
93
|
wordWrap: string;
|
86
94
|
wordBreak: string;
|
87
95
|
};
|
88
|
-
|
96
|
+
listViewItemText: {
|
97
|
+
textOverflow: string;
|
98
|
+
overflow: string;
|
99
|
+
whiteSpace: string;
|
100
|
+
alignSelf: string;
|
89
101
|
fontSize: string;
|
90
|
-
fontWeight: number;
|
91
102
|
color: string;
|
92
|
-
textTransform: string;
|
93
|
-
display: string;
|
94
103
|
fontFamily: string;
|
95
|
-
overflowWrap: string;
|
96
|
-
};
|
97
|
-
H1: {
|
98
104
|
fontWeight: number;
|
99
|
-
lineHeight: string;
|
100
|
-
fontSize: string;
|
101
|
-
color: string;
|
102
|
-
fontFamily: string;
|
103
105
|
display: string;
|
104
106
|
overflowWrap: string;
|
105
107
|
maxWidth: string;
|
106
108
|
wordWrap: string;
|
107
109
|
wordBreak: string;
|
108
110
|
};
|
109
|
-
|
111
|
+
placeholder: {
|
110
112
|
fontWeight: number;
|
111
|
-
|
113
|
+
color: string;
|
114
|
+
fontFamily: string;
|
115
|
+
};
|
116
|
+
panelHeaderSubtext: {
|
117
|
+
alignSelf: string;
|
112
118
|
fontSize: string;
|
119
|
+
mt: string;
|
113
120
|
color: string;
|
114
121
|
fontFamily: string;
|
122
|
+
fontWeight: number;
|
115
123
|
display: string;
|
116
124
|
overflowWrap: string;
|
117
125
|
maxWidth: string;
|
118
126
|
wordWrap: string;
|
119
127
|
wordBreak: string;
|
120
128
|
};
|
121
|
-
|
122
|
-
|
123
|
-
lineHeight: string;
|
129
|
+
panelHeaderText: {
|
130
|
+
alignSelf: string;
|
124
131
|
fontSize: string;
|
125
132
|
color: string;
|
126
133
|
fontFamily: string;
|
134
|
+
fontWeight: number;
|
127
135
|
display: string;
|
128
136
|
overflowWrap: string;
|
129
137
|
maxWidth: string;
|
130
138
|
wordWrap: string;
|
131
139
|
wordBreak: string;
|
132
140
|
};
|
133
|
-
|
141
|
+
sectionTitle: {
|
134
142
|
fontSize: string;
|
135
143
|
fontWeight: number;
|
136
144
|
color: string;
|
137
145
|
fontFamily: string;
|
138
|
-
lineHeight: string;
|
139
146
|
display: string;
|
140
147
|
overflowWrap: string;
|
141
148
|
maxWidth: string;
|
142
149
|
wordWrap: string;
|
143
150
|
wordBreak: string;
|
144
151
|
};
|
145
|
-
|
146
|
-
fontWeight: number;
|
152
|
+
subtitle: {
|
147
153
|
color: string;
|
148
154
|
fontFamily: string;
|
155
|
+
fontWeight: number;
|
156
|
+
display: string;
|
157
|
+
overflowWrap: string;
|
158
|
+
maxWidth: string;
|
159
|
+
wordWrap: string;
|
160
|
+
wordBreak: string;
|
149
161
|
};
|
150
|
-
|
162
|
+
tabLabel: {
|
151
163
|
fontSize: string;
|
152
164
|
fontWeight: number;
|
165
|
+
mb: string;
|
166
|
+
lineHeight: string;
|
153
167
|
color: string;
|
154
|
-
|
168
|
+
height: string;
|
169
|
+
'.is-selected &, .is-hovered &': {
|
170
|
+
color: string;
|
171
|
+
};
|
172
|
+
'.is-selected &': {
|
173
|
+
color: string;
|
174
|
+
mb: number;
|
175
|
+
};
|
176
|
+
'.is-disabled &': {
|
177
|
+
color: string;
|
178
|
+
};
|
155
179
|
display: string;
|
156
180
|
overflowWrap: string;
|
157
181
|
maxWidth: string;
|
158
182
|
wordWrap: string;
|
159
183
|
wordBreak: string;
|
184
|
+
fontFamily: string;
|
160
185
|
};
|
161
|
-
|
186
|
+
tableHeader: {
|
162
187
|
fontSize: string;
|
163
188
|
fontWeight: number;
|
164
189
|
color: string;
|
@@ -169,105 +194,115 @@ export declare const text: {
|
|
169
194
|
wordWrap: string;
|
170
195
|
wordBreak: string;
|
171
196
|
};
|
172
|
-
|
197
|
+
tableData: {
|
173
198
|
fontSize: string;
|
199
|
+
fontWeight: number;
|
174
200
|
color: string;
|
175
201
|
fontFamily: string;
|
176
|
-
fontWeight: number;
|
177
202
|
display: string;
|
178
203
|
overflowWrap: string;
|
179
204
|
maxWidth: string;
|
180
205
|
wordWrap: string;
|
181
206
|
wordBreak: string;
|
182
207
|
};
|
183
|
-
|
208
|
+
textEllipsis: {
|
184
209
|
textOverflow: string;
|
185
210
|
overflow: string;
|
186
211
|
whiteSpace: string;
|
212
|
+
};
|
213
|
+
title: {
|
187
214
|
fontSize: string;
|
188
215
|
fontWeight: number;
|
189
216
|
color: string;
|
217
|
+
fontFamily: string;
|
190
218
|
display: string;
|
191
219
|
overflowWrap: string;
|
192
220
|
maxWidth: string;
|
193
221
|
wordWrap: string;
|
194
222
|
wordBreak: string;
|
195
223
|
};
|
196
|
-
|
197
|
-
|
198
|
-
overflow: string;
|
199
|
-
whiteSpace: string;
|
200
|
-
fontSize: string;
|
224
|
+
H1: {
|
225
|
+
lineHeight: string;
|
201
226
|
fontWeight: number;
|
227
|
+
fontSize: string;
|
202
228
|
color: string;
|
229
|
+
fontFamily: string;
|
203
230
|
display: string;
|
204
231
|
overflowWrap: string;
|
205
232
|
maxWidth: string;
|
206
233
|
wordWrap: string;
|
207
234
|
wordBreak: string;
|
208
235
|
};
|
209
|
-
|
210
|
-
|
211
|
-
|
212
|
-
whiteSpace: string;
|
213
|
-
alignSelf: string;
|
236
|
+
H2: {
|
237
|
+
lineHeight: string;
|
238
|
+
fontWeight: number;
|
214
239
|
fontSize: string;
|
215
|
-
mt: string;
|
216
240
|
color: string;
|
217
241
|
fontFamily: string;
|
218
|
-
fontWeight: number;
|
219
242
|
display: string;
|
220
243
|
overflowWrap: string;
|
221
244
|
maxWidth: string;
|
222
245
|
wordWrap: string;
|
223
246
|
wordBreak: string;
|
224
247
|
};
|
225
|
-
|
226
|
-
|
227
|
-
|
228
|
-
whiteSpace: string;
|
229
|
-
alignSelf: string;
|
248
|
+
H3: {
|
249
|
+
lineHeight: string;
|
250
|
+
fontWeight: number;
|
230
251
|
fontSize: string;
|
231
252
|
color: string;
|
232
253
|
fontFamily: string;
|
233
|
-
fontWeight: number;
|
234
254
|
display: string;
|
235
255
|
overflowWrap: string;
|
236
256
|
maxWidth: string;
|
237
257
|
wordWrap: string;
|
238
258
|
wordBreak: string;
|
239
259
|
};
|
240
|
-
|
260
|
+
H4: {
|
261
|
+
lineHeight: string;
|
262
|
+
fontSize: string;
|
241
263
|
fontWeight: number;
|
242
264
|
color: string;
|
243
265
|
fontFamily: string;
|
266
|
+
display: string;
|
267
|
+
overflowWrap: string;
|
268
|
+
maxWidth: string;
|
269
|
+
wordWrap: string;
|
270
|
+
wordBreak: string;
|
244
271
|
};
|
245
|
-
|
246
|
-
|
272
|
+
h1: {
|
273
|
+
fontWeight: number;
|
247
274
|
fontSize: string;
|
248
|
-
mt: string;
|
249
275
|
color: string;
|
250
276
|
fontFamily: string;
|
251
|
-
fontWeight: number;
|
252
277
|
display: string;
|
253
278
|
overflowWrap: string;
|
254
279
|
maxWidth: string;
|
255
280
|
wordWrap: string;
|
256
281
|
wordBreak: string;
|
257
282
|
};
|
258
|
-
|
259
|
-
|
283
|
+
h2: {
|
284
|
+
fontWeight: number;
|
260
285
|
fontSize: string;
|
261
286
|
color: string;
|
262
287
|
fontFamily: string;
|
288
|
+
display: string;
|
289
|
+
overflowWrap: string;
|
290
|
+
maxWidth: string;
|
291
|
+
wordWrap: string;
|
292
|
+
wordBreak: string;
|
293
|
+
};
|
294
|
+
h3: {
|
263
295
|
fontWeight: number;
|
296
|
+
fontSize: string;
|
297
|
+
color: string;
|
298
|
+
fontFamily: string;
|
264
299
|
display: string;
|
265
300
|
overflowWrap: string;
|
266
301
|
maxWidth: string;
|
267
302
|
wordWrap: string;
|
268
303
|
wordBreak: string;
|
269
304
|
};
|
270
|
-
|
305
|
+
h4: {
|
271
306
|
fontSize: string;
|
272
307
|
fontWeight: number;
|
273
308
|
color: string;
|
@@ -278,7 +313,14 @@ export declare const text: {
|
|
278
313
|
wordWrap: string;
|
279
314
|
wordBreak: string;
|
280
315
|
};
|
281
|
-
|
316
|
+
base: {
|
317
|
+
display: string;
|
318
|
+
fontSize: string;
|
319
|
+
color: string;
|
320
|
+
fontFamily: string;
|
321
|
+
overflowWrap: string;
|
322
|
+
};
|
323
|
+
bodyStrong: {
|
282
324
|
color: string;
|
283
325
|
fontFamily: string;
|
284
326
|
fontWeight: number;
|
@@ -288,31 +330,17 @@ export declare const text: {
|
|
288
330
|
wordWrap: string;
|
289
331
|
wordBreak: string;
|
290
332
|
};
|
291
|
-
|
333
|
+
bodyWeak: {
|
292
334
|
fontSize: string;
|
293
|
-
fontWeight: number;
|
294
|
-
mb: string;
|
295
|
-
lineHeight: string;
|
296
335
|
color: string;
|
297
|
-
|
298
|
-
'.is-selected &, .is-hovered &': {
|
299
|
-
color: string;
|
300
|
-
};
|
301
|
-
'.is-selected &': {
|
302
|
-
color: string;
|
303
|
-
mb: number;
|
304
|
-
};
|
305
|
-
'.is-disabled &': {
|
306
|
-
color: string;
|
307
|
-
};
|
336
|
+
fontFamily: string;
|
308
337
|
display: string;
|
309
338
|
overflowWrap: string;
|
310
339
|
maxWidth: string;
|
311
340
|
wordWrap: string;
|
312
341
|
wordBreak: string;
|
313
|
-
fontFamily: string;
|
314
342
|
};
|
315
|
-
|
343
|
+
buttonLabel: {
|
316
344
|
fontSize: string;
|
317
345
|
fontWeight: number;
|
318
346
|
color: string;
|
@@ -323,31 +351,47 @@ export declare const text: {
|
|
323
351
|
wordWrap: string;
|
324
352
|
wordBreak: string;
|
325
353
|
};
|
326
|
-
|
354
|
+
buttonTitle: {
|
327
355
|
fontSize: string;
|
328
356
|
fontWeight: number;
|
329
357
|
color: string;
|
330
358
|
fontFamily: string;
|
359
|
+
lineHeight: string;
|
331
360
|
display: string;
|
332
361
|
overflowWrap: string;
|
333
362
|
maxWidth: string;
|
334
363
|
wordWrap: string;
|
335
364
|
wordBreak: string;
|
336
365
|
};
|
337
|
-
|
338
|
-
textOverflow: string;
|
339
|
-
overflow: string;
|
340
|
-
whiteSpace: string;
|
341
|
-
};
|
342
|
-
title: {
|
366
|
+
buttonSubtitle: {
|
343
367
|
fontSize: string;
|
344
368
|
fontWeight: number;
|
345
369
|
color: string;
|
346
370
|
fontFamily: string;
|
371
|
+
lineHeight: string;
|
372
|
+
display: string;
|
373
|
+
overflowWrap: string;
|
374
|
+
maxWidth: string;
|
375
|
+
wordWrap: string;
|
376
|
+
wordBreak: string;
|
377
|
+
};
|
378
|
+
capsLabel: {
|
379
|
+
color: string;
|
380
|
+
textTransform: string;
|
381
|
+
fontFamily: string;
|
347
382
|
display: string;
|
348
383
|
overflowWrap: string;
|
349
384
|
maxWidth: string;
|
350
385
|
wordWrap: string;
|
351
386
|
wordBreak: string;
|
352
387
|
};
|
388
|
+
environmentBreadcrumb: {
|
389
|
+
fontSize: string;
|
390
|
+
fontWeight: number;
|
391
|
+
color: string;
|
392
|
+
textTransform: string;
|
393
|
+
display: string;
|
394
|
+
fontFamily: string;
|
395
|
+
overflowWrap: string;
|
396
|
+
};
|
353
397
|
};
|
@@ -98,7 +98,38 @@ var listViewItemSubtext = _objectSpread(_objectSpread({}, subtitle), {}, {
|
|
98
98
|
fontSize: 'sm',
|
99
99
|
mt: '1px'
|
100
100
|
});
|
101
|
-
var
|
101
|
+
var hTags = {
|
102
|
+
h1: _objectSpread(_objectSpread({}, title), {}, {
|
103
|
+
fontWeight: 3
|
104
|
+
}),
|
105
|
+
h2: _objectSpread(_objectSpread({}, sectionTitle), {}, {
|
106
|
+
fontWeight: 3
|
107
|
+
}),
|
108
|
+
h3: _objectSpread(_objectSpread({}, itemTitle), {}, {
|
109
|
+
fontWeight: 3
|
110
|
+
}),
|
111
|
+
h4: _objectSpread(_objectSpread({}, wordWrap), {}, {
|
112
|
+
fontSize: 'sm',
|
113
|
+
fontWeight: 3,
|
114
|
+
color: 'text.primary',
|
115
|
+
fontFamily: 'standard'
|
116
|
+
})
|
117
|
+
};
|
118
|
+
var HTags = {
|
119
|
+
H1: _objectSpread(_objectSpread({}, hTags.h1), {}, {
|
120
|
+
lineHeight: '28px'
|
121
|
+
}),
|
122
|
+
H2: _objectSpread(_objectSpread({}, hTags.h2), {}, {
|
123
|
+
lineHeight: '21px'
|
124
|
+
}),
|
125
|
+
H3: _objectSpread(_objectSpread({}, hTags.h3), {}, {
|
126
|
+
lineHeight: '18px'
|
127
|
+
}),
|
128
|
+
H4: _objectSpread(_objectSpread({}, hTags.h4), {}, {
|
129
|
+
lineHeight: '16px'
|
130
|
+
})
|
131
|
+
};
|
132
|
+
var text = _objectSpread(_objectSpread(_objectSpread({
|
102
133
|
base: base,
|
103
134
|
bodyStrong: bodyStrong,
|
104
135
|
bodyWeak: _objectSpread(_objectSpread({}, wordWrap), {}, {
|
@@ -131,26 +162,8 @@ var text = {
|
|
131
162
|
textTransform: 'uppercase',
|
132
163
|
fontFamily: 'standard'
|
133
164
|
}),
|
134
|
-
environmentBreadcrumb: environmentBreadcrumb
|
135
|
-
|
136
|
-
fontWeight: 3,
|
137
|
-
lineHeight: '28px'
|
138
|
-
}),
|
139
|
-
H2: _objectSpread(_objectSpread({}, sectionTitle), {}, {
|
140
|
-
fontWeight: 3,
|
141
|
-
lineHeight: '21px'
|
142
|
-
}),
|
143
|
-
H3: _objectSpread(_objectSpread({}, itemTitle), {}, {
|
144
|
-
fontWeight: 3,
|
145
|
-
lineHeight: '18px'
|
146
|
-
}),
|
147
|
-
H4: _objectSpread(_objectSpread({}, wordWrap), {}, {
|
148
|
-
fontSize: 'sm',
|
149
|
-
fontWeight: 3,
|
150
|
-
color: 'text.primary',
|
151
|
-
fontFamily: 'standard',
|
152
|
-
lineHeight: '16px'
|
153
|
-
}),
|
165
|
+
environmentBreadcrumb: environmentBreadcrumb
|
166
|
+
}, hTags), HTags), {}, {
|
154
167
|
inputValue: {
|
155
168
|
fontWeight: 1,
|
156
169
|
color: 'text.primary',
|
@@ -205,5 +218,5 @@ var text = {
|
|
205
218
|
}),
|
206
219
|
textEllipsis: textEllipsis,
|
207
220
|
title: title
|
208
|
-
};
|
221
|
+
});
|
209
222
|
exports.text = text;
|
@@ -7,7 +7,8 @@ _Object$defineProperty(exports, "__esModule", {
|
|
7
7
|
exports.FIGMA_LINKS = void 0;
|
8
8
|
var FIGMA_LINKS = {
|
9
9
|
accordionGroup: {
|
10
|
-
"default": 'https://www.figma.com/file/bpbEw54gTTcdIiZs4PKK1p/Astro-Specs?type=design&node-id=446-1808&t=8Wwd3tIBh3GEjCJB-0'
|
10
|
+
"default": 'https://www.figma.com/file/bpbEw54gTTcdIiZs4PKK1p/Astro-Specs?type=design&node-id=446-1808&t=8Wwd3tIBh3GEjCJB-0',
|
11
|
+
differentLevels: 'https://www.figma.com/file/bpbEw54gTTcdIiZs4PKK1p/Astro-Specs?node-id=446%3A1949&mode=dev'
|
11
12
|
},
|
12
13
|
attributeMappings: {
|
13
14
|
"default": 'https://www.figma.com/file/bpbEw54gTTcdIiZs4PKK1p/Astro-Specs?node-id=15076%3A33905&mode=dev',
|
@@ -37,6 +37,11 @@ var body = {
|
|
37
37
|
display: 'flex'
|
38
38
|
}
|
39
39
|
};
|
40
|
+
export var hoveredState = {
|
41
|
+
'&.is-hovered': {
|
42
|
+
color: 'active'
|
43
|
+
}
|
44
|
+
};
|
40
45
|
var header = _objectSpread(_objectSpread({}, base), {}, {
|
41
46
|
display: 'inline-flex',
|
42
47
|
bg: 'transparent',
|
@@ -44,14 +49,11 @@ var header = _objectSpread(_objectSpread({}, base), {}, {
|
|
44
49
|
padding: '0 5px',
|
45
50
|
flexGrow: 0,
|
46
51
|
fontWeight: 700,
|
47
|
-
'&.is-hovered': {
|
48
|
-
color: 'active'
|
49
|
-
},
|
50
52
|
'&.is-pressed': {
|
51
53
|
color: 'accent.20'
|
52
54
|
},
|
53
55
|
'&.is-focused': _objectSpread({}, defaultFocus)
|
54
|
-
});
|
56
|
+
}, hoveredState);
|
55
57
|
export default {
|
56
58
|
title: title,
|
57
59
|
accordion: accordion,
|
@@ -9,7 +9,7 @@ import _Object$defineProperty from "@babel/runtime-corejs3/core-js-stable/object
|
|
9
9
|
import _extends from "@babel/runtime-corejs3/helpers/esm/extends";
|
10
10
|
import _defineProperty from "@babel/runtime-corejs3/helpers/esm/defineProperty";
|
11
11
|
import _objectWithoutProperties from "@babel/runtime-corejs3/helpers/esm/objectWithoutProperties";
|
12
|
-
var _excluded = ["defaultExpandedKeys", "expandedKeys", "onExpandedChange"],
|
12
|
+
var _excluded = ["defaultExpandedKeys", "expandedKeys", "labelHeadingTag", "onExpandedChange"],
|
13
13
|
_excluded2 = ["onFocus"];
|
14
14
|
import _mapInstanceProperty from "@babel/runtime-corejs3/core-js-stable/instance/map";
|
15
15
|
import _Array$from from "@babel/runtime-corejs3/core-js-stable/array/from";
|
@@ -35,6 +35,7 @@ var AccordionGroup = /*#__PURE__*/forwardRef(function (props, ref) {
|
|
35
35
|
var _context;
|
36
36
|
var defaultExpandedKeys = props.defaultExpandedKeys,
|
37
37
|
expandedKeys = props.expandedKeys,
|
38
|
+
labelHeadingTag = props.labelHeadingTag,
|
38
39
|
onExpandedChange = props.onExpandedChange,
|
39
40
|
others = _objectWithoutProperties(props, _excluded);
|
40
41
|
var state = useTreeState(props);
|
@@ -61,9 +62,10 @@ var AccordionGroup = /*#__PURE__*/forwardRef(function (props, ref) {
|
|
61
62
|
ref: accordionRef
|
62
63
|
}, mergeProps(theseProps, others)), _mapInstanceProperty(_context = _Array$from(state.collection)).call(_context, function (item) {
|
63
64
|
return ___EmotionJSX(AccordionItem, {
|
64
|
-
|
65
|
+
"data-id": item['data-id'],
|
65
66
|
item: item,
|
66
|
-
|
67
|
+
key: item.key,
|
68
|
+
labelHeadingTag: labelHeadingTag
|
67
69
|
}, item.props.children);
|
68
70
|
})));
|
69
71
|
});
|
@@ -82,7 +84,9 @@ AccordionGroup.propTypes = {
|
|
82
84
|
/** The initial expanded keys in the collection (uncontrolled). */
|
83
85
|
defaultExpandedKeys: isIterableProp,
|
84
86
|
/** Id of the selected element */
|
85
|
-
id: PropTypes.string
|
87
|
+
id: PropTypes.string,
|
88
|
+
/** HTML header element wrapping the label */
|
89
|
+
labelHeadingTag: AccordionItem.propTypes.labelHeadingTag
|
86
90
|
};
|
87
91
|
AccordionGroup.displayName = 'AccordionGroup';
|
88
92
|
export default AccordionGroup;
|