Module 597619

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