@opengeoweb/sigmet-airmet 2.1.2 → 2.2.0
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/assets/icons.d.ts +1 -1
- package/{sigmet-airmet.esm.js → index.esm.js} +347 -308
- package/{sigmet-airmet.umd.js → index.umd.js} +582 -538
- package/lib/components/ContentDialog/ContentDialog.d.ts +1 -1
- package/lib/components/ProductForms/ProductForm.styles.d.ts +1 -1
- package/lib/utils/testUtils.d.ts +4 -0
- package/package.json +17 -18
|
@@ -1,19 +1,19 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
2
|
import React__default from 'react';
|
|
3
|
-
import {
|
|
3
|
+
import { FormControlLabel, Radio, Grid, Typography, SvgIcon, Tooltip, Button, Checkbox, MenuItem, FormHelperText, Dialog, DialogTitle, DialogContent, Card, CardContent, List, ListItem, Skeleton, Backdrop, CircularProgress } from '@mui/material';
|
|
4
4
|
import { useFormContext } from 'react-hook-form';
|
|
5
5
|
import { ReactHookFormRadioGroup, ReactHookFormSelect, ReactHookFormNumberField, isInteger, isValidMax, isValidMin, isEmpty, ReactHookFormDateTime, isValidDate, isBefore, isBetween, hasMaxFeaturePoints, hasMulitpleIntersections, ReactHookFormHiddenInput, isMaximumOneDrawing, hasIntersectionWithFIR, isValidGeoJsonCoordinates, isXHoursBefore, isAfter, isXHoursAfter, ReactHookFormTextField, containsNoCommas, isLatitude, isNonOrBothCoordinates, isLongitude, errorMessages, isGeometryDirty, ReactHookFormProvider, defaultFormOptions } from '@opengeoweb/form-fields';
|
|
6
6
|
import { useApiContext, useApi, createApiInstance } from '@opengeoweb/api';
|
|
7
7
|
import produce, { produce as produce$1 } from 'immer';
|
|
8
8
|
import { useDispatch, useSelector, shallowEqual } from 'react-redux';
|
|
9
|
-
import { mapTypes, mapSelectors, generateMapId, generateTimesliderId, SyncGroups, generateLayerId, mapActions, publicLayers, MapControls, LayerManagerMapButtonConnect, MapViewConnect, MapViewLayer, TimeSliderConnect } from '@opengeoweb/core';
|
|
9
|
+
import { mapTypes, mapSelectors, generateMapId, generateTimesliderId, SyncGroups, generateLayerId, mapActions, publicLayers, MapControls, LayerManagerMapButtonConnect, LegendMapButtonConnect, MultiDimensionSelectMapButtonsConnect, MapViewConnect, MapViewLayer, TimeSliderConnect } from '@opengeoweb/core';
|
|
10
10
|
import * as turf from '@turf/turf';
|
|
11
11
|
import { polygonToLineString, booleanClockwise, rewind } from '@turf/turf';
|
|
12
|
+
import makeStyles from '@mui/styles/makeStyles';
|
|
12
13
|
import { useDraftFormHelpers, useIsMounted, StatusTag, AlertBanner, usePreventBrowserClose, useConfirmationDialog, isAxiosError, getAxiosErrorMessage, ConfirmationServiceProvider, usePoller } from '@opengeoweb/shared';
|
|
13
|
-
import { LocationOn, Delete, ArrowBackIos, InfoOutlined, Create, CheckCircle, Schedule } from '@
|
|
14
|
+
import { LocationOn, Delete, ArrowBackIos, InfoOutlined, Create, CheckCircle, Schedule } from '@mui/icons-material';
|
|
14
15
|
import moment from 'moment';
|
|
15
16
|
import { debounce } from 'lodash';
|
|
16
|
-
import { Skeleton } from '@material-ui/lab';
|
|
17
17
|
|
|
18
18
|
function _typeof(obj) {
|
|
19
19
|
"@babel/helpers - typeof";
|
|
@@ -450,20 +450,20 @@ var StartOrEndDrawing;
|
|
|
450
450
|
* Copyright 2021 - Finnish Meteorological Institute (FMI)
|
|
451
451
|
* */
|
|
452
452
|
var adagucBaseUrl = 'https://adaguc-server-geoweb.geoweb.knmi.cloud/adagucserver';
|
|
453
|
-
var
|
|
454
|
-
name: '
|
|
455
|
-
url: "".concat(adagucBaseUrl, "?dataset=OVL
|
|
456
|
-
id: '
|
|
453
|
+
var KNMIGeoWebOverlays = {
|
|
454
|
+
name: 'KNMIGeoWebOverlays',
|
|
455
|
+
url: "".concat(adagucBaseUrl, "?dataset=OVL"),
|
|
456
|
+
id: 'knmigeoweboverlays'
|
|
457
457
|
};
|
|
458
458
|
var northSeaPlatforms = {
|
|
459
|
-
service:
|
|
459
|
+
service: KNMIGeoWebOverlays.url,
|
|
460
460
|
name: 'northseastations',
|
|
461
461
|
format: 'image/png',
|
|
462
462
|
layerType: mapTypes.LayerType.overLayer,
|
|
463
463
|
enabled: true
|
|
464
464
|
};
|
|
465
465
|
var majorAirportsEHAA = {
|
|
466
|
-
service:
|
|
466
|
+
service: KNMIGeoWebOverlays.url,
|
|
467
467
|
name: 'airports',
|
|
468
468
|
format: 'image/png',
|
|
469
469
|
layerType: mapTypes.LayerType.overLayer,
|
|
@@ -601,6 +601,12 @@ var MapViewGeoJson = function MapViewGeoJson(_ref) {
|
|
|
601
601
|
}, /*#__PURE__*/React.createElement(MapControls, null, /*#__PURE__*/React.createElement(LayerManagerMapButtonConnect, {
|
|
602
602
|
source: "module",
|
|
603
603
|
mapId: mapId
|
|
604
|
+
}), /*#__PURE__*/React.createElement(LegendMapButtonConnect, {
|
|
605
|
+
source: "module",
|
|
606
|
+
mapId: mapId
|
|
607
|
+
}), /*#__PURE__*/React.createElement(MultiDimensionSelectMapButtonsConnect, {
|
|
608
|
+
source: "module",
|
|
609
|
+
mapId: mapId
|
|
604
610
|
})), /*#__PURE__*/React.createElement(MapViewConnect, {
|
|
605
611
|
mapId: mapId
|
|
606
612
|
}, /*#__PURE__*/React.createElement(MapViewLayer, {
|
|
@@ -1122,6 +1128,9 @@ var useStyles$6 = makeStyles({
|
|
|
1122
1128
|
body: {
|
|
1123
1129
|
paddingTop: '17px'
|
|
1124
1130
|
},
|
|
1131
|
+
containerItem: {
|
|
1132
|
+
paddingTop: '8px'
|
|
1133
|
+
},
|
|
1125
1134
|
volcanicField: {
|
|
1126
1135
|
marginBottom: 16
|
|
1127
1136
|
},
|
|
@@ -1148,7 +1157,7 @@ var useStyles$6 = makeStyles({
|
|
|
1148
1157
|
opacity: '1'
|
|
1149
1158
|
},
|
|
1150
1159
|
drawSection: {
|
|
1151
|
-
|
|
1160
|
+
padding: '10px 0px'
|
|
1152
1161
|
}
|
|
1153
1162
|
});
|
|
1154
1163
|
|
|
@@ -1242,12 +1251,13 @@ var Change = function Change(_ref) {
|
|
|
1242
1251
|
return /*#__PURE__*/React__default.createElement(Grid, {
|
|
1243
1252
|
item: true,
|
|
1244
1253
|
container: true,
|
|
1245
|
-
spacing: 2
|
|
1254
|
+
spacing: 2,
|
|
1255
|
+
className: classes.containerItem
|
|
1246
1256
|
}, /*#__PURE__*/React__default.createElement(Grid, {
|
|
1247
1257
|
item: true,
|
|
1248
1258
|
xs: 4,
|
|
1249
1259
|
container: true,
|
|
1250
|
-
|
|
1260
|
+
justifyContent: "flex-end"
|
|
1251
1261
|
}, /*#__PURE__*/React__default.createElement(Typography, {
|
|
1252
1262
|
variant: "subtitle1",
|
|
1253
1263
|
className: classes.label
|
|
@@ -1255,7 +1265,7 @@ var Change = function Change(_ref) {
|
|
|
1255
1265
|
item: true,
|
|
1256
1266
|
xs: 8,
|
|
1257
1267
|
container: true,
|
|
1258
|
-
|
|
1268
|
+
justifyContent: "flex-start"
|
|
1259
1269
|
}, /*#__PURE__*/React__default.createElement(Grid, {
|
|
1260
1270
|
item: true,
|
|
1261
1271
|
xs: 12
|
|
@@ -1373,7 +1383,7 @@ var DrawTools = function DrawTools(_ref) {
|
|
|
1373
1383
|
item: true,
|
|
1374
1384
|
xs: 12,
|
|
1375
1385
|
container: true,
|
|
1376
|
-
|
|
1386
|
+
justifyContent: "space-between",
|
|
1377
1387
|
"data-testid": "drawtools"
|
|
1378
1388
|
}, /*#__PURE__*/React__default.createElement(Grid, {
|
|
1379
1389
|
item: true
|
|
@@ -1668,7 +1678,7 @@ var getProductFormLifecycleButtons = function getProductFormLifecycleButtons(can
|
|
|
1668
1678
|
return /*#__PURE__*/React.createElement(Grid, {
|
|
1669
1679
|
container: true,
|
|
1670
1680
|
spacing: 1,
|
|
1671
|
-
|
|
1681
|
+
justifyContent: "flex-end"
|
|
1672
1682
|
}, canBe.includes('DISCARDED') && /*#__PURE__*/React.createElement(Grid, {
|
|
1673
1683
|
item: true
|
|
1674
1684
|
}, /*#__PURE__*/React.createElement(Button, {
|
|
@@ -1993,12 +2003,13 @@ var Levels = function Levels(_ref) {
|
|
|
1993
2003
|
return /*#__PURE__*/React__default.createElement(Grid, {
|
|
1994
2004
|
item: true,
|
|
1995
2005
|
container: true,
|
|
1996
|
-
spacing: 2
|
|
2006
|
+
spacing: 2,
|
|
2007
|
+
className: classes.containerItem
|
|
1997
2008
|
}, /*#__PURE__*/React__default.createElement(Grid, {
|
|
1998
2009
|
item: true,
|
|
1999
2010
|
xs: 4,
|
|
2000
2011
|
container: true,
|
|
2001
|
-
|
|
2012
|
+
justifyContent: "flex-end"
|
|
2002
2013
|
}, /*#__PURE__*/React__default.createElement(Typography, {
|
|
2003
2014
|
variant: "subtitle1",
|
|
2004
2015
|
className: classes.label
|
|
@@ -2006,7 +2017,7 @@ var Levels = function Levels(_ref) {
|
|
|
2006
2017
|
item: true,
|
|
2007
2018
|
xs: 8,
|
|
2008
2019
|
container: true,
|
|
2009
|
-
|
|
2020
|
+
justifyContent: "flex-start"
|
|
2010
2021
|
}, /*#__PURE__*/React__default.createElement(Grid, {
|
|
2011
2022
|
item: true,
|
|
2012
2023
|
xs: 12
|
|
@@ -2402,12 +2413,12 @@ var ObservationForecast = function ObservationForecast(_ref) {
|
|
|
2402
2413
|
item: true,
|
|
2403
2414
|
xs: 4,
|
|
2404
2415
|
container: true,
|
|
2405
|
-
|
|
2416
|
+
justifyContent: "flex-end"
|
|
2406
2417
|
}), /*#__PURE__*/React__default.createElement(Grid, {
|
|
2407
2418
|
item: true,
|
|
2408
2419
|
xs: 8,
|
|
2409
2420
|
container: true,
|
|
2410
|
-
|
|
2421
|
+
justifyContent: "flex-start"
|
|
2411
2422
|
}, /*#__PURE__*/React__default.createElement(ReactHookFormRadioGroup, {
|
|
2412
2423
|
name: "isObservationOrForecast",
|
|
2413
2424
|
disabled: isDisabled,
|
|
@@ -2473,7 +2484,7 @@ var ObservationForecastTime = function ObservationForecastTime(_ref) {
|
|
|
2473
2484
|
item: true,
|
|
2474
2485
|
xs: 4,
|
|
2475
2486
|
container: true,
|
|
2476
|
-
|
|
2487
|
+
justifyContent: "flex-end"
|
|
2477
2488
|
}, /*#__PURE__*/React__default.createElement(Typography, {
|
|
2478
2489
|
variant: "subtitle1",
|
|
2479
2490
|
className: classes.label
|
|
@@ -2481,7 +2492,7 @@ var ObservationForecastTime = function ObservationForecastTime(_ref) {
|
|
|
2481
2492
|
item: true,
|
|
2482
2493
|
xs: 8,
|
|
2483
2494
|
container: true,
|
|
2484
|
-
|
|
2495
|
+
justifyContent: "flex-start"
|
|
2485
2496
|
}, /*#__PURE__*/React__default.createElement(ReactHookFormDateTime, {
|
|
2486
2497
|
disablePast: watch('isObservationOrForecast') === 'FCST',
|
|
2487
2498
|
disableFuture: watch('isObservationOrForecast') === 'OBS',
|
|
@@ -2526,7 +2537,7 @@ var Phenomenon = function Phenomenon(_ref) {
|
|
|
2526
2537
|
item: true,
|
|
2527
2538
|
xs: 4,
|
|
2528
2539
|
container: true,
|
|
2529
|
-
|
|
2540
|
+
justifyContent: "flex-end"
|
|
2530
2541
|
}, /*#__PURE__*/React__default.createElement(Typography, {
|
|
2531
2542
|
variant: "subtitle1",
|
|
2532
2543
|
className: classes.label
|
|
@@ -2534,7 +2545,7 @@ var Phenomenon = function Phenomenon(_ref) {
|
|
|
2534
2545
|
item: true,
|
|
2535
2546
|
xs: 8,
|
|
2536
2547
|
container: true,
|
|
2537
|
-
|
|
2548
|
+
justifyContent: "flex-start"
|
|
2538
2549
|
}, /*#__PURE__*/React__default.createElement(ReactHookFormSelect, {
|
|
2539
2550
|
name: "phenomenon",
|
|
2540
2551
|
label: "Select phenomenon",
|
|
@@ -2618,7 +2629,7 @@ var StartGeometry = function StartGeometry(_ref) {
|
|
|
2618
2629
|
item: true,
|
|
2619
2630
|
xs: 4,
|
|
2620
2631
|
container: true,
|
|
2621
|
-
|
|
2632
|
+
justifyContent: "flex-end"
|
|
2622
2633
|
}, /*#__PURE__*/React__default.createElement(Typography, {
|
|
2623
2634
|
variant: "subtitle1",
|
|
2624
2635
|
className: classes.label
|
|
@@ -2766,12 +2777,13 @@ var Progress = function Progress(_ref) {
|
|
|
2766
2777
|
return /*#__PURE__*/React__default.createElement(Grid, {
|
|
2767
2778
|
item: true,
|
|
2768
2779
|
container: true,
|
|
2769
|
-
spacing: 2
|
|
2780
|
+
spacing: 2,
|
|
2781
|
+
className: classes.containerItem
|
|
2770
2782
|
}, /*#__PURE__*/React__default.createElement(Grid, {
|
|
2771
2783
|
item: true,
|
|
2772
2784
|
xs: 4,
|
|
2773
2785
|
container: true,
|
|
2774
|
-
|
|
2786
|
+
justifyContent: "flex-end"
|
|
2775
2787
|
}, /*#__PURE__*/React__default.createElement(Typography, {
|
|
2776
2788
|
variant: "subtitle1",
|
|
2777
2789
|
className: classes.label
|
|
@@ -2779,7 +2791,7 @@ var Progress = function Progress(_ref) {
|
|
|
2779
2791
|
item: true,
|
|
2780
2792
|
xs: 8,
|
|
2781
2793
|
container: true,
|
|
2782
|
-
|
|
2794
|
+
justifyContent: "flex-start"
|
|
2783
2795
|
}, /*#__PURE__*/React__default.createElement(Grid, {
|
|
2784
2796
|
item: true,
|
|
2785
2797
|
xs: 12
|
|
@@ -2985,12 +2997,13 @@ var SelectFIR = function SelectFIR(_ref) {
|
|
|
2985
2997
|
return /*#__PURE__*/React__default.createElement(Grid, {
|
|
2986
2998
|
item: true,
|
|
2987
2999
|
container: true,
|
|
2988
|
-
spacing: 2
|
|
3000
|
+
spacing: 2,
|
|
3001
|
+
className: classes.containerItem
|
|
2989
3002
|
}, /*#__PURE__*/React__default.createElement(Grid, {
|
|
2990
3003
|
item: true,
|
|
2991
3004
|
xs: 4,
|
|
2992
3005
|
container: true,
|
|
2993
|
-
|
|
3006
|
+
justifyContent: "flex-end"
|
|
2994
3007
|
}, /*#__PURE__*/React__default.createElement(Typography, {
|
|
2995
3008
|
variant: "subtitle1",
|
|
2996
3009
|
className: classes.label
|
|
@@ -2998,7 +3011,7 @@ var SelectFIR = function SelectFIR(_ref) {
|
|
|
2998
3011
|
item: true,
|
|
2999
3012
|
xs: 8,
|
|
3000
3013
|
container: true,
|
|
3001
|
-
|
|
3014
|
+
justifyContent: "flex-start"
|
|
3002
3015
|
}, /*#__PURE__*/React__default.createElement(ReactHookFormSelect, {
|
|
3003
3016
|
name: "locationIndicatorATSR",
|
|
3004
3017
|
label: "Select FIR",
|
|
@@ -3064,12 +3077,13 @@ var Type = function Type(_ref) {
|
|
|
3064
3077
|
return /*#__PURE__*/React__default.createElement(Grid, {
|
|
3065
3078
|
item: true,
|
|
3066
3079
|
container: true,
|
|
3067
|
-
spacing: 2
|
|
3080
|
+
spacing: 2,
|
|
3081
|
+
className: classes.containerItem
|
|
3068
3082
|
}, /*#__PURE__*/React__default.createElement(Grid, {
|
|
3069
3083
|
item: true,
|
|
3070
3084
|
xs: 4,
|
|
3071
3085
|
container: true,
|
|
3072
|
-
|
|
3086
|
+
justifyContent: "flex-end"
|
|
3073
3087
|
}, /*#__PURE__*/React__default.createElement(Typography, {
|
|
3074
3088
|
variant: "subtitle1",
|
|
3075
3089
|
className: classes.label
|
|
@@ -3077,7 +3091,7 @@ var Type = function Type(_ref) {
|
|
|
3077
3091
|
item: true,
|
|
3078
3092
|
xs: 8,
|
|
3079
3093
|
container: true,
|
|
3080
|
-
|
|
3094
|
+
justifyContent: "flex-start"
|
|
3081
3095
|
}, /*#__PURE__*/React__default.createElement(Grid, {
|
|
3082
3096
|
item: true,
|
|
3083
3097
|
xs: 12
|
|
@@ -3152,7 +3166,7 @@ var ValidFrom = function ValidFrom(_ref) {
|
|
|
3152
3166
|
item: true,
|
|
3153
3167
|
xs: 4,
|
|
3154
3168
|
container: true,
|
|
3155
|
-
|
|
3169
|
+
justifyContent: "flex-end"
|
|
3156
3170
|
}, /*#__PURE__*/React__default.createElement(Typography, {
|
|
3157
3171
|
variant: "subtitle1",
|
|
3158
3172
|
className: classes.label
|
|
@@ -3160,7 +3174,7 @@ var ValidFrom = function ValidFrom(_ref) {
|
|
|
3160
3174
|
item: true,
|
|
3161
3175
|
xs: 8,
|
|
3162
3176
|
container: true,
|
|
3163
|
-
|
|
3177
|
+
justifyContent: "flex-start"
|
|
3164
3178
|
}, /*#__PURE__*/React__default.createElement(ReactHookFormDateTime, {
|
|
3165
3179
|
disablePast: true,
|
|
3166
3180
|
name: "validDateStart",
|
|
@@ -3246,7 +3260,7 @@ var ValidUntil = function ValidUntil(_ref) {
|
|
|
3246
3260
|
item: true,
|
|
3247
3261
|
xs: 4,
|
|
3248
3262
|
container: true,
|
|
3249
|
-
|
|
3263
|
+
justifyContent: "flex-end"
|
|
3250
3264
|
}, /*#__PURE__*/React__default.createElement(Typography, {
|
|
3251
3265
|
variant: "subtitle1",
|
|
3252
3266
|
className: classes.label
|
|
@@ -3254,7 +3268,7 @@ var ValidUntil = function ValidUntil(_ref) {
|
|
|
3254
3268
|
item: true,
|
|
3255
3269
|
xs: 8,
|
|
3256
3270
|
container: true,
|
|
3257
|
-
|
|
3271
|
+
justifyContent: "flex-start"
|
|
3258
3272
|
}, /*#__PURE__*/React__default.createElement(ReactHookFormDateTime, {
|
|
3259
3273
|
disablePast: true,
|
|
3260
3274
|
name: "validDateEnd",
|
|
@@ -3327,12 +3341,12 @@ var VolcanicFields = function VolcanicFields(_ref) {
|
|
|
3327
3341
|
item: true,
|
|
3328
3342
|
xs: 4,
|
|
3329
3343
|
container: true,
|
|
3330
|
-
|
|
3344
|
+
justifyContent: "flex-end"
|
|
3331
3345
|
}), /*#__PURE__*/React__default.createElement(Grid, {
|
|
3332
3346
|
item: true,
|
|
3333
3347
|
xs: 8,
|
|
3334
3348
|
container: true,
|
|
3335
|
-
|
|
3349
|
+
justifyContent: "flex-start"
|
|
3336
3350
|
}, (!isReadOnly || !!watch('vaSigmetVolcanoName')) && /*#__PURE__*/React__default.createElement(Grid, {
|
|
3337
3351
|
item: true,
|
|
3338
3352
|
xs: 12,
|
|
@@ -3446,12 +3460,12 @@ var SurfaceVisibility = function SurfaceVisibility(_ref) {
|
|
|
3446
3460
|
item: true,
|
|
3447
3461
|
xs: 4,
|
|
3448
3462
|
container: true,
|
|
3449
|
-
|
|
3463
|
+
justifyContent: "flex-end"
|
|
3450
3464
|
}), /*#__PURE__*/React__default.createElement(Grid, {
|
|
3451
3465
|
item: true,
|
|
3452
3466
|
xs: 8,
|
|
3453
3467
|
container: true,
|
|
3454
|
-
|
|
3468
|
+
justifyContent: "flex-start"
|
|
3455
3469
|
}, /*#__PURE__*/React__default.createElement(Grid, {
|
|
3456
3470
|
item: true,
|
|
3457
3471
|
xs: 12,
|
|
@@ -3557,12 +3571,12 @@ var SurfaceWind = function SurfaceWind(_ref) {
|
|
|
3557
3571
|
item: true,
|
|
3558
3572
|
xs: 4,
|
|
3559
3573
|
container: true,
|
|
3560
|
-
|
|
3574
|
+
justifyContent: "flex-end"
|
|
3561
3575
|
}), /*#__PURE__*/React__default.createElement(Grid, {
|
|
3562
3576
|
item: true,
|
|
3563
3577
|
xs: 8,
|
|
3564
3578
|
container: true,
|
|
3565
|
-
|
|
3579
|
+
justifyContent: "flex-start"
|
|
3566
3580
|
}, /*#__PURE__*/React__default.createElement(Grid, {
|
|
3567
3581
|
item: true,
|
|
3568
3582
|
xs: 12,
|
|
@@ -3711,12 +3725,13 @@ var CloudLevels = function CloudLevels(_ref) {
|
|
|
3711
3725
|
return /*#__PURE__*/React__default.createElement(Grid, {
|
|
3712
3726
|
item: true,
|
|
3713
3727
|
container: true,
|
|
3714
|
-
spacing: 2
|
|
3728
|
+
spacing: 2,
|
|
3729
|
+
className: classes.containerItem
|
|
3715
3730
|
}, /*#__PURE__*/React__default.createElement(Grid, {
|
|
3716
3731
|
item: true,
|
|
3717
3732
|
xs: 4,
|
|
3718
3733
|
container: true,
|
|
3719
|
-
|
|
3734
|
+
justifyContent: "flex-end"
|
|
3720
3735
|
}, /*#__PURE__*/React__default.createElement(Typography, {
|
|
3721
3736
|
variant: "subtitle1",
|
|
3722
3737
|
className: classes.label
|
|
@@ -3724,7 +3739,7 @@ var CloudLevels = function CloudLevels(_ref) {
|
|
|
3724
3739
|
item: true,
|
|
3725
3740
|
xs: 8,
|
|
3726
3741
|
container: true,
|
|
3727
|
-
|
|
3742
|
+
justifyContent: "flex-start"
|
|
3728
3743
|
}, /*#__PURE__*/React__default.createElement(Grid, {
|
|
3729
3744
|
item: true,
|
|
3730
3745
|
xs: 12
|
|
@@ -4165,6 +4180,152 @@ var SigmetForm = function SigmetForm(_ref) {
|
|
|
4165
4180
|
setIsDisabled(isInDrawMode);
|
|
4166
4181
|
}
|
|
4167
4182
|
}, [drawMode.start, drawMode.end, isReadOnly, isDisabled]);
|
|
4183
|
+
|
|
4184
|
+
var renderForm = function renderForm() {
|
|
4185
|
+
return /*#__PURE__*/React__default.createElement(React__default.Fragment, null, /*#__PURE__*/React__default.createElement(Grid, {
|
|
4186
|
+
container: true,
|
|
4187
|
+
direction: "column",
|
|
4188
|
+
spacing: 2
|
|
4189
|
+
}, !isCancelSigmet && /*#__PURE__*/React__default.createElement(Phenomenon, {
|
|
4190
|
+
productType: "sigmet",
|
|
4191
|
+
isDisabled: isDisabled,
|
|
4192
|
+
onChange: onChangeForm
|
|
4193
|
+
}), !isCancelSigmet && /*#__PURE__*/React__default.createElement(ObservationForecast, {
|
|
4194
|
+
isDisabled: isDisabled,
|
|
4195
|
+
isReadOnly: isReadOnly
|
|
4196
|
+
}), !isCancelSigmet && /*#__PURE__*/React__default.createElement(ObservationForecastTime, {
|
|
4197
|
+
isDisabled: isDisabled,
|
|
4198
|
+
isReadOnly: isReadOnly,
|
|
4199
|
+
helperText: helperText,
|
|
4200
|
+
onChange: onChangeForm
|
|
4201
|
+
}), !isCancelSigmet && watch('phenomenon') === 'VA_CLD' && /*#__PURE__*/React__default.createElement(VolcanicFields, {
|
|
4202
|
+
isDisabled: isDisabled,
|
|
4203
|
+
isReadOnly: isReadOnly,
|
|
4204
|
+
helperText: helperText
|
|
4205
|
+
}), /*#__PURE__*/React__default.createElement(ValidFrom, {
|
|
4206
|
+
productType: "sigmet",
|
|
4207
|
+
isDisabled: isDisabled,
|
|
4208
|
+
onChange: onChangeForm
|
|
4209
|
+
}), /*#__PURE__*/React__default.createElement(ValidUntil, {
|
|
4210
|
+
productType: "sigmet",
|
|
4211
|
+
isDisabled: isDisabled,
|
|
4212
|
+
onChange: onChangeForm
|
|
4213
|
+
})), /*#__PURE__*/React__default.createElement(SelectFIR, {
|
|
4214
|
+
productType: "sigmet",
|
|
4215
|
+
isDisabled: isDisabled
|
|
4216
|
+
}), /*#__PURE__*/React__default.createElement(StartGeometry, {
|
|
4217
|
+
isReadOnly: isReadOnly,
|
|
4218
|
+
drawMode: drawMode,
|
|
4219
|
+
geoJSONs: geoJSONs,
|
|
4220
|
+
setDrawModeType: function setDrawModeType(mapDrawMode, StartOrEndDrawing) {
|
|
4221
|
+
_setDrawModeType(mapDrawMode, StartOrEndDrawing, updateStartDrawing);
|
|
4222
|
+
}
|
|
4223
|
+
}), !isCancelSigmet && /*#__PURE__*/React__default.createElement(Levels, {
|
|
4224
|
+
isDisabled: isDisabled,
|
|
4225
|
+
isReadOnly: isReadOnly,
|
|
4226
|
+
onChange: onChangeForm,
|
|
4227
|
+
productType: "sigmet"
|
|
4228
|
+
}), !isCancelSigmet && /*#__PURE__*/React__default.createElement(Progress, {
|
|
4229
|
+
productType: "sigmet",
|
|
4230
|
+
isDisabled: isDisabled,
|
|
4231
|
+
isReadOnly: isReadOnly,
|
|
4232
|
+
drawMode: drawMode,
|
|
4233
|
+
geoJSONs: geoJSONs,
|
|
4234
|
+
setDrawModeType: function setDrawModeType(mapDrawMode, StartOrEndDrawing) {
|
|
4235
|
+
_setDrawModeType(mapDrawMode, StartOrEndDrawing, updateEndDrawing);
|
|
4236
|
+
},
|
|
4237
|
+
onChange: onChangeForm
|
|
4238
|
+
}), !isCancelSigmet && /*#__PURE__*/React__default.createElement(Change, {
|
|
4239
|
+
isDisabled: isDisabled,
|
|
4240
|
+
isReadOnly: isReadOnly
|
|
4241
|
+
}), isCancelSigmet && watch('vaSigmetMoveToFIR') && /*#__PURE__*/React__default.createElement(Grid, {
|
|
4242
|
+
item: true,
|
|
4243
|
+
container: true,
|
|
4244
|
+
spacing: 2
|
|
4245
|
+
}, /*#__PURE__*/React__default.createElement(Grid, {
|
|
4246
|
+
item: true,
|
|
4247
|
+
xs: 4,
|
|
4248
|
+
container: true,
|
|
4249
|
+
justifyContent: "flex-end"
|
|
4250
|
+
}), /*#__PURE__*/React__default.createElement(Grid, {
|
|
4251
|
+
item: true,
|
|
4252
|
+
xs: 8,
|
|
4253
|
+
container: true,
|
|
4254
|
+
justifyContent: "flex-start"
|
|
4255
|
+
}, /*#__PURE__*/React__default.createElement(Grid, {
|
|
4256
|
+
item: true,
|
|
4257
|
+
xs: 12
|
|
4258
|
+
}, /*#__PURE__*/React__default.createElement(Typography, {
|
|
4259
|
+
variant: "body2",
|
|
4260
|
+
className: classes.body,
|
|
4261
|
+
"data-testid": "vaSigmetMoveToFIR"
|
|
4262
|
+
}, "Volcanic Cloud is moving in the direction of:", ' ', /*#__PURE__*/React__default.createElement("b", null, " ", watch('vaSigmetMoveToFIR')))))), /*#__PURE__*/React__default.createElement(Grid, {
|
|
4263
|
+
item: true,
|
|
4264
|
+
container: true,
|
|
4265
|
+
spacing: 2,
|
|
4266
|
+
className: classes.containerItem
|
|
4267
|
+
}, /*#__PURE__*/React__default.createElement(Grid, {
|
|
4268
|
+
item: true,
|
|
4269
|
+
xs: 4,
|
|
4270
|
+
container: true,
|
|
4271
|
+
justifyContent: "flex-end"
|
|
4272
|
+
}, /*#__PURE__*/React__default.createElement(Typography, {
|
|
4273
|
+
variant: "subtitle1",
|
|
4274
|
+
className: classes.label
|
|
4275
|
+
}, "Issued at")), /*#__PURE__*/React__default.createElement(Grid, {
|
|
4276
|
+
item: true,
|
|
4277
|
+
xs: 8,
|
|
4278
|
+
container: true,
|
|
4279
|
+
justifyContent: "flex-start"
|
|
4280
|
+
}, /*#__PURE__*/React__default.createElement(Grid, {
|
|
4281
|
+
item: true,
|
|
4282
|
+
xs: 12
|
|
4283
|
+
}, /*#__PURE__*/React__default.createElement(Typography, {
|
|
4284
|
+
variant: "body2",
|
|
4285
|
+
className: classes.body
|
|
4286
|
+
}, getProductIssueDate(initialSigmet, initialCancelSigmet)))), /*#__PURE__*/React__default.createElement(Grid, {
|
|
4287
|
+
item: true,
|
|
4288
|
+
container: true,
|
|
4289
|
+
spacing: 2
|
|
4290
|
+
}, /*#__PURE__*/React__default.createElement(Grid, {
|
|
4291
|
+
item: true,
|
|
4292
|
+
xs: 4,
|
|
4293
|
+
container: true,
|
|
4294
|
+
justifyContent: "flex-end"
|
|
4295
|
+
}, /*#__PURE__*/React__default.createElement(Typography, {
|
|
4296
|
+
variant: "subtitle1",
|
|
4297
|
+
className: classes.label
|
|
4298
|
+
}, "TAC")), /*#__PURE__*/React__default.createElement(Grid, {
|
|
4299
|
+
item: true,
|
|
4300
|
+
xs: 8,
|
|
4301
|
+
container: true,
|
|
4302
|
+
justifyContent: "flex-start"
|
|
4303
|
+
}, /*#__PURE__*/React__default.createElement(Grid, {
|
|
4304
|
+
item: true,
|
|
4305
|
+
xs: 12
|
|
4306
|
+
}, /*#__PURE__*/React__default.createElement(ProductFormTAC, {
|
|
4307
|
+
tac: tac
|
|
4308
|
+
})))), /*#__PURE__*/React__default.createElement(ReactHookFormHiddenInput, {
|
|
4309
|
+
name: "sequence",
|
|
4310
|
+
defaultValue: "-1"
|
|
4311
|
+
}),
|
|
4312
|
+
/* Add hidden fields for TAC generation in case of cancel sigmet */
|
|
4313
|
+
isCancelSigmet && /*#__PURE__*/React__default.createElement(React__default.Fragment, null, /*#__PURE__*/React__default.createElement(ReactHookFormHiddenInput, {
|
|
4314
|
+
name: "cancelsSigmetSequenceId"
|
|
4315
|
+
}), /*#__PURE__*/React__default.createElement(ReactHookFormHiddenInput, {
|
|
4316
|
+
name: "validDateEndOfSigmetToCancel"
|
|
4317
|
+
}), /*#__PURE__*/React__default.createElement(ReactHookFormHiddenInput, {
|
|
4318
|
+
name: "validDateStartOfSigmetToCancel"
|
|
4319
|
+
}))), /*#__PURE__*/React__default.createElement(Type, {
|
|
4320
|
+
isDisabled: isDisabled,
|
|
4321
|
+
isReadOnly: isReadOnly
|
|
4322
|
+
}));
|
|
4323
|
+
};
|
|
4324
|
+
|
|
4325
|
+
if (!showMap) {
|
|
4326
|
+
return renderForm();
|
|
4327
|
+
}
|
|
4328
|
+
|
|
4168
4329
|
return /*#__PURE__*/React__default.createElement("form", {
|
|
4169
4330
|
onChange: onChangeForm,
|
|
4170
4331
|
onSubmit: handleSubmit(function () {
|
|
@@ -4181,7 +4342,7 @@ var SigmetForm = function SigmetForm(_ref) {
|
|
|
4181
4342
|
}, /*#__PURE__*/React__default.createElement(Grid, {
|
|
4182
4343
|
item: true,
|
|
4183
4344
|
xs: 8
|
|
4184
|
-
},
|
|
4345
|
+
}, /*#__PURE__*/React__default.createElement(MapViewGeoJson, {
|
|
4185
4346
|
geoJSONs: geoJSONs,
|
|
4186
4347
|
setLayerGeoJSONs: function setLayerGeoJSONs(geoJSONs) {
|
|
4187
4348
|
return _setLayerGeoJSONs(createInterSections(geoJSONs));
|
|
@@ -4195,143 +4356,7 @@ var SigmetForm = function SigmetForm(_ref) {
|
|
|
4195
4356
|
item: true,
|
|
4196
4357
|
xs: 4,
|
|
4197
4358
|
className: classes.productForm
|
|
4198
|
-
},
|
|
4199
|
-
container: true,
|
|
4200
|
-
direction: "column",
|
|
4201
|
-
spacing: 2
|
|
4202
|
-
}, !isCancelSigmet && /*#__PURE__*/React__default.createElement(Phenomenon, {
|
|
4203
|
-
productType: "sigmet",
|
|
4204
|
-
isDisabled: isDisabled,
|
|
4205
|
-
onChange: onChangeForm
|
|
4206
|
-
}), !isCancelSigmet && /*#__PURE__*/React__default.createElement(ObservationForecast, {
|
|
4207
|
-
isDisabled: isDisabled,
|
|
4208
|
-
isReadOnly: isReadOnly
|
|
4209
|
-
}), !isCancelSigmet && /*#__PURE__*/React__default.createElement(ObservationForecastTime, {
|
|
4210
|
-
isDisabled: isDisabled,
|
|
4211
|
-
isReadOnly: isReadOnly,
|
|
4212
|
-
helperText: helperText,
|
|
4213
|
-
onChange: onChangeForm
|
|
4214
|
-
}), !isCancelSigmet && watch('phenomenon') === 'VA_CLD' && /*#__PURE__*/React__default.createElement(VolcanicFields, {
|
|
4215
|
-
isDisabled: isDisabled,
|
|
4216
|
-
isReadOnly: isReadOnly,
|
|
4217
|
-
helperText: helperText
|
|
4218
|
-
}), /*#__PURE__*/React__default.createElement(ValidFrom, {
|
|
4219
|
-
productType: "sigmet",
|
|
4220
|
-
isDisabled: isDisabled,
|
|
4221
|
-
onChange: onChangeForm
|
|
4222
|
-
}), /*#__PURE__*/React__default.createElement(ValidUntil, {
|
|
4223
|
-
productType: "sigmet",
|
|
4224
|
-
isDisabled: isDisabled,
|
|
4225
|
-
onChange: onChangeForm
|
|
4226
|
-
})), /*#__PURE__*/React__default.createElement(SelectFIR, {
|
|
4227
|
-
productType: "sigmet",
|
|
4228
|
-
isDisabled: isDisabled
|
|
4229
|
-
}), /*#__PURE__*/React__default.createElement(StartGeometry, {
|
|
4230
|
-
isReadOnly: isReadOnly,
|
|
4231
|
-
drawMode: drawMode,
|
|
4232
|
-
geoJSONs: geoJSONs,
|
|
4233
|
-
setDrawModeType: function setDrawModeType(mapDrawMode, StartOrEndDrawing) {
|
|
4234
|
-
_setDrawModeType(mapDrawMode, StartOrEndDrawing, updateStartDrawing);
|
|
4235
|
-
}
|
|
4236
|
-
}), !isCancelSigmet && /*#__PURE__*/React__default.createElement(Levels, {
|
|
4237
|
-
isDisabled: isDisabled,
|
|
4238
|
-
isReadOnly: isReadOnly,
|
|
4239
|
-
onChange: onChangeForm,
|
|
4240
|
-
productType: "sigmet"
|
|
4241
|
-
}), !isCancelSigmet && /*#__PURE__*/React__default.createElement(Progress, {
|
|
4242
|
-
productType: "sigmet",
|
|
4243
|
-
isDisabled: isDisabled,
|
|
4244
|
-
isReadOnly: isReadOnly,
|
|
4245
|
-
drawMode: drawMode,
|
|
4246
|
-
geoJSONs: geoJSONs,
|
|
4247
|
-
setDrawModeType: function setDrawModeType(mapDrawMode, StartOrEndDrawing) {
|
|
4248
|
-
_setDrawModeType(mapDrawMode, StartOrEndDrawing, updateEndDrawing);
|
|
4249
|
-
},
|
|
4250
|
-
onChange: onChangeForm
|
|
4251
|
-
}), !isCancelSigmet && /*#__PURE__*/React__default.createElement(Change, {
|
|
4252
|
-
isDisabled: isDisabled,
|
|
4253
|
-
isReadOnly: isReadOnly
|
|
4254
|
-
}), isCancelSigmet && watch('vaSigmetMoveToFIR') && /*#__PURE__*/React__default.createElement(Grid, {
|
|
4255
|
-
item: true,
|
|
4256
|
-
container: true,
|
|
4257
|
-
spacing: 2
|
|
4258
|
-
}, /*#__PURE__*/React__default.createElement(Grid, {
|
|
4259
|
-
item: true,
|
|
4260
|
-
xs: 4,
|
|
4261
|
-
container: true,
|
|
4262
|
-
justify: "flex-end"
|
|
4263
|
-
}), /*#__PURE__*/React__default.createElement(Grid, {
|
|
4264
|
-
item: true,
|
|
4265
|
-
xs: 8,
|
|
4266
|
-
container: true,
|
|
4267
|
-
justify: "flex-start"
|
|
4268
|
-
}, /*#__PURE__*/React__default.createElement(Grid, {
|
|
4269
|
-
item: true,
|
|
4270
|
-
xs: 12
|
|
4271
|
-
}, /*#__PURE__*/React__default.createElement(Typography, {
|
|
4272
|
-
variant: "body2",
|
|
4273
|
-
className: classes.body,
|
|
4274
|
-
"data-testid": "vaSigmetMoveToFIR"
|
|
4275
|
-
}, "Volcanic Cloud is moving in the direction of:", ' ', /*#__PURE__*/React__default.createElement("b", null, " ", watch('vaSigmetMoveToFIR')))))), /*#__PURE__*/React__default.createElement(Grid, {
|
|
4276
|
-
item: true,
|
|
4277
|
-
container: true,
|
|
4278
|
-
spacing: 2
|
|
4279
|
-
}, /*#__PURE__*/React__default.createElement(Grid, {
|
|
4280
|
-
item: true,
|
|
4281
|
-
xs: 4,
|
|
4282
|
-
container: true,
|
|
4283
|
-
justify: "flex-end"
|
|
4284
|
-
}, /*#__PURE__*/React__default.createElement(Typography, {
|
|
4285
|
-
variant: "subtitle1",
|
|
4286
|
-
className: classes.label
|
|
4287
|
-
}, "Issued at")), /*#__PURE__*/React__default.createElement(Grid, {
|
|
4288
|
-
item: true,
|
|
4289
|
-
xs: 8,
|
|
4290
|
-
container: true,
|
|
4291
|
-
justify: "flex-start"
|
|
4292
|
-
}, /*#__PURE__*/React__default.createElement(Grid, {
|
|
4293
|
-
item: true,
|
|
4294
|
-
xs: 12
|
|
4295
|
-
}, /*#__PURE__*/React__default.createElement(Typography, {
|
|
4296
|
-
variant: "body2",
|
|
4297
|
-
className: classes.body
|
|
4298
|
-
}, getProductIssueDate(initialSigmet, initialCancelSigmet)))), /*#__PURE__*/React__default.createElement(Grid, {
|
|
4299
|
-
item: true,
|
|
4300
|
-
container: true,
|
|
4301
|
-
spacing: 2
|
|
4302
|
-
}, /*#__PURE__*/React__default.createElement(Grid, {
|
|
4303
|
-
item: true,
|
|
4304
|
-
xs: 4,
|
|
4305
|
-
container: true,
|
|
4306
|
-
justify: "flex-end"
|
|
4307
|
-
}, /*#__PURE__*/React__default.createElement(Typography, {
|
|
4308
|
-
variant: "subtitle1",
|
|
4309
|
-
className: classes.label
|
|
4310
|
-
}, "TAC")), /*#__PURE__*/React__default.createElement(Grid, {
|
|
4311
|
-
item: true,
|
|
4312
|
-
xs: 8,
|
|
4313
|
-
container: true,
|
|
4314
|
-
justify: "flex-start"
|
|
4315
|
-
}, /*#__PURE__*/React__default.createElement(Grid, {
|
|
4316
|
-
item: true,
|
|
4317
|
-
xs: 12
|
|
4318
|
-
}, /*#__PURE__*/React__default.createElement(ProductFormTAC, {
|
|
4319
|
-
tac: tac
|
|
4320
|
-
})))), /*#__PURE__*/React__default.createElement(ReactHookFormHiddenInput, {
|
|
4321
|
-
name: "sequence",
|
|
4322
|
-
defaultValue: "-1"
|
|
4323
|
-
}),
|
|
4324
|
-
/* Add hidden fields for TAC generation in case of cancel sigmet */
|
|
4325
|
-
isCancelSigmet && /*#__PURE__*/React__default.createElement(React__default.Fragment, null, /*#__PURE__*/React__default.createElement(ReactHookFormHiddenInput, {
|
|
4326
|
-
name: "cancelsSigmetSequenceId"
|
|
4327
|
-
}), /*#__PURE__*/React__default.createElement(ReactHookFormHiddenInput, {
|
|
4328
|
-
name: "validDateEndOfSigmetToCancel"
|
|
4329
|
-
}), /*#__PURE__*/React__default.createElement(ReactHookFormHiddenInput, {
|
|
4330
|
-
name: "validDateStartOfSigmetToCancel"
|
|
4331
|
-
}))), /*#__PURE__*/React__default.createElement(Type, {
|
|
4332
|
-
isDisabled: isDisabled,
|
|
4333
|
-
isReadOnly: isReadOnly
|
|
4334
|
-
})))));
|
|
4359
|
+
}, renderForm())));
|
|
4335
4360
|
};
|
|
4336
4361
|
|
|
4337
4362
|
var AirmetForm = function AirmetForm(_ref) {
|
|
@@ -4413,6 +4438,132 @@ var AirmetForm = function AirmetForm(_ref) {
|
|
|
4413
4438
|
setIsDisabled(isInDrawMode);
|
|
4414
4439
|
}
|
|
4415
4440
|
}, [drawMode.start, isReadOnly, isDisabled]);
|
|
4441
|
+
|
|
4442
|
+
var renderForm = function renderForm() {
|
|
4443
|
+
return /*#__PURE__*/React__default.createElement(React__default.Fragment, null, /*#__PURE__*/React__default.createElement(Grid, {
|
|
4444
|
+
container: true,
|
|
4445
|
+
direction: "column",
|
|
4446
|
+
spacing: 2
|
|
4447
|
+
}, !isCancelAirmet && /*#__PURE__*/React__default.createElement(Phenomenon, {
|
|
4448
|
+
productType: "airmet",
|
|
4449
|
+
isDisabled: isDisabled,
|
|
4450
|
+
onChange: onChangeForm
|
|
4451
|
+
}), !isCancelAirmet && phenomenon === 'SFC_VIS' && /*#__PURE__*/React__default.createElement(SurfaceVisibility, {
|
|
4452
|
+
isDisabled: isDisabled,
|
|
4453
|
+
onChange: onChangeForm
|
|
4454
|
+
}), !isCancelAirmet && phenomenon === 'SFC_WIND' && /*#__PURE__*/React__default.createElement(SurfaceWind, {
|
|
4455
|
+
isDisabled: isDisabled,
|
|
4456
|
+
onChange: onChangeForm
|
|
4457
|
+
}), !isCancelAirmet && /*#__PURE__*/React__default.createElement(ObservationForecast, {
|
|
4458
|
+
isDisabled: isDisabled,
|
|
4459
|
+
isReadOnly: isReadOnly
|
|
4460
|
+
}), !isCancelAirmet && /*#__PURE__*/React__default.createElement(ObservationForecastTime, {
|
|
4461
|
+
isDisabled: isDisabled,
|
|
4462
|
+
isReadOnly: isReadOnly,
|
|
4463
|
+
helperText: helperText,
|
|
4464
|
+
onChange: onChangeForm
|
|
4465
|
+
}), /*#__PURE__*/React__default.createElement(ValidFrom, {
|
|
4466
|
+
productType: "airmet",
|
|
4467
|
+
isDisabled: isDisabled,
|
|
4468
|
+
onChange: onChangeForm
|
|
4469
|
+
}), /*#__PURE__*/React__default.createElement(ValidUntil, {
|
|
4470
|
+
productType: "airmet",
|
|
4471
|
+
isDisabled: isDisabled,
|
|
4472
|
+
onChange: onChangeForm
|
|
4473
|
+
})), /*#__PURE__*/React__default.createElement(SelectFIR, {
|
|
4474
|
+
productType: "airmet",
|
|
4475
|
+
isDisabled: isDisabled
|
|
4476
|
+
}), /*#__PURE__*/React__default.createElement(StartGeometry, {
|
|
4477
|
+
isReadOnly: isReadOnly,
|
|
4478
|
+
drawMode: drawMode,
|
|
4479
|
+
geoJSONs: geoJSONs,
|
|
4480
|
+
setDrawModeType: function setDrawModeType(mapDrawMode, StartOrEndDrawing) {
|
|
4481
|
+
_setDrawModeType(mapDrawMode, StartOrEndDrawing, updateStartDrawing);
|
|
4482
|
+
}
|
|
4483
|
+
}), !isCancelAirmet && phenomenon !== 'SFC_WIND' && phenomenon !== 'SFC_VIS' && phenomenon !== 'BKN_CLD' && phenomenon !== 'OVC_CLD' && /*#__PURE__*/React__default.createElement(Levels, {
|
|
4484
|
+
isDisabled: isDisabled,
|
|
4485
|
+
isReadOnly: isReadOnly,
|
|
4486
|
+
onChange: onChangeForm,
|
|
4487
|
+
productType: "airmet"
|
|
4488
|
+
}), !isCancelAirmet && (phenomenon === 'BKN_CLD' || phenomenon === 'OVC_CLD') && /*#__PURE__*/React__default.createElement(CloudLevels, {
|
|
4489
|
+
isDisabled: isDisabled,
|
|
4490
|
+
isReadOnly: isReadOnly,
|
|
4491
|
+
onChange: onChangeForm
|
|
4492
|
+
}), !isCancelAirmet && /*#__PURE__*/React__default.createElement(Progress, {
|
|
4493
|
+
productType: "airmet",
|
|
4494
|
+
isDisabled: isDisabled,
|
|
4495
|
+
isReadOnly: isReadOnly,
|
|
4496
|
+
onChange: onChangeForm
|
|
4497
|
+
}), !isCancelAirmet && /*#__PURE__*/React__default.createElement(Change, {
|
|
4498
|
+
isDisabled: isDisabled,
|
|
4499
|
+
isReadOnly: isReadOnly
|
|
4500
|
+
}), /*#__PURE__*/React__default.createElement(Grid, {
|
|
4501
|
+
item: true,
|
|
4502
|
+
container: true,
|
|
4503
|
+
spacing: 2,
|
|
4504
|
+
className: classes.containerItem
|
|
4505
|
+
}, /*#__PURE__*/React__default.createElement(Grid, {
|
|
4506
|
+
item: true,
|
|
4507
|
+
xs: 4,
|
|
4508
|
+
container: true,
|
|
4509
|
+
justifyContent: "flex-end"
|
|
4510
|
+
}, /*#__PURE__*/React__default.createElement(Typography, {
|
|
4511
|
+
variant: "subtitle1",
|
|
4512
|
+
className: classes.label
|
|
4513
|
+
}, "Issued at")), /*#__PURE__*/React__default.createElement(Grid, {
|
|
4514
|
+
item: true,
|
|
4515
|
+
xs: 8,
|
|
4516
|
+
container: true,
|
|
4517
|
+
justifyContent: "flex-start"
|
|
4518
|
+
}, /*#__PURE__*/React__default.createElement(Grid, {
|
|
4519
|
+
item: true,
|
|
4520
|
+
xs: 12
|
|
4521
|
+
}, /*#__PURE__*/React__default.createElement(Typography, {
|
|
4522
|
+
variant: "body2",
|
|
4523
|
+
className: classes.body
|
|
4524
|
+
}, getProductIssueDate(initialAirmet, initialCancelAirmet)))), /*#__PURE__*/React__default.createElement(Grid, {
|
|
4525
|
+
item: true,
|
|
4526
|
+
container: true,
|
|
4527
|
+
spacing: 2
|
|
4528
|
+
}, /*#__PURE__*/React__default.createElement(Grid, {
|
|
4529
|
+
item: true,
|
|
4530
|
+
xs: 4,
|
|
4531
|
+
container: true,
|
|
4532
|
+
justifyContent: "flex-end"
|
|
4533
|
+
}, /*#__PURE__*/React__default.createElement(Typography, {
|
|
4534
|
+
variant: "subtitle1",
|
|
4535
|
+
className: classes.label
|
|
4536
|
+
}, "TAC")), /*#__PURE__*/React__default.createElement(Grid, {
|
|
4537
|
+
item: true,
|
|
4538
|
+
xs: 8,
|
|
4539
|
+
container: true,
|
|
4540
|
+
justifyContent: "flex-start"
|
|
4541
|
+
}, /*#__PURE__*/React__default.createElement(Grid, {
|
|
4542
|
+
item: true,
|
|
4543
|
+
xs: 12
|
|
4544
|
+
}, /*#__PURE__*/React__default.createElement(ProductFormTAC, {
|
|
4545
|
+
tac: tac
|
|
4546
|
+
})))), /*#__PURE__*/React__default.createElement(ReactHookFormHiddenInput, {
|
|
4547
|
+
name: "sequence",
|
|
4548
|
+
defaultValue: "-1"
|
|
4549
|
+
}),
|
|
4550
|
+
/* Add hidden fields for TAC generation in case of cancel airmet */
|
|
4551
|
+
isCancelAirmet && /*#__PURE__*/React__default.createElement(React__default.Fragment, null, /*#__PURE__*/React__default.createElement(ReactHookFormHiddenInput, {
|
|
4552
|
+
name: "cancelsAirmetSequenceId"
|
|
4553
|
+
}), /*#__PURE__*/React__default.createElement(ReactHookFormHiddenInput, {
|
|
4554
|
+
name: "validDateEndOfAirmetToCancel"
|
|
4555
|
+
}), /*#__PURE__*/React__default.createElement(ReactHookFormHiddenInput, {
|
|
4556
|
+
name: "validDateStartOfAirmetToCancel"
|
|
4557
|
+
}))), /*#__PURE__*/React__default.createElement(Type, {
|
|
4558
|
+
isDisabled: isDisabled,
|
|
4559
|
+
isReadOnly: isReadOnly
|
|
4560
|
+
}));
|
|
4561
|
+
};
|
|
4562
|
+
|
|
4563
|
+
if (!showMap) {
|
|
4564
|
+
return renderForm();
|
|
4565
|
+
}
|
|
4566
|
+
|
|
4416
4567
|
return /*#__PURE__*/React__default.createElement("form", {
|
|
4417
4568
|
onChange: onChangeForm,
|
|
4418
4569
|
onSubmit: handleSubmit(function () {
|
|
@@ -4429,7 +4580,7 @@ var AirmetForm = function AirmetForm(_ref) {
|
|
|
4429
4580
|
}, /*#__PURE__*/React__default.createElement(Grid, {
|
|
4430
4581
|
item: true,
|
|
4431
4582
|
xs: 8
|
|
4432
|
-
},
|
|
4583
|
+
}, /*#__PURE__*/React__default.createElement(MapViewGeoJson, {
|
|
4433
4584
|
geoJSONs: geoJSONs,
|
|
4434
4585
|
setLayerGeoJSONs: function setLayerGeoJSONs(geoJSONs) {
|
|
4435
4586
|
return _setLayerGeoJSONs(createInterSections(geoJSONs));
|
|
@@ -4442,123 +4593,7 @@ var AirmetForm = function AirmetForm(_ref) {
|
|
|
4442
4593
|
item: true,
|
|
4443
4594
|
xs: 4,
|
|
4444
4595
|
className: classes.productForm
|
|
4445
|
-
},
|
|
4446
|
-
container: true,
|
|
4447
|
-
direction: "column",
|
|
4448
|
-
spacing: 2
|
|
4449
|
-
}, !isCancelAirmet && /*#__PURE__*/React__default.createElement(Phenomenon, {
|
|
4450
|
-
productType: "airmet",
|
|
4451
|
-
isDisabled: isDisabled,
|
|
4452
|
-
onChange: onChangeForm
|
|
4453
|
-
}), !isCancelAirmet && phenomenon === 'SFC_VIS' && /*#__PURE__*/React__default.createElement(SurfaceVisibility, {
|
|
4454
|
-
isDisabled: isDisabled,
|
|
4455
|
-
onChange: onChangeForm
|
|
4456
|
-
}), !isCancelAirmet && phenomenon === 'SFC_WIND' && /*#__PURE__*/React__default.createElement(SurfaceWind, {
|
|
4457
|
-
isDisabled: isDisabled,
|
|
4458
|
-
onChange: onChangeForm
|
|
4459
|
-
}), !isCancelAirmet && /*#__PURE__*/React__default.createElement(ObservationForecast, {
|
|
4460
|
-
isDisabled: isDisabled,
|
|
4461
|
-
isReadOnly: isReadOnly
|
|
4462
|
-
}), !isCancelAirmet && /*#__PURE__*/React__default.createElement(ObservationForecastTime, {
|
|
4463
|
-
isDisabled: isDisabled,
|
|
4464
|
-
isReadOnly: isReadOnly,
|
|
4465
|
-
helperText: helperText,
|
|
4466
|
-
onChange: onChangeForm
|
|
4467
|
-
}), /*#__PURE__*/React__default.createElement(ValidFrom, {
|
|
4468
|
-
productType: "airmet",
|
|
4469
|
-
isDisabled: isDisabled,
|
|
4470
|
-
onChange: onChangeForm
|
|
4471
|
-
}), /*#__PURE__*/React__default.createElement(ValidUntil, {
|
|
4472
|
-
productType: "airmet",
|
|
4473
|
-
isDisabled: isDisabled,
|
|
4474
|
-
onChange: onChangeForm
|
|
4475
|
-
})), /*#__PURE__*/React__default.createElement(SelectFIR, {
|
|
4476
|
-
productType: "airmet",
|
|
4477
|
-
isDisabled: isDisabled
|
|
4478
|
-
}), /*#__PURE__*/React__default.createElement(StartGeometry, {
|
|
4479
|
-
isReadOnly: isReadOnly,
|
|
4480
|
-
drawMode: drawMode,
|
|
4481
|
-
geoJSONs: geoJSONs,
|
|
4482
|
-
setDrawModeType: function setDrawModeType(mapDrawMode, StartOrEndDrawing) {
|
|
4483
|
-
_setDrawModeType(mapDrawMode, StartOrEndDrawing, updateStartDrawing);
|
|
4484
|
-
}
|
|
4485
|
-
}), !isCancelAirmet && phenomenon !== 'SFC_WIND' && phenomenon !== 'SFC_VIS' && phenomenon !== 'BKN_CLD' && phenomenon !== 'OVC_CLD' && /*#__PURE__*/React__default.createElement(Levels, {
|
|
4486
|
-
isDisabled: isDisabled,
|
|
4487
|
-
isReadOnly: isReadOnly,
|
|
4488
|
-
onChange: onChangeForm,
|
|
4489
|
-
productType: "airmet"
|
|
4490
|
-
}), !isCancelAirmet && (phenomenon === 'BKN_CLD' || phenomenon === 'OVC_CLD') && /*#__PURE__*/React__default.createElement(CloudLevels, {
|
|
4491
|
-
isDisabled: isDisabled,
|
|
4492
|
-
isReadOnly: isReadOnly,
|
|
4493
|
-
onChange: onChangeForm
|
|
4494
|
-
}), !isCancelAirmet && /*#__PURE__*/React__default.createElement(Progress, {
|
|
4495
|
-
productType: "airmet",
|
|
4496
|
-
isDisabled: isDisabled,
|
|
4497
|
-
isReadOnly: isReadOnly,
|
|
4498
|
-
onChange: onChangeForm
|
|
4499
|
-
}), !isCancelAirmet && /*#__PURE__*/React__default.createElement(Change, {
|
|
4500
|
-
isDisabled: isDisabled,
|
|
4501
|
-
isReadOnly: isReadOnly
|
|
4502
|
-
}), /*#__PURE__*/React__default.createElement(Grid, {
|
|
4503
|
-
item: true,
|
|
4504
|
-
container: true,
|
|
4505
|
-
spacing: 2
|
|
4506
|
-
}, /*#__PURE__*/React__default.createElement(Grid, {
|
|
4507
|
-
item: true,
|
|
4508
|
-
xs: 4,
|
|
4509
|
-
container: true,
|
|
4510
|
-
justify: "flex-end"
|
|
4511
|
-
}, /*#__PURE__*/React__default.createElement(Typography, {
|
|
4512
|
-
variant: "subtitle1",
|
|
4513
|
-
className: classes.label
|
|
4514
|
-
}, "Issued at")), /*#__PURE__*/React__default.createElement(Grid, {
|
|
4515
|
-
item: true,
|
|
4516
|
-
xs: 8,
|
|
4517
|
-
container: true,
|
|
4518
|
-
justify: "flex-start"
|
|
4519
|
-
}, /*#__PURE__*/React__default.createElement(Grid, {
|
|
4520
|
-
item: true,
|
|
4521
|
-
xs: 12
|
|
4522
|
-
}, /*#__PURE__*/React__default.createElement(Typography, {
|
|
4523
|
-
variant: "body2",
|
|
4524
|
-
className: classes.body
|
|
4525
|
-
}, getProductIssueDate(initialAirmet, initialCancelAirmet)))), /*#__PURE__*/React__default.createElement(Grid, {
|
|
4526
|
-
item: true,
|
|
4527
|
-
container: true,
|
|
4528
|
-
spacing: 2
|
|
4529
|
-
}, /*#__PURE__*/React__default.createElement(Grid, {
|
|
4530
|
-
item: true,
|
|
4531
|
-
xs: 4,
|
|
4532
|
-
container: true,
|
|
4533
|
-
justify: "flex-end"
|
|
4534
|
-
}, /*#__PURE__*/React__default.createElement(Typography, {
|
|
4535
|
-
variant: "subtitle1",
|
|
4536
|
-
className: classes.label
|
|
4537
|
-
}, "TAC")), /*#__PURE__*/React__default.createElement(Grid, {
|
|
4538
|
-
item: true,
|
|
4539
|
-
xs: 8,
|
|
4540
|
-
container: true,
|
|
4541
|
-
justify: "flex-start"
|
|
4542
|
-
}, /*#__PURE__*/React__default.createElement(Grid, {
|
|
4543
|
-
item: true,
|
|
4544
|
-
xs: 12
|
|
4545
|
-
}, /*#__PURE__*/React__default.createElement(ProductFormTAC, {
|
|
4546
|
-
tac: tac
|
|
4547
|
-
})))), /*#__PURE__*/React__default.createElement(ReactHookFormHiddenInput, {
|
|
4548
|
-
name: "sequence",
|
|
4549
|
-
defaultValue: "-1"
|
|
4550
|
-
}),
|
|
4551
|
-
/* Add hidden fields for TAC generation in case of cancel airmet */
|
|
4552
|
-
isCancelAirmet && /*#__PURE__*/React__default.createElement(React__default.Fragment, null, /*#__PURE__*/React__default.createElement(ReactHookFormHiddenInput, {
|
|
4553
|
-
name: "cancelsAirmetSequenceId"
|
|
4554
|
-
}), /*#__PURE__*/React__default.createElement(ReactHookFormHiddenInput, {
|
|
4555
|
-
name: "validDateEndOfAirmetToCancel"
|
|
4556
|
-
}), /*#__PURE__*/React__default.createElement(ReactHookFormHiddenInput, {
|
|
4557
|
-
name: "validDateStartOfAirmetToCancel"
|
|
4558
|
-
}))), /*#__PURE__*/React__default.createElement(Type, {
|
|
4559
|
-
isDisabled: isDisabled,
|
|
4560
|
-
isReadOnly: isReadOnly
|
|
4561
|
-
})))));
|
|
4596
|
+
}, renderForm())));
|
|
4562
4597
|
};
|
|
4563
4598
|
|
|
4564
4599
|
var useStyles$3 = makeStyles({
|
|
@@ -4578,6 +4613,11 @@ var useStyles$3 = makeStyles({
|
|
|
4578
4613
|
minHeight: 200,
|
|
4579
4614
|
minWidth: 400,
|
|
4580
4615
|
height: '100%'
|
|
4616
|
+
},
|
|
4617
|
+
dialog: {
|
|
4618
|
+
'& .MuiDialogContent-root': {
|
|
4619
|
+
paddingTop: 20
|
|
4620
|
+
}
|
|
4581
4621
|
}
|
|
4582
4622
|
});
|
|
4583
4623
|
|
|
@@ -4607,9 +4647,8 @@ var ContentDialog = function ContentDialog(_a) {
|
|
|
4607
4647
|
open: open,
|
|
4608
4648
|
onClose: handleClose,
|
|
4609
4649
|
maxWidth: other.maxWidth ? other.maxWidth : 'lg',
|
|
4610
|
-
|
|
4650
|
+
className: classes.dialog
|
|
4611
4651
|
}, other), /*#__PURE__*/React.createElement(DialogTitle, {
|
|
4612
|
-
disableTypography: true,
|
|
4613
4652
|
className: classes.dialogHeader
|
|
4614
4653
|
}, /*#__PURE__*/React.createElement(Grid, {
|
|
4615
4654
|
container: true,
|
|
@@ -4901,7 +4940,7 @@ var ProductList = function ProductList(_ref) {
|
|
|
4901
4940
|
}, /*#__PURE__*/React__default.createElement(Grid, {
|
|
4902
4941
|
container: true,
|
|
4903
4942
|
item: true,
|
|
4904
|
-
|
|
4943
|
+
justifyContent: "flex-end"
|
|
4905
4944
|
}, /*#__PURE__*/React__default.createElement(Button, {
|
|
4906
4945
|
variant: "contained",
|
|
4907
4946
|
color: "secondary",
|
|
@@ -4931,7 +4970,7 @@ var ProductList = function ProductList(_ref) {
|
|
|
4931
4970
|
}));
|
|
4932
4971
|
})), isLoading && /*#__PURE__*/React__default.createElement(Skeleton, {
|
|
4933
4972
|
"data-testid": "productList-skeleton",
|
|
4934
|
-
variant: "
|
|
4973
|
+
variant: "rectangular",
|
|
4935
4974
|
height: "660px"
|
|
4936
4975
|
})));
|
|
4937
4976
|
};
|