notee 1.0.1 → 1.0.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/app/views/notee/partials/_comment_box.html.erb +1 -2
- data/lib/notee/version.rb +1 -1
- data/lib/tasks/config/notee.rb +1 -1
- data/lib/tasks/notee_tasks.rake +28 -0
- data/lib/tasks/stylesheets/notee/notee_default.css +7 -10
- data/lib/tasks/views/notee/show.html.erb +3 -0
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 87a081e0734946c5e30c81253f5f3a97a950a75a
|
4
|
+
data.tar.gz: 1ff89c2cae6aad44990971d24e448a6ce6682094
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 7950a9d6da13c058424a3c521d8aa427be7a4677a97bce8085fef1328b49f0af98bb094f1408468c8617d5862194773a2b8dd15a2537ffa5126361d3ebc2f34e
|
7
|
+
data.tar.gz: c36d95287e9c878bcdb807ac5c70d23e4d908ef4842fa130d32c50e792e818d5727ad9fe6395aa2bfd72095849b0eb423919d218496584566a7ddaabde7d13f7
|
@@ -1,4 +1,4 @@
|
|
1
|
-
<div class="
|
1
|
+
<div class="notee_list">
|
2
2
|
<comments post_id='<%= post_id %>'></comments>
|
3
3
|
<comment_form post_id='<%= post_id %>'></comment_form>
|
4
4
|
</div>
|
@@ -16,7 +16,6 @@
|
|
16
16
|
<comment_form class="notee_comment_form" id="notee_form">
|
17
17
|
<form method="POST">
|
18
18
|
|
19
|
-
|
20
19
|
<label class="notee_label" for="comment_name">Name</label>
|
21
20
|
<input class="notee_text_field" type="text" name="comment[name]" id="comment_name" />
|
22
21
|
|
data/lib/notee/version.rb
CHANGED
data/lib/tasks/config/notee.rb
CHANGED
@@ -17,7 +17,7 @@ Notee.configure do |config|
|
|
17
17
|
title: "Notee",
|
18
18
|
url: "http://hogehoge.com",
|
19
19
|
keyword: "hoge, hoge, hoge",
|
20
|
-
description: "
|
20
|
+
description: "【react&rails】notee is creating CMS(blog) app by only one command.",
|
21
21
|
og_image: "http://hogehoge.com/hoge.png"
|
22
22
|
}
|
23
23
|
|
data/lib/tasks/notee_tasks.rake
CHANGED
@@ -9,6 +9,7 @@ namespace :notee do
|
|
9
9
|
add_engine_to_route
|
10
10
|
add_highlight_setting_to_js
|
11
11
|
add_notee_css_path
|
12
|
+
add_viewport_meta_info_and_delete_title
|
12
13
|
copy_directory("/app/views/", "../views/notee")
|
13
14
|
copy_directory("/app/assets/stylesheets/notee/", "../stylesheets/notee")
|
14
15
|
copy_directory("/app/assets/javascripts/notee/", "../javascripts/notee")
|
@@ -140,6 +141,33 @@ $(document).on('ready', function() {
|
|
140
141
|
puts ""
|
141
142
|
end
|
142
143
|
|
144
|
+
def add_viewport_meta_info_and_delete_title
|
145
|
+
puts ""
|
146
|
+
return puts 'setup for application.html.erb in /app/views/layouts/application.html.erb\n' unless route = File.open("#{Rails.root}/app/views/layouts/application.html.erb","r")
|
147
|
+
return if File.open("#{Rails.root}/app/views/layouts/application.html.erb","r").read.include?('<meta name="viewport" content="width=device-width,initial-scale=1.0" />')
|
148
|
+
|
149
|
+
text = <<-EOC
|
150
|
+
|
151
|
+
<meta name="viewport" content="width=device-width,initial-scale=1.0" />
|
152
|
+
|
153
|
+
EOC
|
154
|
+
|
155
|
+
new_html = String.new
|
156
|
+
route.each_line do |line|
|
157
|
+
line += text if line.include?("<head>")
|
158
|
+
line = "" if line.include?("<title>")
|
159
|
+
new_html += line
|
160
|
+
end
|
161
|
+
|
162
|
+
f = File.open("#{Rails.root}/app/views/layouts/application.html.erb","w")
|
163
|
+
f.write(new_html)
|
164
|
+
f.close()
|
165
|
+
|
166
|
+
puts 'Notee added "viewport meta info" to /app/views/layouts/application.html.erb'
|
167
|
+
puts 'Notee deleted "Title tag" in /app/views/layouts/application.html.erb'
|
168
|
+
puts ""
|
169
|
+
end
|
170
|
+
|
143
171
|
|
144
172
|
private
|
145
173
|
|
@@ -243,16 +243,8 @@ ul.li_none , ol.li_none { list-style: none; }
|
|
243
243
|
|
244
244
|
/* notee_comment_box */
|
245
245
|
|
246
|
-
.notee_comment_box {
|
247
|
-
width: 100%;
|
248
|
-
margin: 30px auto;
|
249
|
-
float: left;
|
250
|
-
}
|
251
|
-
|
252
246
|
.notee_comments {
|
253
247
|
width: 94%;
|
254
|
-
padding: 3%;
|
255
|
-
margin_bottom: 20px;
|
256
248
|
float: left;
|
257
249
|
}
|
258
250
|
|
@@ -288,6 +280,7 @@ ul.li_none , ol.li_none { list-style: none; }
|
|
288
280
|
.notee_text_area {
|
289
281
|
width: 100%;
|
290
282
|
height: 78px;
|
283
|
+
min-width: 300px;
|
291
284
|
margin-bottom: 15px;
|
292
285
|
float: left;
|
293
286
|
font-size: 14px;
|
@@ -295,9 +288,13 @@ ul.li_none , ol.li_none { list-style: none; }
|
|
295
288
|
|
296
289
|
.notee_submit {
|
297
290
|
width: 100%;
|
298
|
-
|
291
|
+
height: 40px;
|
292
|
+
line-height: 40px;
|
299
293
|
float: left;
|
300
|
-
font-size:
|
294
|
+
font-size: 16px;
|
295
|
+
border: 0px solid #F7F7F7;
|
296
|
+
background-color: #337C99;
|
297
|
+
color: #F7F7F7;
|
301
298
|
}
|
302
299
|
|
303
300
|
/* pc */
|