How to Remove JS charts by amcharts text in amchart?

风格不统一 提交于 2019-12-08 20:38:13

问题


How can I Remove "Js charts by amcharts" Text from the amchart bar chart. is there a way to do this using chart configuration? Please check the text in Fiddle.


回答1:


The branding text is on the free version. If you want to remove the text, you have to purchase a license. See the license FAQ for information on what license is appropriate for your use case.

If you already have a license and are using AmCharts v3, just download the files from the support site, upload them to your web server and use those instead of the files on the AmCharts CDN. If you're using npm or just wish to use the CDN files with your license, contact AmCharts for instructions on how to apply your license.

If you have a license and you are using AmCharts v4, the instructions are available in your support account.

Finally, if you're still having trouble, contact AmCharts and provide your order details.

We don't provide instructions on how to hide credits on a public forum for obvious reasons.




回答2:


Going to in your angular project :-

Node modules -> @amcharts -> amcharts4 -> internal -> core -> elements -> amchartslogo.js

 then replace function-
    function AmChartsLogo() {
    var _this =
    // Init
    _super.call(this) || this;
    _this.className = "AmChartsLogo";
    _this.valign = "bottom";
    var d = 0;
    _this.opacity = 0;
    _this.defaultState.properties.opacity = 0;
    _this.url = "https://www.amcharts.com/";
    _this.urlTarget = "_blank";
    _this.showSystemTooltip = true;
    _this.readerTitle = "Chart created using amCharts library";
    _this.width = 220 * d;
    _this.height = 70 * d;
    _this.background.opacity = 0;
    var aColor = color("#474758");
    if (new InterfaceColorSet().getFor("background").alternative.hex == "#ffffff") {
        aColor = color("#ffffff");
    }
    var aGradient = new LinearGradient();
    aGradient.addColor(aColor);
    aGradient.addColor(aColor, 1, 0.75);
    aGradient.addColor(color("#3cabff"), 1, 0.755);
    aGradient.rotation = -10;
    var aStroke = aGradient;
    var m = _this.createChild(Polyspline);
    m.shouldClone = false;
    m.isMeasured = false;
    m.segments = [[{ x: 50 * d, y: 50 * d }, { x: 90 * d, y: 50 * d }, { x: 120 * d, y: 20 * d }, { x: 135 * d, y: 35 * d }, { x: 150 * d, y: 20 * d }, { x: 180 * d, y: 50 * d }, { x: 200 * d, y: 50 * d }]];
    m.strokeWidth = 6 * d;
    m.tensionX = 0.8;
    m.tensionY = 1;
    m.stroke = color("#3cabff");
    var a = _this.createChild(Polyspline);
    a.shouldClone = false;
    a.isMeasured = false;
    a.segments = [[{ x: 20 * d, y: 50 * d }, { x: 50 * d, y: 50 * d }, { x: 90 * d, y: 12 * d }, { x: 133 * d, y: 50 * d }, { x: 170 * d, y: 50 * d }, { x: 200 * d, y: 50 * d }]];
    a.strokeWidth = 6 * d;
    a.tensionX = 0.75;
    a.tensionY = 1;
    a.stroke = aStroke;
    _this._disposers.push(a);
    var desaturateFilter = new DesaturateFilter();
    _this.filters.push(desaturateFilter);
    var desaturateFilterHover = new DesaturateFilter();
    desaturateFilterHover.saturation = 1;
    var hoverState = _this.states.create("hover");
    hoverState.properties.opacity = 1;
    hoverState.filters.push(desaturateFilterHover);
    // Apply theme
    _this.applyTheme();
    return _this;
}



回答3:


.amcharts-chart-div > a {
    display: none !important;
}



回答4:


Go to amchart.js Then find this text and remove it(e="")




回答5:


jQuery(document).ajaxComplete(function() {
    jQuery("a[title='JavaScript charts']").remove();
});


来源:https://stackoverflow.com/questions/43109984/how-to-remove-js-charts-by-amcharts-text-in-amchart

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!