barItemStyle.js 650 B

1234567891011121314151617
  1. var makeStyleMapper = require("../../model/mixin/makeStyleMapper");
  2. var getBarItemStyle = makeStyleMapper([['fill', 'color'], ['stroke', 'borderColor'], ['lineWidth', 'borderWidth'], // Compatitable with 2
  3. ['stroke', 'barBorderColor'], ['lineWidth', 'barBorderWidth'], ['opacity'], ['shadowBlur'], ['shadowOffsetX'], ['shadowOffsetY'], ['shadowColor']]);
  4. var _default = {
  5. getBarItemStyle: function (excludes) {
  6. var style = getBarItemStyle(this, excludes);
  7. if (this.getBorderLineDash) {
  8. var lineDash = this.getBorderLineDash();
  9. lineDash && (style.lineDash = lineDash);
  10. }
  11. return style;
  12. }
  13. };
  14. module.exports = _default;