Take into account the parentElement dimensions for embedded version