mirror of
https://github.com/mozilla/pdf.js.git
synced 2025-04-19 22:58:07 +02:00
[Editor] Add a color picker with predefined colors for highlighting text (bug 1866434)
The doorhanger for highlighting has a basic color picker composed of 5 predefined colors to set the default color to use. These colors can be changed thanks to a preference for now but it's something which could be changed in the Firefox settings in the future. Each highlight has in its own toolbar a color picker to just change its color. The different color pickers are so similar (modulo few differences in their styles) that this patch introduces a new class ColorPicker which provides a color picker component which could be reused in future editors. All in all, a large part of this patch is dedicated to color picker itself and its style and the rest is almost a matter of wiring the component.
This commit is contained in:
parent
c0436013a0
commit
ff23d37fa2
22 changed files with 573 additions and 87 deletions
|
@ -332,6 +332,8 @@ pdfjs-editor-remove-freetext-button =
|
|||
.title = Remove text
|
||||
pdfjs-editor-remove-stamp-button =
|
||||
.title = Remove image
|
||||
pdfjs-editor-remove-highlight-button =
|
||||
.title = Remove highlight
|
||||
|
||||
##
|
||||
|
||||
|
@ -384,3 +386,23 @@ pdfjs-editor-resizer-label-bottom-right = Bottom right corner — resize
|
|||
pdfjs-editor-resizer-label-bottom-middle = Bottom middle — resize
|
||||
pdfjs-editor-resizer-label-bottom-left = Bottom left corner — resize
|
||||
pdfjs-editor-resizer-label-middle-left = Middle left — resize
|
||||
|
||||
## Color picker
|
||||
|
||||
# This means "Color used to highlight text"
|
||||
pdfjs-editor-highlight-colorpicker-label = Highlight color
|
||||
|
||||
pdfjs-editor-colorpicker-button =
|
||||
.title = Change color
|
||||
pdfjs-editor-colorpicker-dropdown =
|
||||
.aria-label = Color choices
|
||||
pdfjs-editor-colorpicker-yellow =
|
||||
.title = Yellow
|
||||
pdfjs-editor-colorpicker-green =
|
||||
.title = Green
|
||||
pdfjs-editor-colorpicker-blue =
|
||||
.title = Blue
|
||||
pdfjs-editor-colorpicker-pink =
|
||||
.title = Pink
|
||||
pdfjs-editor-colorpicker-red =
|
||||
.title = Red
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue