core-unsupported-browser.js 8.9 KB

123
  1. /*! For license information please see core-unsupported-browser.js.LICENSE.txt */
  2. !function(){var t,n,e,r={93504:function(t,n,e){"use strict";var r,o=e(79753),i=e(20144),u=e(81655),s=e(31e3),a=e.n(s),c=e(77727),l=e.n(c),f=((0,u.ZI)({allowHigherVersions:!0,browsers:l()}),a()(l())),p=(0,e(62556).getBuilder)("core").clearOnLogout().persist().build(),d=e(45994),v=e(17499),b=null===(r=(0,d.ts)())?(0,v.IY)().setApp("core").build():(0,v.IY)().setApp("core").setUid(r.uid).build(),A=(e(48764).Buffer,"unsupported-browser-ignore"),w=((0,o.generateUrl)("/unsupported"),p.getItem(A),e(31352)),g=e(10861),m=e.n(g),y=e(93455),h=e.n(y),_=e(97859),C=e(48764).Buffer;function x(t,n,e,r,o,i,u){try{var s=t[i](u),a=s.value}catch(t){return void e(t)}s.done?n(a):Promise.resolve(a).then(r,o)}function O(t,n){(null==n||n>t.length)&&(n=t.length);for(var e=0,r=new Array(n);e<n;e++)r[e]=t[e];return r}b.debug("Supported browsers",{supportedBrowsers:f});var B={name:"UnsupportedBrowser",components:{Web:_.default,NcButton:m(),NcEmptyContent:h()},data:function(){return{agents:{}}},computed:{isMobile:function(){return/Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(navigator.userAgent)},filteredSupportedBrowsers:function(){var t=this;return f.filter((function(n){return!!n&&(t.isMobile?t.isMobileBrowser(n):!t.isMobileBrowser(n))}))},formattedBrowsersList:function(){var t=this,n={};return this.filteredSupportedBrowsers.forEach((function(t){var e,r,o=(e=t.split(" "),r=2,function(t){if(Array.isArray(t))return t}(e)||function(t,n){var e=null==t?null:"undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(null!=e){var r,o,i,u,s=[],a=!0,c=!1;try{if(i=(e=e.call(t)).next,0===n){if(Object(e)!==e)return;a=!1}else for(;!(a=(r=i.call(e)).done)&&(s.push(r.value),s.length!==n);a=!0);}catch(t){c=!0,o=t}finally{try{if(!a&&null!=e.return&&(u=e.return(),Object(u)!==u))return}finally{if(c)throw o}}return s}}(e,r)||function(t,n){if(t){if("string"==typeof t)return O(t,n);var e=Object.prototype.toString.call(t).slice(8,-1);return"Object"===e&&t.constructor&&(e=t.constructor.name),"Map"===e||"Set"===e?Array.from(t):"Arguments"===e||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(e)?O(t,n):void 0}}(e,r)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()),i=o[0],u=o[1];(!n[i]||n[i]<parseFloat(u,10))&&(n[i]=parseFloat(u,10))})),Object.keys(n).map((function(e){var r,o;if(null===(r=t.agents[e])||void 0===r||!r.browser)return null;var i=n[e],u=null===(o=t.agents[e])||void 0===o?void 0:o.browser;return t.t("core","{name} version {version} and above",{name:u,version:i})})).filter((function(t){return null!==t}))}},beforeMount:function(){var t,n=this;return(t=regeneratorRuntime.mark((function t(){var r,o;return regeneratorRuntime.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,e.e(7874).then(e.t.bind(e,90614,19));case 2:r=t.sent,o=r.agents,n.agents=o;case 5:case"end":return t.stop()}}),t)})),function(){var n=this,e=arguments;return new Promise((function(r,o){var i=t.apply(n,e);function u(t){x(i,r,o,u,s,"next",t)}function s(t){x(i,r,o,u,s,"throw",t)}u(void 0)}))})()},methods:{t:w.Iu,n:w.uN,forceBrowsing:function(){p.setItem(A,!0);var t=new URLSearchParams(window.location.search);if(t.has("redirect_url")){var n=C.from(t.get("redirect_url"),"base64").toString()||"/";if(n.startsWith("/"))return void(window.location=(0,o.generateUrl)(n))}window.location=(0,o.generateUrl)("/")},isMobileBrowser:function(t){return(t=t.toLowerCase()).includes("and_")||t.includes("android")||t.includes("ios_")||t.includes("mobile")||t.includes("_mob")||t.includes("samsung")}}},j=B,S=e(93379),k=e.n(S),P=e(7795),I=e.n(P),M=e(90569),U=e.n(M),T=e(3565),E=e.n(T),R=e(19216),Z=e.n(R),$=e(44589),N=e.n($),D=e(26376),F={};F.styleTagTransform=N(),F.setAttributes=E(),F.insert=U().bind(null,"head"),F.domAPI=I(),F.insertStyleElement=Z(),k()(D.Z,F),D.Z&&D.Z.locals&&D.Z.locals;var L=(0,e(51900).Z)(j,(function(){var t=this,n=t._self._c;return n("div",{staticClass:"content-unsupported-browser guest-box"},[n("NcEmptyContent",{scopedSlots:t._u([{key:"icon",fn:function(){return[n("Web")]},proxy:!0},{key:"action",fn:function(){return[n("div",[n("h2",[t._v("\n\t\t\t\t\t"+t._s(t.t("core","Your browser is not supported. Please upgrade to a newer version or a supported one."))+"\n\t\t\t\t")]),t._v(" "),n("NcButton",{staticClass:"content-unsupported-browser__continue",attrs:{type:"primary"},on:{click:t.forceBrowsing}},[t._v("\n\t\t\t\t\t"+t._s(t.t("core","Continue with this unsupported browser"))+"\n\t\t\t\t")])],1),t._v(" "),n("ul",{staticClass:"content-unsupported-browser__list"},[n("h3",[t._v(t._s(t.t("core","Supported versions")))]),t._v(" "),t._l(t.formattedBrowsersList,(function(e){return n("li",{key:e},[t._v("\n\t\t\t\t\t"+t._s(e)+"\n\t\t\t\t")])}))],2)]},proxy:!0}])},[t._v("\n\t\t"+t._s(t.t("core","This browser is not supported"))+"\n\t\t")])],1)}),[],!1,null,"f4ecfa46",null).exports;"true"===p.getItem(A)&&(window.location=(0,o.generateUrl)("/")),new i.ZP({el:"#unsupported-browser",name:"UnsupportedBrowserRoot",render:function(t){return t(L)}})},26376:function(t,n,e){"use strict";var r=e(87537),o=e.n(r),i=e(23645),u=e.n(i)()(o());u.push([t.id,".content-unsupported-browser[data-v-f4ecfa46]{display:flex;justify-content:center;width:400px;max-width:calc(90vw - 60px);margin:auto;padding:30px}.content-unsupported-browser .empty-content[data-v-f4ecfa46]{margin:0}.content-unsupported-browser .empty-content[data-v-f4ecfa46] .empty-content__icon{opacity:1}.content-unsupported-browser__continue[data-v-f4ecfa46]{display:block;margin:30px auto}.content-unsupported-browser__list[data-v-f4ecfa46]{margin-top:60px;margin-bottom:30px}.content-unsupported-browser__list li[data-v-f4ecfa46]{text-align:left}","",{version:3,sources:["webpack://./core/src/views/UnsupportedBrowser.vue"],names:[],mappings:"AAGA,8CACC,YAAA,CACA,sBAAA,CACA,WAAA,CACA,2BAAA,CACA,WAAA,CACA,YARS,CAUT,6DACC,QAAA,CACA,kFACC,SAAA,CAIF,wDACC,aAAA,CACA,gBAAA,CAGD,oDACC,eAAA,CACA,kBAxBQ,CAyBR,uDACC,eAAA",sourcesContent:["\n$spacing: 30px;\n\n.content-unsupported-browser {\n\tdisplay: flex;\n\tjustify-content: center;\n\twidth: 400px;\n\tmax-width: calc(90vw - 2 * $spacing);\n\tmargin: auto;\n\tpadding: $spacing;\n\n\t.empty-content {\n\t\tmargin: 0;\n\t\t&::v-deep .empty-content__icon {\n\t\t\topacity: 1;\n\t\t}\n\t}\n\n\t&__continue {\n\t\tdisplay: block;\n\t\tmargin: $spacing auto;\n\t}\n\n\t&__list {\n\t\tmargin-top: 2 * $spacing;\n\t\tmargin-bottom: $spacing;\n\t\tli {\n\t\t\ttext-align: left;\n\t\t}\n\t}\n}\n\n"],sourceRoot:""}]),n.Z=u},72950:function(){}},o={};function i(t){var n=o[t];if(void 0!==n)return n.exports;var e=o[t]={id:t,loaded:!1,exports:{}};return r[t].call(e.exports,e,e.exports,i),e.loaded=!0,e.exports}i.m=r,t=[],i.O=function(n,e,r,o){if(!e){var u=1/0;for(l=0;l<t.length;l++){e=t[l][0],r=t[l][1],o=t[l][2];for(var s=!0,a=0;a<e.length;a++)(!1&o||u>=o)&&Object.keys(i.O).every((function(t){return i.O[t](e[a])}))?e.splice(a--,1):(s=!1,o<u&&(u=o));if(s){t.splice(l--,1);var c=r();void 0!==c&&(n=c)}}return n}o=o||0;for(var l=t.length;l>0&&t[l-1][2]>o;l--)t[l]=t[l-1];t[l]=[e,r,o]},i.n=function(t){var n=t&&t.__esModule?function(){return t.default}:function(){return t};return i.d(n,{a:n}),n},e=Object.getPrototypeOf?function(t){return Object.getPrototypeOf(t)}:function(t){return t.__proto__},i.t=function(t,r){if(1&r&&(t=this(t)),8&r)return t;if("object"==typeof t&&t){if(4&r&&t.__esModule)return t;if(16&r&&"function"==typeof t.then)return t}var o=Object.create(null);i.r(o);var u={};n=n||[null,e({}),e([]),e(e)];for(var s=2&r&&t;"object"==typeof s&&!~n.indexOf(s);s=e(s))Object.getOwnPropertyNames(s).forEach((function(n){u[n]=function(){return t[n]}}));return u.default=function(){return t},i.d(o,u),o},i.d=function(t,n){for(var e in n)i.o(n,e)&&!i.o(t,e)&&Object.defineProperty(t,e,{enumerable:!0,get:n[e]})},i.e=function(){return Promise.resolve()},i.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(t){if("object"==typeof window)return window}}(),i.o=function(t,n){return Object.prototype.hasOwnProperty.call(t,n)},i.r=function(t){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},i.nmd=function(t){return t.paths=[],t.children||(t.children=[]),t},i.j=9315,function(){i.b=document.baseURI||self.location.href;var t={9315:0};i.O.j=function(n){return 0===t[n]};var n=function(n,e){var r,o,u=e[0],s=e[1],a=e[2],c=0;if(u.some((function(n){return 0!==t[n]}))){for(r in s)i.o(s,r)&&(i.m[r]=s[r]);if(a)var l=a(i)}for(n&&n(e);c<u.length;c++)o=u[c],i.o(t,o)&&t[o]&&t[o][0](),t[o]=0;return i.O(l)},e=self.webpackChunknextcloud=self.webpackChunknextcloud||[];e.forEach(n.bind(null,0)),e.push=n.bind(null,e.push.bind(e))}(),i.nc=void 0;var u=i.O(void 0,[7874],(function(){return i(93504)}));u=i.O(u)}();
  3. //# sourceMappingURL=core-unsupported-browser.js.map?v=37d02b6266ef933e26b0