@opengeoweb/warnings 9.28.1 → 9.29.1
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/index.esm.js +1066 -719
- package/package.json +1 -1
- package/src/index.d.ts +10 -10
- package/src/lib/Warnings.stories.d.ts +6 -6
- package/src/lib/components/AreaObjectLoader/AreaObjectFilter.d.ts +9 -9
- package/src/lib/components/AreaObjectLoader/AreaObjectFilter.spec.d.ts +1 -1
- package/src/lib/components/AreaObjectLoader/AreaObjectLoader.d.ts +27 -27
- package/src/lib/components/AreaObjectLoader/AreaObjectLoader.spec.d.ts +1 -1
- package/src/lib/components/AreaObjectLoader/AreaObjectLoader.stories.d.ts +40 -40
- package/src/lib/components/AreaObjectLoader/AreaObjectLoaderConnect.d.ts +6 -6
- package/src/lib/components/AreaObjectLoader/AreaObjectLoaderConnect.integration.spec.d.ts +1 -1
- package/src/lib/components/AreaObjectLoader/AreaObjectLoaderConnect.stories.d.ts +7 -7
- package/src/lib/components/AreaObjectLoader/AreasObjects.d.ts +25 -25
- package/src/lib/components/AreaObjectLoader/AreasObjects.spec.d.ts +1 -1
- package/src/lib/components/ComponentsLookUp/ComponentsLookUp.d.ts +15 -15
- package/src/lib/components/ComponentsLookUp/ComponentsLookUp.spec.d.ts +1 -1
- package/src/lib/components/ComponentsLookUp/index.d.ts +1 -1
- package/src/lib/components/DrawingTool/DrawingTool.stories.d.ts +34 -34
- package/src/lib/components/DrawingTool/DrawingToolConnect.d.ts +16 -16
- package/src/lib/components/DrawingTool/DrawingToolConnect.spec.d.ts +1 -1
- package/src/lib/components/DrawingTool/DrawingToolConnect.stories.d.ts +6 -6
- package/src/lib/components/DrawingTool/DrawingToolDialog.d.ts +19 -19
- package/src/lib/components/DrawingTool/DrawingToolDialog.spec.d.ts +1 -1
- package/src/lib/components/DrawingTool/DrawingToolMapButtonConnect.d.ts +8 -8
- package/src/lib/components/DrawingTool/DrawingToolMapButtonConnect.spec.d.ts +1 -1
- package/src/lib/components/DrawingTool/index.d.ts +3 -3
- package/src/lib/components/DrawingTool/useObjectDrawDialogAction.d.ts +25 -25
- package/src/lib/components/DrawingTool/useObjectDrawDialogAction.spec.d.ts +1 -1
- package/src/lib/components/DrawingToolForm/DrawingToolForm.d.ts +26 -26
- package/src/lib/components/DrawingToolForm/DrawingToolForm.spec.d.ts +1 -1
- package/src/lib/components/DrawingToolForm/DrawingToolFormConnect.d.ts +2 -2
- package/src/lib/components/DrawingToolForm/DrawingToolFormConnect.integration.spec.d.ts +1 -1
- package/src/lib/components/DrawingToolForm/DrawingToolFormContents.d.ts +27 -27
- package/src/lib/components/DrawingToolForm/index.d.ts +2 -2
- package/src/lib/components/FilterList/ExpandableFilterChip.d.ts +10 -0
- package/src/lib/components/FilterList/FilterChipWithOptions.d.ts +7 -7
- package/src/lib/components/FilterList/FilterChipWithOptions.spec.d.ts +1 -1
- package/src/lib/components/FilterList/FilterChipWithOptions.stories.d.ts +19 -19
- package/src/lib/components/FilterList/FilterChipWithOptionsConnect.d.ts +7 -7
- package/src/lib/components/FilterList/FilterList.d.ts +12 -13
- package/src/lib/components/FilterList/FilterOption.d.ts +12 -0
- package/src/lib/components/ObjectManager/ConfirmDeleteDialog.d.ts +11 -11
- package/src/lib/components/ObjectManager/ConfirmDeleteDialog.spec.d.ts +1 -1
- package/src/lib/components/ObjectManager/ObjectManager.d.ts +25 -25
- package/src/lib/components/ObjectManager/ObjectManager.spec.d.ts +1 -1
- package/src/lib/components/ObjectManager/ObjectManager.stories.d.ts +46 -46
- package/src/lib/components/ObjectManager/ObjectManagerConnect.d.ts +6 -6
- package/src/lib/components/ObjectManager/ObjectManagerConnect.integration.spec.d.ts +1 -1
- package/src/lib/components/ObjectManager/ObjectManagerConnect.stories.d.ts +25 -25
- package/src/lib/components/ObjectManager/ObjectManagerConnectErrors.stories.d.ts +9 -9
- package/src/lib/components/ObjectManager/ObjectManagerMapButtonConnect.d.ts +6 -6
- package/src/lib/components/ObjectManager/ObjectManagerMapButtonConnect.spec.d.ts +1 -1
- package/src/lib/components/ObjectManager/Objects.d.ts +22 -22
- package/src/lib/components/ObjectManager/Objects.spec.d.ts +1 -1
- package/src/lib/components/ObjectManager/index.d.ts +2 -2
- package/src/lib/components/Providers/Providers.d.ts +19 -19
- package/src/lib/components/Providers/Providers.spec.d.ts +1 -1
- package/src/lib/components/PublicWarningList/ConfirmWarningDialog.d.ts +13 -13
- package/src/lib/components/PublicWarningList/ConfirmWarningDialog.spec.d.ts +1 -1
- package/src/lib/components/PublicWarningList/PublicWarningList.d.ts +24 -27
- package/src/lib/components/PublicWarningList/PublicWarningList.spec.d.ts +1 -1
- package/src/lib/components/PublicWarningList/PublicWarningList.stories.d.ts +35 -35
- package/src/lib/components/PublicWarningList/PublicWarningListConnect.d.ts +3 -3
- package/src/lib/components/PublicWarningList/PublicWarningListConnect.editorToggle.integration.spec.d.ts +1 -1
- package/src/lib/components/PublicWarningList/PublicWarningListConnect.filter.integration.spec.d.ts +1 -1
- package/src/lib/components/PublicWarningList/PublicWarningListConnect.integration.spec.d.ts +1 -1
- package/src/lib/components/PublicWarningList/PublicWarningListConnect.published.integration.spec.d.ts +1 -1
- package/src/lib/components/PublicWarningList/PublicWarningListConnect.stories.d.ts +9 -9
- package/src/lib/components/PublicWarningList/WarningListColumnContent.d.ts +10 -0
- package/src/lib/components/PublicWarningList/WarningListItem.d.ts +17 -26
- package/src/lib/components/PublicWarningList/WarningListItemMenu.d.ts +14 -0
- package/src/lib/components/PublicWarningList/WarningListItemSeperator.d.ts +8 -8
- package/src/lib/components/PublicWarningList/hooks.d.ts +19 -0
- package/src/lib/components/PublicWarningList/index.d.ts +2 -2
- package/src/lib/components/PublicWarningsForm/AreaField/AreaField.d.ts +9 -9
- package/src/lib/components/PublicWarningsForm/AreaField/AreaField.spec.d.ts +1 -1
- package/src/lib/components/PublicWarningsForm/AreaField/AreaField.stories.d.ts +13 -13
- package/src/lib/components/PublicWarningsForm/AreaField/index.d.ts +1 -1
- package/src/lib/components/PublicWarningsForm/DescriptionField/DescriptionField.d.ts +5 -5
- package/src/lib/components/PublicWarningsForm/DescriptionField/DescriptionField.spec.d.ts +1 -1
- package/src/lib/components/PublicWarningsForm/DescriptionField/DescriptionField.stories.d.ts +21 -21
- package/src/lib/components/PublicWarningsForm/DescriptionField/index.d.ts +1 -1
- package/src/lib/components/PublicWarningsForm/LevelField/LevelField.d.ts +22 -21
- package/src/lib/components/PublicWarningsForm/LevelField/LevelField.spec.d.ts +1 -1
- package/src/lib/components/PublicWarningsForm/LevelField/index.d.ts +1 -1
- package/src/lib/components/PublicWarningsForm/PhenomenonField/PhenomenonField.d.ts +11 -11
- package/src/lib/components/PublicWarningsForm/PhenomenonField/PhenomenonField.spec.d.ts +1 -1
- package/src/lib/components/PublicWarningsForm/PhenomenonField/index.d.ts +1 -1
- package/src/lib/components/PublicWarningsForm/ProbabilityField/ProbabilityField.d.ts +7 -7
- package/src/lib/components/PublicWarningsForm/ProbabilityField/ProbabilityField.spec.d.ts +1 -1
- package/src/lib/components/PublicWarningsForm/ProbabilityField/index.d.ts +1 -1
- package/src/lib/components/PublicWarningsForm/PublicWarningsForm.d.ts +32 -32
- package/src/lib/components/PublicWarningsForm/PublicWarningsForm.spec.d.ts +1 -1
- package/src/lib/components/PublicWarningsForm/PublicWarningsForm.stories.d.ts +29 -29
- package/src/lib/components/PublicWarningsForm/PublicWarningsFormConnect.d.ts +10 -10
- package/src/lib/components/PublicWarningsForm/PublicWarningsFormConnect.spec.d.ts +1 -1
- package/src/lib/components/PublicWarningsForm/PublicWarningsFormConnect.stories.d.ts +7 -7
- package/src/lib/components/PublicWarningsForm/PublicWarningsFormConnectErrors.stories.d.ts +7 -7
- package/src/lib/components/PublicWarningsForm/ValidFromField/ValidFromField.d.ts +9 -9
- package/src/lib/components/PublicWarningsForm/ValidFromField/ValidFromField.spec.d.ts +1 -1
- package/src/lib/components/PublicWarningsForm/ValidFromField/index.d.ts +1 -1
- package/src/lib/components/PublicWarningsForm/ValidUntilField/ValidUntilField.d.ts +11 -11
- package/src/lib/components/PublicWarningsForm/ValidUntilField/ValidUntilField.spec.d.ts +1 -1
- package/src/lib/components/PublicWarningsForm/ValidUntilField/index.d.ts +1 -1
- package/src/lib/components/PublicWarningsForm/index.d.ts +2 -2
- package/src/lib/components/PublicWarningsFormDialog/PublicWarningsFormDialog.d.ts +21 -21
- package/src/lib/components/PublicWarningsFormDialog/PublicWarningsFormDialog.spec.d.ts +1 -1
- package/src/lib/components/PublicWarningsFormDialog/PublicWarningsFormDialog.stories.d.ts +57 -57
- package/src/lib/components/PublicWarningsFormDialog/PublicWarningsFormDialogConnect.d.ts +16 -16
- package/src/lib/components/PublicWarningsFormDialog/PublicWarningsFormDialogConnect.spec.d.ts +1 -1
- package/src/lib/components/PublicWarningsFormDialog/PublicWarningsFormDialogConnect.stories.d.ts +8 -8
- package/src/lib/components/PublicWarningsFormDialog/WarningsAvatar.d.ts +8 -8
- package/src/lib/components/PublicWarningsFormDialog/index.d.ts +2 -2
- package/src/lib/components/WarningsMapView/WarningsMapView.d.ts +14 -14
- package/src/lib/components/WarningsMapView/WarningsMapView.spec.d.ts +1 -1
- package/src/lib/components/WarningsModuleProvider/WarningsModuleProvider.d.ts +7 -7
- package/src/lib/components/WarningsModuleProvider/index.d.ts +1 -1
- package/src/lib/store/config.d.ts +10 -10
- package/src/lib/store/drawings/listener.d.ts +2 -2
- package/src/lib/store/drawings/reducer.d.ts +13 -13
- package/src/lib/store/drawings/reducer.spec.d.ts +1 -1
- package/src/lib/store/drawings/selectors.d.ts +9 -9
- package/src/lib/store/drawings/selectors.spec.d.ts +1 -1
- package/src/lib/store/drawings/types.d.ts +33 -33
- package/src/lib/store/drawings/utils.d.ts +4 -4
- package/src/lib/store/publicWarningForm/listener.d.ts +2 -2
- package/src/lib/store/publicWarningForm/reducer.d.ts +67 -66
- package/src/lib/store/publicWarningForm/reducer.spec.d.ts +1 -1
- package/src/lib/store/publicWarningForm/selectors.d.ts +53 -53
- package/src/lib/store/publicWarningForm/selectors.spec.d.ts +1 -1
- package/src/lib/store/publicWarningForm/types.d.ts +41 -40
- package/src/lib/store/publicWarningForm/utils.d.ts +2 -2
- package/src/lib/store/publicWarnings/listener.d.ts +3 -3
- package/src/lib/store/publicWarnings/listener.spec.d.ts +1 -1
- package/src/lib/store/publicWarnings/reducer.d.ts +27 -27
- package/src/lib/store/publicWarnings/reducer.spec.d.ts +1 -1
- package/src/lib/store/publicWarnings/selectors.d.ts +36 -36
- package/src/lib/store/publicWarnings/selectors.spec.d.ts +1 -1
- package/src/lib/store/publicWarnings/types.d.ts +39 -39
- package/src/lib/store/publicWarnings/utils.d.ts +23 -23
- package/src/lib/store/publicWarnings/utils.spec.d.ts +1 -1
- package/src/lib/store/types.d.ts +9 -9
- package/src/lib/storybookUtils/defaultStorySettings.d.ts +18 -18
- package/src/lib/storybookUtils/storyComponents.d.ts +7 -7
- package/src/lib/storybookUtils/testUtils.d.ts +3 -3
- package/src/lib/utils/api.d.ts +30 -30
- package/src/lib/utils/api.spec.d.ts +1 -1
- package/src/lib/utils/constants.d.ts +1 -1
- package/src/lib/utils/fakeApi/index.d.ts +7 -7
- package/src/lib/utils/fakeApi.d.ts +6 -6
- package/src/lib/utils/fakeApi.spec.d.ts +1 -1
- package/src/lib/utils/i18n.d.ts +7 -7
- package/src/lib/utils/sig-airmet-util.d.ts +5 -5
- package/src/lib/utils/useFormDirty.d.ts +7 -7
- package/src/lib/utils/useFormDirty.spec.d.ts +1 -1
- package/src/lib/utils/warningUtils.d.ts +12 -7
- package/src/lib/utils/warningUtils.spec.d.ts +1 -1
package/index.esm.js
CHANGED
|
@@ -10,15 +10,15 @@ import { useTranslation } from 'react-i18next';
|
|
|
10
10
|
import '@opengeoweb/core';
|
|
11
11
|
import { FORM_FIELDS_NAMESPACE, useDraftFormHelpers, ReactHookFormSelect, ReactHookFormHiddenInput, isValidGeoJsonCoordinates, ReactHookFormTextField, ReactHookFormProvider, defaultFormOptions, errorMessages, ReactHookFormDateTime, isXHoursBefore, isXHoursAfter, isEmpty } from '@opengeoweb/form-fields';
|
|
12
12
|
import { generateMapId, LayerType, getWMJSMapById, getGeoCoordFromLatLong, WMBBOX } from '@opengeoweb/webmap';
|
|
13
|
-
import { snackbarActions } from '@opengeoweb/snackbar';
|
|
13
|
+
import { snackbarActions, snackbarTypes } from '@opengeoweb/snackbar';
|
|
14
14
|
import * as React from 'react';
|
|
15
15
|
import React__default, { useState, useEffect, useRef } from 'react';
|
|
16
|
-
import { styled, Box, Typography, ListItem,
|
|
16
|
+
import { styled, Box, Typography, ListItem, Grid2, Paper, ListItemButton, Stack, LinearProgress, Button, MenuItem, FormHelperText, Tabs, Tab, Card, CardContent, CircularProgress, Menu, DialogTitle, DialogContent, Switch, ListItemIcon, Checkbox, ListItemText } from '@mui/material';
|
|
17
17
|
import { VariableSizeList } from 'react-window';
|
|
18
18
|
import AutoSizer from 'react-virtualized-auto-sizer';
|
|
19
19
|
import { getApi, createApiInstance, createNonAuthApiInstance, createFakeApiInstance, ApiProvider, ProductStatus, useAirmetList, useSigmetList } from '@opengeoweb/api';
|
|
20
20
|
import { useFormContext } from 'react-hook-form';
|
|
21
|
-
import { isEqual, cloneDeep, clamp } from 'lodash';
|
|
21
|
+
import { isEqual, cloneDeep, clamp, debounce } from 'lodash';
|
|
22
22
|
import { useAuthenticationContext } from '@opengeoweb/authentication';
|
|
23
23
|
import { produce } from 'immer';
|
|
24
24
|
import { isAxiosError } from 'axios';
|
|
@@ -43,8 +43,8 @@ var en = {
|
|
|
43
43
|
"delete-dialog-title": "Delete object",
|
|
44
44
|
"delete-dialog-description": "Are you sure you want to delete",
|
|
45
45
|
"delete-succes": "has been deleted",
|
|
46
|
-
"update-succes": "has been updated",
|
|
47
|
-
"save-succes": "has been saved",
|
|
46
|
+
"update-succes": "Object \"{{objectName}}\" has been updated!",
|
|
47
|
+
"save-succes": "Object \"{{objectName}}\" has been saved!",
|
|
48
48
|
"object-manager-no-objects": "No objects found",
|
|
49
49
|
"object-manager-options-menu": "Object options",
|
|
50
50
|
"object-manager-button-edit": "Edit",
|
|
@@ -116,14 +116,18 @@ var en = {
|
|
|
116
116
|
"warning-list-status-draft": "Drafts",
|
|
117
117
|
"warning-list-status-published": "Published",
|
|
118
118
|
"warning-list-status-todo": "Reviews",
|
|
119
|
-
"warning-list-status-expired": "Expired (last 24 hours)",
|
|
119
|
+
"warning-list-status-expired": "Expired & Withdrawn (last 24 hours)",
|
|
120
120
|
"warning-list-header-incident": "Incident",
|
|
121
|
+
"warning-list-header-incidents": "Incidents",
|
|
121
122
|
"warning-list-header-last-update": "Last update",
|
|
122
123
|
"warning-list-header-start-time": "Start time",
|
|
123
124
|
"warning-list-header-end-time": "End time",
|
|
124
125
|
"warning-list-header-domain": "Domain",
|
|
126
|
+
"warning-list-header-domains": "Domains",
|
|
125
127
|
"warning-list-header-phenomenon": "Phenomenon",
|
|
128
|
+
"warning-list-header-phenomena": "Phenomena",
|
|
126
129
|
"warning-list-header-level": "Level",
|
|
130
|
+
"warning-list-header-levels": "Levels",
|
|
127
131
|
"warning-list-header-status": "Status",
|
|
128
132
|
"warning-list-header-draft": "DRAFT",
|
|
129
133
|
"area-object-loader-title": "Add Areas & Objects",
|
|
@@ -145,8 +149,10 @@ var en = {
|
|
|
145
149
|
"filter-source": "Sources",
|
|
146
150
|
"filter-hide": "Hide {{subject}}",
|
|
147
151
|
"filter-show": "Show {{subject}}",
|
|
148
|
-
|
|
149
|
-
|
|
152
|
+
"filter-only": "ONLY",
|
|
153
|
+
"warning-domain-aviation": "Aviation",
|
|
154
|
+
"warning-domain-maritime": "Maritime",
|
|
155
|
+
"warning-domain-public": "Public",
|
|
150
156
|
"error-title-retry": "Try again",
|
|
151
157
|
"aviation-phenomenon-radioactive-cloud": "Radioactive cloud",
|
|
152
158
|
"aviation-phenomenon-heavy-sandstorm": "Heavy sandstorm",
|
|
@@ -184,7 +190,11 @@ var en = {
|
|
|
184
190
|
"warning-dialog-expire-succes": "Warning has been expired",
|
|
185
191
|
"warning-dialog-expire-title": "Expire warning",
|
|
186
192
|
"warning-dialog-expire-confirm": "Expire",
|
|
187
|
-
"warning-dialog-expire-description": "Are you sure you want to expire this warning?"
|
|
193
|
+
"warning-dialog-expire-description": "Are you sure you want to expire this warning?",
|
|
194
|
+
"warning-dialog-withdraw-succes": "Warning has been withdrawn",
|
|
195
|
+
"warning-dialog-withdraw-title": "Withdraw warning",
|
|
196
|
+
"warning-dialog-withdraw-confirm": "Withdraw",
|
|
197
|
+
"warning-dialog-withdraw-description": "Are you sure you want to withdraw this warning?"
|
|
188
198
|
};
|
|
189
199
|
var nl = {
|
|
190
200
|
"drawing-tool-form-tools": "Gereedschap",
|
|
@@ -206,8 +216,8 @@ var nl = {
|
|
|
206
216
|
"delete-dialog-title": "Object verwijderen",
|
|
207
217
|
"delete-dialog-description": "Weet je zeker dat je dit object wilt verwijderen:",
|
|
208
218
|
"delete-succes": "is verwijderd",
|
|
209
|
-
"update-succes": "is bijgewerkt",
|
|
210
|
-
"save-succes": "is opgeslagen",
|
|
219
|
+
"update-succes": "Object \"{{objectName}}\" is bijgewerkt!",
|
|
220
|
+
"save-succes": "Object \"{{objectName}}\" is opgeslagen!",
|
|
211
221
|
"object-manager-no-objects": "Geen objecten gevonden",
|
|
212
222
|
"object-manager-options-menu": "Object acties",
|
|
213
223
|
"object-manager-button-edit": "Bewerken",
|
|
@@ -279,14 +289,18 @@ var nl = {
|
|
|
279
289
|
"warning-list-status-draft": "Concepten",
|
|
280
290
|
"warning-list-status-published": "Gepubliceerd",
|
|
281
291
|
"warning-list-status-todo": "Te doen",
|
|
282
|
-
"warning-list-status-expired": "Verlopen (laatste 24 uur)",
|
|
292
|
+
"warning-list-status-expired": "Verlopen en Ingetrokken (laatste 24 uur)",
|
|
283
293
|
"warning-list-header-incident": "Incident",
|
|
294
|
+
"warning-list-header-incidents": "Incidenten",
|
|
284
295
|
"warning-list-header-last-update": "Laatste update",
|
|
285
296
|
"warning-list-header-start-time": "Starttijd",
|
|
286
297
|
"warning-list-header-end-time": "Eindtijd",
|
|
287
298
|
"warning-list-header-domain": "Domein",
|
|
299
|
+
"warning-list-header-domains": "Domeinen",
|
|
288
300
|
"warning-list-header-phenomenon": "Fenomeen",
|
|
301
|
+
"warning-list-header-phenomena": "Fenomenen",
|
|
289
302
|
"warning-list-header-level": "Niveau",
|
|
303
|
+
"warning-list-header-levels": "Niveaus",
|
|
290
304
|
"warning-list-header-status": "Status",
|
|
291
305
|
"warning-list-header-draft": "CONCEPT",
|
|
292
306
|
"area-object-loader-title": "Gebieden & Objecten toevoegen",
|
|
@@ -306,11 +320,19 @@ var nl = {
|
|
|
306
320
|
"filter-phenomenon": "Fenomenen",
|
|
307
321
|
"filter-level": "Niveaus",
|
|
308
322
|
"filter-source": "Bronnen",
|
|
309
|
-
"error-title-retry": "Probeer opnieuw",
|
|
310
323
|
"warning-dialog-expire-succes": "Waarschuwing laten verlopen is succesvol",
|
|
311
324
|
"warning-dialog-expire-title": "Waarschuwing laten verlopen",
|
|
312
325
|
"warning-dialog-expire-confirm": "Verlopen",
|
|
313
|
-
"warning-dialog-expire-description": "Weet je zeker dat je deze waarschuwing wilt laten verlopen?"
|
|
326
|
+
"warning-dialog-expire-description": "Weet je zeker dat je deze waarschuwing wilt laten verlopen?",
|
|
327
|
+
"warning-dialog-withdraw-succes": "Waarschuwing is succesvol ingetrokken",
|
|
328
|
+
"warning-dialog-withdraw-title": "Waarschuwing intrekken",
|
|
329
|
+
"warning-dialog-withdraw-confirm": "Intrekken",
|
|
330
|
+
"warning-dialog-withdraw-description": "Weet je zeker dat je deze waarschuwing wilt intrekken?",
|
|
331
|
+
"filter-only": "ALLEEN",
|
|
332
|
+
"warning-domain-aviation": "Luchtvaart",
|
|
333
|
+
"warning-domain-maritime": "Maritiem",
|
|
334
|
+
"warning-domain-public": "Publiek",
|
|
335
|
+
"error-title-retry": "Probeer opnieuw"
|
|
314
336
|
};
|
|
315
337
|
var fi = {
|
|
316
338
|
"drawing-tool-form-tools": "Työkalut",
|
|
@@ -332,8 +354,8 @@ var fi = {
|
|
|
332
354
|
"delete-dialog-title": "Poista objekti",
|
|
333
355
|
"delete-dialog-description": "Haluatko varmasti poistaa objektin?",
|
|
334
356
|
"delete-succes": "on poistettu",
|
|
335
|
-
"update-succes": "on päivitetty",
|
|
336
|
-
"save-succes": "on tallennettu",
|
|
357
|
+
"update-succes": "Objekti \"{{objectName}}\" on päivitetty!",
|
|
358
|
+
"save-succes": "Objekti \"{{objectName}}\" on tallennettu!",
|
|
337
359
|
"object-manager-no-objects": "Objektia ei löytynyt",
|
|
338
360
|
"object-manager-options-menu": "Objektin lisävalinnat",
|
|
339
361
|
"object-manager-button-edit": "Muokkaa",
|
|
@@ -407,12 +429,16 @@ var fi = {
|
|
|
407
429
|
"warning-list-status-todo": "Arvostelua",
|
|
408
430
|
"warning-list-status-expired": "Vanhentunutta (viimeiset 24 tuntia)",
|
|
409
431
|
"warning-list-header-incident": "Ongelmaa",
|
|
432
|
+
"warning-list-header-incidents": "Ongelmia",
|
|
410
433
|
"warning-list-header-last-update": "Viimeisin päivitys",
|
|
411
434
|
"warning-list-header-start-time": "Alkamisen ajankohta",
|
|
412
435
|
"warning-list-header-end-time": "Päättymisen ajankohta",
|
|
413
436
|
"warning-list-header-domain": "Domain",
|
|
437
|
+
"warning-list-header-domains": "Domains",
|
|
414
438
|
"warning-list-header-phenomenon": "Sääilmiö",
|
|
439
|
+
"warning-list-header-phenomena": "Sääilmiöt",
|
|
415
440
|
"warning-list-header-level": "Taso",
|
|
441
|
+
"warning-list-header-levels": "Tasot",
|
|
416
442
|
"warning-list-header-status": "Tila",
|
|
417
443
|
"warning-list-header-draft": "LUONNOS",
|
|
418
444
|
"area-object-loader-title": "ei käännetty",
|
|
@@ -432,11 +458,19 @@ var fi = {
|
|
|
432
458
|
"filter-phenomenon": "ei käännetty",
|
|
433
459
|
"filter-level": "ei käännetty",
|
|
434
460
|
"filter-source": "ei käännetty",
|
|
435
|
-
"error-title-retry": "Yritä uudelleen",
|
|
436
461
|
"warning-dialog-expire-succes": "ei käännetty",
|
|
437
462
|
"warning-dialog-expire-title": "ei käännetty",
|
|
438
463
|
"warning-dialog-expire-confirm": "ei käännetty",
|
|
439
|
-
"warning-dialog-expire-description": "ei käännetty"
|
|
464
|
+
"warning-dialog-expire-description": "ei käännetty",
|
|
465
|
+
"warning-dialog-withdraw-succes": "ei käännetty",
|
|
466
|
+
"warning-dialog-withdraw-title": "ei käännetty",
|
|
467
|
+
"warning-dialog-withdraw-confirm": "ei käännetty",
|
|
468
|
+
"warning-dialog-withdraw-description": "ei käännetty",
|
|
469
|
+
"filter-only": "Pelkästään",
|
|
470
|
+
"warning-domain-aviation": "ei käännetty",
|
|
471
|
+
"warning-domain-maritime": "ei käännetty",
|
|
472
|
+
"warning-domain-public": "ei käännetty",
|
|
473
|
+
"error-title-retry": "Yritä uudelleen"
|
|
440
474
|
};
|
|
441
475
|
var no = {
|
|
442
476
|
"drawing-tool-form-tools": "Verktøy",
|
|
@@ -458,8 +492,8 @@ var no = {
|
|
|
458
492
|
"delete-dialog-title": "Slett objekt",
|
|
459
493
|
"delete-dialog-description": "Er du sikker på at du vil slette?",
|
|
460
494
|
"delete-succes": "er slettet",
|
|
461
|
-
"update-succes": "er oppdatert",
|
|
462
|
-
"save-succes": "er lagret",
|
|
495
|
+
"update-succes": "Objekt \"{{objectName}}\" er oppdatert!",
|
|
496
|
+
"save-succes": "Objekt \"{{objectName}}\" er lagret!",
|
|
463
497
|
"object-manager-no-objects": "Fant ingen objekter",
|
|
464
498
|
"object-manager-options-menu": "Objektvalg",
|
|
465
499
|
"object-manager-button-edit": "Endre",
|
|
@@ -533,12 +567,16 @@ var no = {
|
|
|
533
567
|
"warning-list-status-todo": "Til sjekk",
|
|
534
568
|
"warning-list-status-expired": "Utgått (siste 24 timer)",
|
|
535
569
|
"warning-list-header-incident": "Hendelse",
|
|
570
|
+
"warning-list-header-incidents": "Hendelser",
|
|
536
571
|
"warning-list-header-last-update": "Sist oppdatert",
|
|
537
572
|
"warning-list-header-start-time": "Starttid",
|
|
538
573
|
"warning-list-header-end-time": "Sluttid",
|
|
539
574
|
"warning-list-header-domain": "Domene",
|
|
575
|
+
"warning-list-header-domains": "Domener",
|
|
540
576
|
"warning-list-header-phenomenon": "Fenomen",
|
|
541
|
-
"warning-list-header-
|
|
577
|
+
"warning-list-header-phenomena": "Fenomener",
|
|
578
|
+
"warning-list-header-level": "Grad",
|
|
579
|
+
"warning-list-header-levels": "Grad",
|
|
542
580
|
"warning-list-header-status": "Status",
|
|
543
581
|
"warning-list-header-draft": "UTKAST",
|
|
544
582
|
"area-object-loader-title": "Legg til områder og objekter",
|
|
@@ -558,11 +596,19 @@ var no = {
|
|
|
558
596
|
"filter-phenomenon": "Fenomen",
|
|
559
597
|
"filter-level": "Grad",
|
|
560
598
|
"filter-source": "Kilder",
|
|
561
|
-
"error-title-retry": "Prøv igjen",
|
|
562
599
|
"warning-dialog-expire-succes": "ikke oversatt",
|
|
563
600
|
"warning-dialog-expire-title": "ikke oversatt",
|
|
564
601
|
"warning-dialog-expire-confirm": "ikke oversatt",
|
|
565
|
-
"warning-dialog-expire-description": "ikke oversatt"
|
|
602
|
+
"warning-dialog-expire-description": "ikke oversatt",
|
|
603
|
+
"warning-dialog-withdraw-succes": "ikke oversatt",
|
|
604
|
+
"warning-dialog-withdraw-title": "ikke oversatt",
|
|
605
|
+
"warning-dialog-withdraw-confirm": "ikke oversatt",
|
|
606
|
+
"warning-dialog-withdraw-description": "ikke oversatt",
|
|
607
|
+
"filter-only": "BARE",
|
|
608
|
+
"warning-domain-aviation": "ikke oversatt",
|
|
609
|
+
"warning-domain-maritime": "ikke oversatt",
|
|
610
|
+
"warning-domain-public": "ikke oversatt",
|
|
611
|
+
"error-title-retry": "Prøv igjen"
|
|
566
612
|
};
|
|
567
613
|
var warningsTranslations = {
|
|
568
614
|
en: en,
|
|
@@ -1690,43 +1736,43 @@ typeof SuppressedError === "function" ? SuppressedError : function (error, suppr
|
|
|
1690
1736
|
return e.name = "SuppressedError", e.error = error, e.suppressed = suppressed, e;
|
|
1691
1737
|
};
|
|
1692
1738
|
|
|
1693
|
-
/* *
|
|
1694
|
-
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
1695
|
-
* you may not use this file except in compliance with the License.
|
|
1696
|
-
* You may obtain a copy of the License at
|
|
1697
|
-
*
|
|
1698
|
-
* http://www.apache.org/licenses/LICENSE-2.0
|
|
1699
|
-
*
|
|
1700
|
-
* Unless required by applicable law or agreed to in writing, software
|
|
1701
|
-
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
1702
|
-
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
1703
|
-
* See the License for the specific language governing permissions and
|
|
1704
|
-
* limitations under the License.
|
|
1705
|
-
*
|
|
1706
|
-
* Copyright 2023 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
1707
|
-
* Copyright 2023 - Finnish Meteorological Institute (FMI)
|
|
1708
|
-
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
1739
|
+
/* *
|
|
1740
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
1741
|
+
* you may not use this file except in compliance with the License.
|
|
1742
|
+
* You may obtain a copy of the License at
|
|
1743
|
+
*
|
|
1744
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
1745
|
+
*
|
|
1746
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
1747
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
1748
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
1749
|
+
* See the License for the specific language governing permissions and
|
|
1750
|
+
* limitations under the License.
|
|
1751
|
+
*
|
|
1752
|
+
* Copyright 2023 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
1753
|
+
* Copyright 2023 - Finnish Meteorological Institute (FMI)
|
|
1754
|
+
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
1709
1755
|
* */
|
|
1710
1756
|
const objectDialogType = uiTypes.DialogTypes.ObjectManager;
|
|
1711
1757
|
const drawingDialogType = uiTypes.DialogTypes.DrawingTool;
|
|
1712
1758
|
const areaObjectLoaderType = uiTypes.DialogTypes.AreaObjectLoader;
|
|
1713
1759
|
|
|
1714
|
-
/* *
|
|
1715
|
-
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
1716
|
-
* you may not use this file except in compliance with the License.
|
|
1717
|
-
* You may obtain a copy of the License at
|
|
1718
|
-
*
|
|
1719
|
-
* http://www.apache.org/licenses/LICENSE-2.0
|
|
1720
|
-
*
|
|
1721
|
-
* Unless required by applicable law or agreed to in writing, software
|
|
1722
|
-
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
1723
|
-
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
1724
|
-
* See the License for the specific language governing permissions and
|
|
1725
|
-
* limitations under the License.
|
|
1726
|
-
*
|
|
1727
|
-
* Copyright 2023 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
1728
|
-
* Copyright 2023 - Finnish Meteorological Institute (FMI)
|
|
1729
|
-
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
1760
|
+
/* *
|
|
1761
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
1762
|
+
* you may not use this file except in compliance with the License.
|
|
1763
|
+
* You may obtain a copy of the License at
|
|
1764
|
+
*
|
|
1765
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
1766
|
+
*
|
|
1767
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
1768
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
1769
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
1770
|
+
* See the License for the specific language governing permissions and
|
|
1771
|
+
* limitations under the License.
|
|
1772
|
+
*
|
|
1773
|
+
* Copyright 2023 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
1774
|
+
* Copyright 2023 - Finnish Meteorological Institute (FMI)
|
|
1775
|
+
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
1730
1776
|
* */
|
|
1731
1777
|
const drawAdapter = createEntityAdapter({
|
|
1732
1778
|
selectId: draw => draw.drawingInstanceId
|
|
@@ -1808,22 +1854,22 @@ const {
|
|
|
1808
1854
|
} = slice$2;
|
|
1809
1855
|
const drawActions = slice$2.actions;
|
|
1810
1856
|
|
|
1811
|
-
/* *
|
|
1812
|
-
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
1813
|
-
* you may not use this file except in compliance with the License.
|
|
1814
|
-
* You may obtain a copy of the License at
|
|
1815
|
-
*
|
|
1816
|
-
* http://www.apache.org/licenses/LICENSE-2.0
|
|
1817
|
-
*
|
|
1818
|
-
* Unless required by applicable law or agreed to in writing, software
|
|
1819
|
-
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
1820
|
-
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
1821
|
-
* See the License for the specific language governing permissions and
|
|
1822
|
-
* limitations under the License.
|
|
1823
|
-
*
|
|
1824
|
-
* Copyright 2023 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
1825
|
-
* Copyright 2023 - Finnish Meteorological Institute (FMI)
|
|
1826
|
-
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
1857
|
+
/* *
|
|
1858
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
1859
|
+
* you may not use this file except in compliance with the License.
|
|
1860
|
+
* You may obtain a copy of the License at
|
|
1861
|
+
*
|
|
1862
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
1863
|
+
*
|
|
1864
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
1865
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
1866
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
1867
|
+
* See the License for the specific language governing permissions and
|
|
1868
|
+
* limitations under the License.
|
|
1869
|
+
*
|
|
1870
|
+
* Copyright 2023 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
1871
|
+
* Copyright 2023 - Finnish Meteorological Institute (FMI)
|
|
1872
|
+
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
1827
1873
|
* */
|
|
1828
1874
|
const {
|
|
1829
1875
|
selectById: selectDrawByInstanceId
|
|
@@ -1843,22 +1889,22 @@ const translateKeyOutsideComponents = (key, params = undefined) => i18n.t(key, O
|
|
|
1843
1889
|
}, params));
|
|
1844
1890
|
const useWarningsTranslation = () => useTranslation(ns);
|
|
1845
1891
|
|
|
1846
|
-
/* *
|
|
1847
|
-
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
1848
|
-
* you may not use this file except in compliance with the License.
|
|
1849
|
-
* You may obtain a copy of the License at
|
|
1850
|
-
*
|
|
1851
|
-
* http://www.apache.org/licenses/LICENSE-2.0
|
|
1852
|
-
*
|
|
1853
|
-
* Unless required by applicable law or agreed to in writing, software
|
|
1854
|
-
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
1855
|
-
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
1856
|
-
* See the License for the specific language governing permissions and
|
|
1857
|
-
* limitations under the License.
|
|
1858
|
-
*
|
|
1859
|
-
* Copyright 2023 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
1860
|
-
* Copyright 2023 - Finnish Meteorological Institute (FMI)
|
|
1861
|
-
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
1892
|
+
/* *
|
|
1893
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
1894
|
+
* you may not use this file except in compliance with the License.
|
|
1895
|
+
* You may obtain a copy of the License at
|
|
1896
|
+
*
|
|
1897
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
1898
|
+
*
|
|
1899
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
1900
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
1901
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
1902
|
+
* See the License for the specific language governing permissions and
|
|
1903
|
+
* limitations under the License.
|
|
1904
|
+
*
|
|
1905
|
+
* Copyright 2023 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
1906
|
+
* Copyright 2023 - Finnish Meteorological Institute (FMI)
|
|
1907
|
+
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
1862
1908
|
* */
|
|
1863
1909
|
const confirmationDialogOptions = t => {
|
|
1864
1910
|
return {
|
|
@@ -2783,22 +2829,22 @@ $$g({ target: 'Array', proto: true, arity: 1, forced: FORCED$4 }, {
|
|
|
2783
2829
|
}
|
|
2784
2830
|
});
|
|
2785
2831
|
|
|
2786
|
-
/* *
|
|
2787
|
-
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
2788
|
-
* you may not use this file except in compliance with the License.
|
|
2789
|
-
* You may obtain a copy of the License at
|
|
2790
|
-
*
|
|
2791
|
-
* http://www.apache.org/licenses/LICENSE-2.0
|
|
2792
|
-
*
|
|
2793
|
-
* Unless required by applicable law or agreed to in writing, software
|
|
2794
|
-
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
2795
|
-
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
2796
|
-
* See the License for the specific language governing permissions and
|
|
2797
|
-
* limitations under the License.
|
|
2798
|
-
*
|
|
2799
|
-
* Copyright 2023 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
2800
|
-
* Copyright 2023 - Finnish Meteorological Institute (FMI)
|
|
2801
|
-
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
2832
|
+
/* *
|
|
2833
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
2834
|
+
* you may not use this file except in compliance with the License.
|
|
2835
|
+
* You may obtain a copy of the License at
|
|
2836
|
+
*
|
|
2837
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
2838
|
+
*
|
|
2839
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
2840
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
2841
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
2842
|
+
* See the License for the specific language governing permissions and
|
|
2843
|
+
* limitations under the License.
|
|
2844
|
+
*
|
|
2845
|
+
* Copyright 2023 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
2846
|
+
* Copyright 2023 - Finnish Meteorological Institute (FMI)
|
|
2847
|
+
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
2802
2848
|
* */
|
|
2803
2849
|
const DATE_FORMAT_HEADER = 'EEEE, MMMM dd';
|
|
2804
2850
|
|
|
@@ -2959,12 +3005,11 @@ const Objects = ({
|
|
|
2959
3005
|
children: jsx(ListItem, Object.assign({
|
|
2960
3006
|
style: style,
|
|
2961
3007
|
disablePadding: true,
|
|
2962
|
-
secondaryAction: jsxs(
|
|
3008
|
+
secondaryAction: jsxs(Grid2, Object.assign({
|
|
2963
3009
|
container: true,
|
|
2964
3010
|
rowSpacing: 1
|
|
2965
3011
|
}, {
|
|
2966
|
-
children: [jsx(
|
|
2967
|
-
item: true,
|
|
3012
|
+
children: [jsx(Grid2, Object.assign({
|
|
2968
3013
|
className: "objectActions"
|
|
2969
3014
|
}, {
|
|
2970
3015
|
children: jsx(ToggleMenu, {
|
|
@@ -2999,8 +3044,7 @@ const Objects = ({
|
|
|
2999
3044
|
icon: jsx(ExitDomain, {})
|
|
3000
3045
|
}]
|
|
3001
3046
|
})
|
|
3002
|
-
})), object.scope === 'user' && jsx(
|
|
3003
|
-
item: true,
|
|
3047
|
+
})), object.scope === 'user' && jsx(Grid2, Object.assign({
|
|
3004
3048
|
className: "objectActions"
|
|
3005
3049
|
}, {
|
|
3006
3050
|
children: jsx(ToggleMenu, {
|
|
@@ -3198,22 +3242,22 @@ const ObjectManager = ({
|
|
|
3198
3242
|
}));
|
|
3199
3243
|
};
|
|
3200
3244
|
|
|
3201
|
-
/* *
|
|
3202
|
-
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
3203
|
-
* you may not use this file except in compliance with the License.
|
|
3204
|
-
* You may obtain a copy of the License at
|
|
3205
|
-
*
|
|
3206
|
-
* http://www.apache.org/licenses/LICENSE-2.0
|
|
3207
|
-
*
|
|
3208
|
-
* Unless required by applicable law or agreed to in writing, software
|
|
3209
|
-
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
3210
|
-
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
3211
|
-
* See the License for the specific language governing permissions and
|
|
3212
|
-
* limitations under the License.
|
|
3213
|
-
*
|
|
3214
|
-
* Copyright 2023 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
3215
|
-
* Copyright 2023 - Finnish Meteorological Institute (FMI)
|
|
3216
|
-
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
3245
|
+
/* *
|
|
3246
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
3247
|
+
* you may not use this file except in compliance with the License.
|
|
3248
|
+
* You may obtain a copy of the License at
|
|
3249
|
+
*
|
|
3250
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
3251
|
+
*
|
|
3252
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
3253
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
3254
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
3255
|
+
* See the License for the specific language governing permissions and
|
|
3256
|
+
* limitations under the License.
|
|
3257
|
+
*
|
|
3258
|
+
* Copyright 2023 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
3259
|
+
* Copyright 2023 - Finnish Meteorological Institute (FMI)
|
|
3260
|
+
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
3217
3261
|
* */
|
|
3218
3262
|
const API_NAME = 'warnings';
|
|
3219
3263
|
const getIdFromUrl = url => {
|
|
@@ -3330,22 +3374,22 @@ const ConfirmDeleteDialog = ({
|
|
|
3330
3374
|
}));
|
|
3331
3375
|
};
|
|
3332
3376
|
|
|
3333
|
-
/* *
|
|
3334
|
-
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
3335
|
-
* you may not use this file except in compliance with the License.
|
|
3336
|
-
* You may obtain a copy of the License at
|
|
3337
|
-
*
|
|
3338
|
-
* http://www.apache.org/licenses/LICENSE-2.0
|
|
3339
|
-
*
|
|
3340
|
-
* Unless required by applicable law or agreed to in writing, software
|
|
3341
|
-
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
3342
|
-
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
3343
|
-
* See the License for the specific language governing permissions and
|
|
3344
|
-
* limitations under the License.
|
|
3345
|
-
*
|
|
3346
|
-
* Copyright 2023 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
3347
|
-
* Copyright 2023 - Finnish Meteorological Institute (FMI)
|
|
3348
|
-
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
3377
|
+
/* *
|
|
3378
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
3379
|
+
* you may not use this file except in compliance with the License.
|
|
3380
|
+
* You may obtain a copy of the License at
|
|
3381
|
+
*
|
|
3382
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
3383
|
+
*
|
|
3384
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
3385
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
3386
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
3387
|
+
* See the License for the specific language governing permissions and
|
|
3388
|
+
* limitations under the License.
|
|
3389
|
+
*
|
|
3390
|
+
* Copyright 2023 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
3391
|
+
* Copyright 2023 - Finnish Meteorological Institute (FMI)
|
|
3392
|
+
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
3349
3393
|
* */
|
|
3350
3394
|
const publicWarningDialogType = uiTypes.DialogTypes.PublicWarnings;
|
|
3351
3395
|
|
|
@@ -3992,20 +4036,18 @@ const Phenomenon = ({
|
|
|
3992
4036
|
children: warningFormPhenomena.map(phenomenon => jsx(MenuItem, Object.assign({
|
|
3993
4037
|
value: phenomenon.key
|
|
3994
4038
|
}, {
|
|
3995
|
-
children: jsxs(
|
|
4039
|
+
children: jsxs(Grid2, Object.assign({
|
|
3996
4040
|
container: true,
|
|
3997
4041
|
justifyContent: "space-between"
|
|
3998
4042
|
}, {
|
|
3999
|
-
children: [jsx(
|
|
4000
|
-
item: true
|
|
4001
|
-
}, {
|
|
4043
|
+
children: [jsx(Grid2, {
|
|
4002
4044
|
children: t(phenomenon.translationKey)
|
|
4003
|
-
})
|
|
4004
|
-
|
|
4045
|
+
}), jsx(Grid2, Object.assign({
|
|
4046
|
+
sx: {
|
|
4047
|
+
minWidth: 56
|
|
4048
|
+
}
|
|
4005
4049
|
}, {
|
|
4006
|
-
children:
|
|
4007
|
-
children: getPhenomenaIcon(phenomenon.key)
|
|
4008
|
-
})
|
|
4050
|
+
children: getPhenomenaIcon(phenomenon.key)
|
|
4009
4051
|
}))]
|
|
4010
4052
|
}))
|
|
4011
4053
|
}), phenomenon.key))
|
|
@@ -4021,15 +4063,18 @@ var WarningLevel;
|
|
|
4021
4063
|
const LevelColors = {
|
|
4022
4064
|
moderate: {
|
|
4023
4065
|
color: '#FAE21E',
|
|
4024
|
-
textColor: '#051039'
|
|
4066
|
+
textColor: '#051039',
|
|
4067
|
+
borderColor: '#FBFE02'
|
|
4025
4068
|
},
|
|
4026
4069
|
severe: {
|
|
4027
4070
|
color: '#E27000',
|
|
4028
|
-
textColor: '#051039'
|
|
4071
|
+
textColor: '#051039',
|
|
4072
|
+
borderColor: '#FEAE02'
|
|
4029
4073
|
},
|
|
4030
4074
|
extreme: {
|
|
4031
4075
|
color: '#D62A20',
|
|
4032
|
-
textColor: '#ffffff'
|
|
4076
|
+
textColor: '#ffffff',
|
|
4077
|
+
borderColor: '#FF0000'
|
|
4033
4078
|
}
|
|
4034
4079
|
};
|
|
4035
4080
|
const getLevelStyle = levelColor => ({
|
|
@@ -4038,7 +4083,8 @@ const getLevelStyle = levelColor => ({
|
|
|
4038
4083
|
paddingLeft: 0.5,
|
|
4039
4084
|
paddingRight: 0.5,
|
|
4040
4085
|
paddingBottom: '1px',
|
|
4041
|
-
marginLeft: -0.5
|
|
4086
|
+
marginLeft: -0.5,
|
|
4087
|
+
border: levelColor ? `solid 1px ${levelColor.borderColor}` : 'none'
|
|
4042
4088
|
});
|
|
4043
4089
|
const levelOptions = [Object.assign({
|
|
4044
4090
|
translationKey: 'warning-level-moderate',
|
|
@@ -4132,9 +4178,6 @@ const getFilterlistWithTranslationKeys = filterList => filterList.reduce((fiterL
|
|
|
4132
4178
|
const defaultFilters = [{
|
|
4133
4179
|
key: 'incident',
|
|
4134
4180
|
translationKey: 'filter-incident'
|
|
4135
|
-
}, {
|
|
4136
|
-
key: 'domain',
|
|
4137
|
-
translationKey: 'filter-domain'
|
|
4138
4181
|
}, {
|
|
4139
4182
|
key: 'phenomenon',
|
|
4140
4183
|
translationKey: 'filter-phenomenon',
|
|
@@ -4338,22 +4381,22 @@ const {
|
|
|
4338
4381
|
} = slice$1;
|
|
4339
4382
|
const publicWarningActions = slice$1.actions;
|
|
4340
4383
|
|
|
4341
|
-
/* *
|
|
4342
|
-
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
4343
|
-
* you may not use this file except in compliance with the License.
|
|
4344
|
-
* You may obtain a copy of the License at
|
|
4345
|
-
*
|
|
4346
|
-
* http://www.apache.org/licenses/LICENSE-2.0
|
|
4347
|
-
*
|
|
4348
|
-
* Unless required by applicable law or agreed to in writing, software
|
|
4349
|
-
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
4350
|
-
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
4351
|
-
* See the License for the specific language governing permissions and
|
|
4352
|
-
* limitations under the License.
|
|
4353
|
-
*
|
|
4354
|
-
* Copyright 2023 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
4355
|
-
* Copyright 2023 - Finnish Meteorological Institute (FMI)
|
|
4356
|
-
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
4384
|
+
/* *
|
|
4385
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
4386
|
+
* you may not use this file except in compliance with the License.
|
|
4387
|
+
* You may obtain a copy of the License at
|
|
4388
|
+
*
|
|
4389
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
4390
|
+
*
|
|
4391
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
4392
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
4393
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
4394
|
+
* See the License for the specific language governing permissions and
|
|
4395
|
+
* limitations under the License.
|
|
4396
|
+
*
|
|
4397
|
+
* Copyright 2023 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
4398
|
+
* Copyright 2023 - Finnish Meteorological Institute (FMI)
|
|
4399
|
+
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
4357
4400
|
* */
|
|
4358
4401
|
const TAKEOVER_MESSAGE = 'You are no longer the editor of this warning';
|
|
4359
4402
|
const initialState = {};
|
|
@@ -4583,6 +4626,7 @@ const ObjectManagerConnect = ({
|
|
|
4583
4626
|
};
|
|
4584
4627
|
const openSnackbar = message => {
|
|
4585
4628
|
dispatch(snackbarActions.openSnackbar({
|
|
4629
|
+
type: snackbarTypes.SnackbarMessageType.VERBATIM_MESSAGE,
|
|
4586
4630
|
message
|
|
4587
4631
|
}));
|
|
4588
4632
|
};
|
|
@@ -9780,6 +9824,62 @@ var warningListJSON = [
|
|
|
9780
9824
|
descriptionTranslation: "windy"
|
|
9781
9825
|
}
|
|
9782
9826
|
},
|
|
9827
|
+
{
|
|
9828
|
+
id: "3f756602-937d-11ee-a1bf-4k3k3k",
|
|
9829
|
+
lastUpdatedTime: "2023-12-05T16:47:43Z",
|
|
9830
|
+
status: "WITHDRAWN",
|
|
9831
|
+
warningDetail: {
|
|
9832
|
+
phenomenon: "thunderstorm",
|
|
9833
|
+
areas: [
|
|
9834
|
+
{
|
|
9835
|
+
objectName: "test name",
|
|
9836
|
+
geoJSON: {
|
|
9837
|
+
type: "FeatureCollection",
|
|
9838
|
+
features: [
|
|
9839
|
+
{
|
|
9840
|
+
type: "Feature",
|
|
9841
|
+
geometry: {
|
|
9842
|
+
type: "Polygon",
|
|
9843
|
+
coordinates: [
|
|
9844
|
+
[
|
|
9845
|
+
[
|
|
9846
|
+
5.0950448864466225,
|
|
9847
|
+
53.492000941975654
|
|
9848
|
+
],
|
|
9849
|
+
[
|
|
9850
|
+
4.280148780801422,
|
|
9851
|
+
52.46455621916433
|
|
9852
|
+
],
|
|
9853
|
+
[
|
|
9854
|
+
6.878229305858475,
|
|
9855
|
+
52.98133263853793
|
|
9856
|
+
],
|
|
9857
|
+
[
|
|
9858
|
+
5.0950448864466225,
|
|
9859
|
+
53.492000941975654
|
|
9860
|
+
]
|
|
9861
|
+
]
|
|
9862
|
+
]
|
|
9863
|
+
},
|
|
9864
|
+
properties: {
|
|
9865
|
+
fill: "#ff7800",
|
|
9866
|
+
stroke: "#ff7800",
|
|
9867
|
+
"fill-opacity": 0.2,
|
|
9868
|
+
"stroke-width": 2,
|
|
9869
|
+
selectionType: "poly",
|
|
9870
|
+
"stroke-opacity": 1
|
|
9871
|
+
}
|
|
9872
|
+
}
|
|
9873
|
+
]
|
|
9874
|
+
}
|
|
9875
|
+
}
|
|
9876
|
+
],
|
|
9877
|
+
validFrom: "2023-12-07T14:47:34Z",
|
|
9878
|
+
validUntil: "2023-12-09T20:47:34Z",
|
|
9879
|
+
level: "moderate",
|
|
9880
|
+
probability: 50
|
|
9881
|
+
}
|
|
9882
|
+
},
|
|
9783
9883
|
{
|
|
9784
9884
|
id: "4b94edb8-937d-11ee-b619-0ab3cf8a98c1",
|
|
9785
9885
|
lastUpdatedTime: "2023-12-05T14:48:04Z",
|
|
@@ -9894,22 +9994,22 @@ var warningListJSON = [
|
|
|
9894
9994
|
}
|
|
9895
9995
|
];
|
|
9896
9996
|
|
|
9897
|
-
/* *
|
|
9898
|
-
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
9899
|
-
* you may not use this file except in compliance with the License.
|
|
9900
|
-
* You may obtain a copy of the License at
|
|
9901
|
-
*
|
|
9902
|
-
* http://www.apache.org/licenses/LICENSE-2.0
|
|
9903
|
-
*
|
|
9904
|
-
* Unless required by applicable law or agreed to in writing, software
|
|
9905
|
-
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
9906
|
-
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
9907
|
-
* See the License for the specific language governing permissions and
|
|
9908
|
-
* limitations under the License.
|
|
9909
|
-
*
|
|
9910
|
-
* Copyright 2023 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
9911
|
-
* Copyright 2023 - Finnish Meteorological Institute (FMI)
|
|
9912
|
-
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
9997
|
+
/* *
|
|
9998
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
9999
|
+
* you may not use this file except in compliance with the License.
|
|
10000
|
+
* You may obtain a copy of the License at
|
|
10001
|
+
*
|
|
10002
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
10003
|
+
*
|
|
10004
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
10005
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
10006
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
10007
|
+
* See the License for the specific language governing permissions and
|
|
10008
|
+
* limitations under the License.
|
|
10009
|
+
*
|
|
10010
|
+
* Copyright 2023 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
10011
|
+
* Copyright 2023 - Finnish Meteorological Institute (FMI)
|
|
10012
|
+
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
9913
10013
|
* */
|
|
9914
10014
|
const drawingList = drawingListJSON;
|
|
9915
10015
|
const drawingsListFullContent = drawingsListFullContentJSON;
|
|
@@ -10190,22 +10290,22 @@ $$8({ global: true, forced: parseInt !== $parseInt }, {
|
|
|
10190
10290
|
parseInt: $parseInt
|
|
10191
10291
|
});
|
|
10192
10292
|
|
|
10193
|
-
/* *
|
|
10194
|
-
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
10195
|
-
* you may not use this file except in compliance with the License.
|
|
10196
|
-
* You may obtain a copy of the License at
|
|
10197
|
-
*
|
|
10198
|
-
* http://www.apache.org/licenses/LICENSE-2.0
|
|
10199
|
-
*
|
|
10200
|
-
* Unless required by applicable law or agreed to in writing, software
|
|
10201
|
-
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
10202
|
-
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
10203
|
-
* See the License for the specific language governing permissions and
|
|
10204
|
-
* limitations under the License.
|
|
10205
|
-
*
|
|
10206
|
-
* Copyright 2023 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
10207
|
-
* Copyright 2023 - Finnish Meteorological Institute (FMI)
|
|
10208
|
-
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
10293
|
+
/* *
|
|
10294
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
10295
|
+
* you may not use this file except in compliance with the License.
|
|
10296
|
+
* You may obtain a copy of the License at
|
|
10297
|
+
*
|
|
10298
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
10299
|
+
*
|
|
10300
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
10301
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
10302
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
10303
|
+
* See the License for the specific language governing permissions and
|
|
10304
|
+
* limitations under the License.
|
|
10305
|
+
*
|
|
10306
|
+
* Copyright 2023 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
10307
|
+
* Copyright 2023 - Finnish Meteorological Institute (FMI)
|
|
10308
|
+
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
10209
10309
|
* */
|
|
10210
10310
|
const useFormDirty = ({
|
|
10211
10311
|
isDirty,
|
|
@@ -10268,28 +10368,23 @@ const DrawingToolFormContentsNoMemo = ({
|
|
|
10268
10368
|
title: dialogError,
|
|
10269
10369
|
shouldClose: true
|
|
10270
10370
|
})
|
|
10271
|
-
})), jsxs(
|
|
10371
|
+
})), jsxs(Grid2, Object.assign({
|
|
10272
10372
|
"data-testid": "drawingToolForm",
|
|
10273
10373
|
container: true,
|
|
10274
10374
|
direction: "column",
|
|
10275
10375
|
spacing: 1,
|
|
10276
10376
|
padding: 2
|
|
10277
10377
|
}, {
|
|
10278
|
-
children: [jsx(
|
|
10279
|
-
item: true
|
|
10280
|
-
}, {
|
|
10378
|
+
children: [jsx(Grid2, {
|
|
10281
10379
|
children: jsx(Typography, Object.assign({
|
|
10282
10380
|
variant: "body2"
|
|
10283
10381
|
}, {
|
|
10284
10382
|
children: t('drawing-tool-form-tools')
|
|
10285
10383
|
}))
|
|
10286
|
-
})
|
|
10287
|
-
item: true,
|
|
10384
|
+
}), jsx(Grid2, Object.assign({
|
|
10288
10385
|
container: true
|
|
10289
10386
|
}, {
|
|
10290
|
-
children: jsxs(
|
|
10291
|
-
item: true
|
|
10292
|
-
}, {
|
|
10387
|
+
children: jsxs(Grid2, {
|
|
10293
10388
|
children: [drawModes.map(mode => jsx(CustomIconButton, Object.assign({
|
|
10294
10389
|
variant: "tool",
|
|
10295
10390
|
tooltipTitle: mode.title,
|
|
@@ -10331,15 +10426,16 @@ const DrawingToolFormContentsNoMemo = ({
|
|
|
10331
10426
|
}
|
|
10332
10427
|
}
|
|
10333
10428
|
})]
|
|
10334
|
-
})
|
|
10335
|
-
})), jsx(
|
|
10336
|
-
|
|
10337
|
-
|
|
10429
|
+
})
|
|
10430
|
+
})), jsx(Grid2, Object.assign({
|
|
10431
|
+
container: true,
|
|
10432
|
+
size: "grow"
|
|
10338
10433
|
}, {
|
|
10339
|
-
children: jsx(
|
|
10340
|
-
|
|
10341
|
-
|
|
10342
|
-
|
|
10434
|
+
children: jsx(Grid2, Object.assign({
|
|
10435
|
+
size: {
|
|
10436
|
+
xs: 12,
|
|
10437
|
+
sm: 6
|
|
10438
|
+
}
|
|
10343
10439
|
}, {
|
|
10344
10440
|
children: jsx(ReactHookFormSelect, Object.assign({
|
|
10345
10441
|
name: "opacity",
|
|
@@ -10359,9 +10455,7 @@ const DrawingToolFormContentsNoMemo = ({
|
|
|
10359
10455
|
}), opacity))
|
|
10360
10456
|
}))
|
|
10361
10457
|
}))
|
|
10362
|
-
})), jsxs(
|
|
10363
|
-
item: true
|
|
10364
|
-
}, {
|
|
10458
|
+
})), jsxs(Grid2, {
|
|
10365
10459
|
children: [jsx(ReactHookFormTextField, {
|
|
10366
10460
|
name: "objectName",
|
|
10367
10461
|
label: t('drawing-tool-form-object-name'),
|
|
@@ -10375,7 +10469,7 @@ const DrawingToolFormContentsNoMemo = ({
|
|
|
10375
10469
|
}), jsx(ReactHookFormHiddenInput, {
|
|
10376
10470
|
name: "id"
|
|
10377
10471
|
})]
|
|
10378
|
-
})
|
|
10472
|
+
})]
|
|
10379
10473
|
}))]
|
|
10380
10474
|
})), jsx(Box, Object.assign({
|
|
10381
10475
|
sx: {
|
|
@@ -11426,22 +11520,24 @@ const ContainerFormWrapper = styled('div')(({
|
|
|
11426
11520
|
height: 'calc(100% - 88px)'
|
|
11427
11521
|
}
|
|
11428
11522
|
}));
|
|
11523
|
+
const sm6Width = 'calc(100% * 6 / var(--Grid-columns) - (var(--Grid-columns) - 6) * (var(--Grid-columnSpacing) / var(--Grid-columns)))';
|
|
11524
|
+
const sm4Width = 'calc(100% * 4 / var(--Grid-columns) - (var(--Grid-columns) - 4) * (var(--Grid-columnSpacing) / var(--Grid-columns)))';
|
|
11429
11525
|
const ContainerGrid = styled('div')(({
|
|
11430
11526
|
theme
|
|
11431
11527
|
}) => ({
|
|
11432
11528
|
backgroundColor: theme.palette.background.paper,
|
|
11433
|
-
'.
|
|
11529
|
+
'.MuiGrid2-grid-sm-6, .MuiGrid2-grid-sm-4': {
|
|
11434
11530
|
width: '100%',
|
|
11435
11531
|
minWidth: '100%'
|
|
11436
11532
|
},
|
|
11437
11533
|
[containerQueryBreakpoint]: {
|
|
11438
|
-
'.
|
|
11439
|
-
width:
|
|
11440
|
-
minWidth:
|
|
11534
|
+
'.MuiGrid2-grid-sm-6': {
|
|
11535
|
+
width: sm6Width,
|
|
11536
|
+
minWidth: sm6Width
|
|
11441
11537
|
},
|
|
11442
|
-
'.
|
|
11443
|
-
width:
|
|
11444
|
-
minWidth:
|
|
11538
|
+
'.MuiGrid2-grid-sm-4': {
|
|
11539
|
+
width: sm4Width,
|
|
11540
|
+
minWidth: sm4Width
|
|
11445
11541
|
}
|
|
11446
11542
|
}
|
|
11447
11543
|
}));
|
|
@@ -11610,108 +11706,104 @@ const Form = ({
|
|
|
11610
11706
|
shouldClose: true,
|
|
11611
11707
|
severity: _error === null || _error === void 0 ? void 0 : _error.severity
|
|
11612
11708
|
})
|
|
11613
|
-
})), jsxs(
|
|
11709
|
+
})), jsxs(Grid2, Object.assign({
|
|
11710
|
+
size: {
|
|
11711
|
+
xs: 12
|
|
11712
|
+
},
|
|
11614
11713
|
container: true,
|
|
11615
|
-
rowSpacing: 2
|
|
11714
|
+
rowSpacing: 2,
|
|
11715
|
+
columnSpacing: 2
|
|
11616
11716
|
}, {
|
|
11617
|
-
children: [jsx(
|
|
11618
|
-
|
|
11619
|
-
|
|
11717
|
+
children: [jsx(Grid2, Object.assign({
|
|
11718
|
+
size: {
|
|
11719
|
+
xs: 12
|
|
11720
|
+
}
|
|
11620
11721
|
}, {
|
|
11621
11722
|
children: jsx(Phenomenon, {
|
|
11622
11723
|
isDisabled: areFieldsDisabled,
|
|
11623
11724
|
isReadOnly: _isReadOnly2
|
|
11624
11725
|
})
|
|
11625
|
-
})), jsx(
|
|
11626
|
-
|
|
11627
|
-
xs: 12
|
|
11628
|
-
}, {
|
|
11629
|
-
children: jsx(Grid, Object.assign({
|
|
11630
|
-
item: true,
|
|
11726
|
+
})), jsx(Grid2, Object.assign({
|
|
11727
|
+
size: {
|
|
11631
11728
|
xs: 12
|
|
11632
|
-
}
|
|
11633
|
-
children: jsx(AreaField, {
|
|
11634
|
-
onEditObject: () => {},
|
|
11635
|
-
onViewObject: () => {},
|
|
11636
|
-
onDeleteObject: () => {},
|
|
11637
|
-
onAddObject: _onAddObject,
|
|
11638
|
-
isDisabled: areFieldsDisabled || _isReadOnly2
|
|
11639
|
-
})
|
|
11640
|
-
}))
|
|
11641
|
-
})), jsx(Grid, Object.assign({
|
|
11642
|
-
item: true,
|
|
11643
|
-
xs: 12,
|
|
11644
|
-
container: true
|
|
11729
|
+
}
|
|
11645
11730
|
}, {
|
|
11646
|
-
children: jsx(
|
|
11647
|
-
|
|
11731
|
+
children: jsx(AreaField, {
|
|
11732
|
+
onEditObject: () => {},
|
|
11733
|
+
onViewObject: () => {},
|
|
11734
|
+
onDeleteObject: () => {},
|
|
11735
|
+
onAddObject: _onAddObject,
|
|
11736
|
+
isDisabled: areFieldsDisabled || _isReadOnly2
|
|
11737
|
+
})
|
|
11738
|
+
})), jsx(Grid2, Object.assign({
|
|
11739
|
+
size: {
|
|
11648
11740
|
xs: 12
|
|
11649
|
-
}
|
|
11650
|
-
children: jsx(WarningsMapView, {
|
|
11651
|
-
geojsonFeature: geoJSONFeature,
|
|
11652
|
-
defaultBbox: defaultBbox,
|
|
11653
|
-
isSnapshot: _isSnapshot
|
|
11654
|
-
})
|
|
11655
|
-
}))
|
|
11656
|
-
})), jsxs(Grid, Object.assign({
|
|
11657
|
-
item: true,
|
|
11658
|
-
xs: 12,
|
|
11659
|
-
container: true,
|
|
11660
|
-
spacing: 2
|
|
11741
|
+
}
|
|
11661
11742
|
}, {
|
|
11662
|
-
children:
|
|
11663
|
-
|
|
11743
|
+
children: jsx(WarningsMapView, {
|
|
11744
|
+
geojsonFeature: geoJSONFeature,
|
|
11745
|
+
defaultBbox: defaultBbox,
|
|
11746
|
+
isSnapshot: _isSnapshot
|
|
11747
|
+
})
|
|
11748
|
+
})), jsx(Grid2, Object.assign({
|
|
11749
|
+
size: {
|
|
11664
11750
|
xs: 12,
|
|
11665
11751
|
sm: 6
|
|
11666
|
-
}
|
|
11667
|
-
|
|
11668
|
-
|
|
11669
|
-
|
|
11670
|
-
|
|
11671
|
-
})
|
|
11672
|
-
|
|
11752
|
+
}
|
|
11753
|
+
}, {
|
|
11754
|
+
children: jsx(ValidFrom, {
|
|
11755
|
+
isDisabled: areFieldsDisabled,
|
|
11756
|
+
isReadOnly: _isReadOnly2
|
|
11757
|
+
})
|
|
11758
|
+
})), jsx(Grid2, Object.assign({
|
|
11759
|
+
size: {
|
|
11673
11760
|
xs: 12,
|
|
11674
11761
|
sm: 6
|
|
11675
|
-
}
|
|
11676
|
-
|
|
11677
|
-
|
|
11678
|
-
|
|
11679
|
-
|
|
11680
|
-
})
|
|
11681
|
-
})), jsxs(
|
|
11682
|
-
|
|
11683
|
-
|
|
11762
|
+
}
|
|
11763
|
+
}, {
|
|
11764
|
+
children: jsx(ValidUntil, {
|
|
11765
|
+
isDisabled: areFieldsDisabled,
|
|
11766
|
+
isReadOnly: _isReadOnly2
|
|
11767
|
+
})
|
|
11768
|
+
})), jsxs(Grid2, Object.assign({
|
|
11769
|
+
size: {
|
|
11770
|
+
xs: 12
|
|
11771
|
+
},
|
|
11684
11772
|
container: true,
|
|
11685
11773
|
spacing: 2
|
|
11686
11774
|
}, {
|
|
11687
|
-
children: [jsx(
|
|
11688
|
-
|
|
11689
|
-
|
|
11690
|
-
|
|
11775
|
+
children: [jsx(Grid2, Object.assign({
|
|
11776
|
+
size: {
|
|
11777
|
+
xs: 12,
|
|
11778
|
+
sm: 6
|
|
11779
|
+
}
|
|
11691
11780
|
}, {
|
|
11692
11781
|
children: jsx(LevelField, {
|
|
11693
11782
|
isDisabled: areFieldsDisabled,
|
|
11694
11783
|
isReadOnly: _isReadOnly2
|
|
11695
11784
|
})
|
|
11696
|
-
})), jsx(
|
|
11697
|
-
|
|
11698
|
-
|
|
11699
|
-
|
|
11785
|
+
})), jsx(Grid2, Object.assign({
|
|
11786
|
+
size: {
|
|
11787
|
+
xs: 12,
|
|
11788
|
+
sm: 6
|
|
11789
|
+
}
|
|
11700
11790
|
}, {
|
|
11701
11791
|
children: jsx(ProbabilityField, {
|
|
11702
11792
|
isDisabled: areFieldsDisabled,
|
|
11703
11793
|
isReadOnly: _isReadOnly2
|
|
11704
11794
|
})
|
|
11705
11795
|
}))]
|
|
11706
|
-
})), jsx(
|
|
11707
|
-
|
|
11708
|
-
|
|
11796
|
+
})), jsx(Grid2, Object.assign({
|
|
11797
|
+
size: {
|
|
11798
|
+
xs: 12
|
|
11799
|
+
},
|
|
11709
11800
|
container: true,
|
|
11710
11801
|
spacing: 2
|
|
11711
11802
|
}, {
|
|
11712
|
-
children: jsx(
|
|
11713
|
-
|
|
11714
|
-
|
|
11803
|
+
children: jsx(Grid2, Object.assign({
|
|
11804
|
+
size: {
|
|
11805
|
+
xs: 12
|
|
11806
|
+
}
|
|
11715
11807
|
}, {
|
|
11716
11808
|
children: jsx(DescriptionField, {
|
|
11717
11809
|
isDisabled: areFieldsDisabled,
|
|
@@ -11735,14 +11827,15 @@ const Form = ({
|
|
|
11735
11827
|
}
|
|
11736
11828
|
}, {
|
|
11737
11829
|
children: jsx(ContainerGrid, {
|
|
11738
|
-
children: jsxs(
|
|
11830
|
+
children: jsxs(Grid2, Object.assign({
|
|
11739
11831
|
container: true,
|
|
11740
11832
|
spacing: 2
|
|
11741
11833
|
}, {
|
|
11742
|
-
children: [jsx(
|
|
11743
|
-
|
|
11744
|
-
|
|
11745
|
-
|
|
11834
|
+
children: [jsx(Grid2, Object.assign({
|
|
11835
|
+
size: {
|
|
11836
|
+
xs: 12,
|
|
11837
|
+
sm: 4
|
|
11838
|
+
}
|
|
11746
11839
|
}, {
|
|
11747
11840
|
children: jsx(Button, Object.assign({
|
|
11748
11841
|
variant: "tertiary",
|
|
@@ -11755,10 +11848,11 @@ const Form = ({
|
|
|
11755
11848
|
}, {
|
|
11756
11849
|
children: t('warning-button-clear')
|
|
11757
11850
|
}))
|
|
11758
|
-
})), jsx(
|
|
11759
|
-
|
|
11760
|
-
|
|
11761
|
-
|
|
11851
|
+
})), jsx(Grid2, Object.assign({
|
|
11852
|
+
size: {
|
|
11853
|
+
xs: 12,
|
|
11854
|
+
sm: 4
|
|
11855
|
+
}
|
|
11762
11856
|
}, {
|
|
11763
11857
|
children: jsx(Button, Object.assign({
|
|
11764
11858
|
variant: "tertiary",
|
|
@@ -11781,10 +11875,11 @@ const Form = ({
|
|
|
11781
11875
|
})]
|
|
11782
11876
|
}))
|
|
11783
11877
|
}))
|
|
11784
|
-
})), jsx(
|
|
11785
|
-
|
|
11786
|
-
|
|
11787
|
-
|
|
11878
|
+
})), jsx(Grid2, Object.assign({
|
|
11879
|
+
size: {
|
|
11880
|
+
xs: 12,
|
|
11881
|
+
sm: 4
|
|
11882
|
+
}
|
|
11788
11883
|
}, {
|
|
11789
11884
|
children: jsx(Button, Object.assign({
|
|
11790
11885
|
variant: "primary",
|
|
@@ -11828,22 +11923,22 @@ const PublicWarningsForm = props => {
|
|
|
11828
11923
|
}));
|
|
11829
11924
|
};
|
|
11830
11925
|
|
|
11831
|
-
/* *
|
|
11832
|
-
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
11833
|
-
* you may not use this file except in compliance with the License.
|
|
11834
|
-
* You may obtain a copy of the License at
|
|
11835
|
-
*
|
|
11836
|
-
* http://www.apache.org/licenses/LICENSE-2.0
|
|
11837
|
-
*
|
|
11838
|
-
* Unless required by applicable law or agreed to in writing, software
|
|
11839
|
-
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
11840
|
-
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
11841
|
-
* See the License for the specific language governing permissions and
|
|
11842
|
-
* limitations under the License.
|
|
11843
|
-
*
|
|
11844
|
-
* Copyright 2023 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
11845
|
-
* Copyright 2023 - Finnish Meteorological Institute (FMI)
|
|
11846
|
-
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
11926
|
+
/* *
|
|
11927
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
11928
|
+
* you may not use this file except in compliance with the License.
|
|
11929
|
+
* You may obtain a copy of the License at
|
|
11930
|
+
*
|
|
11931
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
11932
|
+
*
|
|
11933
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
11934
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
11935
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
11936
|
+
* See the License for the specific language governing permissions and
|
|
11937
|
+
* limitations under the License.
|
|
11938
|
+
*
|
|
11939
|
+
* Copyright 2023 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
11940
|
+
* Copyright 2023 - Finnish Meteorological Institute (FMI)
|
|
11941
|
+
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
11847
11942
|
* */
|
|
11848
11943
|
const getPublicWarningStore = store => {
|
|
11849
11944
|
if (store && store.publicWarningForm) {
|
|
@@ -11874,22 +11969,22 @@ const getPublicWarningFormError = createSelector(getPublicWarningStore, publicWa
|
|
|
11874
11969
|
const getSelectedPublicWarningId = createSelector(getPublicWarningStore, publicWarningStore => (publicWarningStore === null || publicWarningStore === void 0 ? void 0 : publicWarningStore.selectedPublicWarningId) || '');
|
|
11875
11970
|
const getSelectedPublicIsFormDirty = createSelector(getPublicWarningStore, publicWarningStore => (publicWarningStore === null || publicWarningStore === void 0 ? void 0 : publicWarningStore.isFormDirty) || false);
|
|
11876
11971
|
|
|
11877
|
-
/* *
|
|
11878
|
-
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
11879
|
-
* you may not use this file except in compliance with the License.
|
|
11880
|
-
* You may obtain a copy of the License at
|
|
11881
|
-
*
|
|
11882
|
-
* http://www.apache.org/licenses/LICENSE-2.0
|
|
11883
|
-
*
|
|
11884
|
-
* Unless required by applicable law or agreed to in writing, software
|
|
11885
|
-
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
11886
|
-
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
11887
|
-
* See the License for the specific language governing permissions and
|
|
11888
|
-
* limitations under the License.
|
|
11889
|
-
*
|
|
11890
|
-
* Copyright 2023 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
11891
|
-
* Copyright 2023 - Finnish Meteorological Institute (FMI)
|
|
11892
|
-
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
11972
|
+
/* *
|
|
11973
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
11974
|
+
* you may not use this file except in compliance with the License.
|
|
11975
|
+
* You may obtain a copy of the License at
|
|
11976
|
+
*
|
|
11977
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
11978
|
+
*
|
|
11979
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
11980
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
11981
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
11982
|
+
* See the License for the specific language governing permissions and
|
|
11983
|
+
* limitations under the License.
|
|
11984
|
+
*
|
|
11985
|
+
* Copyright 2023 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
11986
|
+
* Copyright 2023 - Finnish Meteorological Institute (FMI)
|
|
11987
|
+
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
11893
11988
|
* */
|
|
11894
11989
|
var PublicWarningStatus;
|
|
11895
11990
|
(function (PublicWarningStatus) {
|
|
@@ -11899,6 +11994,7 @@ var PublicWarningStatus;
|
|
|
11899
11994
|
PublicWarningStatus["TODO"] = "TODO";
|
|
11900
11995
|
PublicWarningStatus["EXPIRED"] = "EXPIRED";
|
|
11901
11996
|
PublicWarningStatus["IGNORED"] = "IGNORED";
|
|
11997
|
+
PublicWarningStatus["WITHDRAWN"] = "WITHDRAWN";
|
|
11902
11998
|
})(PublicWarningStatus || (PublicWarningStatus = {}));
|
|
11903
11999
|
|
|
11904
12000
|
const PublicWarningsFormConnect = ({
|
|
@@ -13737,7 +13833,7 @@ const PublicWarningsFormDialogConnect = ({
|
|
|
13737
13833
|
};
|
|
13738
13834
|
|
|
13739
13835
|
const actionButton = amount => {
|
|
13740
|
-
return jsxs(
|
|
13836
|
+
return jsxs(Grid2, Object.assign({
|
|
13741
13837
|
container: true,
|
|
13742
13838
|
alignItems: "center",
|
|
13743
13839
|
style: {
|
|
@@ -13824,7 +13920,6 @@ const FilterChipWithOptions = ({
|
|
|
13824
13920
|
children: jsx(FilterChip, {
|
|
13825
13921
|
id: id,
|
|
13826
13922
|
label: label,
|
|
13827
|
-
onAction: onClickOptions,
|
|
13828
13923
|
actionIcon: actionButton(selectedFiltersAmount),
|
|
13829
13924
|
isSelected: isAnyFilterSelected,
|
|
13830
13925
|
handleClick: onClickOptions,
|
|
@@ -13885,7 +13980,7 @@ const FilterChipWithOptions = ({
|
|
|
13885
13980
|
padding: '0px 24px 16px 24px'
|
|
13886
13981
|
}
|
|
13887
13982
|
}, {
|
|
13888
|
-
children: [jsxs(
|
|
13983
|
+
children: [jsxs(Grid2, Object.assign({
|
|
13889
13984
|
container: true,
|
|
13890
13985
|
justifyContent: "space-between",
|
|
13891
13986
|
alignItems: "center"
|
|
@@ -13986,14 +14081,218 @@ const FilterChipWithOptionsConnect = ({
|
|
|
13986
14081
|
}));
|
|
13987
14082
|
};
|
|
13988
14083
|
|
|
14084
|
+
const FilterOption = ({
|
|
14085
|
+
filterId,
|
|
14086
|
+
optionId,
|
|
14087
|
+
checked,
|
|
14088
|
+
onClick,
|
|
14089
|
+
label
|
|
14090
|
+
}) => {
|
|
14091
|
+
const {
|
|
14092
|
+
t
|
|
14093
|
+
} = useWarningsTranslation();
|
|
14094
|
+
const [showOnly, setShowOnly] = useState(false);
|
|
14095
|
+
const updateShowOnly = debounce(show => setShowOnly(show), 100);
|
|
14096
|
+
return jsx(ListItem, Object.assign({
|
|
14097
|
+
disablePadding: true,
|
|
14098
|
+
dense: true,
|
|
14099
|
+
sx: {
|
|
14100
|
+
width: '100%',
|
|
14101
|
+
minWidth: '300px',
|
|
14102
|
+
paddingRight: '0px',
|
|
14103
|
+
marginLeft: '-12px',
|
|
14104
|
+
fontSize: '12px'
|
|
14105
|
+
},
|
|
14106
|
+
secondaryAction: showOnly && jsx(CustomIconButton, Object.assign({
|
|
14107
|
+
"aria-label": `Only ${optionId}`,
|
|
14108
|
+
style: {
|
|
14109
|
+
backgroundColor: 'transparent',
|
|
14110
|
+
width: 'auto'
|
|
14111
|
+
},
|
|
14112
|
+
edge: "end",
|
|
14113
|
+
onClick: () => onClick(!checked, true),
|
|
14114
|
+
onMouseOver: () => updateShowOnly(true),
|
|
14115
|
+
onMouseOut: () => updateShowOnly(false)
|
|
14116
|
+
}, {
|
|
14117
|
+
children: jsx(Typography, Object.assign({
|
|
14118
|
+
sx: {
|
|
14119
|
+
color: 'geowebColors.buttons.primary.default.fill',
|
|
14120
|
+
fontSize: '14px',
|
|
14121
|
+
fontWeight: 500
|
|
14122
|
+
}
|
|
14123
|
+
}, {
|
|
14124
|
+
children: t('filter-only')
|
|
14125
|
+
}))
|
|
14126
|
+
}))
|
|
14127
|
+
}, {
|
|
14128
|
+
children: jsxs(ListItemButton, Object.assign({
|
|
14129
|
+
role: undefined,
|
|
14130
|
+
onClick: () => onClick(!checked),
|
|
14131
|
+
onMouseOver: () => updateShowOnly(true),
|
|
14132
|
+
onMouseOut: () => updateShowOnly(false),
|
|
14133
|
+
dense: true,
|
|
14134
|
+
disableGutters: true,
|
|
14135
|
+
sx: {
|
|
14136
|
+
padding: 0
|
|
14137
|
+
}
|
|
14138
|
+
}, {
|
|
14139
|
+
children: [jsx(ListItemIcon, {
|
|
14140
|
+
children: jsx(Checkbox, {
|
|
14141
|
+
checked: checked,
|
|
14142
|
+
tabIndex: -1,
|
|
14143
|
+
disableRipple: true,
|
|
14144
|
+
inputProps: {
|
|
14145
|
+
'aria-labelledby': optionId,
|
|
14146
|
+
'aria-label': optionId
|
|
14147
|
+
}
|
|
14148
|
+
})
|
|
14149
|
+
}), jsx(ListItemText, {
|
|
14150
|
+
id: optionId,
|
|
14151
|
+
sx: {
|
|
14152
|
+
padding: 0,
|
|
14153
|
+
margin: 0
|
|
14154
|
+
},
|
|
14155
|
+
primary: label || t(`warning-${filterId}-${optionId}`)
|
|
14156
|
+
})]
|
|
14157
|
+
}))
|
|
14158
|
+
}), optionId);
|
|
14159
|
+
};
|
|
14160
|
+
|
|
14161
|
+
const ExpandableFilterChip = ({
|
|
14162
|
+
id,
|
|
14163
|
+
options,
|
|
14164
|
+
updateFilter
|
|
14165
|
+
}) => {
|
|
14166
|
+
const {
|
|
14167
|
+
t
|
|
14168
|
+
} = useWarningsTranslation();
|
|
14169
|
+
const [anchorEl, setAnchorEl] = useState(null);
|
|
14170
|
+
const selectedOptions = Object.keys(options).filter(k => options[k]);
|
|
14171
|
+
const allSelected = selectedOptions.length === Object.keys(options).length;
|
|
14172
|
+
return jsxs(Fragment, {
|
|
14173
|
+
children: [jsx(CustomTooltip, Object.assign({
|
|
14174
|
+
title: t('filter-options'),
|
|
14175
|
+
placement: "bottom"
|
|
14176
|
+
}, {
|
|
14177
|
+
children: jsx("span", Object.assign({
|
|
14178
|
+
style: {
|
|
14179
|
+
margin: 0
|
|
14180
|
+
}
|
|
14181
|
+
}, {
|
|
14182
|
+
children: jsx(FilterChip, {
|
|
14183
|
+
id: id,
|
|
14184
|
+
label: t(`filter-${id}`),
|
|
14185
|
+
isSelected: selectedOptions.length > 0,
|
|
14186
|
+
onClick: ref => setAnchorEl(ref),
|
|
14187
|
+
isDisabled: false,
|
|
14188
|
+
size: "medium",
|
|
14189
|
+
actionIcon: jsxs(Grid2, Object.assign({
|
|
14190
|
+
container: true,
|
|
14191
|
+
alignItems: "center",
|
|
14192
|
+
style: {
|
|
14193
|
+
marginRight: '8px',
|
|
14194
|
+
minWidth: '36px'
|
|
14195
|
+
}
|
|
14196
|
+
}, {
|
|
14197
|
+
children: [jsx(Options, {}), jsx(Typography, Object.assign({
|
|
14198
|
+
variant: "body2",
|
|
14199
|
+
sx: {
|
|
14200
|
+
paddingLeft: 0.5
|
|
14201
|
+
}
|
|
14202
|
+
}, {
|
|
14203
|
+
children: selectedOptions.length > 0 && selectedOptions.length
|
|
14204
|
+
}))]
|
|
14205
|
+
}))
|
|
14206
|
+
})
|
|
14207
|
+
}))
|
|
14208
|
+
})), jsxs(Menu, Object.assign({
|
|
14209
|
+
title: t(`filter-${id}`),
|
|
14210
|
+
open: Boolean(anchorEl),
|
|
14211
|
+
onClose: () => setAnchorEl(null),
|
|
14212
|
+
anchorEl: anchorEl,
|
|
14213
|
+
BackdropProps: {
|
|
14214
|
+
style: {
|
|
14215
|
+
opacity: 0,
|
|
14216
|
+
transition: 'none'
|
|
14217
|
+
}
|
|
14218
|
+
},
|
|
14219
|
+
sx: {
|
|
14220
|
+
padding: 3
|
|
14221
|
+
}
|
|
14222
|
+
}, {
|
|
14223
|
+
children: [jsxs(DialogTitle, Object.assign({
|
|
14224
|
+
id: "dialog-title",
|
|
14225
|
+
sx: {
|
|
14226
|
+
zIndex: 1,
|
|
14227
|
+
padding: '8px 18px 16px 24px',
|
|
14228
|
+
display: 'flex',
|
|
14229
|
+
justifyContent: 'space-between',
|
|
14230
|
+
alignItems: 'center'
|
|
14231
|
+
}
|
|
14232
|
+
}, {
|
|
14233
|
+
children: [jsx(Typography, Object.assign({
|
|
14234
|
+
sx: {
|
|
14235
|
+
fontSize: '20px',
|
|
14236
|
+
fontWeight: 500,
|
|
14237
|
+
paddingRight: 1
|
|
14238
|
+
},
|
|
14239
|
+
"data-testid": "customDialog-title",
|
|
14240
|
+
component: "span"
|
|
14241
|
+
}, {
|
|
14242
|
+
children: t(`filter-${id}`)
|
|
14243
|
+
})), jsx(CustomIconButton, Object.assign({
|
|
14244
|
+
"aria-label": t('close-dialog-confirm'),
|
|
14245
|
+
onClick: () => setAnchorEl(null),
|
|
14246
|
+
sx: {
|
|
14247
|
+
'&.MuiIconButton-root': {
|
|
14248
|
+
color: 'geowebColors.greys.accessible'
|
|
14249
|
+
}
|
|
14250
|
+
}
|
|
14251
|
+
}, {
|
|
14252
|
+
children: jsx(Close, {})
|
|
14253
|
+
}))]
|
|
14254
|
+
})), jsxs(DialogContent, Object.assign({
|
|
14255
|
+
sx: {
|
|
14256
|
+
padding: '0px 24px 16px 24px'
|
|
14257
|
+
}
|
|
14258
|
+
}, {
|
|
14259
|
+
children: [jsxs(Grid2, Object.assign({
|
|
14260
|
+
container: true,
|
|
14261
|
+
justifyContent: "space-between",
|
|
14262
|
+
alignItems: "center"
|
|
14263
|
+
}, {
|
|
14264
|
+
children: [t('filter-select-all'), jsx(Switch, {
|
|
14265
|
+
inputProps: {
|
|
14266
|
+
'aria-label': t('filter-select-all')
|
|
14267
|
+
},
|
|
14268
|
+
checked: allSelected,
|
|
14269
|
+
onChange: () => updateFilter(id, 'ALL', !allSelected),
|
|
14270
|
+
sx: {
|
|
14271
|
+
marginRight: '-12px',
|
|
14272
|
+
marginTop: '-6px'
|
|
14273
|
+
}
|
|
14274
|
+
})]
|
|
14275
|
+
})), jsx(Box, {
|
|
14276
|
+
children: Object.keys(options).map(optionId => {
|
|
14277
|
+
return jsx(FilterOption, {
|
|
14278
|
+
filterId: id,
|
|
14279
|
+
optionId: optionId,
|
|
14280
|
+
checked: options[optionId],
|
|
14281
|
+
onClick: (checked, only) => updateFilter(id, optionId, checked, only)
|
|
14282
|
+
}, `${id}-${optionId}`);
|
|
14283
|
+
})
|
|
14284
|
+
})]
|
|
14285
|
+
}))]
|
|
14286
|
+
}))]
|
|
14287
|
+
});
|
|
14288
|
+
};
|
|
14289
|
+
|
|
13989
14290
|
const FilterList = ({
|
|
13990
14291
|
filters: _filters = [],
|
|
13991
14292
|
onClickAll: _onClickAll = () => {},
|
|
13992
14293
|
isAllSelected: _isAllSelected = true,
|
|
13993
|
-
|
|
13994
|
-
|
|
13995
|
-
setShowSigmet,
|
|
13996
|
-
setShowAirmet
|
|
14294
|
+
filterState,
|
|
14295
|
+
updateFilter
|
|
13997
14296
|
}) => {
|
|
13998
14297
|
const {
|
|
13999
14298
|
t
|
|
@@ -14031,49 +14330,11 @@ const FilterList = ({
|
|
|
14031
14330
|
return jsx(FilterChipWithOptionsConnect, {
|
|
14032
14331
|
filter: filter
|
|
14033
14332
|
}, filter.id);
|
|
14034
|
-
}),
|
|
14035
|
-
|
|
14036
|
-
|
|
14037
|
-
|
|
14038
|
-
|
|
14039
|
-
}),
|
|
14040
|
-
placement: "bottom"
|
|
14041
|
-
}, {
|
|
14042
|
-
children: jsx("span", Object.assign({
|
|
14043
|
-
style: {
|
|
14044
|
-
margin: 0
|
|
14045
|
-
}
|
|
14046
|
-
}, {
|
|
14047
|
-
children: jsx(FilterChip, {
|
|
14048
|
-
id: "sigmet",
|
|
14049
|
-
label: t('sigmet'),
|
|
14050
|
-
isSelected: _showSigmet,
|
|
14051
|
-
handleClick: () => setShowSigmet(!_showSigmet),
|
|
14052
|
-
size: "medium"
|
|
14053
|
-
})
|
|
14054
|
-
}))
|
|
14055
|
-
})), setShowAirmet && jsx(CustomTooltip, Object.assign({
|
|
14056
|
-
title: _showAirmet ? t('filter-hide', {
|
|
14057
|
-
subject: t('airmet')
|
|
14058
|
-
}) : t('filter-show', {
|
|
14059
|
-
subject: t('airmet')
|
|
14060
|
-
}),
|
|
14061
|
-
placement: "bottom"
|
|
14062
|
-
}, {
|
|
14063
|
-
children: jsx("span", Object.assign({
|
|
14064
|
-
style: {
|
|
14065
|
-
margin: 0
|
|
14066
|
-
}
|
|
14067
|
-
}, {
|
|
14068
|
-
children: jsx(FilterChip, {
|
|
14069
|
-
id: "airmet",
|
|
14070
|
-
label: t('airmet'),
|
|
14071
|
-
isSelected: _showAirmet,
|
|
14072
|
-
handleClick: () => setShowAirmet(!_showAirmet),
|
|
14073
|
-
size: "medium"
|
|
14074
|
-
})
|
|
14075
|
-
}))
|
|
14076
|
-
}))]
|
|
14333
|
+
}), filterState && Object.keys(filterState).map(filterId => jsx(ExpandableFilterChip, {
|
|
14334
|
+
id: filterId,
|
|
14335
|
+
options: filterState[filterId],
|
|
14336
|
+
updateFilter: updateFilter
|
|
14337
|
+
}, filterId))]
|
|
14077
14338
|
}));
|
|
14078
14339
|
};
|
|
14079
14340
|
|
|
@@ -14113,98 +14374,6 @@ const WarningListItemSeperator = _a => {
|
|
|
14113
14374
|
}));
|
|
14114
14375
|
};
|
|
14115
14376
|
|
|
14116
|
-
/* *
|
|
14117
|
-
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
14118
|
-
* you may not use this file except in compliance with the License.
|
|
14119
|
-
* You may obtain a copy of the License at
|
|
14120
|
-
*
|
|
14121
|
-
* http://www.apache.org/licenses/LICENSE-2.0
|
|
14122
|
-
*
|
|
14123
|
-
* Unless required by applicable law or agreed to in writing, software
|
|
14124
|
-
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
14125
|
-
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
14126
|
-
* See the License for the specific language governing permissions and
|
|
14127
|
-
* limitations under the License.
|
|
14128
|
-
*
|
|
14129
|
-
* Copyright 2024 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
14130
|
-
* Copyright 2024 - Finnish Meteorological Institute (FMI)
|
|
14131
|
-
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
14132
|
-
* */
|
|
14133
|
-
const transformAirmetToWarningFormat = apiAirmet => {
|
|
14134
|
-
const airmet = apiAirmet.airmet;
|
|
14135
|
-
return {
|
|
14136
|
-
id: apiAirmet.uuid,
|
|
14137
|
-
lastUpdatedTime: apiAirmet.lastUpdateDate,
|
|
14138
|
-
productStatus: airmet.status,
|
|
14139
|
-
warningDetail: {
|
|
14140
|
-
descriptionOriginal: '',
|
|
14141
|
-
descriptionTranslation: '',
|
|
14142
|
-
areas: [{
|
|
14143
|
-
geoJSON: airmet.startGeometry,
|
|
14144
|
-
objectName: airmet.locationIndicatorATSR
|
|
14145
|
-
}],
|
|
14146
|
-
phenomenon: airmet.phenomenon,
|
|
14147
|
-
validFrom: airmet.validDateStart,
|
|
14148
|
-
validUntil: airmet.validDateEnd,
|
|
14149
|
-
level: 'AIR',
|
|
14150
|
-
probability: 0,
|
|
14151
|
-
incident: airmet.sequence
|
|
14152
|
-
}
|
|
14153
|
-
};
|
|
14154
|
-
};
|
|
14155
|
-
const transformSigmetToWarningFormat = apiSigmet => {
|
|
14156
|
-
const sigmet = apiSigmet.sigmet;
|
|
14157
|
-
return {
|
|
14158
|
-
id: apiSigmet.uuid,
|
|
14159
|
-
lastUpdatedTime: apiSigmet.lastUpdateDate,
|
|
14160
|
-
productStatus: sigmet.status,
|
|
14161
|
-
warningDetail: {
|
|
14162
|
-
descriptionOriginal: '',
|
|
14163
|
-
descriptionTranslation: '',
|
|
14164
|
-
areas: [{
|
|
14165
|
-
geoJSON: sigmet.startGeometry,
|
|
14166
|
-
objectName: sigmet.locationIndicatorATSR
|
|
14167
|
-
}],
|
|
14168
|
-
phenomenon: sigmet.phenomenon,
|
|
14169
|
-
validFrom: sigmet.validDateStart,
|
|
14170
|
-
validUntil: sigmet.validDateEnd,
|
|
14171
|
-
level: 'SIG',
|
|
14172
|
-
probability: 0,
|
|
14173
|
-
incident: sigmet.sequence
|
|
14174
|
-
}
|
|
14175
|
-
};
|
|
14176
|
-
};
|
|
14177
|
-
const mapProductStatusToWarningStatus = productStatus => {
|
|
14178
|
-
switch (productStatus) {
|
|
14179
|
-
case ProductStatus.PUBLISHED:
|
|
14180
|
-
return PublicWarningStatus.PUBLISHED;
|
|
14181
|
-
case ProductStatus.DRAFT:
|
|
14182
|
-
return PublicWarningStatus.DRAFT;
|
|
14183
|
-
case ProductStatus.CANCELLED:
|
|
14184
|
-
case ProductStatus.EXPIRED:
|
|
14185
|
-
case ProductStatus.DISCARDED:
|
|
14186
|
-
default:
|
|
14187
|
-
return PublicWarningStatus.EXPIRED;
|
|
14188
|
-
}
|
|
14189
|
-
};
|
|
14190
|
-
|
|
14191
|
-
function useOverflowCheck(text) {
|
|
14192
|
-
const ref = React__default.useRef(null);
|
|
14193
|
-
const [isOverflowing, setIsOverflowing] = React__default.useState(false);
|
|
14194
|
-
React__default.useEffect(() => {
|
|
14195
|
-
const checkOverflow = () => {
|
|
14196
|
-
if (ref.current) {
|
|
14197
|
-
setIsOverflowing(ref.current.scrollWidth > ref.current.clientWidth);
|
|
14198
|
-
}
|
|
14199
|
-
};
|
|
14200
|
-
checkOverflow();
|
|
14201
|
-
}, [text]);
|
|
14202
|
-
return {
|
|
14203
|
-
ref,
|
|
14204
|
-
isOverflowing
|
|
14205
|
-
};
|
|
14206
|
-
}
|
|
14207
|
-
|
|
14208
14377
|
const getSortedStatus = status => {
|
|
14209
14378
|
switch (status) {
|
|
14210
14379
|
case 'DRAFT_PUBLISHED':
|
|
@@ -14256,49 +14425,23 @@ const getWarningWithProposalId = warning => {
|
|
|
14256
14425
|
})
|
|
14257
14426
|
});
|
|
14258
14427
|
};
|
|
14259
|
-
|
|
14260
|
-
const
|
|
14261
|
-
|
|
14262
|
-
|
|
14263
|
-
|
|
14264
|
-
|
|
14265
|
-
|
|
14266
|
-
|
|
14267
|
-
}
|
|
14268
|
-
|
|
14269
|
-
});
|
|
14270
|
-
|
|
14271
|
-
|
|
14272
|
-
|
|
14273
|
-
|
|
14274
|
-
|
|
14275
|
-
|
|
14276
|
-
sx: {
|
|
14277
|
-
height: '16px',
|
|
14278
|
-
padding: '0px',
|
|
14279
|
-
display: 'flex',
|
|
14280
|
-
alignItems: 'center',
|
|
14281
|
-
justifyContent: 'center',
|
|
14282
|
-
color: 'geowebColors.iconButtons.flat.default.color'
|
|
14283
|
-
}
|
|
14284
|
-
}, {
|
|
14285
|
-
children: jsx(Edit, {})
|
|
14286
|
-
}));
|
|
14287
|
-
case 'DRAFT_PUBLISHED':
|
|
14288
|
-
return getStatusTag('Pub', 'green', jsx(Edit, {
|
|
14289
|
-
sx: {
|
|
14290
|
-
width: 20,
|
|
14291
|
-
height: 20,
|
|
14292
|
-
marginTop: '3px'
|
|
14293
|
-
}
|
|
14294
|
-
}));
|
|
14295
|
-
case 'PUBLISHED':
|
|
14296
|
-
return getStatusTag('Pub', 'green');
|
|
14297
|
-
case 'EXPIRED':
|
|
14298
|
-
default:
|
|
14299
|
-
return getStatusTag('Exp', 'grey');
|
|
14300
|
-
}
|
|
14301
|
-
};
|
|
14428
|
+
function useOverflowCheck(text) {
|
|
14429
|
+
const ref = React__default.useRef(null);
|
|
14430
|
+
const [isOverflowing, setIsOverflowing] = React__default.useState(false);
|
|
14431
|
+
React__default.useEffect(() => {
|
|
14432
|
+
const checkOverflow = () => {
|
|
14433
|
+
if (ref.current) {
|
|
14434
|
+
setIsOverflowing(ref.current.scrollWidth > ref.current.clientWidth);
|
|
14435
|
+
}
|
|
14436
|
+
};
|
|
14437
|
+
checkOverflow();
|
|
14438
|
+
}, [text]);
|
|
14439
|
+
return {
|
|
14440
|
+
ref,
|
|
14441
|
+
isOverflowing
|
|
14442
|
+
};
|
|
14443
|
+
}
|
|
14444
|
+
|
|
14302
14445
|
const WarningListColumnContent = _a => {
|
|
14303
14446
|
var {
|
|
14304
14447
|
title,
|
|
@@ -14307,9 +14450,7 @@ const WarningListColumnContent = _a => {
|
|
|
14307
14450
|
width = 76
|
|
14308
14451
|
} = _a,
|
|
14309
14452
|
props = __rest(_a, ["title", "status", "children", "width"]);
|
|
14310
|
-
return jsxs(
|
|
14311
|
-
item: true
|
|
14312
|
-
}, props, {
|
|
14453
|
+
return jsxs(Grid2, Object.assign({
|
|
14313
14454
|
sx: Object.assign(Object.assign({}, props.sx), {
|
|
14314
14455
|
width
|
|
14315
14456
|
})
|
|
@@ -14322,7 +14463,7 @@ const WarningListColumnContent = _a => {
|
|
|
14322
14463
|
fontSize: 10,
|
|
14323
14464
|
lineHeight: 1.6,
|
|
14324
14465
|
height: 12,
|
|
14325
|
-
color: status ===
|
|
14466
|
+
color: status === PublicWarningStatus.EXPIRED || status === PublicWarningStatus.WITHDRAWN ? 'geowebColors.typographyAndIcons.inactiveText' : 'geowebColors.captions.captionStatus.rgba',
|
|
14326
14467
|
display: 'block',
|
|
14327
14468
|
[`@container publicWarningList (min-width: ${breakpoints.desktop}px)`]: {
|
|
14328
14469
|
display: 'none'
|
|
@@ -14335,19 +14476,21 @@ const WarningListColumnContent = _a => {
|
|
|
14335
14476
|
overflow: 'visible',
|
|
14336
14477
|
fontSize: 12,
|
|
14337
14478
|
lineHeight: 1.2,
|
|
14338
|
-
color: status ===
|
|
14479
|
+
color: status === PublicWarningStatus.EXPIRED || status === PublicWarningStatus.WITHDRAWN ? 'geowebColors.typographyAndIcons.inactiveText' : 'geowebColors.typographyAndIcons.text'
|
|
14339
14480
|
}
|
|
14340
14481
|
}, {
|
|
14341
14482
|
children: children || '-'
|
|
14342
14483
|
}))]
|
|
14343
14484
|
}));
|
|
14344
14485
|
};
|
|
14345
|
-
|
|
14486
|
+
|
|
14487
|
+
const WarningListItemMenu = ({
|
|
14346
14488
|
warning,
|
|
14347
14489
|
onEditWarning: _onEditWarning = () => {},
|
|
14348
14490
|
onDeleteWarning: _onDeleteWarning = () => {},
|
|
14349
14491
|
onDeleteReviewWarning: _onDeleteReviewWarning = () => {},
|
|
14350
14492
|
onExpireWarning: _onExpireWarning = () => {},
|
|
14493
|
+
onWithdrawWarning: _onWithdrawWarning = () => {},
|
|
14351
14494
|
t
|
|
14352
14495
|
}) => {
|
|
14353
14496
|
const duplicate = {
|
|
@@ -14358,7 +14501,7 @@ const getMenuItems = ({
|
|
|
14358
14501
|
// disable Expire option if warning is not active
|
|
14359
14502
|
const shouldDisableExpire = !dateUtils.isBetween(dateUtils.getNowUtc(), dateUtils.createDate(warning.warningDetail.validFrom), dateUtils.createDate(warning.warningDetail.validUntil), '[]');
|
|
14360
14503
|
switch (warning.status) {
|
|
14361
|
-
case
|
|
14504
|
+
case PublicWarningStatus.PUBLISHED:
|
|
14362
14505
|
return [{
|
|
14363
14506
|
text: t('warning-list-button-update'),
|
|
14364
14507
|
action: () => _onEditWarning(getWarningWithLinkedToId(warning)),
|
|
@@ -14370,14 +14513,15 @@ const getMenuItems = ({
|
|
|
14370
14513
|
isDisabled: shouldDisableExpire
|
|
14371
14514
|
}, {
|
|
14372
14515
|
text: t('warning-list-button-withdraw'),
|
|
14373
|
-
action: () =>
|
|
14516
|
+
action: () => _onWithdrawWarning(warning),
|
|
14374
14517
|
icon: jsx(Remove, {}),
|
|
14375
|
-
isDisabled:
|
|
14518
|
+
isDisabled: false
|
|
14376
14519
|
}];
|
|
14377
|
-
case
|
|
14520
|
+
case PublicWarningStatus.EXPIRED:
|
|
14521
|
+
case PublicWarningStatus.WITHDRAWN:
|
|
14378
14522
|
return [duplicate];
|
|
14379
|
-
case
|
|
14380
|
-
case
|
|
14523
|
+
case PublicWarningStatus.DRAFT:
|
|
14524
|
+
case PublicWarningStatus.DRAFT_PUBLISHED:
|
|
14381
14525
|
return [{
|
|
14382
14526
|
text: t('object-manager-button-edit'),
|
|
14383
14527
|
action: () => _onEditWarning(warning),
|
|
@@ -14387,7 +14531,7 @@ const getMenuItems = ({
|
|
|
14387
14531
|
action: () => _onDeleteWarning(warning.id, warning.editor),
|
|
14388
14532
|
icon: jsx(Delete, {})
|
|
14389
14533
|
}];
|
|
14390
|
-
case
|
|
14534
|
+
case PublicWarningStatus.TODO:
|
|
14391
14535
|
return [{
|
|
14392
14536
|
text: t('warning-list-button-use'),
|
|
14393
14537
|
action: () => _onEditWarning(getWarningWithProposalId(warning)),
|
|
@@ -14401,19 +14545,162 @@ const getMenuItems = ({
|
|
|
14401
14545
|
return [];
|
|
14402
14546
|
}
|
|
14403
14547
|
};
|
|
14548
|
+
|
|
14549
|
+
/* *
|
|
14550
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
14551
|
+
* you may not use this file except in compliance with the License.
|
|
14552
|
+
* You may obtain a copy of the License at
|
|
14553
|
+
*
|
|
14554
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
14555
|
+
*
|
|
14556
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
14557
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
14558
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
14559
|
+
* See the License for the specific language governing permissions and
|
|
14560
|
+
* limitations under the License.
|
|
14561
|
+
*
|
|
14562
|
+
* Copyright 2024 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
14563
|
+
* Copyright 2024 - Finnish Meteorological Institute (FMI)
|
|
14564
|
+
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
14565
|
+
* */
|
|
14566
|
+
const transformAirmetToWarningFormat = apiAirmet => {
|
|
14567
|
+
const airmet = apiAirmet.airmet;
|
|
14568
|
+
return {
|
|
14569
|
+
id: apiAirmet.uuid,
|
|
14570
|
+
lastUpdatedTime: apiAirmet.lastUpdateDate,
|
|
14571
|
+
productStatus: airmet.status,
|
|
14572
|
+
warningDetail: {
|
|
14573
|
+
descriptionOriginal: '',
|
|
14574
|
+
descriptionTranslation: '',
|
|
14575
|
+
areas: [{
|
|
14576
|
+
geoJSON: airmet.startGeometry,
|
|
14577
|
+
objectName: airmet.locationIndicatorATSR
|
|
14578
|
+
}],
|
|
14579
|
+
phenomenon: airmet.phenomenon,
|
|
14580
|
+
validFrom: airmet.validDateStart,
|
|
14581
|
+
validUntil: airmet.validDateEnd,
|
|
14582
|
+
level: 'AIR',
|
|
14583
|
+
probability: 0,
|
|
14584
|
+
incident: airmet.sequence
|
|
14585
|
+
}
|
|
14586
|
+
};
|
|
14587
|
+
};
|
|
14588
|
+
const transformSigmetToWarningFormat = apiSigmet => {
|
|
14589
|
+
const sigmet = apiSigmet.sigmet;
|
|
14590
|
+
return {
|
|
14591
|
+
id: apiSigmet.uuid,
|
|
14592
|
+
lastUpdatedTime: apiSigmet.lastUpdateDate,
|
|
14593
|
+
productStatus: sigmet.status,
|
|
14594
|
+
warningDetail: {
|
|
14595
|
+
descriptionOriginal: '',
|
|
14596
|
+
descriptionTranslation: '',
|
|
14597
|
+
areas: [{
|
|
14598
|
+
geoJSON: sigmet.startGeometry,
|
|
14599
|
+
objectName: sigmet.locationIndicatorATSR
|
|
14600
|
+
}],
|
|
14601
|
+
phenomenon: sigmet.phenomenon,
|
|
14602
|
+
validFrom: sigmet.validDateStart,
|
|
14603
|
+
validUntil: sigmet.validDateEnd,
|
|
14604
|
+
level: 'SIG',
|
|
14605
|
+
probability: 0,
|
|
14606
|
+
incident: sigmet.sequence
|
|
14607
|
+
}
|
|
14608
|
+
};
|
|
14609
|
+
};
|
|
14610
|
+
const mapProductStatusToWarningStatus = productStatus => {
|
|
14611
|
+
switch (productStatus) {
|
|
14612
|
+
case ProductStatus.PUBLISHED:
|
|
14613
|
+
return PublicWarningStatus.PUBLISHED;
|
|
14614
|
+
case ProductStatus.DRAFT:
|
|
14615
|
+
return PublicWarningStatus.DRAFT;
|
|
14616
|
+
case ProductStatus.CANCELLED:
|
|
14617
|
+
case ProductStatus.EXPIRED:
|
|
14618
|
+
case ProductStatus.DISCARDED:
|
|
14619
|
+
default:
|
|
14620
|
+
return PublicWarningStatus.EXPIRED;
|
|
14621
|
+
}
|
|
14622
|
+
};
|
|
14623
|
+
|
|
14624
|
+
const renderLevelText = levelString => {
|
|
14625
|
+
if (!levelString) {
|
|
14626
|
+
return null;
|
|
14627
|
+
}
|
|
14628
|
+
const firstLetter = levelString[0];
|
|
14629
|
+
const restLetters = levelString.slice(1, levelString.length);
|
|
14630
|
+
return jsxs(Box, {
|
|
14631
|
+
children: [jsx(Box, Object.assign({
|
|
14632
|
+
component: "span",
|
|
14633
|
+
sx: {
|
|
14634
|
+
textTransform: 'uppercase'
|
|
14635
|
+
}
|
|
14636
|
+
}, {
|
|
14637
|
+
children: firstLetter
|
|
14638
|
+
})), jsx(Box, Object.assign({
|
|
14639
|
+
className: "level-suffix",
|
|
14640
|
+
component: "span"
|
|
14641
|
+
}, {
|
|
14642
|
+
children: restLetters
|
|
14643
|
+
}))]
|
|
14644
|
+
});
|
|
14645
|
+
};
|
|
14646
|
+
const renderStatusIcon = status => {
|
|
14647
|
+
const getStatusTag = (content, color, icon = null) => jsx(StatusTag, {
|
|
14648
|
+
content: content,
|
|
14649
|
+
color: color,
|
|
14650
|
+
sx: {
|
|
14651
|
+
width: 'inherit',
|
|
14652
|
+
height: '16px',
|
|
14653
|
+
marginRight: 4
|
|
14654
|
+
},
|
|
14655
|
+
icon: icon
|
|
14656
|
+
});
|
|
14657
|
+
switch (status) {
|
|
14658
|
+
case PublicWarningStatus.TODO:
|
|
14659
|
+
return null;
|
|
14660
|
+
case PublicWarningStatus.DRAFT:
|
|
14661
|
+
return jsx(Box, Object.assign({
|
|
14662
|
+
sx: {
|
|
14663
|
+
height: '16px',
|
|
14664
|
+
padding: '0px',
|
|
14665
|
+
display: 'flex',
|
|
14666
|
+
alignItems: 'center',
|
|
14667
|
+
justifyContent: 'center',
|
|
14668
|
+
color: 'geowebColors.iconButtons.flat.default.color',
|
|
14669
|
+
marginRight: 2
|
|
14670
|
+
}
|
|
14671
|
+
}, {
|
|
14672
|
+
children: jsx(Edit, {})
|
|
14673
|
+
}));
|
|
14674
|
+
case PublicWarningStatus.DRAFT_PUBLISHED:
|
|
14675
|
+
return getStatusTag('Pub', 'green', jsx(Edit, {
|
|
14676
|
+
sx: {
|
|
14677
|
+
width: 20,
|
|
14678
|
+
height: 20,
|
|
14679
|
+
marginTop: '3px'
|
|
14680
|
+
}
|
|
14681
|
+
}));
|
|
14682
|
+
case PublicWarningStatus.PUBLISHED:
|
|
14683
|
+
return getStatusTag('Pub', 'green');
|
|
14684
|
+
case PublicWarningStatus.WITHDRAWN:
|
|
14685
|
+
return getStatusTag('Wdn', 'red');
|
|
14686
|
+
case PublicWarningStatus.EXPIRED:
|
|
14687
|
+
default:
|
|
14688
|
+
return getStatusTag('Exp', 'grey');
|
|
14689
|
+
}
|
|
14690
|
+
};
|
|
14404
14691
|
const WarningListItem = _a => {
|
|
14405
14692
|
var _b, _c;
|
|
14406
14693
|
var {
|
|
14407
14694
|
warning,
|
|
14408
|
-
status,
|
|
14409
14695
|
activeWarningId,
|
|
14410
14696
|
onSelectWarning = () => {},
|
|
14411
14697
|
onEditWarning = () => {},
|
|
14412
14698
|
onDeleteWarning = () => {},
|
|
14413
14699
|
onDeleteReviewWarning = () => {},
|
|
14414
|
-
onExpireWarning = () => {}
|
|
14700
|
+
onExpireWarning = () => {},
|
|
14701
|
+
onWithdrawWarning = () => {}
|
|
14415
14702
|
} = _a,
|
|
14416
|
-
props = __rest(_a, ["warning", "
|
|
14703
|
+
props = __rest(_a, ["warning", "activeWarningId", "onSelectWarning", "onEditWarning", "onDeleteWarning", "onDeleteReviewWarning", "onExpireWarning", "onWithdrawWarning"]);
|
|
14417
14704
|
const {
|
|
14418
14705
|
t
|
|
14419
14706
|
} = useWarningsTranslation();
|
|
@@ -14429,13 +14716,21 @@ const WarningListItem = _a => {
|
|
|
14429
14716
|
isOverflowing: isPhenomenonOverflowing
|
|
14430
14717
|
} = useOverflowCheck(phenomenonText);
|
|
14431
14718
|
const levelDetails = levelOptionsDict[warning.warningDetail.level];
|
|
14719
|
+
const status = warning.status || mapProductStatusToWarningStatus(warning.productStatus);
|
|
14720
|
+
const levelTranslation = levelDetails === null || levelDetails === void 0 ? void 0 : levelDetails.translationKey;
|
|
14721
|
+
const defaultLevelText = React__default.useMemo(() => {
|
|
14722
|
+
if (!levelTranslation) {
|
|
14723
|
+
return '-';
|
|
14724
|
+
}
|
|
14725
|
+
return t(levelTranslation);
|
|
14726
|
+
}, [levelTranslation, t]);
|
|
14432
14727
|
return jsx(ListItem, Object.assign({
|
|
14433
14728
|
sx: {
|
|
14434
14729
|
marginBottom: 0.25,
|
|
14435
14730
|
minHeight: '32px',
|
|
14436
14731
|
padding: '0 0',
|
|
14437
|
-
backgroundColor: status ===
|
|
14438
|
-
borderColor: status ===
|
|
14732
|
+
backgroundColor: status === PublicWarningStatus.EXPIRED || status === PublicWarningStatus.WITHDRAWN ? 'geowebColors.cards.cardContainerDisabled' : 'geowebColors.cards.cardContainer',
|
|
14733
|
+
borderColor: status === PublicWarningStatus.EXPIRED || status === PublicWarningStatus.WITHDRAWN ? 'geowebColors.cards.cardContainerDisabledBorder' : 'geowebColors.cards.cardContainerBorder',
|
|
14439
14734
|
borderRadius: 1,
|
|
14440
14735
|
borderWidth: activeWarningId === warning.id ? '1px' : '1px',
|
|
14441
14736
|
borderStyle: 'solid'
|
|
@@ -14445,13 +14740,14 @@ const WarningListItem = _a => {
|
|
|
14445
14740
|
tooltipTitle: t('warning-list-button-options'),
|
|
14446
14741
|
menuPosition: "bottom",
|
|
14447
14742
|
"aria-label": t('warning-list-button-options'),
|
|
14448
|
-
menuItems:
|
|
14743
|
+
menuItems: WarningListItemMenu({
|
|
14449
14744
|
warning,
|
|
14450
14745
|
t,
|
|
14451
14746
|
onEditWarning,
|
|
14452
14747
|
onDeleteReviewWarning,
|
|
14453
14748
|
onDeleteWarning,
|
|
14454
|
-
onExpireWarning
|
|
14749
|
+
onExpireWarning,
|
|
14750
|
+
onWithdrawWarning
|
|
14455
14751
|
}),
|
|
14456
14752
|
buttonIcon: jsx(Options, {})
|
|
14457
14753
|
}),
|
|
@@ -14474,19 +14770,17 @@ const WarningListItem = _a => {
|
|
|
14474
14770
|
"aria-label": `warning item for ${warning.id}`,
|
|
14475
14771
|
selected: activeWarningId === warning.id
|
|
14476
14772
|
}, {
|
|
14477
|
-
children: jsxs(
|
|
14773
|
+
children: jsxs(Grid2, Object.assign({
|
|
14478
14774
|
className: "warning-list",
|
|
14479
14775
|
container: true,
|
|
14480
|
-
item: true,
|
|
14481
|
-
xs: true,
|
|
14482
14776
|
rowSpacing: 0,
|
|
14483
|
-
columnSpacing:
|
|
14484
|
-
alignItems: "center"
|
|
14777
|
+
columnSpacing: 0,
|
|
14778
|
+
alignItems: "center",
|
|
14779
|
+
size: "grow"
|
|
14485
14780
|
}, {
|
|
14486
14781
|
children: [jsx(WarningListColumnContent, Object.assign({
|
|
14487
14782
|
title: t('warning-list-header-incident'),
|
|
14488
|
-
status: status
|
|
14489
|
-
width: 142
|
|
14783
|
+
status: status
|
|
14490
14784
|
}, {
|
|
14491
14785
|
children: warning.productStatus !== 'DRAFT' ? warning.warningDetail.incident : ''
|
|
14492
14786
|
})), jsx(WarningListColumnContent, Object.assign({
|
|
@@ -14554,7 +14848,7 @@ const WarningListItem = _a => {
|
|
|
14554
14848
|
})), jsx(Box, Object.assign({
|
|
14555
14849
|
sx: {
|
|
14556
14850
|
position: 'absolute',
|
|
14557
|
-
right:
|
|
14851
|
+
right: 16,
|
|
14558
14852
|
bottom: -6
|
|
14559
14853
|
}
|
|
14560
14854
|
}, {
|
|
@@ -14563,31 +14857,39 @@ const WarningListItem = _a => {
|
|
|
14563
14857
|
}))
|
|
14564
14858
|
})), jsx(WarningListColumnContent, Object.assign({
|
|
14565
14859
|
title: t('warning-list-header-level'),
|
|
14566
|
-
status: status
|
|
14860
|
+
status: status,
|
|
14861
|
+
sx: {
|
|
14862
|
+
[`@container publicWarningList (min-width: ${breakpoints.desktop}px)`]: {
|
|
14863
|
+
width: 56
|
|
14864
|
+
}
|
|
14865
|
+
}
|
|
14567
14866
|
}, {
|
|
14568
14867
|
children: jsx(Box, Object.assign({
|
|
14569
14868
|
component: "span",
|
|
14570
|
-
sx: getLevelStyle(levelDetails)
|
|
14869
|
+
sx: Object.assign(Object.assign({}, getLevelStyle(levelDetails)), {
|
|
14870
|
+
fontWeight: 'bold',
|
|
14871
|
+
padding: 0,
|
|
14872
|
+
marginRight: 2,
|
|
14873
|
+
display: 'flex',
|
|
14874
|
+
alignContent: 'center',
|
|
14875
|
+
justifyContent: 'center',
|
|
14876
|
+
flexWrap: 'wrap',
|
|
14877
|
+
[`@container publicWarningList (min-width: ${breakpoints.desktop}px)`]: {
|
|
14878
|
+
marginRight: 0,
|
|
14879
|
+
height: '32px',
|
|
14880
|
+
'.level-suffix': {
|
|
14881
|
+
display: 'none'
|
|
14882
|
+
}
|
|
14883
|
+
}
|
|
14884
|
+
})
|
|
14571
14885
|
}, {
|
|
14572
14886
|
children: (() => {
|
|
14573
|
-
var _a
|
|
14574
|
-
if ((_a = warning.warningDetail) === null || _a === void 0 ? void 0 : _a.level) {
|
|
14575
|
-
|
|
14576
|
-
|
|
14577
|
-
return t(levelDetails.translationKey);
|
|
14578
|
-
}
|
|
14579
|
-
if ((_b = warning.warningDetail) === null || _b === void 0 ? void 0 : _b.level) {
|
|
14580
|
-
// Aviation level
|
|
14581
|
-
return jsx("span", Object.assign({
|
|
14582
|
-
style: {
|
|
14583
|
-
fontWeight: 'bold'
|
|
14584
|
-
}
|
|
14585
|
-
}, {
|
|
14586
|
-
children: warning.warningDetail.level
|
|
14587
|
-
}));
|
|
14588
|
-
}
|
|
14887
|
+
var _a;
|
|
14888
|
+
if (((_a = warning.warningDetail) === null || _a === void 0 ? void 0 : _a.level) && !levelTranslation) {
|
|
14889
|
+
// Show sigmet-airmet level
|
|
14890
|
+
return warning.warningDetail.level;
|
|
14589
14891
|
}
|
|
14590
|
-
return
|
|
14892
|
+
return renderLevelText(defaultLevelText);
|
|
14591
14893
|
})()
|
|
14592
14894
|
}))
|
|
14593
14895
|
})), jsx(WarningListColumnContent, Object.assign({
|
|
@@ -14629,12 +14931,12 @@ const WarningListItem = _a => {
|
|
|
14629
14931
|
position: 'relative'
|
|
14630
14932
|
}
|
|
14631
14933
|
}, {
|
|
14632
|
-
children: [
|
|
14934
|
+
children: [renderStatusIcon(status), warning.editor && jsx(Box, Object.assign({
|
|
14633
14935
|
sx: {
|
|
14634
14936
|
width: '16px',
|
|
14635
14937
|
position: 'absolute',
|
|
14636
14938
|
top: '1px',
|
|
14637
|
-
right: '
|
|
14939
|
+
right: '4px'
|
|
14638
14940
|
}
|
|
14639
14941
|
}, {
|
|
14640
14942
|
children: jsx(WarningAvatar, {
|
|
@@ -14648,29 +14950,57 @@ const WarningListItem = _a => {
|
|
|
14648
14950
|
}), warning.id);
|
|
14649
14951
|
};
|
|
14650
14952
|
|
|
14651
|
-
|
|
14652
|
-
|
|
14653
|
-
|
|
14654
|
-
|
|
14655
|
-
|
|
14656
|
-
|
|
14657
|
-
|
|
14658
|
-
|
|
14659
|
-
|
|
14660
|
-
|
|
14661
|
-
|
|
14662
|
-
|
|
14953
|
+
var Domain;
|
|
14954
|
+
(function (Domain) {
|
|
14955
|
+
Domain["aviation"] = "aviation";
|
|
14956
|
+
Domain["maritime"] = "maritime";
|
|
14957
|
+
Domain["public"] = "public";
|
|
14958
|
+
})(Domain || (Domain = {}));
|
|
14959
|
+
const defaultDomainFilter = {
|
|
14960
|
+
aviation: false,
|
|
14961
|
+
maritime: false,
|
|
14962
|
+
public: true
|
|
14963
|
+
};
|
|
14964
|
+
const useWarningFilters = () => {
|
|
14965
|
+
const [domainFilter, setDomainFilter] = useState(defaultDomainFilter);
|
|
14966
|
+
const updateState = (state, optionKey, value, only) => {
|
|
14967
|
+
if (only) {
|
|
14968
|
+
return Object.keys(state).reduce((acc, k) => Object.assign(Object.assign({}, acc), {
|
|
14969
|
+
[k]: k === optionKey
|
|
14970
|
+
}), {});
|
|
14971
|
+
}
|
|
14972
|
+
return optionKey === 'ALL' ? Object.keys(state).reduce((acc, k) => Object.assign(Object.assign({}, acc), {
|
|
14973
|
+
[k]: value
|
|
14974
|
+
}), {}) : Object.assign(Object.assign({}, state), {
|
|
14975
|
+
[optionKey]: value
|
|
14976
|
+
});
|
|
14977
|
+
};
|
|
14978
|
+
const updateFilter = (filterKey, optionKey, value, only) => {
|
|
14979
|
+
if (filterKey === 'ALL') {
|
|
14980
|
+
return;
|
|
14981
|
+
}
|
|
14982
|
+
if (filterKey === 'domain') {
|
|
14983
|
+
setDomainFilter(state => {
|
|
14984
|
+
return updateState(state, optionKey, value, only);
|
|
14663
14985
|
});
|
|
14664
|
-
resizeObserver.observe(containerRef.current);
|
|
14665
14986
|
}
|
|
14666
|
-
|
|
14667
|
-
|
|
14668
|
-
|
|
14669
|
-
|
|
14670
|
-
|
|
14671
|
-
|
|
14672
|
-
|
|
14987
|
+
};
|
|
14988
|
+
const byFilterState = warning => {
|
|
14989
|
+
const levelDomain = ['SIG', 'AIR'].find(d => d === warning.warningDetail.level) ? Domain.aviation : Domain.public;
|
|
14990
|
+
if (!domainFilter[levelDomain]) {
|
|
14991
|
+
return false;
|
|
14992
|
+
}
|
|
14993
|
+
return true;
|
|
14994
|
+
};
|
|
14995
|
+
return {
|
|
14996
|
+
filterState: {
|
|
14997
|
+
domain: domainFilter
|
|
14998
|
+
},
|
|
14999
|
+
updateFilter,
|
|
15000
|
+
byFilterState
|
|
15001
|
+
};
|
|
14673
15002
|
};
|
|
15003
|
+
|
|
14674
15004
|
const sortWarningsOnStatus = warnings => {
|
|
14675
15005
|
return warnings.reduce((allWarnings, warning) => {
|
|
14676
15006
|
const status = warning.status || mapProductStatusToWarningStatus(warning.productStatus);
|
|
@@ -14689,7 +15019,7 @@ const sortWarningsOnStatus = warnings => {
|
|
|
14689
15019
|
todo: allWarnings === null || allWarnings === void 0 ? void 0 : allWarnings.todo.concat(warning)
|
|
14690
15020
|
});
|
|
14691
15021
|
}
|
|
14692
|
-
if (status === PublicWarningStatus.EXPIRED) {
|
|
15022
|
+
if (status === PublicWarningStatus.EXPIRED || status === PublicWarningStatus.WITHDRAWN) {
|
|
14693
15023
|
return Object.assign(Object.assign({}, allWarnings), {
|
|
14694
15024
|
expired: allWarnings === null || allWarnings === void 0 ? void 0 : allWarnings.expired.concat(warning)
|
|
14695
15025
|
});
|
|
@@ -14708,9 +15038,7 @@ const WarningListHeaderContent = _a => {
|
|
|
14708
15038
|
width = 76
|
|
14709
15039
|
} = _a,
|
|
14710
15040
|
props = __rest(_a, ["title", "width"]);
|
|
14711
|
-
return jsx(
|
|
14712
|
-
item: true
|
|
14713
|
-
}, props, {
|
|
15041
|
+
return jsx(Grid2, Object.assign({
|
|
14714
15042
|
sx: Object.assign(Object.assign({}, props.sx), {
|
|
14715
15043
|
width
|
|
14716
15044
|
})
|
|
@@ -14737,10 +15065,6 @@ const PublicWarningList = ({
|
|
|
14737
15065
|
error,
|
|
14738
15066
|
selectedPublicWarningId: _selectedPublicWarningId = '',
|
|
14739
15067
|
lastUpdatedTime,
|
|
14740
|
-
showSigmet,
|
|
14741
|
-
showAirmet,
|
|
14742
|
-
setShowSigmet,
|
|
14743
|
-
setShowAirmet,
|
|
14744
15068
|
onSelectWarning: _onSelectWarning = () => {},
|
|
14745
15069
|
onEditWarning: _onEditWarning = () => {},
|
|
14746
15070
|
onCreateWarning: _onCreateWarning = () => {},
|
|
@@ -14749,12 +15073,18 @@ const PublicWarningList = ({
|
|
|
14749
15073
|
onDeleteReviewWarning: _onDeleteReviewWarning = () => {},
|
|
14750
15074
|
onClickAllChip: _onClickAllChip = () => {},
|
|
14751
15075
|
onExpireWarning: _onExpireWarning = () => {},
|
|
15076
|
+
onWithdrawWarning: _onWithdrawWarning = () => {},
|
|
14752
15077
|
isAllChipSelected: _isAllChipSelected = true
|
|
14753
15078
|
}) => {
|
|
14754
15079
|
const {
|
|
14755
15080
|
t
|
|
14756
15081
|
} = useWarningsTranslation();
|
|
14757
|
-
const
|
|
15082
|
+
const {
|
|
15083
|
+
filterState,
|
|
15084
|
+
updateFilter,
|
|
15085
|
+
byFilterState
|
|
15086
|
+
} = useWarningFilters();
|
|
15087
|
+
const sortedWarnings = sortWarningsOnStatus(_warnings.filter(byFilterState));
|
|
14758
15088
|
const items = [{
|
|
14759
15089
|
status: PublicWarningStatus.TODO,
|
|
14760
15090
|
totalWarnings: sortedWarnings.todo.length
|
|
@@ -14773,24 +15103,22 @@ const PublicWarningList = ({
|
|
|
14773
15103
|
if (item.totalWarnings !== undefined) {
|
|
14774
15104
|
return 36;
|
|
14775
15105
|
}
|
|
14776
|
-
if (width
|
|
15106
|
+
if (width < 400) {
|
|
14777
15107
|
return 201;
|
|
14778
15108
|
}
|
|
14779
|
-
if (width
|
|
15109
|
+
if (width < 500) {
|
|
14780
15110
|
return 101;
|
|
14781
15111
|
}
|
|
14782
|
-
if (width
|
|
15112
|
+
if (width < breakpoints.tablet) {
|
|
14783
15113
|
return 81;
|
|
14784
15114
|
}
|
|
14785
|
-
if (width
|
|
15115
|
+
if (width < breakpoints.desktop) {
|
|
14786
15116
|
return 71;
|
|
14787
15117
|
}
|
|
14788
15118
|
return 34;
|
|
14789
15119
|
};
|
|
14790
15120
|
const filterRef = React__default.useRef(null);
|
|
14791
|
-
const scrollContainerRef = React__default.useRef(null);
|
|
14792
15121
|
const listRef = React__default.useRef(null);
|
|
14793
|
-
const listInnerRef = React__default.useRef(null);
|
|
14794
15122
|
const resetListIndex = () => {
|
|
14795
15123
|
if (listRef.current) {
|
|
14796
15124
|
listRef.current.resetAfterIndex(0, true);
|
|
@@ -14802,7 +15130,6 @@ const PublicWarningList = ({
|
|
|
14802
15130
|
}
|
|
14803
15131
|
}, [_warnings]);
|
|
14804
15132
|
const filterHeight = useGetFilterHeight(filterRef);
|
|
14805
|
-
const hasScrollbar = useHasScrollbar(scrollContainerRef, listInnerRef);
|
|
14806
15133
|
return jsxs(Box, Object.assign({
|
|
14807
15134
|
sx: {
|
|
14808
15135
|
padding: 3,
|
|
@@ -14813,13 +15140,13 @@ const PublicWarningList = ({
|
|
|
14813
15140
|
},
|
|
14814
15141
|
"data-testid": "publicWarningList"
|
|
14815
15142
|
}, {
|
|
14816
|
-
children: [jsxs(
|
|
15143
|
+
children: [jsxs(Grid2, Object.assign({
|
|
14817
15144
|
container: true,
|
|
14818
15145
|
justifyItems: "flex-end",
|
|
14819
15146
|
ref: filterRef,
|
|
14820
15147
|
sx: {
|
|
14821
15148
|
[`@container publicWarningList (max-width: ${breakpoints.tablet}px)`]: {
|
|
14822
|
-
' .
|
|
15149
|
+
' .MuiGrid2-grid-sm-12': {
|
|
14823
15150
|
maxWidth: '100%',
|
|
14824
15151
|
flexBasis: '100%'
|
|
14825
15152
|
},
|
|
@@ -14832,32 +15159,27 @@ const PublicWarningList = ({
|
|
|
14832
15159
|
}
|
|
14833
15160
|
}
|
|
14834
15161
|
}, {
|
|
14835
|
-
children: [jsx(
|
|
15162
|
+
children: [jsx(Grid2, Object.assign({
|
|
14836
15163
|
className: "warning-filter",
|
|
14837
|
-
item: true,
|
|
14838
|
-
xs: 12,
|
|
14839
|
-
sm: 12,
|
|
14840
|
-
md: 8,
|
|
14841
15164
|
order: {
|
|
14842
15165
|
xs: 2,
|
|
14843
15166
|
md: 1
|
|
15167
|
+
},
|
|
15168
|
+
size: {
|
|
15169
|
+
xs: 12,
|
|
15170
|
+
sm: 12,
|
|
15171
|
+
md: 8
|
|
14844
15172
|
}
|
|
14845
15173
|
}, {
|
|
14846
15174
|
children: jsx(FilterList, {
|
|
14847
15175
|
filters: filters,
|
|
14848
15176
|
isAllSelected: _isAllChipSelected,
|
|
14849
15177
|
onClickAll: _onClickAllChip,
|
|
14850
|
-
|
|
14851
|
-
|
|
14852
|
-
setShowSigmet: setShowSigmet,
|
|
14853
|
-
setShowAirmet: setShowAirmet
|
|
15178
|
+
filterState: filterState,
|
|
15179
|
+
updateFilter: updateFilter
|
|
14854
15180
|
})
|
|
14855
|
-
})), jsxs(
|
|
15181
|
+
})), jsxs(Grid2, Object.assign({
|
|
14856
15182
|
className: "create-warning",
|
|
14857
|
-
item: true,
|
|
14858
|
-
xs: 12,
|
|
14859
|
-
sm: 12,
|
|
14860
|
-
md: 4,
|
|
14861
15183
|
order: {
|
|
14862
15184
|
xs: 1,
|
|
14863
15185
|
md: 2
|
|
@@ -14866,7 +15188,12 @@ const PublicWarningList = ({
|
|
|
14866
15188
|
display: 'flex'
|
|
14867
15189
|
},
|
|
14868
15190
|
justifyContent: "flex-end",
|
|
14869
|
-
alignItems: "self-start"
|
|
15191
|
+
alignItems: "self-start",
|
|
15192
|
+
size: {
|
|
15193
|
+
xs: 12,
|
|
15194
|
+
sm: 12,
|
|
15195
|
+
md: 4
|
|
15196
|
+
}
|
|
14870
15197
|
}, {
|
|
14871
15198
|
children: [lastUpdatedTime && jsx(Box, Object.assign({
|
|
14872
15199
|
sx: {
|
|
@@ -14900,28 +15227,26 @@ const PublicWarningList = ({
|
|
|
14900
15227
|
}), _isLoading && jsx(LinearProgress, {
|
|
14901
15228
|
"data-testid": "loading-bar",
|
|
14902
15229
|
color: "secondary"
|
|
14903
|
-
}), !error && jsxs(
|
|
15230
|
+
}), !error && jsxs(Grid2, Object.assign({
|
|
14904
15231
|
container: true,
|
|
14905
15232
|
rowSpacing: 0,
|
|
14906
|
-
columnSpacing:
|
|
15233
|
+
columnSpacing: 0,
|
|
14907
15234
|
alignItems: "center",
|
|
14908
15235
|
justifyContent: "space-between",
|
|
15236
|
+
size: "grow",
|
|
14909
15237
|
sx: {
|
|
14910
15238
|
maxWidth: '100%',
|
|
14911
15239
|
display: 'none',
|
|
14912
15240
|
marginTop: '4px',
|
|
14913
|
-
[`@container publicWarningList (min-width: ${breakpoints.desktop}px)`]:
|
|
15241
|
+
[`@container publicWarningList (min-width: ${breakpoints.desktop}px)`]: {
|
|
14914
15242
|
display: 'flex'
|
|
14915
|
-
}
|
|
14916
|
-
paddingRight: 2
|
|
14917
|
-
})
|
|
15243
|
+
}
|
|
14918
15244
|
}
|
|
14919
15245
|
}, {
|
|
14920
15246
|
children: [jsx(WarningListHeaderContent, {
|
|
14921
|
-
title: t('warning-list-header-
|
|
14922
|
-
width: 142,
|
|
15247
|
+
title: t('warning-list-header-incidents'),
|
|
14923
15248
|
sx: {
|
|
14924
|
-
|
|
15249
|
+
paddingLeft: 2
|
|
14925
15250
|
}
|
|
14926
15251
|
}), jsx(WarningListHeaderContent, {
|
|
14927
15252
|
title: `${t('warning-list-header-last-update')} UTC`,
|
|
@@ -14933,12 +15258,17 @@ const PublicWarningList = ({
|
|
|
14933
15258
|
title: `${t('warning-list-header-end-time')} UTC`,
|
|
14934
15259
|
width: 142
|
|
14935
15260
|
}), jsx(WarningListHeaderContent, {
|
|
14936
|
-
title: t('warning-list-header-
|
|
15261
|
+
title: t('warning-list-header-domains')
|
|
14937
15262
|
}), jsx(WarningListHeaderContent, {
|
|
14938
|
-
title: t('warning-list-header-
|
|
15263
|
+
title: t('warning-list-header-phenomena'),
|
|
14939
15264
|
width: 140
|
|
14940
15265
|
}), jsx(WarningListHeaderContent, {
|
|
14941
|
-
title: t('warning-list-header-
|
|
15266
|
+
title: t('warning-list-header-levels'),
|
|
15267
|
+
sx: {
|
|
15268
|
+
[`@container publicWarningList (min-width: ${breakpoints.desktop}px)`]: {
|
|
15269
|
+
width: 56
|
|
15270
|
+
}
|
|
15271
|
+
}
|
|
14942
15272
|
}), jsx(WarningListHeaderContent, {
|
|
14943
15273
|
title: t('areas'),
|
|
14944
15274
|
width: 100
|
|
@@ -14954,8 +15284,7 @@ const PublicWarningList = ({
|
|
|
14954
15284
|
sx: {
|
|
14955
15285
|
height: `calc(100% - ${filterHeight}px)`,
|
|
14956
15286
|
minHeight: '206px'
|
|
14957
|
-
}
|
|
14958
|
-
ref: scrollContainerRef
|
|
15287
|
+
}
|
|
14959
15288
|
}, {
|
|
14960
15289
|
children: jsx(AutoSizer, Object.assign({
|
|
14961
15290
|
onResize: resetListIndex
|
|
@@ -14968,8 +15297,7 @@ const PublicWarningList = ({
|
|
|
14968
15297
|
width: _width,
|
|
14969
15298
|
itemCount: items.length,
|
|
14970
15299
|
itemSize: index => getItemSize(index, _width),
|
|
14971
|
-
ref: listRef
|
|
14972
|
-
innerRef: listInnerRef
|
|
15300
|
+
ref: listRef
|
|
14973
15301
|
}, {
|
|
14974
15302
|
children: ({
|
|
14975
15303
|
index,
|
|
@@ -14988,14 +15316,14 @@ const PublicWarningList = ({
|
|
|
14988
15316
|
const publicWarning = warning;
|
|
14989
15317
|
return jsx(WarningListItem, {
|
|
14990
15318
|
style: style,
|
|
14991
|
-
status: publicWarning.status,
|
|
14992
15319
|
warning: publicWarning,
|
|
14993
15320
|
onSelectWarning: _onSelectWarning,
|
|
14994
15321
|
onEditWarning: _onEditWarning,
|
|
14995
15322
|
onDeleteWarning: _onDeleteWarning,
|
|
14996
15323
|
onDeleteReviewWarning: _onDeleteReviewWarning,
|
|
14997
15324
|
activeWarningId: _selectedPublicWarningId,
|
|
14998
|
-
onExpireWarning: _onExpireWarning
|
|
15325
|
+
onExpireWarning: _onExpireWarning,
|
|
15326
|
+
onWithdrawWarning: _onWithdrawWarning
|
|
14999
15327
|
}, key);
|
|
15000
15328
|
}
|
|
15001
15329
|
}))
|
|
@@ -15195,8 +15523,6 @@ const PublicWarningListConnect = () => {
|
|
|
15195
15523
|
refetch: refetchSigmetList,
|
|
15196
15524
|
isFetching: isFetchingSigmet
|
|
15197
15525
|
} = useSigmetList();
|
|
15198
|
-
const [showAirmet, setShowAirmet] = React__default.useState(false);
|
|
15199
|
-
const [showSigmet, setShowSigmet] = React__default.useState(false);
|
|
15200
15526
|
const [confirmDialogOptions, setConfirmDialogOptions] = React__default.useState(undefined);
|
|
15201
15527
|
const filters = useSelector(selectAllFilters);
|
|
15202
15528
|
const isAllChipSelected = useSelector(getIsAllSelected);
|
|
@@ -15253,8 +15579,21 @@ const PublicWarningListConnect = () => {
|
|
|
15253
15579
|
callback: () => onRemoveSuccess(expiredWarning.id, t('warning-dialog-expire-succes'))
|
|
15254
15580
|
});
|
|
15255
15581
|
});
|
|
15582
|
+
const withdrawWarning = warning => __awaiter(void 0, void 0, void 0, function* () {
|
|
15583
|
+
const withdrawWarning = Object.assign(Object.assign({}, warning), {
|
|
15584
|
+
status: PublicWarningStatus.WITHDRAWN
|
|
15585
|
+
});
|
|
15586
|
+
setConfirmDialogOptions({
|
|
15587
|
+
confirmLabel: t('warning-dialog-withdraw-confirm'),
|
|
15588
|
+
title: t('warning-dialog-withdraw-title'),
|
|
15589
|
+
description: t('warning-dialog-withdraw-description'),
|
|
15590
|
+
request: () => warningsApi.updateWarning(withdrawWarning.id, withdrawWarning),
|
|
15591
|
+
callback: () => onRemoveSuccess(withdrawWarning.id, t('warning-dialog-withdraw-succes'))
|
|
15592
|
+
});
|
|
15593
|
+
});
|
|
15256
15594
|
const openSnackbar = message => {
|
|
15257
15595
|
dispatch(snackbarActions.openSnackbar({
|
|
15596
|
+
type: snackbarTypes.SnackbarMessageType.VERBATIM_MESSAGE,
|
|
15258
15597
|
message
|
|
15259
15598
|
}));
|
|
15260
15599
|
};
|
|
@@ -15316,7 +15655,7 @@ const PublicWarningListConnect = () => {
|
|
|
15316
15655
|
}, [dispatch, warnings]);
|
|
15317
15656
|
const transformedSigmets = (sigmetList === null || sigmetList === void 0 ? void 0 : sigmetList.map(transformSigmetToWarningFormat)) || [];
|
|
15318
15657
|
const transformedAirmets = (airmetList === null || airmetList === void 0 ? void 0 : airmetList.map(transformAirmetToWarningFormat)) || [];
|
|
15319
|
-
const combinedWarnings = filteredWarnings.concat(
|
|
15658
|
+
const combinedWarnings = filteredWarnings.concat(transformedSigmets).concat(transformedAirmets).sort((w1, w2) => {
|
|
15320
15659
|
var _a;
|
|
15321
15660
|
return ((_a = w2.lastUpdatedTime) === null || _a === void 0 ? void 0 : _a.localeCompare(w1.lastUpdatedTime || '')) || 0;
|
|
15322
15661
|
});
|
|
@@ -15331,16 +15670,13 @@ const PublicWarningListConnect = () => {
|
|
|
15331
15670
|
onDeleteWarning: deleteWarning,
|
|
15332
15671
|
onDeleteReviewWarning: deleteReviewWarning,
|
|
15333
15672
|
onExpireWarning: expireWarning,
|
|
15673
|
+
onWithdrawWarning: withdrawWarning,
|
|
15334
15674
|
selectedPublicWarningId: selectedPublicWarningId,
|
|
15335
15675
|
lastUpdatedTime: lastUpdatedTime,
|
|
15336
15676
|
onRefetchWarnings: fetchWarnings,
|
|
15337
15677
|
filters: filters,
|
|
15338
15678
|
isAllChipSelected: isAllChipSelected,
|
|
15339
|
-
onClickAllChip: onClickAllChip
|
|
15340
|
-
showSigmet: showSigmet,
|
|
15341
|
-
showAirmet: showAirmet,
|
|
15342
|
-
setShowSigmet: setShowSigmet,
|
|
15343
|
-
setShowAirmet: setShowAirmet
|
|
15679
|
+
onClickAllChip: onClickAllChip
|
|
15344
15680
|
}), confirmDialogOptions && jsx(ConfirmDeleteWarningDialog, {
|
|
15345
15681
|
onClose: () => setConfirmDialogOptions(undefined),
|
|
15346
15682
|
title: confirmDialogOptions.title,
|
|
@@ -15400,7 +15736,7 @@ const componentsLookUp = (payload, apiProps) => {
|
|
|
15400
15736
|
};
|
|
15401
15737
|
|
|
15402
15738
|
const getErrorMessage = error => isAxiosError(error) ? getAxiosErrorMessage(error) : error.message;
|
|
15403
|
-
const getToggleEditorSuccessMessage = isEditor =>
|
|
15739
|
+
const getToggleEditorSuccessMessage = isEditor => isEditor ? 'warning-editor-add-editor' : 'warning-editor-remove-editor';
|
|
15404
15740
|
const publicWarningFormListener = createListenerMiddleware();
|
|
15405
15741
|
publicWarningFormListener.startListening({
|
|
15406
15742
|
actionCreator: publicWarningFormActions.toggleEditorWarning,
|
|
@@ -15421,7 +15757,10 @@ publicWarningFormListener.startListening({
|
|
|
15421
15757
|
listenerApi.dispatch(publicWarningFormActions.toggleEditorWarningSuccess({
|
|
15422
15758
|
isEditor,
|
|
15423
15759
|
username,
|
|
15424
|
-
message:
|
|
15760
|
+
message: {
|
|
15761
|
+
type: snackbarTypes.SnackbarMessageType.TRANSLATABLE_MESSAGE,
|
|
15762
|
+
key: getToggleEditorSuccessMessage(isEditor)
|
|
15763
|
+
}
|
|
15425
15764
|
}));
|
|
15426
15765
|
} catch (error) {
|
|
15427
15766
|
const isDialogOpen = uiSelectors.getisDialogOpen(listenerApi.getState(), publicWarningDialogType);
|
|
@@ -15442,7 +15781,10 @@ publicWarningFormListener.startListening({
|
|
|
15442
15781
|
const publishedWarning = yield saveOrUpdateWarning(publicWarning);
|
|
15443
15782
|
listenerApi.dispatch(publicWarningFormActions.publishWarningSuccess({
|
|
15444
15783
|
publicWarning: publishedWarning,
|
|
15445
|
-
message:
|
|
15784
|
+
message: {
|
|
15785
|
+
type: snackbarTypes.SnackbarMessageType.TRANSLATABLE_MESSAGE,
|
|
15786
|
+
key: 'warning-publish-succes'
|
|
15787
|
+
}
|
|
15446
15788
|
}));
|
|
15447
15789
|
listenerApi.dispatch(uiActions.setToggleOpenDialog({
|
|
15448
15790
|
type: publicWarningDialogType,
|
|
@@ -15467,7 +15809,10 @@ publicWarningFormListener.startListening({
|
|
|
15467
15809
|
const savedWarning = yield saveOrUpdateWarning(publicWarning);
|
|
15468
15810
|
listenerApi.dispatch(publicWarningFormActions.saveWarningSuccess({
|
|
15469
15811
|
publicWarning: savedWarning,
|
|
15470
|
-
message:
|
|
15812
|
+
message: {
|
|
15813
|
+
type: snackbarTypes.SnackbarMessageType.TRANSLATABLE_MESSAGE,
|
|
15814
|
+
key: 'warning-save-succes'
|
|
15815
|
+
}
|
|
15471
15816
|
}));
|
|
15472
15817
|
} catch (error) {
|
|
15473
15818
|
const isDialogOpen = uiSelectors.getisDialogOpen(listenerApi.getState(), publicWarningDialogType);
|
|
@@ -15485,9 +15830,7 @@ publicWarningFormListener.startListening({
|
|
|
15485
15830
|
const {
|
|
15486
15831
|
message
|
|
15487
15832
|
} = payload;
|
|
15488
|
-
listenerApi.dispatch(snackbarActions.openSnackbar(
|
|
15489
|
-
message
|
|
15490
|
-
}));
|
|
15833
|
+
listenerApi.dispatch(snackbarActions.openSnackbar(message));
|
|
15491
15834
|
const isDialogOpen = uiSelectors.getisDialogOpen(listenerApi.getState(), publicWarningDialogType);
|
|
15492
15835
|
toggleDialogLoadingEffect(listenerApi.dispatch, isDialogOpen, false);
|
|
15493
15836
|
})
|
|
@@ -15565,22 +15908,22 @@ publicWarningFormListener.startListening({
|
|
|
15565
15908
|
})
|
|
15566
15909
|
});
|
|
15567
15910
|
|
|
15568
|
-
/* *
|
|
15569
|
-
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
15570
|
-
* you may not use this file except in compliance with the License.
|
|
15571
|
-
* You may obtain a copy of the License at
|
|
15572
|
-
*
|
|
15573
|
-
* http://www.apache.org/licenses/LICENSE-2.0
|
|
15574
|
-
*
|
|
15575
|
-
* Unless required by applicable law or agreed to in writing, software
|
|
15576
|
-
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
15577
|
-
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
15578
|
-
* See the License for the specific language governing permissions and
|
|
15579
|
-
* limitations under the License.
|
|
15580
|
-
*
|
|
15581
|
-
* Copyright 2023 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
15582
|
-
* Copyright 2023 - Finnish Meteorological Institute (FMI)
|
|
15583
|
-
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
15911
|
+
/* *
|
|
15912
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
15913
|
+
* you may not use this file except in compliance with the License.
|
|
15914
|
+
* You may obtain a copy of the License at
|
|
15915
|
+
*
|
|
15916
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
15917
|
+
*
|
|
15918
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
15919
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
15920
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
15921
|
+
* See the License for the specific language governing permissions and
|
|
15922
|
+
* limitations under the License.
|
|
15923
|
+
*
|
|
15924
|
+
* Copyright 2023 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
15925
|
+
* Copyright 2023 - Finnish Meteorological Institute (FMI)
|
|
15926
|
+
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
15584
15927
|
* */
|
|
15585
15928
|
const getLastUpdatedTimeFormatted = () => dateUtils.dateToString(dateUtils.utc(), dateUtils.DATE_FORMAT_HOURS);
|
|
15586
15929
|
const publicWarningsListener = createListenerMiddleware();
|
|
@@ -15621,24 +15964,30 @@ publicWarningsListener.startListening({
|
|
|
15621
15964
|
})
|
|
15622
15965
|
});
|
|
15623
15966
|
|
|
15624
|
-
/* *
|
|
15625
|
-
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
15626
|
-
* you may not use this file except in compliance with the License.
|
|
15627
|
-
* You may obtain a copy of the License at
|
|
15628
|
-
*
|
|
15629
|
-
* http://www.apache.org/licenses/LICENSE-2.0
|
|
15630
|
-
*
|
|
15631
|
-
* Unless required by applicable law or agreed to in writing, software
|
|
15632
|
-
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
15633
|
-
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
15634
|
-
* See the License for the specific language governing permissions and
|
|
15635
|
-
* limitations under the License.
|
|
15636
|
-
*
|
|
15637
|
-
* Copyright 2024 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
15638
|
-
* Copyright 2024 - Finnish Meteorological Institute (FMI)
|
|
15639
|
-
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
15967
|
+
/* *
|
|
15968
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
15969
|
+
* you may not use this file except in compliance with the License.
|
|
15970
|
+
* You may obtain a copy of the License at
|
|
15971
|
+
*
|
|
15972
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
15973
|
+
*
|
|
15974
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
15975
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
15976
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
15977
|
+
* See the License for the specific language governing permissions and
|
|
15978
|
+
* limitations under the License.
|
|
15979
|
+
*
|
|
15980
|
+
* Copyright 2024 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
15981
|
+
* Copyright 2024 - Finnish Meteorological Institute (FMI)
|
|
15982
|
+
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
15640
15983
|
* */
|
|
15641
|
-
const getSnackbarMessage = (objectName, id) =>
|
|
15984
|
+
const getSnackbarMessage = (objectName, id) => ({
|
|
15985
|
+
type: snackbarTypes.SnackbarMessageType.TRANSLATABLE_MESSAGE,
|
|
15986
|
+
key: id ? 'update-succes' : 'save-succes',
|
|
15987
|
+
params: {
|
|
15988
|
+
objectName
|
|
15989
|
+
}
|
|
15990
|
+
});
|
|
15642
15991
|
const drawingsListener = createListenerMiddleware();
|
|
15643
15992
|
drawingsListener.startListening({
|
|
15644
15993
|
actionCreator: drawActions.submitDrawValues,
|
|
@@ -15670,9 +16019,7 @@ drawingsListener.startListening({
|
|
|
15670
16019
|
type: drawingDialogType,
|
|
15671
16020
|
error: ''
|
|
15672
16021
|
}));
|
|
15673
|
-
listenerApi.dispatch(snackbarActions.openSnackbar(
|
|
15674
|
-
message: getSnackbarMessage(formValues.objectName, id)
|
|
15675
|
-
}));
|
|
16022
|
+
listenerApi.dispatch(snackbarActions.openSnackbar(getSnackbarMessage(formValues.objectName, id)));
|
|
15676
16023
|
listenerApi.dispatch(uiActions.toggleIsLoadingDialog({
|
|
15677
16024
|
isLoading: false,
|
|
15678
16025
|
type: drawingDialogType
|
|
@@ -15694,22 +16041,22 @@ drawingsListener.startListening({
|
|
|
15694
16041
|
})
|
|
15695
16042
|
});
|
|
15696
16043
|
|
|
15697
|
-
/* *
|
|
15698
|
-
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
15699
|
-
* you may not use this file except in compliance with the License.
|
|
15700
|
-
* You may obtain a copy of the License at
|
|
15701
|
-
*
|
|
15702
|
-
* http://www.apache.org/licenses/LICENSE-2.0
|
|
15703
|
-
*
|
|
15704
|
-
* Unless required by applicable law or agreed to in writing, software
|
|
15705
|
-
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
15706
|
-
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
15707
|
-
* See the License for the specific language governing permissions and
|
|
15708
|
-
* limitations under the License.
|
|
15709
|
-
*
|
|
15710
|
-
* Copyright 2023 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
15711
|
-
* Copyright 2023 - Finnish Meteorological Institute (FMI)
|
|
15712
|
-
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
16044
|
+
/* *
|
|
16045
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
16046
|
+
* you may not use this file except in compliance with the License.
|
|
16047
|
+
* You may obtain a copy of the License at
|
|
16048
|
+
*
|
|
16049
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
16050
|
+
*
|
|
16051
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
16052
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
16053
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
16054
|
+
* See the License for the specific language governing permissions and
|
|
16055
|
+
* limitations under the License.
|
|
16056
|
+
*
|
|
16057
|
+
* Copyright 2023 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
16058
|
+
* Copyright 2023 - Finnish Meteorological Institute (FMI)
|
|
16059
|
+
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
15713
16060
|
* */
|
|
15714
16061
|
const drawingModuleConfig = {
|
|
15715
16062
|
id: 'drawing-module',
|