TelegramPWA/dev/icons.scss.hbs
2023-09-13 12:22:11 +02:00

50 lines
1.2 KiB
Handlebars

@use "sass:map";
${{ name }}-font: "{{ name }}";
@font-face {
font-family: ${{ name }}-font;
src: {{{ fontSrc }}};
font-weight: normal;
font-style: normal;
font-display: block;
}
.icon-char::before {
font-family: Roboto, "Helvetica Neue", sans-serif;
content: attr(data-char);
width: 1.5rem;
text-align: center;
display: block;
}
{{# if selector }}{{ selector }}::before {
{{ else }}{{ tag }}.{{prefix}} {
{{/ if }}
/* use !important to prevent issues with browser extensions that change fonts */
/* stylelint-disable-next-line font-family-no-missing-generic-family-keyword */
font-family: "{{ name }}" !important;
speak: none;
font-style: normal;
font-weight: normal;
font-variant: normal;
text-transform: none;
line-height: 1;
/* Better Font Rendering =========== */
-webkit-font-smoothing: antialiased;
-moz-osx-font-smoothing: grayscale;
}
${{ name }}-map: (
{{# each codepoints }}
"{{ @key }}": "\\{{ codepoint this }}",
{{/ each }}
);
{{# each codepoints }}
{{# if ../selector }} {{ ../selector }}.{{ ../prefix }}-{{ @key }}::before {
{{ else }}{{ tag }}.{{ ../prefix }}-{{ @key }}::before {
{{/ if }} content: map.get(${{ ../name }}-map, "{{ @key }}");
}
{{/ each }}