mirror of
https://github.com/mozilla/pdf.js.git
synced 2025-04-26 10:08:06 +02:00
parent
f1a9bc93f7
commit
f3d1f20652
4 changed files with 185 additions and 0 deletions
57
examples/text-selection/css/minimal.css
Normal file
57
examples/text-selection/css/minimal.css
Normal file
|
@ -0,0 +1,57 @@
|
|||
body {
|
||||
font-family: arial, verdana, sans-serif;
|
||||
}
|
||||
|
||||
.pdf-content {
|
||||
border: 1px solid #000000;
|
||||
}
|
||||
|
||||
/* CSS classes used by TextLayerBuilder to style the text layer divs */
|
||||
|
||||
/* This stuff is important! Otherwise when you select the text, the text in the divs will show up! */
|
||||
::selection { background:rgba(0,0,255,0.3); }
|
||||
::-moz-selection { background:rgba(0,0,255,0.3); }
|
||||
|
||||
.textLayer {
|
||||
position: absolute;
|
||||
left: 0;
|
||||
top: 0;
|
||||
right: 0;
|
||||
bottom: 0;
|
||||
color: #000;
|
||||
font-family: sans-serif;
|
||||
overflow: hidden;
|
||||
}
|
||||
|
||||
.textLayer > div {
|
||||
color: transparent;
|
||||
position: absolute;
|
||||
line-height: 1;
|
||||
white-space: pre;
|
||||
cursor: text;
|
||||
}
|
||||
|
||||
.textLayer .highlight {
|
||||
margin: -1px;
|
||||
padding: 1px;
|
||||
|
||||
background-color: rgba(180, 0, 170, 0.2);
|
||||
border-radius: 4px;
|
||||
}
|
||||
|
||||
.textLayer .highlight.begin {
|
||||
border-radius: 4px 0px 0px 4px;
|
||||
}
|
||||
|
||||
.textLayer .highlight.end {
|
||||
border-radius: 0px 4px 4px 0px;
|
||||
}
|
||||
|
||||
.textLayer .highlight.middle {
|
||||
border-radius: 0px;
|
||||
}
|
||||
|
||||
.textLayer .highlight.selected {
|
||||
background-color: rgba(0, 100, 0, 0.2);
|
||||
}
|
||||
|
Loading…
Add table
Add a link
Reference in a new issue