mirror of
https://github.com/gorhill/uBlock.git
synced 2024-09-02 17:19:38 +02:00
this fixes #172
This commit is contained in:
parent
e811fd2958
commit
8accb1f347
@ -32,8 +32,8 @@
|
||||
"description":"appears as tab name in dashboard."
|
||||
},
|
||||
"popupPowerSwitchInfo":{
|
||||
"message":"click the power button to <br>permanently disable or enable <br>µBlock for the current site",
|
||||
"description":"English (mind the horizontal extent): click the power button to <br>permanently disable or enable <br>µBlock for the current site"
|
||||
"message":"Click: permanently disable/enable µBlock for this site.\n\n<Ctrl>-click: disable µBlock only on this page.",
|
||||
"description":"English: Click: permanently disable/enable µBlock for this site.\n\n<Ctrl>-click: disable µBlock only on this page."
|
||||
},
|
||||
"popupBlockedRequestPrompt":{
|
||||
"message":"requests blocked",
|
||||
|
@ -14,4 +14,47 @@
|
||||
}
|
||||
#dashboard-nav-widgets {
|
||||
direction: __MSG_@@bidi_dir__;
|
||||
}
|
||||
}
|
||||
|
||||
/* https://developer.mozilla.org/en-US/docs/Web/CSS/::after#Tooltips */
|
||||
*[data-tip] {
|
||||
cursor: pointer;
|
||||
position: relative;
|
||||
}
|
||||
*[data-tip]:hover:after {
|
||||
background-color: #ffffee;
|
||||
border: 1px solid gray;
|
||||
border-radius: 3px;
|
||||
box-shadow: 1px 1px 3px gray;
|
||||
color: black;
|
||||
content: attr(data-tip);
|
||||
direction: __MSG_@@bidi_dir__;
|
||||
font: 11px sans-serif;
|
||||
left: 0;
|
||||
line-height: 130%;
|
||||
min-width: 55vw;
|
||||
padding: 4px 6px;
|
||||
position: absolute;
|
||||
text-align: __MSG_@@bidi_start_edge__;
|
||||
top: 110%;
|
||||
white-space: pre-line;
|
||||
z-index: 20;
|
||||
animation: tooltip 0.8s;
|
||||
-webkit-animation: tooltip 0.8s;
|
||||
}
|
||||
*[data-tip][data-tip-anchor="top"]:hover:after {
|
||||
bottom: 105%;
|
||||
__MSG_@@bidi_start_edge__: auto;
|
||||
__MSG_@@bidi_end_edge__: -10vw;
|
||||
top: auto;
|
||||
}
|
||||
@keyframes tooltip {
|
||||
0% { opacity: 0; }
|
||||
85% { opacity: 0; }
|
||||
100% { opacity: 1; }
|
||||
}
|
||||
@-webkit-keyframes tooltip {
|
||||
0% { opacity: 0; }
|
||||
85% { opacity: 0; }
|
||||
100% { opacity: 1; }
|
||||
}
|
||||
|
@ -5,6 +5,7 @@ body {
|
||||
font: 13px sans-serif;
|
||||
background-color: white;
|
||||
direction: __MSG_@@bidi_dir__;
|
||||
min-width: 160px;
|
||||
}
|
||||
h1,h2,h3,h4 {
|
||||
margin: 0;
|
||||
@ -36,7 +37,8 @@ p {
|
||||
text-align: center;
|
||||
}
|
||||
#switch .fa {
|
||||
font-size: 64px;
|
||||
margin: 0;
|
||||
font-size: 96px;
|
||||
color: green;
|
||||
cursor: pointer;
|
||||
}
|
||||
@ -74,11 +76,3 @@ p {
|
||||
.tool:hover {
|
||||
color: #444;
|
||||
}
|
||||
#options {
|
||||
margin: 16px 0 0 0;
|
||||
font-size: 12px;
|
||||
}
|
||||
.dim {
|
||||
color: #888;
|
||||
text-decoration: none;
|
||||
}
|
||||
|
@ -31,4 +31,10 @@ uDom.onLoad(function() {
|
||||
this.setAttribute('title', title);
|
||||
}
|
||||
});
|
||||
uDom('[data-i18n-tip]').forEach(function() {
|
||||
this.setAttribute(
|
||||
'data-tip',
|
||||
chrome.i18n.getMessage(this.getAttribute('data-i18n-tip')).replace(/<br>/g, '')
|
||||
);
|
||||
});
|
||||
});
|
||||
|
10
popup.html
10
popup.html
@ -11,10 +11,14 @@
|
||||
<body>
|
||||
<h4 title="popupTipDashboard">µBlock<span id="version"></span></h4>
|
||||
<div>
|
||||
<p id="switch"><span class="fa"></span></p>
|
||||
<p id="switch-hint" data-i18n="popupPowerSwitchInfo"></p>
|
||||
<p id="switch" data-i18n-tip="popupPowerSwitchInfo"><span class="fa"></span></p>
|
||||
<p id="switch-hint"></p>
|
||||
<p style="font-size: 16px;" data-i18n="popupBlockedRequestPrompt"></p>
|
||||
<p id="stats"><span data-i18n="popupBlockedOnThisPagePrompt"></span> <span id="gotoPick" class="fa tool" title="popupTipPicker"></span> <span id="gotoLog" class="fa tool" title="popupTipLog"></span></p>
|
||||
<p id="stats">
|
||||
<span data-i18n="popupBlockedOnThisPagePrompt"></span> 
|
||||
<span id="gotoPick" class="fa tool" data-i18n-tip="popupTipPicker" data-tip-anchor="top"></span> 
|
||||
<span id="gotoLog" class="fa tool" data-i18n-tip="popupTipLog" data-tip-anchor="top"></span>
|
||||
</p>
|
||||
<p id="page-blocked">?</p>
|
||||
<p id="stats" data-i18n="popupBlockedSinceInstallPrompt"></p>
|
||||
<p id="total-blocked">?</p>
|
||||
|
Loading…
Reference in New Issue
Block a user