uBlock/src/epicker.html

239 lines
6.5 KiB
HTML

<head>
<meta charset="utf-8">
<title>uBlock Origin Element Picker</title>
<style>
html#ublock0-epicker,
#ublock0-epicker body {
background: transparent !important;
color: black !important;
font: 12px sans-serif !important;
height: 100% !important;
margin: 0 !important;
overflow: hidden !important;
width: 100% !important;
}
#ublock0-epicker :focus {
outline: none !important;
}
#ublock0-epicker ul,
#ublock0-epicker li,
#ublock0-epicker div {
display: block !important;
}
#ublock0-epicker ul {
margin: 0.25em 0 0 0 !important;
}
#ublock0-epicker button {
background-color: #ccc !important;
border: 1px solid #aaa !important;
border-radius: 3px !important;
box-sizing: border-box !important;
box-shadow: none !important;
color: #000 !important;
cursor: pointer !important;
margin: 0 0 0 2px !important;
opacity: 0.7 !important;
padding: 4px 6px !important;
}
#ublock0-epicker button:first-of-type {
margin-left: 0 !important;
}
#ublock0-epicker button:disabled {
color: #999 !important;
background-color: #ccc !important;
}
#ublock0-epicker button:not(:disabled):hover {
opacity: 1 !important;
}
#ublock0-epicker #create:not(:disabled) {
background-color: hsl(36, 100%, 83%) !important;
border-color: hsl(36, 50%, 60%) !important;
}
#ublock0-epicker #preview {
float: left !important;
}
#ublock0-epicker body.preview #preview {
background-color: hsl(204, 100%, 83%) !important;
border-color: hsl(204, 50%, 60%) !important;
}
#ublock0-epicker section {
border: 0 !important;
box-sizing: border-box !important;
display: inline-block !important;
width: 100% !important;
}
#ublock0-epicker section > div:first-child {
border: 1px solid #aaa !important;
margin: 0 !important;
position: relative !important;
}
#ublock0-epicker section.invalidFilter > div:first-child {
border-color: red !important;
}
#ublock0-epicker section > div:first-child > textarea {
background-color: #fff !important;
border: none !important;
box-sizing: border-box !important;
color: #000 !important;
font: 11px monospace !important;
height: 8em !important;
margin: 0 !important;
overflow: hidden !important;
overflow-y: auto !important;
padding: 2px !important;
resize: none !important;
width: 100% !important;
word-break: break-all !important;
}
#ublock0-epicker #resultsetCount {
background-color: #aaa !important;
bottom: 0 !important;
color: white !important;
padding: 2px 4px !important;
position: absolute !important;
right: 0 !important;
}
#ublock0-epicker section.invalidFilter #resultsetCount {
background-color: red !important;
}
#ublock0-epicker section > div:first-child + div {
direction: ltr !important;
margin: 2px 0 !important;
text-align: right !important;
}
#ublock0-epicker ul {
padding: 0 !important;
list-style-type: none !important;
text-align: left !important;
overflow: hidden !important;
}
#ublock0-epicker aside > ul {
max-height: 16em !important;
overflow-y: auto !important;
}
#ublock0-epicker aside > ul > li:first-of-type {
margin-bottom: 0.5em !important;
}
#ublock0-epicker ul > li > span:nth-of-type(1) {
font-weight: bold !important;
}
#ublock0-epicker ul > li > span:nth-of-type(2) {
font-size: smaller !important;
color: gray !important;
}
#ublock0-epicker ul > li > ul {
list-style-type: none !important;
margin: 0 0 0 1em !important;
overflow: hidden !important;
text-align: left !important;
}
#ublock0-epicker ul > li > ul > li {
font: 11px monospace !important;
white-space: nowrap !important;
cursor: pointer !important;
direction: ltr !important;
}
#ublock0-epicker ul > li > ul > li:hover {
background-color: white !important;
}
#ublock0-epicker svg {
position: fixed !important;
top: 0 !important;
left: 0 !important;
cursor: crosshair !important;
width: 100% !important;
height: 100% !important;
}
#ublock0-epicker .paused > svg {
cursor: not-allowed !important;
}
#ublock0-epicker svg > path:first-child {
fill: rgba(0,0,0,0.5) !important;
fill-rule: evenodd !important;
}
#ublock0-epicker svg > path + path {
stroke: #F00 !important;
stroke-width: 0.5px !important;
fill: rgba(255,63,63,0.20) !important;
}
#ublock0-epicker body.zap svg > path + path {
stroke: #FF0 !important;
stroke-width: 0.5px !important;
fill: rgba(255,255,63,0.20) !important;
}
#ublock0-epicker body.preview svg > path {
fill: rgba(0,0,0,0.10) !important;
}
#ublock0-epicker body.preview svg > path + path {
stroke: none !important;
}
#ublock0-epicker aside {
background-color: #eee !important;
border: 1px solid #aaa !important;
bottom: 4px !important;
box-sizing: border-box !important;
min-width: 24em !important;
padding: 4px !important;
position: fixed !important;
right: 4px !important;
visibility: hidden !important;
width: calc(40% - 4px) !important;
}
#ublock0-epicker body.paused > aside {
opacity: 0.1;
visibility: visible !important;
z-index: 100 !important;
}
/**
https://github.com/gorhill/uBlock/issues/3449
https://github.com/uBlockOrigin/uBlock-issues/issues/55
**/
@keyframes startDialog {
0% { opacity: 1.0; }
60% { opacity: 1.0; }
100% { opacity: 0.1; }
}
#ublock0-epicker body.paused > aside:not(:hover):not(.show) {
animation-duration: 1.6s !important;
animation-name: startDialog !important;
animation-timing-function: linear !important;
}
#ublock0-epicker body.paused > aside:hover {
opacity: 1 !important;
}
#ublock0-epicker body.paused > aside.show {
opacity: 1 !important;
}
#ublock0-epicker body.paused > aside.hide {
opacity: 0.1 !important;
}
</style>
</head>
<body direction="{{bidi_dir}}">
<svg><path d></path><path d></path></svg>
<aside>
<section>
<div>
<textarea lang="en" dir="ltr" spellcheck="false"></textarea>
<div id="resultsetCount"></div>
</div>
<div><!--
--><button id="preview" type="button">{{preview}}</button><!--
--><button id="create" type="button" disabled>{{create}}</button><!--
--><button id="pick" type="button">{{pick}}</button><!--
--><button id="quit" type="button">{{quit}}</button><!--
--></div>
</section>
<ul>
<li id="netFilters">
<span>{{netFilters}}</span><ul lang="en" class="changeFilter"></ul>
</li>
<li id="cosmeticFilters">
<span>{{cosmeticFilters}}</span> <span>{{cosmeticFiltersHint}}</span>
<ul lang="en" class="changeFilter"></ul>
</li>
</ul>
</aside>
</body>