securityos/node_modules/fscreen/dist/fscreen.cjs.production.js.map

1 line
4.0 KiB
Plaintext

{"version":3,"file":"fscreen.cjs.production.js","sources":["../src/fscreen.js"],"sourcesContent":["const key = {\n fullscreenEnabled: 0,\n fullscreenElement: 1,\n requestFullscreen: 2,\n exitFullscreen: 3,\n fullscreenchange: 4,\n fullscreenerror: 5,\n fullscreen: 6\n};\n\nconst webkit = [\n 'webkitFullscreenEnabled',\n 'webkitFullscreenElement',\n 'webkitRequestFullscreen',\n 'webkitExitFullscreen',\n 'webkitfullscreenchange',\n 'webkitfullscreenerror',\n '-webkit-full-screen',\n];\n\nconst moz = [\n 'mozFullScreenEnabled',\n 'mozFullScreenElement',\n 'mozRequestFullScreen',\n 'mozCancelFullScreen',\n 'mozfullscreenchange',\n 'mozfullscreenerror',\n '-moz-full-screen',\n];\n\nconst ms = [\n 'msFullscreenEnabled',\n 'msFullscreenElement',\n 'msRequestFullscreen',\n 'msExitFullscreen',\n 'MSFullscreenChange',\n 'MSFullscreenError',\n '-ms-fullscreen',\n];\n\n// so it doesn't throw if no window or document\nconst document = typeof window !== 'undefined' && typeof window.document !== 'undefined' ? window.document : {};\n\nconst vendor = (\n ('fullscreenEnabled' in document && Object.keys(key)) ||\n (webkit[0] in document && webkit) ||\n (moz[0] in document && moz) ||\n (ms[0] in document && ms) ||\n []\n);\n\nexport default {\n requestFullscreen: element => element[vendor[key.requestFullscreen]](),\n requestFullscreenFunction: element => element[vendor[key.requestFullscreen]],\n get exitFullscreen() { return document[vendor[key.exitFullscreen]].bind(document); },\n get fullscreenPseudoClass() { return `:${vendor[key.fullscreen]}`; },\n addEventListener: (type, handler, options) => document.addEventListener(vendor[key[type]], handler, options),\n removeEventListener: (type, handler, options) => document.removeEventListener(vendor[key[type]], handler, options),\n get fullscreenEnabled() { return Boolean(document[vendor[key.fullscreenEnabled]]); },\n set fullscreenEnabled(val) {},\n get fullscreenElement() { return document[vendor[key.fullscreenElement]]; },\n set fullscreenElement(val) {},\n get onfullscreenchange() { return document[`on${vendor[key.fullscreenchange]}`.toLowerCase()]; },\n set onfullscreenchange(handler) { return document[`on${vendor[key.fullscreenchange]}`.toLowerCase()] = handler; },\n get onfullscreenerror() { return document[`on${vendor[key.fullscreenerror]}`.toLowerCase()]; },\n set onfullscreenerror(handler) { return document[`on${vendor[key.fullscreenerror]}`.toLowerCase()] = handler; },\n};\n"],"names":["key","fullscreenEnabled","fullscreenElement","requestFullscreen","exitFullscreen","fullscreenchange","fullscreenerror","fullscreen","webkit","moz","ms","document","window","vendor","Object","keys","element","requestFullscreenFunction","bind","fullscreenPseudoClass","addEventListener","type","handler","options","removeEventListener","Boolean","val","onfullscreenchange","toLowerCase","onfullscreenerror"],"mappings":"aAAA,IAAMA,EAAM,CACVC,kBAAmB,EACnBC,kBAAmB,EACnBC,kBAAmB,EACnBC,eAAgB,EAChBC,iBAAkB,EAClBC,gBAAiB,EACjBC,WAAY,GAGRC,EAAS,CACb,0BACA,0BACA,0BACA,uBACA,yBACA,wBACA,uBAGIC,EAAM,CACV,uBACA,uBACA,uBACA,sBACA,sBACA,qBACA,oBAGIC,EAAK,CACT,sBACA,sBACA,sBACA,mBACA,qBACA,oBACA,kBAIIC,EAA6B,oBAAXC,aAAqD,IAApBA,OAAOD,SAA2BC,OAAOD,SAAW,GAEvGE,EACH,sBAAuBF,GAAYG,OAAOC,KAAKf,IAC/CQ,EAAO,KAAMG,GAAYH,GACzBC,EAAI,KAAME,GAAYF,GACtBC,EAAG,KAAMC,GAAYD,GACtB,KAGa,CACbP,kBAAmB,SAAAa,GAAW,OAAAA,EAAQH,EAAOb,EAAIG,uBACjDc,0BAA2B,SAAAD,GAAW,OAAAA,EAAQH,EAAOb,EAAIG,qBACzDC,qBAAuB,OAAOO,EAASE,EAAOb,EAAII,iBAAiBc,KAAKP,IACxEQ,4BAA8B,MAAO,IAAIN,EAAOb,EAAIO,aACpDa,iBAAkB,SAACC,EAAMC,EAASC,GAAY,OAAAZ,EAASS,iBAAiBP,EAAOb,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