We wrote a Firefox extension that captures the image of the viewed web page and sends it to a server. The user can choose in which of his own categories the image will go (or create a new one). We need the same extension for Chrome, and possibly for Safari.
The existing Firefox extension is available on [url removed, login to view] (in French, press the "Installer DumBook dans Firefox" button to install the extension, then you'll have to register to use it). The source code is available on demand. It's written in HAML/SASS/CoffeeScript with Middleman to build it. It uses the Mozilla Add-on SDK.
We would like all these extensions share a maximum of code (to minimize maintenance and evolution costs), so rewriting or porting the current Firefox extension to a better suited build stack is possible.
The extension must add an icon on the browser tool bar on each page. When the user clicks on it, the extension must send an HTTP request to the main website with the user's cookies so that if the user is already logged in on the main website, the API requests will be correctly authenticated. If he's not logged in the extension will just ask him to log in by sending him to the login page of the main website. That's how the Firefox extension works. If this is not possible on Chrome then the extension must display a login form and get a token to authenticate future requests. But that should be avoided if possible so that users only have to log in once.
The request made when the user clicks returns the list of categories available to the user along with some meta data. The extension must then display a panel with:
* a capture of the current web page. On Firefox it's possible to capture the whole page but it doesn't seem easily feasible on Chrome (issue 45209) so taking only the visible part is ok. On this image the user must be able to select only a part of the image. By default the visible part is selected.
* a select to choose in which category the image must go. The user can choose to create a new one by providing a name.
* a button to submit. The image is sent in a JSON HTTP request as data URL along with some meta data like the title and URL of the page. If it's not possible to generate a data-url we can update the server to also handle another format (like a multipart form).
* a button to visit the selected category that just opens a new tab on the view URL associated with the category
* a button to share the selected category that also opens a new tab on a category specific URL
The extension must be in English but easily translatable.