1
0
mirror of https://github.com/gorhill/uBlock.git synced 2024-09-15 15:32:28 +02:00

hopefully this fixes #1053

This commit is contained in:
gorhill 2015-03-20 10:36:38 -04:00
parent 0e22af516f
commit 669850821a
7 changed files with 49 additions and 24 deletions

View File

@ -10,7 +10,7 @@
<body> <body>
<h2 id="aboutNameVer"></h2> <p id="aboutNameVer"></p>
<ul> <ul>
<li><a href="https://github.com/gorhill/uBlock/releases" data-i18n="aboutChangelog"></a> <li><a href="https://github.com/gorhill/uBlock/releases" data-i18n="aboutChangelog"></a>
<li><a href="https://github.com/gorhill/uBlock/wiki" data-i18n="aboutWiki"></a> <li><a href="https://github.com/gorhill/uBlock/wiki" data-i18n="aboutWiki"></a>

View File

@ -2,9 +2,6 @@ ul {
padding: 0; padding: 0;
list-style-type: none; list-style-type: none;
} }
#options {
margin-top: 0;
}
#options li { #options li {
margin-bottom: 0.5em; margin-bottom: 0.5em;
} }
@ -45,12 +42,14 @@ li.listEntry {
margin: 0 auto 0 auto; margin: 0 auto 0 auto;
margin-left: 1em; margin-left: 1em;
margin-right: 0em; margin-right: 0em;
text-indent: -2em;
} }
body[dir=rtl] li.listEntry { body[dir=rtl] li.listEntry {
margin-left: 0em; margin-left: 0em;
margin-right: 1em; margin-right: 1em;
} }
li.listEntry > * { li.listEntry > * {
text-indent: 0;
unicode-bidi: embed; unicode-bidi: embed;
} }
li.listEntry > a:nth-of-type(2) { li.listEntry > a:nth-of-type(2) {
@ -90,10 +89,12 @@ button.custom.reloadAll:not(.disabled) {
} }
#buttonApply { #buttonApply {
display: initial; display: initial;
margin: 1em 0;
padding: 1em; padding: 1em;
position: fixed; position: fixed;
right: 1em; right: 1em;
top: 0; top: 0;
z-index: 10;
} }
body[dir=rtl] #buttonApply { body[dir=rtl] #buttonApply {
right: auto; right: auto;

View File

@ -1,6 +1,6 @@
body { body {
margin: 0; margin: 0;
padding: 0 0.5em 5em 0.5em; padding: 0 0.5em 0.5em 0.5em;
font: 14px sans-serif; font: 14px sans-serif;
} }
h2, h3 { h2, h3 {
@ -10,9 +10,6 @@ h2, h3 {
h2 { h2 {
font-size: 18px; font-size: 18px;
} }
h2:nth-of-type(1) {
margin-top: 0;
}
h3 { h3 {
font-size: 16px; font-size: 16px;
} }

View File

@ -12,10 +12,8 @@ html, body {
margin: 0; margin: 0;
border: 0; border: 0;
padding: 0; padding: 0;
position: absolute;
width: 100%; width: 100%;
top: 0; top: 0;
height: 50px;
z-index: 10; z-index: 10;
} }
#dashboard-nav-widgets { #dashboard-nav-widgets {
@ -30,20 +28,20 @@ html, body {
font-size: larger; font-size: larger;
} }
.tabButton { .tabButton {
margin: 0; background-color: #eee;
border: 1px solid #ccc; border: 1px solid #ccc;
border-top-left-radius: 3px; border-top-left-radius: 3px;
border-top-right-radius: 3px; border-top-right-radius: 3px;
border-bottom: 1px solid #ccc; border-bottom: 1px solid #ccc;
padding: 4px;
display: inline-block;
position: relative;
top: 1px;
color: black; color: black;
background-color: #eee;
font: inherit;
cursor: pointer; cursor: pointer;
display: inline-block;
font: inherit;
margin: 0;
padding: 4px;
position: relative;
text-decoration: none; text-decoration: none;
top: 1px;
} }
.tabButton:focus { .tabButton:focus {
outline: 0; outline: 0;
@ -52,7 +50,6 @@ html, body {
color: inherited; color: inherited;
} }
.tabButton.selected { .tabButton.selected {
border-bottom: 1px solid white;
background-color: white; background-color: white;
border-bottom: 1px solid white; border-bottom: 1px solid white;
} }
@ -62,8 +59,23 @@ iframe {
padding: 0; padding: 0;
background-color: transparent; background-color: transparent;
width: 100%; width: 100%;
height: 100%; }
border-top: 50px solid transparent;
box-sizing: border-box; @media (max-width: 600px) {
-moz-box-sizing: border-box; #dashboard-nav {
position: relative;
}
#dashboard-nav-widgets {
padding: 0;
}
[data-i18n="extName"] {
display: none;
}
.tabButton {
border-top: 0;
display: block;
}
.tabButton.selected {
border-bottom: 1px solid #ccc;
}
} }

View File

@ -22,7 +22,7 @@
</div> </div>
</div> </div>
<iframe src=""></iframe> <iframe id="iframe" src=""></iframe>
<script src="js/vapi-common.js"></script> <script src="js/vapi-common.js"></script>
<script src="js/udom.js"></script> <script src="js/udom.js"></script>

View File

@ -20,12 +20,21 @@
*/ */
/* global uDom */ /* global uDom */
'use strict';
/******************************************************************************/ /******************************************************************************/
(function() { (function() {
'use strict';
/******************************************************************************/
var resizeFrame = function() {
var navRect = document.getElementById('dashboard-nav').getBoundingClientRect();
var viewRect = document.documentElement.getBoundingClientRect();
document.getElementById('iframe').style.setProperty('height', (viewRect.height - navRect.height) + 'px');
};
/******************************************************************************/ /******************************************************************************/
var loadDashboardPanel = function(tab, q) { var loadDashboardPanel = function(tab, q) {
@ -49,6 +58,9 @@ var onTabClickHandler = function(e) {
/******************************************************************************/ /******************************************************************************/
uDom.onLoad(function() { uDom.onLoad(function() {
window.addEventListener('resize', resizeFrame);
resizeFrame();
var matches = window.location.search.slice(1).match(/\??(tab=([^&]+))?(.*)$/); var matches = window.location.search.slice(1).match(/\??(tab=([^&]+))?(.*)$/);
var tab = '', q = ''; var tab = '', q = '';
if ( matches && matches.length === 4 ) { if ( matches && matches.length === 4 ) {

View File

@ -9,6 +9,9 @@
ul { ul {
padding-left: 1em; padding-left: 1em;
} }
ul#userSettings {
padding-left: 0;
}
li { li {
margin-top: 0.25em; margin-top: 0.25em;
} }