64 Commits

Author SHA1 Message Date
Veeck
fe0b915a5d
Convert app-start/-stop callbacks to async/await (#3035)
supersedes https://github.com/MichMich/MagicMirror/pull/3027 and just
touches the start/stop calls.

---------

Co-authored-by: veeck <michael@veeck.de>
2023-02-22 18:58:00 +01:00
Karsten Hassel
42d42ef452
Prevent electron flashing white screen on startup (#3001)
see #1919

thanks @dfanica for providing the solution in [this
comment](https://github.com/MichMich/MagicMirror/issues/1919#issuecomment-1369898385)

tested this on a pi4 with bullseye 32-bit and 64-bit
2023-01-26 22:16:50 +01:00
Thomas Hirschberger
b9b7d2c95d
Add option to remove "x-frame-options" and "content-security-policy" response headers (#2963)
Many users like me do have the problem that they want to embed other
sites to their mirror by "iframe".
As some developers set the "x-frame-options" and
"content-security-policy" for security reasons these sites can not be
embedded.
Electron provides the "webview" element additionally to "iframe" which
allows to embed these sites although. The main difference is that a new
process is started which handles the "webview" element.
BUT: As the "webview" process needs to be started and is isolated
"webview" is slower and the elements can not be accessed from the
embedding website.

As an alternative i implemented a small callback function in electron.js
which removes the response headers that forbid the embedding.

The removing can be controlled with the new config options:
* ignoreXOriginHeader
* ignoreContentSecurityPolicy
2022-11-07 07:42:27 +01:00
Rohith Dharavath
288a008e72
Update electron.js
corrected spelling mistake
2022-04-21 01:53:22 +05:30
Karsten Hassel
88f7570caf add comments in electron.js 2022-03-29 21:24:17 +02:00
Karsten Hassel
00a7c6b5be added new env var ELECTRON_DISABLE_GPU which disable gpu under electron if set (fixes #2831). 2022-03-29 20:41:36 +02:00
Sam Detweiler
28d866c001 enable useHTTP for full electron version 2021-12-26 17:43:27 +01:00
Seongnoh Sean Yi
17637fb1f6
Merge branch 'develop' into develop 2021-08-31 10:50:05 +02:00
Karsten Hassel
fbc886b21c run prettier ... 2021-08-30 19:55:26 +02:00
Karsten Hassel
8879fb55de disable black cursor on start 2021-08-30 19:47:26 +02:00
eouia
dbdff38d2e Add custom switches for electron mainWindow 2021-08-30 11:32:24 +02:00
rejas
2619f92d09 More var -> let/const conversions 2021-07-14 10:41:29 +02:00
karsten13
f945d50c0d run prettier 2021-07-04 19:21:17 +02:00
Karsten Hassel
ad13de3588 update electron to v13 2021-07-04 17:46:22 +02:00
Karsten Hassel
cfc0bcd5ad workaround for dev_console test using getWindowCount 2021-06-18 21:39:55 +02:00
rejas
6ff85ebe54 Enable contextIsolation in electron
Fixes warning when starting MM
2021-02-27 13:19:16 +01:00
Felix Wiedenbach
b18d98f5ea exposed logger as node module 2021-02-18 19:14:53 +01:00
Felix Wiedenbach
4efe04774c clean up electron 2021-01-05 18:48:55 +01:00
rejas
43bcf4ab98 Run eslint over files, see what gets fixed automatically and clean up 2020-07-27 14:25:43 +02:00
Veeck
13073bc98d Lint stuff 2020-06-02 15:03:59 +02:00
rejas
f2d03a511e User logger in node files 2020-06-02 15:03:59 +02:00
Veeck
abb5dc5739 Run prettier over ALL files once
No other changes done in this commit
2020-05-11 22:22:32 +02:00
Andre
31b3f778fc no single quotes 2020-04-03 12:37:33 +02:00
Andre
351e0f3a0b add https support 2020-03-28 12:37:50 +01:00
rejas
a91f2de26a Remove jshint dependency, use eslint for config verification 2020-03-15 20:38:52 +01:00
Michael Teeuw
8ef8388c32 Set default DISPLAY in package.json. 2020-02-01 15:02:47 +01:00
Michael Teeuw
21dbaa1a03 Move DISPLAY default to electron script. 2020-02-01 13:59:13 +01:00
Seongnoh Sean Yi
3796076360
change Squotes to Dquotes 2019-05-13 23:24:59 +02:00
Seongnoh Sean Yi
94fc4cb8a2
allow html5 autoplay policy
From Chrome 66, autoplay policy is changed. This 1 line can help to play html5 audio and video without user-gesture-allowance in MagicMirror
2019-05-13 21:19:50 +02:00
shbatm
f646360af6 Gracefully shutdown node_helpers (Fixes #1056)
Updated documentation


Corrected Typo in Documentation


Style correction
2017-10-13 16:43:11 -05:00
Bas van Wetten
318c8c68b0 Change suggestion for e2e testing
- Changed global-setup.js to allow for easier test creation
- Changed each e2e test suite to work with new global-setup.js
- All tests (except for dev_console.js) now work with Travis CI
2017-07-23 23:06:27 +02:00
Unknown
a7297d2685 Fix for issue #950
Changed 'server.js' to allow an empty ipwhitelist to allow any and all hosts instead of none as mentioned in the documentation
2017-07-18 14:07:18 +02:00
Unknown
66f93ee541 Added clientonly script
Added clientonly script to have server and client run at different locations
2017-07-02 12:10:16 +02:00
Unknown
98bcfbef7e Removed unused import
Removed unused import from js/electron.js
2017-06-18 19:17:41 +02:00
Veeck
96c338859b More lazy sunday cleanups of missing semicolons, unused vars and other small thins 2017-06-11 11:53:55 +02:00
Rodrigo Ramírez Norambuena
b41bda569d Change method for check if pass dev parameter 2017-04-18 23:34:14 -03:00
Rodrigo Ramez Norambuena
6552157894 Remove white flash on boot up
When the electron app is started appear a white flash before show the
MagicMirror system.

This patch remove the white flash on boot up.
2017-01-04 13:06:24 -03:00
Rodrigo Ramírez Norambuena
19d906c5e4 fix tabs, remove extra spaces and lines. 2016-12-29 22:23:08 -03:00
Andreas 'count' Kotes
6a184b069b make electronOptions configurable, remove kioskmode from documentation 2016-12-13 13:59:24 +01:00
Olexandr Savchuk
c8d5a5319e Clean up duplicate code in Electron options 2016-12-02 21:09:16 +01:00
Olexandr Savchuk
a08fa721cf Added zoom factor config value and Electron option 2016-12-02 21:05:36 +01:00
Michael Teeuw
e2ed0f5e55 Cleanup 2016-08-09 10:33:34 +02:00
Michael Teeuw
d000e3c8a9 Force fullscreen when kioskmode is active 2016-08-09 10:22:29 +02:00
Michael Teeuw
5be8084473 Fix formatting. 2016-07-30 15:58:51 +02:00
Alex Yakhnin
b98237fa44 Added dev parameter 2016-07-30 09:42:31 -04:00
Michael Teeuw
921557161d Add option to enable kios mode 2016-07-27 12:50:59 +02:00
Ashley M. Kirchner
935f4132ab Filemode changes? 2016-05-10 00:46:21 -06:00
Michael Teeuw
6fdcd7f7e9 Add darkTheme. 2016-04-19 20:26:22 +02:00
Michael Teeuw
a34a5c4db0 Separate server core from Electron. 2016-04-08 22:16:22 +02:00
Nicholas Hubbard
426728058c Standardize: TO JSCS! 2016-04-05 14:35:11 -04:00