repres-bootstrap 1.0
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/README.md +165 -0
- data/Rakefile +24 -0
- data/app/assets/javascripts/repres/bootstrap/application.js +13 -0
- data/app/assets/stylesheets/repres/bootstrap/application.css +15 -0
- data/app/controllers/repres/bootstrap/application_controller.rb +2 -0
- data/app/helpers/repres/bootstrap/application_helper.rb +2 -0
- data/app/views/layouts/unirer/bootstrap/application.html.erb +14 -0
- data/app/views/repres/bootstrap/_form_field.html.erb +75 -0
- data/app/views/repres/bootstrap/_form_select_box.html.erb +67 -0
- data/app/views/repres/bootstrap/_script.html.erb +16 -0
- data/app/views/repres/bootstrap/_style.html.erb +11 -0
- data/config/routes.rb +2 -0
- data/lib/repres/bootstrap/engine.rb +11 -0
- data/lib/repres/bootstrap/version.rb +5 -0
- data/lib/repres/bootstrap.rb +6 -0
- data/lib/tasks/bootstrap_tasks.rake +4 -0
- metadata +77 -0
checksums.yaml
ADDED
@@ -0,0 +1,7 @@
|
|
1
|
+
---
|
2
|
+
SHA1:
|
3
|
+
metadata.gz: 60e9c92146139f2f37b68a454671cab2f61b626d
|
4
|
+
data.tar.gz: 2a9e2e56675a463355027fcf739ecde085ffc515
|
5
|
+
SHA512:
|
6
|
+
metadata.gz: c92bc0b713ac45e3177f90f2b62284613f9eed3456c2ff41dfd67aa07868601c22a90cacd0ef79322ea9e311fbdd72554a574433e909b4b5538635fb86684a77
|
7
|
+
data.tar.gz: 2e6f13a23bcc849ad7ef28a203950362e1d490174b12cb258b52bcac89677e97801af4b8420697ed52445106eb22dde340ec17aab5f86b6b339b419e5ed1c6a7
|
data/MIT-LICENSE
ADDED
@@ -0,0 +1,20 @@
|
|
1
|
+
Copyright 2016 Topbit Du
|
2
|
+
|
3
|
+
Permission is hereby granted, free of charge, to any person obtaining
|
4
|
+
a copy of this software and associated documentation files (the
|
5
|
+
"Software"), to deal in the Software without restriction, including
|
6
|
+
without limitation the rights to use, copy, modify, merge, publish,
|
7
|
+
distribute, sublicense, and/or sell copies of the Software, and to
|
8
|
+
permit persons to whom the Software is furnished to do so, subject to
|
9
|
+
the following conditions:
|
10
|
+
|
11
|
+
The above copyright notice and this permission notice shall be
|
12
|
+
included in all copies or substantial portions of the Software.
|
13
|
+
|
14
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
15
|
+
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
|
16
|
+
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
|
17
|
+
NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
|
18
|
+
LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
|
19
|
+
OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
|
20
|
+
WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
data/README.md
ADDED
@@ -0,0 +1,165 @@
|
|
1
|
+
# Repres Bootstrap Bootstrap资源表现引擎
|
2
|
+
|
3
|
+
[![License](https://img.shields.io/badge/license-MIT-green.svg)](http://opensource.org/licenses/MIT)
|
4
|
+
[![Gem Version](https://badge.fury.io/rb/repres-bootstrap.svg)](https://badge.fury.io/rb/repres-bootstrap)
|
5
|
+
|
6
|
+
Repres (REsource REPResentation) is a series of resource presentation engines. The Bootstrap resource presentation engine includes Bootstrap-based resource presentation templates & snippets.
|
7
|
+
Repres (资源表现)是一系列的资源表现引擎。Bootstrap 资源表现引擎包括基于Bootstrap的资源表现模版和片段。
|
8
|
+
|
9
|
+
|
10
|
+
|
11
|
+
## Recent Update
|
12
|
+
Check out the [Road Map](ROADMAP.md) to find out what's the next.
|
13
|
+
Check out the [Change Log](CHANGELOG.md) to find out what's new.
|
14
|
+
|
15
|
+
|
16
|
+
|
17
|
+
## Usage in Gemfile
|
18
|
+
```ruby
|
19
|
+
gem 'repres-bootstrap'
|
20
|
+
```
|
21
|
+
|
22
|
+
|
23
|
+
|
24
|
+
## Render the Pre-defined Partials
|
25
|
+
```erb
|
26
|
+
<html>
|
27
|
+
|
28
|
+
<head>
|
29
|
+
<%= render partial: 'repres/bootstrap/style', locals: { options: { bootstrap: true } } %>
|
30
|
+
</head>
|
31
|
+
|
32
|
+
<body>
|
33
|
+
<div class='container'>
|
34
|
+
<%= form_for @person do |f| %>
|
35
|
+
<%= render partial: 'repres/bootstrap/form_field', locals: { options: { model: model, form: f, name: :phone_number, type: :telephone_field } } %>
|
36
|
+
<%= render partial: 'repres/bootstrap/form_select_box', locals: { options: { model: model, form: f, name: :gender, choices: { 'Male' => '1', 'Female' => '2' }, options: { include_blank: 'Please Select...' } } } %>
|
37
|
+
<% end %>
|
38
|
+
</div>
|
39
|
+
<%= render partial: 'repres/bootstrap/script', locals: { options: { bootstrap: true } } %>
|
40
|
+
</body>
|
41
|
+
|
42
|
+
</html>
|
43
|
+
```
|
44
|
+
|
45
|
+
|
46
|
+
|
47
|
+
### Render the Script
|
48
|
+
The Script partial includes the HTML script tags for Bootstrap and its extensions. Only the [Boot CDN](http://cdn.bootcss.com/) servers are supported.
|
49
|
+
|
50
|
+
The following code snippet does not load any JavaScript library.
|
51
|
+
```erb
|
52
|
+
<%= render partial: 'repres/bootstrap/script' %>
|
53
|
+
```
|
54
|
+
|
55
|
+
The following code snippet loads the latest Bootstrap JavaScript library.
|
56
|
+
```erb
|
57
|
+
<%= render partial: 'repres/bootstrap/script', locals: { options: { bootstrap: true } } %>
|
58
|
+
```
|
59
|
+
|
60
|
+
The following code snippet loads the Bootstrap JavaScript library with the given version.
|
61
|
+
```erb
|
62
|
+
<%= render partial: 'repres/bootstrap/script', locals: { options: { bootstrap: { version: '3.3.5' } } }
|
63
|
+
%>
|
64
|
+
```
|
65
|
+
|
66
|
+
The following JavaScript libraries are switchable, and the version can be configurable:
|
67
|
+
- :bootstrap
|
68
|
+
- :'bootstrap-datepicker'
|
69
|
+
- :'bootstrap-datetimepicker'
|
70
|
+
- :'bootstrap-fileinput'
|
71
|
+
- :'bootstrap-table'
|
72
|
+
|
73
|
+
|
74
|
+
|
75
|
+
### Render the Style
|
76
|
+
The Style partial includes the HTML style tags for Bootstrap and its extensions. Only the [Boot CDN](http://cdn.bootcss.com/) servers are supported.
|
77
|
+
|
78
|
+
The following code snippet does not load any CSS library.
|
79
|
+
```erb
|
80
|
+
<%= render partial: 'repres/bootstrap/style' %>
|
81
|
+
```
|
82
|
+
|
83
|
+
The following code snippet loads the latest Bootstrap CSS library.
|
84
|
+
```erb
|
85
|
+
<%= render partial: 'repres/bootstrap/style', locals: { options: { bootstrap: true } } %>
|
86
|
+
```
|
87
|
+
|
88
|
+
The following code snippet loads the Bootstrap CSS library with the given version.
|
89
|
+
```erb
|
90
|
+
<%= render partial: 'repres/bootstrap/style', locals: { options: { bootstrap: { version: '3.3.5' } } } %>
|
91
|
+
```
|
92
|
+
|
93
|
+
The following CSS libraries are switchable, and the version can be configurable:
|
94
|
+
- :bootstrap
|
95
|
+
- :'bootstrap-theme'
|
96
|
+
- :'bootstrap-datepicker'
|
97
|
+
- :'bootstrap-datetimepicker'
|
98
|
+
- :'bootstrap-fileinput'
|
99
|
+
- :'bootstrap-table'
|
100
|
+
|
101
|
+
|
102
|
+
|
103
|
+
### Render the Form Field
|
104
|
+
The Form Field partial includes the HTML form field tags for Rails Form Builder and Bootstrap.
|
105
|
+
```erb
|
106
|
+
<%= render partial: 'repres/bootstrap/form_field',
|
107
|
+
locals: {
|
108
|
+
options: {
|
109
|
+
model: model,
|
110
|
+
form: f,
|
111
|
+
name: :phone_number,
|
112
|
+
type: :telephone_field
|
113
|
+
}
|
114
|
+
}
|
115
|
+
%>
|
116
|
+
<%= render partial: 'repres/bootstrap/form_field',
|
117
|
+
locals: {
|
118
|
+
options: {
|
119
|
+
model: model,
|
120
|
+
form: f,
|
121
|
+
name: :photo,
|
122
|
+
type: :file_field,
|
123
|
+
input_accept: 'image/*'
|
124
|
+
}
|
125
|
+
}
|
126
|
+
%>
|
127
|
+
```
|
128
|
+
|
129
|
+
|
130
|
+
|
131
|
+
### Render the Form Select Box
|
132
|
+
The Form Select Box partial includes the HTML select tags for Rails Form Builder and Bootstrap.
|
133
|
+
```ruby
|
134
|
+
<%= render partial: 'repres/bootstrap/form_field',
|
135
|
+
locals: {
|
136
|
+
options: {
|
137
|
+
model: model,
|
138
|
+
form: f,
|
139
|
+
name: :country_id,
|
140
|
+
choices: @countries.select('id, name').map { |country| [ country.name, country.id ] },
|
141
|
+
options: { prompt: '请选择国家' }
|
142
|
+
}
|
143
|
+
}
|
144
|
+
%>
|
145
|
+
```
|
146
|
+
|
147
|
+
|
148
|
+
|
149
|
+
The 4 options are required: model, form, name, and type.
|
150
|
+
Here are more options:
|
151
|
+
- label_text: The customized label text.
|
152
|
+
- label_prefix: The label prefix.
|
153
|
+
- label_suffix: The label suffix.
|
154
|
+
|
155
|
+
- group_class: The CSS class for the form group wrapper. The .form-group class is mandatory, and can not be removed.
|
156
|
+
- label_class: the CSS class for the HTML label tag. The .control-label class is mandatory, and can not be removed.
|
157
|
+
- field_class: the CSS class for the wrapper of the form control. The .input-group class is mandatory, and can not be removed.
|
158
|
+
- input_class: The CSS class for the HTML input tag. The .form-control class is mandatory, and can not be removed.
|
159
|
+
- error_class: the CSS class for the validation error block of this field. The .text-danger class is mandatory, and can not be removed.
|
160
|
+
|
161
|
+
- input_prefix: the HTML source codes of input group addon before the form control.
|
162
|
+
- input_suffix: the HTML source codes of input group addon after the form control.
|
163
|
+
- input_accept: The HTML 5 attribute for the file input tag.
|
164
|
+
- input_data: The HTML 5 Data attribute for the input tag.
|
165
|
+
- error_hidden: Determines whether the error message block should be shown if the field has any error.
|
data/Rakefile
ADDED
@@ -0,0 +1,24 @@
|
|
1
|
+
begin
|
2
|
+
require 'bundler/setup'
|
3
|
+
rescue LoadError
|
4
|
+
puts 'You must `gem install bundler` and `bundle install` to run rake tasks'
|
5
|
+
end
|
6
|
+
|
7
|
+
require 'rdoc/task'
|
8
|
+
|
9
|
+
RDoc::Task.new(:rdoc) do |rdoc|
|
10
|
+
rdoc.rdoc_dir = 'rdoc'
|
11
|
+
rdoc.title = 'Repres Bootstrap'
|
12
|
+
rdoc.options << '--line-numbers'
|
13
|
+
rdoc.rdoc_files.include('README.rdoc')
|
14
|
+
rdoc.rdoc_files.include('lib/**/*.rb')
|
15
|
+
end
|
16
|
+
|
17
|
+
|
18
|
+
|
19
|
+
load 'rails/tasks/statistics.rake'
|
20
|
+
|
21
|
+
|
22
|
+
|
23
|
+
Bundler::GemHelper.install_tasks
|
24
|
+
|
@@ -0,0 +1,13 @@
|
|
1
|
+
// This is a manifest file that'll be compiled into application.js, which will include all the files
|
2
|
+
// listed below.
|
3
|
+
//
|
4
|
+
// Any JavaScript/Coffee file within this directory, lib/assets/javascripts, vendor/assets/javascripts,
|
5
|
+
// or any plugin's vendor/assets/javascripts directory can be referenced here using a relative path.
|
6
|
+
//
|
7
|
+
// It's not advisable to add code directly here, but if you do, it'll appear at the bottom of the
|
8
|
+
// compiled file.
|
9
|
+
//
|
10
|
+
// Read Sprockets README (https://github.com/rails/sprockets#sprockets-directives) for details
|
11
|
+
// about supported directives.
|
12
|
+
//
|
13
|
+
//= require_tree .
|
@@ -0,0 +1,15 @@
|
|
1
|
+
/*
|
2
|
+
* This is a manifest file that'll be compiled into application.css, which will include all the files
|
3
|
+
* listed below.
|
4
|
+
*
|
5
|
+
* Any CSS and SCSS file within this directory, lib/assets/stylesheets, vendor/assets/stylesheets,
|
6
|
+
* or any plugin's vendor/assets/stylesheets directory can be referenced here using a relative path.
|
7
|
+
*
|
8
|
+
* You're free to add application-wide styles to this file and they'll appear at the bottom of the
|
9
|
+
* compiled file so the styles you add here take precedence over styles defined in any styles
|
10
|
+
* defined in the other CSS/SCSS files in this directory. It is generally better to create a new
|
11
|
+
* file per style scope.
|
12
|
+
*
|
13
|
+
*= require_tree .
|
14
|
+
*= require_self
|
15
|
+
*/
|
@@ -0,0 +1,14 @@
|
|
1
|
+
<!DOCTYPE html>
|
2
|
+
<html>
|
3
|
+
<head>
|
4
|
+
<title>Repres Bootstrap</title>
|
5
|
+
<%= stylesheet_link_tag "bootstrap/application", media: "all" %>
|
6
|
+
<%= javascript_include_tag "bootstrap/application" %>
|
7
|
+
<%= csrf_meta_tags %>
|
8
|
+
</head>
|
9
|
+
<body>
|
10
|
+
|
11
|
+
<%= yield %>
|
12
|
+
|
13
|
+
</body>
|
14
|
+
</html>
|
@@ -0,0 +1,75 @@
|
|
1
|
+
<%
|
2
|
+
model = options[:model]
|
3
|
+
form = options[:form]
|
4
|
+
name = options[:name]
|
5
|
+
type = options[:type]||:text_field
|
6
|
+
|
7
|
+
group_class_list = [ 'form-group', options[:group_class] ]
|
8
|
+
label_class_list = [ 'control-label', options[:label_class] ]
|
9
|
+
field_class_list = [ 'input-group', options[:field_class] ]
|
10
|
+
input_class_list = [ 'form-control', options[:input_class] ]
|
11
|
+
error_class_list = [ 'text-danger', options[:error_class] ]
|
12
|
+
group_class_list << 'has-error' if model.errors[name].present?
|
13
|
+
|
14
|
+
group_class = group_class_list.flatten.join ' '
|
15
|
+
label_class = label_class_list.flatten.join ' '
|
16
|
+
field_class = field_class_list.flatten.join ' '
|
17
|
+
input_class = input_class_list.flatten.join ' '
|
18
|
+
error_class = error_class_list.flatten.join ' '
|
19
|
+
|
20
|
+
group_data = options[:group_data]
|
21
|
+
field_data = options[:field_data]
|
22
|
+
input_data = options[:input_data]
|
23
|
+
|
24
|
+
input_prefix = options[:input_prefix]
|
25
|
+
input_suffix = options[:input_suffix]
|
26
|
+
|
27
|
+
label_text = options[:label_text]
|
28
|
+
label_prefix = options[:label_prefix]
|
29
|
+
label_suffix = options[:label_suffix]
|
30
|
+
|
31
|
+
input_options = {
|
32
|
+
disabled: options[:disabled],
|
33
|
+
class: input_class_list,
|
34
|
+
placeholder: options[:placeholder],
|
35
|
+
readonly: options[:readonly],
|
36
|
+
maxlength: options[:maxlength],
|
37
|
+
required: options[:required],
|
38
|
+
data: input_data
|
39
|
+
}
|
40
|
+
input_options[:input_accept] = options[:input_accept] if options[:input_accept].present?
|
41
|
+
|
42
|
+
error_hidden = options[:error_hidden]
|
43
|
+
%>
|
44
|
+
|
45
|
+
<div class='<%= group_class %>'>
|
46
|
+
|
47
|
+
<%= form.label name, class: label_class do %><%= label_prefix %><%= label_text||model.class.human_attribute_name(name.to_sym) %><%= label_suffix %><% end %>
|
48
|
+
|
49
|
+
<% if input_prefix.present? || input_suffix.present? %>
|
50
|
+
|
51
|
+
<div class='<%= field_class %>'>
|
52
|
+
|
53
|
+
<% if input_prefix.present? %>
|
54
|
+
<span class='input-group-addon'><%= input_prefix %></span>
|
55
|
+
<% end %>
|
56
|
+
|
57
|
+
<%= form.send type, name, input_options %>
|
58
|
+
|
59
|
+
<% if input_suffix.present? %>
|
60
|
+
<span class='input-group-addon'><%= input_suffix %></span>
|
61
|
+
<% end %>
|
62
|
+
|
63
|
+
</div>
|
64
|
+
|
65
|
+
<% else %>
|
66
|
+
|
67
|
+
<%= form.send type, name, input_options %>
|
68
|
+
|
69
|
+
<% end %>
|
70
|
+
|
71
|
+
<% if model.errors[name].present? && !error_hidden %>
|
72
|
+
<p class='<%= error_class %>'><%= model.errors[name].first %></p>
|
73
|
+
<% end %>
|
74
|
+
|
75
|
+
</div>
|
@@ -0,0 +1,67 @@
|
|
1
|
+
<%
|
2
|
+
model = options[:model]
|
3
|
+
form = options[:form]
|
4
|
+
name = options[:name]
|
5
|
+
|
6
|
+
group_class_list = [ 'form-group', options[:group_class] ]
|
7
|
+
label_class_list = [ 'control-label', options[:label_class] ]
|
8
|
+
field_class_list = [ 'input-group', options[:field_class] ]
|
9
|
+
input_class_list = [ 'form-control', options[:input_class] ]
|
10
|
+
error_class_list = [ 'text-danger', options[:error_class] ]
|
11
|
+
group_class_list << 'has-error' if model.errors[name].present?
|
12
|
+
|
13
|
+
group_class = group_class_list.flatten.join ' '
|
14
|
+
label_class = label_class_list.flatten.join ' '
|
15
|
+
field_class = field_class_list.flatten.join ' '
|
16
|
+
input_class = input_class_list.flatten.join ' '
|
17
|
+
error_class = error_class_list.flatten.join ' '
|
18
|
+
|
19
|
+
input_prefix = options[:input_prefix]
|
20
|
+
input_suffix = options[:input_suffix]
|
21
|
+
|
22
|
+
label_text = options[:label_text]
|
23
|
+
label_prefix = options[:label_prefix]
|
24
|
+
label_suffix = options[:label_suffix]
|
25
|
+
|
26
|
+
input_options = {
|
27
|
+
class: input_class_list,
|
28
|
+
disabled: options[:disabled]
|
29
|
+
}
|
30
|
+
|
31
|
+
error_hidden = options[:error_hidden]
|
32
|
+
|
33
|
+
choices = options[:choices]
|
34
|
+
flags = options[:options]||{}
|
35
|
+
%>
|
36
|
+
|
37
|
+
<div class='<%= group_class %>'>
|
38
|
+
|
39
|
+
<%= form.label name, class: label_class do %><%= label_prefix %><%= label_text||model.class.human_attribute_name(name.to_sym) %><%= label_suffix %><% end %>
|
40
|
+
|
41
|
+
<% if input_prefix.present? || input_suffix.present? %>
|
42
|
+
|
43
|
+
<div class='<%= field_class %>'>
|
44
|
+
|
45
|
+
<% if input_prefix.present? %>
|
46
|
+
<span class='input-group-addon'><%= input_prefix %></span>
|
47
|
+
<% end %>
|
48
|
+
|
49
|
+
<%= form.select name, choices, flags, input_options %>
|
50
|
+
|
51
|
+
<% if input_suffix.present? %>
|
52
|
+
<span class='input-group-addon'><%= input_suffix %></span>
|
53
|
+
<% end %>
|
54
|
+
|
55
|
+
</div>
|
56
|
+
|
57
|
+
<% else %>
|
58
|
+
|
59
|
+
<%= form.select name, choices, flags, input_options %>
|
60
|
+
|
61
|
+
<% end %>
|
62
|
+
|
63
|
+
<% if model.errors[name].present? && !error_hidden %>
|
64
|
+
<p class='<%= error_class %>'><%= model.errors[name].first %></p>
|
65
|
+
<% end %>
|
66
|
+
|
67
|
+
</div>
|
@@ -0,0 +1,16 @@
|
|
1
|
+
<% options = defined?(options) ? options : nil %>
|
2
|
+
|
3
|
+
<%= javascript_include_tag "//cdn.bootcss.com/bootstrap/#{library_version(:bootstrap, '3.3.6', options)}/js/bootstrap.min.js" if library_enabled?(:bootstrap, options) %>
|
4
|
+
|
5
|
+
<%= javascript_include_tag "//cdn.bootcss.com/bootstrap-datepicker/#{library_version(:'bootstrap-datepicker', '1.6.0', options)}/js/bootstrap-datepicker.min.js" if library_enabled?(:'bootstrap-datepicker', options) %>
|
6
|
+
<%= javascript_include_tag "//cdn.bootcss.com/bootstrap-datetimepicker/#{library_version(:'bootstrap-datetimepicker', '4.17.37', options)}/js/bootstrap-datetimepicker.min.js" if library_enabled?(:'bootstrap-datetimepicker', options) %>
|
7
|
+
|
8
|
+
<% if library_enabled?(:'bootstrap-table', options) %>
|
9
|
+
<%= javascript_include_tag "//cdn.bootcss.com/bootstrap-table/#{library_version(:'bootstrap-table', '1.10.0', options)}/bootstrap-table.min.js" %>
|
10
|
+
<%= javascript_include_tag "//cdn.bootcss.com/bootstrap-table/#{library_version(:'bootstrap-table', '1.10.1', options)}/locale/bootstrap-table-zh-CN.min.js", charset: 'UTF-8' %>
|
11
|
+
<% end %>
|
12
|
+
|
13
|
+
<% if library_enabled?(:'bootstrap-fileinput', options) %>
|
14
|
+
<%= javascript_include_tag "//cdn.bootcss.com/bootstrap-fileinput/#{library_version(:'bootstrap-fileinput', '4.3.1', options)}/js/fileinput.min.js" %>
|
15
|
+
<%= javascript_include_tag "//cdn.bootcss.com/bootstrap-fileinput/#{library_version(:'bootstrap-fileinput', '4.3.1', options)}/js/fileinput_locale_zh.min.js", charset: 'UTF-8' %>
|
16
|
+
<% end %>
|
@@ -0,0 +1,11 @@
|
|
1
|
+
<% options = defined?(options) ? options : nil %>
|
2
|
+
|
3
|
+
<%= stylesheet_link_tag "//cdn.bootcss.com/bootstrap/#{library_version :bootstrap, '3.3.6', options}/css/bootstrap.min.css", media: 'all' if library_enabled?(:bootstrap, options) %>
|
4
|
+
<%= stylesheet_link_tag "//cdn.bootcss.com/bootstrap/#{library_version(:'bootstrap-theme', '3.3.6', options)}/css/bootstrap-theme.min.css", media: 'all' if library_enabled?(:'bootstrap-theme', options) %>
|
5
|
+
|
6
|
+
<%= stylesheet_link_tag "//cdn.bootcss.com/bootstrap-datepicker/#{library_version(:'bootstrap-datepicker', '1.6.0', options)}/css/bootstrap-datepicker.min.css", media: 'all' if library_enabled?(:'bootstrap-datepicker', options) %>
|
7
|
+
<%= stylesheet_link_tag "//cdn.bootcss.com/bootstrap-datetimepicker/#{library_version(:'bootstrap-datetimepicker', '4.17.37', options)}/css/bootstrap-datetimepicker.min.css", media: 'all' if library_enabled?(:'bootstrap-datetimepicker', options) %>
|
8
|
+
|
9
|
+
<%= stylesheet_link_tag "//cdn.bootcss.com/bootstrap-table/#{library_version(:'bootstrap-table', '1.10.0', options)}/bootstrap-table.min.css", media: 'all' if library_enabled?(:'bootstrap-table', options) %>
|
10
|
+
|
11
|
+
<%= stylesheet_link_tag "//cdn.bootcss.com/bootstrap-fileinput/#{library_version(:'bootstrap-fileinput', '4.3.1', options)}/css/fileinput.min.css", media: 'all' if library_enabled?(:'bootstrap-fileinput', options) %>
|
data/config/routes.rb
ADDED
metadata
ADDED
@@ -0,0 +1,77 @@
|
|
1
|
+
--- !ruby/object:Gem::Specification
|
2
|
+
name: repres-bootstrap
|
3
|
+
version: !ruby/object:Gem::Version
|
4
|
+
version: '1.0'
|
5
|
+
platform: ruby
|
6
|
+
authors:
|
7
|
+
- Topbit Du
|
8
|
+
autorequire:
|
9
|
+
bindir: bin
|
10
|
+
cert_chain: []
|
11
|
+
date: 2016-04-22 00:00:00.000000000 Z
|
12
|
+
dependencies:
|
13
|
+
- !ruby/object:Gem::Dependency
|
14
|
+
name: rails
|
15
|
+
requirement: !ruby/object:Gem::Requirement
|
16
|
+
requirements:
|
17
|
+
- - "~>"
|
18
|
+
- !ruby/object:Gem::Version
|
19
|
+
version: '4.2'
|
20
|
+
type: :runtime
|
21
|
+
prerelease: false
|
22
|
+
version_requirements: !ruby/object:Gem::Requirement
|
23
|
+
requirements:
|
24
|
+
- - "~>"
|
25
|
+
- !ruby/object:Gem::Version
|
26
|
+
version: '4.2'
|
27
|
+
description: Repres (REsource PRESentation) is a series of resource presentation engines.
|
28
|
+
The Bootstrap resource presentation engine includes Bootstrap-based resource presentation
|
29
|
+
templates & snippets. Repres (资源表现)是一系列的资源表现引擎。Bootstrap 资源表现引擎包括基于Bootstrap的资源表现模版和片段。
|
30
|
+
email:
|
31
|
+
- topbit.du@gmail.com
|
32
|
+
executables: []
|
33
|
+
extensions: []
|
34
|
+
extra_rdoc_files: []
|
35
|
+
files:
|
36
|
+
- MIT-LICENSE
|
37
|
+
- README.md
|
38
|
+
- Rakefile
|
39
|
+
- app/assets/javascripts/repres/bootstrap/application.js
|
40
|
+
- app/assets/stylesheets/repres/bootstrap/application.css
|
41
|
+
- app/controllers/repres/bootstrap/application_controller.rb
|
42
|
+
- app/helpers/repres/bootstrap/application_helper.rb
|
43
|
+
- app/views/layouts/unirer/bootstrap/application.html.erb
|
44
|
+
- app/views/repres/bootstrap/_form_field.html.erb
|
45
|
+
- app/views/repres/bootstrap/_form_select_box.html.erb
|
46
|
+
- app/views/repres/bootstrap/_script.html.erb
|
47
|
+
- app/views/repres/bootstrap/_style.html.erb
|
48
|
+
- config/routes.rb
|
49
|
+
- lib/repres/bootstrap.rb
|
50
|
+
- lib/repres/bootstrap/engine.rb
|
51
|
+
- lib/repres/bootstrap/version.rb
|
52
|
+
- lib/tasks/bootstrap_tasks.rake
|
53
|
+
homepage: https://github.com/topbitdu/repres-bootstrap
|
54
|
+
licenses:
|
55
|
+
- MIT
|
56
|
+
metadata: {}
|
57
|
+
post_install_message:
|
58
|
+
rdoc_options: []
|
59
|
+
require_paths:
|
60
|
+
- lib
|
61
|
+
required_ruby_version: !ruby/object:Gem::Requirement
|
62
|
+
requirements:
|
63
|
+
- - ">="
|
64
|
+
- !ruby/object:Gem::Version
|
65
|
+
version: '0'
|
66
|
+
required_rubygems_version: !ruby/object:Gem::Requirement
|
67
|
+
requirements:
|
68
|
+
- - ">="
|
69
|
+
- !ruby/object:Gem::Version
|
70
|
+
version: '0'
|
71
|
+
requirements: []
|
72
|
+
rubyforge_project:
|
73
|
+
rubygems_version: 2.4.5.1
|
74
|
+
signing_key:
|
75
|
+
specification_version: 4
|
76
|
+
summary: Repres Bootstrap Resource Presentation Engine Bootstrap资源表现引擎
|
77
|
+
test_files: []
|