diff --git a/src/Components/FirmwareSelector/index.jsx b/src/Components/FirmwareSelector/index.jsx index e1a166780..0b3e0eeac 100644 --- a/src/Components/FirmwareSelector/index.jsx +++ b/src/Components/FirmwareSelector/index.jsx @@ -66,6 +66,7 @@ function FirmwareSelector({ version: null, url: null, pwm: null, + releaseUrl: null, }); const [layoutSelectionDisabled, setLayoutSelectionDisabled] = useState(false); @@ -133,6 +134,7 @@ function FirmwareSelector({ key: version.key, value: version.url, name: version.name, + releaseUrl: version.releaseUrl ? version.releaseUrl : null, })); const firmwareOptions = validFirmware.map((key) => ({ @@ -205,6 +207,8 @@ function FirmwareSelector({ const selected = e.target.options.selectedIndex; const selectedOption = e.target.options[selected]; + const releaseUrl = options.versions[selected - 1].releaseUrl; + const firmwareName = selection.firmware; const firmwareVersion = options.versions[selected - 1].key; @@ -223,6 +227,7 @@ function FirmwareSelector({ setSelection({ ...selection, url: e.target.value, + releaseUrl, version: selectedOption && options.versions[selected - 1].key, }); }, [options, selection]); @@ -375,6 +380,42 @@ function FirmwareSelector({ />} } +
+

+ + {t('selectionAttention')} + +

+ +

+ {t('selectionHint')} +

+ +

+

+

+ + {selection.releaseUrl && + + {t('selectionLinkText')} + } +
+