@opengeoweb/taf 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 +1 -0
- package/{index.js → index.esm.js} +98 -91
- package/package.json +14 -15
- package/src/lib/components/ComponentsLookUp/ComponentsLookUp.d.ts +1 -1
- package/src/lib/components/IssuesPane/types.d.ts +1 -1
- package/src/lib/components/TafForm/TafFormRow/TafFormTextField.d.ts +1 -1
- package/src/lib/components/TafForm/TafFormRow/validations/clouds.d.ts +1 -1
- package/src/lib/components/TafForm/utils.d.ts +6 -6
- package/src/lib/components/TafLayout/TafPanel/TafPanel.d.ts +1 -1
- package/src/lib/components/TafLayout/utils.d.ts +1 -1
- package/src/lib/components/TafModule/TafModuleProvider.d.ts +1 -1
- package/src/lib/types.d.ts +16 -16
- package/src/lib/utils/api.d.ts +1 -1
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, {
|
|
2
|
+
import React__default, { useContext, forwardRef } from 'react';
|
|
3
3
|
import { Grid, Button, Chip, Box, Typography, FormLabel, Switch, TextField, Card, Tabs, Tab, Dialog, MenuList, MenuItem, Backdrop, CircularProgress } from '@mui/material';
|
|
4
4
|
import { useFormContext, Controller, useFieldArray } from 'react-hook-form';
|
|
5
5
|
import ReactDOM from 'react-dom';
|
|
@@ -443,7 +443,12 @@ function __awaiter(thisArg, _arguments, P, generator) {
|
|
|
443
443
|
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
444
444
|
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
445
445
|
});
|
|
446
|
-
}
|
|
446
|
+
}
|
|
447
|
+
|
|
448
|
+
typeof SuppressedError === "function" ? SuppressedError : function (error, suppressed, message) {
|
|
449
|
+
var e = new Error(message);
|
|
450
|
+
return e.name = "SuppressedError", e.error = error, e.suppressed = suppressed, e;
|
|
451
|
+
};
|
|
447
452
|
|
|
448
453
|
var commonjsGlobal = typeof globalThis !== 'undefined' ? globalThis : typeof window !== 'undefined' ? window : typeof global !== 'undefined' ? global : typeof self !== 'undefined' ? self : {};
|
|
449
454
|
|
|
@@ -892,40 +897,39 @@ if (
|
|
|
892
897
|
|
|
893
898
|
if (process.env.NODE_ENV === 'production') ;
|
|
894
899
|
|
|
895
|
-
const ContextKey = Symbol.for(`react-redux-context
|
|
896
|
-
const gT = globalThis
|
|
900
|
+
const ContextKey = Symbol.for(`react-redux-context`);
|
|
901
|
+
const gT = typeof globalThis !== "undefined" ? globalThis :
|
|
902
|
+
/* fall back to a per-module scope (pre-8.1 behaviour) if `globalThis` is not available */
|
|
903
|
+
{};
|
|
897
904
|
|
|
898
905
|
function getContext() {
|
|
899
|
-
|
|
906
|
+
var _gT$ContextKey;
|
|
907
|
+
|
|
908
|
+
if (!React.createContext) return {};
|
|
909
|
+
const contextMap = (_gT$ContextKey = gT[ContextKey]) != null ? _gT$ContextKey : gT[ContextKey] = new Map();
|
|
910
|
+
let realContext = contextMap.get(React.createContext);
|
|
900
911
|
|
|
901
912
|
if (!realContext) {
|
|
902
|
-
realContext = createContext(null);
|
|
913
|
+
realContext = React.createContext(null);
|
|
903
914
|
|
|
904
915
|
if (process.env.NODE_ENV !== 'production') {
|
|
905
916
|
realContext.displayName = 'ReactRedux';
|
|
906
917
|
}
|
|
907
918
|
|
|
908
|
-
|
|
919
|
+
contextMap.set(React.createContext, realContext);
|
|
909
920
|
}
|
|
910
921
|
|
|
911
922
|
return realContext;
|
|
912
923
|
}
|
|
913
924
|
|
|
914
|
-
const ReactReduxContext = /*#__PURE__*/
|
|
915
|
-
get(_, handler) {
|
|
916
|
-
const target = getContext(); // @ts-ignore
|
|
917
|
-
|
|
918
|
-
return (_target, ...args) => Reflect[handler](target, ...args);
|
|
919
|
-
}
|
|
925
|
+
const ReactReduxContext = /*#__PURE__*/getContext();
|
|
920
926
|
|
|
921
|
-
|
|
922
|
-
|
|
923
|
-
|
|
924
|
-
*
|
|
925
|
-
*
|
|
926
|
-
*
|
|
927
|
-
* @param {React.Context} [context=ReactReduxContext] Context passed to your `<Provider>`.
|
|
928
|
-
* @returns {Function} A `useReduxContext` hook bound to the specified context.
|
|
927
|
+
/**
|
|
928
|
+
* Hook factory, which creates a `useReduxContext` hook bound to a given context. This is a low-level
|
|
929
|
+
* hook that you should usually not need to call directly.
|
|
930
|
+
*
|
|
931
|
+
* @param {React.Context} [context=ReactReduxContext] Context passed to your `<Provider>`.
|
|
932
|
+
* @returns {Function} A `useReduxContext` hook bound to the specified context.
|
|
929
933
|
*/
|
|
930
934
|
function createReduxContextHook(context = ReactReduxContext) {
|
|
931
935
|
return function useReduxContext() {
|
|
@@ -938,21 +942,21 @@ function createReduxContextHook(context = ReactReduxContext) {
|
|
|
938
942
|
return contextValue;
|
|
939
943
|
};
|
|
940
944
|
}
|
|
941
|
-
/**
|
|
942
|
-
* A hook to access the value of the `ReactReduxContext`. This is a low-level
|
|
943
|
-
* hook that you should usually not need to call directly.
|
|
944
|
-
*
|
|
945
|
-
* @returns {any} the value of the `ReactReduxContext`
|
|
946
|
-
*
|
|
947
|
-
* @example
|
|
948
|
-
*
|
|
949
|
-
* import React from 'react'
|
|
950
|
-
* import { useReduxContext } from 'react-redux'
|
|
951
|
-
*
|
|
952
|
-
* export const CounterComponent = () => {
|
|
953
|
-
* const { store } = useReduxContext()
|
|
954
|
-
* return <div>{store.getState()}</div>
|
|
955
|
-
* }
|
|
945
|
+
/**
|
|
946
|
+
* A hook to access the value of the `ReactReduxContext`. This is a low-level
|
|
947
|
+
* hook that you should usually not need to call directly.
|
|
948
|
+
*
|
|
949
|
+
* @returns {any} the value of the `ReactReduxContext`
|
|
950
|
+
*
|
|
951
|
+
* @example
|
|
952
|
+
*
|
|
953
|
+
* import React from 'react'
|
|
954
|
+
* import { useReduxContext } from 'react-redux'
|
|
955
|
+
*
|
|
956
|
+
* export const CounterComponent = () => {
|
|
957
|
+
* const { store } = useReduxContext()
|
|
958
|
+
* return <div>{store.getState()}</div>
|
|
959
|
+
* }
|
|
956
960
|
*/
|
|
957
961
|
|
|
958
962
|
const useReduxContext = /*#__PURE__*/createReduxContextHook();
|
|
@@ -1423,11 +1427,11 @@ reactIs_development.typeOf = typeOf;
|
|
|
1423
1427
|
|
|
1424
1428
|
if (process.env.NODE_ENV === 'production') ;
|
|
1425
1429
|
|
|
1426
|
-
/**
|
|
1427
|
-
* Hook factory, which creates a `useStore` hook bound to a given context.
|
|
1428
|
-
*
|
|
1429
|
-
* @param {React.Context} [context=ReactReduxContext] Context passed to your `<Provider>`.
|
|
1430
|
-
* @returns {Function} A `useStore` hook bound to the specified context.
|
|
1430
|
+
/**
|
|
1431
|
+
* Hook factory, which creates a `useStore` hook bound to a given context.
|
|
1432
|
+
*
|
|
1433
|
+
* @param {React.Context} [context=ReactReduxContext] Context passed to your `<Provider>`.
|
|
1434
|
+
* @returns {Function} A `useStore` hook bound to the specified context.
|
|
1431
1435
|
*/
|
|
1432
1436
|
|
|
1433
1437
|
function createStoreHook(context = ReactReduxContext) {
|
|
@@ -1442,29 +1446,29 @@ function createStoreHook(context = ReactReduxContext) {
|
|
|
1442
1446
|
return store;
|
|
1443
1447
|
};
|
|
1444
1448
|
}
|
|
1445
|
-
/**
|
|
1446
|
-
* A hook to access the redux store.
|
|
1447
|
-
*
|
|
1448
|
-
* @returns {any} the redux store
|
|
1449
|
-
*
|
|
1450
|
-
* @example
|
|
1451
|
-
*
|
|
1452
|
-
* import React from 'react'
|
|
1453
|
-
* import { useStore } from 'react-redux'
|
|
1454
|
-
*
|
|
1455
|
-
* export const ExampleComponent = () => {
|
|
1456
|
-
* const store = useStore()
|
|
1457
|
-
* return <div>{store.getState()}</div>
|
|
1458
|
-
* }
|
|
1449
|
+
/**
|
|
1450
|
+
* A hook to access the redux store.
|
|
1451
|
+
*
|
|
1452
|
+
* @returns {any} the redux store
|
|
1453
|
+
*
|
|
1454
|
+
* @example
|
|
1455
|
+
*
|
|
1456
|
+
* import React from 'react'
|
|
1457
|
+
* import { useStore } from 'react-redux'
|
|
1458
|
+
*
|
|
1459
|
+
* export const ExampleComponent = () => {
|
|
1460
|
+
* const store = useStore()
|
|
1461
|
+
* return <div>{store.getState()}</div>
|
|
1462
|
+
* }
|
|
1459
1463
|
*/
|
|
1460
1464
|
|
|
1461
1465
|
const useStore = /*#__PURE__*/createStoreHook();
|
|
1462
1466
|
|
|
1463
|
-
/**
|
|
1464
|
-
* Hook factory, which creates a `useDispatch` hook bound to a given context.
|
|
1465
|
-
*
|
|
1466
|
-
* @param {React.Context} [context=ReactReduxContext] Context passed to your `<Provider>`.
|
|
1467
|
-
* @returns {Function} A `useDispatch` hook bound to the specified context.
|
|
1467
|
+
/**
|
|
1468
|
+
* Hook factory, which creates a `useDispatch` hook bound to a given context.
|
|
1469
|
+
*
|
|
1470
|
+
* @param {React.Context} [context=ReactReduxContext] Context passed to your `<Provider>`.
|
|
1471
|
+
* @returns {Function} A `useDispatch` hook bound to the specified context.
|
|
1468
1472
|
*/
|
|
1469
1473
|
|
|
1470
1474
|
function createDispatchHook(context = ReactReduxContext) {
|
|
@@ -1476,26 +1480,26 @@ function createDispatchHook(context = ReactReduxContext) {
|
|
|
1476
1480
|
return store.dispatch;
|
|
1477
1481
|
};
|
|
1478
1482
|
}
|
|
1479
|
-
/**
|
|
1480
|
-
* A hook to access the redux `dispatch` function.
|
|
1481
|
-
*
|
|
1482
|
-
* @returns {any|function} redux store's `dispatch` function
|
|
1483
|
-
*
|
|
1484
|
-
* @example
|
|
1485
|
-
*
|
|
1486
|
-
* import React, { useCallback } from 'react'
|
|
1487
|
-
* import { useDispatch } from 'react-redux'
|
|
1488
|
-
*
|
|
1489
|
-
* export const CounterComponent = ({ value }) => {
|
|
1490
|
-
* const dispatch = useDispatch()
|
|
1491
|
-
* const increaseCounter = useCallback(() => dispatch({ type: 'increase-counter' }), [])
|
|
1492
|
-
* return (
|
|
1493
|
-
* <div>
|
|
1494
|
-
* <span>{value}</span>
|
|
1495
|
-
* <button onClick={increaseCounter}>Increase counter</button>
|
|
1496
|
-
* </div>
|
|
1497
|
-
* )
|
|
1498
|
-
* }
|
|
1483
|
+
/**
|
|
1484
|
+
* A hook to access the redux `dispatch` function.
|
|
1485
|
+
*
|
|
1486
|
+
* @returns {any|function} redux store's `dispatch` function
|
|
1487
|
+
*
|
|
1488
|
+
* @example
|
|
1489
|
+
*
|
|
1490
|
+
* import React, { useCallback } from 'react'
|
|
1491
|
+
* import { useDispatch } from 'react-redux'
|
|
1492
|
+
*
|
|
1493
|
+
* export const CounterComponent = ({ value }) => {
|
|
1494
|
+
* const dispatch = useDispatch()
|
|
1495
|
+
* const increaseCounter = useCallback(() => dispatch({ type: 'increase-counter' }), [])
|
|
1496
|
+
* return (
|
|
1497
|
+
* <div>
|
|
1498
|
+
* <span>{value}</span>
|
|
1499
|
+
* <button onClick={increaseCounter}>Increase counter</button>
|
|
1500
|
+
* </div>
|
|
1501
|
+
* )
|
|
1502
|
+
* }
|
|
1499
1503
|
*/
|
|
1500
1504
|
|
|
1501
1505
|
const useDispatch = /*#__PURE__*/createDispatchHook();
|
|
@@ -30392,6 +30396,7 @@ var RULESET = 'rule';
|
|
|
30392
30396
|
var DECLARATION = 'decl';
|
|
30393
30397
|
var IMPORT = '@import';
|
|
30394
30398
|
var KEYFRAMES = '@keyframes';
|
|
30399
|
+
var LAYER = '@layer';
|
|
30395
30400
|
|
|
30396
30401
|
/**
|
|
30397
30402
|
* @param {number}
|
|
@@ -30806,7 +30811,7 @@ function parse (value, root, parent, rule, rules, rulesets, pseudo, points, decl
|
|
|
30806
30811
|
// \0 }
|
|
30807
30812
|
case 0: case 125: scanning = 0;
|
|
30808
30813
|
// ;
|
|
30809
|
-
case 59 + offset:
|
|
30814
|
+
case 59 + offset: if (ampersand == -1) characters = replace(characters, /\f/g, '');
|
|
30810
30815
|
if (property > 0 && (strlen(characters) - length))
|
|
30811
30816
|
append(property > 32 ? declaration(characters + ';', rule, parent, length - 1) : declaration(replace(characters, ' ', '') + ';', rule, parent, length - 2), declarations);
|
|
30812
30817
|
break
|
|
@@ -30821,8 +30826,8 @@ function parse (value, root, parent, rule, rules, rulesets, pseudo, points, decl
|
|
|
30821
30826
|
parse(characters, root, reference, reference, props, rulesets, length, points, children);
|
|
30822
30827
|
else
|
|
30823
30828
|
switch (atrule === 99 && charat(characters, 3) === 110 ? 100 : atrule) {
|
|
30824
|
-
// d m s
|
|
30825
|
-
case 100: case 109: case 115:
|
|
30829
|
+
// d l m s
|
|
30830
|
+
case 100: case 108: case 109: case 115:
|
|
30826
30831
|
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);
|
|
30827
30832
|
break
|
|
30828
30833
|
default:
|
|
@@ -30941,6 +30946,7 @@ function serialize (children, callback) {
|
|
|
30941
30946
|
*/
|
|
30942
30947
|
function stringify (element, index, children, callback) {
|
|
30943
30948
|
switch (element.type) {
|
|
30949
|
+
case LAYER: if (element.children.length) break
|
|
30944
30950
|
case IMPORT: case DECLARATION: return element.return = element.return || element.value
|
|
30945
30951
|
case COMMENT: return ''
|
|
30946
30952
|
case KEYFRAMES: return element.return = element.value + '{' + serialize(element.children, callback) + '}'
|
|
@@ -31752,6 +31758,7 @@ function murmur2(str) {
|
|
|
31752
31758
|
|
|
31753
31759
|
var unitlessKeys = {
|
|
31754
31760
|
animationIterationCount: 1,
|
|
31761
|
+
aspectRatio: 1,
|
|
31755
31762
|
borderImageOutset: 1,
|
|
31756
31763
|
borderImageSlice: 1,
|
|
31757
31764
|
borderImageWidth: 1,
|
|
@@ -32122,7 +32129,7 @@ var useInsertionEffectAlwaysWithSyncFallback = !isBrowser$1 ? syncFallback : use
|
|
|
32122
32129
|
var isBrowser = typeof document !== 'undefined';
|
|
32123
32130
|
var hasOwnProperty = {}.hasOwnProperty;
|
|
32124
32131
|
|
|
32125
|
-
var EmotionCacheContext = /* #__PURE__ */createContext( // we're doing this to avoid preconstruct's dead code elimination in this one case
|
|
32132
|
+
var EmotionCacheContext = /* #__PURE__ */React.createContext( // we're doing this to avoid preconstruct's dead code elimination in this one case
|
|
32126
32133
|
// because this module is primarily intended for the browser and node
|
|
32127
32134
|
// but it's also required in react native and similar environments sometimes
|
|
32128
32135
|
// and we could have a special build just for that
|
|
@@ -32161,7 +32168,7 @@ if (!isBrowser) {
|
|
|
32161
32168
|
cache = createCache({
|
|
32162
32169
|
key: 'css'
|
|
32163
32170
|
});
|
|
32164
|
-
return /*#__PURE__*/createElement(EmotionCacheContext.Provider, {
|
|
32171
|
+
return /*#__PURE__*/React.createElement(EmotionCacheContext.Provider, {
|
|
32165
32172
|
value: cache
|
|
32166
32173
|
}, func(props, cache));
|
|
32167
32174
|
} else {
|
|
@@ -32171,14 +32178,14 @@ if (!isBrowser) {
|
|
|
32171
32178
|
};
|
|
32172
32179
|
}
|
|
32173
32180
|
|
|
32174
|
-
var ThemeContext = /* #__PURE__ */createContext({});
|
|
32181
|
+
var ThemeContext = /* #__PURE__ */React.createContext({});
|
|
32175
32182
|
|
|
32176
32183
|
if (process.env.NODE_ENV !== 'production') {
|
|
32177
32184
|
ThemeContext.displayName = 'EmotionThemeContext';
|
|
32178
32185
|
}
|
|
32179
32186
|
|
|
32180
32187
|
var useTheme = function useTheme() {
|
|
32181
|
-
return useContext(ThemeContext);
|
|
32188
|
+
return React.useContext(ThemeContext);
|
|
32182
32189
|
};
|
|
32183
32190
|
|
|
32184
32191
|
var typePropName = '__EMOTION_TYPE_PLEASE_DO_NOT_USE__';
|
|
@@ -32204,7 +32211,7 @@ var Insertion = function Insertion(_ref) {
|
|
|
32204
32211
|
next = next.next;
|
|
32205
32212
|
}
|
|
32206
32213
|
|
|
32207
|
-
return /*#__PURE__*/createElement("style", (_ref2 = {}, _ref2["data-emotion"] = cache.key + " " + serializedNames, _ref2.dangerouslySetInnerHTML = {
|
|
32214
|
+
return /*#__PURE__*/React.createElement("style", (_ref2 = {}, _ref2["data-emotion"] = cache.key + " " + serializedNames, _ref2.dangerouslySetInnerHTML = {
|
|
32208
32215
|
__html: rules
|
|
32209
32216
|
}, _ref2.nonce = cache.sheet.nonce, _ref2));
|
|
32210
32217
|
}
|
|
@@ -32231,7 +32238,7 @@ var Emotion = /* #__PURE__ */withEmotionCache(function (props, cache, ref) {
|
|
|
32231
32238
|
className = props.className + " ";
|
|
32232
32239
|
}
|
|
32233
32240
|
|
|
32234
|
-
var serialized = serializeStyles(registeredStyles, undefined, useContext(ThemeContext));
|
|
32241
|
+
var serialized = serializeStyles(registeredStyles, undefined, React.useContext(ThemeContext));
|
|
32235
32242
|
|
|
32236
32243
|
if (process.env.NODE_ENV !== 'production' && serialized.name.indexOf('-') === -1) {
|
|
32237
32244
|
var labelFromStack = props[labelPropName];
|
|
@@ -32252,11 +32259,11 @@ var Emotion = /* #__PURE__ */withEmotionCache(function (props, cache, ref) {
|
|
|
32252
32259
|
|
|
32253
32260
|
newProps.ref = ref;
|
|
32254
32261
|
newProps.className = className;
|
|
32255
|
-
return /*#__PURE__*/createElement(Fragment, null, /*#__PURE__*/createElement(Insertion, {
|
|
32262
|
+
return /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement(Insertion, {
|
|
32256
32263
|
cache: cache,
|
|
32257
32264
|
serialized: serialized,
|
|
32258
32265
|
isStringTag: typeof WrappedComponent === 'string'
|
|
32259
|
-
}), /*#__PURE__*/createElement(WrappedComponent, newProps));
|
|
32266
|
+
}), /*#__PURE__*/React.createElement(WrappedComponent, newProps));
|
|
32260
32267
|
});
|
|
32261
32268
|
|
|
32262
32269
|
if (process.env.NODE_ENV !== 'production') {
|
package/package.json
CHANGED
|
@@ -1,35 +1,34 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@opengeoweb/taf",
|
|
3
|
-
"version": "6.0.
|
|
3
|
+
"version": "6.0.2",
|
|
4
4
|
"description": "GeoWeb TAF 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
|
-
"
|
|
12
|
+
"main": "./index.esm.js",
|
|
14
13
|
"dependencies": {},
|
|
15
14
|
"peerDependencies": {
|
|
16
|
-
"@emotion/react": "11.
|
|
15
|
+
"@emotion/react": "11.11.1",
|
|
17
16
|
"@mui/material": "5.12.0",
|
|
18
|
-
"@opengeoweb/api": "6.0.
|
|
19
|
-
"@opengeoweb/authentication": "6.0.
|
|
20
|
-
"@opengeoweb/core": "6.0.
|
|
21
|
-
"@opengeoweb/form-fields": "6.0.
|
|
22
|
-
"@opengeoweb/shared": "6.0.
|
|
23
|
-
"@opengeoweb/store": "6.0.
|
|
24
|
-
"@opengeoweb/theme": "6.0.
|
|
17
|
+
"@opengeoweb/api": "6.0.2",
|
|
18
|
+
"@opengeoweb/authentication": "6.0.2",
|
|
19
|
+
"@opengeoweb/core": "6.0.2",
|
|
20
|
+
"@opengeoweb/form-fields": "6.0.2",
|
|
21
|
+
"@opengeoweb/shared": "6.0.2",
|
|
22
|
+
"@opengeoweb/store": "6.0.2",
|
|
23
|
+
"@opengeoweb/theme": "6.0.2",
|
|
25
24
|
"@reduxjs/toolkit": "1.9.5",
|
|
26
|
-
"axios": "1.
|
|
25
|
+
"axios": "1.4.0",
|
|
27
26
|
"lodash": "4.17.21",
|
|
28
27
|
"moment": "2.29.4",
|
|
29
28
|
"react": "18.2.0",
|
|
30
29
|
"react-dom": "18.2.0",
|
|
31
|
-
"react-hook-form": "7.45.
|
|
32
|
-
"react-redux": "8.1.
|
|
30
|
+
"react-hook-form": "7.45.4",
|
|
31
|
+
"react-redux": "8.1.2",
|
|
33
32
|
"react-sortablejs": "6.1.4",
|
|
34
33
|
"sortablejs": "1.15.0"
|
|
35
34
|
}
|
|
@@ -16,7 +16,7 @@ export declare const tafScreenPreset: {
|
|
|
16
16
|
syncGroups: never[];
|
|
17
17
|
mosaicNode: string;
|
|
18
18
|
};
|
|
19
|
-
|
|
19
|
+
type TafComponentType = 'TafModule';
|
|
20
20
|
export interface ComponentsLookUpPayload {
|
|
21
21
|
componentType: TafComponentType;
|
|
22
22
|
id: string;
|
|
@@ -2,7 +2,7 @@ import { TextFieldProps } from '@mui/material';
|
|
|
2
2
|
import React from 'react';
|
|
3
3
|
import { RegisterOptions } from 'react-hook-form';
|
|
4
4
|
export declare const getDisplayValue: (value: string, disabled: boolean) => string;
|
|
5
|
-
|
|
5
|
+
type BaseTextFieldProps = TextFieldProps & {
|
|
6
6
|
shouldPreventUppercase?: boolean;
|
|
7
7
|
};
|
|
8
8
|
export declare const BaseTextField: React.FC<BaseTextFieldProps>;
|
|
@@ -19,9 +19,9 @@ export declare const emptyBaseForecast: {
|
|
|
19
19
|
};
|
|
20
20
|
export declare const MIN_NUMBER_CHANGE_GROUP = 5;
|
|
21
21
|
export declare const formatIssueTime: (issueDate: string) => string;
|
|
22
|
-
|
|
22
|
+
type BaseForecastOrChangeGroupFormData<T extends BaseForecast | ChangeGroup> = T extends ChangeGroup ? ChangeGroupFormData : BaseForecastFormData;
|
|
23
23
|
export declare function formatFormValues<T extends BaseForecast | ChangeGroup>(row: T): BaseForecastOrChangeGroupFormData<T>;
|
|
24
|
-
|
|
24
|
+
type BaseForecastOrChangeGroup<T extends BaseForecastFormData | ChangeGroupFormData> = T extends ChangeGroupFormData ? ChangeGroup : BaseForecast;
|
|
25
25
|
export declare function parseFormValues<T extends ChangeGroupFormData | BaseForecastFormData>(row: T, tafStart: string, tafEnd: string): BaseForecastOrChangeGroup<T>;
|
|
26
26
|
export declare const convertTafValuesToObject: (formData: TafFormData) => Taf;
|
|
27
27
|
export declare const shouldRetrieveTAC: (product: Taf) => boolean;
|
|
@@ -31,14 +31,14 @@ export declare const TAC_NOT_AVAILABLE = "No TAC available";
|
|
|
31
31
|
export declare const TAC_RETRIEVING_DATA = "Retrieving TAC";
|
|
32
32
|
export declare const TAC_FAILED = "Failed to retrieve TAC";
|
|
33
33
|
export declare const tacHasError: (tac: TAC) => boolean;
|
|
34
|
-
export declare const useTACGenerator: (taf: Taf, requestTAC: (postTaf: Taf, getJSON?: boolean
|
|
34
|
+
export declare const useTACGenerator: (taf: Taf, requestTAC: (postTaf: Taf, getJSON?: boolean, abortSignal?: AbortSignal) => Promise<{
|
|
35
35
|
data: TAC;
|
|
36
36
|
}>, getJSON?: boolean) => [TAC, (tafToPost: Taf) => void, (newTAC: TAC) => void];
|
|
37
|
-
export
|
|
37
|
+
export type SortableField = {
|
|
38
38
|
id: string;
|
|
39
39
|
chosen: boolean;
|
|
40
40
|
};
|
|
41
|
-
export declare const useDragOrder: (trigger: (name?: string | string[]
|
|
41
|
+
export declare const useDragOrder: (trigger: (name?: string | string[]) => Promise<boolean>, move: (oldIndex: number, newIndex: number) => void) => {
|
|
42
42
|
onChangeOrder: (event: Sortable.SortableEvent) => void;
|
|
43
43
|
onStartDrag: (event: Sortable.SortableEvent) => void;
|
|
44
44
|
activeDraggingIndex: number | boolean;
|
|
@@ -65,7 +65,7 @@ export declare const emptyChangegroup: {
|
|
|
65
65
|
change: string;
|
|
66
66
|
probability: string;
|
|
67
67
|
};
|
|
68
|
-
export declare const getTafStatusLabel: (status: TafStatus, action?: TafActions
|
|
68
|
+
export declare const getTafStatusLabel: (status: TafStatus, action?: TafActions, isFormDisabled?: boolean) => string;
|
|
69
69
|
export declare const getMessageType: (taf: Taf, tafAction: TafActions) => string;
|
|
70
70
|
export declare const getAmendedCorrectedTafTimes: (taf: Taf, tafAction: TafActions) => Taf;
|
|
71
71
|
export declare const createChangeGroup: (changeGroup: ChangeGroupFormData) => ChangeGroupFormData;
|
|
@@ -3,7 +3,7 @@ import { AxiosError } from 'axios';
|
|
|
3
3
|
import { TafFromBackend, Taf, TafActions, TafStatus, TafFromFrontEnd } from '../../../types';
|
|
4
4
|
import { IssuesPanePosition } from '../../IssuesPane/types';
|
|
5
5
|
export declare const fromActionToStatus: (tafAction: TafActions) => TafStatus;
|
|
6
|
-
export
|
|
6
|
+
export type TafError = {
|
|
7
7
|
type: 'CANCELLED' | 'SERVER' | 'WARNING';
|
|
8
8
|
title: string;
|
|
9
9
|
message?: string;
|
|
@@ -8,7 +8,7 @@ export declare const getBaseTime: (baseTime: string, location: string) => {
|
|
|
8
8
|
nextBaseTime: Moment;
|
|
9
9
|
};
|
|
10
10
|
export declare const getTafTimeSlot: (baseTime: string, location: string, status: TafStatus) => TimeSlot;
|
|
11
|
-
|
|
11
|
+
type TafTimeSlots = {
|
|
12
12
|
current: TafFromBackend[];
|
|
13
13
|
upcoming: TafFromBackend[];
|
|
14
14
|
expired: TafFromBackend[];
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
2
|
import { BaseTaf, TafActions } from '../../types';
|
|
3
|
-
|
|
3
|
+
type ValidateFormPromise = () => Promise<void | BaseTaf>;
|
|
4
4
|
interface TafModuleMethods {
|
|
5
5
|
onPreventCloseView?: (shouldPreventClose: boolean) => void;
|
|
6
6
|
}
|
package/src/lib/types.d.ts
CHANGED
|
@@ -9,20 +9,20 @@ export interface Wind {
|
|
|
9
9
|
gust?: number | string;
|
|
10
10
|
unit: 'KT';
|
|
11
11
|
}
|
|
12
|
-
export
|
|
12
|
+
export type NSW = 'NSW';
|
|
13
13
|
export interface Weather {
|
|
14
14
|
weather1: WeatherPhenomena | NSW;
|
|
15
15
|
weather2?: WeatherPhenomena | NSW;
|
|
16
16
|
weather3?: WeatherPhenomena | NSW;
|
|
17
17
|
}
|
|
18
|
-
export
|
|
19
|
-
export
|
|
18
|
+
export type CloudCoverage = 'FEW' | 'SCT' | 'BKN' | 'OVC';
|
|
19
|
+
export type CloudType = 'CB' | 'TCU';
|
|
20
20
|
export interface Cloud {
|
|
21
21
|
coverage: CloudCoverage;
|
|
22
22
|
height: number;
|
|
23
23
|
type?: CloudType;
|
|
24
24
|
}
|
|
25
|
-
export
|
|
25
|
+
export type NSC = 'NSC';
|
|
26
26
|
export interface VerticalVisibility {
|
|
27
27
|
verticalVisibility: number;
|
|
28
28
|
}
|
|
@@ -32,7 +32,7 @@ export interface Clouds {
|
|
|
32
32
|
cloud3?: Cloud;
|
|
33
33
|
cloud4?: Cloud;
|
|
34
34
|
}
|
|
35
|
-
export
|
|
35
|
+
export type TafDate = string;
|
|
36
36
|
export interface Valid {
|
|
37
37
|
start: TafDate;
|
|
38
38
|
end?: TafDate;
|
|
@@ -45,13 +45,13 @@ export interface BaseForecast {
|
|
|
45
45
|
cloud?: Clouds;
|
|
46
46
|
cavOK?: boolean;
|
|
47
47
|
}
|
|
48
|
-
export
|
|
48
|
+
export type Change = 'TEMPO' | 'BECMG' | 'FM';
|
|
49
49
|
export interface ChangeGroup extends BaseForecast {
|
|
50
50
|
change: Change;
|
|
51
51
|
probability?: 'PROB30' | 'PROB40';
|
|
52
52
|
}
|
|
53
|
-
export
|
|
54
|
-
export
|
|
53
|
+
export type MessageType = 'ORG' | 'AMD' | 'COR' | 'CNL';
|
|
54
|
+
export type Location = 'EHAM' | 'EHRD' | 'EHGG' | 'EHBK' | 'EHLE' | 'TNCB';
|
|
55
55
|
export interface BaseTaf {
|
|
56
56
|
validDateStart: TafDate;
|
|
57
57
|
validDateEnd: TafDate;
|
|
@@ -66,9 +66,9 @@ export interface BaseTaf {
|
|
|
66
66
|
uuid: string;
|
|
67
67
|
issueDate?: TafDate;
|
|
68
68
|
}
|
|
69
|
-
export
|
|
70
|
-
export
|
|
71
|
-
export
|
|
69
|
+
export type TafStatus = 'NEW' | 'DRAFT' | 'DRAFT_AMENDED' | 'DRAFT_CORRECTED' | 'PUBLISHED' | 'CORRECTED' | 'AMENDED' | 'CANCELLED' | 'EXPIRED';
|
|
70
|
+
export type TafActions = 'NEW' | 'DRAFT' | 'DRAFT_AMEND' | 'DRAFT_CORRECT' | 'PUBLISH' | 'CANCEL' | 'CORRECT' | 'AMEND' | 'CLOSE' | 'CLEAR';
|
|
71
|
+
export type TafCanbe = 'DRAFTED' | 'DISCARDED' | 'PUBLISHED' | 'CANCELLED' | 'AMENDED' | 'CORRECTED';
|
|
72
72
|
export interface Taf extends BaseTaf {
|
|
73
73
|
status: TafStatus;
|
|
74
74
|
}
|
|
@@ -129,22 +129,22 @@ export interface TafFromFrontEnd {
|
|
|
129
129
|
/**
|
|
130
130
|
* TAF (json) settings (libs/taf/src/lib/utils/tafConfig.json)
|
|
131
131
|
*/
|
|
132
|
-
export
|
|
132
|
+
export type TafConfigLocation = {
|
|
133
133
|
validity_duration: number;
|
|
134
134
|
activity_period: number;
|
|
135
135
|
label: string;
|
|
136
136
|
};
|
|
137
|
-
export
|
|
137
|
+
export type TafConfigLocations = Record<string, TafConfigLocation>;
|
|
138
138
|
export interface TafConfig {
|
|
139
139
|
location_indicator_mwo: string;
|
|
140
140
|
locations: TafConfigLocations;
|
|
141
141
|
locationOrder: string[];
|
|
142
142
|
}
|
|
143
|
-
export
|
|
144
|
-
export
|
|
143
|
+
export type TimeSlot = 'UPCOMING' | 'ACTIVE' | 'EXPIRED';
|
|
144
|
+
export type AdverseWeatherTAC = {
|
|
145
145
|
tac: {
|
|
146
146
|
text: string;
|
|
147
147
|
type?: string;
|
|
148
148
|
}[][];
|
|
149
149
|
};
|
|
150
|
-
export
|
|
150
|
+
export type TAC = string | AdverseWeatherTAC;
|
package/src/lib/utils/api.d.ts
CHANGED