Apply Roboto on switch to Material

pull/6275/head^2
Cagatay Civici 2024-10-01 15:15:38 +03:00
parent c8ecf64355
commit ab6dbe9deb
3 changed files with 9 additions and 1 deletions

View File

@ -4,6 +4,10 @@ html {
font-feature-settings: "cv02","cv03","cv04","cv11"; font-feature-settings: "cv02","cv03","cv04","cv11";
} }
.material {
font-family: "Roboto", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol";
}
body { body {
margin: 0px; margin: 0px;
min-height: 100%; min-height: 100%;

View File

@ -278,6 +278,9 @@ export default {
const preset = presets[value]; const preset = presets[value];
const surfacePalette = this.surfaces.find((s) => s.name === this.selectedSurfaceColor)?.palette; const surfacePalette = this.surfaces.find((s) => s.name === this.selectedSurfaceColor)?.palette;
if (value === 'Material') document.documentElement.classList.add('material');
else document.documentElement.classList.remove('material');
$t().preset(preset).preset(this.getPresetExt()).surfacePalette(surfacePalette).use({ useDefaultOptions: true }); $t().preset(preset).preset(this.getPresetExt()).surfacePalette(surfacePalette).use({ useDefaultOptions: true });
} }
}, },

View File

@ -77,7 +77,8 @@ export default defineNuxtConfig({
], ],
link: [ link: [
{ rel: 'icon', href: baseUrl + 'favicon.ico' }, { rel: 'icon', href: baseUrl + 'favicon.ico' },
{ rel: 'stylesheet', href: 'https://rsms.me/inter/inter.css' } { rel: 'stylesheet', href: 'https://rsms.me/inter/inter.css' },
{ rel: 'stylesheet', href: 'https://fonts.googleapis.com/css?family=Roboto:400|Roboto:500|Roboto:600|Roboto:700', fetchpriority: 'low' }
], ],
script: [ script: [
{ {