1
0
Fork 0
mirror of https://github.com/mozilla/pdf.js.git synced 2025-04-29 15:47:57 +02:00

[editor] Add an Ink editor

- Approximate the drawn curve by a set of Bezier curves in using
  js code from https://github.com/soswow/fit-curves.
  The code has been slightly modified in order to make the linter
  happy.
This commit is contained in:
Calixte Denizet 2022-06-04 23:28:19 +02:00
parent 2fbf14ace8
commit c161a86ba1
14 changed files with 1461 additions and 13 deletions

View file

@ -78,10 +78,45 @@
outline: var(--focus-outline);
}
.annotationEditorLayer .freeTextEditor:hover:not(:focus-within) {
.annotationEditorLayer .inkEditor:not(:focus) {
resize: none;
}
.annotationEditorLayer .freeTextEditor:hover:not(:focus-within),
.annotationEditorLayer .inkEditor:hover:not(:focus) {
outline: var(--hover-outline);
}
.annotationEditorLayer .inkEditor.disabled:focus {
resize: horizontal;
}
.annotationEditorLayer .inkEditor {
position: absolute;
background: transparent;
border-radius: 3px;
overflow: auto;
width: 100%;
height: 100%;
}
.annotationEditorLayer .inkEditor:focus {
outline: var(--focus-outline);
resize: both;
}
.annotationEditorLayer .inkEditor.editing {
resize: none;
}
.annotationEditorLayer .inkEditor .inkEditorCanvas {
position: absolute;
top: 0;
left: 0;
width: 100%;
height: 100%;
}
.annotationEditorLayer .selectedEditor {
outline: var(--focus-outline);
resize: none;