You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

21 lines
692 B

4 years ago
  1. 'use strict';
  2. Object.defineProperty(exports, "__esModule", {
  3. value: true
  4. });
  5. var _replaceValueSymbols = require('./replaceValueSymbols.js');
  6. var _replaceValueSymbols2 = _interopRequireDefault(_replaceValueSymbols);
  7. function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
  8. var replaceSymbols = function replaceSymbols(css, replacements) {
  9. css.walkDecls(function (decl) {
  10. return decl.value = (0, _replaceValueSymbols2.default)(decl.value, replacements);
  11. });
  12. css.walkAtRules('media', function (atRule) {
  13. return atRule.params = (0, _replaceValueSymbols2.default)(atRule.params, replacements);
  14. });
  15. };
  16. exports.default = replaceSymbols;