mirror of
https://github.com/lrsjng/h5ai.git
synced 2025-05-30 06:55:16 -04:00
Adds no-browser fallback.
This commit is contained in:
parent
a4e599034e
commit
a076dfc7d3
6 changed files with 13 additions and 15 deletions
|
@ -45,13 +45,14 @@
|
||||||
color: @col-error;
|
color: @col-error;
|
||||||
margin-left: 16px;
|
margin-left: 16px;
|
||||||
}
|
}
|
||||||
.unsupportedBrowserMsg {
|
.noBrowserMsg {
|
||||||
display: none;
|
display: none;
|
||||||
color: @col-error;
|
color: @col-error;
|
||||||
margin-left: 16px;
|
margin-left: 16px;
|
||||||
a, a:active, a:visited {
|
a, a:active, a:visited {
|
||||||
color: @col-error;
|
color: @col-error;
|
||||||
text-decoration: underline;
|
text-decoration: underline;
|
||||||
|
opacity: 1;
|
||||||
&:hover {
|
&:hover {
|
||||||
color: @col-hover;
|
color: @col-hover;
|
||||||
}
|
}
|
||||||
|
|
|
@ -51,11 +51,6 @@ body {
|
||||||
html.js .hideOnJs, html.no-js .hideOnNoJs {
|
html.js .hideOnJs, html.no-js .hideOnNoJs {
|
||||||
display: none;
|
display: none;
|
||||||
}
|
}
|
||||||
html.oldie {
|
html.no-browser .noBrowserMsg {
|
||||||
.unsupportedBrowserMsg {
|
display: inline !important;
|
||||||
display: inline !important;
|
|
||||||
}
|
|
||||||
#tree {
|
|
||||||
display: none !important;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -61,8 +61,6 @@
|
||||||
img {
|
img {
|
||||||
width: 16px;
|
width: 16px;
|
||||||
height: 16px;
|
height: 16px;
|
||||||
position: relative;
|
|
||||||
top: -2px;
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
td:nth-child(2), th:nth-child(2) {
|
td:nth-child(2), th:nth-child(2) {
|
||||||
|
|
|
@ -33,7 +33,11 @@
|
||||||
var $ = jQuery,
|
var $ = jQuery,
|
||||||
mode = $('script[src$="scripts.js"]').data('mode');
|
mode = $('script[src$="scripts.js"]').data('mode');
|
||||||
|
|
||||||
if (mode === 'info') {
|
if ($('html').hasClass('no-browser')) {
|
||||||
|
|
||||||
|
$(function () { $('#no-js-fallback').removeClass('hideOnJs'); })
|
||||||
|
|
||||||
|
} else if (mode === 'info') {
|
||||||
|
|
||||||
$(function () { modulejs.require('info'); });
|
$(function () { modulejs.require('info'); });
|
||||||
|
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
doctype 5
|
doctype 5
|
||||||
//if lt IE 9
|
//if lt IE 9
|
||||||
<html class="no-js oldie" lang="en">
|
<html class="no-js no-browser" lang="en">
|
||||||
//[if gt IE 8]><!
|
//[if gt IE 8]><!
|
||||||
html.no-js( lang="en" )
|
html.no-js( lang="en" )
|
||||||
//<![endif]
|
//<![endif]
|
||||||
|
@ -68,7 +68,7 @@ html.no-js( lang="en" )
|
||||||
| {{pkg.name}} {{pkg.version}}
|
| {{pkg.name}} {{pkg.version}}
|
||||||
span.hideOnJs.noJsMsg
|
span.hideOnJs.noJsMsg
|
||||||
| ⚡ JavaScript disabled! ⚡
|
| ⚡ JavaScript disabled! ⚡
|
||||||
span.unsupportedBrowserMsg
|
span.noBrowserMsg
|
||||||
| ⚡ Unsupported browser! Works best in
|
| ⚡ Unsupported browser! Works best in
|
||||||
a( href="http://browsehappy.com" ) modern browsers
|
a( href="http://browsehappy.com" ) modern browsers
|
||||||
| . ⚡
|
| . ⚡
|
||||||
|
|
|
@ -4,7 +4,7 @@
|
||||||
|
|
||||||
doctype 5
|
doctype 5
|
||||||
//if lt IE 9
|
//if lt IE 9
|
||||||
<html class="no-js oldie" lang="en">
|
<html class="no-js no-browser" lang="en">
|
||||||
//[if gt IE 8]><!
|
//[if gt IE 8]><!
|
||||||
html.no-js( lang="en" )
|
html.no-js( lang="en" )
|
||||||
//<![endif]
|
//<![endif]
|
||||||
|
@ -32,7 +32,7 @@ html.no-js( lang="en" )
|
||||||
| {{pkg.name}} {{pkg.version}}
|
| {{pkg.name}} {{pkg.version}}
|
||||||
span.hideOnJs.noJsMsg
|
span.hideOnJs.noJsMsg
|
||||||
| ⚡ JavaScript disabled! ⚡
|
| ⚡ JavaScript disabled! ⚡
|
||||||
span.unsupportedBrowserMsg
|
span.noBrowserMsg
|
||||||
| ⚡ Unsupported browser! Works best in
|
| ⚡ Unsupported browser! Works best in
|
||||||
a( href="http://browsehappy.com" ) modern browsers
|
a( href="http://browsehappy.com" ) modern browsers
|
||||||
| . ⚡
|
| . ⚡
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue