mirror of
https://github.com/fspc/BikeShed-1.git
synced 2025-02-28 08:43:23 -05:00
Bootstrap 3 setup.
This commit is contained in:
parent
40a22e8b78
commit
508a1d8d06
16
Gemfile
16
Gemfile
@ -19,18 +19,12 @@ gem 'pg', '~> 0.17.1'
|
||||
gem 'will_paginate', '~> 3.0.3'
|
||||
gem 'jbuilder', '~> 2.0.3'
|
||||
|
||||
# Gems used only for assets and not required
|
||||
# in production environments by default.
|
||||
group :assets do
|
||||
gem 'sass-rails', '~> 3.0'
|
||||
gem 'coffee-rails', '~> 3.2.1'
|
||||
gem 'bootstrap-sass', '~> 3.1.1'
|
||||
# Assets
|
||||
gem 'sass-rails', '~> 3.0'
|
||||
gem 'coffee-rails', '~> 3.2.1'
|
||||
gem 'bootstrap-sass', '~> 3.1.1'
|
||||
|
||||
# See https://github.com/sstephenson/execjs#readme for more supported runtimes
|
||||
# gem 'therubyracer'
|
||||
|
||||
gem 'uglifier', '>= 1.0.3'
|
||||
end
|
||||
gem 'uglifier', '>= 1.0.3'
|
||||
|
||||
group :development, :test do
|
||||
gem 'rspec-rails', '~> 2.14.0'
|
||||
|
@ -12,8 +12,7 @@
|
||||
//
|
||||
//= require jquery
|
||||
//= require jquery_ujs
|
||||
//= require twitter/bootstrap/bootstrap-button
|
||||
//= require twitter/bootstrap/bootstrap-modal
|
||||
//= require bootstrap
|
||||
//= require utils
|
||||
//= require bootstrap-datepicker
|
||||
//= require bootstrap-timepicker
|
||||
|
@ -1,15 +0,0 @@
|
||||
/*
|
||||
* This is a manifest file that'll be compiled into application.css, which will include all the files
|
||||
* listed below.
|
||||
*
|
||||
* Any CSS and SCSS file within this directory, lib/assets/stylesheets, vendor/assets/stylesheets,
|
||||
* or vendor/assets/stylesheets of plugins, if any, can be referenced here using a relative path.
|
||||
*
|
||||
* You're free to add application-wide styles to this file and they'll appear at the top of the
|
||||
* compiled file, but it's generally better to create a new file per style scope.
|
||||
*
|
||||
*= require_self
|
||||
*= require datepicker
|
||||
*= require bootstrap-timepicker
|
||||
*= require bootstrap_and_overrides
|
||||
*/
|
4
app/assets/stylesheets/application.scss
Normal file
4
app/assets/stylesheets/application.scss
Normal file
@ -0,0 +1,4 @@
|
||||
@import "bootstrap";
|
||||
@import "datepicker";
|
||||
@import "bootstrap-timepicker";
|
||||
@import "frontend";
|
@ -1,47 +0,0 @@
|
||||
@import "twitter/bootstrap/bootstrap";
|
||||
body {
|
||||
padding-top: 60px;
|
||||
padding-left: 20px;
|
||||
}
|
||||
|
||||
@import "twitter/bootstrap/responsive";
|
||||
|
||||
// Set the correct sprite paths
|
||||
@iconSpritePath: asset-path('twitter/bootstrap/glyphicons-halflings.png');
|
||||
@iconWhiteSpritePath: asset-path('twitter/bootstrap/glyphicons-halflings-white.png');
|
||||
|
||||
// Set the Font Awesome (Font Awesome is default. You can disable by commenting below lines)
|
||||
// Note: If you use asset_path() here, your compiled boostrap_and_overrides.css will not
|
||||
// have the proper paths. So for now we use the absolute path.
|
||||
@fontAwesomeEotPath: '/assets/fontawesome-webfont.eot';
|
||||
@fontAwesomeWoffPath: '/assets/fontawesome-webfont.woff';
|
||||
@fontAwesomeTtfPath: '/assets/fontawesome-webfont.ttf';
|
||||
@fontAwesomeSvgPath: '/assets/fontawesome-webfont.svg';
|
||||
|
||||
// Font Awesome
|
||||
@import "fontawesome";
|
||||
|
||||
// Your custom LESS stylesheets goes here
|
||||
//
|
||||
// Since bootstrap was imported above you have access to its mixins which
|
||||
// you may use and inherit here
|
||||
//
|
||||
// If you'd like to override bootstrap's own variables, you can do so here as well
|
||||
// See http://twitter.github.com/bootstrap/less.html for their names and documentation
|
||||
//
|
||||
// Example:
|
||||
// @linkColor: #ff0000;
|
||||
|
||||
[data-toggle="buttons-radio"] > .btn > input[type="radio"],
|
||||
[data-toggle="buttons"] > .btn > input[type="checkbox"] {
|
||||
display: none;
|
||||
}
|
||||
|
||||
.inline-block {
|
||||
display: inline-block;
|
||||
}
|
||||
|
||||
.control-group.error .btn-group > .btn {
|
||||
color: #b94a48;
|
||||
border-color: #b94a48;
|
||||
}
|
7
app/assets/stylesheets/frontend.scss
Normal file
7
app/assets/stylesheets/frontend.scss
Normal file
@ -0,0 +1,7 @@
|
||||
body {
|
||||
padding-top: 5px;
|
||||
}
|
||||
|
||||
.x-boundlist-item {
|
||||
white-space: nowrap;
|
||||
}
|
@ -1,5 +1,3 @@
|
||||
<%= stylesheet_link_tag "bootstrap_and_overrides", :media => "all" %>
|
||||
|
||||
<h2>Forgot your password?</h2>
|
||||
<br>
|
||||
<br>
|
||||
|
@ -1,5 +1,3 @@
|
||||
<%= stylesheet_link_tag "bootstrap_and_overrides", :media => "all" %>
|
||||
|
||||
<h2>Edit <%= resource_name.to_s.humanize %></h2>
|
||||
|
||||
<%= form_for(resource, :as => resource_name, :url => registration_path(resource_name), :html => { :method => :put }) do |f| %>
|
||||
|
@ -1,4 +1,3 @@
|
||||
= stylesheet_link_tag "bootstrap_and_overrides", :media => "all"
|
||||
= form_for(resource, :as => resource_name, :url => registration_path(resource_name)) do |f|
|
||||
= devise_error_messages!
|
||||
.controls
|
||||
|
@ -1,5 +1,3 @@
|
||||
<%= stylesheet_link_tag "bootstrap_and_overrides", :media => "all" %>
|
||||
|
||||
<h2>Velocipede</h2>
|
||||
<a href="http://madewithloveinbaltimore.org">Made with ♥ in Baltimore</a>
|
||||
<br>
|
||||
|
@ -1,29 +1,22 @@
|
||||
!!! 5
|
||||
%html{:lang => "en"}
|
||||
%html{lang: 'en'}
|
||||
%head
|
||||
%meta{:charset => "utf-8"}/
|
||||
%meta{ name: "viewport", content: "width=device-width", "initial-scale" => "1.0"}
|
||||
%title= content_for?(:title) ? yield(:title) : "Velocipede"
|
||||
%meta{charset: 'utf-8'}/
|
||||
%meta{name: 'viewport', content: 'width=device-width', "initial-scale": '1.0'}
|
||||
%title= content_for?(:title) ? yield(:title) : 'Velocipede'
|
||||
= csrf_meta_tags
|
||||
= stylesheet_link_tag "bootstrap_and_overrides", "datepicker", "bootstrap-timepicker", :media => "all"
|
||||
= stylesheet_link_tag 'application', media: 'all'
|
||||
/[if lt IE 9]
|
||||
= javascript_include_tag "http://html5shim.googlecode.com/svn/trunk/html5.js"
|
||||
:css
|
||||
body {
|
||||
padding-top: 5px;
|
||||
}
|
||||
.x-boundlist-item {
|
||||
white-space: nowrap;
|
||||
}
|
||||
= javascript_include_tag 'http://html5shim.googlecode.com/svn/trunk/html5.js'
|
||||
|
||||
%body
|
||||
.container
|
||||
|
||||
.content
|
||||
- if flash[:notice]
|
||||
%p{:class => 'notice'}= flash[:notice]
|
||||
%p{class: 'notice'}= flash[:notice]
|
||||
- if flash[:alert]
|
||||
%p{:class => 'alert'}= flash[:alert]
|
||||
%p{class: 'alert'}= flash[:alert]
|
||||
.row
|
||||
.span12
|
||||
= yield
|
||||
@ -31,5 +24,5 @@
|
||||
%footer
|
||||
%p © BikeShed #{Time.now.year}
|
||||
|
||||
= javascript_include_tag "application"
|
||||
= javascript_include_tag 'application'
|
||||
= javascript_include_tag params[:controller]
|
||||
|
@ -1,4 +1,3 @@
|
||||
= stylesheet_link_tag "bootstrap_and_overrides", :media => "all"
|
||||
%h2 Dashboard
|
||||
|
||||
%p
|
||||
|
@ -62,5 +62,8 @@ module Velocipede
|
||||
|
||||
# Version of your assets, change this if you want to expire all your assets
|
||||
config.assets.version = '1.0'
|
||||
|
||||
# Enabled for bootstrap-sass gem
|
||||
config.assets.initialize_on_precompile
|
||||
end
|
||||
end
|
||||
|
Loading…
x
Reference in New Issue
Block a user