ExtJS Classic:设置resizable=true的TextArea无法调整大小的问题
ExtJS TextArea设置
resizable: true后无法调整大小的问题 我创建了一个示例,运行后发现,即使给TextArea设置了resizable: true属性,仍无法调整大小。
Ext.application({ name: 'Fiddle', launch: function () { var shows = Ext.create('Ext.data.Store', { fields: ['id', 'show'], data: [{ id: 0, show: 'Battlestar Galactica' }, { id: 1, show: 'Doctor Who' }, { id: 2, show: 'Farscape' }, { id: 3, show: 'Firefly' }, { id: 4, show: 'Star Trek' }, { id: 5, show: 'Star Wars: Christmas Special' }] }); Ext.create('Ext.form.Panel', { renderTo: Ext.getBody(), title: 'Sci-Fi Television', width: 400, frame: true, resizable: true, items: [{ xtype: 'tagfield', fieldLabel: 'Select a Show', store: shows, displayField: 'show', valueField: 'id', queryMode: 'local', filterPickList: true }, { xtype: 'textareafield', resizable: true, fieldLabel: 'Some label', anchor: '100%', //resizeHandles: 's', //grow: true }] }); } });
请问我遗漏了什么?
为排查问题,我查看了官方文档,修改了文档示例代码:
Ext.create('Ext.form.FormPanel', { title : 'Sample TextArea', width : 400, bodyPadding: 10, renderTo : Ext.getBody(), items: [{ xtype : 'textareafield', grow : true, name : 'message', fieldLabel: 'Message', anchor : '100%', resizable: true, }] });
添加resizable: true行后,运行鼠标悬停可看到灰色调整条(调整条显示正常)。但在自己的表单中,鼠标悬停任何位置都不显示灰色调整条;若添加grow: true,则出现UI错位——灰色调整条虽显示但位置错误(调整条位置错位)。
如何让表单显示正常,同时实现TextArea的垂直调整?
内容的提问来源于stack exchange,提问作者boggy
相关产品推荐
相关产品推荐

