main
Last change
on this file was 79a0317, checked in by stefan toskovski <stefantoska84@…>, 6 days ago |
F4 Finalna Verzija
|
-
Property mode
set to
100644
|
File size:
513 bytes
|
Rev | Line | |
---|
[79a0317] | 1 | var OptimizationLevel = require('../../../options/optimization-level').OptimizationLevel;
|
---|
| 2 |
|
---|
| 3 | var plugin = {
|
---|
| 4 | level1: {
|
---|
| 5 | property: function fontWeight(_rule, property, options) {
|
---|
| 6 | var value = property.value[0][1];
|
---|
| 7 |
|
---|
| 8 | if (!options.level[OptimizationLevel.One].optimizeFontWeight) {
|
---|
| 9 | return;
|
---|
| 10 | }
|
---|
| 11 |
|
---|
| 12 | if (value == 'normal') {
|
---|
| 13 | value = '400';
|
---|
| 14 | } else if (value == 'bold') {
|
---|
| 15 | value = '700';
|
---|
| 16 | }
|
---|
| 17 |
|
---|
| 18 | property.value[0][1] = value;
|
---|
| 19 | }
|
---|
| 20 | }
|
---|
| 21 | };
|
---|
| 22 |
|
---|
| 23 | module.exports = plugin;
|
---|
Note:
See
TracBrowser
for help on using the repository browser.