@opengeoweb/warnings 8.4.1 → 9.0.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.
Files changed (2) hide show
  1. package/index.esm.js +11 -7
  2. package/package.json +3 -24
package/index.esm.js CHANGED
@@ -2,9 +2,9 @@ import * as React from 'react';
2
2
  import React__default, { useContext, useRef, useCallback, useDebugValue, createElement, PureComponent, useState, useEffect } from 'react';
3
3
  import 'react-dom';
4
4
  import { Polygons, Share, ExitDomain, Edit, Delete, DrawPolygon, Visibility, Add, breakpoints, CoastalEvent, Fog, TemperatureHigh, TemperatureLow, Rain, Snow, Lightning, Wind } from '@opengeoweb/theme';
5
- import { uiActions, uiTypes, getSingularDrawtoolDrawLayerId, drawtoolSelectors, layerSelectors, uiSelectors, mapStoreActions, drawtoolActions, layerActions, snackbarActions } from '@opengeoweb/store';
6
- import { emptyGeoJSON, MapControlButton, getGeoJSONPropertyValue, getIcon, currentlySupportedDrawModes } from '@opengeoweb/webmap-react';
7
- import { useSetupDialog } from '@opengeoweb/core';
5
+ import { uiActions, uiTypes, getSingularDrawtoolDrawLayerId, drawtoolSelectors, layerSelectors, uiSelectors, mapStoreActions, drawtoolActions, layerActions, useSetupDialog } from '@opengeoweb/store';
6
+ import { emptyGeoJSON, MapControlButton, getGeoJSONPropertyValue, getIcon, rewindGeometry, currentlySupportedDrawModes } from '@opengeoweb/webmap-react';
7
+ import { snackbarActions } from '@opengeoweb/snackbar';
8
8
  import { dateUtils, ToggleMenu, getHeight, calculateStartSize, ToolContainerDraggable, AlertBanner, ConfirmationDialog, getAxiosErrorMessage, CustomIconButton, SwitchButton, isAxiosError } from '@opengeoweb/shared';
9
9
  import { Box, Typography, ListItem, Paper, ListItemButton, Stack, LinearProgress, Button, Grid, FormHelperText, MenuItem, Tabs, Tab, FormControl, Card, CardContent, styled, ListItemIcon, FormControlLabel, Radio } from '@mui/material';
10
10
  import { getApi, createApiInstance, createNonAuthApiInstance, createFakeApiInstance, ApiProvider } from '@opengeoweb/api';
@@ -23385,9 +23385,13 @@ var DrawingToolForm = function DrawingToolForm(_ref) {
23385
23385
  handleSubmit(function (formValues) {
23386
23386
  // remove unneeded properties
23387
23387
  formValues.opacity;
23388
- var allFormValues = __rest(formValues, ["opacity"]);
23388
+ var geoJSON = formValues.geoJSON,
23389
+ allFormValues = __rest(formValues, ["opacity", "geoJSON"]);
23390
+ // rewind geometry
23391
+ var rewindedGeometry = rewindGeometry(geoJSON);
23389
23392
  onSubmitForm(Object.assign(Object.assign({}, allFormValues), {
23390
- id: id
23393
+ id: id,
23394
+ geoJSON: rewindedGeometry
23391
23395
  }));
23392
23396
  })();
23393
23397
  };
@@ -23600,7 +23604,7 @@ var DrawingToolFormConnect = function DrawingToolFormConnect() {
23600
23604
  });
23601
23605
  var onSubmitForm = function onSubmitForm(formValues) {
23602
23606
  dispatch(drawActions.submitDrawValues({
23603
- geoJSON: layerFeatureGeoJSON,
23607
+ geoJSON: formValues.geoJSON,
23604
23608
  objectName: formValues.objectName,
23605
23609
  scope: 'user',
23606
23610
  id: drawing === null || drawing === void 0 ? void 0 : drawing.id
@@ -23719,7 +23723,7 @@ var DrawingToolConnect = function DrawingToolConnect(_ref) {
23719
23723
  React.useEffect(function () {
23720
23724
  dispatch(drawtoolActions.registerDrawTool({
23721
23725
  drawToolId: drawingDialogType,
23722
- drawModes: currentlySupportedDrawModes
23726
+ defaultDrawModes: currentlySupportedDrawModes
23723
23727
  }));
23724
23728
  return function () {
23725
23729
  dispatch(drawtoolActions.unregisterDrawTool({
package/package.json CHANGED
@@ -1,35 +1,14 @@
1
1
  {
2
2
  "name": "@opengeoweb/warnings",
3
- "version": "8.4.1",
3
+ "version": "9.0.0",
4
4
  "description": "GeoWeb warinings library for the opengeoweb project",
5
5
  "license": "Apache-2.0",
6
6
  "repository": {
7
7
  "type": "git",
8
8
  "url": "git@gitlab.com:opengeoweb/opengeoweb.git"
9
9
  },
10
- "dependencies": {
11
- "@mui/material": "5.12.0",
12
- "@opengeoweb/api": "8.4.1",
13
- "@opengeoweb/core": "8.4.1",
14
- "@opengeoweb/form-fields": "8.4.1",
15
- "@opengeoweb/shared": "8.4.1",
16
- "@opengeoweb/store": "8.4.1",
17
- "@opengeoweb/theme": "8.4.1",
18
- "@opengeoweb/webmap": "8.4.1",
19
- "@opengeoweb/webmap-react": "8.4.1",
20
- "@redux-eggs/redux-toolkit": "2.2.0",
21
- "@redux-eggs/saga-extension": "2.2.0",
22
- "@reduxjs/toolkit": "1.9.7",
23
- "axios": "1.5.0",
24
- "lodash": "4.17.21",
25
- "react": "18.2.0",
26
- "react-hook-form": "7.47.0",
27
- "react-redux": "8.1.3",
28
- "react-window": "1.8.9",
29
- "redux-saga": "1.2.3"
30
- },
10
+ "dependencies": {},
31
11
  "module": "./index.esm.js",
32
12
  "type": "module",
33
- "main": "./index.esm.js",
34
- "peerDependencies": {}
13
+ "main": "./index.esm.js"
35
14
  }