@antv/g2plot
Version:
G2 Plot, a market of plots built with the Grammar of Graphics'
27 lines • 1.03 kB
JavaScript
;
Object.defineProperty(exports, "__esModule", { value: true });
var tslib_1 = require("tslib");
var label_1 = tslib_1.__importDefault(require("../../../util/responsive/apply/label"));
var ApplyResponsiveLineLabel = /** @class */ (function (_super) {
tslib_1.__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;
}(label_1.default));
function responsivePointLabel(layer) {
var responsiveTheme = layer.getResponsiveTheme();
var applyResponsiveLineLabel = new ApplyResponsiveLineLabel({
plot: layer,
responsiveTheme: responsiveTheme,
});
}
exports.default = responsivePointLabel;
//# sourceMappingURL=label.js.map