mirror of
https://github.com/MichMich/MagicMirror.git
synced 2025-08-21 12:55:22 +00:00
Merge pull request #2771 from CFenner/patch-1
This commit is contained in:
@@ -19,6 +19,7 @@ _This release is scheduled to be released on 2022-04-01._
|
|||||||
|
|
||||||
- deprecated roboto fonts package `roboto-fontface-bower` replaced with `fontsource`.
|
- deprecated roboto fonts package `roboto-fontface-bower` replaced with `fontsource`.
|
||||||
- update `helmet` to v5.
|
- update `helmet` to v5.
|
||||||
|
- updates Font Awesome css class to new default style (fixes #2768)
|
||||||
|
|
||||||
### Fixed
|
### Fixed
|
||||||
|
|
||||||
|
@@ -3,7 +3,7 @@
|
|||||||
{% if imageUrl %}
|
{% if imageUrl %}
|
||||||
<img src="{{ imageUrl }}" height="{{ imageHeight }}" style="margin-bottom: 10px;"/>
|
<img src="{{ imageUrl }}" height="{{ imageHeight }}" style="margin-bottom: 10px;"/>
|
||||||
{% else %}
|
{% else %}
|
||||||
<span class="bright fa fa-{{ imageFA }}" style='margin-bottom: 10px; font-size: {{ imageHeight }};'/></span>
|
<span class="bright fas fa-{{ imageFA }}" style='margin-bottom: 10px; font-size: {{ imageHeight }};'/></span>
|
||||||
{% endif %}
|
{% endif %}
|
||||||
<br/>
|
<br/>
|
||||||
{% endif %}
|
{% endif %}
|
||||||
|
@@ -13,7 +13,7 @@ Module.register("calendar", {
|
|||||||
maximumNumberOfDays: 365,
|
maximumNumberOfDays: 365,
|
||||||
limitDays: 0, // Limit the number of days shown, 0 = no limit
|
limitDays: 0, // Limit the number of days shown, 0 = no limit
|
||||||
displaySymbol: true,
|
displaySymbol: true,
|
||||||
defaultSymbol: "calendar", // Fontawesome Symbol see https://fontawesome.com/cheatsheet?from=io
|
defaultSymbol: "calendar-alt", // Fontawesome Symbol see https://fontawesome.com/cheatsheet?from=io
|
||||||
showLocation: false,
|
showLocation: false,
|
||||||
displayRepeatingCountTitle: false,
|
displayRepeatingCountTitle: false,
|
||||||
defaultRepeatingCountTitle: "",
|
defaultRepeatingCountTitle: "",
|
||||||
@@ -43,7 +43,7 @@ Module.register("calendar", {
|
|||||||
tableClass: "small",
|
tableClass: "small",
|
||||||
calendars: [
|
calendars: [
|
||||||
{
|
{
|
||||||
symbol: "calendar",
|
symbol: "calendar-alt",
|
||||||
url: "https://www.calendarlabs.com/templates/ical/US-Holidays.ics"
|
url: "https://www.calendarlabs.com/templates/ical/US-Holidays.ics"
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
@@ -239,7 +239,7 @@ Module.register("calendar", {
|
|||||||
const symbols = this.symbolsForEvent(event);
|
const symbols = this.symbolsForEvent(event);
|
||||||
symbols.forEach((s, index) => {
|
symbols.forEach((s, index) => {
|
||||||
const symbol = document.createElement("span");
|
const symbol = document.createElement("span");
|
||||||
symbol.className = "fa fa-fw fa-" + s;
|
symbol.className = "fas fa-fw fa-" + s;
|
||||||
if (index > 0) {
|
if (index > 0) {
|
||||||
symbol.style.paddingLeft = "5px";
|
symbol.style.paddingLeft = "5px";
|
||||||
}
|
}
|
||||||
|
@@ -199,13 +199,13 @@ Module.register("clock", {
|
|||||||
sunWrapper.innerHTML =
|
sunWrapper.innerHTML =
|
||||||
'<span class="' +
|
'<span class="' +
|
||||||
(isVisible ? "bright" : "") +
|
(isVisible ? "bright" : "") +
|
||||||
'"><i class="fa fa-sun-o" aria-hidden="true"></i> ' +
|
'"><i class="fas fa-sun" aria-hidden="true"></i> ' +
|
||||||
untilNextEventString +
|
untilNextEventString +
|
||||||
"</span>" +
|
"</span>" +
|
||||||
'<span><i class="fa fa-arrow-up" aria-hidden="true"></i> ' +
|
'<span><i class="fas fa-arrow-up" aria-hidden="true"></i> ' +
|
||||||
formatTime(this.config, sunTimes.sunrise) +
|
formatTime(this.config, sunTimes.sunrise) +
|
||||||
"</span>" +
|
"</span>" +
|
||||||
'<span><i class="fa fa-arrow-down" aria-hidden="true"></i> ' +
|
'<span><i class="fas fa-arrow-down" aria-hidden="true"></i> ' +
|
||||||
formatTime(this.config, sunTimes.sunset) +
|
formatTime(this.config, sunTimes.sunset) +
|
||||||
"</span>";
|
"</span>";
|
||||||
digitalWrapper.appendChild(sunWrapper);
|
digitalWrapper.appendChild(sunWrapper);
|
||||||
@@ -230,13 +230,13 @@ Module.register("clock", {
|
|||||||
moonWrapper.innerHTML =
|
moonWrapper.innerHTML =
|
||||||
'<span class="' +
|
'<span class="' +
|
||||||
(isVisible ? "bright" : "") +
|
(isVisible ? "bright" : "") +
|
||||||
'"><i class="fa fa-moon-o" aria-hidden="true"></i> ' +
|
'"><i class="fas fa-moon" aria-hidden="true"></i> ' +
|
||||||
illuminatedFractionString +
|
illuminatedFractionString +
|
||||||
"</span>" +
|
"</span>" +
|
||||||
'<span><i class="fa fa-arrow-up" aria-hidden="true"></i> ' +
|
'<span><i class="fas fa-arrow-up" aria-hidden="true"></i> ' +
|
||||||
(moonRise ? formatTime(this.config, moonRise) : "...") +
|
(moonRise ? formatTime(this.config, moonRise) : "...") +
|
||||||
"</span>" +
|
"</span>" +
|
||||||
'<span><i class="fa fa-arrow-down" aria-hidden="true"></i> ' +
|
'<span><i class="fas fa-arrow-down" aria-hidden="true"></i> ' +
|
||||||
(moonSet ? formatTime(this.config, moonSet) : "...") +
|
(moonSet ? formatTime(this.config, moonSet) : "...") +
|
||||||
"</span>";
|
"</span>";
|
||||||
digitalWrapper.appendChild(moonWrapper);
|
digitalWrapper.appendChild(moonWrapper);
|
||||||
|
@@ -135,7 +135,7 @@ Module.register("currentweather", {
|
|||||||
var windDirection = document.createElement("sup");
|
var windDirection = document.createElement("sup");
|
||||||
if (this.config.showWindDirectionAsArrow) {
|
if (this.config.showWindDirectionAsArrow) {
|
||||||
if (this.windDeg !== null) {
|
if (this.windDeg !== null) {
|
||||||
windDirection.innerHTML = ' <i class="fa fa-long-arrow-down" style="transform:rotate(' + this.windDeg + 'deg);"></i> ';
|
windDirection.innerHTML = ' <i class="fas fa-long-arrow-alt-down" style="transform:rotate(' + this.windDeg + 'deg);"></i> ';
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
windDirection.innerHTML = " " + this.translate(this.windDirection);
|
windDirection.innerHTML = " " + this.translate(this.windDirection);
|
||||||
@@ -234,7 +234,7 @@ Module.register("currentweather", {
|
|||||||
|
|
||||||
if (this.config.showIndoorTemperature && this.indoorTemperature) {
|
if (this.config.showIndoorTemperature && this.indoorTemperature) {
|
||||||
var indoorIcon = document.createElement("span");
|
var indoorIcon = document.createElement("span");
|
||||||
indoorIcon.className = "fa fa-home";
|
indoorIcon.className = "fas fa-home";
|
||||||
large.appendChild(indoorIcon);
|
large.appendChild(indoorIcon);
|
||||||
|
|
||||||
var indoorTemperatureElem = document.createElement("span");
|
var indoorTemperatureElem = document.createElement("span");
|
||||||
@@ -245,7 +245,7 @@ Module.register("currentweather", {
|
|||||||
|
|
||||||
if (this.config.showIndoorHumidity && this.indoorHumidity) {
|
if (this.config.showIndoorHumidity && this.indoorHumidity) {
|
||||||
var indoorHumidityIcon = document.createElement("span");
|
var indoorHumidityIcon = document.createElement("span");
|
||||||
indoorHumidityIcon.className = "fa fa-tint";
|
indoorHumidityIcon.className = "fas fa-tint";
|
||||||
large.appendChild(indoorHumidityIcon);
|
large.appendChild(indoorHumidityIcon);
|
||||||
|
|
||||||
var indoorHumidityElem = document.createElement("span");
|
var indoorHumidityElem = document.createElement("span");
|
||||||
|
@@ -1,7 +1,7 @@
|
|||||||
{% if not suspended %}
|
{% if not suspended %}
|
||||||
{% for name, status in moduleList %}
|
{% for name, status in moduleList %}
|
||||||
<div class="small bright">
|
<div class="small bright">
|
||||||
<i class="fa fa-exclamation-circle"></i>
|
<i class="fas fa-exclamation-circle"></i>
|
||||||
<span>
|
<span>
|
||||||
{% set mainTextLabel = "UPDATE_NOTIFICATION" if name === "default" else "UPDATE_NOTIFICATION_MODULE" %}
|
{% set mainTextLabel = "UPDATE_NOTIFICATION" if name === "default" else "UPDATE_NOTIFICATION_MODULE" %}
|
||||||
{{ mainTextLabel | translate({MODULE_NAME: name}) }}
|
{{ mainTextLabel | translate({MODULE_NAME: name}) }}
|
||||||
|
@@ -15,7 +15,7 @@
|
|||||||
{% if config.showWindDirection %}
|
{% if config.showWindDirection %}
|
||||||
<sup>
|
<sup>
|
||||||
{% if config.showWindDirectionAsArrow %}
|
{% if config.showWindDirectionAsArrow %}
|
||||||
<i class="fa fa-long-arrow-up" style="transform:rotate({{ current.windDirection }}deg);"></i>
|
<i class="fas fa-long-arrow-alt-up" style="transform:rotate({{ current.windDirection }}deg);"></i>
|
||||||
{% else %}
|
{% else %}
|
||||||
{{ current.cardinalWindDirection() | translate }}
|
{{ current.cardinalWindDirection() | translate }}
|
||||||
{% endif %}
|
{% endif %}
|
||||||
@@ -47,7 +47,7 @@
|
|||||||
<div class="normal light indoor">
|
<div class="normal light indoor">
|
||||||
{% if config.showIndoorTemperature and indoor.temperature %}
|
{% if config.showIndoorTemperature and indoor.temperature %}
|
||||||
<div>
|
<div>
|
||||||
<span class="fa fa-home"></span>
|
<span class="fas fa-home"></span>
|
||||||
<span class="bright">
|
<span class="bright">
|
||||||
{{ indoor.temperature | roundValue | unit("temperature") | decimalSymbol }}
|
{{ indoor.temperature | roundValue | unit("temperature") | decimalSymbol }}
|
||||||
</span>
|
</span>
|
||||||
@@ -55,7 +55,7 @@
|
|||||||
{% endif %}
|
{% endif %}
|
||||||
{% if config.showIndoorHumidity and indoor.humidity %}
|
{% if config.showIndoorHumidity and indoor.humidity %}
|
||||||
<div>
|
<div>
|
||||||
<span class="fa fa-tint"></span>
|
<span class="fas fa-tint"></span>
|
||||||
<span class="bright">
|
<span class="bright">
|
||||||
{{ indoor.humidity | roundValue | unit("humidity") | decimalSymbol }}
|
{{ indoor.humidity | roundValue | unit("humidity") | decimalSymbol }}
|
||||||
</span>
|
</span>
|
||||||
|
@@ -33,7 +33,7 @@ describe("Calendar module", function () {
|
|||||||
});
|
});
|
||||||
|
|
||||||
it("should show the default calendar symbol in each event", () => {
|
it("should show the default calendar symbol in each event", () => {
|
||||||
testElementLength(".calendar .event .fa-calendar", 0, "not");
|
testElementLength(".calendar .event .fa-calendar-alt", 0, "not");
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
|
||||||
|
@@ -117,7 +117,7 @@ describe("Weather module", function () {
|
|||||||
});
|
});
|
||||||
|
|
||||||
it("should render showWindDirectionAsArrow = true", function () {
|
it("should render showWindDirectionAsArrow = true", function () {
|
||||||
const elem = getElement(".weather .normal.medium sup i.fa-long-arrow-up");
|
const elem = getElement(".weather .normal.medium sup i.fa-long-arrow-alt-up");
|
||||||
expect(elem.outerHTML).toContain("transform:rotate(250deg);");
|
expect(elem.outerHTML).toContain("transform:rotate(250deg);");
|
||||||
});
|
});
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user