summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorgebele <gebele@in-silico.ch>2016-06-10 06:35:19 +0000
committergebele <gebele@in-silico.ch>2016-06-10 06:35:19 +0000
commit52a3d062409337ecc019991b00d0495f90f8261e (patch)
tree0015cf05f182d1070e828238cc0f88ced8dc938e
parent10ead88b17c70fdb3b53bb9daaa4a10c7755c2bf (diff)
added version and share buttons
-rw-r--r--application.rb1
-rw-r--r--nano-lazar.gemspec22
-rw-r--r--public/images/Email.pngbin0 -> 396 bytes
-rw-r--r--public/images/Facebook.pngbin0 -> 318 bytes
-rw-r--r--public/images/Google+.pngbin0 -> 432 bytes
-rw-r--r--public/images/LinkedIn.pngbin0 -> 356 bytes
-rw-r--r--public/images/Twitter.pngbin0 -> 379 bytes
-rw-r--r--views/layout.haml21
8 files changed, 42 insertions, 2 deletions
diff --git a/application.rb b/application.rb
index 225776d..1f7fa00 100644
--- a/application.rb
+++ b/application.rb
@@ -13,6 +13,7 @@ get '/?' do
end
get '/predict/?' do
+ @version = File.read("VERSION").chomp
data = JSON.parse(File.read("./data.json"))
query_features = JSON.parse(File.read("./query-features.json"))
@example = data[data.keys.sample]["physchem"].select{|f,v| query_features.include? f}
diff --git a/nano-lazar.gemspec b/nano-lazar.gemspec
new file mode 100644
index 0000000..c6ae2b1
--- /dev/null
+++ b/nano-lazar.gemspec
@@ -0,0 +1,22 @@
+# -*- encoding: utf-8 -*-
+
+Gem::Specification.new do |s|
+ s.name = "nano-lazar"
+ s.version = File.read("./VERSION")
+ s.authors = ["Christoph Helma","Micha Rautenberg","Denis Gebele"]
+ s.email = ["helma@in-silico.ch","rautenberg@in-silico.ch","gebele@in-silico.ch"]
+ s.homepage = "http://github.com/enanomapper/nano-lazar"
+ s.summary = %q{nano-lazar}
+ s.description = %q{Graphical User Interface for Nano Lazar Toxicology Predictions}
+ s.license = 'GPL-3'
+
+ s.rubyforge_project = "nano-lazar"
+
+ s.files = `git ls-files`.split("\n")
+ s.required_ruby_version = '>= 2.0.0'
+
+ s.add_runtime_dependency "sinatra"
+ s.add_runtime_dependency "rdiscount"
+ s.add_runtime_dependency "haml"
+ s.add_runtime_dependency "unicorn"
+end
diff --git a/public/images/Email.png b/public/images/Email.png
new file mode 100644
index 0000000..1e5c8bf
--- /dev/null
+++ b/public/images/Email.png
Binary files differ
diff --git a/public/images/Facebook.png b/public/images/Facebook.png
new file mode 100644
index 0000000..3d249fd
--- /dev/null
+++ b/public/images/Facebook.png
Binary files differ
diff --git a/public/images/Google+.png b/public/images/Google+.png
new file mode 100644
index 0000000..9db76fd
--- /dev/null
+++ b/public/images/Google+.png
Binary files differ
diff --git a/public/images/LinkedIn.png b/public/images/LinkedIn.png
new file mode 100644
index 0000000..dcdda37
--- /dev/null
+++ b/public/images/LinkedIn.png
Binary files differ
diff --git a/public/images/Twitter.png b/public/images/Twitter.png
new file mode 100644
index 0000000..05e0c2c
--- /dev/null
+++ b/public/images/Twitter.png
Binary files differ
diff --git a/views/layout.haml b/views/layout.haml
index acdef62..d924f95 100644
--- a/views/layout.haml
+++ b/views/layout.haml
@@ -38,8 +38,25 @@
%a{:href=>"https://lazar.in-silico.ch/predict"} lazar
%div.container-fluid
- Problems, bugs, ideas for improvements ? Please report at our
- %a{:href => 'https://github.com/enanomapper/nano-lazar/issues', :rel => "external"} issue tracker
+ %topline
+ %div.row
+ %div.col-md-8
+ Problems, bugs, ideas for improvements ? Please report at our
+ %a{:href => 'https://github.com/enanomapper/nano-lazar/issues', :rel => "external"} issue tracker
+ or send us an email
+ %a{ :href=>"mailto:info@in-silico.ch", :target=>"_top"}
+ %img.share{:src=>"/images/Email.png"}
+ (version #{@version}).
+ %div.col-md-2
+ %div.col-md-2
+ %a{:href=>"https://twitter.com/intent/tweet?source=http%3A%2F%2Flazar.in-silico.ch&text=:%20http%3A%2F%2Flazar.in-silico.ch", :target=>"_blank", :title=>"Tweet"}
+ %img.share{:src=>"/images/Twitter.png"}
+ %a{:href=>"https://plus.google.com/share?url=http%3A%2F%2Flazar.in-silico.ch", :target=>"_blank", :title=>"Share on Google+"}
+ %img.share{:src=>"/images/Google+.png"}
+ %a{:href=>"http://www.linkedin.com/shareArticle?mini=true&url=http%3A%2F%2Flazar.in-silico.ch&title=&summary=&source=http%3A%2F%2Flazar.in-silico.ch", :target=>"_blank", :title=>"Share on LinkedIn"}
+ %img.share{:src=>"/images/LinkedIn.png"}
+ %a{:href=>"https://www.facebook.com/sharer/sharer.php?u=http%3A%2F%2Flazar.in-silico.ch&title=&summary=&source=http%3A%2F%2Flazar.in-silico.ch", :target=>"_blank", :title=>"Share on Facebook"}
+ %img.share{:src=>"/images/Facebook.png"}
:javascript
$(document).ready(function(){
$("#back-top").hide();