@opengeoweb/sigmet-airmet 6.0.1 → 6.0.2

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.d.ts ADDED
@@ -0,0 +1 @@
1
+ export * from "./src/index";
@@ -1,5 +1,5 @@
1
1
  import * as React from 'react';
2
- import React__default, { createContext, version, useContext, useRef, useCallback, useDebugValue, forwardRef, createElement, Fragment } from 'react';
2
+ import React__default, { useContext, useRef, useCallback, useDebugValue, forwardRef } from 'react';
3
3
  import { FormControlLabel, Radio, Grid, Typography, Box as Box$2, Button, Checkbox, MenuItem, FormHelperText, useTheme as useTheme$2, Dialog, DialogTitle, DialogContent, Card, LinearProgress, List, ListItemButton, Backdrop, CircularProgress } from '@mui/material';
4
4
  import { useFormContext } from 'react-hook-form';
5
5
  import { useDraftFormHelpers, ReactHookFormRadioGroup, ReactHookFormSelect, ReactHookFormNumberField, isInteger, isValidMax, isValidMin, isEmpty, ReactHookFormDateTime, isValidDate, isBefore, isBetween, hasMaxFeaturePoints, hasMulitpleIntersections, ReactHookFormHiddenInput, isMaximumOneDrawing, hasIntersectionWithFIR, isValidGeoJsonCoordinates, isXHoursBefore, isAfter, isXHoursAfter, ReactHookFormTextField, isLatitude, isNonOrBothCoordinates, isLongitude, ReactHookFormFormControl, isGeometryDirty, ReactHookFormProvider, defaultFormOptions } from '@opengeoweb/form-fields';
@@ -661,7 +661,12 @@ function __awaiter(thisArg, _arguments, P, generator) {
661
661
  function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
662
662
  step((generator = generator.apply(thisArg, _arguments || [])).next());
663
663
  });
664
- }
664
+ }
665
+
666
+ typeof SuppressedError === "function" ? SuppressedError : function (error, suppressed, message) {
667
+ var e = new Error(message);
668
+ return e.name = "SuppressedError", e.error = error, e.suppressed = suppressed, e;
669
+ };
665
670
 
666
671
  // A version of a radio button with label where the label and surrounding white space is not clickable
667
672
  var RadioButtonAndLabel = function RadioButtonAndLabel(props) {
@@ -3927,40 +3932,39 @@ if (process.env.NODE_ENV === 'production') {
3927
3932
  withSelector.exports = withSelector_development;
3928
3933
  }
3929
3934
 
3930
- const ContextKey = Symbol.for(`react-redux-context-${version}`);
3931
- const gT = globalThis;
3935
+ const ContextKey = Symbol.for(`react-redux-context`);
3936
+ const gT = typeof globalThis !== "undefined" ? globalThis :
3937
+ /* fall back to a per-module scope (pre-8.1 behaviour) if `globalThis` is not available */
3938
+ {};
3932
3939
 
3933
3940
  function getContext() {
3934
- let realContext = gT[ContextKey];
3941
+ var _gT$ContextKey;
3942
+
3943
+ if (!React.createContext) return {};
3944
+ const contextMap = (_gT$ContextKey = gT[ContextKey]) != null ? _gT$ContextKey : gT[ContextKey] = new Map();
3945
+ let realContext = contextMap.get(React.createContext);
3935
3946
 
3936
3947
  if (!realContext) {
3937
- realContext = createContext(null);
3948
+ realContext = React.createContext(null);
3938
3949
 
3939
3950
  if (process.env.NODE_ENV !== 'production') {
3940
3951
  realContext.displayName = 'ReactRedux';
3941
3952
  }
3942
3953
 
3943
- gT[ContextKey] = realContext;
3954
+ contextMap.set(React.createContext, realContext);
3944
3955
  }
3945
3956
 
3946
3957
  return realContext;
3947
3958
  }
3948
3959
 
3949
- const ReactReduxContext = /*#__PURE__*/new Proxy({}, /*#__PURE__*/new Proxy({}, {
3950
- get(_, handler) {
3951
- const target = getContext(); // @ts-ignore
3960
+ const ReactReduxContext = /*#__PURE__*/getContext();
3952
3961
 
3953
- return (_target, ...args) => Reflect[handler](target, ...args);
3954
- }
3955
-
3956
- }));
3957
-
3958
- /**
3959
- * Hook factory, which creates a `useReduxContext` hook bound to a given context. This is a low-level
3960
- * hook that you should usually not need to call directly.
3961
- *
3962
- * @param {React.Context} [context=ReactReduxContext] Context passed to your `<Provider>`.
3963
- * @returns {Function} A `useReduxContext` hook bound to the specified context.
3962
+ /**
3963
+ * Hook factory, which creates a `useReduxContext` hook bound to a given context. This is a low-level
3964
+ * hook that you should usually not need to call directly.
3965
+ *
3966
+ * @param {React.Context} [context=ReactReduxContext] Context passed to your `<Provider>`.
3967
+ * @returns {Function} A `useReduxContext` hook bound to the specified context.
3964
3968
  */
3965
3969
  function createReduxContextHook(context = ReactReduxContext) {
3966
3970
  return function useReduxContext() {
@@ -3973,21 +3977,21 @@ function createReduxContextHook(context = ReactReduxContext) {
3973
3977
  return contextValue;
3974
3978
  };
3975
3979
  }
3976
- /**
3977
- * A hook to access the value of the `ReactReduxContext`. This is a low-level
3978
- * hook that you should usually not need to call directly.
3979
- *
3980
- * @returns {any} the value of the `ReactReduxContext`
3981
- *
3982
- * @example
3983
- *
3984
- * import React from 'react'
3985
- * import { useReduxContext } from 'react-redux'
3986
- *
3987
- * export const CounterComponent = () => {
3988
- * const { store } = useReduxContext()
3989
- * return <div>{store.getState()}</div>
3990
- * }
3980
+ /**
3981
+ * A hook to access the value of the `ReactReduxContext`. This is a low-level
3982
+ * hook that you should usually not need to call directly.
3983
+ *
3984
+ * @returns {any} the value of the `ReactReduxContext`
3985
+ *
3986
+ * @example
3987
+ *
3988
+ * import React from 'react'
3989
+ * import { useReduxContext } from 'react-redux'
3990
+ *
3991
+ * export const CounterComponent = () => {
3992
+ * const { store } = useReduxContext()
3993
+ * return <div>{store.getState()}</div>
3994
+ * }
3991
3995
  */
3992
3996
 
3993
3997
  const useReduxContext = /*#__PURE__*/createReduxContextHook();
@@ -4002,11 +4006,11 @@ const initializeUseSelector = fn => {
4002
4006
  };
4003
4007
 
4004
4008
  const refEquality = (a, b) => a === b;
4005
- /**
4006
- * Hook factory, which creates a `useSelector` hook bound to a given context.
4007
- *
4008
- * @param {React.Context} [context=ReactReduxContext] Context passed to your `<Provider>`.
4009
- * @returns {Function} A `useSelector` hook bound to the specified context.
4009
+ /**
4010
+ * Hook factory, which creates a `useSelector` hook bound to a given context.
4011
+ *
4012
+ * @param {React.Context} [context=ReactReduxContext] Context passed to your `<Provider>`.
4013
+ * @returns {Function} A `useSelector` hook bound to the specified context.
4010
4014
  */
4011
4015
 
4012
4016
 
@@ -4083,28 +4087,28 @@ function createSelectorHook(context = ReactReduxContext) {
4083
4087
  return selectedState;
4084
4088
  };
4085
4089
  }
4086
- /**
4087
- * A hook to access the redux store's state. This hook takes a selector function
4088
- * as an argument. The selector is called with the store state.
4089
- *
4090
- * This hook takes an optional equality comparison function as the second parameter
4091
- * that allows you to customize the way the selected state is compared to determine
4092
- * whether the component needs to be re-rendered.
4093
- *
4094
- * @param {Function} selector the selector function
4095
- * @param {Function=} equalityFn the function that will be used to determine equality
4096
- *
4097
- * @returns {any} the selected state
4098
- *
4099
- * @example
4100
- *
4101
- * import React from 'react'
4102
- * import { useSelector } from 'react-redux'
4103
- *
4104
- * export const CounterComponent = () => {
4105
- * const counter = useSelector(state => state.counter)
4106
- * return <div>{counter}</div>
4107
- * }
4090
+ /**
4091
+ * A hook to access the redux store's state. This hook takes a selector function
4092
+ * as an argument. The selector is called with the store state.
4093
+ *
4094
+ * This hook takes an optional equality comparison function as the second parameter
4095
+ * that allows you to customize the way the selected state is compared to determine
4096
+ * whether the component needs to be re-rendered.
4097
+ *
4098
+ * @param {Function} selector the selector function
4099
+ * @param {Function=} equalityFn the function that will be used to determine equality
4100
+ *
4101
+ * @returns {any} the selected state
4102
+ *
4103
+ * @example
4104
+ *
4105
+ * import React from 'react'
4106
+ * import { useSelector } from 'react-redux'
4107
+ *
4108
+ * export const CounterComponent = () => {
4109
+ * const counter = useSelector(state => state.counter)
4110
+ * return <div>{counter}</div>
4111
+ * }
4108
4112
  */
4109
4113
 
4110
4114
  const useSelector = /*#__PURE__*/createSelectorHook();
@@ -4631,11 +4635,11 @@ function shallowEqual(objA, objB) {
4631
4635
  return true;
4632
4636
  }
4633
4637
 
4634
- /**
4635
- * Hook factory, which creates a `useStore` hook bound to a given context.
4636
- *
4637
- * @param {React.Context} [context=ReactReduxContext] Context passed to your `<Provider>`.
4638
- * @returns {Function} A `useStore` hook bound to the specified context.
4638
+ /**
4639
+ * Hook factory, which creates a `useStore` hook bound to a given context.
4640
+ *
4641
+ * @param {React.Context} [context=ReactReduxContext] Context passed to your `<Provider>`.
4642
+ * @returns {Function} A `useStore` hook bound to the specified context.
4639
4643
  */
4640
4644
 
4641
4645
  function createStoreHook(context = ReactReduxContext) {
@@ -4650,29 +4654,29 @@ function createStoreHook(context = ReactReduxContext) {
4650
4654
  return store;
4651
4655
  };
4652
4656
  }
4653
- /**
4654
- * A hook to access the redux store.
4655
- *
4656
- * @returns {any} the redux store
4657
- *
4658
- * @example
4659
- *
4660
- * import React from 'react'
4661
- * import { useStore } from 'react-redux'
4662
- *
4663
- * export const ExampleComponent = () => {
4664
- * const store = useStore()
4665
- * return <div>{store.getState()}</div>
4666
- * }
4657
+ /**
4658
+ * A hook to access the redux store.
4659
+ *
4660
+ * @returns {any} the redux store
4661
+ *
4662
+ * @example
4663
+ *
4664
+ * import React from 'react'
4665
+ * import { useStore } from 'react-redux'
4666
+ *
4667
+ * export const ExampleComponent = () => {
4668
+ * const store = useStore()
4669
+ * return <div>{store.getState()}</div>
4670
+ * }
4667
4671
  */
4668
4672
 
4669
4673
  const useStore = /*#__PURE__*/createStoreHook();
4670
4674
 
4671
- /**
4672
- * Hook factory, which creates a `useDispatch` hook bound to a given context.
4673
- *
4674
- * @param {React.Context} [context=ReactReduxContext] Context passed to your `<Provider>`.
4675
- * @returns {Function} A `useDispatch` hook bound to the specified context.
4675
+ /**
4676
+ * Hook factory, which creates a `useDispatch` hook bound to a given context.
4677
+ *
4678
+ * @param {React.Context} [context=ReactReduxContext] Context passed to your `<Provider>`.
4679
+ * @returns {Function} A `useDispatch` hook bound to the specified context.
4676
4680
  */
4677
4681
 
4678
4682
  function createDispatchHook(context = ReactReduxContext) {
@@ -4684,26 +4688,26 @@ function createDispatchHook(context = ReactReduxContext) {
4684
4688
  return store.dispatch;
4685
4689
  };
4686
4690
  }
4687
- /**
4688
- * A hook to access the redux `dispatch` function.
4689
- *
4690
- * @returns {any|function} redux store's `dispatch` function
4691
- *
4692
- * @example
4693
- *
4694
- * import React, { useCallback } from 'react'
4695
- * import { useDispatch } from 'react-redux'
4696
- *
4697
- * export const CounterComponent = ({ value }) => {
4698
- * const dispatch = useDispatch()
4699
- * const increaseCounter = useCallback(() => dispatch({ type: 'increase-counter' }), [])
4700
- * return (
4701
- * <div>
4702
- * <span>{value}</span>
4703
- * <button onClick={increaseCounter}>Increase counter</button>
4704
- * </div>
4705
- * )
4706
- * }
4691
+ /**
4692
+ * A hook to access the redux `dispatch` function.
4693
+ *
4694
+ * @returns {any|function} redux store's `dispatch` function
4695
+ *
4696
+ * @example
4697
+ *
4698
+ * import React, { useCallback } from 'react'
4699
+ * import { useDispatch } from 'react-redux'
4700
+ *
4701
+ * export const CounterComponent = ({ value }) => {
4702
+ * const dispatch = useDispatch()
4703
+ * const increaseCounter = useCallback(() => dispatch({ type: 'increase-counter' }), [])
4704
+ * return (
4705
+ * <div>
4706
+ * <span>{value}</span>
4707
+ * <button onClick={increaseCounter}>Increase counter</button>
4708
+ * </div>
4709
+ * )
4710
+ * }
4707
4711
  */
4708
4712
 
4709
4713
  const useDispatch = /*#__PURE__*/createDispatchHook();
@@ -10411,6 +10415,7 @@ var RULESET = 'rule';
10411
10415
  var DECLARATION = 'decl';
10412
10416
  var IMPORT = '@import';
10413
10417
  var KEYFRAMES = '@keyframes';
10418
+ var LAYER = '@layer';
10414
10419
 
10415
10420
  /**
10416
10421
  * @param {number}
@@ -10825,7 +10830,7 @@ function parse (value, root, parent, rule, rules, rulesets, pseudo, points, decl
10825
10830
  // \0 }
10826
10831
  case 0: case 125: scanning = 0;
10827
10832
  // ;
10828
- case 59 + offset:
10833
+ case 59 + offset: if (ampersand == -1) characters = replace(characters, /\f/g, '');
10829
10834
  if (property > 0 && (strlen(characters) - length))
10830
10835
  append(property > 32 ? declaration(characters + ';', rule, parent, length - 1) : declaration(replace(characters, ' ', '') + ';', rule, parent, length - 2), declarations);
10831
10836
  break
@@ -10840,8 +10845,8 @@ function parse (value, root, parent, rule, rules, rulesets, pseudo, points, decl
10840
10845
  parse(characters, root, reference, reference, props, rulesets, length, points, children);
10841
10846
  else
10842
10847
  switch (atrule === 99 && charat(characters, 3) === 110 ? 100 : atrule) {
10843
- // d m s
10844
- case 100: case 109: case 115:
10848
+ // d l m s
10849
+ case 100: case 108: case 109: case 115:
10845
10850
  parse(value, reference, reference, rule && append(ruleset(value, reference, reference, 0, 0, rules, points, type, rules, props = [], length), children), rules, children, length, points, rule ? props : children);
10846
10851
  break
10847
10852
  default:
@@ -10960,6 +10965,7 @@ function serialize (children, callback) {
10960
10965
  */
10961
10966
  function stringify (element, index, children, callback) {
10962
10967
  switch (element.type) {
10968
+ case LAYER: if (element.children.length) break
10963
10969
  case IMPORT: case DECLARATION: return element.return = element.return || element.value
10964
10970
  case COMMENT: return ''
10965
10971
  case KEYFRAMES: return element.return = element.value + '{' + serialize(element.children, callback) + '}'
@@ -11763,6 +11769,7 @@ function murmur2(str) {
11763
11769
 
11764
11770
  var unitlessKeys = {
11765
11771
  animationIterationCount: 1,
11772
+ aspectRatio: 1,
11766
11773
  borderImageOutset: 1,
11767
11774
  borderImageSlice: 1,
11768
11775
  borderImageWidth: 1,
@@ -12133,7 +12140,7 @@ var useInsertionEffectAlwaysWithSyncFallback = !isBrowser$2 ? syncFallback : use
12133
12140
  var isBrowser$1 = typeof document !== 'undefined';
12134
12141
  var hasOwnProperty = {}.hasOwnProperty;
12135
12142
 
12136
- var EmotionCacheContext = /* #__PURE__ */createContext( // we're doing this to avoid preconstruct's dead code elimination in this one case
12143
+ var EmotionCacheContext = /* #__PURE__ */React.createContext( // we're doing this to avoid preconstruct's dead code elimination in this one case
12137
12144
  // because this module is primarily intended for the browser and node
12138
12145
  // but it's also required in react native and similar environments sometimes
12139
12146
  // and we could have a special build just for that
@@ -12172,7 +12179,7 @@ if (!isBrowser$1) {
12172
12179
  cache = createCache({
12173
12180
  key: 'css'
12174
12181
  });
12175
- return /*#__PURE__*/createElement(EmotionCacheContext.Provider, {
12182
+ return /*#__PURE__*/React.createElement(EmotionCacheContext.Provider, {
12176
12183
  value: cache
12177
12184
  }, func(props, cache));
12178
12185
  } else {
@@ -12182,7 +12189,7 @@ if (!isBrowser$1) {
12182
12189
  };
12183
12190
  }
12184
12191
 
12185
- var ThemeContext = /* #__PURE__ */createContext({});
12192
+ var ThemeContext = /* #__PURE__ */React.createContext({});
12186
12193
 
12187
12194
  if (process.env.NODE_ENV !== 'production') {
12188
12195
  ThemeContext.displayName = 'EmotionThemeContext';
@@ -12211,7 +12218,7 @@ var Insertion$1 = function Insertion(_ref) {
12211
12218
  next = next.next;
12212
12219
  }
12213
12220
 
12214
- return /*#__PURE__*/createElement("style", (_ref2 = {}, _ref2["data-emotion"] = cache.key + " " + serializedNames, _ref2.dangerouslySetInnerHTML = {
12221
+ return /*#__PURE__*/React.createElement("style", (_ref2 = {}, _ref2["data-emotion"] = cache.key + " " + serializedNames, _ref2.dangerouslySetInnerHTML = {
12215
12222
  __html: rules
12216
12223
  }, _ref2.nonce = cache.sheet.nonce, _ref2));
12217
12224
  }
@@ -12238,7 +12245,7 @@ var Emotion = /* #__PURE__ */withEmotionCache(function (props, cache, ref) {
12238
12245
  className = props.className + " ";
12239
12246
  }
12240
12247
 
12241
- var serialized = serializeStyles(registeredStyles, undefined, useContext(ThemeContext));
12248
+ var serialized = serializeStyles(registeredStyles, undefined, React.useContext(ThemeContext));
12242
12249
 
12243
12250
  if (process.env.NODE_ENV !== 'production' && serialized.name.indexOf('-') === -1) {
12244
12251
  var labelFromStack = props[labelPropName];
@@ -12259,11 +12266,11 @@ var Emotion = /* #__PURE__ */withEmotionCache(function (props, cache, ref) {
12259
12266
 
12260
12267
  newProps.ref = ref;
12261
12268
  newProps.className = className;
12262
- return /*#__PURE__*/createElement(Fragment, null, /*#__PURE__*/createElement(Insertion$1, {
12269
+ return /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement(Insertion$1, {
12263
12270
  cache: cache,
12264
12271
  serialized: serialized,
12265
12272
  isStringTag: typeof WrappedComponent === 'string'
12266
- }), /*#__PURE__*/createElement(WrappedComponent, newProps));
12273
+ }), /*#__PURE__*/React.createElement(WrappedComponent, newProps));
12267
12274
  });
12268
12275
 
12269
12276
  if (process.env.NODE_ENV !== 'production') {
@@ -12322,7 +12329,7 @@ var Insertion = function Insertion(_ref) {
12322
12329
  next = next.next;
12323
12330
  }
12324
12331
 
12325
- return /*#__PURE__*/createElement("style", (_ref2 = {}, _ref2["data-emotion"] = cache.key + " " + serializedNames, _ref2.dangerouslySetInnerHTML = {
12332
+ return /*#__PURE__*/React.createElement("style", (_ref2 = {}, _ref2["data-emotion"] = cache.key + " " + serializedNames, _ref2.dangerouslySetInnerHTML = {
12326
12333
  __html: rules
12327
12334
  }, _ref2.nonce = cache.sheet.nonce, _ref2));
12328
12335
  }
@@ -12392,7 +12399,7 @@ var createStyled = function createStyled(tag, options) {
12392
12399
  mergedProps[key] = props[key];
12393
12400
  }
12394
12401
 
12395
- mergedProps.theme = useContext(ThemeContext);
12402
+ mergedProps.theme = React.useContext(ThemeContext);
12396
12403
  }
12397
12404
 
12398
12405
  if (typeof props.className === 'string') {
@@ -12422,11 +12429,11 @@ var createStyled = function createStyled(tag, options) {
12422
12429
 
12423
12430
  newProps.className = className;
12424
12431
  newProps.ref = ref;
12425
- return /*#__PURE__*/createElement(Fragment, null, /*#__PURE__*/createElement(Insertion, {
12432
+ return /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement(Insertion, {
12426
12433
  cache: cache,
12427
12434
  serialized: serialized,
12428
12435
  isStringTag: typeof FinalTag === 'string'
12429
- }), /*#__PURE__*/createElement(FinalTag, newProps));
12436
+ }), /*#__PURE__*/React.createElement(FinalTag, newProps));
12430
12437
  });
12431
12438
  Styled.displayName = identifierName !== undefined ? identifierName : "Styled(" + (typeof baseTag === 'string' ? baseTag : baseTag.displayName || baseTag.name || 'Component') + ")";
12432
12439
  Styled.defaultProps = tag.defaultProps;
@@ -12464,17 +12471,15 @@ tags.forEach(function (tagName) {
12464
12471
  newStyled[tagName] = newStyled(tagName);
12465
12472
  });
12466
12473
 
12467
- var emStyled = newStyled;
12468
-
12469
12474
  /**
12470
- * @mui/styled-engine v5.12.0
12475
+ * @mui/styled-engine v5.13.2
12471
12476
  *
12472
12477
  * @license MIT
12473
12478
  * This source code is licensed under the MIT license found in the
12474
12479
  * LICENSE file in the root directory of this source tree.
12475
12480
  */
12476
12481
  function styled(tag, options) {
12477
- const stylesFactory = emStyled(tag, options);
12482
+ const stylesFactory = newStyled(tag, options);
12478
12483
  if (process.env.NODE_ENV !== 'production') {
12479
12484
  return (...styles) => {
12480
12485
  const component = typeof tag === 'string' ? `"${tag}"` : 'component';
@@ -12870,6 +12875,9 @@ process.env.NODE_ENV !== 'production' ? spacingKeys.reduce((obj, key) => {
12870
12875
  return obj;
12871
12876
  }, {}) : {};
12872
12877
 
12878
+ // The different signatures imply different meaning for their arguments that can't be expressed structurally.
12879
+ // We express the difference with variable names.
12880
+ /* tslint:disable:unified-signatures */
12873
12881
  /* tslint:enable:unified-signatures */
12874
12882
 
12875
12883
  function createSpacing(spacingInput = 8) {
@@ -13106,8 +13114,8 @@ const width = style$1({
13106
13114
  const maxWidth = props => {
13107
13115
  if (props.maxWidth !== undefined && props.maxWidth !== null) {
13108
13116
  const styleFromPropValue = propValue => {
13109
- var _props$theme, _props$theme$breakpoi, _props$theme$breakpoi2;
13110
- const breakpoint = ((_props$theme = props.theme) == null ? void 0 : (_props$theme$breakpoi = _props$theme.breakpoints) == null ? void 0 : (_props$theme$breakpoi2 = _props$theme$breakpoi.values) == null ? void 0 : _props$theme$breakpoi2[propValue]) || values[propValue];
13117
+ var _props$theme;
13118
+ const breakpoint = ((_props$theme = props.theme) == null || (_props$theme = _props$theme.breakpoints) == null || (_props$theme = _props$theme.values) == null ? void 0 : _props$theme[propValue]) || values[propValue];
13111
13119
  return {
13112
13120
  maxWidth: breakpoint || sizingTransform(propValue)
13113
13121
  };
@@ -13459,6 +13467,8 @@ function unstable_createStyleFunctionSx() {
13459
13467
  if (val == null) {
13460
13468
  return null;
13461
13469
  }
13470
+
13471
+ // TODO v6: remove, see https://github.com/mui/material-ui/pull/38123
13462
13472
  if (themeKey === 'typography' && val === 'inherit') {
13463
13473
  return {
13464
13474
  [prop]: val
@@ -13603,7 +13613,7 @@ const splitProps = props => {
13603
13613
  systemProps: {},
13604
13614
  otherProps: {}
13605
13615
  };
13606
- const config = (_props$theme$unstable = props == null ? void 0 : (_props$theme = props.theme) == null ? void 0 : _props$theme.unstable_sxConfig) != null ? _props$theme$unstable : defaultSxConfig$1;
13616
+ const config = (_props$theme$unstable = props == null || (_props$theme = props.theme) == null ? void 0 : _props$theme.unstable_sxConfig) != null ? _props$theme$unstable : defaultSxConfig$1;
13607
13617
  Object.keys(props).forEach(prop => {
13608
13618
  if (config[prop]) {
13609
13619
  result.systemProps[prop] = props[prop];
package/package.json CHANGED
@@ -1,38 +1,37 @@
1
1
  {
2
2
  "name": "@opengeoweb/sigmet-airmet",
3
- "version": "6.0.1",
3
+ "version": "6.0.2",
4
4
  "description": "GeoWeb Sigmet/Airmet 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
- "module": "./index.js",
11
- "main": "./index.js",
10
+ "module": "./index.esm.js",
12
11
  "type": "module",
13
- "types": "./src/index.d.ts",
12
+ "main": "./index.esm.js",
14
13
  "dependencies": {
15
14
  "@mui/material": "5.12.0",
16
- "@mui/system": "5.12.0",
17
- "@opengeoweb/api": "6.0.1",
18
- "@opengeoweb/authentication": "6.0.1",
19
- "@opengeoweb/core": "6.0.1",
20
- "@opengeoweb/form-fields": "6.0.1",
21
- "@opengeoweb/shared": "6.0.1",
22
- "@opengeoweb/store": "6.0.1",
23
- "@opengeoweb/theme": "6.0.1",
24
- "@opengeoweb/webmap": "6.0.1",
15
+ "@mui/system": "5.14.5",
16
+ "@opengeoweb/api": "6.0.2",
17
+ "@opengeoweb/authentication": "6.0.2",
18
+ "@opengeoweb/core": "6.0.2",
19
+ "@opengeoweb/form-fields": "6.0.2",
20
+ "@opengeoweb/shared": "6.0.2",
21
+ "@opengeoweb/store": "6.0.2",
22
+ "@opengeoweb/theme": "6.0.2",
23
+ "@opengeoweb/webmap": "6.0.2",
25
24
  "@redux-eggs/redux-toolkit": "2.2.0",
26
25
  "@redux-eggs/saga-extension": "2.2.0",
27
26
  "@reduxjs/toolkit": "1.9.5",
28
27
  "@turf/turf": "6.5.0",
29
- "axios": "1.2.0",
28
+ "axios": "1.4.0",
30
29
  "immer": "9.0.21",
31
30
  "lodash": "4.17.21",
32
31
  "moment": "2.29.4",
33
32
  "react": "18.2.0",
34
- "react-hook-form": "7.45.2",
35
- "react-redux": "8.1.1"
33
+ "react-hook-form": "7.45.4",
34
+ "react-redux": "8.1.2"
36
35
  },
37
36
  "peerDependencies": {}
38
37
  }
@@ -1,6 +1,6 @@
1
1
  import * as React from 'react';
2
2
  import { ApiModuleProps } from './AviationProductApiWrapper';
3
- declare type AirmetComponentType = 'AirmetModule';
3
+ type AirmetComponentType = 'AirmetModule';
4
4
  export interface AirmetComponentsLookUpPayload {
5
5
  componentType: AirmetComponentType;
6
6
  id: string;
@@ -1,6 +1,6 @@
1
1
  import * as React from 'react';
2
2
  import { ApiModuleProps } from './AviationProductApiWrapper';
3
- declare type SigmetComponentType = 'SigmetModule';
3
+ type SigmetComponentType = 'SigmetModule';
4
4
  export interface SigmetComponentsLookUpPayload {
5
5
  componentType: SigmetComponentType;
6
6
  id: string;
@@ -2,7 +2,7 @@ import { AirmetFromBackend, ProductConfig, ProductType, SigmetFromBackend } from
2
2
  export declare const ERROR_CONFIG = "An error has occurred while loading the config";
3
3
  export declare const ERROR_BACKEND = "An error has occurred while retrieving the list, please try again";
4
4
  export declare const validateConfig: (productType: ProductType, productConfig: ProductConfig) => true | Error;
5
- declare type State = {
5
+ type State = {
6
6
  isLoading: boolean;
7
7
  error: Error;
8
8
  result: SigmetFromBackend[] | AirmetFromBackend[];
@@ -91,6 +91,11 @@ export declare const CancelAirmetLightTheme: {
91
91
  name: string;
92
92
  link: string;
93
93
  }[];
94
+ } | {
95
+ zeplinLink: {
96
+ name: string;
97
+ link: string;
98
+ }[];
94
99
  };
95
100
  };
96
101
  export declare const CancelAirmetDarkTheme: () => React.ReactElement;
@@ -1,6 +1,6 @@
1
1
  import React from 'react';
2
2
  import { ConfigurableFormFieldProps, ProductConfig } from '../../../types';
3
- export declare const getFirLocationDefaultValues: (productConfig: ProductConfig, currentFir?: string | undefined) => {
3
+ export declare const getFirLocationDefaultValues: (productConfig: ProductConfig, currentFir?: string) => {
4
4
  locationIndicatorATSR: string;
5
5
  locationIndicatorATSU: string;
6
6
  locationIndicatorMWO: string;
@@ -1,6 +1,6 @@
1
1
  import React from 'react';
2
2
  import { CancelSigmet, Sigmet, Airmet, CancelAirmet } from '../../types';
3
- declare type AviationProduct = Sigmet | CancelSigmet | Airmet | CancelAirmet;
3
+ type AviationProduct = Sigmet | CancelSigmet | Airmet | CancelAirmet;
4
4
  export declare const noTAC = "Missing data: no TAC can be generated";
5
5
  export declare const shouldRetrieveTAC: (product: AviationProduct) => boolean;
6
6
  export declare const useTAC: (initialProduct: AviationProduct, getTAC: (product: AviationProduct) => Promise<{
@@ -49,7 +49,7 @@ export declare const getAllowedUnits: (selectedFIR: string, productConfig: Produ
49
49
  /**
50
50
  * Function to translate the geojson data to a GeoJSON.FeatureCollection
51
51
  */
52
- export declare const getFir: (productConfig: ProductConfig, firName?: string | undefined) => FIRLocationGeoJson;
52
+ export declare const getFir: (productConfig: ProductConfig, firName?: string) => FIRLocationGeoJson;
53
53
  /**
54
54
  * Function to check if the given geojson object has 'fir' selectionType property
55
55
  */
@@ -1,6 +1,6 @@
1
1
  /// <reference types="react" />
2
2
  import { mapTypes } from '@opengeoweb/store';
3
- export declare type ProductType = 'sigmet' | 'airmet';
3
+ export type ProductType = 'sigmet' | 'airmet';
4
4
  /**
5
5
  * The possible phenomena for the sigmet
6
6
  */
@@ -66,11 +66,11 @@ export declare enum VisibilityCause {
66
66
  'SQ' = "Squalls",
67
67
  'VA' = "Volcanic Ash"
68
68
  }
69
- export declare type ICAOLocation = string;
70
- export declare type MWOLocation = string;
71
- export declare type ATSULocation = string;
72
- export declare type ATSRLocation = string;
73
- export declare type FIR = Record<ICAOLocation, string>;
69
+ export type ICAOLocation = string;
70
+ export type MWOLocation = string;
71
+ export type ATSULocation = string;
72
+ export type ATSRLocation = string;
73
+ export type FIR = Record<ICAOLocation, string>;
74
74
  export declare enum MovementUnit {
75
75
  'KT' = "kt",
76
76
  'KMH' = "kmh"
@@ -79,12 +79,12 @@ export declare enum WindUnit {
79
79
  'KT' = "kt",
80
80
  'MPS' = "mps"
81
81
  }
82
- export declare type VisibilityUnit = 'm';
82
+ export type VisibilityUnit = 'm';
83
83
  export interface Coordinate {
84
84
  latitude: number;
85
85
  longitude: number;
86
86
  }
87
- export declare type DateType = string;
87
+ export type DateType = string;
88
88
  /**
89
89
  * ProductStatus is returned by the backend. The backend fills in this property.
90
90
  * For the backend, it should only need to store 'DRAFT' | 'PUBLISHED' | 'CANCELLED' in its DB.
@@ -92,8 +92,8 @@ export declare type DateType = string;
92
92
  *
93
93
  * Note: ProductStatus from the backend should be refreshed regularly to display status updates.
94
94
  */
95
- export declare type ProductStatus = 'DRAFT' | 'PUBLISHED' | 'CANCELLED' | 'EXPIRED';
96
- export declare type ProductActions = 'DRAFT' | 'PUBLISHED' | 'CANCELLED' | 'EXPIRED' | 'DISCARDED' | 'CLOSED';
95
+ export type ProductStatus = 'DRAFT' | 'PUBLISHED' | 'CANCELLED' | 'EXPIRED';
96
+ export type ProductActions = 'DRAFT' | 'PUBLISHED' | 'CANCELLED' | 'EXPIRED' | 'DISCARDED' | 'CLOSED';
97
97
  export declare enum ProductStatusDescription {
98
98
  'DRAFT' = "Draft",
99
99
  'PUBLISHED' = "Published",
@@ -104,7 +104,7 @@ export declare enum ProductStatusDescription {
104
104
  * A Cancel Sigmet/Airmet (a sigmet/airmet which cancels another sigmet/airmet) can only have the status 'PUBLISHED',
105
105
  * e.g. cannot be edited, cancelled or stored as draft.
106
106
  */
107
- export declare type CancelProductStatus = 'PUBLISHED';
107
+ export type CancelProductStatus = 'PUBLISHED';
108
108
  /**
109
109
  * ProductCanbe lifecycle is determined by the backend. E.g. the backend fills in these properties.
110
110
  *
@@ -113,13 +113,13 @@ export declare type CancelProductStatus = 'PUBLISHED';
113
113
  * 'PUBLISHED': product can be PUBLISHED
114
114
  * 'CANCELLED': product can be CANCELLED
115
115
  */
116
- export declare type ProductCanbe = 'DRAFTED' | 'DISCARDED' | 'PUBLISHED' | 'CANCELLED';
116
+ export type ProductCanbe = 'DRAFTED' | 'DISCARDED' | 'PUBLISHED' | 'CANCELLED';
117
117
  /**
118
118
  * ProductSequence is a sequence label with a counter of the SIGMETs/AIRMETs issued on a day (starting at with 1 01:00),
119
119
  * max 3 characters long; first character should be a capital letter,
120
120
  * others are numbers: A01-A99, 01-99 or 1-99
121
121
  */
122
- export declare type ProductSequenceId = string;
122
+ export type ProductSequenceId = string;
123
123
  /**
124
124
  * This is the base sigmet/airmet structure, used for both the Sigmet, Airmet and CancelSigmet, CancelAirmet
125
125
  */
@@ -193,12 +193,12 @@ export declare enum Direction {
193
193
  'NW' = "NW",
194
194
  'NNW' = "NNW"
195
195
  }
196
- export declare type ObservationOrForcast = 'OBS' | 'FCST';
197
- export declare type Change = 'INTSF' | 'WKN' | 'NC';
198
- export declare type LevelInfoMode = 'AT' | 'BETW' | 'BETW_SFC' | 'TOPS' | 'TOPS_ABV' | 'TOPS_BLW' | 'ABV';
199
- export declare type CloudLevelInfoMode = 'BETW' | 'BETW_SFC' | 'BETW_SFC_ABV' | 'BETW_ABV';
200
- export declare type SigmetMovementType = 'STATIONARY' | 'MOVEMENT' | 'FORECAST_POSITION' | 'NO_VA_EXP';
201
- export declare type AirmetMovementType = 'STATIONARY' | 'MOVEMENT';
196
+ export type ObservationOrForcast = 'OBS' | 'FCST';
197
+ export type Change = 'INTSF' | 'WKN' | 'NC';
198
+ export type LevelInfoMode = 'AT' | 'BETW' | 'BETW_SFC' | 'TOPS' | 'TOPS_ABV' | 'TOPS_BLW' | 'ABV';
199
+ export type CloudLevelInfoMode = 'BETW' | 'BETW_SFC' | 'BETW_SFC_ABV' | 'BETW_ABV';
200
+ export type SigmetMovementType = 'STATIONARY' | 'MOVEMENT' | 'FORECAST_POSITION' | 'NO_VA_EXP';
201
+ export type AirmetMovementType = 'STATIONARY' | 'MOVEMENT';
202
202
  /**
203
203
  * To store all the other sigmet information
204
204
  */
@@ -292,7 +292,7 @@ export interface AirmetFromBackend {
292
292
  creationDate: DateType;
293
293
  canbe: ProductCanbe[];
294
294
  }
295
- export declare type AviationProduct = Sigmet | CancelSigmet | Airmet | CancelAirmet;
295
+ export type AviationProduct = Sigmet | CancelSigmet | Airmet | CancelAirmet;
296
296
  export declare const isInstanceOfSigmet: (obj: Sigmet | CancelSigmet) => obj is Sigmet;
297
297
  export declare const isInstanceOfCancelSigmet: (obj: AviationProduct) => obj is CancelSigmet;
298
298
  export declare const isInstanceOfAirmet: (obj: Airmet | CancelAirmet) => obj is Airmet;
@@ -303,7 +303,7 @@ export declare enum StartOrEndDrawing {
303
303
  'start' = "start",
304
304
  'end' = "end"
305
305
  }
306
- export declare type FormMode = 'new' | 'edit' | 'view';
306
+ export type FormMode = 'new' | 'edit' | 'view';
307
307
  export interface FormFieldProps {
308
308
  productType?: ProductType;
309
309
  onChange?: (event?: React.ChangeEvent<HTMLInputElement>) => void;
@@ -317,7 +317,7 @@ export interface AllowedUnits {
317
317
  unit_type: string;
318
318
  allowed_units: string[];
319
319
  }
320
- export declare type FirAllowedUnits = Record<string, AllowedUnits[]>;
320
+ export type FirAllowedUnits = Record<string, AllowedUnits[]>;
321
321
  export interface CloudLevelMinMaxType {
322
322
  FT?: number;
323
323
  M?: number;
@@ -335,10 +335,10 @@ export interface MovementMinMaxType {
335
335
  KT?: number;
336
336
  KMH?: number;
337
337
  }
338
- export declare type FIRLocationGeoJson = GeoJSON.FeatureCollection<GeoJSON.Geometry, {
338
+ export type FIRLocationGeoJson = GeoJSON.FeatureCollection<GeoJSON.Geometry, {
339
339
  selectionType: string;
340
340
  }>;
341
- export declare type FIRArea = {
341
+ export type FIRArea = {
342
342
  fir_name: string;
343
343
  fir_location: FIRLocationGeoJson;
344
344
  location_indicator_atsr: string;
@@ -380,10 +380,10 @@ export interface FIRConfigAirmet extends FIRArea {
380
380
  visibility_rounding_below?: number;
381
381
  visibility_rounding_above?: number;
382
382
  }
383
- declare type SigmetFIRArea = Record<string, FIRConfigSigmet>;
384
- declare type AirmetFIRArea = Record<string, FIRConfigAirmet>;
385
- export declare type Firareas = SigmetFIRArea | AirmetFIRArea;
386
- export declare type ProductConfig = {
383
+ type SigmetFIRArea = Record<string, FIRConfigSigmet>;
384
+ type AirmetFIRArea = Record<string, FIRConfigAirmet>;
385
+ export type Firareas = SigmetFIRArea | AirmetFIRArea;
386
+ export type ProductConfig = {
387
387
  location_indicator_mwo: string;
388
388
  active_firs: string[];
389
389
  valid_from_delay_minutes: number;
@@ -1,6 +1,6 @@
1
1
  import { CreateApiProps } from '@opengeoweb/api';
2
2
  import { Airmet, AirmetFromBackend, AirmetFromFrontend, ProductConfig, Sigmet, SigmetFromBackend, SigmetFromFrontend } from '../types';
3
- export declare type SigmetAirmetApi = {
3
+ export type SigmetAirmetApi = {
4
4
  getSigmetConfiguration: (productConfigKey: any) => Promise<{
5
5
  data: ProductConfig;
6
6
  }>;
@@ -9,7 +9,7 @@ interface ErrorObject<Keyword extends string = string, Params = Record<string, u
9
9
  schema?: Schema;
10
10
  data?: unknown;
11
11
  }
12
- export declare type AJVErrorObject = ErrorObject<string, Record<string, unknown>, unknown>;
12
+ export type AJVErrorObject = ErrorObject<string, Record<string, unknown>, unknown>;
13
13
  export declare const parseErrors: (errors: AJVErrorObject[]) => AJVErrorObject[];
14
14
  export declare const createReadableErrorMessage: (errors: AJVErrorObject[]) => string;
15
15
  export declare const validateSigmet: (sigmetConfig: SigmetConfig) => boolean | AJVErrorObject[];