virgo 0.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/MIT-LICENSE +20 -0
- data/Rakefile +37 -0
- data/app/assets/javascripts/tinymce/manifest.coffee +1 -0
- data/app/assets/javascripts/tinymce/plugins/image_manager/plugin.coffee +234 -0
- data/app/assets/javascripts/virgo/admin/page_modules/edit_form.coffee +4 -0
- data/app/assets/javascripts/virgo/admin/page_modules/edit_subject_form.coffee +29 -0
- data/app/assets/javascripts/virgo/admin/posts/edit_locking.coffee +35 -0
- data/app/assets/javascripts/virgo/admin/posts/form.coffee +183 -0
- data/app/assets/javascripts/virgo/admin/slides/form.coffee +27 -0
- data/app/assets/javascripts/virgo/admin/slideshows/form.coffee +26 -0
- data/app/assets/javascripts/virgo/admin_only.coffee +1 -0
- data/app/assets/javascripts/virgo/application.coffee +51 -0
- data/app/assets/javascripts/virgo/common.coffee +83 -0
- data/app/assets/javascripts/virgo/common/character_counter.coffee +27 -0
- data/app/assets/javascripts/virgo/components/header.coffee +47 -0
- data/app/assets/javascripts/virgo/components/media_modal.coffee +151 -0
- data/app/assets/javascripts/virgo/components/share_bar.coffee +53 -0
- data/app/assets/javascripts/virgo/components/slideshow.coffee +35 -0
- data/app/assets/javascripts/virgo/lib/jquery-ui-multiselect.js +342 -0
- data/app/assets/javascripts/virgo/lib/jquery.browser.js +184 -0
- data/app/assets/javascripts/virgo/lib/jquery.cookie.js +114 -0
- data/app/assets/javascripts/virgo/lib/jquery.pjax.js +932 -0
- data/app/assets/javascripts/virgo/lib/jquery_ext.coffee +0 -0
- data/app/assets/javascripts/virgo/lib/manifest.coffee +5 -0
- data/app/assets/javascripts/virgo/lib/ouibounce.js +194 -0
- data/app/assets/javascripts/virgo/page_modules.coffee +175 -0
- data/app/assets/javascripts/virgo/posts/show.coffee +32 -0
- data/app/assets/stylesheets/tinymce/skin.sass +2 -0
- data/app/assets/stylesheets/tinymce/skins/railspress/content.min.sass +82 -0
- data/app/assets/stylesheets/tinymce/skins/railspress/fonts/tinymce-small.eot +0 -0
- data/app/assets/stylesheets/tinymce/skins/railspress/fonts/tinymce-small.svg +62 -0
- data/app/assets/stylesheets/tinymce/skins/railspress/fonts/tinymce-small.ttf +0 -0
- data/app/assets/stylesheets/tinymce/skins/railspress/fonts/tinymce-small.woff +0 -0
- data/app/assets/stylesheets/tinymce/skins/railspress/fonts/tinymce.eot +0 -0
- data/app/assets/stylesheets/tinymce/skins/railspress/fonts/tinymce.svg +63 -0
- data/app/assets/stylesheets/tinymce/skins/railspress/fonts/tinymce.ttf +0 -0
- data/app/assets/stylesheets/tinymce/skins/railspress/fonts/tinymce.woff +0 -0
- data/app/assets/stylesheets/tinymce/skins/railspress/img/anchor.gif +0 -0
- data/app/assets/stylesheets/tinymce/skins/railspress/img/loader.gif +0 -0
- data/app/assets/stylesheets/tinymce/skins/railspress/img/object.gif +0 -0
- data/app/assets/stylesheets/tinymce/skins/railspress/img/trans.gif +0 -0
- data/app/assets/stylesheets/tinymce/skins/railspress/skin.min.sass +1703 -0
- data/app/assets/stylesheets/virgo/_common.sass +65 -0
- data/app/assets/stylesheets/virgo/admin.sass +301 -0
- data/app/assets/stylesheets/virgo/admin/columns.sass +3 -0
- data/app/assets/stylesheets/virgo/admin/images.sass +14 -0
- data/app/assets/stylesheets/virgo/admin/media_modal.sass +72 -0
- data/app/assets/stylesheets/virgo/admin/post.sass +102 -0
- data/app/assets/stylesheets/virgo/admin/slideshow.sass +35 -0
- data/app/assets/stylesheets/virgo/admin/users.sass +2 -0
- data/app/assets/stylesheets/virgo/admin_only.sass +1 -0
- data/app/assets/stylesheets/virgo/application.sass +605 -0
- data/app/assets/stylesheets/virgo/columns.sass +51 -0
- data/app/assets/stylesheets/virgo/install.sass +15 -0
- data/app/assets/stylesheets/virgo/lib/bootstrap/bootstrap-imports.sass +9 -0
- data/app/assets/stylesheets/virgo/lib/bootstrap/bootstrap-overrides.sass +51 -0
- data/app/assets/stylesheets/virgo/lib/bootstrap/bootstrap-variables.sass +27 -0
- data/app/assets/stylesheets/virgo/lib/jquery-ui-multiselect.css +30 -0
- data/app/assets/stylesheets/virgo/lib/manifest.sass +3 -0
- data/app/assets/stylesheets/virgo/lib/ouibounce.css +222 -0
- data/app/assets/stylesheets/virgo/lib/select2-imports.sass +8 -0
- data/app/assets/stylesheets/virgo/page_modules.sass +54 -0
- data/app/assets/stylesheets/virgo/pages/authors.sass +30 -0
- data/app/assets/stylesheets/virgo/posts.sass +782 -0
- data/app/assets/stylesheets/virgo/search.sass +36 -0
- data/app/assets/stylesheets/virgo/ui.sass +434 -0
- data/app/assets/stylesheets/virgo/users.sass +9 -0
- data/app/controllers/virgo/admin/base_controller.rb +22 -0
- data/app/controllers/virgo/admin/categories_controller.rb +90 -0
- data/app/controllers/virgo/admin/columns_controller.rb +65 -0
- data/app/controllers/virgo/admin/images_controller.rb +89 -0
- data/app/controllers/virgo/admin/media_modal_controller.rb +101 -0
- data/app/controllers/virgo/admin/newsletters_controller.rb +37 -0
- data/app/controllers/virgo/admin/page_modules_controller.rb +62 -0
- data/app/controllers/virgo/admin/pages_controller.rb +6 -0
- data/app/controllers/virgo/admin/posts_controller.rb +173 -0
- data/app/controllers/virgo/admin/sites_controller.rb +31 -0
- data/app/controllers/virgo/admin/slides_controller.rb +71 -0
- data/app/controllers/virgo/admin/slideshows_controller.rb +66 -0
- data/app/controllers/virgo/admin/tags_controller.rb +98 -0
- data/app/controllers/virgo/admin/users/sessions_controller.rb +21 -0
- data/app/controllers/virgo/admin/users_controller.rb +84 -0
- data/app/controllers/virgo/application_controller.rb +151 -0
- data/app/controllers/virgo/categories_controller.rb +20 -0
- data/app/controllers/virgo/columns_controller.rb +24 -0
- data/app/controllers/virgo/images_controller.rb +9 -0
- data/app/controllers/virgo/install_controller.rb +46 -0
- data/app/controllers/virgo/page_modules_controller.rb +23 -0
- data/app/controllers/virgo/pages_controller.rb +29 -0
- data/app/controllers/virgo/posts_controller.rb +101 -0
- data/app/controllers/virgo/search_controller.rb +35 -0
- data/app/controllers/virgo/subscribers_controller.rb +54 -0
- data/app/controllers/virgo/tags_controller.rb +15 -0
- data/app/controllers/virgo/users/confirmations_controller.rb +18 -0
- data/app/controllers/virgo/users/passwords_controller.rb +31 -0
- data/app/controllers/virgo/users/registrations_controller.rb +41 -0
- data/app/controllers/virgo/users/sessions_controller.rb +32 -0
- data/app/controllers/virgo/users_controller.rb +15 -0
- data/app/helpers/virgo/admin/post_helper.rb +54 -0
- data/app/helpers/virgo/admin_helper.rb +15 -0
- data/app/helpers/virgo/application_helper.rb +124 -0
- data/app/helpers/virgo/hooks_helper.rb +30 -0
- data/app/helpers/virgo/page_modules_helper.rb +4 -0
- data/app/helpers/virgo/post_helper.rb +159 -0
- data/app/helpers/virgo/render_helper.rb +33 -0
- data/app/helpers/virgo/search_helper.rb +49 -0
- data/app/helpers/virgo/shortcode_helper.rb +7 -0
- data/app/helpers/virgo/text_helper.rb +12 -0
- data/app/helpers/virgo/video_helper.rb +34 -0
- data/app/models/concerns/virgo/common/slug_history.rb +36 -0
- data/app/models/concerns/virgo/common/uuid.rb +22 -0
- data/app/models/concerns/virgo/post/recommendations.rb +15 -0
- data/app/models/concerns/virgo/post/search.rb +100 -0
- data/app/models/concerns/virgo/user/search.rb +39 -0
- data/app/models/virgo/ability.rb +59 -0
- data/app/models/virgo/category.rb +44 -0
- data/app/models/virgo/column.rb +25 -0
- data/app/models/virgo/form_model.rb +19 -0
- data/app/models/virgo/image.rb +63 -0
- data/app/models/virgo/page_module.rb +42 -0
- data/app/models/virgo/page_module_post.rb +8 -0
- data/app/models/virgo/post.rb +391 -0
- data/app/models/virgo/post_category.rb +8 -0
- data/app/models/virgo/post_search.rb +7 -0
- data/app/models/virgo/post_tag.rb +10 -0
- data/app/models/virgo/site.rb +36 -0
- data/app/models/virgo/slide.rb +23 -0
- data/app/models/virgo/slideshow.rb +37 -0
- data/app/models/virgo/slug_history.rb +5 -0
- data/app/models/virgo/subscriber.rb +5 -0
- data/app/models/virgo/tag.rb +34 -0
- data/app/models/virgo/user.rb +145 -0
- data/app/uploaders/virgo/application_uploader.rb +11 -0
- data/app/uploaders/virgo/avatar_uploader.rb +21 -0
- data/app/uploaders/virgo/featured_image_uploader.rb +28 -0
- data/app/uploaders/virgo/image_uploader.rb +40 -0
- data/app/uploaders/virgo/slide_uploader.rb +19 -0
- data/app/views/layouts/virgo/admin.haml +16 -0
- data/app/views/layouts/virgo/admin/site_settings.haml +14 -0
- data/app/views/layouts/virgo/application.haml +63 -0
- data/app/views/layouts/virgo/errors.haml +42 -0
- data/app/views/layouts/virgo/main.haml +5 -0
- data/app/views/layouts/virgo/posts.haml +10 -0
- data/app/views/virgo/admin/categories/_form.haml +19 -0
- data/app/views/virgo/admin/categories/edit.haml +7 -0
- data/app/views/virgo/admin/categories/index.haml +38 -0
- data/app/views/virgo/admin/categories/modal_form.haml +11 -0
- data/app/views/virgo/admin/categories/new.haml +7 -0
- data/app/views/virgo/admin/categories/success_modal.haml +14 -0
- data/app/views/virgo/admin/columns/_form.haml +30 -0
- data/app/views/virgo/admin/columns/edit.haml +1 -0
- data/app/views/virgo/admin/columns/index.haml +30 -0
- data/app/views/virgo/admin/columns/new.haml +1 -0
- data/app/views/virgo/admin/images/_form.haml +46 -0
- data/app/views/virgo/admin/images/edit.haml +1 -0
- data/app/views/virgo/admin/images/index.haml +32 -0
- data/app/views/virgo/admin/images/new.haml +1 -0
- data/app/views/virgo/admin/media_modal/_image_settings.haml +17 -0
- data/app/views/virgo/admin/media_modal/_library_panel.haml +26 -0
- data/app/views/virgo/admin/media_modal/_upload_panel.haml +21 -0
- data/app/views/virgo/admin/media_modal/_upload_success.haml +7 -0
- data/app/views/virgo/admin/media_modal/index.haml +19 -0
- data/app/views/virgo/admin/newsletters/changelog.haml +25 -0
- data/app/views/virgo/admin/newsletters/edit.haml +6 -0
- data/app/views/virgo/admin/page_modules/edit.haml +33 -0
- data/app/views/virgo/admin/page_modules/edit_subject.haml +43 -0
- data/app/views/virgo/admin/pages/help.haml +114 -0
- data/app/views/virgo/admin/posts/_author_dropdown.haml +1 -0
- data/app/views/virgo/admin/posts/_categories_form.haml +7 -0
- data/app/views/virgo/admin/posts/_category.haml +22 -0
- data/app/views/virgo/admin/posts/_form.haml +201 -0
- data/app/views/virgo/admin/posts/_revisions.haml +40 -0
- data/app/views/virgo/admin/posts/edit.haml +9 -0
- data/app/views/virgo/admin/posts/index.haml +59 -0
- data/app/views/virgo/admin/posts/new.haml +1 -0
- data/app/views/virgo/admin/posts/revision_detail.haml +28 -0
- data/app/views/virgo/admin/posts/revisions.haml +3 -0
- data/app/views/virgo/admin/sites/edit.haml +12 -0
- data/app/views/virgo/admin/slides/_form.haml +41 -0
- data/app/views/virgo/admin/slides/edit.haml +1 -0
- data/app/views/virgo/admin/slides/new.haml +1 -0
- data/app/views/virgo/admin/slideshows/_form.haml +49 -0
- data/app/views/virgo/admin/slideshows/edit.haml +1 -0
- data/app/views/virgo/admin/slideshows/index.haml +43 -0
- data/app/views/virgo/admin/slideshows/new.haml +1 -0
- data/app/views/virgo/admin/tags/_form.haml +16 -0
- data/app/views/virgo/admin/tags/edit.haml +7 -0
- data/app/views/virgo/admin/tags/index.haml +33 -0
- data/app/views/virgo/admin/tags/modal_form.haml +12 -0
- data/app/views/virgo/admin/tags/new.haml +7 -0
- data/app/views/virgo/admin/tags/success_modal.haml +14 -0
- data/app/views/virgo/admin/users/_form.haml +62 -0
- data/app/views/virgo/admin/users/edit.haml +1 -0
- data/app/views/virgo/admin/users/index.haml +34 -0
- data/app/views/virgo/admin/users/new.haml +1 -0
- data/app/views/virgo/application/sitemap.xml.builder +0 -0
- data/app/views/virgo/authors/_profile_long.haml +13 -0
- data/app/views/virgo/authors/_profile_short.haml +10 -0
- data/app/views/virgo/categories/show.haml +24 -0
- data/app/views/virgo/columns/index.haml +19 -0
- data/app/views/virgo/columns/show.haml +18 -0
- data/app/views/virgo/common/_admin_navbar.haml +100 -0
- data/app/views/virgo/common/_alerts.haml +40 -0
- data/app/views/virgo/common/_analytics.html.erb +1 -0
- data/app/views/virgo/common/_base_errors.haml +8 -0
- data/app/views/virgo/common/_category_heading.haml +26 -0
- data/app/views/virgo/common/_disqus.html.erb +24 -0
- data/app/views/virgo/common/_disqus_comment_count.html.erb +12 -0
- data/app/views/virgo/common/_fb_api.html.erb +30 -0
- data/app/views/virgo/common/_fonts.html.erb +1 -0
- data/app/views/virgo/common/_footer.haml +13 -0
- data/app/views/virgo/common/_footer_javascript.html.erb +0 -0
- data/app/views/virgo/common/_header_analytics.html.erb +9 -0
- data/app/views/virgo/common/_list_signup.haml +20 -0
- data/app/views/virgo/common/_ouibounce_modal.haml +26 -0
- data/app/views/virgo/common/_public_nav.haml +58 -0
- data/app/views/virgo/common/_search_form.haml +8 -0
- data/app/views/virgo/common/_share_bar.haml +45 -0
- data/app/views/virgo/common/_user_vars.haml +2 -0
- data/app/views/virgo/errors/404.haml +10 -0
- data/app/views/virgo/errors/500.haml +10 -0
- data/app/views/virgo/images/_shortcode.haml +4 -0
- data/app/views/virgo/install/index.haml +58 -0
- data/app/views/virgo/install/success.haml +12 -0
- data/app/views/virgo/page_modules/_latest_posts.haml +29 -0
- data/app/views/virgo/page_modules/_popular_posts.haml +51 -0
- data/app/views/virgo/pages/authors.haml +8 -0
- data/app/views/virgo/pages/home.haml +0 -0
- data/app/views/virgo/pages/show.haml +6 -0
- data/app/views/virgo/posts/_author_info.haml +16 -0
- data/app/views/virgo/posts/_post_full.haml +63 -0
- data/app/views/virgo/posts/_post_short.haml +30 -0
- data/app/views/virgo/posts/_post_thumb_box.haml +13 -0
- data/app/views/virgo/posts/_recommendations.haml +12 -0
- data/app/views/virgo/posts/_sidebar_thumb.haml +4 -0
- data/app/views/virgo/posts/index.haml +22 -0
- data/app/views/virgo/posts/latest.haml +16 -0
- data/app/views/virgo/posts/more.haml +10 -0
- data/app/views/virgo/posts/rss.xml.builder +17 -0
- data/app/views/virgo/posts/show.haml +17 -0
- data/app/views/virgo/search/_form.haml +5 -0
- data/app/views/virgo/search/_item.haml +22 -0
- data/app/views/virgo/search/index.haml +11 -0
- data/app/views/virgo/search/new.haml +4 -0
- data/app/views/virgo/shortcode_templates/blockquote.haml +9 -0
- data/app/views/virgo/shortcode_templates/h1.haml +1 -0
- data/app/views/virgo/shortcode_templates/h2.haml +1 -0
- data/app/views/virgo/shortcode_templates/h3.haml +1 -0
- data/app/views/virgo/shortcode_templates/h4.haml +1 -0
- data/app/views/virgo/shortcode_templates/image.haml +17 -0
- data/app/views/virgo/shortcode_templates/pullquote.haml +3 -0
- data/app/views/virgo/shortcode_templates/slideshow.haml +35 -0
- data/app/views/virgo/shortcode_templates/tweet.haml +3 -0
- data/app/views/virgo/shortcode_templates/video.haml +8 -0
- data/app/views/virgo/subscribers/_success_modal.haml +13 -0
- data/app/views/virgo/subscribers/modal.haml +15 -0
- data/app/views/virgo/tags/show.haml +16 -0
- data/app/views/virgo/users/confirmations/new.html.haml +10 -0
- data/app/views/virgo/users/devise_mailer/confirmation_instructions.html.erb +7 -0
- data/app/views/virgo/users/devise_mailer/reset_password_instructions.html.haml +6 -0
- data/app/views/virgo/users/devise_mailer/unlock_instructions.html.haml +5 -0
- data/app/views/virgo/users/passwords/edit.html.haml +14 -0
- data/app/views/virgo/users/passwords/new.html.haml +14 -0
- data/app/views/virgo/users/registrations/edit.html.haml +30 -0
- data/app/views/virgo/users/registrations/new.html.haml +13 -0
- data/app/views/virgo/users/sessions/new.html.haml +12 -0
- data/app/views/virgo/users/shared/_links.haml +26 -0
- data/app/views/virgo/users/show.haml +11 -0
- data/app/views/virgo/users/unlocks/new.html.haml +9 -0
- data/config/initializers/action_mailer.rb +7 -0
- data/config/initializers/active_record.rb +72 -0
- data/config/initializers/active_record_symbolize.rb +18 -0
- data/config/initializers/assets.rb +17 -0
- data/config/initializers/backtrace_silencers.rb +7 -0
- data/config/initializers/carrierwave.rb +36 -0
- data/config/initializers/cookies_serializer.rb +3 -0
- data/config/initializers/devise.rb +257 -0
- data/config/initializers/filter_parameter_logging.rb +4 -0
- data/config/initializers/hash.rb +5 -0
- data/config/initializers/inflections.rb +16 -0
- data/config/initializers/mime_types.rb +4 -0
- data/config/initializers/nil_class.rb +13 -0
- data/config/initializers/non_digest_assets.rb +3 -0
- data/config/initializers/paper_trail.rb +30 -0
- data/config/initializers/schema_plus.rb +5 -0
- data/config/initializers/session_store.rb +3 -0
- data/config/initializers/shortcode.rb +12 -0
- data/config/initializers/simple_form.rb +170 -0
- data/config/initializers/simple_form_bootstrap.rb +136 -0
- data/config/initializers/string.rb +5 -0
- data/config/initializers/time_formatting.rb +23 -0
- data/config/initializers/wrap_parameters.rb +14 -0
- data/config/locales/devise.en.yml +60 -0
- data/config/routes.rb +96 -0
- data/config/schedule.rb +3 -0
- data/db/migrate/20150729174510_create_virgo_schema.rb +225 -0
- data/lib/generators/virgo/install/install_generator.rb +16 -0
- data/lib/generators/virgo/views/views_generator.rb +22 -0
- data/lib/tasks/virgo_tasks.rake +7 -0
- data/lib/virgo.rb +4 -0
- data/lib/virgo/development_mail_interceptor.rb +6 -0
- data/lib/virgo/email_validator.rb +6 -0
- data/lib/virgo/engine.rb +73 -0
- data/lib/virgo/reduce_validator.rb +6 -0
- data/lib/virgo/upload_helpers.rb +89 -0
- data/lib/virgo/version.rb +3 -0
- data/lib/virgo/view_help.rb +3 -0
- metadata +1051 -0
@@ -0,0 +1 @@
|
|
1
|
+
= render 'form'
|
@@ -0,0 +1,34 @@
|
|
1
|
+
= link_to "Add New", new_admin_user_path, class: 'btn btn-inverse pull-right action-btn', id: 'new-user-link'
|
2
|
+
= render '/virgo/common/search_form', url: admin_users_path
|
3
|
+
.clear
|
4
|
+
.table-panel
|
5
|
+
%table.table.admin-posts-table
|
6
|
+
%thead
|
7
|
+
%tr
|
8
|
+
%th= sortable_column "Username"
|
9
|
+
%th= sortable_column "Byline", column: :byline
|
10
|
+
%th= sortable_column "Email"
|
11
|
+
%th= sortable_column "Role"
|
12
|
+
%th= sortable_column "Added at", column: :created_at
|
13
|
+
%th= sortable_column "Posts", column: "post_count"
|
14
|
+
|
15
|
+
%tbody
|
16
|
+
- if @users.empty?
|
17
|
+
%tr.empty
|
18
|
+
%td{colspan: "6"}
|
19
|
+
No users
|
20
|
+
|
21
|
+
- @users.each do |user|
|
22
|
+
%tr
|
23
|
+
%td= link_to truncate(user.username, length: 40), edit_admin_user_path(user)
|
24
|
+
%td= truncate(user.pretty_name, length: 40)
|
25
|
+
%td= truncate(user.email, length: 40)
|
26
|
+
%td= user.role.try(:to_s).try(:capitalize)
|
27
|
+
%td= user.created_at.to_s(:slashes_with_time)
|
28
|
+
%td
|
29
|
+
- if user.post_count == 0
|
30
|
+
%span 0
|
31
|
+
- else
|
32
|
+
= link_to user.post_count, admin_posts_path(filters: {user_ids: [user.id]})
|
33
|
+
|
34
|
+
= paginate @users
|
@@ -0,0 +1 @@
|
|
1
|
+
= render 'form'
|
File without changes
|
@@ -0,0 +1,13 @@
|
|
1
|
+
- cache author do
|
2
|
+
.container.author-detail
|
3
|
+
.row
|
4
|
+
.col-md-10.col-md-offset-1
|
5
|
+
.media.author-profile-long{class: ('no-img' if author.avatar.blank?)}
|
6
|
+
.media-left
|
7
|
+
= image_tag author.avatar.url(:thumb), class: 'img-circle'
|
8
|
+
|
9
|
+
.media-body
|
10
|
+
%h4.media-heading= author.byline
|
11
|
+
.media-text
|
12
|
+
= raw author.about
|
13
|
+
|
@@ -0,0 +1,24 @@
|
|
1
|
+
- content_for :title do
|
2
|
+
= "#{site.name} | #{@category.name}"
|
3
|
+
|
4
|
+
- content_for :posts_content do
|
5
|
+
- cache [@category, page_param] do
|
6
|
+
- category_feature = Virgo::Post.category_feature(@category)
|
7
|
+
|
8
|
+
- if category_feature
|
9
|
+
= render '/virgo/common/category_heading', post: category_feature, category: @category
|
10
|
+
|
11
|
+
.container.posts-container.category-posts
|
12
|
+
.row
|
13
|
+
.col-md-8.col-md-offset-2
|
14
|
+
.category-posts-inner
|
15
|
+
.category-header-wrap
|
16
|
+
%h3.category-header Latest in #{@category.name}
|
17
|
+
- @posts.each do |post|
|
18
|
+
= render '/virgo/posts/post_short', post: post
|
19
|
+
|
20
|
+
.pagination-wrap
|
21
|
+
= paginate @posts
|
22
|
+
|
23
|
+
- content_for :end_of_body do
|
24
|
+
= render '/virgo/common/disqus_comment_count'
|
@@ -0,0 +1,19 @@
|
|
1
|
+
- content_for :posts_content do
|
2
|
+
- cache [Virgo::Column.order(updated_at: :asc).last, 'index'] do
|
3
|
+
.posts-container.columns-index
|
4
|
+
.container.columns-index-inner
|
5
|
+
.content-col
|
6
|
+
%h3.columns-header Columns
|
7
|
+
|
8
|
+
.row
|
9
|
+
- @columns.each do |column|
|
10
|
+
- cache column do
|
11
|
+
.col-lg-4.column-box-wrap
|
12
|
+
.column-box{style: "background-image: url('#{column.image.url(:content)}');", data: {uri: column_url(column)}}
|
13
|
+
.overlay
|
14
|
+
.column-name
|
15
|
+
= column.name
|
16
|
+
.description= column.description
|
17
|
+
|
18
|
+
.rail-col
|
19
|
+
= render "/virgo/page_modules/popular_posts", tabbed: true, category: Virgo::Category.COLUMNS, tab: :category
|
@@ -0,0 +1,18 @@
|
|
1
|
+
- content_for :title do
|
2
|
+
= "#{site.name} | #{@column.name}"
|
3
|
+
|
4
|
+
- cache [@column, page_param] do
|
5
|
+
.container.posts-container.column-posts
|
6
|
+
.row
|
7
|
+
.col-md-10.col-md-offset-1
|
8
|
+
%h1.text-center.section-heading
|
9
|
+
.inner= @column.name
|
10
|
+
|
11
|
+
- @posts.each do |post|
|
12
|
+
= render '/virgo/posts/post_short', post: post
|
13
|
+
|
14
|
+
.pagination-wrap
|
15
|
+
= paginate @posts
|
16
|
+
|
17
|
+
- content_for :end_of_body do
|
18
|
+
= render '/virgo/common/disqus_comment_count'
|
@@ -0,0 +1,100 @@
|
|
1
|
+
- if admin_access?
|
2
|
+
%nav.admin-nav.navbar
|
3
|
+
.container-fluid
|
4
|
+
%ul.nav.navbar-nav
|
5
|
+
%li
|
6
|
+
= link_to virgo.root_path do
|
7
|
+
%i.fa.fa-home
|
8
|
+
Home
|
9
|
+
|
10
|
+
- if can? :index, Virgo::Post
|
11
|
+
%li{class: ('active' if controller?('virgo/admin/posts') && posts_action?)}
|
12
|
+
= link_to virgo.admin_posts_path do
|
13
|
+
%i.fa.fa-thumb-tack
|
14
|
+
Posts
|
15
|
+
|
16
|
+
%li{class: ('active' if controller?('virgo/admin/posts') && pages_action?)}
|
17
|
+
= link_to virgo.admin_posts_path(filters: {post_type: :page}) do
|
18
|
+
%i.fa.fa-file-o
|
19
|
+
Pages
|
20
|
+
|
21
|
+
%li{class: ('active' if controller?('virgo/admin/slideshows', 'admin/slides'))}
|
22
|
+
= link_to virgo.admin_slideshows_path do
|
23
|
+
%i.fa.fa-camera-retro
|
24
|
+
Slideshows
|
25
|
+
|
26
|
+
%li{class: ('active' if controller?('virgo/admin/categories'))}
|
27
|
+
= link_to virgo.admin_categories_path do
|
28
|
+
%i.fa.fa-archive
|
29
|
+
Categories
|
30
|
+
|
31
|
+
%li{class: ('active' if controller?('virgo/admin/tags'))}
|
32
|
+
= link_to virgo.admin_tags_path do
|
33
|
+
%i.fa.fa-tag
|
34
|
+
Tags
|
35
|
+
|
36
|
+
- if can? :index, Virgo::Column
|
37
|
+
%li{class: ('active' if controller?('virgo/admin/columns'))}
|
38
|
+
= link_to virgo.admin_columns_path do
|
39
|
+
%i.fa.fa-newspaper-o
|
40
|
+
Columns
|
41
|
+
|
42
|
+
- if can? :index, Virgo::User
|
43
|
+
%li{class: ('active' if controller?('virgo/admin/users'))}
|
44
|
+
= link_to virgo.admin_users_path do
|
45
|
+
%i.fa.fa-user
|
46
|
+
Users
|
47
|
+
|
48
|
+
%li{class: ('active' if controller?('virgo/admin/images'))}
|
49
|
+
= link_to virgo.admin_images_path do
|
50
|
+
%i.fa.fa-file-image-o
|
51
|
+
Media Library
|
52
|
+
|
53
|
+
- if can? :index, Virgo::Site
|
54
|
+
%li{class: ('active' if controller?('virgo/admin/sites', 'virgo/admin/page_modules', 'virgo/admin/newsletters'))}
|
55
|
+
= link_to virgo.admin_site_edit_path do
|
56
|
+
%i.fa.fa-wrench
|
57
|
+
Settings
|
58
|
+
|
59
|
+
%li{class: ('active' if action?('help'))}
|
60
|
+
= link_to virgo.admin_help_path do
|
61
|
+
%i.fa.fa-life-ring
|
62
|
+
Help
|
63
|
+
|
64
|
+
- if admin_access? && @post.present? && @post.persisted?
|
65
|
+
- if admin_view?
|
66
|
+
%li
|
67
|
+
= link_to virgo.post_detail_path(@post), class: 'edit-post-link pull-left' do
|
68
|
+
%i.fa.fa-eye
|
69
|
+
- if @post.page?
|
70
|
+
View Page
|
71
|
+
- else
|
72
|
+
View Post
|
73
|
+
- else
|
74
|
+
%li
|
75
|
+
= link_to virgo.edit_admin_post_path, class: 'edit-post-link pull-left' do
|
76
|
+
%i.fa.fa-pencil-square-o
|
77
|
+
Edit Post
|
78
|
+
|
79
|
+
.navbar-links.hidden-xs
|
80
|
+
.collapse.navbar-collapse
|
81
|
+
%ul#account-dropdown.nav.navbar-nav.navbar-right
|
82
|
+
%li.dropdown
|
83
|
+
%a#my-account.dropdown-toggle{data: {toggle: "dropdown"}}
|
84
|
+
Account
|
85
|
+
%i.fa.fa-chevron-down
|
86
|
+
|
87
|
+
%ul.dropdown-menu
|
88
|
+
- if user_signed_in?
|
89
|
+
- if admin_access?
|
90
|
+
%li
|
91
|
+
= link_to 'Admin', virgo.admin_posts_path
|
92
|
+
|
93
|
+
%li
|
94
|
+
= link_to "My Settings", virgo.edit_admin_user_path(current_user)
|
95
|
+
|
96
|
+
%li
|
97
|
+
= link_to "Home", virgo.root_path
|
98
|
+
|
99
|
+
%li
|
100
|
+
= link_to "Sign Out", virgo.destroy_user_session_path, data: {method: :delete}
|
@@ -0,0 +1,40 @@
|
|
1
|
+
-if flash and flash[:notice].present?
|
2
|
+
.container-fluid.alert-container
|
3
|
+
.row.alert-row.fade.in
|
4
|
+
.col-md-12
|
5
|
+
.alert.alert-success.flash
|
6
|
+
%a{:class => 'close', :data => {:dismiss => 'alert', :target => ".alert-row"}}
|
7
|
+
×
|
8
|
+
.inner-text
|
9
|
+
=flash[:notice]
|
10
|
+
|
11
|
+
-if flash and flash[:alert].present?
|
12
|
+
.container-fluid.alert-container
|
13
|
+
.row.alert-row.fade.in
|
14
|
+
.col-md-12
|
15
|
+
.alert.alert-danger.flash
|
16
|
+
%a{:class => 'close', :data => {:dismiss => 'alert', :target => ".alert-row"}}
|
17
|
+
×
|
18
|
+
.inner-text
|
19
|
+
=flash[:alert]
|
20
|
+
|
21
|
+
-if flash and flash[:warning].present?
|
22
|
+
.container-fluid.alert-container
|
23
|
+
.row.alert-row.fade.in
|
24
|
+
.col-md-12
|
25
|
+
.alert.alert-danger.flash
|
26
|
+
%a{:class => 'close', :data => {:dismiss => 'alert', :target => ".alert-row"}}
|
27
|
+
×
|
28
|
+
.inner-text
|
29
|
+
=flash[:warning]
|
30
|
+
|
31
|
+
-if flash and flash[:validation_errors].present?
|
32
|
+
.container-fluid.alert-container
|
33
|
+
.row.alert-row.fade.in
|
34
|
+
.col-md-12
|
35
|
+
.alert.alert-danger.flash.validation-errors
|
36
|
+
%a{:class => 'close', :data => {:dismiss => 'alert', :target => ".alert-row"}}
|
37
|
+
×
|
38
|
+
.inner-text
|
39
|
+
=flash[:validation_errors]
|
40
|
+
|
@@ -0,0 +1 @@
|
|
1
|
+
<%# You can override this template with your custom analytics code %>
|
@@ -0,0 +1,8 @@
|
|
1
|
+
- if record.present? && record.errors[:base].any?
|
2
|
+
.alert.base-errors.alert-danger.flash.fade.in.alert-dismissible
|
3
|
+
%a{:class => 'close', :data => {:dismiss => 'alert'}}
|
4
|
+
×
|
5
|
+
.inner-text
|
6
|
+
- record.errors[:base].each do |message|
|
7
|
+
.error-message= message
|
8
|
+
|
@@ -0,0 +1,26 @@
|
|
1
|
+
- if local_assigns.has_key?(:post)
|
2
|
+
- @feature = post
|
3
|
+
|
4
|
+
- if @feature
|
5
|
+
- category = local_assigns.has_key?(:category) ? category : @feature.primary_category
|
6
|
+
|
7
|
+
- cache @feature do
|
8
|
+
- if @feature
|
9
|
+
.feature-heading-container.category-heading
|
10
|
+
- if @feature.featured_image && @feature.featured_image.credit.present?
|
11
|
+
.photo-credit= raw @feature.featured_image.credit
|
12
|
+
%a.feature-heading{href: expanded_post_url(@feature)}
|
13
|
+
.feature-heading-img-box{style: "background-image: url('#{@feature.featured_image.try(:image).try(:url, :wide)}');"}
|
14
|
+
.feature-heading-inner
|
15
|
+
.container-fluid
|
16
|
+
- # unfortunately this double wrapping is required to vertically center this auto-height element
|
17
|
+
.feature-post-wrap
|
18
|
+
- if category
|
19
|
+
.category-wrap.big-tag
|
20
|
+
%span.category-name= category.name
|
21
|
+
.feature-post-box{class: ("#{' long-headline' if @feature.headline.length > 42}#{' short-headline' if @feature.headline.length < 21}#{' extralong-headline' if @feature.headline.length > 91}")}
|
22
|
+
%h2.post-headline
|
23
|
+
%span.outer
|
24
|
+
%span.inner= @feature.headline
|
25
|
+
.read-story-link Read Story
|
26
|
+
|
@@ -0,0 +1,24 @@
|
|
1
|
+
<div id="disqus_thread"></div>
|
2
|
+
<script type="text/javascript">
|
3
|
+
|
4
|
+
function disqus_config() {
|
5
|
+
this.callbacks.onReady = [function() {
|
6
|
+
setTimeout(function(){
|
7
|
+
$(document).trigger("disqusready");
|
8
|
+
}, 150);
|
9
|
+
}];
|
10
|
+
}
|
11
|
+
|
12
|
+
/* * * CONFIGURATION VARIABLES * * */
|
13
|
+
var disqus_shortname = '<%= site.disqus_app_id %>';
|
14
|
+
|
15
|
+
var disqus_identifier = "<%= @post.disqus_identifier %>";
|
16
|
+
|
17
|
+
/* * * DON'T EDIT BELOW THIS LINE * * */
|
18
|
+
(function() {
|
19
|
+
var dsq = document.createElement('script'); dsq.type = 'text/javascript'; dsq.async = true;
|
20
|
+
dsq.src = '//' + disqus_shortname + '.disqus.com/embed.js';
|
21
|
+
(document.getElementsByTagName('head')[0] || document.getElementsByTagName('body')[0]).appendChild(dsq);
|
22
|
+
})();
|
23
|
+
</script>
|
24
|
+
<noscript>Please enable JavaScript to view the <a href="https://disqus.com/?ref_noscript" rel="nofollow">comments powered by Disqus.</a></noscript>
|
@@ -0,0 +1,12 @@
|
|
1
|
+
<script type="text/javascript">
|
2
|
+
/* * * CONFIGURATION VARIABLES * * */
|
3
|
+
var disqus_shortname = '<%= site.disqus_app_id %>';
|
4
|
+
|
5
|
+
/* * * DON'T EDIT BELOW THIS LINE * * */
|
6
|
+
(function () {
|
7
|
+
var s = document.createElement('script'); s.async = true;
|
8
|
+
s.type = 'text/javascript';
|
9
|
+
s.src = '//' + disqus_shortname + '.disqus.com/count.js';
|
10
|
+
(document.getElementsByTagName('HEAD')[0] || document.getElementsByTagName('BODY')[0]).appendChild(s);
|
11
|
+
}());
|
12
|
+
</script>
|
@@ -0,0 +1,30 @@
|
|
1
|
+
<% if Rails.application.secrets.facebook_app_id.present? %>
|
2
|
+
<script>
|
3
|
+
window.fbAsyncInit = function() {
|
4
|
+
FB.init({
|
5
|
+
appId : '<%= Rails.application.secrets.facebook_app_id %>',
|
6
|
+
xfbml : true,
|
7
|
+
version : 'v2.3'
|
8
|
+
});
|
9
|
+
};
|
10
|
+
|
11
|
+
(function(d, s, id){
|
12
|
+
var js, fjs = d.getElementsByTagName(s)[0];
|
13
|
+
if (d.getElementById(id)) {return;}
|
14
|
+
js = d.createElement(s); js.id = id;
|
15
|
+
js.src = "//connect.facebook.net/en_US/sdk.js";
|
16
|
+
fjs.parentNode.insertBefore(js, fjs);
|
17
|
+
}(document, 'script', 'facebook-jssdk'));
|
18
|
+
</script>
|
19
|
+
|
20
|
+
<div id="fb-root"></div>
|
21
|
+
<script>(function(d, s, id) {
|
22
|
+
var js, fjs = d.getElementsByTagName(s)[0];
|
23
|
+
if (d.getElementById(id)) return;
|
24
|
+
js = d.createElement(s); js.id = id;
|
25
|
+
js.src = "//connect.facebook.net/en_US/sdk.js#xfbml=1&version=v2.3&appId=<%= Rails.application.secrets.facebook_app_id %>";
|
26
|
+
fjs.parentNode.insertBefore(js, fjs);
|
27
|
+
}(document, 'script', 'facebook-jssdk'));</script>
|
28
|
+
<% else %>
|
29
|
+
<script> window.fb_api_disabled = true </script>
|
30
|
+
<% end %>
|
@@ -0,0 +1 @@
|
|
1
|
+
<%= stylesheet_link_tag "//fonts.googleapis.com/css?family=Open+Sans:300,400italic,600italic,700italic,400,600,700,800|Montserrat:400,700" %>
|
@@ -0,0 +1,13 @@
|
|
1
|
+
%footer#footer.page-group
|
2
|
+
.inner.container-fluid
|
3
|
+
.row
|
4
|
+
.col-sm-4.col-md-offset-8
|
5
|
+
-# %ul.footer-list.footer-right
|
6
|
+
- # %li You can add your
|
7
|
+
- # %li custom footer links
|
8
|
+
- # %li here
|
9
|
+
|
10
|
+
= render '/virgo/common/analytics'
|
11
|
+
|
12
|
+
= render '/virgo/common/fb_api'
|
13
|
+
= render '/virgo/common/ouibounce_modal'
|
File without changes
|
@@ -0,0 +1,9 @@
|
|
1
|
+
<% if Rails.env.production? && !is_admin_view? %>
|
2
|
+
<script type="text/javascript">
|
3
|
+
!function(){var analytics=window.analytics=window.analytics||[];if(!analytics.initialize)if(analytics.invoked)window.console&&console.error&&console.error("Segment snippet included twice.");else{analytics.invoked=!0;analytics.methods=["trackSubmit","trackClick","trackLink","trackForm","pageview","identify","group","track","ready","alias","page","once","off","on"];analytics.factory=function(t){return function(){var e=Array.prototype.slice.call(arguments);e.unshift(t);analytics.push(e);return analytics}};for(var t=0;t<analytics.methods.length;t++){var e=analytics.methods[t];analytics[e]=analytics.factory(e)}analytics.load=function(t){var e=document.createElement("script");e.type="text/javascript";e.async=!0;e.src=("https:"===document.location.protocol?"https://":"http://")+"cdn.segment.com/analytics.js/v1/"+t+"/analytics.min.js";var n=document.getElementsByTagName("script")[0];n.parentNode.insertBefore(e,n)};analytics.SNIPPET_VERSION="3.0.1";
|
4
|
+
analytics.load("<%= Rails.application.secrets.segment_write_key %>");
|
5
|
+
analytics.page()
|
6
|
+
}}();
|
7
|
+
</script>
|
8
|
+
<script type='text/javascript'>var _sf_startpt=(new Date()).getTime()</script>
|
9
|
+
<% end %>
|
@@ -0,0 +1,20 @@
|
|
1
|
+
.list-signup.page-group
|
2
|
+
.inner
|
3
|
+
.row
|
4
|
+
.col-sm-3
|
5
|
+
.title-wrap
|
6
|
+
%h2.title
|
7
|
+
.weekly
|
8
|
+
Newsletter
|
9
|
+
%br
|
10
|
+
Signup
|
11
|
+
.clear
|
12
|
+
.col-sm-9
|
13
|
+
.copy Sign up to get our weekly newsletter.
|
14
|
+
= simple_form_for (@subscriber || Subscriber.new), url: virgo.subscribers_path, html: {id: 'list-signup-form'} do |f|
|
15
|
+
.input-btn-append.inverse.email-input-wrap
|
16
|
+
= f.text_field :email, class: 'email-input', placeholder: "Your Email Address"
|
17
|
+
= f.button :submit, "Sign Up", class: "sign-up-btn", 'data-loading-text' => "Loading"
|
18
|
+
.list-signup-message.success
|
19
|
+
Thanks! You’ve signed up successfully.
|
20
|
+
.list-signup-message.error
|
@@ -0,0 +1,26 @@
|
|
1
|
+
#ouibounce-modal.campaign-prompt
|
2
|
+
.underlay
|
3
|
+
.ouibounce-modal.campaign-prompt-modal
|
4
|
+
%a.ouibounce-close.js-close-modal{href: "#"}
|
5
|
+
%i.fa.fa-times
|
6
|
+
.ouibounce-modal-body
|
7
|
+
.header-wrap.text-center
|
8
|
+
%h2.primary-head.text-center Hey!
|
9
|
+
%p.copy.text-center Keep up to date with a weekly digest email of our hottest stories.
|
10
|
+
= simple_form_for (@subscriber || Virgo::Subscriber.new), url: virgo.subscribers_path, html: {class: 'list-signup-form js-list-signup-form ouibounce-list-signup-form', id: 'ouibounce-list-signup-form'} do |f|
|
11
|
+
.input-btn-append.inverse.email-input-wrap
|
12
|
+
= f.text_field :email, class: 'email-input', placeholder: "Your Email Address"
|
13
|
+
= f.button :submit, "Sign Up", class: "sign-up-btn", 'data-loading-text' => "Loading"
|
14
|
+
|
15
|
+
.list-signup-message.info
|
16
|
+
%span.desktop-copy
|
17
|
+
Subscribe to our weekly newsletter
|
18
|
+
%span.mobile-copy
|
19
|
+
Subscribe to our weekly newsletter
|
20
|
+
.list-signup-message.success
|
21
|
+
%i.fa.fa-check
|
22
|
+
Thank you for joining the newsletter!
|
23
|
+
.list-signup-message.error
|
24
|
+
|
25
|
+
.ouibounce-modal-footer
|
26
|
+
%a.js-close-modal.js-ouibounce-footer-button{href: '#'} No thanks, I’m just too tired.
|