Skip to content

Commit

Permalink
fix(firmwareerrorpanel): removed loading status in FirmwareErrorPanel…
Browse files Browse the repository at this point in the history
… component
  • Loading branch information
thiagohernandez committed Aug 29, 2023
1 parent edc54f5 commit a1a968f
Showing 1 changed file with 24 additions and 14 deletions.
38 changes: 24 additions & 14 deletions src/renderer/modules/Firmware/FirmwareErrorPanel.js
Original file line number Diff line number Diff line change
Expand Up @@ -220,39 +220,49 @@ function FirmwareErrorPanel({ nextBlock, retryBlock }) {

return (
<Style>
{loading && !handleError ? (
{!handleError ? (
<FirmwareLoader />
) : (
<div className="firmware-wrapper">
<div className="firmware-row">
<div className="firmware-content borderLeftTopRadius">
<div className="firmware-content--inner">
<Title text={i18n.firmwareUpdate.texts.errorTitle} headingLevel={3} type="warning" />
<div className="errorListWrapper">
{handleError ? (
state.context.error == "error.platform.GitHubData" ? (
{state.context.error === "error.platform.GitHubData" ? (
<>
<Title text={i18n.firmwareUpdate.texts.errorTitle} headingLevel={3} type="warning" />
<div className="errorListWrapper">
<div className="errorListItem">
<div className="errorListImage iconWarning">
<IconNoWifi />
</div>
<div className="errorListContent">{i18n.firmwareUpdate.texts.noInternetConncetion}</div>
</div>
) : (
""
)
) : (
""
)}
</div>
</div>
</>
) : (
<>
<Title text="Something went wrong" headingLevel={3} type="warning" />
<div className="errorListWrapper">
<div className="errorListItem">
<div className="errorListImage iconWarning">
<IconNoWifi />
</div>
<div className="errorListContent">
{state.context?.error ? state.context.error : "Contact our customer for more details"}
</div>
</div>
</div>
</>
)}
</div>
</div>
<div className="firmware-sidebar borderRightTopRadius">
<FirmwareNeuronStatus
isUpdated={false}
icon={<IconWarning />}
status="warning"
deviceProduct={state.context.device.info.product}
keyboardType={state.context.device.info.keyboardType}
deviceProduct={state.context.device.info?.product ? state.context.device.info.product : "Raise"}
keyboardType={state.context.device.info?.keyboardType ? state.context.device.info.keyboardType : "Wired"}
/>
</div>
</div>
Expand Down

0 comments on commit a1a968f

Please sign in to comment.