Merge pull request #13971 from MoonE/remove-ie-compatibility

Remove more IE compatibility
This commit is contained in:
MoonE
2022-08-12 00:38:47 +02:00
committed by GitHub
12 changed files with 6 additions and 39 deletions

View File

@@ -36,16 +36,12 @@ export const GMLNS = 'http://www.opengis.net/gml';
/**
* A regular expression that matches if a string only contains whitespace
* characters. It will e.g. match `''`, `' '`, `'\n'` etc. The non-breaking
* space (0xa0) is explicitly included as IE doesn't include it in its
* definition of `\s`.
*
* Information from `goog.string.isEmptyOrWhitespace`: https://github.com/google/closure-library/blob/e877b1e/closure/goog/string/string.js#L156-L160
* characters. It will e.g. match `''`, `' '`, `'\n'` etc.
*
* @const
* @type {RegExp}
*/
const ONLY_WHITESPACE_RE = /^[\s\xa0]*$/;
const ONLY_WHITESPACE_RE = /^\s*$/;
/**
* @typedef {Object} Options

View File

@@ -419,9 +419,6 @@ function defaultIconUrlFunction(href) {
* geometry types, and into MultiPoint/MultiLineString/MultiPolygon if they are
* all of the same type.
*
* Note that the KML format uses the URL() constructor. Older browsers such as IE
* which do not support this will need a URL polyfill to be loaded before use.
*
* @api
*/
class KML extends XMLFeature {

View File

@@ -23,7 +23,6 @@ The document ends with guidelines for implementing a new format.
The `ol/xml` namespace contains a number of useful functions for parsing XML documents. All code in OpenLayers that reads data from XML documents should use it. It has several features:
* Browser support back to IE9
* Correct treatment of XML namespaces
* Robust handling of errors
* Modular design to promote the re-use of parsers
@@ -42,7 +41,7 @@ The `ol/format/XML` class includes a number of methods for reading arrays of fea
read{Features,Feature,Geometry}From{Document,Node}
`Document`s are top-level XML document objects, `Node`s are children of the top-level XML document object. In modern browsers `Document` is a subclass of `Node`, and inherits all of `Node`'s methods. In IE, this is not the case: `Document` is not a subclass of `Node`, and `Document` only has some of `Node`'s functionality. The distinction between the two is therefore necessary.
`Document`s are top-level XML document objects, `Node`s are children of the top-level XML document object. In modern browsers `Document` is a subclass of `Node`, and inherits all of `Node`'s methods.
## `ol/xml`

View File

@@ -87,10 +87,6 @@ export class DragAndDropEvent extends Event {
* @classdesc
* Handles input of vector data by drag and drop.
*
* Note that the DragAndDrop interaction uses the TextDecoder() constructor if the supplied
* combination of formats read both text string and ArrayBuffer sources. Older browsers such
* as IE which do not support this will need a TextDecoder polyfill to be loaded before use.
*
* @api
*
* @fires DragAndDropEvent

View File

@@ -64,7 +64,7 @@ function verifyBrokenDiagonalRendering(data, offset) {
* Determines if the current browser configuration can render triangular clip regions correctly.
* This value is cached so the function is only expensive the first time called.
* Firefox on Windows (as of now) does not if HWA is enabled. See https://bugzilla.mozilla.org/show_bug.cgi?id=1606976
* IE also doesn't. Chrome works, and everything seems to work on OSX and Android. This function caches the
* Chrome works, and everything seems to work on OSX and Android. This function caches the
* result. I suppose that it is conceivably possible that a browser might flip modes while the app is
* running, but lets hope not.
*