diff --git a/Gemfile b/Gemfile index 3ffff1c9b..f659a0724 100644 --- a/Gemfile +++ b/Gemfile @@ -1,57 +1,24 @@ source 'https://rubygems.org' +ruby '2.3.1' +gem 'pg', '~> 0.18.4' -# Bundle edge Rails instead: gem 'rails', github: 'rails/rails' gem 'rails', '4.2.6' - -# Use SCSS for stylesheets -gem 'sass-rails', '~> 5.0' -# Use Uglifier as compressor for JavaScript assets -gem 'uglifier', '>= 1.3.0' -# Use CoffeeScript for .coffee assets and views -gem 'coffee-rails', '~> 4.1.0' -# See https://github.com/rails/execjs#readme for more supported runtimes -# gem 'therubyracer', platforms: :ruby -# Using postgres for heroku -gem 'pg' -# Use jquery as the JavaScript library -gem 'jquery-rails' -# Turbolinks makes following links in your web application faster. Read more: https://github.com/rails/turbolinks -# gem 'turbolinks' -# Build JSON APIs with ease. Read more: https://github.com/rails/jbuilder -gem 'jbuilder', '~> 2.0' -# bundle exec rake doc:rails generates the API under doc/api. -gem 'sdoc', '~> 0.4.0', group: :doc - -# Use Scrivitio gem gem 'scrivito', '~> 1.3.0.rc1' -gem 'bootstrap-sass', '~> 3.3.5' -gem 'scrivito_section_widgets' -gem 'scrivito_teaser_widget' - -# Use ActiveModel has_secure_password -# gem 'bcrypt', '~> 3.1.7' - -# Use Unicorn as the app server -# gem 'unicorn' -# Use Capistrano for deployment -# gem 'capistrano-rails', group: :development +gem 'scrivito_section_widgets', '1.0.0' +gem 'scrivito_teaser_widget', '0.1.1' -group :development, :test do - # Call 'byebug' anywhere in the code to stop execution and get a debugger console - gem 'byebug' +gem 'coffee-rails', '~> 4.1.0' +gem 'jbuilder', '~> 2.0' +gem 'jquery-rails' -end +gem 'sass-rails', '~> 5.0' +gem 'sdoc', '~> 0.4.0', group: :doc +gem 'uglifier', '>= 1.3.0' group :development do - # Access an IRB console on exception pages or by using <%= console %> in views + gem 'spring', '1.7.1' + gem 'sqlite3', '1.3.11' gem 'web-console', '~> 2.0' - - # Spring speeds up development by keeping your application running in the background. Read more: https://github.com/rails/spring - gem 'spring' - - # Use sqlite3 as the database for Active Record - gem 'sqlite3' -end - +end \ No newline at end of file diff --git a/Gemfile.lock b/Gemfile.lock index fee7a9b1c..c678a5780 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -38,15 +38,9 @@ GEM tzinfo (~> 1.1) addressable (2.4.0) arel (6.0.3) - autoprefixer-rails (6.3.6) - execjs binding_of_caller (0.7.2) debug_inspector (>= 0.0.1) - bootstrap-sass (3.3.6) - autoprefixer-rails (>= 5.2.1) - sass (>= 3.3.4) builder (3.2.2) - byebug (8.2.4) coffee-rails (4.1.1) coffee-script (>= 2.2.0) railties (>= 4.0.0, < 5.1.x) @@ -54,7 +48,7 @@ GEM coffee-script-source execjs coffee-script-source (1.10.0) - concurrent-ruby (1.0.1) + concurrent-ruby (1.0.2) connection_pool (2.2.0) debug_inspector (0.0.2) diff-lcs (1.2.5) @@ -86,7 +80,7 @@ GEM mime-types-data (3.2016.0221) mini_portile2 (2.0.0) minitest (5.8.4) - multi_json (1.11.3) + multi_json (1.12.0) multipart-post (2.0.0) nokogiri (1.6.7.2) mini_portile2 (~> 2.0.0.rc2) @@ -128,20 +122,20 @@ GEM sprockets (>= 2.8, < 4.0) sprockets-rails (>= 2.0, < 4.0) tilt (>= 1.1, < 3) - scrivito (1.3.0.rc1) + scrivito (1.3.0.rc3) railties - scrivito_content_browser (= 1.3.0.rc1) - scrivito_editors (= 1.3.0.rc1) - scrivito_sdk (= 1.3.0.rc1) - scrivito_content_browser (1.3.0.rc1) + scrivito_content_browser (= 1.3.0.rc3) + scrivito_editors (= 1.3.0.rc3) + scrivito_sdk (= 1.3.0.rc3) + scrivito_content_browser (1.3.0.rc3) railties - scrivito_sdk (= 1.3.0.rc1) - scrivito_editors (1.3.0.rc1) + scrivito_sdk (= 1.3.0.rc3) + scrivito_editors (1.3.0.rc3) jquery-ui-rails (>= 5.0.0) railties - scrivito_content_browser (= 1.3.0.rc1) - scrivito_sdk (= 1.3.0.rc1) - scrivito_sdk (1.3.0.rc1) + scrivito_content_browser (= 1.3.0.rc3) + scrivito_sdk (= 1.3.0.rc3) + scrivito_sdk (1.3.0.rc3) addressable (~> 2.3) connection_pool (~> 2.2) diff-lcs (~> 1.2) @@ -153,7 +147,7 @@ GEM nokogiri (~> 1.6) rails (~> 4.2.0) rake (>= 0.9.2.2) - scrivito_section_widgets (0.90.1) + scrivito_section_widgets (1.0.0) bundler scrivito scrivito_teaser_widget (0.1.1) @@ -188,22 +182,23 @@ PLATFORMS ruby DEPENDENCIES - bootstrap-sass (~> 3.3.5) - byebug coffee-rails (~> 4.1.0) jbuilder (~> 2.0) jquery-rails - pg + pg (~> 0.18.4) rails (= 4.2.6) sass-rails (~> 5.0) scrivito (~> 1.3.0.rc1) - scrivito_section_widgets - scrivito_teaser_widget + scrivito_section_widgets (= 1.0.0) + scrivito_teaser_widget (= 0.1.1) sdoc (~> 0.4.0) - spring - sqlite3 + spring (= 1.7.1) + sqlite3 (= 1.3.11) uglifier (>= 1.3.0) web-console (~> 2.0) +RUBY VERSION + ruby 2.3.1p112 + BUNDLED WITH - 1.11.2 + 1.12.3 diff --git a/app/assets/stylesheets/application.css b/app/assets/stylesheets/application.css index 061a19eee..16e2cf118 100644 --- a/app/assets/stylesheets/application.css +++ b/app/assets/stylesheets/application.css @@ -13,3 +13,273 @@ *= require scrivito *= require scrivito_section_widgets */ +.cd-fw, body { + text-align: center +} + +.meetup-item a, .mentor-person > header > a { + text-decoration: none +} + +@font-face { + font-family: coderdojo; + src: url(../font/coderdojo.eot); + src: url(../font/coderdojo.eot?#iefix) format('eot'), url(../font/coderdojo.woff) format('woff'), url(../font/coderdojo.ttf) format('truetype'), url(../font/coderdojo.svg#coderdojo) format('svg'); + font-weight: 400; + font-style: normal +} + +.cd:before { + display: inline-block; + font-family: coderdojo; + font-style: normal; + font-weight: 400; + line-height: 1; + -webkit-font-smoothing: antialiased; + -moz-osx-font-smoothing: grayscale +} + +.cd-lg { + font-size: 1.3333333333333333em; + line-height: .75em; + vertical-align: -15% +} + +.meetup-item, .mentor-person { + overflow: hidden; + vertical-align: top +} + +.cd-2x { + font-size: 2em +} + +.cd-3x { + font-size: 3em +} + +.cd-4x { + font-size: 4em +} + +.cd-5x { + font-size: 5em +} + +.cd-fw { + width: 1.2857142857142858em +} + +.cd-spin { + -webkit-animation: spin 2s infinite linear; + animation: spin 2s infinite linear +} + +.cd-clock:before { + content: "\EA01" +} + +.cd-connect:before { + content: "\EA02" +} + +.cd-glyph07:before { + content: "\EA03" +} + +.cd-glyph08:before { + content: "\EA04" +} + +.cd-logo-jp:before { + content: "\EA05" +} + +.cd-logo:before { + content: "\EA06" +} + +.cd-pin:before { + content: "\EA07" +} + +.cd-spinner:before { + content: "\EA08" +} + +body { + margin: 0; + padding: 0; + font-size: 16px +} + +a { + color: #2e9ad9 +} + +.under-construction { + color: #cd8585; + font-size: 75%; + margin: 0; + padding: .2em; + background: #FFF +} + +body > footer { + margin: -.25em 0 0; + padding: 1.5em 0 4em; + color: #fff +} + +body > footer h2 { + font-size: 87.5%; + margin-top: 0; + margin-bottom: 2em +} + +body > footer a { + color: inherit +} + +.title, body > footer a:hover { + color: #fff +} + +.title { + margin: 0; + padding: 2em +} + +.title > i.cd:before { + font-size: 500%; + display: block +} + +.title > h1 { + font-size: 1.5em; + margin: .5em 0 1em +} + +.title > p { + padding: 0 1em; + margin: 0 auto; + max-width: 680px; + font-size: 130% +} + +@media only screen and (min-width:560px) { + body > footer > ul li { + border-radius: 3px; + line-height: 2.8em + } + + .title > i.cd:before { + font-size: 800% + } + + .title > h1 { + font-size: 1.7em; + margin-bottom: .5em + } + + .title > p { + padding: 0 3em; + font-size: 110% + } +} + +@media only screen and (min-width:720px) { + .title > i.cd:before { + font-size: 1000% + } + + .title > h1 { + font-size: 2.2em; + margin-bottom: .2em + } + + .title > p { + padding: 0 5em; + font-size: 90% + } +} + +body > section { + padding: 1.5em; + background: #fff +} + +body > section > * { + margin: 0 auto; + max-width: 750px +} + +body > section:nth-child(even) { + background: #f7f7f7 +} + +body > section > h1 { + display: none +} + +body > section > h2 { + font-size: 120%; + color: #999; + margin-bottom: .4em +} + +body > section > ul { + text-align: left; + padding-left: 2em; + color: #666 +} + +body > section > p { + margin-bottom: .8em; + text-align: left +} + +.meetup, .meetup > ul { + text-align: center +} + +@media only screen and (min-width:560px) { + body > section > ul { + padding-left: 7em + } + + body > section > p { + text-align: center + } +} + +body > section.cover { + padding: 0; + max-height: 500px; + overflow: hidden; + background: #999; + line-height: 0 +} + +.cover > img { + width: 100%; + max-width: 1200px +} + +.meetup > ul, .mentor > ul { + list-style: none; + max-width: 100% +} + +@media only screen and (min-width:560px) { + .cover > img { + / / margin-top: -100px; + margin-top: -10px + } +} + +@media only screen and (min-width:720px) { + .cover > img { + margin-top: -25px + } +} \ No newline at end of file diff --git a/app/views/layouts/application.html.erb b/app/views/layouts/application.html.erb index 603179993..ca857d712 100644 --- a/app/views/layouts/application.html.erb +++ b/app/views/layouts/application.html.erb @@ -9,9 +9,7 @@ - -<%= yield %> -<%= scrivito_body_tags %> - + <%= yield %> + <%= scrivito_body_tags %> diff --git a/app/views/page/index.html.erb b/app/views/page/index.html.erb index 5c91f1d39..88841d6d6 100644 --- a/app/views/page/index.html.erb +++ b/app/views/page/index.html.erb @@ -1,16 +1 @@ -
-

<%= link_to 'Home', scrivito_path(Obj.root) %>

- - <%= scrivito_tag_list :ul, Obj.root, :toclist do |list, page| %> - <%= list.tag :li do %> - <%= link_to page.display_title, scrivito_path(page) %> - <% end %> - <% end %> - - <% if Obj.root.toclist.empty? && scrivito_in_editable_view? %> -

(Hint: Click on the Scrivito icon to the right to create the first subpage.)

- <% end %> -
- -<%= scrivito_tag :h1, @obj, :title %> <%= scrivito_tag :div, @obj, :body %> diff --git a/app/views/text_widget/show.html.erb b/app/views/text_widget/show.html.erb index 1f9f1793c..024466dee 100644 --- a/app/views/text_widget/show.html.erb +++ b/app/views/text_widget/show.html.erb @@ -1 +1,2 @@ <%= scrivito_tag :div, widget, :text %> +