bootsy 2.0.11 → 2.0.12
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +31 -37
- data/Rakefile +5 -5
- data/app/assets/javascripts/bootsy/editor_options.js +13 -1
- data/app/assets/stylesheets/bootsy.css +333 -3
- data/app/controllers/bootsy/images_controller.rb +23 -21
- data/app/helpers/bootsy/application_helper.rb +4 -2
- data/app/uploaders/bootsy/image_uploader.rb +9 -5
- data/app/views/bootsy/images/_modal.html.erb +6 -4
- data/lib/bootsy.rb +4 -6
- data/lib/bootsy/activerecord/image_gallery.rb +5 -2
- data/lib/bootsy/container.rb +10 -9
- data/lib/bootsy/engine.rb +3 -1
- data/lib/bootsy/form_helper.rb +36 -26
- data/lib/bootsy/simple_form/bootsy_input.rb +10 -6
- data/lib/bootsy/version.rb +2 -1
- data/lib/generators/bootsy/install_generator.rb +36 -22
- data/lib/generators/bootsy/templates/bootsy.rb +28 -28
- metadata +9 -12
- data/app/assets/stylesheets/bootsy/bootstrap-submenu.css +0 -47
- data/app/assets/stylesheets/bootsy/bootstrap-wysihtml5.css +0 -102
- data/app/assets/stylesheets/bootsy/bootsy.css +0 -170
@@ -1,7 +1,8 @@
|
|
1
1
|
# Use this setup block to configure all options available in Bootsy.
|
2
2
|
Bootsy.setup do |config|
|
3
3
|
# Default editor options
|
4
|
-
#
|
4
|
+
# You can also override them locally by passing an
|
5
|
+
# editor_options hash to bootsy_area
|
5
6
|
# config.editor_options = {
|
6
7
|
# font_styles: true,
|
7
8
|
# emphasis: true,
|
@@ -11,54 +12,53 @@ Bootsy.setup do |config|
|
|
11
12
|
# image: true,
|
12
13
|
# color: true
|
13
14
|
# }
|
14
|
-
|
15
|
+
#
|
15
16
|
# Image versions available
|
16
|
-
#
|
17
|
+
# Possible values: :small, :medium, :large and/or :original
|
17
18
|
config.image_versions_available = [:small, :medium, :large, :original]
|
18
|
-
|
19
|
-
|
19
|
+
#
|
20
|
+
#
|
20
21
|
# SMALL IMAGES
|
21
|
-
|
22
|
+
#
|
22
23
|
# Width limit for small images
|
23
24
|
# config.small_image[:width] = 160
|
24
|
-
|
25
|
+
#
|
25
26
|
# Height limit for small images
|
26
27
|
# config.small_image[:height] = 160
|
27
|
-
|
28
|
-
|
28
|
+
#
|
29
|
+
#
|
29
30
|
# MEDIUM IMAGES
|
30
|
-
|
31
|
+
#
|
31
32
|
# Width limit for medium images
|
32
33
|
# config.medium_image[:width] = 360
|
33
|
-
|
34
|
+
#
|
34
35
|
# Height limit for medium images
|
35
36
|
# config.medium_image[:height] = 360
|
36
|
-
|
37
|
-
|
37
|
+
#
|
38
|
+
#
|
38
39
|
# LARGE IMAGES
|
39
|
-
|
40
|
+
#
|
40
41
|
# Width limit for large images
|
41
42
|
# config.large_image[:width] = 760
|
42
|
-
|
43
|
+
#
|
43
44
|
# Height limit for large images
|
44
45
|
# config.large_image[:height] = 760
|
45
|
-
|
46
|
-
|
46
|
+
#
|
47
|
+
#
|
47
48
|
# Whether user can destroy uploaded files
|
48
49
|
# config.allow_destroy = true
|
49
|
-
|
50
|
-
|
51
|
-
# Storage mode
|
52
|
-
# You can change the sorage mode below from :file to :fog if you want
|
53
|
-
# to use Amazon S3 and other cloud services. If you do that, please add
|
54
|
-
# 'fog' to your Gemfile and create and configure your credentials in an
|
55
|
-
# initializer file, as described in Carrierwave's docs:
|
56
|
-
# https://github.com/carrierwaveuploader/carrierwave/blob/master/README.md#using-amazon-s3
|
57
50
|
#
|
51
|
+
#
|
52
|
+
# Storage mode
|
53
|
+
# You can change the sorage mode below from :file to :fog if you want
|
54
|
+
# to use Amazon S3 and other cloud services. If you do that, please add
|
55
|
+
# 'fog' to your Gemfile and create and configure your credentials in an
|
56
|
+
# initializer file, as described in Carrierwave's docs:
|
57
|
+
# https://github.com/carrierwaveuploader/carrierwave#using-amazon-s3
|
58
58
|
# config.storage = :file
|
59
|
-
|
60
|
-
|
59
|
+
#
|
60
|
+
#
|
61
61
|
# Store directory (inside 'public') for storage = :file
|
62
|
-
#
|
62
|
+
# BE CAREFUL! Changing this may break previously uploaded file paths!
|
63
63
|
# config.store_dir = 'uploads'
|
64
64
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: bootsy
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 2.0.
|
4
|
+
version: 2.0.12
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Volmer Soares
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2014-
|
11
|
+
date: 2014-12-14 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: mini_magick
|
@@ -16,42 +16,42 @@ dependencies:
|
|
16
16
|
requirements:
|
17
17
|
- - "~>"
|
18
18
|
- !ruby/object:Gem::Version
|
19
|
-
version:
|
19
|
+
version: '4.0'
|
20
20
|
type: :runtime
|
21
21
|
prerelease: false
|
22
22
|
version_requirements: !ruby/object:Gem::Requirement
|
23
23
|
requirements:
|
24
24
|
- - "~>"
|
25
25
|
- !ruby/object:Gem::Version
|
26
|
-
version:
|
26
|
+
version: '4.0'
|
27
27
|
- !ruby/object:Gem::Dependency
|
28
28
|
name: carrierwave
|
29
29
|
requirement: !ruby/object:Gem::Requirement
|
30
30
|
requirements:
|
31
31
|
- - "~>"
|
32
32
|
- !ruby/object:Gem::Version
|
33
|
-
version: 0.10
|
33
|
+
version: '0.10'
|
34
34
|
type: :runtime
|
35
35
|
prerelease: false
|
36
36
|
version_requirements: !ruby/object:Gem::Requirement
|
37
37
|
requirements:
|
38
38
|
- - "~>"
|
39
39
|
- !ruby/object:Gem::Version
|
40
|
-
version: 0.10
|
40
|
+
version: '0.10'
|
41
41
|
- !ruby/object:Gem::Dependency
|
42
42
|
name: remotipart
|
43
43
|
requirement: !ruby/object:Gem::Requirement
|
44
44
|
requirements:
|
45
45
|
- - "~>"
|
46
46
|
- !ruby/object:Gem::Version
|
47
|
-
version: 1.2
|
47
|
+
version: '1.2'
|
48
48
|
type: :runtime
|
49
49
|
prerelease: false
|
50
50
|
version_requirements: !ruby/object:Gem::Requirement
|
51
51
|
requirements:
|
52
52
|
- - "~>"
|
53
53
|
- !ruby/object:Gem::Version
|
54
|
-
version: 1.2
|
54
|
+
version: '1.2'
|
55
55
|
description: A beautiful WYSIWYG editor with image uploads for Rails.
|
56
56
|
email:
|
57
57
|
- volmerius@gmail.com
|
@@ -75,9 +75,6 @@ files:
|
|
75
75
|
- app/assets/javascripts/bootsy/translations.js
|
76
76
|
- app/assets/javascripts/bootsy/wysihtml5.js
|
77
77
|
- app/assets/stylesheets/bootsy.css
|
78
|
-
- app/assets/stylesheets/bootsy/bootstrap-submenu.css
|
79
|
-
- app/assets/stylesheets/bootsy/bootstrap-wysihtml5.css
|
80
|
-
- app/assets/stylesheets/bootsy/bootsy.css
|
81
78
|
- app/controllers/bootsy/application_controller.rb
|
82
79
|
- app/controllers/bootsy/images_controller.rb
|
83
80
|
- app/helpers/bootsy/application_helper.rb
|
@@ -126,7 +123,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
126
123
|
version: '0'
|
127
124
|
requirements: []
|
128
125
|
rubyforge_project:
|
129
|
-
rubygems_version: 2.
|
126
|
+
rubygems_version: 2.2.2
|
130
127
|
signing_key:
|
131
128
|
specification_version: 4
|
132
129
|
summary: A beautiful WYSIWYG editor with image uploads for Rails.
|
@@ -1,47 +0,0 @@
|
|
1
|
-
.dropdown-submenu {
|
2
|
-
position:relative;
|
3
|
-
}
|
4
|
-
|
5
|
-
.dropdown-submenu>.dropdown-menu {
|
6
|
-
top: 0;
|
7
|
-
left: 100%;
|
8
|
-
margin-top: -6px;
|
9
|
-
margin-left: -1px;
|
10
|
-
-webkit-border-radius: 0 6px 6px 6px;
|
11
|
-
-moz-border-radius: 0 6px 6px 6px;
|
12
|
-
border-radius: 0 6px 6px 6px;
|
13
|
-
}
|
14
|
-
|
15
|
-
.dropdown-submenu:hover > .dropdown-menu {
|
16
|
-
display:block;
|
17
|
-
}
|
18
|
-
|
19
|
-
.dropdown-submenu > a:after {
|
20
|
-
display: block;
|
21
|
-
content: " ";
|
22
|
-
float: right;
|
23
|
-
width: 0;
|
24
|
-
height: 0;
|
25
|
-
border-color: transparent;
|
26
|
-
border-style: solid;
|
27
|
-
border-width: 5px 0 5px 5px;
|
28
|
-
border-left-color: #cccccc;
|
29
|
-
margin-top: 5px;
|
30
|
-
margin-right: -10px;
|
31
|
-
}
|
32
|
-
|
33
|
-
.dropdown-submenu:hover > a:after {
|
34
|
-
border-left-color: #ffffff;
|
35
|
-
}
|
36
|
-
|
37
|
-
.dropdown-submenu.pull-left {
|
38
|
-
float:none;
|
39
|
-
}
|
40
|
-
|
41
|
-
.dropdown-submenu.pull-left > .dropdown-menu {
|
42
|
-
left: -100%;
|
43
|
-
margin-left: 10px;
|
44
|
-
-webkit-border-radius: 6px 0 6px 6px;
|
45
|
-
-moz-border-radius: 6px 0 6px 6px;
|
46
|
-
border-radius: 6px 0 6px 6px;
|
47
|
-
}
|
@@ -1,102 +0,0 @@
|
|
1
|
-
ul.wysihtml5-toolbar {
|
2
|
-
margin: 0;
|
3
|
-
padding: 0;
|
4
|
-
display: block;
|
5
|
-
}
|
6
|
-
|
7
|
-
ul.wysihtml5-toolbar::after {
|
8
|
-
clear: both;
|
9
|
-
display: table;
|
10
|
-
content: "";
|
11
|
-
}
|
12
|
-
|
13
|
-
ul.wysihtml5-toolbar > li {
|
14
|
-
float: left;
|
15
|
-
display: list-item;
|
16
|
-
list-style: none;
|
17
|
-
margin: 0 5px 10px 0;
|
18
|
-
}
|
19
|
-
|
20
|
-
ul.wysihtml5-toolbar a[data-wysihtml5-command=bold] {
|
21
|
-
font-weight: bold;
|
22
|
-
}
|
23
|
-
|
24
|
-
ul.wysihtml5-toolbar a[data-wysihtml5-command=italic] {
|
25
|
-
font-style: italic;
|
26
|
-
}
|
27
|
-
|
28
|
-
ul.wysihtml5-toolbar a[data-wysihtml5-command=underline] {
|
29
|
-
text-decoration: underline;
|
30
|
-
}
|
31
|
-
|
32
|
-
ul.wysihtml5-toolbar a.btn.wysihtml5-command-active {
|
33
|
-
background-image: none;
|
34
|
-
-webkit-box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.15),0 1px 2px rgba(0, 0, 0, 0.05);
|
35
|
-
-moz-box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.15),0 1px 2px rgba(0, 0, 0, 0.05);
|
36
|
-
box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.15),0 1px 2px rgba(0, 0, 0, 0.05);
|
37
|
-
background-color: #E6E6E6;
|
38
|
-
background-color: #D9D9D9;
|
39
|
-
outline: 0;
|
40
|
-
}
|
41
|
-
|
42
|
-
ul.wysihtml5-commands-disabled .dropdown-menu {
|
43
|
-
display: none !important;
|
44
|
-
}
|
45
|
-
|
46
|
-
ul.wysihtml5-toolbar div.wysihtml5-colors {
|
47
|
-
display:block;
|
48
|
-
width: 50px;
|
49
|
-
height: 20px;
|
50
|
-
margin-top: 2px;
|
51
|
-
margin-left: 5px;
|
52
|
-
position: absolute;
|
53
|
-
pointer-events: none;
|
54
|
-
}
|
55
|
-
|
56
|
-
ul.wysihtml5-toolbar a.wysihtml5-colors-title {
|
57
|
-
padding-left: 70px;
|
58
|
-
}
|
59
|
-
|
60
|
-
ul.wysihtml5-toolbar div[data-wysihtml5-command-value="black"] {
|
61
|
-
background: black !important;
|
62
|
-
}
|
63
|
-
|
64
|
-
ul.wysihtml5-toolbar div[data-wysihtml5-command-value="silver"] {
|
65
|
-
background: silver !important;
|
66
|
-
}
|
67
|
-
|
68
|
-
ul.wysihtml5-toolbar div[data-wysihtml5-command-value="gray"] {
|
69
|
-
background: gray !important;
|
70
|
-
}
|
71
|
-
|
72
|
-
ul.wysihtml5-toolbar div[data-wysihtml5-command-value="maroon"] {
|
73
|
-
background: maroon !important;
|
74
|
-
}
|
75
|
-
|
76
|
-
ul.wysihtml5-toolbar div[data-wysihtml5-command-value="red"] {
|
77
|
-
background: red !important;
|
78
|
-
}
|
79
|
-
|
80
|
-
ul.wysihtml5-toolbar div[data-wysihtml5-command-value="purple"] {
|
81
|
-
background: purple !important;
|
82
|
-
}
|
83
|
-
|
84
|
-
ul.wysihtml5-toolbar div[data-wysihtml5-command-value="green"] {
|
85
|
-
background: green !important;
|
86
|
-
}
|
87
|
-
|
88
|
-
ul.wysihtml5-toolbar div[data-wysihtml5-command-value="olive"] {
|
89
|
-
background: olive !important;
|
90
|
-
}
|
91
|
-
|
92
|
-
ul.wysihtml5-toolbar div[data-wysihtml5-command-value="navy"] {
|
93
|
-
background: navy !important;
|
94
|
-
}
|
95
|
-
|
96
|
-
ul.wysihtml5-toolbar div[data-wysihtml5-command-value="blue"] {
|
97
|
-
background: blue !important;
|
98
|
-
}
|
99
|
-
|
100
|
-
ul.wysihtml5-toolbar div[data-wysihtml5-command-value="orange"] {
|
101
|
-
background: orange !important;
|
102
|
-
}
|
@@ -1,170 +0,0 @@
|
|
1
|
-
.wysiwyg-color-black {
|
2
|
-
color: black;
|
3
|
-
}
|
4
|
-
|
5
|
-
.wysiwyg-color-silver {
|
6
|
-
color: silver;
|
7
|
-
}
|
8
|
-
|
9
|
-
.wysiwyg-color-gray {
|
10
|
-
color: gray;
|
11
|
-
}
|
12
|
-
|
13
|
-
.wysiwyg-color-white {
|
14
|
-
color: white;
|
15
|
-
}
|
16
|
-
|
17
|
-
.wysiwyg-color-maroon {
|
18
|
-
color: maroon;
|
19
|
-
}
|
20
|
-
|
21
|
-
.wysiwyg-color-red {
|
22
|
-
color: red;
|
23
|
-
}
|
24
|
-
|
25
|
-
.wysiwyg-color-purple {
|
26
|
-
color: purple;
|
27
|
-
}
|
28
|
-
|
29
|
-
.wysiwyg-color-fuchsia {
|
30
|
-
color: fuchsia;
|
31
|
-
}
|
32
|
-
|
33
|
-
.wysiwyg-color-green {
|
34
|
-
color: green;
|
35
|
-
}
|
36
|
-
|
37
|
-
.wysiwyg-color-lime {
|
38
|
-
color: lime;
|
39
|
-
}
|
40
|
-
|
41
|
-
.wysiwyg-color-olive {
|
42
|
-
color: olive;
|
43
|
-
}
|
44
|
-
|
45
|
-
.wysiwyg-color-orange {
|
46
|
-
color: orange;
|
47
|
-
}
|
48
|
-
|
49
|
-
.wysiwyg-color-yellow {
|
50
|
-
color: yellow;
|
51
|
-
}
|
52
|
-
|
53
|
-
.wysiwyg-color-navy {
|
54
|
-
color: navy;
|
55
|
-
}
|
56
|
-
|
57
|
-
.wysiwyg-color-blue {
|
58
|
-
color: blue;
|
59
|
-
}
|
60
|
-
|
61
|
-
.wysiwyg-color-teal {
|
62
|
-
color: teal;
|
63
|
-
}
|
64
|
-
|
65
|
-
.wysiwyg-color-aqua {
|
66
|
-
color: aqua;
|
67
|
-
}
|
68
|
-
|
69
|
-
.wysiwyg-float-left {
|
70
|
-
float: left;
|
71
|
-
margin: 0 8px 8px 0;
|
72
|
-
}
|
73
|
-
|
74
|
-
.wysiwyg-float-right {
|
75
|
-
float: right;
|
76
|
-
margin: 0 0 8px 8px;
|
77
|
-
}
|
78
|
-
|
79
|
-
.bootsy blockquote {
|
80
|
-
padding: 10px 20px;
|
81
|
-
margin: 0 0 20px;
|
82
|
-
font-size: 17.5px;
|
83
|
-
border-left: 5px solid #eee;
|
84
|
-
}
|
85
|
-
.bootsy blockquote p:last-child,
|
86
|
-
.bootsy blockquote ul:last-child,
|
87
|
-
.bootsy blockquote ol:last-child {
|
88
|
-
margin-bottom: 0;
|
89
|
-
}
|
90
|
-
.bootsy blockquote footer,
|
91
|
-
.bootsy blockquote small,
|
92
|
-
.bootsy blockquote .small {
|
93
|
-
display: block;
|
94
|
-
font-size: 80%;
|
95
|
-
line-height: 1.42857143;
|
96
|
-
color: #777;
|
97
|
-
}
|
98
|
-
.bootsy blockquote footer:before,
|
99
|
-
.bootsy blockquote small:before,
|
100
|
-
.bootsy blockquote .small:before {
|
101
|
-
content: '\2014 \00A0';
|
102
|
-
}
|
103
|
-
.bootsy .blockquote-reverse,
|
104
|
-
.bootsy blockquote.pull-right {
|
105
|
-
padding-right: 15px;
|
106
|
-
padding-left: 0;
|
107
|
-
text-align: right;
|
108
|
-
border-right: 5px solid #eee;
|
109
|
-
border-left: 0;
|
110
|
-
}
|
111
|
-
.bootsy .blockquote-reverse footer:before,
|
112
|
-
.bootsy blockquote.pull-right footer:before,
|
113
|
-
.blockquote-reverse small:before,
|
114
|
-
.bootsy blockquote.pull-right small:before,
|
115
|
-
.bootsy .blockquote-reverse .small:before,
|
116
|
-
.bootsy blockquote.pull-right .small:before {
|
117
|
-
content: '';
|
118
|
-
}
|
119
|
-
.bootsy .blockquote-reverse footer:after,
|
120
|
-
.bootsy blockquote.pull-right footer:after,
|
121
|
-
.bootsy .blockquote-reverse small:after,
|
122
|
-
.bootsy blockquote.pull-right small:after,
|
123
|
-
.bootsy .blockquote-reverse .small:after,
|
124
|
-
.bootsy blockquote.pull-right .small:after {
|
125
|
-
content: '\00A0 \2014';
|
126
|
-
}
|
127
|
-
.bootsy blockquote:before,
|
128
|
-
.bootsy blockquote:after {
|
129
|
-
content: "";
|
130
|
-
}
|
131
|
-
|
132
|
-
textarea.bootsy:required:invalid {
|
133
|
-
color: inherit;
|
134
|
-
}
|
135
|
-
|
136
|
-
/*Modal Design Styles*/
|
137
|
-
|
138
|
-
.bootsy-modal .file-input-name {display: none;} /*Hide the input file name from showing as it's not needed and ruins design*/
|
139
|
-
|
140
|
-
/*Set a min-height on the modal body to prevent jumping up and down of modal when adding content*/
|
141
|
-
.bootsy-modal .modal-body {
|
142
|
-
min-height: 120px;
|
143
|
-
}
|
144
|
-
|
145
|
-
.bootsy-image {
|
146
|
-
margin-bottom: 15px;
|
147
|
-
}
|
148
|
-
|
149
|
-
.bootsy-upload-loader {
|
150
|
-
display: inline-block;
|
151
|
-
padding-right: 5px;
|
152
|
-
}
|
153
|
-
|
154
|
-
.bootsy-gallery-loader {
|
155
|
-
display: block;
|
156
|
-
margin: 0 auto;
|
157
|
-
}
|
158
|
-
|
159
|
-
/*The below code is needed for capybara to be able to find the input, as it*/
|
160
|
-
/*does not work*/
|
161
|
-
.file-input-wrapper input[type=file], .file-input-wrapper input[type=file]:focus, .file-input-wrapper input[type=file]:hover {
|
162
|
-
opacity: .01;
|
163
|
-
}
|
164
|
-
|
165
|
-
/* Avoid Boostrap input borders */
|
166
|
-
body.bootsy_text_area.form-control {
|
167
|
-
border: none;
|
168
|
-
-webkit-box-shadow: none;
|
169
|
-
box-shadow: none;
|
170
|
-
}
|