Skip to content

Commit b0eae23

Browse files
samsharafrozenhelium
authored andcommitted
feat: use GDACS as the primary source for Imminent Risk Watch
1 parent ab085ed commit b0eae23

File tree

3 files changed

+35
-29
lines changed

3 files changed

+35
-29
lines changed

.changeset/pink-beans-develop.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
"go-web-app": patch
3+
---
4+
5+
Prioritize GDACS as the Primary Source for Imminent Risk Watch in [#1547](https://github.com/IFRCGo/go-web-app/issues/1547)

.changeset/slimy-eggs-peel.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,4 +2,5 @@
22
"go-web-app": patch
33
---
44

5-
Add Organization type and Learning type filter in Operational learning
5+
Add Organization type and Learning type filter in Operational learning in [#1469](https://github.com/IFRCGo/go-web-app/issues/1469)
6+

app/src/components/domain/RiskImminentEvents/index.tsx

Lines changed: 28 additions & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,7 @@ type Props = BaseProps & ({
5757
function RiskImminentEvents(props: Props) {
5858
const {
5959
className,
60-
defaultSource = 'pdc',
60+
defaultSource = 'gdacs',
6161
...otherProps
6262
} = props;
6363
const [activeView, setActiveView] = useState<ImminentEventSource>(defaultSource);
@@ -168,6 +168,33 @@ function RiskImminentEvents(props: Props) {
168168
footerActionsContainerClassName={styles.footerActions}
169169
footerActions={(
170170
<>
171+
<Radio
172+
name="gdacs"
173+
value={activeView === 'gdacs'}
174+
onClick={handleRadioClick}
175+
label={strings.imminentEventsSourceGdacsLabel}
176+
actions={(
177+
<InfoPopup
178+
title={strings.gdacsTitle}
179+
popupClassName={styles.popup}
180+
descriptionClassName={styles.description}
181+
description={resolveToComponent(
182+
strings.gdacsDescription,
183+
{
184+
here: (
185+
<Link
186+
href="https://www.gdacs.org/default.aspx"
187+
variant="tertiary"
188+
external
189+
>
190+
{strings.here}
191+
</Link>
192+
),
193+
},
194+
)}
195+
/>
196+
)}
197+
/>
171198
<Radio
172199
name="pdc"
173200
value={activeView === 'pdc'}
@@ -224,33 +251,6 @@ function RiskImminentEvents(props: Props) {
224251
)}
225252
/>
226253
)}
227-
<Radio
228-
name="gdacs"
229-
value={activeView === 'gdacs'}
230-
onClick={handleRadioClick}
231-
label={strings.imminentEventsSourceGdacsLabel}
232-
actions={(
233-
<InfoPopup
234-
title={strings.gdacsTitle}
235-
popupClassName={styles.popup}
236-
descriptionClassName={styles.description}
237-
description={resolveToComponent(
238-
strings.gdacsDescription,
239-
{
240-
here: (
241-
<Link
242-
href="https://www.gdacs.org/default.aspx"
243-
variant="tertiary"
244-
external
245-
>
246-
{strings.here}
247-
</Link>
248-
),
249-
},
250-
)}
251-
/>
252-
)}
253-
/>
254254
{environment !== 'production' && (
255255
<Radio
256256
name="meteoSwiss"

0 commit comments

Comments
 (0)