@netzi/tokens 0.1.0-beta.10

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,93 @@
1
+ Copyright (c) 2014, The Fira Code Project Authors (https://github.com/tonsky/FiraCode)
2
+
3
+ This Font Software is licensed under the SIL Open Font License, Version 1.1.
4
+ This license is copied below, and is also available with a FAQ at:
5
+ http://scripts.sil.org/OFL
6
+
7
+
8
+ -----------------------------------------------------------
9
+ SIL OPEN FONT LICENSE Version 1.1 - 26 February 2007
10
+ -----------------------------------------------------------
11
+
12
+ PREAMBLE
13
+ The goals of the Open Font License (OFL) are to stimulate worldwide
14
+ development of collaborative font projects, to support the font creation
15
+ efforts of academic and linguistic communities, and to provide a free and
16
+ open framework in which fonts may be shared and improved in partnership
17
+ with others.
18
+
19
+ The OFL allows the licensed fonts to be used, studied, modified and
20
+ redistributed freely as long as they are not sold by themselves. The
21
+ fonts, including any derivative works, can be bundled, embedded,
22
+ redistributed and/or sold with any software provided that any reserved
23
+ names are not used by derivative works. The fonts and derivatives,
24
+ however, cannot be released under any other type of license. The
25
+ requirement for fonts to remain under this license does not apply
26
+ to any document created using the fonts or their derivatives.
27
+
28
+ DEFINITIONS
29
+ "Font Software" refers to the set of files released by the Copyright
30
+ Holder(s) under this license and clearly marked as such. This may
31
+ include source files, build scripts and documentation.
32
+
33
+ "Reserved Font Name" refers to any names specified as such after the
34
+ copyright statement(s).
35
+
36
+ "Original Version" refers to the collection of Font Software components as
37
+ distributed by the Copyright Holder(s).
38
+
39
+ "Modified Version" refers to any derivative made by adding to, deleting,
40
+ or substituting -- in part or in whole -- any of the components of the
41
+ Original Version, by changing formats or by porting the Font Software to a
42
+ new environment.
43
+
44
+ "Author" refers to any designer, engineer, programmer, technical
45
+ writer or other person who contributed to the Font Software.
46
+
47
+ PERMISSION & CONDITIONS
48
+ Permission is hereby granted, free of charge, to any person obtaining
49
+ a copy of the Font Software, to use, study, copy, merge, embed, modify,
50
+ redistribute, and sell modified and unmodified copies of the Font
51
+ Software, subject to the following conditions:
52
+
53
+ 1) Neither the Font Software nor any of its individual components,
54
+ in Original or Modified Versions, may be sold by itself.
55
+
56
+ 2) Original or Modified Versions of the Font Software may be bundled,
57
+ redistributed and/or sold with any software, provided that each copy
58
+ contains the above copyright notice and this license. These can be
59
+ included either as stand-alone text files, human-readable headers or
60
+ in the appropriate machine-readable metadata fields within text or
61
+ binary files as long as those fields can be easily viewed by the user.
62
+
63
+ 3) No Modified Version of the Font Software may use the Reserved Font
64
+ Name(s) unless explicit written permission is granted by the corresponding
65
+ Copyright Holder. This restriction only applies to the primary font name as
66
+ presented to the users.
67
+
68
+ 4) The name(s) of the Copyright Holder(s) or the Author(s) of the Font
69
+ Software shall not be used to promote, endorse or advertise any
70
+ Modified Version, except to acknowledge the contribution(s) of the
71
+ Copyright Holder(s) and the Author(s) or with their explicit written
72
+ permission.
73
+
74
+ 5) The Font Software, modified or unmodified, in part or in whole,
75
+ must be distributed entirely under this license, and must not be
76
+ distributed under any other license. The requirement for fonts to
77
+ remain under this license does not apply to any document created
78
+ using the Font Software.
79
+
80
+ TERMINATION
81
+ This license becomes null and void if any of the above conditions are
82
+ not met.
83
+
84
+ DISCLAIMER
85
+ THE FONT SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
86
+ EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OF
87
+ MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT
88
+ OF COPYRIGHT, PATENT, TRADEMARK, OR OTHER RIGHT. IN NO EVENT SHALL THE
89
+ COPYRIGHT HOLDER BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
90
+ INCLUDING ANY GENERAL, SPECIAL, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL
91
+ DAMAGES, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
92
+ FROM, OUT OF THE USE OR INABILITY TO USE THE FONT SOFTWARE OR FROM
93
+ OTHER DEALINGS IN THE FONT SOFTWARE.
@@ -0,0 +1,93 @@
1
+ Copyright 2020 The Plus Jakarta Sans Project Authors (https://github.com/tokotype/PlusJakartaSans)
2
+
3
+ This Font Software is licensed under the SIL Open Font License, Version 1.1.
4
+ This license is copied below, and is also available with a FAQ at:
5
+ http://scripts.sil.org/OFL
6
+
7
+
8
+ -----------------------------------------------------------
9
+ SIL OPEN FONT LICENSE Version 1.1 - 26 February 2007
10
+ -----------------------------------------------------------
11
+
12
+ PREAMBLE
13
+ The goals of the Open Font License (OFL) are to stimulate worldwide
14
+ development of collaborative font projects, to support the font creation
15
+ efforts of academic and linguistic communities, and to provide a free and
16
+ open framework in which fonts may be shared and improved in partnership
17
+ with others.
18
+
19
+ The OFL allows the licensed fonts to be used, studied, modified and
20
+ redistributed freely as long as they are not sold by themselves. The
21
+ fonts, including any derivative works, can be bundled, embedded,
22
+ redistributed and/or sold with any software provided that any reserved
23
+ names are not used by derivative works. The fonts and derivatives,
24
+ however, cannot be released under any other type of license. The
25
+ requirement for fonts to remain under this license does not apply
26
+ to any document created using the fonts or their derivatives.
27
+
28
+ DEFINITIONS
29
+ "Font Software" refers to the set of files released by the Copyright
30
+ Holder(s) under this license and clearly marked as such. This may
31
+ include source files, build scripts and documentation.
32
+
33
+ "Reserved Font Name" refers to any names specified as such after the
34
+ copyright statement(s).
35
+
36
+ "Original Version" refers to the collection of Font Software components as
37
+ distributed by the Copyright Holder(s).
38
+
39
+ "Modified Version" refers to any derivative made by adding to, deleting,
40
+ or substituting -- in part or in whole -- any of the components of the
41
+ Original Version, by changing formats or by porting the Font Software to a
42
+ new environment.
43
+
44
+ "Author" refers to any designer, engineer, programmer, technical
45
+ writer or other person who contributed to the Font Software.
46
+
47
+ PERMISSION & CONDITIONS
48
+ Permission is hereby granted, free of charge, to any person obtaining
49
+ a copy of the Font Software, to use, study, copy, merge, embed, modify,
50
+ redistribute, and sell modified and unmodified copies of the Font
51
+ Software, subject to the following conditions:
52
+
53
+ 1) Neither the Font Software nor any of its individual components,
54
+ in Original or Modified Versions, may be sold by itself.
55
+
56
+ 2) Original or Modified Versions of the Font Software may be bundled,
57
+ redistributed and/or sold with any software, provided that each copy
58
+ contains the above copyright notice and this license. These can be
59
+ included either as stand-alone text files, human-readable headers or
60
+ in the appropriate machine-readable metadata fields within text or
61
+ binary files as long as those fields can be easily viewed by the user.
62
+
63
+ 3) No Modified Version of the Font Software may use the Reserved Font
64
+ Name(s) unless explicit written permission is granted by the corresponding
65
+ Copyright Holder. This restriction only applies to the primary font name as
66
+ presented to the users.
67
+
68
+ 4) The name(s) of the Copyright Holder(s) or the Author(s) of the Font
69
+ Software shall not be used to promote, endorse or advertise any
70
+ Modified Version, except to acknowledge the contribution(s) of the
71
+ Copyright Holder(s) and the Author(s) or with their explicit written
72
+ permission.
73
+
74
+ 5) The Font Software, modified or unmodified, in part or in whole,
75
+ must be distributed entirely under this license, and must not be
76
+ distributed under any other license. The requirement for fonts to
77
+ remain under this license does not apply to any document created
78
+ using the Font Software.
79
+
80
+ TERMINATION
81
+ This license becomes null and void if any of the above conditions are
82
+ not met.
83
+
84
+ DISCLAIMER
85
+ THE FONT SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
86
+ EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OF
87
+ MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT
88
+ OF COPYRIGHT, PATENT, TRADEMARK, OR OTHER RIGHT. IN NO EVENT SHALL THE
89
+ COPYRIGHT HOLDER BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
90
+ INCLUDING ANY GENERAL, SPECIAL, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL
91
+ DAMAGES, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
92
+ FROM, OUT OF THE USE OR INABILITY TO USE THE FONT SOFTWARE OR FROM
93
+ OTHER DEALINGS IN THE FONT SOFTWARE.
@@ -0,0 +1,136 @@
1
+ /* ===========================================================
2
+ @netzi/tokens — Fuentes de marca, AUTOALOJADAS
3
+ Plus Jakarta Sans (texto) y Fira Code (monoespaciada), como fuentes
4
+ variables woff2 en dos subconjuntos: `latin` y `latin-ext` (ç, ñ, ß, ã,
5
+ l·l… política 10). El navegador descarga solo el subconjunto que el texto
6
+ necesita (`unicode-range`). Nada se pide a Google: política 14 («Google
7
+ Fonts se autoaloja; nunca se carga desde Google en producción») y 08b
8
+ (ningún recurso de terceros antes del consentimiento).
9
+
10
+ Este archivo NO va en index.css: impórtalo aparte
11
+ (`@import '@netzi/tokens/fonts.css'`) si tu app usa las fuentes de marca.
12
+ Las rutas son relativas al paquete: Vite y el CLI de Angular las
13
+ reescriben y copian los woff2 al build.
14
+
15
+ Licencias: SIL Open Font License 1.1, copia junto a cada fuente
16
+ (fonts/LICENSE-PlusJakartaSans.txt, fonts/LICENSE-FiraCode.txt).
17
+ Origen y versiones: docs/licencias/medios.md del repositorio.
18
+ =========================================================== */
19
+
20
+ @font-face {
21
+ font-family: 'Plus Jakarta Sans';
22
+ font-style: normal;
23
+ font-weight: 200 800;
24
+ font-display: swap;
25
+ src: url('./fonts/plus-jakarta-sans-latin.woff2') format('woff2');
26
+ unicode-range:
27
+ U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329,
28
+ U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
29
+ }
30
+
31
+ @font-face {
32
+ font-family: 'Plus Jakarta Sans';
33
+ font-style: normal;
34
+ font-weight: 200 800;
35
+ font-display: swap;
36
+ src: url('./fonts/plus-jakarta-sans-latin-ext.woff2') format('woff2');
37
+ unicode-range:
38
+ U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329,
39
+ U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F,
40
+ U+A720-A7FF;
41
+ }
42
+
43
+ @font-face {
44
+ font-family: 'Fira Code';
45
+ font-style: normal;
46
+ font-weight: 300 700;
47
+ font-display: swap;
48
+ src: url('./fonts/fira-code-latin.woff2') format('woff2');
49
+ unicode-range:
50
+ U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329,
51
+ U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
52
+ }
53
+
54
+ @font-face {
55
+ font-family: 'Fira Code';
56
+ font-style: normal;
57
+ font-weight: 300 700;
58
+ font-display: swap;
59
+ src: url('./fonts/fira-code-latin-ext.woff2') format('woff2');
60
+ unicode-range:
61
+ U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329,
62
+ U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F,
63
+ U+A720-A7FF;
64
+ }
65
+
66
+ /* -----------------------------------------------------------
67
+ Respaldo con métricas ajustadas (#178)
68
+ Con `swap`, el texto se pinta primero con una fuente del sistema y salta
69
+ al llegar la de marca: otra anchura de letra y otra altura de línea mueven
70
+ la página entera (layout shift). Estas caras locales hacen que la fuente
71
+ del sistema ocupe lo mismo que la de marca, así que el cambio apenas mueve
72
+ nada. Las familias de los tokens las nombran justo detrás de la de marca
73
+ (`--netzi-font-sans`, `--netzi-font-mono`).
74
+
75
+ De dónde salen los números (se rehacen si cambia la fuente de marca):
76
+ - Vertical (fontTools 4.60 sobre los woff2 de fonts/): Plus Jakarta Sans
77
+ tiene 1000 unidades por eme, ascendente 1038, descendente 222 e
78
+ interlineado 0 (OS/2 «typo», con USE_TYPO_METRICS; «hhea» da lo
79
+ mismo). Fira Code: 2000 unidades, 1980, 644 y 0.
80
+ - Anchura: medida en Chromium (`measureText` de un canvas) sobre el texto
81
+ entero de las 63 páginas del playground, en español y en inglés, con sus
82
+ espacios. Plus Jakarta Sans ocupa un 3,88 % más que Arial a peso 400
83
+ (3,76 % en español, 4,00 % en inglés) y un 0,98 % más que Arial Bold a
84
+ 700. Se mide sobre texto real y no sobre las letras sueltas porque el
85
+ espacio de Plus Jakarta Sans es muy estrecho (0,17 em, el de Arial
86
+ 0,278) y cuenta tanto como las letras. Separar el espacio en su propia
87
+ cara (con `unicode-range`) se probó y movía más, no menos.
88
+ - size-adjust = anchura de la de marca / anchura del respaldo.
89
+ - ascent-override, descent-override y line-gap-override = la métrica de
90
+ la de marca (en ems) / size-adjust: el navegador las escala después por
91
+ size-adjust, y la caja de línea queda como la de marca.
92
+ - Resultado (scripts/saltos-de-layout.mjs, 71 rutas a 1280 px): lo que se
93
+ mueve al llegar la fuente suma 0,058 con este respaldo y 1,033 sin él en
94
+ el Linux del CI (Liberation), y 0,061 y 0,300 en macOS (Arial).
95
+ Liberation Sans y Liberation Mono (Linux) tienen las métricas de Arial y
96
+ Courier New, así que valen los mismos números. El peso 700 va aparte
97
+ porque Arial Bold no es Arial ensanchada; de 550 en adelante se usa esa
98
+ cara en vez de engrosar la normal. En la monoespaciada todo ocupa 0,6 em
99
+ en las dos (Courier New, 0,6001), también en negrita: basta una cara, y la
100
+ negrita la sintetiza el navegador. Su size-adjust no es 0,6 / 0,6001
101
+ (99,98 %) sino 100,03 %: con el hinting de Linux cada avance se redondea a
102
+ píxeles enteros, y a 99,98 % el respaldo se quedaba justo por debajo de la
103
+ media unidad (7,4995 px a 12,5 px, que redondea a 7) mientras Fira Code
104
+ daba 7,5 (que redondea a 8). Con 100,03 % los dos redondean igual de 11 a
105
+ 22,5 px, y sin hinting la anchura cambia un 0,02 %. Ascent y descent salen
106
+ igual que arriba: 0,99 / 1,0003 y 0,322 / 1,0003.
107
+ ----------------------------------------------------------- */
108
+
109
+ @font-face {
110
+ font-family: 'Plus Jakarta Sans Fallback';
111
+ font-weight: 100 549;
112
+ src: local('Arial'), local('Liberation Sans'), local('Arimo');
113
+ size-adjust: 103.88%;
114
+ ascent-override: 99.92%;
115
+ descent-override: 21.37%;
116
+ line-gap-override: 0%;
117
+ }
118
+
119
+ @font-face {
120
+ font-family: 'Plus Jakarta Sans Fallback';
121
+ font-weight: 550 900;
122
+ src: local('Arial Bold'), local('Liberation Sans Bold'), local('Arimo Bold');
123
+ size-adjust: 100.98%;
124
+ ascent-override: 102.79%;
125
+ descent-override: 21.98%;
126
+ line-gap-override: 0%;
127
+ }
128
+
129
+ @font-face {
130
+ font-family: 'Fira Code Fallback';
131
+ src: local('Courier New'), local('Liberation Mono'), local('Cousine');
132
+ size-adjust: 100.03%;
133
+ ascent-override: 98.97%;
134
+ descent-override: 32.19%;
135
+ line-gap-override: 0%;
136
+ }
@@ -0,0 +1,7 @@
1
+ /* ===========================================================
2
+ @netzi/tokens — Entrada por defecto
3
+ Incluye tokens + base. NO incluye fonts.css (impórtalo aparte
4
+ si quieres cargar las fuentes desde Google Fonts).
5
+ =========================================================== */
6
+ @import './tokens.css';
7
+ @import './base.css';