quick-templater 0.0.5

Sign up to get free protection for your applications and to get access to all the features.
Files changed (42) hide show
  1. checksums.yaml +7 -0
  2. data/.gitignore +18 -0
  3. data/.rspec +2 -0
  4. data/.travis.yml +6 -0
  5. data/Gemfile +11 -0
  6. data/LICENSE.txt +22 -0
  7. data/README.md +53 -0
  8. data/Rakefile +1 -0
  9. data/app/assets/stylesheets/quick-templater/bootstrap3/carousel.css +148 -0
  10. data/app/assets/stylesheets/quick-templater/bootstrap3/jumbotron.css +4 -0
  11. data/app/assets/stylesheets/quick-templater/bootstrap3/justified_nav.css +88 -0
  12. data/app/assets/stylesheets/quick-templater/bootstrap3/narrow_jumbotron.css +79 -0
  13. data/app/assets/stylesheets/quick-templater/bootstrap3/navbar.css +8 -0
  14. data/app/assets/stylesheets/quick-templater/bootstrap3/navbar_fixed_top.css +4 -0
  15. data/app/assets/stylesheets/quick-templater/bootstrap3/navbar_static_top.css +7 -0
  16. data/app/assets/stylesheets/quick-templater/bootstrap3/non_responsive.css +120 -0
  17. data/app/assets/stylesheets/quick-templater/bootstrap3/offcanvas.css +51 -0
  18. data/app/assets/stylesheets/quick-templater/bootstrap3/sign_in_page.css +40 -0
  19. data/app/assets/stylesheets/quick-templater/bootstrap3/starter.css +7 -0
  20. data/app/assets/stylesheets/quick-templater/bootstrap3/sticky_footer.css +38 -0
  21. data/app/assets/stylesheets/quick-templater/bootstrap3/sticky_footer_navbar.css +46 -0
  22. data/lib/generators/quick-templater/layout/layout_generator.rb +64 -0
  23. data/lib/generators/quick-templater/layout/templates/bootstrap3/carousel.html.erb +186 -0
  24. data/lib/generators/quick-templater/layout/templates/bootstrap3/jumbotron.html.erb +79 -0
  25. data/lib/generators/quick-templater/layout/templates/bootstrap3/justified_nav.html.erb +67 -0
  26. data/lib/generators/quick-templater/layout/templates/bootstrap3/narrow_jumbotron.html.erb +65 -0
  27. data/lib/generators/quick-templater/layout/templates/bootstrap3/navbar.html.erb +68 -0
  28. data/lib/generators/quick-templater/layout/templates/bootstrap3/navbar_fixed_top.html.erb +71 -0
  29. data/lib/generators/quick-templater/layout/templates/bootstrap3/navbar_static_top.html.erb +72 -0
  30. data/lib/generators/quick-templater/layout/templates/bootstrap3/non_responsive.html.erb +78 -0
  31. data/lib/generators/quick-templater/layout/templates/bootstrap3/offcanvas.html.erb +110 -0
  32. data/lib/generators/quick-templater/layout/templates/bootstrap3/quick-templater.css.erb +8 -0
  33. data/lib/generators/quick-templater/layout/templates/bootstrap3/sign_in_page.html.erb +34 -0
  34. data/lib/generators/quick-templater/layout/templates/bootstrap3/starter.html.erb +48 -0
  35. data/lib/generators/quick-templater/layout/templates/bootstrap3/sticky_footer.html.erb +37 -0
  36. data/lib/generators/quick-templater/layout/templates/bootstrap3/sticky_footer_navbar.html.erb +71 -0
  37. data/lib/quick-templater/version.rb +3 -0
  38. data/lib/quick-templater.rb +7 -0
  39. data/quick-templater.gemspec +25 -0
  40. data/spec/generators/layout_spec.rb +42 -0
  41. data/spec/spec_helper.rb +8 -0
  42. metadata +128 -0
@@ -0,0 +1,71 @@
1
+ <!DOCTYPE html>
2
+ <html lang="en">
3
+ <head>
4
+ <meta charset="utf-8">
5
+ <meta http-equiv="X-UA-Compatible" content="IE=edge">
6
+ <meta name="viewport" content="width=device-width, initial-scale=1.0">
7
+
8
+ <title><%= options.app_name %></title>
9
+
10
+ <%%= stylesheet_link_tag "application", media: "all", "data-turbolinks-track" => true %>
11
+ <%%= stylesheet_link_tag "quick-templater", media: "all", "data-turbolinks-track" => true %>
12
+ <%%= javascript_include_tag "application", "data-turbolinks-track" => true %>
13
+ <%%= csrf_meta_tag %>
14
+ </head>
15
+
16
+ <body>
17
+
18
+ <!-- Fixed navbar -->
19
+ <div class="navbar navbar-default navbar-fixed-top" role="navigation">
20
+ <div class="container">
21
+ <div class="navbar-header">
22
+ <button type="button" class="navbar-toggle" data-toggle="collapse" data-target=".navbar-collapse">
23
+ <span class="sr-only">Toggle navigation</span>
24
+ <span class="icon-bar"></span>
25
+ <span class="icon-bar"></span>
26
+ <span class="icon-bar"></span>
27
+ </button>
28
+ <a class="navbar-brand" href="#"><%= options.app_name %></a>
29
+ </div>
30
+ <div class="navbar-collapse collapse">
31
+ <ul class="nav navbar-nav">
32
+ <li class="active"><a href="#">Home</a></li>
33
+ <li><a href="#about">About</a></li>
34
+ <li><a href="#contact">Contact</a></li>
35
+ <li class="dropdown">
36
+ <a href="#" class="dropdown-toggle" data-toggle="dropdown">Dropdown <b class="caret"></b></a>
37
+ <ul class="dropdown-menu">
38
+ <li><a href="#">Action</a></li>
39
+ <li><a href="#">Another action</a></li>
40
+ <li><a href="#">Something else here</a></li>
41
+ <li class="divider"></li>
42
+ <li class="dropdown-header">Nav header</li>
43
+ <li><a href="#">Separated link</a></li>
44
+ <li><a href="#">One more separated link</a></li>
45
+ </ul>
46
+ </li>
47
+ </ul>
48
+ <ul class="nav navbar-nav navbar-right">
49
+ <li><a href="#">Default</a></li>
50
+ <li><a href="#">Static top</a></li>
51
+ <li class="active"><a href="#">Fixed top</a></li>
52
+ </ul>
53
+ </div><!--/.nav-collapse -->
54
+ </div>
55
+ </div>
56
+
57
+ <div class="container">
58
+
59
+ <!-- Main component for a primary marketing message or call to action -->
60
+ <div class="jumbotron">
61
+ <h1>Navbar example</h1>
62
+ <p>This example is a quick exercise to illustrate how the default, static and fixed to top navbar work. It includes the responsive CSS and HTML, so it also adapts to your viewport and device.</p>
63
+ <p>To see the difference between static and fixed top navbars, just scroll.</p>
64
+ <p>
65
+ <a class="btn btn-lg btn-primary" href="../../components/#navbar" role="button">View navbar docs &raquo;</a>
66
+ </p>
67
+ </div>
68
+
69
+ </div> <!-- /container -->
70
+ </body>
71
+ </html>
@@ -0,0 +1,72 @@
1
+ <!DOCTYPE html>
2
+ <html lang="en">
3
+ <head>
4
+ <meta charset="utf-8">
5
+ <meta http-equiv="X-UA-Compatible" content="IE=edge">
6
+ <meta name="viewport" content="width=device-width, initial-scale=1.0">
7
+
8
+ <title><%= options.app_name %></title>
9
+
10
+ <%%= stylesheet_link_tag "application", media: "all", "data-turbolinks-track" => true %>
11
+ <%%= stylesheet_link_tag "quick-templater", media: "all", "data-turbolinks-track" => true %>
12
+ <%%= javascript_include_tag "application", "data-turbolinks-track" => true %>
13
+ <%%= csrf_meta_tag %>
14
+ </head>
15
+
16
+ <body>
17
+
18
+ <!-- Static navbar -->
19
+ <div class="navbar navbar-default navbar-static-top" role="navigation">
20
+ <div class="container">
21
+ <div class="navbar-header">
22
+ <button type="button" class="navbar-toggle" data-toggle="collapse" data-target=".navbar-collapse">
23
+ <span class="sr-only">Toggle navigation</span>
24
+ <span class="icon-bar"></span>
25
+ <span class="icon-bar"></span>
26
+ <span class="icon-bar"></span>
27
+ </button>
28
+ <a class="navbar-brand" href="#"><%= options.app_name %></a>
29
+ </div>
30
+ <div class="navbar-collapse collapse">
31
+ <ul class="nav navbar-nav">
32
+ <li class="active"><a href="#">Home</a></li>
33
+ <li><a href="#about">About</a></li>
34
+ <li><a href="#contact">Contact</a></li>
35
+ <li class="dropdown">
36
+ <a href="#" class="dropdown-toggle" data-toggle="dropdown">Dropdown <b class="caret"></b></a>
37
+ <ul class="dropdown-menu">
38
+ <li><a href="#">Action</a></li>
39
+ <li><a href="#">Another action</a></li>
40
+ <li><a href="#">Something else here</a></li>
41
+ <li class="divider"></li>
42
+ <li class="dropdown-header">Nav header</li>
43
+ <li><a href="#">Separated link</a></li>
44
+ <li><a href="#">One more separated link</a></li>
45
+ </ul>
46
+ </li>
47
+ </ul>
48
+ <ul class="nav navbar-nav navbar-right">
49
+ <li><a href="#">Default</a></li>
50
+ <li class="active"><a href="#">Static top</a></li>
51
+ <li><a href="#">Fixed top</a></li>
52
+ </ul>
53
+ </div><!--/.nav-collapse -->
54
+ </div>
55
+ </div>
56
+
57
+
58
+ <div class="container">
59
+
60
+ <!-- Main component for a primary marketing message or call to action -->
61
+ <div class="jumbotron">
62
+ <h1>Navbar example</h1>
63
+ <p>This example is a quick exercise to illustrate how the default, static and fixed to top navbar work. It includes the responsive CSS and HTML, so it also adapts to your viewport and device.</p>
64
+ <p>To see the difference between static and fixed top navbars, just scroll.</p>
65
+ <p>
66
+ <a class="btn btn-lg btn-primary" href="../../components/#navbar" role="button">View navbar docs &raquo;</a>
67
+ </p>
68
+ </div>
69
+
70
+ </div> <!-- /container -->
71
+ </body>
72
+ </html>
@@ -0,0 +1,78 @@
1
+ <!DOCTYPE html>
2
+ <html lang="en">
3
+ <head>
4
+ <meta charset="utf-8">
5
+ <meta http-equiv="X-UA-Compatible" content="IE=edge">
6
+
7
+ <title><%= options.app_name %></title>
8
+
9
+ <%%= stylesheet_link_tag "application", media: "all", "data-turbolinks-track" => true %>
10
+ <%%= stylesheet_link_tag "quick-templater", media: "all", "data-turbolinks-track" => true %>
11
+ <%%= javascript_include_tag "application", "data-turbolinks-track" => true %>
12
+ <%%= csrf_meta_tag %>
13
+ </head>
14
+
15
+ <body>
16
+
17
+ <!-- Fixed navbar -->
18
+ <div class="navbar navbar-default navbar-fixed-top" role="navigation">
19
+ <div class="container">
20
+ <div class="navbar-header">
21
+ <button type="button" class="navbar-toggle" data-toggle="collapse" data-target=".navbar-collapse">
22
+ <span class="sr-only">Toggle navigation</span>
23
+ <span class="icon-bar"></span>
24
+ <span class="icon-bar"></span>
25
+ <span class="icon-bar"></span>
26
+ </button>
27
+ <a class="navbar-brand" href="#"><%= options.app_name %></a>
28
+ </div>
29
+ <div class="navbar-collapse collapse">
30
+ <ul class="nav navbar-nav">
31
+ <li class="active"><a href="#">Home</a></li>
32
+ <li><a href="#about">About</a></li>
33
+ <li><a href="#contact">Contact</a></li>
34
+ <li class="dropdown">
35
+ <a href="#" class="dropdown-toggle" data-toggle="dropdown">Dropdown <b class="caret"></b></a>
36
+ <ul class="dropdown-menu">
37
+ <li><a href="#">Action</a></li>
38
+ <li><a href="#">Another action</a></li>
39
+ <li><a href="#">Something else here</a></li>
40
+ <li class="divider"></li>
41
+ <li class="dropdown-header">Nav header</li>
42
+ <li><a href="#">Separated link</a></li>
43
+ <li><a href="#">One more separated link</a></li>
44
+ </ul>
45
+ </li>
46
+ </ul>
47
+ <ul class="nav navbar-nav navbar-right">
48
+ <li><a href="#">Link</a></li>
49
+ <li><a href="#">Link</a></li>
50
+ <li><a href="#">Link</a></li>
51
+ </ul>
52
+ </div><!--/.nav-collapse -->
53
+ </div>
54
+ </div>
55
+
56
+ <div class="container">
57
+
58
+ <div class="page-header">
59
+ <h1>Non-responsive Bootstrap</h1>
60
+ <p class="lead">Disable the responsiveness of Bootstrap by fixing the width of the container and using the first grid system tier.</p>
61
+ </div>
62
+
63
+ <h3>What changes</h3>
64
+ <p>Note the lack of the <code>&lt;meta name="viewport" content="width=device-width, initial-scale=1.0"&gt;</code>, which disables the zooming aspect of sites in mobile devices. In addition, we reset our container's width and are basically good to go.</p>
65
+
66
+ <h3>Regarding navbars</h3>
67
+ <p>As a heads up, the navbar component is rather tricky here in that the styles for displaying it are rather specific and detailed. Overrides to ensure desktop styles display are not as performant or sleek as one would like. Just be aware there may be potential gotchas as you build on top of this example when using the navbar.</p>
68
+
69
+ <h3>Non-responsive grid system</h3>
70
+ <div class="row">
71
+ <div class="col-xs-4">One third</div>
72
+ <div class="col-xs-4">One third</div>
73
+ <div class="col-xs-4">One third</div>
74
+ </div>
75
+
76
+ </div> <!-- /container -->
77
+ </body>
78
+ </html>
@@ -0,0 +1,110 @@
1
+ <!DOCTYPE html>
2
+ <html lang="en">
3
+ <head>
4
+ <meta charset="utf-8">
5
+ <meta http-equiv="X-UA-Compatible" content="IE=edge">
6
+ <meta name="viewport" content="width=device-width, initial-scale=1.0">
7
+
8
+ <title><%= options.app_name %></title>
9
+
10
+ <%%= stylesheet_link_tag "application", media: "all", "data-turbolinks-track" => true %>
11
+ <%%= stylesheet_link_tag "quick-templater", media: "all", "data-turbolinks-track" => true %>
12
+ <%%= javascript_include_tag "application", "data-turbolinks-track" => true %>
13
+ <%%= csrf_meta_tag %>
14
+ </head>
15
+
16
+ <body>
17
+ <div class="navbar navbar-fixed-top navbar-inverse" role="navigation">
18
+ <div class="container">
19
+ <div class="navbar-header">
20
+ <button type="button" class="navbar-toggle" data-toggle="collapse" data-target=".navbar-collapse">
21
+ <span class="sr-only">Toggle navigation</span>
22
+ <span class="icon-bar"></span>
23
+ <span class="icon-bar"></span>
24
+ <span class="icon-bar"></span>
25
+ </button>
26
+ <a class="navbar-brand" href="#"><%= options.app_name %></a>
27
+ </div>
28
+ <div class="collapse navbar-collapse">
29
+ <ul class="nav navbar-nav">
30
+ <li class="active"><a href="#">Home</a></li>
31
+ <li><a href="#about">About</a></li>
32
+ <li><a href="#contact">Contact</a></li>
33
+ </ul>
34
+ </div><!-- /.nav-collapse -->
35
+ </div><!-- /.container -->
36
+ </div><!-- /.navbar -->
37
+
38
+ <div class="container">
39
+
40
+ <div class="row row-offcanvas row-offcanvas-right">
41
+
42
+ <div class="col-xs-12 col-sm-9">
43
+ <p class="pull-right visible-xs">
44
+ <button type="button" class="btn btn-primary btn-xs" data-toggle="offcanvas">Toggle nav</button>
45
+ </p>
46
+ <div class="jumbotron">
47
+ <h1>Hello, world!</h1>
48
+ <p>This is an example to show the potential of an offcanvas layout pattern in Bootstrap. Try some responsive-range viewport sizes to see it in action.</p>
49
+ </div>
50
+ <div class="row">
51
+ <div class="col-6 col-sm-6 col-lg-4">
52
+ <h2>Heading</h2>
53
+ <p>Donec id elit non mi porta gravida at eget metus. Fusce dapibus, tellus ac cursus commodo, tortor mauris condimentum nibh, ut fermentum massa justo sit amet risus. Etiam porta sem malesuada magna mollis euismod. Donec sed odio dui. </p>
54
+ <p><a class="btn btn-default" href="#" role="button">View details &raquo;</a></p>
55
+ </div><!--/span-->
56
+ <div class="col-6 col-sm-6 col-lg-4">
57
+ <h2>Heading</h2>
58
+ <p>Donec id elit non mi porta gravida at eget metus. Fusce dapibus, tellus ac cursus commodo, tortor mauris condimentum nibh, ut fermentum massa justo sit amet risus. Etiam porta sem malesuada magna mollis euismod. Donec sed odio dui. </p>
59
+ <p><a class="btn btn-default" href="#" role="button">View details &raquo;</a></p>
60
+ </div><!--/span-->
61
+ <div class="col-6 col-sm-6 col-lg-4">
62
+ <h2>Heading</h2>
63
+ <p>Donec id elit non mi porta gravida at eget metus. Fusce dapibus, tellus ac cursus commodo, tortor mauris condimentum nibh, ut fermentum massa justo sit amet risus. Etiam porta sem malesuada magna mollis euismod. Donec sed odio dui. </p>
64
+ <p><a class="btn btn-default" href="#" role="button">View details &raquo;</a></p>
65
+ </div><!--/span-->
66
+ <div class="col-6 col-sm-6 col-lg-4">
67
+ <h2>Heading</h2>
68
+ <p>Donec id elit non mi porta gravida at eget metus. Fusce dapibus, tellus ac cursus commodo, tortor mauris condimentum nibh, ut fermentum massa justo sit amet risus. Etiam porta sem malesuada magna mollis euismod. Donec sed odio dui. </p>
69
+ <p><a class="btn btn-default" href="#" role="button">View details &raquo;</a></p>
70
+ </div><!--/span-->
71
+ <div class="col-6 col-sm-6 col-lg-4">
72
+ <h2>Heading</h2>
73
+ <p>Donec id elit non mi porta gravida at eget metus. Fusce dapibus, tellus ac cursus commodo, tortor mauris condimentum nibh, ut fermentum massa justo sit amet risus. Etiam porta sem malesuada magna mollis euismod. Donec sed odio dui. </p>
74
+ <p><a class="btn btn-default" href="#" role="button">View details &raquo;</a></p>
75
+ </div><!--/span-->
76
+ <div class="col-6 col-sm-6 col-lg-4">
77
+ <h2>Heading</h2>
78
+ <p>Donec id elit non mi porta gravida at eget metus. Fusce dapibus, tellus ac cursus commodo, tortor mauris condimentum nibh, ut fermentum massa justo sit amet risus. Etiam porta sem malesuada magna mollis euismod. Donec sed odio dui. </p>
79
+ <p><a class="btn btn-default" href="#" role="button">View details &raquo;</a></p>
80
+ </div><!--/span-->
81
+ </div><!--/row-->
82
+ </div><!--/span-->
83
+
84
+ <div class="col-xs-6 col-sm-3 sidebar-offcanvas" id="sidebar" role="navigation">
85
+ <div class="list-group">
86
+ <a href="#" class="list-group-item active">Link</a>
87
+ <a href="#" class="list-group-item">Link</a>
88
+ <a href="#" class="list-group-item">Link</a>
89
+ <a href="#" class="list-group-item">Link</a>
90
+ <a href="#" class="list-group-item">Link</a>
91
+ <a href="#" class="list-group-item">Link</a>
92
+ <a href="#" class="list-group-item">Link</a>
93
+ <a href="#" class="list-group-item">Link</a>
94
+ <a href="#" class="list-group-item">Link</a>
95
+ <a href="#" class="list-group-item">Link</a>
96
+ </div>
97
+ </div><!--/span-->
98
+ </div><!--/row-->
99
+
100
+ <hr>
101
+
102
+ <footer>
103
+ <p>&copy; Company 2013</p>
104
+ </footer>
105
+
106
+ </div><!--/.container-->
107
+
108
+ <script src="offcanvas.js"></script>
109
+ </body>
110
+ </html>
@@ -0,0 +1,8 @@
1
+ /*
2
+ * This css will include all quick-templater css you need
3
+ *
4
+ *= require quick-templater/bootstrap3/<%= options.template %>.css
5
+ *= require_self
6
+ */
7
+
8
+ /* Write here your css for overriding the theme's rules */
@@ -0,0 +1,34 @@
1
+
2
+ <!DOCTYPE html>
3
+ <html lang="en">
4
+ <head>
5
+ <meta charset="utf-8">
6
+ <meta http-equiv="X-UA-Compatible" content="IE=edge">
7
+ <meta name="viewport" content="width=device-width, initial-scale=1.0">
8
+
9
+ <title><%= options.app_name %></title>
10
+
11
+ <%%= stylesheet_link_tag "application", media: "all", "data-turbolinks-track" => true %>
12
+ <%%= stylesheet_link_tag "quick-templater", media: "all", "data-turbolinks-track" => true %>
13
+ <%%= javascript_include_tag "application", "data-turbolinks-track" => true %>
14
+ <%%= csrf_meta_tag %>
15
+ </head>
16
+
17
+ <body>
18
+
19
+ <div class="container">
20
+
21
+ <form class="form-signin" role="form">
22
+ <h2 class="form-signin-heading">Please sign in</h2>
23
+ <input type="text" class="form-control" placeholder="Email address" required autofocus>
24
+ <input type="password" class="form-control" placeholder="Password" required>
25
+ <label class="checkbox">
26
+ <input type="checkbox" value="remember-me"> Remember me
27
+ </label>
28
+ <button class="btn btn-lg btn-primary btn-block" type="submit">Sign in</button>
29
+ </form>
30
+
31
+ </div> <!-- /container -->
32
+
33
+ </body>
34
+ </html>
@@ -0,0 +1,48 @@
1
+ <!DOCTYPE html>
2
+ <html lang="en">
3
+ <head>
4
+ <meta charset="utf-8">
5
+ <meta http-equiv="X-UA-Compatible" content="IE=edge">
6
+ <meta name="viewport" content="width=device-width, initial-scale=1.0">
7
+
8
+ <title><%= options.app_name %></title>
9
+
10
+ <%%= stylesheet_link_tag "application", media: "all", "data-turbolinks-track" => true %>
11
+ <%%= stylesheet_link_tag "quick-templater", media: "all", "data-turbolinks-track" => true %>
12
+ <%%= javascript_include_tag "application", "data-turbolinks-track" => true %>
13
+ <%%= csrf_meta_tag %>
14
+ </head>
15
+
16
+ <body>
17
+
18
+ <div class="navbar navbar-inverse navbar-fixed-top" role="navigation">
19
+ <div class="container">
20
+ <div class="navbar-header">
21
+ <button type="button" class="navbar-toggle" data-toggle="collapse" data-target=".navbar-collapse">
22
+ <span class="sr-only">Toggle navigation</span>
23
+ <span class="icon-bar"></span>
24
+ <span class="icon-bar"></span>
25
+ <span class="icon-bar"></span>
26
+ </button>
27
+ <a class="navbar-brand" href="#"><%= options.app_name %></a>
28
+ </div>
29
+ <div class="collapse navbar-collapse">
30
+ <ul class="nav navbar-nav">
31
+ <li class="active"><a href="#">Home</a></li>
32
+ <li><a href="#about">About</a></li>
33
+ <li><a href="#contact">Contact</a></li>
34
+ </ul>
35
+ </div><!--/.nav-collapse -->
36
+ </div>
37
+ </div>
38
+
39
+ <div class="container">
40
+
41
+ <div class="starter-template">
42
+ <h1>Bootstrap starter template</h1>
43
+ <p class="lead">Use this document as a way to quickly start any new project.<br> All you get is this text and a mostly barebones HTML document.</p>
44
+ </div>
45
+
46
+ </div><!-- /.container -->
47
+ </body>
48
+ </html>
@@ -0,0 +1,37 @@
1
+ <!DOCTYPE html>
2
+ <html lang="en">
3
+ <head>
4
+ <meta charset="utf-8">
5
+ <meta http-equiv="X-UA-Compatible" content="IE=edge">
6
+ <meta name="viewport" content="width=device-width, initial-scale=1.0">
7
+
8
+ <title><%= options.app_name %></title>
9
+
10
+ <%%= stylesheet_link_tag "application", media: "all", "data-turbolinks-track" => true %>
11
+ <%%= stylesheet_link_tag "quick-templater", media: "all", "data-turbolinks-track" => true %>
12
+ <%%= javascript_include_tag "application", "data-turbolinks-track" => true %>
13
+ <%%= csrf_meta_tag %>
14
+ </head>
15
+
16
+ <body>
17
+
18
+ <!-- Wrap all page content here -->
19
+ <div id="wrap">
20
+
21
+ <!-- Begin page content -->
22
+ <div class="container">
23
+ <div class="page-header">
24
+ <h1>Sticky footer</h1>
25
+ </div>
26
+ <p class="lead">Pin a fixed-height footer to the bottom of the viewport in desktop browsers with this custom HTML and CSS.</p>
27
+ <p>Use <a href="../sticky-footer-navbar">the sticky footer with a fixed navbar</a> if need be, too.</p>
28
+ </div>
29
+ </div>
30
+
31
+ <div id="footer">
32
+ <div class="container">
33
+ <p class="text-muted">Place sticky footer content here.</p>
34
+ </div>
35
+ </div>
36
+ </body>
37
+ </html>
@@ -0,0 +1,71 @@
1
+ <!DOCTYPE html>
2
+ <html lang="en">
3
+ <head>
4
+ <meta charset="utf-8">
5
+ <meta http-equiv="X-UA-Compatible" content="IE=edge">
6
+ <meta name="viewport" content="width=device-width, initial-scale=1.0">
7
+
8
+ <title><%= options.app_name %></title>
9
+
10
+ <%%= stylesheet_link_tag "application", media: "all", "data-turbolinks-track" => true %>
11
+ <%%= stylesheet_link_tag "quick-templater", media: "all", "data-turbolinks-track" => true %>
12
+ <%%= javascript_include_tag "application", "data-turbolinks-track" => true %>
13
+ <%%= csrf_meta_tag %>
14
+ </head>
15
+
16
+ <body>
17
+
18
+ <!-- Wrap all page content here -->
19
+ <div id="wrap">
20
+
21
+ <!-- Fixed navbar -->
22
+ <div class="navbar navbar-default navbar-fixed-top" role="navigation">
23
+ <div class="container">
24
+ <div class="navbar-header">
25
+ <button type="button" class="navbar-toggle" data-toggle="collapse" data-target=".navbar-collapse">
26
+ <span class="sr-only">Toggle navigation</span>
27
+ <span class="icon-bar"></span>
28
+ <span class="icon-bar"></span>
29
+ <span class="icon-bar"></span>
30
+ </button>
31
+ <a class="navbar-brand" href="#"><%= options.app_name %></a>
32
+ </div>
33
+ <div class="collapse navbar-collapse">
34
+ <ul class="nav navbar-nav">
35
+ <li class="active"><a href="#">Home</a></li>
36
+ <li><a href="#about">About</a></li>
37
+ <li><a href="#contact">Contact</a></li>
38
+ <li class="dropdown">
39
+ <a href="#" class="dropdown-toggle" data-toggle="dropdown">Dropdown <b class="caret"></b></a>
40
+ <ul class="dropdown-menu">
41
+ <li><a href="#">Action</a></li>
42
+ <li><a href="#">Another action</a></li>
43
+ <li><a href="#">Something else here</a></li>
44
+ <li class="divider"></li>
45
+ <li class="dropdown-header">Nav header</li>
46
+ <li><a href="#">Separated link</a></li>
47
+ <li><a href="#">One more separated link</a></li>
48
+ </ul>
49
+ </li>
50
+ </ul>
51
+ </div><!--/.nav-collapse -->
52
+ </div>
53
+ </div>
54
+
55
+ <!-- Begin page content -->
56
+ <div class="container">
57
+ <div class="page-header">
58
+ <h1>Sticky footer with fixed navbar</h1>
59
+ </div>
60
+ <p class="lead">Pin a fixed-height footer to the bottom of the viewport in desktop browsers with this custom HTML and CSS. A fixed navbar has been added within <code>#wrap</code> with <code>padding-top: 60px;</code> on the <code>.container</code>.</p>
61
+ <p>Back to <a href="../sticky-footer">the default sticky footer</a> minus the navbar.</p>
62
+ </div>
63
+ </div>
64
+
65
+ <div id="footer">
66
+ <div class="container">
67
+ <p class="text-muted">Place sticky footer content here.</p>
68
+ </div>
69
+ </div>
70
+ </body>
71
+ </html>
@@ -0,0 +1,3 @@
1
+ module QuickTemplater
2
+ VERSION = "0.0.5"
3
+ end
@@ -0,0 +1,7 @@
1
+ require "quick-templater/version"
2
+
3
+ module QuickTemplater
4
+ class Engine < Rails::Engine
5
+
6
+ end
7
+ end
@@ -0,0 +1,25 @@
1
+ # coding: utf-8
2
+ lib = File.expand_path('../lib', __FILE__)
3
+ $LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
4
+ require 'quick-templater/version'
5
+
6
+ Gem::Specification.new do |spec|
7
+ spec.name = "quick-templater"
8
+ spec.version = QuickTemplater::VERSION
9
+ spec.authors = ["jurrick"]
10
+ spec.email = ["jurianp@gmail.com"]
11
+ spec.summary = %q{Web app template generator}
12
+ spec.description = %q{Web app theme generator for Ruby On Rails projects}
13
+ spec.homepage = "http://github.com/jurrick/quick-templater"
14
+ spec.license = "MIT"
15
+
16
+ spec.files = `git ls-files`.split($/)
17
+ spec.executables = spec.files.grep(%r{^bin/}) { |f| File.basename(f) }
18
+ spec.test_files = spec.files.grep(%r{^(test|spec|features)/})
19
+ spec.require_paths = ["lib"]
20
+
21
+ spec.add_development_dependency "bundler", "~> 1.5"
22
+ spec.add_development_dependency "rake"
23
+
24
+ spec.add_development_dependency "rspec"
25
+ end
@@ -0,0 +1,42 @@
1
+ require "spec_helper"
2
+
3
+ require "generator_spec/test_case"
4
+
5
+ require "generators/quick-templater/layout/layout_generator"
6
+
7
+ describe QuickTemplater::Layout do
8
+ include GeneratorSpec::TestCase
9
+ destination File.expand_path('../../tmp', __FILE__)
10
+
11
+ before(:all) do
12
+ prepare_destination
13
+ end
14
+
15
+ it 'creates layout with name test1' do
16
+ run_generator %w(test1)
17
+ assert_file 'app/views/layouts/test1.html.erb'
18
+ end
19
+
20
+ describe 'are generated' do
21
+ describe 'with default template engine' do
22
+ before {run_generator}
23
+ it 'application.html.erb' do
24
+ assert_file 'app/views/layouts/application.html.erb'
25
+ end
26
+ end
27
+ describe 'with haml' do
28
+ before {run_generator %w(--engine=haml)}
29
+ it 'application.html.haml' do
30
+ assert_file 'app/views/layouts/application.html.haml'
31
+ end
32
+ end
33
+ describe 'with slim' do
34
+ before do
35
+ run_generator %w(--engine=slim)
36
+ end
37
+ it 'application.html.slim' do
38
+ assert_file 'app/views/layouts/application.html.slim'
39
+ end
40
+ end
41
+ end
42
+ end
@@ -0,0 +1,8 @@
1
+ require 'bundler/setup'
2
+ require 'rspec'
3
+
4
+ RSpec.configure do |config|
5
+ config.treat_symbols_as_metadata_keys_with_true_values = true
6
+ config.run_all_when_everything_filtered = true
7
+ config.filter_run :focus
8
+ end