import{__assign as o}from'./../../../ext-esm/tslib/tslib.es6.js';import{jsxs as t,jsx as i}from"react/jsx-runtime";import s from"classnames";import{makeStyles as e,useTheme as n}from"@material-ui/core";import{CenterAlignmentIcon as c}from"../../../icons/iconParkIcons.js";import"../../../icons/customIcons/icons/AddMessage.js";import"../../../icons/customIcons/icons/Attention.js";import"../../../icons/customIcons/icons/Collapse.js";import"../../../icons/customIcons/icons/Expand.js";import"../../../icons/customIcons/icons/FolderClosed.js";import"../../../icons/customIcons/icons/FolderClosedFilled.js";import"../../../icons/customIcons/icons/FolderOpened.js";import"../../../icons/customIcons/icons/GreaterOrEqual.js";import"../../../icons/customIcons/icons/LessOrEqual.js";import"../../../icons/customIcons/icons/Search.js";import"../../../icons/customIcons/icons/Wellhub.js";import"../../../icons/customIcons/icons/MultiRuler.js";import"../../../icons/customIcons/icons/Checkbox.js";import"../../../icons/customIcons/icons/CheckboxChecked.js";import"../../../icons/customIcons/icons/CheckboxIndeterminate.js";import"../../../icons/customIcons/icons/Radio.js";import"../../../icons/customIcons/icons/RadioChecked.js";import"../../../icons/customIcons/icons/SimulFrac.js";import"../../../icons/customIcons/icons/ZipperFrac.js";import"../../../icons/customIcons/icons/CautionFilled.js";import r from"../AppSideBar/AppSideBar.js";import p from"../../IconButton/index.js";import{AppSettingsPopover as m}from"../AppSettingsPopover/AppSettingsPopover.js";import a from"../../Button/components/Button/index.js";import"moment-timezone";import"../../Button/components/LiveButton/components/LiveButtonStateIndicator/index.js";import"../../Button/components/LiveButton/styles.js";import{useMatchAppContainerSize as l}from"../../../effects/useMatchAppContainerSize.js";import{isNativeDetected as d,isMobileDetected as u}from"../../../utils/mobileDetect.js";var h=e({appLayout:{display:"flex",flexDirection:"column",width:"100%",height:"100%"},header:{paddingLeft:12,paddingRight:12,display:"flex",height:36},contentWrapper:{display:"flex",position:"relative",flexGrow:1,height:"calc(100% - 36px)","@media (max-width: 960px)":{height:"100%"}},content:{display:"flex",flexDirection:"column",textAlign:"center",alignItems:"center",justifyContent:"center",height:"100%",width:"100%"},popoverContent:{padding:"0 16px"},filtersTrigger:{width:30,height:30}}),j=function(t){var s=n(),e=l({width:{max:s.breakpoints.width("md")}}),r=h();return e?i(p,o({className:r.filtersTrigger,size:"small",tooltipProps:{title:"Filters"},variant:"contained"},t,{children:i(c,{size:16})})):i(a,o({startIcon:i(c,{size:16})},t,{children:"Filters"}))},f=function(e){var c=e.appSettingsPopoverProps,p=e.children,a=e.classes,f=void 0===a?{}:a,I=e.header,g=e.sideBarContent,x=e.sideBarProps,v=h(),C=n(),B=l({width:{max:C.breakpoints.width("md")}}),F=d||u||B;return t("div",o({className:s(v.appLayout,f.appLayout)},{children:[F&&t("div",o({className:s(v.header,f.header)},{children:[i(m,o({Trigger:j,classes:{popoverContent:v.popoverContent},header:"Filters",anchorOrigin:{vertical:"top",horizontal:"left"},transformOrigin:{vertical:"top",horizontal:"left"}},c,{children:g})),I]})),t("div",o({className:s(v.contentWrapper,f.contentWrapper)},{children:[!F&&i(r,o({},x,{anchor:"left"},{children:g})),p&&i("div",o({className:s(v.content,f.content)},{children:p}))]}))]}))};export{f as AppFilterPanelLayout};
