@wayke-se/components-react 2.16.0 → 3.0.0-beta.10
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/README.md +33 -2
- package/dist-node/index.js +3254 -1142
- package/dist-node/index.js.map +1 -1
- package/dist-src/State/CentralStorage/useCentralStorage.js +7 -8
- package/dist-src/State/Path/PathProvider.js +1 -1
- package/dist-src/State/RelatedSearch/RelatedSearchProvider.js +1 -1
- package/dist-src/State/Search/SearchProvider.js +7 -10
- package/dist-src/components/ActionList/index.js +2 -3
- package/dist-src/components/Checklist/index.js +1 -1
- package/dist-src/components/ExtendContent/index.js +1 -1
- package/dist-src/components/Filter/index.js +10 -7
- package/dist-src/components/FilterPanel/checkListFacet.js +1 -1
- package/dist-src/components/FilterPanel/colorFacet.js +1 -1
- package/dist-src/components/FilterPanel/index.js +1 -1
- package/dist-src/components/FilterPanel/rangeFacet.js +14 -16
- package/dist-src/components/FinancialOptions/LoanModal.js +27 -29
- package/dist-src/components/FinancialOptions/leasing.js +6 -6
- package/dist-src/components/FinancialOptions/loan.js +5 -6
- package/dist-src/components/Gallery/index.js +11 -16
- package/dist-src/components/Grid/index.js +2 -3
- package/dist-src/components/InputSelect/index.js +1 -1
- package/dist-src/components/InsuranceOptions/InsuranceFree.js +1 -2
- package/dist-src/components/InsuranceOptions/InsuranceFreeModal.js +4 -5
- package/dist-src/components/InsuranceOptions/InsuranceModal.js +3 -3
- package/dist-src/components/Lightbox/index.js +1 -1
- package/dist-src/components/OpeningHours/index.js +9 -9
- package/dist-src/components/RangeSlider/SliderWithLabel.js +1 -1
- package/dist-src/components/Result/index.js +7 -6
- package/dist-src/components/Video/EmbededVideo.js +1 -1
- package/dist-src/components/Video/QuickNavEmbeded.js +2 -2
- package/dist-src/components/Video/useThumbnail.js +1 -1
- package/dist-src/components/Video/utils.js +2 -2
- package/dist-src/hooks/useFetch.js +1 -1
- package/dist-src/hooks/useVimeoThumbnail.js +1 -1
- package/dist-src/layouts/searchItem/Branch.js +9 -10
- package/dist-src/layouts/searchItem/BranchModal.js +1 -1
- package/dist-src/layouts/searchItem/CheckList.js +16 -16
- package/dist-src/layouts/searchItem/ManufacturerPackagesOption.js +1 -2
- package/dist-src/layouts/searchItem/PackageOptionModal.js +7 -10
- package/dist-src/layouts/searchItem/PackageOptions.js +11 -14
- package/dist-src/layouts/searchItem/Property.js +4 -6
- package/dist-src/layouts/searchItem/Related.js +3 -4
- package/dist-src/layouts/searchItem/index.js +42 -21
- package/dist-src/providers/WaykeItemProvidet.js +7 -11
- package/dist-src/providers/WaykeProvider.js +8 -12
- package/dist-src/utils/phonenumbers.js +1 -1
- package/dist-src/utils/specification.js +9 -13
- package/dist-src/utils/vehicle-properties/property-tree-creator.js +5 -5
- package/dist-types/State/CentralStorage/useCentralStorage.d.ts +1 -1
- package/dist-types/State/Settings/SettingsContext.d.ts +1 -0
- package/dist-types/components/InputSearch/index.d.ts +5 -3
- package/dist-types/components/RangeSlider/handle.d.ts +2 -2
- package/dist-types/components/RangeSlider/track.d.ts +2 -2
- package/dist-types/components/Video/useThumbnail.d.ts +1 -1
- package/dist-types/components/Video/utils.d.ts +2 -2
- package/dist-types/hooks/useFetch.d.ts +1 -1
- package/dist-types/hooks/useInsurance.d.ts +1 -1
- package/dist-types/hooks/useLoan.d.ts +1 -1
- package/dist-types/hooks/useSearchItem.d.ts +1 -1
- package/dist-types/hooks/useSearchItemBranch.d.ts +1 -1
- package/dist-types/hooks/useVimeoThumbnail.d.ts +1 -1
- package/dist-types/utils/regex.d.ts +1 -1
- package/dist-types/utils/ssn.d.ts +1 -1
- package/dist-web/index.js +250 -323
- package/dist-web/index.js.map +1 -1
- package/package.json +18 -26
- package/dist-src/components/Ecom/index.js +0 -48
- package/dist-src/hooks/useEcom.js +0 -18
- package/dist-types/components/Ecom/index.d.ts +0 -10
- package/dist-types/hooks/useEcom.d.ts +0 -3
package/README.md
CHANGED
|
@@ -21,7 +21,9 @@ npm install react react-dom styled-components
|
|
|
21
21
|
```javascript
|
|
22
22
|
import React from 'react';
|
|
23
23
|
import WaykeComposite from '@wayke-se/components-react'
|
|
24
|
-
import '@wayke
|
|
24
|
+
import '@wayke-se/components-react/assets/default.css';
|
|
25
|
+
// Optional
|
|
26
|
+
import '@wayke-se/ecom-web/dist/index.css';
|
|
25
27
|
|
|
26
28
|
const ProviderSettings: WaykeProviderSettings = {
|
|
27
29
|
graphQlUrl: "https://gql.wayketech.se/query",
|
|
@@ -40,6 +42,31 @@ const App = () => (
|
|
|
40
42
|
);
|
|
41
43
|
```
|
|
42
44
|
|
|
45
|
+
### Environments for test
|
|
46
|
+
```javascript
|
|
47
|
+
const ProviderSettings: WaykeProviderSettings = {
|
|
48
|
+
graphQlUrl: "https://gql.wayketech.se/query",
|
|
49
|
+
url: "https://test-ext-api.wayketech.se/vehicles",
|
|
50
|
+
urlMlt: "https://test-ext-api.wayketech.se/vehicles-mlt-ext",
|
|
51
|
+
ecomSettings: {
|
|
52
|
+
url: "https://ecom.wayketech.se",
|
|
53
|
+
},
|
|
54
|
+
}
|
|
55
|
+
```
|
|
56
|
+
|
|
57
|
+
### Environments for production
|
|
58
|
+
```javascript
|
|
59
|
+
const ProviderSettings: WaykeProviderSettings = {
|
|
60
|
+
graphQlUrl: "https://gql.wayke.se/query",
|
|
61
|
+
url: "https://api.wayke.se/vehicles",
|
|
62
|
+
urlMlt: "https://api.wayke.se/vehicles-mlt-ext",
|
|
63
|
+
ecomSettings: {
|
|
64
|
+
url: "https://ecom.wayke.se",
|
|
65
|
+
},
|
|
66
|
+
}
|
|
67
|
+
```
|
|
68
|
+
|
|
69
|
+
|
|
43
70
|
### WaykeComposite uses hash-route, i want to use path-route
|
|
44
71
|
|
|
45
72
|
In this case you need to make sure that you are in control of the routing where same html file is
|
|
@@ -49,6 +76,8 @@ served for `/your/path/to/this/component` and `/your/path/to/this/component/0000
|
|
|
49
76
|
import React from 'react';
|
|
50
77
|
import { WaykeCompositePath } from '@wayke-se/components-react'
|
|
51
78
|
import '@wayke.se/components-react/assets/default.css';
|
|
79
|
+
// Optional
|
|
80
|
+
import '@wayke-se/ecom-web/dist/index.css';
|
|
52
81
|
|
|
53
82
|
const App = () => (
|
|
54
83
|
<WaykeCompositePath
|
|
@@ -90,6 +119,8 @@ It's recomended to place WaykeItemProvider close to app-root in order to keep th
|
|
|
90
119
|
import React, { useCallback } from 'react';
|
|
91
120
|
import { WaykeItemProvider, WaykeSearchItem } from '@wayke-se/components-react'
|
|
92
121
|
import '@wayke.se/components-react/assets/default.css';
|
|
122
|
+
// Optional
|
|
123
|
+
import '@wayke-se/ecom-web/dist/index.css';
|
|
93
124
|
|
|
94
125
|
const App = ({}) => {
|
|
95
126
|
const id = 'd01f79a3-7552-49c4-9d4d-deb3aa581c31';
|
|
@@ -431,7 +462,7 @@ To style the components, copy the following snippet into your *CSS* file and mod
|
|
|
431
462
|
```
|
|
432
463
|
|
|
433
464
|
### Ecom theme
|
|
434
|
-
The default ecom css can be found and imported `node_module/@wayke-se/ecom-
|
|
465
|
+
The default ecom css can be found and imported `node_module/@wayke-se/ecom-web/dist/index.css`.
|
|
435
466
|
|
|
436
467
|
> **It is highly recommended to *NOT* add or remove any properties defined above in the color selectors**. However, since fonts usually requires more configuration we encourage you to add the necessary font styling required to match your current profile. If you add new properties to the font selectors, please be careful and ensure everything looks as intended before going into production.
|
|
437
468
|
|