From 86453a4337f54cb8f9981a5eee09481f0f485666 Mon Sep 17 00:00:00 2001 From: Bailey Brightman Date: Fri, 27 Nov 2020 16:05:34 -0400 Subject: [PATCH 01/34] Container plugin functional --- dist/SpringRoll-Container-umd.js | 2 +- dist/SpringRoll-Container-umd.js.map | 2 +- dist/SpringRoll-umd.js | 2 + dist/SpringRoll-umd.js.map | 1 + dist/SpringRoll.js | 2 + dist/SpringRoll.js.map | 1 + dist/index.js | 2 +- dist/index.js.map | 2 +- e2e/client.js.map | 2 +- package-lock.json | 676 +++- package.json | 4 +- src/plugins/fullscreenPlugin.js | 50 + src/plugins/fullscreenPlugin/README.md | 0 src/plugins/index.js | 1 + yarn.lock | 4271 ++++++++++++++++++++++++ 15 files changed, 4903 insertions(+), 115 deletions(-) create mode 100644 dist/SpringRoll-umd.js create mode 100644 dist/SpringRoll-umd.js.map create mode 100644 dist/SpringRoll.js create mode 100644 dist/SpringRoll.js.map create mode 100644 src/plugins/fullscreenPlugin.js create mode 100644 src/plugins/fullscreenPlugin/README.md create mode 100644 yarn.lock diff --git a/dist/SpringRoll-Container-umd.js b/dist/SpringRoll-Container-umd.js index e59a1c5c..6166cbe4 100644 --- a/dist/SpringRoll-Container-umd.js +++ b/dist/SpringRoll-Container-umd.js @@ -1,2 +1,2 @@ -!function(t,e){"object"==typeof exports&&"undefined"!=typeof module?e(exports):"function"==typeof define&&define.amd?define(["exports"],e):e((t=t||self).springroll=t.springroll||{})}(this,function(t){"use strict";var e={searchParams:"URLSearchParams"in self,iterable:"Symbol"in self&&"iterator"in Symbol,blob:"FileReader"in self&&"Blob"in self&&function(){try{return new Blob,!0}catch(t){return!1}}(),formData:"FormData"in self,arrayBuffer:"ArrayBuffer"in self};if(e.arrayBuffer)var n=["[object Int8Array]","[object Uint8Array]","[object Uint8ClampedArray]","[object Int16Array]","[object Uint16Array]","[object Int32Array]","[object Uint32Array]","[object Float32Array]","[object Float64Array]"],r=ArrayBuffer.isView||function(t){return t&&n.indexOf(Object.prototype.toString.call(t))>-1};function i(t){if("string"!=typeof t&&(t=String(t)),/[^a-z0-9\-#$%&'*+.^_`|~]/i.test(t))throw new TypeError("Invalid character in header field name");return t.toLowerCase()}function o(t){return"string"!=typeof t&&(t=String(t)),t}function s(t){var n={next:function(){var e=t.shift();return{done:void 0===e,value:e}}};return e.iterable&&(n[Symbol.iterator]=function(){return n}),n}function a(t){this.map={},t instanceof a?t.forEach(function(t,e){this.append(e,t)},this):Array.isArray(t)?t.forEach(function(t){this.append(t[0],t[1])},this):t&&Object.getOwnPropertyNames(t).forEach(function(e){this.append(e,t[e])},this)}function u(t){if(t.bodyUsed)return Promise.reject(new TypeError("Already read"));t.bodyUsed=!0}function l(t){return new Promise(function(e,n){t.onload=function(){e(t.result)},t.onerror=function(){n(t.error)}})}function c(t){var e=new FileReader,n=l(e);return e.readAsArrayBuffer(t),n}function f(t){if(t.slice)return t.slice(0);var e=new Uint8Array(t.byteLength);return e.set(new Uint8Array(t)),e.buffer}function h(){return this.bodyUsed=!1,this._initBody=function(t){var n;this._bodyInit=t,t?"string"==typeof t?this._bodyText=t:e.blob&&Blob.prototype.isPrototypeOf(t)?this._bodyBlob=t:e.formData&&FormData.prototype.isPrototypeOf(t)?this._bodyFormData=t:e.searchParams&&URLSearchParams.prototype.isPrototypeOf(t)?this._bodyText=t.toString():e.arrayBuffer&&e.blob&&((n=t)&&DataView.prototype.isPrototypeOf(n))?(this._bodyArrayBuffer=f(t.buffer),this._bodyInit=new Blob([this._bodyArrayBuffer])):e.arrayBuffer&&(ArrayBuffer.prototype.isPrototypeOf(t)||r(t))?this._bodyArrayBuffer=f(t):this._bodyText=t=Object.prototype.toString.call(t):this._bodyText="",this.headers.get("content-type")||("string"==typeof t?this.headers.set("content-type","text/plain;charset=UTF-8"):this._bodyBlob&&this._bodyBlob.type?this.headers.set("content-type",this._bodyBlob.type):e.searchParams&&URLSearchParams.prototype.isPrototypeOf(t)&&this.headers.set("content-type","application/x-www-form-urlencoded;charset=UTF-8"))},e.blob&&(this.blob=function(){var t=u(this);if(t)return t;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(){return this._bodyArrayBuffer?u(this)||Promise.resolve(this._bodyArrayBuffer):this.blob().then(c)}),this.text=function(){var t,e,n,r=u(this);if(r)return r;if(this._bodyBlob)return t=this._bodyBlob,e=new FileReader,n=l(e),e.readAsText(t),n;if(this._bodyArrayBuffer)return Promise.resolve(function(t){for(var e=new Uint8Array(t),n=new Array(e.length),r=0;r-1?r:n),this.mode=e.mode||this.mode||null,this.signal=e.signal||this.signal,this.referrer=null,("GET"===this.method||"HEAD"===this.method)&&i)throw new TypeError("Body not allowed for GET or HEAD requests");this._initBody(i)}function v(t){var e=new FormData;return t.trim().split("&").forEach(function(t){if(t){var n=t.split("="),r=n.shift().replace(/\+/g," "),i=n.join("=").replace(/\+/g," ");e.append(decodeURIComponent(r),decodeURIComponent(i))}}),e}function y(t,e){e||(e={}),this.type="default",this.status=void 0===e.status?200:e.status,this.ok=this.status>=200&&this.status<300,this.statusText="statusText"in e?e.statusText:"OK",this.headers=new a(e.headers),this.url=e.url||"",this._initBody(t)}p.prototype.clone=function(){return new p(this,{body:this._bodyInit})},h.call(p.prototype),h.call(y.prototype),y.prototype.clone=function(){return new y(this._bodyInit,{status:this.status,statusText:this.statusText,headers:new a(this.headers),url:this.url})},y.error=function(){var t=new y(null,{status:0,statusText:""});return t.type="error",t};var g=[301,302,303,307,308];y.redirect=function(t,e){if(-1===g.indexOf(e))throw new RangeError("Invalid status code");return new y(null,{status:e,headers:{location:t}})};var m=self.DOMException;try{new m}catch(t){(m=function(t,e){this.message=t,this.name=e;var n=Error(t);this.stack=n.stack}).prototype=Object.create(Error.prototype),m.prototype.constructor=m}function b(t,n){return new Promise(function(r,i){var o=new p(t,n);if(o.signal&&o.signal.aborted)return i(new m("Aborted","AbortError"));var s=new XMLHttpRequest;function u(){s.abort()}s.onload=function(){var t,e,n={status:s.status,statusText:s.statusText,headers:(t=s.getAllResponseHeaders()||"",e=new a,t.replace(/\r?\n[\t ]+/g," ").split(/\r?\n/).forEach(function(t){var n=t.split(":"),r=n.shift().trim();if(r){var i=n.join(":").trim();e.append(r,i)}}),e)};n.url="responseURL"in s?s.responseURL:n.headers.get("X-Request-URL");var i="response"in s?s.response:s.responseText;r(new y(i,n))},s.onerror=function(){i(new TypeError("Network request failed"))},s.ontimeout=function(){i(new TypeError("Network request failed"))},s.onabort=function(){i(new m("Aborted","AbortError"))},s.open(o.method,o.url,!0),"include"===o.credentials?s.withCredentials=!0:"omit"===o.credentials&&(s.withCredentials=!1),"responseType"in s&&e.blob&&(s.responseType="blob"),o.headers.forEach(function(t,e){s.setRequestHeader(e,t)}),o.signal&&(o.signal.addEventListener("abort",u),s.onreadystatechange=function(){4===s.readyState&&o.signal.removeEventListener("abort",u)}),s.send(void 0===o._bodyInit?null:o._bodyInit)})}b.polyfill=!0,self.fetch||(self.fetch=b,self.Headers=a,self.Request=p,self.Response=y);var S="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{};function w(t,e){return t(e={exports:{}},e.exports),e.exports}var k=function(t){return t&&t.Math==Math&&t},E=k("object"==typeof globalThis&&globalThis)||k("object"==typeof window&&window)||k("object"==typeof self&&self)||k("object"==typeof S&&S)||Function("return this")(),x={CSSRuleList:0,CSSStyleDeclaration:0,CSSValueList:0,ClientRectList:0,DOMRectList:0,DOMStringList:0,DOMTokenList:1,DataTransferItemList:0,FileList:0,HTMLAllCollection:0,HTMLCollection:0,HTMLFormElement:0,HTMLSelectElement:0,MediaList:0,MimeTypeArray:0,NamedNodeMap:0,NodeList:1,PaintRequestList:0,Plugin:0,PluginArray:0,SVGLengthList:0,SVGNumberList:0,SVGPathSegList:0,SVGPointList:0,SVGStringList:0,SVGTransformList:0,SourceBufferList:0,StyleSheetList:0,TextTrackCueList:0,TextTrackList:0,TouchList:0},P=function(t){if("function"!=typeof t)throw TypeError(String(t)+" is not a function");return t},L=function(t,e,n){if(P(t),void 0===e)return t;switch(n){case 0:return function(){return t.call(e)};case 1:return function(n){return t.call(e,n)};case 2:return function(n,r){return t.call(e,n,r)};case 3:return function(n,r,i){return t.call(e,n,r,i)}}return function(){return t.apply(e,arguments)}},_=function(t){try{return!!t()}catch(t){return!0}},C={}.toString,B=function(t){return C.call(t).slice(8,-1)},O="".split,A=_(function(){return!Object("z").propertyIsEnumerable(0)})?function(t){return"String"==B(t)?O.call(t,""):Object(t)}:Object,V=function(t){if(null==t)throw TypeError("Can't call method on "+t);return t},T=function(t){return Object(V(t))},M=Math.ceil,j=Math.floor,R=function(t){return isNaN(t=+t)?0:(t>0?j:M)(t)},N=Math.min,F=function(t){return t>0?N(R(t),9007199254740991):0},K=function(t){return"object"==typeof t?null!==t:"function"==typeof t},I=Array.isArray||function(t){return"Array"==B(t)},D=!_(function(){return 7!=Object.defineProperty({},1,{get:function(){return 7}})[1]}),G=E.document,U=K(G)&&K(G.createElement),z=function(t){return U?G.createElement(t):{}},H=!D&&!_(function(){return 7!=Object.defineProperty(z("div"),"a",{get:function(){return 7}}).a}),q=function(t){if(!K(t))throw TypeError(String(t)+" is not an object");return t},W=function(t,e){if(!K(t))return t;var n,r;if(e&&"function"==typeof(n=t.toString)&&!K(r=n.call(t)))return r;if("function"==typeof(n=t.valueOf)&&!K(r=n.call(t)))return r;if(!e&&"function"==typeof(n=t.toString)&&!K(r=n.call(t)))return r;throw TypeError("Can't convert object to primitive value")},X=Object.defineProperty,Y={f:D?X:function(t,e,n){if(q(t),e=W(e,!0),q(n),H)try{return X(t,e,n)}catch(t){}if("get"in n||"set"in n)throw TypeError("Accessors not supported");return"value"in n&&(t[e]=n.value),t}},$=function(t,e){return{enumerable:!(1&t),configurable:!(2&t),writable:!(4&t),value:e}},J=D?function(t,e,n){return Y.f(t,e,$(1,n))}:function(t,e,n){return t[e]=n,t},Q=function(t,e){try{J(E,t,e)}catch(n){E[t]=e}return e},Z=E["__core-js_shared__"]||Q("__core-js_shared__",{}),tt=w(function(t){(t.exports=function(t,e){return Z[t]||(Z[t]=void 0!==e?e:{})})("versions",[]).push({version:"3.6.5",mode:"global",copyright:"© 2020 Denis Pushkarev (zloirock.ru)"})}),et={}.hasOwnProperty,nt=function(t,e){return et.call(t,e)},rt=0,it=Math.random(),ot=function(t){return"Symbol("+String(void 0===t?"":t)+")_"+(++rt+it).toString(36)},st=!!Object.getOwnPropertySymbols&&!_(function(){return!String(Symbol())}),at=st&&!Symbol.sham&&"symbol"==typeof Symbol.iterator,ut=tt("wks"),lt=E.Symbol,ct=at?lt:lt&<.withoutSetter||ot,ft=function(t){return nt(ut,t)||(st&&nt(lt,t)?ut[t]=lt[t]:ut[t]=ct("Symbol."+t)),ut[t]},ht=ft("species"),dt=function(t,e){var n;return I(t)&&("function"!=typeof(n=t.constructor)||n!==Array&&!I(n.prototype)?K(n)&&null===(n=n[ht])&&(n=void 0):n=void 0),new(void 0===n?Array:n)(0===e?0:e)},pt=[].push,vt=function(t){var e=1==t,n=2==t,r=3==t,i=4==t,o=6==t,s=5==t||o;return function(a,u,l,c){for(var f,h,d=T(a),p=A(d),v=L(u,l,3),y=F(p.length),g=0,m=c||dt,b=e?m(a,y):n?m(a,0):void 0;y>g;g++)if((s||g in p)&&(h=v(f=p[g],g,d),t))if(e)b[g]=h;else if(h)switch(t){case 3:return!0;case 5:return f;case 6:return g;case 2:pt.call(b,f)}else if(i)return!1;return o?-1:r||i?i:b}},yt={forEach:vt(0),map:vt(1),filter:vt(2),some:vt(3),every:vt(4),find:vt(5),findIndex:vt(6)},gt=function(t,e){var n=[][t];return!!n&&_(function(){n.call(null,e||function(){throw 1},1)})},mt=Object.defineProperty,bt={},St=function(t){throw t},wt=function(t,e){if(nt(bt,t))return bt[t];e||(e={});var n=[][t],r=!!nt(e,"ACCESSORS")&&e.ACCESSORS,i=nt(e,0)?e[0]:St,o=nt(e,1)?e[1]:void 0;return bt[t]=!!n&&!_(function(){if(r&&!D)return!0;var t={length:-1};r?mt(t,1,{enumerable:!0,get:St}):t[1]=1,n.call(t,i,o)})},kt=yt.forEach,Et=gt("forEach"),xt=wt("forEach"),Pt=Et&&xt?[].forEach:function(t){return kt(this,t,arguments.length>1?arguments[1]:void 0)};for(var Lt in x){var _t=E[Lt],Ct=_t&&_t.prototype;if(Ct&&Ct.forEach!==Pt)try{J(Ct,"forEach",Pt)}catch(t){Ct.forEach=Pt}}var Bt,Ot=function(t){return A(V(t))},At=Math.max,Vt=Math.min,Tt=function(t){return function(e,n,r){var i,o=Ot(e),s=F(o.length),a=function(t,e){var n=R(t);return n<0?At(n+e,0):Vt(n,e)}(r,s);if(t&&n!=n){for(;s>a;)if((i=o[a++])!=i)return!0}else for(;s>a;a++)if((t||a in o)&&o[a]===n)return t||a||0;return!t&&-1}},Mt={includes:Tt(!0),indexOf:Tt(!1)},jt={},Rt=Mt.indexOf,Nt=function(t,e){var n,r=Ot(t),i=0,o=[];for(n in r)!nt(jt,n)&&nt(r,n)&&o.push(n);for(;e.length>i;)nt(r,n=e[i++])&&(~Rt(o,n)||o.push(n));return o},Ft=["constructor","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","toLocaleString","toString","valueOf"],Kt=Object.keys||function(t){return Nt(t,Ft)},It=D?Object.defineProperties:function(t,e){q(t);for(var n,r=Kt(e),i=r.length,o=0;i>o;)Y.f(t,n=r[o++],e[n]);return t},Dt=E,Gt=function(t){return"function"==typeof t?t:void 0},Ut=function(t,e){return arguments.length<2?Gt(Dt[t])||Gt(E[t]):Dt[t]&&Dt[t][e]||E[t]&&E[t][e]},zt=Ut("document","documentElement"),Ht=tt("keys"),qt=function(t){return Ht[t]||(Ht[t]=ot(t))},Wt=qt("IE_PROTO"),Xt=function(){},Yt=function(t){return"