-
-
Save jronallo/1804715 to your computer and use it in GitHub Desktop.
Refinery + Twitter Bootstrap WIP
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<head> | |
<meta charset='<%= Rails.application.config.encoding %>' /> | |
<!--[if IE]><meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1" /><![endif]--> | |
<title><%= browser_title(yield(:title)) %></title> | |
<%= raw(%(<meta name="description" content="#{@meta.meta_description}" />)) if @meta.meta_description.present? -%> | |
<%= raw(%(<meta name="keywords" content="#{@meta.meta_keywords}">)) if @meta.meta_keywords.present? -%> | |
<%= raw(%(<link rel="canonical" content="#{@canonical}" />)) if @canonical.present? -%> | |
<%= csrf_meta_tags if Refinery::Core.authenticity_token_on_frontend -%> | |
<%= yield :meta %> | |
<%= stylesheet_link_tag "application" %> | |
<%= yield :stylesheets %> | |
<%= render :partial => '/refinery/google_analytics' %> | |
<%= javascript_include_tag 'modernizr-min' %> | |
</head> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<%= render(:partial => "/refinery/menu", :locals => { | |
:dom_id => 'menu', | |
:css => 'menu' | |
}) %> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
module ApplicationHelper | |
def custom_menu_branch_css(local_assigns) | |
options = local_assigns.dup | |
options.update(:sibling_count => options[:menu_branch].shown_siblings.length) unless options[:sibling_count] | |
css = [] | |
css << 'active' if selected_page_or_descendant_page_selected?(local_assigns[:menu_branch]) | |
css | |
end | |
end |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
source 'https://rubygems.org' | |
gem 'rails', '3.2.1' | |
# Bundle edge Rails instead: | |
# gem 'rails', :git => 'git://github.com/rails/rails.git' | |
gem 'sqlite3' | |
# Gems used only for assets and not required | |
# in production environments by default. | |
group :assets do | |
gem 'sass-rails', '~> 3.2.3' | |
gem 'coffee-rails', '~> 3.2.1' | |
# See https://github.com/sstephenson/execjs#readme for more supported runtimes | |
# gem 'therubyracer' | |
gem 'uglifier', '>= 1.0.3' | |
end | |
gem 'jquery-rails' | |
# To use ActiveModel has_secure_password | |
# gem 'bcrypt-ruby', '~> 3.0.0' | |
# To use Jbuilder templates for JSON | |
# gem 'jbuilder' | |
# Use unicorn as the web server | |
# gem 'unicorn' | |
# Deploy with Capistrano | |
# gem 'capistrano' | |
# To use debugger | |
gem 'ruby-debug19', :require => 'ruby-debug' | |
gem 'therubyracer' | |
gem 'refinerycms', :git => 'git://github.com/resolve/refinerycms.git' | |
# group :development, :test do | |
# gem 'refinerycms-testing', '~> 2.0' | |
# end | |
# USER DEFINED | |
gem 'twitter-bootstrap-rails' | |
# Add i18n support (optional, you can remove this if you really want to but it is advised to keep it). | |
gem 'refinerycms-i18n', '~> 2.0.0', :git => 'git://github.com/parndt/refinerycms-i18n.git' | |
# Specify additional Refinery CMS Engines here (all optional): | |
# gem 'refinerycms-blog', :git => 'git://github.com/resolve/refinerycms-blog.git', :branch => 'rails-3-1' | |
# gem 'refinerycms-inquiries', :git => 'git://github.com/resolve/refinerycms-inquiries.git', :branch => 'rails-3-1' | |
# gem 'refinerycms-search', :git => 'git://github.com/resolve/refinerycms-search.git', :branch => 'rails-3-1' | |
# gem 'refinerycms-page-images', :git => 'git://github.com/resolve/refinerycms-page-images.git', :branch => 'rails-3-1' | |
# END USER DEFINED |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE html> | |
<%= render :partial => '/refinery/html_tag' %> | |
<% site_bar = render(:partial => '/refinery/site_bar', :locals => {:head => true}) -%> | |
<%= render :partial => '/refinery/head' %> | |
<body> | |
<%= site_bar -%> | |
<header id="header"> | |
<%= render :partial => '/refinery/header' -%> | |
</header> | |
<div class="container"> | |
<div class="content"> | |
<div class="row"> | |
<div class="span11"> | |
<%= yield %> | |
</div> | |
<div class="span1"> </div> | |
<div class="span4"> | |
<h3>Sidebar</h3> | |
<ul> | |
<li><%= link_to "Link1", "/path1" %></li> | |
<li><%= link_to "Link2", "/path2" %></li> | |
<li><%= link_to "Link3", "/path3" %></li> | |
</ul> | |
</div> | |
</div> | |
<footer> | |
<%= render :partial => '/refinery/footer' -%> | |
</footer> | |
</div> | |
</div> | |
<%= render :partial => '/refinery/javascripts' %> | |
</body> | |
</html> |
Hi,
I've never used this. I just created this form of someone else's gist
so that I would have it around. You might ask whoever I forked this
from. I intend on using Twitter Bootstrap in Refinery, but haven't
done so yet.
Jason
…On Tue, May 1, 2012 at 12:46 PM, elmo ***@***.*** wrote:
Hello Jranallo,
Thanks for posting this. I notice that you've appended a 'WIP' at the end. Would you consider this stable enough to use now, or should I wait a bit?
Best,
Elmo
---
Reply to this email directly or view it on GitHub:
https://gist.github.com/1804715
Thanks for getting back to me. I intend to do the same. I'll let you know how it goes.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Hello Jranallo,
Thanks for posting this. I notice that you've appended a 'WIP' at the end. Would you consider this stable enough to use now, or should I wait a bit?
Best,
Elmo