Merge pull request #2662 from rejas/prettier

This commit is contained in:
Michael Teeuw 2021-09-11 16:10:40 +02:00 committed by GitHub
commit 60e03777f3
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
12 changed files with 83 additions and 87 deletions

2
.github/FUNDING.yml vendored
View File

@ -1,2 +1,2 @@
github: MichMich
custom: ['https://magicmirror.builders/#donate']
custom: ["https://magicmirror.builders/#donate"]

View File

@ -20,6 +20,7 @@ If you are facing an issue or found a bug while trying to install MagicMirror vi
## I found a bug in the MagicMirror Docker image
If you are facing an issue or found a bug while running MagicMirror inside a Docker container please create an issue in the corresponding repository:
- karsten13/magicmirror: [https://gitlab.com/khassel/magicmirror](https://gitlab.com/khassel/magicmirror)
- (deprecated) bastilimbach/docker-magicmirror: [https://github.com/bastilimbach/docker-MagicMirror](https://github.com/bastilimbach/docker-MagicMirror)

View File

@ -2,23 +2,20 @@ Hello and thank you for wanting to contribute to the MagicMirror project
**Please make sure that you have followed these 4 rules before submitting your Pull Request:**
> 1) Base your pull requests against the `develop` branch.
> 1. Base your pull requests against the `develop` branch.
>
> 2. Include these infos in the description:
>
> 2) Include these infos in the description:
> * Does the pull request solve a **related** issue?
> * If so, can you reference the issue like this `Fixes #<issue_number>`?
> * What does the pull request accomplish? Use a list if needed.
> * If it includes major visual changes please add screenshots.
> - Does the pull request solve a **related** issue?
> - If so, can you reference the issue like this `Fixes #<issue_number>`?
> - What does the pull request accomplish? Use a list if needed.
> - If it includes major visual changes please add screenshots.
>
> 3. Please run `npm run lint:prettier` before submitting so that
> style issues are fixed.
>
> 3) Please run `npm run lint:prettier` before submitting so that
> style issues are fixed.
>
>
> 4) Don't forget to add an entry about your changes to
> the CHANGELOG.md file.
> 4. Don't forget to add an entry about your changes to
> the CHANGELOG.md file.
**Note**: Sometimes the development moves very fast. It is highly
recommended that you update your branch of `develop` before creating a

View File

@ -4,9 +4,9 @@ name: "Run Codecov Tests"
on:
push:
branches: [ master, develop ]
branches: [master, develop]
pull_request:
branches: [ master, develop ]
branches: [master, develop]
jobs:
run-and-upload-coverage-report:

View File

@ -4,15 +4,15 @@ name: "Enforce Changelog"
on:
pull_request:
types: [opened, synchronize, reopened, ready_for_review, labeled, unlabeled]
types: [opened, synchronize, reopened, ready_for_review, labeled, unlabeled]
jobs:
check:
runs-on: ubuntu-latest
timeout-minutes: 10
steps:
- uses: actions/checkout@v2
- uses: dangoslen/changelog-enforcer@v1.6.1
with:
changeLogPath: 'CHANGELOG.md'
skipLabels: 'Skip Changelog'
- uses: actions/checkout@v2
- uses: dangoslen/changelog-enforcer@v1.6.1
with:
changeLogPath: "CHANGELOG.md"
skipLabels: "Skip Changelog"

View File

@ -5,9 +5,9 @@ name: "Run Automated Tests"
on:
push:
branches: [ master, develop ]
branches: [master, develop]
pull_request:
branches: [ master, develop ]
branches: [master, develop]
jobs:
test:
@ -15,20 +15,20 @@ jobs:
timeout-minutes: 30
strategy:
matrix:
node-version: [12.x, 14.x, 16.8]
node-version: [12.x, 14.x, 16.x]
steps:
- uses: actions/checkout@v2
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v1
with:
node-version: ${{ matrix.node-version }}
- run: |
node -v
Xvfb :99 -screen 0 1024x768x16 &
export DISPLAY=:99
npm install
npm run test:prettier
npm run test:js
npm run test:css
npm run test:unit
npm run test:e2e
- uses: actions/checkout@v2
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v1
with:
node-version: ${{ matrix.node-version }}
- run: |
node -v
Xvfb :99 -screen 0 1024x768x16 &
export DISPLAY=:99
npm install
npm run test:prettier
npm run test:js
npm run test:css
npm run test:unit
npm run test:e2e

View File

@ -1,8 +1,4 @@
/config
/coverage
/vendor
!/vendor/vendor.js
.github
.nyc_output
package-lock.json
*.ts

View File

@ -26,6 +26,7 @@ _This release is scheduled to be released on 2021-10-01._
- Refactored clock layout.
- Refactored methods from weatherproviders into weatherobject (isDaytime, updateSunTime).
- Use of `logger.js` in jest tests.
- Run prettier over all relevant files.
### Fixed

View File

@ -57,7 +57,8 @@ let config = {
calendars: [
{
symbol: "calendar-check",
url: "webcal://www.calendarlabs.com/ical-calendar/ics/76/US_Holidays.ics" }
url: "webcal://www.calendarlabs.com/ical-calendar/ics/76/US_Holidays.ics"
}
]
}
},

View File

@ -1,16 +1,16 @@
type ModuleProperties = {
defaults?: object,
start?(): void,
getHeader?(): string,
getTemplate?(): string,
getTemplateData?(): object,
notificationReceived?(notification: string, payload: any, sender: object): void,
socketNotificationReceived?(notification: string, payload: any): void,
suspend?(): void,
resume?(): void,
getDom?(): HTMLElement,
getStyles?(): string[],
[key: string]: any,
defaults?: object;
start?(): void;
getHeader?(): string;
getTemplate?(): string;
getTemplateData?(): object;
notificationReceived?(notification: string, payload: any, sender: object): void;
socketNotificationReceived?(notification: string, payload: any): void;
suspend?(): void;
resume?(): void;
getDom?(): HTMLElement;
getStyles?(): string[];
[key: string]: any;
};
export declare const Module: {
@ -18,14 +18,14 @@ export declare const Module: {
};
export declare const Log: {
info(message?: any, ...optionalParams: any[]): void,
log(message?: any, ...optionalParams: any[]): void,
error(message?: any, ...optionalParams: any[]): void,
warn(message?: any, ...optionalParams: any[]): void,
group(groupTitle?: string, ...optionalParams: any[]): void,
groupCollapsed(groupTitle?: string, ...optionalParams: any[]): void,
groupEnd(): void,
time(timerName?: string): void,
timeEnd(timerName?: string): void,
timeStamp(timerName?: string): void,
};
info(message?: any, ...optionalParams: any[]): void;
log(message?: any, ...optionalParams: any[]): void;
error(message?: any, ...optionalParams: any[]): void;
warn(message?: any, ...optionalParams: any[]): void;
group(groupTitle?: string, ...optionalParams: any[]): void;
groupCollapsed(groupTitle?: string, ...optionalParams: any[]): void;
groupEnd(): void;
time(timerName?: string): void;
timeEnd(timerName?: string): void;
timeStamp(timerName?: string): void;
};

View File

@ -1,2 +1,2 @@
@import url("../node_modules/@fortawesome/fontawesome-free/css/all.min.css");
@import url("../node_modules/@fortawesome/fontawesome-free/css/v4-shims.min.css");
@import url("../node_modules/@fortawesome/fontawesome-free/css/v4-shims.min.css");

36
vendor/package.json vendored
View File

@ -1,20 +1,20 @@
{
"name": "magicmirror-vendors",
"description": "Package for vendors use by MagicMirror Core.",
"repository": {
"type": "git",
"url": "git+https://github.com/MichMich/MagicMirror.git"
},
"license": "MIT",
"bugs": {
"url": "https://github.com/MichMich/MagicMirror/issues"
},
"dependencies": {
"@fortawesome/fontawesome-free": "^5.15.4",
"moment": "^2.29.1",
"moment-timezone": "^0.5.33",
"nunjucks": "^3.2.3",
"suncalc": "^1.8.0",
"weathericons": "^2.1.0"
}
"name": "magicmirror-vendors",
"description": "Package for vendors use by MagicMirror Core.",
"repository": {
"type": "git",
"url": "git+https://github.com/MichMich/MagicMirror.git"
},
"license": "MIT",
"bugs": {
"url": "https://github.com/MichMich/MagicMirror/issues"
},
"dependencies": {
"@fortawesome/fontawesome-free": "^5.15.4",
"moment": "^2.29.1",
"moment-timezone": "^0.5.33",
"nunjucks": "^3.2.3",
"suncalc": "^1.8.0",
"weathericons": "^2.1.0"
}
}