@bytebrand/fe-ui-core 4.1.197 → 4.1.198

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.1.197",
3
+ "version": "4.1.198",
4
4
  "description": "UI components for the auto.de project",
5
5
  "main": "index.ts",
6
6
  "module": "dist/common.js",
@@ -125,7 +125,7 @@ export const HIGHLIGHTS_TYPES = transformHighlights();
125
125
 
126
126
  export const FilterBlockFactory: IFilterBlockFactory = {
127
127
  SUPER_ADMIN: (props: any): JSX.Element => (<SuperAdminWidget {...props} />),
128
- BASIC_DATA: (props: any): JSX.Element => (<BasicDataWidget {...props} />),
128
+ BASIC_DATA: (props: any): JSX.Element => (<BasicDataWidget {...props} isNotDetailed={true}/>),
129
129
  DRIVE_TRANSMISSION: (props: any): JSX.Element => (<DriveTransmissionWidget {...props} />),
130
130
  BODY_COLOR: (props: any): JSX.Element => (<BodyColorWidget {...props} />),
131
131
  INTERIOR: (props: any): JSX.Element => (<InteriorWidget {...props} />),
@@ -10,6 +10,7 @@ interface IFuelProps {
10
10
  values: any[];
11
11
  aggregation?: any;
12
12
  t?: any;
13
+ isNotDetailed:boolean;
13
14
  onChange: (fieldName: string, fieldValue: string[]) => void;
14
15
  }
15
16
 
@@ -28,7 +29,7 @@ class Fuel extends React.Component<IFuelProps, {}> {
28
29
  };
29
30
 
30
31
  getOptions = (options: string[]) => options.map((option: string) => {
31
- const { t } = this.props;
32
+ const { t, isNotDetailed } = this.props;
32
33
 
33
34
  const agg = this.getAggregation(option);
34
35
 
@@ -36,6 +37,7 @@ class Fuel extends React.Component<IFuelProps, {}> {
36
37
  value: option,
37
38
  label: (
38
39
  <span className={styles.wrapOptions}>
40
+ {!isNotDetailed?<IconSVG name={option} customDimensions />:null}
39
41
  <FilterLabel text={t(`cbd:${option}`)} agg={agg} />
40
42
  </span>
41
43
  )
@@ -6,13 +6,14 @@ import MakeModel, { IMakeModelProps } from '../../SearchPage/Filters/MakeModel/M
6
6
  interface IBasicDataWidgetState {
7
7
  t: (phrase: string) => string;
8
8
  [key: string]: any;
9
+ isNotDetailed?: boolean;
9
10
  }
10
11
 
11
12
  class BasicDataWidget extends React.Component<IMakeModelProps, IBasicDataWidgetState> {
12
13
  render(): JSX.Element {
13
14
  const {
14
15
  MMS_GROUPS, BODY_TYPE, FIRST_REGISTRATION, MILEAGE, POWER, PRICE, RATE, CONSUMPTION,
15
- SEATS, DOORS, FUEL, onFilterChange, onChangeFilterControls, onAddMmsGroup, onRemoveMmsGroup, t
16
+ SEATS, DOORS, FUEL, onFilterChange, onChangeFilterControls, onAddMmsGroup, onRemoveMmsGroup, t, isNotDetailed
16
17
  } = this.props;
17
18
 
18
19
  const makeModelProps = {
@@ -37,7 +38,9 @@ class BasicDataWidget extends React.Component<IMakeModelProps, IBasicDataWidgetS
37
38
  values: FUEL.values,
38
39
  aggregation: FUEL.aggregation || {},
39
40
  onChange: onFilterChange,
40
- className: styles.fuelOptions
41
+ className: styles.fuelOptions,
42
+ // tslint:disable-next-line:object-literal-shorthand
43
+ isNotDetailed: isNotDetailed
41
44
  };
42
45
 
43
46
  const consumptionProps = {