diff --git a/index.css b/index.css index f86f028d..58c03f92 100644 --- a/index.css +++ b/index.css @@ -2,7 +2,7 @@ body { margin: 0; } -.animate, .loading { +.animate, .loading, .warning { position: absolute; z-index: 1001; } @@ -79,13 +79,17 @@ body { line-height: 22px; } - .screen { width: 100%; height: 100%; z-index: 1000; } +.warning { + width: 256px; + text-align: justify; +} + body.OxThemeClassic, .OxThemeClassic .screen { background-color: rgb(240, 240, 240); @@ -116,4 +120,4 @@ body.OxThemeModern, } .OxThemeModern .readme .item.selected { background: rgb(32, 32, 32); -} \ No newline at end of file +} diff --git a/index.js b/index.js index f339f4a2..33d9d515 100644 --- a/index.js +++ b/index.js @@ -96,6 +96,11 @@ Ox.load(function() { top: '8px', right: '8px' }; + } else if (element == 'warning') { + css = { + left: center - 128 + 'px', + top: middle + 16 + 'px', + }; } return css; }, @@ -122,7 +127,7 @@ Ox.load(function() { }); }); }, - load: function() { + load: function(browserSupported) { var url = app.url.get(); if (url) { app.user({url: url}) @@ -139,7 +144,19 @@ Ox.load(function() { app.$ui.loading.animate({opacity: 0}, 500, function() { app.$ui.loading.remove(); }); - if (!url) { + if (!browserSupported) { + app.$ui.warning = app.ui.warning() + .css(app.getCSS('warning')) + .appendTo(Ox.$body); + app.$ui.logo + .css({cursor: 'pointer'}) + .one({ + click: function() { + app.$ui.warning.remove(); + app.load(true); + } + }); + } else if (!url) { app.$ui.logo .css({cursor: 'pointer'}) .bind({ @@ -443,6 +460,16 @@ Ox.load(function() { app.setTheme(data.value); } }); + }, + warning: function() { + return $('