mirror of
https://github.com/MichMich/MagicMirror.git
synced 2025-06-27 11:50:00 +00:00
commit
702145dada
19
css/main.css
19
css/main.css
@ -35,7 +35,6 @@ body {
|
|||||||
|
|
||||||
|
|
||||||
header {
|
header {
|
||||||
margin-top: 30px;
|
|
||||||
text-transform: uppercase;
|
text-transform: uppercase;
|
||||||
font-size: 15px;
|
font-size: 15px;
|
||||||
font-family: 'roboto_condensedregular';
|
font-family: 'roboto_condensedregular';
|
||||||
@ -50,6 +49,18 @@ sup {
|
|||||||
font-size: 50%;
|
font-size: 50%;
|
||||||
line-height: 50%;
|
line-height: 50%;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Module styles.
|
||||||
|
*/
|
||||||
|
|
||||||
|
.module {
|
||||||
|
margin-top: 30px;
|
||||||
|
}
|
||||||
|
.module:first-child {
|
||||||
|
margin-top: 0px;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Region Definitions.
|
* Region Definitions.
|
||||||
*/
|
*/
|
||||||
@ -120,6 +131,8 @@ sup {
|
|||||||
.region.right {
|
.region.right {
|
||||||
text-align: right;
|
text-align: right;
|
||||||
}
|
}
|
||||||
.region.right table {
|
.region table {
|
||||||
float: right;
|
width: 100%;
|
||||||
|
border-spacing: 0px;
|
||||||
|
border-collapse: separate;
|
||||||
}
|
}
|
14
js/main.js
14
js/main.js
@ -31,7 +31,7 @@ var MM = (function() {
|
|||||||
dom.className = module.name;
|
dom.className = module.name;
|
||||||
|
|
||||||
if (typeof module.data.classes === 'string') {
|
if (typeof module.data.classes === 'string') {
|
||||||
dom.className = dom.className + ' ' + module.data.classes;
|
dom.className = 'module '+ dom.className + ' ' + module.data.classes;
|
||||||
}
|
}
|
||||||
|
|
||||||
dom.opacity = 0;
|
dom.opacity = 0;
|
||||||
@ -167,7 +167,12 @@ var MM = (function() {
|
|||||||
moduleWrapper.style.opacity = 0;
|
moduleWrapper.style.opacity = 0;
|
||||||
|
|
||||||
setTimeout(function() {
|
setTimeout(function() {
|
||||||
moduleWrapper.style.display = 'none';
|
// To not take up any space, we just make the position absolute.
|
||||||
|
// since it's fade out anyway, we can see it lay above or
|
||||||
|
// below other modules. This works way better than adjusting
|
||||||
|
// the .display property.
|
||||||
|
moduleWrapper.style.position = 'absolute';
|
||||||
|
|
||||||
if (typeof callback === 'function') { callback(); }
|
if (typeof callback === 'function') { callback(); }
|
||||||
}, speed);
|
}, speed);
|
||||||
}
|
}
|
||||||
@ -184,12 +189,15 @@ var MM = (function() {
|
|||||||
var moduleWrapper = document.getElementById(module.identifier);
|
var moduleWrapper = document.getElementById(module.identifier);
|
||||||
if (moduleWrapper !== null) {
|
if (moduleWrapper !== null) {
|
||||||
moduleWrapper.style.transition = "opacity " + speed / 1000 + "s";
|
moduleWrapper.style.transition = "opacity " + speed / 1000 + "s";
|
||||||
|
// Restore the postition. See hideModule() for more info.
|
||||||
|
moduleWrapper.style.position = 'static';
|
||||||
moduleWrapper.style.opacity = 1;
|
moduleWrapper.style.opacity = 1;
|
||||||
moduleWrapper.style.display = 'block';
|
|
||||||
|
|
||||||
setTimeout(function() {
|
setTimeout(function() {
|
||||||
if (typeof callback === 'function') { callback(); }
|
if (typeof callback === 'function') { callback(); }
|
||||||
}, speed);
|
}, speed);
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -21,9 +21,3 @@
|
|||||||
padding-left: 30px;
|
padding-left: 30px;
|
||||||
text-align: right;
|
text-align: right;
|
||||||
}
|
}
|
||||||
|
|
||||||
.calendar table {
|
|
||||||
width: 100%;
|
|
||||||
border-spacing: 0px;
|
|
||||||
border-collapse: separate;
|
|
||||||
}
|
|
||||||
|
@ -12,8 +12,3 @@
|
|||||||
padding-left: 20px;
|
padding-left: 20px;
|
||||||
padding-right: 0px;
|
padding-right: 0px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.weatherforecast table {
|
|
||||||
border-spacing: 0px;
|
|
||||||
border-collapse: separate;
|
|
||||||
}
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user