mirror of
https://github.com/mue/mue.git
synced 2026-07-15 13:03:55 +02:00
Bug fixes
This commit is contained in:
@@ -65,8 +65,11 @@ export default class Clock extends React.PureComponent {
|
||||
}
|
||||
|
||||
render() {
|
||||
if (localStorage.getItem('time') === 'false') return null;
|
||||
|
||||
let clockHTML = <h1 className='clock'>{this.state.time}<span className='ampm'>{this.state.ampm}</span> </h1>;
|
||||
if (localStorage.getItem('analog') === 'true') clockHTML = <Analog className='analogclock' value={this.state.time} renderHourMarks={false} renderMinuteMarks={false} />;
|
||||
|
||||
return clockHTML;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -28,7 +28,7 @@ export default class Favourite extends React.PureComponent {
|
||||
}
|
||||
|
||||
render() {
|
||||
if (localStorage.getItem('favouriteEnabled') === 'false') return null;
|
||||
if (localStorage.getItem('favouriteEnabled') === 'false' || localStorage.getItem('background') === 'false') return null;
|
||||
return <div className='favourite'>
|
||||
{this.state.favourited}
|
||||
</div>
|
||||
|
||||
@@ -12,9 +12,7 @@ export default class View extends React.PureComponent {
|
||||
setAttribute(blur, brightness) {
|
||||
document.querySelector('#backgroundImage').setAttribute(
|
||||
'style',
|
||||
`background-image: url(${document.getElementById('backgroundImage').style.backgroundImage.replace('url("', '').replace('")', '')});
|
||||
-webkit-filter: blur(${blur});
|
||||
-webkit-filter: brightness(${brightness}%);`
|
||||
`background-image: url(${document.getElementById('backgroundImage').style.backgroundImage.replace('url("', '').replace('")', '')}); -webkit-filter: blur(${blur}); -webkit-filter: brightness(${brightness}%);`
|
||||
);
|
||||
}
|
||||
|
||||
@@ -38,7 +36,7 @@ export default class View extends React.PureComponent {
|
||||
}
|
||||
|
||||
render() {
|
||||
if (localStorage.getItem('view') === 'false') return null;
|
||||
if (localStorage.getItem('view') === 'false' || localStorage.getItem('background') === 'false') return null;
|
||||
return <div className='view'>
|
||||
<FullscreenIcon id='viewButton' onClick={() => this.viewStuff()} />
|
||||
</div>
|
||||
|
||||
@@ -97,6 +97,8 @@ export default class Quote extends React.PureComponent {
|
||||
}
|
||||
|
||||
render() {
|
||||
if (localStorage.getItem('quote') === 'false') return null;
|
||||
|
||||
let copy = <FileCopy className='copyButton' onClick={() => this.copyQuote()}></FileCopy>;
|
||||
if (localStorage.getItem('copyButton') === 'false') copy = null;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user