Show More
@@ -187,6 +187,7 b' Check if we should use full-topic or min' | |||
|
187 | 187 | I think something like this would be better |
|
188 | 188 | |
|
189 | 189 | ```py |
|
190 | // markdown renderer | |
|
190 | 191 | |
|
191 | 192 | def db(): |
|
192 | 193 | global connection |
@@ -226,10 +227,26 b' def db():' | |||
|
226 | 227 | 'comment_body': ''' |
|
227 | 228 | I like this ! |
|
228 | 229 | |
|
229 |
But please check this code |
|
|
230 | But please check this code | |
|
231 | ||
|
232 | .. code-block:: javascript | |
|
233 | ||
|
234 | // THIS IS RST CODE | |
|
235 | ||
|
236 | this.createResolutionComment = function(commentId) { | |
|
237 | // hide the trigger text | |
|
238 | $('#resolve-comment-{0}'.format(commentId)).hide(); | |
|
230 | 239 | |
|
231 | def main(): | |
|
232 | print 'ok' | |
|
240 | var comment = $('#comment-'+commentId); | |
|
241 | var commentData = comment.data(); | |
|
242 | if (commentData.commentInline) { | |
|
243 | this.createComment(comment, commentId) | |
|
244 | } else { | |
|
245 | Rhodecode.comments.createGeneralComment('general', "$placeholder", commentId) | |
|
246 | } | |
|
247 | ||
|
248 | return false; | |
|
249 | }; | |
|
233 | 250 | |
|
234 | 251 | This should work better ! |
|
235 | 252 | ''', |
@@ -101,6 +101,7 b' text_monospace = "\'Menlo\', \'Liberation M' | |||
|
101 | 101 | margin: 0; |
|
102 | 102 | padding: 0; |
|
103 | 103 | font-family: ${text_regular|n}; |
|
104 | color: #000000; | |
|
104 | 105 | } |
|
105 | 106 | |
|
106 | 107 | /* Prevent Webkit and Windows Mobile platforms from changing default font sizes.*/ |
@@ -211,6 +212,20 b' text_monospace = "\'Menlo\', \'Liberation M' | |||
|
211 | 212 | |
|
212 | 213 | code { |
|
213 | 214 | font-family: ${text_monospace|n}; |
|
215 | white-space: pre-line !important; | |
|
216 | color: #000000; | |
|
217 | } | |
|
218 | ||
|
219 | ul.changes-ul { | |
|
220 | list-style: none; | |
|
221 | list-style-type: none; | |
|
222 | padding: 0; | |
|
223 | margin: 10px 0; | |
|
224 | } | |
|
225 | ul.changes-ul li { | |
|
226 | list-style: none; | |
|
227 | list-style-type: none; | |
|
228 | margin: 2px 0; | |
|
214 | 229 | } |
|
215 | 230 | |
|
216 | 231 | @media only screen and (-webkit-min-device-pixel-ratio: 2) { |
@@ -237,13 +252,19 b' text_monospace = "\'Menlo\', \'Liberation M' | |||
|
237 | 252 | padding: 3px 5px 3px |
|
238 | 253 | } |
|
239 | 254 | |
|
240 | div.markdown-block h1, div.markdown-block h2, div.markdown-block h3, div.markdown-block h4, div.markdown-block h5, div.markdown-block h6 { | |
|
255 | div.markdown-block h1, | |
|
256 | div.markdown-block h2, | |
|
257 | div.markdown-block h3, | |
|
258 | div.markdown-block h4, | |
|
259 | div.markdown-block h5, | |
|
260 | div.markdown-block h6 { | |
|
241 | 261 | border-bottom: none !important; |
|
242 | 262 | padding: 0 !important; |
|
243 | 263 | overflow: visible !important |
|
244 | 264 | } |
|
245 | 265 | |
|
246 |
div.markdown-block h1, |
|
|
266 | div.markdown-block h1, | |
|
267 | div.markdown-block h2 { | |
|
247 | 268 | border-bottom: 1px #e6e5e5 solid !important |
|
248 | 269 | } |
|
249 | 270 | |
@@ -290,7 +311,13 b' text_monospace = "\'Menlo\', \'Liberation M' | |||
|
290 | 311 | margin-bottom: 13px |
|
291 | 312 | } |
|
292 | 313 | |
|
293 | div.markdown-block ol, div.markdown-block ul, div.markdown-block p, div.markdown-block blockquote, div.markdown-block dl, div.markdown-block li, div.markdown-block table { | |
|
314 | div.markdown-block ol, | |
|
315 | div.markdown-block ul, | |
|
316 | div.markdown-block p, | |
|
317 | div.markdown-block blockquote, | |
|
318 | div.markdown-block dl, | |
|
319 | div.markdown-block li, | |
|
320 | div.markdown-block table { | |
|
294 | 321 | margin: 3px 0 13px 0 !important; |
|
295 | 322 | color: #424242 !important; |
|
296 | 323 | font-size: 13px !important; |
@@ -371,27 +398,30 b' text_monospace = "\'Menlo\', \'Liberation M' | |||
|
371 | 398 | background-color: #eeeeee |
|
372 | 399 | } |
|
373 | 400 | |
|
374 | div.markdown-block code, div.markdown-block pre, div.markdown-block #ws, div.markdown-block #message { | |
|
401 | div.markdown-block code, | |
|
402 | div.markdown-block pre, | |
|
403 | div.markdown-block #ws, | |
|
404 | div.markdown-block #message { | |
|
375 | 405 | font-family: ${text_monospace|n}; |
|
376 | 406 | font-size: 11px; |
|
377 | 407 | -webkit-border-radius: 2px; |
|
378 | 408 | -moz-border-radius: 2px; |
|
379 | 409 | border-radius: 2px; |
|
380 |
background-color: |
|
|
410 | background-color: #FFFFFF; | |
|
381 | 411 | color: #7E7F7F |
|
382 | 412 | } |
|
383 | 413 | |
|
384 | 414 | div.markdown-block code { |
|
385 |
border: 1px solid # |
|
|
415 | border: 1px solid #7E7F7F; | |
|
386 | 416 | margin: 0 2px; |
|
387 | 417 | padding: 0 5px |
|
388 | 418 | } |
|
389 | 419 | |
|
390 | 420 | div.markdown-block pre { |
|
391 |
border: 1px solid # |
|
|
421 | border: 1px solid #7E7F7F; | |
|
392 | 422 | overflow: auto; |
|
393 | 423 | padding: .5em; |
|
394 |
background-color: #F |
|
|
424 | background-color: #FFFFFF; | |
|
395 | 425 | } |
|
396 | 426 | |
|
397 | 427 | div.markdown-block pre > code { |
@@ -411,7 +441,12 b' text_monospace = "\'Menlo\', \'Liberation M' | |||
|
411 | 441 | font-weight: normal |
|
412 | 442 | } |
|
413 | 443 | |
|
414 | div.rst-block h1, div.rst-block h2, div.rst-block h3, div.rst-block h4, div.rst-block h5, div.rst-block h6 { | |
|
444 | div.rst-block h1, | |
|
445 | div.rst-block h2, | |
|
446 | div.rst-block h3, | |
|
447 | div.rst-block h4, | |
|
448 | div.rst-block h5, | |
|
449 | div.rst-block h6 { | |
|
415 | 450 | border-bottom: 0 !important; |
|
416 | 451 | margin: 0 !important; |
|
417 | 452 | padding: 0 !important; |
@@ -461,7 +496,7 b' text_monospace = "\'Menlo\', \'Liberation M' | |||
|
461 | 496 | background-color: ghostWhite !important; |
|
462 | 497 | color: #444 !important; |
|
463 | 498 | padding: 0 .2em !important; |
|
464 |
border: 1px solid # |
|
|
499 | border: 1px solid #7E7F7F !important | |
|
465 | 500 | } |
|
466 | 501 | |
|
467 | 502 | div.rst-block pre code { |
@@ -474,14 +509,18 b' text_monospace = "\'Menlo\', \'Liberation M' | |||
|
474 | 509 | div.rst-block pre { |
|
475 | 510 | margin: 1em 0; |
|
476 | 511 | padding: 15px; |
|
477 |
border: 1px solid # |
|
|
512 | border: 1px solid #7E7F7F; | |
|
478 | 513 | -webkit-border-radius: 2px; |
|
479 | 514 | -moz-border-radius: 2px; |
|
480 | 515 | border-radius: 2px; |
|
481 | 516 | overflow: auto; |
|
482 | 517 | font-size: 12px; |
|
483 | 518 | color: #444; |
|
484 |
background-color: #F |
|
|
519 | background-color: #FFFFFF; | |
|
520 | } | |
|
521 | ||
|
522 | .clear-both { | |
|
523 | clear:both; | |
|
485 | 524 | } |
|
486 | 525 | |
|
487 | 526 | /*elasticmatch is custom rhodecode tag*/ |
@@ -581,7 +620,7 b' text_monospace = "\'Menlo\', \'Liberation M' | |||
|
581 | 620 | </a> |
|
582 | 621 | </td> |
|
583 | 622 | </tr> |
|
584 | <tr> | |
|
623 | <tr style="background-color: #fff"> | |
|
585 | 624 | <td style="padding:15px;" valign="top">${self.body()}</td> |
|
586 | 625 | </tr> |
|
587 | 626 | </table> |
@@ -89,12 +89,13 b' data = {' | |||
|
89 | 89 | } |
|
90 | 90 | %> |
|
91 | 91 | |
|
92 | ## header | |
|
92 | 93 | <table style="text-align:left;vertical-align:middle;width: 100%"> |
|
93 | 94 | <tr> |
|
94 | 95 | <td style="width:100%;border-bottom:1px solid #dbd9da;"> |
|
95 | 96 | |
|
96 |
< |
|
|
97 | <div style="margin-bottom: 4px"> | |
|
97 | <div style="margin: 0; font-weight: bold"> | |
|
98 | <div class="clear-both" style="margin-bottom: 4px"> | |
|
98 | 99 | <span style="color:#7E7F7F">@${h.person(user.username)}</span> |
|
99 | 100 | ${_('left a')} |
|
100 | 101 | <a href="${commit_comment_url}" style="${base.link_css()}"> |
@@ -107,13 +108,14 b' data = {' | |||
|
107 | 108 | </div> |
|
108 | 109 | <div style="margin-top: 10px"></div> |
|
109 | 110 | ${_('Commit')} <code>${data['commit_id']}</code> ${_('of repository')}: ${data['repo_name']} |
|
110 |
</ |
|
|
111 | </div> | |
|
111 | 112 | |
|
112 | 113 | </td> |
|
113 | 114 | </tr> |
|
114 | 115 | |
|
115 | 116 | </table> |
|
116 | ||
|
117 | <div class="clear-both"></div> | |
|
118 | ## main body | |
|
117 | 119 | <table style="text-align:left;vertical-align:middle;width: 100%"> |
|
118 | 120 | |
|
119 | 121 | ## spacing def |
@@ -110,12 +110,13 b' data = {' | |||
|
110 | 110 | } |
|
111 | 111 | %> |
|
112 | 112 | |
|
113 | ## header | |
|
113 | 114 | <table style="text-align:left;vertical-align:middle;width: 100%"> |
|
114 | 115 | <tr> |
|
115 | 116 | <td style="width:100%;border-bottom:1px solid #dbd9da;"> |
|
116 | 117 | |
|
117 |
< |
|
|
118 | <div style="margin-bottom: 4px"> | |
|
118 | <div style="margin: 0; font-weight: bold"> | |
|
119 | <div class="clear-both" style="margin-bottom: 4px"> | |
|
119 | 120 | <span style="color:#7E7F7F">@${h.person(user.username)}</span> |
|
120 | 121 | ${_('left a')} |
|
121 | 122 | <a href="${pr_comment_url}" style="${base.link_css()}"> |
@@ -128,13 +129,14 b' data = {' | |||
|
128 | 129 | </div> |
|
129 | 130 | <div style="margin-top: 10px"></div> |
|
130 | 131 | ${_('Pull request')} <code>!${data['pr_id']}: ${data['pr_title']}</code> |
|
131 |
</ |
|
|
132 | </div> | |
|
132 | 133 | |
|
133 | 134 | </td> |
|
134 | 135 | </tr> |
|
135 | 136 | |
|
136 | 137 | </table> |
|
137 | ||
|
138 | <div class="clear-both"></div> | |
|
139 | ## main body | |
|
138 | 140 | <table style="text-align:left;vertical-align:middle;width: 100%"> |
|
139 | 141 | |
|
140 | 142 | ## spacing def |
@@ -72,13 +72,13 b' data = {' | |||
|
72 | 72 | 'target_repo_url': h.link_to(pull_request_target_repo.repo_name, pull_request_target_repo_url), |
|
73 | 73 | } |
|
74 | 74 | %> |
|
75 | ||
|
75 | ## header | |
|
76 | 76 | <table style="text-align:left;vertical-align:middle;width: 100%"> |
|
77 | 77 | <tr> |
|
78 | 78 | <td style="width:100%;border-bottom:1px solid #dbd9da;"> |
|
79 | 79 | |
|
80 |
< |
|
|
81 | <div style="margin-bottom: 4px"> | |
|
80 | <div style="margin: 0; font-weight: bold"> | |
|
81 | <div class="clear-both" class="clear-both" style="margin-bottom: 4px"> | |
|
82 | 82 | <span style="color:#7E7F7F">@${h.person(user.username)}</span> |
|
83 | 83 | ${_('requested a')} |
|
84 | 84 | <a href="${pull_request_url}" style="${base.link_css()}"> |
@@ -87,13 +87,14 b' data = {' | |||
|
87 | 87 | </div> |
|
88 | 88 | <div style="margin-top: 10px"></div> |
|
89 | 89 | ${_('Pull request')} <code>!${data['pr_id']}: ${data['pr_title']}</code> |
|
90 |
</ |
|
|
90 | </div> | |
|
91 | 91 | |
|
92 | 92 | </td> |
|
93 | 93 | </tr> |
|
94 | 94 | |
|
95 | 95 | </table> |
|
96 | ||
|
96 | <div class="clear-both"></div> | |
|
97 | ## main body | |
|
97 | 98 | <table style="text-align:left;vertical-align:middle;width: 100%"> |
|
98 | 99 | ## spacing def |
|
99 | 100 | <tr> |
@@ -85,12 +85,13 b' data = {' | |||
|
85 | 85 | } |
|
86 | 86 | %> |
|
87 | 87 | |
|
88 | ## header | |
|
88 | 89 | <table style="text-align:left;vertical-align:middle;width: 100%"> |
|
89 | 90 | <tr> |
|
90 | 91 | <td style="width:100%;border-bottom:1px solid #dbd9da;"> |
|
91 | 92 | |
|
92 |
< |
|
|
93 | <div style="margin-bottom: 4px"> | |
|
93 | <div style="margin: 0; font-weight: bold"> | |
|
94 | <div class="clear-both" style="margin-bottom: 4px"> | |
|
94 | 95 | <span style="color:#7E7F7F">@${h.person(updating_user.username)}</span> |
|
95 | 96 | ${_('updated')} |
|
96 | 97 | <a href="${pull_request_url}" style="${base.link_css()}"> |
@@ -99,13 +100,14 b' data = {' | |||
|
99 | 100 | </div> |
|
100 | 101 | <div style="margin-top: 10px"></div> |
|
101 | 102 | ${_('Pull request')} <code>!${data['pr_id']}: ${data['pr_title']}</code> |
|
102 |
</ |
|
|
103 | </div> | |
|
103 | 104 | |
|
104 | 105 | </td> |
|
105 | 106 | </tr> |
|
106 | 107 | |
|
107 | 108 | </table> |
|
108 | ||
|
109 | <div class="clear-both"></div> | |
|
110 | ## main body | |
|
109 | 111 | <table style="text-align:left;vertical-align:middle;width: 100%"> |
|
110 | 112 | ## spacing def |
|
111 | 113 | <tr> |
@@ -137,27 +139,31 b' data = {' | |||
|
137 | 139 | </tr> |
|
138 | 140 | <tr> |
|
139 | 141 | <td style="padding-right:20px;">${_('Changes')}:</td> |
|
140 | <td style="white-space:pre-line">\ | |
|
142 | <td> | |
|
141 | 143 |
|
|
142 | ||
|
143 | - Added: ${len(added_commits)} | |
|
144 | - Removed: ${len(removed_commits)} | |
|
144 | <ul class="changes-ul"> | |
|
145 | <li>- Added: ${len(added_commits)}</li> | |
|
146 | <li>- Removed: ${len(removed_commits)}</li> | |
|
147 | </ul> | |
|
145 | 148 | |
|
146 | 149 | <strong>Changed files:</strong> |
|
150 | <ul class="changes-ul"> | |
|
147 | 151 | |
|
148 | 152 | %if not changed_files: |
|
149 | No file changes found | |
|
153 | <li>No file changes found</li> | |
|
150 | 154 | %else: |
|
151 | 155 | %for file_name in added_files: |
|
152 | - A <a href="${pull_request_url + '#a_' + h.FID(ancestor_commit_id, file_name)}">${file_name}</a> | |
|
156 | <li>- A <a href="${pull_request_url + '#a_' + h.FID(ancestor_commit_id, file_name)}">${file_name}</a></li> | |
|
153 | 157 | %endfor |
|
154 | 158 | %for file_name in modified_files: |
|
155 | - M <a href="${pull_request_url + '#a_' + h.FID(ancestor_commit_id, file_name)}">${file_name}</a> | |
|
159 | <li>- M <a href="${pull_request_url + '#a_' + h.FID(ancestor_commit_id, file_name)}">${file_name}</a></li> | |
|
156 | 160 | %endfor |
|
157 | 161 | %for file_name in removed_files: |
|
158 | - R <a href="${pull_request_url + '#a_' + h.FID(ancestor_commit_id, file_name)}">${file_name}</a> | |
|
162 | <li>- R <a href="${pull_request_url + '#a_' + h.FID(ancestor_commit_id, file_name)}">${file_name}</a></li> | |
|
159 | 163 | %endfor |
|
160 | 164 | %endif |
|
165 | ||
|
166 | </ul> | |
|
161 | 167 | </td> |
|
162 | 168 | </tr> |
|
163 | 169 |
@@ -19,7 +19,7 b' A new user `${user.username}` has regist' | |||
|
19 | 19 | ${self.plaintext_footer()} |
|
20 | 20 | </%def> |
|
21 | 21 | |
|
22 | ||
|
22 | ## header | |
|
23 | 23 | <table style="text-align:left;vertical-align:middle;width: 100%"> |
|
24 | 24 | <tr> |
|
25 | 25 | <td style="width:100%;border-bottom:1px solid #dbd9da;"> |
@@ -31,7 +31,8 b' A new user `${user.username}` has regist' | |||
|
31 | 31 | </td> |
|
32 | 32 | </tr> |
|
33 | 33 | </table> |
|
34 | ||
|
34 | <div class="clear-both"></div> | |
|
35 | ## main body | |
|
35 | 36 | <table style="text-align:left;vertical-align:middle;width: 100%"> |
|
36 | 37 | ## spacing def |
|
37 | 38 | <tr> |
General Comments 0
You need to be logged in to leave comments.
Login now