Adjust text box size for linked contents