modal box react to window resizing
ensure jquery lib is the first loaded