mirror of
https://github.com/nextcloud/server.git
synced 2026-04-05 09:06:35 -04:00
Remove old ie polify
Signed-off-by: Carl Schwan <carl@carlschwan.eu>
This commit is contained in:
parent
5509063caa
commit
c17b8317d6
8 changed files with 6 additions and 224 deletions
|
|
@ -28,7 +28,6 @@
|
|||
import _ from 'underscore'
|
||||
import $ from 'jquery'
|
||||
import moment from 'moment'
|
||||
import cssVars from 'css-vars-ponyfill'
|
||||
|
||||
import { initSessionHeartBeat } from './session-heartbeat'
|
||||
import OC from './OC/index'
|
||||
|
|
@ -133,20 +132,6 @@ moment.locale(locale)
|
|||
* Initializes core
|
||||
*/
|
||||
export const initCore = () => {
|
||||
const userAgent = window.navigator.userAgent
|
||||
const edge = userAgent.indexOf('Edge/')
|
||||
|
||||
if (edge > 0) {
|
||||
$('html').addClass('edge')
|
||||
console.info('Legacy browser detected, applying css vars polyfill')
|
||||
cssVars({
|
||||
watch: true,
|
||||
// set edge < 16 as incompatible
|
||||
onlyLegacy: !(/Edge\/([0-9]{2})\./i.test(navigator.userAgent)
|
||||
&& parseInt(/Edge\/([0-9]{2})\./i.exec(navigator.userAgent)[1]) < 16),
|
||||
})
|
||||
}
|
||||
|
||||
$(window).on('unload.main', () => { OC._unloadCalled = true })
|
||||
$(window).on('beforeunload.main', () => {
|
||||
// super-trick thanks to http://stackoverflow.com/a/4651049
|
||||
|
|
|
|||
4
dist/core-common.js
vendored
4
dist/core-common.js
vendored
File diff suppressed because one or more lines are too long
173
dist/core-common.js.LICENSE.txt
vendored
173
dist/core-common.js.LICENSE.txt
vendored
|
|
@ -54,14 +54,6 @@
|
|||
* Licensed MIT © Zeno Rocha
|
||||
*/
|
||||
|
||||
/*!
|
||||
* css-vars-ponyfill
|
||||
* v2.4.8
|
||||
* https://jhildenbiddle.github.io/css-vars-ponyfill/
|
||||
* (c) 2018-2022 John Hildenbiddle <http://hildenbiddle.com>
|
||||
* MIT license
|
||||
*/
|
||||
|
||||
/*!
|
||||
* escape-html
|
||||
* Copyright(c) 2012-2013 TJ Holowaychuk
|
||||
|
|
@ -70,14 +62,6 @@
|
|||
* MIT Licensed
|
||||
*/
|
||||
|
||||
/*!
|
||||
* get-css-data
|
||||
* v2.1.0
|
||||
* https://github.com/jhildenbiddle/get-css-data
|
||||
* (c) 2018-2022 John Hildenbiddle <http://hildenbiddle.com>
|
||||
* MIT license
|
||||
*/
|
||||
|
||||
/*!
|
||||
* jQuery JavaScript Library v3.6.0
|
||||
* https://jquery.com/
|
||||
|
|
@ -773,163 +757,6 @@
|
|||
* Copyright Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors
|
||||
*/
|
||||
|
||||
/**
|
||||
* Fetches, parses, and transforms CSS custom properties from specified
|
||||
* <style> and <link> elements into static values, then appends a new <style>
|
||||
* element with static values to the DOM to provide CSS custom property
|
||||
* compatibility for legacy browsers. Also provides a single interface for
|
||||
* live updates of runtime values in both modern and legacy browsers.
|
||||
*
|
||||
* @preserve
|
||||
* @param {object} [options] Options object
|
||||
* @param {object} [options.rootElement=document] Root element to traverse for
|
||||
* <link> and <style> nodes
|
||||
* @param {boolean} [options.shadowDOM=false] Determines if shadow DOM <link>
|
||||
* and <style> nodes will be processed.
|
||||
* @param {string} [options.include="style,link[rel=stylesheet]"] CSS selector
|
||||
* matching <link re="stylesheet"> and <style> nodes to
|
||||
* process
|
||||
* @param {string} [options.exclude] CSS selector matching <link
|
||||
* rel="stylehseet"> and <style> nodes to exclude from those
|
||||
* matches by options.include
|
||||
* @param {object} [options.variables] A map of custom property name/value
|
||||
* pairs. Property names can omit or include the leading
|
||||
* double-hyphen (—), and values specified will override
|
||||
* previous values
|
||||
* @param {boolean} [options.onlyLegacy=true] Determines if the ponyfill will
|
||||
* only generate legacy-compatible CSS in browsers that lack
|
||||
* native support (i.e., legacy browsers)
|
||||
* @param {boolean} [options.preserveStatic=true] Determines if CSS
|
||||
* declarations that do not reference a custom property will
|
||||
* be preserved in the transformed CSS
|
||||
* @param {boolean} [options.preserveVars=false] Determines if CSS custom
|
||||
* property declarations will be preserved in the transformed
|
||||
* CSS
|
||||
* @param {boolean} [options.silent=false] Determines if warning and error
|
||||
* messages will be displayed on the console
|
||||
* @param {boolean} [options.updateDOM=true] Determines if the ponyfill will
|
||||
* update the DOM after processing CSS custom properties
|
||||
* @param {boolean} [options.updateURLs=true] Determines if relative url()
|
||||
* paths will be converted to absolute urls in external CSS
|
||||
* @param {boolean} [options.watch=false] Determines if a MutationObserver will
|
||||
* be created that will execute the ponyfill when a <link> or
|
||||
* <style> DOM mutation is observed
|
||||
* @param {function} [options.onBeforeSend] Callback before XHR is sent. Passes
|
||||
* 1) the XHR object, 2) source node reference, and 3) the
|
||||
* source URL as arguments
|
||||
* @param {function} [options.onError] Callback after a CSS parsing error has
|
||||
* occurred or an XHR request has failed. Passes 1) an error
|
||||
* message, and 2) source node reference, 3) xhr, and 4 url as
|
||||
* arguments.
|
||||
* @param {function} [options.onWarning] Callback after each CSS parsing warning
|
||||
* has occurred. Passes 1) a warning message as an argument.
|
||||
* @param {function} [options.onSuccess] Callback after CSS data has been
|
||||
* collected from each node and before CSS custom properties
|
||||
* have been transformed. Allows modifying the CSS data before
|
||||
* it is transformed by returning any string value (or false
|
||||
* to skip). Passes 1) CSS text, 2) source node reference, and
|
||||
* 3) the source URL as arguments.
|
||||
* @param {function} [options.onComplete] Callback after all CSS has been
|
||||
* processed, legacy-compatible CSS has been generated, and
|
||||
* (optionally) the DOM has been updated. Passes 1) a CSS
|
||||
* string with CSS variable values resolved, 2) an array of
|
||||
* output <style> node references that have been appended to
|
||||
* the DOM, 3) an object containing all custom properies names
|
||||
* and values, and 4) the ponyfill execution time in
|
||||
* milliseconds.
|
||||
* @param {function} [options.onFinally] Callback in modern and legacy browsers
|
||||
* after the ponyfill has finished all tasks. Passes 1) a
|
||||
* boolean indicating if the last ponyfill call resulted in a
|
||||
* style change, 2) a boolean indicating if the current
|
||||
* browser provides native support for CSS custom properties,
|
||||
* and 3) the ponyfill execution time in milliseconds.
|
||||
* @example
|
||||
*
|
||||
* cssVars({
|
||||
* rootElement : document,
|
||||
* shadowDOM : false,
|
||||
* include : 'style,link[rel="stylesheet"]',
|
||||
* exclude : '',
|
||||
* variables : {},
|
||||
* onlyLegacy : true,
|
||||
* preserveStatic: true,
|
||||
* preserveVars : false,
|
||||
* silent : false,
|
||||
* updateDOM : true,
|
||||
* updateURLs : true,
|
||||
* watch : false,
|
||||
* onBeforeSend(xhr, node, url) {},
|
||||
* onError(message, node, xhr, url) {},
|
||||
* onWarning(message) {},
|
||||
* onSuccess(cssText, node, url) {},
|
||||
* onComplete(cssText, styleNode, cssVariables, benchmark) {},
|
||||
* onFinally(hasChanged, hasNativeSupport, benchmark)
|
||||
* });
|
||||
*/
|
||||
|
||||
/**
|
||||
* Gets CSS data from <style> and <link> nodes (including @imports), then
|
||||
* returns data in order processed by DOM. Allows specifying nodes to
|
||||
* include/exclude and filtering CSS data using RegEx.
|
||||
*
|
||||
* @preserve
|
||||
* @param {object} [options] The options object
|
||||
* @param {object} [options.rootElement=document] Root element to traverse for
|
||||
* <link> and <style> nodes.
|
||||
* @param {string} [options.include] CSS selector matching <link> and <style>
|
||||
* nodes to include
|
||||
* @param {string} [options.exclude] CSS selector matching <link> and <style>
|
||||
* nodes to exclude
|
||||
* @param {object} [options.filter] Regular expression used to filter node CSS
|
||||
* data. Each block of CSS data is tested against the filter,
|
||||
* and only matching data is included.
|
||||
* @param {boolean} [options.skipDisabled=true] Determines if disabled
|
||||
* stylesheets will be skipped while collecting CSS data.
|
||||
* @param {boolean} [options.useCSSOM=false] Determines if CSS data will be
|
||||
* collected from a stylesheet's runtime values instead of its
|
||||
* text content. This is required to get accurate CSS data
|
||||
* when a stylesheet has been modified using the deleteRule()
|
||||
* or insertRule() methods because these modifications will
|
||||
* not be reflected in the stylesheet's text content.
|
||||
* @param {function} [options.onBeforeSend] Callback before XHR is sent. Passes
|
||||
* 1) the XHR object, 2) source node reference, and 3) the
|
||||
* source URL as arguments.
|
||||
* @param {function} [options.onSuccess] Callback on each CSS node read. Passes
|
||||
* 1) CSS text, 2) source node reference, and 3) the source
|
||||
* URL as arguments.
|
||||
* @param {function} [options.onError] Callback on each error. Passes 1) the XHR
|
||||
* object for inspection, 2) soure node reference, and 3) the
|
||||
* source URL that failed (either a <link> href or an @import)
|
||||
* as arguments
|
||||
* @param {function} [options.onComplete] Callback after all nodes have been
|
||||
* processed. Passes 1) concatenated CSS text, 2) an array of
|
||||
* CSS text in DOM order, and 3) an array of nodes in DOM
|
||||
* order as arguments.
|
||||
*
|
||||
* @example
|
||||
*
|
||||
* getCssData({
|
||||
* rootElement : document,
|
||||
* include : 'style,link[rel="stylesheet"]',
|
||||
* exclude : '[href="skip.css"]',
|
||||
* filter : /red/,
|
||||
* skipDisabled: true,
|
||||
* useCSSOM : false,
|
||||
* onBeforeSend(xhr, node, url) {
|
||||
* // ...
|
||||
* }
|
||||
* onSuccess(cssText, node, url) {
|
||||
* // ...
|
||||
* }
|
||||
* onError(xhr, node, url) {
|
||||
* // ...
|
||||
* },
|
||||
* onComplete(cssText, cssArray, nodeArray) {
|
||||
* // ...
|
||||
* }
|
||||
* });
|
||||
*/
|
||||
|
||||
/**
|
||||
* vue-local-storage v0.6.0
|
||||
* (c) 2017 Alexander Avakov
|
||||
|
|
|
|||
2
dist/core-common.js.map
vendored
2
dist/core-common.js.map
vendored
File diff suppressed because one or more lines are too long
4
dist/core-main.js
vendored
4
dist/core-main.js
vendored
File diff suppressed because one or more lines are too long
2
dist/core-main.js.map
vendored
2
dist/core-main.js.map
vendored
File diff suppressed because one or more lines are too long
29
package-lock.json
generated
29
package-lock.json
generated
|
|
@ -37,7 +37,6 @@
|
|||
"camelcase": "^6.3.0",
|
||||
"clipboard": "^2.0.10",
|
||||
"core-js": "^3.24.0",
|
||||
"css-vars-ponyfill": "^2.4.8",
|
||||
"davclient.js": "git+https://github.com/owncloud/davclient.js.git#0.2.1",
|
||||
"debounce": "^1.2.1",
|
||||
"dompurify": "^2.3.6",
|
||||
|
|
@ -12317,15 +12316,6 @@
|
|||
"node": ">=0.10.0"
|
||||
}
|
||||
},
|
||||
"node_modules/css-vars-ponyfill": {
|
||||
"version": "2.4.8",
|
||||
"resolved": "https://registry.npmjs.org/css-vars-ponyfill/-/css-vars-ponyfill-2.4.8.tgz",
|
||||
"integrity": "sha512-4/j4AX4htytYHWyHVZ2BFQ+NoCGZEcOH2h4/2mmgE4SkrFg4Xq6tGYR77DtvvUIDsaXuJN+sj41bbgauA0Gfmg==",
|
||||
"dependencies": {
|
||||
"balanced-match": "^1.0.2",
|
||||
"get-css-data": "^2.0.2"
|
||||
}
|
||||
},
|
||||
"node_modules/css-what": {
|
||||
"version": "3.4.2",
|
||||
"resolved": "https://registry.npmjs.org/css-what/-/css-what-3.4.2.tgz",
|
||||
|
|
@ -15796,11 +15786,6 @@
|
|||
"node": "6.* || 8.* || >= 10.*"
|
||||
}
|
||||
},
|
||||
"node_modules/get-css-data": {
|
||||
"version": "2.0.2",
|
||||
"resolved": "https://registry.npmjs.org/get-css-data/-/get-css-data-2.0.2.tgz",
|
||||
"integrity": "sha512-pYqg80/7u/MdBrrAQj2OIoZ08TxEnvCHyU5WFnPxxS/D0S8OpUTkqGFRzn8bO38DmtCuYBpR9VMCen78BL4jiQ=="
|
||||
},
|
||||
"node_modules/get-intrinsic": {
|
||||
"version": "1.1.1",
|
||||
"resolved": "https://registry.npmjs.org/get-intrinsic/-/get-intrinsic-1.1.1.tgz",
|
||||
|
|
@ -41849,15 +41834,6 @@
|
|||
}
|
||||
}
|
||||
},
|
||||
"css-vars-ponyfill": {
|
||||
"version": "2.4.8",
|
||||
"resolved": "https://registry.npmjs.org/css-vars-ponyfill/-/css-vars-ponyfill-2.4.8.tgz",
|
||||
"integrity": "sha512-4/j4AX4htytYHWyHVZ2BFQ+NoCGZEcOH2h4/2mmgE4SkrFg4Xq6tGYR77DtvvUIDsaXuJN+sj41bbgauA0Gfmg==",
|
||||
"requires": {
|
||||
"balanced-match": "^1.0.2",
|
||||
"get-css-data": "^2.0.2"
|
||||
}
|
||||
},
|
||||
"css-what": {
|
||||
"version": "3.4.2",
|
||||
"resolved": "https://registry.npmjs.org/css-what/-/css-what-3.4.2.tgz",
|
||||
|
|
@ -44541,11 +44517,6 @@
|
|||
"resolved": "https://registry.npmjs.org/get-caller-file/-/get-caller-file-2.0.5.tgz",
|
||||
"integrity": "sha512-DyFP3BM/3YHTQOCUL/w0OZHR0lpKeGrxotcHWcqNEdnltqFwXVfhEBQ94eIo34AfQpo0rGki4cyIiftY06h2Fg=="
|
||||
},
|
||||
"get-css-data": {
|
||||
"version": "2.0.2",
|
||||
"resolved": "https://registry.npmjs.org/get-css-data/-/get-css-data-2.0.2.tgz",
|
||||
"integrity": "sha512-pYqg80/7u/MdBrrAQj2OIoZ08TxEnvCHyU5WFnPxxS/D0S8OpUTkqGFRzn8bO38DmtCuYBpR9VMCen78BL4jiQ=="
|
||||
},
|
||||
"get-intrinsic": {
|
||||
"version": "1.1.1",
|
||||
"resolved": "https://registry.npmjs.org/get-intrinsic/-/get-intrinsic-1.1.1.tgz",
|
||||
|
|
|
|||
|
|
@ -57,7 +57,6 @@
|
|||
"camelcase": "^6.3.0",
|
||||
"clipboard": "^2.0.10",
|
||||
"core-js": "^3.24.0",
|
||||
"css-vars-ponyfill": "^2.4.8",
|
||||
"davclient.js": "git+https://github.com/owncloud/davclient.js.git#0.2.1",
|
||||
"debounce": "^1.2.1",
|
||||
"dompurify": "^2.3.6",
|
||||
|
|
|
|||
Loading…
Reference in a new issue