mirror of
https://github.com/braver/programmingfonts.git
synced 2024-10-05 01:31:36 +02:00
67 lines
1.0 KiB
Plaintext
67 lines
1.0 KiB
Plaintext
|
@root-path: '../resources';
|
||
|
|
||
|
|
||
|
.font (@name, @weight, @style, @file)
|
||
|
when (@weight = normal)
|
||
|
and (@style = normal) {
|
||
|
|
||
|
|
||
|
@font-path: '@{root-path}/@{file}';
|
||
|
|
||
|
@font-face {
|
||
|
font-family: @name;
|
||
|
font-weight: @weight;
|
||
|
font-style: @style;
|
||
|
src: url(@font-path);
|
||
|
}
|
||
|
|
||
|
}
|
||
|
|
||
|
.font (@name, @weight, @style, @file)
|
||
|
when (@weight = bold)
|
||
|
and (@style = normal) {
|
||
|
|
||
|
|
||
|
@font-path: '@{root-path}/@{file}';
|
||
|
|
||
|
@font-face {
|
||
|
font-family: @name;
|
||
|
font-weight: @weight;
|
||
|
font-style: @style;
|
||
|
src: url(@font-path);
|
||
|
}
|
||
|
|
||
|
}
|
||
|
|
||
|
.font (@name, @weight, @style, @file)
|
||
|
when (@weight = normal)
|
||
|
and (@style = italic) {
|
||
|
|
||
|
|
||
|
@font-path: '@{root-path}/@{file}';
|
||
|
|
||
|
@font-face {
|
||
|
font-family: @name;
|
||
|
font-weight: @weight;
|
||
|
font-style: @style;
|
||
|
src: url(@font-path);
|
||
|
}
|
||
|
|
||
|
}
|
||
|
|
||
|
.font (@name, @weight, @style, @file)
|
||
|
when (@weight = 'bold')
|
||
|
and (@style = 'italic') {
|
||
|
|
||
|
|
||
|
@font-path: '@{root-path}/@{file}';
|
||
|
|
||
|
@font-face {
|
||
|
font-family: @name;
|
||
|
font-weight: @weight;
|
||
|
font-style: @style;
|
||
|
src: url(@font-path);
|
||
|
}
|
||
|
|
||
|
}
|