import React from 'react' ; import { Observable } from 'rxjs' ; import useObservable from 'react-use/lib/useObservable' ; import classNames from 'classnames' ; import { APP_WRAPPER_CLASS } from '../../utils' ; export const AppWrapper = ( { chromeVisible$ , children } ) => { const visible = useObservable ( chromeVisible$ ) ; return ( < div className = { classNames ( APP_WRAPPER_CLASS , { 'kbnAppWrapper--hiddenChrome' : ! visible } ) } > { children } < /div>); } ;