Module 597619

2,124 characters · in no known chunk
Dependencies
Lazily required by (0)none
Lazily requires (0)none
Source Raw
function(e,t,n){"use strict";n.d(t,{xb:()=>g,fs:()=>A});var i=n(627968),r=n(64700),s=n(503698),a=n.n(s),o=n(607399),l=n(17928),u=n(112834),c=n(964486),d=n(775602),_=n(723702),f=n(614738),h=n(354328),p=n(742023),E=n(19575);let m=r.createContext({lang:"",style:"",className:"",focused:!1});function g(){let e=r.useContext(m);if(void 0===e)throw Error("useRootElementContext must be used within a RootElementContextProvider");return e}function A(e){let t,{rootClassName:n,lang:s,theme:g,density:A,focused:I,fontScale:T,fontScaleClass:S,mouseMode:N,keyboardModeEnabled:y,saturation:C,desaturateUserColors:v,useForcedColors:O,systemForcedColors:R,useReducedMotion:b,alwaysShowLinkDecorations:D,hardwareAccelerationEnabled:L,highContrastMode:w,isPopoutWindow:M,children:P}=e,x=window.CSS.supports("selector(::-webkit-scrollbar)"),U=(0,l.bG)([d.A],()=>d.A.zoom),k=M?"":`--custom-zoom: ${U};`,G=(0,h.A)("highlight_mana_buttons"),F=(0,h.A)("highlight_mana_components"),V=(0,h.A)("highlight_void_toggleables"),B=(0,h.A)("highlight_void_buttons"),H=(0,l.bG)([p.Ay],()=>p.Ay.hdrDynamicRange),j=`font-size: ${T}%; --saturation-factor: ${C}; dynamic-range-limit: ${H}; ${k}`,Y=a()((t="",(0,_.isWindows)()?t="platform-win":(0,_.isMac)()?t="platform-osx":(0,_.isLinux)()?t="platform-linux":(0,_.isWeb)()&&(t="platform-web"),__OVERLAY__?`${t} platform-overlay`:t),(0,u.m)(g),`density-${A}`,S,{"low-saturation":C<=.4,"keyboard-mode":y,"decorate-links":D,"no-webkit-scrollbar":!x,"has-webkit-scrollbar":x,"mouse-mode":N,"reduce-motion":b,"full-motion":!b,"is-mobile":o.Fr,"app-focused":I,"desaturate-user-colors":v,"disable-forced-colors":!O&&"active"===R,"enable-forced-colors":O,"visual-refresh":!0,"hardware-acceleration-disabled":!L,"visual-refresh-chat-input":!1,"mana-toggle-inputs":(0,f.y)("RootElementContextProvider"),"highlight-mana-buttons":G,"highlight-mana-components":F,"highlight-void-toggleables":V,"highlight-void-buttons":B,"high-contrast-mode":w},n),W=r.useMemo(()=>({lang:s,style:j,className:Y,focused:I}),[s,j,Y,I]);return(0,c.Ay)(()=>{E.Ay.setTrafficLightPosition({x:9,y:9})}),(0,i.jsx)(m.Provider,{value:W,children:P})}}