@antv/g2plot
Version:
G2 Plot, a market of plots built with the Grammar of Graphics'
24 lines • 914 B
JavaScript
import { __extends } from "tslib";
import ApplyResponsiveLabel from '../../../util/responsive/apply/label';
var ApplyResponsiveLineLabel = /** @class */ (function (_super) {
__extends(ApplyResponsiveLineLabel, _super);
function ApplyResponsiveLineLabel() {
return _super !== null && _super.apply(this, arguments) || this;
}
ApplyResponsiveLineLabel.prototype.getType = function () {
var props = this.plot.options;
if (props.label && props.label.type) {
return props.label.type;
}
return 'point';
};
return ApplyResponsiveLineLabel;
}(ApplyResponsiveLabel));
export default function responsivePointLabel(layer) {
var responsiveTheme = layer.getResponsiveTheme();
var applyResponsiveLineLabel = new ApplyResponsiveLineLabel({
plot: layer,
responsiveTheme: responsiveTheme,
});
}
//# sourceMappingURL=label.js.map