@eeacms/volto-arcgis-block 0.1.87 → 0.1.89
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/CHANGELOG.md
CHANGED
|
@@ -4,6 +4,14 @@ All notable changes to this project will be documented in this file. Dates are d
|
|
|
4
4
|
|
|
5
5
|
Generated by [`auto-changelog`](https://github.com/CookPete/auto-changelog).
|
|
6
6
|
|
|
7
|
+
### [0.1.89](https://github.com/eea/volto-arcgis-block/compare/0.1.88...0.1.89) - 19 January 2023
|
|
8
|
+
|
|
9
|
+
### [0.1.88](https://github.com/eea/volto-arcgis-block/compare/0.1.87...0.1.88) - 17 January 2023
|
|
10
|
+
|
|
11
|
+
#### :hammer_and_wrench: Others
|
|
12
|
+
|
|
13
|
+
- lint [masanchez85 - [`047ec22`](https://github.com/eea/volto-arcgis-block/commit/047ec22ce5a4f69283c37030a4d0f7794f9f089e)]
|
|
14
|
+
- Code fixes [masanchez85 - [`01c9eda`](https://github.com/eea/volto-arcgis-block/commit/01c9eda63016c26eba1b9f7bfc7760b7bea92199)]
|
|
7
15
|
### [0.1.87](https://github.com/eea/volto-arcgis-block/compare/0.1.86...0.1.87) - 12 January 2023
|
|
8
16
|
|
|
9
17
|
### [0.1.86](https://github.com/eea/volto-arcgis-block/compare/0.1.85...0.1.86) - 11 January 2023
|
package/package.json
CHANGED
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import React, { createRef } from 'react';
|
|
2
2
|
import { loadModules } from 'esri-loader';
|
|
3
|
+
import { FontAwesomeIcon } from '@fortawesome/react-fontawesome';
|
|
3
4
|
|
|
4
5
|
var Graphic,
|
|
5
6
|
Extent,
|
|
@@ -22,7 +23,10 @@ class AreaWidget extends React.Component {
|
|
|
22
23
|
: createRef();
|
|
23
24
|
//Initially, we set the state of the component to
|
|
24
25
|
//not be showing the basemap panel
|
|
25
|
-
this.state = {
|
|
26
|
+
this.state = {
|
|
27
|
+
showMapMenu: false,
|
|
28
|
+
showInfoPopup: false,
|
|
29
|
+
};
|
|
26
30
|
this.menuClass =
|
|
27
31
|
'esri-icon-cursor-marquee esri-widget--button esri-widget esri-interactive';
|
|
28
32
|
// Enable defaultPopup option to charge popup and highlifght feature
|
|
@@ -164,6 +168,9 @@ class AreaWidget extends React.Component {
|
|
|
164
168
|
if (e.action === 'start') {
|
|
165
169
|
if (extentGraphic) this.props.view.graphics.remove(extentGraphic);
|
|
166
170
|
origin = this.props.view.toMap(e);
|
|
171
|
+
this.setState({
|
|
172
|
+
showInfoPopup: true,
|
|
173
|
+
});
|
|
167
174
|
} else if (e.action === 'update') {
|
|
168
175
|
if (extentGraphic) this.props.view.graphics.remove(extentGraphic);
|
|
169
176
|
let p = this.props.view.toMap(e);
|
|
@@ -184,7 +191,9 @@ class AreaWidget extends React.Component {
|
|
|
184
191
|
this.props.view.graphics.add(extentGraphic);
|
|
185
192
|
}
|
|
186
193
|
});
|
|
187
|
-
this.setState({
|
|
194
|
+
this.setState({
|
|
195
|
+
ShowGraphics: drawGraphics,
|
|
196
|
+
});
|
|
188
197
|
}
|
|
189
198
|
clearWidget() {
|
|
190
199
|
this.props.mapViewer.view.popup.close();
|
|
@@ -196,6 +205,9 @@ class AreaWidget extends React.Component {
|
|
|
196
205
|
this.nutsGroupLayer.removeAll();
|
|
197
206
|
this.props.view.graphics.removeAll();
|
|
198
207
|
this.props.updateArea();
|
|
208
|
+
this.setState({
|
|
209
|
+
showInfoPopup: false,
|
|
210
|
+
});
|
|
199
211
|
}
|
|
200
212
|
/**
|
|
201
213
|
* This method is executed after the rener method is executed
|
|
@@ -389,6 +401,21 @@ class AreaWidget extends React.Component {
|
|
|
389
401
|
</div>
|
|
390
402
|
</div>
|
|
391
403
|
</div>
|
|
404
|
+
{this.state.showInfoPopup && (
|
|
405
|
+
<div className="map-container">
|
|
406
|
+
<div className="drawRectanglePopup-block">
|
|
407
|
+
<div className="drawRectanglePopup-content">
|
|
408
|
+
<span className="drawRectanglePopup-icon">
|
|
409
|
+
<FontAwesomeIcon icon={['fas', 'download']} />
|
|
410
|
+
</span>
|
|
411
|
+
<div className="drawRectanglePopup-text">
|
|
412
|
+
Click on the download icon of the "Menu of products" to
|
|
413
|
+
download the dataset
|
|
414
|
+
</div>
|
|
415
|
+
</div>
|
|
416
|
+
</div>
|
|
417
|
+
</div>
|
|
418
|
+
)}
|
|
392
419
|
</div>
|
|
393
420
|
</>
|
|
394
421
|
);
|
|
@@ -34,7 +34,6 @@ export const AddCartItem = ({
|
|
|
34
34
|
const [message, setMessage] = useState(0);
|
|
35
35
|
const [showMessage] = useState(false);
|
|
36
36
|
const [modal, setModal] = useState(false);
|
|
37
|
-
const [loginUrl] = React.useState('');
|
|
38
37
|
|
|
39
38
|
const checkArea = (e) => {
|
|
40
39
|
let check = document.querySelector('.area-panel input:checked').value;
|
|
@@ -257,7 +256,7 @@ export const AddCartItem = ({
|
|
|
257
256
|
<br></br>
|
|
258
257
|
<li>
|
|
259
258
|
<p>
|
|
260
|
-
If you
|
|
259
|
+
If you want to download the full dataset, click{' '}
|
|
261
260
|
<UniversalLink
|
|
262
261
|
openLinkInNewTab
|
|
263
262
|
href="https://clms-prod.eea.europa.eu/en/how-to-guides/how-to-download-spatial-data/how-to-download-m2m"
|
|
@@ -362,88 +361,17 @@ export const AddCartItem = ({
|
|
|
362
361
|
) : (
|
|
363
362
|
// If isLoggedIn == false and user clicks download
|
|
364
363
|
<>
|
|
365
|
-
<Modal
|
|
366
|
-
size="tiny"
|
|
367
|
-
onClose={() => closeModal()}
|
|
368
|
-
onOpen={() => showModal()}
|
|
369
|
-
open={modal}
|
|
370
|
-
className="modal-clms-container"
|
|
371
|
-
>
|
|
372
|
-
<div className="modal-close modal-clms-close">
|
|
373
|
-
<span
|
|
374
|
-
className="ccl-icon-close"
|
|
375
|
-
aria-label="Close"
|
|
376
|
-
onClick={(e) => closeModal(e)}
|
|
377
|
-
onKeyDown={(e) => closeModal(e)}
|
|
378
|
-
tabIndex="0"
|
|
379
|
-
role="button"
|
|
380
|
-
></span>
|
|
381
|
-
</div>
|
|
382
|
-
<Modal.Content>
|
|
383
|
-
<div className="content">
|
|
384
|
-
<div className="modal-login-title">
|
|
385
|
-
This website uses EU Login for user authentication.
|
|
386
|
-
</div>
|
|
387
|
-
<div className="modal-login-text">
|
|
388
|
-
<p>
|
|
389
|
-
{' '}
|
|
390
|
-
EU Login, the European Commission Authentication Service,
|
|
391
|
-
enables you to access various web applications centrally
|
|
392
|
-
using the same e-mail and password. You can read more{' '}
|
|
393
|
-
<UniversalLink
|
|
394
|
-
openLinkInNewTab
|
|
395
|
-
href="https://ecas.ec.europa.eu/cas/about.html"
|
|
396
|
-
>
|
|
397
|
-
here
|
|
398
|
-
</UniversalLink>
|
|
399
|
-
.
|
|
400
|
-
</p>
|
|
401
|
-
<p>
|
|
402
|
-
{' '}
|
|
403
|
-
If you have EU Login account, please click 'Login using EU
|
|
404
|
-
Login'.
|
|
405
|
-
</p>
|
|
406
|
-
<p>
|
|
407
|
-
If you don't have EU Login account, please follow this{' '}
|
|
408
|
-
<UniversalLink
|
|
409
|
-
openLinkInNewTab
|
|
410
|
-
href="https://ecas.ec.europa.eu/cas/eim/external/register.cgi"
|
|
411
|
-
>
|
|
412
|
-
link
|
|
413
|
-
</UniversalLink>{' '}
|
|
414
|
-
to create it.
|
|
415
|
-
</p>
|
|
416
|
-
<p>
|
|
417
|
-
If you have other questions, please contact our
|
|
418
|
-
<UniversalLink openLinkInNewTab href="/en/service-desk">
|
|
419
|
-
{' '}
|
|
420
|
-
Service desk
|
|
421
|
-
</UniversalLink>
|
|
422
|
-
.
|
|
423
|
-
</p>
|
|
424
|
-
</div>
|
|
425
|
-
</div>
|
|
426
|
-
</Modal.Content>
|
|
427
|
-
<Modal.Actions>
|
|
428
|
-
<div className="modal-buttons">
|
|
429
|
-
<a
|
|
430
|
-
href={loginUrl || '#'}
|
|
431
|
-
className="ccl-button ccl-button-green"
|
|
432
|
-
>
|
|
433
|
-
Login using EU Login
|
|
434
|
-
</a>
|
|
435
|
-
</div>
|
|
436
|
-
</Modal.Actions>
|
|
437
|
-
</Modal>
|
|
438
364
|
<Popup
|
|
439
365
|
trigger={
|
|
440
366
|
<span
|
|
441
367
|
className={'map-menu-icon map-menu-icon-login'}
|
|
442
368
|
onClick={(e) => {
|
|
443
|
-
showModal(e);
|
|
369
|
+
//showModal(e);
|
|
370
|
+
document.querySelector('.header-login-link').click();
|
|
444
371
|
}}
|
|
445
372
|
onKeyDown={(e) => {
|
|
446
|
-
showModal(e);
|
|
373
|
+
//showModal(e);
|
|
374
|
+
document.querySelector('.header-login-link').click();
|
|
447
375
|
}}
|
|
448
376
|
tabIndex="0"
|
|
449
377
|
role="button"
|
|
@@ -1123,3 +1123,35 @@ input[type='range']::-ms-track {
|
|
|
1123
1123
|
color: #a0b128 !important;
|
|
1124
1124
|
content: '\e800';
|
|
1125
1125
|
}
|
|
1126
|
+
|
|
1127
|
+
/*Draw rectangle popup*/
|
|
1128
|
+
|
|
1129
|
+
.drawRectanglePopup-content {
|
|
1130
|
+
/*margin-right: calc(100vw - 250px);
|
|
1131
|
+
margin-top: -8rem;*/
|
|
1132
|
+
position: absolute;
|
|
1133
|
+
display: flex;
|
|
1134
|
+
width: 19rem;
|
|
1135
|
+
height: 60px;
|
|
1136
|
+
justify-content: space-between;
|
|
1137
|
+
padding: 0.6rem 0.8rem 0.8rem 0.8rem;
|
|
1138
|
+
background-color: white;
|
|
1139
|
+
transform: translate(-34vw, -214%);
|
|
1140
|
+
}
|
|
1141
|
+
|
|
1142
|
+
.drawRectanglePopup-content .drawRectanglePopup-icon {
|
|
1143
|
+
margin-top: 0.6rem;
|
|
1144
|
+
margin-right: 0.6rem;
|
|
1145
|
+
color: #a0b128;
|
|
1146
|
+
font-size: 1rem;
|
|
1147
|
+
text-decoration: none;
|
|
1148
|
+
}
|
|
1149
|
+
|
|
1150
|
+
/*.drawRectanglePopup-icon .svg{
|
|
1151
|
+
margin-top: 0.6rem;
|
|
1152
|
+
}*/
|
|
1153
|
+
|
|
1154
|
+
.drawRectanglePopup-text {
|
|
1155
|
+
font-family: 'Lato', sans-serif;
|
|
1156
|
+
font-size: 0.875rem;
|
|
1157
|
+
}
|