diff --git a/app/src/components/portal/index.js b/app/src/components/portal/index.js index 9cc49327378..44a2d3f7805 100644 --- a/app/src/components/portal/index.js +++ b/app/src/components/portal/index.js @@ -1,6 +1,7 @@ // @flow import * as React from 'react' import ReactDom from 'react-dom' +import { Box } from '@opentrons/components' type PortalLevel = 'page' | 'top' @@ -13,20 +14,25 @@ type State = {| hasRoot: boolean, |} -const PORTAL_ROOT_ID_BY_LEVEL: { [PortalLevel]: string } = { - page: '__otAppModalPortalRoot', - top: '__otAppTopPortalRoot', +type PortalLevelInfo = {| + id: string, + zIndex: number | string, +|} + +const PORTAL_ROOT_PROPS_BY_LEVEL: { [PortalLevel]: PortalLevelInfo } = { + page: { id: '__otAppModalPortalRoot', zIndex: 1 }, + top: { id: '__otAppTopPortalRoot', zIndex: 10 }, } const getPortalRoot = level => - global.document.getElementById(PORTAL_ROOT_ID_BY_LEVEL[level]) + global.document.getElementById(PORTAL_ROOT_PROPS_BY_LEVEL[level].id) export function PortalRoot(): React.Node { - return
+ return