在无法调整浏览器窗口大小之前,无法正确查看px-vis-timeseries图形

时间:2018-11-15 11:45:40

标签: css polymer time-series predix

我正在使用以下px-vis-timeseries图形配置,并根据资产选择显示图形。

 <px-card header-text="Rotor - Lifetime Remaining ">
      <div style='height: 350px;'>
      <px-vis-timeseries
        width="1000" 
        height="250"
        margin='{"top":30,"bottom":60,"left":65,"right":65}' 
        register-config='{"type":"vertical","width":200}'
        selection-type="xy" 
        chart-data="{{ltuchartData}}" 
        series-config="[[LTUseriesConfig]]"
        chart-extents="[[_chartExtents]]" 
        prevent-web-worker-synchronization="true"
        event-config='{}'
        threshold-data='[
          {"for": "y0","type": "max", "value": 50}, 
          {"for": "y0","type": "min","value": 25}]'
        threshold-config='{
          "max": {"color": "orange","dashPattern": "5,0","title": "LIFE TIME ASSESSMENT",
            "showThresholdBox": true,"displayTitle": true},
          "min": {"color": "red","dashPattern": "5,0", "title": "INCREASED RISK OF FAILURE",
            "showThresholdBox": true,"displayTitle": true}}'
        x-axis-config='{"title":"Time"}' 
        y-axis-config='{"axis1":{"title":"Remaining","titleTruncation":false,"unit":"%"}}'
        hide-gridlines-x="true" 
        hide-gridlines-y="true" 
        disable-navigator="true" 
        toolbar-config="{{ToolbarConfig}}">
      </px-vis-timeseries>
    </div>
  </px-card>

我的问题是,当我第一次从上下文浏览器中选择资产时,此时没有正确获取图形视图作为附加快照,那么我需要调整浏览器窗口的大小,然后才能正确获取图形视图,并且如果我给属性prevent-resize =如果在px-vis-timeseries配置中为true,则每次都能正确获取图形,但是在这种情况下,我的图形没有响应,我们也需要响应图,因此我无法使用prevent-resize来解决此问题。

如果有人可以向我提供一些指导或建议来解决此问题,我将不胜感激。enter image description here

0 个答案:

没有答案