Skip to content

Commit

Permalink
chore: whitespace
Browse files Browse the repository at this point in the history
  • Loading branch information
philippfromme committed Nov 1, 2024
1 parent e9057cb commit 4d1ce1f
Show file tree
Hide file tree
Showing 2 changed files with 34 additions and 29 deletions.
14 changes: 8 additions & 6 deletions client/src/plugins/update-checks/UpdateAvailableOverlay.js
Original file line number Diff line number Diff line change
Expand Up @@ -17,18 +17,20 @@ import * as css from './UpdateAvailableOverlay.less';
const OFFSET = { right: 0 };

export function UpdateAvailableOverlay(props) {

return (
<Overlay
id="update-available-overlay" anchor={ props.anchor } onClose={ props.onClose } offset={ OFFSET }
>
<UpdateAvailableSection version={ props.version } openVersionInfoPage={ props.openVersionInfoPage } onGoToDownloadPage={ props.onGoToDownloadPage } />
<Overlay id="update-available-overlay"
anchor={ props.anchor }
onClose={ props.onClose }
offset={ OFFSET }>
<UpdateAvailableSection
version={ props.version }
openVersionInfoPage={ props.openVersionInfoPage }
onGoToDownloadPage={ props.onGoToDownloadPage } />
</Overlay>
);
}

function UpdateAvailableSection({ version, openVersionInfoPage, onGoToDownloadPage }) {

return (
<div className={ css.UpdateAvailableOverlay }>
<Section maxHeight="500px">
Expand Down
49 changes: 26 additions & 23 deletions client/src/plugins/update-checks/UpdateChecks.js
Original file line number Diff line number Diff line change
Expand Up @@ -390,29 +390,32 @@ export default class UpdateChecks extends PureComponent {
} = this;
return (
<React.Fragment>
{updateAvailable && <Fill slot="status-bar__app" group="9_update_checks">
<button
className="btn btn--primary"
title="Toggle update info"
onClick={ toggle }
ref={ buttonRef }
>Update</button>
</Fill>}
{openUpdateAvailablePopUp && <UpdateAvailableOverlay
anchor={ buttonRef.current }
openVersionInfoPage={ openVersionInfoPage }
onGoToDownloadPage={ this.onGoToDownloadPage }
onClose={ close }
version={ latestVersionInfo.latestVersion }
/>}
{showModal && <NewVersionInfoView
onClose={ this.onClose }
onGoToDownloadPage={ this.onGoToDownloadPage }
onOpenPrivacyPreferences={ this.openPrivacyPreferences }
latestVersionInfo={ latestVersionInfo }
updateChecksEnabled={ updateChecksEnabled }
currentVersion={ currentVersion }
/>
{
updateAvailable && <Fill slot="status-bar__app" group="9_update_checks">
<button
className="btn btn--primary"
title="Toggle update info"
onClick={ toggle }
ref={ buttonRef }
>Update</button>
</Fill>
}
{
openUpdateAvailablePopUp && <UpdateAvailableOverlay
anchor={ buttonRef.current }
openVersionInfoPage={ openVersionInfoPage }
onGoToDownloadPage={ this.onGoToDownloadPage }
onClose={ close }
version={ latestVersionInfo.latestVersion } />
}
{
showModal && <NewVersionInfoView
onClose={ this.onClose }
onGoToDownloadPage={ this.onGoToDownloadPage }
onOpenPrivacyPreferences={ this.openPrivacyPreferences }
latestVersionInfo={ latestVersionInfo }
updateChecksEnabled={ updateChecksEnabled }
currentVersion={ currentVersion } />
}
</React.Fragment>

Expand Down

0 comments on commit 4d1ce1f

Please sign in to comment.