@bytebrand/fe-ui-core 4.1.41 → 4.1.42

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.41",
3
+ "version": "4.1.42",
4
4
  "description": "UI components for the auto.de project",
5
5
  "main": "index.ts",
6
6
  "module": "dist/common.js",
@@ -4,29 +4,38 @@
4
4
 
5
5
  .wrapper
6
6
  text-align: center
7
- white-space: nowrap
7
+ white-space: nowrap;
8
+ position: relative;
8
9
  width: 100%
9
10
 
10
11
  .pointer
11
12
  cursor: pointer
12
13
 
13
14
  .label
14
- display: block
15
- font-family: $font-style-arial
16
- font-size: 8px
17
- line-height: 1;
15
+ font-size: 12px
18
16
  text-transform: uppercase
19
17
  font-weight: bold
20
- color: $priceReviewColors[darkBackground]
21
- margin-bottom: 2px
22
-
23
- +media-phone-only()
24
- font-size: 10px
25
- margin-bottom: 6px;
18
+ color: $priceReviewColors[darkBackground];
26
19
 
27
20
  .segmentWrapper
28
- display: flex
29
- justify-content: center
21
+ display: flex;
22
+ box-sizing: border-box;
23
+ align-items: center;
24
+ height: 30px;
25
+ justify-content: center;
26
+ border-radius: 4px;
27
+ position: relative;
28
+ border: 1px solid $priceReviewColors[darkBackground];
29
+ &:before
30
+ content: '';
31
+ height: inherit;
32
+ position: absolute;
33
+ top: 0;
34
+ left: 0;
35
+ border-radius: 4px 0px 0px 4px;
36
+ width: 12px;
37
+ background-color: $priceReviewColors[darkBackground];
38
+ z-index: 2;
30
39
 
31
40
  .segment
32
41
  display: inline-block
@@ -49,10 +58,13 @@
49
58
 
50
59
  for colorName in $priceReviewColors
51
60
  $color = $priceReviewColors[colorName]
61
+ $backgroundColor = $priceReviewColors[colorName]
52
62
  if $color == $priceReviewColors.noRating
53
63
  $color = $priceReviewColors[darkBackground]
54
64
  $backgroundColor = $priceReviewColors[colorName]
55
65
  .{colorName}
56
66
  color: $color
57
67
  .{colorName}Background
58
- background-color: $backgroundColor
68
+ border-color: $backgroundColor
69
+ &:before
70
+ background-color: $backgroundColor
@@ -20,7 +20,7 @@ export interface IPriceRatingProps {
20
20
  const PriceRating: React.SFC<IPriceRatingProps> = ({ t, rating, className, darkBackground, i18nPrefix, classLabel, classSegmentWrapper, onClick }) => {
21
21
  const ratingCode = (rating > 0 && rating < priceRatings.length) ? rating : 0;
22
22
  const ratingName = priceRatings[ratingCode];
23
-
23
+ console.log('ratingName', ratingName);
24
24
  const onWrapperClick = (event: React.SyntheticEvent<HTMLDivElement>) => {
25
25
  if (typeof onClick === 'function') {
26
26
  onClick(event);
@@ -46,10 +46,11 @@ const PriceRating: React.SFC<IPriceRatingProps> = ({ t, rating, className, darkB
46
46
  className={classnames(styles.wrapper, className, { [styles.pointer]: typeof onClick === 'function' })}
47
47
  onClick={onWrapperClick}
48
48
  >
49
- <span className={classnames(styles.label, styles[ratingName], classLabel)}>
50
- {t(`${i18nPrefix}${ratingName}`)}
51
- </span>
52
- <div className={classnames(styles.segmentWrapper, classSegmentWrapper)}>{renderSegments()}</div>
49
+ <div className={classnames(styles.segmentWrapper, styles[`${ratingName}Background`], classSegmentWrapper)}>
50
+ <span className={classnames(styles.label, styles[ratingName], classLabel)}>
51
+ {t(`${i18nPrefix}${ratingName}`)}
52
+ </span>
53
+ </div>
53
54
  </div>
54
55
  );
55
56
  };
@@ -53,11 +53,6 @@
53
53
  .priceRating
54
54
  [class^=PriceRating__label]
55
55
  font-size: 10px;
56
- margin-bottom: 12px;
57
- [class^=PriceRating__segmentWrapper] > div
58
- max-width: 18px;
59
- width: 18px;
60
- height: 14px
61
56
 
62
57
  .financingUnits
63
58
  color: rgba($grey-3, .8);
@@ -20,7 +20,6 @@
20
20
  & > div:last-of-type
21
21
  width: 100%;
22
22
  max-width: 142px;
23
- margin: 0 auto;
24
23
  display flex
25
24
  flex-direction: column;
26
25
  justify-content: center;
@@ -74,18 +74,18 @@
74
74
  padding-top: 15px;
75
75
 
76
76
  +media-tablet-landscape-up()
77
- margin-top: 20px;
77
+ margin-top: 19px;
78
78
  padding-top: 0;
79
79
  border: none;
80
80
 
81
81
  .btnCompareRemove
82
82
  min-width: 50px !important;
83
- height: 34px;
83
+ height: 30px;
84
84
  border: 1px solid #BA1A1A !important;
85
85
 
86
86
  .btnCarToCompare
87
87
  display: flex;
88
- height: 34px;
88
+ height: 30px;
89
89
  align-items: center;
90
90
  text-transform uppercase !important
91
91
  width: 100%;
@@ -95,8 +95,8 @@
95
95
  .btnPlusIcon
96
96
  font-size: 26px;
97
97
  margin-right: 10px;
98
- line-height: 32px;
98
+ line-height: 26px;
99
99
 
100
100
  .btnText
101
101
  position: relative;
102
- top: -4px;
102
+ top: -2px;