-
-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: add support for color, fill and fontSize styles on <Text> elements
Fixes #46
- Loading branch information
Showing
9 changed files
with
249 additions
and
192 deletions.
There are no files selected for viewing
Binary file not shown.
Binary file not shown.
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
// The base font size that will be used for text | ||
export const BASE_FONT_SIZE = 11; | ||
|
||
// These should match the supported attributes in react-pdf | ||
// See: https://react-pdf.org/svg#presentation-attributes | ||
export const PRESENTATION_ATTRIBUTES = [ | ||
'color', | ||
'dominantBaseline', | ||
'fill', | ||
'fillOpacity', | ||
'fillRule', | ||
'opacity', | ||
'stroke', | ||
'strokeWidth', | ||
'strokeOpacity', | ||
'strokeLinecap', | ||
'strokeDasharray', | ||
'transform', | ||
'textAnchor', | ||
'visibility', | ||
]; |
Oops, something went wrong.