@kando-env/kando-ui 1.0.7 → 1.0.9
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/lib/CovidView/views/components/Map.js +3 -2
- package/lib/CovidView/views/components/TrendPopupContent/TrendPopupContent.js +4 -4
- package/lib/CovidView/views/components/areas/AreaPolygonWBE.js +7 -7
- package/lib/{EventsView/views/components → DashboardV2}/SamplingParameters/ParametersContainer/ParametersButtons/styles.js +4 -4
- package/lib/{EventsView/views/components → DashboardV2}/SamplingParameters/ParametersContainer/ParametersContainer.js +1 -1
- package/lib/{EventsView/views/components → DashboardV2}/SamplingParameters/SamplingContainer/ExceptionBar/styles.js +4 -4
- package/lib/{EventsView/views/components → DashboardV2}/SamplingParameters/SamplingContainer/SamplingContainer.js +1 -1
- package/lib/{EventsView/views/components → DashboardV2}/SamplingParameters/SamplingParameters.js +3 -3
- package/lib/{EventsView/views/components → DashboardV2}/SamplingParameters/charts/options/options.js +25 -4
- package/lib/{EventsView/views/components → DashboardV2}/UtilityDashboard/MostPolluting/Areas/AreaBox/AreaBox.js +6 -6
- package/lib/{EventsView/views/components → DashboardV2}/UtilityDashboard/MostPolluting/Areas/AreaBox/styles.js +1 -1
- package/lib/{EventsView/views/components → DashboardV2}/UtilityDashboard/MostPolluting/Areas/Areas.js +40 -45
- package/lib/{EventsView/views/components → DashboardV2}/UtilityDashboard/MostPolluting/Areas/styles.js +3 -3
- package/lib/{EventsView/views/components → DashboardV2}/UtilityDashboard/MostPolluting/Factories/Factories.js +40 -45
- package/lib/{EventsView/views/components → DashboardV2}/UtilityDashboard/MostPolluting/Factories/FactoryBox/FactoryBox.js +5 -4
- package/lib/{EventsView/views/components → DashboardV2}/UtilityDashboard/MostPolluting/Factories/FactoryBox/styles.js +1 -1
- package/lib/{EventsView/views/components → DashboardV2}/UtilityDashboard/MostPolluting/Factories/styles.js +2 -2
- package/lib/{EventsView/views/components → DashboardV2}/UtilityDashboard/MostPolluting/MostPolluting.js +7 -13
- package/lib/{EventsView/views/components → DashboardV2}/UtilityDashboard/MostPolluting/ShowMore/styles.js +1 -1
- package/lib/{EventsView/views/components → DashboardV2}/UtilityDashboard/MostPolluting/Tabs/Tabs.js +17 -32
- package/lib/{EventsView/views/components/UtilityDashboard/TopBar → DashboardV2/UtilityDashboard/MostPolluting}/models.js +3 -1
- package/lib/{EventsView/views/components → DashboardV2}/UtilityDashboard/MostPolluting/styles.js +2 -2
- package/lib/{EventsView/views/components → DashboardV2}/UtilityDashboard/MostSevereEvents/MostSevereEvents.js +1 -1
- package/lib/{EventsView/views/components → DashboardV2}/UtilityDashboard/MostSevereEvents/MostSevereEvents.scss +5 -5
- package/lib/{EventsView/views/components → DashboardV2}/UtilityDashboard/TopBar/MostCommon/Back/Back.js +1 -1
- package/lib/{EventsView/views/components → DashboardV2}/UtilityDashboard/TopBar/MostCommon/MostCommon.js +1 -1
- package/lib/{EventsView/views/components → DashboardV2}/UtilityDashboard/TopBar/MostCommon/styles.js +11 -11
- package/lib/DashboardV2/UtilityDashboard/TopBar/QualitySummary/PieChart/PieChart.js +128 -0
- package/lib/{EventsView/views/components → DashboardV2}/UtilityDashboard/TopBar/QualitySummary/PollutedLine/PollutedLine.js +3 -3
- package/lib/{EventsView/views/components → DashboardV2}/UtilityDashboard/TopBar/QualitySummary/QualitySummary.js +15 -4
- package/lib/{EventsView/views/components → DashboardV2}/UtilityDashboard/TopBar/QualitySummary/styles.js +8 -8
- package/lib/{EventsView/views/components → DashboardV2}/UtilityDashboard/TopBar/TopBar.js +3 -3
- package/lib/{EventsView/views/components → DashboardV2}/UtilityDashboard/TopBar/UtilityInformation/UtilityInformation.js +2 -2
- package/lib/{EventsView/views/components → DashboardV2}/UtilityDashboard/TopBar/UtilityInformation/styles.js +6 -6
- package/lib/{EventsView/views/components → DashboardV2}/UtilityDashboard/TopBar/styles.js +1 -1
- package/lib/{EventsView/views/components → DashboardV2}/UtilityDashboard/UtilityDashboard.js +1 -1
- package/lib/{EventsView/views/components → DashboardV2}/UtilityDashboard/UtilityDashboard.stories.js +62 -1
- package/lib/{EventsView/views/components → DashboardV2}/UtilityDashboard/mocks/areas.mock.js +9 -33
- package/lib/{EventsView/views/components → DashboardV2}/UtilityDashboard/mocks/factories.mock.js +4 -16
- package/lib/EventsView/views/components/Body.js +55 -29
- package/lib/EventsView/views/components/map/Map.js +11 -6
- package/lib/EventsView/views/components/points/PointMarker.js +15 -15
- package/lib/index.js +67 -3
- package/lib/shared/components/DoubleTabs/styles.js +1 -1
- package/lib/shared/components/KandoModal/KandoModal.js +2 -2
- package/lib/shared/components/Map/Map.js +4 -1
- package/lib/shared/components/Select/Select.js +48 -6
- package/lib/shared/components/Select/Select.scss +5 -14
- package/lib/shared/components/Select/Select.stories.js +4 -1
- package/package.json +9 -8
- package/lib/EventsView/views/components/UtilityDashboard/TopBar/QualitySummary/PieChart/PieChart.js +0 -117
- /package/lib/{EventsView/views/components → DashboardV2}/SamplingParameters/NoResults/NoResults.js +0 -0
- /package/lib/{EventsView/views/components → DashboardV2}/SamplingParameters/NoResults/NoResults.stories.js +0 -0
- /package/lib/{EventsView/views/components → DashboardV2}/SamplingParameters/NoResults/discover.svg +0 -0
- /package/lib/{EventsView/views/components → DashboardV2}/SamplingParameters/ParametersContainer/ParametersButtons/ParameterButton/ParameterButton.js +0 -0
- /package/lib/{EventsView/views/components → DashboardV2}/SamplingParameters/ParametersContainer/ParametersButtons/ParametersButtons.js +0 -0
- /package/lib/{EventsView/views/components → DashboardV2}/SamplingParameters/SamplingContainer/ExceptionBar/ExceptionBar.js +0 -0
- /package/lib/{EventsView/views/components → DashboardV2}/SamplingParameters/SamplingContainer/ExceptionBar/ExceptionBar.stories.js +0 -0
- /package/lib/{EventsView/views/components → DashboardV2}/SamplingParameters/SamplingContainer/ExpandableSamplingTable/ExpandableSamplingTable.js +0 -0
- /package/lib/{EventsView/views/components → DashboardV2}/SamplingParameters/SamplingContainer/ExpandableSamplingTable/ExpandableSamplingTable.scss +0 -0
- /package/lib/{EventsView/views/components → DashboardV2}/SamplingParameters/SamplingContainer/ExpandableSamplingTable/assets/rigth.svg +0 -0
- /package/lib/{EventsView/views/components → DashboardV2}/SamplingParameters/SamplingParameters.mock.js +0 -0
- /package/lib/{EventsView/views/components → DashboardV2}/SamplingParameters/SamplingParameters.stories.js +0 -0
- /package/lib/{EventsView/views/components → DashboardV2}/SamplingParameters/charts/ParametersChart.js +0 -0
- /package/lib/{EventsView/views/components → DashboardV2}/SamplingParameters/charts/SamplingChart.js +0 -0
- /package/lib/{EventsView/views/components → DashboardV2}/SamplingParameters/dataParser.js +0 -0
- /package/lib/{EventsView/views/components → DashboardV2}/SamplingParameters/models.js +0 -0
- /package/lib/{EventsView/views/components → DashboardV2}/SamplingParameters/styles/samplingParameters.js +0 -0
- /package/lib/{EventsView/views/components → DashboardV2}/SamplingParameters/styles/styles.js +0 -0
- /package/lib/{EventsView/views/components → DashboardV2}/UtilityDashboard/MostPolluting/Areas/AreaBox/AreaMap/AreaMap.js +0 -0
- /package/lib/{EventsView/views/components → DashboardV2}/UtilityDashboard/MostPolluting/Areas/AreaBox/PieChart/PieChart.js +0 -0
- /package/lib/{EventsView/views/components → DashboardV2}/UtilityDashboard/MostPolluting/Factories/FactoryBox/PieChart/PieChart.js +0 -0
- /package/lib/{EventsView/views/components → DashboardV2}/UtilityDashboard/MostPolluting/MostPolluting.stories.js +0 -0
- /package/lib/{EventsView/views/components → DashboardV2}/UtilityDashboard/MostPolluting/ShowMore/ShowMore.js +0 -0
- /package/lib/{EventsView/views/components → DashboardV2}/UtilityDashboard/MostPolluting/Tabs/Tabs.stories.js +0 -0
- /package/lib/{EventsView/views/components → DashboardV2}/UtilityDashboard/MostPolluting/Tabs/assets/home.svg +0 -0
- /package/lib/{EventsView/views/components → DashboardV2}/UtilityDashboard/MostPolluting/Tabs/assets/index.js +0 -0
- /package/lib/{EventsView/views/components → DashboardV2}/UtilityDashboard/MostPolluting/Tabs/assets/matash.svg +0 -0
- /package/lib/{EventsView/views/components → DashboardV2}/UtilityDashboard/MostPolluting/Tabs/assets/plant.svg +0 -0
- /package/lib/{EventsView/views/components → DashboardV2}/UtilityDashboard/MostPolluting/Tabs/assets/shape.svg +0 -0
- /package/lib/{EventsView/views/components → DashboardV2}/UtilityDashboard/MostPolluting/Tabs/assets/water.svg +0 -0
- /package/lib/{EventsView/views/components → DashboardV2}/UtilityDashboard/MostPolluting/assets/down-arrow.svg +0 -0
- /package/lib/{EventsView/views/components → DashboardV2}/UtilityDashboard/MostPolluting/assets/gas.svg +0 -0
- /package/lib/{EventsView/views/components → DashboardV2}/UtilityDashboard/MostPolluting/assets/index.js +0 -0
- /package/lib/{EventsView/views/components → DashboardV2}/UtilityDashboard/MostPolluting/assets/leather.svg +0 -0
- /package/lib/{EventsView/views/components → DashboardV2}/UtilityDashboard/MostPolluting/assets/metal.svg +0 -0
- /package/lib/{EventsView/views/components → DashboardV2}/UtilityDashboard/MostPolluting/assets/shop.svg +0 -0
- /package/lib/{EventsView/views/components → DashboardV2}/UtilityDashboard/MostPolluting/assets/show-more.svg +0 -0
- /package/lib/{EventsView/views/components → DashboardV2}/UtilityDashboard/MostSevereEvents/MostSevereEvents.stories.js +0 -0
- /package/lib/{EventsView/views/components → DashboardV2}/UtilityDashboard/MostSevereEvents/NoEvents/NoEvents.js +0 -0
- /package/lib/{EventsView/views/components → DashboardV2}/UtilityDashboard/MostSevereEvents/NoEvents/NoEvents.stories.js +0 -0
- /package/lib/{EventsView/views/components → DashboardV2}/UtilityDashboard/MostSevereEvents/NoEvents/discover.svg +0 -0
- /package/lib/{EventsView/views/components → DashboardV2}/UtilityDashboard/MostSevereEvents/SevereEvent/SevereEvent.js +0 -0
- /package/lib/{EventsView/views/components → DashboardV2}/UtilityDashboard/MostSevereEvents/SevereEvent/SevereEvent.scss +0 -0
- /package/lib/{EventsView/views/components → DashboardV2}/UtilityDashboard/MostSevereEvents/SevereEvent/assets/info.svg +0 -0
- /package/lib/{EventsView/views/components → DashboardV2}/UtilityDashboard/MostSevereEvents/SevereEvent/assets/pipe-bluckages.svg +0 -0
- /package/lib/{EventsView/views/components → DashboardV2}/UtilityDashboard/MostSevereEvents/SevereEvent/assets/pipe.svg +0 -0
- /package/lib/{EventsView/views/components → DashboardV2}/UtilityDashboard/MostSevereEvents/SevereEvent/assets/sludge.svg +0 -0
- /package/lib/{EventsView/views/components/UtilityDashboard/MostPolluting → DashboardV2/UtilityDashboard/MostSevereEvents}/models.js +0 -0
- /package/lib/{EventsView/views/components → DashboardV2}/UtilityDashboard/TopBar/MostCommon/assets/arrow.svg +0 -0
- /package/lib/{EventsView/views/components → DashboardV2}/UtilityDashboard/TopBar/MostCommon/assets/bacteria.svg +0 -0
- /package/lib/{EventsView/views/components → DashboardV2}/UtilityDashboard/TopBar/MostCommon/assets/clock.svg +0 -0
- /package/lib/{EventsView/views/components → DashboardV2}/UtilityDashboard/TopBar/MostCommon/assets/pipes.svg +0 -0
- /package/lib/{EventsView/views/components → DashboardV2}/UtilityDashboard/TopBar/QualitySummary/assets/down-arrow.svg +0 -0
- /package/lib/{EventsView/views/components/UtilityDashboard/MostSevereEvents → DashboardV2/UtilityDashboard/TopBar}/models.js +0 -0
- /package/lib/{EventsView/views/components → DashboardV2}/UtilityDashboard/mocks/events.mock.js +0 -0
- /package/lib/{EventsView/views/components → DashboardV2}/UtilityDashboard/mocks/index.js +0 -0
|
@@ -19,42 +19,42 @@ var _styles = require("../styles");
|
|
|
19
19
|
|
|
20
20
|
var Container = _styledComponents.default.div.withConfig({
|
|
21
21
|
displayName: "styles__Container",
|
|
22
|
-
componentId: "sc-
|
|
22
|
+
componentId: "sc-1ikbh2k-0"
|
|
23
23
|
})(["@media (max-width:1200px){grid-area:info;height:100% !important;overflow:hidden;box-sizing:border-box;}"]);
|
|
24
24
|
|
|
25
25
|
exports.Container = Container;
|
|
26
26
|
|
|
27
27
|
var ContentHolder = _styledComponents.default.div.withConfig({
|
|
28
28
|
displayName: "styles__ContentHolder",
|
|
29
|
-
componentId: "sc-
|
|
29
|
+
componentId: "sc-1ikbh2k-1"
|
|
30
30
|
})(["object-fit:contain;box-shadow:-0.9px -0.5px 5px 0 rgba(0,0,0,0.06);border:solid 1px #ebebeb;height:calc( 100% - 37px);"]);
|
|
31
31
|
|
|
32
32
|
exports.ContentHolder = ContentHolder;
|
|
33
33
|
|
|
34
34
|
var ContentTop = _styledComponents.default.div.withConfig({
|
|
35
35
|
displayName: "styles__ContentTop",
|
|
36
|
-
componentId: "sc-
|
|
36
|
+
componentId: "sc-1ikbh2k-2"
|
|
37
37
|
})(["display:flex;justify-content:space-between;align-items:center;padding:12px 20px;font-size:14px;font-weight:600;background-color:rgba(244,244,244,0.5);> .total-score{> .score{font-size:18px;font-weight:600;color:#f6004f;margin-left:11px;}}@media (max-width:1450px){padding:6px 10px;font-size:13px;> .total-score{> .score{font-size:17px;}}}"]);
|
|
38
38
|
|
|
39
39
|
exports.ContentTop = ContentTop;
|
|
40
40
|
|
|
41
41
|
var ShowMapLink = _styledComponents.default.a.withConfig({
|
|
42
42
|
displayName: "styles__ShowMapLink",
|
|
43
|
-
componentId: "sc-
|
|
43
|
+
componentId: "sc-1ikbh2k-3"
|
|
44
44
|
})(["font-weight:300;color:#f6004f;"]);
|
|
45
45
|
|
|
46
46
|
exports.ShowMapLink = ShowMapLink;
|
|
47
47
|
|
|
48
48
|
var ContentBottom = _styledComponents.default.div.withConfig({
|
|
49
49
|
displayName: "styles__ContentBottom",
|
|
50
|
-
componentId: "sc-
|
|
50
|
+
componentId: "sc-1ikbh2k-4"
|
|
51
51
|
})(["padding:10px 5px;display:grid;justify-content:space-evenly;grid-template-columns:repeat(3,1fr);"]);
|
|
52
52
|
|
|
53
53
|
exports.ContentBottom = ContentBottom;
|
|
54
54
|
|
|
55
55
|
var Score = _styledComponents.default.div.withConfig({
|
|
56
56
|
displayName: "styles__Score",
|
|
57
|
-
componentId: "sc-
|
|
57
|
+
componentId: "sc-1ikbh2k-5"
|
|
58
58
|
})(["text-align:center;border:1px solid transparent;padding:20px;&:nth-child(1),:nth-child(2){border-right-color:#ebebeb;}> .subtitle{font-size:14px;font-weight:600;}> .number{font-size:48px;font-weight:700;}@media (max-width:1450px){padding:12px;> .subtitle{font-size:12px;font-weight:600;}> .number{font-size:40px;font-weight:700;}}"]);
|
|
59
59
|
|
|
60
60
|
exports.Score = Score;
|
|
@@ -11,7 +11,7 @@ var _styledComponents = _interopRequireDefault(require("styled-components"));
|
|
|
11
11
|
|
|
12
12
|
var BoxTitle = _styledComponents.default.div.withConfig({
|
|
13
13
|
displayName: "styles__BoxTitle",
|
|
14
|
-
componentId: "sc-
|
|
14
|
+
componentId: "sc-mii6vb-0"
|
|
15
15
|
})(["font-family:Gilroy;font-size:24px;line-height:0.92;color:#1d1d1d;font-weight:normal;margin-bottom:14px;@media (min-width:1200px){@media (max-width:1450px){font-size:20px;@media (max-width:1250px){font-size:16px;}}}@media (max-width:400px){font-size:16px;}"]);
|
|
16
16
|
|
|
17
17
|
exports.BoxTitle = BoxTitle;
|
package/lib/{EventsView/views/components → DashboardV2}/UtilityDashboard/UtilityDashboard.js
RENAMED
|
@@ -19,7 +19,7 @@ var _TopBar = require("./TopBar/TopBar");
|
|
|
19
19
|
|
|
20
20
|
var Container = _styledComponents.default.div.withConfig({
|
|
21
21
|
displayName: "UtilityDashboard__Container",
|
|
22
|
-
componentId: "sc-
|
|
22
|
+
componentId: "sc-wo5cbi-0"
|
|
23
23
|
})(["padding:50px 30px;width:100%;overflow:hidden;@media (max-width:768px){padding:25px 5px;}> .title{font-family:Gilroy;font-size:36px;font-weight:700;line-height:0.61;color:#1d1d1d;margin-bottom:25px;}> .top-bar{margin-bottom:45px;}> .most-polluting{margin-bottom:45px;}"]);
|
|
24
24
|
|
|
25
25
|
var UtilityDashboard = function UtilityDashboard() {
|
package/lib/{EventsView/views/components → DashboardV2}/UtilityDashboard/UtilityDashboard.stories.js
RENAMED
|
@@ -5,7 +5,7 @@ var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefau
|
|
|
5
5
|
Object.defineProperty(exports, "__esModule", {
|
|
6
6
|
value: true
|
|
7
7
|
});
|
|
8
|
-
exports.Default = exports.default = void 0;
|
|
8
|
+
exports.NoScore = exports.Default = exports.default = void 0;
|
|
9
9
|
|
|
10
10
|
var _msw = require("msw");
|
|
11
11
|
|
|
@@ -40,6 +40,67 @@ Default.parameters = {
|
|
|
40
40
|
wwtp: 5
|
|
41
41
|
}
|
|
42
42
|
},
|
|
43
|
+
summary: {
|
|
44
|
+
clear: {
|
|
45
|
+
increasePercent: -15,
|
|
46
|
+
percent: 75
|
|
47
|
+
},
|
|
48
|
+
polluted: {
|
|
49
|
+
total: 25,
|
|
50
|
+
extreme: {
|
|
51
|
+
increasePercent: 0.4,
|
|
52
|
+
percent: 5
|
|
53
|
+
},
|
|
54
|
+
high: {
|
|
55
|
+
increasePercent: -0.1,
|
|
56
|
+
percent: 3
|
|
57
|
+
},
|
|
58
|
+
medium: {
|
|
59
|
+
increasePercent: 0.4,
|
|
60
|
+
percent: 17
|
|
61
|
+
}
|
|
62
|
+
}
|
|
63
|
+
}
|
|
64
|
+
}));
|
|
65
|
+
}), _msw.rest.get('/areas', function (req, res, ctx) {
|
|
66
|
+
return res(ctx.json({
|
|
67
|
+
areasArr: _mocks.areasArr
|
|
68
|
+
}));
|
|
69
|
+
}), _msw.rest.get('/factories', function (req, res, ctx) {
|
|
70
|
+
return res(ctx.json({
|
|
71
|
+
factoriesArr: _mocks.factoriesArr
|
|
72
|
+
}));
|
|
73
|
+
}), _msw.rest.get('/wwtp', function (req, res, ctx) {
|
|
74
|
+
return res(ctx.json({
|
|
75
|
+
factoriesArr: _mocks.factoriesArr
|
|
76
|
+
}));
|
|
77
|
+
}), _msw.rest.get('/pumping', function (req, res, ctx) {
|
|
78
|
+
return res(ctx.json({
|
|
79
|
+
factoriesArr: _mocks.factoriesArr
|
|
80
|
+
}));
|
|
81
|
+
}), _msw.rest.get('/collectors', function (req, res, ctx) {
|
|
82
|
+
return res(ctx.json({
|
|
83
|
+
factoriesArr: _mocks.factoriesArr
|
|
84
|
+
}));
|
|
85
|
+
}), _msw.rest.get('/events', function (req, res, ctx) {
|
|
86
|
+
return res(ctx.json({
|
|
87
|
+
eventsArr: _mocks.eventsArr
|
|
88
|
+
}));
|
|
89
|
+
})]
|
|
90
|
+
};
|
|
91
|
+
var NoScore = Template.bind({});
|
|
92
|
+
exports.NoScore = NoScore;
|
|
93
|
+
NoScore.args = {};
|
|
94
|
+
NoScore.parameters = {
|
|
95
|
+
msw: [_msw.rest.get('/summary', function (req, res, ctx) {
|
|
96
|
+
return res(ctx.json({
|
|
97
|
+
utilityInfo: {
|
|
98
|
+
scores: {
|
|
99
|
+
areas: 7,
|
|
100
|
+
factories: 27,
|
|
101
|
+
wwtp: 5
|
|
102
|
+
}
|
|
103
|
+
},
|
|
43
104
|
summary: {
|
|
44
105
|
clear: {
|
|
45
106
|
up: false,
|
package/lib/{EventsView/views/components → DashboardV2}/UtilityDashboard/mocks/areas.mock.js
RENAMED
|
@@ -8,7 +8,6 @@ var areasArr = [{
|
|
|
8
8
|
title: 'Vallese - indsutrial zon.',
|
|
9
9
|
percent: 0.1,
|
|
10
10
|
factories: 5,
|
|
11
|
-
up: true,
|
|
12
11
|
status: 'high',
|
|
13
12
|
locationLatLon: [32.0929012, 34.8072057],
|
|
14
13
|
points: [[32.09464364419881, 34.8044514656067], [32.0943523859244, 34.81043815612794], [32.09074798793366, 34.80904340744019], [32.09103925769882, 34.80406522750855]],
|
|
@@ -20,9 +19,8 @@ var areasArr = [{
|
|
|
20
19
|
}
|
|
21
20
|
}, {
|
|
22
21
|
title: 'South Industrial',
|
|
23
|
-
percent: 0.2,
|
|
22
|
+
percent: -0.2,
|
|
24
23
|
factories: 3,
|
|
25
|
-
up: true,
|
|
26
24
|
locationLatLon: [32.0929012, 34.8072057],
|
|
27
25
|
status: 'high',
|
|
28
26
|
points: [[32.09464364419881, 34.8044514656067], [32.0943523859244, 34.81043815612794], [32.09074798793366, 34.80904340744019], [32.09103925769882, 34.80406522750855]],
|
|
@@ -36,7 +34,6 @@ var areasArr = [{
|
|
|
36
34
|
title: 'North Industrial',
|
|
37
35
|
percent: 0.4,
|
|
38
36
|
factories: 2,
|
|
39
|
-
up: true,
|
|
40
37
|
locationLatLon: [32.0929012, 34.8072057],
|
|
41
38
|
status: 'high',
|
|
42
39
|
points: [[32.09464364419881, 34.8044514656067], [32.0943523859244, 34.81043815612794], [32.09074798793366, 34.80904340744019], [32.09103925769882, 34.80406522750855]],
|
|
@@ -48,9 +45,8 @@ var areasArr = [{
|
|
|
48
45
|
}
|
|
49
46
|
}, {
|
|
50
47
|
title: 'Ca Degli Oppin',
|
|
51
|
-
percent: 0.3,
|
|
48
|
+
percent: -0.3,
|
|
52
49
|
factories: 2,
|
|
53
|
-
up: false,
|
|
54
50
|
locationLatLon: [32.0929012, 34.8072057],
|
|
55
51
|
status: 'high',
|
|
56
52
|
points: [[32.09464364419881, 34.8044514656067], [32.0943523859244, 34.81043815612794], [32.09074798793366, 34.80904340744019], [32.09103925769882, 34.80406522750855]],
|
|
@@ -64,7 +60,6 @@ var areasArr = [{
|
|
|
64
60
|
title: 'South Industrial',
|
|
65
61
|
percent: 0.2,
|
|
66
62
|
factories: 3,
|
|
67
|
-
up: true,
|
|
68
63
|
locationLatLon: [32.0929012, 34.8072057],
|
|
69
64
|
status: 'none',
|
|
70
65
|
points: [[32.09464364419881, 34.8044514656067], [32.0943523859244, 34.81043815612794], [32.09074798793366, 34.80904340744019], [32.09103925769882, 34.80406522750855]],
|
|
@@ -76,9 +71,8 @@ var areasArr = [{
|
|
|
76
71
|
}
|
|
77
72
|
}, {
|
|
78
73
|
title: 'Ca Degli Oppin',
|
|
79
|
-
percent: 0.3,
|
|
74
|
+
percent: -0.3,
|
|
80
75
|
factories: 2,
|
|
81
|
-
up: false,
|
|
82
76
|
locationLatLon: [32.0929012, 34.8072057],
|
|
83
77
|
status: 'medium',
|
|
84
78
|
points: [[32.09464364419881, 34.8044514656067], [32.0943523859244, 34.81043815612794], [32.09074798793366, 34.80904340744019], [32.09103925769882, 34.80406522750855]],
|
|
@@ -90,9 +84,8 @@ var areasArr = [{
|
|
|
90
84
|
}
|
|
91
85
|
}, {
|
|
92
86
|
title: 'Ca Degli Oppin',
|
|
93
|
-
percent: 0.1,
|
|
87
|
+
percent: -0.1,
|
|
94
88
|
factories: 5,
|
|
95
|
-
up: false,
|
|
96
89
|
locationLatLon: [32.0929012, 34.8072057],
|
|
97
90
|
status: 'medium',
|
|
98
91
|
points: [[32.09464364419881, 34.8044514656067], [32.0943523859244, 34.81043815612794], [32.09074798793366, 34.80904340744019], [32.09103925769882, 34.80406522750855]],
|
|
@@ -106,7 +99,6 @@ var areasArr = [{
|
|
|
106
99
|
title: 'North Industrial',
|
|
107
100
|
percent: 0.1,
|
|
108
101
|
factories: 2,
|
|
109
|
-
up: true,
|
|
110
102
|
locationLatLon: [32.0929012, 34.8072057],
|
|
111
103
|
status: 'none',
|
|
112
104
|
points: [[32.09464364419881, 34.8044514656067], [32.0943523859244, 34.81043815612794], [32.09074798793366, 34.80904340744019], [32.09103925769882, 34.80406522750855]],
|
|
@@ -120,7 +112,6 @@ var areasArr = [{
|
|
|
120
112
|
title: 'Vallese - indsutrial zon.',
|
|
121
113
|
percent: 0.1,
|
|
122
114
|
factories: 5,
|
|
123
|
-
up: true,
|
|
124
115
|
locationLatLon: [32.0929012, 34.8072057],
|
|
125
116
|
status: 'high',
|
|
126
117
|
points: [[32.09464364419881, 34.8044514656067], [32.0943523859244, 34.81043815612794], [32.09074798793366, 34.80904340744019], [32.09103925769882, 34.80406522750855]],
|
|
@@ -132,9 +123,8 @@ var areasArr = [{
|
|
|
132
123
|
}
|
|
133
124
|
}, {
|
|
134
125
|
title: 'South Industrial',
|
|
135
|
-
percent: 0.2,
|
|
126
|
+
percent: -0.2,
|
|
136
127
|
factories: 3,
|
|
137
|
-
up: true,
|
|
138
128
|
locationLatLon: [32.0929012, 34.8072057],
|
|
139
129
|
status: 'high',
|
|
140
130
|
points: [[32.09464364419881, 34.8044514656067], [32.0943523859244, 34.81043815612794], [32.09074798793366, 34.80904340744019], [32.09103925769882, 34.80406522750855]],
|
|
@@ -148,7 +138,6 @@ var areasArr = [{
|
|
|
148
138
|
title: 'North Industrial',
|
|
149
139
|
percent: 0.4,
|
|
150
140
|
factories: 2,
|
|
151
|
-
up: true,
|
|
152
141
|
locationLatLon: [32.0929012, 34.8072057],
|
|
153
142
|
status: 'medium',
|
|
154
143
|
points: [[32.09464364419881, 34.8044514656067], [32.0943523859244, 34.81043815612794], [32.09074798793366, 34.80904340744019], [32.09103925769882, 34.80406522750855]],
|
|
@@ -160,9 +149,8 @@ var areasArr = [{
|
|
|
160
149
|
}
|
|
161
150
|
}, {
|
|
162
151
|
title: 'Ca Degli Oppin',
|
|
163
|
-
percent: 0.3,
|
|
152
|
+
percent: -0.3,
|
|
164
153
|
factories: 2,
|
|
165
|
-
up: false,
|
|
166
154
|
locationLatLon: [32.0929012, 34.8072057],
|
|
167
155
|
status: 'high',
|
|
168
156
|
points: [[32.09464364419881, 34.8044514656067], [32.0943523859244, 34.81043815612794], [32.09074798793366, 34.80904340744019], [32.09103925769882, 34.80406522750855]],
|
|
@@ -174,9 +162,8 @@ var areasArr = [{
|
|
|
174
162
|
}
|
|
175
163
|
}, {
|
|
176
164
|
title: 'South Industrial',
|
|
177
|
-
percent: 0.2,
|
|
165
|
+
percent: -0.2,
|
|
178
166
|
factories: 3,
|
|
179
|
-
up: true,
|
|
180
167
|
locationLatLon: [32.0929012, 34.8072057],
|
|
181
168
|
status: 'high',
|
|
182
169
|
points: [[32.09464364419881, 34.8044514656067], [32.0943523859244, 34.81043815612794], [32.09074798793366, 34.80904340744019], [32.09103925769882, 34.80406522750855]],
|
|
@@ -190,7 +177,6 @@ var areasArr = [{
|
|
|
190
177
|
title: 'Ca Degli Oppin',
|
|
191
178
|
percent: 0.3,
|
|
192
179
|
factories: 2,
|
|
193
|
-
up: false,
|
|
194
180
|
locationLatLon: [32.0929012, 34.8072057],
|
|
195
181
|
status: 'medium',
|
|
196
182
|
points: [[32.09464364419881, 34.8044514656067], [32.0943523859244, 34.81043815612794], [32.09074798793366, 34.80904340744019], [32.09103925769882, 34.80406522750855]],
|
|
@@ -204,7 +190,6 @@ var areasArr = [{
|
|
|
204
190
|
title: 'Ca Degli Oppin',
|
|
205
191
|
percent: 0.1,
|
|
206
192
|
factories: 5,
|
|
207
|
-
up: false,
|
|
208
193
|
locationLatLon: [32.0929012, 34.8072057],
|
|
209
194
|
status: 'high',
|
|
210
195
|
points: [[32.09464364419881, 34.8044514656067], [32.0943523859244, 34.81043815612794], [32.09074798793366, 34.80904340744019], [32.09103925769882, 34.80406522750855]],
|
|
@@ -218,7 +203,6 @@ var areasArr = [{
|
|
|
218
203
|
title: 'North Industrial',
|
|
219
204
|
percent: 0.1,
|
|
220
205
|
factories: 2,
|
|
221
|
-
up: true,
|
|
222
206
|
locationLatLon: [32.0929012, 34.8072057],
|
|
223
207
|
status: 'high',
|
|
224
208
|
points: [[32.09464364419881, 34.8044514656067], [32.0943523859244, 34.81043815612794], [32.09074798793366, 34.80904340744019], [32.09103925769882, 34.80406522750855]],
|
|
@@ -232,7 +216,6 @@ var areasArr = [{
|
|
|
232
216
|
title: 'Vallese - indsutrial zon.',
|
|
233
217
|
percent: 0.1,
|
|
234
218
|
factories: 5,
|
|
235
|
-
up: true,
|
|
236
219
|
locationLatLon: [32.0929012, 34.8072057],
|
|
237
220
|
status: 'medium',
|
|
238
221
|
points: [[32.09464364419881, 34.8044514656067], [32.0943523859244, 34.81043815612794], [32.09074798793366, 34.80904340744019], [32.09103925769882, 34.80406522750855]],
|
|
@@ -244,9 +227,8 @@ var areasArr = [{
|
|
|
244
227
|
}
|
|
245
228
|
}, {
|
|
246
229
|
title: 'South Industrial',
|
|
247
|
-
percent: 0.2,
|
|
230
|
+
percent: -0.2,
|
|
248
231
|
factories: 3,
|
|
249
|
-
up: true,
|
|
250
232
|
locationLatLon: [32.0929012, 34.8072057],
|
|
251
233
|
status: 'high',
|
|
252
234
|
points: [[32.09464364419881, 34.8044514656067], [32.0943523859244, 34.81043815612794], [32.09074798793366, 34.80904340744019], [32.09103925769882, 34.80406522750855]],
|
|
@@ -260,7 +242,6 @@ var areasArr = [{
|
|
|
260
242
|
title: 'North Industrial',
|
|
261
243
|
percent: 0.4,
|
|
262
244
|
factories: 2,
|
|
263
|
-
up: true,
|
|
264
245
|
locationLatLon: [32.0929012, 34.8072057],
|
|
265
246
|
status: 'extreme',
|
|
266
247
|
points: [[32.09464364419881, 34.8044514656067], [32.0943523859244, 34.81043815612794], [32.09074798793366, 34.80904340744019], [32.09103925769882, 34.80406522750855]],
|
|
@@ -274,7 +255,6 @@ var areasArr = [{
|
|
|
274
255
|
title: 'Ca Degli Oppin',
|
|
275
256
|
percent: 0.3,
|
|
276
257
|
factories: 2,
|
|
277
|
-
up: false,
|
|
278
258
|
locationLatLon: [32.0929012, 34.8072057],
|
|
279
259
|
status: 'high',
|
|
280
260
|
points: [[32.09464364419881, 34.8044514656067], [32.0943523859244, 34.81043815612794], [32.09074798793366, 34.80904340744019], [32.09103925769882, 34.80406522750855]],
|
|
@@ -286,9 +266,8 @@ var areasArr = [{
|
|
|
286
266
|
}
|
|
287
267
|
}, {
|
|
288
268
|
title: 'South Industrial',
|
|
289
|
-
percent: 0.2,
|
|
269
|
+
percent: -0.2,
|
|
290
270
|
factories: 3,
|
|
291
|
-
up: true,
|
|
292
271
|
locationLatLon: [32.0929012, 34.8072057],
|
|
293
272
|
status: 'high',
|
|
294
273
|
points: [[32.09464364419881, 34.8044514656067], [32.0943523859244, 34.81043815612794], [32.09074798793366, 34.80904340744019], [32.09103925769882, 34.80406522750855]],
|
|
@@ -302,7 +281,6 @@ var areasArr = [{
|
|
|
302
281
|
title: 'Ca Degli Oppin',
|
|
303
282
|
percent: 0.3,
|
|
304
283
|
factories: 2,
|
|
305
|
-
up: false,
|
|
306
284
|
locationLatLon: [32.0929012, 34.8072057],
|
|
307
285
|
status: 'high',
|
|
308
286
|
points: [[32.09464364419881, 34.8044514656067], [32.0943523859244, 34.81043815612794], [32.09074798793366, 34.80904340744019], [32.09103925769882, 34.80406522750855]],
|
|
@@ -316,7 +294,6 @@ var areasArr = [{
|
|
|
316
294
|
title: 'Ca Degli Oppin',
|
|
317
295
|
percent: 0.1,
|
|
318
296
|
factories: 5,
|
|
319
|
-
up: false,
|
|
320
297
|
locationLatLon: [32.0929012, 34.8072057],
|
|
321
298
|
status: 'extreme',
|
|
322
299
|
points: [[32.09464364419881, 34.8044514656067], [32.0943523859244, 34.81043815612794], [32.09074798793366, 34.80904340744019], [32.09103925769882, 34.80406522750855]],
|
|
@@ -330,7 +307,6 @@ var areasArr = [{
|
|
|
330
307
|
title: 'North Industrial',
|
|
331
308
|
percent: 0.1,
|
|
332
309
|
factories: 2,
|
|
333
|
-
up: true,
|
|
334
310
|
locationLatLon: [32.0929012, 34.8072057],
|
|
335
311
|
status: 'extreme',
|
|
336
312
|
points: [[32.09464364419881, 34.8044514656067], [32.0943523859244, 34.81043815612794], [32.09074798793366, 34.80904340744019], [32.09103925769882, 34.80406522750855]],
|
package/lib/{EventsView/views/components → DashboardV2}/UtilityDashboard/mocks/factories.mock.js
RENAMED
|
@@ -8,7 +8,6 @@ var factoriesArr = [{
|
|
|
8
8
|
title: 'Factory 1',
|
|
9
9
|
percent: 0.3,
|
|
10
10
|
area: 'Vallese - indsutrial zon.',
|
|
11
|
-
up: false,
|
|
12
11
|
quality: {
|
|
13
12
|
extreme: 20,
|
|
14
13
|
high: 5,
|
|
@@ -20,7 +19,6 @@ var factoriesArr = [{
|
|
|
20
19
|
title: 'Factory 2',
|
|
21
20
|
percent: 0.4,
|
|
22
21
|
area: 'North Industrial',
|
|
23
|
-
up: true,
|
|
24
22
|
quality: {
|
|
25
23
|
extreme: 15,
|
|
26
24
|
high: 10,
|
|
@@ -30,9 +28,8 @@ var factoriesArr = [{
|
|
|
30
28
|
sector: 'metal'
|
|
31
29
|
}, {
|
|
32
30
|
title: 'Factory 3',
|
|
33
|
-
percent: 0.1,
|
|
31
|
+
percent: -0.1,
|
|
34
32
|
area: 'South Industrial',
|
|
35
|
-
up: false,
|
|
36
33
|
quality: {
|
|
37
34
|
extreme: 15,
|
|
38
35
|
high: 0,
|
|
@@ -44,7 +41,6 @@ var factoriesArr = [{
|
|
|
44
41
|
title: 'Factory 4',
|
|
45
42
|
percent: 0.5,
|
|
46
43
|
area: 'Co Degli Oppin',
|
|
47
|
-
up: true,
|
|
48
44
|
quality: {
|
|
49
45
|
extreme: 14,
|
|
50
46
|
high: 10,
|
|
@@ -56,7 +52,6 @@ var factoriesArr = [{
|
|
|
56
52
|
title: 'Factory 1',
|
|
57
53
|
percent: 0.3,
|
|
58
54
|
area: 'Vallese - indsutrial zon.',
|
|
59
|
-
up: false,
|
|
60
55
|
quality: {
|
|
61
56
|
extreme: 20,
|
|
62
57
|
high: 5,
|
|
@@ -66,9 +61,8 @@ var factoriesArr = [{
|
|
|
66
61
|
sector: 'shop'
|
|
67
62
|
}, {
|
|
68
63
|
title: 'Factory 2',
|
|
69
|
-
percent: 0.4,
|
|
64
|
+
percent: -0.4,
|
|
70
65
|
area: 'North Industrial',
|
|
71
|
-
up: true,
|
|
72
66
|
quality: {
|
|
73
67
|
extreme: 15,
|
|
74
68
|
high: 10,
|
|
@@ -80,7 +74,6 @@ var factoriesArr = [{
|
|
|
80
74
|
title: 'Factory 3',
|
|
81
75
|
percent: 0.1,
|
|
82
76
|
area: 'South Industrial',
|
|
83
|
-
up: false,
|
|
84
77
|
quality: {
|
|
85
78
|
extreme: 15,
|
|
86
79
|
high: 0,
|
|
@@ -92,7 +85,6 @@ var factoriesArr = [{
|
|
|
92
85
|
title: 'Factory 4',
|
|
93
86
|
percent: 0.5,
|
|
94
87
|
area: 'Co Degli Oppin',
|
|
95
|
-
up: true,
|
|
96
88
|
quality: {
|
|
97
89
|
extreme: 14,
|
|
98
90
|
high: 10,
|
|
@@ -102,9 +94,8 @@ var factoriesArr = [{
|
|
|
102
94
|
sector: 'gas'
|
|
103
95
|
}, {
|
|
104
96
|
title: 'Factory 1',
|
|
105
|
-
percent: 0.3,
|
|
97
|
+
percent: -0.3,
|
|
106
98
|
area: 'Vallese - indsutrial zon.',
|
|
107
|
-
up: false,
|
|
108
99
|
quality: {
|
|
109
100
|
extreme: 20,
|
|
110
101
|
high: 5,
|
|
@@ -116,7 +107,6 @@ var factoriesArr = [{
|
|
|
116
107
|
title: 'Factory 2',
|
|
117
108
|
percent: 0.4,
|
|
118
109
|
area: 'North Industrial',
|
|
119
|
-
up: true,
|
|
120
110
|
quality: {
|
|
121
111
|
extreme: 15,
|
|
122
112
|
high: 10,
|
|
@@ -128,7 +118,6 @@ var factoriesArr = [{
|
|
|
128
118
|
title: 'Factory 3',
|
|
129
119
|
percent: 0.1,
|
|
130
120
|
area: 'South Industrial',
|
|
131
|
-
up: false,
|
|
132
121
|
quality: {
|
|
133
122
|
extreme: 15,
|
|
134
123
|
high: 0,
|
|
@@ -138,9 +127,8 @@ var factoriesArr = [{
|
|
|
138
127
|
sector: 'leather'
|
|
139
128
|
}, {
|
|
140
129
|
title: 'Factory 4',
|
|
141
|
-
percent: 0.5,
|
|
130
|
+
percent: -0.5,
|
|
142
131
|
area: 'Co Degli Oppin',
|
|
143
|
-
up: true,
|
|
144
132
|
quality: {
|
|
145
133
|
extreme: 14,
|
|
146
134
|
high: 10,
|
|
@@ -11,12 +11,22 @@ exports.default = void 0;
|
|
|
11
11
|
|
|
12
12
|
var _react = _interopRequireWildcard(require("react"));
|
|
13
13
|
|
|
14
|
+
var _actions = require("../../../shared/redux/areas/actions");
|
|
15
|
+
|
|
16
|
+
var _actions2 = require("../../../shared/redux/events/actions");
|
|
17
|
+
|
|
18
|
+
var _actions3 = require("../../../shared/redux/edges/actions");
|
|
19
|
+
|
|
14
20
|
var _reactRedux = require("react-redux");
|
|
15
21
|
|
|
16
22
|
var _Map = _interopRequireDefault(require("./map/Map"));
|
|
17
23
|
|
|
24
|
+
var _actions4 = require("../../../shared/redux/global/actions");
|
|
25
|
+
|
|
18
26
|
var _ErrorBoundary = _interopRequireDefault(require("../../../shared/utilities/ErrorBoundary"));
|
|
19
27
|
|
|
28
|
+
var _rootActions = require("../../../shared/redux/rootActions");
|
|
29
|
+
|
|
20
30
|
var _Sidebar = _interopRequireDefault(require("./events/Sidebar"));
|
|
21
31
|
|
|
22
32
|
function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
|
|
@@ -36,35 +46,51 @@ var Body = function Body(props) {
|
|
|
36
46
|
var global_data = props.global_data;
|
|
37
47
|
var waterAuthorityId = props.global_data.waterAuthorityId;
|
|
38
48
|
var dispatch = (0, _reactRedux.useDispatch)();
|
|
39
|
-
(0, _react.useEffect)(function () {
|
|
40
|
-
//
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
49
|
+
(0, _react.useEffect)(function () {
|
|
50
|
+
// @ts-ignore
|
|
51
|
+
var Kando = window.KandoCable;
|
|
52
|
+
console.log("Kando", Kando);
|
|
53
|
+
Kando.cableConsumer.subscribe({
|
|
54
|
+
channel: 'AreasChannel',
|
|
55
|
+
water_authority_id: waterAuthorityId
|
|
56
|
+
}, function (data) {
|
|
57
|
+
dispatch((0, _actions.updateAreas)(data));
|
|
58
|
+
});
|
|
59
|
+
Kando.cableConsumer.subscribe({
|
|
60
|
+
channel: 'RollingEventsChannel',
|
|
61
|
+
water_authority_id: waterAuthorityId
|
|
62
|
+
}, function (event) {
|
|
63
|
+
if (event.destroyed) {
|
|
64
|
+
dispatch((0, _actions2.removeEvent)(event));
|
|
65
|
+
} else {
|
|
66
|
+
dispatch((0, _actions2.updateEvents)(event));
|
|
67
|
+
}
|
|
68
|
+
});
|
|
69
|
+
Kando.cableConsumer.subscribe({
|
|
70
|
+
channel: 'LinkedPointsChannel',
|
|
71
|
+
water_authority_id: waterAuthorityId
|
|
72
|
+
}, function (data) {
|
|
73
|
+
dispatch((0, _actions3.updateEdges)(data));
|
|
74
|
+
dispatch((0, _actions2.refreshCurrentTime)());
|
|
75
|
+
});
|
|
76
|
+
dispatch((0, _actions4.moreInfo)(false, {}));
|
|
77
|
+
dispatch((0, _actions4.setCurrentTime)(Date.now() / 1000 | 0));
|
|
78
|
+
return function cleanup() {
|
|
79
|
+
dispatch((0, _rootActions.resetStore)());
|
|
80
|
+
dispatch((0, _actions4.setCurrentTime)(0));
|
|
81
|
+
Kando.cableConsumer.unsubscribe({
|
|
82
|
+
channel: 'AreasChannel',
|
|
83
|
+
water_authority_id: waterAuthorityId
|
|
84
|
+
});
|
|
85
|
+
Kando.cableConsumer.unsubscribe({
|
|
86
|
+
channel: 'RollingEventsChannel',
|
|
87
|
+
water_authority_id: waterAuthorityId
|
|
88
|
+
});
|
|
89
|
+
Kando.cableConsumer.unsubscribe({
|
|
90
|
+
channel: 'LinkedPointsChannel',
|
|
91
|
+
water_authority_id: waterAuthorityId
|
|
92
|
+
});
|
|
93
|
+
};
|
|
68
94
|
}, [global_data.waterAuthorityId]);
|
|
69
95
|
return /*#__PURE__*/_react.default.createElement("div", null, /*#__PURE__*/_react.default.createElement(_ErrorBoundary.default, null, /*#__PURE__*/_react.default.createElement(_Sidebar.default, null), /*#__PURE__*/_react.default.createElement(_Map.default, null)));
|
|
70
96
|
};
|
|
@@ -84,6 +84,7 @@ var Map = function Map(props) {
|
|
|
84
84
|
setMapZoomLevel = _useState2[1];
|
|
85
85
|
|
|
86
86
|
var initializeMap = function initializeMap() {
|
|
87
|
+
// @ts-ignore
|
|
87
88
|
mapRef.current = _leaflet.default.map("map", {
|
|
88
89
|
center: [32.109333, 34.855499],
|
|
89
90
|
// Tel-Aviv
|
|
@@ -96,19 +97,23 @@ var Map = function Map(props) {
|
|
|
96
97
|
tileSize: 512,
|
|
97
98
|
zoomOffset: -1
|
|
98
99
|
})]
|
|
99
|
-
});
|
|
100
|
-
|
|
100
|
+
});
|
|
101
101
|
mapRef.current.whenReady(function () {
|
|
102
102
|
setTimeout(function () {
|
|
103
|
-
|
|
103
|
+
if (!mapRef.current) {
|
|
104
|
+
return;
|
|
105
|
+
}
|
|
106
|
+
|
|
104
107
|
mapRef.current.invalidateSize(true);
|
|
105
108
|
dispatch((0, _actions4.storeMap)(mapRef.current));
|
|
106
109
|
dispatch((0, _actions4.sideNavExpanded)(true));
|
|
107
110
|
}, 0);
|
|
108
|
-
});
|
|
109
|
-
|
|
111
|
+
});
|
|
110
112
|
mapRef.current.on("zoomend", function (e) {
|
|
111
|
-
|
|
113
|
+
if (!mapRef.current) {
|
|
114
|
+
return;
|
|
115
|
+
}
|
|
116
|
+
|
|
112
117
|
var zoom = mapRef.current.getZoom();
|
|
113
118
|
console.log("ZOOMEND: " + zoom);
|
|
114
119
|
setMapZoomLevel(zoom);
|
|
@@ -19,39 +19,39 @@ var _useRemoveExistingLayers = _interopRequireWildcard(require("../../../../shar
|
|
|
19
19
|
|
|
20
20
|
var _i18n = _interopRequireDefault(require("../../../../shared/utilities/i18n"));
|
|
21
21
|
|
|
22
|
-
var _lineChart = _interopRequireDefault(require("../../../../assets/
|
|
22
|
+
var _lineChart = _interopRequireDefault(require("../../../../assets/line-chart.svg"));
|
|
23
23
|
|
|
24
24
|
var _jquery = _interopRequireDefault(require("jquery"));
|
|
25
25
|
|
|
26
26
|
var _actions = require("../../../../shared/redux/global/actions");
|
|
27
27
|
|
|
28
|
-
var _whitePoint = _interopRequireDefault(require("../../../../assets/
|
|
28
|
+
var _whitePoint = _interopRequireDefault(require("../../../../assets/white-point.png"));
|
|
29
29
|
|
|
30
|
-
var _whitePinRedShadow = _interopRequireDefault(require("../../../../assets/
|
|
30
|
+
var _whitePinRedShadow = _interopRequireDefault(require("../../../../assets/point_icons/white-pin-red-shadow.png"));
|
|
31
31
|
|
|
32
|
-
var _whitePinBlackShadow = _interopRequireDefault(require("../../../../assets/
|
|
32
|
+
var _whitePinBlackShadow = _interopRequireDefault(require("../../../../assets/point_icons/white-pin-black-shadow.png"));
|
|
33
33
|
|
|
34
|
-
var _redPinRedShadow = _interopRequireDefault(require("../../../../assets/
|
|
34
|
+
var _redPinRedShadow = _interopRequireDefault(require("../../../../assets/point_icons/red-pin-red-shadow.png"));
|
|
35
35
|
|
|
36
|
-
var _yellowCircle = _interopRequireDefault(require("../../../../assets/
|
|
36
|
+
var _yellowCircle = _interopRequireDefault(require("../../../../assets/point_icons/yellow-circle.svg"));
|
|
37
37
|
|
|
38
|
-
var _brightBlueCircle = _interopRequireDefault(require("../../../../assets/
|
|
38
|
+
var _brightBlueCircle = _interopRequireDefault(require("../../../../assets/point_icons/bright-blue-circle.svg"));
|
|
39
39
|
|
|
40
|
-
var _greenCircle = _interopRequireDefault(require("../../../../assets/
|
|
40
|
+
var _greenCircle = _interopRequireDefault(require("../../../../assets/point_icons/green-circle.svg"));
|
|
41
41
|
|
|
42
|
-
var _pinkCircle = _interopRequireDefault(require("../../../../assets/
|
|
42
|
+
var _pinkCircle = _interopRequireDefault(require("../../../../assets/point_icons/pink-circle.svg"));
|
|
43
43
|
|
|
44
|
-
var _blueCircle = _interopRequireDefault(require("../../../../assets/
|
|
44
|
+
var _blueCircle = _interopRequireDefault(require("../../../../assets/point_icons/blue-circle.svg"));
|
|
45
45
|
|
|
46
|
-
var _WWTPIcon = _interopRequireDefault(require("../../../../assets/
|
|
46
|
+
var _WWTPIcon = _interopRequireDefault(require("../../../../assets/point_icons/WWTP-icon.svg"));
|
|
47
47
|
|
|
48
|
-
var _factoryIcon = _interopRequireDefault(require("../../../../assets/
|
|
48
|
+
var _factoryIcon = _interopRequireDefault(require("../../../../assets/point_icons/factory-icon.svg"));
|
|
49
49
|
|
|
50
|
-
var _pumpStationIcon = _interopRequireDefault(require("../../../../assets/
|
|
50
|
+
var _pumpStationIcon = _interopRequireDefault(require("../../../../assets/point_icons/pump-station-icon.svg"));
|
|
51
51
|
|
|
52
|
-
var _observationIcon = _interopRequireDefault(require("../../../../assets/
|
|
52
|
+
var _observationIcon = _interopRequireDefault(require("../../../../assets/point_icons/observation-icon.svg"));
|
|
53
53
|
|
|
54
|
-
var _samplingIcon = _interopRequireDefault(require("../../../../assets/
|
|
54
|
+
var _samplingIcon = _interopRequireDefault(require("../../../../assets/point_icons/sampling-icon.svg"));
|
|
55
55
|
|
|
56
56
|
var _DamageType = _interopRequireDefault(require("../events/event_info/damage_type/DamageType"));
|
|
57
57
|
|