nytimes / document-viewer Goto Github PK
View Code? Open in Web Editor NEWThe NYTimes Document Viewer
Home Page: http://open.blogs.nytimes.com/2010/03/27/a-new-view-introducing-doc-viewer-2-0/
License: Apache License 2.0
The NYTimes Document Viewer
Home Page: http://open.blogs.nytimes.com/2010/03/27/a-new-view-introducing-doc-viewer-2-0/
License: Apache License 2.0
It would be great to have a mini-mode option for DV.load
, which would fit the document viewer into dimensions suitable for embedding in a blog (or blog-style format). A common request. The API could be:
DV.load(doc, {mini: true});
Unless it would be better to have mini-mode be automatically activated by the current width of the viewer...
I am unable to add a new note. Please let me know how to enable this option.
At the moment, we have poll the DOM every 100 milliseconds, doing two things: checking to see if the window dimensions have changed, in order to resize the viewer, and checking to see if the viewer DIV has been scrolled down, and we need to load a new page.
The polling could be removed, and the feel of resizing and scrolling correspondingly tightened up, if we can figure out a way to reliably and performantly work with scroll
and resize
events in a cross-browser fashion.
Now that iPads are starting to spread around, it would be great to have the viewer listen to the appropriate touch events to scroll the page. Currently you have to use the two-fingered-scroll to scroll the viewer.
I am probably just missing out on something here, but my question is:
How do I generate the JSON file, that is needed as input for the document-viewer?
Especially the annotations don't look like something that one would generate by hand.
Is there another project that can used for generating this, and if yes, is that open sourced too?
The selector rules for handling state changes are quite long and fairly brittle should the markup change. Example from view-text.css
.DV-viewText #DV-sidebar #DV-well .DV-chaptersContainer div.DV-hasChildren div.DV-first .DV-trigger{ margin-left:-1px; }
These should be optimized so to ease templating.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.