Issue while using Containment

Issue while using Containment

Hi,
 
I am using containment function for constrainting resizablility of a div component.
 
Queries:
1. while stretching div component from left, the position of component is changing ie. reaching to top side of the specified container.
2.while stretching div component from right,i am able to stretch it to half of the specified container only but not the full container.
3.while repositioning the stretched div,the size of top and width are increasing inversely proportionally.
 
Requirement:
I want div component to resize from left and right in the same row with no increase in height or top.
 
Please suggest something!!