echarts icon indicating copy to clipboard operation
echarts copied to clipboard

图表的容器dom隐藏后然后显示。出现的图表太小了。

Open shikelong opened this issue 11 years ago • 2 comments

 <!--饼图 -->
            <div ng-show="showChartType=='pie'">              
                        <!-- pie:上报事件比例图:全院及科室-->
                        <div class="col echartContent" id="eventsProportionPie" ng-controller="eventProportionController"></div>         
            </div>
            <!--柏拉图 -->
            <div ng-show="showChartType=='plato'">
                 <div class="echartContent" id="plato"></div>
            </div>
            <!--折线图 -->
            <div ng-show="showChartType=='line'">
                 <div class="echartContent" ng-controller="trendLineController" id="trendLine"></div>
            </div>

···css .echartContent{

width: 100%;
height: 400px;

}


类似于这样的写法。在页面加载完成以后的图表显示正常。然后切换图标的隐藏显示之后,图表就很小。 如果把dom容器的width定义为绝对的px.那么图表大小不变。 请问有其他方法能解决这个问题吗? 

![plato](https://cloud.githubusercontent.com/assets/4499997/7826891/e39c4cd2-0452-11e5-97e3-239e0c77592e.png)

shikelong avatar May 27 '15 01:05 shikelong

这个问题还解决不了吗

shenmegui9 avatar Aug 02 '17 06:08 shenmegui9

@shenmegui9 找一个合适的时机 调用echart实例的resize方法试试。

shikelong avatar Aug 02 '17 07:08 shikelong