@woosmap/ui 4.164.2 → 4.164.4
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
|
@@ -5,7 +5,7 @@ import distanceImgSq from '../../images/products/product-distance-sq.png';
|
|
|
5
5
|
import mapImgSq from '../../images/products/product-map-sq.png';
|
|
6
6
|
import indoorImgSq from '../../images/products/product-indoor-sq.png';
|
|
7
7
|
// import geofencingImgSq from '../../images/products/product-geofencing-sq.png';
|
|
8
|
-
import transitImgSq from '../../images/products/product-transit-sq.png';
|
|
8
|
+
// import transitImgSq from '../../images/products/product-transit-sq.png';
|
|
9
9
|
|
|
10
10
|
/* eslint-disable */
|
|
11
11
|
|
|
@@ -20,7 +20,7 @@ const Pricing = {
|
|
|
20
20
|
publicTierCount: 2,
|
|
21
21
|
unit: "Monthly Requests",
|
|
22
22
|
description:
|
|
23
|
-
"Search for your points of interest by location, proxilmity to a route, by their characteristics with autocomplete capabilities
|
|
23
|
+
"Search for your points of interest by location, proxilmity to a route, by their characteristics with autocomplete capabilities",
|
|
24
24
|
pricing: [
|
|
25
25
|
[100000, 0.52],
|
|
26
26
|
[500000, 0.41],
|
|
@@ -54,7 +54,7 @@ const Pricing = {
|
|
|
54
54
|
publicTierCount: 2,
|
|
55
55
|
unit: "Monthly Requests",
|
|
56
56
|
description:
|
|
57
|
-
"
|
|
57
|
+
"Handle and maintain location data, ensuring accuracy and reliability",
|
|
58
58
|
pricing: [
|
|
59
59
|
[100000, 10.32],
|
|
60
60
|
[500000, 8.24],
|
|
@@ -119,7 +119,7 @@ const Pricing = {
|
|
|
119
119
|
},
|
|
120
120
|
'Details UK Addresses': {
|
|
121
121
|
defaultQueries: 0,
|
|
122
|
-
publicTierCount:
|
|
122
|
+
publicTierCount: 4, unit: "Monthly Requests",
|
|
123
123
|
description:
|
|
124
124
|
"Get details on Autocomplete suggestions on UK addresses benefiting from best available data on the market",
|
|
125
125
|
pricing: [
|
|
@@ -154,7 +154,7 @@ const Pricing = {
|
|
|
154
154
|
},
|
|
155
155
|
'Geocode/Reverse Geocode UK addresses': {
|
|
156
156
|
defaultQueries: 0,
|
|
157
|
-
publicTierCount:
|
|
157
|
+
publicTierCount: 4, unit: "Monthly Requests",
|
|
158
158
|
description:
|
|
159
159
|
"Geocoding/Reverse geocoding on localities, postcodes and UK addresses benefiting from best available data on the market",
|
|
160
160
|
pricing: [
|
|
@@ -200,11 +200,11 @@ const Pricing = {
|
|
|
200
200
|
},
|
|
201
201
|
},
|
|
202
202
|
},
|
|
203
|
-
'Map
|
|
203
|
+
'Map': {
|
|
204
204
|
image : mapImgSq,
|
|
205
205
|
description : "Display your data without compromising readability",
|
|
206
206
|
pricings: {
|
|
207
|
-
'
|
|
207
|
+
'Mapload': {
|
|
208
208
|
defaultQueries: 0,
|
|
209
209
|
publicTierCount: 2,
|
|
210
210
|
unit: "Monthly Requests",
|
|
@@ -346,6 +346,23 @@ const Pricing = {
|
|
|
346
346
|
],
|
|
347
347
|
discountEligible: false,
|
|
348
348
|
},
|
|
349
|
+
'Transit': {
|
|
350
|
+
defaultQueries: 0,
|
|
351
|
+
publicTierCount: 2,
|
|
352
|
+
unit: "Monthly Requests",
|
|
353
|
+
description:
|
|
354
|
+
"Get distance, duration, path and public transport details between an origin and a destination, based on public transportation",
|
|
355
|
+
pricing: [
|
|
356
|
+
[100000, 3.68],
|
|
357
|
+
[500000, 2.94],
|
|
358
|
+
[1000000, 2.76],
|
|
359
|
+
[5000000, 1.38],
|
|
360
|
+
[10000000, 0.35],
|
|
361
|
+
[20000000, 0.11],
|
|
362
|
+
[50000000, 0.04],
|
|
363
|
+
],
|
|
364
|
+
discountEligible: false,
|
|
365
|
+
},
|
|
349
366
|
},
|
|
350
367
|
},
|
|
351
368
|
Geolocation: {
|
|
@@ -405,29 +422,6 @@ const Pricing = {
|
|
|
405
422
|
},
|
|
406
423
|
},
|
|
407
424
|
},
|
|
408
|
-
'Transit': {
|
|
409
|
-
image : transitImgSq,
|
|
410
|
-
description : "Get time and path for travels using public transportation",
|
|
411
|
-
pricings: {
|
|
412
|
-
'Map': {
|
|
413
|
-
defaultQueries: 0,
|
|
414
|
-
publicTierCount: 2,
|
|
415
|
-
unit: "Monthly Requests",
|
|
416
|
-
description:
|
|
417
|
-
"Get distance, duration, path and public transport details between an origin and a destination, based on public transportation",
|
|
418
|
-
pricing: [
|
|
419
|
-
[100000, 2.58],
|
|
420
|
-
[500000, 2.06],
|
|
421
|
-
[1000000, 1.93],
|
|
422
|
-
[5000000, 0.97],
|
|
423
|
-
[10000000, 0.24],
|
|
424
|
-
[20000000, 0.07],
|
|
425
|
-
[50000000, 0.03],
|
|
426
|
-
],
|
|
427
|
-
discountEligible: false,
|
|
428
|
-
},
|
|
429
|
-
},
|
|
430
|
-
},
|
|
431
425
|
Indoor: {
|
|
432
426
|
image : indoorImgSq,
|
|
433
427
|
description : "Map private venues and propose indoor search and wayfinding",
|
|
@@ -65,7 +65,7 @@ class PricingSimulator extends Component {
|
|
|
65
65
|
const { sliders } = this.state;
|
|
66
66
|
const { publicMode, currency } = this.props;
|
|
67
67
|
const { total, discount, contactSale } = this.computeTotal();
|
|
68
|
-
let totalDisplayed = total
|
|
68
|
+
let totalDisplayed = `${parseInt(total, 10)}${currency}`;
|
|
69
69
|
if (contactSale) {
|
|
70
70
|
totalDisplayed = <a href="/en/contact">Contact Sales</a>;
|
|
71
71
|
}
|
|
@@ -112,6 +112,7 @@ class PricingSimulator extends Component {
|
|
|
112
112
|
const productPricing = PricingData[category].pricings[pricingKey];
|
|
113
113
|
return (
|
|
114
114
|
<PricingSlider
|
|
115
|
+
id={this.getAnchor(`${category}_${pricingKey}`)}
|
|
115
116
|
productPricing={productPricing}
|
|
116
117
|
name={pricingKey}
|
|
117
118
|
key={`pricing_${pricingKey.replace(' ', '')}`}
|
|
@@ -20,12 +20,12 @@ class PricingSlider extends Component {
|
|
|
20
20
|
const valueToRemove = Math.min(tier[0] - previousPricingTier[0], q);
|
|
21
21
|
if (valueToRemove > 0) {
|
|
22
22
|
q -= valueToRemove;
|
|
23
|
-
return amount + (valueToRemove /
|
|
23
|
+
return amount + (valueToRemove / 100000) * tier[1] * coef;
|
|
24
24
|
}
|
|
25
25
|
} else {
|
|
26
26
|
const valueToRemove = Math.min(tier[0], q);
|
|
27
27
|
q -= valueToRemove;
|
|
28
|
-
return amount + (valueToRemove /
|
|
28
|
+
return amount + (valueToRemove / 100000) * tier[1] * coef;
|
|
29
29
|
}
|
|
30
30
|
return amount;
|
|
31
31
|
}, 0)
|
|
@@ -35,13 +35,13 @@ class PricingSlider extends Component {
|
|
|
35
35
|
computeQueries = (valueNow) => {
|
|
36
36
|
const { productPricing, publicMode } = this.props;
|
|
37
37
|
const { pricing, publicTierCount } = productPricing;
|
|
38
|
-
const tierIndex = Math.min(Math.floor(valueNow /
|
|
38
|
+
const tierIndex = Math.min(Math.floor(valueNow / 100000), pricing.length - 1);
|
|
39
39
|
// eslint-disable-next-line prefer-destructuring
|
|
40
40
|
const tier = pricing[tierIndex][0];
|
|
41
|
-
const value = valueNow - tierIndex *
|
|
41
|
+
const value = valueNow - tierIndex * 100000;
|
|
42
42
|
|
|
43
43
|
const previousTier = pricing[tierIndex - 1] ? pricing[tierIndex - 1][0] : 0;
|
|
44
|
-
const newValue = ((tier - previousTier) * value) /
|
|
44
|
+
const newValue = ((tier - previousTier) * value) / 100000 + previousTier;
|
|
45
45
|
if (newValue > pricing[publicMode ? publicTierCount - 1 : pricing.length - 1][0]) {
|
|
46
46
|
return '∞';
|
|
47
47
|
}
|
|
@@ -58,7 +58,7 @@ class PricingSlider extends Component {
|
|
|
58
58
|
const tier = pricing[matchedTierIndex];
|
|
59
59
|
if (tier) {
|
|
60
60
|
const previousTier = matchedTierIndex > 0 ? pricing[matchedTierIndex - 1][0] : 0;
|
|
61
|
-
const queries = matchedTierIndex *
|
|
61
|
+
const queries = matchedTierIndex * 100000 + (100000 * (value - previousTier)) / tier[0];
|
|
62
62
|
this.onChange(queries);
|
|
63
63
|
}
|
|
64
64
|
};
|
|
@@ -80,11 +80,11 @@ class PricingSlider extends Component {
|
|
|
80
80
|
if (props.key === 0) {
|
|
81
81
|
value = 0;
|
|
82
82
|
} else {
|
|
83
|
-
const index = props.key /
|
|
83
|
+
const index = props.key / 100000 - 1;
|
|
84
84
|
if (index === displayedPricing.length - 1 && publicMode) {
|
|
85
85
|
value = '∞';
|
|
86
86
|
} else {
|
|
87
|
-
const tier = displayedPricing[props.key /
|
|
87
|
+
const tier = displayedPricing[props.key / 100000 - 1];
|
|
88
88
|
value = numeral(tier[0]).format('0.[0]a');
|
|
89
89
|
}
|
|
90
90
|
}
|
|
@@ -96,7 +96,7 @@ class PricingSlider extends Component {
|
|
|
96
96
|
);
|
|
97
97
|
};
|
|
98
98
|
|
|
99
|
-
getMarks = (displayedPricing) => [-1, ...displayedPricing.keys()].map((key) => (key + 1) *
|
|
99
|
+
getMarks = (displayedPricing) => [-1, ...displayedPricing.keys()].map((key) => (key + 1) * 100000);
|
|
100
100
|
|
|
101
101
|
getDisplayedPricing = () => {
|
|
102
102
|
const { productPricing, publicMode } = this.props;
|
|
@@ -132,7 +132,7 @@ class PricingSlider extends Component {
|
|
|
132
132
|
};
|
|
133
133
|
|
|
134
134
|
render() {
|
|
135
|
-
const { name, productPricing, currency, values } = this.props;
|
|
135
|
+
const { name, productPricing, currency, values, id } = this.props;
|
|
136
136
|
const { queries } = values;
|
|
137
137
|
const { displayedPricing, amount, formatedQueries, marks, computedQueries } = this.getDisplayedData(queries);
|
|
138
138
|
let displayedAmount = <span className="amount">{`0${currency}`}</span>;
|
|
@@ -144,7 +144,7 @@ class PricingSlider extends Component {
|
|
|
144
144
|
displayedAmount = <span className="free-label">FREE</span>;
|
|
145
145
|
}
|
|
146
146
|
return (
|
|
147
|
-
<div className="pricing-slider__wrapper" id={
|
|
147
|
+
<div className="pricing-slider__wrapper" id={id}>
|
|
148
148
|
<div className="pricing-slider__info">
|
|
149
149
|
<h3>{name}</h3>
|
|
150
150
|
<p>{productPricing.description}</p>
|
|
@@ -170,7 +170,7 @@ class PricingSlider extends Component {
|
|
|
170
170
|
onChange={(_queries) => {
|
|
171
171
|
this.onChange(_queries);
|
|
172
172
|
}}
|
|
173
|
-
max={displayedPricing.length *
|
|
173
|
+
max={displayedPricing.length * 100000}
|
|
174
174
|
/>
|
|
175
175
|
<div className="pricing-slider__queries">
|
|
176
176
|
<div className="pricing-slider__queries__label">{productPricing.unit}</div>
|
|
@@ -192,6 +192,7 @@ PricingSlider.propTypes = {
|
|
|
192
192
|
defaultQueries: PropTypes.number,
|
|
193
193
|
onChange: PropTypes.func,
|
|
194
194
|
values: PropTypes.object.isRequired,
|
|
195
|
+
id: PropTypes.string.isRequired,
|
|
195
196
|
};
|
|
196
197
|
|
|
197
198
|
export default PricingSlider;
|