-
-
Save AnderRV/f7f5d0d248ccc8de68dc093f5b7137aa to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
! function(e) { | |
var t = {}; | |
function n(o) { | |
if (t[o]) return t[o].exports; | |
var i = t[o] = { | |
i: o, | |
l: !1, | |
exports: {} | |
}; | |
return e[o].call(i.exports, i, i.exports, n), i.l = !0, i.exports | |
} | |
n.m = e, n.c = t, n.d = function(e, t, o) { | |
n.o(e, t) || Object.defineProperty(e, t, { | |
enumerable: !0, | |
get: o | |
}) | |
}, n.r = function(e) { | |
"undefined" != typeof Symbol && Symbol.toStringTag && Object.defineProperty(e, Symbol.toStringTag, { | |
value: "Module" | |
}), Object.defineProperty(e, "__esModule", { | |
value: !0 | |
}) | |
}, n.t = function(e, t) { | |
if (1 & t && (e = n(e)), 8 & t) return e; | |
if (4 & t && "object" == typeof e && e && e.__esModule) return e; | |
var o = Object.create(null); | |
if (n.r(o), Object.defineProperty(o, "default", { | |
enumerable: !0, | |
value: e | |
}), 2 & t && "string" != typeof e) | |
for (var i in e) n.d(o, i, function(t) { | |
return e[t] | |
}.bind(null, i)); | |
return o | |
}, n.n = function(e) { | |
var t = e && e.__esModule ? function() { | |
return e.default | |
} : function() { | |
return e | |
}; | |
return n.d(t, "a", t), t | |
}, n.o = function(e, t) { | |
return Object.prototype.hasOwnProperty.call(e, t) | |
}, n.p = "", n(n.s = 152) | |
}([function(e, t) { | |
var n = e.exports = "undefined" != typeof window && window.Math == Math ? window : "undefined" != typeof self && self.Math == Math ? self : Function("return this")(); | |
"number" == typeof __g && (__g = n) | |
}, function(e, t, n) { | |
"use strict"; | |
t.a = function(...e) { | |
const { | |
search: t | |
} = document.location; | |
t.includes("lmd-show-dev-logs") && console.log(e) | |
} | |
}, function(e, t, n) { | |
"use strict"; | |
var o = n(38), | |
i = "object" == typeof self && self && self.Object === Object && self, | |
r = o.a || i || Function("return this")(); | |
t.a = r | |
}, function(e, t, n) { | |
var o = n(16), | |
i = n(30); | |
e.exports = n(7) ? function(e, t, n) { | |
return o.f(e, t, i(1, n)) | |
} : function(e, t, n) { | |
return e[t] = n, e | |
} | |
}, function(e, t, n) { | |
var o = n(13)("wks"), | |
i = n(15), | |
r = n(0).Symbol, | |
s = "function" == typeof r; | |
(e.exports = function(e) { | |
return o[e] || (o[e] = s && r[e] || (s ? r : i)("Symbol." + e)) | |
}).store = o | |
}, , function(e, t, n) { | |
"use strict"; | |
var o = n(2).a.Symbol; | |
t.a = o | |
}, function(e, t, n) { | |
e.exports = !n(28)((function() { | |
return 7 != Object.defineProperty({}, "a", { | |
get: function() { | |
return 7 | |
} | |
}).a | |
})) | |
}, function(e, t) { | |
var n = {}.hasOwnProperty; | |
e.exports = function(e, t) { | |
return n.call(e, t) | |
} | |
}, function(e, t, n) { | |
"use strict"; | |
t.a = function(e) { | |
var t = typeof e; | |
return null != e && ("object" == t || "function" == t) | |
} | |
}, function(e, t, n) { | |
"use strict"; | |
t.a = function(e) { | |
return null != e && "object" == typeof e | |
} | |
}, function(e, t, n) { | |
"use strict"; | |
var o = n(6), | |
i = Object.prototype, | |
r = i.hasOwnProperty, | |
s = i.toString, | |
a = o.a ? o.a.toStringTag : void 0; | |
var c = function(e) { | |
var t = r.call(e, a), | |
n = e[a]; | |
try { | |
e[a] = void 0; | |
var o = !0 | |
} catch (e) {} | |
var i = s.call(e); | |
return o && (t ? e[a] = n : delete e[a]), i | |
}, | |
u = Object.prototype.toString; | |
var l = function(e) { | |
return u.call(e) | |
}, | |
d = o.a ? o.a.toStringTag : void 0; | |
t.a = function(e) { | |
return null == e ? void 0 === e ? "[object Undefined]" : "[object Null]" : d && d in Object(e) ? c(e) : l(e) | |
} | |
}, , function(e, t, n) { | |
var o = n(14), | |
i = n(0), | |
r = i["__core-js_shared__"] || (i["__core-js_shared__"] = {}); | |
(e.exports = function(e, t) { | |
return r[e] || (r[e] = void 0 !== t ? t : {}) | |
})("versions", []).push({ | |
version: o.version, | |
mode: n(27) ? "pure" : "global", | |
copyright: "© 2020 Denis Pushkarev (zloirock.ru)" | |
}) | |
}, function(e, t) { | |
var n = e.exports = { | |
version: "2.6.12" | |
}; | |
"number" == typeof __e && (__e = n) | |
}, function(e, t) { | |
var n = 0, | |
o = Math.random(); | |
e.exports = function(e) { | |
return "Symbol(".concat(void 0 === e ? "" : e, ")_", (++n + o).toString(36)) | |
} | |
}, function(e, t, n) { | |
var o = n(17), | |
i = n(45), | |
r = n(46), | |
s = Object.defineProperty; | |
t.f = n(7) ? Object.defineProperty : function(e, t, n) { | |
if (o(e), t = r(t, !0), o(n), i) try { | |
return s(e, t, n) | |
} catch (e) {} | |
if ("get" in n || "set" in n) throw TypeError("Accessors not supported!"); | |
return "value" in n && (e[t] = n.value), e | |
} | |
}, function(e, t, n) { | |
var o = n(18); | |
e.exports = function(e) { | |
if (!o(e)) throw TypeError(e + " is not an object!"); | |
return e | |
} | |
}, function(e, t) { | |
e.exports = function(e) { | |
return "object" == typeof e ? null !== e : "function" == typeof e | |
} | |
}, function(e, t) { | |
e.exports = {} | |
}, function(e, t, n) { | |
var o = n(48), | |
i = n(31); | |
e.exports = function(e) { | |
return o(i(e)) | |
} | |
}, function(e, t, n) { | |
var o = n(0), | |
i = n(3), | |
r = n(8), | |
s = n(15)("src"), | |
a = n(52), | |
c = ("" + a).split("toString"); | |
n(14).inspectSource = function(e) { | |
return a.call(e) | |
}, (e.exports = function(e, t, n, a) { | |
var u = "function" == typeof n; | |
u && (r(n, "name") || i(n, "name", t)), e[t] !== n && (u && (r(n, s) || i(n, s, e[t] ? "" + e[t] : c.join(String(t)))), e === o ? e[t] = n : a ? e[t] ? e[t] = n : i(e, t, n) : (delete e[t], i(e, t, n))) | |
})(Function.prototype, "toString", (function() { | |
return "function" == typeof this && this[s] || a.call(this) | |
})) | |
}, function(e, t, n) { | |
var o = n(13)("keys"), | |
i = n(15); | |
e.exports = function(e) { | |
return o[e] || (o[e] = i(e)) | |
} | |
}, function(e, t, n) { | |
"use strict"; | |
n.d(t, "a", (function() { | |
return o | |
})), n.d(t, "d", (function() { | |
return i | |
})), n.d(t, "b", (function() { | |
return r | |
})), n.d(t, "c", (function() { | |
return s | |
})); | |
const o = e => { | |
const t = document.createElement("div"); | |
return t.innerHTML = e.trim(), t.firstChild | |
}, | |
i = (e, t) => { | |
const n = Element.prototype; | |
return (n.matches || n.webkitMatchesSelector || n.mozMatchesSelector || n.msMatchesSelector || function(e) { | |
return -1 !== [].indexOf.call(document.querySelectorAll(e), this) | |
}).call(e, t) | |
}; | |
const r = e => { | |
if (!0 === function(e) { | |
return "SCRIPT" === e.tagName | |
}(e)) e.parentNode.replaceChild(function(e) { | |
const t = document.createElement("script"); | |
t.text = e.innerHTML; | |
let n = 0; | |
const o = e.attributes; | |
let i; | |
for (; n < o.length;) t.setAttribute((i = o[n]).name, i.value), n += 1; | |
return t | |
}(e), e); | |
else { | |
let t = 0; | |
const n = e.childNodes; | |
for (; t < n.length;) r(n[t]), t += 1 | |
} | |
return e | |
}, | |
s = (e, t) => { | |
if (Element.prototype.closest) return e.closest(t); | |
let n = e; | |
do { | |
if (i(n, t)) return n; | |
n = n.parentElement || n.parentNode | |
} while (null !== n && 1 === n.nodeType); | |
return null | |
} | |
}, function(e, t, n) { | |
"use strict"; | |
function o(e, ...t) { | |
let n = !0; | |
return t.reduce((e, t) => e && void 0 !== e[t] ? e[t] : (n = !1, null), e), n | |
} | |
n.d(t, "a", (function() { | |
return o | |
})) | |
}, function(e, t, n) { | |
"use strict"; | |
var o = n(11), | |
i = n(10); | |
t.a = function(e) { | |
return "symbol" == typeof e || Object(i.a)(e) && "[object Symbol]" == Object(o.a)(e) | |
} | |
}, , function(e, t) { | |
e.exports = !1 | |
}, function(e, t) { | |
e.exports = function(e) { | |
try { | |
return !!e() | |
} catch (e) { | |
return !0 | |
} | |
} | |
}, function(e, t, n) { | |
var o = n(18), | |
i = n(0).document, | |
r = o(i) && o(i.createElement); | |
e.exports = function(e) { | |
return r ? i.createElement(e) : {} | |
} | |
}, function(e, t) { | |
e.exports = function(e, t) { | |
return { | |
enumerable: !(1 & e), | |
configurable: !(2 & e), | |
writable: !(4 & e), | |
value: t | |
} | |
} | |
}, function(e, t) { | |
e.exports = function(e) { | |
if (null == e) throw TypeError("Can't call method on " + e); | |
return e | |
} | |
}, function(e, t, n) { | |
var o = n(58), | |
i = n(34); | |
e.exports = Object.keys || function(e) { | |
return o(e, i) | |
} | |
}, function(e, t) { | |
var n = Math.ceil, | |
o = Math.floor; | |
e.exports = function(e) { | |
return isNaN(e = +e) ? 0 : (e > 0 ? o : n)(e) | |
} | |
}, function(e, t) { | |
e.exports = "constructor,hasOwnProperty,isPrototypeOf,propertyIsEnumerable,toLocaleString,toString,valueOf".split(",") | |
}, function(e, t, n) { | |
var o = n(16).f, | |
i = n(8), | |
r = n(4)("toStringTag"); | |
e.exports = function(e, t, n) { | |
e && !i(e = n ? e : e.prototype, r) && o(e, r, { | |
configurable: !0, | |
value: t | |
}) | |
} | |
}, function(e, t, n) { | |
"use strict"; | |
n.d(t, "a", (function() { | |
return i | |
})), n.d(t, "c", (function() { | |
return r | |
})), n.d(t, "b", (function() { | |
return s | |
})); | |
var o = n(23); | |
const i = (e, t) => { | |
document.addEventListener("click", n => { | |
let i = n.target, | |
r = !0; | |
for (; i !== document.body;) | |
if (i = i.parentNode, Object(o.d)(i, e)) { | |
r = !1; | |
break | |
} r && "function" == typeof t && t() | |
}, !1) | |
}; | |
function r(e) { | |
"loading" === document.readyState ? document.addEventListener("DOMContentLoaded", () => { | |
e() | |
}) : e() | |
} | |
const s = (e, t, n) => { | |
document.addEventListener(e, e => { | |
e.target && Object(o.d)(e.target, t) && n(e) | |
}) | |
} | |
}, function(e, t, n) { | |
for (var o = n(43), i = n(32), r = n(21), s = n(0), a = n(3), c = n(19), u = n(4), l = u("iterator"), d = u("toStringTag"), f = c.Array, p = { | |
CSSRuleList: !0, | |
CSSStyleDeclaration: !1, | |
CSSValueList: !1, | |
ClientRectList: !1, | |
DOMRectList: !1, | |
DOMStringList: !1, | |
DOMTokenList: !0, | |
DataTransferItemList: !1, | |
FileList: !1, | |
HTMLAllCollection: !1, | |
HTMLCollection: !1, | |
HTMLFormElement: !1, | |
HTMLSelectElement: !1, | |
MediaList: !0, | |
MimeTypeArray: !1, | |
NamedNodeMap: !1, | |
NodeList: !0, | |
PaintRequestList: !1, | |
Plugin: !1, | |
PluginArray: !1, | |
SVGLengthList: !1, | |
SVGNumberList: !1, | |
SVGPathSegList: !1, | |
SVGPointList: !1, | |
SVGStringList: !1, | |
SVGTransformList: !1, | |
SourceBufferList: !1, | |
StyleSheetList: !0, | |
TextTrackCueList: !1, | |
TextTrackList: !1, | |
TouchList: !1 | |
}, m = i(p), h = 0; h < m.length; h++) { | |
var g, y = m[h], | |
v = p[y], | |
b = s[y], | |
w = b && b.prototype; | |
if (w && (w[l] || a(w, l, f), w[d] || a(w, d, y), c[y] = f, v)) | |
for (g in o) w[g] || r(w, g, o[g], !0) | |
} | |
}, function(e, t, n) { | |
"use strict"; | |
(function(e) { | |
var n = "object" == typeof e && e && e.Object === Object && e; | |
t.a = n | |
}).call(this, n(80)) | |
}, , function(e, t, n) { | |
! function(e) { | |
"use strict"; | |
var t = "undefined" != typeof globalThis && globalThis || "undefined" != typeof self && self || void 0 !== t && t, | |
n = "URLSearchParams" in t, | |
o = "Symbol" in t && "iterator" in Symbol, | |
i = "FileReader" in t && "Blob" in t && function() { | |
try { | |
return new Blob, !0 | |
} catch (e) { | |
return !1 | |
} | |
}(), | |
r = "FormData" in t, | |
s = "ArrayBuffer" in t; | |
if (s) var a = ["[object Int8Array]", "[object Uint8Array]", "[object Uint8ClampedArray]", "[object Int16Array]", "[object Uint16Array]", "[object Int32Array]", "[object Uint32Array]", "[object Float32Array]", "[object Float64Array]"], | |
c = ArrayBuffer.isView || function(e) { | |
return e && a.indexOf(Object.prototype.toString.call(e)) > -1 | |
}; | |
function u(e) { | |
if ("string" != typeof e && (e = String(e)), /[^a-z0-9\-#$%&'*+.^_`|~!]/i.test(e) || "" === e) throw new TypeError('Invalid character in header field name: "' + e + '"'); | |
return e.toLowerCase() | |
} | |
function l(e) { | |
return "string" != typeof e && (e = String(e)), e | |
} | |
function d(e) { | |
var t = { | |
next: function() { | |
var t = e.shift(); | |
return { | |
done: void 0 === t, | |
value: t | |
} | |
} | |
}; | |
return o && (t[Symbol.iterator] = function() { | |
return t | |
}), t | |
} | |
function f(e) { | |
this.map = {}, e instanceof f ? e.forEach((function(e, t) { | |
this.append(t, e) | |
}), this) : Array.isArray(e) ? e.forEach((function(e) { | |
this.append(e[0], e[1]) | |
}), this) : e && Object.getOwnPropertyNames(e).forEach((function(t) { | |
this.append(t, e[t]) | |
}), this) | |
} | |
function p(e) { | |
if (e.bodyUsed) return Promise.reject(new TypeError("Already read")); | |
e.bodyUsed = !0 | |
} | |
function m(e) { | |
return new Promise((function(t, n) { | |
e.onload = function() { | |
t(e.result) | |
}, e.onerror = function() { | |
n(e.error) | |
} | |
})) | |
} | |
function h(e) { | |
var t = new FileReader, | |
n = m(t); | |
return t.readAsArrayBuffer(e), n | |
} | |
function g(e) { | |
if (e.slice) return e.slice(0); | |
var t = new Uint8Array(e.byteLength); | |
return t.set(new Uint8Array(e)), t.buffer | |
} | |
function y() { | |
return this.bodyUsed = !1, this._initBody = function(e) { | |
var t; | |
this.bodyUsed = this.bodyUsed, this._bodyInit = e, e ? "string" == typeof e ? this._bodyText = e : i && Blob.prototype.isPrototypeOf(e) ? this._bodyBlob = e : r && FormData.prototype.isPrototypeOf(e) ? this._bodyFormData = e : n && URLSearchParams.prototype.isPrototypeOf(e) ? this._bodyText = e.toString() : s && i && (t = e) && DataView.prototype.isPrototypeOf(t) ? (this._bodyArrayBuffer = g(e.buffer), this._bodyInit = new Blob([this._bodyArrayBuffer])) : s && (ArrayBuffer.prototype.isPrototypeOf(e) || c(e)) ? this._bodyArrayBuffer = g(e) : this._bodyText = e = Object.prototype.toString.call(e) : this._bodyText = "", this.headers.get("content-type") || ("string" == typeof e ? this.headers.set("content-type", "text/plain;charset=UTF-8") : this._bodyBlob && this._bodyBlob.type ? this.headers.set("content-type", this._bodyBlob.type) : n && URLSearchParams.prototype.isPrototypeOf(e) && this.headers.set("content-type", "application/x-www-form-urlencoded;charset=UTF-8")) | |
}, i && (this.blob = function() { | |
var e = p(this); | |
if (e) return e; | |
if (this._bodyBlob) return Promise.resolve(this._bodyBlob); | |
if (this._bodyArrayBuffer) return Promise.resolve(new Blob([this._bodyArrayBuffer])); | |
if (this._bodyFormData) throw new Error("could not read FormData body as blob"); | |
return Promise.resolve(new Blob([this._bodyText])) | |
}, this.arrayBuffer = function() { | |
if (this._bodyArrayBuffer) { | |
var e = p(this); | |
return e || (ArrayBuffer.isView(this._bodyArrayBuffer) ? Promise.resolve(this._bodyArrayBuffer.buffer.slice(this._bodyArrayBuffer.byteOffset, this._bodyArrayBuffer.byteOffset + this._bodyArrayBuffer.byteLength)) : Promise.resolve(this._bodyArrayBuffer)) | |
} | |
return this.blob().then(h) | |
}), this.text = function() { | |
var e, t, n, o = p(this); | |
if (o) return o; | |
if (this._bodyBlob) return e = this._bodyBlob, t = new FileReader, n = m(t), t.readAsText(e), n; | |
if (this._bodyArrayBuffer) return Promise.resolve(function(e) { | |
for (var t = new Uint8Array(e), n = new Array(t.length), o = 0; o < t.length; o++) n[o] = String.fromCharCode(t[o]); | |
return n.join("") | |
}(this._bodyArrayBuffer)); | |
if (this._bodyFormData) throw new Error("could not read FormData body as text"); | |
return Promise.resolve(this._bodyText) | |
}, r && (this.formData = function() { | |
return this.text().then(w) | |
}), this.json = function() { | |
return this.text().then(JSON.parse) | |
}, this | |
} | |
f.prototype.append = function(e, t) { | |
e = u(e), t = l(t); | |
var n = this.map[e]; | |
this.map[e] = n ? n + ", " + t : t | |
}, f.prototype.delete = function(e) { | |
delete this.map[u(e)] | |
}, f.prototype.get = function(e) { | |
return e = u(e), this.has(e) ? this.map[e] : null | |
}, f.prototype.has = function(e) { | |
return this.map.hasOwnProperty(u(e)) | |
}, f.prototype.set = function(e, t) { | |
this.map[u(e)] = l(t) | |
}, f.prototype.forEach = function(e, t) { | |
for (var n in this.map) this.map.hasOwnProperty(n) && e.call(t, this.map[n], n, this) | |
}, f.prototype.keys = function() { | |
var e = []; | |
return this.forEach((function(t, n) { | |
e.push(n) | |
})), d(e) | |
}, f.prototype.values = function() { | |
var e = []; | |
return this.forEach((function(t) { | |
e.push(t) | |
})), d(e) | |
}, f.prototype.entries = function() { | |
var e = []; | |
return this.forEach((function(t, n) { | |
e.push([n, t]) | |
})), d(e) | |
}, o && (f.prototype[Symbol.iterator] = f.prototype.entries); | |
var v = ["DELETE", "GET", "HEAD", "OPTIONS", "POST", "PUT"]; | |
function b(e, t) { | |
if (!(this instanceof b)) throw new TypeError('Please use the "new" operator, this DOM object constructor cannot be called as a function.'); | |
var n, o, i = (t = t || {}).body; | |
if (e instanceof b) { | |
if (e.bodyUsed) throw new TypeError("Already read"); | |
this.url = e.url, this.credentials = e.credentials, t.headers || (this.headers = new f(e.headers)), this.method = e.method, this.mode = e.mode, this.signal = e.signal, i || null == e._bodyInit || (i = e._bodyInit, e.bodyUsed = !0) | |
} else this.url = String(e); | |
if (this.credentials = t.credentials || this.credentials || "same-origin", !t.headers && this.headers || (this.headers = new f(t.headers)), this.method = (n = t.method || this.method || "GET", o = n.toUpperCase(), v.indexOf(o) > -1 ? o : n), this.mode = t.mode || this.mode || null, this.signal = t.signal || this.signal, this.referrer = null, ("GET" === this.method || "HEAD" === this.method) && i) throw new TypeError("Body not allowed for GET or HEAD requests"); | |
if (this._initBody(i), !("GET" !== this.method && "HEAD" !== this.method || "no-store" !== t.cache && "no-cache" !== t.cache)) { | |
var r = /([?&])_=[^&]*/; | |
r.test(this.url) ? this.url = this.url.replace(r, "$1_=" + (new Date).getTime()) : this.url += (/\?/.test(this.url) ? "&" : "?") + "_=" + (new Date).getTime() | |
} | |
} | |
function w(e) { | |
var t = new FormData; | |
return e.trim().split("&").forEach((function(e) { | |
if (e) { | |
var n = e.split("="), | |
o = n.shift().replace(/\+/g, " "), | |
i = n.join("=").replace(/\+/g, " "); | |
t.append(decodeURIComponent(o), decodeURIComponent(i)) | |
} | |
})), t | |
} | |
function _(e, t) { | |
if (!(this instanceof _)) throw new TypeError('Please use the "new" operator, this DOM object constructor cannot be called as a function.'); | |
t || (t = {}), this.type = "default", this.status = void 0 === t.status ? 200 : t.status, this.ok = this.status >= 200 && this.status < 300, this.statusText = void 0 === t.statusText ? "" : "" + t.statusText, this.headers = new f(t.headers), this.url = t.url || "", this._initBody(e) | |
} | |
b.prototype.clone = function() { | |
return new b(this, { | |
body: this._bodyInit | |
}) | |
}, y.call(b.prototype), y.call(_.prototype), _.prototype.clone = function() { | |
return new _(this._bodyInit, { | |
status: this.status, | |
statusText: this.statusText, | |
headers: new f(this.headers), | |
url: this.url | |
}) | |
}, _.error = function() { | |
var e = new _(null, { | |
status: 0, | |
statusText: "" | |
}); | |
return e.type = "error", e | |
}; | |
var E = [301, 302, 303, 307, 308]; | |
_.redirect = function(e, t) { | |
if (-1 === E.indexOf(t)) throw new RangeError("Invalid status code"); | |
return new _(null, { | |
status: t, | |
headers: { | |
location: e | |
} | |
}) | |
}, e.DOMException = t.DOMException; | |
try { | |
new e.DOMException | |
} catch (t) { | |
e.DOMException = function(e, t) { | |
this.message = e, this.name = t; | |
var n = Error(e); | |
this.stack = n.stack | |
}, e.DOMException.prototype = Object.create(Error.prototype), e.DOMException.prototype.constructor = e.DOMException | |
} | |
function L(n, o) { | |
return new Promise((function(r, a) { | |
var c = new b(n, o); | |
if (c.signal && c.signal.aborted) return a(new e.DOMException("Aborted", "AbortError")); | |
var u = new XMLHttpRequest; | |
function d() { | |
u.abort() | |
} | |
u.onload = function() { | |
var e, t, n = { | |
status: u.status, | |
statusText: u.statusText, | |
headers: (e = u.getAllResponseHeaders() || "", t = new f, e.replace(/\r?\n[\t ]+/g, " ").split("\r").map((function(e) { | |
return 0 === e.indexOf("\n") ? e.substr(1, e.length) : e | |
})).forEach((function(e) { | |
var n = e.split(":"), | |
o = n.shift().trim(); | |
if (o) { | |
var i = n.join(":").trim(); | |
t.append(o, i) | |
} | |
})), t) | |
}; | |
n.url = "responseURL" in u ? u.responseURL : n.headers.get("X-Request-URL"); | |
var o = "response" in u ? u.response : u.responseText; | |
setTimeout((function() { | |
r(new _(o, n)) | |
}), 0) | |
}, u.onerror = function() { | |
setTimeout((function() { | |
a(new TypeError("Network request failed")) | |
}), 0) | |
}, u.ontimeout = function() { | |
setTimeout((function() { | |
a(new TypeError("Network request failed")) | |
}), 0) | |
}, u.onabort = function() { | |
setTimeout((function() { | |
a(new e.DOMException("Aborted", "AbortError")) | |
}), 0) | |
}, u.open(c.method, function(e) { | |
try { | |
return "" === e && t.location.href ? t.location.href : e | |
} catch (t) { | |
return e | |
} | |
}(c.url), !0), "include" === c.credentials ? u.withCredentials = !0 : "omit" === c.credentials && (u.withCredentials = !1), "responseType" in u && (i ? u.responseType = "blob" : s && c.headers.get("Content-Type") && -1 !== c.headers.get("Content-Type").indexOf("application/octet-stream") && (u.responseType = "arraybuffer")), !o || "object" != typeof o.headers || o.headers instanceof f ? c.headers.forEach((function(e, t) { | |
u.setRequestHeader(t, e) | |
})) : Object.getOwnPropertyNames(o.headers).forEach((function(e) { | |
u.setRequestHeader(e, l(o.headers[e])) | |
})), c.signal && (c.signal.addEventListener("abort", d), u.onreadystatechange = function() { | |
4 === u.readyState && c.signal.removeEventListener("abort", d) | |
}), u.send(void 0 === c._bodyInit ? null : c._bodyInit) | |
})) | |
} | |
L.polyfill = !0, t.fetch || (t.fetch = L, t.Headers = f, t.Request = b, t.Response = _), e.Headers = f, e.Request = b, e.Response = _, e.fetch = L, Object.defineProperty(e, "__esModule", { | |
value: !0 | |
}) | |
}(t), e.exports = self.fetch | |
}, , function(e, t, n) { | |
"use strict"; | |
var o = /\s/; | |
var i = function(e) { | |
for (var t = e.length; t-- && o.test(e.charAt(t));); | |
return t | |
}, | |
r = /^\s+/; | |
var s = function(e) { | |
return e ? e.slice(0, i(e) + 1).replace(r, "") : e | |
}, | |
a = n(9), | |
c = n(25), | |
u = /^[-+]0x[0-9a-f]+$/i, | |
l = /^0b[01]+$/i, | |
d = /^0o[0-7]+$/i, | |
f = parseInt; | |
t.a = function(e) { | |
if ("number" == typeof e) return e; | |
if (Object(c.a)(e)) return NaN; | |
if (Object(a.a)(e)) { | |
var t = "function" == typeof e.valueOf ? e.valueOf() : e; | |
e = Object(a.a)(t) ? t + "" : t | |
} | |
if ("string" != typeof e) return 0 === e ? e : +e; | |
e = s(e); | |
var n = l.test(e); | |
return n || d.test(e) ? f(e.slice(2), n ? 2 : 8) : u.test(e) ? NaN : +e | |
} | |
}, function(e, t, n) { | |
"use strict"; | |
var o = n(44), | |
i = n(47), | |
r = n(19), | |
s = n(20); | |
e.exports = n(50)(Array, "Array", (function(e, t) { | |
this._t = s(e), this._i = 0, this._k = t | |
}), (function() { | |
var e = this._t, | |
t = this._k, | |
n = this._i++; | |
return !e || n >= e.length ? (this._t = void 0, i(1)) : i(0, "keys" == t ? n : "values" == t ? e[n] : [n, e[n]]) | |
}), "values"), r.Arguments = r.Array, o("keys"), o("values"), o("entries") | |
}, function(e, t, n) { | |
var o = n(4)("unscopables"), | |
i = Array.prototype; | |
null == i[o] && n(3)(i, o, {}), e.exports = function(e) { | |
i[o][e] = !0 | |
} | |
}, function(e, t, n) { | |
e.exports = !n(7) && !n(28)((function() { | |
return 7 != Object.defineProperty(n(29)("div"), "a", { | |
get: function() { | |
return 7 | |
} | |
}).a | |
})) | |
}, function(e, t, n) { | |
var o = n(18); | |
e.exports = function(e, t) { | |
if (!o(e)) return e; | |
var n, i; | |
if (t && "function" == typeof(n = e.toString) && !o(i = n.call(e))) return i; | |
if ("function" == typeof(n = e.valueOf) && !o(i = n.call(e))) return i; | |
if (!t && "function" == typeof(n = e.toString) && !o(i = n.call(e))) return i; | |
throw TypeError("Can't convert object to primitive value") | |
} | |
}, function(e, t) { | |
e.exports = function(e, t) { | |
return { | |
value: t, | |
done: !!e | |
} | |
} | |
}, function(e, t, n) { | |
var o = n(49); | |
e.exports = Object("z").propertyIsEnumerable(0) ? Object : function(e) { | |
return "String" == o(e) ? e.split("") : Object(e) | |
} | |
}, function(e, t) { | |
var n = {}.toString; | |
e.exports = function(e) { | |
return n.call(e).slice(8, -1) | |
} | |
}, function(e, t, n) { | |
"use strict"; | |
var o = n(27), | |
i = n(51), | |
r = n(21), | |
s = n(3), | |
a = n(19), | |
c = n(55), | |
u = n(35), | |
l = n(63), | |
d = n(4)("iterator"), | |
f = !([].keys && "next" in [].keys()), | |
p = function() { | |
return this | |
}; | |
e.exports = function(e, t, n, m, h, g, y) { | |
c(n, t, m); | |
var v, b, w, _ = function(e) { | |
if (!f && e in T) return T[e]; | |
switch (e) { | |
case "keys": | |
case "values": | |
return function() { | |
return new n(this, e) | |
} | |
} | |
return function() { | |
return new n(this, e) | |
} | |
}, | |
E = t + " Iterator", | |
L = "values" == h, | |
O = !1, | |
T = e.prototype, | |
j = T[d] || T["@@iterator"] || h && T[h], | |
I = j || _(h), | |
S = h ? L ? _("entries") : I : void 0, | |
x = "Array" == t && T.entries || j; | |
if (x && (w = l(x.call(new e))) !== Object.prototype && w.next && (u(w, E, !0), o || "function" == typeof w[d] || s(w, d, p)), L && j && "values" !== j.name && (O = !0, I = function() { | |
return j.call(this) | |
}), o && !y || !f && !O && T[d] || s(T, d, I), a[t] = I, a[E] = p, h) | |
if (v = { | |
values: L ? I : _("values"), | |
keys: g ? I : _("keys"), | |
entries: S | |
}, y) | |
for (b in v) b in T || r(T, b, v[b]); | |
else i(i.P + i.F * (f || O), t, v); | |
return v | |
} | |
}, function(e, t, n) { | |
var o = n(0), | |
i = n(14), | |
r = n(3), | |
s = n(21), | |
a = n(53), | |
c = function(e, t, n) { | |
var u, l, d, f, p = e & c.F, | |
m = e & c.G, | |
h = e & c.S, | |
g = e & c.P, | |
y = e & c.B, | |
v = m ? o : h ? o[t] || (o[t] = {}) : (o[t] || {}).prototype, | |
b = m ? i : i[t] || (i[t] = {}), | |
w = b.prototype || (b.prototype = {}); | |
for (u in m && (n = t), n) d = ((l = !p && v && void 0 !== v[u]) ? v : n)[u], f = y && l ? a(d, o) : g && "function" == typeof d ? a(Function.call, d) : d, v && s(v, u, d, e & c.U), b[u] != d && r(b, u, f), g && w[u] != d && (w[u] = d) | |
}; | |
o.core = i, c.F = 1, c.G = 2, c.S = 4, c.P = 8, c.B = 16, c.W = 32, c.U = 64, c.R = 128, e.exports = c | |
}, function(e, t, n) { | |
e.exports = n(13)("native-function-to-string", Function.toString) | |
}, function(e, t, n) { | |
var o = n(54); | |
e.exports = function(e, t, n) { | |
if (o(e), void 0 === t) return e; | |
switch (n) { | |
case 1: | |
return function(n) { | |
return e.call(t, n) | |
}; | |
case 2: | |
return function(n, o) { | |
return e.call(t, n, o) | |
}; | |
case 3: | |
return function(n, o, i) { | |
return e.call(t, n, o, i) | |
} | |
} | |
return function() { | |
return e.apply(t, arguments) | |
} | |
} | |
}, function(e, t) { | |
e.exports = function(e) { | |
if ("function" != typeof e) throw TypeError(e + " is not a function!"); | |
return e | |
} | |
}, function(e, t, n) { | |
"use strict"; | |
var o = n(56), | |
i = n(30), | |
r = n(35), | |
s = {}; | |
n(3)(s, n(4)("iterator"), (function() { | |
return this | |
})), e.exports = function(e, t, n) { | |
e.prototype = o(s, { | |
next: i(1, n) | |
}), r(e, t + " Iterator") | |
} | |
}, function(e, t, n) { | |
var o = n(17), | |
i = n(57), | |
r = n(34), | |
s = n(22)("IE_PROTO"), | |
a = function() {}, | |
c = function() { | |
var e, t = n(29)("iframe"), | |
o = r.length; | |
for (t.style.display = "none", n(62).appendChild(t), t.src = "javascript:", (e = t.contentWindow.document).open(), e.write("<script>document.F=Object<\/script>"), e.close(), c = e.F; o--;) delete c.prototype[r[o]]; | |
return c() | |
}; | |
e.exports = Object.create || function(e, t) { | |
var n; | |
return null !== e ? (a.prototype = o(e), n = new a, a.prototype = null, n[s] = e) : n = c(), void 0 === t ? n : i(n, t) | |
} | |
}, function(e, t, n) { | |
var o = n(16), | |
i = n(17), | |
r = n(32); | |
e.exports = n(7) ? Object.defineProperties : function(e, t) { | |
i(e); | |
for (var n, s = r(t), a = s.length, c = 0; a > c;) o.f(e, n = s[c++], t[n]); | |
return e | |
} | |
}, function(e, t, n) { | |
var o = n(8), | |
i = n(20), | |
r = n(59)(!1), | |
s = n(22)("IE_PROTO"); | |
e.exports = function(e, t) { | |
var n, a = i(e), | |
c = 0, | |
u = []; | |
for (n in a) n != s && o(a, n) && u.push(n); | |
for (; t.length > c;) o(a, n = t[c++]) && (~r(u, n) || u.push(n)); | |
return u | |
} | |
}, function(e, t, n) { | |
var o = n(20), | |
i = n(60), | |
r = n(61); | |
e.exports = function(e) { | |
return function(t, n, s) { | |
var a, c = o(t), | |
u = i(c.length), | |
l = r(s, u); | |
if (e && n != n) { | |
for (; u > l;) | |
if ((a = c[l++]) != a) return !0 | |
} else | |
for (; u > l; l++) | |
if ((e || l in c) && c[l] === n) return e || l || 0; | |
return !e && -1 | |
} | |
} | |
}, function(e, t, n) { | |
var o = n(33), | |
i = Math.min; | |
e.exports = function(e) { | |
return e > 0 ? i(o(e), 9007199254740991) : 0 | |
} | |
}, function(e, t, n) { | |
var o = n(33), | |
i = Math.max, | |
r = Math.min; | |
e.exports = function(e, t) { | |
return (e = o(e)) < 0 ? i(e + t, 0) : r(e, t) | |
} | |
}, function(e, t, n) { | |
var o = n(0).document; | |
e.exports = o && o.documentElement | |
}, function(e, t, n) { | |
var o = n(8), | |
i = n(64), | |
r = n(22)("IE_PROTO"), | |
s = Object.prototype; | |
e.exports = Object.getPrototypeOf || function(e) { | |
return e = i(e), o(e, r) ? e[r] : "function" == typeof e.constructor && e instanceof e.constructor ? e.constructor.prototype : e instanceof Object ? s : null | |
} | |
}, function(e, t, n) { | |
var o = n(31); | |
e.exports = function(e) { | |
return Object(o(e)) | |
} | |
}, , function(e, t, n) { | |
"use strict"; | |
const o = []; | |
t.a = (e, t = !1, n = !1, i) => { | |
if (o.indexOf(e) >= 0) { | |
const t = document.querySelector('script[src~="'.concat(e, '"]')); | |
if (t) return void i(t) | |
} | |
const r = document.createElement("script"); | |
r.type = "text/javascript", r.async = t, r.defer = n, r.src = e, r.onload = () => { | |
o.push(e), i && i(r) | |
}, (document.getElementsByTagName("head")[0] || document.getElementsByTagName("body")[0] || document.getElementsByTagName("script")[0].parentNode).insertBefore(r, null) | |
} | |
}, function(e, t, n) { | |
"use strict"; | |
n.d(t, "b", (function() { | |
return i | |
})), n.d(t, "h", (function() { | |
return r | |
})), n.d(t, "k", (function() { | |
return s | |
})), n.d(t, "f", (function() { | |
return a | |
})), n.d(t, "g", (function() { | |
return c | |
})), n.d(t, "j", (function() { | |
return u | |
})), n.d(t, "c", (function() { | |
return l | |
})), n.d(t, "d", (function() { | |
return d | |
})), n.d(t, "i", (function() { | |
return f | |
})), n.d(t, "e", (function() { | |
return p | |
})), n.d(t, "a", (function() { | |
return h | |
})), n.d(t, "m", (function() { | |
return y | |
})), n.d(t, "l", (function() { | |
return v | |
})); | |
var o = n(24); | |
const i = () => { | |
const e = window.lmd.context && window.lmd.context.element && window.lmd.context.element.type, | |
{ | |
typePage: t | |
} = window.lmd; | |
return "Article" !== e || "video" !== t && "portfolio" !== t ? e : t | |
}, | |
r = () => window.lmd.context && window.lmd.context.element && window.lmd.context.element.restreint || !1, | |
s = (e = null) => { | |
let t = ""; | |
if (Object(o.a)(window.lmd, "context", "pageType") && (t = window.lmd.context.pageType.toLowerCase()), "amplitude" === e && Object(o.a)(window.lmd, "analytics", "amplitude", "pageType")) return window.lmd.analytics.amplitude.pageType.toLowerCase(); | |
if ("fba" === e && Object(o.a)(window.lmd, "analytics", "fba", "pageType")) return window.lmd.analytics.fba.pageType.toLowerCase(); | |
switch (t) { | |
case "rubrique_une": | |
case "rubrique_une_abonnes": | |
return "home"; | |
case "rubrique": | |
return "home rubrique"; | |
case "element": | |
return "element-".concat(i().toLowerCase() || "none").concat(r() ? "-restreint" : ""); | |
default: | |
return t | |
} | |
}, | |
a = () => window.lmd.context && window.lmd.context.element && window.lmd.context.element.is_a_teaser || !1, | |
c = () => window.lmd.context && window.lmd.context.element && window.lmd.context.element.type && "Article" === window.lmd.context.element.type && window.lmd.context.article && window.lmd.context.article.format && "large" === window.lmd.context.article.format; | |
function u() { | |
return "Grand Format" === window.lmd.typePage | |
} | |
const l = e => e.nature_editoriale && e.nature_editoriale.nom ? e.nature_editoriale.nom : "", | |
d = () => window.performance && { | |
0: "navigates", | |
1: "reload", | |
2: "back", | |
255: "?" | |
} [window.performance.navigation.type] || "?", | |
f = () => { | |
const e = navigator.userAgent || navigator.vendor || window.opera; | |
return -1 !== e.indexOf("FBAN") || -1 !== e.indexOf("FBAV") | |
}, | |
p = () => window.innerWidth || document.documentElement.clientWidth || document.body.clientWidth; | |
let m = !1; | |
const h = () => { | |
const e = sessionStorage.getItem("pageinsession"); | |
if (!0 === m && e) return e.length; | |
if (m = !0, "reload" !== d()) { | |
const t = e && "".concat(e, "i") || "i"; | |
return sessionStorage.setItem("pageinsession", t), t.length | |
} | |
return e ? e.length : 1 | |
}, | |
g = (e, t) => Math.round((e - t) / 1e3), | |
y = () => g(Date.now(), window.performance.timing.domInteractive), | |
v = () => g(window.performance.timing.domInteractive, window.performance.timing.connectStart) | |
}, , , , , , function(e, t, n) { | |
"use strict"; | |
function o() { | |
const e = window, | |
t = document, | |
n = t.documentElement, | |
o = t.getElementsByTagName("body")[0], | |
i = e.innerHeight || n.clientHeight || o.clientHeight; | |
return { | |
width: e.innerWidth || n.clientWidth || o.clientWidth, | |
height: i | |
} | |
} | |
function i(e) { | |
const t = e.getBoundingClientRect(), | |
n = window.pageYOffset || document.documentElement.scrollTop; | |
return t.top + n | |
} | |
n.d(t, "b", (function() { | |
return o | |
})), n.d(t, "a", (function() { | |
return i | |
})) | |
}, function(e, t, n) { | |
"use strict"; | |
n.d(t, "a", (function() { | |
return o | |
})), n.d(t, "f", (function() { | |
return i | |
})), n.d(t, "b", (function() { | |
return r | |
})), n.d(t, "e", (function() { | |
return s | |
})), n.d(t, "d", (function() { | |
return a | |
})), n.d(t, "c", (function() { | |
return c | |
})); | |
const o = (e, t) => { | |
window.addEventListener ? window.addEventListener(e, t, !1) : window.attachEvent && window.attachEvent("on".concat(e), t) | |
}, | |
i = (e, t) => { | |
window.removeEventListener ? window.removeEventListener(e, t) : window.detachEvent && window.detachEvent("on".concat(e), t) | |
}, | |
r = (window.performance.navigation.type, e => { | |
const t = document.querySelector(e); | |
if (null === t) return !1; | |
const n = t.getBoundingClientRect(); | |
return Math.max(document.documentElement.clientHeight, window.innerHeight) - n.top > 0 | |
}), | |
s = e => { | |
let t = !0; | |
o("scroll", (function() { | |
t && (t = !1, e.bind(document.documentElement)()) | |
})) | |
}, | |
a = (e, t) => { | |
let n = !0; | |
o("scroll", (function() { | |
if (r(e) && n) { | |
const o = document.querySelector(e); | |
n = !1, t.bind(o)() | |
} | |
})) | |
}, | |
c = (e, t) => { | |
let n = !0; | |
o("scroll", (function() { | |
if ((e => { | |
const t = document.querySelector(e); | |
if (null === t) return !1; | |
const n = t.getBoundingClientRect(); | |
return Math.max(document.documentElement.clientHeight, window.innerHeight) - n.bottom > 0 | |
})(e) && n) { | |
const o = document.querySelector(e); | |
n = !1, t.bind(o)() | |
} | |
})) | |
} | |
}, function(e, t, n) { | |
"use strict"; | |
n.d(t, "d", (function() { | |
return u | |
})), n.d(t, "a", (function() { | |
return c | |
})), n.d(t, "b", (function() { | |
return s | |
})), n.d(t, "c", (function() { | |
return r | |
})); | |
var o = n(1); | |
const i = { | |
ads: 5, | |
analytics: 2, | |
personalization: 4, | |
mediaPlatforms: !1, | |
social: 3 | |
}; | |
function r(e = 1964504, t = 80722398) { | |
Object(o.a)("getIubendaConsentFromCookie"); | |
const n = document.cookie.split(";"); | |
for (let o = 0; o < n.length; o += 1) | |
if (" " === n[o].charAt(0) && (n[o] = n[o].substring(1)), (0 === n[o].indexOf("_iub_cs-s".concat(e)) || 0 === n[o].indexOf("_iub_cs-".concat(t))) && -1 !== n[o].indexOf("purposes")) try { | |
const e = JSON.parse(decodeURIComponent(n[o]).split("=")[1]).purposes; | |
return delete e[1], e | |
} catch (e) { | |
return !1 | |
} | |
return null | |
} | |
function s() { | |
Object(o.a)("getConsentFromCookie"); | |
let e = null; | |
const t = RegExp("lmd_consent=[^;]+").exec(document.cookie); | |
if (t) { | |
const n = JSON.parse(decodeURIComponent(t ? t.toString().replace(/^[^=]+./, "") : "")); | |
n.purposes && (e = {}, Object.keys(n.purposes).forEach(t => { | |
const o = i[t] || !1; | |
!1 !== o && (e[o] = n.purposes[t]) | |
})) | |
} | |
return e | |
} | |
const a = () => { | |
Object(o.a)("getPurposesFromCookie"); | |
let e = null; | |
const t = RegExp("lmd_consent=[^;]+").exec(document.cookie); | |
if (t) { | |
const n = JSON.parse(decodeURIComponent(t ? t.toString().replace(/^[^=]+./, "") : "")); | |
n.purposes && (e = n.purposes) | |
} | |
return e | |
}, | |
c = e => { | |
Object(o.a)("getConsentForPurpose - type: ".concat(e)); | |
const t = a(); | |
return !(!t || !t[e]) && t[e] | |
}; | |
function u() { | |
return Object(o.a)("hasConsent"), null !== a() | |
} | |
}, , , function(e, t, n) { | |
"use strict"; | |
var o = n(9), | |
i = n(2), | |
r = function() { | |
return i.a.Date.now() | |
}, | |
s = n(42), | |
a = Math.max, | |
c = Math.min; | |
t.a = function(e, t, n) { | |
var i, u, l, d, f, p, m = 0, | |
h = !1, | |
g = !1, | |
y = !0; | |
if ("function" != typeof e) throw new TypeError("Expected a function"); | |
function v(t) { | |
var n = i, | |
o = u; | |
return i = u = void 0, m = t, d = e.apply(o, n) | |
} | |
function b(e) { | |
return m = e, f = setTimeout(_, t), h ? v(e) : d | |
} | |
function w(e) { | |
var n = e - p; | |
return void 0 === p || n >= t || n < 0 || g && e - m >= l | |
} | |
function _() { | |
var e = r(); | |
if (w(e)) return E(e); | |
f = setTimeout(_, function(e) { | |
var n = t - (e - p); | |
return g ? c(n, l - (e - m)) : n | |
}(e)) | |
} | |
function E(e) { | |
return f = void 0, y && i ? v(e) : (i = u = void 0, d) | |
} | |
function L() { | |
var e = r(), | |
n = w(e); | |
if (i = arguments, u = this, p = e, n) { | |
if (void 0 === f) return b(p); | |
if (g) return clearTimeout(f), f = setTimeout(_, t), v(p) | |
} | |
return void 0 === f && (f = setTimeout(_, t)), d | |
} | |
return t = Object(s.a)(t) || 0, Object(o.a)(n) && (h = !!n.leading, l = (g = "maxWait" in n) ? a(Object(s.a)(n.maxWait) || 0, t) : l, y = "trailing" in n ? !!n.trailing : y), L.cancel = function() { | |
void 0 !== f && clearTimeout(f), m = 0, i = p = u = f = void 0 | |
}, L.flush = function() { | |
return void 0 === f ? d : E(r()) | |
}, L | |
} | |
}, , function(e, t) { | |
var n; | |
n = function() { | |
return this | |
}(); | |
try { | |
n = n || new Function("return this")() | |
} catch (e) { | |
"object" == typeof window && (n = window) | |
} | |
e.exports = n | |
}, , , , , function(e, t, n) { | |
"use strict"; | |
n.d(t, "a", (function() { | |
return c | |
})), n.d(t, "b", (function() { | |
return r | |
})), n.d(t, "c", (function() { | |
return a | |
})); | |
const o = { | |
key: () => {}, | |
getItem: () => null, | |
setItem: () => {}, | |
removeItem: () => {}, | |
clear: () => {} | |
}; | |
window.sessionStorage && (o.getItem = e => JSON.parse(window.sessionStorage.getItem(e)), o.setItem = (e, t) => window.sessionStorage.setItem(e, JSON.stringify(t))); | |
var i = o; | |
window.wasAutoRefresh = "boolean" == typeof window.wasAutoRefresh ? window.wasAutoRefresh : null, window.autoRefreshInterval = window.autoRefreshInterval || null; | |
const r = e => [3090717, 3092470, 3129731, 3141491].indexOf(e) > -1, | |
s = () => { | |
const e = i.getItem("auto-refresh") || !1, | |
t = i.getItem("auto-refresh-from") || !1; | |
return null === window.wasAutoRefresh && (window.wasAutoRefresh = e && t === document.location.toString(), i.setItem("auto-refresh", !1)), window.wasAutoRefresh | |
}, | |
a = () => "boolean" == typeof window.wasAutoRefresh ? window.wasAutoRefresh : s(), | |
c = (e = (() => !0), t = 36e4) => { | |
null !== window.autoRefreshInterval && clearInterval(window.autoRefreshInterval), s(), window.autoRefreshInterval = setInterval(() => { | |
!0 === e() && (i.setItem("auto-refresh", !0), i.setItem("auto-refresh-from", document.location.toString()), document.location.reload()) | |
}, t) | |
} | |
}, , , , , , function(e, t, n) { | |
"use strict"; | |
t.a = function(e, t, n) { | |
const o = new IntersectionObserver(t, n || {}); | |
return o.observe(e), o | |
} | |
}, , , , function(e, t, n) { | |
"use strict"; | |
var o = n(78), | |
i = n(9); | |
t.a = function(e, t, n) { | |
var r = !0, | |
s = !0; | |
if ("function" != typeof e) throw new TypeError("Expected a function"); | |
return Object(i.a)(n) && (r = "leading" in n ? !!n.leading : r, s = "trailing" in n ? !!n.trailing : s), Object(o.a)(e, t, { | |
leading: r, | |
maxWait: t, | |
trailing: s | |
}) | |
} | |
}, , function(e, t, n) { | |
var o, i, r, s = Object.assign || function(e) { | |
for (var t = 1; t < arguments.length; t++) { | |
var n = arguments[t]; | |
for (var o in n) Object.prototype.hasOwnProperty.call(n, o) && (e[o] = n[o]) | |
} | |
return e | |
}, | |
a = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function(e) { | |
return typeof e | |
} : function(e) { | |
return e && "function" == typeof Symbol && e.constructor === Symbol && e !== Symbol.prototype ? "symbol" : typeof e | |
}; | |
r = function() { | |
"use strict"; | |
var e = function(e, t) { | |
return e.getAttribute("data-" + t) | |
}, | |
t = function(t) { | |
return "true" === e(t, "was-processed") | |
}, | |
n = function(e) { | |
return e.getBoundingClientRect().top + window.pageYOffset - e.ownerDocument.documentElement.clientTop | |
}, | |
o = function(e) { | |
return e.getBoundingClientRect().left + window.pageXOffset - e.ownerDocument.documentElement.clientLeft | |
}; | |
function i(e, t, i) { | |
return !(function(e, t, o) { | |
return (t === window ? window.innerHeight + window.pageYOffset : n(t) + t.offsetHeight) <= n(e) - o | |
}(e, t, i) || function(e, t, o) { | |
return (t === window ? window.pageYOffset : n(t)) >= n(e) + o + e.offsetHeight | |
}(e, t, i) || function(e, t, n) { | |
var i = window.innerWidth; | |
return (t === window ? i + window.pageXOffset : o(t) + i) <= o(e) - n | |
}(e, t, i) || function(e, t, n) { | |
return (t === window ? window.pageXOffset : o(t)) >= o(e) + n + e.offsetWidth | |
}(e, t, i)) | |
} | |
var r, a = function(e, t) { | |
var n, o = new e(t); | |
try { | |
n = new CustomEvent("LazyLoad::Initialized", { | |
detail: { | |
instance: o | |
} | |
}) | |
} catch (e) { | |
(n = document.createEvent("CustomEvent")).initCustomEvent("LazyLoad::Initialized", !1, !1, { | |
instance: o | |
}) | |
} | |
window.dispatchEvent(n) | |
}, | |
c = function(e, t) { | |
return t ? e.replace(/\.(jpe?g|png)/gi, ".webp") : e | |
}, | |
u = "undefined" != typeof window, | |
l = u && !("onscroll" in window) || /(gle|ing|ro)bot|crawl|spider/i.test(navigator.userAgent), | |
d = u && "classList" in document.createElement("p"), | |
f = u && !(!(r = document.createElement("canvas")).getContext || !r.getContext("2d")) && 0 === r.toDataURL("image/webp").indexOf("data:image/webp"), | |
p = function(e, t) { | |
d ? e.classList.add(t) : e.className += (e.className ? " " : "") + t | |
}, | |
m = function(t, n, o, i) { | |
for (var r, s = 0; r = t.children[s]; s += 1) | |
if ("SOURCE" === r.tagName) { | |
var a = e(r, o); | |
h(r, n, a, i) | |
} | |
}, | |
h = function(e, t, n, o) { | |
n && e.setAttribute(t, c(n, o)) | |
}, | |
g = { | |
IMG: function(t, n) { | |
var o = f && n.to_webp, | |
i = n.data_srcset, | |
r = t.parentNode; | |
r && "PICTURE" === r.tagName && m(r, "srcset", i, o); | |
var s = e(t, n.data_sizes); | |
h(t, "sizes", s); | |
var a = e(t, i); | |
h(t, "srcset", a, o); | |
var c = e(t, n.data_src); | |
h(t, "src", c, o) | |
}, | |
IFRAME: function(t, n) { | |
var o = e(t, n.data_src); | |
h(t, "src", o) | |
}, | |
VIDEO: function(t, n) { | |
var o = n.data_src, | |
i = e(t, o); | |
m(t, "src", o), h(t, "src", i), t.load() | |
} | |
}, | |
y = function(t, n) { | |
var o, i, r = n._settings, | |
s = t.tagName, | |
a = g[s]; | |
if (a) return a(t, r), n._updateLoadingCount(1), void(n._elements = (o = n._elements, i = t, o.filter((function(e) { | |
return e !== i | |
})))); | |
! function(t, n) { | |
var o = f && n.to_webp, | |
i = e(t, n.data_src), | |
r = e(t, n.data_bg); | |
if (i) { | |
var s = c(i, o); | |
t.style.backgroundImage = 'url("' + s + '")' | |
} | |
if (r) { | |
var a = c(r, o); | |
t.style.backgroundImage = a | |
} | |
}(t, r) | |
}, | |
v = function(e, t) { | |
e && e(t) | |
}, | |
b = function(e, t, n) { | |
e.addEventListener(t, n) | |
}, | |
w = function(e, t, n) { | |
e.removeEventListener(t, n) | |
}, | |
_ = function(e, t, n) { | |
w(e, "load", t), w(e, "loadeddata", t), w(e, "error", n) | |
}, | |
E = function(e, t, n) { | |
var o = n._settings, | |
i = t ? o.class_loaded : o.class_error, | |
r = t ? o.callback_load : o.callback_error, | |
s = e.target; | |
! function(e, t) { | |
d ? e.classList.remove(t) : e.className = e.className.replace(new RegExp("(^|\\s+)" + t + "(\\s+|$)"), " ").replace(/^\s+/, "").replace(/\s+$/, "") | |
}(s, o.class_loading), p(s, i), v(r, s), n._updateLoadingCount(-1) | |
}, | |
L = function(e, t) { | |
var n = function n(i) { | |
E(i, !0, t), _(e, n, o) | |
}, | |
o = function o(i) { | |
E(i, !1, t), _(e, n, o) | |
}; | |
! function(e, t, n) { | |
b(e, "load", t), b(e, "loadeddata", t), b(e, "error", n) | |
}(e, n, o) | |
}, | |
O = ["IMG", "IFRAME", "VIDEO"], | |
T = function(e) { | |
this._settings = s({}, { | |
elements_selector: "img", | |
container: window, | |
threshold: 300, | |
throttle: 150, | |
data_src: "src", | |
data_srcset: "srcset", | |
data_sizes: "sizes", | |
data_bg: "bg", | |
class_loading: "loading", | |
class_loaded: "loaded", | |
class_error: "error", | |
class_initial: "initial", | |
skip_invisible: !0, | |
callback_load: null, | |
callback_error: null, | |
callback_set: null, | |
callback_enter: null, | |
callback_finish: null, | |
to_webp: !1 | |
}, e), this._loadingCount = 0, this._queryOriginNode = this._settings.container === window ? document : this._settings.container, this._previousLoopTime = 0, this._loopTimeout = null, this._boundHandleScroll = this.handleScroll.bind(this), this._isFirstLoop = !0, window.addEventListener("resize", this._boundHandleScroll), this.update() | |
}; | |
return T.prototype = { | |
_loopThroughElements: function(e) { | |
var t = this._settings, | |
n = this._elements, | |
o = n ? n.length : 0, | |
r = void 0, | |
s = [], | |
a = this._isFirstLoop; | |
if (a && (this._isFirstLoop = !1), 0 !== o) { | |
for (r = 0; r < o; r++) { | |
var c = n[r]; | |
t.skip_invisible && null === c.offsetParent || (e || i(c, t.container, t.threshold)) && (a && p(c, t.class_initial), this.load(c), s.push(r)) | |
}! function(e, t) { | |
for (; t.length;) e.splice(t.pop(), 1) | |
}(n, s) | |
} else this._stopScrollHandler() | |
}, | |
_startScrollHandler: function() { | |
this._isHandlingScroll || (this._isHandlingScroll = !0, this._settings.container.addEventListener("scroll", this._boundHandleScroll)) | |
}, | |
_stopScrollHandler: function() { | |
this._isHandlingScroll && (this._isHandlingScroll = !1, this._settings.container.removeEventListener("scroll", this._boundHandleScroll)) | |
}, | |
_updateLoadingCount: function(e) { | |
this._loadingCount += e, 0 === this._elements.length && 0 === this._loadingCount && v(this._settings.callback_finish) | |
}, | |
handleScroll: function() { | |
var e = this._settings.throttle; | |
if (0 !== e) { | |
var t = Date.now(), | |
n = e - (t - this._previousLoopTime); | |
n <= 0 || n > e ? (this._loopTimeout && (clearTimeout(this._loopTimeout), this._loopTimeout = null), this._previousLoopTime = t, this._loopThroughElements()) : this._loopTimeout || (this._loopTimeout = setTimeout(function() { | |
this._previousLoopTime = Date.now(), this._loopTimeout = null, this._loopThroughElements() | |
}.bind(this), n)) | |
} else this._loopThroughElements() | |
}, | |
loadAll: function() { | |
this._loopThroughElements(!0) | |
}, | |
update: function(e) { | |
var n = this._settings, | |
o = e || this._queryOriginNode.querySelectorAll(n.elements_selector); | |
this._elements = function(e) { | |
return e.filter((function(e) { | |
return !t(e) | |
})) | |
}(Array.prototype.slice.call(o)), l ? this.loadAll() : (this._loopThroughElements(), this._startScrollHandler()) | |
}, | |
destroy: function() { | |
window.removeEventListener("resize", this._boundHandleScroll), this._loopTimeout && (clearTimeout(this._loopTimeout), this._loopTimeout = null), this._stopScrollHandler(), this._elements = null, this._queryOriginNode = null, this._settings = null | |
}, | |
load: function(e, n) { | |
! function(e, n, o) { | |
var i = n._settings; | |
!o && t(e) || (v(i.callback_enter, e), O.indexOf(e.tagName) > -1 && (L(e, n), p(e, i.class_loading)), y(e, n), function(e) { | |
! function(e, t, n) { | |
var o = "data-" + t; | |
null !== n ? e.setAttribute(o, n) : e.removeAttribute(o) | |
}(e, "was-processed", "true") | |
}(e), v(i.callback_set, e)) | |
}(e, this, n) | |
} | |
}, u && function(e, t) { | |
if (t) | |
if (t.length) | |
for (var n, o = 0; n = t[o]; o += 1) a(e, n); | |
else a(e, t) | |
}(T, window.lazyLoadOptions), T | |
}, "object" === a(t) && void 0 !== e ? e.exports = r() : void 0 === (i = "function" == typeof(o = r) ? o.call(t, n, t, e) : o) || (e.exports = i) | |
}, function(e, t, n) { | |
"use strict"; | |
n.d(t, "b", (function() { | |
return o | |
})), n.d(t, "a", (function() { | |
return i | |
})); | |
const o = 1024, | |
i = 576 | |
}, function(e, t) { | |
! function() { | |
"use strict"; | |
if ("object" == typeof window) | |
if ("IntersectionObserver" in window && "IntersectionObserverEntry" in window && "intersectionRatio" in window.IntersectionObserverEntry.prototype) "isIntersecting" in window.IntersectionObserverEntry.prototype || Object.defineProperty(window.IntersectionObserverEntry.prototype, "isIntersecting", { | |
get: function() { | |
return this.intersectionRatio > 0 | |
} | |
}); | |
else { | |
var e = window.document, | |
t = []; | |
o.prototype.THROTTLE_TIMEOUT = 100, o.prototype.POLL_INTERVAL = null, o.prototype.USE_MUTATION_OBSERVER = !0, o.prototype.observe = function(e) { | |
if (!this._observationTargets.some((function(t) { | |
return t.element == e | |
}))) { | |
if (!e || 1 != e.nodeType) throw new Error("target must be an Element"); | |
this._registerInstance(), this._observationTargets.push({ | |
element: e, | |
entry: null | |
}), this._monitorIntersections(), this._checkForIntersections() | |
} | |
}, o.prototype.unobserve = function(e) { | |
this._observationTargets = this._observationTargets.filter((function(t) { | |
return t.element != e | |
})), this._observationTargets.length || (this._unmonitorIntersections(), this._unregisterInstance()) | |
}, o.prototype.disconnect = function() { | |
this._observationTargets = [], this._unmonitorIntersections(), this._unregisterInstance() | |
}, o.prototype.takeRecords = function() { | |
var e = this._queuedEntries.slice(); | |
return this._queuedEntries = [], e | |
}, o.prototype._initThresholds = function(e) { | |
var t = e || [0]; | |
return Array.isArray(t) || (t = [t]), t.sort().filter((function(e, t, n) { | |
if ("number" != typeof e || isNaN(e) || e < 0 || e > 1) throw new Error("threshold must be a number between 0 and 1 inclusively"); | |
return e !== n[t - 1] | |
})) | |
}, o.prototype._parseRootMargin = function(e) { | |
var t = (e || "0px").split(/\s+/).map((function(e) { | |
var t = /^(-?\d*\.?\d+)(px|%)$/.exec(e); | |
if (!t) throw new Error("rootMargin must be specified in pixels or percent"); | |
return { | |
value: parseFloat(t[1]), | |
unit: t[2] | |
} | |
})); | |
return t[1] = t[1] || t[0], t[2] = t[2] || t[0], t[3] = t[3] || t[1], t | |
}, o.prototype._monitorIntersections = function() { | |
this._monitoringIntersections || (this._monitoringIntersections = !0, this.POLL_INTERVAL ? this._monitoringInterval = setInterval(this._checkForIntersections, this.POLL_INTERVAL) : (i(window, "resize", this._checkForIntersections, !0), i(e, "scroll", this._checkForIntersections, !0), this.USE_MUTATION_OBSERVER && "MutationObserver" in window && (this._domObserver = new MutationObserver(this._checkForIntersections), this._domObserver.observe(e, { | |
attributes: !0, | |
childList: !0, | |
characterData: !0, | |
subtree: !0 | |
})))) | |
}, o.prototype._unmonitorIntersections = function() { | |
this._monitoringIntersections && (this._monitoringIntersections = !1, clearInterval(this._monitoringInterval), this._monitoringInterval = null, r(window, "resize", this._checkForIntersections, !0), r(e, "scroll", this._checkForIntersections, !0), this._domObserver && (this._domObserver.disconnect(), this._domObserver = null)) | |
}, o.prototype._checkForIntersections = function() { | |
var e = this._rootIsInDom(), | |
t = e ? this._getRootRect() : { | |
top: 0, | |
bottom: 0, | |
left: 0, | |
right: 0, | |
width: 0, | |
height: 0 | |
}; | |
this._observationTargets.forEach((function(o) { | |
var i = o.element, | |
r = s(i), | |
a = this._rootContainsTarget(i), | |
c = o.entry, | |
u = e && a && this._computeTargetAndRootIntersection(i, t), | |
l = o.entry = new n({ | |
time: window.performance && performance.now && performance.now(), | |
target: i, | |
boundingClientRect: r, | |
rootBounds: t, | |
intersectionRect: u | |
}); | |
c ? e && a ? this._hasCrossedThreshold(c, l) && this._queuedEntries.push(l) : c && c.isIntersecting && this._queuedEntries.push(l) : this._queuedEntries.push(l) | |
}), this), this._queuedEntries.length && this._callback(this.takeRecords(), this) | |
}, o.prototype._computeTargetAndRootIntersection = function(t, n) { | |
if ("none" != window.getComputedStyle(t).display) { | |
for (var o, i, r, a, u, l, d, f, p = s(t), m = c(t), h = !1; !h;) { | |
var g = null, | |
y = 1 == m.nodeType ? window.getComputedStyle(m) : {}; | |
if ("none" == y.display) return; | |
if (m == this.root || m == e ? (h = !0, g = n) : m != e.body && m != e.documentElement && "visible" != y.overflow && (g = s(m)), g && (o = g, i = p, r = void 0, a = void 0, u = void 0, l = void 0, d = void 0, f = void 0, r = Math.max(o.top, i.top), a = Math.min(o.bottom, i.bottom), u = Math.max(o.left, i.left), l = Math.min(o.right, i.right), f = a - r, !(p = (d = l - u) >= 0 && f >= 0 && { | |
top: r, | |
bottom: a, | |
left: u, | |
right: l, | |
width: d, | |
height: f | |
}))) break; | |
m = c(m) | |
} | |
return p | |
} | |
}, o.prototype._getRootRect = function() { | |
var t; | |
if (this.root) t = s(this.root); | |
else { | |
var n = e.documentElement, | |
o = e.body; | |
t = { | |
top: 0, | |
left: 0, | |
right: n.clientWidth || o.clientWidth, | |
width: n.clientWidth || o.clientWidth, | |
bottom: n.clientHeight || o.clientHeight, | |
height: n.clientHeight || o.clientHeight | |
} | |
} | |
return this._expandRectByRootMargin(t) | |
}, o.prototype._expandRectByRootMargin = function(e) { | |
var t = this._rootMarginValues.map((function(t, n) { | |
return "px" == t.unit ? t.value : t.value * (n % 2 ? e.width : e.height) / 100 | |
})), | |
n = { | |
top: e.top - t[0], | |
right: e.right + t[1], | |
bottom: e.bottom + t[2], | |
left: e.left - t[3] | |
}; | |
return n.width = n.right - n.left, n.height = n.bottom - n.top, n | |
}, o.prototype._hasCrossedThreshold = function(e, t) { | |
var n = e && e.isIntersecting ? e.intersectionRatio || 0 : -1, | |
o = t.isIntersecting ? t.intersectionRatio || 0 : -1; | |
if (n !== o) | |
for (var i = 0; i < this.thresholds.length; i++) { | |
var r = this.thresholds[i]; | |
if (r == n || r == o || r < n != r < o) return !0 | |
} | |
}, o.prototype._rootIsInDom = function() { | |
return !this.root || a(e, this.root) | |
}, o.prototype._rootContainsTarget = function(t) { | |
return a(this.root || e, t) | |
}, o.prototype._registerInstance = function() { | |
t.indexOf(this) < 0 && t.push(this) | |
}, o.prototype._unregisterInstance = function() { | |
var e = t.indexOf(this); - 1 != e && t.splice(e, 1) | |
}, window.IntersectionObserver = o, window.IntersectionObserverEntry = n | |
} | |
function n(e) { | |
this.time = e.time, this.target = e.target, this.rootBounds = e.rootBounds, this.boundingClientRect = e.boundingClientRect, this.intersectionRect = e.intersectionRect || { | |
top: 0, | |
bottom: 0, | |
left: 0, | |
right: 0, | |
width: 0, | |
height: 0 | |
}, this.isIntersecting = !!e.intersectionRect; | |
var t = this.boundingClientRect, | |
n = t.width * t.height, | |
o = this.intersectionRect, | |
i = o.width * o.height; | |
this.intersectionRatio = n ? Number((i / n).toFixed(4)) : this.isIntersecting ? 1 : 0 | |
} | |
function o(e, t) { | |
var n, o, i, r = t || {}; | |
if ("function" != typeof e) throw new Error("callback must be a function"); | |
if (r.root && 1 != r.root.nodeType) throw new Error("root must be an Element"); | |
this._checkForIntersections = (n = this._checkForIntersections.bind(this), o = this.THROTTLE_TIMEOUT, i = null, function() { | |
i || (i = setTimeout((function() { | |
n(), i = null | |
}), o)) | |
}), this._callback = e, this._observationTargets = [], this._queuedEntries = [], this._rootMarginValues = this._parseRootMargin(r.rootMargin), this.thresholds = this._initThresholds(r.threshold), this.root = r.root || null, this.rootMargin = this._rootMarginValues.map((function(e) { | |
return e.value + e.unit | |
})).join(" ") | |
} | |
function i(e, t, n, o) { | |
"function" == typeof e.addEventListener ? e.addEventListener(t, n, o || !1) : "function" == typeof e.attachEvent && e.attachEvent("on" + t, n) | |
} | |
function r(e, t, n, o) { | |
"function" == typeof e.removeEventListener ? e.removeEventListener(t, n, o || !1) : "function" == typeof e.detatchEvent && e.detatchEvent("on" + t, n) | |
} | |
function s(e) { | |
var t; | |
try { | |
t = e.getBoundingClientRect() | |
} catch (e) {} | |
return t ? (t.width && t.height || (t = { | |
top: t.top, | |
right: t.right, | |
bottom: t.bottom, | |
left: t.left, | |
width: t.right - t.left, | |
height: t.bottom - t.top | |
}), t) : { | |
top: 0, | |
bottom: 0, | |
left: 0, | |
right: 0, | |
width: 0, | |
height: 0 | |
} | |
} | |
function a(e, t) { | |
for (var n = t; n;) { | |
if (n == e) return !0; | |
n = c(n) | |
} | |
return !1 | |
} | |
function c(e) { | |
var t = e.parentNode; | |
return t && 11 == t.nodeType && t.host ? t.host : t && t.assignedSlot ? t.assignedSlot.parentNode : t | |
} | |
}() | |
}, , , , , , , function(e, t, n) { | |
e.exports = n(119) | |
}, , function(e, t, n) { | |
"use strict"; | |
Object.defineProperty(t, "__esModule", { | |
value: !0 | |
}); | |
var o, i = n(125), | |
r = (o = i) && o.__esModule ? o : { | |
default: o | |
}; | |
t.default = r.default, e.exports = t.default | |
}, function(e, t, n) { | |
"use strict"; | |
function o() { | |
let e = document.querySelector(".article__content > p:nth-last-of-type(1)"); | |
return e && e.classList.contains("author__detail") && (e = document.querySelector(".article__content > p:nth-last-of-type(2)")), e | |
} | |
function i(e) { | |
const t = function() { | |
let e = document.querySelector(".article__content > p:first-of-type"); | |
return e && e.classList.contains("article__status") && (e = document.querySelector(".article__content > p:nth-of-type(2)")), e | |
}(), | |
n = o(); | |
let i = ""; | |
return t && n && (i = e.offsetTop <= t.offsetTop ? "debut" : e.offsetTop >= n.offsetTop ? "fin" : "milieu"), i | |
} | |
n.d(t, "b", (function() { | |
return o | |
})), n.d(t, "a", (function() { | |
return i | |
})) | |
}, , , , function(e, t, n) { | |
"use strict"; | |
(function(e) { | |
n.d(t, "b", (function() { | |
return u | |
})), n.d(t, "a", (function() { | |
return d | |
})); | |
var o = n(78), | |
i = n(36), | |
r = n(24); | |
function s(e) { | |
return e.toLowerCase().replace(/[à âä]/g, "a").replace(/[æ]/g, "ae").replace(/[ç]/g, "c").replace(/[éèêë]/g, "e").replace(/[îï]/g, "i").replace(/[ô]/g, "o").replace(/[œ]/g, "oe").replace(/[ùûü]/g, "u").replace(/-/g, " ").replace(/'/g, " ") | |
} | |
function a(e, t) { | |
const n = s(e).indexOf(s(t)); | |
let o = e; | |
return n >= 0 && (o = "".concat(e.substring(0, n), '<span class="election__highlight">').concat(e.substring(n, n + t.length), "</span>").concat(e.substring(n + t.length))), o | |
} | |
const c = !!Object(r.a)(window.lmd, "isAec") && window.lmd.isAec; | |
function u() { | |
const e = document.querySelector(".election__search"); | |
e && e.classList.contains("election__search--depth") && e.classList.remove("election__search--depth") | |
} | |
function l() { | |
const t = document.getElementById("js-city-input"), | |
n = document.getElementById("js-city-result"); | |
"" === t.value && function() { | |
const e = document.getElementById("js-city-input"), | |
t = document.getElementById("js-city-result"); | |
e.classList.contains("election__city-input--active") && e.classList.remove("election__city-input--active"), t.classList.contains("election__city-result--show") && t.classList.remove("election__city-result--show"), t.innerHTML = "" | |
}(), | |
function(t) { | |
const n = document.getElementById("js-city-result"); | |
let o, i = !1; | |
e("/ajax/town/search/?criteria=".concat(encodeURIComponent(t)).concat("&v=3"), { | |
method: "GET", | |
mode: "cors" | |
}).then(e => { | |
if (!e.ok) throw e; | |
return e.json() | |
}).then(e => { | |
const r = Object.keys(e).filter(e => "debug" !== e), | |
s = Object.values(e), | |
u = "https://".concat(window.lmd.hosts.lemonde, "/resultats-elections"); | |
if (n.innerHTML = '<p class="election__city-result-none">Aucun résultat de recherche</p>', r.length > 0) { | |
for (let e = 0; e < r.length; e += 1) { | |
let n = s[e].name, | |
r = s[e].zipcode; | |
void 0 !== s[e].name && (n = a(s[e].name, t)), void 0 !== s[e].zipcode && (r = a(s[e].zipcode, t)); | |
let l = "", | |
d = ""; | |
l = "region" === s[e].type ? "".concat(s[e].slug) : "departement" === s[e].type ? "".concat(s[e].regionSlug, "/").concat(s[e].slug) : "".concat(s[e].slug.replace(/\s/g, "-"), "-").concat(s[e].insee), d = '<a href="'.concat(u, "/").concat(l, "/").concat(c ? "?embed" : "", '" class="election__city-result-link">').concat(n, " (").concat(r, ")</a>"), "region" !== s[e].type && "" !== r || (d = '<a href="'.concat(u, "/").concat(l, "/").concat(c ? "?embed" : "", '" class="election__city-result-link">').concat(n, "</a>")), i ? o += d : (i = !0, o = d) | |
} | |
n.innerHTML = o | |
} | |
}).catch(e => { | |
console.error("erreur ".concat(e.message)) | |
}) | |
}(s(t.value)), n.classList.add("election__city-result--show"), t.classList.add("election__city-input--active") | |
} | |
function d() { | |
const e = document.getElementById("js-city-input"), | |
t = document.getElementById("js-city-result"), | |
n = document.querySelector(".election__search"); | |
Object(i.a)(".election__city-input", () => { | |
e.classList.contains("election__city-input--active") && e.classList.remove("election__city-input--active") | |
}), Object(i.a)(".election__city-result", () => { | |
t.classList.contains("election__city-result--show") && t.classList.remove("election__city-result--show") | |
}), e && (e.addEventListener("keyup", Object(o.a)(l, 500)), e.addEventListener("click", e => { | |
e.preventDefault(), n && n.classList.add("election__search--depth") | |
})) | |
} | |
}).call(this, n(40)) | |
}, function(e, t, n) { | |
"use strict"; | |
n.r(t), n.d(t, "lazyloadSnippet", (function() { | |
return l | |
})); | |
n(37), n(129), n(99); | |
var o = n(97), | |
i = n.n(o), | |
r = n(106), | |
s = n(66), | |
a = n(91); | |
const c = { | |
init: () => { | |
Object(s.a)("/dist/assets/js/standalone/respimage/respimage.min.js", !0, !1, () => { | |
c.update() | |
}) | |
}, | |
update: () => { | |
const e = document.querySelectorAll("[data-src],[data-srcset]"); | |
let t, n; | |
for (t = 0; t < e.length; t += 1) n = e[t], n.hasAttribute("data-src") && n.setAttribute("src", n.getAttribute("data-src")), n.hasAttribute("data-srcset") && n.setAttribute("srcset", n.getAttribute("data-srcset")) | |
} | |
}, | |
u = window.navigator.userAgent; | |
function l(e, t) { | |
const [n] = e; | |
if (n.isIntersecting) { | |
const e = n.target.getAttribute("data-src"); | |
e && n.target.setAttribute("src", e), Object(r.iframeResizer)({ | |
heightCalculationMethod: "documentElementOffset", | |
log: !1, | |
resizeFrom: "child", | |
scrolling: !1 | |
}, n.target), t.disconnect() | |
} | |
return !0 | |
} | |
u.indexOf("MSIE ") > -1 || u.indexOf("Trident/") > -1 ? (window.lmd.lazyload = c, window.lmd.lazyload.init()) : window.lmd.lazyload = new i.a({ | |
elements_selector: ["img", ".lazy"], | |
class_loading: "lzld--loading" | |
}); | |
const d = document.querySelectorAll(".js-lazyload-snippet"), | |
f = { | |
rootMargin: "150px", | |
threshold: .1 | |
}; | |
d.forEach(e => Object(a.a)(e, l, f)) | |
}, , , function(e, t, n) { | |
"use strict"; | |
n.d(t, "b", (function() { | |
return r | |
})), n.d(t, "c", (function() { | |
return s | |
})), n.d(t, "a", (function() { | |
return a | |
})); | |
var o = n(73), | |
i = n(98); | |
function r() { | |
const e = document.getElementById("js-relance-banner"); | |
Object(o.b)().width >= i.b && e && (e.classList.add("message--shown"), e.dispatchEvent(new Event("shown"))) | |
} | |
function s() { | |
const e = document.getElementById("js-relance-banner"); | |
Object(o.b)().width >= i.b && e && e.classList.contains("message--shown") && e.classList.remove("message--shown") | |
} | |
function a() { | |
const e = document.getElementById("js-relance-close"), | |
t = document.getElementById("js-relance-banner"); | |
e && e.addEventListener("click", e => { | |
e.preventDefault(), s(), t.dispatchEvent(new Event("close")) | |
}) | |
} | |
}, , function(e, t, n) { | |
var o = n(120); | |
t.iframeResize = o, t.iframeResizer = o, t.iframeResizerContentWindow = n(121) | |
}, function(e, t, n) { | |
var o, i, r; | |
! function(n) { | |
if ("undefined" != typeof window) { | |
var s, a = 0, | |
c = !1, | |
u = !1, | |
l = "message".length, | |
d = "[iFrameSizer]", | |
f = d.length, | |
p = null, | |
m = window.requestAnimationFrame, | |
h = { | |
max: 1, | |
scroll: 1, | |
bodyScroll: 1, | |
documentElementScroll: 1 | |
}, | |
g = {}, | |
y = null, | |
v = { | |
autoResize: !0, | |
bodyBackground: null, | |
bodyMargin: null, | |
bodyMarginV1: 8, | |
bodyPadding: null, | |
checkOrigin: !0, | |
inPageLinks: !1, | |
enablePublicMethods: !0, | |
heightCalculationMethod: "bodyOffset", | |
id: "iFrameResizer", | |
interval: 32, | |
log: !1, | |
maxHeight: 1 / 0, | |
maxWidth: 1 / 0, | |
minHeight: 0, | |
minWidth: 0, | |
mouseEvents: !0, | |
resizeFrom: "parent", | |
scrolling: !1, | |
sizeHeight: !0, | |
sizeWidth: !1, | |
warningTimeout: 5e3, | |
tolerance: 0, | |
widthCalculationMethod: "scroll", | |
onClose: function() { | |
return !0 | |
}, | |
onClosed: function() {}, | |
onInit: function() {}, | |
onMessage: function() { | |
I("onMessage function not defined") | |
}, | |
onMouseEnter: function() {}, | |
onMouseLeave: function() {}, | |
onResized: function() {}, | |
onScroll: function() { | |
return !0 | |
} | |
}, | |
b = {}; | |
window.jQuery && ((s = window.jQuery).fn ? s.fn.iFrameResize || (s.fn.iFrameResize = function(e) { | |
return this.filter("iframe").each((function(t, n) { | |
F(n, e) | |
})).end() | |
}) : j("", "Unable to bind to jQuery, it is not fully loaded.")), i = [], void 0 === (r = "function" == typeof(o = G) ? o.apply(t, i) : o) || (e.exports = r), window.iFrameResize = window.iFrameResize || G() | |
} | |
function w() { | |
return window.MutationObserver || window.WebKitMutationObserver || window.MozMutationObserver | |
} | |
function _(e, t, n) { | |
e.addEventListener(t, n, !1) | |
} | |
function E(e, t, n) { | |
e.removeEventListener(t, n, !1) | |
} | |
function L(e) { | |
return d + "[" + function(e) { | |
var t = "Host page: " + e; | |
return window.top !== window.self && (t = window.parentIFrame && window.parentIFrame.getId ? window.parentIFrame.getId() + ": " + e : "Nested host page: " + e), t | |
}(e) + "]" | |
} | |
function O(e) { | |
return g[e] ? g[e].log : c | |
} | |
function T(e, t) { | |
S("log", e, t, O(e)) | |
} | |
function j(e, t) { | |
S("info", e, t, O(e)) | |
} | |
function I(e, t) { | |
S("warn", e, t, !0) | |
} | |
function S(e, t, n, o) { | |
!0 === o && "object" == typeof window.console && console[e](L(t), n) | |
} | |
function x(e) { | |
function t() { | |
i("Height"), i("Width"), q((function() { | |
z(k), B(F), h("onResized", k) | |
}), k, "init") | |
} | |
function n(e) { | |
return "border-box" !== e.boxSizing ? 0 : (e.paddingTop ? parseInt(e.paddingTop, 10) : 0) + (e.paddingBottom ? parseInt(e.paddingBottom, 10) : 0) | |
} | |
function o(e) { | |
return "border-box" !== e.boxSizing ? 0 : (e.borderTopWidth ? parseInt(e.borderTopWidth, 10) : 0) + (e.borderBottomWidth ? parseInt(e.borderBottomWidth, 10) : 0) | |
} | |
function i(e) { | |
var t = Number(g[F]["max" + e]), | |
n = Number(g[F]["min" + e]), | |
o = e.toLowerCase(), | |
i = Number(k[o]); | |
T(F, "Checking " + o + " is in range " + n + "-" + t), i < n && (i = n, T(F, "Set " + o + " to min value")), i > t && (i = t, T(F, "Set " + o + " to max value")), k[o] = "" + i | |
} | |
function r(e) { | |
return x.substr(x.indexOf(":") + l + e) | |
} | |
function s(e, t) { | |
var n, o, i; | |
n = function() { | |
var n, o; | |
P("Send Page Info", "pageInfo:" + (n = document.body.getBoundingClientRect(), o = k.iframe.getBoundingClientRect(), JSON.stringify({ | |
iframeHeight: o.height, | |
iframeWidth: o.width, | |
clientHeight: Math.max(document.documentElement.clientHeight, window.innerHeight || 0), | |
clientWidth: Math.max(document.documentElement.clientWidth, window.innerWidth || 0), | |
offsetTop: parseInt(o.top - n.top, 10), | |
offsetLeft: parseInt(o.left - n.left, 10), | |
scrollTop: window.pageYOffset, | |
scrollLeft: window.pageXOffset, | |
documentHeight: document.documentElement.clientHeight, | |
documentWidth: document.documentElement.clientWidth, | |
windowHeight: window.innerHeight, | |
windowWidth: window.innerWidth | |
})), e, t) | |
}, o = 32, b[i = t] || (b[i] = setTimeout((function() { | |
b[i] = null, n() | |
}), o)) | |
} | |
function a(e) { | |
var t = e.getBoundingClientRect(); | |
return C(F), { | |
x: Math.floor(Number(t.left) + Number(p.x)), | |
y: Math.floor(Number(t.top) + Number(p.y)) | |
} | |
} | |
function c(e) { | |
var t = e ? a(k.iframe) : { | |
x: 0, | |
y: 0 | |
}, | |
n = { | |
x: Number(k.width) + t.x, | |
y: Number(k.height) + t.y | |
}; | |
T(F, "Reposition requested from iFrame (offset x:" + t.x + " y:" + t.y + ")"), window.top !== window.self ? window.parentIFrame ? window.parentIFrame["scrollTo" + (e ? "Offset" : "")](n.x, n.y) : I(F, "Unable to scroll to requested position, window.parentIFrame not found") : (p = n, u(), T(F, "--")) | |
} | |
function u() { | |
!1 !== h("onScroll", p) ? B(F) : N() | |
} | |
function m(e) { | |
var t = {}; | |
if (0 === Number(k.width) && 0 === Number(k.height)) { | |
var n = r(9).split(":"); | |
t = { | |
x: n[1], | |
y: n[0] | |
} | |
} else t = { | |
x: k.width, | |
y: k.height | |
}; | |
h(e, { | |
iframe: k.iframe, | |
screenX: Number(t.x), | |
screenY: Number(t.y), | |
type: k.type | |
}) | |
} | |
function h(e, t) { | |
return A(F, e, t) | |
} | |
var y, v, w, L, O, S, x = e.data, | |
k = {}, | |
F = null; | |
"[iFrameResizerChild]Ready" === x ? function() { | |
for (var e in g) P("iFrame requested init", H(e), g[e].iframe, e) | |
}() : d === ("" + x).substr(0, f) && x.substr(f).split(":")[0] in g ? (w = x.substr(f).split(":"), L = w[1] ? parseInt(w[1], 10) : 0, O = g[w[0]] && g[w[0]].iframe, S = getComputedStyle(O), k = { | |
iframe: O, | |
id: w[0], | |
height: L + n(S) + o(S), | |
width: w[2], | |
type: w[3] | |
}, F = k.id, g[F] && (g[F].loaded = !0), (v = k.type in { | |
true: 1, | |
false: 1, | |
undefined: 1 | |
}) && T(F, "Ignoring init message from meta parent page"), !v && function(e) { | |
var t = !0; | |
return g[e] || (t = !1, I(k.type + " No settings for " + e + ". Message was: " + x)), t | |
}(F) && (T(F, "Received: " + x), y = !0, null === k.iframe && (I(F, "IFrame (" + k.id + ") not found"), y = !1), y && function() { | |
var t, n = e.origin, | |
o = g[F] && g[F].checkOrigin; | |
if (o && "" + n != "null" && !(o.constructor === Array ? function() { | |
var e = 0, | |
t = !1; | |
for (T(F, "Checking connection is from allowed list of origins: " + o); e < o.length; e++) | |
if (o[e] === n) { | |
t = !0; | |
break | |
} return t | |
}() : (t = g[F] && g[F].remoteHost, T(F, "Checking connection is from: " + t), n === t))) throw new Error("Unexpected message received from: " + n + " for " + k.iframe.id + ". Message was: " + e.data + ". This error can be disabled by setting the checkOrigin: false option or by providing of array of trusted domains."); | |
return !0 | |
}() && function() { | |
switch (g[F] && g[F].firstRun && g[F] && (g[F].firstRun = !1), k.type) { | |
case "close": | |
M(k.iframe); | |
break; | |
case "message": | |
d = r(6), T(F, "onMessage passed: {iframe: " + k.iframe.id + ", message: " + d + "}"), h("onMessage", { | |
iframe: k.iframe, | |
message: JSON.parse(d) | |
}), T(F, "--"); | |
break; | |
case "mouseenter": | |
m("onMouseEnter"); | |
break; | |
case "mouseleave": | |
m("onMouseLeave"); | |
break; | |
case "autoResize": | |
g[F].autoResize = JSON.parse(r(9)); | |
break; | |
case "scrollTo": | |
c(!1); | |
break; | |
case "scrollToOffset": | |
c(!0); | |
break; | |
case "pageInfo": | |
s(g[F] && g[F].iframe, F), | |
function() { | |
function e(e, o) { | |
function i() { | |
g[n] ? s(g[n].iframe, n) : t() | |
} ["scroll", "resize"].forEach((function(t) { | |
T(n, e + t + " listener for sendPageInfo"), o(window, t, i) | |
})) | |
} | |
function t() { | |
e("Remove ", E) | |
} | |
var n = F; | |
e("Add ", _), g[n] && (g[n].stopPageInfo = t) | |
}(); | |
break; | |
case "pageInfoStop": | |
g[F] && g[F].stopPageInfo && (g[F].stopPageInfo(), delete g[F].stopPageInfo); | |
break; | |
case "inPageLink": | |
e = r(9), o = e.split("#")[1] || "", i = decodeURIComponent(o), (l = document.getElementById(i) || document.getElementsByName(i)[0]) ? (n = a(l), T(F, "Moving to in page link (#" + o + ") at x: " + n.x + " y: " + n.y), p = { | |
x: n.x, | |
y: n.y | |
}, u(), T(F, "--")) : window.top !== window.self ? window.parentIFrame ? window.parentIFrame.moveToAnchor(o) : T(F, "In page link #" + o + " not found and window.parentIFrame not found") : T(F, "In page link #" + o + " not found"); | |
break; | |
case "reset": | |
R(k); | |
break; | |
case "init": | |
t(), h("onInit", k.iframe); | |
break; | |
default: | |
0 === Number(k.width) && 0 === Number(k.height) ? I("Unsupported message received (" + k.type + "), this is likely due to the iframe containing a later version of iframe-resizer than the parent page") : t() | |
} | |
var e, n, o, i, l, d | |
}())) : j(F, "Ignored: " + x) | |
} | |
function A(e, t, n) { | |
var o = null, | |
i = null; | |
if (g[e]) { | |
if ("function" != typeof(o = g[e][t])) throw new TypeError(t + " on iFrame[" + e + "] is not a function"); | |
i = o(n) | |
} | |
return i | |
} | |
function k(e) { | |
var t = e.id; | |
delete g[t] | |
} | |
function M(e) { | |
var t = e.id; | |
if (!1 !== A(t, "onClose", t)) { | |
T(t, "Removing iFrame: " + t); | |
try { | |
e.parentNode && e.parentNode.removeChild(e) | |
} catch (e) { | |
I(e) | |
} | |
A(t, "onClosed", t), T(t, "--"), k(e) | |
} else T(t, "Close iframe cancelled by onClose event") | |
} | |
function C(e) { | |
null === p && T(e, "Get page position: " + (p = { | |
x: void 0 !== window.pageXOffset ? window.pageXOffset : document.documentElement.scrollLeft, | |
y: void 0 !== window.pageYOffset ? window.pageYOffset : document.documentElement.scrollTop | |
}).x + "," + p.y) | |
} | |
function B(e) { | |
null !== p && (window.scrollTo(p.x, p.y), T(e, "Set page position: " + p.x + "," + p.y), N()) | |
} | |
function N() { | |
p = null | |
} | |
function R(e) { | |
T(e.id, "Size reset requested by " + ("init" === e.type ? "host page" : "iFrame")), C(e.id), q((function() { | |
z(e), P("reset", "reset", e.iframe, e.id) | |
}), e, "reset") | |
} | |
function z(e) { | |
function t(t) { | |
u || "0" !== e[t] || (u = !0, T(o, "Hidden iFrame detected, creating visibility listener"), function() { | |
function e() { | |
Object.keys(g).forEach((function(e) { | |
! function(e) { | |
function t(t) { | |
return "0px" === (g[e] && g[e].iframe.style[t]) | |
} | |
g[e] && null !== g[e].iframe.offsetParent && (t("height") || t("width")) && P("Visibility change", "resize", g[e].iframe, e) | |
}(e) | |
})) | |
} | |
function t(t) { | |
T("window", "Mutation observed: " + t[0].target + " " + t[0].type), D(e, 16) | |
} | |
var n = w(); | |
n && (o = document.querySelector("body"), new n(t).observe(o, { | |
attributes: !0, | |
attributeOldValue: !1, | |
characterData: !0, | |
characterDataOldValue: !1, | |
childList: !0, | |
subtree: !0 | |
})); | |
var o | |
}()) | |
} | |
function n(n) { | |
! function(t) { | |
e.id ? (e.iframe.style[t] = e[t] + "px", T(e.id, "IFrame (" + o + ") " + t + " set to " + e[t] + "px")) : T("undefined", "messageData id not set") | |
}(n), t(n) | |
} | |
var o = e.iframe.id; | |
g[o] && (g[o].sizeHeight && n("height"), g[o].sizeWidth && n("width")) | |
} | |
function q(e, t, n) { | |
n !== t.type && m && !window.jasmine ? (T(t.id, "Requesting animation frame"), m(e)) : e() | |
} | |
function P(e, t, n, o, i) { | |
var r, s = !1; | |
o = o || n.id, g[o] && (n && "contentWindow" in n && null !== n.contentWindow ? (r = g[o] && g[o].targetOrigin, T(o, "[" + e + "] Sending msg to iframe[" + o + "] (" + t + ") targetOrigin: " + r), n.contentWindow.postMessage(d + t, r)) : I(o, "[" + e + "] IFrame(" + o + ") not found"), i && g[o] && g[o].warningTimeout && (g[o].msgTimeout = setTimeout((function() { | |
!g[o] || g[o].loaded || s || (s = !0, I(o, "IFrame has not responded within " + g[o].warningTimeout / 1e3 + " seconds. Check iFrameResizer.contentWindow.js has been loaded in iFrame. This message can be ignored if everything is working, or you can set the warningTimeout option to a higher value or zero to suppress this warning.")) | |
}), g[o].warningTimeout))) | |
} | |
function H(e) { | |
return e + ":" + g[e].bodyMarginV1 + ":" + g[e].sizeWidth + ":" + g[e].log + ":" + g[e].interval + ":" + g[e].enablePublicMethods + ":" + g[e].autoResize + ":" + g[e].bodyMargin + ":" + g[e].heightCalculationMethod + ":" + g[e].bodyBackground + ":" + g[e].bodyPadding + ":" + g[e].tolerance + ":" + g[e].inPageLinks + ":" + g[e].resizeFrom + ":" + g[e].widthCalculationMethod + ":" + g[e].mouseEvents | |
} | |
function F(e, t) { | |
function n(e) { | |
var t = e.split("Callback"); | |
if (2 === t.length) { | |
var n = "on" + t[0].charAt(0).toUpperCase() + t[0].slice(1); | |
this[n] = this[e], delete this[e], I(o, "Deprecated: '" + e + "' has been renamed '" + n + "'. The old method will be removed in the next major version.") | |
} | |
} | |
var o = function(n) { | |
var o; | |
return "" === n && (e.id = (o = t && t.id || v.id + a++, null !== document.getElementById(o) && (o += a++), n = o), c = (t || {}).log, T(n, "Added missing iframe ID: " + n + " (" + e.src + ")")), n | |
}(e.id); | |
o in g && "iFrameResizer" in e ? I(o, "Ignored iFrame, already setup.") : (! function(t) { | |
var i; | |
t = t || {}, g[o] = { | |
firstRun: !0, | |
iframe: e, | |
remoteHost: e.src && e.src.split("/").slice(0, 3).join("/") | |
}, | |
function(e) { | |
if ("object" != typeof e) throw new TypeError("Options is not an object") | |
}(t), Object.keys(t).forEach(n, t), | |
function(e) { | |
for (var t in v) Object.prototype.hasOwnProperty.call(v, t) && (g[o][t] = Object.prototype.hasOwnProperty.call(e, t) ? e[t] : v[t]) | |
}(t), g[o] && (g[o].targetOrigin = !0 === g[o].checkOrigin ? "" === (i = g[o].remoteHost) || null !== i.match(/^(about:blank|javascript:|file:\/\/)/) ? "*" : i : "*") | |
}(t), function() { | |
switch (T(o, "IFrame scrolling " + (g[o] && g[o].scrolling ? "enabled" : "disabled") + " for " + o), e.style.overflow = !1 === (g[o] && g[o].scrolling) ? "hidden" : "auto", g[o] && g[o].scrolling) { | |
case "omit": | |
break; | |
case !0: | |
e.scrolling = "yes"; | |
break; | |
case !1: | |
e.scrolling = "no"; | |
break; | |
default: | |
e.scrolling = g[o] ? g[o].scrolling : "no" | |
} | |
}(), function() { | |
function t(t) { | |
var n = g[o][t]; | |
1 / 0 !== n && 0 !== n && (e.style[t] = "number" == typeof n ? n + "px" : n, T(o, "Set " + t + " = " + e.style[t])) | |
} | |
function n(e) { | |
if (g[o]["min" + e] > g[o]["max" + e]) throw new Error("Value for min" + e + " can not be greater than max" + e) | |
} | |
n("Height"), n("Width"), t("maxHeight"), t("minHeight"), t("maxWidth"), t("minWidth") | |
}(), "number" != typeof(g[o] && g[o].bodyMargin) && "0" !== (g[o] && g[o].bodyMargin) || (g[o].bodyMarginV1 = g[o].bodyMargin, g[o].bodyMargin = g[o].bodyMargin + "px"), function(t) { | |
var n = w(); | |
n && function(t) { | |
e.parentNode && new t((function(t) { | |
t.forEach((function(t) { | |
Array.prototype.slice.call(t.removedNodes).forEach((function(t) { | |
t === e && M(e) | |
})) | |
})) | |
})).observe(e.parentNode, { | |
childList: !0 | |
}) | |
}(n), _(e, "load", (function() { | |
var n, i; | |
P("iFrame.onload", t, e, void 0, !0), n = g[o] && g[o].firstRun, i = g[o] && g[o].heightCalculationMethod in h, !n && i && R({ | |
iframe: e, | |
height: 0, | |
width: 0, | |
type: "init" | |
}) | |
})), P("init", t, e, void 0, !0) | |
}(H(o)), g[o] && (g[o].iframe.iFrameResizer = { | |
close: M.bind(null, g[o].iframe), | |
removeListeners: k.bind(null, g[o].iframe), | |
resize: P.bind(null, "Window resize", "resize", g[o].iframe), | |
moveToAnchor: function(e) { | |
P("Move to anchor", "moveToAnchor:" + e, g[o].iframe, o) | |
}, | |
sendMessage: function(e) { | |
P("Send Message", "message:" + (e = JSON.stringify(e)), g[o].iframe, o) | |
} | |
})) | |
} | |
function D(e, t) { | |
null === y && (y = setTimeout((function() { | |
y = null, e() | |
}), t)) | |
} | |
function U() { | |
"hidden" !== document.visibilityState && (T("document", "Trigger event: Visiblity change"), D((function() { | |
W("Tab Visable", "resize") | |
}), 16)) | |
} | |
function W(e, t) { | |
Object.keys(g).forEach((function(n) { | |
(function(e) { | |
return g[e] && "parent" === g[e].resizeFrom && g[e].autoResize && !g[e].firstRun | |
})(n) && P(e, t, g[n].iframe, n) | |
})) | |
} | |
function V() { | |
_(window, "message", x), _(window, "resize", (function() { | |
var e; | |
T("window", "Trigger event: " + (e = "resize")), D((function() { | |
W("Window " + e, "resize") | |
}), 16) | |
})), _(document, "visibilitychange", U), _(document, "-webkit-visibilitychange", U) | |
} | |
function G() { | |
function e(e, n) { | |
n && (! function() { | |
if (!n.tagName) throw new TypeError("Object is not a valid DOM element"); | |
if ("IFRAME" !== n.tagName.toUpperCase()) throw new TypeError("Expected <IFRAME> tag, found <" + n.tagName + ">") | |
}(), F(n, e), t.push(n)) | |
} | |
var t; | |
return function() { | |
var e, t = ["moz", "webkit", "o", "ms"]; | |
for (e = 0; e < t.length && !m; e += 1) m = window[t[e] + "RequestAnimationFrame"]; | |
m ? m = m.bind(window) : T("setup", "RequestAnimationFrame not supported") | |
}(), V(), | |
function(n, o) { | |
switch (t = [], function(e) { | |
e && e.enablePublicMethods && I("enablePublicMethods option has been removed, public methods are now always available in the iFrame") | |
}(n), typeof o) { | |
case "undefined": | |
case "string": | |
Array.prototype.forEach.call(document.querySelectorAll(o || "iframe"), e.bind(void 0, n)); | |
break; | |
case "object": | |
e(n, o); | |
break; | |
default: | |
throw new TypeError("Unexpected data type (" + typeof o + ")") | |
} | |
return t | |
} | |
} | |
}() | |
}, function(e, t, n) { | |
! function(t) { | |
if ("undefined" != typeof window) { | |
var n = !0, | |
o = "", | |
i = 0, | |
r = "", | |
s = null, | |
a = "", | |
c = !1, | |
u = { | |
resize: 1, | |
click: 1 | |
}, | |
l = !0, | |
d = 1, | |
f = "bodyOffset", | |
p = !0, | |
m = "", | |
h = {}, | |
g = 32, | |
y = null, | |
v = !1, | |
b = !1, | |
w = "[iFrameSizer]", | |
_ = w.length, | |
E = "", | |
L = { | |
max: 1, | |
min: 1, | |
bodyScroll: 1, | |
documentElementScroll: 1 | |
}, | |
O = "child", | |
T = window.parent, | |
j = "*", | |
I = 0, | |
S = !1, | |
x = null, | |
A = 16, | |
k = 1, | |
M = "scroll", | |
C = window, | |
B = function() { | |
ne("onMessage function not defined") | |
}, | |
N = function() {}, | |
R = function() {}, | |
z = { | |
height: function() { | |
return ne("Custom height calculation function not defined"), document.documentElement.offsetHeight | |
}, | |
width: function() { | |
return ne("Custom width calculation function not defined"), document.body.scrollWidth | |
} | |
}, | |
q = {}, | |
P = !1; | |
try { | |
var H = Object.create({}, { | |
passive: { | |
get: function() { | |
P = !0 | |
} | |
} | |
}); | |
window.addEventListener("test", K, H), window.removeEventListener("test", K, H) | |
} catch (e) {} | |
var F, D, U, W, V, G, J, X = { | |
bodyOffset: function() { | |
return document.body.offsetHeight + pe("marginTop") + pe("marginBottom") | |
}, | |
offset: function() { | |
return X.bodyOffset() | |
}, | |
bodyScroll: function() { | |
return document.body.scrollHeight | |
}, | |
custom: function() { | |
return z.height() | |
}, | |
documentElementOffset: function() { | |
return document.documentElement.offsetHeight | |
}, | |
documentElementScroll: function() { | |
return document.documentElement.scrollHeight | |
}, | |
max: function() { | |
return Math.max.apply(null, he(X)) | |
}, | |
min: function() { | |
return Math.min.apply(null, he(X)) | |
}, | |
grow: function() { | |
return X.max() | |
}, | |
lowestElement: function() { | |
return Math.max(X.bodyOffset() || X.documentElementOffset(), me("bottom", ye())) | |
}, | |
taggedElement: function() { | |
return ge("bottom", "data-iframe-height") | |
} | |
}, | |
Y = { | |
bodyScroll: function() { | |
return document.body.scrollWidth | |
}, | |
bodyOffset: function() { | |
return document.body.offsetWidth | |
}, | |
custom: function() { | |
return z.width() | |
}, | |
documentElementScroll: function() { | |
return document.documentElement.scrollWidth | |
}, | |
documentElementOffset: function() { | |
return document.documentElement.offsetWidth | |
}, | |
scroll: function() { | |
return Math.max(Y.bodyScroll(), Y.documentElementScroll()) | |
}, | |
max: function() { | |
return Math.max.apply(null, he(Y)) | |
}, | |
min: function() { | |
return Math.min.apply(null, he(Y)) | |
}, | |
rightMostElement: function() { | |
return me("right", ye()) | |
}, | |
taggedElement: function() { | |
return ge("right", "data-iframe-width") | |
} | |
}, | |
$ = (F = ve, V = null, G = 0, J = function() { | |
G = Date.now(), V = null, W = F.apply(D, U), V || (D = U = null) | |
}, function() { | |
var e = Date.now(); | |
G || (G = e); | |
var t = A - (e - G); | |
return D = this, U = arguments, t <= 0 || t > A ? (V && (clearTimeout(V), V = null), G = e, W = F.apply(D, U), V || (D = U = null)) : V || (V = setTimeout(J, t)), W | |
}); | |
Q(window, "message", (function(t) { | |
var n = { | |
init: function() { | |
m = t.data, T = t.source, oe(), l = !1, setTimeout((function() { | |
p = !1 | |
}), 128) | |
}, | |
reset: function() { | |
p ? te("Page reset ignored by init") : (te("Page size reset by host page"), _e("resetPage")) | |
}, | |
resize: function() { | |
be("resizeParent", "Parent window requested size check") | |
}, | |
moveToAnchor: function() { | |
h.findTarget(i()) | |
}, | |
inPageLink: function() { | |
this.moveToAnchor() | |
}, | |
pageInfo: function() { | |
var e = i(); | |
te("PageInfoFromParent called from parent: " + e), R(JSON.parse(e)), te(" --") | |
}, | |
message: function() { | |
var e = i(); | |
te("onMessage called from parent: " + e), B(JSON.parse(e)), te(" --") | |
} | |
}; | |
function o() { | |
return t.data.split("]")[1].split(":")[0] | |
} | |
function i() { | |
return t.data.substr(t.data.indexOf(":") + 1) | |
} | |
function r() { | |
return t.data.split(":")[2] in { | |
true: 1, | |
false: 1 | |
} | |
} | |
function s() { | |
var i = o(); | |
i in n ? n[i]() : !e.exports && "iFrameResize" in window || "jQuery" in window && "iFrameResize" in window.jQuery.prototype || r() || ne("Unexpected message (" + t.data + ")") | |
} | |
w === ("" + t.data).substr(0, _) && (!1 === l ? s() : r() ? n.init() : te('Ignored message of type "' + o() + '". Received before initialization.')) | |
})), Q(window, "readystatechange", Oe), Oe() | |
} | |
function K() {} | |
function Q(e, t, n, o) { | |
e.addEventListener(t, n, !!P && (o || {})) | |
} | |
function Z(e) { | |
return e.charAt(0).toUpperCase() + e.slice(1) | |
} | |
function ee(e) { | |
return w + "[" + E + "] " + e | |
} | |
function te(e) { | |
v && "object" == typeof window.console && console.log(ee(e)) | |
} | |
function ne(e) { | |
"object" == typeof window.console && console.warn(ee(e)) | |
} | |
function oe() { | |
var e; | |
! function() { | |
function e(e) { | |
return "true" === e | |
} | |
var t = m.substr(_).split(":"); | |
E = t[0], i = void 0 !== t[1] ? Number(t[1]) : i, c = void 0 !== t[2] ? e(t[2]) : c, v = void 0 !== t[3] ? e(t[3]) : v, g = void 0 !== t[4] ? Number(t[4]) : g, n = void 0 !== t[6] ? e(t[6]) : n, r = t[7], f = void 0 !== t[8] ? t[8] : f, o = t[9], a = t[10], I = void 0 !== t[11] ? Number(t[11]) : I, h.enable = void 0 !== t[12] && e(t[12]), O = void 0 !== t[13] ? t[13] : O, M = void 0 !== t[14] ? t[14] : M, b = void 0 !== t[15] ? Boolean(t[15]) : b | |
}(), te("Initialising iFrame (" + window.location.href + ")"), | |
function() { | |
function e(e, t) { | |
return "function" == typeof e && (te("Setup custom " + t + "CalcMethod"), z[t] = e, e = "custom"), e | |
} | |
"iFrameResizer" in window && Object === window.iFrameResizer.constructor && (t = window.iFrameResizer, te("Reading data from page: " + JSON.stringify(t)), Object.keys(t).forEach(ie, t), B = "onMessage" in t ? t.onMessage : B, N = "onReady" in t ? t.onReady : N, j = "targetOrigin" in t ? t.targetOrigin : j, f = "heightCalculationMethod" in t ? t.heightCalculationMethod : f, M = "widthCalculationMethod" in t ? t.widthCalculationMethod : M, f = e(f, "height"), M = e(M, "width")); | |
var t; | |
te("TargetOrigin for parent set to: " + j) | |
}(), | |
function() { | |
void 0 === r && (r = i + "px"); | |
re("margin", function(e, t) { | |
-1 !== t.indexOf("-") && (ne("Negative CSS value ignored for " + e), t = ""); | |
return t | |
}("margin", r)) | |
}(), re("background", o), re("padding", a), (e = document.createElement("div")).style.clear = "both", e.style.display = "block", e.style.height = "0", document.body.appendChild(e), ue(), le(), document.documentElement.style.height = "", document.body.style.height = "", te('HTML & body height set to "auto"'), te("Enable public methods"), C.parentIFrame = { | |
autoResize: function(e) { | |
return !0 === e && !1 === n ? (n = !0, de()) : !1 === e && !0 === n && (n = !1, ae("remove"), null !== s && s.disconnect(), clearInterval(y)), Le(0, 0, "autoResize", JSON.stringify(n)), n | |
}, | |
close: function() { | |
Le(0, 0, "close") | |
}, | |
getId: function() { | |
return E | |
}, | |
getPageInfo: function(e) { | |
"function" == typeof e ? (R = e, Le(0, 0, "pageInfo")) : (R = function() {}, Le(0, 0, "pageInfoStop")) | |
}, | |
moveToAnchor: function(e) { | |
h.findTarget(e) | |
}, | |
reset: function() { | |
Ee("parentIFrame.reset") | |
}, | |
scrollTo: function(e, t) { | |
Le(t, e, "scrollTo") | |
}, | |
scrollToOffset: function(e, t) { | |
Le(t, e, "scrollToOffset") | |
}, | |
sendMessage: function(e, t) { | |
Le(0, 0, "message", JSON.stringify(e), t) | |
}, | |
setHeightCalculationMethod: function(e) { | |
f = e, ue() | |
}, | |
setWidthCalculationMethod: function(e) { | |
M = e, le() | |
}, | |
setTargetOrigin: function(e) { | |
te("Set targetOrigin: " + e), j = e | |
}, | |
size: function(e, t) { | |
be("size", "parentIFrame.size(" + (e || "") + (t ? "," + t : "") + ")", e, t) | |
} | |
}, | |
function() { | |
if (!0 !== b) return; | |
function e(e) { | |
Le(0, 0, e.type, e.screenY + ":" + e.screenX) | |
} | |
function t(t, n) { | |
te("Add event listener: " + n), Q(window.document, t, e) | |
} | |
t("mouseenter", "Mouse Enter"), t("mouseleave", "Mouse Leave") | |
}(), de(), h = function() { | |
function e(e) { | |
var t = e.getBoundingClientRect(), | |
n = { | |
x: void 0 !== window.pageXOffset ? window.pageXOffset : document.documentElement.scrollLeft, | |
y: void 0 !== window.pageYOffset ? window.pageYOffset : document.documentElement.scrollTop | |
}; | |
return { | |
x: parseInt(t.left, 10) + parseInt(n.x, 10), | |
y: parseInt(t.top, 10) + parseInt(n.y, 10) | |
} | |
} | |
function t(t) { | |
var n = t.split("#")[1] || t, | |
o = decodeURIComponent(n), | |
i = document.getElementById(o) || document.getElementsByName(o)[0]; | |
void 0 !== i ? function(t) { | |
var o = e(t); | |
te("Moving to in page link (#" + n + ") at x: " + o.x + " y: " + o.y), Le(o.y, o.x, "scrollToOffset") | |
}(i) : (te("In page link (#" + n + ") not found in iFrame, so sending to parent"), Le(0, 0, "inPageLink", "#" + n)) | |
} | |
function n() { | |
var e = window.location.hash, | |
n = window.location.href; | |
"" !== e && "#" !== e && t(n) | |
} | |
h.enable ? Array.prototype.forEach && document.querySelectorAll ? (te("Setting up location.hash handlers"), Array.prototype.forEach.call(document.querySelectorAll('a[href^="#"]'), (function(e) { | |
"#" !== e.getAttribute("href") && Q(e, "click", (function(e) { | |
e.preventDefault(), t(this.getAttribute("href")) | |
})) | |
})), Q(window, "hashchange", n), setTimeout(n, 128)) : ne("In page linking not fully supported in this browser! (See README.md for IE8 workaround)") : te("In page linking not enabled"); | |
return { | |
findTarget: t | |
} | |
}(), be("init", "Init message from host page"), N() | |
} | |
function ie(e) { | |
var t = e.split("Callback"); | |
if (2 === t.length) { | |
var n = "on" + t[0].charAt(0).toUpperCase() + t[0].slice(1); | |
this[n] = this[e], delete this[e], ne("Deprecated: '" + e + "' has been renamed '" + n + "'. The old method will be removed in the next major version.") | |
} | |
} | |
function re(e, t) { | |
void 0 !== t && "" !== t && "null" !== t && (document.body.style[e] = t, te("Body " + e + ' set to "' + t + '"')) | |
} | |
function se(e) { | |
var t = { | |
add: function(t) { | |
function n() { | |
be(e.eventName, e.eventType) | |
} | |
q[t] = n, Q(window, t, n, { | |
passive: !0 | |
}) | |
}, | |
remove: function(e) { | |
var t, n, o, i = q[e]; | |
delete q[e], t = window, n = e, o = i, t.removeEventListener(n, o, !1) | |
} | |
}; | |
e.eventNames && Array.prototype.map ? (e.eventName = e.eventNames[0], e.eventNames.map(t[e.method])) : t[e.method](e.eventName), te(Z(e.method) + " event listener: " + e.eventType) | |
} | |
function ae(e) { | |
se({ | |
method: e, | |
eventType: "Animation Start", | |
eventNames: ["animationstart", "webkitAnimationStart"] | |
}), se({ | |
method: e, | |
eventType: "Animation Iteration", | |
eventNames: ["animationiteration", "webkitAnimationIteration"] | |
}), se({ | |
method: e, | |
eventType: "Animation End", | |
eventNames: ["animationend", "webkitAnimationEnd"] | |
}), se({ | |
method: e, | |
eventType: "Input", | |
eventName: "input" | |
}), se({ | |
method: e, | |
eventType: "Mouse Up", | |
eventName: "mouseup" | |
}), se({ | |
method: e, | |
eventType: "Mouse Down", | |
eventName: "mousedown" | |
}), se({ | |
method: e, | |
eventType: "Orientation Change", | |
eventName: "orientationchange" | |
}), se({ | |
method: e, | |
eventType: "Print", | |
eventName: ["afterprint", "beforeprint"] | |
}), se({ | |
method: e, | |
eventType: "Ready State Change", | |
eventName: "readystatechange" | |
}), se({ | |
method: e, | |
eventType: "Touch Start", | |
eventName: "touchstart" | |
}), se({ | |
method: e, | |
eventType: "Touch End", | |
eventName: "touchend" | |
}), se({ | |
method: e, | |
eventType: "Touch Cancel", | |
eventName: "touchcancel" | |
}), se({ | |
method: e, | |
eventType: "Transition Start", | |
eventNames: ["transitionstart", "webkitTransitionStart", "MSTransitionStart", "oTransitionStart", "otransitionstart"] | |
}), se({ | |
method: e, | |
eventType: "Transition Iteration", | |
eventNames: ["transitioniteration", "webkitTransitionIteration", "MSTransitionIteration", "oTransitionIteration", "otransitioniteration"] | |
}), se({ | |
method: e, | |
eventType: "Transition End", | |
eventNames: ["transitionend", "webkitTransitionEnd", "MSTransitionEnd", "oTransitionEnd", "otransitionend"] | |
}), "child" === O && se({ | |
method: e, | |
eventType: "IFrame Resized", | |
eventName: "resize" | |
}) | |
} | |
function ce(e, t, n, o) { | |
return t !== e && (e in n || (ne(e + " is not a valid option for " + o + "CalculationMethod."), e = t), te(o + ' calculation method set to "' + e + '"')), e | |
} | |
function ue() { | |
f = ce(f, "bodyOffset", X, "height") | |
} | |
function le() { | |
M = ce(M, "scroll", Y, "width") | |
} | |
function de() { | |
var e; | |
!0 === n ? (ae("add"), e = 0 > g, window.MutationObserver || window.WebKitMutationObserver ? e ? fe() : s = function() { | |
function e(e) { | |
function t(e) { | |
!1 === e.complete && (te("Attach listeners to " + e.src), e.addEventListener("load", o, !1), e.addEventListener("error", i, !1), s.push(e)) | |
} | |
"attributes" === e.type && "src" === e.attributeName ? t(e.target) : "childList" === e.type && Array.prototype.forEach.call(e.target.querySelectorAll("img"), t) | |
} | |
function t(e) { | |
te("Remove listeners from " + e.src), e.removeEventListener("load", o, !1), e.removeEventListener("error", i, !1), | |
function(e) { | |
s.splice(s.indexOf(e), 1) | |
}(e) | |
} | |
function n(e, n, o) { | |
t(e.target), be(n, o + ": " + e.target.src) | |
} | |
function o(e) { | |
n(e, "imageLoad", "Image loaded") | |
} | |
function i(e) { | |
n(e, "imageLoadFailed", "Image load failed") | |
} | |
function r(t) { | |
be("mutationObserver", "mutationObserver: " + t[0].target + " " + t[0].type), t.forEach(e) | |
} | |
var s = [], | |
a = window.MutationObserver || window.WebKitMutationObserver, | |
c = function() { | |
var e = document.querySelector("body"); | |
return c = new a(r), te("Create body MutationObserver"), c.observe(e, { | |
attributes: !0, | |
attributeOldValue: !1, | |
characterData: !0, | |
characterDataOldValue: !1, | |
childList: !0, | |
subtree: !0 | |
}), c | |
}(); | |
return { | |
disconnect: function() { | |
"disconnect" in c && (te("Disconnect body MutationObserver"), c.disconnect(), s.forEach(t)) | |
} | |
} | |
}() : (te("MutationObserver not supported in this browser!"), fe())) : te("Auto Resize disabled") | |
} | |
function fe() { | |
0 !== g && (te("setInterval: " + g + "ms"), y = setInterval((function() { | |
be("interval", "setInterval: " + g) | |
}), Math.abs(g))) | |
} | |
function pe(e, t) { | |
var n = 0; | |
return t = t || document.body, n = null !== (n = document.defaultView.getComputedStyle(t, null)) ? n[e] : 0, parseInt(n, 10) | |
} | |
function me(e, t) { | |
for (var n = t.length, o = 0, i = 0, r = Z(e), s = Date.now(), a = 0; a < n; a++)(o = t[a].getBoundingClientRect()[e] + pe("margin" + r, t[a])) > i && (i = o); | |
return s = Date.now() - s, te("Parsed " + n + " HTML elements"), te("Element position calculated in " + s + "ms"), | |
function(e) { | |
e > A / 2 && te("Event throttle increased to " + (A = 2 * e) + "ms") | |
}(s), i | |
} | |
function he(e) { | |
return [e.bodyOffset(), e.bodyScroll(), e.documentElementOffset(), e.documentElementScroll()] | |
} | |
function ge(e, t) { | |
var n = document.querySelectorAll("[" + t + "]"); | |
return 0 === n.length && (ne("No tagged elements (" + t + ") found on page"), document.querySelectorAll("body *")), me(e, n) | |
} | |
function ye() { | |
return document.querySelectorAll("body *") | |
} | |
function ve(e, t, n, o) { | |
var i, r; | |
! function() { | |
function e(e, t) { | |
return !(Math.abs(e - t) <= I) | |
} | |
return i = void 0 !== n ? n : X[f](), r = void 0 !== o ? o : Y[M](), e(d, i) || c && e(k, r) | |
}() && "init" !== e ? !(e in { | |
init: 1, | |
interval: 1, | |
size: 1 | |
}) && (f in L || c && M in L) ? Ee(t) : e in { | |
interval: 1 | |
} || te("No change in size detected") : (we(), Le(d = i, k = r, e)) | |
} | |
function be(e, t, n, o) { | |
S && e in u ? te("Trigger event cancelled: " + e) : (e in { | |
reset: 1, | |
resetPage: 1, | |
init: 1 | |
} || te("Trigger event: " + t), "init" === e ? ve(e, t, n, o) : $(e, t, n, o)) | |
} | |
function we() { | |
S || (S = !0, te("Trigger event lock on")), clearTimeout(x), x = setTimeout((function() { | |
S = !1, te("Trigger event lock off"), te("--") | |
}), 128) | |
} | |
function _e(e) { | |
d = X[f](), k = Y[M](), Le(d, k, e) | |
} | |
function Ee(e) { | |
var t = f; | |
f = "bodyOffset", te("Reset trigger event: " + e), we(), _e("reset"), f = t | |
} | |
function Le(e, t, n, o, i) { | |
var r; | |
void 0 === i ? i = j : te("Message targetOrigin: " + i), te("Sending message to host page (" + (r = E + ":" + e + ":" + t + ":" + n + (void 0 !== o ? ":" + o : "")) + ")"), T.postMessage(w + r, i) | |
} | |
function Oe() { | |
"loading" !== document.readyState && window.parent.postMessage("[iFrameResizerChild]Ready", "*") | |
} | |
}() | |
}, , , , function(e, t, n) { | |
"use strict"; | |
Object.defineProperty(t, "__esModule", { | |
value: !0 | |
}); | |
var o = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function(e) { | |
return typeof e | |
} : function(e) { | |
return e && "function" == typeof Symbol && e.constructor === Symbol && e !== Symbol.prototype ? "symbol" : typeof e | |
}, | |
i = function() { | |
function e(e, t) { | |
for (var n = 0; n < t.length; n++) { | |
var o = t[n]; | |
o.enumerable = o.enumerable || !1, o.configurable = !0, "value" in o && (o.writable = !0), Object.defineProperty(e, o.key, o) | |
} | |
} | |
return function(t, n, o) { | |
return n && e(t.prototype, n), o && e(t, o), t | |
} | |
}(), | |
r = c(n(126)), | |
s = c(n(127)), | |
a = n(128); | |
function c(e) { | |
return e && e.__esModule ? e : { | |
default: e | |
} | |
} | |
var u = function() { | |
function e(t, n) { | |
! function(e, t) { | |
if (!(e instanceof t)) throw new TypeError("Cannot call a class as a function") | |
}(this, e), this.changeListeners = [], this.cookies = function(e) { | |
return "string" == typeof e ? r.default.parse(e) : "object" === (void 0 === e ? "undefined" : o(e)) && null !== e ? e : {} | |
}(t), this.hooks = n, this.HAS_DOCUMENT_COOKIE = (0, a.hasDocumentCookie)() | |
} | |
return i(e, [{ | |
key: "_updateBrowserValues", | |
value: function() { | |
this.HAS_DOCUMENT_COOKIE && (this.cookies = r.default.parse(document.cookie)) | |
} | |
}, { | |
key: "get", | |
value: function(e) { | |
var t = arguments.length > 1 && void 0 !== arguments[1] ? arguments[1] : {}; | |
return this._updateBrowserValues(), d(this.cookies[e], t) | |
} | |
}, { | |
key: "getAll", | |
value: function() { | |
var e = arguments.length > 0 && void 0 !== arguments[0] ? arguments[0] : {}; | |
this._updateBrowserValues(); | |
var t = {}; | |
for (var n in this.cookies) t[n] = d(this.cookies[n], e); | |
return t | |
} | |
}, { | |
key: "set", | |
value: function(e, t, n) { | |
"object" === (void 0 === t ? "undefined" : o(t)) && (t = JSON.stringify(t)), this.hooks && this.hooks.onSet && this.hooks.onSet(e, t, n), this.cookies[e] = t, this.HAS_DOCUMENT_COOKIE && (document.cookie = r.default.serialize(e, t, n)), this._emitChange({ | |
name: e, | |
value: t, | |
options: n | |
}) | |
} | |
}, { | |
key: "remove", | |
value: function(e, t) { | |
var n = t = (0, s.default)({}, t, { | |
expires: new Date(1970, 1, 1, 0, 0, 1), | |
maxAge: 0 | |
}); | |
this.hooks && this.hooks.onRemove && this.hooks.onRemove(e, n), delete this.cookies[e], this.HAS_DOCUMENT_COOKIE && (document.cookie = r.default.serialize(e, "", n)), this._emitChange({ | |
name: e, | |
value: void 0, | |
options: t | |
}) | |
} | |
}, { | |
key: "_emitChange", | |
value: function(e) { | |
for (var t = 0; t < this.changeListeners.length; ++t) this.changeListeners[t](e) | |
} | |
}, { | |
key: "addChangeListener", | |
value: function(e) { | |
this.changeListeners.push(e) | |
} | |
}, { | |
key: "removeChangeListener", | |
value: function(e) { | |
var t = this.changeListeners.indexOf(e); | |
t >= 0 && this.changeListeners.splice(t, 1) | |
} | |
}]), e | |
}(); | |
function l(e, t) { | |
return void 0 === t && (t = !e || "{" !== e[0] && "[" !== e[0] && '"' !== e[0]), !t | |
} | |
function d(e) { | |
var t = arguments.length > 1 && void 0 !== arguments[1] ? arguments[1] : {}; | |
if (l(e, t.doNotParse)) try { | |
return JSON.parse(e) | |
} catch (e) {} | |
return e | |
} | |
t.default = u, e.exports = t.default | |
}, function(e, t, n) { | |
"use strict"; | |
/*! | |
* cookie | |
* Copyright(c) 2012-2014 Roman Shtylman | |
* Copyright(c) 2015 Douglas Christopher Wilson | |
* MIT Licensed | |
*/ | |
t.parse = function(e, t) { | |
if ("string" != typeof e) throw new TypeError("argument str must be a string"); | |
for (var n = {}, i = t || {}, s = e.split(r), c = i.decode || o, u = 0; u < s.length; u++) { | |
var l = s[u], | |
d = l.indexOf("="); | |
if (!(d < 0)) { | |
var f = l.substr(0, d).trim(), | |
p = l.substr(++d, l.length).trim(); | |
'"' == p[0] && (p = p.slice(1, -1)), null == n[f] && (n[f] = a(p, c)) | |
} | |
} | |
return n | |
}, t.serialize = function(e, t, n) { | |
var o = n || {}, | |
r = o.encode || i; | |
if ("function" != typeof r) throw new TypeError("option encode is invalid"); | |
if (!s.test(e)) throw new TypeError("argument name is invalid"); | |
var a = r(t); | |
if (a && !s.test(a)) throw new TypeError("argument val is invalid"); | |
var c = e + "=" + a; | |
if (null != o.maxAge) { | |
var u = o.maxAge - 0; | |
if (isNaN(u)) throw new Error("maxAge should be a Number"); | |
c += "; Max-Age=" + Math.floor(u) | |
} | |
if (o.domain) { | |
if (!s.test(o.domain)) throw new TypeError("option domain is invalid"); | |
c += "; Domain=" + o.domain | |
} | |
if (o.path) { | |
if (!s.test(o.path)) throw new TypeError("option path is invalid"); | |
c += "; Path=" + o.path | |
} | |
if (o.expires) { | |
if ("function" != typeof o.expires.toUTCString) throw new TypeError("option expires is invalid"); | |
c += "; Expires=" + o.expires.toUTCString() | |
} | |
o.httpOnly && (c += "; HttpOnly"); | |
o.secure && (c += "; Secure"); | |
if (o.sameSite) { | |
switch ("string" == typeof o.sameSite ? o.sameSite.toLowerCase() : o.sameSite) { | |
case !0: | |
c += "; SameSite=Strict"; | |
break; | |
case "lax": | |
c += "; SameSite=Lax"; | |
break; | |
case "strict": | |
c += "; SameSite=Strict"; | |
break; | |
default: | |
throw new TypeError("option sameSite is invalid") | |
} | |
} | |
return c | |
}; | |
var o = decodeURIComponent, | |
i = encodeURIComponent, | |
r = /; */, | |
s = /^[\u0009\u0020-\u007e\u0080-\u00ff]+$/; | |
function a(e, t) { | |
try { | |
return t(e) | |
} catch (t) { | |
return e | |
} | |
} | |
}, function(e, t, n) { | |
"use strict"; | |
/* | |
object-assign | |
(c) Sindre Sorhus | |
@license MIT | |
*/ | |
var o = Object.getOwnPropertySymbols, | |
i = Object.prototype.hasOwnProperty, | |
r = Object.prototype.propertyIsEnumerable; | |
function s(e) { | |
if (null == e) throw new TypeError("Object.assign cannot be called with null or undefined"); | |
return Object(e) | |
} | |
e.exports = function() { | |
try { | |
if (!Object.assign) return !1; | |
var e = new String("abc"); | |
if (e[5] = "de", "5" === Object.getOwnPropertyNames(e)[0]) return !1; | |
for (var t = {}, n = 0; n < 10; n++) t["_" + String.fromCharCode(n)] = n; | |
if ("0123456789" !== Object.getOwnPropertyNames(t).map((function(e) { | |
return t[e] | |
})).join("")) return !1; | |
var o = {}; | |
return "abcdefghijklmnopqrst".split("").forEach((function(e) { | |
o[e] = e | |
})), "abcdefghijklmnopqrst" === Object.keys(Object.assign({}, o)).join("") | |
} catch (e) { | |
return !1 | |
} | |
}() ? Object.assign : function(e, t) { | |
for (var n, a, c = s(e), u = 1; u < arguments.length; u++) { | |
for (var l in n = Object(arguments[u])) i.call(n, l) && (c[l] = n[l]); | |
if (o) { | |
a = o(n); | |
for (var d = 0; d < a.length; d++) r.call(n, a[d]) && (c[a[d]] = n[a[d]]) | |
} | |
} | |
return c | |
} | |
}, function(e, t, n) { | |
"use strict"; | |
Object.defineProperty(t, "__esModule", { | |
value: !0 | |
}); | |
var o = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function(e) { | |
return typeof e | |
} : function(e) { | |
return e && "function" == typeof Symbol && e.constructor === Symbol && e !== Symbol.prototype ? "symbol" : typeof e | |
}; | |
function i() { | |
return "object" === ("undefined" == typeof document ? "undefined" : o(document)) && "string" == typeof document.cookie | |
} | |
t.hasDocumentCookie = i, t.cleanCookies = function() { | |
document.cookie.split(";").forEach((function(e) { | |
document.cookie = e.replace(/^ +/, "").replace(/=.*/, "=;expires=" + (new Date).toUTCString() + ";path=/") | |
})) | |
}; | |
t.HAS_DOCUMENT_COOKIE = i() | |
}, function(e, t) { | |
const n = (e, ...t) => { | |
if (null == e) throw new TypeError("Cannot convert argument to object"); | |
const n = Object(e); | |
for (let e = 1; e < t.length; e += 1) { | |
const o = t[e]; | |
if (null != o) { | |
const e = Object.keys(Object(o)); | |
for (let t = 0, i = e.length; t < i; t += 1) { | |
const i = e[t], | |
r = Object.getOwnPropertyDescriptor(o, i); | |
void 0 !== r && r.enumerable && (n[i] = o[i]) | |
} | |
} | |
} | |
return n | |
}; | |
Object.assign || Object.defineProperty(Object, "assign", { | |
enumerable: !1, | |
configurable: !0, | |
writable: !0, | |
value: n | |
}) | |
}, , , , , , , , , , , , , , , , , , , , , , , function(e, t, n) { | |
n(153), n(306), n(316), n(154), n(312), n(114), n(156), n(157), n(158), e.exports = n(159) | |
}, function(e, t) { | |
! function() { | |
if ("function" == typeof window.CustomEvent) return !1; | |
function e(e, t) { | |
t = t || { | |
bubbles: !1, | |
cancelable: !1, | |
detail: void 0 | |
}; | |
var n = document.createEvent("CustomEvent"); | |
return n.initCustomEvent(e, t.bubbles, t.cancelable, t.detail), n | |
} | |
e.prototype = window.Event.prototype, window.CustomEvent = e | |
}() | |
}, function(e, t) { | |
const n = document.getElementById("premium-banner"), | |
o = document.getElementById("Header"), | |
i = document.querySelector("#Header .center"), | |
r = document.querySelector("#Header .right"), | |
s = document.getElementById("Nav"), | |
a = document.getElementById("nav-mobile"), | |
c = () => { | |
const { | |
height: e | |
} = n.getBoundingClientRect(), { | |
height: t | |
} = o.getBoundingClientRect(); | |
o.style.marginTop = "".concat(e - 1, "px"), i.style.marginTop = "".concat(e - 1, "px"), r.style.marginTop = "".concat(e - 1, "px"), s.style.marginTop = "".concat(e - 1, "px"), a && (a.style.top = "".concat(e + t - 2, "px")) | |
}, | |
{ | |
user: u | |
} = window.lmd, | |
l = (new Date).getTime(), | |
d = document.getElementById("js-reminder-close"), | |
f = document.getElementById("js-reminder-link"), | |
p = document.getElementById("js-reminder-link-sepa"), | |
m = document.getElementById("js-body"), | |
h = "lmd_premium_banner_reminder_next_display_timestamp", | |
g = () => { | |
const e = (new Date).getTime() + (window.lmd_debug ? 3e4 : 432e6); | |
window.localStorage.setItem(h, e) | |
}; | |
function y(e, t, n) { | |
if (e && t && n && !Number.isNaN(n)) { | |
const o = new CustomEvent("actionPremiumBanner", { | |
detail: { | |
label: t, | |
phase: n | |
} | |
}); | |
e.dispatchEvent(o) | |
} | |
} | |
const v = (e, t, c) => { | |
o.style.marginTop = "", i.style.marginTop = "", r.style.marginTop = "", s.style.marginTop = "", a && (a.style.top = ""), g(), m.classList.remove("body--premium-banner"), n.parentNode.removeChild(n), y(e, t, c) | |
}; | |
(() => { | |
if (n) { | |
const e = parseInt(n.getAttribute("data-banner"), 10); | |
d.addEventListener("click", v.bind(null, d, "fermer", e)), f && f.addEventListener("click", t => { | |
t.preventDefault(), y(f, "maj", e), setTimeout(() => { | |
window.location.href = f.href | |
}, 100) | |
}), p && p.addEventListener("click", t => { | |
t.preventDefault(), y(p, "sepa", e), setTimeout(() => { | |
window.location.href = p.href | |
}, 100) | |
}), u && u.abo && !(() => { | |
const e = document.getElementById("cookie-banner"); | |
return !(!e || e.classList.contains("is-closed")) | |
})() && (() => { | |
const e = window.localStorage.getItem(h); | |
return !e || l >= e | |
})() && (m.classList.add("body--premium-banner"), n.classList.add("message--reminder-on"), window.addEventListener("resize", () => { | |
c() | |
}), c()) | |
} | |
})() | |
}, function(e, t) { | |
const n = '[data-ui="dropdown"]', | |
o = "data-ui-dropdown", | |
i = "data-selected-id", | |
r = document.querySelectorAll(n); | |
for (let e = 0; e < r.length; e += 1) { | |
const t = r[e], | |
n = t.getAttribute(o), | |
s = t.getAttribute("id"); | |
t.addEventListener("change", e => { | |
const o = t.getElementsByClassName("js-dropdown__select-container"), | |
r = e.target.value; | |
s === n && e.target.classList.contains("dropdown__selectbox") && Array.prototype.forEach.call(o, e => { | |
e.getAttribute(i) === r ? e.classList.remove("dropdown__select-container--hidden") : e.classList.add("dropdown__select-container--hidden") | |
}) | |
}) | |
} | |
}, function(e, t, n) { | |
"use strict"; | |
n.r(t); | |
var o = n(108), | |
i = n.n(o), | |
r = n(75), | |
s = n(1); | |
const a = document.querySelector(".message.message--register"), | |
c = document.getElementById("js-register-banner-trigger"), | |
u = document.getElementById("js-register-banner-content"), | |
l = window.lmd.user && !0 === window.lmd.user.abo, | |
d = () => { | |
setTimeout(() => { | |
if (Object(s.a)("register-banner - onConsentGiven setTimeout"), null !== a) { | |
const t = [1], | |
n = new i.a, | |
o = parseInt(n.get("lmd_gdpr_token"), 10); | |
if (t.includes(o) && !l && !0 === Object(r.d)() && !1 === Object(r.a)("ads")) return void a.classList.add("message--hidden"); | |
if (!l && !0 === Object(r.d)() && !1 === Object(r.a)("ads")) { | |
var e; | |
return "home" === (null === (e = window.lmd) || void 0 === e ? void 0 : e.typePage) && (c.classList.add("ui-collapse--shown"), u.classList.add("ui-collapse--shown")), void(!0 === a.classList.contains("message--hidden") && (a.classList.remove("message--hidden"), function(e) { | |
const t = new CustomEvent("lmdRegisterBannerVisible"); | |
e.dispatchEvent(t) | |
}(a))) | |
} | |
a.classList.add("message--hidden") | |
} | |
}, 500) | |
}; | |
document.addEventListener("gdprConsentFirstGiven", () => d(), { | |
once: !1 | |
}), document.addEventListener("gdprConsentGiven", () => d(), { | |
once: !1 | |
}), document.addEventListener("lmdCookieBannerClosed", () => d(), { | |
once: !1 | |
}), d() | |
}, function(e, t, n) { | |
"use strict"; | |
n.r(t), | |
function(e) { | |
var t = n(97), | |
o = n.n(t); | |
const i = t => { | |
var n, o, i, r, s; | |
const a = null !== (n = t.dataset.url) && void 0 !== n ? n : null, | |
c = null !== (o = t.dataset.position) && void 0 !== o ? o : null, | |
u = null !== (i = t.dataset.viewArticle) && void 0 !== i ? i : "0", | |
l = null !== (r = t.dataset.grid) && void 0 !== r ? r : "0", | |
d = null !== (s = t.dataset.service) && void 0 !== s ? s : ""; | |
if (null === a || null === c) return; | |
const f = window.lmd.isAbo ? 1 : 0, | |
p = window.lmd.device || "desktop"; | |
e("/ajax/bizdev?isAbo=".concat(f, "&device=").concat(p, "&url=").concat(a, "&position=").concat(c, "&viewArticle=").concat(u, "&grid=").concat(l, "&service=").concat(d)).then(e => { | |
if (!e.ok) throw e; | |
return e.json() | |
}).then(e => { | |
const n = document.createElement("div"); | |
n.innerHTML = e.html.trim(), t.replaceWith(...n.childNodes), window.lmd.lazyload.update() | |
}).catch(e => { | |
console.error("loading bizdev", { | |
e: e | |
}) | |
}) | |
}; | |
window.lmd.lazyloadBizdev = new o.a({ | |
elements_selector: ".lazy-bizdev", | |
callback_enter: i | |
}) | |
}.call(this, n(40)) | |
}, function(e, t, n) { | |
"use strict"; | |
n.r(t), | |
function(e) { | |
var t = n(97), | |
o = n.n(t); | |
const i = t => { | |
var n; | |
const o = null !== (n = window.lmd.context.article.legacyId) && void 0 !== n ? n : null; | |
null !== o && window.lmd.isAbo && e("/ajax/forecast?legacyId=".concat(o)).then(e => { | |
if (!e.ok) throw e; | |
return e.json() | |
}).then(e => { | |
const n = document.createElement("div"); | |
n.innerHTML = e.html.trim(), t.replaceWith(...n.childNodes), window.lmd.lazyload.update() | |
}).catch(e => { | |
console.error("loadingforecast", { | |
e: e | |
}) | |
}) | |
}; | |
window.lmd.lazyloadForecast = new o.a({ | |
elements_selector: ".lazy-forecast", | |
callback_enter: i | |
}) | |
}.call(this, n(40)) | |
}, function(e, t, n) { | |
"use strict"; | |
n.r(t); | |
var o = n(95), | |
i = n(109), | |
r = n(74), | |
s = n(67), | |
a = n(24); | |
function c(e, t, n) { | |
const o = e.getBoundingClientRect(); | |
if (Math.max(document.documentElement.clientHeight, window.innerHeight) - o.bottom > 0) { | |
if (t) { | |
u({ | |
facebookEvent: "fin_de_lecture_teaser", | |
googleAnalyticsEvent: "fin_lecture_teaser" | |
}) | |
} else if (n) { | |
u({ | |
facebookEvent: "fin_de_lecture_quali", | |
googleAnalyticsEvent: "fin_lecture_quali" | |
}) | |
} else { | |
u({ | |
facebookEvent: "fin_de_lecture_article", | |
googleAnalyticsEvent: "fin_lecture_article" | |
}) | |
} | |
const o = new CustomEvent("lmdNewEndReadArticleStopListening"); | |
e.dispatchEvent(o) | |
} | |
} | |
function u(e = {}) { | |
const t = new CustomEvent("lmdNewEndReadArticle", { | |
detail: { | |
...e | |
} | |
}); | |
window.dispatchEvent(t) | |
} | |
function l(e, t, n = !1) { | |
const i = Object(o.a)(c.bind(null, e, t, n), 250); | |
Object(r.a)("scroll", i), e.addEventListener("lmdNewEndReadArticleStopListening", () => Object(r.f)("scroll", i)) | |
} | |
function d(e) { | |
const t = Object(i.b)(); | |
t && l(t, !1, e) | |
} | |
const f = s.b(); | |
if ("Article" === f || "video" === f) { | |
let e = null; | |
Object(a.a)(window.lmd, "analytics", "amplitude", "pageType") && "commentaires" === window.lmd.analytics.amplitude.pageType && (e = !0); | |
if (!("video" === f && !e)) | |
if (s.f()) ! function() { | |
const e = document.getElementsByClassName("paywall__next")[0]; | |
e && l(e, !0) | |
}(); | |
else { | |
setTimeout(() => { | |
d(!1) | |
}, 13e3); | |
const { | |
nbChar: e = 0 | |
} = window.lmd.context.article, t = Math.floor(.01328 * e * 1e3); | |
setTimeout(() => d(!0), t) | |
} | |
} | |
}, , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , function(e, t, n) { | |
"use strict"; | |
n.r(t); | |
var o = n(36); | |
function i() { | |
const e = document.querySelectorAll(".Nav__sub-item"); | |
e.length && Array.prototype.forEach.call(e, e => { | |
e.classList.contains("js-desktop-open") && e.classList.remove("js-desktop-open") | |
}) | |
} | |
function r() { | |
const e = document.querySelectorAll(".js-dropdown"); | |
e.length && Array.prototype.forEach.call(e, e => { | |
e.parentNode.classList.contains("Nav__item--active") && e.parentNode.classList.remove("Nav__item--active"), e.classList.contains("js-dropdown-burger-open") && (e.classList.remove("js-dropdown-burger-open"), e.setAttribute("aria-expanded", !1)) | |
}) | |
} | |
function s() { | |
const e = document.querySelectorAll(".js-dropdown"); | |
e.length && Array.prototype.forEach.call(e, e => { | |
e.setAttribute("aria-expanded", !1) | |
}) | |
} | |
function a(e) { | |
const t = document.getElementById("overlay"); | |
e && !t.classList.contains("overlay--visible") ? t.classList.add("overlay--visible") : !e && t.classList.contains("overlay--visible") && t.classList.remove("overlay--visible") | |
} | |
var c = n(73), | |
u = n(98), | |
l = n(117); | |
const d = window.lmd.env || "prd", | |
f = "lmd_partner_banner_reminder_next_display_timestamp", | |
p = "lmd_partner_banner_reminder_next_display_count", | |
m = "lmd_partner_banner_reminder_tage_advantage"; | |
let h = !1; | |
function g() { | |
const e = (new Date).getTime() + ("prd" !== d && "stg" !== d ? 6e4 : 6048e5); | |
window.localStorage.setItem(f, e), window.localStorage.setItem(p, 3) | |
} | |
function y(e) { | |
const t = document.getElementById("js-partner-banner"); | |
e ? t.classList.add("message--enable") : t.classList.remove("message--enable") | |
} | |
function v() { | |
const e = document.getElementById("js-partner-banner"); | |
Object(c.b)().width >= u.b && e && document.getElementById("js-partner-banner").classList.contains("message--enable") && (e.classList.add("message--shown"), e.dispatchEvent(new Event("shown")), function() { | |
if (h) return; | |
const e = window.localStorage.getItem(p); | |
if (h = !0, null !== e) { | |
const t = parseInt(e, 10) - 1; | |
t <= 0 ? g() : window.localStorage.setItem(p, t) | |
} | |
}()) | |
} | |
function b() { | |
const e = document.getElementById("js-partner-banner"); | |
Object(c.b)().width >= u.b && e && e.classList.contains("message--shown") && e.classList.remove("message--shown") | |
} | |
function w() { | |
const e = document.getElementById("js-campaign-header"), | |
t = document.getElementById("js-article"), | |
n = document.querySelector(".Nav"), | |
o = document.getElementById("Header"), | |
i = document.getElementById("js-relance-banner"), | |
r = document.getElementById("js-partner-banner"); | |
o && o.classList.add("sticky"), n && n.classList.add("Nav--sticky"), e && e.classList.add("page__heading--sticky-js"), i && Object(l.b)(), r && v(), t && t.classList.add("zone--sticky") | |
} | |
function _() { | |
const e = document.getElementById("js-campaign-header"), | |
t = document.getElementById("js-article"), | |
n = document.querySelector(".Nav"), | |
o = document.getElementById("Header"), | |
i = document.getElementById("js-campaign-description"), | |
r = document.getElementById("js-relance-banner"), | |
s = document.getElementById("js-partner-banner"); | |
o && o.classList.contains("sticky") && o.classList.remove("sticky"), n && n.classList.contains("Nav--sticky") && n.classList.remove("Nav--sticky"), e && e.classList.contains("page__heading--sticky-js") ? e.classList.remove("page__heading--sticky-js") : (r && Object(l.c)(), s && b(), null !== i && (i.style.paddingTop = "none")), t && t.classList.contains("zone--sticky") && t.classList.remove("zone--sticky") | |
} | |
document.querySelector(".message--partner-nyt") && function() { | |
var e; | |
const t = window.localStorage.getItem(f), | |
n = window.localStorage.getItem(m), | |
o = (new Date).getTime(), | |
i = !t || o >= t, | |
r = null !== (e = window.localStorage.getItem(p)) && void 0 !== e ? e : 1; | |
return !n && i && r > 0 | |
}() && (! function() { | |
const e = document.getElementById("js-partner-close"), | |
t = document.getElementById("js-partner-banner"); | |
e && e.addEventListener("click", e => { | |
e.preventDefault(), b(), y(!1), g(), t.dispatchEvent(new Event("close")) | |
}) | |
}(), function() { | |
const e = document.getElementById("js-partner-link"); | |
e && e.addEventListener("click", () => { | |
window.localStorage.setItem(m, !0), b() | |
}) | |
}(), y(!0)); | |
var E = n(108), | |
L = n.n(E); | |
function O(e) { | |
const t = document.getElementById("connexion-desktop"), | |
n = document.querySelector(".User__arrow"), | |
o = document.querySelector("body"); | |
e || t.classList.contains("Connexion--open") ? (a(), t && t.classList.contains("Connexion--open") && t.classList.remove("Connexion--open"), n && n.classList.contains("User__arrow--up") && n.classList.remove("User__arrow--up"), o.classList.contains("Burger__display") && o.classList.remove("Burger__display")) : (a(!0), n.classList.add("User__arrow--up"), t.classList.add("Connexion--open"), o.classList.add("Burger__display")) | |
} | |
function T() { | |
const e = document.querySelector(".js-trigger-connexion"); | |
e.classList.contains("js-connexion-open") ? e.classList.remove("js-connexion-open") : e.classList.add("js-connexion-open") | |
} | |
var j = n(113); | |
let I; | |
function S() { | |
const e = document.querySelectorAll(".js-dropdown"); | |
e.length && Array.prototype.forEach.call(e, e => { | |
e.classList.contains("js-dropdown-burger") ? e.classList.remove("js-dropdown-burger") : e.classList.add("js-dropdown-burger") | |
}) | |
} | |
function x() { | |
const e = document.getElementById("nav-markup") || null, | |
t = document.getElementById("nav-mobile"), | |
n = document.querySelector("Header"), | |
o = document.getElementById("nav-desktop"), | |
i = document.querySelector("body"); | |
e && (n.classList.remove("Header--mobile"), Array.prototype.forEach.call(I, e => { | |
e.classList.remove("js-is-open") | |
}), t.classList.remove("js-burger-is-open"), o.appendChild(e), i.classList.remove("Burger__display"), r(), S()) | |
} | |
function A() { | |
const e = document.querySelectorAll(".js-home-tab-burger"), | |
t = document.querySelectorAll(".js-home-tab"); | |
e.length && Array.prototype.forEach.call(t, e => { | |
e.addEventListener("click", e => { | |
e.preventDefault(), x() | |
}) | |
}) | |
} | |
function k(e = !0) { | |
const t = document.getElementById("nav-markup") || null, | |
n = document.getElementById("nav-mobile") || null, | |
o = document.getElementById("nav-desktop"), | |
i = document.getElementById("nav-desktop-contextual"), | |
r = document.getElementById("Burger-contextual-desktop") || null, | |
s = document.querySelector("Header"), | |
a = document.querySelector("body"); | |
e ? n && n.classList.contains("js-burger-is-open") ? (s.classList.remove("Header--mobile"), Array.prototype.forEach.call(I, e => { | |
e.classList.remove("js-is-open") | |
}), n.classList.remove("js-burger-is-open"), o.appendChild(t), a.classList.remove("Burger__display")) : (s.classList.add("Header--mobile"), Array.prototype.forEach.call(I, e => { | |
e.classList.add("js-is-open") | |
}), n.classList.add("js-burger-is-open"), n.appendChild(t), A(), a.classList.add("Burger__display")) : r && !e && (r.classList.contains("js-is-open") ? (Array.prototype.forEach.call(I, e => { | |
e.classList.remove("js-is-open") | |
}), r.classList.remove("js-is-open"), o.appendChild(t), a.classList.remove("Burger-contextual__display")) : (Array.prototype.forEach.call(I, e => { | |
e.classList.add("js-is-open") | |
}), r.classList.add("js-is-open"), i.appendChild(t), A(), a.classList.add("Burger-contextual__display"))) | |
} | |
function M() { | |
i(), r(), (window.innerWidth || document.documentElement.clientWidth || document.body.clientWidth) <= 1023 ? k() : k(!1), S(), a(), | |
function() { | |
const e = document.querySelectorAll(".js-home-tab"); | |
e.length && Array.prototype.forEach.call(e, e => { | |
e.classList.contains("js-home-tab-burger") ? e.classList.remove("js-home-tab-burger") : e.classList.add("js-home-tab-burger") | |
}) | |
}() | |
} | |
function C() { | |
const e = document.querySelector(".js-trigger-connexion"); | |
I.length && Array.prototype.forEach.call(I, t => { | |
t.addEventListener("click", (function(t) { | |
t.preventDefault(), Object(j.b)(), M(), O(!0), this.classList.contains("js-is-open") && function() { | |
const e = document.querySelectorAll(".js-dropdown"); | |
e.length && Array.prototype.forEach.call(e, e => { | |
e.parentNode.classList.add("Nav__item--active"), e.parentNode.querySelector(".Nav__sub-item").classList.add("js-desktop-open"), e.setAttribute("aria-expanded", !0), e.classList.contains("js-dropdown-burger") && e.classList.add("js-dropdown-burger-open") | |
}) | |
}(), e && e.classList.contains("js-connexion-open") && T() | |
})) | |
}) | |
} | |
function B(e) { | |
return e.setAttribute("aria-expanded", !1), e.nextElementSibling.classList.remove("js-desktop-open"), e.parentNode.classList.remove("Nav__item--active"), e.classList.contains("js-dropdown-burger-open") && e.classList.remove("js-dropdown-burger-open"), a(), window.activeNav = null, !1 | |
} | |
function N(e) { | |
const t = document.querySelector("body"), | |
n = document.getElementById("Burger-contextual-desktop") || null; | |
return e && !e.classList.contains("js-dropdown-burger") && t.classList.remove("Burger__display"), e.parentNode.classList.contains("Nav__item--active") ? B(e) : (i(), a(), r(), window.activeNav = e, e.parentNode.classList.add("Nav__item--active"), e.parentNode.querySelector(".Nav__sub-item").classList.add("js-desktop-open"), e.setAttribute("aria-expanded", !0), e.classList.contains("js-dropdown-burger") && e.classList.add("js-dropdown-burger-open"), t.classList.add("Burger__display"), a(!n), !0) | |
} | |
function R() { | |
const e = document.querySelectorAll(".js-dropdown"); | |
e.length && Array.prototype.forEach.call(e, e => { | |
e.addEventListener("click", e => { | |
e.preventDefault(), N(e.currentTarget), Object(c.b)().width >= u.a && function(e) { | |
if ("0" === e.getAttribute("data-lazyload")) { | |
const t = e.parentNode.querySelectorAll(".js-media-nav"); | |
t && Array.prototype.forEach.call(t, e => { | |
const t = e.getAttribute("data-lazy"), | |
n = e.getAttribute("data-lazy-retina"); | |
n && e.setAttribute("srcset", n), e.setAttribute("src", t), e.removeAttribute("data-lazy"), e.removeAttribute("data-lazy-retina") | |
}), e.setAttribute("data-lazyload", "1") | |
} | |
}(e.currentTarget) | |
}), e.addEventListener("keydown", e => { | |
32 === e.which && (e.preventDefault(), N(e.currentTarget)) | |
}) | |
}) | |
} | |
function z(e) { | |
const t = document.querySelectorAll(".zone"); | |
t.length && Array.prototype.forEach.call(t, t => { | |
e || t.classList.contains("zone--hidden") ? t.classList.remove("zone--hidden") : t.classList.add("zone--hidden") | |
}) | |
} | |
function q() { | |
const e = document.querySelectorAll(".js-home-tab"), | |
t = document.querySelector(".Nav__item--home"), | |
n = document.querySelector("body"), | |
o = document.getElementById("en-continu"); | |
if (e.length) { | |
document.querySelector(".Nav").addEventListener("focusin", e => { | |
e.target && window.activeNav && e.target.classList.contains("js-dropdown") && e.target !== window.activeNav && B(window.activeNav) | |
}), Array.prototype.forEach.call(e, e => { | |
e.addEventListener("click", l => { | |
if (l.preventDefault(), e.classList.contains("js-is-active")) return !1; | |
if (s(), i(), function() { | |
const e = document.querySelector("main"), | |
t = document.getElementById("en-continu"), | |
n = document.querySelectorAll(".js-home-tab"); | |
t.classList.add("js-is-hide"), e.classList.add("js-is-hide"), t.classList.remove("js-is-active"), e.classList.remove("js-is-active"), n.length && Array.prototype.forEach.call(n, e => { | |
e.parentNode.classList.remove("Nav__item--active") | |
}) | |
}(), a(), r(), Object(c.b)().width >= u.b) return t.classList.add("Nav__item--active"), n.classList.remove("Burger__display"), !1; | |
if (e.classList.contains("js-is-active")) return !1; | |
const d = document.querySelector("[data-target=".concat(e.getAttribute("data-target"), "]")); | |
return d && (d.parentNode.classList.add("Nav__item--active"), "en-continu" === e.getAttribute("data-target") ? (((e, t) => { | |
let n, o; | |
"0" === t.getAttribute("data-lazyload") && (n = e.querySelectorAll(".js-media-live"), o = e.querySelectorAll(".js-media-live-srcset"), n && Array.prototype.forEach.call(n, e => { | |
const t = e.getAttribute("data-lazy"); | |
e.setAttribute("src", t), e.removeAttribute("data-lazy") | |
}), o && Array.prototype.forEach.call(o, e => { | |
const t = e.getAttribute("data-lazy-srcset"); | |
e.setAttribute("srcset", t), e.removeAttribute("data-lazy-srcset") | |
}), t.setAttribute("data-lazyload", "1")) | |
})(o, e), z(), document.getElementById(e.getAttribute("data-target")).classList.remove("js-is-hide")) : z(!0)), x(), !0 | |
}) | |
}) | |
} | |
} | |
window.activeNav = null, Object(o.c)(() => { | |
I = document.querySelectorAll(".Burger"), q(), R(), | |
function() { | |
const e = document.getElementById("overlay"), | |
t = document.querySelector("body"), | |
n = document.getElementById("connexion-desktop"), | |
o = document.querySelector(".User__arrow"); | |
e && e.addEventListener("click", (function(e) { | |
e.preventDefault(), this.classList.contains("overlay--visible") && (i(), s(), a(), r(), t.classList.contains("Burger__display") && t.classList.remove("Burger__display"), n && n.classList.contains("Connexion--open") && n.classList.remove("Connexion--open"), o && o.classList.contains("User__arrow--up") && o.classList.remove("User__arrow--up")) | |
})) | |
}(), C(), | |
function() { | |
const e = document.querySelector(".js-trigger-connexion"); | |
e && e.addEventListener("click", e => { | |
e.preventDefault(), T(), O() | |
}); | |
const t = document.getElementsByClassName("js-header-login-staled")[0]; | |
if (t) { | |
(new L.a).get("lmd_a_c") || t.classList.remove("Header__connexion--hide") | |
} | |
}(), | |
function() { | |
const e = document.getElementById("js-campaign-header"), | |
t = document.querySelector(".Nav"), | |
n = document.querySelector("Header"), | |
o = document.querySelector(".account__header"), | |
i = e ? e.offsetHeight : 0, | |
r = document.getElementById("js-campaign-description"), | |
s = document.getElementById("js-partner-banner"), | |
a = null == t ? void 0 : t.clientHeight, | |
d = { | |
threshold: 0, | |
rootMargin: "".concat(a || 0, "px") | |
}; | |
if (t && Object(c.b)().width >= u.b && "0" === t.getAttribute("data-sticky")) { | |
null !== r && (r.style.paddingTop = "none"); | |
new IntersectionObserver(e => { | |
const { | |
isIntersecting: n | |
} = e[0]; | |
n ? (_(), t.classList.remove("on-scroll")) : (t.classList.add("on-scroll"), w()) | |
}, d).observe(n) | |
} else Object(c.b)().width < u.b && null !== r && (r.style.paddingTop = "".concat(i, "px")); | |
if (!e && t && "1" === t.getAttribute("data-sticky") && Object(c.b)().width >= u.b && (Object(l.b)(), s && v()), o) { | |
new IntersectionObserver(e => { | |
const { | |
isIntersecting: t | |
} = e[0]; | |
t ? _() : w() | |
}, d).observe(o) | |
} | |
}() | |
}) | |
}, , , , , , function(e, t, n) { | |
"use strict"; | |
n.r(t); | |
var o = n(36); | |
const i = '[data-toggle="collapse"]', | |
r = "data-toggle-target", | |
s = "data-toggle-scope", | |
a = "ui-collapse--shown", | |
c = e => { | |
const t = (e => e.hasAttribute(s) ? document.querySelector(e.getAttribute(s)) : e.parentNode)(e), | |
n = ((e, t) => !!e.hasAttribute(r) && t.querySelectorAll(e.getAttribute(r)))(e, t); | |
let o; | |
e.classList.toggle(a); | |
const i = e.innerHTML; | |
if ("Voir toute la liste" === i ? e.innerHTML = "Réduire la liste" : "Réduire la liste" === i && (e.innerHTML = "Voir toute la liste"), "Voir plus de villes" === i ? e.innerHTML = "Voir moins de villes" : "Voir moins de villes" === i && (e.innerHTML = "Voir plus de villes"), "Voir plus de départements" === i ? e.innerHTML = "Voir moins de départements" : "Voir moins de départements" === i && (e.innerHTML = "Voir plus de départements"), "Voir plus" === i ? e.innerHTML = "Voir moins" : "Voir moins" === i && (e.innerHTML = "Voir plus"), "Pourquoi voyez-vous ce message ?" === i ? e.innerHTML = "Réduire ce message" : "Réduire ce message" === i && (e.innerHTML = "Pourquoi voyez-vous ce message ?"), n && n.length > 0) | |
for (o = 0; o < n.length; o += 1) n[o].classList.toggle(a) | |
}; | |
Object(o.b)("click", i, e => { | |
"A" === e.currentTarget.tagName && e.preventDefault(), c(e.target) | |
}); | |
n(155); | |
var u = n(23); | |
const l = '[data-ui="tabs"]', | |
d = "data-ui-tabs", | |
f = "data-ui-contents", | |
p = "--active", | |
m = "--shown", | |
h = (e, t) => { | |
const n = document.getElementsByClassName(t); | |
for (let e = 0; e < n.length; e += 1) n[e].classList.remove(t); | |
e.classList.add(t) | |
}, | |
g = document.querySelectorAll(l); | |
for (let e = 0; e < g.length; e += 1) { | |
const t = g[e]; | |
t.addEventListener("click", e => { | |
"A" === e.currentTarget.tagName && e.preventDefault(); | |
const n = t.getAttribute(d), | |
o = t.getAttribute(f); | |
if (e.target && Object(u.d)(e.target, ".".concat(n))) { | |
const t = document.getElementsByClassName(n), | |
i = document.getElementsByClassName(o), | |
r = Array.prototype.indexOf.call(t, e.target), | |
s = i.item(r); | |
h(e.target, n + p), s && h(s, o + m) | |
} | |
}) | |
} | |
}, , , , function(e, t, n) { | |
"use strict"; | |
n.r(t); | |
var o = n(36); | |
let i = null; | |
function r(e, t) { | |
if (e.classList.contains("ui-collapse--shown")) { | |
t.classList.remove("capping--extended"); | |
const e = new CustomEvent("cappingHelp"); | |
t.dispatchEvent(e) | |
} else { | |
void 0 !== window.siriusCapping.stop && window.siriusCapping.stop(), t.classList.add("capping--extended"); | |
const e = new CustomEvent("cappingHelp", { | |
detail: { | |
label: "aide" | |
} | |
}); | |
t.dispatchEvent(e) | |
} | |
} | |
function s() { | |
const e = document.getElementById("js-capping"), | |
t = document.getElementById("js-capping-trigger"); | |
t && (i || (i = r.bind(null, t, e)), t.addEventListener("click", i)) | |
} | |
function a() { | |
const e = document.getElementById("js-capping-header"), | |
t = window.setTimeout(() => { | |
e.classList.add("capping__header--visible"), clearTimeout(t), | |
function() { | |
const e = document.getElementById("js-capping-content"), | |
t = document.getElementById("js-capping-wrapper"), | |
n = window.setTimeout(() => { | |
e.classList.add("capping__content--visible"), t.classList.add("capping__wrapper--visible"), clearTimeout(n) | |
}, 1e3) | |
}(), "reading" === window.siriusCapping.config.mode && function() { | |
const e = document.getElementById("js-capping-bottom"), | |
t = window.setTimeout(() => { | |
e.classList.add("capping__bottom--visible"), clearTimeout(t) | |
}, 1e3) | |
}() | |
}, 500) | |
} | |
Object(o.b)("click", ".js-capping-close", e => { | |
if (void 0 !== window.siriusCapping.continueReading) { | |
const t = document.getElementById("js-capping"); | |
if (t) | |
if (e.target.classList.contains("js-capping-close-extended")) { | |
const e = new CustomEvent("cappingContinue"); | |
t.dispatchEvent(e) | |
} else { | |
const e = new CustomEvent("cappingContinue", { | |
detail: { | |
label: "continuer" | |
} | |
}); | |
t.dispatchEvent(e) | |
} window.siriusCapping.continueReading() | |
} | |
}); | |
var c = n(85), | |
u = n(66); | |
const l = lmd && lmd.features && !0 === lmd.features.capping, | |
d = lmd && lmd.user && void 0 !== lmd.user.id, | |
f = d && !0 === lmd.user.capping && !Object(c.c)(); | |
if (!(lmd && lmd.context && !0 === lmd.context.aec) && l) { | |
const e = window.siriusCapping || {}; | |
var p, m, h, g, y; | |
if (e.config = { | |
enable: f, | |
brand: "c5c40d6a-1b00-42de-8e6d-f9e7795fd87b", | |
copyPasteObserver: { | |
enable: !0, | |
characterLimit: 800, | |
prependToClipboard: '<br>Vous pouvez partager un article en cliquant sur les icônes de partage en haut à droite de celui-ci. <br>\nLa reproduction totale ou partielle d’un article, sans l’autorisation écrite et préalable du <a href="https://www.lemonde.fr">Monde</a>, est strictement interdite. <br>\nPour plus d’informations, consultez nos <a href="https://moncompte.lemonde.fr/cgv">conditions générales de vente</a>. <br>\nPour toute demande d’autorisation, contactez <a href="mailto:droitsdauteur@lemonde.fr">droitsdauteur@lemonde.fr</a>. <br>\nEn tant qu’abonné, vous pouvez offrir jusqu’à cinq articles par mois à l’un de vos proches grâce à la fonctionnalité « Offrir un article ». <br><br>\n\n<a href="'.concat(document.location.href, '">').concat(document.location.href, "</a><br><br>\n\n") | |
} | |
}, d) e.config.userId = lmd.user.id, e.config.tolerance = null !== (p = null === (m = lmd.user) || void 0 === m ? void 0 : m.cappingTolerance) && void 0 !== p ? p : 1, e.config.mode = null !== (h = null === (g = lmd.user) || void 0 === g ? void 0 : g.cappingMode) && void 0 !== h ? h : "reading", e.config.showPopinFunction = function(e) { | |
let t = "Lecture du <i>Monde</i> en cours sur un autre appareil."; | |
if (void 0 !== e && !0 === e.determined && (t = "Un autre appareil vient de bloquer votre lecture."), document.querySelector(".capping__notice").innerHTML = t, "device" === window.siriusCapping.config.mode) { | |
let e = "Votre abonnement <i>Le Monde</i> permet la lecture sur un seul appareil"; | |
window.siriusCapping.config.tolerance > 1 && (e = "Votre abonnement <i>Le Monde</i> permet la lecture sur ".concat(window.siriusCapping.config.tolerance, " appareils maximum")), document.querySelector(".capping__title").innerHTML = e; | |
const t = document.getElementById("js-capping-yellow-button"); | |
t && (t.style.display = "none"); | |
const n = document.getElementById("js-capping-bottom"); | |
n && (n.style.display = "none") | |
} | |
const n = document.getElementById("js-capping"); | |
if (n) { | |
const e = document.getElementById("js-body"); | |
document.querySelector("Main").prepend(n), s(), e.classList.add("capping--body"), n.classList.add("capping--visible"); | |
const t = new CustomEvent("cappingVisible"); | |
n.dispatchEvent(t), a() | |
} | |
}, e.config.hidePopinFunction = function() { | |
const e = document.getElementById("js-capping"), | |
t = document.getElementById("js-body"), | |
n = document.getElementById("js-capping-faq"), | |
o = document.getElementById("js-capping-trigger"), | |
i = document.getElementById("js-capping-content"), | |
r = document.getElementById("js-capping-wrapper"), | |
s = document.getElementById("js-capping-header"), | |
a = document.getElementById("js-capping-bottom"); | |
t && t.classList.contains("capping--body") && t.classList.remove("capping--body"), e && (e.classList.contains("capping--visible") && e.classList.remove("capping--visible"), e.classList.contains("capping--extended") && e.classList.remove("capping--extended")), i && i.classList.contains("capping__content--visible") && i.classList.remove("capping__content--visible"), r && r.classList.contains("capping__wrapper--visible") && r.classList.remove("capping__wrapper--visible"), s && s.classList.contains("capping__header--visible") && s.classList.remove("capping__header--visible"), a && a.classList.contains("capping__bottom--visible") && a.classList.remove("capping__bottom--visible"), n && n.classList.contains("ui-collapse--shown") && n.classList.remove("ui-collapse--shown"), o && o.classList.contains("ui-collapse--shown") && o.classList.remove("ui-collapse--shown") | |
}, null !== (y = lmd.user) && void 0 !== y && y.restrictArticlesOlderThan && (e.config.restrictArticlesOlderThan = lmd.user.restrictArticlesOlderThan, e.config.restrictArticlesAccessFunction = function() { | |
const e = document.getElementById("js-capping-old-article"); | |
if (e) { | |
const t = document.getElementById("js-body"); | |
document.querySelector("Main").prepend(e); | |
const n = document.getElementById("js-capping-old-article-header"), | |
o = document.getElementById("js-capping-old-article-wrapper"), | |
i = document.getElementById("js-capping-old-article-content"); | |
t.classList.add("capping--body"), e.classList.add("capping--visible"), i.classList.add("capping__content--visible"), o.classList.add("capping__wrapper--visible"), n.classList.add("capping__header--visible") | |
} | |
}); | |
window.siriusCapping = e, Object(u.a)("https://capping.sirius.press/sdk.v1.0.0.js") | |
} | |
}]); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment