moodle/lib/amd/build/fullscreen.min.js.map
2023-03-09 09:53:19 +08:00

1 line
2.0 KiB
Plaintext

{"version":3,"file":"fullscreen.min.js","sources":["../src/fullscreen.js"],"sourcesContent":["// This file is part of Moodle - http://moodle.org/\n//\n// Moodle is free software: you can redistribute it and/or modify\n// it under the terms of the GNU General Public License as published by\n// the Free Software Foundation, either version 3 of the License, or\n// (at your option) any later version.\n//\n// Moodle is distributed in the hope that it will be useful,\n// but WITHOUT ANY WARRANTY; without even the implied warranty of\n// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n// GNU General Public License for more details.\n//\n// You should have received a copy of the GNU General Public License\n// along with Moodle. If not, see <http://www.gnu.org/licenses/>.\n\n/**\n * Detects if an element is fullscreen.\n *\n * @module core/fullscreen\n * @copyright 2020 University of Nottingham\n * @author Neill Magill <neill.magill@nottingham.ac.uk>\n * @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later\n */\n\n/**\n * Gets the element that is fullscreen or null if no element is fullscreen.\n *\n * @method\n * @returns {HTMLElement}\n */\nexport const getElement = () => {\n let element = null;\n if (document.fullscreenElement) {\n element = document.fullscreenElement;\n } else if (document.mozFullscreenElement) {\n // Fallback for older Firefox.\n element = document.mozFullscreenElement;\n } else if (document.msFullscreenElement) {\n // Fallback for Edge and IE.\n element = document.msFullscreenElement;\n } else if (document.webkitFullscreenElement) {\n // Fallback for Chrome, Edge and Safari.\n element = document.webkitFullscreenElement;\n }\n\n return element;\n};\n"],"names":["element","document","fullscreenElement","mozFullscreenElement","msFullscreenElement","webkitFullscreenElement"],"mappings":"gKA8B0B,SAClBA,QAAU,YACVC,SAASC,kBACTF,QAAUC,SAASC,kBACZD,SAASE,qBAEhBH,QAAUC,SAASE,qBACZF,SAASG,oBAEhBJ,QAAUC,SAASG,oBACZH,SAASI,0BAEhBL,QAAUC,SAASI,yBAGhBL"}