mirror of
https://github.com/MichMich/MagicMirror.git
synced 2025-06-28 12:12:20 +00:00
Able to turn off and on the clock module
This commit is contained in:
parent
f468dbf427
commit
747e1a818d
@ -66,6 +66,13 @@ The following properties can be configured:
|
|||||||
<br><b>Default value:</b> <code>false</code>
|
<br><b>Default value:</b> <code>false</code>
|
||||||
</td>
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
|
<tr>
|
||||||
|
<td><code>showDate</code></td>
|
||||||
|
<td>Turn off or on the Date section.<br>
|
||||||
|
<br><b>Possible values:</b> <code>true</code> or <code>false</code>
|
||||||
|
<br><b>Default value:</b> <code>true</code>
|
||||||
|
</td>
|
||||||
|
</tr>
|
||||||
<tr>
|
<tr>
|
||||||
<td><code>displayType</code></td>
|
<td><code>displayType</code></td>
|
||||||
<td>Display a digital clock, analog clock, or both together.<br>
|
<td>Display a digital clock, analog clock, or both together.<br>
|
||||||
|
@ -15,6 +15,7 @@ Module.register("clock",{
|
|||||||
showPeriod: true,
|
showPeriod: true,
|
||||||
showPeriodUpper: false,
|
showPeriodUpper: false,
|
||||||
clockBold: false,
|
clockBold: false,
|
||||||
|
showDate: true,
|
||||||
|
|
||||||
/* specific to the analog clock */
|
/* specific to the analog clock */
|
||||||
analogSize: '200px',
|
analogSize: '200px',
|
||||||
@ -85,7 +86,9 @@ Module.register("clock",{
|
|||||||
timeString = moment().format("h:mm");
|
timeString = moment().format("h:mm");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
if(this.config.showDate){
|
||||||
dateWrapper.innerHTML = moment().format("dddd, LL");
|
dateWrapper.innerHTML = moment().format("dddd, LL");
|
||||||
|
}
|
||||||
timeWrapper.innerHTML = timeString;
|
timeWrapper.innerHTML = timeString;
|
||||||
secondsWrapper.innerHTML = moment().format("ss");
|
secondsWrapper.innerHTML = moment().format("ss");
|
||||||
if (this.config.showPeriodUpper) {
|
if (this.config.showPeriodUpper) {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user