Fix parsing z-index from parent elems
Fix parsing z-index from parent elems

This fixes parsing z-index values from parent elems. This was
noticed while testing a datepicker on a modal. The datepicker
wasn't properly parsing its parent modals z-index so its dropdown
was appearing behind the modal. This fixes the parent z-index
parsing by having it properly short-circuit the loop. Previously
we were using return which in javascript only returns out of the
loop and not out of the function as a whole. Now the function
checks if it has a non zero z-index value and if so it stops
parsing parent elems z-index values and returns the non-zero
parent z-index.

redding/romo,redding/romo,redding/romo