@opengeoweb/warnings 21.1.0 → 21.2.0-nightly-20261113

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/README.md CHANGED
@@ -10,8 +10,24 @@ Run `nx test warnings` to execute the unit tests via [Jest](https://jestjs.io).
10
10
 
11
11
  - [TypeScript Docs](https://opengeoweb.gitlab.io/opengeoweb/typescript-docs/warnings/)
12
12
 
13
- ### Enable issueing new Maritime Warnings from the warning list
13
+ ### Configuring the warning forms
14
14
 
15
- To get the option to issue maritime warnings via the geoweb application, add the following config key in `config.json`:
15
+ The warning list offers a form for each warning type. The public warning, warning event and maritime warning forms all need the Warnings backend, configured with `GW_DRAWINGS_BASE_URL` in `config.json`. Each form also has its own config key:
16
16
 
17
- - `"GW_WARNINGS_MARITIME_WARNINGS": true`
17
+ - `"GW_FEATURE_PUBLIC_WARNINGS"`: public warnings. Defaults to `true`; set to `false` to hide the public warning form and to leave public warnings out of the warning list.
18
+ - `"GW_FEATURE_WARNINGS_EVENT"`: warning event form. Defaults to `false`; set to `true` to show it.
19
+ - `"GW_WARNINGS_MARITIME_WARNINGS"`: maritime warning forms. Defaults to `false`; set to `true` to show them.
20
+
21
+ The same keys decide which forms are offered when sharing a drawing.
22
+
23
+ Each key also controls the requests to the Warnings backend. The warning list only loads warning events from `/events` when `GW_FEATURE_WARNINGS_EVENT` is `true`. Public and maritime warnings are loaded from the same `/warnings` endpoint. That request is only skipped when `GW_FEATURE_PUBLIC_WARNINGS` is `false` and `GW_WARNINGS_MARITIME_WARNINGS` is not `true`. Warnings of a disabled type are left out of the list.
24
+
25
+ For example, to only issue maritime warnings:
26
+
27
+ ```json
28
+ {
29
+ "GW_DRAWINGS_BASE_URL": "https://your-warnings-backend",
30
+ "GW_FEATURE_PUBLIC_WARNINGS": false,
31
+ "GW_WARNINGS_MARITIME_WARNINGS": true
32
+ }
33
+ ```
package/dist/README.md CHANGED
@@ -10,8 +10,24 @@ Run `nx test warnings` to execute the unit tests via [Jest](https://jestjs.io).
10
10
 
11
11
  - [TypeScript Docs](https://opengeoweb.gitlab.io/opengeoweb/typescript-docs/warnings/)
12
12
 
13
- ### Enable issueing new Maritime Warnings from the warning list
13
+ ### Configuring the warning forms
14
14
 
15
- To get the option to issue maritime warnings via the geoweb application, add the following config key in `config.json`:
15
+ The warning list offers a form for each warning type. The public warning, warning event and maritime warning forms all need the Warnings backend, configured with `GW_DRAWINGS_BASE_URL` in `config.json`. Each form also has its own config key:
16
16
 
17
- - `"GW_WARNINGS_MARITIME_WARNINGS": true`
17
+ - `"GW_FEATURE_PUBLIC_WARNINGS"`: public warnings. Defaults to `true`; set to `false` to hide the public warning form and to leave public warnings out of the warning list.
18
+ - `"GW_FEATURE_WARNINGS_EVENT"`: warning event form. Defaults to `false`; set to `true` to show it.
19
+ - `"GW_WARNINGS_MARITIME_WARNINGS"`: maritime warning forms. Defaults to `false`; set to `true` to show them.
20
+
21
+ The same keys decide which forms are offered when sharing a drawing.
22
+
23
+ Each key also controls the requests to the Warnings backend. The warning list only loads warning events from `/events` when `GW_FEATURE_WARNINGS_EVENT` is `true`. Public and maritime warnings are loaded from the same `/warnings` endpoint. That request is only skipped when `GW_FEATURE_PUBLIC_WARNINGS` is `false` and `GW_WARNINGS_MARITIME_WARNINGS` is not `true`. Warnings of a disabled type are left out of the list.
24
+
25
+ For example, to only issue maritime warnings:
26
+
27
+ ```json
28
+ {
29
+ "GW_DRAWINGS_BASE_URL": "https://your-warnings-backend",
30
+ "GW_FEATURE_PUBLIC_WARNINGS": false,
31
+ "GW_WARNINGS_MARITIME_WARNINGS": true
32
+ }
33
+ ```