mirror of
https://github.com/paricafe/misskey.git
synced 2024-11-30 21:06:44 -06:00
fix hw acc
This commit is contained in:
parent
97a79ae67b
commit
7417bfadc8
2 changed files with 12 additions and 11 deletions
|
@ -198,16 +198,7 @@ export async function common(createVue: () => App<Element>) {
|
|||
}, { immediate: true });
|
||||
|
||||
watch(defaultStore.reactiveState.useHardwareAcceleration, v => {
|
||||
if (v) {
|
||||
const miHwAcc = document.createElement('style');
|
||||
miHwAcc.textContent = `html {
|
||||
-webkit-font-smoothing: antialiased;
|
||||
-moz-osx-font-smoothing: grayscale;
|
||||
}`;
|
||||
document.head.appendChild(miHwAcc);
|
||||
} else {
|
||||
document.querySelector('style')?.remove();
|
||||
}
|
||||
document.documentElement.classList.toggle('font-smoothing-auto', !v);
|
||||
}, { immediate: true });
|
||||
|
||||
// Keep screen on
|
||||
|
|
|
@ -14,6 +14,16 @@
|
|||
* SPDX-License-Identifier: AGPL-3.0-only
|
||||
*/
|
||||
|
||||
* {
|
||||
-webkit-font-smoothing: antialiased;
|
||||
-moz-osx-font-smoothing: grayscale;
|
||||
}
|
||||
|
||||
.font-smoothing-auto * {
|
||||
-webkit-font-smoothing: auto;
|
||||
-moz-osx-font-smoothing: auto;
|
||||
}
|
||||
|
||||
:root {
|
||||
--MI-radius: 12px;
|
||||
--MI-marginFull: 16px;
|
||||
|
|
Loading…
Reference in a new issue