@widergy/energy-ui 3.96.7 → 3.97.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/CHANGELOG.md +7 -0
- package/dist/components/UTPanel/UTPanel.mdx +11 -0
- package/dist/components/UTPanel/UTPanel.stories.js +700 -0
- package/dist/components/UTPanel/versions/V1/README.md +40 -36
- package/dist/components/UTPanel/versions/V1/index.js +39 -5
- package/dist/components/UTPanel/versions/V1/styles.module.scss +11 -6
- package/dist/constants/testIds.js +1 -0
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,3 +1,10 @@
|
|
|
1
|
+
# [3.97.0](https://github.com/widergy/energy-ui/compare/v3.96.7...v3.97.0) (2025-08-11)
|
|
2
|
+
|
|
3
|
+
|
|
4
|
+
### Features
|
|
5
|
+
|
|
6
|
+
* [AXCH-556] add back button to utpanel v1 ([#660](https://github.com/widergy/energy-ui/issues/660)) ([7f178f4](https://github.com/widergy/energy-ui/commit/7f178f45479d13382cb229a09b51cfb19998db8f))
|
|
7
|
+
|
|
1
8
|
## [3.96.7](https://github.com/widergy/energy-ui/compare/v3.96.6...v3.96.7) (2025-08-06)
|
|
2
9
|
|
|
3
10
|
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { ArgTypes, Canvas, Description, Meta, Title } from '@storybook/addon-docs';
|
|
2
|
+
|
|
3
|
+
import * as UTPanelStories from './UTPanel.stories';
|
|
4
|
+
|
|
5
|
+
<Meta of={UTPanelStories} />
|
|
6
|
+
|
|
7
|
+
<Title>UTPanel</Title>
|
|
8
|
+
|
|
9
|
+
<Description of={UTPanelStories} />
|
|
10
|
+
|
|
11
|
+
<ArgTypes />
|
|
@@ -0,0 +1,700 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.default = exports.V1Workflow = exports.V1WithStatus = exports.V1WithPagination = exports.V1WithHeaderItems = exports.V1WithActions = exports.V1LargeSize = exports.V1Inline = exports.V1Default = exports.V1Collapsible = exports.V0WithCustomTitle = exports.V0LeftSide = exports.V0Default = exports.Playground = void 0;
|
|
7
|
+
var _react = _interopRequireDefault(require("react"));
|
|
8
|
+
var _utils = require("stories/utils");
|
|
9
|
+
var _UTLabel = _interopRequireDefault(require("../UTLabel"));
|
|
10
|
+
var _UTButton = _interopRequireDefault(require("../UTButton"));
|
|
11
|
+
var _2 = _interopRequireDefault(require("."));
|
|
12
|
+
function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
|
|
13
|
+
// Mock content for the panel
|
|
14
|
+
const mockContent = /*#__PURE__*/_react.default.createElement("div", {
|
|
15
|
+
style: {
|
|
16
|
+
padding: '16px'
|
|
17
|
+
}
|
|
18
|
+
}, /*#__PURE__*/_react.default.createElement(_UTLabel.default, {
|
|
19
|
+
variant: "body1",
|
|
20
|
+
style: {
|
|
21
|
+
marginBottom: '16px'
|
|
22
|
+
}
|
|
23
|
+
}, "Este es el contenido del panel. Aqu\xED puedes agregar cualquier componente o contenido que necesites."), /*#__PURE__*/_react.default.createElement(_UTLabel.default, {
|
|
24
|
+
variant: "body2",
|
|
25
|
+
colorTheme: "gray",
|
|
26
|
+
style: {
|
|
27
|
+
marginBottom: '16px'
|
|
28
|
+
}
|
|
29
|
+
}, "Lorem ipsum dolor sit amet, consectetur adipiscing elit. Sed do eiusmod tempor incididunt ut labore et dolore magna aliqua."), /*#__PURE__*/_react.default.createElement("div", {
|
|
30
|
+
style: {
|
|
31
|
+
marginTop: '24px'
|
|
32
|
+
}
|
|
33
|
+
}, /*#__PURE__*/_react.default.createElement(_UTButton.default, {
|
|
34
|
+
variant: "filled",
|
|
35
|
+
colorTheme: "primary",
|
|
36
|
+
style: {
|
|
37
|
+
marginRight: '8px'
|
|
38
|
+
}
|
|
39
|
+
}, "Acci\xF3n Principal"), /*#__PURE__*/_react.default.createElement(_UTButton.default, {
|
|
40
|
+
variant: "outlined",
|
|
41
|
+
colorTheme: "gray"
|
|
42
|
+
}, "Acci\xF3n Secundaria")));
|
|
43
|
+
const headerItemsExample = [{
|
|
44
|
+
title: 'Estado',
|
|
45
|
+
icon: 'IconCheck',
|
|
46
|
+
value: 'Completado'
|
|
47
|
+
}, {
|
|
48
|
+
title: 'Fecha',
|
|
49
|
+
icon: 'IconCalendar',
|
|
50
|
+
value: '15/12/2023'
|
|
51
|
+
}, {
|
|
52
|
+
title: 'Usuario',
|
|
53
|
+
icon: 'IconUser',
|
|
54
|
+
value: 'Juan Pérez'
|
|
55
|
+
}];
|
|
56
|
+
var _default = exports.default = {
|
|
57
|
+
args: {
|
|
58
|
+
children: mockContent,
|
|
59
|
+
open: false,
|
|
60
|
+
title: 'Título del Panel',
|
|
61
|
+
version: 'V0'
|
|
62
|
+
},
|
|
63
|
+
argTypes: {
|
|
64
|
+
version: {
|
|
65
|
+
control: 'select',
|
|
66
|
+
description: 'Versión del componente a utilizar.',
|
|
67
|
+
options: ['V0', 'V1'],
|
|
68
|
+
table: {
|
|
69
|
+
defaultValue: {
|
|
70
|
+
summary: 'V0'
|
|
71
|
+
},
|
|
72
|
+
type: {
|
|
73
|
+
summary: (0, _utils.joinArgTypes)(['V0', 'V1'])
|
|
74
|
+
}
|
|
75
|
+
}
|
|
76
|
+
},
|
|
77
|
+
open: {
|
|
78
|
+
control: 'boolean',
|
|
79
|
+
description: 'Controla si el panel está abierto o cerrado.',
|
|
80
|
+
table: {
|
|
81
|
+
defaultValue: {
|
|
82
|
+
summary: 'false'
|
|
83
|
+
},
|
|
84
|
+
type: {
|
|
85
|
+
summary: 'boolean'
|
|
86
|
+
}
|
|
87
|
+
}
|
|
88
|
+
},
|
|
89
|
+
title: {
|
|
90
|
+
control: 'text',
|
|
91
|
+
description: 'Título que se muestra en el header del panel.',
|
|
92
|
+
table: {
|
|
93
|
+
defaultValue: {
|
|
94
|
+
summary: 'undefined'
|
|
95
|
+
},
|
|
96
|
+
type: {
|
|
97
|
+
summary: 'string'
|
|
98
|
+
}
|
|
99
|
+
}
|
|
100
|
+
},
|
|
101
|
+
subtitle: {
|
|
102
|
+
control: 'text',
|
|
103
|
+
description: '(V1 only) Subtítulo que se muestra debajo del título.',
|
|
104
|
+
table: {
|
|
105
|
+
defaultValue: {
|
|
106
|
+
summary: 'undefined'
|
|
107
|
+
},
|
|
108
|
+
type: {
|
|
109
|
+
summary: 'string'
|
|
110
|
+
}
|
|
111
|
+
}
|
|
112
|
+
},
|
|
113
|
+
panelSide: {
|
|
114
|
+
control: 'select',
|
|
115
|
+
description: 'Lado desde el cual aparece el panel.',
|
|
116
|
+
options: ['left', 'right', 'top', 'bottom'],
|
|
117
|
+
table: {
|
|
118
|
+
defaultValue: {
|
|
119
|
+
summary: 'right'
|
|
120
|
+
},
|
|
121
|
+
type: {
|
|
122
|
+
summary: (0, _utils.joinArgTypes)(['left', 'right', 'top', 'bottom'])
|
|
123
|
+
}
|
|
124
|
+
}
|
|
125
|
+
},
|
|
126
|
+
size: {
|
|
127
|
+
control: 'select',
|
|
128
|
+
description: '(V1 only) Tamaño del panel.',
|
|
129
|
+
options: ['S', 'M', 'L'],
|
|
130
|
+
table: {
|
|
131
|
+
defaultValue: {
|
|
132
|
+
summary: 'M'
|
|
133
|
+
},
|
|
134
|
+
type: {
|
|
135
|
+
summary: (0, _utils.joinArgTypes)(['S', 'M', 'L'])
|
|
136
|
+
}
|
|
137
|
+
}
|
|
138
|
+
},
|
|
139
|
+
disableScrollbar: {
|
|
140
|
+
control: 'boolean',
|
|
141
|
+
description: 'Deshabilita el scrollbar del contenido.',
|
|
142
|
+
table: {
|
|
143
|
+
defaultValue: {
|
|
144
|
+
summary: 'false'
|
|
145
|
+
},
|
|
146
|
+
type: {
|
|
147
|
+
summary: 'boolean'
|
|
148
|
+
}
|
|
149
|
+
}
|
|
150
|
+
},
|
|
151
|
+
hideCloseButton: {
|
|
152
|
+
control: 'boolean',
|
|
153
|
+
description: '(V1 only) Oculta el botón de cerrar.',
|
|
154
|
+
table: {
|
|
155
|
+
defaultValue: {
|
|
156
|
+
summary: 'false'
|
|
157
|
+
},
|
|
158
|
+
type: {
|
|
159
|
+
summary: 'boolean'
|
|
160
|
+
}
|
|
161
|
+
}
|
|
162
|
+
},
|
|
163
|
+
hideHeader: {
|
|
164
|
+
control: 'boolean',
|
|
165
|
+
description: '(V1 only) Oculta completamente el header.',
|
|
166
|
+
table: {
|
|
167
|
+
defaultValue: {
|
|
168
|
+
summary: 'false'
|
|
169
|
+
},
|
|
170
|
+
type: {
|
|
171
|
+
summary: 'boolean'
|
|
172
|
+
}
|
|
173
|
+
}
|
|
174
|
+
},
|
|
175
|
+
hideMainButton: {
|
|
176
|
+
control: 'boolean',
|
|
177
|
+
description: '(V1 only) Oculta el botón principal del footer.',
|
|
178
|
+
table: {
|
|
179
|
+
defaultValue: {
|
|
180
|
+
summary: 'false'
|
|
181
|
+
},
|
|
182
|
+
type: {
|
|
183
|
+
summary: 'boolean'
|
|
184
|
+
}
|
|
185
|
+
}
|
|
186
|
+
},
|
|
187
|
+
showBackButton: {
|
|
188
|
+
control: 'boolean',
|
|
189
|
+
description: '(V1 only) Muestra el botón de volver.',
|
|
190
|
+
table: {
|
|
191
|
+
defaultValue: {
|
|
192
|
+
summary: 'false'
|
|
193
|
+
},
|
|
194
|
+
type: {
|
|
195
|
+
summary: 'boolean'
|
|
196
|
+
}
|
|
197
|
+
}
|
|
198
|
+
},
|
|
199
|
+
showTag: {
|
|
200
|
+
control: 'boolean',
|
|
201
|
+
description: '(V1 only) Muestra un tag en el header.',
|
|
202
|
+
table: {
|
|
203
|
+
defaultValue: {
|
|
204
|
+
summary: 'false'
|
|
205
|
+
},
|
|
206
|
+
type: {
|
|
207
|
+
summary: 'boolean'
|
|
208
|
+
}
|
|
209
|
+
}
|
|
210
|
+
},
|
|
211
|
+
showMainStatus: {
|
|
212
|
+
control: 'boolean',
|
|
213
|
+
description: '(V1 only) Muestra un status principal en el header.',
|
|
214
|
+
table: {
|
|
215
|
+
defaultValue: {
|
|
216
|
+
summary: 'false'
|
|
217
|
+
},
|
|
218
|
+
type: {
|
|
219
|
+
summary: 'boolean'
|
|
220
|
+
}
|
|
221
|
+
}
|
|
222
|
+
},
|
|
223
|
+
showPagination: {
|
|
224
|
+
control: 'boolean',
|
|
225
|
+
description: '(V1 only) Muestra controles de paginación.',
|
|
226
|
+
table: {
|
|
227
|
+
defaultValue: {
|
|
228
|
+
summary: 'false'
|
|
229
|
+
},
|
|
230
|
+
type: {
|
|
231
|
+
summary: 'boolean'
|
|
232
|
+
}
|
|
233
|
+
}
|
|
234
|
+
},
|
|
235
|
+
inline: {
|
|
236
|
+
control: 'boolean',
|
|
237
|
+
description: '(V1 only) Renderiza el panel inline en lugar de modal.',
|
|
238
|
+
table: {
|
|
239
|
+
defaultValue: {
|
|
240
|
+
summary: 'false'
|
|
241
|
+
},
|
|
242
|
+
type: {
|
|
243
|
+
summary: 'boolean'
|
|
244
|
+
}
|
|
245
|
+
}
|
|
246
|
+
},
|
|
247
|
+
collapsablePanel: {
|
|
248
|
+
control: 'boolean',
|
|
249
|
+
description: '(V1 only) Permite colapsar el panel cuando está inline.',
|
|
250
|
+
table: {
|
|
251
|
+
defaultValue: {
|
|
252
|
+
summary: 'false'
|
|
253
|
+
},
|
|
254
|
+
type: {
|
|
255
|
+
summary: 'boolean'
|
|
256
|
+
}
|
|
257
|
+
}
|
|
258
|
+
},
|
|
259
|
+
collapsableHeader: {
|
|
260
|
+
control: 'boolean',
|
|
261
|
+
description: '(V1 only) Permite colapsar el contenido del header.',
|
|
262
|
+
table: {
|
|
263
|
+
defaultValue: {
|
|
264
|
+
summary: 'false'
|
|
265
|
+
},
|
|
266
|
+
type: {
|
|
267
|
+
summary: 'boolean'
|
|
268
|
+
}
|
|
269
|
+
}
|
|
270
|
+
},
|
|
271
|
+
isWorkflow: {
|
|
272
|
+
control: 'boolean',
|
|
273
|
+
description: '(V1 only) Activa el modo workflow con barra de progreso.',
|
|
274
|
+
table: {
|
|
275
|
+
defaultValue: {
|
|
276
|
+
summary: 'false'
|
|
277
|
+
},
|
|
278
|
+
type: {
|
|
279
|
+
summary: 'boolean'
|
|
280
|
+
}
|
|
281
|
+
}
|
|
282
|
+
},
|
|
283
|
+
currentStep: {
|
|
284
|
+
control: 'number',
|
|
285
|
+
description: '(V1 only) Paso actual del workflow.',
|
|
286
|
+
table: {
|
|
287
|
+
defaultValue: {
|
|
288
|
+
summary: '1'
|
|
289
|
+
},
|
|
290
|
+
type: {
|
|
291
|
+
summary: 'number'
|
|
292
|
+
}
|
|
293
|
+
}
|
|
294
|
+
},
|
|
295
|
+
stepsCount: {
|
|
296
|
+
control: 'number',
|
|
297
|
+
description: '(V1 only) Total de pasos del workflow.',
|
|
298
|
+
table: {
|
|
299
|
+
defaultValue: {
|
|
300
|
+
summary: 'undefined'
|
|
301
|
+
},
|
|
302
|
+
type: {
|
|
303
|
+
summary: 'number'
|
|
304
|
+
}
|
|
305
|
+
}
|
|
306
|
+
},
|
|
307
|
+
onClose: {
|
|
308
|
+
control: false,
|
|
309
|
+
description: 'Callback ejecutado al cerrar el panel.',
|
|
310
|
+
table: {
|
|
311
|
+
defaultValue: {
|
|
312
|
+
summary: 'undefined'
|
|
313
|
+
},
|
|
314
|
+
type: {
|
|
315
|
+
summary: 'function'
|
|
316
|
+
}
|
|
317
|
+
}
|
|
318
|
+
},
|
|
319
|
+
onOpen: {
|
|
320
|
+
control: false,
|
|
321
|
+
description: 'Callback ejecutado al abrir el panel.',
|
|
322
|
+
table: {
|
|
323
|
+
defaultValue: {
|
|
324
|
+
summary: 'undefined'
|
|
325
|
+
},
|
|
326
|
+
type: {
|
|
327
|
+
summary: 'function'
|
|
328
|
+
}
|
|
329
|
+
}
|
|
330
|
+
},
|
|
331
|
+
onGoBack: {
|
|
332
|
+
control: false,
|
|
333
|
+
description: '(V1 only) Callback ejecutado al presionar el botón de volver.',
|
|
334
|
+
table: {
|
|
335
|
+
defaultValue: {
|
|
336
|
+
summary: 'undefined'
|
|
337
|
+
},
|
|
338
|
+
type: {
|
|
339
|
+
summary: 'function'
|
|
340
|
+
}
|
|
341
|
+
}
|
|
342
|
+
},
|
|
343
|
+
children: {
|
|
344
|
+
control: false,
|
|
345
|
+
description: 'Contenido del panel.',
|
|
346
|
+
table: {
|
|
347
|
+
defaultValue: {
|
|
348
|
+
summary: 'undefined'
|
|
349
|
+
},
|
|
350
|
+
type: {
|
|
351
|
+
summary: 'ReactNode'
|
|
352
|
+
}
|
|
353
|
+
}
|
|
354
|
+
},
|
|
355
|
+
classes: {
|
|
356
|
+
control: false,
|
|
357
|
+
description: 'Clases CSS personalizadas para diferentes elementos.',
|
|
358
|
+
table: {
|
|
359
|
+
defaultValue: {
|
|
360
|
+
summary: '{}'
|
|
361
|
+
},
|
|
362
|
+
type: {
|
|
363
|
+
summary: 'object'
|
|
364
|
+
}
|
|
365
|
+
}
|
|
366
|
+
},
|
|
367
|
+
classNames: {
|
|
368
|
+
control: false,
|
|
369
|
+
description: '(V1 only) Clases CSS personalizadas para diferentes elementos.',
|
|
370
|
+
table: {
|
|
371
|
+
defaultValue: {
|
|
372
|
+
summary: 'undefined'
|
|
373
|
+
},
|
|
374
|
+
type: {
|
|
375
|
+
summary: 'object'
|
|
376
|
+
}
|
|
377
|
+
}
|
|
378
|
+
}
|
|
379
|
+
},
|
|
380
|
+
component: _2.default,
|
|
381
|
+
parameters: {
|
|
382
|
+
controls: {
|
|
383
|
+
exclude: ['modalProps', 'perfectScrollbarOptions', 'containerRef', 'TitleComponent', 'TitleIcon', 'HeaderComponent', 'headerItems', 'headerMainActionButton', 'headerSecondaryActionButton', 'mainButton', 'statusProps', 'tagProps', 'titleProps', 'paginationProps', 'BackdropProps', 'onEndReachedCallback', 'titleDataTestId', 'closeButtonDataTestId', 'backButtonDataTestId', 'mainActionDataTestId', 'secondaryActionDataTestId', 'singleHeaderItemsColumn']
|
|
384
|
+
},
|
|
385
|
+
docs: {
|
|
386
|
+
description: {
|
|
387
|
+
component: 'Componente Panel con dos versiones disponibles. V0 es una versión básica con funcionalidad de drawer. V1 es una versión avanzada con múltiples características como workflow, header items, botones de acción, etc.'
|
|
388
|
+
}
|
|
389
|
+
}
|
|
390
|
+
}
|
|
391
|
+
}; // V0 Stories
|
|
392
|
+
const V0Default = exports.V0Default = {
|
|
393
|
+
args: {
|
|
394
|
+
version: 'V0',
|
|
395
|
+
open: false,
|
|
396
|
+
title: 'Panel V0 - Básico',
|
|
397
|
+
panelSide: 'right',
|
|
398
|
+
disableScrollbar: false
|
|
399
|
+
},
|
|
400
|
+
name: 'V0 - Básico'
|
|
401
|
+
};
|
|
402
|
+
const V0WithCustomTitle = exports.V0WithCustomTitle = {
|
|
403
|
+
args: {
|
|
404
|
+
version: 'V0',
|
|
405
|
+
open: false,
|
|
406
|
+
title: 'Panel con Título Personalizado',
|
|
407
|
+
panelSide: 'right',
|
|
408
|
+
children: /*#__PURE__*/_react.default.createElement("div", {
|
|
409
|
+
style: {
|
|
410
|
+
padding: '16px'
|
|
411
|
+
}
|
|
412
|
+
}, /*#__PURE__*/_react.default.createElement(_UTLabel.default, {
|
|
413
|
+
variant: "title2",
|
|
414
|
+
weight: "medium",
|
|
415
|
+
style: {
|
|
416
|
+
marginBottom: '16px'
|
|
417
|
+
}
|
|
418
|
+
}, "Contenido del Panel V0"), /*#__PURE__*/_react.default.createElement(_UTLabel.default, {
|
|
419
|
+
variant: "body1"
|
|
420
|
+
}, "Este panel utiliza la versi\xF3n V0 que es m\xE1s simple y b\xE1sica."))
|
|
421
|
+
},
|
|
422
|
+
name: 'V0 - Con Título Personalizado'
|
|
423
|
+
};
|
|
424
|
+
const V0LeftSide = exports.V0LeftSide = {
|
|
425
|
+
args: {
|
|
426
|
+
version: 'V0',
|
|
427
|
+
open: false,
|
|
428
|
+
title: 'Panel desde la Izquierda',
|
|
429
|
+
panelSide: 'left',
|
|
430
|
+
children: /*#__PURE__*/_react.default.createElement("div", {
|
|
431
|
+
style: {
|
|
432
|
+
padding: '16px'
|
|
433
|
+
}
|
|
434
|
+
}, /*#__PURE__*/_react.default.createElement(_UTLabel.default, {
|
|
435
|
+
variant: "body1"
|
|
436
|
+
}, "Este panel aparece desde el lado izquierdo de la pantalla."))
|
|
437
|
+
},
|
|
438
|
+
name: 'V0 - Lado Izquierdo'
|
|
439
|
+
};
|
|
440
|
+
|
|
441
|
+
// V1 Stories
|
|
442
|
+
const V1Default = exports.V1Default = {
|
|
443
|
+
args: {
|
|
444
|
+
version: 'V1',
|
|
445
|
+
open: false,
|
|
446
|
+
title: 'Panel V1 - Avanzado',
|
|
447
|
+
subtitle: 'Subtítulo descriptivo',
|
|
448
|
+
panelSide: 'right',
|
|
449
|
+
size: 'M'
|
|
450
|
+
},
|
|
451
|
+
name: 'V1 - Básico'
|
|
452
|
+
};
|
|
453
|
+
const V1WithHeaderItems = exports.V1WithHeaderItems = {
|
|
454
|
+
args: {
|
|
455
|
+
version: 'V1',
|
|
456
|
+
open: false,
|
|
457
|
+
title: 'Panel con Header Items',
|
|
458
|
+
subtitle: 'Información adicional en el header',
|
|
459
|
+
panelSide: 'right',
|
|
460
|
+
size: 'M',
|
|
461
|
+
headerItems: headerItemsExample,
|
|
462
|
+
children: /*#__PURE__*/_react.default.createElement("div", {
|
|
463
|
+
style: {
|
|
464
|
+
padding: '16px'
|
|
465
|
+
}
|
|
466
|
+
}, /*#__PURE__*/_react.default.createElement(_UTLabel.default, {
|
|
467
|
+
variant: "body1"
|
|
468
|
+
}, "Este panel V1 incluye items adicionales en el header que muestran informaci\xF3n relevante."))
|
|
469
|
+
},
|
|
470
|
+
name: 'V1 - Con Header Items'
|
|
471
|
+
};
|
|
472
|
+
const V1WithActions = exports.V1WithActions = {
|
|
473
|
+
args: {
|
|
474
|
+
version: 'V1',
|
|
475
|
+
open: false,
|
|
476
|
+
title: 'Panel con Acciones',
|
|
477
|
+
subtitle: 'Panel con botones de acción',
|
|
478
|
+
panelSide: 'right',
|
|
479
|
+
size: 'M',
|
|
480
|
+
headerMainActionButton: {
|
|
481
|
+
colorTheme: 'error',
|
|
482
|
+
text: 'Guardar',
|
|
483
|
+
onClick: () => alert('Acción principal ejecutada')
|
|
484
|
+
},
|
|
485
|
+
headerSecondaryActionButton: {
|
|
486
|
+
text: 'Cancelar',
|
|
487
|
+
onClick: () => alert('Acción secundaria ejecutada')
|
|
488
|
+
},
|
|
489
|
+
mainButton: {
|
|
490
|
+
text: 'Confirmar',
|
|
491
|
+
onClick: () => alert('Botón principal ejecutado')
|
|
492
|
+
},
|
|
493
|
+
children: /*#__PURE__*/_react.default.createElement("div", {
|
|
494
|
+
style: {
|
|
495
|
+
padding: '16px'
|
|
496
|
+
}
|
|
497
|
+
}, /*#__PURE__*/_react.default.createElement(_UTLabel.default, {
|
|
498
|
+
variant: "body1"
|
|
499
|
+
}, "Este panel incluye botones de acci\xF3n tanto en el header como en el footer."))
|
|
500
|
+
},
|
|
501
|
+
name: 'V1 - Con Acciones'
|
|
502
|
+
};
|
|
503
|
+
const V1WithStatus = exports.V1WithStatus = {
|
|
504
|
+
args: {
|
|
505
|
+
version: 'V1',
|
|
506
|
+
open: false,
|
|
507
|
+
title: 'Panel con Status',
|
|
508
|
+
subtitle: 'Panel con tag y status principal',
|
|
509
|
+
panelSide: 'right',
|
|
510
|
+
size: 'M',
|
|
511
|
+
showTag: true,
|
|
512
|
+
showMainStatus: true,
|
|
513
|
+
tagProps: {
|
|
514
|
+
variant: 'information',
|
|
515
|
+
children: 'Nuevo'
|
|
516
|
+
},
|
|
517
|
+
statusProps: {
|
|
518
|
+
variant: 'success',
|
|
519
|
+
label: 'Activo'
|
|
520
|
+
},
|
|
521
|
+
children: /*#__PURE__*/_react.default.createElement("div", {
|
|
522
|
+
style: {
|
|
523
|
+
padding: '16px'
|
|
524
|
+
}
|
|
525
|
+
}, /*#__PURE__*/_react.default.createElement(_UTLabel.default, {
|
|
526
|
+
variant: "body1"
|
|
527
|
+
}, "Este panel muestra un tag y un status principal en el header."))
|
|
528
|
+
},
|
|
529
|
+
name: 'V1 - Con Status y Tag'
|
|
530
|
+
};
|
|
531
|
+
const V1Workflow = exports.V1Workflow = {
|
|
532
|
+
args: {
|
|
533
|
+
version: 'V1',
|
|
534
|
+
open: false,
|
|
535
|
+
title: 'Workflow Panel',
|
|
536
|
+
subtitle: 'Panel en modo workflow',
|
|
537
|
+
panelSide: 'right',
|
|
538
|
+
size: 'L',
|
|
539
|
+
isWorkflow: true,
|
|
540
|
+
currentStep: 2,
|
|
541
|
+
stepsCount: 5,
|
|
542
|
+
showBackButton: true,
|
|
543
|
+
onGoBack: () => alert('Volver al paso anterior'),
|
|
544
|
+
children: /*#__PURE__*/_react.default.createElement("div", {
|
|
545
|
+
style: {
|
|
546
|
+
padding: '16px'
|
|
547
|
+
}
|
|
548
|
+
}, /*#__PURE__*/_react.default.createElement(_UTLabel.default, {
|
|
549
|
+
variant: "title3",
|
|
550
|
+
weight: "medium",
|
|
551
|
+
style: {
|
|
552
|
+
marginBottom: '16px'
|
|
553
|
+
}
|
|
554
|
+
}, "Paso 2 de 5"), /*#__PURE__*/_react.default.createElement(_UTLabel.default, {
|
|
555
|
+
variant: "body1"
|
|
556
|
+
}, "Este panel est\xE1 en modo workflow y muestra una barra de progreso en la parte superior."))
|
|
557
|
+
},
|
|
558
|
+
name: 'V1 - Workflow'
|
|
559
|
+
};
|
|
560
|
+
const V1WithPagination = exports.V1WithPagination = {
|
|
561
|
+
args: {
|
|
562
|
+
version: 'V1',
|
|
563
|
+
open: false,
|
|
564
|
+
title: 'Panel con Paginación',
|
|
565
|
+
subtitle: 'Navegación por páginas',
|
|
566
|
+
panelSide: 'right',
|
|
567
|
+
size: 'M',
|
|
568
|
+
showPagination: true,
|
|
569
|
+
paginationProps: {
|
|
570
|
+
currentPage: 2,
|
|
571
|
+
totalPages: 10,
|
|
572
|
+
nextButton: {
|
|
573
|
+
onClick: () => alert('Página siguiente')
|
|
574
|
+
},
|
|
575
|
+
backButton: {
|
|
576
|
+
onClick: () => alert('Página anterior')
|
|
577
|
+
}
|
|
578
|
+
},
|
|
579
|
+
children: /*#__PURE__*/_react.default.createElement("div", {
|
|
580
|
+
style: {
|
|
581
|
+
padding: '16px'
|
|
582
|
+
}
|
|
583
|
+
}, /*#__PURE__*/_react.default.createElement(_UTLabel.default, {
|
|
584
|
+
variant: "body1"
|
|
585
|
+
}, "Este panel incluye controles de paginaci\xF3n en la parte superior."))
|
|
586
|
+
},
|
|
587
|
+
name: 'V1 - Con Paginación'
|
|
588
|
+
};
|
|
589
|
+
const V1Inline = exports.V1Inline = {
|
|
590
|
+
args: {
|
|
591
|
+
version: 'V1',
|
|
592
|
+
open: false,
|
|
593
|
+
title: 'Panel Inline',
|
|
594
|
+
subtitle: 'Panel renderizado inline',
|
|
595
|
+
panelSide: 'right',
|
|
596
|
+
size: 'M',
|
|
597
|
+
inline: true,
|
|
598
|
+
children: /*#__PURE__*/_react.default.createElement("div", {
|
|
599
|
+
style: {
|
|
600
|
+
padding: '16px'
|
|
601
|
+
}
|
|
602
|
+
}, /*#__PURE__*/_react.default.createElement(_UTLabel.default, {
|
|
603
|
+
variant: "body1"
|
|
604
|
+
}, "Este panel est\xE1 renderizado inline en lugar de como un modal."))
|
|
605
|
+
},
|
|
606
|
+
name: 'V1 - Inline',
|
|
607
|
+
parameters: {
|
|
608
|
+
docs: {
|
|
609
|
+
description: {
|
|
610
|
+
story: 'Panel renderizado inline. Útil cuando se necesita integrar el panel como parte del layout principal.'
|
|
611
|
+
}
|
|
612
|
+
}
|
|
613
|
+
}
|
|
614
|
+
};
|
|
615
|
+
const V1Collapsible = exports.V1Collapsible = {
|
|
616
|
+
args: {
|
|
617
|
+
version: 'V1',
|
|
618
|
+
open: false,
|
|
619
|
+
title: 'Panel Colapsable',
|
|
620
|
+
subtitle: 'Panel que se puede colapsar',
|
|
621
|
+
panelSide: 'right',
|
|
622
|
+
size: 'M',
|
|
623
|
+
inline: true,
|
|
624
|
+
collapsablePanel: true,
|
|
625
|
+
collapsableHeader: true,
|
|
626
|
+
headerItems: headerItemsExample,
|
|
627
|
+
children: /*#__PURE__*/_react.default.createElement("div", {
|
|
628
|
+
style: {
|
|
629
|
+
padding: '16px'
|
|
630
|
+
}
|
|
631
|
+
}, /*#__PURE__*/_react.default.createElement(_UTLabel.default, {
|
|
632
|
+
variant: "body1"
|
|
633
|
+
}, "Este panel se puede colapsar completamente y tambi\xE9n tiene un header colapsable."))
|
|
634
|
+
},
|
|
635
|
+
name: 'V1 - Colapsable',
|
|
636
|
+
parameters: {
|
|
637
|
+
docs: {
|
|
638
|
+
description: {
|
|
639
|
+
story: 'Panel con capacidad de colapsar tanto el contenido completo como el header.'
|
|
640
|
+
}
|
|
641
|
+
}
|
|
642
|
+
}
|
|
643
|
+
};
|
|
644
|
+
const V1LargeSize = exports.V1LargeSize = {
|
|
645
|
+
args: {
|
|
646
|
+
version: 'V1',
|
|
647
|
+
open: false,
|
|
648
|
+
title: 'Panel Grande',
|
|
649
|
+
subtitle: 'Panel con tamaño Large',
|
|
650
|
+
panelSide: 'right',
|
|
651
|
+
size: 'L',
|
|
652
|
+
headerItems: headerItemsExample,
|
|
653
|
+
children: /*#__PURE__*/_react.default.createElement("div", {
|
|
654
|
+
style: {
|
|
655
|
+
padding: '16px'
|
|
656
|
+
}
|
|
657
|
+
}, /*#__PURE__*/_react.default.createElement(_UTLabel.default, {
|
|
658
|
+
variant: "body1"
|
|
659
|
+
}, "Este panel utiliza el tama\xF1o Large (L) para mostrar m\xE1s contenido."), /*#__PURE__*/_react.default.createElement("div", {
|
|
660
|
+
style: {
|
|
661
|
+
marginTop: '20px'
|
|
662
|
+
}
|
|
663
|
+
}, Array.from({
|
|
664
|
+
length: 10
|
|
665
|
+
}, (_, i) => /*#__PURE__*/_react.default.createElement(_UTLabel.default, {
|
|
666
|
+
key: i,
|
|
667
|
+
variant: "body2",
|
|
668
|
+
style: {
|
|
669
|
+
display: 'block',
|
|
670
|
+
marginBottom: '8px'
|
|
671
|
+
}
|
|
672
|
+
}, "L\xEDnea de contenido ", i + 1, " - Lorem ipsum dolor sit amet consectetur."))))
|
|
673
|
+
},
|
|
674
|
+
name: 'V1 - Tamaño Grande'
|
|
675
|
+
};
|
|
676
|
+
const Playground = exports.Playground = {
|
|
677
|
+
args: {
|
|
678
|
+
version: 'V1',
|
|
679
|
+
open: false,
|
|
680
|
+
title: 'Panel Playground',
|
|
681
|
+
subtitle: 'Experimenta con todas las opciones',
|
|
682
|
+
panelSide: 'right',
|
|
683
|
+
size: 'M',
|
|
684
|
+
disableScrollbar: false,
|
|
685
|
+
hideCloseButton: false,
|
|
686
|
+
hideHeader: false,
|
|
687
|
+
hideMainButton: false,
|
|
688
|
+
showBackButton: false,
|
|
689
|
+
showTag: false,
|
|
690
|
+
showMainStatus: false,
|
|
691
|
+
showPagination: false,
|
|
692
|
+
inline: false,
|
|
693
|
+
collapsablePanel: false,
|
|
694
|
+
collapsableHeader: false,
|
|
695
|
+
isWorkflow: false,
|
|
696
|
+
currentStep: 1,
|
|
697
|
+
stepsCount: 3
|
|
698
|
+
},
|
|
699
|
+
name: 'Playground'
|
|
700
|
+
};
|
|
@@ -4,39 +4,43 @@ Component used for displaying a side panel.
|
|
|
4
4
|
|
|
5
5
|
## Props
|
|
6
6
|
|
|
7
|
-
| Name | Type
|
|
8
|
-
| :-------------------------- |
|
|
9
|
-
| children | node
|
|
10
|
-
| classes | object
|
|
11
|
-
| classNames | object
|
|
12
|
-
| collapsableHeader | bool
|
|
13
|
-
| currentStep | number
|
|
14
|
-
| disableScrollbar | bool
|
|
15
|
-
| HeaderComponent | node
|
|
16
|
-
| headerItems | array
|
|
17
|
-
| headerMainActionButton | object
|
|
18
|
-
| headerSecondaryActionButton | object
|
|
19
|
-
| hideCloseButton | bool
|
|
20
|
-
| hideHeader | bool
|
|
21
|
-
| hideMainButton | bool
|
|
22
|
-
| isWorkflow | bool
|
|
23
|
-
| mainButton | object
|
|
24
|
-
| modalProps | object
|
|
25
|
-
| onClose | func
|
|
26
|
-
| onEndReachedCallback | func
|
|
27
|
-
|
|
|
28
|
-
|
|
|
29
|
-
|
|
|
30
|
-
|
|
|
31
|
-
|
|
|
32
|
-
|
|
|
33
|
-
|
|
|
34
|
-
|
|
|
35
|
-
|
|
|
36
|
-
|
|
|
37
|
-
|
|
|
38
|
-
|
|
|
39
|
-
|
|
|
40
|
-
|
|
|
41
|
-
|
|
|
42
|
-
|
|
|
7
|
+
| Name | Type | Default | Description |
|
|
8
|
+
| :-------------------------- | ------- | -------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
|
|
9
|
+
| children | node | | Component content |
|
|
10
|
+
| classes | object | | Classes returned by UTPanel own[theme](./theme.js#L40) `retrieveStyle` and classes received from props. |
|
|
11
|
+
| classNames | object | | Overrides the default panel theme. headerMainActionButton |
|
|
12
|
+
| collapsableHeader | bool | false | Indicates if "header items" section is collapsible. |
|
|
13
|
+
| currentStep | number | 1 | Workflow step number used to show the current progress in the UTProgressBar |
|
|
14
|
+
| disableScrollbar | bool | false | Render the children without scrollbar |
|
|
15
|
+
| HeaderComponent | node | | Custom header to render. |
|
|
16
|
+
| headerItems | array | | Array of items (object) to show in "header items" section. Each item should have: "title" - String, "icon" - String, "value" - String |
|
|
17
|
+
| headerMainActionButton | object | | Object with header main button details: "colorTheme" - string - deafult: 'primary' // "variant" - string - default: 'semitransparent'<br />// This prop will be spread so that it supports any UTButton props. |
|
|
18
|
+
| headerSecondaryActionButton | object | | Object with header secondary button details: "colorTheme" - string - default: "success" // "variant" - string - default: "filled" // This prop will be spread so that it supports any UTButton props. |
|
|
19
|
+
| hideCloseButton | bool | false | Indicates whether the close button is hide or not |
|
|
20
|
+
| hideHeader | bool | false | Indicates whether the entire header is hide or not |
|
|
21
|
+
| hideMainButton | bool | false | Indicates whether the main (bottom) button is hide or not |
|
|
22
|
+
| isWorkflow | bool | false | Indicates if the panel children's content a workflow. This prop activates the progress bar. |
|
|
23
|
+
| mainButton | object | | [UTButton props](https://github.com/widergy/Energy-UI/tree/master/src/lib/components/UTButton) |
|
|
24
|
+
| modalProps | object | | Material UI[modal props](https://v4.mui.com/api/modal/) |
|
|
25
|
+
| onClose | func | | Callback to execute when closing panel. |
|
|
26
|
+
| onEndReachedCallback | func | | Callback to execute when reaching the end of the vertical scroll |
|
|
27
|
+
| onGoBack | func | () => {} | Callback to execute when goBackButton is used |
|
|
28
|
+
| onOpen | func | () => {} | Callback to execute when opening panel. |
|
|
29
|
+
| open | bool | | Indicates whether the panel is open or not |
|
|
30
|
+
| panelSide | string | | Indicates panel side. |
|
|
31
|
+
| perfectScrollbarOptions | object | | [Perfect scrollbar](https://www.npmjs.com/package/react-perfect-scrollbar) props |
|
|
32
|
+
| singleHeaderItemsColumn | bool | false | Indicates whether the header items are shown in a single column or not |
|
|
33
|
+
| size | string | 'M' | Indicates the size of panel. Currently we have two options:<br /> L -> 800px<br /> M -> 450px |
|
|
34
|
+
| stepsCount | Number | | Indicates the total steps in case of workflow |
|
|
35
|
+
| subtitle | string | | Subtitle to show |
|
|
36
|
+
| title | string | | Title to show |
|
|
37
|
+
| titleProps | object | {} | UTLabel props for title. Default props: variant="title2" weight="medium" |
|
|
38
|
+
| collapsablePanel | bool | false | Indicates if panel can be collapsed when inline mode is enabled |
|
|
39
|
+
| inline | bool | false | Indicates if panel should be rendered inline instead of as a modal |
|
|
40
|
+
| paginationProps | object | {} | Object containing pagination configuration: nextButton (UTButton props), backButton (UTButton props), currentPage (number), totalPages (number) |
|
|
41
|
+
| showMainStatus | bool | false | Shows a status indicator next to the title |
|
|
42
|
+
| showPagination | bool | false | Shows pagination controls in the header |
|
|
43
|
+
| statusProps | object | {} | Props passed to UTStatus component when showMainStatus is true |
|
|
44
|
+
| showBackButton | boolean | false | Shows a go back arrow button |
|
|
45
|
+
| showTag | bool | false | Shows a tag indicator in the header area. When true, the tagProps object is passed to the UTStatus component to render a tag. |
|
|
46
|
+
| tagProps | object | {} | Object containing props for the UTStatus component used as a tag in the header. Supports all [UTStatus props](https://github.com/widergy/Energy-UI/tree/master/src/lib/components/UTStatus) |
|
|
@@ -31,10 +31,11 @@ const {
|
|
|
31
31
|
} = _testIds.TEST_IDS;
|
|
32
32
|
const UTPanel = _ref => {
|
|
33
33
|
let {
|
|
34
|
+
backButtonDataTestId = panel.backButton,
|
|
34
35
|
BackdropProps = {},
|
|
35
36
|
children,
|
|
36
|
-
classes: theme,
|
|
37
37
|
classNames,
|
|
38
|
+
classes: theme,
|
|
38
39
|
closeButtonDataTestId = panel.closeButton,
|
|
39
40
|
collapsableHeader = false,
|
|
40
41
|
collapsablePanel = false,
|
|
@@ -54,19 +55,23 @@ const UTPanel = _ref => {
|
|
|
54
55
|
modalProps,
|
|
55
56
|
onClose,
|
|
56
57
|
onEndReachedCallback,
|
|
58
|
+
onGoBack = () => {},
|
|
57
59
|
onOpen = () => {},
|
|
58
60
|
open,
|
|
59
61
|
paginationProps = {},
|
|
60
62
|
panelSide,
|
|
61
63
|
perfectScrollbarOptions,
|
|
62
64
|
secondaryActionDataTestId = panel.secondaryAction,
|
|
65
|
+
showBackButton = false,
|
|
63
66
|
showMainStatus = false,
|
|
64
67
|
showPagination = false,
|
|
68
|
+
showTag = false,
|
|
65
69
|
singleHeaderItemsColumn = false,
|
|
66
70
|
size = 'M',
|
|
67
71
|
statusProps = {},
|
|
68
72
|
stepsCount,
|
|
69
73
|
subtitle = '',
|
|
74
|
+
tagProps = {},
|
|
70
75
|
title = '',
|
|
71
76
|
titleDataTestId = panel.title,
|
|
72
77
|
titleProps = {},
|
|
@@ -87,8 +92,10 @@ const UTPanel = _ref => {
|
|
|
87
92
|
totalPages = 1
|
|
88
93
|
} = paginationProps;
|
|
89
94
|
const {
|
|
95
|
+
backButton: backButtonClass,
|
|
90
96
|
closeButton: closeButtonClass,
|
|
91
97
|
headerContainer: headerContainerClass,
|
|
98
|
+
iconBack: iconBackClass,
|
|
92
99
|
iconClose: iconCloseClass,
|
|
93
100
|
perfectScrollbar: perfectScrollbarClass,
|
|
94
101
|
title: titleClass,
|
|
@@ -119,11 +126,22 @@ const UTPanel = _ref => {
|
|
|
119
126
|
open: panelIsCollapsible || open,
|
|
120
127
|
swipeAreaWidth: 0,
|
|
121
128
|
variant: inline ? collapsablePanel ? 'permanent' : 'persistent' : 'temporary'
|
|
122
|
-
}, props), (!hideCloseButton || isWorkflow || panelIsCollapsible) && /*#__PURE__*/_react.default.createElement("div", {
|
|
129
|
+
}, props), (!hideCloseButton || isWorkflow || panelIsCollapsible || showBackButton) && /*#__PURE__*/_react.default.createElement("div", {
|
|
123
130
|
className: _stylesModule.default.controlAreaContainer
|
|
124
131
|
}, /*#__PURE__*/_react.default.createElement("div", {
|
|
125
132
|
className: _stylesModule.default.controlAreaBar
|
|
126
|
-
},
|
|
133
|
+
}, showBackButton && /*#__PURE__*/_react.default.createElement("div", {
|
|
134
|
+
className: _stylesModule.default.backButtonContainer
|
|
135
|
+
}, /*#__PURE__*/_react.default.createElement(_UTButton.default, {
|
|
136
|
+
classNames: {
|
|
137
|
+
icon: iconBackClass,
|
|
138
|
+
root: backButtonClass
|
|
139
|
+
},
|
|
140
|
+
dataTestId: backButtonDataTestId,
|
|
141
|
+
Icon: "IconArrowLeft",
|
|
142
|
+
onClick: onGoBack,
|
|
143
|
+
variant: "text"
|
|
144
|
+
})), showPagination && /*#__PURE__*/_react.default.createElement("div", {
|
|
127
145
|
className: _stylesModule.default.paginationContainer
|
|
128
146
|
}, /*#__PURE__*/_react.default.createElement(_UTLabel.default, {
|
|
129
147
|
colorTheme: "gray"
|
|
@@ -155,7 +173,7 @@ const UTPanel = _ref => {
|
|
|
155
173
|
className: _stylesModule.default.headerArea
|
|
156
174
|
}, /*#__PURE__*/_react.default.createElement("div", {
|
|
157
175
|
className: _stylesModule.default.headerLeftArea
|
|
158
|
-
}, /*#__PURE__*/_react.default.createElement("div", {
|
|
176
|
+
}, showTag && tagProps && /*#__PURE__*/_react.default.createElement(_UTStatus.default, tagProps, tagProps.children), /*#__PURE__*/_react.default.createElement("div", {
|
|
159
177
|
className: _stylesModule.default.titleArea
|
|
160
178
|
}, /*#__PURE__*/_react.default.createElement(_UTLabel.default, _extends({
|
|
161
179
|
className: classes.title,
|
|
@@ -209,6 +227,7 @@ const UTPanel = _ref => {
|
|
|
209
227
|
}, mainButton), (mainButton === null || mainButton === void 0 ? void 0 : mainButton.text) || _constants.ACCEPT_BUTTON_TEXT));
|
|
210
228
|
};
|
|
211
229
|
UTPanel.propTypes = {
|
|
230
|
+
backButtonDataTestId: _propTypes.string,
|
|
212
231
|
BackdropProps: _propTypes.object,
|
|
213
232
|
classes: (0, _propTypes.objectOf)(_propTypes.string),
|
|
214
233
|
classNames: _propTypes.object,
|
|
@@ -245,6 +264,7 @@ UTPanel.propTypes = {
|
|
|
245
264
|
modalProps: _propTypes.object,
|
|
246
265
|
onClose: _propTypes.func,
|
|
247
266
|
onEndReachedCallback: _propTypes.func,
|
|
267
|
+
onGoBack: _propTypes.func,
|
|
248
268
|
onOpen: _propTypes.func,
|
|
249
269
|
open: _propTypes.bool,
|
|
250
270
|
panelSide: _propTypes.string,
|
|
@@ -252,14 +272,28 @@ UTPanel.propTypes = {
|
|
|
252
272
|
secondaryActionDataTestId: _propTypes.string,
|
|
253
273
|
singleHeaderItemsColumn: _propTypes.bool,
|
|
254
274
|
size: (0, _propTypes.oneOf)(Object.keys(_constants.SIZES)),
|
|
275
|
+
showBackButton: _propTypes.bool,
|
|
255
276
|
showMainStatus: _propTypes.bool,
|
|
277
|
+
showTag: _propTypes.bool,
|
|
278
|
+
showPagination: _propTypes.bool,
|
|
256
279
|
statusProps: _propTypes.object,
|
|
257
280
|
stepsCount: _propTypes.number,
|
|
258
|
-
showPagination: _propTypes.bool,
|
|
259
281
|
currentPage: _propTypes.number,
|
|
260
282
|
totalPages: _propTypes.number,
|
|
261
283
|
subtitle: _propTypes.string,
|
|
262
284
|
paginationProps: _propTypes.object,
|
|
285
|
+
tagProps: (0, _propTypes.shape)({
|
|
286
|
+
classes: (0, _propTypes.objectOf)(_propTypes.string),
|
|
287
|
+
className: _propTypes.string,
|
|
288
|
+
Icon: _propTypes.elementType,
|
|
289
|
+
iconProps: _propTypes.object,
|
|
290
|
+
labelDataTestId: _propTypes.string,
|
|
291
|
+
size: _propTypes.string,
|
|
292
|
+
title: _propTypes.string,
|
|
293
|
+
type: _propTypes.string,
|
|
294
|
+
variant: _propTypes.string,
|
|
295
|
+
withoutIcon: _propTypes.bool
|
|
296
|
+
}),
|
|
263
297
|
title: _propTypes.string,
|
|
264
298
|
titleDataTestId: _propTypes.string,
|
|
265
299
|
titleProps: _propTypes.object
|
|
@@ -8,6 +8,11 @@ $collapsed-panel-size: 58px;
|
|
|
8
8
|
height: 100%;
|
|
9
9
|
}
|
|
10
10
|
|
|
11
|
+
.backButtonContainer {
|
|
12
|
+
margin-right: auto;
|
|
13
|
+
padding-right: 8px;
|
|
14
|
+
}
|
|
15
|
+
|
|
11
16
|
.controlAreaBar {
|
|
12
17
|
display: flex;
|
|
13
18
|
justify-content: flex-end;
|
|
@@ -64,25 +69,25 @@ $collapsed-panel-size: 58px;
|
|
|
64
69
|
.headerItemsContainer {
|
|
65
70
|
display: flex;
|
|
66
71
|
flex-wrap: wrap;
|
|
72
|
+
margin-top: 0;
|
|
73
|
+
|
|
74
|
+
max-height: 100%;
|
|
67
75
|
padding: 0 24px;
|
|
68
76
|
transition:
|
|
69
77
|
max-height 0.08s ease,
|
|
70
78
|
opacity 0.08s ease,
|
|
71
79
|
margin-top 0.08s ease;
|
|
72
|
-
|
|
73
|
-
max-height: 100%;
|
|
74
|
-
margin-top: 0;
|
|
75
80
|
}
|
|
76
81
|
|
|
77
82
|
.expandedContainer {
|
|
78
|
-
opacity: 1;
|
|
79
83
|
max-height: 100%;
|
|
84
|
+
opacity: 1;
|
|
80
85
|
}
|
|
81
86
|
|
|
82
87
|
.collapsedContainer {
|
|
83
|
-
opacity: 0;
|
|
84
|
-
max-height: 0;
|
|
85
88
|
margin-top: -16px;
|
|
89
|
+
max-height: 0;
|
|
90
|
+
opacity: 0;
|
|
86
91
|
}
|
|
87
92
|
|
|
88
93
|
.small {
|
|
@@ -65,6 +65,7 @@ const TEST_IDS = exports.TEST_IDS = {
|
|
|
65
65
|
title: "".concat(ID_CONSTANTS.ONBOARDING, ".title")
|
|
66
66
|
},
|
|
67
67
|
panel: {
|
|
68
|
+
backButton: "".concat(ID_CONSTANTS.PANEL, ".backButton"),
|
|
68
69
|
closeButton: "".concat(ID_CONSTANTS.PANEL, ".closeButton"),
|
|
69
70
|
mainAction: "".concat(ID_CONSTANTS.PANEL, ".mainAction"),
|
|
70
71
|
secondaryAction: "".concat(ID_CONSTANTS.PANEL, ".secondaryAction"),
|