-
Notifications
You must be signed in to change notification settings - Fork 489
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Showing
6 changed files
with
140 additions
and
9 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
46 changes: 46 additions & 0 deletions
46
client/src/plugins/update-checks/UpdateAvailableOverlay.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,46 @@ | ||
/** | ||
* Copyright Camunda Services GmbH and/or licensed to Camunda Services GmbH | ||
* under one or more contributor license agreements. See the NOTICE file | ||
* distributed with this work for additional information regarding copyright | ||
* ownership. | ||
* | ||
* Camunda licenses this file to you under the MIT; you may not use this file | ||
* except in compliance with the MIT License. | ||
*/ | ||
|
||
import React from 'react'; | ||
|
||
import { Overlay, Section } from '../../shared/ui'; | ||
|
||
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> | ||
); | ||
} | ||
|
||
function UpdateAvailableSection({ version, openVersionInfoPage, onGoToDownloadPage }) { | ||
|
||
return ( | ||
<div className={ css.UpdateAvailableOverlay }> | ||
<Section maxHeight="500px"> | ||
<Section.Header> | ||
Update available | ||
</Section.Header> | ||
<Section.Body> | ||
<p>Camunda Desktop Modeler {version} is available for use.</p> | ||
<a className="links" onClick={ onGoToDownloadPage }> Update now </a> | ||
<a className="links" onClick={ openVersionInfoPage }>Learn what's new</a> | ||
</Section.Body> | ||
</Section> | ||
</div> | ||
); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
:local(.UpdateAvailableOverlay) { | ||
|
||
.links { | ||
display: block; | ||
padding: 2px; | ||
cursor: pointer; | ||
} | ||
} | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters