MDL-42407 Filepicker: generate a smarter zIndex for the filepicker