mirror of
https://github.com/rsms/inter.git
synced 2024-09-11 10:55:24 +03:00
- UPM is adjusted to 2048 - Additional opsz VF axis (multi master) added which will eventually replace the separate Display family - New tooling that uses fontmake instead of Inter's own fontbuild toolchain. (The old toolchain is still supported, i.e. `make -f Makefile_v1.make ...`)
80 lines
2.2 KiB
CSS
80 lines
2.2 KiB
CSS
---
|
|
layout: none
|
|
---
|
|
{% assign font_v = site.data.fontinfo[0].version %}
|
|
/*
|
|
Font families defined by this CSS:
|
|
|
|
- "Inter" static "traditional" fonts for older web browsers
|
|
- "Inter var" single-axis variable fonts for all modern browsers
|
|
- "Inter var experimental" multi-axis variable fonts for some modern web browsers
|
|
|
|
Use like this in your CSS:
|
|
|
|
:root { font-family: 'Inter', sans-serif; }
|
|
@supports (font-variation-settings: normal) {
|
|
:root { font-family: 'Inter var', sans-serif; }
|
|
}
|
|
|
|
------------------------- static ------------------------- */
|
|
{% include Inter-static.css %}
|
|
|
|
/* ----------------------- variable ----------------------- */
|
|
|
|
@font-face {
|
|
font-family: 'Inter var';
|
|
font-style: normal;
|
|
font-weight: 100 900;
|
|
font-display: swap;
|
|
src: url('font-files/Inter-roman.var.woff2?v={{font_v}}') format('woff2');
|
|
font-named-instance: 'Regular';
|
|
}
|
|
|
|
@font-face {
|
|
font-family: 'Inter var';
|
|
font-style: italic;
|
|
font-weight: 100 900;
|
|
font-display: swap;
|
|
src: url('font-files/Inter-italic.var.woff2?v={{font_v}}') format('woff2');
|
|
font-named-instance: 'Italic';
|
|
}
|
|
|
|
/* ----------- experimental multi-axis variable -----------
|
|
|
|
Slant axis is not yet widely supported (as of February 2019) and thus this
|
|
multi-axis single-file variable font is opt-in rather than the default.
|
|
When using this, you will likely need to set font-variation-settings explicitly, e.g:
|
|
* { font-variation-settings: "slnt" 0deg }
|
|
.italic { font-variation-settings: "slnt" 10deg }
|
|
*/
|
|
|
|
{%- comment -%}
|
|
{% include Inter.var.css %}
|
|
{%- endcomment %}
|
|
|
|
@font-face {
|
|
font-family: 'Inter var experimental';
|
|
font-style: oblique 0deg 10deg;
|
|
font-weight: 100 900;
|
|
font-display: swap;
|
|
src: url('font-files/Inter.var.woff2?v={{font_v}}') format('woff2');
|
|
}
|
|
|
|
/* Legacy name (became legacy on Feb 2, 2019) */
|
|
@font-face {
|
|
font-family: 'Inter var alt';
|
|
font-weight: 100 900;
|
|
font-style: normal;
|
|
font-named-instance: 'Regular';
|
|
font-display: swap;
|
|
src: url("font-files/Inter-roman.var.woff2?v={{font_v}}") format("woff2");
|
|
}
|
|
@font-face {
|
|
font-family: 'Inter var alt';
|
|
font-weight: 100 900;
|
|
font-style: italic;
|
|
font-named-instance: 'Italic';
|
|
font-display: swap;
|
|
src: url("font-files/Inter-italic.var.woff2?v={{font_v}}") format("woff2");
|
|
}
|