Reputation: 4283
I setup my tagfield value by using class,
.x-tagfield-input-field {
width: 3px;
}
I want to change width after selecting first element.
select : function(tag){
var tagClass = component.inputCell.dom.getElementsByClassName("x-tagfield-input");
}
How to change the width after first element selection?
Upvotes: 0
Views: 420
Reputation: 902
ExtJS provides addCls()
method to add class dynamically. If you are giving width in class then add new class as tagClass.addCls(<new class name>)
. If you want to specify width on the fly then use setWidth()
as tagClass.setWidth(width in pixels)
.
Check this and reply.
Upvotes: 1