@bytebrand/fe-ui-core 4.0.253 → 4.0.254

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@bytebrand/fe-ui-core",
3
- "version": "4.0.253",
3
+ "version": "4.0.254",
4
4
  "description": "UI components for the auto.de project",
5
5
  "main": "index.ts",
6
6
  "module": "dist/common.js",
@@ -22,6 +22,7 @@ export interface IExpansionPanelProps {
22
22
  expandedClassName?: string;
23
23
  arrowIconClassName?: string;
24
24
  expanded?: string | boolean;
25
+ accordionClassName?: string;
25
26
  }
26
27
 
27
28
  interface IConditionalWrapperProps {
@@ -46,7 +47,8 @@ class ExpansionPanel extends React.Component<IExpansionPanelProps> {
46
47
  defaultExpanded,
47
48
  subTitleClassName,
48
49
  onChange,
49
- expanded
50
+ expanded,
51
+ accordionClassName
50
52
  } = this.props;
51
53
 
52
54
  const scrollElementClassName = classnames(reactScrollClassName);
@@ -60,8 +62,9 @@ class ExpansionPanel extends React.Component<IExpansionPanelProps> {
60
62
  <ThemeProvider theme={Theme}>
61
63
  <Accordion
62
64
  defaultExpanded={defaultExpanded}
63
- onChange={onChange(reactScrollName)}
64
- expanded={expanded === reactScrollName}
65
+ onChange={!!onChange && onChange(reactScrollName)}
66
+ expanded={!!expanded && (expanded === reactScrollName)}
67
+ className={accordionClassName}
65
68
  >
66
69
  <AccordionSummary
67
70
  expandIcon={<IconSVG name={'arrowSelect'} className={styles.icon} customDimensions />}