2017-03-09 64 views
1

https://js.devexpress.com/Documentation/16_2/ApiReference/UI_Widgets/dxDataGrid/Angular2 - 如何改變DevExtreme負荷指標的大小,DataGrid控件

以上是由Devextreme團隊提供的API參考。我已使用loadPanel屬性更改微調指示器指向一個自定義gif。 這裏是由Devextreme隊

loadPanel: { 
    enabled: "auto", 
    height: 90, 
    indicatorSrc: "", 
    showIndicator: true, 
    showPane: true, 
    text: "Loading...", 
    width: 200 
} 

,我已經改變了喜歡的東西暴露的財產,

loadPanel: { 
    enabled: "auto", 
    height: 90, 
    indicatorSrc: "images/MyCustom.gif", 
    showIndicator: true, 
    showPane: false, 
    text: "Loading...", 
    width: 200 
} 

然而,GIF出現萎縮和高度寬度屬性僅爲它周圍的框窗格的大小。試圖通過設置指標類的CSS樣式來改變大小,但沒有工作

/deep/ .dx-loadindicator-content { 
    width: 200px; 
    height: 200px; 
} 

任何人都可以實現這一目標嗎?

+0

你從哪裏寫這個css規則? – yurzui

+0

在組件的CSS – lohiarahul

+0

鏈接不起作用 – lohiarahul

回答

1

loadPanel.widthloadPanel.height選項直接與負載板幾何形狀相連。它們不會影響圖標大小。但是,您可以通過CSS自定義圖標大小,就像您在問題中指出的一樣。只需使用下面的CSS選擇器:

/deep/ .dx-datagrid .dx-loadindicator { 
    width: 64px; 
    height: 64px; 
} 
+1

工作。非常感謝。猜猜我對CSS不好。 :) – lohiarahul