mirror of
https://github.com/nextcloud/server.git
synced 2026-06-11 01:30:50 -04:00
Merge pull request #30033 from nextcloud/ie-polifils
This commit is contained in:
commit
e0d2f015ad
3 changed files with 3 additions and 13 deletions
2
core/js/dist/main.js
vendored
2
core/js/dist/main.js
vendored
File diff suppressed because one or more lines are too long
2
core/js/dist/main.js.map
vendored
2
core/js/dist/main.js.map
vendored
File diff suppressed because one or more lines are too long
|
|
@ -133,20 +133,10 @@ moment.locale(locale)
|
|||
*/
|
||||
export const initCore = () => {
|
||||
const userAgent = window.navigator.userAgent
|
||||
const msie = userAgent.indexOf('MSIE ')
|
||||
const trident = userAgent.indexOf('Trident/')
|
||||
const edge = userAgent.indexOf('Edge/')
|
||||
|
||||
if (msie > 0 || trident > 0) {
|
||||
// (IE 10 or older) || IE 11
|
||||
$('html').addClass('ie')
|
||||
} else if (edge > 0) {
|
||||
// for edge
|
||||
if (edge > 0) {
|
||||
$('html').addClass('edge')
|
||||
}
|
||||
|
||||
// css variables fallback for IE
|
||||
if (msie > 0 || trident > 0 || edge > 0) {
|
||||
console.info('Legacy browser detected, applying css vars polyfill')
|
||||
cssVars({
|
||||
watch: true,
|
||||
|
|
|
|||
Loading…
Reference in a new issue