@opengeoweb/warnings 9.16.0 → 9.18.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/index.esm.js +1427 -1353
- package/package.json +1 -1
- package/src/lib/components/DrawingTool/DrawingTool.stories.d.ts +2 -2
- package/src/lib/components/ObjectManager/ObjectManager.stories.d.ts +7 -7
- package/src/lib/components/PublicWarningList/PublicWarningList.stories.d.ts +10 -2
- package/src/lib/components/PublicWarningsFormDialog/PublicWarningsFormDialog.stories.d.ts +18 -18
- package/src/lib/utils/constants.d.ts +0 -1
- package/src/lib/utils/i18n.d.ts +4 -413
- package/src/lib/storyshots/Storyshots.spec.d.ts +0 -1
package/index.esm.js
CHANGED
|
@@ -3,23 +3,23 @@ import React__default, { useState, useEffect, useRef } from 'react';
|
|
|
3
3
|
import { useDispatch, useSelector } from 'react-redux';
|
|
4
4
|
import { Polygons, Share, ExitDomain, Edit, Delete, DrawPolygon, Visibility, Add, Wind, Fog, Lightning, Snow, Rain, TemperatureHigh, TemperatureLow, CoastalEvent, breakpoints, Options, VisibilityOff, Success } from '@opengeoweb/theme';
|
|
5
5
|
import { uiTypes, uiActions, getSingularDrawtoolDrawLayerId, drawtoolSelectors, layerSelectors, uiSelectors, mapStoreActions, drawtoolActions, layerActions, useSetupDialog } from '@opengeoweb/store';
|
|
6
|
-
import { emptyGeoJSON, MapControlButton, getIcon, rewindGeometry, getGeoJSONPropertyValue, currentlySupportedDrawModes, MapView, MapViewLayer, defaultLayers, getFeatureExtent } from '@opengeoweb/webmap-react';
|
|
7
|
-
import {
|
|
8
|
-
import { useTranslation } from 'react-i18next';
|
|
6
|
+
import { defaultPolygon, emptyGeoJSON, MapControlButton, getIcon, rewindGeometry, getGeoJSONPropertyValue, currentlySupportedDrawModes, MapView, MapViewLayer, defaultLayers, getFeatureExtent } from '@opengeoweb/webmap-react';
|
|
7
|
+
import { useConfirmationDialog, ToggleMenu, dateUtils, calculateStartSize, ToolContainerDraggable, AlertBanner, ConfirmationDialog, getAxiosErrorMessage, usePrevious, CustomIconButton, CustomTooltip, Avatar, getInitials, SwitchButton, LastUpdateTime, StatusTag, ErrorBoundary, pollingIntervalTimeout, isAxiosError as isAxiosError$1 } from '@opengeoweb/shared';
|
|
9
8
|
import { createEntityAdapter, createSlice, createSelector, createListenerMiddleware, isAnyOf } from '@reduxjs/toolkit';
|
|
10
|
-
import 'i18next';
|
|
9
|
+
import i18n from 'i18next';
|
|
10
|
+
import { useTranslation } from 'react-i18next';
|
|
11
|
+
import { defaultBbox } from '@opengeoweb/core';
|
|
11
12
|
import { snackbarActions } from '@opengeoweb/snackbar';
|
|
12
13
|
import { styled, Box, Typography, ListItem, Grid, Paper, ListItemButton, Stack, LinearProgress, Button, FormHelperText, MenuItem, Tabs, Tab, FormControl, Card, CardContent, ListItemIcon, CircularProgress, List } from '@mui/material';
|
|
13
14
|
import { VariableSizeList } from 'react-window';
|
|
14
15
|
import AutoSizer from 'react-virtualized-auto-sizer';
|
|
15
|
-
import { DATE_FORMAT_FNS, ReactHookFormHiddenInput, isValidGeoJsonCoordinates, ReactHookFormSelect, ReactHookFormTextField, ReactHookFormProvider, defaultFormOptions, useDraftFormHelpers, errorMessages, ReactHookFormDateTime, isValidDate, isXHoursBefore, isXHoursAfter, isEmpty } from '@opengeoweb/form-fields';
|
|
16
16
|
import { getApi, createApiInstance, createNonAuthApiInstance, createFakeApiInstance, ApiProvider } from '@opengeoweb/api';
|
|
17
|
+
import { ReactHookFormHiddenInput, isValidGeoJsonCoordinates, ReactHookFormSelect, ReactHookFormTextField, ReactHookFormProvider, defaultFormOptions, useDraftFormHelpers, errorMessages, ReactHookFormDateTime, isXHoursBefore, isXHoursAfter, isEmpty } from '@opengeoweb/form-fields';
|
|
17
18
|
import { useFormContext } from 'react-hook-form';
|
|
18
19
|
import { isEqual, cloneDeep, clamp } from 'lodash';
|
|
19
20
|
import { useAuthenticationContext } from '@opengeoweb/authentication';
|
|
20
21
|
import { produce } from 'immer';
|
|
21
22
|
import { generateMapId, LayerType, getWMJSMapById, WMBBOX } from '@opengeoweb/webmap';
|
|
22
|
-
import { defaultBbox } from '@opengeoweb/core';
|
|
23
23
|
import { isAxiosError } from 'axios';
|
|
24
24
|
|
|
25
25
|
var en = {
|
|
@@ -124,6 +124,7 @@ var en = {
|
|
|
124
124
|
"warning-list-header-domain": "Domain",
|
|
125
125
|
"warning-list-header-phenomenon": "Phenomenon",
|
|
126
126
|
"warning-list-header-level": "Level",
|
|
127
|
+
"warning-list-header-status": "Status",
|
|
127
128
|
"warning-list-header-draft": "DRAFT"
|
|
128
129
|
};
|
|
129
130
|
var nl = {
|
|
@@ -228,6 +229,7 @@ var nl = {
|
|
|
228
229
|
"warning-list-header-domain": "Domein",
|
|
229
230
|
"warning-list-header-phenomenon": "Fenomeen",
|
|
230
231
|
"warning-list-header-level": "Hoogte",
|
|
232
|
+
"warning-list-header-status": "Status",
|
|
231
233
|
"warning-list-header-draft": "CONCEPT"
|
|
232
234
|
};
|
|
233
235
|
var fi = {
|
|
@@ -332,111 +334,113 @@ var fi = {
|
|
|
332
334
|
"warning-list-header-domain": "ei käännetty",
|
|
333
335
|
"warning-list-header-phenomenon": "ei käännetty",
|
|
334
336
|
"warning-list-header-level": "ei käännetty",
|
|
337
|
+
"warning-list-header-status": "ei käännetty",
|
|
335
338
|
"warning-list-header-draft": "ei käännetty"
|
|
336
339
|
};
|
|
337
340
|
var no = {
|
|
338
|
-
"drawing-tool-form-tools": "
|
|
339
|
-
"drawing-tool-form-opacity": "
|
|
340
|
-
"drawing-tool-form-object-name": "
|
|
341
|
-
"drawing-tool-form-save": "
|
|
342
|
-
"drawing-tool-form-update": "
|
|
343
|
-
"drawing-tool-form-exit-draw-mode": "
|
|
344
|
-
"drawing-tool-form-drawing-required": "
|
|
345
|
-
"close-dialog-cancel": "
|
|
346
|
-
"close-dialog-confirm": "
|
|
347
|
-
"close-draw-dialog-title": "
|
|
348
|
-
"close-dialog-description": "
|
|
349
|
-
"drawing-tool-title": "
|
|
350
|
-
"object-manager-title": "
|
|
351
|
-
"object-manager-add": "
|
|
352
|
-
"delete-dialog-cancel": "
|
|
353
|
-
"delete-dialog-confirm": "
|
|
354
|
-
"delete-dialog-title": "
|
|
355
|
-
"delete-dialog-description": "
|
|
356
|
-
"delete-succes": "
|
|
357
|
-
"update-succes": "
|
|
358
|
-
"save-succes": "
|
|
359
|
-
"object-manager-no-objects": "
|
|
360
|
-
"object-manager-options-menu": "
|
|
361
|
-
"object-manager-button-edit": "
|
|
362
|
-
"object-manager-button-share": "
|
|
363
|
-
"object-manager-button-delete": "
|
|
364
|
-
"object-manager-button-view": "
|
|
365
|
-
"object-manager-no-object-selected": "
|
|
366
|
-
"object-manager-object-selected": "
|
|
367
|
-
"object-manager-share-menu": "
|
|
368
|
-
"public-warning-title": "
|
|
369
|
-
"close-warning-dialog-title": "
|
|
370
|
-
"warning-edit-mode-title": "
|
|
371
|
-
"warning-edit-mode-description": "
|
|
372
|
-
"warning-dialog-cancel": "
|
|
373
|
-
"warning-edit-mode-confirm": "
|
|
374
|
-
"warning-view-mode-title": "
|
|
375
|
-
"warning-view-mode-description": "
|
|
376
|
-
"warning-view-mode-confirm": "
|
|
377
|
-
"warning-probability": "
|
|
378
|
-
"warning-button-clear": "
|
|
379
|
-
"warning-button-save": "
|
|
380
|
-
"warning-button-saving": "
|
|
381
|
-
"warning-button-publish": "
|
|
382
|
-
"warning-button-publishing": "
|
|
383
|
-
"warning-area": "
|
|
384
|
-
"warning-button-add-object": "
|
|
385
|
-
"warning-description-original": "
|
|
386
|
-
"warning-description-translation": "
|
|
387
|
-
"warning-description-NL": "
|
|
388
|
-
"warning-level": "
|
|
389
|
-
"warning-level-moderate": "
|
|
390
|
-
"warning-level-severe": "
|
|
391
|
-
"warning-level-extreme": "
|
|
392
|
-
"warning-phenomenon": "
|
|
393
|
-
"warning-phenomenon-wind": "
|
|
394
|
-
"warning-phenomenon-fog": "
|
|
395
|
-
"warning-phenomenon-thunderstorm": "
|
|
396
|
-
"warning-phenomenon-snow-ice": "
|
|
397
|
-
"warning-phenomenon-rain": "
|
|
398
|
-
"warning-phenomenon-high-temp": "
|
|
399
|
-
"warning-phenomenon-low-temp": "
|
|
400
|
-
"warning-phenomenon-funnel-cloud": "
|
|
401
|
-
"warning-phenomenon-coastal-event": "
|
|
402
|
-
"warning-probability-moderate-level-invalid": "
|
|
403
|
-
"warning-valid-from": "
|
|
404
|
-
"warning-valid-until": "
|
|
405
|
-
"warning-valid-from-error-before-current": "ikke
|
|
406
|
-
"warning-valid-from-error-max-hours": "ikke
|
|
407
|
-
"warning-valid-until-error-before-current": "ikke
|
|
408
|
-
"warning-valid-until-error-max-hours": "ikke
|
|
409
|
-
"warning-valid-until-error-min-hours": "
|
|
410
|
-
"warning-dialog-delete-succes": "
|
|
411
|
-
"warning-dialog-delete-title": "
|
|
412
|
-
"warning-dialog-delete-confirm": "
|
|
413
|
-
"warning-dialog-delete-description": "
|
|
414
|
-
"warning-dialog-ignore-succes": "
|
|
415
|
-
"warning-dialog-ignore-title": "
|
|
416
|
-
"warning-dialog-ignore-confirm": "
|
|
417
|
-
"warning-dialog-ignore-description": "
|
|
418
|
-
"warning-save-succes": "
|
|
419
|
-
"warning-publish-succes": "
|
|
420
|
-
"warning-editor-user-viewer": "
|
|
421
|
-
"warning-editor-user-editor": "
|
|
422
|
-
"warning-editor-add-editor": "
|
|
423
|
-
"warning-editor-remove-editor": "ikke
|
|
424
|
-
"warning-list-button_create": "
|
|
425
|
-
"warning-list-button-use": "
|
|
426
|
-
"warning-list-button-ignore": "
|
|
427
|
-
"warning-list-button-options": "
|
|
428
|
-
"warning-list-status-draft": "
|
|
429
|
-
"warning-list-status-published": "
|
|
430
|
-
"warning-list-status-todo": "
|
|
431
|
-
"warning-list-status-expired": "
|
|
432
|
-
"warning-list-header-incident": "
|
|
433
|
-
"warning-list-header-last-update": "
|
|
434
|
-
"warning-list-header-start-time": "
|
|
435
|
-
"warning-list-header-end-time": "
|
|
436
|
-
"warning-list-header-domain": "
|
|
437
|
-
"warning-list-header-phenomenon": "
|
|
438
|
-
"warning-list-header-level": "
|
|
439
|
-
"warning-list-header-
|
|
341
|
+
"drawing-tool-form-tools": "Verktøy",
|
|
342
|
+
"drawing-tool-form-opacity": "Gjennomsiktighet",
|
|
343
|
+
"drawing-tool-form-object-name": "Objektnavn",
|
|
344
|
+
"drawing-tool-form-save": "Lagre nytt objekt",
|
|
345
|
+
"drawing-tool-form-update": "Oppdater objekt",
|
|
346
|
+
"drawing-tool-form-exit-draw-mode": "Trykk ESC for å avslutte tegnemodus",
|
|
347
|
+
"drawing-tool-form-drawing-required": "Objekttegning kreves",
|
|
348
|
+
"close-dialog-cancel": "Avbryt",
|
|
349
|
+
"close-dialog-confirm": "Lukk",
|
|
350
|
+
"close-draw-dialog-title": "Lukk tegneverktøy",
|
|
351
|
+
"close-dialog-description": "Du har gjort endringer, er du sikker på at du vil lukke?",
|
|
352
|
+
"drawing-tool-title": "Tegneverktøy",
|
|
353
|
+
"object-manager-title": "Objektmanager for",
|
|
354
|
+
"object-manager-add": "Legg til nytt objekt",
|
|
355
|
+
"delete-dialog-cancel": "Avbryt",
|
|
356
|
+
"delete-dialog-confirm": "Slett",
|
|
357
|
+
"delete-dialog-title": "Slett objekt",
|
|
358
|
+
"delete-dialog-description": "Er du sikker på at du vil slette?",
|
|
359
|
+
"delete-succes": "er slettet",
|
|
360
|
+
"update-succes": "er oppdatert",
|
|
361
|
+
"save-succes": "er lagret",
|
|
362
|
+
"object-manager-no-objects": "Fant ingen objekter",
|
|
363
|
+
"object-manager-options-menu": "Objektvalg",
|
|
364
|
+
"object-manager-button-edit": "Endre",
|
|
365
|
+
"object-manager-button-share": "Del",
|
|
366
|
+
"object-manager-button-delete": "Slett",
|
|
367
|
+
"object-manager-button-view": "Vis",
|
|
368
|
+
"object-manager-no-object-selected": "(ingen objekt er valgt)",
|
|
369
|
+
"object-manager-object-selected": "objekt er valgt",
|
|
370
|
+
"object-manager-share-menu": "Del objekt med",
|
|
371
|
+
"public-warning-title": "Farevarsel",
|
|
372
|
+
"close-warning-dialog-title": "Lukk farevarsel",
|
|
373
|
+
"warning-edit-mode-title": "Bytt til editeringsmodus",
|
|
374
|
+
"warning-edit-mode-description": "Dette varselet er allerede under endring av en annen bruker. Viktig informasjon kan gå tapt ved å bytte",
|
|
375
|
+
"warning-dialog-cancel": "Gå tilbake",
|
|
376
|
+
"warning-edit-mode-confirm": "Editeringsmodus",
|
|
377
|
+
"warning-view-mode-title": "Whoops",
|
|
378
|
+
"warning-view-mode-description": "Er du sikker på at du vil endre til visningsmodus? Ulagret endringer vil gå tapt.",
|
|
379
|
+
"warning-view-mode-confirm": "Bytt modus",
|
|
380
|
+
"warning-probability": "Sannsynlighet",
|
|
381
|
+
"warning-button-clear": "Slett",
|
|
382
|
+
"warning-button-save": "Lagre",
|
|
383
|
+
"warning-button-saving": "Lagrer",
|
|
384
|
+
"warning-button-publish": "Publiser",
|
|
385
|
+
"warning-button-publishing": "Publiserer",
|
|
386
|
+
"warning-area": "Område",
|
|
387
|
+
"warning-button-add-object": "Legg til objekt",
|
|
388
|
+
"warning-description-original": "Original beskrivelse",
|
|
389
|
+
"warning-description-translation": "Oversatt beskrivelse",
|
|
390
|
+
"warning-description-NL": "Nederlandsk (valgt)",
|
|
391
|
+
"warning-level": "Grad",
|
|
392
|
+
"warning-level-moderate": "Moderat",
|
|
393
|
+
"warning-level-severe": "Stor",
|
|
394
|
+
"warning-level-extreme": "Ekstrem",
|
|
395
|
+
"warning-phenomenon": "Fenomen",
|
|
396
|
+
"warning-phenomenon-wind": "Vind",
|
|
397
|
+
"warning-phenomenon-fog": "Tåke",
|
|
398
|
+
"warning-phenomenon-thunderstorm": "Tordenvær",
|
|
399
|
+
"warning-phenomenon-snow-ice": "Snø/is",
|
|
400
|
+
"warning-phenomenon-rain": "Regn",
|
|
401
|
+
"warning-phenomenon-high-temp": "Høy temperatur",
|
|
402
|
+
"warning-phenomenon-low-temp": "Lav temperatur",
|
|
403
|
+
"warning-phenomenon-funnel-cloud": "Tornado",
|
|
404
|
+
"warning-phenomenon-coastal-event": "Kysthendelse",
|
|
405
|
+
"warning-probability-moderate-level-invalid": "Sannsynlighet bør være minst 30% når level er moderat",
|
|
406
|
+
"warning-valid-from": "Gyldig fra",
|
|
407
|
+
"warning-valid-until": "Gyldig til",
|
|
408
|
+
"warning-valid-from-error-before-current": "Gyldig fra kan ikke være før nåtid",
|
|
409
|
+
"warning-valid-from-error-max-hours": "Gyldig fra kan ikke være mer enn {{MAX_HOURS}} timer etter nåtid",
|
|
410
|
+
"warning-valid-until-error-before-current": "Gyldig til kan ikke være før nåtid",
|
|
411
|
+
"warning-valid-until-error-max-hours": "Gyldig til kan ikke være mer enn {{MAX_HOURS}} timer etter nåtid",
|
|
412
|
+
"warning-valid-until-error-min-hours": "Gyldig til må være minst {{MIN_HOURS}} timer etter Gyldig fra",
|
|
413
|
+
"warning-dialog-delete-succes": "Varselet er slettet",
|
|
414
|
+
"warning-dialog-delete-title": "Slett varsel",
|
|
415
|
+
"warning-dialog-delete-confirm": "Slett",
|
|
416
|
+
"warning-dialog-delete-description": "Er du sikker på at du vil slette varselet?",
|
|
417
|
+
"warning-dialog-ignore-succes": "Varselet er blitt ignorert",
|
|
418
|
+
"warning-dialog-ignore-title": "Ignorer varselet",
|
|
419
|
+
"warning-dialog-ignore-confirm": "Ignorer",
|
|
420
|
+
"warning-dialog-ignore-description": "Er du sikker på at du vil ignorere dette varselet?",
|
|
421
|
+
"warning-save-succes": "Farevarselet er lagret!",
|
|
422
|
+
"warning-publish-succes": "Farevarselet er publisert!",
|
|
423
|
+
"warning-editor-user-viewer": "Visningsmodus",
|
|
424
|
+
"warning-editor-user-editor": "Editeringsmodus",
|
|
425
|
+
"warning-editor-add-editor": "Du editerer nå dette varselet",
|
|
426
|
+
"warning-editor-remove-editor": "Du editerer ikke lenger dette varselet",
|
|
427
|
+
"warning-list-button_create": "Lag et farevarsel",
|
|
428
|
+
"warning-list-button-use": "Bruk",
|
|
429
|
+
"warning-list-button-ignore": "Ignorer",
|
|
430
|
+
"warning-list-button-options": "Valg",
|
|
431
|
+
"warning-list-status-draft": "Utkast",
|
|
432
|
+
"warning-list-status-published": "Publisert",
|
|
433
|
+
"warning-list-status-todo": "Til sjekk",
|
|
434
|
+
"warning-list-status-expired": "Utgått (siste 24 timer)",
|
|
435
|
+
"warning-list-header-incident": "Hendelse",
|
|
436
|
+
"warning-list-header-last-update": "Sist oppdatert",
|
|
437
|
+
"warning-list-header-start-time": "Starttid",
|
|
438
|
+
"warning-list-header-end-time": "Sluttid",
|
|
439
|
+
"warning-list-header-domain": "Domene",
|
|
440
|
+
"warning-list-header-phenomenon": "Fenomen",
|
|
441
|
+
"warning-list-header-level": "Level",
|
|
442
|
+
"warning-list-header-status": "Status",
|
|
443
|
+
"warning-list-header-draft": "UTKAST"
|
|
440
444
|
};
|
|
441
445
|
var warningsTranslations = {
|
|
442
446
|
en: en,
|
|
@@ -629,370 +633,93 @@ const {
|
|
|
629
633
|
});
|
|
630
634
|
const getWarningFormDirty = createSelector(selectDrawByInstanceId, drawing => (drawing === null || drawing === void 0 ? void 0 : drawing.isFormDirty) || false);
|
|
631
635
|
|
|
632
|
-
|
|
633
|
-
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
634
|
-
* you may not use this file except in compliance with the License.
|
|
635
|
-
* You may obtain a copy of the License at
|
|
636
|
-
*
|
|
637
|
-
* http://www.apache.org/licenses/LICENSE-2.0
|
|
638
|
-
*
|
|
639
|
-
* Unless required by applicable law or agreed to in writing, software
|
|
640
|
-
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
641
|
-
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
642
|
-
* See the License for the specific language governing permissions and
|
|
643
|
-
* limitations under the License.
|
|
644
|
-
*
|
|
645
|
-
* Copyright 2023 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
646
|
-
* Copyright 2023 - Finnish Meteorological Institute (FMI)
|
|
647
|
-
* */
|
|
648
|
-
const WARN_NAMESPACE = 'warn';
|
|
649
|
-
const outsideComponentTranslations = handleOutsideComponentTranslations(warningsTranslations, WARN_NAMESPACE);
|
|
636
|
+
var commonjsGlobal = typeof globalThis !== 'undefined' ? globalThis : typeof window !== 'undefined' ? window : typeof global !== 'undefined' ? global : typeof self !== 'undefined' ? self : {};
|
|
650
637
|
|
|
651
|
-
|
|
652
|
-
|
|
653
|
-
* you may not use this file except in compliance with the License.
|
|
654
|
-
* You may obtain a copy of the License at
|
|
655
|
-
*
|
|
656
|
-
* http://www.apache.org/licenses/LICENSE-2.0
|
|
657
|
-
*
|
|
658
|
-
* Unless required by applicable law or agreed to in writing, software
|
|
659
|
-
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
660
|
-
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
661
|
-
* See the License for the specific language governing permissions and
|
|
662
|
-
* limitations under the License.
|
|
663
|
-
*
|
|
664
|
-
* Copyright 2023 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
665
|
-
* Copyright 2023 - Finnish Meteorological Institute (FMI)
|
|
666
|
-
* */
|
|
667
|
-
const confirmationDialogOptions = t => {
|
|
668
|
-
return {
|
|
669
|
-
cancelLabel: t('close-dialog-cancel'),
|
|
670
|
-
title: t('close-draw-dialog-title'),
|
|
671
|
-
description: t('close-dialog-description'),
|
|
672
|
-
confirmLabel: t('close-dialog-confirm'),
|
|
673
|
-
catchOnCancel: true
|
|
674
|
-
};
|
|
638
|
+
var check = function (it) {
|
|
639
|
+
return it && it.Math === Math && it;
|
|
675
640
|
};
|
|
676
|
-
|
|
677
|
-
|
|
678
|
-
|
|
679
|
-
|
|
680
|
-
|
|
681
|
-
|
|
682
|
-
|
|
683
|
-
|
|
684
|
-
|
|
685
|
-
|
|
686
|
-
|
|
687
|
-
|
|
688
|
-
|
|
689
|
-
|
|
690
|
-
|
|
691
|
-
|
|
692
|
-
|
|
693
|
-
|
|
694
|
-
|
|
695
|
-
|
|
696
|
-
|
|
697
|
-
if (drawDialogActiveDrawModeId) {
|
|
698
|
-
// disable the edit layer
|
|
699
|
-
dispatch(layerActions.toggleFeatureMode({
|
|
700
|
-
layerId: drawLayerId,
|
|
701
|
-
isInEditMode: false,
|
|
702
|
-
drawMode: ''
|
|
703
|
-
}));
|
|
704
|
-
// reset active draw tool
|
|
705
|
-
dispatch(drawtoolActions.changeDrawToolMode({
|
|
706
|
-
drawToolId: drawingDialogType,
|
|
707
|
-
drawModeId: drawDialogActiveDrawModeId
|
|
708
|
-
}));
|
|
709
|
-
}
|
|
710
|
-
// close draw dialog
|
|
711
|
-
dispatch(uiActions.setActiveMapIdForDialog({
|
|
712
|
-
type: drawingDialogType,
|
|
713
|
-
mapId,
|
|
714
|
-
setOpen: false,
|
|
715
|
-
source
|
|
716
|
-
}));
|
|
717
|
-
// reset all drawings fields
|
|
718
|
-
dispatch(drawActions.setDrawValues({
|
|
719
|
-
drawingInstanceId: drawingDialogType,
|
|
720
|
-
objectName: '',
|
|
721
|
-
id: ''
|
|
722
|
-
}));
|
|
723
|
-
// reset error
|
|
724
|
-
if (dialogError) {
|
|
725
|
-
dispatch(uiActions.setErrorDialog({
|
|
726
|
-
type: drawingDialogType,
|
|
727
|
-
error: ''
|
|
728
|
-
}));
|
|
729
|
-
}
|
|
730
|
-
// clear existing geoJSON
|
|
731
|
-
if (featureLayerContainsGeoJSON) {
|
|
732
|
-
dispatch(mapStoreActions.layerChangeGeojson({
|
|
733
|
-
layerId: drawLayerId,
|
|
734
|
-
geojson: emptyGeoJSON
|
|
735
|
-
}));
|
|
736
|
-
}
|
|
737
|
-
});
|
|
738
|
-
return {
|
|
739
|
-
closeDrawDialog
|
|
740
|
-
};
|
|
641
|
+
|
|
642
|
+
// https://github.com/zloirock/core-js/issues/86#issuecomment-115759028
|
|
643
|
+
var global$i =
|
|
644
|
+
// eslint-disable-next-line es/no-global-this -- safe
|
|
645
|
+
check(typeof globalThis == 'object' && globalThis) ||
|
|
646
|
+
check(typeof window == 'object' && window) ||
|
|
647
|
+
// eslint-disable-next-line no-restricted-globals -- safe
|
|
648
|
+
check(typeof self == 'object' && self) ||
|
|
649
|
+
check(typeof commonjsGlobal == 'object' && commonjsGlobal) ||
|
|
650
|
+
check(typeof commonjsGlobal == 'object' && commonjsGlobal) ||
|
|
651
|
+
// eslint-disable-next-line no-new-func -- fallback
|
|
652
|
+
(function () { return this; })() || Function('return this')();
|
|
653
|
+
|
|
654
|
+
var objectGetOwnPropertyDescriptor = {};
|
|
655
|
+
|
|
656
|
+
var fails$l = function (exec) {
|
|
657
|
+
try {
|
|
658
|
+
return !!exec();
|
|
659
|
+
} catch (error) {
|
|
660
|
+
return true;
|
|
661
|
+
}
|
|
741
662
|
};
|
|
742
|
-
|
|
743
|
-
|
|
744
|
-
|
|
745
|
-
|
|
746
|
-
|
|
747
|
-
|
|
748
|
-
|
|
749
|
-
|
|
750
|
-
|
|
751
|
-
|
|
752
|
-
|
|
753
|
-
|
|
754
|
-
|
|
755
|
-
|
|
756
|
-
|
|
757
|
-
|
|
758
|
-
|
|
759
|
-
|
|
760
|
-
|
|
761
|
-
|
|
762
|
-
|
|
763
|
-
|
|
764
|
-
|
|
765
|
-
|
|
766
|
-
|
|
767
|
-
|
|
768
|
-
|
|
769
|
-
|
|
770
|
-
|
|
771
|
-
|
|
663
|
+
|
|
664
|
+
var fails$k = fails$l;
|
|
665
|
+
|
|
666
|
+
// Detect IE8's incomplete defineProperty implementation
|
|
667
|
+
var descriptors = !fails$k(function () {
|
|
668
|
+
// eslint-disable-next-line es/no-object-defineproperty -- required for testing
|
|
669
|
+
return Object.defineProperty({}, 1, { get: function () { return 7; } })[1] !== 7;
|
|
670
|
+
});
|
|
671
|
+
|
|
672
|
+
var fails$j = fails$l;
|
|
673
|
+
|
|
674
|
+
var functionBindNative = !fails$j(function () {
|
|
675
|
+
// eslint-disable-next-line es/no-function-prototype-bind -- safe
|
|
676
|
+
var test = (function () { /* empty */ }).bind();
|
|
677
|
+
// eslint-disable-next-line no-prototype-builtins -- safe
|
|
678
|
+
return typeof test != 'function' || test.hasOwnProperty('prototype');
|
|
679
|
+
});
|
|
680
|
+
|
|
681
|
+
var NATIVE_BIND$2 = functionBindNative;
|
|
682
|
+
|
|
683
|
+
var call$b = Function.prototype.call;
|
|
684
|
+
|
|
685
|
+
var functionCall = NATIVE_BIND$2 ? call$b.bind(call$b) : function () {
|
|
686
|
+
return call$b.apply(call$b, arguments);
|
|
687
|
+
};
|
|
688
|
+
|
|
689
|
+
var objectPropertyIsEnumerable = {};
|
|
690
|
+
|
|
691
|
+
var $propertyIsEnumerable = {}.propertyIsEnumerable;
|
|
692
|
+
// eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe
|
|
693
|
+
var getOwnPropertyDescriptor$2 = Object.getOwnPropertyDescriptor;
|
|
694
|
+
|
|
695
|
+
// Nashorn ~ JDK8 bug
|
|
696
|
+
var NASHORN_BUG = getOwnPropertyDescriptor$2 && !$propertyIsEnumerable.call({ 1: 2 }, 1);
|
|
697
|
+
|
|
698
|
+
// `Object.prototype.propertyIsEnumerable` method implementation
|
|
699
|
+
// https://tc39.es/ecma262/#sec-object.prototype.propertyisenumerable
|
|
700
|
+
objectPropertyIsEnumerable.f = NASHORN_BUG ? function propertyIsEnumerable(V) {
|
|
701
|
+
var descriptor = getOwnPropertyDescriptor$2(this, V);
|
|
702
|
+
return !!descriptor && descriptor.enumerable;
|
|
703
|
+
} : $propertyIsEnumerable;
|
|
704
|
+
|
|
705
|
+
var createPropertyDescriptor$4 = function (bitmap, value) {
|
|
772
706
|
return {
|
|
773
|
-
|
|
707
|
+
enumerable: !(bitmap & 1),
|
|
708
|
+
configurable: !(bitmap & 2),
|
|
709
|
+
writable: !(bitmap & 4),
|
|
710
|
+
value: value
|
|
774
711
|
};
|
|
775
712
|
};
|
|
776
|
-
|
|
777
|
-
|
|
778
|
-
|
|
779
|
-
|
|
780
|
-
|
|
781
|
-
|
|
782
|
-
|
|
783
|
-
|
|
784
|
-
|
|
785
|
-
|
|
786
|
-
hasGeoJSON,
|
|
787
|
-
dialogLayerId
|
|
788
|
-
};
|
|
789
|
-
};
|
|
790
|
-
const useObjectDrawDialogAction = ({
|
|
791
|
-
mapId,
|
|
792
|
-
source
|
|
793
|
-
}) => {
|
|
794
|
-
const {
|
|
795
|
-
t
|
|
796
|
-
} = useTranslation(WARN_NAMESPACE);
|
|
797
|
-
const dispatch = useDispatch();
|
|
798
|
-
const confirmDialog = useConfirmationDialog();
|
|
799
|
-
const currentDrawLayerId = getSingularDrawtoolDrawLayerId(mapId);
|
|
800
|
-
// draw selectors
|
|
801
|
-
const {
|
|
802
|
-
isDialogOpen: isDrawDialogOpen,
|
|
803
|
-
hasGeoJSON: drawDialogLayerHasGeoJSON,
|
|
804
|
-
dialogLayerId: drawDialogLayerId
|
|
805
|
-
} = useDialogOptions({
|
|
806
|
-
dialogType: drawingDialogType
|
|
807
|
-
});
|
|
808
|
-
const drawDialogActiveDrawModeId = useSelector(store => drawtoolSelectors.getActiveDrawModeId(store, drawingDialogType));
|
|
809
|
-
const isFormDirty = useSelector(store => getWarningFormDirty(store, drawingDialogType));
|
|
810
|
-
// object selectors
|
|
811
|
-
const {
|
|
812
|
-
isDialogOpen: isObjectDialogOpen,
|
|
813
|
-
hasGeoJSON: objectDialogLayerHasGeoJSON,
|
|
814
|
-
dialogLayerId: objectDialogLayerId
|
|
815
|
-
} = useDialogOptions({
|
|
816
|
-
dialogType: objectDialogType
|
|
817
|
-
});
|
|
818
|
-
const clearGeoJSON = layerId => {
|
|
819
|
-
dispatch(mapStoreActions.layerChangeGeojson({
|
|
820
|
-
layerId,
|
|
821
|
-
geojson: emptyGeoJSON
|
|
822
|
-
}));
|
|
823
|
-
};
|
|
824
|
-
const openObjectDialog = () => __awaiter(void 0, void 0, void 0, function* () {
|
|
825
|
-
if (isDrawDialogOpen) {
|
|
826
|
-
if (isFormDirty) {
|
|
827
|
-
const mayProceed = yield confirmDialog(confirmationDialogOptions(t)).then(() => true).catch(() => false);
|
|
828
|
-
if (!mayProceed) {
|
|
829
|
-
return;
|
|
830
|
-
}
|
|
831
|
-
}
|
|
832
|
-
if (drawDialogLayerHasGeoJSON) {
|
|
833
|
-
clearGeoJSON(drawDialogLayerId);
|
|
834
|
-
}
|
|
835
|
-
closeDrawDialog(true);
|
|
836
|
-
}
|
|
837
|
-
// open object dialog
|
|
838
|
-
dispatch(uiActions.setActiveMapIdForDialog({
|
|
839
|
-
type: objectDialogType,
|
|
840
|
-
mapId,
|
|
841
|
-
setOpen: true,
|
|
842
|
-
source
|
|
843
|
-
}));
|
|
844
|
-
// move shape to screen
|
|
845
|
-
if (isObjectDialogOpen && objectDialogLayerHasGeoJSON) {
|
|
846
|
-
// update new shape
|
|
847
|
-
dispatch(mapStoreActions.layerSetGeojsonFromLayer({
|
|
848
|
-
layerId: currentDrawLayerId,
|
|
849
|
-
sourceLayerId: objectDialogLayerId
|
|
850
|
-
}));
|
|
851
|
-
// remove current shape
|
|
852
|
-
clearGeoJSON(objectDialogLayerId);
|
|
853
|
-
}
|
|
854
|
-
});
|
|
855
|
-
const openDrawDialog = newGeoJSON => {
|
|
856
|
-
if (isObjectDialogOpen) {
|
|
857
|
-
if (objectDialogLayerHasGeoJSON) {
|
|
858
|
-
clearGeoJSON(objectDialogLayerId);
|
|
859
|
-
}
|
|
860
|
-
const shouldResetShape = newGeoJSON === undefined;
|
|
861
|
-
closeObjectDialog(shouldResetShape);
|
|
862
|
-
}
|
|
863
|
-
// open draw dialog
|
|
864
|
-
dispatch(uiActions.setActiveMapIdForDialog({
|
|
865
|
-
type: drawingDialogType,
|
|
866
|
-
mapId,
|
|
867
|
-
setOpen: true,
|
|
868
|
-
source
|
|
869
|
-
}));
|
|
870
|
-
// activate draw tool
|
|
871
|
-
dispatch(drawtoolActions.updateGeoJSONLayerId({
|
|
872
|
-
drawToolId: drawingDialogType,
|
|
873
|
-
geoJSONLayerId: currentDrawLayerId
|
|
874
|
-
}));
|
|
875
|
-
// move shape to screen
|
|
876
|
-
if (isDrawDialogOpen && drawDialogLayerHasGeoJSON) {
|
|
877
|
-
// update new shape
|
|
878
|
-
dispatch(mapStoreActions.layerSetGeojsonFromLayer({
|
|
879
|
-
layerId: currentDrawLayerId,
|
|
880
|
-
sourceLayerId: drawDialogLayerId
|
|
881
|
-
}));
|
|
882
|
-
// remove current shape
|
|
883
|
-
clearGeoJSON(drawDialogLayerId);
|
|
884
|
-
}
|
|
885
|
-
if (drawDialogActiveDrawModeId) {
|
|
886
|
-
// activate current
|
|
887
|
-
dispatch(layerActions.toggleFeatureMode({
|
|
888
|
-
layerId: currentDrawLayerId,
|
|
889
|
-
isInEditMode: true,
|
|
890
|
-
drawMode: drawDialogActiveDrawModeId
|
|
891
|
-
}));
|
|
892
|
-
// deactivate previous
|
|
893
|
-
dispatch(layerActions.toggleFeatureMode({
|
|
894
|
-
layerId: drawDialogLayerId,
|
|
895
|
-
isInEditMode: false,
|
|
896
|
-
drawMode: ''
|
|
897
|
-
}));
|
|
898
|
-
}
|
|
899
|
-
if (newGeoJSON) {
|
|
900
|
-
dispatch(mapStoreActions.layerChangeGeojson({
|
|
901
|
-
layerId: currentDrawLayerId,
|
|
902
|
-
geojson: newGeoJSON
|
|
903
|
-
}));
|
|
904
|
-
}
|
|
905
|
-
};
|
|
906
|
-
const {
|
|
907
|
-
closeDrawDialog
|
|
908
|
-
} = useCloseDrawDialog({
|
|
909
|
-
mapId,
|
|
910
|
-
source
|
|
911
|
-
});
|
|
912
|
-
const {
|
|
913
|
-
closeObjectDialog
|
|
914
|
-
} = useCloseObjectDialog({
|
|
915
|
-
mapId,
|
|
916
|
-
source
|
|
917
|
-
});
|
|
918
|
-
return {
|
|
919
|
-
closeDrawDialog,
|
|
920
|
-
closeObjectDialog,
|
|
921
|
-
openObjectDialog,
|
|
922
|
-
openDrawDialog
|
|
923
|
-
};
|
|
924
|
-
};
|
|
925
|
-
|
|
926
|
-
/* *
|
|
927
|
-
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
928
|
-
* you may not use this file except in compliance with the License.
|
|
929
|
-
* You may obtain a copy of the License at
|
|
930
|
-
*
|
|
931
|
-
* http://www.apache.org/licenses/LICENSE-2.0
|
|
932
|
-
*
|
|
933
|
-
* Unless required by applicable law or agreed to in writing, software
|
|
934
|
-
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
935
|
-
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
936
|
-
* See the License for the specific language governing permissions and
|
|
937
|
-
* limitations under the License.
|
|
938
|
-
*
|
|
939
|
-
* Copyright 2023 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
940
|
-
* Copyright 2023 - Finnish Meteorological Institute (FMI)
|
|
941
|
-
* */
|
|
942
|
-
const ObjectManagerMapButtonConnect = ({
|
|
943
|
-
mapId,
|
|
944
|
-
source: _source = 'app'
|
|
945
|
-
}) => {
|
|
946
|
-
const objectDialogMapId = useSelector(store => uiSelectors.getDialogMapId(store, objectDialogType));
|
|
947
|
-
const isObjectDialogOpen = useSelector(store => uiSelectors.getisDialogOpen(store, objectDialogType));
|
|
948
|
-
const {
|
|
949
|
-
openObjectDialog,
|
|
950
|
-
closeObjectDialog
|
|
951
|
-
} = useObjectDrawDialogAction({
|
|
952
|
-
mapId,
|
|
953
|
-
source: _source
|
|
954
|
-
});
|
|
955
|
-
const onClick = () => {
|
|
956
|
-
const shouldOpen = objectDialogMapId !== mapId ? true : !isObjectDialogOpen;
|
|
957
|
-
shouldOpen ? openObjectDialog() : closeObjectDialog();
|
|
958
|
-
};
|
|
959
|
-
const isOpen = objectDialogMapId === mapId && isObjectDialogOpen;
|
|
960
|
-
return /*#__PURE__*/React__default.createElement(MapControlButton, {
|
|
961
|
-
"aria-label": `Object Manager Button for ${mapId}`,
|
|
962
|
-
title: "Object Manager",
|
|
963
|
-
onClick: onClick,
|
|
964
|
-
isActive: isOpen
|
|
965
|
-
}, /*#__PURE__*/React__default.createElement(Polygons, null));
|
|
966
|
-
};
|
|
967
|
-
|
|
968
|
-
var commonjsGlobal = typeof globalThis !== 'undefined' ? globalThis : typeof window !== 'undefined' ? window : typeof global !== 'undefined' ? global : typeof self !== 'undefined' ? self : {};
|
|
969
|
-
|
|
970
|
-
var fails$l = function (exec) {
|
|
971
|
-
try {
|
|
972
|
-
return !!exec();
|
|
973
|
-
} catch (error) {
|
|
974
|
-
return true;
|
|
975
|
-
}
|
|
976
|
-
};
|
|
977
|
-
|
|
978
|
-
var fails$k = fails$l;
|
|
979
|
-
|
|
980
|
-
var functionBindNative = !fails$k(function () {
|
|
981
|
-
// eslint-disable-next-line es/no-function-prototype-bind -- safe
|
|
982
|
-
var test = (function () { /* empty */ }).bind();
|
|
983
|
-
// eslint-disable-next-line no-prototype-builtins -- safe
|
|
984
|
-
return typeof test != 'function' || test.hasOwnProperty('prototype');
|
|
985
|
-
});
|
|
986
|
-
|
|
987
|
-
var NATIVE_BIND$2 = functionBindNative;
|
|
988
|
-
|
|
989
|
-
var FunctionPrototype$2 = Function.prototype;
|
|
990
|
-
var call$b = FunctionPrototype$2.call;
|
|
991
|
-
var uncurryThisWithBind = NATIVE_BIND$2 && FunctionPrototype$2.bind.bind(call$b, call$b);
|
|
992
|
-
|
|
993
|
-
var functionUncurryThis = NATIVE_BIND$2 ? uncurryThisWithBind : function (fn) {
|
|
994
|
-
return function () {
|
|
995
|
-
return call$b.apply(fn, arguments);
|
|
713
|
+
|
|
714
|
+
var NATIVE_BIND$1 = functionBindNative;
|
|
715
|
+
|
|
716
|
+
var FunctionPrototype$2 = Function.prototype;
|
|
717
|
+
var call$a = FunctionPrototype$2.call;
|
|
718
|
+
var uncurryThisWithBind = NATIVE_BIND$1 && FunctionPrototype$2.bind.bind(call$a, call$a);
|
|
719
|
+
|
|
720
|
+
var functionUncurryThis = NATIVE_BIND$1 ? uncurryThisWithBind : function (fn) {
|
|
721
|
+
return function () {
|
|
722
|
+
return call$a.apply(fn, arguments);
|
|
996
723
|
};
|
|
997
724
|
};
|
|
998
725
|
|
|
@@ -1006,14 +733,14 @@ var classofRaw$1 = function (it) {
|
|
|
1006
733
|
};
|
|
1007
734
|
|
|
1008
735
|
var uncurryThis$h = functionUncurryThis;
|
|
1009
|
-
var fails$
|
|
736
|
+
var fails$i = fails$l;
|
|
1010
737
|
var classof$6 = classofRaw$1;
|
|
1011
738
|
|
|
1012
739
|
var $Object$4 = Object;
|
|
1013
740
|
var split = uncurryThis$h(''.split);
|
|
1014
741
|
|
|
1015
742
|
// fallback for non-array-like ES3 and non-enumerable old V8 strings
|
|
1016
|
-
var indexedObject = fails$
|
|
743
|
+
var indexedObject = fails$i(function () {
|
|
1017
744
|
// throws an error in rhino, see https://github.com/mozilla/rhino/issues/346
|
|
1018
745
|
// eslint-disable-next-line no-prototype-builtins -- safe
|
|
1019
746
|
return !$Object$4('z').propertyIsEnumerable(0);
|
|
@@ -1046,128 +773,78 @@ var toIndexedObject$5 = function (it) {
|
|
|
1046
773
|
return IndexedObject$2(requireObjectCoercible$5(it));
|
|
1047
774
|
};
|
|
1048
775
|
|
|
1049
|
-
|
|
1050
|
-
|
|
776
|
+
// https://tc39.es/ecma262/#sec-IsHTMLDDA-internal-slot
|
|
777
|
+
var documentAll = typeof document == 'object' && document.all;
|
|
778
|
+
|
|
779
|
+
// `IsCallable` abstract operation
|
|
780
|
+
// https://tc39.es/ecma262/#sec-iscallable
|
|
781
|
+
// eslint-disable-next-line unicorn/no-typeof-undefined -- required for testing
|
|
782
|
+
var isCallable$i = typeof documentAll == 'undefined' && documentAll !== undefined ? function (argument) {
|
|
783
|
+
return typeof argument == 'function' || argument === documentAll;
|
|
784
|
+
} : function (argument) {
|
|
785
|
+
return typeof argument == 'function';
|
|
1051
786
|
};
|
|
1052
787
|
|
|
1053
|
-
|
|
1054
|
-
var global$i =
|
|
1055
|
-
// eslint-disable-next-line es/no-global-this -- safe
|
|
1056
|
-
check(typeof globalThis == 'object' && globalThis) ||
|
|
1057
|
-
check(typeof window == 'object' && window) ||
|
|
1058
|
-
// eslint-disable-next-line no-restricted-globals -- safe
|
|
1059
|
-
check(typeof self == 'object' && self) ||
|
|
1060
|
-
check(typeof commonjsGlobal == 'object' && commonjsGlobal) ||
|
|
1061
|
-
check(typeof commonjsGlobal == 'object' && commonjsGlobal) ||
|
|
1062
|
-
// eslint-disable-next-line no-new-func -- fallback
|
|
1063
|
-
(function () { return this; })() || Function('return this')();
|
|
788
|
+
var isCallable$h = isCallable$i;
|
|
1064
789
|
|
|
1065
|
-
var
|
|
790
|
+
var isObject$a = function (it) {
|
|
791
|
+
return typeof it == 'object' ? it !== null : isCallable$h(it);
|
|
792
|
+
};
|
|
1066
793
|
|
|
1067
794
|
var global$h = global$i;
|
|
795
|
+
var isCallable$g = isCallable$i;
|
|
1068
796
|
|
|
1069
|
-
|
|
1070
|
-
|
|
797
|
+
var aFunction = function (argument) {
|
|
798
|
+
return isCallable$g(argument) ? argument : undefined;
|
|
799
|
+
};
|
|
1071
800
|
|
|
1072
|
-
var
|
|
1073
|
-
|
|
1074
|
-
defineProperty$7(global$h, key, { value: value, configurable: true, writable: true });
|
|
1075
|
-
} catch (error) {
|
|
1076
|
-
global$h[key] = value;
|
|
1077
|
-
} return value;
|
|
801
|
+
var getBuiltIn$5 = function (namespace, method) {
|
|
802
|
+
return arguments.length < 2 ? aFunction(global$h[namespace]) : global$h[namespace] && global$h[namespace][method];
|
|
1078
803
|
};
|
|
1079
804
|
|
|
1080
|
-
var
|
|
1081
|
-
var defineGlobalProperty$2 = defineGlobalProperty$3;
|
|
805
|
+
var uncurryThis$g = functionUncurryThis;
|
|
1082
806
|
|
|
1083
|
-
var
|
|
1084
|
-
var store$3 = sharedStore.exports = globalThis$1[SHARED] || defineGlobalProperty$2(SHARED, {});
|
|
807
|
+
var objectIsPrototypeOf = uncurryThis$g({}.isPrototypeOf);
|
|
1085
808
|
|
|
1086
|
-
|
|
1087
|
-
version: '3.36.1',
|
|
1088
|
-
mode: 'global',
|
|
1089
|
-
copyright: '© 2014-2024 Denis Pushkarev (zloirock.ru)',
|
|
1090
|
-
license: 'https://github.com/zloirock/core-js/blob/v3.36.1/LICENSE',
|
|
1091
|
-
source: 'https://github.com/zloirock/core-js'
|
|
1092
|
-
});
|
|
809
|
+
var engineUserAgent = typeof navigator != 'undefined' && String(navigator.userAgent) || '';
|
|
1093
810
|
|
|
1094
|
-
var
|
|
811
|
+
var global$g = global$i;
|
|
812
|
+
var userAgent = engineUserAgent;
|
|
1095
813
|
|
|
1096
|
-
var
|
|
1097
|
-
|
|
1098
|
-
|
|
814
|
+
var process = global$g.process;
|
|
815
|
+
var Deno = global$g.Deno;
|
|
816
|
+
var versions = process && process.versions || Deno && Deno.version;
|
|
817
|
+
var v8 = versions && versions.v8;
|
|
818
|
+
var match, version;
|
|
1099
819
|
|
|
1100
|
-
|
|
820
|
+
if (v8) {
|
|
821
|
+
match = v8.split('.');
|
|
822
|
+
// in old Chrome, versions of V8 isn't V8 = Chrome / 10
|
|
823
|
+
// but their correct versions are not interesting for us
|
|
824
|
+
version = match[0] > 0 && match[0] < 4 ? 1 : +(match[0] + match[1]);
|
|
825
|
+
}
|
|
1101
826
|
|
|
1102
|
-
|
|
1103
|
-
|
|
1104
|
-
|
|
1105
|
-
|
|
1106
|
-
|
|
1107
|
-
|
|
1108
|
-
|
|
1109
|
-
|
|
1110
|
-
|
|
1111
|
-
var toObject$4 = toObject$5;
|
|
1112
|
-
|
|
1113
|
-
var hasOwnProperty = uncurryThis$g({}.hasOwnProperty);
|
|
1114
|
-
|
|
1115
|
-
// `HasOwnProperty` abstract operation
|
|
1116
|
-
// https://tc39.es/ecma262/#sec-hasownproperty
|
|
1117
|
-
// eslint-disable-next-line es/no-object-hasown -- safe
|
|
1118
|
-
var hasOwnProperty_1 = Object.hasOwn || function hasOwn(it, key) {
|
|
1119
|
-
return hasOwnProperty(toObject$4(it), key);
|
|
1120
|
-
};
|
|
1121
|
-
|
|
1122
|
-
var uncurryThis$f = functionUncurryThis;
|
|
1123
|
-
|
|
1124
|
-
var id = 0;
|
|
1125
|
-
var postfix = Math.random();
|
|
1126
|
-
var toString$8 = uncurryThis$f(1.0.toString);
|
|
1127
|
-
|
|
1128
|
-
var uid$2 = function (key) {
|
|
1129
|
-
return 'Symbol(' + (key === undefined ? '' : key) + ')_' + toString$8(++id + postfix, 36);
|
|
1130
|
-
};
|
|
1131
|
-
|
|
1132
|
-
var engineUserAgent = typeof navigator != 'undefined' && String(navigator.userAgent) || '';
|
|
1133
|
-
|
|
1134
|
-
var global$g = global$i;
|
|
1135
|
-
var userAgent = engineUserAgent;
|
|
1136
|
-
|
|
1137
|
-
var process = global$g.process;
|
|
1138
|
-
var Deno = global$g.Deno;
|
|
1139
|
-
var versions = process && process.versions || Deno && Deno.version;
|
|
1140
|
-
var v8 = versions && versions.v8;
|
|
1141
|
-
var match, version;
|
|
1142
|
-
|
|
1143
|
-
if (v8) {
|
|
1144
|
-
match = v8.split('.');
|
|
1145
|
-
// in old Chrome, versions of V8 isn't V8 = Chrome / 10
|
|
1146
|
-
// but their correct versions are not interesting for us
|
|
1147
|
-
version = match[0] > 0 && match[0] < 4 ? 1 : +(match[0] + match[1]);
|
|
1148
|
-
}
|
|
1149
|
-
|
|
1150
|
-
// BrowserFS NodeJS `process` polyfill incorrectly set `.v8` to `0.0`
|
|
1151
|
-
// so check `userAgent` even if `.v8` exists, but 0
|
|
1152
|
-
if (!version && userAgent) {
|
|
1153
|
-
match = userAgent.match(/Edge\/(\d+)/);
|
|
1154
|
-
if (!match || match[1] >= 74) {
|
|
1155
|
-
match = userAgent.match(/Chrome\/(\d+)/);
|
|
1156
|
-
if (match) version = +match[1];
|
|
1157
|
-
}
|
|
1158
|
-
}
|
|
827
|
+
// BrowserFS NodeJS `process` polyfill incorrectly set `.v8` to `0.0`
|
|
828
|
+
// so check `userAgent` even if `.v8` exists, but 0
|
|
829
|
+
if (!version && userAgent) {
|
|
830
|
+
match = userAgent.match(/Edge\/(\d+)/);
|
|
831
|
+
if (!match || match[1] >= 74) {
|
|
832
|
+
match = userAgent.match(/Chrome\/(\d+)/);
|
|
833
|
+
if (match) version = +match[1];
|
|
834
|
+
}
|
|
835
|
+
}
|
|
1159
836
|
|
|
1160
837
|
var engineV8Version = version;
|
|
1161
838
|
|
|
1162
839
|
/* eslint-disable es/no-symbol -- required for testing */
|
|
1163
840
|
var V8_VERSION = engineV8Version;
|
|
1164
|
-
var fails$
|
|
841
|
+
var fails$h = fails$l;
|
|
1165
842
|
var global$f = global$i;
|
|
1166
843
|
|
|
1167
844
|
var $String$5 = global$f.String;
|
|
1168
845
|
|
|
1169
846
|
// eslint-disable-next-line es/no-object-getownpropertysymbols -- required for testing
|
|
1170
|
-
var symbolConstructorDetection = !!Object.getOwnPropertySymbols && !fails$
|
|
847
|
+
var symbolConstructorDetection = !!Object.getOwnPropertySymbols && !fails$h(function () {
|
|
1171
848
|
var symbol = Symbol('symbol detection');
|
|
1172
849
|
// Chrome 38 Symbol has incorrect toString conversion
|
|
1173
850
|
// `get-own-property-symbols` polyfill symbols converted to object are not Symbol instances
|
|
@@ -1185,144 +862,25 @@ var useSymbolAsUid = NATIVE_SYMBOL$2
|
|
|
1185
862
|
&& !Symbol.sham
|
|
1186
863
|
&& typeof Symbol.iterator == 'symbol';
|
|
1187
864
|
|
|
1188
|
-
var global$e = global$i;
|
|
1189
|
-
var shared$3 = shared$4;
|
|
1190
|
-
var hasOwn$a = hasOwnProperty_1;
|
|
1191
|
-
var uid$1 = uid$2;
|
|
1192
|
-
var NATIVE_SYMBOL$1 = symbolConstructorDetection;
|
|
1193
|
-
var USE_SYMBOL_AS_UID$1 = useSymbolAsUid;
|
|
1194
|
-
|
|
1195
|
-
var Symbol$2 = global$e.Symbol;
|
|
1196
|
-
var WellKnownSymbolsStore = shared$3('wks');
|
|
1197
|
-
var createWellKnownSymbol = USE_SYMBOL_AS_UID$1 ? Symbol$2['for'] || Symbol$2 : Symbol$2 && Symbol$2.withoutSetter || uid$1;
|
|
1198
|
-
|
|
1199
|
-
var wellKnownSymbol$a = function (name) {
|
|
1200
|
-
if (!hasOwn$a(WellKnownSymbolsStore, name)) {
|
|
1201
|
-
WellKnownSymbolsStore[name] = NATIVE_SYMBOL$1 && hasOwn$a(Symbol$2, name)
|
|
1202
|
-
? Symbol$2[name]
|
|
1203
|
-
: createWellKnownSymbol('Symbol.' + name);
|
|
1204
|
-
} return WellKnownSymbolsStore[name];
|
|
1205
|
-
};
|
|
1206
|
-
|
|
1207
|
-
// https://tc39.es/ecma262/#sec-IsHTMLDDA-internal-slot
|
|
1208
|
-
var documentAll = typeof document == 'object' && document.all;
|
|
1209
|
-
|
|
1210
|
-
// `IsCallable` abstract operation
|
|
1211
|
-
// https://tc39.es/ecma262/#sec-iscallable
|
|
1212
|
-
// eslint-disable-next-line unicorn/no-typeof-undefined -- required for testing
|
|
1213
|
-
var isCallable$i = typeof documentAll == 'undefined' && documentAll !== undefined ? function (argument) {
|
|
1214
|
-
return typeof argument == 'function' || argument === documentAll;
|
|
1215
|
-
} : function (argument) {
|
|
1216
|
-
return typeof argument == 'function';
|
|
1217
|
-
};
|
|
1218
|
-
|
|
1219
|
-
var isCallable$h = isCallable$i;
|
|
1220
|
-
|
|
1221
|
-
var isObject$a = function (it) {
|
|
1222
|
-
return typeof it == 'object' ? it !== null : isCallable$h(it);
|
|
1223
|
-
};
|
|
1224
|
-
|
|
1225
|
-
var isObject$9 = isObject$a;
|
|
1226
|
-
|
|
1227
|
-
var $String$4 = String;
|
|
1228
|
-
var $TypeError$a = TypeError;
|
|
1229
|
-
|
|
1230
|
-
// `Assert: Type(argument) is Object`
|
|
1231
|
-
var anObject$8 = function (argument) {
|
|
1232
|
-
if (isObject$9(argument)) return argument;
|
|
1233
|
-
throw new $TypeError$a($String$4(argument) + ' is not an object');
|
|
1234
|
-
};
|
|
1235
|
-
|
|
1236
|
-
var objectDefineProperties = {};
|
|
1237
|
-
|
|
1238
|
-
var fails$h = fails$l;
|
|
1239
|
-
|
|
1240
|
-
// Detect IE8's incomplete defineProperty implementation
|
|
1241
|
-
var descriptors = !fails$h(function () {
|
|
1242
|
-
// eslint-disable-next-line es/no-object-defineproperty -- required for testing
|
|
1243
|
-
return Object.defineProperty({}, 1, { get: function () { return 7; } })[1] !== 7;
|
|
1244
|
-
});
|
|
1245
|
-
|
|
1246
|
-
var DESCRIPTORS$c = descriptors;
|
|
1247
|
-
var fails$g = fails$l;
|
|
1248
|
-
|
|
1249
|
-
// V8 ~ Chrome 36-
|
|
1250
|
-
// https://bugs.chromium.org/p/v8/issues/detail?id=3334
|
|
1251
|
-
var v8PrototypeDefineBug = DESCRIPTORS$c && fails$g(function () {
|
|
1252
|
-
// eslint-disable-next-line es/no-object-defineproperty -- required for testing
|
|
1253
|
-
return Object.defineProperty(function () { /* empty */ }, 'prototype', {
|
|
1254
|
-
value: 42,
|
|
1255
|
-
writable: false
|
|
1256
|
-
}).prototype !== 42;
|
|
1257
|
-
});
|
|
1258
|
-
|
|
1259
|
-
var objectDefineProperty = {};
|
|
1260
|
-
|
|
1261
|
-
var global$d = global$i;
|
|
1262
|
-
var isObject$8 = isObject$a;
|
|
1263
|
-
|
|
1264
|
-
var document$1 = global$d.document;
|
|
1265
|
-
// typeof document.createElement is 'object' in old IE
|
|
1266
|
-
var EXISTS$1 = isObject$8(document$1) && isObject$8(document$1.createElement);
|
|
1267
|
-
|
|
1268
|
-
var documentCreateElement$2 = function (it) {
|
|
1269
|
-
return EXISTS$1 ? document$1.createElement(it) : {};
|
|
1270
|
-
};
|
|
1271
|
-
|
|
1272
|
-
var DESCRIPTORS$b = descriptors;
|
|
1273
|
-
var fails$f = fails$l;
|
|
1274
|
-
var createElement = documentCreateElement$2;
|
|
1275
|
-
|
|
1276
|
-
// Thanks to IE8 for its funny defineProperty
|
|
1277
|
-
var ie8DomDefine = !DESCRIPTORS$b && !fails$f(function () {
|
|
1278
|
-
// eslint-disable-next-line es/no-object-defineproperty -- required for testing
|
|
1279
|
-
return Object.defineProperty(createElement('div'), 'a', {
|
|
1280
|
-
get: function () { return 7; }
|
|
1281
|
-
}).a !== 7;
|
|
1282
|
-
});
|
|
1283
|
-
|
|
1284
|
-
var NATIVE_BIND$1 = functionBindNative;
|
|
1285
|
-
|
|
1286
|
-
var call$a = Function.prototype.call;
|
|
1287
|
-
|
|
1288
|
-
var functionCall = NATIVE_BIND$1 ? call$a.bind(call$a) : function () {
|
|
1289
|
-
return call$a.apply(call$a, arguments);
|
|
1290
|
-
};
|
|
1291
|
-
|
|
1292
|
-
var global$c = global$i;
|
|
1293
|
-
var isCallable$g = isCallable$i;
|
|
1294
|
-
|
|
1295
|
-
var aFunction = function (argument) {
|
|
1296
|
-
return isCallable$g(argument) ? argument : undefined;
|
|
1297
|
-
};
|
|
1298
|
-
|
|
1299
|
-
var getBuiltIn$5 = function (namespace, method) {
|
|
1300
|
-
return arguments.length < 2 ? aFunction(global$c[namespace]) : global$c[namespace] && global$c[namespace][method];
|
|
1301
|
-
};
|
|
1302
|
-
|
|
1303
|
-
var uncurryThis$e = functionUncurryThis;
|
|
1304
|
-
|
|
1305
|
-
var objectIsPrototypeOf = uncurryThis$e({}.isPrototypeOf);
|
|
1306
|
-
|
|
1307
865
|
var getBuiltIn$4 = getBuiltIn$5;
|
|
1308
866
|
var isCallable$f = isCallable$i;
|
|
1309
867
|
var isPrototypeOf$2 = objectIsPrototypeOf;
|
|
1310
|
-
var USE_SYMBOL_AS_UID = useSymbolAsUid;
|
|
868
|
+
var USE_SYMBOL_AS_UID$1 = useSymbolAsUid;
|
|
1311
869
|
|
|
1312
|
-
var $Object$
|
|
870
|
+
var $Object$3 = Object;
|
|
1313
871
|
|
|
1314
|
-
var isSymbol$2 = USE_SYMBOL_AS_UID ? function (it) {
|
|
872
|
+
var isSymbol$2 = USE_SYMBOL_AS_UID$1 ? function (it) {
|
|
1315
873
|
return typeof it == 'symbol';
|
|
1316
874
|
} : function (it) {
|
|
1317
875
|
var $Symbol = getBuiltIn$4('Symbol');
|
|
1318
|
-
return isCallable$f($Symbol) && isPrototypeOf$2($Symbol.prototype, $Object$
|
|
876
|
+
return isCallable$f($Symbol) && isPrototypeOf$2($Symbol.prototype, $Object$3(it));
|
|
1319
877
|
};
|
|
1320
878
|
|
|
1321
|
-
var $String$
|
|
879
|
+
var $String$4 = String;
|
|
1322
880
|
|
|
1323
881
|
var tryToString$2 = function (argument) {
|
|
1324
882
|
try {
|
|
1325
|
-
return $String$
|
|
883
|
+
return $String$4(argument);
|
|
1326
884
|
} catch (error) {
|
|
1327
885
|
return 'Object';
|
|
1328
886
|
}
|
|
@@ -1331,12 +889,12 @@ var tryToString$2 = function (argument) {
|
|
|
1331
889
|
var isCallable$e = isCallable$i;
|
|
1332
890
|
var tryToString$1 = tryToString$2;
|
|
1333
891
|
|
|
1334
|
-
var $TypeError$
|
|
892
|
+
var $TypeError$a = TypeError;
|
|
1335
893
|
|
|
1336
894
|
// `Assert: IsCallable(argument) is true`
|
|
1337
895
|
var aCallable$3 = function (argument) {
|
|
1338
896
|
if (isCallable$e(argument)) return argument;
|
|
1339
|
-
throw new $TypeError$
|
|
897
|
+
throw new $TypeError$a(tryToString$1(argument) + ' is not a function');
|
|
1340
898
|
};
|
|
1341
899
|
|
|
1342
900
|
var aCallable$2 = aCallable$3;
|
|
@@ -1351,41 +909,127 @@ var getMethod$2 = function (V, P) {
|
|
|
1351
909
|
|
|
1352
910
|
var call$9 = functionCall;
|
|
1353
911
|
var isCallable$d = isCallable$i;
|
|
1354
|
-
var isObject$
|
|
912
|
+
var isObject$9 = isObject$a;
|
|
1355
913
|
|
|
1356
|
-
var $TypeError$
|
|
914
|
+
var $TypeError$9 = TypeError;
|
|
1357
915
|
|
|
1358
916
|
// `OrdinaryToPrimitive` abstract operation
|
|
1359
917
|
// https://tc39.es/ecma262/#sec-ordinarytoprimitive
|
|
1360
918
|
var ordinaryToPrimitive$1 = function (input, pref) {
|
|
1361
919
|
var fn, val;
|
|
1362
|
-
if (pref === 'string' && isCallable$d(fn = input.toString) && !isObject$
|
|
1363
|
-
if (isCallable$d(fn = input.valueOf) && !isObject$
|
|
1364
|
-
if (pref !== 'string' && isCallable$d(fn = input.toString) && !isObject$
|
|
1365
|
-
throw new $TypeError$
|
|
920
|
+
if (pref === 'string' && isCallable$d(fn = input.toString) && !isObject$9(val = call$9(fn, input))) return val;
|
|
921
|
+
if (isCallable$d(fn = input.valueOf) && !isObject$9(val = call$9(fn, input))) return val;
|
|
922
|
+
if (pref !== 'string' && isCallable$d(fn = input.toString) && !isObject$9(val = call$9(fn, input))) return val;
|
|
923
|
+
throw new $TypeError$9("Can't convert object to primitive value");
|
|
924
|
+
};
|
|
925
|
+
|
|
926
|
+
var sharedStore = {exports: {}};
|
|
927
|
+
|
|
928
|
+
var global$e = global$i;
|
|
929
|
+
|
|
930
|
+
// eslint-disable-next-line es/no-object-defineproperty -- safe
|
|
931
|
+
var defineProperty$7 = Object.defineProperty;
|
|
932
|
+
|
|
933
|
+
var defineGlobalProperty$3 = function (key, value) {
|
|
934
|
+
try {
|
|
935
|
+
defineProperty$7(global$e, key, { value: value, configurable: true, writable: true });
|
|
936
|
+
} catch (error) {
|
|
937
|
+
global$e[key] = value;
|
|
938
|
+
} return value;
|
|
939
|
+
};
|
|
940
|
+
|
|
941
|
+
var globalThis$1 = global$i;
|
|
942
|
+
var defineGlobalProperty$2 = defineGlobalProperty$3;
|
|
943
|
+
|
|
944
|
+
var SHARED = '__core-js_shared__';
|
|
945
|
+
var store$3 = sharedStore.exports = globalThis$1[SHARED] || defineGlobalProperty$2(SHARED, {});
|
|
946
|
+
|
|
947
|
+
(store$3.versions || (store$3.versions = [])).push({
|
|
948
|
+
version: '3.36.1',
|
|
949
|
+
mode: 'global',
|
|
950
|
+
copyright: '© 2014-2024 Denis Pushkarev (zloirock.ru)',
|
|
951
|
+
license: 'https://github.com/zloirock/core-js/blob/v3.36.1/LICENSE',
|
|
952
|
+
source: 'https://github.com/zloirock/core-js'
|
|
953
|
+
});
|
|
954
|
+
|
|
955
|
+
var store$2 = sharedStore.exports;
|
|
956
|
+
|
|
957
|
+
var shared$4 = function (key, value) {
|
|
958
|
+
return store$2[key] || (store$2[key] = value || {});
|
|
959
|
+
};
|
|
960
|
+
|
|
961
|
+
var requireObjectCoercible$4 = requireObjectCoercible$6;
|
|
962
|
+
|
|
963
|
+
var $Object$2 = Object;
|
|
964
|
+
|
|
965
|
+
// `ToObject` abstract operation
|
|
966
|
+
// https://tc39.es/ecma262/#sec-toobject
|
|
967
|
+
var toObject$5 = function (argument) {
|
|
968
|
+
return $Object$2(requireObjectCoercible$4(argument));
|
|
969
|
+
};
|
|
970
|
+
|
|
971
|
+
var uncurryThis$f = functionUncurryThis;
|
|
972
|
+
var toObject$4 = toObject$5;
|
|
973
|
+
|
|
974
|
+
var hasOwnProperty = uncurryThis$f({}.hasOwnProperty);
|
|
975
|
+
|
|
976
|
+
// `HasOwnProperty` abstract operation
|
|
977
|
+
// https://tc39.es/ecma262/#sec-hasownproperty
|
|
978
|
+
// eslint-disable-next-line es/no-object-hasown -- safe
|
|
979
|
+
var hasOwnProperty_1 = Object.hasOwn || function hasOwn(it, key) {
|
|
980
|
+
return hasOwnProperty(toObject$4(it), key);
|
|
981
|
+
};
|
|
982
|
+
|
|
983
|
+
var uncurryThis$e = functionUncurryThis;
|
|
984
|
+
|
|
985
|
+
var id = 0;
|
|
986
|
+
var postfix = Math.random();
|
|
987
|
+
var toString$8 = uncurryThis$e(1.0.toString);
|
|
988
|
+
|
|
989
|
+
var uid$2 = function (key) {
|
|
990
|
+
return 'Symbol(' + (key === undefined ? '' : key) + ')_' + toString$8(++id + postfix, 36);
|
|
991
|
+
};
|
|
992
|
+
|
|
993
|
+
var global$d = global$i;
|
|
994
|
+
var shared$3 = shared$4;
|
|
995
|
+
var hasOwn$a = hasOwnProperty_1;
|
|
996
|
+
var uid$1 = uid$2;
|
|
997
|
+
var NATIVE_SYMBOL$1 = symbolConstructorDetection;
|
|
998
|
+
var USE_SYMBOL_AS_UID = useSymbolAsUid;
|
|
999
|
+
|
|
1000
|
+
var Symbol$2 = global$d.Symbol;
|
|
1001
|
+
var WellKnownSymbolsStore = shared$3('wks');
|
|
1002
|
+
var createWellKnownSymbol = USE_SYMBOL_AS_UID ? Symbol$2['for'] || Symbol$2 : Symbol$2 && Symbol$2.withoutSetter || uid$1;
|
|
1003
|
+
|
|
1004
|
+
var wellKnownSymbol$a = function (name) {
|
|
1005
|
+
if (!hasOwn$a(WellKnownSymbolsStore, name)) {
|
|
1006
|
+
WellKnownSymbolsStore[name] = NATIVE_SYMBOL$1 && hasOwn$a(Symbol$2, name)
|
|
1007
|
+
? Symbol$2[name]
|
|
1008
|
+
: createWellKnownSymbol('Symbol.' + name);
|
|
1009
|
+
} return WellKnownSymbolsStore[name];
|
|
1366
1010
|
};
|
|
1367
1011
|
|
|
1368
1012
|
var call$8 = functionCall;
|
|
1369
|
-
var isObject$
|
|
1013
|
+
var isObject$8 = isObject$a;
|
|
1370
1014
|
var isSymbol$1 = isSymbol$2;
|
|
1371
1015
|
var getMethod$1 = getMethod$2;
|
|
1372
1016
|
var ordinaryToPrimitive = ordinaryToPrimitive$1;
|
|
1373
1017
|
var wellKnownSymbol$9 = wellKnownSymbol$a;
|
|
1374
1018
|
|
|
1375
|
-
var $TypeError$
|
|
1019
|
+
var $TypeError$8 = TypeError;
|
|
1376
1020
|
var TO_PRIMITIVE = wellKnownSymbol$9('toPrimitive');
|
|
1377
1021
|
|
|
1378
1022
|
// `ToPrimitive` abstract operation
|
|
1379
1023
|
// https://tc39.es/ecma262/#sec-toprimitive
|
|
1380
1024
|
var toPrimitive$1 = function (input, pref) {
|
|
1381
|
-
if (!isObject$
|
|
1025
|
+
if (!isObject$8(input) || isSymbol$1(input)) return input;
|
|
1382
1026
|
var exoticToPrim = getMethod$1(input, TO_PRIMITIVE);
|
|
1383
1027
|
var result;
|
|
1384
1028
|
if (exoticToPrim) {
|
|
1385
1029
|
if (pref === undefined) pref = 'default';
|
|
1386
1030
|
result = call$8(exoticToPrim, input, pref);
|
|
1387
|
-
if (!isObject$
|
|
1388
|
-
throw new $TypeError$
|
|
1031
|
+
if (!isObject$8(result) || isSymbol$1(result)) return result;
|
|
1032
|
+
throw new $TypeError$8("Can't convert object to primitive value");
|
|
1389
1033
|
}
|
|
1390
1034
|
if (pref === undefined) pref = 'number';
|
|
1391
1035
|
return ordinaryToPrimitive(input, pref);
|
|
@@ -1401,29 +1045,101 @@ var toPropertyKey$2 = function (argument) {
|
|
|
1401
1045
|
return isSymbol(key) ? key : key + '';
|
|
1402
1046
|
};
|
|
1403
1047
|
|
|
1404
|
-
var
|
|
1405
|
-
var
|
|
1406
|
-
|
|
1407
|
-
var
|
|
1048
|
+
var global$c = global$i;
|
|
1049
|
+
var isObject$7 = isObject$a;
|
|
1050
|
+
|
|
1051
|
+
var document$1 = global$c.document;
|
|
1052
|
+
// typeof document.createElement is 'object' in old IE
|
|
1053
|
+
var EXISTS$1 = isObject$7(document$1) && isObject$7(document$1.createElement);
|
|
1054
|
+
|
|
1055
|
+
var documentCreateElement$2 = function (it) {
|
|
1056
|
+
return EXISTS$1 ? document$1.createElement(it) : {};
|
|
1057
|
+
};
|
|
1058
|
+
|
|
1059
|
+
var DESCRIPTORS$c = descriptors;
|
|
1060
|
+
var fails$g = fails$l;
|
|
1061
|
+
var createElement = documentCreateElement$2;
|
|
1062
|
+
|
|
1063
|
+
// Thanks to IE8 for its funny defineProperty
|
|
1064
|
+
var ie8DomDefine = !DESCRIPTORS$c && !fails$g(function () {
|
|
1065
|
+
// eslint-disable-next-line es/no-object-defineproperty -- required for testing
|
|
1066
|
+
return Object.defineProperty(createElement('div'), 'a', {
|
|
1067
|
+
get: function () { return 7; }
|
|
1068
|
+
}).a !== 7;
|
|
1069
|
+
});
|
|
1070
|
+
|
|
1071
|
+
var DESCRIPTORS$b = descriptors;
|
|
1072
|
+
var call$7 = functionCall;
|
|
1073
|
+
var propertyIsEnumerableModule$1 = objectPropertyIsEnumerable;
|
|
1074
|
+
var createPropertyDescriptor$3 = createPropertyDescriptor$4;
|
|
1075
|
+
var toIndexedObject$4 = toIndexedObject$5;
|
|
1408
1076
|
var toPropertyKey$1 = toPropertyKey$2;
|
|
1077
|
+
var hasOwn$9 = hasOwnProperty_1;
|
|
1078
|
+
var IE8_DOM_DEFINE$1 = ie8DomDefine;
|
|
1079
|
+
|
|
1080
|
+
// eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe
|
|
1081
|
+
var $getOwnPropertyDescriptor$1 = Object.getOwnPropertyDescriptor;
|
|
1082
|
+
|
|
1083
|
+
// `Object.getOwnPropertyDescriptor` method
|
|
1084
|
+
// https://tc39.es/ecma262/#sec-object.getownpropertydescriptor
|
|
1085
|
+
objectGetOwnPropertyDescriptor.f = DESCRIPTORS$b ? $getOwnPropertyDescriptor$1 : function getOwnPropertyDescriptor(O, P) {
|
|
1086
|
+
O = toIndexedObject$4(O);
|
|
1087
|
+
P = toPropertyKey$1(P);
|
|
1088
|
+
if (IE8_DOM_DEFINE$1) try {
|
|
1089
|
+
return $getOwnPropertyDescriptor$1(O, P);
|
|
1090
|
+
} catch (error) { /* empty */ }
|
|
1091
|
+
if (hasOwn$9(O, P)) return createPropertyDescriptor$3(!call$7(propertyIsEnumerableModule$1.f, O, P), O[P]);
|
|
1092
|
+
};
|
|
1093
|
+
|
|
1094
|
+
var objectDefineProperty = {};
|
|
1095
|
+
|
|
1096
|
+
var DESCRIPTORS$a = descriptors;
|
|
1097
|
+
var fails$f = fails$l;
|
|
1098
|
+
|
|
1099
|
+
// V8 ~ Chrome 36-
|
|
1100
|
+
// https://bugs.chromium.org/p/v8/issues/detail?id=3334
|
|
1101
|
+
var v8PrototypeDefineBug = DESCRIPTORS$a && fails$f(function () {
|
|
1102
|
+
// eslint-disable-next-line es/no-object-defineproperty -- required for testing
|
|
1103
|
+
return Object.defineProperty(function () { /* empty */ }, 'prototype', {
|
|
1104
|
+
value: 42,
|
|
1105
|
+
writable: false
|
|
1106
|
+
}).prototype !== 42;
|
|
1107
|
+
});
|
|
1108
|
+
|
|
1109
|
+
var isObject$6 = isObject$a;
|
|
1110
|
+
|
|
1111
|
+
var $String$3 = String;
|
|
1112
|
+
var $TypeError$7 = TypeError;
|
|
1113
|
+
|
|
1114
|
+
// `Assert: Type(argument) is Object`
|
|
1115
|
+
var anObject$8 = function (argument) {
|
|
1116
|
+
if (isObject$6(argument)) return argument;
|
|
1117
|
+
throw new $TypeError$7($String$3(argument) + ' is not an object');
|
|
1118
|
+
};
|
|
1119
|
+
|
|
1120
|
+
var DESCRIPTORS$9 = descriptors;
|
|
1121
|
+
var IE8_DOM_DEFINE = ie8DomDefine;
|
|
1122
|
+
var V8_PROTOTYPE_DEFINE_BUG$1 = v8PrototypeDefineBug;
|
|
1123
|
+
var anObject$7 = anObject$8;
|
|
1124
|
+
var toPropertyKey = toPropertyKey$2;
|
|
1409
1125
|
|
|
1410
1126
|
var $TypeError$6 = TypeError;
|
|
1411
1127
|
// eslint-disable-next-line es/no-object-defineproperty -- safe
|
|
1412
1128
|
var $defineProperty = Object.defineProperty;
|
|
1413
1129
|
// eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe
|
|
1414
|
-
var $getOwnPropertyDescriptor
|
|
1130
|
+
var $getOwnPropertyDescriptor = Object.getOwnPropertyDescriptor;
|
|
1415
1131
|
var ENUMERABLE = 'enumerable';
|
|
1416
1132
|
var CONFIGURABLE$1 = 'configurable';
|
|
1417
1133
|
var WRITABLE = 'writable';
|
|
1418
1134
|
|
|
1419
1135
|
// `Object.defineProperty` method
|
|
1420
1136
|
// https://tc39.es/ecma262/#sec-object.defineproperty
|
|
1421
|
-
objectDefineProperty.f = DESCRIPTORS$
|
|
1137
|
+
objectDefineProperty.f = DESCRIPTORS$9 ? V8_PROTOTYPE_DEFINE_BUG$1 ? function defineProperty(O, P, Attributes) {
|
|
1422
1138
|
anObject$7(O);
|
|
1423
|
-
P = toPropertyKey
|
|
1139
|
+
P = toPropertyKey(P);
|
|
1424
1140
|
anObject$7(Attributes);
|
|
1425
1141
|
if (typeof O === 'function' && P === 'prototype' && 'value' in Attributes && WRITABLE in Attributes && !Attributes[WRITABLE]) {
|
|
1426
|
-
var current = $getOwnPropertyDescriptor
|
|
1142
|
+
var current = $getOwnPropertyDescriptor(O, P);
|
|
1427
1143
|
if (current && current[WRITABLE]) {
|
|
1428
1144
|
O[P] = Attributes.value;
|
|
1429
1145
|
Attributes = {
|
|
@@ -1435,9 +1151,9 @@ objectDefineProperty.f = DESCRIPTORS$a ? V8_PROTOTYPE_DEFINE_BUG$1 ? function de
|
|
|
1435
1151
|
} return $defineProperty(O, P, Attributes);
|
|
1436
1152
|
} : $defineProperty : function defineProperty(O, P, Attributes) {
|
|
1437
1153
|
anObject$7(O);
|
|
1438
|
-
P = toPropertyKey
|
|
1154
|
+
P = toPropertyKey(P);
|
|
1439
1155
|
anObject$7(Attributes);
|
|
1440
|
-
if (IE8_DOM_DEFINE
|
|
1156
|
+
if (IE8_DOM_DEFINE) try {
|
|
1441
1157
|
return $defineProperty(O, P, Attributes);
|
|
1442
1158
|
} catch (error) { /* empty */ }
|
|
1443
1159
|
if ('get' in Attributes || 'set' in Attributes) throw new $TypeError$6('Accessors not supported');
|
|
@@ -1445,161 +1161,58 @@ objectDefineProperty.f = DESCRIPTORS$a ? V8_PROTOTYPE_DEFINE_BUG$1 ? function de
|
|
|
1445
1161
|
return O;
|
|
1446
1162
|
};
|
|
1447
1163
|
|
|
1448
|
-
var
|
|
1449
|
-
var
|
|
1450
|
-
|
|
1451
|
-
// `Math.trunc` method
|
|
1452
|
-
// https://tc39.es/ecma262/#sec-math.trunc
|
|
1453
|
-
// eslint-disable-next-line es/no-math-trunc -- safe
|
|
1454
|
-
var mathTrunc = Math.trunc || function trunc(x) {
|
|
1455
|
-
var n = +x;
|
|
1456
|
-
return (n > 0 ? floor : ceil)(n);
|
|
1457
|
-
};
|
|
1458
|
-
|
|
1459
|
-
var trunc = mathTrunc;
|
|
1460
|
-
|
|
1461
|
-
// `ToIntegerOrInfinity` abstract operation
|
|
1462
|
-
// https://tc39.es/ecma262/#sec-tointegerorinfinity
|
|
1463
|
-
var toIntegerOrInfinity$3 = function (argument) {
|
|
1464
|
-
var number = +argument;
|
|
1465
|
-
// eslint-disable-next-line no-self-compare -- NaN check
|
|
1466
|
-
return number !== number || number === 0 ? 0 : trunc(number);
|
|
1467
|
-
};
|
|
1468
|
-
|
|
1469
|
-
var toIntegerOrInfinity$2 = toIntegerOrInfinity$3;
|
|
1470
|
-
|
|
1471
|
-
var max = Math.max;
|
|
1472
|
-
var min$2 = Math.min;
|
|
1473
|
-
|
|
1474
|
-
// Helper for a popular repeating case of the spec:
|
|
1475
|
-
// Let integer be ? ToInteger(index).
|
|
1476
|
-
// If integer < 0, let result be max((length + integer), 0); else let result be min(integer, length).
|
|
1477
|
-
var toAbsoluteIndex$1 = function (index, length) {
|
|
1478
|
-
var integer = toIntegerOrInfinity$2(index);
|
|
1479
|
-
return integer < 0 ? max(integer + length, 0) : min$2(integer, length);
|
|
1480
|
-
};
|
|
1481
|
-
|
|
1482
|
-
var toIntegerOrInfinity$1 = toIntegerOrInfinity$3;
|
|
1483
|
-
|
|
1484
|
-
var min$1 = Math.min;
|
|
1164
|
+
var DESCRIPTORS$8 = descriptors;
|
|
1165
|
+
var definePropertyModule$3 = objectDefineProperty;
|
|
1166
|
+
var createPropertyDescriptor$2 = createPropertyDescriptor$4;
|
|
1485
1167
|
|
|
1486
|
-
|
|
1487
|
-
|
|
1488
|
-
|
|
1489
|
-
|
|
1490
|
-
return
|
|
1168
|
+
var createNonEnumerableProperty$8 = DESCRIPTORS$8 ? function (object, key, value) {
|
|
1169
|
+
return definePropertyModule$3.f(object, key, createPropertyDescriptor$2(1, value));
|
|
1170
|
+
} : function (object, key, value) {
|
|
1171
|
+
object[key] = value;
|
|
1172
|
+
return object;
|
|
1491
1173
|
};
|
|
1492
1174
|
|
|
1493
|
-
var
|
|
1175
|
+
var makeBuiltIn$3 = {exports: {}};
|
|
1494
1176
|
|
|
1495
|
-
|
|
1496
|
-
|
|
1497
|
-
var lengthOfArrayLike$3 = function (obj) {
|
|
1498
|
-
return toLength$1(obj.length);
|
|
1499
|
-
};
|
|
1177
|
+
var DESCRIPTORS$7 = descriptors;
|
|
1178
|
+
var hasOwn$8 = hasOwnProperty_1;
|
|
1500
1179
|
|
|
1501
|
-
var
|
|
1502
|
-
|
|
1503
|
-
var
|
|
1180
|
+
var FunctionPrototype$1 = Function.prototype;
|
|
1181
|
+
// eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe
|
|
1182
|
+
var getDescriptor = DESCRIPTORS$7 && Object.getOwnPropertyDescriptor;
|
|
1504
1183
|
|
|
1505
|
-
|
|
1506
|
-
|
|
1507
|
-
|
|
1508
|
-
|
|
1509
|
-
var length = lengthOfArrayLike$2(O);
|
|
1510
|
-
if (length === 0) return !IS_INCLUDES && -1;
|
|
1511
|
-
var index = toAbsoluteIndex(fromIndex, length);
|
|
1512
|
-
var value;
|
|
1513
|
-
// Array#includes uses SameValueZero equality algorithm
|
|
1514
|
-
// eslint-disable-next-line no-self-compare -- NaN check
|
|
1515
|
-
if (IS_INCLUDES && el !== el) while (length > index) {
|
|
1516
|
-
value = O[index++];
|
|
1517
|
-
// eslint-disable-next-line no-self-compare -- NaN check
|
|
1518
|
-
if (value !== value) return true;
|
|
1519
|
-
// Array#indexOf ignores holes, Array#includes - not
|
|
1520
|
-
} else for (;length > index; index++) {
|
|
1521
|
-
if ((IS_INCLUDES || index in O) && O[index] === el) return IS_INCLUDES || index || 0;
|
|
1522
|
-
} return !IS_INCLUDES && -1;
|
|
1523
|
-
};
|
|
1524
|
-
};
|
|
1184
|
+
var EXISTS = hasOwn$8(FunctionPrototype$1, 'name');
|
|
1185
|
+
// additional protection from minified / mangled / dropped function names
|
|
1186
|
+
var PROPER = EXISTS && (function something() { /* empty */ }).name === 'something';
|
|
1187
|
+
var CONFIGURABLE = EXISTS && (!DESCRIPTORS$7 || (DESCRIPTORS$7 && getDescriptor(FunctionPrototype$1, 'name').configurable));
|
|
1525
1188
|
|
|
1526
|
-
var
|
|
1527
|
-
|
|
1528
|
-
|
|
1529
|
-
|
|
1530
|
-
// `Array.prototype.indexOf` method
|
|
1531
|
-
// https://tc39.es/ecma262/#sec-array.prototype.indexof
|
|
1532
|
-
indexOf: createMethod$3(false)
|
|
1189
|
+
var functionName = {
|
|
1190
|
+
EXISTS: EXISTS,
|
|
1191
|
+
PROPER: PROPER,
|
|
1192
|
+
CONFIGURABLE: CONFIGURABLE
|
|
1533
1193
|
};
|
|
1534
1194
|
|
|
1535
|
-
var hiddenKeys$4 = {};
|
|
1536
|
-
|
|
1537
1195
|
var uncurryThis$d = functionUncurryThis;
|
|
1538
|
-
var
|
|
1539
|
-
var
|
|
1540
|
-
var indexOf$1 = arrayIncludes.indexOf;
|
|
1541
|
-
var hiddenKeys$3 = hiddenKeys$4;
|
|
1542
|
-
|
|
1543
|
-
var push$1 = uncurryThis$d([].push);
|
|
1544
|
-
|
|
1545
|
-
var objectKeysInternal = function (object, names) {
|
|
1546
|
-
var O = toIndexedObject$3(object);
|
|
1547
|
-
var i = 0;
|
|
1548
|
-
var result = [];
|
|
1549
|
-
var key;
|
|
1550
|
-
for (key in O) !hasOwn$9(hiddenKeys$3, key) && hasOwn$9(O, key) && push$1(result, key);
|
|
1551
|
-
// Don't enum bug & hidden keys
|
|
1552
|
-
while (names.length > i) if (hasOwn$9(O, key = names[i++])) {
|
|
1553
|
-
~indexOf$1(result, key) || push$1(result, key);
|
|
1554
|
-
}
|
|
1555
|
-
return result;
|
|
1556
|
-
};
|
|
1557
|
-
|
|
1558
|
-
// IE8- don't enum bug keys
|
|
1559
|
-
var enumBugKeys$3 = [
|
|
1560
|
-
'constructor',
|
|
1561
|
-
'hasOwnProperty',
|
|
1562
|
-
'isPrototypeOf',
|
|
1563
|
-
'propertyIsEnumerable',
|
|
1564
|
-
'toLocaleString',
|
|
1565
|
-
'toString',
|
|
1566
|
-
'valueOf'
|
|
1567
|
-
];
|
|
1196
|
+
var isCallable$c = isCallable$i;
|
|
1197
|
+
var store$1 = sharedStore.exports;
|
|
1568
1198
|
|
|
1569
|
-
var
|
|
1570
|
-
var enumBugKeys$2 = enumBugKeys$3;
|
|
1199
|
+
var functionToString = uncurryThis$d(Function.toString);
|
|
1571
1200
|
|
|
1572
|
-
// `
|
|
1573
|
-
|
|
1574
|
-
|
|
1575
|
-
|
|
1576
|
-
|
|
1577
|
-
}
|
|
1201
|
+
// this helper broken in `core-js@3.4.1-3.4.4`, so we can't use `shared` helper
|
|
1202
|
+
if (!isCallable$c(store$1.inspectSource)) {
|
|
1203
|
+
store$1.inspectSource = function (it) {
|
|
1204
|
+
return functionToString(it);
|
|
1205
|
+
};
|
|
1206
|
+
}
|
|
1578
1207
|
|
|
1579
|
-
var
|
|
1580
|
-
var V8_PROTOTYPE_DEFINE_BUG = v8PrototypeDefineBug;
|
|
1581
|
-
var definePropertyModule$3 = objectDefineProperty;
|
|
1582
|
-
var anObject$6 = anObject$8;
|
|
1583
|
-
var toIndexedObject$2 = toIndexedObject$5;
|
|
1584
|
-
var objectKeys$1 = objectKeys$2;
|
|
1208
|
+
var inspectSource$2 = store$1.inspectSource;
|
|
1585
1209
|
|
|
1586
|
-
|
|
1587
|
-
|
|
1588
|
-
// eslint-disable-next-line es/no-object-defineproperties -- safe
|
|
1589
|
-
objectDefineProperties.f = DESCRIPTORS$9 && !V8_PROTOTYPE_DEFINE_BUG ? Object.defineProperties : function defineProperties(O, Properties) {
|
|
1590
|
-
anObject$6(O);
|
|
1591
|
-
var props = toIndexedObject$2(Properties);
|
|
1592
|
-
var keys = objectKeys$1(Properties);
|
|
1593
|
-
var length = keys.length;
|
|
1594
|
-
var index = 0;
|
|
1595
|
-
var key;
|
|
1596
|
-
while (length > index) definePropertyModule$3.f(O, key = keys[index++], props[key]);
|
|
1597
|
-
return O;
|
|
1598
|
-
};
|
|
1210
|
+
var global$b = global$i;
|
|
1211
|
+
var isCallable$b = isCallable$i;
|
|
1599
1212
|
|
|
1600
|
-
var
|
|
1213
|
+
var WeakMap$1 = global$b.WeakMap;
|
|
1601
1214
|
|
|
1602
|
-
var
|
|
1215
|
+
var weakMapBasicDetection = isCallable$b(WeakMap$1) && /native code/.test(String(WeakMap$1));
|
|
1603
1216
|
|
|
1604
1217
|
var shared$2 = shared$4;
|
|
1605
1218
|
var uid = uid$2;
|
|
@@ -1610,157 +1223,25 @@ var sharedKey$3 = function (key) {
|
|
|
1610
1223
|
return keys[key] || (keys[key] = uid(key));
|
|
1611
1224
|
};
|
|
1612
1225
|
|
|
1613
|
-
|
|
1614
|
-
|
|
1615
|
-
var
|
|
1616
|
-
var
|
|
1617
|
-
var
|
|
1618
|
-
var
|
|
1619
|
-
var
|
|
1226
|
+
var hiddenKeys$4 = {};
|
|
1227
|
+
|
|
1228
|
+
var NATIVE_WEAK_MAP = weakMapBasicDetection;
|
|
1229
|
+
var global$a = global$i;
|
|
1230
|
+
var isObject$5 = isObject$a;
|
|
1231
|
+
var createNonEnumerableProperty$7 = createNonEnumerableProperty$8;
|
|
1232
|
+
var hasOwn$7 = hasOwnProperty_1;
|
|
1233
|
+
var shared$1 = sharedStore.exports;
|
|
1620
1234
|
var sharedKey$2 = sharedKey$3;
|
|
1235
|
+
var hiddenKeys$3 = hiddenKeys$4;
|
|
1621
1236
|
|
|
1622
|
-
var
|
|
1623
|
-
var
|
|
1624
|
-
var
|
|
1625
|
-
var
|
|
1626
|
-
var IE_PROTO$1 = sharedKey$2('IE_PROTO');
|
|
1237
|
+
var OBJECT_ALREADY_INITIALIZED = 'Object already initialized';
|
|
1238
|
+
var TypeError$1 = global$a.TypeError;
|
|
1239
|
+
var WeakMap = global$a.WeakMap;
|
|
1240
|
+
var set, get, has;
|
|
1627
1241
|
|
|
1628
|
-
var
|
|
1629
|
-
|
|
1630
|
-
|
|
1631
|
-
return LT + SCRIPT + GT + content + LT + '/' + SCRIPT + GT;
|
|
1632
|
-
};
|
|
1633
|
-
|
|
1634
|
-
// Create object with fake `null` prototype: use ActiveX Object with cleared prototype
|
|
1635
|
-
var NullProtoObjectViaActiveX = function (activeXDocument) {
|
|
1636
|
-
activeXDocument.write(scriptTag(''));
|
|
1637
|
-
activeXDocument.close();
|
|
1638
|
-
var temp = activeXDocument.parentWindow.Object;
|
|
1639
|
-
activeXDocument = null; // avoid memory leak
|
|
1640
|
-
return temp;
|
|
1641
|
-
};
|
|
1642
|
-
|
|
1643
|
-
// Create object with fake `null` prototype: use iframe Object with cleared prototype
|
|
1644
|
-
var NullProtoObjectViaIFrame = function () {
|
|
1645
|
-
// Thrash, waste and sodomy: IE GC bug
|
|
1646
|
-
var iframe = documentCreateElement$1('iframe');
|
|
1647
|
-
var JS = 'java' + SCRIPT + ':';
|
|
1648
|
-
var iframeDocument;
|
|
1649
|
-
iframe.style.display = 'none';
|
|
1650
|
-
html.appendChild(iframe);
|
|
1651
|
-
// https://github.com/zloirock/core-js/issues/475
|
|
1652
|
-
iframe.src = String(JS);
|
|
1653
|
-
iframeDocument = iframe.contentWindow.document;
|
|
1654
|
-
iframeDocument.open();
|
|
1655
|
-
iframeDocument.write(scriptTag('document.F=Object'));
|
|
1656
|
-
iframeDocument.close();
|
|
1657
|
-
return iframeDocument.F;
|
|
1658
|
-
};
|
|
1659
|
-
|
|
1660
|
-
// Check for document.domain and active x support
|
|
1661
|
-
// No need to use active x approach when document.domain is not set
|
|
1662
|
-
// see https://github.com/es-shims/es5-shim/issues/150
|
|
1663
|
-
// variation of https://github.com/kitcambridge/es5-shim/commit/4f738ac066346
|
|
1664
|
-
// avoid IE GC bug
|
|
1665
|
-
var activeXDocument;
|
|
1666
|
-
var NullProtoObject = function () {
|
|
1667
|
-
try {
|
|
1668
|
-
activeXDocument = new ActiveXObject('htmlfile');
|
|
1669
|
-
} catch (error) { /* ignore */ }
|
|
1670
|
-
NullProtoObject = typeof document != 'undefined'
|
|
1671
|
-
? document.domain && activeXDocument
|
|
1672
|
-
? NullProtoObjectViaActiveX(activeXDocument) // old IE
|
|
1673
|
-
: NullProtoObjectViaIFrame()
|
|
1674
|
-
: NullProtoObjectViaActiveX(activeXDocument); // WSH
|
|
1675
|
-
var length = enumBugKeys$1.length;
|
|
1676
|
-
while (length--) delete NullProtoObject[PROTOTYPE][enumBugKeys$1[length]];
|
|
1677
|
-
return NullProtoObject();
|
|
1678
|
-
};
|
|
1679
|
-
|
|
1680
|
-
hiddenKeys$2[IE_PROTO$1] = true;
|
|
1681
|
-
|
|
1682
|
-
// `Object.create` method
|
|
1683
|
-
// https://tc39.es/ecma262/#sec-object.create
|
|
1684
|
-
// eslint-disable-next-line es/no-object-create -- safe
|
|
1685
|
-
var objectCreate = Object.create || function create(O, Properties) {
|
|
1686
|
-
var result;
|
|
1687
|
-
if (O !== null) {
|
|
1688
|
-
EmptyConstructor[PROTOTYPE] = anObject$5(O);
|
|
1689
|
-
result = new EmptyConstructor();
|
|
1690
|
-
EmptyConstructor[PROTOTYPE] = null;
|
|
1691
|
-
// add "__proto__" for Object.getPrototypeOf polyfill
|
|
1692
|
-
result[IE_PROTO$1] = O;
|
|
1693
|
-
} else result = NullProtoObject();
|
|
1694
|
-
return Properties === undefined ? result : definePropertiesModule.f(result, Properties);
|
|
1695
|
-
};
|
|
1696
|
-
|
|
1697
|
-
var wellKnownSymbol$8 = wellKnownSymbol$a;
|
|
1698
|
-
var create$2 = objectCreate;
|
|
1699
|
-
var defineProperty$6 = objectDefineProperty.f;
|
|
1700
|
-
|
|
1701
|
-
var UNSCOPABLES = wellKnownSymbol$8('unscopables');
|
|
1702
|
-
var ArrayPrototype = Array.prototype;
|
|
1703
|
-
|
|
1704
|
-
// Array.prototype[@@unscopables]
|
|
1705
|
-
// https://tc39.es/ecma262/#sec-array.prototype-@@unscopables
|
|
1706
|
-
if (ArrayPrototype[UNSCOPABLES] === undefined) {
|
|
1707
|
-
defineProperty$6(ArrayPrototype, UNSCOPABLES, {
|
|
1708
|
-
configurable: true,
|
|
1709
|
-
value: create$2(null)
|
|
1710
|
-
});
|
|
1711
|
-
}
|
|
1712
|
-
|
|
1713
|
-
// add a key to Array.prototype[@@unscopables]
|
|
1714
|
-
var addToUnscopables$1 = function (key) {
|
|
1715
|
-
ArrayPrototype[UNSCOPABLES][key] = true;
|
|
1716
|
-
};
|
|
1717
|
-
|
|
1718
|
-
var iterators = {};
|
|
1719
|
-
|
|
1720
|
-
var global$b = global$i;
|
|
1721
|
-
var isCallable$c = isCallable$i;
|
|
1722
|
-
|
|
1723
|
-
var WeakMap$1 = global$b.WeakMap;
|
|
1724
|
-
|
|
1725
|
-
var weakMapBasicDetection = isCallable$c(WeakMap$1) && /native code/.test(String(WeakMap$1));
|
|
1726
|
-
|
|
1727
|
-
var createPropertyDescriptor$4 = function (bitmap, value) {
|
|
1728
|
-
return {
|
|
1729
|
-
enumerable: !(bitmap & 1),
|
|
1730
|
-
configurable: !(bitmap & 2),
|
|
1731
|
-
writable: !(bitmap & 4),
|
|
1732
|
-
value: value
|
|
1733
|
-
};
|
|
1734
|
-
};
|
|
1735
|
-
|
|
1736
|
-
var DESCRIPTORS$8 = descriptors;
|
|
1737
|
-
var definePropertyModule$2 = objectDefineProperty;
|
|
1738
|
-
var createPropertyDescriptor$3 = createPropertyDescriptor$4;
|
|
1739
|
-
|
|
1740
|
-
var createNonEnumerableProperty$8 = DESCRIPTORS$8 ? function (object, key, value) {
|
|
1741
|
-
return definePropertyModule$2.f(object, key, createPropertyDescriptor$3(1, value));
|
|
1742
|
-
} : function (object, key, value) {
|
|
1743
|
-
object[key] = value;
|
|
1744
|
-
return object;
|
|
1745
|
-
};
|
|
1746
|
-
|
|
1747
|
-
var NATIVE_WEAK_MAP = weakMapBasicDetection;
|
|
1748
|
-
var global$a = global$i;
|
|
1749
|
-
var isObject$5 = isObject$a;
|
|
1750
|
-
var createNonEnumerableProperty$7 = createNonEnumerableProperty$8;
|
|
1751
|
-
var hasOwn$8 = hasOwnProperty_1;
|
|
1752
|
-
var shared$1 = sharedStore.exports;
|
|
1753
|
-
var sharedKey$1 = sharedKey$3;
|
|
1754
|
-
var hiddenKeys$1 = hiddenKeys$4;
|
|
1755
|
-
|
|
1756
|
-
var OBJECT_ALREADY_INITIALIZED = 'Object already initialized';
|
|
1757
|
-
var TypeError$1 = global$a.TypeError;
|
|
1758
|
-
var WeakMap = global$a.WeakMap;
|
|
1759
|
-
var set, get, has;
|
|
1760
|
-
|
|
1761
|
-
var enforce = function (it) {
|
|
1762
|
-
return has(it) ? get(it) : set(it, {});
|
|
1763
|
-
};
|
|
1242
|
+
var enforce = function (it) {
|
|
1243
|
+
return has(it) ? get(it) : set(it, {});
|
|
1244
|
+
};
|
|
1764
1245
|
|
|
1765
1246
|
var getterFor = function (TYPE) {
|
|
1766
1247
|
return function (it) {
|
|
@@ -1772,38 +1253,38 @@ var getterFor = function (TYPE) {
|
|
|
1772
1253
|
};
|
|
1773
1254
|
|
|
1774
1255
|
if (NATIVE_WEAK_MAP || shared$1.state) {
|
|
1775
|
-
var store
|
|
1256
|
+
var store = shared$1.state || (shared$1.state = new WeakMap());
|
|
1776
1257
|
/* eslint-disable no-self-assign -- prototype methods protection */
|
|
1777
|
-
store
|
|
1778
|
-
store
|
|
1779
|
-
store
|
|
1258
|
+
store.get = store.get;
|
|
1259
|
+
store.has = store.has;
|
|
1260
|
+
store.set = store.set;
|
|
1780
1261
|
/* eslint-enable no-self-assign -- prototype methods protection */
|
|
1781
1262
|
set = function (it, metadata) {
|
|
1782
|
-
if (store
|
|
1263
|
+
if (store.has(it)) throw new TypeError$1(OBJECT_ALREADY_INITIALIZED);
|
|
1783
1264
|
metadata.facade = it;
|
|
1784
|
-
store
|
|
1265
|
+
store.set(it, metadata);
|
|
1785
1266
|
return metadata;
|
|
1786
1267
|
};
|
|
1787
1268
|
get = function (it) {
|
|
1788
|
-
return store
|
|
1269
|
+
return store.get(it) || {};
|
|
1789
1270
|
};
|
|
1790
1271
|
has = function (it) {
|
|
1791
|
-
return store
|
|
1272
|
+
return store.has(it);
|
|
1792
1273
|
};
|
|
1793
1274
|
} else {
|
|
1794
|
-
var STATE = sharedKey$
|
|
1795
|
-
hiddenKeys$
|
|
1275
|
+
var STATE = sharedKey$2('state');
|
|
1276
|
+
hiddenKeys$3[STATE] = true;
|
|
1796
1277
|
set = function (it, metadata) {
|
|
1797
|
-
if (hasOwn$
|
|
1278
|
+
if (hasOwn$7(it, STATE)) throw new TypeError$1(OBJECT_ALREADY_INITIALIZED);
|
|
1798
1279
|
metadata.facade = it;
|
|
1799
1280
|
createNonEnumerableProperty$7(it, STATE, metadata);
|
|
1800
1281
|
return metadata;
|
|
1801
1282
|
};
|
|
1802
1283
|
get = function (it) {
|
|
1803
|
-
return hasOwn$
|
|
1284
|
+
return hasOwn$7(it, STATE) ? it[STATE] : {};
|
|
1804
1285
|
};
|
|
1805
1286
|
has = function (it) {
|
|
1806
|
-
return hasOwn$
|
|
1287
|
+
return hasOwn$7(it, STATE);
|
|
1807
1288
|
};
|
|
1808
1289
|
}
|
|
1809
1290
|
|
|
@@ -1815,87 +1296,11 @@ var internalState = {
|
|
|
1815
1296
|
getterFor: getterFor
|
|
1816
1297
|
};
|
|
1817
1298
|
|
|
1818
|
-
var objectGetOwnPropertyDescriptor = {};
|
|
1819
|
-
|
|
1820
|
-
var objectPropertyIsEnumerable = {};
|
|
1821
|
-
|
|
1822
|
-
var $propertyIsEnumerable = {}.propertyIsEnumerable;
|
|
1823
|
-
// eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe
|
|
1824
|
-
var getOwnPropertyDescriptor$2 = Object.getOwnPropertyDescriptor;
|
|
1825
|
-
|
|
1826
|
-
// Nashorn ~ JDK8 bug
|
|
1827
|
-
var NASHORN_BUG = getOwnPropertyDescriptor$2 && !$propertyIsEnumerable.call({ 1: 2 }, 1);
|
|
1828
|
-
|
|
1829
|
-
// `Object.prototype.propertyIsEnumerable` method implementation
|
|
1830
|
-
// https://tc39.es/ecma262/#sec-object.prototype.propertyisenumerable
|
|
1831
|
-
objectPropertyIsEnumerable.f = NASHORN_BUG ? function propertyIsEnumerable(V) {
|
|
1832
|
-
var descriptor = getOwnPropertyDescriptor$2(this, V);
|
|
1833
|
-
return !!descriptor && descriptor.enumerable;
|
|
1834
|
-
} : $propertyIsEnumerable;
|
|
1835
|
-
|
|
1836
|
-
var DESCRIPTORS$7 = descriptors;
|
|
1837
|
-
var call$7 = functionCall;
|
|
1838
|
-
var propertyIsEnumerableModule$1 = objectPropertyIsEnumerable;
|
|
1839
|
-
var createPropertyDescriptor$2 = createPropertyDescriptor$4;
|
|
1840
|
-
var toIndexedObject$1 = toIndexedObject$5;
|
|
1841
|
-
var toPropertyKey = toPropertyKey$2;
|
|
1842
|
-
var hasOwn$7 = hasOwnProperty_1;
|
|
1843
|
-
var IE8_DOM_DEFINE = ie8DomDefine;
|
|
1844
|
-
|
|
1845
|
-
// eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe
|
|
1846
|
-
var $getOwnPropertyDescriptor = Object.getOwnPropertyDescriptor;
|
|
1847
|
-
|
|
1848
|
-
// `Object.getOwnPropertyDescriptor` method
|
|
1849
|
-
// https://tc39.es/ecma262/#sec-object.getownpropertydescriptor
|
|
1850
|
-
objectGetOwnPropertyDescriptor.f = DESCRIPTORS$7 ? $getOwnPropertyDescriptor : function getOwnPropertyDescriptor(O, P) {
|
|
1851
|
-
O = toIndexedObject$1(O);
|
|
1852
|
-
P = toPropertyKey(P);
|
|
1853
|
-
if (IE8_DOM_DEFINE) try {
|
|
1854
|
-
return $getOwnPropertyDescriptor(O, P);
|
|
1855
|
-
} catch (error) { /* empty */ }
|
|
1856
|
-
if (hasOwn$7(O, P)) return createPropertyDescriptor$2(!call$7(propertyIsEnumerableModule$1.f, O, P), O[P]);
|
|
1857
|
-
};
|
|
1858
|
-
|
|
1859
|
-
var makeBuiltIn$3 = {exports: {}};
|
|
1860
|
-
|
|
1861
|
-
var DESCRIPTORS$6 = descriptors;
|
|
1862
|
-
var hasOwn$6 = hasOwnProperty_1;
|
|
1863
|
-
|
|
1864
|
-
var FunctionPrototype$1 = Function.prototype;
|
|
1865
|
-
// eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe
|
|
1866
|
-
var getDescriptor = DESCRIPTORS$6 && Object.getOwnPropertyDescriptor;
|
|
1867
|
-
|
|
1868
|
-
var EXISTS = hasOwn$6(FunctionPrototype$1, 'name');
|
|
1869
|
-
// additional protection from minified / mangled / dropped function names
|
|
1870
|
-
var PROPER = EXISTS && (function something() { /* empty */ }).name === 'something';
|
|
1871
|
-
var CONFIGURABLE = EXISTS && (!DESCRIPTORS$6 || (DESCRIPTORS$6 && getDescriptor(FunctionPrototype$1, 'name').configurable));
|
|
1872
|
-
|
|
1873
|
-
var functionName = {
|
|
1874
|
-
EXISTS: EXISTS,
|
|
1875
|
-
PROPER: PROPER,
|
|
1876
|
-
CONFIGURABLE: CONFIGURABLE
|
|
1877
|
-
};
|
|
1878
|
-
|
|
1879
1299
|
var uncurryThis$c = functionUncurryThis;
|
|
1880
|
-
var isCallable$b = isCallable$i;
|
|
1881
|
-
var store = sharedStore.exports;
|
|
1882
|
-
|
|
1883
|
-
var functionToString = uncurryThis$c(Function.toString);
|
|
1884
|
-
|
|
1885
|
-
// this helper broken in `core-js@3.4.1-3.4.4`, so we can't use `shared` helper
|
|
1886
|
-
if (!isCallable$b(store.inspectSource)) {
|
|
1887
|
-
store.inspectSource = function (it) {
|
|
1888
|
-
return functionToString(it);
|
|
1889
|
-
};
|
|
1890
|
-
}
|
|
1891
|
-
|
|
1892
|
-
var inspectSource$2 = store.inspectSource;
|
|
1893
|
-
|
|
1894
|
-
var uncurryThis$b = functionUncurryThis;
|
|
1895
1300
|
var fails$e = fails$l;
|
|
1896
1301
|
var isCallable$a = isCallable$i;
|
|
1897
|
-
var hasOwn$
|
|
1898
|
-
var DESCRIPTORS$
|
|
1302
|
+
var hasOwn$6 = hasOwnProperty_1;
|
|
1303
|
+
var DESCRIPTORS$6 = descriptors;
|
|
1899
1304
|
var CONFIGURABLE_FUNCTION_NAME$1 = functionName.CONFIGURABLE;
|
|
1900
1305
|
var inspectSource$1 = inspectSource$2;
|
|
1901
1306
|
var InternalStateModule$1 = internalState;
|
|
@@ -1904,13 +1309,13 @@ var enforceInternalState = InternalStateModule$1.enforce;
|
|
|
1904
1309
|
var getInternalState$2 = InternalStateModule$1.get;
|
|
1905
1310
|
var $String$2 = String;
|
|
1906
1311
|
// eslint-disable-next-line es/no-object-defineproperty -- safe
|
|
1907
|
-
var defineProperty$
|
|
1908
|
-
var stringSlice$4 = uncurryThis$
|
|
1909
|
-
var replace$4 = uncurryThis$
|
|
1910
|
-
var join = uncurryThis$
|
|
1312
|
+
var defineProperty$6 = Object.defineProperty;
|
|
1313
|
+
var stringSlice$4 = uncurryThis$c(''.slice);
|
|
1314
|
+
var replace$4 = uncurryThis$c(''.replace);
|
|
1315
|
+
var join = uncurryThis$c([].join);
|
|
1911
1316
|
|
|
1912
|
-
var CONFIGURABLE_LENGTH = DESCRIPTORS$
|
|
1913
|
-
return defineProperty$
|
|
1317
|
+
var CONFIGURABLE_LENGTH = DESCRIPTORS$6 && !fails$e(function () {
|
|
1318
|
+
return defineProperty$6(function () { /* empty */ }, 'length', { value: 8 }).length !== 8;
|
|
1914
1319
|
});
|
|
1915
1320
|
|
|
1916
1321
|
var TEMPLATE = String(String).split('String');
|
|
@@ -1921,21 +1326,21 @@ var makeBuiltIn$2 = makeBuiltIn$3.exports = function (value, name, options) {
|
|
|
1921
1326
|
}
|
|
1922
1327
|
if (options && options.getter) name = 'get ' + name;
|
|
1923
1328
|
if (options && options.setter) name = 'set ' + name;
|
|
1924
|
-
if (!hasOwn$
|
|
1925
|
-
if (DESCRIPTORS$
|
|
1329
|
+
if (!hasOwn$6(value, 'name') || (CONFIGURABLE_FUNCTION_NAME$1 && value.name !== name)) {
|
|
1330
|
+
if (DESCRIPTORS$6) defineProperty$6(value, 'name', { value: name, configurable: true });
|
|
1926
1331
|
else value.name = name;
|
|
1927
1332
|
}
|
|
1928
|
-
if (CONFIGURABLE_LENGTH && options && hasOwn$
|
|
1929
|
-
defineProperty$
|
|
1333
|
+
if (CONFIGURABLE_LENGTH && options && hasOwn$6(options, 'arity') && value.length !== options.arity) {
|
|
1334
|
+
defineProperty$6(value, 'length', { value: options.arity });
|
|
1930
1335
|
}
|
|
1931
1336
|
try {
|
|
1932
|
-
if (options && hasOwn$
|
|
1933
|
-
if (DESCRIPTORS$
|
|
1337
|
+
if (options && hasOwn$6(options, 'constructor') && options.constructor) {
|
|
1338
|
+
if (DESCRIPTORS$6) defineProperty$6(value, 'prototype', { writable: false });
|
|
1934
1339
|
// in V8 ~ Chrome 53, prototypes of some methods, like `Array.prototype.values`, are non-writable
|
|
1935
1340
|
} else if (value.prototype) value.prototype = undefined;
|
|
1936
1341
|
} catch (error) { /* empty */ }
|
|
1937
1342
|
var state = enforceInternalState(value);
|
|
1938
|
-
if (!hasOwn$
|
|
1343
|
+
if (!hasOwn$6(state, 'source')) {
|
|
1939
1344
|
state.source = join(TEMPLATE, typeof name == 'string' ? name : '');
|
|
1940
1345
|
} return value;
|
|
1941
1346
|
};
|
|
@@ -1947,7 +1352,7 @@ Function.prototype.toString = makeBuiltIn$2(function toString() {
|
|
|
1947
1352
|
}, 'toString');
|
|
1948
1353
|
|
|
1949
1354
|
var isCallable$9 = isCallable$i;
|
|
1950
|
-
var definePropertyModule$
|
|
1355
|
+
var definePropertyModule$2 = objectDefineProperty;
|
|
1951
1356
|
var makeBuiltIn$1 = makeBuiltIn$3.exports;
|
|
1952
1357
|
var defineGlobalProperty$1 = defineGlobalProperty$3;
|
|
1953
1358
|
|
|
@@ -1965,7 +1370,7 @@ var defineBuiltIn$4 = function (O, key, value, options) {
|
|
|
1965
1370
|
else if (O[key]) simple = true;
|
|
1966
1371
|
} catch (error) { /* empty */ }
|
|
1967
1372
|
if (simple) O[key] = value;
|
|
1968
|
-
else definePropertyModule$
|
|
1373
|
+
else definePropertyModule$2.f(O, key, {
|
|
1969
1374
|
value: value,
|
|
1970
1375
|
enumerable: false,
|
|
1971
1376
|
configurable: !options.nonConfigurable,
|
|
@@ -1976,46 +1381,165 @@ var defineBuiltIn$4 = function (O, key, value, options) {
|
|
|
1976
1381
|
|
|
1977
1382
|
var objectGetOwnPropertyNames = {};
|
|
1978
1383
|
|
|
1979
|
-
var
|
|
1980
|
-
var
|
|
1384
|
+
var ceil = Math.ceil;
|
|
1385
|
+
var floor = Math.floor;
|
|
1386
|
+
|
|
1387
|
+
// `Math.trunc` method
|
|
1388
|
+
// https://tc39.es/ecma262/#sec-math.trunc
|
|
1389
|
+
// eslint-disable-next-line es/no-math-trunc -- safe
|
|
1390
|
+
var mathTrunc = Math.trunc || function trunc(x) {
|
|
1391
|
+
var n = +x;
|
|
1392
|
+
return (n > 0 ? floor : ceil)(n);
|
|
1393
|
+
};
|
|
1981
1394
|
|
|
1982
|
-
var
|
|
1395
|
+
var trunc = mathTrunc;
|
|
1983
1396
|
|
|
1984
|
-
// `
|
|
1985
|
-
// https://tc39.es/ecma262/#sec-
|
|
1986
|
-
|
|
1987
|
-
|
|
1988
|
-
|
|
1397
|
+
// `ToIntegerOrInfinity` abstract operation
|
|
1398
|
+
// https://tc39.es/ecma262/#sec-tointegerorinfinity
|
|
1399
|
+
var toIntegerOrInfinity$3 = function (argument) {
|
|
1400
|
+
var number = +argument;
|
|
1401
|
+
// eslint-disable-next-line no-self-compare -- NaN check
|
|
1402
|
+
return number !== number || number === 0 ? 0 : trunc(number);
|
|
1989
1403
|
};
|
|
1990
1404
|
|
|
1991
|
-
var
|
|
1405
|
+
var toIntegerOrInfinity$2 = toIntegerOrInfinity$3;
|
|
1992
1406
|
|
|
1993
|
-
|
|
1994
|
-
|
|
1407
|
+
var max = Math.max;
|
|
1408
|
+
var min$2 = Math.min;
|
|
1995
1409
|
|
|
1996
|
-
|
|
1997
|
-
|
|
1998
|
-
|
|
1999
|
-
var
|
|
2000
|
-
var
|
|
1410
|
+
// Helper for a popular repeating case of the spec:
|
|
1411
|
+
// Let integer be ? ToInteger(index).
|
|
1412
|
+
// If integer < 0, let result be max((length + integer), 0); else let result be min(integer, length).
|
|
1413
|
+
var toAbsoluteIndex$1 = function (index, length) {
|
|
1414
|
+
var integer = toIntegerOrInfinity$2(index);
|
|
1415
|
+
return integer < 0 ? max(integer + length, 0) : min$2(integer, length);
|
|
1416
|
+
};
|
|
2001
1417
|
|
|
2002
|
-
var
|
|
1418
|
+
var toIntegerOrInfinity$1 = toIntegerOrInfinity$3;
|
|
2003
1419
|
|
|
2004
|
-
|
|
2005
|
-
|
|
2006
|
-
|
|
2007
|
-
|
|
2008
|
-
|
|
1420
|
+
var min$1 = Math.min;
|
|
1421
|
+
|
|
1422
|
+
// `ToLength` abstract operation
|
|
1423
|
+
// https://tc39.es/ecma262/#sec-tolength
|
|
1424
|
+
var toLength$2 = function (argument) {
|
|
1425
|
+
var len = toIntegerOrInfinity$1(argument);
|
|
1426
|
+
return len > 0 ? min$1(len, 0x1FFFFFFFFFFFFF) : 0; // 2 ** 53 - 1 == 9007199254740991
|
|
2009
1427
|
};
|
|
2010
1428
|
|
|
2011
|
-
var
|
|
2012
|
-
var ownKeys = ownKeys$1;
|
|
2013
|
-
var getOwnPropertyDescriptorModule = objectGetOwnPropertyDescriptor;
|
|
2014
|
-
var definePropertyModule = objectDefineProperty;
|
|
1429
|
+
var toLength$1 = toLength$2;
|
|
2015
1430
|
|
|
2016
|
-
|
|
1431
|
+
// `LengthOfArrayLike` abstract operation
|
|
1432
|
+
// https://tc39.es/ecma262/#sec-lengthofarraylike
|
|
1433
|
+
var lengthOfArrayLike$3 = function (obj) {
|
|
1434
|
+
return toLength$1(obj.length);
|
|
1435
|
+
};
|
|
1436
|
+
|
|
1437
|
+
var toIndexedObject$3 = toIndexedObject$5;
|
|
1438
|
+
var toAbsoluteIndex = toAbsoluteIndex$1;
|
|
1439
|
+
var lengthOfArrayLike$2 = lengthOfArrayLike$3;
|
|
1440
|
+
|
|
1441
|
+
// `Array.prototype.{ indexOf, includes }` methods implementation
|
|
1442
|
+
var createMethod$3 = function (IS_INCLUDES) {
|
|
1443
|
+
return function ($this, el, fromIndex) {
|
|
1444
|
+
var O = toIndexedObject$3($this);
|
|
1445
|
+
var length = lengthOfArrayLike$2(O);
|
|
1446
|
+
if (length === 0) return !IS_INCLUDES && -1;
|
|
1447
|
+
var index = toAbsoluteIndex(fromIndex, length);
|
|
1448
|
+
var value;
|
|
1449
|
+
// Array#includes uses SameValueZero equality algorithm
|
|
1450
|
+
// eslint-disable-next-line no-self-compare -- NaN check
|
|
1451
|
+
if (IS_INCLUDES && el !== el) while (length > index) {
|
|
1452
|
+
value = O[index++];
|
|
1453
|
+
// eslint-disable-next-line no-self-compare -- NaN check
|
|
1454
|
+
if (value !== value) return true;
|
|
1455
|
+
// Array#indexOf ignores holes, Array#includes - not
|
|
1456
|
+
} else for (;length > index; index++) {
|
|
1457
|
+
if ((IS_INCLUDES || index in O) && O[index] === el) return IS_INCLUDES || index || 0;
|
|
1458
|
+
} return !IS_INCLUDES && -1;
|
|
1459
|
+
};
|
|
1460
|
+
};
|
|
1461
|
+
|
|
1462
|
+
var arrayIncludes = {
|
|
1463
|
+
// `Array.prototype.includes` method
|
|
1464
|
+
// https://tc39.es/ecma262/#sec-array.prototype.includes
|
|
1465
|
+
includes: createMethod$3(true),
|
|
1466
|
+
// `Array.prototype.indexOf` method
|
|
1467
|
+
// https://tc39.es/ecma262/#sec-array.prototype.indexof
|
|
1468
|
+
indexOf: createMethod$3(false)
|
|
1469
|
+
};
|
|
1470
|
+
|
|
1471
|
+
var uncurryThis$b = functionUncurryThis;
|
|
1472
|
+
var hasOwn$5 = hasOwnProperty_1;
|
|
1473
|
+
var toIndexedObject$2 = toIndexedObject$5;
|
|
1474
|
+
var indexOf$1 = arrayIncludes.indexOf;
|
|
1475
|
+
var hiddenKeys$2 = hiddenKeys$4;
|
|
1476
|
+
|
|
1477
|
+
var push$1 = uncurryThis$b([].push);
|
|
1478
|
+
|
|
1479
|
+
var objectKeysInternal = function (object, names) {
|
|
1480
|
+
var O = toIndexedObject$2(object);
|
|
1481
|
+
var i = 0;
|
|
1482
|
+
var result = [];
|
|
1483
|
+
var key;
|
|
1484
|
+
for (key in O) !hasOwn$5(hiddenKeys$2, key) && hasOwn$5(O, key) && push$1(result, key);
|
|
1485
|
+
// Don't enum bug & hidden keys
|
|
1486
|
+
while (names.length > i) if (hasOwn$5(O, key = names[i++])) {
|
|
1487
|
+
~indexOf$1(result, key) || push$1(result, key);
|
|
1488
|
+
}
|
|
1489
|
+
return result;
|
|
1490
|
+
};
|
|
1491
|
+
|
|
1492
|
+
// IE8- don't enum bug keys
|
|
1493
|
+
var enumBugKeys$3 = [
|
|
1494
|
+
'constructor',
|
|
1495
|
+
'hasOwnProperty',
|
|
1496
|
+
'isPrototypeOf',
|
|
1497
|
+
'propertyIsEnumerable',
|
|
1498
|
+
'toLocaleString',
|
|
1499
|
+
'toString',
|
|
1500
|
+
'valueOf'
|
|
1501
|
+
];
|
|
1502
|
+
|
|
1503
|
+
var internalObjectKeys$1 = objectKeysInternal;
|
|
1504
|
+
var enumBugKeys$2 = enumBugKeys$3;
|
|
1505
|
+
|
|
1506
|
+
var hiddenKeys$1 = enumBugKeys$2.concat('length', 'prototype');
|
|
1507
|
+
|
|
1508
|
+
// `Object.getOwnPropertyNames` method
|
|
1509
|
+
// https://tc39.es/ecma262/#sec-object.getownpropertynames
|
|
1510
|
+
// eslint-disable-next-line es/no-object-getownpropertynames -- safe
|
|
1511
|
+
objectGetOwnPropertyNames.f = Object.getOwnPropertyNames || function getOwnPropertyNames(O) {
|
|
1512
|
+
return internalObjectKeys$1(O, hiddenKeys$1);
|
|
1513
|
+
};
|
|
1514
|
+
|
|
1515
|
+
var objectGetOwnPropertySymbols = {};
|
|
1516
|
+
|
|
1517
|
+
// eslint-disable-next-line es/no-object-getownpropertysymbols -- safe
|
|
1518
|
+
objectGetOwnPropertySymbols.f = Object.getOwnPropertySymbols;
|
|
1519
|
+
|
|
1520
|
+
var getBuiltIn$3 = getBuiltIn$5;
|
|
1521
|
+
var uncurryThis$a = functionUncurryThis;
|
|
1522
|
+
var getOwnPropertyNamesModule = objectGetOwnPropertyNames;
|
|
1523
|
+
var getOwnPropertySymbolsModule$1 = objectGetOwnPropertySymbols;
|
|
1524
|
+
var anObject$6 = anObject$8;
|
|
1525
|
+
|
|
1526
|
+
var concat$1 = uncurryThis$a([].concat);
|
|
1527
|
+
|
|
1528
|
+
// all object keys, includes non-enumerable and symbols
|
|
1529
|
+
var ownKeys$1 = getBuiltIn$3('Reflect', 'ownKeys') || function ownKeys(it) {
|
|
1530
|
+
var keys = getOwnPropertyNamesModule.f(anObject$6(it));
|
|
1531
|
+
var getOwnPropertySymbols = getOwnPropertySymbolsModule$1.f;
|
|
1532
|
+
return getOwnPropertySymbols ? concat$1(keys, getOwnPropertySymbols(it)) : keys;
|
|
1533
|
+
};
|
|
1534
|
+
|
|
1535
|
+
var hasOwn$4 = hasOwnProperty_1;
|
|
1536
|
+
var ownKeys = ownKeys$1;
|
|
1537
|
+
var getOwnPropertyDescriptorModule = objectGetOwnPropertyDescriptor;
|
|
1538
|
+
var definePropertyModule$1 = objectDefineProperty;
|
|
1539
|
+
|
|
1540
|
+
var copyConstructorProperties$3 = function (target, source, exceptions) {
|
|
2017
1541
|
var keys = ownKeys(source);
|
|
2018
|
-
var defineProperty = definePropertyModule.f;
|
|
1542
|
+
var defineProperty = definePropertyModule$1.f;
|
|
2019
1543
|
var getOwnPropertyDescriptor = getOwnPropertyDescriptorModule.f;
|
|
2020
1544
|
for (var i = 0; i < keys.length; i++) {
|
|
2021
1545
|
var key = keys[i];
|
|
@@ -2025,87 +1549,628 @@ var copyConstructorProperties$3 = function (target, source, exceptions) {
|
|
|
2025
1549
|
}
|
|
2026
1550
|
};
|
|
2027
1551
|
|
|
2028
|
-
var fails$d = fails$l;
|
|
2029
|
-
var isCallable$8 = isCallable$i;
|
|
1552
|
+
var fails$d = fails$l;
|
|
1553
|
+
var isCallable$8 = isCallable$i;
|
|
1554
|
+
|
|
1555
|
+
var replacement = /#|\.prototype\./;
|
|
1556
|
+
|
|
1557
|
+
var isForced$1 = function (feature, detection) {
|
|
1558
|
+
var value = data[normalize(feature)];
|
|
1559
|
+
return value === POLYFILL ? true
|
|
1560
|
+
: value === NATIVE ? false
|
|
1561
|
+
: isCallable$8(detection) ? fails$d(detection)
|
|
1562
|
+
: !!detection;
|
|
1563
|
+
};
|
|
1564
|
+
|
|
1565
|
+
var normalize = isForced$1.normalize = function (string) {
|
|
1566
|
+
return String(string).replace(replacement, '.').toLowerCase();
|
|
1567
|
+
};
|
|
1568
|
+
|
|
1569
|
+
var data = isForced$1.data = {};
|
|
1570
|
+
var NATIVE = isForced$1.NATIVE = 'N';
|
|
1571
|
+
var POLYFILL = isForced$1.POLYFILL = 'P';
|
|
1572
|
+
|
|
1573
|
+
var isForced_1 = isForced$1;
|
|
1574
|
+
|
|
1575
|
+
var global$9 = global$i;
|
|
1576
|
+
var getOwnPropertyDescriptor$1 = objectGetOwnPropertyDescriptor.f;
|
|
1577
|
+
var createNonEnumerableProperty$6 = createNonEnumerableProperty$8;
|
|
1578
|
+
var defineBuiltIn$3 = defineBuiltIn$4;
|
|
1579
|
+
var defineGlobalProperty = defineGlobalProperty$3;
|
|
1580
|
+
var copyConstructorProperties$2 = copyConstructorProperties$3;
|
|
1581
|
+
var isForced = isForced_1;
|
|
1582
|
+
|
|
1583
|
+
/*
|
|
1584
|
+
options.target - name of the target object
|
|
1585
|
+
options.global - target is the global object
|
|
1586
|
+
options.stat - export as static methods of target
|
|
1587
|
+
options.proto - export as prototype methods of target
|
|
1588
|
+
options.real - real prototype method for the `pure` version
|
|
1589
|
+
options.forced - export even if the native feature is available
|
|
1590
|
+
options.bind - bind methods to the target, required for the `pure` version
|
|
1591
|
+
options.wrap - wrap constructors to preventing global pollution, required for the `pure` version
|
|
1592
|
+
options.unsafe - use the simple assignment of property instead of delete + defineProperty
|
|
1593
|
+
options.sham - add a flag to not completely full polyfills
|
|
1594
|
+
options.enumerable - export as enumerable property
|
|
1595
|
+
options.dontCallGetSet - prevent calling a getter on target
|
|
1596
|
+
options.name - the .name of the function if it does not match the key
|
|
1597
|
+
*/
|
|
1598
|
+
var _export = function (options, source) {
|
|
1599
|
+
var TARGET = options.target;
|
|
1600
|
+
var GLOBAL = options.global;
|
|
1601
|
+
var STATIC = options.stat;
|
|
1602
|
+
var FORCED, target, key, targetProperty, sourceProperty, descriptor;
|
|
1603
|
+
if (GLOBAL) {
|
|
1604
|
+
target = global$9;
|
|
1605
|
+
} else if (STATIC) {
|
|
1606
|
+
target = global$9[TARGET] || defineGlobalProperty(TARGET, {});
|
|
1607
|
+
} else {
|
|
1608
|
+
target = global$9[TARGET] && global$9[TARGET].prototype;
|
|
1609
|
+
}
|
|
1610
|
+
if (target) for (key in source) {
|
|
1611
|
+
sourceProperty = source[key];
|
|
1612
|
+
if (options.dontCallGetSet) {
|
|
1613
|
+
descriptor = getOwnPropertyDescriptor$1(target, key);
|
|
1614
|
+
targetProperty = descriptor && descriptor.value;
|
|
1615
|
+
} else targetProperty = target[key];
|
|
1616
|
+
FORCED = isForced(GLOBAL ? key : TARGET + (STATIC ? '.' : '#') + key, options.forced);
|
|
1617
|
+
// contained in target
|
|
1618
|
+
if (!FORCED && targetProperty !== undefined) {
|
|
1619
|
+
if (typeof sourceProperty == typeof targetProperty) continue;
|
|
1620
|
+
copyConstructorProperties$2(sourceProperty, targetProperty);
|
|
1621
|
+
}
|
|
1622
|
+
// add a flag to not completely full polyfills
|
|
1623
|
+
if (options.sham || (targetProperty && targetProperty.sham)) {
|
|
1624
|
+
createNonEnumerableProperty$6(sourceProperty, 'sham', true);
|
|
1625
|
+
}
|
|
1626
|
+
defineBuiltIn$3(target, key, sourceProperty, options);
|
|
1627
|
+
}
|
|
1628
|
+
};
|
|
1629
|
+
|
|
1630
|
+
var internalObjectKeys = objectKeysInternal;
|
|
1631
|
+
var enumBugKeys$1 = enumBugKeys$3;
|
|
1632
|
+
|
|
1633
|
+
// `Object.keys` method
|
|
1634
|
+
// https://tc39.es/ecma262/#sec-object.keys
|
|
1635
|
+
// eslint-disable-next-line es/no-object-keys -- safe
|
|
1636
|
+
var objectKeys$2 = Object.keys || function keys(O) {
|
|
1637
|
+
return internalObjectKeys(O, enumBugKeys$1);
|
|
1638
|
+
};
|
|
1639
|
+
|
|
1640
|
+
var DESCRIPTORS$5 = descriptors;
|
|
1641
|
+
var uncurryThis$9 = functionUncurryThis;
|
|
1642
|
+
var call$6 = functionCall;
|
|
1643
|
+
var fails$c = fails$l;
|
|
1644
|
+
var objectKeys$1 = objectKeys$2;
|
|
1645
|
+
var getOwnPropertySymbolsModule = objectGetOwnPropertySymbols;
|
|
1646
|
+
var propertyIsEnumerableModule = objectPropertyIsEnumerable;
|
|
1647
|
+
var toObject$3 = toObject$5;
|
|
1648
|
+
var IndexedObject$1 = indexedObject;
|
|
1649
|
+
|
|
1650
|
+
// eslint-disable-next-line es/no-object-assign -- safe
|
|
1651
|
+
var $assign = Object.assign;
|
|
1652
|
+
// eslint-disable-next-line es/no-object-defineproperty -- required for testing
|
|
1653
|
+
var defineProperty$5 = Object.defineProperty;
|
|
1654
|
+
var concat = uncurryThis$9([].concat);
|
|
1655
|
+
|
|
1656
|
+
// `Object.assign` method
|
|
1657
|
+
// https://tc39.es/ecma262/#sec-object.assign
|
|
1658
|
+
var objectAssign = !$assign || fails$c(function () {
|
|
1659
|
+
// should have correct order of operations (Edge bug)
|
|
1660
|
+
if (DESCRIPTORS$5 && $assign({ b: 1 }, $assign(defineProperty$5({}, 'a', {
|
|
1661
|
+
enumerable: true,
|
|
1662
|
+
get: function () {
|
|
1663
|
+
defineProperty$5(this, 'b', {
|
|
1664
|
+
value: 3,
|
|
1665
|
+
enumerable: false
|
|
1666
|
+
});
|
|
1667
|
+
}
|
|
1668
|
+
}), { b: 2 })).b !== 1) return true;
|
|
1669
|
+
// should work with symbols and should have deterministic property order (V8 bug)
|
|
1670
|
+
var A = {};
|
|
1671
|
+
var B = {};
|
|
1672
|
+
// eslint-disable-next-line es/no-symbol -- safe
|
|
1673
|
+
var symbol = Symbol('assign detection');
|
|
1674
|
+
var alphabet = 'abcdefghijklmnopqrst';
|
|
1675
|
+
A[symbol] = 7;
|
|
1676
|
+
alphabet.split('').forEach(function (chr) { B[chr] = chr; });
|
|
1677
|
+
return $assign({}, A)[symbol] !== 7 || objectKeys$1($assign({}, B)).join('') !== alphabet;
|
|
1678
|
+
}) ? function assign(target, source) { // eslint-disable-line no-unused-vars -- required for `.length`
|
|
1679
|
+
var T = toObject$3(target);
|
|
1680
|
+
var argumentsLength = arguments.length;
|
|
1681
|
+
var index = 1;
|
|
1682
|
+
var getOwnPropertySymbols = getOwnPropertySymbolsModule.f;
|
|
1683
|
+
var propertyIsEnumerable = propertyIsEnumerableModule.f;
|
|
1684
|
+
while (argumentsLength > index) {
|
|
1685
|
+
var S = IndexedObject$1(arguments[index++]);
|
|
1686
|
+
var keys = getOwnPropertySymbols ? concat(objectKeys$1(S), getOwnPropertySymbols(S)) : objectKeys$1(S);
|
|
1687
|
+
var length = keys.length;
|
|
1688
|
+
var j = 0;
|
|
1689
|
+
var key;
|
|
1690
|
+
while (length > j) {
|
|
1691
|
+
key = keys[j++];
|
|
1692
|
+
if (!DESCRIPTORS$5 || call$6(propertyIsEnumerable, S, key)) T[key] = S[key];
|
|
1693
|
+
}
|
|
1694
|
+
} return T;
|
|
1695
|
+
} : $assign;
|
|
1696
|
+
|
|
1697
|
+
var $$7 = _export;
|
|
1698
|
+
var assign = objectAssign;
|
|
1699
|
+
|
|
1700
|
+
// `Object.assign` method
|
|
1701
|
+
// https://tc39.es/ecma262/#sec-object.assign
|
|
1702
|
+
// eslint-disable-next-line es/no-object-assign -- required for testing
|
|
1703
|
+
$$7({ target: 'Object', stat: true, arity: 2, forced: Object.assign !== assign }, {
|
|
1704
|
+
assign: assign
|
|
1705
|
+
});
|
|
1706
|
+
|
|
1707
|
+
const WARN_NAMESPACE = 'warn';
|
|
1708
|
+
const translateKeyOutsideComponents = (key, params = undefined) => i18n.t(key, Object.assign({
|
|
1709
|
+
ns: [WARN_NAMESPACE]
|
|
1710
|
+
}, params));
|
|
1711
|
+
const useWarningsTranslation = () => useTranslation(WARN_NAMESPACE);
|
|
1712
|
+
|
|
1713
|
+
/* *
|
|
1714
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
1715
|
+
* you may not use this file except in compliance with the License.
|
|
1716
|
+
* You may obtain a copy of the License at
|
|
1717
|
+
*
|
|
1718
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
1719
|
+
*
|
|
1720
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
1721
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
1722
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
1723
|
+
* See the License for the specific language governing permissions and
|
|
1724
|
+
* limitations under the License.
|
|
1725
|
+
*
|
|
1726
|
+
* Copyright 2023 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
1727
|
+
* Copyright 2023 - Finnish Meteorological Institute (FMI)
|
|
1728
|
+
* */
|
|
1729
|
+
const confirmationDialogOptions = t => {
|
|
1730
|
+
return {
|
|
1731
|
+
cancelLabel: t('close-dialog-cancel'),
|
|
1732
|
+
title: t('close-draw-dialog-title'),
|
|
1733
|
+
description: t('close-dialog-description'),
|
|
1734
|
+
confirmLabel: t('close-dialog-confirm'),
|
|
1735
|
+
catchOnCancel: true
|
|
1736
|
+
};
|
|
1737
|
+
};
|
|
1738
|
+
const useCloseDrawDialog = ({
|
|
1739
|
+
mapId,
|
|
1740
|
+
source
|
|
1741
|
+
}) => {
|
|
1742
|
+
const {
|
|
1743
|
+
t
|
|
1744
|
+
} = useWarningsTranslation();
|
|
1745
|
+
const dispatch = useDispatch();
|
|
1746
|
+
const drawLayerId = getSingularDrawtoolDrawLayerId(mapId);
|
|
1747
|
+
const drawDialogActiveDrawModeId = useSelector(store => drawtoolSelectors.getActiveDrawModeId(store, drawingDialogType));
|
|
1748
|
+
const featureLayerContainsGeoJSON = useSelector(store => layerSelectors.getHasFeatureLayerGeoJSON(store, drawLayerId));
|
|
1749
|
+
const dialogError = useSelector(store => uiSelectors.getDialogError(store, drawingDialogType));
|
|
1750
|
+
const isFormDirty = useSelector(store => getWarningFormDirty(store, drawingDialogType));
|
|
1751
|
+
const confirmDialog = useConfirmationDialog();
|
|
1752
|
+
const closeDrawDialog = (skipConfirmationDialog = false) => __awaiter(void 0, void 0, void 0, function* () {
|
|
1753
|
+
if (isFormDirty && !skipConfirmationDialog) {
|
|
1754
|
+
const mayProceed = yield confirmDialog(confirmationDialogOptions(t)).then(() => true).catch(() => false);
|
|
1755
|
+
if (!mayProceed) {
|
|
1756
|
+
return;
|
|
1757
|
+
}
|
|
1758
|
+
}
|
|
1759
|
+
if (drawDialogActiveDrawModeId) {
|
|
1760
|
+
// disable the edit layer
|
|
1761
|
+
dispatch(layerActions.toggleFeatureMode({
|
|
1762
|
+
layerId: drawLayerId,
|
|
1763
|
+
isInEditMode: false,
|
|
1764
|
+
drawMode: ''
|
|
1765
|
+
}));
|
|
1766
|
+
// reset active draw tool
|
|
1767
|
+
dispatch(drawtoolActions.changeDrawToolMode({
|
|
1768
|
+
drawToolId: drawingDialogType,
|
|
1769
|
+
drawModeId: drawDialogActiveDrawModeId
|
|
1770
|
+
}));
|
|
1771
|
+
}
|
|
1772
|
+
// close draw dialog
|
|
1773
|
+
dispatch(uiActions.setActiveMapIdForDialog({
|
|
1774
|
+
type: drawingDialogType,
|
|
1775
|
+
mapId,
|
|
1776
|
+
setOpen: false,
|
|
1777
|
+
source
|
|
1778
|
+
}));
|
|
1779
|
+
// reset all drawings fields
|
|
1780
|
+
dispatch(drawActions.setDrawValues({
|
|
1781
|
+
drawingInstanceId: drawingDialogType,
|
|
1782
|
+
objectName: '',
|
|
1783
|
+
id: ''
|
|
1784
|
+
}));
|
|
1785
|
+
// reset error
|
|
1786
|
+
if (dialogError) {
|
|
1787
|
+
dispatch(uiActions.setErrorDialog({
|
|
1788
|
+
type: drawingDialogType,
|
|
1789
|
+
error: ''
|
|
1790
|
+
}));
|
|
1791
|
+
}
|
|
1792
|
+
// clear existing geoJSON
|
|
1793
|
+
if (featureLayerContainsGeoJSON) {
|
|
1794
|
+
dispatch(mapStoreActions.layerChangeGeojson({
|
|
1795
|
+
layerId: drawLayerId,
|
|
1796
|
+
geojson: emptyGeoJSON
|
|
1797
|
+
}));
|
|
1798
|
+
}
|
|
1799
|
+
});
|
|
1800
|
+
return {
|
|
1801
|
+
closeDrawDialog
|
|
1802
|
+
};
|
|
1803
|
+
};
|
|
1804
|
+
const useCloseObjectDialog = ({
|
|
1805
|
+
mapId,
|
|
1806
|
+
source
|
|
1807
|
+
}) => {
|
|
1808
|
+
const dispatch = useDispatch();
|
|
1809
|
+
const drawLayerId = getSingularDrawtoolDrawLayerId(mapId);
|
|
1810
|
+
const featureLayerContainsGeoJSON = useSelector(store => layerSelectors.getHasFeatureLayerGeoJSON(store, drawLayerId));
|
|
1811
|
+
const closeObjectDialog = (shouldReset = true) => {
|
|
1812
|
+
// reset active object
|
|
1813
|
+
if (shouldReset) {
|
|
1814
|
+
dispatch(drawActions.setDrawValues({
|
|
1815
|
+
drawingInstanceId: drawingDialogType,
|
|
1816
|
+
objectName: '',
|
|
1817
|
+
id: ''
|
|
1818
|
+
}));
|
|
1819
|
+
}
|
|
1820
|
+
// close object dialog
|
|
1821
|
+
dispatch(uiActions.setActiveMapIdForDialog({
|
|
1822
|
+
type: objectDialogType,
|
|
1823
|
+
mapId,
|
|
1824
|
+
setOpen: false,
|
|
1825
|
+
source
|
|
1826
|
+
}));
|
|
1827
|
+
if (featureLayerContainsGeoJSON && shouldReset) {
|
|
1828
|
+
dispatch(mapStoreActions.layerChangeGeojson({
|
|
1829
|
+
layerId: drawLayerId,
|
|
1830
|
+
geojson: emptyGeoJSON
|
|
1831
|
+
}));
|
|
1832
|
+
}
|
|
1833
|
+
};
|
|
1834
|
+
return {
|
|
1835
|
+
closeObjectDialog
|
|
1836
|
+
};
|
|
1837
|
+
};
|
|
1838
|
+
const useDialogOptions = ({
|
|
1839
|
+
dialogType
|
|
1840
|
+
}) => {
|
|
1841
|
+
const isDialogOpen = useSelector(store => uiSelectors.getisDialogOpen(store, dialogType));
|
|
1842
|
+
const dialogMapId = useSelector(store => uiSelectors.getDialogMapId(store, dialogType));
|
|
1843
|
+
const dialogLayerId = getSingularDrawtoolDrawLayerId(dialogMapId);
|
|
1844
|
+
const hasGeoJSON = useSelector(store => layerSelectors.getHasFeatureLayerGeoJSON(store, dialogLayerId));
|
|
1845
|
+
return {
|
|
1846
|
+
isDialogOpen,
|
|
1847
|
+
dialogMapId,
|
|
1848
|
+
hasGeoJSON,
|
|
1849
|
+
dialogLayerId
|
|
1850
|
+
};
|
|
1851
|
+
};
|
|
1852
|
+
const useObjectDrawDialogAction = ({
|
|
1853
|
+
mapId,
|
|
1854
|
+
source
|
|
1855
|
+
}) => {
|
|
1856
|
+
const {
|
|
1857
|
+
t
|
|
1858
|
+
} = useWarningsTranslation();
|
|
1859
|
+
const dispatch = useDispatch();
|
|
1860
|
+
const confirmDialog = useConfirmationDialog();
|
|
1861
|
+
const currentDrawLayerId = getSingularDrawtoolDrawLayerId(mapId);
|
|
1862
|
+
// draw selectors
|
|
1863
|
+
const {
|
|
1864
|
+
isDialogOpen: isDrawDialogOpen,
|
|
1865
|
+
hasGeoJSON: drawDialogLayerHasGeoJSON,
|
|
1866
|
+
dialogLayerId: drawDialogLayerId
|
|
1867
|
+
} = useDialogOptions({
|
|
1868
|
+
dialogType: drawingDialogType
|
|
1869
|
+
});
|
|
1870
|
+
const drawDialogActiveDrawModeId = useSelector(store => drawtoolSelectors.getActiveDrawModeId(store, drawingDialogType));
|
|
1871
|
+
const isFormDirty = useSelector(store => getWarningFormDirty(store, drawingDialogType));
|
|
1872
|
+
// object selectors
|
|
1873
|
+
const {
|
|
1874
|
+
isDialogOpen: isObjectDialogOpen,
|
|
1875
|
+
hasGeoJSON: objectDialogLayerHasGeoJSON,
|
|
1876
|
+
dialogLayerId: objectDialogLayerId
|
|
1877
|
+
} = useDialogOptions({
|
|
1878
|
+
dialogType: objectDialogType
|
|
1879
|
+
});
|
|
1880
|
+
const clearGeoJSON = layerId => {
|
|
1881
|
+
dispatch(mapStoreActions.layerChangeGeojson({
|
|
1882
|
+
layerId,
|
|
1883
|
+
geojson: emptyGeoJSON
|
|
1884
|
+
}));
|
|
1885
|
+
};
|
|
1886
|
+
const openObjectDialog = () => __awaiter(void 0, void 0, void 0, function* () {
|
|
1887
|
+
if (isDrawDialogOpen) {
|
|
1888
|
+
if (isFormDirty) {
|
|
1889
|
+
const mayProceed = yield confirmDialog(confirmationDialogOptions(t)).then(() => true).catch(() => false);
|
|
1890
|
+
if (!mayProceed) {
|
|
1891
|
+
return;
|
|
1892
|
+
}
|
|
1893
|
+
}
|
|
1894
|
+
if (drawDialogLayerHasGeoJSON) {
|
|
1895
|
+
clearGeoJSON(drawDialogLayerId);
|
|
1896
|
+
}
|
|
1897
|
+
closeDrawDialog(true);
|
|
1898
|
+
}
|
|
1899
|
+
// open object dialog
|
|
1900
|
+
dispatch(uiActions.setActiveMapIdForDialog({
|
|
1901
|
+
type: objectDialogType,
|
|
1902
|
+
mapId,
|
|
1903
|
+
setOpen: true,
|
|
1904
|
+
source
|
|
1905
|
+
}));
|
|
1906
|
+
// move shape to screen
|
|
1907
|
+
if (isObjectDialogOpen && objectDialogLayerHasGeoJSON) {
|
|
1908
|
+
// update new shape
|
|
1909
|
+
dispatch(mapStoreActions.layerSetGeojsonFromLayer({
|
|
1910
|
+
layerId: currentDrawLayerId,
|
|
1911
|
+
sourceLayerId: objectDialogLayerId
|
|
1912
|
+
}));
|
|
1913
|
+
// remove current shape
|
|
1914
|
+
clearGeoJSON(objectDialogLayerId);
|
|
1915
|
+
}
|
|
1916
|
+
});
|
|
1917
|
+
const openDrawDialog = newGeoJSON => {
|
|
1918
|
+
if (isObjectDialogOpen) {
|
|
1919
|
+
if (objectDialogLayerHasGeoJSON) {
|
|
1920
|
+
clearGeoJSON(objectDialogLayerId);
|
|
1921
|
+
}
|
|
1922
|
+
const shouldResetShape = newGeoJSON === undefined;
|
|
1923
|
+
closeObjectDialog(shouldResetShape);
|
|
1924
|
+
}
|
|
1925
|
+
// open draw dialog
|
|
1926
|
+
dispatch(uiActions.setActiveMapIdForDialog({
|
|
1927
|
+
type: drawingDialogType,
|
|
1928
|
+
mapId,
|
|
1929
|
+
setOpen: true,
|
|
1930
|
+
source
|
|
1931
|
+
}));
|
|
1932
|
+
// activate draw tool
|
|
1933
|
+
dispatch(drawtoolActions.updateGeoJSONLayerId({
|
|
1934
|
+
drawToolId: drawingDialogType,
|
|
1935
|
+
geoJSONLayerId: currentDrawLayerId
|
|
1936
|
+
}));
|
|
1937
|
+
// activate default draw mode
|
|
1938
|
+
if (!drawDialogActiveDrawModeId && !isDrawDialogOpen) {
|
|
1939
|
+
dispatch(drawtoolActions.changeDrawToolMode({
|
|
1940
|
+
drawToolId: drawingDialogType,
|
|
1941
|
+
drawModeId: defaultPolygon.drawModeId
|
|
1942
|
+
}));
|
|
1943
|
+
}
|
|
1944
|
+
// move shape to screen
|
|
1945
|
+
if (isDrawDialogOpen && drawDialogLayerHasGeoJSON) {
|
|
1946
|
+
// update new shape
|
|
1947
|
+
dispatch(mapStoreActions.layerSetGeojsonFromLayer({
|
|
1948
|
+
layerId: currentDrawLayerId,
|
|
1949
|
+
sourceLayerId: drawDialogLayerId
|
|
1950
|
+
}));
|
|
1951
|
+
// remove current shape
|
|
1952
|
+
clearGeoJSON(drawDialogLayerId);
|
|
1953
|
+
}
|
|
1954
|
+
if (drawDialogActiveDrawModeId) {
|
|
1955
|
+
// activate current
|
|
1956
|
+
dispatch(layerActions.toggleFeatureMode({
|
|
1957
|
+
layerId: currentDrawLayerId,
|
|
1958
|
+
isInEditMode: true,
|
|
1959
|
+
drawMode: drawDialogActiveDrawModeId
|
|
1960
|
+
}));
|
|
1961
|
+
// deactivate previous
|
|
1962
|
+
dispatch(layerActions.toggleFeatureMode({
|
|
1963
|
+
layerId: drawDialogLayerId,
|
|
1964
|
+
isInEditMode: false,
|
|
1965
|
+
drawMode: ''
|
|
1966
|
+
}));
|
|
1967
|
+
}
|
|
1968
|
+
if (newGeoJSON) {
|
|
1969
|
+
dispatch(mapStoreActions.layerChangeGeojson({
|
|
1970
|
+
layerId: currentDrawLayerId,
|
|
1971
|
+
geojson: newGeoJSON
|
|
1972
|
+
}));
|
|
1973
|
+
}
|
|
1974
|
+
};
|
|
1975
|
+
const {
|
|
1976
|
+
closeDrawDialog
|
|
1977
|
+
} = useCloseDrawDialog({
|
|
1978
|
+
mapId,
|
|
1979
|
+
source
|
|
1980
|
+
});
|
|
1981
|
+
const {
|
|
1982
|
+
closeObjectDialog
|
|
1983
|
+
} = useCloseObjectDialog({
|
|
1984
|
+
mapId,
|
|
1985
|
+
source
|
|
1986
|
+
});
|
|
1987
|
+
return {
|
|
1988
|
+
closeDrawDialog,
|
|
1989
|
+
closeObjectDialog,
|
|
1990
|
+
openObjectDialog,
|
|
1991
|
+
openDrawDialog
|
|
1992
|
+
};
|
|
1993
|
+
};
|
|
1994
|
+
|
|
1995
|
+
/* *
|
|
1996
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
1997
|
+
* you may not use this file except in compliance with the License.
|
|
1998
|
+
* You may obtain a copy of the License at
|
|
1999
|
+
*
|
|
2000
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
2001
|
+
*
|
|
2002
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
2003
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
2004
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
2005
|
+
* See the License for the specific language governing permissions and
|
|
2006
|
+
* limitations under the License.
|
|
2007
|
+
*
|
|
2008
|
+
* Copyright 2023 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
2009
|
+
* Copyright 2023 - Finnish Meteorological Institute (FMI)
|
|
2010
|
+
* */
|
|
2011
|
+
const ObjectManagerMapButtonConnect = ({
|
|
2012
|
+
mapId,
|
|
2013
|
+
source: _source = 'app'
|
|
2014
|
+
}) => {
|
|
2015
|
+
const objectDialogMapId = useSelector(store => uiSelectors.getDialogMapId(store, objectDialogType));
|
|
2016
|
+
const isObjectDialogOpen = useSelector(store => uiSelectors.getisDialogOpen(store, objectDialogType));
|
|
2017
|
+
const {
|
|
2018
|
+
openObjectDialog,
|
|
2019
|
+
closeObjectDialog
|
|
2020
|
+
} = useObjectDrawDialogAction({
|
|
2021
|
+
mapId,
|
|
2022
|
+
source: _source
|
|
2023
|
+
});
|
|
2024
|
+
const onClick = () => {
|
|
2025
|
+
const shouldOpen = objectDialogMapId !== mapId ? true : !isObjectDialogOpen;
|
|
2026
|
+
shouldOpen ? openObjectDialog() : closeObjectDialog();
|
|
2027
|
+
};
|
|
2028
|
+
const isOpen = objectDialogMapId === mapId && isObjectDialogOpen;
|
|
2029
|
+
return /*#__PURE__*/React__default.createElement(MapControlButton, {
|
|
2030
|
+
"aria-label": `Object Manager Button for ${mapId}`,
|
|
2031
|
+
title: "Object Manager",
|
|
2032
|
+
onClick: onClick,
|
|
2033
|
+
isActive: isOpen
|
|
2034
|
+
}, /*#__PURE__*/React__default.createElement(Polygons, null));
|
|
2035
|
+
};
|
|
2036
|
+
|
|
2037
|
+
var objectDefineProperties = {};
|
|
2038
|
+
|
|
2039
|
+
var DESCRIPTORS$4 = descriptors;
|
|
2040
|
+
var V8_PROTOTYPE_DEFINE_BUG = v8PrototypeDefineBug;
|
|
2041
|
+
var definePropertyModule = objectDefineProperty;
|
|
2042
|
+
var anObject$5 = anObject$8;
|
|
2043
|
+
var toIndexedObject$1 = toIndexedObject$5;
|
|
2044
|
+
var objectKeys = objectKeys$2;
|
|
2045
|
+
|
|
2046
|
+
// `Object.defineProperties` method
|
|
2047
|
+
// https://tc39.es/ecma262/#sec-object.defineproperties
|
|
2048
|
+
// eslint-disable-next-line es/no-object-defineproperties -- safe
|
|
2049
|
+
objectDefineProperties.f = DESCRIPTORS$4 && !V8_PROTOTYPE_DEFINE_BUG ? Object.defineProperties : function defineProperties(O, Properties) {
|
|
2050
|
+
anObject$5(O);
|
|
2051
|
+
var props = toIndexedObject$1(Properties);
|
|
2052
|
+
var keys = objectKeys(Properties);
|
|
2053
|
+
var length = keys.length;
|
|
2054
|
+
var index = 0;
|
|
2055
|
+
var key;
|
|
2056
|
+
while (length > index) definePropertyModule.f(O, key = keys[index++], props[key]);
|
|
2057
|
+
return O;
|
|
2058
|
+
};
|
|
2059
|
+
|
|
2060
|
+
var getBuiltIn$2 = getBuiltIn$5;
|
|
2061
|
+
|
|
2062
|
+
var html$1 = getBuiltIn$2('document', 'documentElement');
|
|
2063
|
+
|
|
2064
|
+
/* global ActiveXObject -- old IE, WSH */
|
|
2065
|
+
var anObject$4 = anObject$8;
|
|
2066
|
+
var definePropertiesModule = objectDefineProperties;
|
|
2067
|
+
var enumBugKeys = enumBugKeys$3;
|
|
2068
|
+
var hiddenKeys = hiddenKeys$4;
|
|
2069
|
+
var html = html$1;
|
|
2070
|
+
var documentCreateElement$1 = documentCreateElement$2;
|
|
2071
|
+
var sharedKey$1 = sharedKey$3;
|
|
2072
|
+
|
|
2073
|
+
var GT = '>';
|
|
2074
|
+
var LT = '<';
|
|
2075
|
+
var PROTOTYPE = 'prototype';
|
|
2076
|
+
var SCRIPT = 'script';
|
|
2077
|
+
var IE_PROTO$1 = sharedKey$1('IE_PROTO');
|
|
2078
|
+
|
|
2079
|
+
var EmptyConstructor = function () { /* empty */ };
|
|
2080
|
+
|
|
2081
|
+
var scriptTag = function (content) {
|
|
2082
|
+
return LT + SCRIPT + GT + content + LT + '/' + SCRIPT + GT;
|
|
2083
|
+
};
|
|
2084
|
+
|
|
2085
|
+
// Create object with fake `null` prototype: use ActiveX Object with cleared prototype
|
|
2086
|
+
var NullProtoObjectViaActiveX = function (activeXDocument) {
|
|
2087
|
+
activeXDocument.write(scriptTag(''));
|
|
2088
|
+
activeXDocument.close();
|
|
2089
|
+
var temp = activeXDocument.parentWindow.Object;
|
|
2090
|
+
activeXDocument = null; // avoid memory leak
|
|
2091
|
+
return temp;
|
|
2092
|
+
};
|
|
2030
2093
|
|
|
2031
|
-
|
|
2094
|
+
// Create object with fake `null` prototype: use iframe Object with cleared prototype
|
|
2095
|
+
var NullProtoObjectViaIFrame = function () {
|
|
2096
|
+
// Thrash, waste and sodomy: IE GC bug
|
|
2097
|
+
var iframe = documentCreateElement$1('iframe');
|
|
2098
|
+
var JS = 'java' + SCRIPT + ':';
|
|
2099
|
+
var iframeDocument;
|
|
2100
|
+
iframe.style.display = 'none';
|
|
2101
|
+
html.appendChild(iframe);
|
|
2102
|
+
// https://github.com/zloirock/core-js/issues/475
|
|
2103
|
+
iframe.src = String(JS);
|
|
2104
|
+
iframeDocument = iframe.contentWindow.document;
|
|
2105
|
+
iframeDocument.open();
|
|
2106
|
+
iframeDocument.write(scriptTag('document.F=Object'));
|
|
2107
|
+
iframeDocument.close();
|
|
2108
|
+
return iframeDocument.F;
|
|
2109
|
+
};
|
|
2032
2110
|
|
|
2033
|
-
|
|
2034
|
-
|
|
2035
|
-
|
|
2036
|
-
|
|
2037
|
-
|
|
2038
|
-
|
|
2111
|
+
// Check for document.domain and active x support
|
|
2112
|
+
// No need to use active x approach when document.domain is not set
|
|
2113
|
+
// see https://github.com/es-shims/es5-shim/issues/150
|
|
2114
|
+
// variation of https://github.com/kitcambridge/es5-shim/commit/4f738ac066346
|
|
2115
|
+
// avoid IE GC bug
|
|
2116
|
+
var activeXDocument;
|
|
2117
|
+
var NullProtoObject = function () {
|
|
2118
|
+
try {
|
|
2119
|
+
activeXDocument = new ActiveXObject('htmlfile');
|
|
2120
|
+
} catch (error) { /* ignore */ }
|
|
2121
|
+
NullProtoObject = typeof document != 'undefined'
|
|
2122
|
+
? document.domain && activeXDocument
|
|
2123
|
+
? NullProtoObjectViaActiveX(activeXDocument) // old IE
|
|
2124
|
+
: NullProtoObjectViaIFrame()
|
|
2125
|
+
: NullProtoObjectViaActiveX(activeXDocument); // WSH
|
|
2126
|
+
var length = enumBugKeys.length;
|
|
2127
|
+
while (length--) delete NullProtoObject[PROTOTYPE][enumBugKeys[length]];
|
|
2128
|
+
return NullProtoObject();
|
|
2039
2129
|
};
|
|
2040
2130
|
|
|
2041
|
-
|
|
2042
|
-
|
|
2131
|
+
hiddenKeys[IE_PROTO$1] = true;
|
|
2132
|
+
|
|
2133
|
+
// `Object.create` method
|
|
2134
|
+
// https://tc39.es/ecma262/#sec-object.create
|
|
2135
|
+
// eslint-disable-next-line es/no-object-create -- safe
|
|
2136
|
+
var objectCreate = Object.create || function create(O, Properties) {
|
|
2137
|
+
var result;
|
|
2138
|
+
if (O !== null) {
|
|
2139
|
+
EmptyConstructor[PROTOTYPE] = anObject$4(O);
|
|
2140
|
+
result = new EmptyConstructor();
|
|
2141
|
+
EmptyConstructor[PROTOTYPE] = null;
|
|
2142
|
+
// add "__proto__" for Object.getPrototypeOf polyfill
|
|
2143
|
+
result[IE_PROTO$1] = O;
|
|
2144
|
+
} else result = NullProtoObject();
|
|
2145
|
+
return Properties === undefined ? result : definePropertiesModule.f(result, Properties);
|
|
2043
2146
|
};
|
|
2044
2147
|
|
|
2045
|
-
var
|
|
2046
|
-
var
|
|
2047
|
-
var
|
|
2148
|
+
var wellKnownSymbol$8 = wellKnownSymbol$a;
|
|
2149
|
+
var create$2 = objectCreate;
|
|
2150
|
+
var defineProperty$4 = objectDefineProperty.f;
|
|
2048
2151
|
|
|
2049
|
-
var
|
|
2152
|
+
var UNSCOPABLES = wellKnownSymbol$8('unscopables');
|
|
2153
|
+
var ArrayPrototype = Array.prototype;
|
|
2050
2154
|
|
|
2051
|
-
|
|
2052
|
-
|
|
2053
|
-
|
|
2054
|
-
|
|
2055
|
-
|
|
2056
|
-
|
|
2057
|
-
|
|
2155
|
+
// Array.prototype[@@unscopables]
|
|
2156
|
+
// https://tc39.es/ecma262/#sec-array.prototype-@@unscopables
|
|
2157
|
+
if (ArrayPrototype[UNSCOPABLES] === undefined) {
|
|
2158
|
+
defineProperty$4(ArrayPrototype, UNSCOPABLES, {
|
|
2159
|
+
configurable: true,
|
|
2160
|
+
value: create$2(null)
|
|
2161
|
+
});
|
|
2162
|
+
}
|
|
2058
2163
|
|
|
2059
|
-
|
|
2060
|
-
|
|
2061
|
-
|
|
2062
|
-
options.stat - export as static methods of target
|
|
2063
|
-
options.proto - export as prototype methods of target
|
|
2064
|
-
options.real - real prototype method for the `pure` version
|
|
2065
|
-
options.forced - export even if the native feature is available
|
|
2066
|
-
options.bind - bind methods to the target, required for the `pure` version
|
|
2067
|
-
options.wrap - wrap constructors to preventing global pollution, required for the `pure` version
|
|
2068
|
-
options.unsafe - use the simple assignment of property instead of delete + defineProperty
|
|
2069
|
-
options.sham - add a flag to not completely full polyfills
|
|
2070
|
-
options.enumerable - export as enumerable property
|
|
2071
|
-
options.dontCallGetSet - prevent calling a getter on target
|
|
2072
|
-
options.name - the .name of the function if it does not match the key
|
|
2073
|
-
*/
|
|
2074
|
-
var _export = function (options, source) {
|
|
2075
|
-
var TARGET = options.target;
|
|
2076
|
-
var GLOBAL = options.global;
|
|
2077
|
-
var STATIC = options.stat;
|
|
2078
|
-
var FORCED, target, key, targetProperty, sourceProperty, descriptor;
|
|
2079
|
-
if (GLOBAL) {
|
|
2080
|
-
target = global$9;
|
|
2081
|
-
} else if (STATIC) {
|
|
2082
|
-
target = global$9[TARGET] || defineGlobalProperty(TARGET, {});
|
|
2083
|
-
} else {
|
|
2084
|
-
target = global$9[TARGET] && global$9[TARGET].prototype;
|
|
2085
|
-
}
|
|
2086
|
-
if (target) for (key in source) {
|
|
2087
|
-
sourceProperty = source[key];
|
|
2088
|
-
if (options.dontCallGetSet) {
|
|
2089
|
-
descriptor = getOwnPropertyDescriptor$1(target, key);
|
|
2090
|
-
targetProperty = descriptor && descriptor.value;
|
|
2091
|
-
} else targetProperty = target[key];
|
|
2092
|
-
FORCED = isForced(GLOBAL ? key : TARGET + (STATIC ? '.' : '#') + key, options.forced);
|
|
2093
|
-
// contained in target
|
|
2094
|
-
if (!FORCED && targetProperty !== undefined) {
|
|
2095
|
-
if (typeof sourceProperty == typeof targetProperty) continue;
|
|
2096
|
-
copyConstructorProperties$2(sourceProperty, targetProperty);
|
|
2097
|
-
}
|
|
2098
|
-
// add a flag to not completely full polyfills
|
|
2099
|
-
if (options.sham || (targetProperty && targetProperty.sham)) {
|
|
2100
|
-
createNonEnumerableProperty$6(sourceProperty, 'sham', true);
|
|
2101
|
-
}
|
|
2102
|
-
defineBuiltIn$3(target, key, sourceProperty, options);
|
|
2103
|
-
}
|
|
2164
|
+
// add a key to Array.prototype[@@unscopables]
|
|
2165
|
+
var addToUnscopables$1 = function (key) {
|
|
2166
|
+
ArrayPrototype[UNSCOPABLES][key] = true;
|
|
2104
2167
|
};
|
|
2105
2168
|
|
|
2106
|
-
var
|
|
2169
|
+
var iterators = {};
|
|
2170
|
+
|
|
2171
|
+
var fails$b = fails$l;
|
|
2107
2172
|
|
|
2108
|
-
var correctPrototypeGetter = !fails$
|
|
2173
|
+
var correctPrototypeGetter = !fails$b(function () {
|
|
2109
2174
|
function F() { /* empty */ }
|
|
2110
2175
|
F.prototype.constructor = null;
|
|
2111
2176
|
// eslint-disable-next-line es/no-object-getprototypeof -- required for testing
|
|
@@ -2114,7 +2179,7 @@ var correctPrototypeGetter = !fails$c(function () {
|
|
|
2114
2179
|
|
|
2115
2180
|
var hasOwn$3 = hasOwnProperty_1;
|
|
2116
2181
|
var isCallable$7 = isCallable$i;
|
|
2117
|
-
var toObject$
|
|
2182
|
+
var toObject$2 = toObject$5;
|
|
2118
2183
|
var sharedKey = sharedKey$3;
|
|
2119
2184
|
var CORRECT_PROTOTYPE_GETTER = correctPrototypeGetter;
|
|
2120
2185
|
|
|
@@ -2126,7 +2191,7 @@ var ObjectPrototype = $Object$1.prototype;
|
|
|
2126
2191
|
// https://tc39.es/ecma262/#sec-object.getprototypeof
|
|
2127
2192
|
// eslint-disable-next-line es/no-object-getprototypeof -- safe
|
|
2128
2193
|
var objectGetPrototypeOf = CORRECT_PROTOTYPE_GETTER ? $Object$1.getPrototypeOf : function (O) {
|
|
2129
|
-
var object = toObject$
|
|
2194
|
+
var object = toObject$2(O);
|
|
2130
2195
|
if (hasOwn$3(object, IE_PROTO)) return object[IE_PROTO];
|
|
2131
2196
|
var constructor = object.constructor;
|
|
2132
2197
|
if (isCallable$7(constructor) && object instanceof constructor) {
|
|
@@ -2134,7 +2199,7 @@ var objectGetPrototypeOf = CORRECT_PROTOTYPE_GETTER ? $Object$1.getPrototypeOf :
|
|
|
2134
2199
|
} return object instanceof $Object$1 ? ObjectPrototype : null;
|
|
2135
2200
|
};
|
|
2136
2201
|
|
|
2137
|
-
var fails$
|
|
2202
|
+
var fails$a = fails$l;
|
|
2138
2203
|
var isCallable$6 = isCallable$i;
|
|
2139
2204
|
var isObject$4 = isObject$a;
|
|
2140
2205
|
var getPrototypeOf$1 = objectGetPrototypeOf;
|
|
@@ -2159,7 +2224,7 @@ if ([].keys) {
|
|
|
2159
2224
|
}
|
|
2160
2225
|
}
|
|
2161
2226
|
|
|
2162
|
-
var NEW_ITERATOR_PROTOTYPE = !isObject$4(IteratorPrototype$2) || fails$
|
|
2227
|
+
var NEW_ITERATOR_PROTOTYPE = !isObject$4(IteratorPrototype$2) || fails$a(function () {
|
|
2163
2228
|
var test = {};
|
|
2164
2229
|
// FF44- legacy iterators case
|
|
2165
2230
|
return IteratorPrototype$2[ITERATOR$3].call(test) !== test;
|
|
@@ -2180,7 +2245,7 @@ var iteratorsCore = {
|
|
|
2180
2245
|
BUGGY_SAFARI_ITERATORS: BUGGY_SAFARI_ITERATORS$1
|
|
2181
2246
|
};
|
|
2182
2247
|
|
|
2183
|
-
var defineProperty$
|
|
2248
|
+
var defineProperty$3 = objectDefineProperty.f;
|
|
2184
2249
|
var hasOwn$2 = hasOwnProperty_1;
|
|
2185
2250
|
var wellKnownSymbol$6 = wellKnownSymbol$a;
|
|
2186
2251
|
|
|
@@ -2189,7 +2254,7 @@ var TO_STRING_TAG$2 = wellKnownSymbol$6('toStringTag');
|
|
|
2189
2254
|
var setToStringTag$3 = function (target, TAG, STATIC) {
|
|
2190
2255
|
if (target && !STATIC) target = target.prototype;
|
|
2191
2256
|
if (target && !hasOwn$2(target, TO_STRING_TAG$2)) {
|
|
2192
|
-
defineProperty$
|
|
2257
|
+
defineProperty$3(target, TO_STRING_TAG$2, { configurable: true, value: TAG });
|
|
2193
2258
|
}
|
|
2194
2259
|
};
|
|
2195
2260
|
|
|
@@ -2209,13 +2274,13 @@ var iteratorCreateConstructor = function (IteratorConstructor, NAME, next, ENUME
|
|
|
2209
2274
|
return IteratorConstructor;
|
|
2210
2275
|
};
|
|
2211
2276
|
|
|
2212
|
-
var uncurryThis$
|
|
2277
|
+
var uncurryThis$8 = functionUncurryThis;
|
|
2213
2278
|
var aCallable$1 = aCallable$3;
|
|
2214
2279
|
|
|
2215
2280
|
var functionUncurryThisAccessor = function (object, key, method) {
|
|
2216
2281
|
try {
|
|
2217
2282
|
// eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe
|
|
2218
|
-
return uncurryThis$
|
|
2283
|
+
return uncurryThis$8(aCallable$1(Object.getOwnPropertyDescriptor(object, key)[method]));
|
|
2219
2284
|
} catch (error) { /* empty */ }
|
|
2220
2285
|
};
|
|
2221
2286
|
|
|
@@ -2264,8 +2329,8 @@ var objectSetPrototypeOf = Object.setPrototypeOf || ('__proto__' in {} ? functio
|
|
|
2264
2329
|
};
|
|
2265
2330
|
}() : undefined);
|
|
2266
2331
|
|
|
2267
|
-
var $$
|
|
2268
|
-
var call$
|
|
2332
|
+
var $$6 = _export;
|
|
2333
|
+
var call$5 = functionCall;
|
|
2269
2334
|
var FunctionName = functionName;
|
|
2270
2335
|
var isCallable$5 = isCallable$i;
|
|
2271
2336
|
var createIteratorConstructor = iteratorCreateConstructor;
|
|
@@ -2337,7 +2402,7 @@ var iteratorDefine = function (Iterable, NAME, IteratorConstructor, next, DEFAUL
|
|
|
2337
2402
|
createNonEnumerableProperty$5(IterablePrototype, 'name', VALUES);
|
|
2338
2403
|
} else {
|
|
2339
2404
|
INCORRECT_VALUES_NAME = true;
|
|
2340
|
-
defaultIterator = function values() { return call$
|
|
2405
|
+
defaultIterator = function values() { return call$5(nativeIterator, this); };
|
|
2341
2406
|
}
|
|
2342
2407
|
}
|
|
2343
2408
|
|
|
@@ -2352,7 +2417,7 @@ var iteratorDefine = function (Iterable, NAME, IteratorConstructor, next, DEFAUL
|
|
|
2352
2417
|
if (BUGGY_SAFARI_ITERATORS || INCORRECT_VALUES_NAME || !(KEY in IterablePrototype)) {
|
|
2353
2418
|
defineBuiltIn$1(IterablePrototype, KEY, methods[KEY]);
|
|
2354
2419
|
}
|
|
2355
|
-
} else $$
|
|
2420
|
+
} else $$6({ target: NAME, proto: true, forced: BUGGY_SAFARI_ITERATORS || INCORRECT_VALUES_NAME }, methods);
|
|
2356
2421
|
}
|
|
2357
2422
|
|
|
2358
2423
|
// define iterator
|
|
@@ -2374,10 +2439,10 @@ var toIndexedObject = toIndexedObject$5;
|
|
|
2374
2439
|
var addToUnscopables = addToUnscopables$1;
|
|
2375
2440
|
var Iterators = iterators;
|
|
2376
2441
|
var InternalStateModule = internalState;
|
|
2377
|
-
var defineProperty$
|
|
2442
|
+
var defineProperty$2 = objectDefineProperty.f;
|
|
2378
2443
|
var defineIterator = iteratorDefine;
|
|
2379
2444
|
var createIterResultObject = createIterResultObject$1;
|
|
2380
|
-
var DESCRIPTORS$
|
|
2445
|
+
var DESCRIPTORS$3 = descriptors;
|
|
2381
2446
|
|
|
2382
2447
|
var ARRAY_ITERATOR = 'Array Iterator';
|
|
2383
2448
|
var setInternalState = InternalStateModule.set;
|
|
@@ -2427,77 +2492,10 @@ addToUnscopables('values');
|
|
|
2427
2492
|
addToUnscopables('entries');
|
|
2428
2493
|
|
|
2429
2494
|
// V8 ~ Chrome 45- bug
|
|
2430
|
-
if (DESCRIPTORS$
|
|
2431
|
-
defineProperty$
|
|
2495
|
+
if (DESCRIPTORS$3 && values.name !== 'values') try {
|
|
2496
|
+
defineProperty$2(values, 'name', { value: 'values' });
|
|
2432
2497
|
} catch (error) { /* empty */ }
|
|
2433
2498
|
|
|
2434
|
-
var DESCRIPTORS$3 = descriptors;
|
|
2435
|
-
var uncurryThis$8 = functionUncurryThis;
|
|
2436
|
-
var call$5 = functionCall;
|
|
2437
|
-
var fails$a = fails$l;
|
|
2438
|
-
var objectKeys = objectKeys$2;
|
|
2439
|
-
var getOwnPropertySymbolsModule = objectGetOwnPropertySymbols;
|
|
2440
|
-
var propertyIsEnumerableModule = objectPropertyIsEnumerable;
|
|
2441
|
-
var toObject$2 = toObject$5;
|
|
2442
|
-
var IndexedObject$1 = indexedObject;
|
|
2443
|
-
|
|
2444
|
-
// eslint-disable-next-line es/no-object-assign -- safe
|
|
2445
|
-
var $assign = Object.assign;
|
|
2446
|
-
// eslint-disable-next-line es/no-object-defineproperty -- required for testing
|
|
2447
|
-
var defineProperty$2 = Object.defineProperty;
|
|
2448
|
-
var concat = uncurryThis$8([].concat);
|
|
2449
|
-
|
|
2450
|
-
// `Object.assign` method
|
|
2451
|
-
// https://tc39.es/ecma262/#sec-object.assign
|
|
2452
|
-
var objectAssign = !$assign || fails$a(function () {
|
|
2453
|
-
// should have correct order of operations (Edge bug)
|
|
2454
|
-
if (DESCRIPTORS$3 && $assign({ b: 1 }, $assign(defineProperty$2({}, 'a', {
|
|
2455
|
-
enumerable: true,
|
|
2456
|
-
get: function () {
|
|
2457
|
-
defineProperty$2(this, 'b', {
|
|
2458
|
-
value: 3,
|
|
2459
|
-
enumerable: false
|
|
2460
|
-
});
|
|
2461
|
-
}
|
|
2462
|
-
}), { b: 2 })).b !== 1) return true;
|
|
2463
|
-
// should work with symbols and should have deterministic property order (V8 bug)
|
|
2464
|
-
var A = {};
|
|
2465
|
-
var B = {};
|
|
2466
|
-
// eslint-disable-next-line es/no-symbol -- safe
|
|
2467
|
-
var symbol = Symbol('assign detection');
|
|
2468
|
-
var alphabet = 'abcdefghijklmnopqrst';
|
|
2469
|
-
A[symbol] = 7;
|
|
2470
|
-
alphabet.split('').forEach(function (chr) { B[chr] = chr; });
|
|
2471
|
-
return $assign({}, A)[symbol] !== 7 || objectKeys($assign({}, B)).join('') !== alphabet;
|
|
2472
|
-
}) ? function assign(target, source) { // eslint-disable-line no-unused-vars -- required for `.length`
|
|
2473
|
-
var T = toObject$2(target);
|
|
2474
|
-
var argumentsLength = arguments.length;
|
|
2475
|
-
var index = 1;
|
|
2476
|
-
var getOwnPropertySymbols = getOwnPropertySymbolsModule.f;
|
|
2477
|
-
var propertyIsEnumerable = propertyIsEnumerableModule.f;
|
|
2478
|
-
while (argumentsLength > index) {
|
|
2479
|
-
var S = IndexedObject$1(arguments[index++]);
|
|
2480
|
-
var keys = getOwnPropertySymbols ? concat(objectKeys(S), getOwnPropertySymbols(S)) : objectKeys(S);
|
|
2481
|
-
var length = keys.length;
|
|
2482
|
-
var j = 0;
|
|
2483
|
-
var key;
|
|
2484
|
-
while (length > j) {
|
|
2485
|
-
key = keys[j++];
|
|
2486
|
-
if (!DESCRIPTORS$3 || call$5(propertyIsEnumerable, S, key)) T[key] = S[key];
|
|
2487
|
-
}
|
|
2488
|
-
} return T;
|
|
2489
|
-
} : $assign;
|
|
2490
|
-
|
|
2491
|
-
var $$6 = _export;
|
|
2492
|
-
var assign = objectAssign;
|
|
2493
|
-
|
|
2494
|
-
// `Object.assign` method
|
|
2495
|
-
// https://tc39.es/ecma262/#sec-object.assign
|
|
2496
|
-
// eslint-disable-next-line es/no-object-assign -- required for testing
|
|
2497
|
-
$$6({ target: 'Object', stat: true, arity: 2, forced: Object.assign !== assign }, {
|
|
2498
|
-
assign: assign
|
|
2499
|
-
});
|
|
2500
|
-
|
|
2501
2499
|
// iterable DOM collections
|
|
2502
2500
|
// flag - `iterable` interface - 'entries', 'keys', 'values', 'forEach' methods
|
|
2503
2501
|
var domIterables = {
|
|
@@ -2682,7 +2680,6 @@ $$5({ target: 'Array', proto: true, arity: 1, forced: FORCED$3 }, {
|
|
|
2682
2680
|
* Copyright 2023 - Finnish Meteorological Institute (FMI)
|
|
2683
2681
|
* */
|
|
2684
2682
|
const DATE_FORMAT_HEADER = 'EEEE, MMMM dd';
|
|
2685
|
-
const DATE_FORMAT_LASTUPDATEDTIME = 'HH:mm';
|
|
2686
2683
|
|
|
2687
2684
|
const DEFAULT_ADD_BUTTON_HEIGHT = 80;
|
|
2688
2685
|
const OBJECT_ITEM_SIZE = 50;
|
|
@@ -2760,7 +2757,7 @@ const Objects = ({
|
|
|
2760
2757
|
}) => {
|
|
2761
2758
|
const {
|
|
2762
2759
|
t
|
|
2763
|
-
} =
|
|
2760
|
+
} = useWarningsTranslation();
|
|
2764
2761
|
const listRef = React__default.useRef(null);
|
|
2765
2762
|
const {
|
|
2766
2763
|
listInclHeaders,
|
|
@@ -2927,7 +2924,7 @@ const Objects = ({
|
|
|
2927
2924
|
maxHeight: '32px',
|
|
2928
2925
|
overflow: 'hidden'
|
|
2929
2926
|
}
|
|
2930
|
-
}, object.scope === 'global' && 'Global: ', `${dateUtils.dateToString(dateUtils.utc(object.lastUpdatedTime),
|
|
2927
|
+
}, object.scope === 'global' && 'Global: ', `${dateUtils.dateToString(dateUtils.utc(object.lastUpdatedTime), dateUtils.DATE_FORMAT_DATEPICKER)} UTC`))))));
|
|
2931
2928
|
})))));
|
|
2932
2929
|
};
|
|
2933
2930
|
|
|
@@ -2967,7 +2964,7 @@ const ObjectManager = ({
|
|
|
2967
2964
|
}) => {
|
|
2968
2965
|
const {
|
|
2969
2966
|
t
|
|
2970
|
-
} =
|
|
2967
|
+
} = useWarningsTranslation();
|
|
2971
2968
|
const minSize = DEFAULT_OBJECT_MANAGER_MIN_SIZE;
|
|
2972
2969
|
const startSizeCalc = calculateStartSize(minSize, _size, _startPosition);
|
|
2973
2970
|
const [sizeInState, setSizeInState] = React.useState(startSizeCalc);
|
|
@@ -3125,7 +3122,7 @@ const ConfirmDeleteDialog = ({
|
|
|
3125
3122
|
}) => {
|
|
3126
3123
|
const {
|
|
3127
3124
|
t
|
|
3128
|
-
} =
|
|
3125
|
+
} = useWarningsTranslation();
|
|
3129
3126
|
const warningsApi = getWarningsApi();
|
|
3130
3127
|
const [isLoading, setIsLoading] = React__default.useState(false);
|
|
3131
3128
|
const [error, setError] = React__default.useState(undefined);
|
|
@@ -3404,7 +3401,7 @@ const ObjectManagerConnect = ({
|
|
|
3404
3401
|
}) => {
|
|
3405
3402
|
const {
|
|
3406
3403
|
t
|
|
3407
|
-
} =
|
|
3404
|
+
} = useWarningsTranslation();
|
|
3408
3405
|
const {
|
|
3409
3406
|
dialogOrder,
|
|
3410
3407
|
setDialogOrder,
|
|
@@ -5895,7 +5892,7 @@ const DrawingToolMapButtonConnect = ({
|
|
|
5895
5892
|
}) => {
|
|
5896
5893
|
const {
|
|
5897
5894
|
t
|
|
5898
|
-
} =
|
|
5895
|
+
} = useWarningsTranslation();
|
|
5899
5896
|
// const drawingDialogType = isMultiMap
|
|
5900
5897
|
// ? `${uiTypes.DialogTypes.DrawingTool}-${mapId}`
|
|
5901
5898
|
// : uiTypes.DialogTypes.DrawingTool;
|
|
@@ -5950,7 +5947,7 @@ const DrawingTool = ({
|
|
|
5950
5947
|
}) => {
|
|
5951
5948
|
const {
|
|
5952
5949
|
t
|
|
5953
|
-
} =
|
|
5950
|
+
} = useWarningsTranslation();
|
|
5954
5951
|
const minSize = DEFAULT_DRAW_TOOL_MIN_SIZE;
|
|
5955
5952
|
const startSizeCalc = calculateStartSize(minSize, _size, _startPosition);
|
|
5956
5953
|
const [sizeInState, setSizeInState] = React.useState(startSizeCalc);
|
|
@@ -6151,7 +6148,7 @@ const DrawingToolFormContentsNoMemo = ({
|
|
|
6151
6148
|
}) => {
|
|
6152
6149
|
const {
|
|
6153
6150
|
t
|
|
6154
|
-
} =
|
|
6151
|
+
} = useWarningsTranslation();
|
|
6155
6152
|
const hasErrors = Object.keys(errors).length > 0;
|
|
6156
6153
|
return /*#__PURE__*/React__default.createElement(React__default.Fragment, null, /*#__PURE__*/React__default.createElement(Box, {
|
|
6157
6154
|
sx: {
|
|
@@ -6273,7 +6270,7 @@ const DrawingToolFormContentsNoMemo = ({
|
|
|
6273
6270
|
};
|
|
6274
6271
|
const DrawingToolFormContents = /*#__PURE__*/React__default.memo(DrawingToolFormContentsNoMemo, isEqual);
|
|
6275
6272
|
|
|
6276
|
-
const getObjectName$1 = objectName => objectName || `${dateUtils.dateToString(new Date(),
|
|
6273
|
+
const getObjectName$1 = objectName => objectName || `${dateUtils.dateToString(new Date(), dateUtils.DATE_FORMAT_DATEPICKER, true)} UTC`;
|
|
6277
6274
|
const DrawingToolForm = ({
|
|
6278
6275
|
onSubmitForm,
|
|
6279
6276
|
isLoading: _isLoading = false,
|
|
@@ -6313,7 +6310,7 @@ const DrawingToolForm = ({
|
|
|
6313
6310
|
}
|
|
6314
6311
|
});
|
|
6315
6312
|
React.useEffect(() => {
|
|
6316
|
-
if (_activeDrawModeId) {
|
|
6313
|
+
if (_activeDrawModeId || _activeDrawModeId === '') {
|
|
6317
6314
|
setValue('geoJSON', geoJSON, {
|
|
6318
6315
|
shouldDirty: true
|
|
6319
6316
|
});
|
|
@@ -6525,7 +6522,7 @@ const DrawingToolConnect = ({
|
|
|
6525
6522
|
}) => {
|
|
6526
6523
|
const {
|
|
6527
6524
|
t
|
|
6528
|
-
} =
|
|
6525
|
+
} = useWarningsTranslation();
|
|
6529
6526
|
const dialogType = getDialogType(initialMapId, _isMultiMap);
|
|
6530
6527
|
const activeMapId = useSelector(store => uiSelectors.getDialogMapId(store, dialogType));
|
|
6531
6528
|
// In case of a multimap, use the map id that is passed
|
|
@@ -6629,7 +6626,7 @@ const PublicWarningsFormDialog = ({
|
|
|
6629
6626
|
}) => {
|
|
6630
6627
|
const {
|
|
6631
6628
|
t
|
|
6632
|
-
} =
|
|
6629
|
+
} = useWarningsTranslation();
|
|
6633
6630
|
const minSize = DEFAULT_WARNING_DIALOG_MIN_SIZE;
|
|
6634
6631
|
const startSizeCalc = calculateStartSize(minSize, _size, _startPosition);
|
|
6635
6632
|
const [sizeInState, setSizeInState] = React.useState(startSizeCalc);
|
|
@@ -7366,7 +7363,7 @@ const tabStyle = {
|
|
|
7366
7363
|
const CustomTabPanel = props => {
|
|
7367
7364
|
const {
|
|
7368
7365
|
t
|
|
7369
|
-
} =
|
|
7366
|
+
} = useWarningsTranslation();
|
|
7370
7367
|
const {
|
|
7371
7368
|
children,
|
|
7372
7369
|
value,
|
|
@@ -7417,7 +7414,7 @@ const DescriptionField = ({
|
|
|
7417
7414
|
}) => {
|
|
7418
7415
|
const {
|
|
7419
7416
|
t
|
|
7420
|
-
} =
|
|
7417
|
+
} = useWarningsTranslation();
|
|
7421
7418
|
const {
|
|
7422
7419
|
isRequired
|
|
7423
7420
|
} = useDraftFormHelpers();
|
|
@@ -7497,7 +7494,7 @@ const DescriptionField = ({
|
|
|
7497
7494
|
})));
|
|
7498
7495
|
};
|
|
7499
7496
|
|
|
7500
|
-
const formatDate = lastUpdatedTime => dateUtils.dateToString(dateUtils.isoStringToDate(lastUpdatedTime), `${
|
|
7497
|
+
const formatDate = lastUpdatedTime => dateUtils.dateToString(dateUtils.isoStringToDate(lastUpdatedTime, false), `${dateUtils.DATE_FORMAT_DATEPICKER} 'UTC'`);
|
|
7501
7498
|
const getObjectName = (geoJSON, objectName, t) => {
|
|
7502
7499
|
if (geoJSON) {
|
|
7503
7500
|
return objectName || t('object-manager-object-selected');
|
|
@@ -7513,7 +7510,7 @@ const AreaField = ({
|
|
|
7513
7510
|
}) => {
|
|
7514
7511
|
const {
|
|
7515
7512
|
t
|
|
7516
|
-
} =
|
|
7513
|
+
} = useWarningsTranslation();
|
|
7517
7514
|
const {
|
|
7518
7515
|
getValues,
|
|
7519
7516
|
formState: {
|
|
@@ -7671,7 +7668,7 @@ const Phenomenon = ({
|
|
|
7671
7668
|
}) => {
|
|
7672
7669
|
const {
|
|
7673
7670
|
t
|
|
7674
|
-
} =
|
|
7671
|
+
} = useWarningsTranslation();
|
|
7675
7672
|
const {
|
|
7676
7673
|
isRequired
|
|
7677
7674
|
} = useDraftFormHelpers();
|
|
@@ -7736,7 +7733,7 @@ const LevelField = ({
|
|
|
7736
7733
|
}) => {
|
|
7737
7734
|
const {
|
|
7738
7735
|
t
|
|
7739
|
-
} =
|
|
7736
|
+
} = useWarningsTranslation();
|
|
7740
7737
|
const {
|
|
7741
7738
|
isRequired
|
|
7742
7739
|
} = useDraftFormHelpers();
|
|
@@ -7809,7 +7806,9 @@ const LevelField = ({
|
|
|
7809
7806
|
* Copyright 2023 - Finnish Meteorological Institute (FMI)
|
|
7810
7807
|
* */
|
|
7811
7808
|
const VALID_FROM_MAX_HOURS_AFTER_CURRENT = 168;
|
|
7812
|
-
const isValueBeforeCurrentTime$1 = (value, t) =>
|
|
7809
|
+
const isValueBeforeCurrentTime$1 = (value, t) => {
|
|
7810
|
+
return isXHoursBefore(value, dateUtils.getCurrentTimeAsString(), 0) || t('warning-valid-from-error-before-current');
|
|
7811
|
+
};
|
|
7813
7812
|
const isMaxHoursAfterCurrentTime$1 = (value, t) => isXHoursAfter(value, dateUtils.getCurrentTimeAsString(), VALID_FROM_MAX_HOURS_AFTER_CURRENT) || t('warning-valid-from-error-max-hours', {
|
|
7814
7813
|
ns: WARN_NAMESPACE,
|
|
7815
7814
|
MAX_HOURS: VALID_FROM_MAX_HOURS_AFTER_CURRENT
|
|
@@ -7820,7 +7819,7 @@ const ValidFrom = ({
|
|
|
7820
7819
|
}) => {
|
|
7821
7820
|
const {
|
|
7822
7821
|
t
|
|
7823
|
-
} =
|
|
7822
|
+
} = useWarningsTranslation();
|
|
7824
7823
|
const {
|
|
7825
7824
|
isRequired
|
|
7826
7825
|
} = useDraftFormHelpers();
|
|
@@ -7835,7 +7834,7 @@ const ValidFrom = ({
|
|
|
7835
7834
|
rules: {
|
|
7836
7835
|
validate: {
|
|
7837
7836
|
isRequired,
|
|
7838
|
-
isValidDate,
|
|
7837
|
+
isValidDate: dateUtils.isValidIsoDateString,
|
|
7839
7838
|
// The valid from time cannot be before the current time
|
|
7840
7839
|
isValueBeforeCurrentTime: value => isValueBeforeCurrentTime$1(value, t),
|
|
7841
7840
|
// Valid from can be no more than X hours after current time
|
|
@@ -7874,7 +7873,7 @@ const isMaxHoursAfterCurrentTime = (value, t) => isXHoursAfter(value, dateUtils.
|
|
|
7874
7873
|
MAX_HOURS: VALID_UNTIL_MAX_HOURS_AFTER_CURRENT
|
|
7875
7874
|
});
|
|
7876
7875
|
const isMinHoursAfterValidFrom = (value, validFromValue, t) => {
|
|
7877
|
-
if (isEmpty(value) || isEmpty(validFromValue) || !
|
|
7876
|
+
if (isEmpty(value) || isEmpty(validFromValue) || !dateUtils.isValidIsoDateString(validFromValue)) {
|
|
7878
7877
|
return true;
|
|
7879
7878
|
}
|
|
7880
7879
|
const duration = dateUtils.differenceInHours(new Date(value), new Date(validFromValue));
|
|
@@ -7889,7 +7888,7 @@ const ValidUntil = ({
|
|
|
7889
7888
|
}) => {
|
|
7890
7889
|
const {
|
|
7891
7890
|
t
|
|
7892
|
-
} =
|
|
7891
|
+
} = useWarningsTranslation();
|
|
7893
7892
|
const {
|
|
7894
7893
|
isRequired
|
|
7895
7894
|
} = useDraftFormHelpers();
|
|
@@ -7905,7 +7904,7 @@ const ValidUntil = ({
|
|
|
7905
7904
|
rules: {
|
|
7906
7905
|
validate: {
|
|
7907
7906
|
isRequired,
|
|
7908
|
-
isValidDate,
|
|
7907
|
+
isValidDate: dateUtils.isValidIsoDateString,
|
|
7909
7908
|
// The valid until time cannot be before the current time
|
|
7910
7909
|
isValueBeforeCurrentTime: value => isValueBeforeCurrentTime(value, t),
|
|
7911
7910
|
// Valid until time can be no more than X hours after current time
|
|
@@ -8011,7 +8010,7 @@ const ProbabilityField = ({
|
|
|
8011
8010
|
}) => {
|
|
8012
8011
|
const {
|
|
8013
8012
|
t
|
|
8014
|
-
} =
|
|
8013
|
+
} = useWarningsTranslation();
|
|
8015
8014
|
const {
|
|
8016
8015
|
trigger,
|
|
8017
8016
|
getValues
|
|
@@ -8187,7 +8186,7 @@ const Form = ({
|
|
|
8187
8186
|
}) => {
|
|
8188
8187
|
const {
|
|
8189
8188
|
t
|
|
8190
|
-
} =
|
|
8189
|
+
} = useWarningsTranslation();
|
|
8191
8190
|
const {
|
|
8192
8191
|
handleSubmit,
|
|
8193
8192
|
reset,
|
|
@@ -8565,7 +8564,7 @@ const PublicWarningsFormDialogConnect = ({
|
|
|
8565
8564
|
} = useSetupDialog(publicWarningDialogType, _source);
|
|
8566
8565
|
const {
|
|
8567
8566
|
t
|
|
8568
|
-
} =
|
|
8567
|
+
} = useWarningsTranslation();
|
|
8569
8568
|
const dispatch = useDispatch();
|
|
8570
8569
|
const confirmDialog = useConfirmationDialog();
|
|
8571
8570
|
const formAction = useSelector(store => getPublicWarningFormState(store));
|
|
@@ -8660,18 +8659,6 @@ const PublicWarningsFormDialogConnect = ({
|
|
|
8660
8659
|
}));
|
|
8661
8660
|
};
|
|
8662
8661
|
|
|
8663
|
-
const getStatus = status => {
|
|
8664
|
-
switch (status) {
|
|
8665
|
-
case 'DRAFT':
|
|
8666
|
-
return outsideComponentTranslations['warning-list-status-draft'];
|
|
8667
|
-
case 'PUBLISHED':
|
|
8668
|
-
return outsideComponentTranslations['warning-list-status-published'];
|
|
8669
|
-
case 'TODO':
|
|
8670
|
-
return outsideComponentTranslations['warning-list-status-todo'];
|
|
8671
|
-
default:
|
|
8672
|
-
return outsideComponentTranslations['warning-list-status-expired'];
|
|
8673
|
-
}
|
|
8674
|
-
};
|
|
8675
8662
|
const sortWarningsOnStatus = warnings => {
|
|
8676
8663
|
return warnings.reduce((allWarnings, warning) => {
|
|
8677
8664
|
if (warning.status === 'DRAFT') {
|
|
@@ -8713,6 +8700,30 @@ const getWarningWithoutId = warning => {
|
|
|
8713
8700
|
warningDetail: cleanWarningDetail
|
|
8714
8701
|
});
|
|
8715
8702
|
};
|
|
8703
|
+
const WarningListHeaderContent = _a => {
|
|
8704
|
+
var {
|
|
8705
|
+
title,
|
|
8706
|
+
width = 76
|
|
8707
|
+
} = _a,
|
|
8708
|
+
props = __rest(_a, ["title", "width"]);
|
|
8709
|
+
return /*#__PURE__*/React__default.createElement(Grid, Object.assign({
|
|
8710
|
+
item: true
|
|
8711
|
+
}, props, {
|
|
8712
|
+
sx: Object.assign(Object.assign({}, props.sx), {
|
|
8713
|
+
width
|
|
8714
|
+
})
|
|
8715
|
+
}), /*#__PURE__*/React__default.createElement(Box, {
|
|
8716
|
+
sx: {
|
|
8717
|
+
overflow: 'hidden',
|
|
8718
|
+
fontWeight: 'normal',
|
|
8719
|
+
textOverflow: 'ellipsis',
|
|
8720
|
+
fontSize: 12,
|
|
8721
|
+
lineHeight: 1.33,
|
|
8722
|
+
height: 16,
|
|
8723
|
+
color: 'geowebColors.captions.captionStatus.rgba'
|
|
8724
|
+
}
|
|
8725
|
+
}, title));
|
|
8726
|
+
};
|
|
8716
8727
|
const WarningListColumnContent = _a => {
|
|
8717
8728
|
var {
|
|
8718
8729
|
title,
|
|
@@ -8735,7 +8746,11 @@ const WarningListColumnContent = _a => {
|
|
|
8735
8746
|
fontSize: 10,
|
|
8736
8747
|
lineHeight: 1.6,
|
|
8737
8748
|
height: 12,
|
|
8738
|
-
color: status === 'EXPIRED' ? 'geowebColors.typographyAndIcons.inactiveText' : 'geowebColors.captions.captionStatus.rgba'
|
|
8749
|
+
color: status === 'EXPIRED' ? 'geowebColors.typographyAndIcons.inactiveText' : 'geowebColors.captions.captionStatus.rgba',
|
|
8750
|
+
display: 'block',
|
|
8751
|
+
[`@container publicWarningList (min-width: ${breakpoints.desktop}px)`]: {
|
|
8752
|
+
display: 'none'
|
|
8753
|
+
}
|
|
8739
8754
|
}
|
|
8740
8755
|
}, title)), /*#__PURE__*/React__default.createElement(Box, {
|
|
8741
8756
|
sx: {
|
|
@@ -8757,7 +8772,19 @@ const WarningsOnStatus = ({
|
|
|
8757
8772
|
}) => {
|
|
8758
8773
|
const {
|
|
8759
8774
|
t
|
|
8760
|
-
} =
|
|
8775
|
+
} = useWarningsTranslation();
|
|
8776
|
+
const getStatus = status => {
|
|
8777
|
+
switch (status) {
|
|
8778
|
+
case 'DRAFT':
|
|
8779
|
+
return t('warning-list-status-draft');
|
|
8780
|
+
case 'PUBLISHED':
|
|
8781
|
+
return t('warning-list-status-published');
|
|
8782
|
+
case 'TODO':
|
|
8783
|
+
return t('warning-list-status-todo');
|
|
8784
|
+
default:
|
|
8785
|
+
return t('warning-list-status-expired');
|
|
8786
|
+
}
|
|
8787
|
+
};
|
|
8761
8788
|
const headerText = `${warnings.length} ${getStatus(status)}`;
|
|
8762
8789
|
const onClickWarning = warning => () => _onSelectWarning(warning);
|
|
8763
8790
|
const onClickEditWarning = warning => () => _onEditWarning(warning);
|
|
@@ -8809,15 +8836,14 @@ const WarningsOnStatus = ({
|
|
|
8809
8836
|
return /*#__PURE__*/React__default.createElement(ListItem, {
|
|
8810
8837
|
key: warning.id,
|
|
8811
8838
|
sx: {
|
|
8812
|
-
marginBottom: 0.
|
|
8839
|
+
marginBottom: 0.25,
|
|
8840
|
+
minHeight: '32px',
|
|
8813
8841
|
padding: '0 0',
|
|
8814
|
-
minHeight: '48px',
|
|
8815
8842
|
backgroundColor: status === 'EXPIRED' ? 'geowebColors.cards.cardContainerDisabled' : 'geowebColors.cards.cardContainer',
|
|
8816
8843
|
borderColor: status === 'EXPIRED' ? 'geowebColors.cards.cardContainerDisabledBorder' : 'geowebColors.cards.cardContainerBorder',
|
|
8817
8844
|
borderRadius: 1,
|
|
8818
8845
|
borderWidth: activeWarningId === warning.id ? '1px' : '1px',
|
|
8819
|
-
borderStyle: 'solid'
|
|
8820
|
-
containerType: 'inline-size'
|
|
8846
|
+
borderStyle: 'solid'
|
|
8821
8847
|
},
|
|
8822
8848
|
secondaryAction: status !== 'EXPIRED' ? ( /*#__PURE__*/React__default.createElement(ToggleMenu, {
|
|
8823
8849
|
menuTitle: t('warning-list-button-options'),
|
|
@@ -8834,12 +8860,11 @@ const WarningsOnStatus = ({
|
|
|
8834
8860
|
}, /*#__PURE__*/React__default.createElement(ListItemButton, {
|
|
8835
8861
|
sx: {
|
|
8836
8862
|
height: '100%',
|
|
8837
|
-
minHeight: '48px',
|
|
8838
8863
|
padding: 1,
|
|
8839
8864
|
'.warning-list': {
|
|
8840
8865
|
justifyContent: 'left'
|
|
8841
8866
|
},
|
|
8842
|
-
[`@container (min-width: ${breakpoints.desktop}px)`]: {
|
|
8867
|
+
[`@container publicWarningList (min-width: ${breakpoints.desktop}px)`]: {
|
|
8843
8868
|
'.warning-list': {
|
|
8844
8869
|
justifyContent: 'space-between'
|
|
8845
8870
|
}
|
|
@@ -8861,18 +8886,18 @@ const WarningsOnStatus = ({
|
|
|
8861
8886
|
status: status,
|
|
8862
8887
|
width: 142
|
|
8863
8888
|
}), /*#__PURE__*/React__default.createElement(WarningListColumnContent, {
|
|
8864
|
-
title: t('warning-list-header-last-update')
|
|
8889
|
+
title: `${t('warning-list-header-last-update')} UTC`,
|
|
8865
8890
|
status: status,
|
|
8866
8891
|
width: 142
|
|
8867
|
-
}, warning.lastUpdatedTime &&
|
|
8868
|
-
title: t('warning-list-header-start-time')
|
|
8892
|
+
}, warning.lastUpdatedTime && dateUtils.dateToString(dateUtils.utc(warning.lastUpdatedTime), dateUtils.DATE_FORMAT_NAME_OF_DAY_MONTH)), /*#__PURE__*/React__default.createElement(WarningListColumnContent, {
|
|
8893
|
+
title: `${t('warning-list-header-start-time')} UTC`,
|
|
8869
8894
|
status: status,
|
|
8870
8895
|
width: 142
|
|
8871
|
-
}, warning.warningDetail.validFrom &&
|
|
8872
|
-
title: t('warning-list-header-end-time')
|
|
8896
|
+
}, warning.warningDetail.validFrom && dateUtils.dateToString(dateUtils.utc(warning.warningDetail.validFrom), dateUtils.DATE_FORMAT_NAME_OF_DAY_MONTH)), /*#__PURE__*/React__default.createElement(WarningListColumnContent, {
|
|
8897
|
+
title: `${t('warning-list-header-end-time')} UTC`,
|
|
8873
8898
|
status: status,
|
|
8874
8899
|
width: 142
|
|
8875
|
-
}, warning.warningDetail.validUntil &&
|
|
8900
|
+
}, warning.warningDetail.validUntil && dateUtils.dateToString(dateUtils.utc(warning.warningDetail.validUntil), dateUtils.DATE_FORMAT_NAME_OF_DAY_MONTH)), /*#__PURE__*/React__default.createElement(WarningListColumnContent, {
|
|
8876
8901
|
title: t('warning-list-header-domain'),
|
|
8877
8902
|
status: status
|
|
8878
8903
|
}, warning.warningDetail.domain), /*#__PURE__*/React__default.createElement(WarningListColumnContent, {
|
|
@@ -8902,6 +8927,7 @@ const WarningsOnStatus = ({
|
|
|
8902
8927
|
marginLeft: -0.5
|
|
8903
8928
|
}
|
|
8904
8929
|
}, ((_a = warning.warningDetail) === null || _a === void 0 ? void 0 : _a.level) && (levelDetails === null || levelDetails === void 0 ? void 0 : levelDetails.title) || '-')), /*#__PURE__*/React__default.createElement(WarningListColumnContent, {
|
|
8930
|
+
title: t('warning-list-header-status'),
|
|
8905
8931
|
status: status,
|
|
8906
8932
|
width: 96
|
|
8907
8933
|
}, status === 'DRAFT' ? ( /*#__PURE__*/React__default.createElement(Box, {
|
|
@@ -8920,7 +8946,7 @@ const WarningsOnStatus = ({
|
|
|
8920
8946
|
editor: warning.editor
|
|
8921
8947
|
}))), /*#__PURE__*/React__default.createElement(Button, {
|
|
8922
8948
|
sx: {
|
|
8923
|
-
height: '
|
|
8949
|
+
height: '16px',
|
|
8924
8950
|
padding: '0px',
|
|
8925
8951
|
'& .MuiSvgIcon-root': {
|
|
8926
8952
|
marginRight: '-2px'
|
|
@@ -8932,7 +8958,8 @@ const WarningsOnStatus = ({
|
|
|
8932
8958
|
content: status.toLowerCase(),
|
|
8933
8959
|
color: status === 'EXPIRED' ? 'grey' : 'green',
|
|
8934
8960
|
sx: {
|
|
8935
|
-
width: 66
|
|
8961
|
+
width: 66,
|
|
8962
|
+
height: '16px'
|
|
8936
8963
|
}
|
|
8937
8964
|
}))))));
|
|
8938
8965
|
}))));
|
|
@@ -8952,13 +8979,15 @@ const PublicWarningList = ({
|
|
|
8952
8979
|
}) => {
|
|
8953
8980
|
const {
|
|
8954
8981
|
t
|
|
8955
|
-
} =
|
|
8982
|
+
} = useWarningsTranslation();
|
|
8956
8983
|
const sortedWarnings = warnings ? sortWarningsOnStatus(warnings) : null;
|
|
8957
8984
|
return /*#__PURE__*/React__default.createElement(Box, {
|
|
8958
8985
|
sx: {
|
|
8959
8986
|
padding: 3,
|
|
8960
8987
|
height: '100%',
|
|
8961
|
-
overflowY: 'auto'
|
|
8988
|
+
overflowY: 'auto',
|
|
8989
|
+
containerName: 'publicWarningList',
|
|
8990
|
+
containerType: 'inline-size'
|
|
8962
8991
|
},
|
|
8963
8992
|
"data-testid": "publicWarningList"
|
|
8964
8993
|
}, /*#__PURE__*/React__default.createElement(Grid, {
|
|
@@ -8976,10 +9005,55 @@ const PublicWarningList = ({
|
|
|
8976
9005
|
}, t('warning-list-button_create'))), error && /*#__PURE__*/React__default.createElement(AlertBanner, {
|
|
8977
9006
|
title: error.message,
|
|
8978
9007
|
shouldClose: true
|
|
8979
|
-
}), _isLoading
|
|
9008
|
+
}), _isLoading ? ( /*#__PURE__*/React__default.createElement(LinearProgress, {
|
|
8980
9009
|
"data-testid": "loading-bar",
|
|
8981
9010
|
color: "secondary"
|
|
8982
|
-
}))
|
|
9011
|
+
})) : ( /*#__PURE__*/React__default.createElement(Box, {
|
|
9012
|
+
sx: {
|
|
9013
|
+
height: '4px'
|
|
9014
|
+
}
|
|
9015
|
+
})), !error && ( /*#__PURE__*/React__default.createElement(Grid, {
|
|
9016
|
+
container: true,
|
|
9017
|
+
rowSpacing: 0,
|
|
9018
|
+
columnSpacing: 2,
|
|
9019
|
+
alignItems: "center",
|
|
9020
|
+
justifyContent: "space-between",
|
|
9021
|
+
sx: {
|
|
9022
|
+
maxWidth: '100%',
|
|
9023
|
+
display: 'none',
|
|
9024
|
+
[`@container publicWarningList (min-width: ${breakpoints.desktop}px)`]: {
|
|
9025
|
+
display: 'flex'
|
|
9026
|
+
}
|
|
9027
|
+
}
|
|
9028
|
+
}, /*#__PURE__*/React__default.createElement(WarningListHeaderContent, {
|
|
9029
|
+
title: t('warning-list-header-incident'),
|
|
9030
|
+
width: 142,
|
|
9031
|
+
sx: {
|
|
9032
|
+
marginLeft: 1
|
|
9033
|
+
}
|
|
9034
|
+
}), /*#__PURE__*/React__default.createElement(WarningListHeaderContent, {
|
|
9035
|
+
title: `${t('warning-list-header-last-update')} UTC`,
|
|
9036
|
+
width: 142
|
|
9037
|
+
}), /*#__PURE__*/React__default.createElement(WarningListHeaderContent, {
|
|
9038
|
+
title: `${t('warning-list-header-start-time')} UTC`,
|
|
9039
|
+
width: 142
|
|
9040
|
+
}), /*#__PURE__*/React__default.createElement(WarningListHeaderContent, {
|
|
9041
|
+
title: `${t('warning-list-header-end-time')} UTC`,
|
|
9042
|
+
width: 142
|
|
9043
|
+
}), /*#__PURE__*/React__default.createElement(WarningListHeaderContent, {
|
|
9044
|
+
title: t('warning-list-header-domain')
|
|
9045
|
+
}), /*#__PURE__*/React__default.createElement(WarningListHeaderContent, {
|
|
9046
|
+
title: t('warning-list-header-phenomenon'),
|
|
9047
|
+
width: 140
|
|
9048
|
+
}), /*#__PURE__*/React__default.createElement(WarningListHeaderContent, {
|
|
9049
|
+
title: t('warning-list-header-level')
|
|
9050
|
+
}), /*#__PURE__*/React__default.createElement(WarningListHeaderContent, {
|
|
9051
|
+
title: t('warning-list-header-status'),
|
|
9052
|
+
width: 96,
|
|
9053
|
+
sx: {
|
|
9054
|
+
marginRight: '48px'
|
|
9055
|
+
}
|
|
9056
|
+
}))), lastUpdatedTime && ( /*#__PURE__*/React__default.createElement(Box, {
|
|
8983
9057
|
sx: {
|
|
8984
9058
|
marginBottom: -3.25,
|
|
8985
9059
|
button: {
|
|
@@ -9135,7 +9209,7 @@ const ConfirmDeleteWarningDialog = ({
|
|
|
9135
9209
|
}) => {
|
|
9136
9210
|
const {
|
|
9137
9211
|
t
|
|
9138
|
-
} =
|
|
9212
|
+
} = useWarningsTranslation();
|
|
9139
9213
|
const [isLoading, setIsLoading] = React__default.useState(false);
|
|
9140
9214
|
const [error, setError] = React__default.useState(undefined);
|
|
9141
9215
|
const onSubmit = () => __awaiter(void 0, void 0, void 0, function* () {
|
|
@@ -9180,7 +9254,7 @@ const ConfirmDeleteWarningDialog = ({
|
|
|
9180
9254
|
const PublicWarningListConnect = () => {
|
|
9181
9255
|
const {
|
|
9182
9256
|
t
|
|
9183
|
-
} =
|
|
9257
|
+
} = useWarningsTranslation();
|
|
9184
9258
|
const dispatch = useDispatch();
|
|
9185
9259
|
const confirmDialog = useConfirmationDialog();
|
|
9186
9260
|
const [confirmDialogOptions, setConfirmDialogOptions] = React__default.useState(undefined);
|
|
@@ -9324,7 +9398,7 @@ const componentsLookUp = (payload, apiProps) => {
|
|
|
9324
9398
|
};
|
|
9325
9399
|
|
|
9326
9400
|
const getErrorMessage = error => isAxiosError(error) ? getAxiosErrorMessage(error) : error.message;
|
|
9327
|
-
const getToggleEditorSuccessMessage = isEditor =>
|
|
9401
|
+
const getToggleEditorSuccessMessage = isEditor => translateKeyOutsideComponents(isEditor ? 'warning-editor-add-editor' : 'warning-editor-remove-editor');
|
|
9328
9402
|
const publicWarningFormListener = createListenerMiddleware();
|
|
9329
9403
|
publicWarningFormListener.startListening({
|
|
9330
9404
|
actionCreator: publicWarningFormActions.toggleEditorWarning,
|
|
@@ -9366,7 +9440,7 @@ publicWarningFormListener.startListening({
|
|
|
9366
9440
|
const publishedWarning = yield saveOrUpdateWarning(publicWarning);
|
|
9367
9441
|
listenerApi.dispatch(publicWarningFormActions.publishWarningSuccess({
|
|
9368
9442
|
publicWarning: publishedWarning,
|
|
9369
|
-
message:
|
|
9443
|
+
message: translateKeyOutsideComponents('warning-publish-succes')
|
|
9370
9444
|
}));
|
|
9371
9445
|
listenerApi.dispatch(uiActions.setToggleOpenDialog({
|
|
9372
9446
|
type: publicWarningDialogType,
|
|
@@ -9391,7 +9465,7 @@ publicWarningFormListener.startListening({
|
|
|
9391
9465
|
const savedWarning = yield saveOrUpdateWarning(publicWarning);
|
|
9392
9466
|
listenerApi.dispatch(publicWarningFormActions.saveWarningSuccess({
|
|
9393
9467
|
publicWarning: savedWarning,
|
|
9394
|
-
message:
|
|
9468
|
+
message: translateKeyOutsideComponents('warning-save-succes')
|
|
9395
9469
|
}));
|
|
9396
9470
|
} catch (error) {
|
|
9397
9471
|
const isDialogOpen = uiSelectors.getisDialogOpen(listenerApi.getState(), publicWarningDialogType);
|
|
@@ -9478,7 +9552,7 @@ const errorEffect = (dispatch, message, isDialogOpen) => {
|
|
|
9478
9552
|
* Copyright 2023 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
9479
9553
|
* Copyright 2023 - Finnish Meteorological Institute (FMI)
|
|
9480
9554
|
* */
|
|
9481
|
-
const getLastUpdatedTimeFormatted = () => dateUtils.dateToString(dateUtils.utc(),
|
|
9555
|
+
const getLastUpdatedTimeFormatted = () => dateUtils.dateToString(dateUtils.utc(), dateUtils.DATE_FORMAT_HOURS);
|
|
9482
9556
|
const publicWarningsListener = createListenerMiddleware();
|
|
9483
9557
|
publicWarningsListener.startListening({
|
|
9484
9558
|
actionCreator: publicWarningActions.fetchWarnings,
|
|
@@ -9533,7 +9607,7 @@ publicWarningsListener.startListening({
|
|
|
9533
9607
|
* Copyright 2024 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
9534
9608
|
* Copyright 2024 - Finnish Meteorological Institute (FMI)
|
|
9535
9609
|
* */
|
|
9536
|
-
const getSnackbarMessage = (objectName, id) => id ? `Object "${objectName}" ${
|
|
9610
|
+
const getSnackbarMessage = (objectName, id) => id ? `Object "${objectName}" ${translateKeyOutsideComponents('update-succes')}!` : `Object "${objectName}" ${translateKeyOutsideComponents('save-succes')}!`;
|
|
9537
9611
|
const drawingsListener = createListenerMiddleware();
|
|
9538
9612
|
drawingsListener.startListening({
|
|
9539
9613
|
actionCreator: drawActions.submitDrawValues,
|