@woosmap/ui 4.220.10 → 4.220.13
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/.eslintrc +0 -10
- package/.storybook/main.js +0 -7
- package/package.json +3 -11
- package/src/components/Button/Button.js +2 -2
- package/src/components/Button/Button.stories.js +5 -5
- package/src/components/Button/Button.test.js +1 -1
- package/src/components/Button/ButtonSwitch.js +1 -1
- package/src/components/Button/ButtonWithDropdown.js +3 -3
- package/src/components/Button/ButtonWithDropdown.test.js +1 -1
- package/src/components/Card/Card.js +29 -29
- package/src/components/Card/Card.stories.js +6 -6
- package/src/components/Card/Card.test.js +1 -1
- package/src/components/Card/SimpleCard.js +2 -2
- package/src/components/Card/SimpleCard.styl +2 -2
- package/src/components/Card/SimpleCard.test.js +1 -1
- package/src/components/CodeSnippet/CodeSnippet.stories.js +1 -1
- package/src/components/CodeSnippet/CodeSnippet.test.js +1 -1
- package/src/components/CopyClipboardButton/CopyClipboardButton.js +3 -3
- package/src/components/CopyClipboardButton/CopyToClipboard.stories.js +1 -1
- package/src/components/CopyClipboardButton/CopyToClipboard.test.js +1 -1
- package/src/components/DateTime/DateTime.stories.js +1 -1
- package/src/components/DateTime/DateTime.test.js +1 -1
- package/src/components/Demo/AddressDemo.js +10 -10
- package/src/components/Demo/AddressDemo.stories.js +1 -1
- package/src/components/Demo/AutocompleteAddressDemo.js +10 -10
- package/src/components/Demo/AutocompleteAddressDemo.stories.js +2 -2
- package/src/components/Demo/DistanceDemo.js +12 -12
- package/src/components/Demo/DistanceDemo.stories.js +1 -1
- package/src/components/Demo/DistanceDemo.test.js +1 -1
- package/src/components/Demo/GeolocationDemo.js +7 -7
- package/src/components/Demo/GeolocationDemo.stories.js +1 -1
- package/src/components/Demo/GeolocationDemo.test.js +1 -1
- package/src/components/Demo/LocalitiesAddressDemo.js +8 -8
- package/src/components/Demo/LocalitiesAddressDemo.stories.js +1 -1
- package/src/components/Demo/LocalitiesAllDemo.js +5 -5
- package/src/components/Demo/LocalitiesAllDemo.stories.js +1 -1
- package/src/components/Demo/LocalitiesDemo.js +10 -10
- package/src/components/Demo/LocalitiesDemo.stories.js +1 -1
- package/src/components/Demo/LocalitiesFRAddressDemo.js +239 -261
- package/src/components/Demo/LocalitiesFRAddressDemo.stories.js +2 -2
- package/src/components/Demo/LocalitiesUKAddressDemo.js +271 -294
- package/src/components/Demo/LocalitiesUKAddressDemo.stories.js +1 -1
- package/src/components/Demo/MapDemo.js +231 -233
- package/src/components/Demo/MapDemo.stories.js +1 -1
- package/src/components/Demo/SearchDemo.js +9 -9
- package/src/components/Demo/SearchDemo.stories.js +1 -1
- package/src/components/Demo/SearchDemo.test.js +1 -1
- package/src/components/Demo/Showcase.stories.js +7 -7
- package/src/components/Demo/SkeletonDemo.js +8 -8
- package/src/components/Demo/SkeletonDemo.stories.js +2 -2
- package/src/components/Demo/SkeletonDemo.test.js +2 -2
- package/src/components/Demo/W3WDemo.js +9 -9
- package/src/components/Demo/W3WDemo.stories.js +2 -2
- package/src/components/Dropdown/Dropdown.js +4 -4
- package/src/components/Dropdown/Dropdown.stories.js +1 -1
- package/src/components/Dropdown/Dropdown.test.js +1 -1
- package/src/components/DynamicTag/DynamicTag.js +5 -5
- package/src/components/DynamicTag/DynamicTag.stories.js +1 -1
- package/src/components/DynamicTag/DynamicTag.test.js +1 -1
- package/src/components/Flash/Flash.js +1 -1
- package/src/components/Flash/Flash.stories.js +1 -1
- package/src/components/Flash/Flash.test.js +1 -1
- package/src/components/Icon/Icon.js +409 -409
- package/src/components/Icon/Icon.stories.js +1 -1
- package/src/components/Icon/Icon.test.js +1 -1
- package/src/components/Icon/WebSiteIcon.js +231 -231
- package/src/components/InfoMessage/Flash.js +1 -1
- package/src/components/InfoMessage/InfoMessage.js +2 -2
- package/src/components/InfoMessage/InfoMessage.stories.js +1 -1
- package/src/components/InfoMessage/InfoMessage.test.js +1 -1
- package/src/components/Input/Input.js +2 -2
- package/src/components/Input/Input.password.test.js +1 -1
- package/src/components/Input/Input.stories.js +1 -1
- package/src/components/Input/Input.test.js +1 -1
- package/src/components/Label/Label.js +1 -1
- package/src/components/Label/Label.stories.js +1 -1
- package/src/components/Label/Label.test.js +1 -1
- package/src/components/Map/InfoWindow.test.js +1 -1
- package/src/components/Map/Map.stories.js +3 -3
- package/src/components/Map/Marker.test.js +1 -1
- package/src/components/Map/drawOnMap.test.js +2 -10
- package/src/components/Map/marker.styl +2 -2
- package/src/components/Modal/ConfirmationModal.js +2 -2
- package/src/components/Modal/ConfirmationModal.test.js +1 -1
- package/src/components/Modal/Modal.js +6 -6
- package/src/components/Modal/Modal.stories.js +3 -3
- package/src/components/Modal/Modal.test.js +1 -1
- package/src/components/OfflineChatBot/OfflineChatBot.js +4 -4
- package/src/components/OfflineChatBot/OfflineChatBot.stories.js +2 -2
- package/src/components/Panel/Panel.js +2 -2
- package/src/components/Panel/Panel.stories.js +2 -2
- package/src/components/Panel/Panel.test.js +1 -1
- package/src/components/PasswordStrengthBar/PasswordStrengthBar.stories.js +1 -1
- package/src/components/PasswordStrengthBar/PasswordStrengthBar.test.js +1 -1
- package/src/components/Popover/ConfirmationPopover.js +3 -3
- package/src/components/Popover/ConfirmationPopover.test.js +1 -1
- package/src/components/Popover/Popover.js +1 -1
- package/src/components/Popover/Popover.stories.js +3 -3
- package/src/components/Popover/Popover.test.js +2 -2
- package/src/components/PricingSlider/PricingData.js +94 -113
- package/src/components/PricingSlider/PricingSimulator.js +132 -90
- package/src/components/PricingSlider/PricingSimulator.stories.js +1 -1
- package/src/components/PricingSlider/PricingSlider.js +9 -10
- package/src/components/ProgressBar/ProgressBar.js +1 -1
- package/src/components/ProgressBar/ProgressBar.stories.js +1 -1
- package/src/components/ProgressBar/ProgressBar.test.js +1 -1
- package/src/components/ScrollBar/ScrollBar.stories.js +1 -1
- package/src/components/ScrollBar/ScrollBar.test.js +1 -1
- package/src/components/Select/Select.stories.js +4 -4
- package/src/components/Select/TagSelect.test.js +1 -1
- package/src/components/ServiceMessage/ServiceMessage.js +1 -1
- package/src/components/ServiceMessage/ServiceMessage.stories.js +2 -2
- package/src/components/SnackBar/SnackBar.js +2 -2
- package/src/components/SnackBar/SnackBar.stories.js +3 -3
- package/src/components/SnackBar/SnackBar.test.js +3 -3
- package/src/components/SnackBar/withSnackBar.js +1 -1
- package/src/components/Stepper/Stepper.js +2 -2
- package/src/components/Stepper/Stepper.stories.js +1 -1
- package/src/components/Switch/Switch.stories.js +1 -1
- package/src/components/Switch/Switch.test.js +1 -1
- package/src/components/Tab/Tab.js +1 -1
- package/src/components/Tab/Tab.stories.js +1 -1
- package/src/components/Tooltip/Tooltip.stories.js +1 -1
- package/src/components/Tooltip/Tooltip.test.js +1 -1
- package/src/components/UseCase/UseCase.js +9 -9
- package/src/components/UseCase/UseCase.stories.js +4 -4
- package/src/components/UseCase/UseCase.styl +8 -8
- package/src/components/Woosmap/AddressAutocomplete.js +3 -3
- package/src/components/Woosmap/LocalitiesAutocomplete.js +1 -1
- package/src/components/Woosmap/Woosmap.stories.js +3 -3
- package/src/components/utils/Script.test.js +1 -1
- package/src/components/utils/locale.js +2 -2
- package/src/components/withClickOutside/withClickOutside.test.js +1 -1
- package/src/components/withFormValidation/withFormValidation.js +2 -2
- package/src/components/withFormValidation/withFormValidation.stories.js +2 -2
- package/src/components/withFormValidation/withFormValidation.test.js +2 -2
- package/src/index.js +61 -61
- package/src/locales/en/translation.json +143 -128
- package/src/locales/fr/translation.json +143 -128
- package/src/styles/commons/flags.styl +1 -1
- package/src/styles/console/button.styl +3 -3
- package/src/styles/console/{pricing-slider.styl → pricing-slider-back.styl} +48 -21
- package/src/styles/style-console.styl +1 -2
- package/src/website.js +25 -25
- package/craco.config.js +0 -9
package/.eslintrc
CHANGED
package/.storybook/main.js
CHANGED
|
@@ -92,13 +92,6 @@ module.exports = {
|
|
|
92
92
|
},
|
|
93
93
|
);
|
|
94
94
|
|
|
95
|
-
// Ajout de l'alias '@' pour src
|
|
96
|
-
config.resolve = config.resolve || {};
|
|
97
|
-
config.resolve.alias = {
|
|
98
|
-
...(config.resolve.alias || {}),
|
|
99
|
-
'@': path.resolve(__dirname, '../src'),
|
|
100
|
-
};
|
|
101
|
-
|
|
102
95
|
return config;
|
|
103
96
|
},
|
|
104
97
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@woosmap/ui",
|
|
3
|
-
"version": "4.220.
|
|
3
|
+
"version": "4.220.13",
|
|
4
4
|
"repository": {
|
|
5
5
|
"type": "git",
|
|
6
6
|
"url": "git+https://github.com/WebGeoServices/ui.git"
|
|
@@ -35,12 +35,11 @@
|
|
|
35
35
|
},
|
|
36
36
|
"scripts": {
|
|
37
37
|
"start": "yarn stylus-dev && yarn storybook:dev",
|
|
38
|
-
"app": "yarn stylus-dev && craco start",
|
|
39
38
|
"stylus": "stylus ./src/styles/style-console.styl -o dist/styles/dev",
|
|
40
39
|
"stylus-dev": "stylus ./src/styles/style-console.styl -o dist/styles/dev && stylus ./src/styles/style-stories.styl -o dist/styles/dev",
|
|
41
|
-
"build": "rimraf dist && NODE_ENV=production babel src --out-dir dist --copy-files --no-copy-ignored --ignore '**/*.stories.js,**/*.test.js,**/*.styl' && yarn build-css
|
|
40
|
+
"build": "rimraf dist && NODE_ENV=production babel src --out-dir dist --copy-files --no-copy-ignored --ignore '**/*.stories.js,**/*.test.js,**/*.styl' && yarn build-css",
|
|
42
41
|
"build-css": "stylus ./src/styles/style-console.styl -o dist && stylus ./src/styles/style-stories.styl -o dist",
|
|
43
|
-
"test": "
|
|
42
|
+
"test": "react-scripts test",
|
|
44
43
|
"test:generate-output": "react-scripts test --json --outputFile=./.storybook/jest-test-results.json --silent",
|
|
45
44
|
"prestorybook:dev": "clear && echo \"DOING FIRST TEST RUN\" && CI=true npm run test:generate-output",
|
|
46
45
|
"storybook:dev": "clear && concurrently -k \"npm run storybook\" \"npm run test:generate-output\"",
|
|
@@ -56,11 +55,6 @@
|
|
|
56
55
|
"lint": "eslint src --ext .js,.jsx --fix",
|
|
57
56
|
"lint:check": "eslint src --ext .js,.jsx"
|
|
58
57
|
},
|
|
59
|
-
"jest": {
|
|
60
|
-
"moduleNameMapper": {
|
|
61
|
-
"^@/(.*)$": "<rootDir>/src/$1"
|
|
62
|
-
}
|
|
63
|
-
},
|
|
64
58
|
"eslintConfig": {
|
|
65
59
|
"extends": [
|
|
66
60
|
"react-app",
|
|
@@ -85,7 +79,6 @@
|
|
|
85
79
|
"@babel/plugin-proposal-class-properties": "^7.18.6",
|
|
86
80
|
"@babel/preset-env": "^7.25.4",
|
|
87
81
|
"@babel/preset-react": "^7.24.7",
|
|
88
|
-
"@craco/craco": "^7.1.0",
|
|
89
82
|
"@emotion/is-prop-valid": "^1.3.0",
|
|
90
83
|
"@storybook/addon-actions": "^8.3.1",
|
|
91
84
|
"@storybook/addon-essentials": "^8.3.1",
|
|
@@ -105,7 +98,6 @@
|
|
|
105
98
|
"concurrently": "^8.2.2",
|
|
106
99
|
"eslint-config-airbnb": "^19.0.4",
|
|
107
100
|
"eslint-config-prettier": "^9.1.0",
|
|
108
|
-
"eslint-import-resolver-alias": "^1.1.2",
|
|
109
101
|
"eslint-plugin-prettier": "^5.2.1",
|
|
110
102
|
"eslint-plugin-sonarjs": "^1.0.4",
|
|
111
103
|
"jest-google-maps-mock": "^1.0.7",
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import React, { Component } from 'react';
|
|
2
2
|
import PropTypes from 'prop-types';
|
|
3
3
|
import cl from 'classnames';
|
|
4
|
-
import Icon from '
|
|
5
|
-
import { tr } from '
|
|
4
|
+
import Icon from '../Icon/Icon';
|
|
5
|
+
import { tr } from '../utils/locale';
|
|
6
6
|
|
|
7
7
|
export default class Button extends Component {
|
|
8
8
|
constructor(props) {
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import Button from '
|
|
3
|
-
import ButtonGroup from '
|
|
4
|
-
import ButtonSwitch from '
|
|
5
|
-
import ButtonWithDropdown from '
|
|
6
|
-
import Tooltip from '
|
|
2
|
+
import Button from './Button';
|
|
3
|
+
import ButtonGroup from './ButtonGroup';
|
|
4
|
+
import ButtonSwitch from './ButtonSwitch';
|
|
5
|
+
import ButtonWithDropdown from './ButtonWithDropdown';
|
|
6
|
+
import Tooltip from '../Tooltip/Tooltip';
|
|
7
7
|
|
|
8
8
|
const Story = {
|
|
9
9
|
title: 'base/Button',
|
|
@@ -2,7 +2,7 @@ import React from 'react';
|
|
|
2
2
|
import { render } from '@testing-library/react';
|
|
3
3
|
import '@testing-library/jest-dom/extend-expect';
|
|
4
4
|
|
|
5
|
-
import Button from '
|
|
5
|
+
import Button from './Button';
|
|
6
6
|
|
|
7
7
|
it('renders a Button component ', () => {
|
|
8
8
|
const { container } = render(<Button label="label" className="myclass" />);
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import React, { Component } from 'react';
|
|
2
2
|
import PropTypes, { bool } from 'prop-types';
|
|
3
|
-
import Button from '
|
|
4
|
-
import Dropdown from '
|
|
5
|
-
import uniqueid from '
|
|
3
|
+
import Button from './Button';
|
|
4
|
+
import Dropdown from '../Dropdown/Dropdown';
|
|
5
|
+
import uniqueid from '../uniqueid';
|
|
6
6
|
|
|
7
7
|
class ButtonWithDropdown extends Component {
|
|
8
8
|
renderDropdown = () => {
|
|
@@ -3,7 +3,7 @@ import { render } from '@testing-library/react';
|
|
|
3
3
|
import '@testing-library/jest-dom/extend-expect';
|
|
4
4
|
import 'resize-observer-polyfill/dist/ResizeObserver.global';
|
|
5
5
|
|
|
6
|
-
import ButtonWithDropdown from '
|
|
6
|
+
import ButtonWithDropdown from './ButtonWithDropdown';
|
|
7
7
|
|
|
8
8
|
it('renders a small Button', () => {
|
|
9
9
|
const args = {
|
|
@@ -2,37 +2,37 @@
|
|
|
2
2
|
import React, { Component } from 'react';
|
|
3
3
|
import cl from 'classnames';
|
|
4
4
|
import PropTypes from 'prop-types';
|
|
5
|
-
import { tr } from '
|
|
6
|
-
import Icon from '
|
|
7
|
-
import Tooltip from '
|
|
5
|
+
import { tr } from '../utils/locale';
|
|
6
|
+
import Icon from '../Icon/Icon';
|
|
7
|
+
import Tooltip from '../Tooltip/Tooltip';
|
|
8
8
|
|
|
9
|
-
import datasetsImg from '
|
|
10
|
-
import localitiesImg from '
|
|
11
|
-
import localitiesUkImg from '
|
|
12
|
-
import geolocationImg from '
|
|
13
|
-
import storesImg from '
|
|
14
|
-
import distanceImg from '
|
|
15
|
-
import addressImg from '
|
|
16
|
-
import mapImg from '
|
|
17
|
-
import trafficImg from '
|
|
18
|
-
import indoorImg from '
|
|
19
|
-
import what3wordsImg from '
|
|
20
|
-
import transitImg from '
|
|
21
|
-
import distanceTollImg from '
|
|
9
|
+
import datasetsImg from '../../images/products/product-datasets.png';
|
|
10
|
+
import localitiesImg from '../../images/products/product-localities.png';
|
|
11
|
+
import localitiesUkImg from '../../images/products/product-localities-uk.png';
|
|
12
|
+
import geolocationImg from '../../images/products/product-geolocation.png';
|
|
13
|
+
import storesImg from '../../images/products/product-stores.png';
|
|
14
|
+
import distanceImg from '../../images/products/product-distance.png';
|
|
15
|
+
import addressImg from '../../images/products/product-address.png';
|
|
16
|
+
import mapImg from '../../images/products/product-map.png';
|
|
17
|
+
import trafficImg from '../../images/products/product-traffic.png';
|
|
18
|
+
import indoorImg from '../../images/products/product-indoor.png';
|
|
19
|
+
import what3wordsImg from '../../images/products/product-what3words.png';
|
|
20
|
+
import transitImg from '../../images/products/product-transit.png';
|
|
21
|
+
import distanceTollImg from '../../images/products/product-distance-toll.png';
|
|
22
22
|
|
|
23
|
-
import datasetsImgSq from '
|
|
24
|
-
import localitiesImgSq from '
|
|
25
|
-
import localitiesUkImgSq from '
|
|
26
|
-
import geolocationImgSq from '
|
|
27
|
-
import storesImgSq from '
|
|
28
|
-
import distanceImgSq from '
|
|
29
|
-
import addressImgSq from '
|
|
30
|
-
import mapImgSq from '
|
|
31
|
-
import trafficImgSq from '
|
|
32
|
-
import indoorImgSq from '
|
|
33
|
-
import what3wordsImgSq from '
|
|
34
|
-
import transitImgSq from '
|
|
35
|
-
import distanceTollImgSq from '
|
|
23
|
+
import datasetsImgSq from '../../images/products/product-datasets-sq.png';
|
|
24
|
+
import localitiesImgSq from '../../images/products/product-localities-sq.png';
|
|
25
|
+
import localitiesUkImgSq from '../../images/products/product-localities-uk-sq.png';
|
|
26
|
+
import geolocationImgSq from '../../images/products/product-geolocation-sq.png';
|
|
27
|
+
import storesImgSq from '../../images/products/product-stores-sq.png';
|
|
28
|
+
import distanceImgSq from '../../images/products/product-distance-sq.png';
|
|
29
|
+
import addressImgSq from '../../images/products/product-address-sq.png';
|
|
30
|
+
import mapImgSq from '../../images/products/product-map-sq.png';
|
|
31
|
+
import trafficImgSq from '../../images/products/product-traffic-sq.png';
|
|
32
|
+
import indoorImgSq from '../../images/products/product-indoor-sq.png';
|
|
33
|
+
import what3wordsImgSq from '../../images/products/product-what3words-sq.png';
|
|
34
|
+
import transitImgSq from '../../images/products/product-transit-sq.png';
|
|
35
|
+
import distanceTollImgSq from '../../images/products/product-distance-toll-sq.png';
|
|
36
36
|
|
|
37
37
|
const productImg = {
|
|
38
38
|
DATASETS: datasetsImg,
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import Button from '
|
|
3
|
-
import Switch from '
|
|
4
|
-
import Label from '
|
|
5
|
-
import Tooltip from '
|
|
6
|
-
import Card from '
|
|
7
|
-
import SimpleCard from '
|
|
2
|
+
import Button from '../Button/Button';
|
|
3
|
+
import Switch from '../Switch/Switch';
|
|
4
|
+
import Label from '../Label/Label';
|
|
5
|
+
import Tooltip from '../Tooltip/Tooltip';
|
|
6
|
+
import Card from './Card';
|
|
7
|
+
import SimpleCard from './SimpleCard';
|
|
8
8
|
|
|
9
9
|
const Story = {
|
|
10
10
|
title: 'base/Card',
|
|
@@ -2,7 +2,7 @@ import React from 'react';
|
|
|
2
2
|
import { render, screen } from '@testing-library/react';
|
|
3
3
|
import '@testing-library/jest-dom/extend-expect';
|
|
4
4
|
|
|
5
|
-
import Card from '
|
|
5
|
+
import Card from './Card';
|
|
6
6
|
|
|
7
7
|
it('renders a Card component ', () => {
|
|
8
8
|
const { getByTestId } = render(
|
|
@@ -2,8 +2,8 @@
|
|
|
2
2
|
import React, { Component } from 'react';
|
|
3
3
|
import cl from 'classnames';
|
|
4
4
|
import PropTypes from 'prop-types';
|
|
5
|
-
import Icon from '
|
|
6
|
-
import { tr } from '
|
|
5
|
+
import Icon from '../Icon/Icon';
|
|
6
|
+
import { tr } from '../utils/locale';
|
|
7
7
|
|
|
8
8
|
class SimpleCard extends Component {
|
|
9
9
|
render() {
|
|
@@ -30,10 +30,10 @@
|
|
|
30
30
|
box-shadow inset 0 0 .1rem $dark60
|
|
31
31
|
.row-inactive &
|
|
32
32
|
&.disabled
|
|
33
|
-
background #fff url('
|
|
33
|
+
background #fff url('../../images/texture.png')
|
|
34
34
|
color $secondary60
|
|
35
35
|
&.active
|
|
36
|
-
background $primary6 url('
|
|
36
|
+
background $primary6 url('../../images/texture.png')
|
|
37
37
|
&__title
|
|
38
38
|
ellipsis()
|
|
39
39
|
font-weight 600
|
|
@@ -2,7 +2,7 @@ import React from 'react';
|
|
|
2
2
|
import { render, screen } from '@testing-library/react';
|
|
3
3
|
import '@testing-library/jest-dom/extend-expect';
|
|
4
4
|
|
|
5
|
-
import SimpleCard from '
|
|
5
|
+
import SimpleCard from './SimpleCard';
|
|
6
6
|
|
|
7
7
|
it('renders a SimpleCard component ', () => {
|
|
8
8
|
const { getByTestId } = render(
|
|
@@ -2,7 +2,7 @@ import React from 'react';
|
|
|
2
2
|
import { render } from '@testing-library/react';
|
|
3
3
|
import '@testing-library/jest-dom/extend-expect';
|
|
4
4
|
|
|
5
|
-
import CodeSnippet from '
|
|
5
|
+
import CodeSnippet from './CodeSnippet';
|
|
6
6
|
|
|
7
7
|
it('renders a CodeSnippet', () => {
|
|
8
8
|
const jsonObj = {
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import React, { Component } from 'react';
|
|
2
2
|
import PropTypes from 'prop-types';
|
|
3
|
-
import copy from '
|
|
4
|
-
import { tr } from '
|
|
5
|
-
import Button from '
|
|
3
|
+
import copy from '../utils/CopyToClipoard';
|
|
4
|
+
import { tr } from '../utils/locale';
|
|
5
|
+
import Button from '../Button/Button';
|
|
6
6
|
|
|
7
7
|
export default class CopyClipboardButton extends Component {
|
|
8
8
|
constructor(props) {
|
|
@@ -2,7 +2,7 @@ import React from 'react';
|
|
|
2
2
|
import { fireEvent, render } from '@testing-library/react';
|
|
3
3
|
import '@testing-library/jest-dom/extend-expect';
|
|
4
4
|
|
|
5
|
-
import CopyClipboardButton from '
|
|
5
|
+
import CopyClipboardButton from './CopyClipboardButton';
|
|
6
6
|
|
|
7
7
|
const textToBeCopied = 'Text to be copied';
|
|
8
8
|
|
|
@@ -2,7 +2,7 @@ import React from 'react';
|
|
|
2
2
|
import { render } from '@testing-library/react';
|
|
3
3
|
import '@testing-library/jest-dom/extend-expect';
|
|
4
4
|
|
|
5
|
-
import DateTime from '
|
|
5
|
+
import DateTime from './DateTime';
|
|
6
6
|
|
|
7
7
|
it('renders a label component ', () => {
|
|
8
8
|
const { container } = render(<DateTime />);
|
|
@@ -2,16 +2,16 @@
|
|
|
2
2
|
import React, { Component } from 'react';
|
|
3
3
|
import axios from 'axios';
|
|
4
4
|
import cl from 'classnames';
|
|
5
|
-
import markerIcon from '
|
|
6
|
-
import Demo from '
|
|
7
|
-
import Constants from '
|
|
8
|
-
import { createWoosmapMap, WoosmapMapBoundingBox } from '
|
|
9
|
-
import Button from '
|
|
10
|
-
import ButtonGroup from '
|
|
11
|
-
import CountrySelect from '
|
|
12
|
-
import { tr } from '
|
|
13
|
-
import Input from '
|
|
14
|
-
import AddressAutocomplete from '
|
|
5
|
+
import markerIcon from '../../images/marker.png';
|
|
6
|
+
import Demo from './SkeletonDemo';
|
|
7
|
+
import Constants from '../../Constants';
|
|
8
|
+
import { createWoosmapMap, WoosmapMapBoundingBox } from '../Map/drawOnMap';
|
|
9
|
+
import Button from '../Button/Button';
|
|
10
|
+
import ButtonGroup from '../Button/ButtonGroup';
|
|
11
|
+
import CountrySelect from '../Select/CountrySelect';
|
|
12
|
+
import { tr } from '../utils/locale';
|
|
13
|
+
import Input from '../Input/Input';
|
|
14
|
+
import AddressAutocomplete from '../Woosmap/AddressAutocomplete';
|
|
15
15
|
|
|
16
16
|
const languages = [
|
|
17
17
|
{ value: 'fr', label: 'French' },
|
|
@@ -2,16 +2,16 @@ import axios from 'axios';
|
|
|
2
2
|
import cl from 'classnames';
|
|
3
3
|
import React, { Component } from 'react';
|
|
4
4
|
import PropTypes from 'prop-types';
|
|
5
|
-
import markerIcon from '
|
|
6
|
-
import LocalitiesAutocomplete from '
|
|
7
|
-
import Constants from '
|
|
8
|
-
import { tr } from '
|
|
9
|
-
import CountrySelect from '
|
|
10
|
-
import Input from '
|
|
11
|
-
import Tab from '
|
|
12
|
-
import Script from '
|
|
13
|
-
import CodeSnippet from '
|
|
14
|
-
import { createWoosmapMap } from '
|
|
5
|
+
import markerIcon from '../../images/marker.png';
|
|
6
|
+
import LocalitiesAutocomplete from '../Woosmap/LocalitiesAutocomplete';
|
|
7
|
+
import Constants from '../../Constants';
|
|
8
|
+
import { tr } from '../utils/locale';
|
|
9
|
+
import CountrySelect from '../Select/CountrySelect';
|
|
10
|
+
import Input from '../Input/Input';
|
|
11
|
+
import Tab from '../Tab/Tab';
|
|
12
|
+
import Script from '../utils/Script';
|
|
13
|
+
import CodeSnippet from '../CodeSnippet/CodeSnippet';
|
|
14
|
+
import { createWoosmapMap } from '../Map/drawOnMap';
|
|
15
15
|
|
|
16
16
|
const MAP_CLASSNAME = 'map';
|
|
17
17
|
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import AutocompleteAddressDemo from '
|
|
3
|
-
import { changeLanguage } from '
|
|
2
|
+
import AutocompleteAddressDemo from './AutocompleteAddressDemo';
|
|
3
|
+
import { changeLanguage } from '../utils/locale';
|
|
4
4
|
|
|
5
5
|
const Story = {
|
|
6
6
|
title: 'demo/AutocompleteAddress',
|
|
@@ -5,18 +5,18 @@ import PropTypes from 'prop-types';
|
|
|
5
5
|
import cl from 'classnames';
|
|
6
6
|
import polyline from '@mapbox/polyline';
|
|
7
7
|
import Datetime from 'react-datetime';
|
|
8
|
-
import DrivingImg from '
|
|
9
|
-
import CyclingImg from '
|
|
10
|
-
import WalkingImg from '
|
|
11
|
-
import markerIcon from '
|
|
12
|
-
import Demo from '
|
|
13
|
-
import Input from '
|
|
14
|
-
import Constants from '
|
|
15
|
-
import LocalitiesAutocomplete from '
|
|
16
|
-
import Button from '
|
|
17
|
-
import ButtonGroup from '
|
|
18
|
-
import { tr } from '
|
|
19
|
-
import { createWoosmapMap } from '
|
|
8
|
+
import DrivingImg from '../../images/car.png';
|
|
9
|
+
import CyclingImg from '../../images/cycle.png';
|
|
10
|
+
import WalkingImg from '../../images/walk.png';
|
|
11
|
+
import markerIcon from '../../images/marker.png';
|
|
12
|
+
import Demo from './SkeletonDemo';
|
|
13
|
+
import Input from '../Input/Input';
|
|
14
|
+
import Constants from '../../Constants';
|
|
15
|
+
import LocalitiesAutocomplete from '../Woosmap/LocalitiesAutocomplete';
|
|
16
|
+
import Button from '../Button/Button';
|
|
17
|
+
import ButtonGroup from '../Button/ButtonGroup';
|
|
18
|
+
import { tr } from '../utils/locale';
|
|
19
|
+
import { createWoosmapMap } from '../Map/drawOnMap';
|
|
20
20
|
|
|
21
21
|
const languages = [
|
|
22
22
|
{ value: 'fr', label: 'French' },
|
|
@@ -2,7 +2,7 @@ import React from 'react';
|
|
|
2
2
|
import { fireEvent, render, screen, waitFor } from '@testing-library/react';
|
|
3
3
|
import '@testing-library/jest-dom/extend-expect';
|
|
4
4
|
|
|
5
|
-
import DistanceDemo from '
|
|
5
|
+
import DistanceDemo from './DistanceDemo';
|
|
6
6
|
|
|
7
7
|
const API_ERROR_MESSAGE = 'Some handled error message';
|
|
8
8
|
|
|
@@ -2,13 +2,13 @@
|
|
|
2
2
|
import axios from 'axios';
|
|
3
3
|
import React, { Component } from 'react';
|
|
4
4
|
import PropTypes from 'prop-types';
|
|
5
|
-
import markerIcon from '
|
|
6
|
-
import markerGeolocationIcon from '
|
|
7
|
-
import Demo from '
|
|
8
|
-
import Constants from '
|
|
9
|
-
import { tr } from '
|
|
10
|
-
import Input from '
|
|
11
|
-
import { WoosmapMapBoundingBox, woosmapBoundsFromViewport, createWoosmapMap } from '
|
|
5
|
+
import markerIcon from '../../images/marker-dot.svg';
|
|
6
|
+
import markerGeolocationIcon from '../../images/marker-alt.png';
|
|
7
|
+
import Demo from './SkeletonDemo';
|
|
8
|
+
import Constants from '../../Constants';
|
|
9
|
+
import { tr } from '../utils/locale';
|
|
10
|
+
import Input from '../Input/Input';
|
|
11
|
+
import { WoosmapMapBoundingBox, woosmapBoundsFromViewport, createWoosmapMap } from '../Map/drawOnMap';
|
|
12
12
|
|
|
13
13
|
export default class GeolocationDemo extends Component {
|
|
14
14
|
constructor(props) {
|
|
@@ -2,7 +2,7 @@ import React from 'react';
|
|
|
2
2
|
import { render } from '@testing-library/react';
|
|
3
3
|
import '@testing-library/jest-dom/extend-expect';
|
|
4
4
|
|
|
5
|
-
import GeolocationDemo from '
|
|
5
|
+
import GeolocationDemo from './GeolocationDemo';
|
|
6
6
|
|
|
7
7
|
it('render geolocation demo', () => {
|
|
8
8
|
const { container } = render(<GeolocationDemo />);
|
|
@@ -2,14 +2,14 @@
|
|
|
2
2
|
import React, { Component } from 'react';
|
|
3
3
|
import axios from 'axios';
|
|
4
4
|
import PropTypes from 'prop-types';
|
|
5
|
-
import markerIcon from '
|
|
6
|
-
import Demo from '
|
|
7
|
-
import Constants from '
|
|
8
|
-
import AddressAutocomplete from '
|
|
9
|
-
import CountrySelect from '
|
|
10
|
-
import Input from '
|
|
11
|
-
import { tr } from '
|
|
12
|
-
import { createWoosmapMap } from '
|
|
5
|
+
import markerIcon from '../../images/marker.png';
|
|
6
|
+
import Demo from './SkeletonDemo';
|
|
7
|
+
import Constants from '../../Constants';
|
|
8
|
+
import AddressAutocomplete from '../Woosmap/AddressAutocomplete';
|
|
9
|
+
import CountrySelect from '../Select/CountrySelect';
|
|
10
|
+
import Input from '../Input/Input';
|
|
11
|
+
import { tr } from '../utils/locale';
|
|
12
|
+
import { createWoosmapMap } from '../Map/drawOnMap';
|
|
13
13
|
|
|
14
14
|
export default class LocalitiesAddressDemo extends Component {
|
|
15
15
|
constructor(props) {
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
/* eslint-disable jsx-a11y/click-events-have-key-events */
|
|
2
2
|
import React, { Component } from 'react';
|
|
3
|
-
import LocalitiesDemo from '
|
|
4
|
-
import Button from '
|
|
5
|
-
import ButtonGroup from '
|
|
6
|
-
import { tr } from '
|
|
7
|
-
import LocalitiesAddressDemo from '
|
|
3
|
+
import LocalitiesDemo from './LocalitiesDemo';
|
|
4
|
+
import Button from '../Button/Button';
|
|
5
|
+
import ButtonGroup from '../Button/ButtonGroup';
|
|
6
|
+
import { tr } from '../utils/locale';
|
|
7
|
+
import LocalitiesAddressDemo from './LocalitiesAddressDemo';
|
|
8
8
|
|
|
9
9
|
export default class LocalitiesAllDemo extends Component {
|
|
10
10
|
constructor(props) {
|
|
@@ -3,16 +3,16 @@ import axios from 'axios';
|
|
|
3
3
|
import cl from 'classnames';
|
|
4
4
|
import React, { Component } from 'react';
|
|
5
5
|
import PropTypes from 'prop-types';
|
|
6
|
-
import Demo from '
|
|
7
|
-
import Select from '
|
|
8
|
-
import Button from '
|
|
9
|
-
import ButtonGroup from '
|
|
10
|
-
import LocalitiesAutocomplete from '
|
|
11
|
-
import CountrySelect, { countriesOptions } from '
|
|
12
|
-
import Constants from '
|
|
13
|
-
import { tr } from '
|
|
14
|
-
import { WoosmapMapBoundingBox, createWoosmapMap } from '
|
|
15
|
-
import markerIcon from '
|
|
6
|
+
import Demo from './SkeletonDemo';
|
|
7
|
+
import Select from '../Select/Select';
|
|
8
|
+
import Button from '../Button/Button';
|
|
9
|
+
import ButtonGroup from '../Button/ButtonGroup';
|
|
10
|
+
import LocalitiesAutocomplete from '../Woosmap/LocalitiesAutocomplete';
|
|
11
|
+
import CountrySelect, { countriesOptions } from '../Select/CountrySelect';
|
|
12
|
+
import Constants from '../../Constants';
|
|
13
|
+
import { tr } from '../utils/locale';
|
|
14
|
+
import { WoosmapMapBoundingBox, createWoosmapMap } from '../Map/drawOnMap';
|
|
15
|
+
import markerIcon from '../../images/marker.png';
|
|
16
16
|
|
|
17
17
|
const languages = [
|
|
18
18
|
{ value: 'fr', label: 'French' },
|