@bytebrand/fe-ui-core 4.1.91 → 4.1.93
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 +1 -1
- package/source/components/VehicleSmallCard/VehicleData/VechiclePriceItem/VechiclePriceItem.tsx +2 -2
- package/source/components/VehicleSmallCard/VehicleSmallCard.tsx +3 -0
- package/source/components/_common/IconSVG/IconSVGConfig.tsx +6 -1
- package/source/components/_common/IconSVG/SVG/common/DashboardQuestionMark.tsx +20 -0
- package/source/components/_common/IconSVG/SVG/slider/360New.tsx +20 -0
- package/source/components/_common/withStats/withStats.styl +2 -2
- package/source/components/_common/withStats/withStats.tsx +14 -1
package/package.json
CHANGED
package/source/components/VehicleSmallCard/VehicleData/VechiclePriceItem/VechiclePriceItem.tsx
CHANGED
|
@@ -67,7 +67,7 @@ class VehiclePriceItem extends React.Component<IVehiclePriceItemProps> {
|
|
|
67
67
|
const stylesItem = classnames(
|
|
68
68
|
styles.priceItem,
|
|
69
69
|
{ [styles.priceItemFavorite]: vehicleComponentName === 'favorite' },
|
|
70
|
-
{ [styles.priceItemComparable]: vehicleComponentName === 'comparable'},
|
|
70
|
+
{ [styles.priceItemComparable]: vehicleComponentName === 'comparable' },
|
|
71
71
|
{ [styles.priceItemDisable]: isPriceDisable },
|
|
72
72
|
{ [styles.priceItemBuy]: isTotal }
|
|
73
73
|
);
|
|
@@ -76,7 +76,7 @@ class VehiclePriceItem extends React.Component<IVehiclePriceItemProps> {
|
|
|
76
76
|
styles.priceItemCategory,
|
|
77
77
|
{ [styles.priceItemCategorySearch]: vehicleComponentName === 'search' || vehicleComponentName === 'myVehicles' },
|
|
78
78
|
{ [styles.priceItemCategoryFavorite]: vehicleComponentName === 'favorite' },
|
|
79
|
-
{ [styles.priceItemCategoryComparable]: vehicleComponentName === 'comparable'}
|
|
79
|
+
{ [styles.priceItemCategoryComparable]: vehicleComponentName === 'comparable' }
|
|
80
80
|
);
|
|
81
81
|
return (
|
|
82
82
|
<div className={stylesItem}>
|
|
@@ -69,6 +69,7 @@ interface IVehicleSmallCardProps {
|
|
|
69
69
|
children?: ReactNode;
|
|
70
70
|
showSlider?: boolean;
|
|
71
71
|
showOfferBtn?: boolean;
|
|
72
|
+
hasInteriorExteriorPhoto?: boolean;
|
|
72
73
|
showFavoriteStar?: boolean;
|
|
73
74
|
minimizeData?: boolean;
|
|
74
75
|
onContainerClick?: (event?: any) => void;
|
|
@@ -130,6 +131,7 @@ const VehicleSmallCard: FunctionComponent<IVehicleSmallCardProps> = (props) => {
|
|
|
130
131
|
iconName,
|
|
131
132
|
showSlider,
|
|
132
133
|
percentage,
|
|
134
|
+
hasInteriorExteriorPhoto,
|
|
133
135
|
showOfferBtn = false,
|
|
134
136
|
showFavoriteStar = true,
|
|
135
137
|
minimizeData = false,
|
|
@@ -163,6 +165,7 @@ const VehicleSmallCard: FunctionComponent<IVehicleSmallCardProps> = (props) => {
|
|
|
163
165
|
const decoratedSliderProps = {
|
|
164
166
|
t,
|
|
165
167
|
id,
|
|
168
|
+
hasInteriorExteriorPhoto,
|
|
166
169
|
...label,
|
|
167
170
|
...stats,
|
|
168
171
|
...slider,
|
|
@@ -228,6 +228,7 @@ import DiscountRibbonNew from './SVG/slider/DiscountRibbonNew';
|
|
|
228
228
|
import FullscreenWindow from './SVG/slider/FullscreenWindow';
|
|
229
229
|
import FullScreen from './SVG/slider/Fullscreen';
|
|
230
230
|
import Rotate360 from './SVG/slider/360';
|
|
231
|
+
import Rotate360New from './SVG/slider/360New';
|
|
231
232
|
import ToBuy from './SVG/slider/ToBuy';
|
|
232
233
|
import Checked from './SVG/slider/Checked';
|
|
233
234
|
import Easy from './SVG/slider/Easy';
|
|
@@ -302,6 +303,8 @@ import RegistrationDashboard from './SVG/common/RegistrationDashboard';
|
|
|
302
303
|
import DeliveryDashboard from './SVG/common/DeliveryDashboard';
|
|
303
304
|
import HandingOverDashboard from './SVG/common/HandingOverDashboard';
|
|
304
305
|
import PickupDashboard from './SVG/common/PickupDashboard';
|
|
306
|
+
import DashboardQuestionMark from './SVG/common/DashboardQuestionMark';
|
|
307
|
+
|
|
305
308
|
interface IComponentsProp {
|
|
306
309
|
[key: string]: (props: any) => React.ReactNode;
|
|
307
310
|
}
|
|
@@ -505,6 +508,7 @@ const components: IComponentsProp = {
|
|
|
505
508
|
discountRibbonMobile: DiscountRibbonMobile,
|
|
506
509
|
discountRibbonNew: DiscountRibbonNew,
|
|
507
510
|
rotate360: Rotate360,
|
|
511
|
+
rotate360New: Rotate360New,
|
|
508
512
|
fullScreen: FullScreen,
|
|
509
513
|
fullscreenWindow: FullscreenWindow,
|
|
510
514
|
toBuy: ToBuy,
|
|
@@ -695,7 +699,8 @@ const components: IComponentsProp = {
|
|
|
695
699
|
registrationDashboard: RegistrationDashboard,
|
|
696
700
|
deliveryDashboard: DeliveryDashboard,
|
|
697
701
|
handingOverDashboard: HandingOverDashboard,
|
|
698
|
-
pickupDashboard: PickupDashboard
|
|
702
|
+
pickupDashboard: PickupDashboard,
|
|
703
|
+
dashboardQuestionMark:DashboardQuestionMark
|
|
699
704
|
};
|
|
700
705
|
|
|
701
706
|
export default components;
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
/* tslint:disable */
|
|
2
|
+
import * as React from 'react';
|
|
3
|
+
|
|
4
|
+
const DashboardQuestionMark = (
|
|
5
|
+
props: any
|
|
6
|
+
) => (
|
|
7
|
+
<svg
|
|
8
|
+
width="28"
|
|
9
|
+
height="27"
|
|
10
|
+
viewBox="0 0 28 27"
|
|
11
|
+
fill="none"
|
|
12
|
+
xmlns="http://www.w3.org/2000/svg"
|
|
13
|
+
{ ...props }
|
|
14
|
+
>
|
|
15
|
+
<path d="M12.3513 21.6065H15.018V18.9399H12.3513V21.6065ZM13.6847 0.273193C6.32468 0.273193 0.351349 6.24653 0.351349 13.6065C0.351349 20.9665 6.32468 26.9399 13.6847 26.9399C21.0447 26.9399 27.018 20.9665 27.018 13.6065C27.018 6.24653 21.0447 0.273193 13.6847 0.273193ZM13.6847 24.2732C7.80468 24.2732 3.01802 19.4865 3.01802 13.6065C3.01802 7.72653 7.80468 2.93986 13.6847 2.93986C19.5647 2.93986 24.3513 7.72653 24.3513 13.6065C24.3513 19.4865 19.5647 24.2732 13.6847 24.2732ZM13.6847 5.60653C10.738 5.60653 8.35135 7.99319 8.35135 10.9399H11.018C11.018 9.47319 12.218 8.27319 13.6847 8.27319C15.1513 8.27319 16.3513 9.47319 16.3513 10.9399C16.3513 13.6065 12.3513 13.2732 12.3513 17.6065H15.018C15.018 14.6065 19.018 14.2732 19.018 10.9399C19.018 7.99319 16.6313 5.60653 13.6847 5.60653Z" fill="#005CCB"/>
|
|
16
|
+
</svg>
|
|
17
|
+
);
|
|
18
|
+
|
|
19
|
+
export default DashboardQuestionMark;
|
|
20
|
+
/* tslint:enable */
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
/* tslint:disable */
|
|
2
|
+
import * as React from 'react';
|
|
3
|
+
|
|
4
|
+
const Svg360New = (props: any) => (
|
|
5
|
+
<svg
|
|
6
|
+
viewBox="0 0 24 24"
|
|
7
|
+
width="1em"
|
|
8
|
+
height="1em"
|
|
9
|
+
{...props}
|
|
10
|
+
>
|
|
11
|
+
<path fillRule="evenodd" clipRule="evenodd" d="M19.2731 12.0024C19.2854 11.774 19.2917 11.5352 19.2917 11.2855C19.2917 11.1381 19.2896 10.9914 19.2854 10.8455C20.9575 11.7695 21.9814 13.0117 21.9814 14.3777C21.9814 16.8116 18.7309 18.8525 14.3546 19.4004V18.3921C16.0124 18.1721 17.47 17.7275 18.5982 17.1434C20.2857 16.2698 20.9814 15.24 20.9814 14.3777C20.9814 13.6409 20.4735 12.7818 19.2731 12.0024ZM8.73484 18.2452V16.9993C8.73484 16.8454 8.90151 16.7491 9.03484 16.8261L12.3089 18.7164C12.4422 18.7934 12.4422 18.9858 12.3089 19.0628L9.03484 20.9531C8.90151 21.03 8.73484 20.9338 8.73484 20.7799V19.2622C4.82573 18.562 2.01855 16.6395 2.01855 14.3777C2.01855 13.0115 3.04264 11.7692 4.71506 10.8452C4.71086 10.9912 4.70874 11.138 4.70874 11.2855C4.70874 11.5353 4.71462 11.7743 4.72619 12.0028C3.52623 12.7822 3.01855 13.641 3.01855 14.3777C3.01855 15.24 3.71425 16.2698 5.40178 17.1434C6.31839 17.618 7.45254 18.0005 8.73484 18.2452Z" fill="#636578"/>
|
|
12
|
+
<path fillRule="evenodd" clipRule="evenodd" d="M12.5852 4.01221H11.371H8.76601C8.17317 4.01221 7.93534 4.05632 7.82485 4.10914L7.82398 4.10955C7.78226 4.12949 7.739 4.15017 7.66339 4.36463L6.90141 7.76114L6.89787 7.77689L6.89333 7.79238C6.36163 9.60562 6.44052 12.1325 6.61804 13.7916C6.65081 14.0978 6.91756 14.3404 7.25825 14.3404H7.51156C7.75013 14.3404 7.94353 14.147 7.94353 13.9084C7.94353 13.5663 8.22089 13.289 8.56302 13.289L11.3769 13.289L12.6228 13.289C12.6231 13.289 12.6234 13.289 12.6238 13.289H13.9287H15.3304C15.6726 13.289 15.9499 13.5663 15.9499 13.9084C15.9499 14.147 16.1433 14.3404 16.3819 14.3404H16.6927C17.0621 14.3404 17.3517 14.0778 17.3866 13.7448C17.5607 12.0842 17.633 9.5881 17.1064 7.79238L17.1018 7.77689L17.0983 7.76114L16.3363 4.36463C16.2607 4.15017 16.2175 4.12949 16.1757 4.10955L16.1749 4.10914C16.0644 4.05632 15.8265 4.01221 15.2337 4.01221H12.5852ZM12.6228 14.289L13.9287 14.289H15.001C15.1677 14.8951 15.7228 15.3404 16.3819 15.3404H16.6927C17.539 15.3404 18.2893 14.7252 18.3812 13.8491C18.5576 12.1668 18.6497 9.51711 18.0706 7.52675L17.3059 4.11822L17.3 4.09191L17.2913 4.06638C17.1801 3.7402 17.0155 3.40262 16.6062 3.20696C16.2639 3.04331 15.8059 3.01221 15.2337 3.01221H12.5852H11.371H8.76601C8.19381 3.01221 7.73577 3.04331 7.3935 3.20696C6.98426 3.40262 6.81959 3.7402 6.70842 4.06638L6.69972 4.09191L6.69381 4.11822L5.92913 7.52675C5.3446 9.5359 5.44389 12.2173 5.62372 13.898C5.71431 14.7446 6.43952 15.3404 7.25825 15.3404H7.51156C8.17066 15.3404 8.72577 14.8951 8.89243 14.289H11.3759C11.3763 14.289 11.3766 14.289 11.3769 14.289L12.6228 14.289Z" fill="#636578"/>
|
|
13
|
+
<path d="M17.5619 7.56836V7.56836C13.9305 8.65377 10.0509 8.65178 6.41895 7.56836V7.56836" stroke="#636578" stroke-linecap="round"/>
|
|
14
|
+
<circle cx="8.15374" cy="10.3359" r="0.768972" fill="#636578"/>
|
|
15
|
+
<circle cx="15.8442" cy="10.4555" r="0.768972" fill="#636578"/>
|
|
16
|
+
</svg>
|
|
17
|
+
);
|
|
18
|
+
|
|
19
|
+
export default Svg360New;
|
|
20
|
+
/* tslint:enable */
|
|
@@ -19,7 +19,8 @@ $indent = 10px
|
|
|
19
19
|
justify-content: flex-start
|
|
20
20
|
font-size: $font-size-default
|
|
21
21
|
padding: 0 $indent
|
|
22
|
-
box-sizing: border-box
|
|
22
|
+
box-sizing: border-box;
|
|
23
|
+
gap: 0.6em;
|
|
23
24
|
user-select: none;
|
|
24
25
|
|
|
25
26
|
&::after
|
|
@@ -38,7 +39,6 @@ $indent = 10px
|
|
|
38
39
|
align-items: center
|
|
39
40
|
justify-content: space-around;
|
|
40
41
|
height: inherit;
|
|
41
|
-
gap: 0.6em;
|
|
42
42
|
|
|
43
43
|
&:last-of-type
|
|
44
44
|
margin-left: auto
|
|
@@ -82,6 +82,19 @@ export default function withStats(WrappedComponent: any) {
|
|
|
82
82
|
);
|
|
83
83
|
};
|
|
84
84
|
|
|
85
|
+
renderRotateSvg = (): JSX.Element => {
|
|
86
|
+
const { hasInteriorExteriorPhoto, images } = this.props;
|
|
87
|
+
const hasExteriorPhotos = hasInteriorExteriorPhoto && Array.isArray(images) && images.length > 0;
|
|
88
|
+
if (!hasExteriorPhotos) return null;
|
|
89
|
+
return (
|
|
90
|
+
<div className={styles.section}>
|
|
91
|
+
{hasExteriorPhotos ? (
|
|
92
|
+
<IconSVG name='rotate360New' customDimensions className={styles.statsEyeIcon} />
|
|
93
|
+
) : null}
|
|
94
|
+
</div>
|
|
95
|
+
);
|
|
96
|
+
};
|
|
97
|
+
|
|
85
98
|
renderStarButton = () => {
|
|
86
99
|
const { isFavoured, onFavoriteClick } = this.props;
|
|
87
100
|
if (!onFavoriteClick) return null;
|
|
@@ -100,7 +113,6 @@ export default function withStats(WrappedComponent: any) {
|
|
|
100
113
|
const { statsData, isFavoured, onFavoriteClick } = this.props;
|
|
101
114
|
if (!statsData) return null;
|
|
102
115
|
const { totalCarImpCount, totalFavCount } = statsData;
|
|
103
|
-
|
|
104
116
|
const favoritesClassName = classnames(
|
|
105
117
|
styles.statsFavoritesCount,
|
|
106
118
|
{
|
|
@@ -162,6 +174,7 @@ export default function withStats(WrappedComponent: any) {
|
|
|
162
174
|
<WrappedComponent {...wrappedComponentProps} onSlideChange={this.onSlideChange} isReferenceSearch={isReferenceSearch} />
|
|
163
175
|
<div className={classnames(styles.controls, styles[statsSize])}>
|
|
164
176
|
{this.renderImagesData()}
|
|
177
|
+
{this.renderRotateSvg()}
|
|
165
178
|
{this.renderStarButton()}
|
|
166
179
|
{this.renderStatsData()}
|
|
167
180
|
</div>
|