documentcloud/document-viewer — Issue #8: "e is undefined" error when using display:none on an embedded player
Author: cadecairos
Created: 2011-12-08 16:27:01+00:00
State: open

I'm creating a DocumentCloud plug-in for Popcorn.js, and this error is proving to be a bit of a blocker in terms of hiding and displaying the players.

The plug-in can insert multiple players into one div and hide/display them successfully with the visibility attribute, but this proves to be a bad choice simply because the hidden players "push" the visible players to the side or down. With in-line display I can make it seem like the hidden players aren't even there.

This is when I get the error. I traced it to a function called sortPages that returns undefined when called in the drawPages function.

Here's a case where the bug is present: http://www.chrisdecairos.ca/projects/documentcloudissue/plugins/documentcloud/popcorn.documentcloud.html

Let me know If I can help with anything, thanks!