self-resize working