项目原始demo,不改动
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.
This repo is archived. You can view files and clone it, but cannot push or open issues/pull-requests.
 
 
 
 

30 line
780 B

  1. 'use strict';
  2. Object.defineProperty(exports, '__esModule', {
  3. value: true
  4. });
  5. var important = function important(node) {
  6. return node.important;
  7. };
  8. var unimportant = function unimportant(node) {
  9. return !node.important;
  10. };
  11. var hasInherit = function hasInherit(node) {
  12. return ~node.value.indexOf('inherit');
  13. };
  14. var hasInitial = function hasInitial(node) {
  15. return ~node.value.indexOf('initial');
  16. };
  17. exports['default'] = function () {
  18. for (var _len = arguments.length, props = Array(_len), _key = 0; _key < _len; _key++) {
  19. props[_key] = arguments[_key];
  20. }
  21. if (props.some(hasInherit) || props.some(hasInitial)) {
  22. return false;
  23. }
  24. return props.every(important) || props.every(unimportant);
  25. };
  26. module.exports = exports['default'];