Option to load Google fonts from local folder

This commit is contained in:
pmoreno.rodriguez 2023-10-28 22:10:17 +02:00
parent e59aed4d5d
commit 040f48e137
33 changed files with 276 additions and 0 deletions

View file

@ -0,0 +1,232 @@
/* cyrillic-ext */
@font-face {
font-family: 'Raleway';
font-style: normal;
font-weight: 400;
src: url(../fonts/raleway-29-cyrillic-ext-400.woff2) format('woff2');
unicode-range: U+0460-052F, U+1C80-1C88, U+20B4, U+2DE0-2DFF, U+A640-A69F, U+FE2E-FE2F;
}
/* cyrillic */
@font-face {
font-family: 'Raleway';
font-style: normal;
font-weight: 400;
src: url(../fonts/raleway-29-cyrillic-400.woff2) format('woff2');
unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}
/* vietnamese */
@font-face {
font-family: 'Raleway';
font-style: normal;
font-weight: 400;
src: url(../fonts/raleway-29-vietnamese-400.woff2) format('woff2');
unicode-range: U+0102-0103, U+0110-0111, U+0128-0129, U+0168-0169, U+01A0-01A1, U+01AF-01B0, U+0300-0301, U+0303-0304, U+0308-0309, U+0323, U+0329, U+1EA0-1EF9, U+20AB;
}
/* latin-ext */
@font-face {
font-family: 'Raleway';
font-style: normal;
font-weight: 400;
src: url(../fonts/raleway-29-latin-ext-400.woff2) format('woff2');
unicode-range: U+0100-02AF, U+0304, U+0308, U+0329, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20CF, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
/* latin */
@font-face {
font-family: 'Raleway';
font-style: normal;
font-weight: 400;
src: url(../fonts/raleway-29-latin-400.woff2) format('woff2');
unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+2074, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
/* cyrillic-ext */
@font-face {
font-family: 'Raleway';
font-style: normal;
font-weight: 800;
src: url(../fonts/raleway-29-cyrillic-ext-800.woff2) format('woff2');
unicode-range: U+0460-052F, U+1C80-1C88, U+20B4, U+2DE0-2DFF, U+A640-A69F, U+FE2E-FE2F;
}
/* cyrillic */
@font-face {
font-family: 'Raleway';
font-style: normal;
font-weight: 800;
src: url(../fonts/raleway-29-cyrillic-800.woff2) format('woff2');
unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}
/* vietnamese */
@font-face {
font-family: 'Raleway';
font-style: normal;
font-weight: 800;
src: url(../fonts/raleway-29-vietnamese-800.woff2) format('woff2');
unicode-range: U+0102-0103, U+0110-0111, U+0128-0129, U+0168-0169, U+01A0-01A1, U+01AF-01B0, U+0300-0301, U+0303-0304, U+0308-0309, U+0323, U+0329, U+1EA0-1EF9, U+20AB;
}
/* latin-ext */
@font-face {
font-family: 'Raleway';
font-style: normal;
font-weight: 800;
src: url(../fonts/raleway-29-latin-ext-800.woff2) format('woff2');
unicode-range: U+0100-02AF, U+0304, U+0308, U+0329, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20CF, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
/* latin */
@font-face {
font-family: 'Raleway';
font-style: normal;
font-weight: 800;
src: url(../fonts/raleway-29-latin-800.woff2) format('woff2');
unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+2074, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
/* cyrillic-ext */
@font-face {
font-family: 'Raleway';
font-style: normal;
font-weight: 900;
src: url(../fonts/raleway-29-cyrillic-ext-900.woff2) format('woff2');
unicode-range: U+0460-052F, U+1C80-1C88, U+20B4, U+2DE0-2DFF, U+A640-A69F, U+FE2E-FE2F;
}
/* cyrillic */
@font-face {
font-family: 'Raleway';
font-style: normal;
font-weight: 900;
src: url(../fonts/raleway-29-cyrillic-900.woff2) format('woff2');
unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}
/* vietnamese */
@font-face {
font-family: 'Raleway';
font-style: normal;
font-weight: 900;
src: url(../fonts/raleway-29-vietnamese-900.woff2) format('woff2');
unicode-range: U+0102-0103, U+0110-0111, U+0128-0129, U+0168-0169, U+01A0-01A1, U+01AF-01B0, U+0300-0301, U+0303-0304, U+0308-0309, U+0323, U+0329, U+1EA0-1EF9, U+20AB;
}
/* latin-ext */
@font-face {
font-family: 'Raleway';
font-style: normal;
font-weight: 900;
src: url(../fonts/raleway-29-latin-ext-900.woff2) format('woff2');
unicode-range: U+0100-02AF, U+0304, U+0308, U+0329, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20CF, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
/* latin */
@font-face {
font-family: 'Raleway';
font-style: normal;
font-weight: 900;
src: url(../fonts/raleway-29-latin-900.woff2) format('woff2');
unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+2074, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
/* cyrillic-ext */
@font-face {
font-family: 'Source Sans Pro';
font-style: normal;
font-weight: 400;
src: url(../fonts/sourcesanspro-22-cyrillic-ext-400.woff2) format('woff2');
unicode-range: U+0460-052F, U+1C80-1C88, U+20B4, U+2DE0-2DFF, U+A640-A69F, U+FE2E-FE2F;
}
/* cyrillic */
@font-face {
font-family: 'Source Sans Pro';
font-style: normal;
font-weight: 400;
src: url(../fonts/sourcesanspro-22-cyrillic-400.woff2) format('woff2');
unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}
/* greek-ext */
@font-face {
font-family: 'Source Sans Pro';
font-style: normal;
font-weight: 400;
src: url(../fonts/sourcesanspro-22-greek-ext-400.woff2) format('woff2');
unicode-range: U+1F00-1FFF;
}
/* greek */
@font-face {
font-family: 'Source Sans Pro';
font-style: normal;
font-weight: 400;
src: url(../fonts/sourcesanspro-22-greek-400.woff2) format('woff2');
unicode-range: U+0370-03FF;
}
/* vietnamese */
@font-face {
font-family: 'Source Sans Pro';
font-style: normal;
font-weight: 400;
src: url(../fonts/raleway-29-vietnamese-400.woff2) format('woff2');
unicode-range: U+0102-0103, U+0110-0111, U+0128-0129, U+0168-0169, U+01A0-01A1, U+01AF-01B0, U+0300-0301, U+0303-0304, U+0308-0309, U+0323, U+0329, U+1EA0-1EF9, U+20AB;
}
/* latin-ext */
@font-face {
font-family: 'Source Sans Pro';
font-style: normal;
font-weight: 400;
src: url(../fonts/sourcesanspro-22-latin-ext-400.woff2) format('woff2');
unicode-range: U+0100-02AF, U+0304, U+0308, U+0329, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20CF, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
/* latin */
@font-face {
font-family: 'Source Sans Pro';
font-style: normal;
font-weight: 400;
src: url(../fonts/sourcesanspro-22-latin-400.woff2) format('woff2');
unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+2074, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
/* cyrillic-ext */
@font-face {
font-family: 'Source Sans Pro';
font-style: normal;
font-weight: 700;
src: url(../fonts/sourcesanspro-22-cyrillic-ext-700.woff2) format('woff2');
unicode-range: U+0460-052F, U+1C80-1C88, U+20B4, U+2DE0-2DFF, U+A640-A69F, U+FE2E-FE2F;
}
/* cyrillic */
@font-face {
font-family: 'Source Sans Pro';
font-style: normal;
font-weight: 700;
src: url(../fonts/sourcesanspro-22-cyrillic-700.woff2) format('woff2');
unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}
/* greek-ext */
@font-face {
font-family: 'Source Sans Pro';
font-style: normal;
font-weight: 700;
src: url(../fonts/sourcesanspro-22-greek-ext-700.woff2) format('woff2');
unicode-range: U+1F00-1FFF;
}
/* greek */
@font-face {
font-family: 'Source Sans Pro';
font-style: normal;
font-weight: 700;
src: url(../fonts/sourcesanspro-22-greek-700.woff2) format('woff2');
unicode-range: U+0370-03FF;
}
/* vietnamese */
@font-face {
font-family: 'Source Sans Pro';
font-style: normal;
font-weight: 700;
src: url(../fonts/sourcesanspro-22-vietnamese-700.woff2) format('woff2');
unicode-range: U+0102-0103, U+0110-0111, U+0128-0129, U+0168-0169, U+01A0-01A1, U+01AF-01B0, U+0300-0301, U+0303-0304, U+0308-0309, U+0323, U+0329, U+1EA0-1EF9, U+20AB;
}
/* latin-ext */
@font-face {
font-family: 'Source Sans Pro';
font-style: normal;
font-weight: 700;
src: url(../fonts/sourcesanspro-22-latin-ext-700.woff2) format('woff2');
unicode-range: U+0100-02AF, U+0304, U+0308, U+0329, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20CF, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
/* latin */
@font-face {
font-family: 'Source Sans Pro';
font-style: normal;
font-weight: 700;
src: url(../fonts/sourcesanspro-22-latin-700.woff2) format('woff2');
unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+2074, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

View file

@ -0,0 +1 @@
@import url("https://fonts.googleapis.com/css?family=Source+Sans+Pro:400,700|Raleway:400,800,900");

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

View file

@ -24,6 +24,8 @@ en:
BLOG_PAGE_HELP: The route to the blog page when working with blog sidebar
SIDEBAR: Show sidebar on non-editable pages
SIDEBAR_HELP: Show sidebar on pages like Offline, SimpleSearch Results, Error, etc.
GOOGLE_FONTS:
LOCAL: Use locally hosted Google Fonts
MINIPOSTS: Show miniposts in sidebar
MINIPOSTS_NUMBER: Miniposts number to show
MINIPOSTS_NUMBER_DESCRIPTION: Number of miniposts that will be showed in sidebar
@ -164,6 +166,17 @@ en:
ACTIONS_TITLE: Actions
STYLING_TITLE: Styling
BEHAVIOR_TITLE: Behaviors
OVERLAY_HOVER_EFFECT:
LABEL: Overlay effect on hover
HELP: Set the hover effect when the mouse is over an image
FADEIN_BOTTOM: Fade in bottom
FADEIN_TOP: Fade in top
FADEIN_LEFT: Fade in left
FADEIN_RIGHT: Fade in right
FADEIN_TOP_RIGHT: Fade in top right
FADEIN_TOP_LEFT: Fade in top left
FADEIN_BOTTOM_RIGHT: Fade in bottom right
FADEIN_BOTTOM_LEFT: Fade in bottom left
OPEN_EFFECT:
LABEL: Open Effect
ZOOM: Zoom
@ -282,6 +295,8 @@ de:
BLOG_PAGE_HELP: Der Pfad zur Blog-Seite wenn die Blog-Seitenleiste aktiv ist
SIDEBAR: Seitenleiste auf nicht bearbeitbaren Seiten anzeigen
SIDEBAR_HELP: Seitenleiste auf Seiten wie Offline, SimpleSearch-Ergebnisse, Fehler usw. anzeigen.
GOOGLE_FONTS:
LOCAL: Verwenden Sie lokal gehostete Google Fonts
MINIPOSTS: Miniposts in der Seitenleiste zeigen
MINIPOSTS_NUMBER: Anzahl der anzuzeigenden Miniposts
MINIPOSTS_NUMBER_DESCRIPTION: Anzahl der in der Seitenleiste anzuzeigenden Miniposts
@ -419,6 +434,17 @@ de:
ACTIONS_TITLE: Aktionen
STYLING_TITLE: Aussehen
BEHAVIOR_TITLE: Verhalten
OVERLAY_HOVER_EFFECT:
LABEL: Overlay-Effekt beim Hover
HELP: Legen Sie den Hover-Effekt fest, wenn sich die Maus über einem Bild befindet
FADEIN_BOTTOM: Unten einblenden
FADEIN_TOP: Oben einblenden
FADEIN_LEFT: Links einblenden
FADEIN_RIGHT: Rechts einblenden
FADEIN_TOP_RIGHT: Oben rechts einblenden
FADEIN_TOP_LEFT: Oben links einblenden
FADEIN_BOTTOM_RIGHT: Unten rechts einblenden
FADEIN_BOTTOM_LEFT: Unten links einblenden
OPEN_EFFECT:
LABEL: Effekt beim Öffnen
ZOOM: zoomen
@ -537,6 +563,8 @@ es:
BLOG_PAGE_HELP: Ruta de la página de Blog cuando funciona con el blog de barra lateral
SIDEBAR: Mostrar barra lateral en página no editables
SIDEBAR_HELP: Mostrar barra lateral en páginas como Offline, SimpleSearch Results, Error, etc.
GOOGLE_FONTS:
LOCAL: Usar fuentes de Google alojadas localmente
MINIPOSTS: Activar Miniposts en la barra lateral
MINIPOSTS_NUMBER: Número de miniposts a mostrar
MINIPOSTS_NUMBER_DESCRIPTION: Número de miniposts que se mostrarán en la barra lateral
@ -677,6 +705,17 @@ es:
ACTIONS_TITLE: Acciones
STYLING_TITLE: Estilos
BEHAVIOR_TITLE: Comportamiento
OVERLAY_HOVER_EFFECT:
LABEL: Efecto de superposición al pasar el ratón
HELP: Establece el efecto de superposición cuando el ratón está sobre una imagen
FADEIN_BOTTOM: Fundido inferior
FADEIN_TOP: Fundido superior
FADEIN_LEFT: Fundido desde la izquierda
FADEIN_RIGHT: Fundido desde la derecha
FADEIN_TOP_RIGHT: Fundido superior derecha
FADEIN_TOP_LEFT: Fundido superior izquierda
FADEIN_BOTTOM_RIGHT: Fundido inferior derecha
FADEIN_BOTTOM_LEFT: Fundido inferior izquierda
OPEN_EFFECT:
LABEL: Efecto de apertura
ZOOM: Zoom

View file

@ -3,6 +3,9 @@
{% set compress = theme_var('production-mode') ? '.min.css' : '.css' %}
{% set favicon = theme_config.favicon ? theme_config.favicon|first : { type:'image/png', path: url('theme://images/favicon.png') } %}
{# Set Google Fonts source - Local or Remote#}
{% set google_fonts = theme_var('google_fonts_local') ? '-local.css' : '-remote.css' %}
{# Set site language and datestamp for pages #}
{% set lang = grav.language.getActive ?: grav.config.site.default_lang %}
{% set datestamp = include('partials/page-bits/date.html.twig') %}
@ -38,6 +41,7 @@
{% do assets.addCss('theme://assets/css/fontawesome-all.min.css',{'rel':'preload','as':'style','onload':'this.rel="stylesheet"'}) %}
{% do assets.addCss('theme://assets/css/misc.css', 10) %}
{% do assets.addCss('theme://assets/css/custom.css', 15) %}
{% do assets.addCss('theme://assets/css/google-fonts' ~ google_fonts, {'priority': 20}) %}
{% endblock %}
{% block javascripts %}