import{makeStyle as e}from"@gem-sdk/core";let t=e=>Object.keys(e??{}).filter(e=>["--d","--d-mobile","--d-tablet"].includes(e)).reduce((t,b)=>({...t,[b]:e?.[b]}),{}),b=e=>Object.keys(e??{}).filter(e=>["--d","--d-mobile","--d-tablet"].includes(e)).reduce((t,b)=>({...t,[b.replace("--d","--pe")]:e?.[b]==="none"?"none":"auto"}),{}),l=e=>Object.keys(e??{}).filter(e=>["--bw","--bw-mobile","--bw-tablet","--bc","--bc-tablet","--bc-mobile","--b","--b-tablet","--b-mobile","--bs","--bs-tablet","--bs-mobile","--radius","--radius-tablet","--radius-mobile","--bblr","--bbrr","--btlr","--btrr","--bblr-tablet","--bbrr-tablet","--btlr-tablet","--btrr-tablet","--bblr-mobile","--bbrr-mobile","--btlr-mobile","--btrr-mobile"].includes(e)).reduce((t,b)=>({...t,[b]:e?.[b]}),{}),i=e=>Object.keys(e??{}).filter(e=>e.startsWith("--mt")||e.startsWith("--mb")||e.startsWith("--ml")||e.startsWith("--mr")).reduce((t,b)=>({...t,[b]:e?.[b]}),{}),r=e=>Object.keys(e??{}).filter(b=>!Object.keys(i(e)).includes(b)&&!Object.keys(t(e)).includes(b)&&!Object.keys(l(e)).includes(b)).reduce((t,b)=>({...t,[b]:e?.[b]}),{}),a=(e="",t="")=>({id:`dialog:${e}:${t}`,time:`dialog:${e}:${t}:time`}),o=(e,t=0)=>{let b=e?new Date(Number(e)):new Date,l=Date.now()-b.getTime();return Math.abs(l/24/60/60/1e3)>=t},s=e=>!!/Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(e),d=(e,t)=>"tablet"===t?e?.tablet??e?.desktop:"mobile"===t?e?.mobile??e?.tablet??e?.desktop:e?.desktop,m=(t,b)=>({...t?.desktop?e({h:"100%"}):b?.desktop?e({h:b.desktop}):e({minh:"300px"}),"--h-tablet":d(t,"tablet")?"100%":d(b,"tablet")??"300px","--h-mobile":d(t,"mobile")?"100%":d(b,"mobile")??"300px","--maxh":d(t,"desktop")?"100%":"","--maxh-tablet":d(t,"tablet")?"100%":"","--maxh-mobile":d(t,"mobile")?"100%":""}),c=e=>({...e,"--h":e["--h"]?.includes("%")?"100%":e["--h"],"--h-tablet":e["--h-tablet"]?.includes("%")?"100%":e["--h-tablet"],"--h-mobile":e["--h-mobile"]?.includes("%")?"100%":e["--h-mobile"]}),n=e=>{let t=parseFloat(e?.toString()??"0");return isNaN(t)?0:t},h=e=>"number"!=typeof e||isNaN(e)?"string"==typeof e?parseFloat(e)+"%":"0%":e+"%";export{a as createDialogKey,l as getBorderStyle,t as getDisplayStyle,r as getInnerStyle,h as getOverlayOpacity,d as getPropertyByDevice,i as getWrapperDialogStyle,m as heightStyle,s as isMobile,o as isShowModal,n as parseNumber,b as pointerEventStyle,c as removeHeightPercentForContent};
