resize - Extjs5 Textarea Resizing -


i have following form defined:

ext.define('admin.view.messaging.msgdataform',{     extend: 'ext.window.window',     xtype: 'msgdataform',     title: 'compose practice message',               defaultfocus: '[name=subject]',          modal: true,                 layout: 'fit',       closable: false,     width: 700,      items: [{         xtype: 'form',               layout: 'anchor',         fielddefaults: {labelwidth: 60,labelalign: 'right',anchor: '100%'},         padding: 10,         items: [{                        xtype: 'fieldcontainer',             layout: 'hbox',             fieldlabel: 'date',                                                          items: [{                 xtype: 'datefield',                 name: 'msgdate',                                     format: 'f j, y g:i a',                 readonly: true,                 flex: 1,                 margin: '0 5 0 0'             },{                 xtype: 'combo',                 name: 'priority',                            fieldlabel: 'priority',                 store: ext.create('ext.data.store',{                     fields: ['priorityval','priority'],                     data: [{'priorityval':0,'priority':'low'},{'priorityval':1,'priority':'normal'},{'priorityval':2,'priority':'high'}]                 }),                 querymode: 'local',                 displayfield: 'priority',                 valuefield: 'priorityval',                 width: 160             }]                       },{             xtype: 'textfield',             name: 'subject',                 fieldlabel: 'subject'         },{             xtype: 'textarea',             id: 'editor1',             name: 'message',                         style: {background: '#e1e1e1'}         }]     }],     buttons:[{         text: 'send',         handler: 'onclick_btnmsgdatasend'     },{         text: 'cancel',              handler: 'onclick_btnmsddatacancel'     }] }); 

the height of textarea not sized when window rendered. additionally, when window resized, width of textarea resized - not height. attempting listen resize event on text area after window resized isn't fired. ideas? thanks.

you width resized because of default configuration of 'anchor:100%'.

on other hand, height it's little bit more difficult, idea comes me try particular css (using property cls) manipulate height (height:'100%') or that. because can't use flex in textarea, nest de textarea in panel , use flex on try it.

check documentation of textarea of extjs5 other posible solutions: http://docs.sencha.com/extjs/5.0/5.0.1-apidocs/#!/api/ext.form.field.textarea


Comments

Popular posts from this blog

php - failed to open stream: HTTP request failed! HTTP/1.0 400 Bad Request -

java - How to filter a backspace keyboard input -

java - Show Soft Keyboard when EditText Appears -