Generate proper URL for unsupported browsers page

Signed-off-by: Julius Härtl <jus@bitgrid.net>

Compile assets

Signed-off-by: nextcloud-command <nextcloud-command@users.noreply.github.com>
This commit is contained in:
Julius Härtl 2022-11-21 14:39:10 +01:00
Родитель 5bf96eecc6
Коммит 61ce0ad293
Не найден ключ, соответствующий данной подписи
Идентификатор ключа GPG: 4C614C6ED2CDE6DF
5 изменённых файлов: 8 добавлений и 7 удалений

Просмотреть файл

@ -19,12 +19,13 @@
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
import { generateUrl } from '@nextcloud/router'
import { supportedBrowsersRegExp } from '../services/BrowsersListService.js'
import browserStorage from '../services/BrowserStorageService.js'
import logger from '../logger.js'
export const browserStorageKey = 'unsupported-browser-ignore'
const redirectPath = '/unsupported'
const redirectPath = generateUrl('/unsupported')
const isBrowserOverridden = browserStorage.getItem(browserStorageKey) === 'true'

4
dist/core-unsupported-browser-redirect.js поставляемый
Просмотреть файл

@ -1,3 +1,3 @@
/*! For license information please see core-unsupported-browser-redirect.js.LICENSE.txt */
!function(){var e,n={25714:function(e,n,r){"use strict";var o,t,i,u=r(81655),l=r(31e3),c=r.n(l),a=r(77727),d=r.n(a),f=(0,u.ZI)({allowHigherVersions:!0,browsers:d()}),s=(c()(d()),(0,r(62556).getBuilder)("core").clearOnLogout().persist().build()),p=r(22200),b=r(17499),h=null===(o=(0,p.getCurrentUser)())?(0,b.IY)().setApp("core").build():(0,b.IY)().setApp("core").setUid(o.uid).build(),v=r(48764).Buffer,w="/unsupported",g="true"===s.getItem("unsupported-browser-ignore");window.TESTING||null!==(t=OC)&&void 0!==t&&null!==(i=t.config)&&void 0!==i&&i.no_unsupported_browser_warning||function(){if(f.test(navigator.userAgent))h.debug("this browser is officially supported ! 🚀");else if(g)h.debug("this browser is NOT supported but has been manually overridden ! ⚠️");else if(-1===window.location.pathname.indexOf(w)){var e=window.location.href.replace(window.location.origin,""),n=v.from(e).toString("base64");history.pushState(null,null,"".concat(w,"?redirect_url=").concat(n)),window.location.reload()}}()},72950:function(){}},r={};function o(e){var t=r[e];if(void 0!==t)return t.exports;var i=r[e]={id:e,loaded:!1,exports:{}};return n[e].call(i.exports,i,i.exports,o),i.loaded=!0,i.exports}o.m=n,o.amdD=function(){throw new Error("define cannot be used indirect")},o.amdO={},e=[],o.O=function(n,r,t,i){if(!r){var u=1/0;for(d=0;d<e.length;d++){r=e[d][0],t=e[d][1],i=e[d][2];for(var l=!0,c=0;c<r.length;c++)(!1&i||u>=i)&&Object.keys(o.O).every((function(e){return o.O[e](r[c])}))?r.splice(c--,1):(l=!1,i<u&&(u=i));if(l){e.splice(d--,1);var a=t();void 0!==a&&(n=a)}}return n}i=i||0;for(var d=e.length;d>0&&e[d-1][2]>i;d--)e[d]=e[d-1];e[d]=[r,t,i]},o.n=function(e){var n=e&&e.__esModule?function(){return e.default}:function(){return e};return o.d(n,{a:n}),n},o.d=function(e,n){for(var r in n)o.o(n,r)&&!o.o(e,r)&&Object.defineProperty(e,r,{enumerable:!0,get:n[r]})},o.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(e){if("object"==typeof window)return window}}(),o.o=function(e,n){return Object.prototype.hasOwnProperty.call(e,n)},o.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},o.nmd=function(e){return e.paths=[],e.children||(e.children=[]),e},o.j=8876,function(){o.b=document.baseURI||self.location.href;var e={8876:0};o.O.j=function(n){return 0===e[n]};var n=function(n,r){var t,i,u=r[0],l=r[1],c=r[2],a=0;if(u.some((function(n){return 0!==e[n]}))){for(t in l)o.o(l,t)&&(o.m[t]=l[t]);if(c)var d=c(o)}for(n&&n(r);a<u.length;a++)i=u[a],o.o(e,i)&&e[i]&&e[i][0](),e[i]=0;return o.O(d)},r=self.webpackChunknextcloud=self.webpackChunknextcloud||[];r.forEach(n.bind(null,0)),r.push=n.bind(null,r.push.bind(r))}(),o.nc=void 0;var t=o.O(void 0,[7874],(function(){return o(25714)}));t=o.O(t)}();
//# sourceMappingURL=core-unsupported-browser-redirect.js.map?v=e0e9eb378fc9bdf8296c
!function(){var e,n={25714:function(e,n,r){"use strict";var o,t,i,u=r(79753),l=r(81655),c=r(31e3),a=r.n(c),d=r(77727),f=r.n(d),s=(0,l.ZI)({allowHigherVersions:!0,browsers:f()}),p=(a()(f()),(0,r(62556).getBuilder)("core").clearOnLogout().persist().build()),b=r(22200),h=r(17499),g=null===(o=(0,b.getCurrentUser)())?(0,h.IY)().setApp("core").build():(0,h.IY)().setApp("core").setUid(o.uid).build(),v=r(48764).Buffer,w=(0,u.generateUrl)("/unsupported"),O="true"===p.getItem("unsupported-browser-ignore");window.TESTING||null!==(t=OC)&&void 0!==t&&null!==(i=t.config)&&void 0!==i&&i.no_unsupported_browser_warning||function(){if(s.test(navigator.userAgent))g.debug("this browser is officially supported ! 🚀");else if(O)g.debug("this browser is NOT supported but has been manually overridden ! ⚠️");else if(-1===window.location.pathname.indexOf(w)){var e=window.location.href.replace(window.location.origin,""),n=v.from(e).toString("base64");history.pushState(null,null,"".concat(w,"?redirect_url=").concat(n)),window.location.reload()}}()},72950:function(){}},r={};function o(e){var t=r[e];if(void 0!==t)return t.exports;var i=r[e]={id:e,loaded:!1,exports:{}};return n[e].call(i.exports,i,i.exports,o),i.loaded=!0,i.exports}o.m=n,o.amdD=function(){throw new Error("define cannot be used indirect")},o.amdO={},e=[],o.O=function(n,r,t,i){if(!r){var u=1/0;for(d=0;d<e.length;d++){r=e[d][0],t=e[d][1],i=e[d][2];for(var l=!0,c=0;c<r.length;c++)(!1&i||u>=i)&&Object.keys(o.O).every((function(e){return o.O[e](r[c])}))?r.splice(c--,1):(l=!1,i<u&&(u=i));if(l){e.splice(d--,1);var a=t();void 0!==a&&(n=a)}}return n}i=i||0;for(var d=e.length;d>0&&e[d-1][2]>i;d--)e[d]=e[d-1];e[d]=[r,t,i]},o.n=function(e){var n=e&&e.__esModule?function(){return e.default}:function(){return e};return o.d(n,{a:n}),n},o.d=function(e,n){for(var r in n)o.o(n,r)&&!o.o(e,r)&&Object.defineProperty(e,r,{enumerable:!0,get:n[r]})},o.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(e){if("object"==typeof window)return window}}(),o.o=function(e,n){return Object.prototype.hasOwnProperty.call(e,n)},o.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},o.nmd=function(e){return e.paths=[],e.children||(e.children=[]),e},o.j=8876,function(){o.b=document.baseURI||self.location.href;var e={8876:0};o.O.j=function(n){return 0===e[n]};var n=function(n,r){var t,i,u=r[0],l=r[1],c=r[2],a=0;if(u.some((function(n){return 0!==e[n]}))){for(t in l)o.o(l,t)&&(o.m[t]=l[t]);if(c)var d=c(o)}for(n&&n(r);a<u.length;a++)i=u[a],o.o(e,i)&&e[i]&&e[i][0](),e[i]=0;return o.O(d)},r=self.webpackChunknextcloud=self.webpackChunknextcloud||[];r.forEach(n.bind(null,0)),r.push=n.bind(null,r.push.bind(r))}(),o.nc=void 0;var t=o.O(void 0,[7874],(function(){return o(25714)}));t=o.O(t)}();
//# sourceMappingURL=core-unsupported-browser-redirect.js.map?v=22e284cc4a754bfd50a8

Различия файлов скрыты, потому что одна или несколько строк слишком длинны

4
dist/core-unsupported-browser.js поставляемый

Различия файлов скрыты, потому что одна или несколько строк слишком длинны

2
dist/core-unsupported-browser.js.map поставляемый

Различия файлов скрыты, потому что одна или несколько строк слишком длинны