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.

47 lines
1.8 KiB

4 years ago
  1. "use strict";
  2. function _defaults(obj, defaults) { var keys = Object.getOwnPropertyNames(defaults); for (var i = 0; i < keys.length; i++) { var key = keys[i]; var value = Object.getOwnPropertyDescriptor(defaults, key); if (value && value.configurable && obj[key] === undefined) { Object.defineProperty(obj, key, value); } } return obj; }
  3. function _inheritsLoose(subClass, superClass) { subClass.prototype = Object.create(superClass.prototype); subClass.prototype.constructor = subClass; _defaults(subClass, superClass); }
  4. function _defineProperty(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
  5. var Declaration = require('../declaration');
  6. var MaskBorder =
  7. /*#__PURE__*/
  8. function (_Declaration) {
  9. _inheritsLoose(MaskBorder, _Declaration);
  10. function MaskBorder() {
  11. return _Declaration.apply(this, arguments) || this;
  12. }
  13. var _proto = MaskBorder.prototype;
  14. /**
  15. * Return property name by final spec
  16. */
  17. _proto.normalize = function normalize() {
  18. return this.name.replace('box-image', 'border');
  19. }
  20. /**
  21. * Return flex property for 2012 spec
  22. */
  23. ;
  24. _proto.prefixed = function prefixed(prop, prefix) {
  25. var result = _Declaration.prototype.prefixed.call(this, prop, prefix);
  26. if (prefix === '-webkit-') {
  27. result = result.replace('border', 'box-image');
  28. }
  29. return result;
  30. };
  31. return MaskBorder;
  32. }(Declaration);
  33. _defineProperty(MaskBorder, "names", ['mask-border', 'mask-border-source', 'mask-border-slice', 'mask-border-width', 'mask-border-outset', 'mask-border-repeat', 'mask-box-image', 'mask-box-image-source', 'mask-box-image-slice', 'mask-box-image-width', 'mask-box-image-outset', 'mask-box-image-repeat']);
  34. module.exports = MaskBorder;