Skip to content

lobbyradar/lobbyradar-extension

 
 

Repository files navigation

Lobbyradar

Lobbyradar is a Browserextension which uses Data available on lobbyradar.opendatacloud.de Lobbyradar is meant to run on Chrome, Safari and Firefox. It is built using the BabelExt Project. BabelExt simplifies cross-browser development of Extensions. It abstracts Message passing between background- and foreground scripts. Background scripts are run in the Context of the Extension. They have access to the extension data, here: settings and lobbydata. Foreground scripts are injected into the current page and can modify the DOM and interact with the UI. BabelExt comes with an unusual Build-Script based on PhantomJS.

I had to modify BabelExt for lobbyradar, so browser abstraction is somewhat lost.

Directories

lib/: Background and Foreground scripts, settings files (settings.json, local_settings.json) test/: Test-Page with many names and an iframe. Serve this directory with a web server to test your extension. build/: Installable Extensions generated by the build script.

Chrome/: the Chrome-Extension. This Directory is modified by the build script. Safari.safariextension/: the Safari extension. Modified by build script and Safaris extensions builder (Info.plist) Firefox/: the Firefox extension. Modified by Build script and Firefox-SDK.

Do not delete the Extension directories! The build script generates only part of the files.

Files

fg_page.js: Injected into the Page. The same for all Browsers bg_*.js: Background Scripts. One Version for Chrome/Safari, different for Firefox.

Background-scripts for Chrome/Safari are modified in lib/. Background-scripts for Firefox are modified in Firefox/.

I strongly recommend to understand the build script.

Build process

Download PhantomJS (http://phantomjs.org), which is used to build and deploy browser-extensions. You need to have the Chrome Browser installed to build the Chrome extension.

In UNIX-based OSes, run ./bin/build.sh

The build system hasn't been tested under Windows yet - your best bet is probably to look at the scripts and write a Windows equivalent. If it's any good, please send in a patch!

IMPORTANT SAFARI NOTE: If the extension directory does not end in ".safariextension", it will not be recognized by Safari. Symlinks inside the extension directory are not allowed.

Instructions for loading/testing an extension in each browser

  • You need to build the package before you start - the initial build process configures some files that aren't stored in git

Chrome / Opera

Firefox

Safari

Releasing packages

You need to release your extension by hand in each Extension store.

LICENSE

MIT (X11) license. See LICENSE.txt

About

The Lobbyradar browser plugin shows you connections of persons and organisations connected to lobbying activities.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • JavaScript 80.0%
  • CSS 15.1%
  • HTML 4.9%