Giter Site home page Giter Site logo

nytimes / document-viewer Goto Github PK

View Code? Open in Web Editor NEW
310.0 310.0 162.0 818 KB

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

JavaScript 100.00%

document-viewer's People

Contributors

amclean avatar bkoski avatar jashkenas avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

document-viewer's Issues

Mini-Mode.

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...

Stop polling the DOM.

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.

page-width / scrolling for iPad

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.

How to create input data in JSON?

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?

Brittle and Inefficient CSS Selectors for state changes

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.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.