Extjs scrollable panel

2020-04-02 00:56发布

I have a panel where I insert some HTML from the server:

myPanel.update(response.responseText);

But if this text is too big, none of the scrollbars appear to navigate the text.

How can I configure a vertical scrollbar in this panel?

This is my panel definition:

{
  xtype:'panel',
  width: '100%',
  height: 300,
  id:'mypanel'
},

Thanks.

标签: Extjs extjs4
3条回答
家丑人穷心不美
2楼-- · 2020-04-02 01:21

Basically you would just add the autoScroll property like

autoScroll: true

Here's a working JSFiddle

查看更多
啃猪蹄的小仙女
3楼-- · 2020-04-02 01:37

Actually you should have two properties together:

autoScroll: 'true'

and

height: 300

They work together, one without the other will not produce the scroll bar.

查看更多
Explosion°爆炸
4楼-- · 2020-04-02 01:39

...or if you always want a vertical scrollbar

overflowY: 'scroll'
查看更多
登录 后发表回答