diff --git a/Gemfile b/Gemfile index 9327840c..ed45ea4c 100644 --- a/Gemfile +++ b/Gemfile @@ -35,6 +35,7 @@ gem 'paranoia' # Javascript gem 'coffee-rails' gem 'rails-jquery-autocomplete' +gem 'animate-rails' # SEO gem 'meta-tags' diff --git a/Gemfile.lock b/Gemfile.lock index 60802fc5..34073450 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -54,6 +54,8 @@ GEM activerecord (>= 3.0) addressable (2.5.2) public_suffix (>= 2.0.2, < 4.0) + animate-rails (1.0.10) + rails arel (9.0.0) ast (2.4.0) authority (3.3.0) @@ -546,6 +548,7 @@ PLATFORMS DEPENDENCIES acts_as_list + animate-rails authority aws-sdk (~> 1.5) aws-sdk-s3 @@ -619,4 +622,4 @@ RUBY VERSION ruby 2.5.1p57 BUNDLED WITH - 1.16.4 + 1.17.3 diff --git a/app/assets/stylesheets/application.css b/app/assets/stylesheets/application.css index 9aa7a8b5..f79752be 100644 --- a/app/assets/stylesheets/application.css +++ b/app/assets/stylesheets/application.css @@ -13,5 +13,6 @@ *= require font-awesome *= require medium-editor/medium-editor *= require medium-editor/themes/beagle + *= require animate *= require_tree . */ diff --git a/app/views/documents/analysis.html.erb b/app/views/documents/analysis.html.erb index a9010d5d..8e13cc07 100644 --- a/app/views/documents/analysis.html.erb +++ b/app/views/documents/analysis.html.erb @@ -9,18 +9,7 @@
- Readability scales are a real thing, I promise. This is some text about - their background that speaks to their legitimacy. -
In order to provide you with a generalized score in Notebook.ai, we compute several of the most well-known readability scores on your text and average - them together. You can see the original scores per readability test below: + them together. You can see the original scores per readability test by clicking + "show more readability statistics".
- <%= - pie_chart({ - 'Alice Yellowbottom' => 33, - 'Bob Zebracakes' => 19, - 'Carol Anderson' => 12, - 'David Butters' => 10, - 'Ethan Coolridge' => 15, - 'Fred Danvers' => 14 - }) - %> -
+ To increase your readability further, try using shorter sentences.+ <%= + pie_chart({ + 'Alice Yellowbottom' => 33, + 'Bob Zebracakes' => 19, + 'Carol Anderson' => 12, + 'David Butters' => 10, + 'Ethan Coolridge' => 15, + 'Fred Danvers' => 14 + }) + %> +
++ Based on their frequency in appearing in <%= @document.title %>, the + following characters are ordered by importance. +
+ +Main character
+<%= line_chart((1..100).map { |i| [i, 5 + 7 * Math.sin(i).abs * rand(3)] }) %> @@ -480,3 +542,24 @@