@opengeoweb/warnings 11.0.0 → 12.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.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@opengeoweb/warnings",
3
- "version": "11.0.0",
3
+ "version": "12.0.0",
4
4
  "description": "GeoWeb warinings library for the opengeoweb project",
5
5
  "license": "Apache-2.0",
6
6
  "repository": {
@@ -8,34 +8,45 @@
8
8
  "url": "git@gitlab.com:opengeoweb/opengeoweb.git"
9
9
  },
10
10
  "dependencies": {
11
- "@opengeoweb/api": "*",
12
- "@opengeoweb/shared": "*",
13
- "@opengeoweb/store": "*",
14
- "@opengeoweb/webmap-react": "*",
15
- "@tanstack/react-query": "^5.52.1",
16
- "react-redux": "^8.1.3",
17
- "@opengeoweb/theme": "*",
18
- "@opengeoweb/form-fields": "*",
19
- "react-hook-form": "^7.50.1",
20
- "lodash": "^4.17.21",
11
+ "@emotion/react": "11.14.0",
12
+ "@emotion/styled": "11.14.0",
13
+ "@mui/material": "^6.1.1",
14
+ "@mui/system": "6.4.6",
15
+ "@mui/x-date-pickers": "7.27.1",
21
16
  "@reduxjs/toolkit": "^1.9.7",
22
- "@opengeoweb/snackbar": "*",
23
- "react-window": "^1.8.10",
24
- "react-virtualized-auto-sizer": "^1.0.20",
17
+ "@sentry/react": "8.54.0",
18
+ "@storybook/core-events": "8.4.2",
19
+ "@storybook/preview-api": "8.4.2",
20
+ "@storybook/react": "8.4.2",
21
+ "@tanstack/query-core": "5.67.1",
22
+ "@tanstack/react-query": "^5.52.1",
23
+ "@testing-library/react": "16.0.1",
24
+ "@testing-library/user-event": "14.5.2",
25
+ "@turf/turf": "7.2.0",
25
26
  "axios": "^1.7.7",
26
- "@opengeoweb/core": "*",
27
- "@opengeoweb/webmap": "*",
28
- "@opengeoweb/authentication": "*",
29
- "@opengeoweb/sigmet-airmet": "*",
30
- "react-i18next": "^15.1.1",
27
+ "date-fns": "4.1.0",
28
+ "dompurify": "3.2.4",
31
29
  "i18next": "^23.11.5",
32
- "@mui/material": "^6.1.1",
33
- "msw": "^1.3.3"
34
- },
35
- "peerDependencies": {
36
- "react": "18",
37
- "@emotion/react": "*",
38
- "@emotion/styled": "*"
30
+ "immer": "10.1.1",
31
+ "jest-canvas-mock": "2.5.2",
32
+ "jest-date-mock": "1.0.10",
33
+ "lodash": "^4.17.21",
34
+ "msw": "^2.7.3",
35
+ "msw-storybook-addon": "2.0.4",
36
+ "ol": "^10.4.0",
37
+ "proj4": "2.15.0",
38
+ "re-resizable": "6.11.2",
39
+ "react": "18.3.1",
40
+ "react-draggable": "4.4.6",
41
+ "react-hook-form": "^7.50.1",
42
+ "react-i18next": "^15.1.1",
43
+ "react-redux": "^8.1.3",
44
+ "react-resize-detector": "9.1.1",
45
+ "react-router-dom": "6.23.1",
46
+ "react-sortablejs": "6.1.4",
47
+ "react-virtualized-auto-sizer": "^1.0.20",
48
+ "react-window": "^1.8.10",
49
+ "sortablejs": "1.15.2"
39
50
  },
40
51
  "module": "./index.esm.js",
41
52
  "type": "module",
@@ -1,3 +1,3 @@
1
1
  export declare const fakeSigmetTAC = "EHAA SIGMET 1 VALID 121249/121449 EHDB- EHAA AMSTERDAM FIR FRQ TS OBS ENTIRE FIR FL010 STNR WKN";
2
2
  export declare const fakeAirmetTAC = "EHAA AIRMET -1 VALID 310700/311100 EHDB- EHAA AMSTERDAM FIR ISOL CB OBS ENTIRE FIR FL020 STNR NC";
3
- export declare const aviationEndpoints: import("msw").RestHandler<import("msw").MockedRequest<import("msw").DefaultBodyType>>[];
3
+ export declare const aviationEndpoints: import("msw").HttpHandler[];
@@ -0,0 +1 @@
1
+ export {};
@@ -1,4 +1,6 @@
1
1
  import { Credentials } from '@opengeoweb/authentication';
2
2
  import { PublicWarning } from '../../store/publicWarningForm/types';
3
3
  export declare const getPublicWarningList: (auth: Credentials) => Promise<PublicWarning[]>;
4
- export declare const updatePublicWarningEditor: (warningId: string, isEditor: boolean, auth: Credentials) => Promise<object>;
4
+ export declare const updatePublicWarningEditor: (warningId: string, isEditor: boolean, auth: Credentials) => Promise<Headers | null>;
5
+ export declare const updatePublicWarning: (warningId: string, auth: Credentials, data: PublicWarning) => Promise<Headers | null>;
6
+ export declare const postPublicWarning: (auth: Credentials, data: PublicWarning) => Promise<Headers | null>;
@@ -5,11 +5,20 @@ import { PublicWarning } from '../../store/publicWarningForm/types';
5
5
  * https://tanstack.com/query/v4/docs/framework/react/guides/disabling-queries
6
6
  */
7
7
  export declare const usePublicWarnings: (disabled?: boolean) => UseQueryResult<PublicWarning[]>;
8
- interface MutateProps {
8
+ type MutationReturnType<T> = UseMutationResult<Headers | null, Error, T, {
9
+ oldData: PublicWarning[] | undefined;
10
+ }>;
11
+ interface MutateEditorProps {
9
12
  id: string;
10
13
  isEditor: boolean;
11
14
  }
12
- export declare const useMutatePublicWarningEditor: () => UseMutationResult<object, Error, MutateProps, {
13
- oldData: PublicWarning[] | undefined;
14
- }>;
15
+ export declare const useMutatePublicWarningEditor: () => MutationReturnType<MutateEditorProps>;
16
+ interface UpdateWarningProps {
17
+ id?: string;
18
+ data: PublicWarning;
19
+ panelId?: string;
20
+ }
21
+ export declare const useMutateWarning: (snackBarMessage: string) => MutationReturnType<UpdateWarningProps>;
22
+ export declare const usePublishWarning: () => MutationReturnType<UpdateWarningProps>;
23
+ export declare const useSaveWarning: () => MutationReturnType<UpdateWarningProps>;
15
24
  export {};
@@ -1,6 +1,5 @@
1
- import { SystemScope } from '@opengeoweb/shared';
2
1
  import { Warning } from '../../store/publicWarningForm/types';
3
- import { defaultDomainFilter, defaultEmptyFilter, defaultLevelFilter, defaultPhenomenonFilter } from './filter-utils';
2
+ import { AllPhenomenaKeys, defaultDomainFilter, defaultEmptyFilter, defaultLevelFilter, defaultPhenomenonFilter, Domain } from './filter-utils';
4
3
  export interface PickedFilterState {
5
4
  incident: Partial<typeof defaultEmptyFilter>;
6
5
  source: Partial<typeof defaultEmptyFilter>;
@@ -8,7 +7,7 @@ export interface PickedFilterState {
8
7
  phenomenon: Partial<typeof defaultPhenomenonFilter>;
9
8
  level: Partial<typeof defaultLevelFilter>;
10
9
  }
11
- interface FilterState extends PickedFilterState {
10
+ export interface FilterState extends PickedFilterState {
12
11
  incident: typeof defaultEmptyFilter;
13
12
  source: typeof defaultEmptyFilter;
14
13
  domain: typeof defaultDomainFilter;
@@ -24,5 +23,5 @@ export interface FilterHookState {
24
23
  byFilterState: (warning: Warning) => boolean;
25
24
  filterState: PickedFilterState;
26
25
  }
27
- export declare const useWarningFilters: (warnings: Warning[], onUpdateFilters: (filterState: PickedFilterState, origin: SystemScope) => void, savedFilterState: PickedFilterState, presetFilterState?: PickedFilterState) => FilterHookState;
28
- export {};
26
+ export declare const getPhenomenaForDomainFilter: (domainFilter: Record<Domain, boolean>) => (keyof typeof AllPhenomenaKeys)[];
27
+ export declare const useWarningFilters: (warnings: Warning[], onUpdateFilters: (filterState: Partial<FilterState>, systemUpdate?: boolean) => void, savedFilterState: FilterState, presetFilterState?: PickedFilterState) => FilterHookState;
@@ -26,7 +26,7 @@ export declare const defaultDomainFilter: Record<Domain, boolean>;
26
26
  export declare const domainLevels: Record<Domain, Level[]>;
27
27
  export declare const defaultLevelFilter: Record<Level | 'unspecified', boolean>;
28
28
  export declare const defaultEmptyFilter: Record<string, boolean>;
29
- export declare const makeFilterFromList: <T extends string>(options: T[]) => Record<T | 'unspecified', boolean>;
29
+ export declare const makeFilterFromList: <T extends string>(options: T[], value?: boolean) => Record<T | 'unspecified', boolean>;
30
30
  export declare const AllPhenomenaKeys: Record<"wind" | "fog" | "thunderstorm" | "snowIce" | "rain" | "highTemp" | "lowTemp" | "coastalEvent" | "EMBD_TS" | "EMBD_TSGR" | "FRQ_TS" | "FRQ_TSGR" | "HVY_DS" | "HVY_SS" | "OBSC_TS" | "OBSC_TSGR" | "RDOACT_CLD" | "SEV_ICE" | "SEV_ICE_FRZ_RN" | "SEV_MTW" | "SEV_TURB" | "SQL_TS" | "SQL_TSGR" | "VA_CLD" | "SFC_VIS" | "SFC_WIND" | "OVC_CLD" | "BKN_CLD" | "ISOL_CB" | "OCNL_CB" | "FRQ_CB" | "ISOL_TS" | "OCNL_TS" | "ISOL_TSGR" | "OCNL_TSGR" | "ISOL_TCU" | "OCNL_TCU" | "FRQ_TCU" | "MOD_ICE" | "MOD_MTW" | "MOD_TURB" | "MT_OBSC", "wind" | "fog" | "thunderstorm" | "snowIce" | "rain" | "highTemp" | "lowTemp" | "coastalEvent" | "EMBD_TS" | "EMBD_TSGR" | "FRQ_TS" | "FRQ_TSGR" | "HVY_DS" | "HVY_SS" | "OBSC_TS" | "OBSC_TSGR" | "RDOACT_CLD" | "SEV_ICE" | "SEV_ICE_FRZ_RN" | "SEV_MTW" | "SEV_TURB" | "SQL_TS" | "SQL_TSGR" | "VA_CLD" | "SFC_VIS" | "SFC_WIND" | "OVC_CLD" | "BKN_CLD" | "ISOL_CB" | "OCNL_CB" | "FRQ_CB" | "ISOL_TS" | "OCNL_TS" | "ISOL_TSGR" | "OCNL_TSGR" | "ISOL_TCU" | "OCNL_TCU" | "FRQ_TCU" | "MOD_ICE" | "MOD_MTW" | "MOD_TURB" | "MT_OBSC">;
31
31
  export declare const domainPhenomena: Record<Domain, Partial<keyof typeof AllPhenomenaKeys>[]>;
32
32
  export declare const defaultPhenomenonFilter: Record<string, boolean>;
@@ -44,8 +44,8 @@ interface OptionsMetadata {
44
44
  /** Whether or not all options are selected */
45
45
  allSelected: boolean;
46
46
  }
47
- export declare const getSelectedOptions: (options: OptionsType) => OptionsMetadata;
48
- export declare const updateState: <T extends string>(state: Partial<Record<T, boolean>>, optionKey: T | 'ALL', value: boolean, only?: boolean) => Record<T, boolean>;
47
+ export declare const getSelectedOptions: (options?: OptionsType) => OptionsMetadata;
48
+ export declare const updateState: <T extends string>(state: Record<T, boolean>, optionKey: T | 'ALL', value: boolean, only?: boolean) => Record<T, boolean>;
49
49
  /** Make sure our value is in the filter */
50
50
  export declare const getValue: <T>(values: Record<string, T>, value: string) => T | 'unspecified';
51
51
  export declare const getFiltersFromWarnings: (warnings: Warning[], filterKey: string) => string[];
@@ -11,7 +11,7 @@ export declare const ListError: {
11
11
  parameters: {
12
12
  msw: {
13
13
  handlers: {
14
- warnings: import("msw").RestHandler<import("msw").MockedRequest<import("msw").DefaultBodyType>>;
14
+ warnings: import("msw").HttpHandler[];
15
15
  };
16
16
  };
17
17
  };
@@ -23,7 +23,7 @@ export declare const EditorChanged: {
23
23
  parameters: {
24
24
  msw: {
25
25
  handlers: {
26
- warnings: import("msw").RestHandler<import("msw").MockedRequest<import("msw").DefaultBodyType>>[];
26
+ warnings: import("msw").HttpHandler[];
27
27
  };
28
28
  };
29
29
  };
@@ -36,7 +36,7 @@ export declare const ExtraLongList: {
36
36
  parameters: {
37
37
  msw: {
38
38
  handlers: {
39
- warnings: import("msw").RestHandler<import("msw").MockedRequest<import("msw").DefaultBodyType>>;
39
+ warnings: (import("msw").HttpHandler | import("msw").RequestHandler<import("msw/lib/core/HttpResponse-Cy7ytzUn").g, any, any, import("msw").RequestHandlerOptions>)[];
40
40
  };
41
41
  };
42
42
  };
@@ -2,10 +2,10 @@ import * as React from 'react';
2
2
  import { AviationProduct, FormMode } from '@opengeoweb/sigmet-airmet';
3
3
  import { FeatureCollection, GeoJsonProperties, Geometry } from 'geojson';
4
4
  import { MapPreset } from '@opengeoweb/store';
5
- import { PublicWarningDetail, WarningType } from '../../store/publicWarningForm/types';
5
+ import { Area, PublicWarningDetail, WarningType } from '../../store/publicWarningForm/types';
6
6
  import { BaseDrawingListItem, DrawingListItem } from '../../store/warningsDrawings/types';
7
7
  import { WarningLevel } from './LevelField';
8
- import { FormAction, FormError } from '../../store/publicWarningForm/reducer';
8
+ import { FormError } from '../../store/publicWarningForm/reducer';
9
9
  export declare const useScrollTopOnError: (error: FormError) => React.RefObject<HTMLDivElement>;
10
10
  export declare const getEmptyPublicWarning: () => PublicWarningDetail;
11
11
  export declare const getFormData: (publicWarningsDetails: PublicWarningDetail | undefined, object?: DrawingListItem) => FormData;
@@ -16,10 +16,9 @@ interface FormData extends PublicWarningDetail {
16
16
  }
17
17
  export declare const prepareFormValues: (data: FormData) => PublicWarningDetail;
18
18
  export interface FormProps {
19
- formAction?: FormAction;
20
19
  defaultMapPreset?: MapPreset;
21
- onSaveForm?: (formValues: PublicWarningDetail) => void;
22
- onPublishForm?: (formValues: PublicWarningDetail) => void;
20
+ onSaveForm?: (formValues: PublicWarningDetail) => Promise<Headers | null>;
21
+ onPublishForm?: (formValues: PublicWarningDetail) => Promise<Headers | null>;
23
22
  onClearForm?: () => void;
24
23
  object?: DrawingListItem;
25
24
  publicWarningDetails?: PublicWarningDetail;
@@ -31,6 +30,7 @@ export interface FormProps {
31
30
  selectedAviationProduct?: AviationProduct;
32
31
  warningType?: WarningType;
33
32
  mode?: FormMode;
33
+ onSetViewModeResetArea?: (area: Area[]) => void;
34
34
  }
35
35
  export declare function warningLevelFeatureColors(level: WarningLevel | undefined, geoJSON: FeatureCollection<Geometry, GeoJsonProperties> | undefined, // Allow undefined
36
36
  isAviationWarning?: boolean): FeatureCollection<Geometry, GeoJsonProperties>;
@@ -1,32 +1,24 @@
1
1
  import * as React from 'react';
2
- declare const _default: {
3
- title: string;
4
- };
5
- export default _default;
6
- export declare const PublicWarningsFormDemo: {
7
- (): React.ReactElement;
8
- storyName: string;
9
- };
10
- export declare const PublicWarningsFormDemoDark: {
11
- (): React.ReactElement;
12
- storyName: string;
13
- };
14
- export declare const PublicWarningsEmptyFormDemo: {
15
- (): React.ReactElement;
16
- storyName: string;
17
- };
18
- export declare const PublicWarningsEmptyFormDemoDark: {
19
- (): React.ReactElement;
20
- storyName: string;
21
- };
22
- export declare const PublicWarningsSavingFormDemo: () => React.ReactElement;
23
- export declare const PublicWarningsSavingFormDemoDark: () => React.ReactElement;
24
- export declare const PublicWarningsErrorFormDemo: () => React.ReactElement;
25
- export declare const PublicWarningsErrorFormDemoDark: () => React.ReactElement;
26
- export declare const PublicWarningsReadOnlyFormDemo: () => React.ReactElement;
27
- export declare const PublicWarningsReadOnlyFormDemoDark: () => React.ReactElement;
28
- export declare const PublicWarningsDisabledFormDemo: () => React.ReactElement;
29
- export declare const PublicWarningsDisabledFormDemoDark: () => React.ReactElement;
2
+ import type { Meta, StoryObj } from '@storybook/react';
3
+ import { FormProps } from './PublicWarningsForm';
4
+ interface DemoProps {
5
+ formProps: FormProps;
6
+ darkMode: boolean;
7
+ isReadOnly: boolean;
8
+ error?: string;
9
+ }
10
+ export declare const PublicWarningsFormDemo: ({ formProps, darkMode, isReadOnly, error, }: DemoProps) => React.ReactElement;
11
+ type Story = StoryObj<typeof PublicWarningsFormDemo>;
12
+ declare const meta: Meta<typeof PublicWarningsFormDemo>;
13
+ export default meta;
14
+ export declare const LightMode: Story;
15
+ export declare const DarkMode: Story;
16
+ export declare const EmptyForm: Story;
17
+ export declare const EmptyFormDark: Story;
18
+ export declare const ErrorForm: Story;
19
+ export declare const ErrorFormDark: Story;
20
+ export declare const ReadOnlyForm: Story;
21
+ export declare const ReadOnlyFormDark: Story;
30
22
  export declare const PublicWarningsFormAirmetDraftLight: () => React.ReactElement;
31
23
  export declare const PublicWarningsFormAirmetDraftDark: () => React.ReactElement;
32
24
  export declare const PublicWarningsFormAirmetCancels: () => React.ReactElement;
@@ -8,6 +8,5 @@ export interface PublicWarningsFormConnectProps {
8
8
  warningType?: WarningType;
9
9
  mode?: FormMode;
10
10
  defaultMapPreset?: MapPreset;
11
- onFormSubmit?: () => void;
12
11
  }
13
12
  export declare const PublicWarningsFormConnect: React.FC<PublicWarningsFormConnectProps>;
@@ -1,7 +1,6 @@
1
1
  import * as React from 'react';
2
2
  import { FeatureCollection } from 'geojson';
3
3
  import { MapPreset } from '@opengeoweb/store';
4
- export declare const zoomToFeature: (mapId: string, geojsonFeature: FeatureCollection | undefined) => void;
5
4
  interface WarningsMapViewProps {
6
5
  geojsonFeature: FeatureCollection | undefined;
7
6
  defaultMapPreset?: MapPreset;
@@ -1,8 +1,7 @@
1
1
  import { PayloadAction, Draft } from '@reduxjs/toolkit';
2
2
  import { AlertColor } from '@mui/material';
3
- import { snackbarTypes } from '@opengeoweb/snackbar';
4
3
  import { DrawingListItem } from '../warningsDrawings/types';
5
- import { Area, PublicWarning, Warning, WarningType } from './types';
4
+ import { Area, Warning, WarningType } from './types';
6
5
  export type FormAction = '' | 'saving' | 'publishing' | 'readonly' | 'edit';
7
6
  export interface FormError {
8
7
  severity?: AlertColor;
@@ -40,22 +39,6 @@ export declare const publicWarningFormReducer: import("redux").Reducer<WarningFo
40
39
  warningType?: WarningType;
41
40
  panelId?: string;
42
41
  }>) => void;
43
- publishWarning: (draft: Draft<WarningFormState>, action: PayloadAction<{
44
- publicWarning: PublicWarning;
45
- refetchWarnings?: () => void;
46
- }>) => void;
47
- publishWarningSuccess: (draft: Draft<WarningFormState>, action: PayloadAction<{
48
- publicWarning: PublicWarning;
49
- message: snackbarTypes.SnackbarMessage;
50
- }>) => void;
51
- saveWarning: (draft: Draft<WarningFormState>, action: PayloadAction<{
52
- publicWarning: PublicWarning;
53
- refetchWarnings?: () => void;
54
- }>) => void;
55
- saveWarningSuccess: (draft: Draft<WarningFormState>, action: PayloadAction<{
56
- publicWarning: Warning;
57
- message: snackbarTypes.SnackbarMessage;
58
- }>) => void;
59
42
  setFormError: (draft: Draft<WarningFormState>, action: PayloadAction<FormError>) => void;
60
43
  removeFormError: (draft: Draft<WarningFormState>) => void;
61
44
  setFormDirty: (draft: Draft<WarningFormState>, action: PayloadAction<{
@@ -1,6 +1,11 @@
1
1
  import { WarningModuleStore } from '../types';
2
2
  import { WarningFormState } from './reducer';
3
3
  export declare const getPublicWarningStore: (store: WarningModuleStore) => WarningFormState;
4
+ export declare const selectPublicWarningState: ((state: WarningModuleStore) => WarningFormState) & import("reselect").OutputSelectorFields<(args_0: WarningFormState) => WarningFormState, {
5
+ clearCache: () => void;
6
+ }> & {
7
+ clearCache: () => void;
8
+ };
4
9
  export declare const getPublicWarningObject: ((state: WarningModuleStore) => import("../warningsDrawings/types").DrawingListItem | undefined) & import("reselect").OutputSelectorFields<(args_0: WarningFormState) => import("../warningsDrawings/types").DrawingListItem | undefined, {
5
10
  clearCache: () => void;
6
11
  }> & {
@@ -1,14 +1,13 @@
1
- import { SystemScope } from '@opengeoweb/shared';
2
1
  import { Draft, PayloadAction } from '@reduxjs/toolkit';
3
- import { PickedFilterState } from '../../components/FilterList/filter-hooks';
4
2
  import { Warning } from '../publicWarningForm/types';
5
3
  import { PublicWarningsState } from './types';
4
+ import { FilterState } from '../../components/FilterList/filter-hooks';
6
5
  export declare const publicWarningsAdapter: import("@reduxjs/toolkit").EntityAdapter<Warning>;
7
6
  export declare const initialState: PublicWarningsState;
8
7
  export declare const publicWarningsReducer: import("redux").Reducer<PublicWarningsState>, publicWarningActions: import("@reduxjs/toolkit").CaseReducerActions<{
9
8
  setWarningFilters: (draft: Draft<PublicWarningsState>, action: PayloadAction<{
10
- filterState: PickedFilterState;
9
+ filterState: Partial<FilterState>;
11
10
  panelId?: string;
12
- origin: SystemScope;
11
+ systemUpdate: boolean;
13
12
  }>) => void;
14
13
  }, "publicWarnings">;
@@ -1,5 +1,6 @@
1
1
  import { PublicWarningsState } from './types';
2
2
  import { WarningModuleStore } from '../types';
3
+ import { FilterState } from '../../components/FilterList/filter-hooks';
3
4
  export declare const getPublicWarningsStore: (store: WarningModuleStore) => PublicWarningsState;
4
5
  export declare const selectAllPublicWarnings: (state: WarningModuleStore) => import("../publicWarningForm/types").Warning[];
5
6
  export declare const isPublicWarningsLoading: ((state: WarningModuleStore) => boolean) & import("reselect").OutputSelectorFields<(args_0: PublicWarningsState) => boolean, {
@@ -17,7 +18,7 @@ export declare const getPublicWarningsLastUpdatedTime: ((state: WarningModuleSto
17
18
  }> & {
18
19
  clearCache: () => void;
19
20
  };
20
- export declare const getWarningsFilterById: ((state: WarningModuleStore, panelId?: string | undefined) => import("../../components/FilterList/filter-hooks").PickedFilterState) & import("reselect").OutputSelectorFields<(args_0: Record<string, import("../../components/FilterList/filter-hooks").PickedFilterState>, args_1: string | undefined) => import("../../components/FilterList/filter-hooks").PickedFilterState, {
21
+ export declare const getWarningsFilterById: ((state: WarningModuleStore, panelId?: string | undefined) => FilterState) & import("reselect").OutputSelectorFields<(args_0: Record<string, FilterState>, args_1: string | undefined) => FilterState, {
21
22
  clearCache: () => void;
22
23
  }> & {
23
24
  clearCache: () => void;
@@ -25,11 +26,11 @@ export declare const getWarningsFilterById: ((state: WarningModuleStore, panelId
25
26
  export declare const getWarningsPresetById: ((state: WarningModuleStore, panelId?: string | undefined) => {
26
27
  filterState: null;
27
28
  } | {
28
- filterState: import("../../components/FilterList/filter-hooks").PickedFilterState;
29
- }) & import("reselect").OutputSelectorFields<(args_0: Record<string, import("../../components/FilterList/filter-hooks").PickedFilterState>, args_1: string | undefined) => {
29
+ filterState: FilterState;
30
+ }) & import("reselect").OutputSelectorFields<(args_0: Record<string, FilterState>, args_1: string | undefined) => {
30
31
  filterState: null;
31
32
  } | {
32
- filterState: import("../../components/FilterList/filter-hooks").PickedFilterState;
33
+ filterState: FilterState;
33
34
  }, {
34
35
  clearCache: () => void;
35
36
  }> & {
@@ -1,6 +1,6 @@
1
1
  import { EntityState } from '@reduxjs/toolkit';
2
2
  import { Warning } from '../publicWarningForm/types';
3
- import { PickedFilterState } from '../../components/FilterList/filter-hooks';
3
+ import { FilterState } from '../../components/FilterList/filter-hooks';
4
4
  export interface FilterTranslation {
5
5
  translationKey: string;
6
6
  key: string;
@@ -15,5 +15,5 @@ export interface PublicWarningsState {
15
15
  isLoading: boolean;
16
16
  lastUpdatedTime: string;
17
17
  error?: PublicWarningError;
18
- filterState: Record<string, PickedFilterState>;
18
+ filterState: Record<string, FilterState>;
19
19
  }
@@ -1,5 +1,5 @@
1
- import { Warning } from '../store/publicWarningForm/types';
1
+ import { PublicWarning } from '../store/publicWarningForm/types';
2
2
  export declare const testGeoJSON: GeoJSON.FeatureCollection;
3
3
  export declare function fakeErrorRequest<ReturnType>(error: string): Promise<ReturnType>;
4
4
  export declare const fakePostError = "2 validation errors for Request\nbody -> warningDetail -> phenomenon\n value is not a valid enumeration member; permitted: 'wind', 'fog', 'thunderstorm', 'snowIce', 'rain', 'highTemp', 'funnelCloud', 'lowTemp', 'coastalEvent' (type=type_error.enum; enum_values=[<PhenomenonEnum.WIND: 'wind'>, <PhenomenonEnum.FOG: 'fog'>, <PhenomenonEnum.THUNDERSTORM: 'thunderstorm'>, <PhenomenonEnum.SNOW_ICE: 'snowIce'>, <PhenomenonEnum.RAIN: 'rain'>, <PhenomenonEnum.HIGH_TEMP: 'highTemp'>, <PhenomenonEnum.FUNNEL_CLD: 'funnelCloud'>, <PhenomenonEnum.LOW_TEMP: 'lowTemp'>, <PhenomenonEnum.COASTAL_EVENT: 'coastalEvent'>])\nbody -> warningDetail -> level\n value is not a valid enumeration member; permitted: 'moderate', 'severe', 'extreme' (type=type_error.enum; enum_values=[<LevelEnum.MODERATE: 'moderate'>, <LevelEnum.SEVERE: 'severe'>, <LevelEnum.EXTREME: 'extreme'>])";
5
- export declare const testPublicWarning: Warning;
5
+ export declare const testPublicWarning: PublicWarning;
@@ -1,4 +1,4 @@
1
- import { RestHandler } from 'msw';
1
+ import { RequestHandler } from 'msw';
2
2
  import type { DrawingFromBE, DrawingListItem } from '../../store/warningsDrawings/types';
3
3
  import type { AirmetWarning, PublicWarning, SigmetWarning, Warning } from '../../store/publicWarningForm/types';
4
4
  declare const drawingList: DrawingListItem[];
@@ -9,7 +9,7 @@ declare const sigmetList: SigmetWarning[];
9
9
  declare const airmetList: AirmetWarning[];
10
10
  declare const combinedWarnings: Warning[];
11
11
  declare const areaKeywordList: string[];
12
- export declare const publicWarningEndpoints: RestHandler<import("msw").MockedRequest<import("msw").DefaultBodyType>>[];
13
- export declare const makeWarningsHandler: (result: Warning[]) => RestHandler;
14
- declare const requestHandlers: RestHandler<import("msw").MockedRequest<import("msw").DefaultBodyType>>[];
12
+ export declare const publicWarningEndpoints: import("msw").HttpHandler[];
13
+ export declare const makeWarningsHandler: (result: Warning[]) => RequestHandler;
14
+ declare const requestHandlers: import("msw").HttpHandler[];
15
15
  export { drawingList, drawingsListFullContent, warningList, lengthWarningListWithoutExpiredWithdrawn, sigmetList, airmetList, combinedWarnings, areaKeywordList, requestHandlers, };