-
Notifications
You must be signed in to change notification settings - Fork 10.1k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Improves rendering performance of annotation layers.
This change does the following: * Address TODO to remove getEmptyContainer helper. * Not set container bg-color. The old code is incorrect, causing it to not have any effect. It sets color to an array (item.color) rather css string. Also in most cases it would set it to black background which is incorrect. * only add border instructions when there is actually a border * reduce memory consumption by not creating new 3 element arrays for annotation colors. In fact according to spec, this would be incorrect, as the default should be "transparent". Note that only Link annotations were actually setting a border style and color. While Text annotations might have calculated a border they did not color it. This behaviour is now controlled by the boolean flag.
- Loading branch information
1 parent
01cf219
commit 3c17063
Showing
2 changed files
with
33 additions
and
31 deletions.
There are no files selected for viewing
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