- client: Don't hide version string when built-in auto-update is disabled: Merge pull request #628 in DNS/adguard-home from fix/1726 to master
Close #1726
Squashed commit of the following:
commit 3eac793c7c05fbb599f510fd8cae560011b7f5ca
Merge: aebfaf61 16a6aada
Author: ArtemBaskal <a.baskal@adguard.com>
Date: Wed May 27 14:14:58 2020 +0300
Merge branch 'master' into fix/1726
commit aebfaf610113f83027feb959ed87adef1b2db255
Author: ArtemBaskal <a.baskal@adguard.com>
Date: Wed May 27 12:54:30 2020 +0300
Always show version but hide update button when program is launched with "--no-check-update" flag
commit 1d4ee05959379420fee9730b3bf8ba737852e96e
Author: ArtemBaskal <a.baskal@adguard.com>
Date: Wed May 27 11:59:10 2020 +0300
Use classnames lib
commit 7003a7064c9625fab513dc02222faff4a340393f
Author: ArtemBaskal <a.baskal@adguard.com>
Date: Tue May 26 19:40:22 2020 +0300
- client: Don't hide version string when built-in auto-update is disabled
This commit is contained in:
@@ -6,14 +6,15 @@ import './Version.css';
|
||||
|
||||
const Version = (props) => {
|
||||
const {
|
||||
dnsVersion, processingVersion, t,
|
||||
dnsVersion = 'undefined', processingVersion, t, checkUpdateFlag,
|
||||
} = props;
|
||||
|
||||
return (
|
||||
<div className="version">
|
||||
<div className="version__text">
|
||||
<Trans>version</Trans>: <span className="version__value" title={dnsVersion}>{dnsVersion}</span>
|
||||
<button
|
||||
<Trans>version</Trans>:
|
||||
<span className="version__value" title={dnsVersion}>{dnsVersion}</span>
|
||||
{checkUpdateFlag && <button
|
||||
type="button"
|
||||
className="btn btn-icon btn-icon-sm btn-outline-primary btn-sm ml-2"
|
||||
onClick={() => props.getVersion(true)}
|
||||
@@ -23,7 +24,7 @@ const Version = (props) => {
|
||||
<svg className="icons">
|
||||
<use xlinkHref="#refresh" />
|
||||
</svg>
|
||||
</button>
|
||||
</button>}
|
||||
</div>
|
||||
</div>
|
||||
);
|
||||
@@ -33,6 +34,7 @@ Version.propTypes = {
|
||||
dnsVersion: PropTypes.string.isRequired,
|
||||
getVersion: PropTypes.func.isRequired,
|
||||
processingVersion: PropTypes.bool.isRequired,
|
||||
checkUpdateFlag: PropTypes.bool.isRequired,
|
||||
t: PropTypes.func.isRequired,
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user