##// END OF EJS Templates
fixed settings clearfix overwritter css
Liviu -
r3644:779d6290 new-ui
parent child Browse files
Show More
@@ -1,412 +1,408 b''
1 // summary.less
1 // summary.less
2 // For use in RhodeCode applications;
2 // For use in RhodeCode applications;
3 // Used for headers and file detail summary screens.
3 // Used for headers and file detail summary screens.
4
4
5 .summary {
5 .summary {
6 clear: both;
6 clear: both;
7 float: none;
7 float: none;
8 position: relative;
8 position: relative;
9 width: 100%;
9 width: 100%;
10 margin: 0;
10 margin: 0;
11 padding: 0;
11 padding: 0;
12 background: #FCFCFC;
12 background: #FCFCFC;
13 border: 1px solid #EAEAEA;
13 border: 1px solid #EAEAEA;
14 border-radius: @border-radius;
14 border-radius: @border-radius;
15 margin-bottom: 20px;
15 margin-bottom: 20px;
16
16
17 .summary-detail-header {
17 .summary-detail-header {
18 float: left;
18 float: left;
19 display: block;
19 display: block;
20 width: 100%;
20 width: 100%;
21 margin-bottom: @textmargin;
21 margin-bottom: @textmargin;
22 padding: 0 0 .5em 0;
22 padding: 0 0 .5em 0;
23 border-bottom: @border-thickness solid @border-default-color;
23 border-bottom: @border-thickness solid @border-default-color;
24
24
25 .breadcrumbs {
25 .breadcrumbs {
26 float: left;
26 float: left;
27 display: inline;
27 display: inline;
28 margin: 0;
28 margin: 0;
29 padding: 0;
29 padding: 0;
30 }
30 }
31 h4 {
31 h4 {
32 float: left;
32 float: left;
33 margin: 0 1em 0 0;
33 margin: 0 1em 0 0;
34 padding: 0;
34 padding: 0;
35 line-height: 1.2em;
35 line-height: 1.2em;
36 font-size: @basefontsize;
36 font-size: @basefontsize;
37 }
37 }
38
38
39 .action_link {
39 .action_link {
40 float: right;
40 float: right;
41 }
41 }
42
42
43 .new-file {
43 .new-file {
44 float: right;
44 float: right;
45 margin-top: -1.5em;
45 margin-top: -1.5em;
46 }
46 }
47 }
47 }
48
48
49 .summary-detail {
49 .summary-detail {
50 float: none;
50 float: none;
51 position: relative;
51 position: relative;
52 width: 100%;
52 width: 100%;
53 margin: 0;
53 margin: 0;
54 padding: 0;
54 padding: 0;
55
55
56 .file_diff_buttons {
56 .file_diff_buttons {
57 margin-top: @space;
57 margin-top: @space;
58 }
58 }
59
59
60 // commit message
60 // commit message
61 .commit {
61 .commit {
62 white-space: pre-wrap;
62 white-space: pre-wrap;
63 }
63 }
64
64
65 .left-clone {
65 .left-clone {
66 float: left;
66 float: left;
67 height: 30px;
67 height: 30px;
68 margin: 0;
68 margin: 0;
69 padding: 0;
69 padding: 0;
70 width: 130px;
70 width: 130px;
71 font-weight: @text-semibold-weight;
71 font-weight: @text-semibold-weight;
72 font-family: @text-semibold;
72 font-family: @text-semibold;
73 }
73 }
74 .left-clone select {
74 .left-clone select {
75 width: 130px;
75 width: 130px;
76 margin-right: 0;
76 margin-right: 0;
77 background-color: @grey7;
77 background-color: @grey7;
78 border-color: @grey4;
78 border-color: @grey4;
79 color: #5C5C5C;
79 color: #5C5C5C;
80 border-top-right-radius: 0;
80 border-top-right-radius: 0;
81 border-bottom-right-radius: 0;
81 border-bottom-right-radius: 0;
82 }
82 }
83
83
84 .right-clone {
84 .right-clone {
85 float: left;
85 float: left;
86 width: ~"calc(100% - 170px)";
86 width: ~"calc(100% - 170px)";
87
87
88 .clipboard-action {
88 .clipboard-action {
89 margin-left: -30px;
89 margin-left: -30px;
90 }
90 }
91 }
91 }
92
92
93 .clone_url_input {
93 .clone_url_input {
94 width: ~"calc(100% - 90px)";
94 width: ~"calc(100% - 90px)";
95 padding: 6px 30px 6px 10px;
95 padding: 6px 30px 6px 10px;
96 height: 14px;
96 height: 14px;
97 box-shadow: 0 1px 1px 0 rgba(0,0,0,0.07);
97 box-shadow: 0 1px 1px 0 rgba(0,0,0,0.07);
98 border-top-left-radius: 0;
98 border-top-left-radius: 0;
99 border-bottom-left-radius: 0;
99 border-bottom-left-radius: 0;
100 margin-left: -1px;
100 margin-left: -1px;
101 }
101 }
102
102
103 &.directory {
103 &.directory {
104 margin-bottom: 0;
104 margin-bottom: 0;
105 }
105 }
106
106
107 .desc {
107 .desc {
108 white-space: pre-wrap;
108 white-space: pre-wrap;
109 }
109 }
110 .disabled {
110 .disabled {
111 opacity: .5;
111 opacity: .5;
112 cursor: inherit;
112 cursor: inherit;
113 }
113 }
114 .help-block {
114 .help-block {
115 color: inherit;
115 color: inherit;
116 margin: 0;
116 margin: 0;
117 }
117 }
118 }
118 }
119
119
120 .sidebar-right {
120 .sidebar-right {
121 float: left;
121 float: left;
122 width: 24%;
122 width: 24%;
123 margin: 0;
123 margin: 0;
124 padding: 0;
124 padding: 0;
125
125
126 ul {
126 ul {
127 margin-left: 0;
127 margin-left: 0;
128 padding-left: 0;
128 padding-left: 0;
129
129
130 li {
130 li {
131 list-style-type: none;
131 list-style-type: none;
132 }
132 }
133 }
133 }
134 }
134 }
135
135
136 #clone_by_name, #clone_by_id{
136 #clone_by_name, #clone_by_id{
137 display: inline-block;
137 display: inline-block;
138 margin-left: 0px;
138 margin-left: 0px;
139 }
139 }
140
140
141 .codeblock {
141 .codeblock {
142 border: none;
142 border: none;
143 background-color: transparent;
143 background-color: transparent;
144 }
144 }
145
145
146 .code-body {
146 .code-body {
147 border: @border-thickness solid @border-default-color;
147 border: @border-thickness solid @border-default-color;
148 .border-radius(@border-radius);
148 .border-radius(@border-radius);
149 }
149 }
150
150
151 .btn-collapse {
151 .btn-collapse {
152 clear: both;
152 clear: both;
153 float: none;
153 float: none;
154 background: #F7F7F7;
154 background: #F7F7F7;
155 text-align: center;
155 text-align: center;
156 color: #949494;
156 color: #949494;
157 font-size: 11px;
157 font-size: 11px;
158
158
159 &:hover {
159 &:hover {
160 background: #f1f1f1;
160 background: #f1f1f1;
161 color: #2B2B2D;
161 color: #2B2B2D;
162 }
162 }
163 }
163 }
164 }
164 }
165
165
166 // this is used outside of just the summary
166 // this is used outside of just the summary
167 .fieldset, // similar to form fieldset
167 .fieldset, // similar to form fieldset
168 .summary .sidebar-right-content { // these have to match
168 .summary .sidebar-right-content { // these have to match
169 clear: both;
169 clear: both;
170 float: none;
170 float: none;
171 position: relative;
171 position: relative;
172 display:block;
172 display:block;
173 width: 100%;
173 width: 100%;
174 min-height: 1em;
174 min-height: 1em;
175 margin-bottom: 10px;
175 margin-bottom: 10px;
176 padding: 0;
176 padding: 0;
177 line-height: 1.2em;
177 line-height: 1.2em;
178
178
179 &:after { // clearfix
179 &:after { // clearfix
180 content: "";
180 content: "";
181 clear: both;
181 clear: both;
182 width: 100%;
182 width: 100%;
183 height: 1em;
183 height: 1em;
184 }
184 }
185 }
185 }
186
186
187 .summary .sidebar-right-content {
187 .summary .sidebar-right-content {
188 margin-bottom: @space;
188 margin-bottom: @space;
189
189
190 .rc-user {
190 .rc-user {
191 min-width: 0;
191 min-width: 0;
192 }
192 }
193 }
193 }
194
194
195 .fieldset {
195 .fieldset {
196
196
197 .left-label { // similar to form legend
197 .left-label { // similar to form legend
198 display: block;
198 display: block;
199 margin: 0;
199 margin: 0;
200 padding: 0;
200 padding: 0;
201 font-weight: @text-semibold-weight;
201 font-weight: @text-semibold-weight;
202 font-family: @text-semibold;
202 font-family: @text-semibold;
203 }
203 }
204
204
205 .left-label-summary {
205 .left-label-summary {
206 padding-left: 20px;
206 padding-left: 20px;
207 margin-bottom: 5px;
207 margin-bottom: 5px;
208
208
209 p {
209 p {
210 margin-bottom: 5px;
210 margin-bottom: 5px;
211 color: @grey1;
211 color: @grey1;
212 float: left;
212 float: left;
213 width: 130px;
213 width: 130px;
214 }
214 }
215
215
216 .right-label-summary {
216 .right-label-summary {
217 float: left;
217 float: left;
218 margin-top: 7px;
218 margin-top: 7px;
219 }
219 }
220 }
220 }
221
221
222 .left-content {
222 .left-content {
223 width: ~"calc(50% - 20px)";
223 width: ~"calc(50% - 20px)";
224 float: left;
224 float: left;
225 margin: 15px 0 15px 20px;
225 margin: 15px 0 15px 20px;
226 }
226 }
227
227
228 .right-content { // similar to form fields
228 .right-content { // similar to form fields
229 float: left;
229 float: left;
230 display: block;
230 display: block;
231 width: ~"calc(50% - 20px)";
231 width: ~"calc(50% - 20px)";
232 text-align: right;
232 text-align: right;
233 margin: 15px 20px 15px 0;
233 margin: 15px 20px 15px 0;
234
234
235 .truncate-wrap,
235 .truncate-wrap,
236 .truncate {
236 .truncate {
237 max-width: 100%;
237 max-width: 100%;
238 width: 100%;
238 width: 100%;
239 }
239 }
240
240
241 .commit-long {
241 .commit-long {
242 overflow-x: auto;
242 overflow-x: auto;
243 }
243 }
244
244
245 .commit-info {
245 .commit-info {
246 margin-top: 7px;
246 margin-top: 7px;
247 }
247 }
248
248
249 .tag, .tagtag, .branchtag, .booktag, .metatag, .perm_tag {
249 .tag, .tagtag, .branchtag, .booktag, .metatag, .perm_tag {
250 background:transparent;
250 background:transparent;
251 border: none;
251 border: none;
252 box-shadow: none;
252 box-shadow: none;
253 margin-left: 10px;
253 margin-left: 10px;
254 font-size: 13px;
254 font-size: 13px;
255 }
255 }
256
256
257 .tag span, .tag i {
257 .tag span, .tag i {
258 color: @grey1;
258 color: @grey1;
259 }
259 }
260 }
260 }
261 .commit.truncate-wrap {
261 .commit.truncate-wrap {
262 overflow:hidden;
262 overflow:hidden;
263 text-overflow: ellipsis;
263 text-overflow: ellipsis;
264 }
264 }
265 }
265 }
266
266
267 // expand commit message
267 // expand commit message
268 #message_expand {
268 #message_expand {
269 clear: both;
269 clear: both;
270 display: block;
270 display: block;
271 color: @rcblue;
271 color: @rcblue;
272 cursor: pointer;
272 cursor: pointer;
273 }
273 }
274
274
275 #trimmed_message_box {
275 #trimmed_message_box {
276 max-height: floor(2 * @basefontsize * 1.2); // 2 lines * line-height
276 max-height: floor(2 * @basefontsize * 1.2); // 2 lines * line-height
277 overflow: hidden;
277 overflow: hidden;
278 }
278 }
279
279
280 // show/hide comments button
280 // show/hide comments button
281 .show-inline-comments {
281 .show-inline-comments {
282 display: inline;
282 display: inline;
283 cursor: pointer;
283 cursor: pointer;
284
284
285 .comments-show { display: inline; }
285 .comments-show { display: inline; }
286 .comments-hide { display: none; }
286 .comments-hide { display: none; }
287
287
288 &.comments-visible {
288 &.comments-visible {
289 .comments-show { display: none; }
289 .comments-show { display: none; }
290 .comments-hide { display: inline; }
290 .comments-hide { display: inline; }
291 }
291 }
292 }
292 }
293
293
294 // Quick Start section
294 // Quick Start section
295
295
296 .empty-repo {
296 .empty-repo {
297 border: 1px solid #EAEAEA;
297 border: 1px solid #EAEAEA;
298 border-bottom: 0;
298 border-bottom: 0;
299 border-radius: @border-radius;
299 border-radius: @border-radius;
300 padding: 0 20px;
300 padding: 0 20px;
301 }
301 }
302
302
303 .empty-repo h3, .quick_start p {
303 .empty-repo h3, .quick_start p {
304 margin-bottom: 10px;
304 margin-bottom: 10px;
305 }
305 }
306
306
307 .quick_start pre {
307 .quick_start pre {
308 background: #FCFEFF;
308 background: #FCFEFF;
309 border: 1px solid #CBDBEB;
309 border: 1px solid #CBDBEB;
310 box-shadow: @button-shadow;
310 box-shadow: @button-shadow;
311 padding: 10px 15px;
311 padding: 10px 15px;
312 border-radius: 4px;
312 border-radius: 4px;
313 color: @grey2;
313 color: @grey2;
314 }
314 }
315
315
316 .clearfix {
316 .clear-fix {
317 clear: both;
317 clear: both;
318 }
318 }
319
319
320 .quick_start {
320 .quick_start {
321 display: block;
321 display: block;
322 position: relative;
322 position: relative;
323 border: 1px solid #EAEAEA;
323 border: 1px solid #EAEAEA;
324 border-top: 0;
324 border-top: 0;
325 border-radius: @border-radius;
325 border-radius: @border-radius;
326 padding: 0 20px;
326 padding: 0 20px;
327
327
328 // adds some space to make copy and paste easier
328 // adds some space to make copy and paste easier
329 .left-label,
329 .left-label,
330 .right-content {
330 .right-content {
331 line-height: 1.6em;
331 line-height: 1.6em;
332 }
332 }
333 }
333 }
334
334
335
335
336 .submodule {
336 .submodule {
337 .summary-detail {
337 .summary-detail {
338 width: 100%;
338 width: 100%;
339
339
340 .btn-collapse {
340 .btn-collapse {
341 display: none;
341 display: none;
342 }
342 }
343 }
343 }
344 }
344 }
345
345
346 .codeblock-header {
346 .codeblock-header {
347 float: left;
347 float: left;
348 display: block;
348 display: block;
349 width: 100%;
349 width: 100%;
350 margin: 0;
350 margin: 0;
351 padding: @space 0 10px 0;
351 padding: @space 0 10px 0;
352 border-top: @border-thickness solid @border-default-color;
352 border-top: @border-thickness solid @border-default-color;
353
353
354 .stats {
354 .stats {
355 float: left;
355 float: left;
356 }
356 }
357 .stats-filename {
357 .stats-filename {
358 font-size: 120%;
358 font-size: 120%;
359 }
359 }
360 .stats-first-item {
360 .stats-first-item {
361 padding: 0px 0px 0px 3px;
361 padding: 0px 0px 0px 3px;
362 }
362 }
363
363
364 .buttons {
364 .buttons {
365 float: right;
365 float: right;
366 text-align: right;
366 text-align: right;
367 color: @grey4;
367 color: @grey4;
368 }
368 }
369
369
370 .file-container {
370 .file-container {
371 display: inline-block;
371 display: inline-block;
372 width: 100%;
372 width: 100%;
373 }
373 }
374
374
375 }
375 }
376
376
377 #summary-menu-stats {
377 #summary-menu-stats {
378
378
379 .stats-bullet {
379 .stats-bullet {
380 color: @grey3;
380 color: @grey3;
381 min-width: 3em;
381 min-width: 3em;
382 }
382 }
383
383
384 .repo-size {
384 .repo-size {
385 margin-bottom: .5em;
385 margin-bottom: .5em;
386 }
386 }
387
387
388 }
388 }
389
389
390 .rctable.repo_summary {
390 .rctable.repo_summary {
391 border: 1px solid #eaeaea;
391 border: 1px solid #eaeaea;
392 border-radius: 2px;
392 border-radius: 2px;
393 border-collapse: inherit;
393 border-collapse: inherit;
394 border-bottom: 0;
394 border-bottom: 0;
395
395
396 th {
396 th {
397 background: @grey7;
397 background: @grey7;
398 border-bottom: 0;
398 border-bottom: 0;
399 }
399 }
400
400
401 td {
401 td {
402 border-color: #eaeaea;
402 border-color: #eaeaea;
403 }
403 }
404
404
405 td.td-status {
405 td.td-status {
406 padding: 0 0 0 10px;
406 padding: 0 0 0 10px;
407 }
407 }
408 }
408 }
409
410
411
412
@@ -1,114 +1,114 b''
1 <%inherit file="/summary/summary_base.mako"/>
1 <%inherit file="/summary/summary_base.mako"/>
2
2
3 <%namespace name="components" file="/summary/components.mako"/>
3 <%namespace name="components" file="/summary/components.mako"/>
4
4
5
5
6 <%def name="menu_bar_subnav()">
6 <%def name="menu_bar_subnav()">
7 ${self.repo_menu(active='summary')}
7 ${self.repo_menu(active='summary')}
8 </%def>
8 </%def>
9
9
10 <%def name="main()">
10 <%def name="main()">
11
11
12 <div id="repo-summary" class="summary">
12 <div id="repo-summary" class="summary">
13 ${components.summary_detail(breadcrumbs_links=self.breadcrumbs_links(), show_downloads=True)}
13 ${components.summary_detail(breadcrumbs_links=self.breadcrumbs_links(), show_downloads=True)}
14 </div><!--end repo-summary-->
14 </div><!--end repo-summary-->
15
15
16
16
17 <div class="box">
17 <div class="box">
18 %if not c.repo_commits:
18 %if not c.repo_commits:
19 <div class="empty-repo">
19 <div class="empty-repo">
20 <div class="title">
20 <div class="title">
21 <h3>${_('Quick start')}</h3>
21 <h3>${_('Quick start')}</h3>
22 </div>
22 </div>
23 <div class="clearfix"></div>
23 <div class="clear-fix"></div>
24 </div>
24 </div>
25 %endif
25 %endif
26 <div class="table">
26 <div class="table">
27 <div id="shortlog_data">
27 <div id="shortlog_data">
28 <%include file='summary_commits.mako'/>
28 <%include file='summary_commits.mako'/>
29 </div>
29 </div>
30 </div>
30 </div>
31 </div>
31 </div>
32
32
33 %if c.readme_data:
33 %if c.readme_data:
34 <div id="readme" class="anchor">
34 <div id="readme" class="anchor">
35 <div class="box">
35 <div class="box">
36 <div class="title" title="${h.tooltip(_('Readme file from commit %s:%s') % (c.rhodecode_db_repo.landing_rev[0], c.rhodecode_db_repo.landing_rev[1]))}">
36 <div class="title" title="${h.tooltip(_('Readme file from commit %s:%s') % (c.rhodecode_db_repo.landing_rev[0], c.rhodecode_db_repo.landing_rev[1]))}">
37 <h3 class="breadcrumbs">
37 <h3 class="breadcrumbs">
38 <a href="${h.route_path('repo_files',repo_name=c.repo_name,commit_id=c.rhodecode_db_repo.landing_rev[1],f_path=c.readme_file)}">${c.readme_file}</a>
38 <a href="${h.route_path('repo_files',repo_name=c.repo_name,commit_id=c.rhodecode_db_repo.landing_rev[1],f_path=c.readme_file)}">${c.readme_file}</a>
39 </h3>
39 </h3>
40 </div>
40 </div>
41 <div class="readme codeblock">
41 <div class="readme codeblock">
42 <div class="readme_box">
42 <div class="readme_box">
43 ${c.readme_data|n}
43 ${c.readme_data|n}
44 </div>
44 </div>
45 </div>
45 </div>
46 </div>
46 </div>
47 </div>
47 </div>
48 %endif
48 %endif
49
49
50 <script type="text/javascript">
50 <script type="text/javascript">
51 $(document).ready(function(){
51 $(document).ready(function(){
52
52
53 var showCloneField = function(clone_url_format){
53 var showCloneField = function(clone_url_format){
54 $.each(['http', 'http_id', 'ssh'], function (idx, val) {
54 $.each(['http', 'http_id', 'ssh'], function (idx, val) {
55 if(val === clone_url_format){
55 if(val === clone_url_format){
56 $('#clone_option_' + val).show();
56 $('#clone_option_' + val).show();
57 $('#clone_option').val(val)
57 $('#clone_option').val(val)
58 } else {
58 } else {
59 $('#clone_option_' + val).hide();
59 $('#clone_option_' + val).hide();
60 }
60 }
61 });
61 });
62 };
62 };
63 // default taken from session
63 // default taken from session
64 showCloneField(templateContext.session_attrs.clone_url_format);
64 showCloneField(templateContext.session_attrs.clone_url_format);
65
65
66 $('#clone_option').on('change', function(e) {
66 $('#clone_option').on('change', function(e) {
67 var selected = $(this).val();
67 var selected = $(this).val();
68
68
69 storeUserSessionAttr('rc_user_session_attr.clone_url_format', selected);
69 storeUserSessionAttr('rc_user_session_attr.clone_url_format', selected);
70 showCloneField(selected)
70 showCloneField(selected)
71 });
71 });
72
72
73 var initialCommitData = {
73 var initialCommitData = {
74 id: null,
74 id: null,
75 text: 'tip',
75 text: 'tip',
76 type: 'tag',
76 type: 'tag',
77 raw_id: null,
77 raw_id: null,
78 files_url: null
78 files_url: null
79 };
79 };
80
80
81 select2RefSwitcher('#download_options', initialCommitData);
81 select2RefSwitcher('#download_options', initialCommitData);
82
82
83 // on change of download options
83 // on change of download options
84 $('#download_options').on('change', function(e) {
84 $('#download_options').on('change', function(e) {
85 // format of Object {text: "v0.0.3", type: "tag", id: "rev"}
85 // format of Object {text: "v0.0.3", type: "tag", id: "rev"}
86 var ext = '.zip';
86 var ext = '.zip';
87 var selected_cs = e.added;
87 var selected_cs = e.added;
88 var fname = e.added.raw_id + ext;
88 var fname = e.added.raw_id + ext;
89 var href = pyroutes.url('repo_archivefile', {'repo_name': templateContext.repo_name, 'fname':fname});
89 var href = pyroutes.url('repo_archivefile', {'repo_name': templateContext.repo_name, 'fname':fname});
90 // set new label
90 // set new label
91 $('#archive_link').html('<i class="icon-archive"></i> {0}{1}'.format(escapeHtml(e.added.text), ext));
91 $('#archive_link').html('<i class="icon-archive"></i> {0}{1}'.format(escapeHtml(e.added.text), ext));
92
92
93 // set new url to button,
93 // set new url to button,
94 $('#archive_link').attr('href', href)
94 $('#archive_link').attr('href', href)
95 });
95 });
96
96
97
97
98 // calculate size of repository
98 // calculate size of repository
99 calculateSize = function () {
99 calculateSize = function () {
100
100
101 var callback = function (data) {
101 var callback = function (data) {
102 % if c.show_stats:
102 % if c.show_stats:
103 showRepoStats('lang_stats', data);
103 showRepoStats('lang_stats', data);
104 % endif
104 % endif
105 };
105 };
106
106
107 showRepoSize('repo_size_container', templateContext.repo_name, templateContext.repo_landing_commit, callback);
107 showRepoSize('repo_size_container', templateContext.repo_name, templateContext.repo_landing_commit, callback);
108
108
109 }
109 }
110
110
111 })
111 })
112 </script>
112 </script>
113
113
114 </%def>
114 </%def>
General Comments 0
You need to be logged in to leave comments. Login now