Show More
@@ -28,7 +28,7 b'' | |||
|
28 | 28 | "moment": "^2.18.1", |
|
29 | 29 | "mousetrap": "^1.6.1", |
|
30 | 30 | "qrious": "^4.0.2", |
|
31 |
"sticky-sidebar": "3.3. |
|
|
31 | "sticky-sidebar": "3.3.4", | |
|
32 | 32 | "waypoints": "4.0.1", |
|
33 | 33 | "webpack": "4.23.1", |
|
34 | 34 | "webpack-cli": "3.1.2", |
@@ -128,6 +128,7 b' class RepoCommitsView(RepoAppView):' | |||
|
128 | 128 | c.statuses = [] |
|
129 | 129 | c.comments = [] |
|
130 | 130 | c.unresolved_comments = [] |
|
131 | c.resolved_comments = [] | |
|
131 | 132 | if len(c.commit_ranges) == 1: |
|
132 | 133 | commit = c.commit_ranges[0] |
|
133 | 134 | c.comments = CommentsModel().get_comments( |
@@ -148,6 +149,8 b' class RepoCommitsView(RepoAppView):' | |||
|
148 | 149 | |
|
149 | 150 | c.unresolved_comments = CommentsModel()\ |
|
150 | 151 | .get_commit_unresolved_todos(commit.raw_id) |
|
152 | c.resolved_comments = CommentsModel()\ | |
|
153 | .get_commit_resolved_todos(commit.raw_id) | |
|
151 | 154 | |
|
152 | 155 | diff = None |
|
153 | 156 | # Iterate over ranges (default commit view is always one commit) |
@@ -187,6 +187,23 b' class CommentsModel(BaseModel):' | |||
|
187 | 187 | |
|
188 | 188 | return todos |
|
189 | 189 | |
|
190 | def get_commit_resolved_todos(self, commit_id, show_outdated=True): | |
|
191 | ||
|
192 | todos = Session().query(ChangesetComment) \ | |
|
193 | .filter(ChangesetComment.revision == commit_id) \ | |
|
194 | .filter(ChangesetComment.resolved_by != None) \ | |
|
195 | .filter(ChangesetComment.comment_type | |
|
196 | == ChangesetComment.COMMENT_TYPE_TODO) | |
|
197 | ||
|
198 | if not show_outdated: | |
|
199 | todos = todos.filter( | |
|
200 | coalesce(ChangesetComment.display_state, '') != | |
|
201 | ChangesetComment.COMMENT_OUTDATED) | |
|
202 | ||
|
203 | todos = todos.all() | |
|
204 | ||
|
205 | return todos | |
|
206 | ||
|
190 | 207 | def _log_audit_action(self, action, action_data, auth_user, comment): |
|
191 | 208 | audit_logger.store( |
|
192 | 209 | action=action, |
@@ -71,6 +71,12 b' input[type="button"] {' | |||
|
71 | 71 | margin: 0 0 0 0; |
|
72 | 72 | } |
|
73 | 73 | |
|
74 | &.btn-active { | |
|
75 | color: @rcdarkblue; | |
|
76 | background-color: @white; | |
|
77 | .border ( @border-thickness, @rcdarkblue ); | |
|
78 | } | |
|
79 | ||
|
74 | 80 | } |
|
75 | 81 | |
|
76 | 82 | |
@@ -97,6 +103,11 b' input[type="button"] {' | |||
|
97 | 103 | .border ( @border-thickness-buttons, @grey5 ); |
|
98 | 104 | background-color: transparent; |
|
99 | 105 | } |
|
106 | &.btn-active { | |
|
107 | color: @rcdarkblue; | |
|
108 | background-color: @white; | |
|
109 | .border ( @border-thickness, @rcdarkblue ); | |
|
110 | } | |
|
100 | 111 | } |
|
101 | 112 | |
|
102 | 113 | .btn-primary, |
@@ -214,8 +225,28 b' input[type="button"] {' | |||
|
214 | 225 | display: inline-block; |
|
215 | 226 | .btn { |
|
216 | 227 | float: left; |
|
217 |
margin: 0 0 0 |
|
|
228 | margin: 0 0 0 0; | |
|
229 | // first item | |
|
230 | &:first-of-type:not(:last-of-type) { | |
|
231 | border-radius: @border-radius 0 0 @border-radius; | |
|
232 | ||
|
218 | 233 | } |
|
234 | // middle elements | |
|
235 | &:not(:first-of-type):not(:last-of-type) { | |
|
236 | border-radius: 0; | |
|
237 | border-left-width: 0; | |
|
238 | border-right-width: 0; | |
|
239 | } | |
|
240 | // last item | |
|
241 | &:last-of-type:not(:first-of-type) { | |
|
242 | border-radius: 0 @border-radius @border-radius 0; | |
|
243 | } | |
|
244 | ||
|
245 | &:only-child { | |
|
246 | border-radius: @border-radius; | |
|
247 | } | |
|
248 | } | |
|
249 | ||
|
219 | 250 | } |
|
220 | 251 | |
|
221 | 252 | .btn-link { |
@@ -682,13 +682,14 b' input.filediff-collapse-state {' | |||
|
682 | 682 | display: none |
|
683 | 683 | } |
|
684 | 684 | .filediff-collapse-indicator { |
|
685 |
|
|
|
686 |
|
|
|
687 | border-style: solid; | |
|
688 | border-width: 4.5px 0 4.5px 9.3px; | |
|
689 | border-color: transparent transparent transparent #aaa; | |
|
690 | margin: 6px 0px; | |
|
685 | float: left; | |
|
686 | cursor: pointer; | |
|
687 | margin: 1px -5px; | |
|
691 | 688 | } |
|
689 | .filediff-collapse-indicator:before { | |
|
690 | content: '\f105'; | |
|
691 | } | |
|
692 | ||
|
692 | 693 | .filediff-menu { |
|
693 | 694 | display: none; |
|
694 | 695 | } |
@@ -696,18 +697,20 b' input.filediff-collapse-state {' | |||
|
696 | 697 | } |
|
697 | 698 | |
|
698 | 699 | &+ .filediff { /* file diff is expanded */ |
|
700 | ||
|
699 | 701 | .filediff-collapse-indicator { |
|
700 |
|
|
|
701 |
|
|
|
702 | border-style: solid; | |
|
703 | border-width: 9.3px 4.5px 0 4.5px; | |
|
704 | border-color: #aaa transparent transparent transparent; | |
|
705 | margin: 6px 0px; | |
|
702 | float: left; | |
|
703 | cursor: pointer; | |
|
704 | margin: 1px -5px; | |
|
705 | } | |
|
706 | .filediff-collapse-indicator:before { | |
|
707 | content: '\f107'; | |
|
708 | } | |
|
706 | 709 | |
|
707 | } | |
|
708 | 710 | .filediff-menu { |
|
709 | 711 | display: block; |
|
710 | 712 | } |
|
713 | ||
|
711 | 714 | margin: 10px 0; |
|
712 | 715 | &:nth-child(2) { |
|
713 | 716 | margin: 0; |
@@ -735,13 +738,14 b' input.filediff-collapse-state {' | |||
|
735 | 738 | |
|
736 | 739 | #diff-file-sticky{ |
|
737 | 740 | will-change: min-height; |
|
741 | height: 80px; | |
|
738 | 742 | } |
|
739 | 743 | |
|
740 | 744 | .sidebar__inner{ |
|
741 | 745 | transform: translate(0, 0); /* For browsers don't support translate3d. */ |
|
742 | 746 | transform: translate3d(0, 0, 0); |
|
743 | 747 | will-change: position, transform; |
|
744 |
height: |
|
|
748 | height: 65px; | |
|
745 | 749 | z-index: 30; |
|
746 | 750 | background-color: #fff; |
|
747 | 751 | padding: 5px 0px; |
@@ -775,10 +779,17 b' input.filediff-collapse-state {' | |||
|
775 | 779 | } |
|
776 | 780 | |
|
777 | 781 | .diffset-menu { |
|
778 | margin-bottom: 20px; | |
|
782 | ||
|
779 | 783 | } |
|
784 | ||
|
785 | #todo-box { | |
|
786 | clear:both; | |
|
787 | display: none; | |
|
788 | text-align: right | |
|
789 | } | |
|
790 | ||
|
780 | 791 | .diffset { |
|
781 |
margin: |
|
|
792 | margin: 0px auto; | |
|
782 | 793 | .diffset-heading { |
|
783 | 794 | border: 1px solid @grey5; |
|
784 | 795 | margin-bottom: -1px; |
@@ -826,6 +837,8 b' input.filediff-collapse-state {' | |||
|
826 | 837 | margin-right: 3px; |
|
827 | 838 | font-size: 12px; |
|
828 | 839 | font-weight: normal; |
|
840 | min-width: 30px; | |
|
841 | text-align: center; | |
|
829 | 842 | |
|
830 | 843 | &:first-child { |
|
831 | 844 | border-radius: @border-radius 0 0 @border-radius; |
@@ -877,18 +890,10 b' input.filediff-collapse-state {' | |||
|
877 | 890 | } |
|
878 | 891 | } |
|
879 | 892 | |
|
880 | .filediff-collapse-indicator { | |
|
881 | border-style: solid; | |
|
882 | float: left; | |
|
883 | margin: 4px 0px 0 0; | |
|
884 | cursor: pointer; | |
|
885 | } | |
|
886 | ||
|
887 | 893 | .filediff-heading { |
|
888 | background: @grey7; | |
|
889 | 894 | cursor: pointer; |
|
890 | 895 | display: block; |
|
891 |
padding: |
|
|
896 | padding: 10px 10px; | |
|
892 | 897 | } |
|
893 | 898 | .filediff-heading:after { |
|
894 | 899 | content: ""; |
@@ -900,9 +905,9 b' input.filediff-collapse-state {' | |||
|
900 | 905 | } |
|
901 | 906 | |
|
902 | 907 | .filediff-menu { |
|
903 | float: right; | |
|
904 | 908 | text-align: right; |
|
905 | 909 | padding: 5px 5px 5px 0px; |
|
910 | background: @grey7; | |
|
906 | 911 | |
|
907 | 912 | &> a, |
|
908 | 913 | &> span { |
@@ -958,8 +963,16 b' input.filediff-collapse-state {' | |||
|
958 | 963 | } |
|
959 | 964 | |
|
960 | 965 | |
|
966 | .op-added { | |
|
967 | color: @alert1; | |
|
968 | } | |
|
969 | ||
|
970 | .op-deleted { | |
|
971 | color: @alert2; | |
|
972 | } | |
|
961 | 973 | |
|
962 | 974 | .filediff, .filelist { |
|
975 | ||
|
963 | 976 | .pill { |
|
964 | 977 | &[op="name"] { |
|
965 | 978 | background: none; |
@@ -10,6 +10,14 b'' | |||
|
10 | 10 | width: 100%; |
|
11 | 11 | } |
|
12 | 12 | |
|
13 | .comments-heading { | |
|
14 | margin-bottom: -1px; | |
|
15 | background: @grey6; | |
|
16 | display: block; | |
|
17 | padding: 10px 0px; | |
|
18 | font-size: 18px | |
|
19 | } | |
|
20 | ||
|
13 | 21 | tr.inline-comments div { |
|
14 | 22 | max-width: 100%; |
|
15 | 23 |
@@ -1107,6 +1107,52 b' label {' | |||
|
1107 | 1107 | } |
|
1108 | 1108 | } |
|
1109 | 1109 | |
|
1110 | .review-status { | |
|
1111 | &.under_review { | |
|
1112 | color: @alert3; | |
|
1113 | } | |
|
1114 | &.approved { | |
|
1115 | color: @alert1; | |
|
1116 | } | |
|
1117 | &.rejected, | |
|
1118 | &.forced_closed{ | |
|
1119 | color: @alert2; | |
|
1120 | } | |
|
1121 | &.not_reviewed { | |
|
1122 | color: @grey5; | |
|
1123 | } | |
|
1124 | } | |
|
1125 | ||
|
1126 | .review-status-under_review { | |
|
1127 | color: @alert3; | |
|
1128 | } | |
|
1129 | .status-tag-under_review { | |
|
1130 | border-color: @alert3; | |
|
1131 | } | |
|
1132 | ||
|
1133 | .review-status-approved { | |
|
1134 | color: @alert1; | |
|
1135 | } | |
|
1136 | .status-tag-approved { | |
|
1137 | border-color: @alert1; | |
|
1138 | } | |
|
1139 | ||
|
1140 | .review-status-rejected, | |
|
1141 | .review-status-forced_closed { | |
|
1142 | color: @alert2; | |
|
1143 | } | |
|
1144 | .status-tag-rejected, | |
|
1145 | .status-tag-forced_closed { | |
|
1146 | border-color: @alert2; | |
|
1147 | } | |
|
1148 | ||
|
1149 | .review-status-not_reviewed { | |
|
1150 | color: @grey5; | |
|
1151 | } | |
|
1152 | .status-tag-not_reviewed { | |
|
1153 | border-color: @grey5; | |
|
1154 | } | |
|
1155 | ||
|
1110 | 1156 | .flag_status_comment_box { |
|
1111 | 1157 | margin: 5px 6px 0px 2px; |
|
1112 | 1158 | } |
@@ -1,12 +1,12 b'' | |||
|
1 | 1 | @font-face { |
|
2 | 2 | font-family: 'rcicons'; |
|
3 | 3 | |
|
4 |
src: url('../fonts/RCIcons/rcicons.eot? |
|
|
5 |
src: url('../fonts/RCIcons/rcicons.eot? |
|
|
6 |
url('../fonts/RCIcons/rcicons.woff2? |
|
|
7 |
url('../fonts/RCIcons/rcicons.woff? |
|
|
8 |
url('../fonts/RCIcons/rcicons.ttf? |
|
|
9 |
url('../fonts/RCIcons/rcicons.svg? |
|
|
4 | src: url('../fonts/RCIcons/rcicons.eot?44705679'); | |
|
5 | src: url('../fonts/RCIcons/rcicons.eot?44705679#iefix') format('embedded-opentype'), | |
|
6 | url('../fonts/RCIcons/rcicons.woff2?44705679') format('woff2'), | |
|
7 | url('../fonts/RCIcons/rcicons.woff?44705679') format('woff'), | |
|
8 | url('../fonts/RCIcons/rcicons.ttf?44705679') format('truetype'), | |
|
9 | url('../fonts/RCIcons/rcicons.svg?44705679#rcicons') format('svg'); | |
|
10 | 10 | |
|
11 | 11 | font-weight: normal; |
|
12 | 12 | font-style: normal; |
@@ -163,8 +163,6 b'' | |||
|
163 | 163 | .icon-down:before { content: '\e80b'; } /* '' */ |
|
164 | 164 | .icon-folder:before { content: '\e80c'; } /* '' */ |
|
165 | 165 | .icon-folder-open:before { content: '\e80d'; } /* '' */ |
|
166 | .icon-folder-empty:before { content: '\f114'; } /* '' */ | |
|
167 | .icon-folder-open-empty:before { content: '\f115'; } /* '' */ | |
|
168 | 166 | .icon-trash-empty:before { content: '\e80e'; } /* '' */ |
|
169 | 167 | .icon-group:before { content: '\e80f'; } /* '' */ |
|
170 | 168 | .icon-remove:before { content: '\e810'; } /* '' */ |
@@ -187,6 +185,7 b'' | |||
|
187 | 185 | .icon-info-circled:before { content: '\e821'; } /* '' */ |
|
188 | 186 | .icon-upload:before { content: '\e822'; } /* '' */ |
|
189 | 187 | .icon-home:before { content: '\e823'; } /* '' */ |
|
188 | .icon-flag-filled:before { content: '\e824'; } /* '' */ | |
|
190 | 189 | .icon-git:before { content: '\e82a'; } /* '' */ |
|
191 | 190 | .icon-hg:before { content: '\e82d'; } /* '' */ |
|
192 | 191 | .icon-svn:before { content: '\e82e'; } /* '' */ |
@@ -195,11 +194,24 b'' | |||
|
195 | 194 | .icon-rhodecode:before { content: '\e831'; } /* '' */ |
|
196 | 195 | .icon-up:before { content: '\e832'; } /* '' */ |
|
197 | 196 | .icon-merge:before { content: '\e833'; } /* '' */ |
|
197 | .icon-spin-alt:before { content: '\e834'; } /* '' */ | |
|
198 | .icon-spin:before { content: '\e838'; } /* '' */ | |
|
198 | 199 | .icon-docs:before { content: '\f0c5'; } /* '' */ |
|
199 | 200 | .icon-menu:before { content: '\f0c9'; } /* '' */ |
|
201 | .icon-sort:before { content: '\f0dc'; } /* '' */ | |
|
200 | 202 | .icon-paste:before { content: '\f0ea'; } /* '' */ |
|
201 | 203 | .icon-doc-text:before { content: '\f0f6'; } /* '' */ |
|
202 | 204 | .icon-plus-squared:before { content: '\f0fe'; } /* '' */ |
|
205 | .icon-angle-left:before { content: '\f104'; } /* '' */ | |
|
206 | .icon-angle-right:before { content: '\f105'; } /* '' */ | |
|
207 | .icon-angle-up:before { content: '\f106'; } /* '' */ | |
|
208 | .icon-angle-down:before { content: '\f107'; } /* '' */ | |
|
209 | .icon-circle-empty:before { content: '\f10c'; } /* '' */ | |
|
210 | .icon-circle:before { content: '\f111'; } /* '' */ | |
|
211 | .icon-folder-empty:before { content: '\f114'; } /* '' */ | |
|
212 | .icon-folder-open-empty:before { content: '\f115'; } /* '' */ | |
|
213 | .icon-code:before { content: '\f121'; } /* '' */ | |
|
214 | .icon-info:before { content: '\f129'; } /* '' */ | |
|
203 | 215 | .icon-minus-squared:before { content: '\f146'; } /* '' */ |
|
204 | 216 | .icon-minus-squared-alt:before { content: '\f147'; } /* '' */ |
|
205 | 217 | .icon-doc-inv:before { content: '\f15b'; } /* '' */ |
@@ -207,10 +219,9 b'' | |||
|
207 | 219 | .icon-plus-squared-alt:before { content: '\f196'; } /* '' */ |
|
208 | 220 | .icon-file-code:before { content: '\f1c9'; } /* '' */ |
|
209 | 221 | .icon-history:before { content: '\f1da'; } /* '' */ |
|
222 | .icon-circle-thin:before { content: '\f1db'; } /* '' */ | |
|
210 | 223 | .icon-sliders:before { content: '\f1de'; } /* '' */ |
|
211 | 224 | .icon-trash:before { content: '\f1f8'; } /* '' */ |
|
212 | .icon-spin-alt:before { content: '\e834'; } /* '' */ | |
|
213 | .icon-spin:before { content: '\e838'; } /* '' */ | |
|
214 | 225 | |
|
215 | 226 | |
|
216 | 227 | // MERGED ICONS BASED ON CURRENT ONES |
@@ -233,10 +244,12 b'' | |||
|
233 | 244 | .icon-false:before { &:extend(.icon-delete:before); } |
|
234 | 245 | .icon-expand-linked:before { &:extend(.icon-down:before); } |
|
235 | 246 | .icon-pr-merge-fail:before { &:extend(.icon-delete:before); } |
|
247 | .icon-wide-mode:before { &:extend(.icon-sort:before); } | |
|
248 | .icon-flag-filled-red:before { &:extend(.icon-flag-filled:before); } | |
|
236 | 249 | |
|
237 | 250 | // TRANSFORM |
|
238 | ||
|
239 | 251 | .icon-merge:before {transform: rotate(180deg);} |
|
252 | .icon-wide-mode:before {transform: rotate(90deg);} | |
|
240 | 253 | |
|
241 | 254 | // -- END ICON CLASSES -- // |
|
242 | 255 | |
@@ -254,6 +267,7 b'' | |||
|
254 | 267 | .icon-false { color: @grey5 } |
|
255 | 268 | .icon-expand-linked { cursor: pointer; color: @grey3; font-size: 14px } |
|
256 | 269 | .icon-more-linked { cursor: pointer; color: @grey3 } |
|
270 | .icon-flag-filled-red { color: @color5 !important; } | |
|
257 | 271 | |
|
258 | 272 | .repo-switcher-dropdown .select2-result-label { |
|
259 | 273 | .icon-git:before { |
@@ -152,6 +152,8 b' select.select2{height:28px;visibility:hi' | |||
|
152 | 152 | .drop-menu-no-width { |
|
153 | 153 | .drop-menu-base; |
|
154 | 154 | width: auto; |
|
155 | min-width: 0; | |
|
156 | margin: 0; | |
|
155 | 157 | } |
|
156 | 158 | |
|
157 | 159 | .field-sm .drop-menu { |
@@ -153,6 +153,7 b'' | |||
|
153 | 153 | text-align: center; |
|
154 | 154 | color: #949494; |
|
155 | 155 | font-size: 11px; |
|
156 | line-height: 1.3em; | |
|
156 | 157 | |
|
157 | 158 | &:hover { |
|
158 | 159 | background: #f1f1f1; |
@@ -199,6 +200,10 b'' | |||
|
199 | 200 | .fieldset { |
|
200 | 201 | margin-bottom: 0; |
|
201 | 202 | } |
|
203 | ||
|
204 | .tags-main { | |
|
205 | margin-bottom: 5px; | |
|
206 | } | |
|
202 | 207 | } |
|
203 | 208 | |
|
204 | 209 | .fieldset { |
@@ -564,6 +564,72 b'' | |||
|
564 | 564 | "src": "fontawesome" |
|
565 | 565 | }, |
|
566 | 566 | { |
|
567 | "uid": "7034e4d22866af82bef811f52fb1ba46", | |
|
568 | "css": "code", | |
|
569 | "code": 61729, | |
|
570 | "src": "fontawesome" | |
|
571 | }, | |
|
572 | { | |
|
573 | "uid": "f3f90c8c89795da30f7444634476ea4f", | |
|
574 | "css": "angle-left", | |
|
575 | "code": 61700, | |
|
576 | "src": "fontawesome" | |
|
577 | }, | |
|
578 | { | |
|
579 | "uid": "7bf14281af5633a597f85b061ef1cfb9", | |
|
580 | "css": "angle-right", | |
|
581 | "code": 61701, | |
|
582 | "src": "fontawesome" | |
|
583 | }, | |
|
584 | { | |
|
585 | "uid": "5de9370846a26947e03f63142a3f1c07", | |
|
586 | "css": "angle-up", | |
|
587 | "code": 61702, | |
|
588 | "src": "fontawesome" | |
|
589 | }, | |
|
590 | { | |
|
591 | "uid": "e4dde1992f787163e2e2b534b8c8067d", | |
|
592 | "css": "angle-down", | |
|
593 | "code": 61703, | |
|
594 | "src": "fontawesome" | |
|
595 | }, | |
|
596 | { | |
|
597 | "uid": "4i0s2bklai5fywieqm4dqqngfz9ptfab", | |
|
598 | "css": "flag-filled", | |
|
599 | "code": 59428, | |
|
600 | "src": "typicons" | |
|
601 | }, | |
|
602 | { | |
|
603 | "uid": "3d4ea8a78dc34efe891f3a0f3d961274", | |
|
604 | "css": "info", | |
|
605 | "code": 61737, | |
|
606 | "src": "fontawesome" | |
|
607 | }, | |
|
608 | { | |
|
609 | "uid": "56a21935a5d4d79b2e91ec00f760b369", | |
|
610 | "css": "sort", | |
|
611 | "code": 61660, | |
|
612 | "src": "fontawesome" | |
|
613 | }, | |
|
614 | { | |
|
615 | "uid": "130380e481a7defc690dfb24123a1f0c", | |
|
616 | "css": "circle", | |
|
617 | "code": 61713, | |
|
618 | "src": "fontawesome" | |
|
619 | }, | |
|
620 | { | |
|
621 | "uid": "422e07e5afb80258a9c4ed1706498f8a", | |
|
622 | "css": "circle-empty", | |
|
623 | "code": 61708, | |
|
624 | "src": "fontawesome" | |
|
625 | }, | |
|
626 | { | |
|
627 | "uid": "5774d0a0e50f6eefc8be01bd761e5dd3", | |
|
628 | "css": "circle-thin", | |
|
629 | "code": 61915, | |
|
630 | "src": "fontawesome" | |
|
631 | }, | |
|
632 | { | |
|
567 | 633 | "uid": "c43db6645e7515889fc2193294f50767", |
|
568 | 634 | "css": "plus", |
|
569 | 635 | "code": 59411, |
|
1 | NO CONTENT: modified file, binary diff hidden |
@@ -78,6 +78,8 b'' | |||
|
78 | 78 | |
|
79 | 79 | <glyph glyph-name="home" unicode="" d="M888 336q16-16 11-27t-27-11l-84 0 0-310q0-14-1-21t-8-13-23-6l-204 0 0 310-204 0 0-310-194 0q-28 0-35 10t-7 30l0 310-84 0q-22 0-27 11t11 27l400 402q16 16 38 16t38-16z" horiz-adv-x="900" /> |
|
80 | 80 | |
|
81 | <glyph glyph-name="flag-filled" unicode="" d="M640 693q25 25 57 11t32-47l0-418q0-21-15-36-80-80-193-80t-193 80q-47 46-110 50t-114-36l0-238q0-21-15-37t-36-15-37 15-16 37l0 678q0 21 15 36 80 80 193 80t193-80q50-50 120-50t119 50z" horiz-adv-x="729" /> | |
|
82 | ||
|
81 | 83 | <glyph glyph-name="git" unicode="" d="M929 844h-858c-36 0-65-30-65-65v-857c0-36 30-65 65-65h857c36 0 65 30 65 65v857c1 35-29 65-64 65z m-729-549c4-11 9-20 14-27 6-8 14-14 22-18 9-4 19-6 29-6 9 0 16 1 24 2 7 2 14 4 20 7l6 51h-27c-4 0-8 1-10 4-2 1-3 5-3 7l5 39h105l-16-131c-8-7-16-12-25-15-9-4-18-8-28-10-10-3-18-5-30-7-10-1-21-2-33-2-20 0-38 4-54 11-16 8-30 18-41 30-12 13-20 28-27 45-6 18-10 36-10 56 0 18 3 34 7 50 3 17 10 30 17 44 8 14 16 25 26 36 10 12 22 20 34 28 13 7 26 14 41 17 15 4 30 7 47 7 13 0 25-2 36-4 11-3 21-6 29-10 8-4 16-9 22-14 6-5 13-11 18-16l-20-31c-4-5-9-8-14-9-5-1-10 0-16 4-5 3-10 6-14 8-5 3-9 5-14 7-5 1-10 2-15 3-5 2-11 2-17 2-14 0-27-3-38-9-11-6-21-14-29-25-8-10-15-24-18-38-5-15-7-31-7-48-1-14 2-27 4-38z m336-102h-71l39 315h71l-39-315z m343 258h-80l-33-258h-70l32 258h-80l7 57h231l-7-57z" horiz-adv-x="1000" /> |
|
82 | 84 | |
|
83 | 85 | <glyph glyph-name="hg" unicode="" d="M927 841h-853c-36 0-65-29-65-65v-853c0-36 29-65 65-65h853c36 0 65 29 65 65v853c0 36-29 65-65 65z m-483-648h-70l16 133h-113l-17-133h-70l39 313h70l-16-132h113l16 132h71l-39-313z m177 101c3-11 8-20 14-27 7-8 14-14 23-18 8-4 18-6 28-6 9 0 16 1 23 3 7 1 14 3 20 6l6 51h-27c-4 0-7 1-9 3-3 3-3 6-3 9l5 39h104l-16-131c-8-6-16-11-25-15-9-5-18-8-27-11-9-2-19-4-30-6-10-1-21-2-33-2-19 0-37 4-53 11-16 7-30 17-41 29-11 13-20 28-26 45-7 17-10 35-10 55 0 17 2 34 6 50 4 15 10 30 17 43 7 14 16 26 26 36 10 11 22 20 34 28 13 7 27 13 41 17 14 4 30 7 46 7 13 0 25-2 36-4 11-3 20-6 29-10 8-4 16-9 23-14 7-5 13-11 18-17l-23-28c-4-5-8-8-13-9-5-1-11 0-16 3-5 4-10 7-14 9-5 3-9 5-14 6-4 2-9 3-14 4-5 1-11 1-17 1-14 0-27-3-38-8-11-6-21-14-29-25-8-10-15-23-19-38-5-15-7-31-7-49 0-13 2-26 5-37z" horiz-adv-x="1000" /> |
@@ -102,16 +104,34 b'' | |||
|
102 | 104 | |
|
103 | 105 | <glyph glyph-name="menu" unicode="" d="M857 100v-71q0-15-10-25t-26-11h-785q-15 0-25 11t-11 25v71q0 15 11 25t25 11h785q15 0 26-11t10-25z m0 286v-72q0-14-10-25t-26-10h-785q-15 0-25 10t-11 25v72q0 14 11 25t25 10h785q15 0 26-10t10-25z m0 285v-71q0-14-10-25t-26-11h-785q-15 0-25 11t-11 25v71q0 15 11 26t25 10h785q15 0 26-10t10-26z" horiz-adv-x="857.1" /> |
|
104 | 106 | |
|
107 | <glyph glyph-name="sort" unicode="" d="M571 243q0-15-10-25l-250-250q-11-11-25-11t-25 11l-250 250q-11 10-11 25t11 25 25 11h500q14 0 25-11t10-25z m0 214q0-14-10-25t-25-11h-500q-15 0-25 11t-11 25 11 25l250 250q10 11 25 11t25-11l250-250q10-10 10-25z" horiz-adv-x="571.4" /> | |
|
108 | ||
|
105 | 109 | <glyph glyph-name="paste" unicode="" d="M429-79h500v358h-233q-22 0-37 15t-16 38v232h-214v-643z m142 804v36q0 7-5 12t-12 6h-393q-7 0-13-6t-5-12v-36q0-7 5-13t13-5h393q7 0 12 5t5 13z m143-375h167l-167 167v-167z m286-71v-375q0-23-16-38t-38-16h-535q-23 0-38 16t-16 38v89h-303q-23 0-38 16t-16 37v750q0 23 16 38t38 16h607q22 0 38-16t15-38v-183q12-7 20-15l228-228q16-15 27-42t11-49z" horiz-adv-x="1000" /> |
|
106 | 110 | |
|
107 | 111 | <glyph glyph-name="doc-text" unicode="" d="M819 638q16-16 27-42t11-50v-642q0-23-15-38t-38-16h-750q-23 0-38 16t-16 38v892q0 23 16 38t38 16h500q22 0 49-11t42-27z m-248 136v-210h210q-5 17-12 23l-175 175q-6 7-23 12z m215-853v572h-232q-23 0-38 16t-16 37v233h-429v-858h715z m-572 483q0 7 5 12t13 5h393q8 0 13-5t5-12v-36q0-8-5-13t-13-5h-393q-8 0-13 5t-5 13v36z m411-125q8 0 13-5t5-13v-36q0-8-5-13t-13-5h-393q-8 0-13 5t-5 13v36q0 8 5 13t13 5h393z m0-143q8 0 13-5t5-13v-36q0-8-5-13t-13-5h-393q-8 0-13 5t-5 13v36q0 8 5 13t13 5h393z" horiz-adv-x="857.1" /> |
|
108 | 112 | |
|
109 | 113 | <glyph glyph-name="plus-squared" unicode="" d="M714 314v72q0 14-10 25t-25 10h-179v179q0 15-11 25t-25 11h-71q-15 0-25-11t-11-25v-179h-178q-15 0-25-10t-11-25v-72q0-14 11-25t25-10h178v-179q0-14 11-25t25-11h71q15 0 25 11t11 25v179h179q14 0 25 10t10 25z m143 304v-536q0-66-47-113t-114-48h-535q-67 0-114 48t-47 113v536q0 66 47 113t114 48h535q67 0 114-48t47-113z" horiz-adv-x="857.1" /> |
|
110 | 114 | |
|
115 | <glyph glyph-name="angle-left" unicode="" d="M350 546q0-7-6-12l-219-220 219-219q6-6 6-13t-6-13l-28-28q-5-5-12-5t-13 5l-260 261q-6 5-6 12t6 13l260 260q5 6 13 6t12-6l28-28q6-5 6-13z" horiz-adv-x="357.1" /> | |
|
116 | ||
|
117 | <glyph glyph-name="angle-right" unicode="" d="M332 314q0-7-5-12l-261-261q-5-5-12-5t-13 5l-28 28q-6 6-6 13t6 13l219 219-219 220q-6 5-6 12t6 13l28 28q5 6 13 6t12-6l261-260q5-5 5-13z" horiz-adv-x="357.1" /> | |
|
118 | ||
|
119 | <glyph glyph-name="angle-up" unicode="" d="M600 189q0-7-6-12l-28-28q-5-6-12-6t-13 6l-220 219-219-219q-5-6-13-6t-12 6l-28 28q-6 5-6 12t6 13l260 260q5 6 12 6t13-6l260-260q6-5 6-13z" horiz-adv-x="642.9" /> | |
|
120 | ||
|
121 | <glyph glyph-name="angle-down" unicode="" d="M600 439q0-7-6-12l-260-261q-5-5-13-5t-12 5l-260 261q-6 5-6 12t6 13l28 28q5 6 12 6t13-6l219-219 220 219q5 6 13 6t12-6l28-28q6-5 6-13z" horiz-adv-x="642.9" /> | |
|
122 | ||
|
123 | <glyph glyph-name="circle-empty" unicode="" d="M429 654q-83 0-153-41t-110-111-41-152 41-152 110-111 153-41 152 41 110 111 41 152-41 152-110 111-152 41z m428-304q0-117-57-215t-156-156-215-58-216 58-155 156-58 215 58 215 155 156 216 58 215-58 156-156 57-215z" horiz-adv-x="857.1" /> | |
|
124 | ||
|
125 | <glyph glyph-name="circle" unicode="" d="M857 350q0-117-57-215t-156-156-215-58-216 58-155 156-58 215 58 215 155 156 216 58 215-58 156-156 57-215z" horiz-adv-x="857.1" /> | |
|
126 | ||
|
111 | 127 | <glyph glyph-name="folder-empty" unicode="" d="M857 118v393q0 22-15 38t-38 15h-393q-23 0-38 16t-16 38v36q0 22-15 38t-38 15h-179q-22 0-38-15t-16-38v-536q0-22 16-38t38-16h679q22 0 38 16t15 38z m72 393v-393q0-51-37-88t-88-37h-679q-51 0-88 37t-37 88v536q0 51 37 88t88 37h179q51 0 88-37t37-88v-18h375q51 0 88-37t37-88z" horiz-adv-x="928.6" /> |
|
112 | 128 | |
|
113 | 129 | <glyph glyph-name="folder-open-empty" unicode="" d="M994 331q0 19-30 19h-607q-22 0-48-12t-39-29l-164-203q-11-13-11-22 0-20 30-20h607q23 0 48 13t40 29l164 203q10 12 10 22z m-637 90h429v90q0 22-16 38t-38 15h-321q-23 0-38 16t-16 38v36q0 22-15 38t-38 15h-179q-22 0-38-15t-16-38v-476l143 175q25 30 65 49t78 19z m708-90q0-35-25-67l-165-203q-24-30-65-49t-78-19h-607q-51 0-88 37t-37 88v536q0 51 37 88t88 37h179q51 0 88-37t37-88v-18h303q52 0 88-37t37-88v-90h107q30 0 56-13t37-40q8-17 8-37z" horiz-adv-x="1071.4" /> |
|
114 | 130 | |
|
131 | <glyph glyph-name="code" unicode="" d="M344 69l-28-28q-5-5-12-5t-13 5l-260 261q-6 5-6 12t6 13l260 260q5 6 13 6t12-6l28-28q6-5 6-13t-6-12l-219-220 219-219q6-6 6-13t-6-13z m330 596l-208-721q-2-7-9-11t-13-1l-34 9q-8 3-11 9t-2 14l209 720q2 8 8 11t13 2l35-10q7-2 11-9t1-13z m367-363l-260-261q-6-5-13-5t-13 5l-28 28q-5 6-5 13t5 13l219 219-219 220q-5 5-5 12t5 13l28 28q6 6 13 6t13-6l260-260q5-5 5-13t-5-12z" horiz-adv-x="1071.4" /> | |
|
132 | ||
|
133 | <glyph glyph-name="info" unicode="" d="M357 100v-71q0-15-10-25t-26-11h-285q-15 0-25 11t-11 25v71q0 15 11 25t25 11h35v214h-35q-15 0-25 11t-11 25v71q0 15 11 25t25 11h214q15 0 25-11t11-25v-321h35q15 0 26-11t10-25z m-71 643v-107q0-15-11-25t-25-11h-143q-14 0-25 11t-11 25v107q0 14 11 25t25 11h143q15 0 25-11t11-25z" horiz-adv-x="357.1" /> | |
|
134 | ||
|
115 | 135 | <glyph glyph-name="minus-squared" unicode="" d="M714 314v72q0 14-10 25t-25 10h-500q-15 0-25-10t-11-25v-72q0-14 11-25t25-10h500q14 0 25 10t10 25z m143 304v-536q0-66-47-113t-114-48h-535q-67 0-114 48t-47 113v536q0 66 47 113t114 48h535q67 0 114-48t47-113z" horiz-adv-x="857.1" /> |
|
116 | 136 | |
|
117 | 137 | <glyph glyph-name="minus-squared-alt" unicode="" d="M643 404v-36q0-8-5-13t-13-5h-464q-8 0-13 5t-5 13v36q0 7 5 12t13 5h464q8 0 13-5t5-12z m71-250v464q0 37-26 63t-63 26h-464q-37 0-63-26t-27-63v-464q0-37 27-63t63-27h464q37 0 63 27t26 63z m72 464v-464q0-67-47-114t-114-47h-464q-67 0-114 47t-47 114v464q0 66 47 113t114 48h464q66 0 114-48t47-113z" horiz-adv-x="785.7" /> |
@@ -126,6 +146,8 b'' | |||
|
126 | 146 | |
|
127 | 147 | <glyph glyph-name="history" unicode="" d="M857 350q0-87-34-166t-91-137-137-92-166-34q-96 0-183 41t-147 114q-4 6-4 13t5 11l76 77q6 5 14 5 9-1 13-7 41-53 100-82t126-29q58 0 110 23t92 61 61 91 22 111-22 111-61 91-92 61-110 23q-55 0-105-20t-90-57l77-77q17-16 8-38-10-23-33-23h-250q-15 0-25 11t-11 25v250q0 24 22 33 22 10 39-8l72-72q60 57 137 88t159 31q87 0 166-34t137-92 91-137 34-166z m-357 161v-250q0-8-5-13t-13-5h-178q-8 0-13 5t-5 13v35q0 8 5 13t13 5h125v197q0 8 5 13t12 5h36q8 0 13-5t5-13z" horiz-adv-x="857.1" /> |
|
128 | 148 | |
|
149 | <glyph glyph-name="circle-thin" unicode="" d="M429 707q-73 0-139-28t-114-76-76-114-29-139 29-139 76-113 114-77 139-28 138 28 114 77 76 113 29 139-29 139-76 114-114 76-138 28z m428-357q0-117-57-215t-156-156-215-58-216 58-155 156-58 215 58 215 155 156 216 58 215-58 156-156 57-215z" horiz-adv-x="857.1" /> | |
|
150 | ||
|
129 | 151 | <glyph glyph-name="sliders" unicode="" d="M196 64v-71h-196v71h196z m197 72q14 0 25-11t11-25v-143q0-14-11-25t-25-11h-143q-14 0-25 11t-11 25v143q0 15 11 25t25 11h143z m89 214v-71h-482v71h482z m-357 286v-72h-125v72h125z m732-572v-71h-411v71h411z m-536 643q15 0 26-10t10-26v-142q0-15-10-25t-26-11h-142q-15 0-25 11t-11 25v142q0 15 11 26t25 10h142z m358-286q14 0 25-10t10-25v-143q0-15-10-25t-25-11h-143q-15 0-25 11t-11 25v143q0 14 11 25t25 10h143z m178-71v-71h-125v71h125z m0 286v-72h-482v72h482z" horiz-adv-x="857.1" /> |
|
130 | 152 | |
|
131 | 153 | <glyph glyph-name="trash" unicode="" d="M286 82v393q0 8-5 13t-13 5h-36q-8 0-13-5t-5-13v-393q0-8 5-13t13-5h36q8 0 13 5t5 13z m143 0v393q0 8-5 13t-13 5h-36q-8 0-13-5t-5-13v-393q0-8 5-13t13-5h36q8 0 13 5t5 13z m142 0v393q0 8-5 13t-12 5h-36q-8 0-13-5t-5-13v-393q0-8 5-13t13-5h36q7 0 12 5t5 13z m-303 554h250l-27 65q-4 5-9 6h-177q-6-1-10-6z m518-18v-36q0-8-5-13t-13-5h-54v-529q0-46-26-80t-63-34h-464q-37 0-63 33t-27 79v531h-53q-8 0-13 5t-5 13v36q0 8 5 13t13 5h172l39 93q9 21 31 35t44 15h178q23 0 44-15t30-35l39-93h173q8 0 13-5t5-13z" horiz-adv-x="785.7" /> |
|
1 | NO CONTENT: modified file, binary diff hidden |
|
1 | NO CONTENT: modified file, binary diff hidden |
|
1 | NO CONTENT: modified file, binary diff hidden |
@@ -1,10 +1,12 b'' | |||
|
1 | 1 | ## -*- coding: utf-8 -*- |
|
2 | 2 | |
|
3 | 3 | <%inherit file="/base/base.mako"/> |
|
4 | <%namespace name="base" file="/base/base.mako"/> | |
|
4 | 5 | <%namespace name="diff_block" file="/changeset/diff_block.mako"/> |
|
6 | <%namespace name="file_base" file="/files/base.mako"/> | |
|
5 | 7 | |
|
6 | 8 | <%def name="title()"> |
|
7 |
${_(' |
|
|
9 | ${_('{} Commit').format(c.repo_name)} - ${h.show_id(c.commit)} | |
|
8 | 10 | %if c.rhodecode_name: |
|
9 | 11 | · ${h.branding(c.rhodecode_name)} |
|
10 | 12 | %endif |
@@ -19,120 +21,111 b'' | |||
|
19 | 21 | </%def> |
|
20 | 22 | |
|
21 | 23 | <%def name="main()"> |
|
22 | <script> | |
|
24 | <script type="text/javascript"> | |
|
23 | 25 | // TODO: marcink switch this to pyroutes |
|
24 | 26 | AJAX_COMMENT_DELETE_URL = "${h.route_path('repo_commit_comment_delete',repo_name=c.repo_name,commit_id=c.commit.raw_id,comment_id='__COMMENT_ID__')}"; |
|
25 | 27 | templateContext.commit_data.commit_id = "${c.commit.raw_id}"; |
|
26 | 28 | </script> |
|
29 | ||
|
27 | 30 | <div class="box"> |
|
28 | 31 | |
|
29 | <div id="changeset_compare_view_content" class="summary changeset"> | |
|
30 | <div class="summary-detail"> | |
|
32 | <div class="summary"> | |
|
33 | ||
|
31 | 34 |
|
|
32 |
|
|
|
33 | <p>${_('Commit')}</p> | |
|
34 |
|
|
|
35 | <code> | |
|
36 | ${h.show_id(c.commit)} | |
|
37 | </code> | |
|
35 | <div class="left-content"> | |
|
36 | ||
|
37 | <div class="left-content-avatar"> | |
|
38 | ${base.gravatar(c.commit.author_email, 30)} | |
|
39 | </div> | |
|
40 | ||
|
41 | <div class="left-content-message"> | |
|
42 | <div class="fieldset collapsable-content no-hide" data-toggle="summary-details"> | |
|
43 | <div class="commit truncate-wrap">${h.urlify_commit_message(h.chop_at_smart(c.commit.message, '\n', suffix_if_chopped='...'), c.repo_name)}</div> | |
|
44 | </div> | |
|
45 | ||
|
46 | <div class="fieldset collapsable-content" data-toggle="summary-details" style="display: none"> | |
|
47 | <div class="commit">${h.urlify_commit_message(c.commit.message,c.repo_name)}</div> | |
|
48 | </div> | |
|
49 | ||
|
50 | <div class="fieldset" data-toggle="summary-details"> | |
|
51 | <div class=""> | |
|
52 | <table> | |
|
53 | <tr class="file_author tooltip" title="${h.tooltip(h.author_string(c.commit.author_email))}"> | |
|
54 | ||
|
55 | <td> | |
|
56 | <span class="user commit-author">${h.link_to_user(c.commit.author)}</span> | |
|
57 | <span class="commit-date">- ${h.age_component(c.commit.date)}</span> | |
|
58 | </td> | |
|
59 | ||
|
60 | <td> | |
|
61 | ## second cell for consistency with files | |
|
62 | </td> | |
|
63 | </tr> | |
|
64 | </table> | |
|
65 | </div> | |
|
66 | </div> | |
|
67 | ||
|
68 | </div> | |
|
69 | </div> | |
|
70 | ||
|
71 | <div class="right-content"> | |
|
72 | ||
|
73 | <div data-toggle="summary-details"> | |
|
74 | <div class="tags tags-main"> | |
|
75 | <code><a href="${h.route_path('repo_commit',repo_name=c.repo_name,commit_id=c.commit.raw_id)}">${h.show_id(c.commit)}</a></code> | |
|
38 | 76 | <i class="tooltip icon-clipboard clipboard-action" data-clipboard-text="${c.commit.raw_id}" title="${_('Copy the full commit id')}"></i> |
|
39 |
|
|
|
40 | <span class="tag phase-${c.commit.phase} tooltip" title="${_('Commit phase')}">${c.commit.phase}</span> | |
|
77 | ${file_base.refs(c.commit)} | |
|
78 | ||
|
79 | ## phase | |
|
80 | % if hasattr(c.commit, 'phase') and getattr(c.commit, 'phase') != 'public': | |
|
81 | <span class="tag phase-${c.commit.phase} tooltip" title="${_('Commit phase')}"> | |
|
82 | <i class="icon-info"></i>${c.commit.phase} | |
|
83 | </span> | |
|
41 | 84 | % endif |
|
42 | 85 | |
|
43 | 86 | ## obsolete commits |
|
44 |
% if |
|
|
45 | % if c.commit.obsolete: | |
|
46 | <span class="tag obsolete-${c.commit.obsolete} tooltip" title="${_('Evolve State')}">${_('obsolete')}</span> | |
|
47 |
|
|
|
87 | % if getattr(c.commit, 'obsolete', False): | |
|
88 | <span class="tag obsolete-${c.commit.obsolete} tooltip" title="${_('Evolve State')}"> | |
|
89 | ${_('obsolete')} | |
|
90 | </span> | |
|
48 | 91 | % endif |
|
49 | 92 | |
|
50 | 93 | ## hidden commits |
|
51 |
% if |
|
|
52 | % if c.commit.hidden: | |
|
53 | <span class="tag hidden-${c.commit.hidden} tooltip" title="${_('Evolve State')}">${_('hidden')}</span> | |
|
94 | % if getattr(c.commit, 'hidden', False): | |
|
95 | <span class="tag hidden-${c.commit.hidden} tooltip" title="${_('Evolve State')}"> | |
|
96 | ${_('hidden')} | |
|
97 | </span> | |
|
54 | 98 | % endif |
|
99 | </div> | |
|
100 | ||
|
101 | %if c.statuses: | |
|
102 | <div class="tag status-tag-${c.statuses[0]} pull-right"> | |
|
103 | <i class="icon-circle review-status-${c.statuses[0]}"></i> | |
|
104 | <div class="pull-right">${h.commit_status_lbl(c.statuses[0])}</div> | |
|
105 | </div> | |
|
55 | 106 |
% |
|
56 | 107 | |
|
108 | </div> | |
|
57 | 109 | |
|
58 | <div class="pull-right"> | |
|
59 | <span id="parent_link"> | |
|
110 | </div> | |
|
111 | </div> | |
|
112 | ||
|
113 | <div class="fieldset collapsable-content" data-toggle="summary-details" style="display: none;"> | |
|
114 | <div class="left-label-summary"> | |
|
115 | <p>${_('Commit navigation')}:</p> | |
|
116 | <div class="right-label-summary"> | |
|
117 | <span id="parent_link" class="tag tagtag"> | |
|
60 | 118 |
|
|
61 | 119 |
|
|
62 | | | |
|
63 |
|
|
|
120 | ||
|
121 | <span id="child_link" class="tag tagtag"> | |
|
64 | 122 |
|
|
65 | 123 |
|
|
66 | 124 |
|
|
67 | ||
|
68 | </div> | |
|
69 | 125 |
|
|
70 | 126 |
|
|
71 | 127 | |
|
72 | ||
|
73 | ||
|
74 | <div class="fieldset"> | |
|
75 | <div class="left-label-summary"> | |
|
76 | <p>${_('Description')}:</p> | |
|
77 | <div class="right-label-summary"> | |
|
78 | <div id="trimmed_message_box" class="commit">${h.urlify_commit_message(c.commit.message,c.repo_name)}</div> | |
|
79 | <div id="message_expand" style="display:none;"> | |
|
80 | ${_('Expand')} | |
|
81 | </div> | |
|
82 | </div> | |
|
83 | </div> | |
|
84 | </div> | |
|
85 | ||
|
86 | %if c.statuses: | |
|
87 | <div class="fieldset"> | |
|
88 | <div class="left-label-summary"> | |
|
89 | <p>${_('Commit status')}:</p> | |
|
90 | <div class="right-label-summary"> | |
|
91 | <div class="changeset-status-ico"> | |
|
92 | <div class="${'flag_status %s' % c.statuses[0]} pull-left"></div> | |
|
93 | </div> | |
|
94 | <div title="${_('Commit status')}" class="changeset-status-lbl">[${h.commit_status_lbl(c.statuses[0])}]</div> | |
|
95 | </div> | |
|
96 | </div> | |
|
97 | </div> | |
|
98 | %endif | |
|
99 | ||
|
100 | <div class="fieldset"> | |
|
101 | <div class="left-label-summary"> | |
|
102 | <p>${_('References')}:</p> | |
|
103 | <div class="right-label-summary"> | |
|
104 | <div class="tags"> | |
|
105 | %if c.commit.merge: | |
|
106 | <span class="mergetag tag"> | |
|
107 | <i class="icon-merge"></i>${_('merge')} | |
|
108 | </span> | |
|
109 | %endif | |
|
110 | ||
|
111 | %if h.is_hg(c.rhodecode_repo): | |
|
112 | %for book in c.commit.bookmarks: | |
|
113 | <span class="booktag tag" title="${h.tooltip(_('Bookmark %s') % book)}"> | |
|
114 | <a href="${h.route_path('repo_files:default_path',repo_name=c.repo_name,commit_id=c.commit.raw_id,_query=dict(at=book))}"><i class="icon-bookmark"></i>${h.shorter(book)}</a> | |
|
115 | </span> | |
|
116 | %endfor | |
|
117 | %endif | |
|
118 | ||
|
119 | %for tag in c.commit.tags: | |
|
120 | <span class="tagtag tag" title="${h.tooltip(_('Tag %s') % tag)}"> | |
|
121 | <a href="${h.route_path('repo_files:default_path',repo_name=c.repo_name,commit_id=c.commit.raw_id,_query=dict(at=tag))}"><i class="icon-tag"></i>${tag}</a> | |
|
122 | </span> | |
|
123 | %endfor | |
|
124 | ||
|
125 | %if c.commit.branch: | |
|
126 | <span class="branchtag tag" title="${h.tooltip(_('Branch %s') % c.commit.branch)}"> | |
|
127 | <a href="${h.route_path('repo_files:default_path',repo_name=c.repo_name,commit_id=c.commit.raw_id,_query=dict(at=c.commit.branch))}"><i class="icon-code-fork"></i>${h.shorter(c.commit.branch)}</a> | |
|
128 | </span> | |
|
129 | %endif | |
|
130 | </div> | |
|
131 | </div> | |
|
132 | </div> | |
|
133 | </div> | |
|
134 | ||
|
135 | <div class="fieldset"> | |
|
128 | <div class="fieldset collapsable-content" data-toggle="summary-details" style="display: none;"> | |
|
136 | 129 | <div class="left-label-summary"> |
|
137 | 130 | <p>${_('Diff options')}:</p> |
|
138 | 131 | <div class="right-label-summary"> |
@@ -153,58 +146,14 b'' | |||
|
153 | 146 | </div> |
|
154 | 147 | </div> |
|
155 | 148 | |
|
156 |
<div class=" |
|
|
157 | <div class="left-label-summary"> | |
|
158 | <p>${_('Comments')}:</p> | |
|
159 | <div class="right-label-summary"> | |
|
160 | <div class="comments-number"> | |
|
161 | %if c.comments: | |
|
162 | <a href="#comments">${_ungettext("%d Commit comment", "%d Commit comments", len(c.comments)) % len(c.comments)}</a>, | |
|
163 | %else: | |
|
164 | ${_ungettext("%d Commit comment", "%d Commit comments", len(c.comments)) % len(c.comments)} | |
|
165 | %endif | |
|
166 | %if c.inline_cnt: | |
|
167 | <a href="#" onclick="return Rhodecode.comments.nextComment();" id="inline-comments-counter">${_ungettext("%d Inline Comment", "%d Inline Comments", c.inline_cnt) % c.inline_cnt}</a> | |
|
168 | %else: | |
|
169 | ${_ungettext("%d Inline Comment", "%d Inline Comments", c.inline_cnt) % c.inline_cnt} | |
|
170 | %endif | |
|
171 | </div> | |
|
172 | </div> | |
|
173 | </div> | |
|
149 | <div class="clear-fix"></div> | |
|
150 | ||
|
151 | <div class="btn-collapse" data-toggle="summary-details"> | |
|
152 | ${_('Show More')} | |
|
174 | 153 | </div> |
|
175 | 154 | |
|
176 | <div class="fieldset"> | |
|
177 | <div class="left-label-summary"> | |
|
178 | <p>${_('Unresolved TODOs')}:</p> | |
|
179 | <div class="right-label-summary"> | |
|
180 | <div class="comments-number"> | |
|
181 | % if c.unresolved_comments: | |
|
182 | % for co in c.unresolved_comments: | |
|
183 | <a class="permalink" href="#comment-${co.comment_id}" onclick="Rhodecode.comments.scrollToComment($('#comment-${co.comment_id}'))"> #${co.comment_id}</a>${'' if loop.last else ','} | |
|
184 | % endfor | |
|
185 | % else: | |
|
186 | ${_('There are no unresolved TODOs')} | |
|
187 | % endif | |
|
188 | </div> | |
|
189 | </div> | |
|
190 | </div> | |
|
191 | 155 |
|
|
192 | 156 | |
|
193 | <div class="fieldset"> | |
|
194 | <div class="left-label-summary"> | |
|
195 | <p>${_('Author')}</p> | |
|
196 | ||
|
197 | <div class="right-label-summary"> | |
|
198 | ${self.gravatar_with_user(c.commit.author)} | |
|
199 | <div class="user-inline-data">- ${h.age_component(c.commit.date)}</div> | |
|
200 | </div> | |
|
201 | </div> | |
|
202 | ||
|
203 | <div class="clear-fix"></div> | |
|
204 | ||
|
205 | </div> <!-- end summary-detail --> | |
|
206 | </div> <!-- end summary --> | |
|
207 | </div> | |
|
208 | 157 | <div class="cs_files"> |
|
209 | 158 | <%namespace name="cbdiffs" file="/codeblocks/diffs.mako"/> |
|
210 | 159 | ${cbdiffs.render_diffset_menu(c.changes[c.commit.raw_id])} |
@@ -212,6 +161,11 b'' | |||
|
212 | 161 | c.changes[c.commit.raw_id], commit=c.commit, use_comments=True,inline_comments=c.inline_comments )} |
|
213 | 162 | </div> |
|
214 | 163 | |
|
164 | <div class="comments-heading"> | |
|
165 | <i class="icon-comment"></i> | |
|
166 | ${_('Comments')} ${len(c.comments)} | |
|
167 | </div> | |
|
168 | ||
|
215 | 169 | ## template for inline comment form |
|
216 | 170 | <%namespace name="comment" file="/changeset/changeset_file_comment.mako"/> |
|
217 | 171 | |
@@ -350,6 +304,7 b'' | |||
|
350 | 304 | |
|
351 | 305 | // inject comments into their proper positions |
|
352 | 306 | var file_comments = $('.inline-comment-placeholder'); |
|
307 | ||
|
353 | 308 | }) |
|
354 | 309 | </script> |
|
355 | 310 |
@@ -23,6 +23,7 b'' | |||
|
23 | 23 | </%def> |
|
24 | 24 | |
|
25 | 25 | <%def name="main()"> |
|
26 | ||
|
26 | 27 | <div class="box"> |
|
27 | 28 | <div class="summary changeset"> |
|
28 | 29 | <div class="summary-detail"> |
@@ -60,8 +61,7 b'' | |||
|
60 | 61 | <div class="right-label-summary"> |
|
61 | 62 | <div class="code-header" > |
|
62 | 63 | <div class="compare_header"> |
|
63 |
< |
|
|
64 | <a href="${h.route_path('repo_compare', | |
|
64 | <a class="btn btn-primary" href="${h.route_path('repo_compare', | |
|
65 | 65 | repo_name=c.repo_name, |
|
66 | 66 | source_ref_type='rev', |
|
67 | 67 | source_ref=getattr(c.commit_ranges[0].parents[0] if c.commit_ranges[0].parents else h.EmptyCommit(), 'raw_id'), |
@@ -75,7 +75,6 b'' | |||
|
75 | 75 |
|
|
76 | 76 |
|
|
77 | 77 |
|
|
78 | </div> | |
|
79 | 78 | |
|
80 | 79 | <div class="clear-fix"></div> |
|
81 | 80 | </div> <!-- end summary-detail --> |
@@ -104,8 +103,9 b'' | |||
|
104 | 103 | <%namespace name="cbdiffs" file="/codeblocks/diffs.mako"/> |
|
105 | 104 | <%namespace name="comment" file="/changeset/changeset_file_comment.mako"/> |
|
106 | 105 | <%namespace name="diff_block" file="/changeset/diff_block.mako"/> |
|
107 | ${cbdiffs.render_diffset_menu()} | |
|
106 | ||
|
108 | 107 | %for commit in c.commit_ranges: |
|
108 | ${cbdiffs.render_diffset_menu(c.changes[commit.raw_id])} | |
|
109 | 109 | ${cbdiffs.render_diffset( |
|
110 | 110 | diffset=c.changes[commit.raw_id], |
|
111 | 111 | collapse_when_files_over=5, |
@@ -50,6 +50,12 b" return '%s_%s_%i' % (h.md5_safe(commit+f" | |||
|
50 | 50 | inline_comments=None, |
|
51 | 51 | |
|
52 | 52 | )"> |
|
53 | ||
|
54 | <% | |
|
55 | diffset_container_id = h.md5(diffset.target_ref) | |
|
56 | collapse_all = len(diffset.files) > collapse_when_files_over | |
|
57 | %> | |
|
58 | ||
|
53 | 59 | %if use_comments: |
|
54 | 60 | <div id="cb-comments-inline-container-template" class="js-template"> |
|
55 | 61 | ${inline_comments_container([], inline_comments)} |
@@ -79,9 +85,6 b" return '%s_%s_%i' % (h.md5_safe(commit+f" | |||
|
79 | 85 | </div> |
|
80 | 86 | |
|
81 | 87 | %endif |
|
82 | <% | |
|
83 | collapse_all = len(diffset.files) > collapse_when_files_over | |
|
84 | %> | |
|
85 | 88 | |
|
86 | 89 | %if c.user_session_attrs["diffmode"] == 'sideside': |
|
87 | 90 | <style> |
@@ -107,37 +110,88 b' collapse_all = len(diffset.files) > coll' | |||
|
107 | 110 | %endif |
|
108 | 111 | |
|
109 | 112 | <div class="diffset ${disable_new_comments and 'diffset-comments-disabled'}"> |
|
110 | <div class="diffset-heading ${diffset.limited_diff and 'diffset-heading-warning' or ''}"> | |
|
111 | %if commit: | |
|
113 | ||
|
114 | <div style="height: 20px; line-height: 20px"> | |
|
115 | ## expand/collapse action | |
|
116 | <div class="pull-left"> | |
|
117 | <a class="${'collapsed' if collapse_all else ''}" href="#expand-files" onclick="toggleExpand(this, '${diffset_container_id}'); return false"> | |
|
118 | % if collapse_all: | |
|
119 | <i class="icon-plus-squared-alt icon-no-margin"></i>${_('Expand all files')} | |
|
120 | % else: | |
|
121 | <i class="icon-minus-squared-alt icon-no-margin"></i>${_('Collapse all files')} | |
|
122 | % endif | |
|
123 | </a> | |
|
124 | ||
|
125 | </div> | |
|
126 | ||
|
127 | ## todos | |
|
128 | <div class="pull-right"> | |
|
129 | <div class="comments-number" style="padding-left: 10px"> | |
|
130 | % if hasattr(c, 'unresolved_comments') and hasattr(c, 'resolved_comments'): | |
|
131 | <i class="icon-flag-filled" style="color: #949494">TODOs:</i> | |
|
132 | % if c.unresolved_comments: | |
|
133 | <a href="#show-todos" onclick="$('#todo-box').toggle(); return false"> | |
|
134 | ${_('{} unresolved').format(len(c.unresolved_comments))} | |
|
135 | </a> | |
|
136 | % else: | |
|
137 | ${_('0 unresolved')} | |
|
138 | % endif | |
|
139 | ||
|
140 | ${_('{} Resolved').format(len(c.unresolved_comments))} | |
|
141 | % endif | |
|
142 | </div> | |
|
143 | </div> | |
|
144 | ||
|
145 | ## comments | |
|
112 | 146 |
|
|
113 | <a class="btn tooltip" title="${h.tooltip(_('Browse Files at revision {}').format(commit.raw_id))}" href="${h.route_path('repo_files',repo_name=diffset.repo_name, commit_id=commit.raw_id, f_path='')}"> | |
|
114 | ${_('Browse Files')} | |
|
147 | <div class="comments-number" style="padding-left: 10px"> | |
|
148 | % if hasattr(c, 'comments') and hasattr(c, 'inline_cnt'): | |
|
149 | <i class="icon-comment" style="color: #949494">COMMENTS:</i> | |
|
150 | % if c.comments: | |
|
151 | <a href="#comments">${_ungettext("{} General", "{} General", len(c.comments)).format(len(c.comments))}</a>, | |
|
152 | % else: | |
|
153 | ${_('0 General')} | |
|
154 | % endif | |
|
155 | ||
|
156 | % if c.inline_cnt: | |
|
157 | <a href="#" onclick="return Rhodecode.comments.nextComment();" | |
|
158 | id="inline-comments-counter">${_ungettext("{} Inline", "{} Inline", c.inline_cnt).format(c.inline_cnt)} | |
|
115 | 159 | </a> |
|
160 | % else: | |
|
161 | ${_('0 Inline')} | |
|
162 | % endif | |
|
163 | % endif | |
|
164 | </div> | |
|
165 | </div> | |
|
166 | ||
|
167 | </div> | |
|
168 | ||
|
169 | % if diffset.limited_diff: | |
|
170 | <div class="diffset-heading ${(diffset.limited_diff and 'diffset-heading-warning' or '')}"> | |
|
171 | <h2 class="clearinner"> | |
|
172 | ${_('The requested changes are too big and content was truncated.')} | |
|
173 | <a href="${h.current_route_path(request, fulldiff=1)}" onclick="return confirm('${_("Showing a big diff might take some time and resources, continue?")}')">${_('Show full diff')}</a> | |
|
174 | </h2> | |
|
175 | </div> | |
|
176 | ## commit range header for each individual diff | |
|
177 | % elif commit and hasattr(c, 'commit_ranges') and len(c.commit_ranges) > 1: | |
|
178 | <div class="diffset-heading ${(diffset.limited_diff and 'diffset-heading-warning' or '')}"> | |
|
179 | <div class="clearinner"> | |
|
180 | <a class="tooltip revision" title="${h.tooltip(commit.message)}" href="${h.route_path('repo_commit',repo_name=diffset.repo_name,commit_id=commit.raw_id)}">${('r%s:%s' % (commit.idx,h.short_id(commit.raw_id)))}</a> | |
|
181 | </div> | |
|
116 | 182 |
|
|
117 | 183 |
|
|
118 | <h2 class="clearinner"> | |
|
119 | ## invidual commit | |
|
120 | % if commit: | |
|
121 | <a class="tooltip revision" title="${h.tooltip(commit.message)}" href="${h.route_path('repo_commit',repo_name=diffset.repo_name,commit_id=commit.raw_id)}">${('r%s:%s' % (commit.idx,h.short_id(commit.raw_id)))}</a> - | |
|
122 | ${h.age_component(commit.date)} | |
|
123 | % if diffset.limited_diff: | |
|
124 | - ${_('The requested changes are too big and content was truncated.')} | |
|
125 | ${_ungettext('%(num)s file changed.', '%(num)s files changed.', diffset.changed_files) % {'num': diffset.changed_files}} | |
|
126 | <a href="${h.current_route_path(request, fulldiff=1)}" onclick="return confirm('${_("Showing a big diff might take some time and resources, continue?")}')">${_('Show full diff')}</a> | |
|
127 | % elif hasattr(c, 'commit_ranges') and len(c.commit_ranges) > 1: | |
|
128 | ## compare diff, has no file-selector and we want to show stats anyway | |
|
129 | ${_ungettext('{num} file changed: {linesadd} inserted, ''{linesdel} deleted', | |
|
130 | '{num} files changed: {linesadd} inserted, {linesdel} deleted', diffset.changed_files) \ | |
|
131 | .format(num=diffset.changed_files, linesadd=diffset.lines_added, linesdel=diffset.lines_deleted)} | |
|
184 | ||
|
185 | <div id="todo-box"> | |
|
186 | % if hasattr(c, 'unresolved_comments') and c.unresolved_comments: | |
|
187 | % for co in c.unresolved_comments: | |
|
188 | <a class="permalink" href="#comment-${co.comment_id}" | |
|
189 | onclick="Rhodecode.comments.scrollToComment($('#comment-${co.comment_id}'))"> | |
|
190 | <i class="icon-flag-filled-red"></i> | |
|
191 | ${co.comment_id}</a>${('' if loop.last else ',')} | |
|
192 | % endfor | |
|
132 | 193 |
|
|
133 | % else: | |
|
134 | ## pull requests/compare | |
|
135 | ${_('File Changes')} | |
|
136 | % endif | |
|
137 | ||
|
138 | </h2> | |
|
139 | 194 | </div> |
|
140 | ||
|
141 | 195 | %if diffset.has_hidden_changes: |
|
142 | 196 | <p class="empty_data">${_('Some changes may be hidden')}</p> |
|
143 | 197 | %elif not diffset.files: |
@@ -157,14 +211,14 b' collapse_all = len(diffset.files) > coll' | |||
|
157 | 211 | ## anchor with support of sticky header |
|
158 | 212 | <div class="anchor" id="a_${h.FID(filediff.raw_id, filediff.patch['filename'])}"></div> |
|
159 | 213 | |
|
160 | <input ${(collapse_all and 'checked' or '')} class="filediff-collapse-state" id="filediff-collapse-${id(filediff)}" type="checkbox" onchange="updateSticky();"> | |
|
214 | <input ${(collapse_all and 'checked' or '')} class="filediff-collapse-state collapse-${diffset_container_id}" id="filediff-collapse-${id(filediff)}" type="checkbox" onchange="updateSticky();"> | |
|
161 | 215 | <div |
|
162 | 216 | class="filediff" |
|
163 | 217 | data-f-path="${filediff.patch['filename']}" |
|
164 | 218 | data-anchor-id="${h.FID(filediff.raw_id, filediff.patch['filename'])}" |
|
165 | 219 | > |
|
166 | 220 | <label for="filediff-collapse-${id(filediff)}" class="filediff-heading"> |
|
167 | <div class="filediff-collapse-indicator"></div> | |
|
221 | <div class="filediff-collapse-indicator icon-"></div> | |
|
168 | 222 | ${diff_ops(filediff)} |
|
169 | 223 | </label> |
|
170 | 224 | |
@@ -292,25 +346,26 b' collapse_all = len(diffset.files) > coll' | |||
|
292 | 346 | display_state = '' |
|
293 | 347 | %> |
|
294 | 348 | <div class="filediffs filediff-outdated" style="${display_state}"> |
|
295 | <input ${(collapse_all and 'checked' or '')} class="filediff-collapse-state" id="filediff-collapse-${id(filename)}" type="checkbox" onchange="updateSticky();"> | |
|
349 | <input ${(collapse_all and 'checked' or '')} class="filediff-collapse-state collapse-${diffset_container_id}" id="filediff-collapse-${id(filename)}" type="checkbox" onchange="updateSticky();"> | |
|
296 | 350 | <div class="filediff" data-f-path="${filename}" id="a_${h.FID(filediff.raw_id, filename)}"> |
|
297 | 351 | <label for="filediff-collapse-${id(filename)}" class="filediff-heading"> |
|
298 | 352 | <div class="filediff-collapse-indicator"></div> |
|
353 | ||
|
299 | 354 | <span class="pill"> |
|
300 | 355 | ## file was deleted |
|
301 |
|
|
|
356 | ${filename} | |
|
302 | 357 | </span> |
|
303 |
<span class="pill-group" |
|
|
358 | <span class="pill-group pull-left" > | |
|
304 | 359 | ## file op, doesn't need translation |
|
305 | 360 | <span class="pill" op="removed">removed in this version</span> |
|
306 | 361 | </span> |
|
307 | 362 | <a class="pill filediff-anchor" href="#a_${h.FID(filediff.raw_id, filename)}">¶</a> |
|
308 |
<span class="pill-group |
|
|
363 | <span class="pill-group pull-right"> | |
|
309 | 364 | <span class="pill" op="deleted">-${comments_dict['stats']}</span> |
|
310 | 365 | </span> |
|
311 | 366 | </label> |
|
312 | 367 | |
|
313 | <table class="cb cb-diff-${c.user_session_attrs["diffmode"]} code-highlight ${over_lines_changed_limit and 'cb-collapsed' or ''}"> | |
|
368 | <table class="cb cb-diff-${c.user_session_attrs["diffmode"]} code-highlight ${(over_lines_changed_limit and 'cb-collapsed' or '')}"> | |
|
314 | 369 | <tr> |
|
315 | 370 | % if c.user_session_attrs["diffmode"] == 'unified': |
|
316 | 371 | <td></td> |
@@ -358,29 +413,30 b' from rhodecode.lib.diffs import NEW_FILE' | |||
|
358 | 413 | MOD_FILENODE, RENAMED_FILENODE, CHMOD_FILENODE, BIN_FILENODE, COPIED_FILENODE |
|
359 | 414 | %> |
|
360 | 415 | <span class="pill"> |
|
416 | <i class="icon-file-text"></i> | |
|
361 | 417 | %if filediff.source_file_path and filediff.target_file_path: |
|
362 | 418 | %if filediff.source_file_path != filediff.target_file_path: |
|
363 | 419 | ## file was renamed, or copied |
|
364 | 420 | %if RENAMED_FILENODE in filediff.patch['stats']['ops']: |
|
365 |
|
|
|
421 | ${filediff.target_file_path} ⬅ <del>${filediff.source_file_path}</del> | |
|
366 | 422 | <% final_path = filediff.target_file_path %> |
|
367 | 423 | %elif COPIED_FILENODE in filediff.patch['stats']['ops']: |
|
368 |
|
|
|
424 | ${filediff.target_file_path} ⬅ ${filediff.source_file_path} | |
|
369 | 425 | <% final_path = filediff.target_file_path %> |
|
370 | 426 | %endif |
|
371 | 427 | %else: |
|
372 | 428 | ## file was modified |
|
373 |
|
|
|
429 | ${filediff.source_file_path} | |
|
374 | 430 | <% final_path = filediff.source_file_path %> |
|
375 | 431 | %endif |
|
376 | 432 | %else: |
|
377 | 433 | %if filediff.source_file_path: |
|
378 | 434 | ## file was deleted |
|
379 |
|
|
|
435 | ${filediff.source_file_path} | |
|
380 | 436 | <% final_path = filediff.source_file_path %> |
|
381 | 437 | %else: |
|
382 | 438 | ## file was added |
|
383 |
|
|
|
439 | ${filediff.target_file_path} | |
|
384 | 440 | <% final_path = filediff.target_file_path %> |
|
385 | 441 | %endif |
|
386 | 442 | %endif |
@@ -389,7 +445,7 b' from rhodecode.lib.diffs import NEW_FILE' | |||
|
389 | 445 | ## anchor link |
|
390 | 446 | <a class="pill filediff-anchor" href="#a_${h.FID(filediff.raw_id, filediff.patch['filename'])}">¶</a> |
|
391 | 447 | |
|
392 |
<span class="pill-group |
|
|
448 | <span class="pill-group pull-right"> | |
|
393 | 449 | |
|
394 | 450 | ## ops pills |
|
395 | 451 | %if filediff.limited_diff: |
@@ -501,13 +557,11 b' from rhodecode.lib.diffs import NEW_FILE' | |||
|
501 | 557 | ${commentblock.comment_block(comment, inline=True)} |
|
502 | 558 | %endfor |
|
503 | 559 | % if comments and comments[-1].outdated: |
|
504 | <span class="btn btn-secondary cb-comment-add-button comment-outdated}" | |
|
505 | style="display: none;}"> | |
|
560 | <span class="btn btn-secondary cb-comment-add-button comment-outdated}" style="display: none;}"> | |
|
506 | 561 | ${_('Add another comment')} |
|
507 | 562 | </span> |
|
508 | 563 | % else: |
|
509 | <span onclick="return Rhodecode.comments.createComment(this)" | |
|
510 | class="btn btn-secondary cb-comment-add-button"> | |
|
564 | <span onclick="return Rhodecode.comments.createComment(this)" class="btn btn-secondary cb-comment-add-button"> | |
|
511 | 565 | ${_('Add another comment')} |
|
512 | 566 | </span> |
|
513 | 567 | % endif |
@@ -717,7 +771,8 b' def get_comments_for(diff_type, comments' | |||
|
717 | 771 | </button> |
|
718 | 772 | </%def> |
|
719 | 773 | |
|
720 |
<%def name="render_diffset_menu(diffset |
|
|
774 | <%def name="render_diffset_menu(diffset, range_diff_on=None)"> | |
|
775 | <% diffset_container_id = h.md5(diffset.target_ref) %> | |
|
721 | 776 | |
|
722 | 777 | <div id="diff-file-sticky" class="diffset-menu clearinner"> |
|
723 | 778 | ## auto adjustable |
@@ -725,22 +780,22 b' def get_comments_for(diff_type, comments' | |||
|
725 | 780 | <div class="sidebar__bar"> |
|
726 | 781 | <div class="pull-right"> |
|
727 | 782 | <div class="btn-group"> |
|
728 | ||
|
729 | ## DIFF OPTIONS via Select2 | |
|
730 |
< |
|
|
731 | ${h.hidden('diff_menu')} | |
|
783 | <a class="btn tooltip toggle-wide-diff" href="#toggle-wide-diff" onclick="toggleWideDiff(this); return false" title="${h.tooltip(_('Toggle wide diff'))}"> | |
|
784 | <i class="icon-wide-mode"></i> | |
|
785 | </a> | |
|
732 | 786 | </div> |
|
787 | <div class="btn-group"> | |
|
733 | 788 | |
|
734 | 789 | <a |
|
735 |
class="btn ${(c.user_session_attrs["diffmode"] == 'sideside' and 'btn- |
|
|
736 | title="${h.tooltip(_('View side by side'))}" | |
|
790 | class="btn ${(c.user_session_attrs["diffmode"] == 'sideside' and 'btn-active')} tooltip" | |
|
791 | title="${h.tooltip(_('View diff as side by side'))}" | |
|
737 | 792 | href="${h.current_route_path(request, diffmode='sideside')}"> |
|
738 | 793 | <span>${_('Side by Side')}</span> |
|
739 | 794 | </a> |
|
740 | 795 | |
|
741 | 796 | <a |
|
742 |
class="btn ${(c.user_session_attrs["diffmode"] == 'unified' and 'btn- |
|
|
743 | title="${h.tooltip(_('View unified'))}" href="${h.current_route_path(request, diffmode='unified')}"> | |
|
797 | class="btn ${(c.user_session_attrs["diffmode"] == 'unified' and 'btn-active')} tooltip" | |
|
798 | title="${h.tooltip(_('View diff as unified'))}" href="${h.current_route_path(request, diffmode='unified')}"> | |
|
744 | 799 | <span>${_('Unified')}</span> |
|
745 | 800 | </a> |
|
746 | 801 | |
@@ -760,20 +815,20 b' def get_comments_for(diff_type, comments' | |||
|
760 | 815 | </a> |
|
761 | 816 | % endif |
|
762 | 817 | </div> |
|
818 | <div class="btn-group"> | |
|
819 | ||
|
820 | <div class="pull-left"> | |
|
821 | ${h.hidden('diff_menu_{}'.format(diffset_container_id))} | |
|
822 | </div> | |
|
823 | ||
|
824 | </div> | |
|
763 | 825 | </div> |
|
764 | 826 | <div class="pull-left"> |
|
765 | 827 | <div class="btn-group"> |
|
766 | 828 | <div class="pull-left"> |
|
767 |
${h.hidden('file_filter |
|
|
829 | ${h.hidden('file_filter_{}'.format(diffset_container_id))} | |
|
768 | 830 | </div> |
|
769 | <a | |
|
770 | class="btn" | |
|
771 | href="#" | |
|
772 | onclick="$('input[class=filediff-collapse-state]').prop('checked', false); updateSticky(); return false">${_('Expand All Files')}</a> | |
|
773 | <a | |
|
774 | class="btn" | |
|
775 | href="#" | |
|
776 | onclick="$('input[class=filediff-collapse-state]').prop('checked', true); updateSticky(); return false">${_('Collapse All Files')}</a> | |
|
831 | ||
|
777 | 832 | </div> |
|
778 | 833 | </div> |
|
779 | 834 | </div> |
@@ -788,19 +843,19 b' def get_comments_for(diff_type, comments' | |||
|
788 | 843 | </div> |
|
789 | 844 | |
|
790 | 845 | % if diffset: |
|
791 | ||
|
792 | 846 | %if diffset.limited_diff: |
|
793 | 847 | <% file_placeholder = _ungettext('%(num)s file changed', '%(num)s files changed', diffset.changed_files) % {'num': diffset.changed_files} %> |
|
794 | 848 | %else: |
|
795 | <% file_placeholder = _ungettext('%(num)s file changed: %(linesadd)s inserted, ''%(linesdel)s deleted', '%(num)s files changed: %(linesadd)s inserted, %(linesdel)s deleted', diffset.changed_files) % {'num': diffset.changed_files, 'linesadd': diffset.lines_added, 'linesdel': diffset.lines_deleted}%> | |
|
849 | <% file_placeholder = h.literal(_ungettext('%(num)s file changed: <span class="op-added">%(linesadd)s inserted</span>, <span class="op-deleted">%(linesdel)s deleted</span>', '%(num)s files changed: <span class="op-added">%(linesadd)s inserted</span>, <span class="op-deleted">%(linesdel)s deleted</span>', | |
|
850 | diffset.changed_files) % {'num': diffset.changed_files, 'linesadd': diffset.lines_added, 'linesdel': diffset.lines_deleted}) %> | |
|
851 | ||
|
796 | 852 | %endif |
|
797 | 853 | ## case on range-diff placeholder needs to be updated |
|
798 | 854 | % if range_diff_on is True: |
|
799 | 855 | <% file_placeholder = _('Disabled on range diff') %> |
|
800 | 856 | % endif |
|
801 | 857 | |
|
802 | <script> | |
|
803 | ||
|
858 | <script type="text/javascript"> | |
|
804 | 859 | var feedFilesOptions = function (query, initialData) { |
|
805 | 860 | var data = {results: []}; |
|
806 | 861 | var isQuery = typeof query.term !== 'undefined'; |
@@ -826,14 +881,13 b' def get_comments_for(diff_type, comments' | |||
|
826 | 881 | query.callback(data); |
|
827 | 882 | }; |
|
828 | 883 | |
|
829 |
var |
|
|
830 | return function(data, escapeMarkup) { | |
|
884 | var selectionFormatter = function(data, escapeMarkup) { | |
|
831 | 885 |
|
|
832 |
|
|
|
833 |
|
|
|
886 | var tmpl = '<div><strong>{0}</strong></div>'.format(escapeMarkup(data['text'])); | |
|
887 | var pill = '<div class="pill-group" style="position: absolute; top:7px; right: 0">' + | |
|
834 | 888 |
|
|
835 | 889 |
|
|
836 |
|
|
|
890 | '</div>' | |
|
837 | 891 |
|
|
838 | 892 |
|
|
839 | 893 |
|
@@ -847,11 +901,20 b' def get_comments_for(diff_type, comments' | |||
|
847 | 901 | |
|
848 | 902 |
|
|
849 | 903 |
|
|
850 | ||
|
851 | }(result, escapeMarkup); | |
|
904 | }; | |
|
905 | var formatFileResult = function(result, container, query, escapeMarkup) { | |
|
906 | return selectionFormatter(result, escapeMarkup); | |
|
852 | 907 | }; |
|
853 | 908 | |
|
854 | var preloadFileFilterData = { | |
|
909 | var formatSelection = function (data, container) { | |
|
910 | return '${file_placeholder}' | |
|
911 | }; | |
|
912 | ||
|
913 | if (window.preloadFileFilterData === undefined) { | |
|
914 | window.preloadFileFilterData = {} | |
|
915 | } | |
|
916 | ||
|
917 | preloadFileFilterData["${diffset_container_id}"] = { | |
|
855 | 918 | results: [ |
|
856 | 919 | % for filediff in diffset.files: |
|
857 | 920 | {id:"a_${h.FID(filediff.raw_id, filediff.patch['filename'])}", |
@@ -861,35 +924,48 b' def get_comments_for(diff_type, comments' | |||
|
861 | 924 | ] |
|
862 | 925 | }; |
|
863 | 926 | |
|
864 | $(document).ready(function () { | |
|
865 | ||
|
866 | var fileFilter = $("#file_filter").select2({ | |
|
927 | var diffFileFilterId = "#file_filter_" + "${diffset_container_id}"; | |
|
928 | var diffFileFilter = $(diffFileFilterId).select2({ | |
|
867 | 929 |
|
|
868 | 930 |
|
|
869 | 'placeholder': "${file_placeholder}", | |
|
931 | ||
|
870 | 932 |
|
|
871 | 933 |
|
|
872 |
|
|
|
934 | data: preloadFileFilterData["${diffset_container_id}"], | |
|
873 | 935 |
|
|
874 |
|
|
|
936 | feedFilesOptions(query, preloadFileFilterData["${diffset_container_id}"]); | |
|
875 | 937 |
|
|
876 | formatResult: formatFileResult | |
|
938 | initSelection: function(element, callback) { | |
|
939 | callback({'init': true}); | |
|
940 | }, | |
|
941 | formatResult: formatFileResult, | |
|
942 | formatSelection: formatSelection | |
|
877 | 943 |
|
|
878 | 944 | |
|
879 | 945 |
|
|
880 |
|
|
|
946 | diffFileFilter.select2("enable", false); | |
|
881 | 947 |
|
|
882 | 948 | |
|
883 |
|
|
|
949 | $(diffFileFilterId).on('select2-selecting', function (e) { | |
|
950 | var idSelector = e.choice.id; | |
|
951 | ||
|
952 | // expand the container if we quick-select the field | |
|
953 | $('#'+idSelector).next().prop('checked', false); | |
|
954 | // hide the mast as we later do preventDefault() | |
|
955 | $("#select2-drop-mask").click(); | |
|
956 | ||
|
957 | window.location.hash = '#'+idSelector; | |
|
958 | updateSticky(); | |
|
959 | ||
|
884 | 960 |
|
|
885 | var selected = $('#file_filter').select2('data'); | |
|
886 | var idSelector = "#"+selected.id; | |
|
887 | window.location.hash = idSelector; | |
|
888 | // expand the container if we quick-select the field | |
|
889 | $(idSelector).next().prop('checked', false); | |
|
890 | updateSticky() | |
|
891 | 961 |
|
|
892 | 962 | |
|
963 | </script> | |
|
964 | % endif | |
|
965 | ||
|
966 | <script type="text/javascript"> | |
|
967 | $(document).ready(function () { | |
|
968 | ||
|
893 | 969 | var contextPrefix = _gettext('Context file: '); |
|
894 | 970 | ## sticky sidebar |
|
895 | 971 | var sidebarElement = document.getElementById('diff-file-sticky'); |
@@ -900,7 +976,7 b' def get_comments_for(diff_type, comments' | |||
|
900 | 976 | }); |
|
901 | 977 | sidebarElement.addEventListener('affixed.static.stickySidebar', function () { |
|
902 | 978 | // reset our file so it's not holding new value |
|
903 | $('.fpath-placeholder-text').html(contextPrefix) | |
|
979 | $('.fpath-placeholder-text').html(contextPrefix + ' - ') | |
|
904 | 980 | }); |
|
905 | 981 | |
|
906 | 982 | updateSticky = function () { |
@@ -908,16 +984,10 b' def get_comments_for(diff_type, comments' | |||
|
908 | 984 | Waypoint.refreshAll(); |
|
909 | 985 | }; |
|
910 | 986 | |
|
911 |
var animateText = |
|
|
987 | var animateText = function (fPath, anchorId) { | |
|
912 | 988 | fPath = Select2.util.escapeMarkup(fPath); |
|
913 | ||
|
914 | // animate setting the text | |
|
915 | var callback = function () { | |
|
916 | $('.fpath-placeholder-text').animate({'opacity': 1.00}, 200) | |
|
917 | 989 |
|
|
918 | 990 |
|
|
919 | $('.fpath-placeholder-text').animate({'opacity': 0.15}, 200, callback); | |
|
920 | }); | |
|
921 | 991 | |
|
922 | 992 | ## dynamic file waypoints |
|
923 | 993 | var setFPathInfo = function(fPath, anchorId){ |
@@ -925,6 +995,7 b' def get_comments_for(diff_type, comments' | |||
|
925 | 995 | }; |
|
926 | 996 | |
|
927 | 997 | var codeBlock = $('.filediff'); |
|
998 | ||
|
928 | 999 | // forward waypoint |
|
929 | 1000 | codeBlock.waypoint( |
|
930 | 1001 | function(direction) { |
@@ -932,7 +1003,9 b' def get_comments_for(diff_type, comments' | |||
|
932 | 1003 | setFPathInfo($(this.element).data('fPath'), $(this.element).data('anchorId')) |
|
933 | 1004 | } |
|
934 | 1005 | }, { |
|
935 |
offset: |
|
|
1006 | offset: function () { | |
|
1007 | return 70; | |
|
1008 | }, | |
|
936 | 1009 | context: '.fpath-placeholder' |
|
937 | 1010 | } |
|
938 | 1011 | ); |
@@ -945,26 +1018,26 b' def get_comments_for(diff_type, comments' | |||
|
945 | 1018 | } |
|
946 | 1019 | }, { |
|
947 | 1020 | offset: function () { |
|
948 | return -this.element.clientHeight + 90 | |
|
1021 | return -this.element.clientHeight + 90; | |
|
949 | 1022 | }, |
|
950 | 1023 | context: '.fpath-placeholder' |
|
951 | 1024 | } |
|
952 | 1025 | ); |
|
953 | 1026 | |
|
954 | var preloadDiffMenuData = { | |
|
955 | results: [ | |
|
956 | ## Wide diff mode | |
|
957 | { | |
|
958 | id: 1, | |
|
959 | text: _gettext('Toggle Wide Mode diff'), | |
|
960 | action: function () { | |
|
1027 | toggleWideDiff = function (el) { | |
|
961 | 1028 |
|
|
962 | 1029 |
|
|
963 | 1030 |
|
|
1031 | if (wide === true) { | |
|
1032 | $(el).addClass('btn-active'); | |
|
1033 | } else { | |
|
1034 | $(el).removeClass('btn-active'); | |
|
1035 | } | |
|
964 | 1036 |
|
|
965 |
|
|
|
966 | url: null, | |
|
967 | }, | |
|
1037 | }; | |
|
1038 | ||
|
1039 | var preloadDiffMenuData = { | |
|
1040 | results: [ | |
|
968 | 1041 | |
|
969 | 1042 | ## Whitespace change |
|
970 | 1043 | % if request.GET.get('ignorews', '') == '1': |
@@ -1006,26 +1079,43 b' def get_comments_for(diff_type, comments' | |||
|
1006 | 1079 | // get stored diff mode and pre-enable it |
|
1007 | 1080 | if (templateContext.session_attrs.wide_diff_mode === "true") { |
|
1008 | 1081 | Rhodecode.comments.toggleWideMode(null); |
|
1082 | $('.toggle-wide-diff').addClass('btn-active'); | |
|
1009 | 1083 | } |
|
1010 | 1084 | |
|
1011 | $("#diff_menu").select2({ | |
|
1085 | var diffMenuId = "#diff_menu_" + "${diffset_container_id}"; | |
|
1086 | $(diffMenuId).select2({ | |
|
1012 | 1087 | minimumResultsForSearch: -1, |
|
1013 | containerCssClass: "drop-menu", | |
|
1088 | containerCssClass: "drop-menu-no-width", | |
|
1014 | 1089 | dropdownCssClass: "drop-menu-dropdown", |
|
1015 | 1090 | dropdownAutoWidth: true, |
|
1016 | 1091 | data: preloadDiffMenuData, |
|
1017 |
placeholder: "${_(' |
|
|
1092 | placeholder: "${_('...')}", | |
|
1018 | 1093 | }); |
|
1019 |
$( |
|
|
1094 | $(diffMenuId).on('select2-selecting', function (e) { | |
|
1020 | 1095 | e.choice.action(); |
|
1021 | 1096 | if (e.choice.url !== null) { |
|
1022 | 1097 | window.location = e.choice.url |
|
1023 | 1098 | } |
|
1024 | 1099 | }); |
|
1025 | ||
|
1100 | toggleExpand = function (el, diffsetEl) { | |
|
1101 | var el = $(el); | |
|
1102 | if (el.hasClass('collapsed')) { | |
|
1103 | $('.filediff-collapse-state.collapse-{0}'.format(diffsetEl)).prop('checked', false); | |
|
1104 | el.removeClass('collapsed'); | |
|
1105 | el.html( | |
|
1106 | '<i class="icon-minus-squared-alt icon-no-margin"></i>' + | |
|
1107 | _gettext('Collapse all files')); | |
|
1108 | } | |
|
1109 | else { | |
|
1110 | $('.filediff-collapse-state.collapse-{0}'.format(diffsetEl)).prop('checked', true); | |
|
1111 | el.addClass('collapsed'); | |
|
1112 | el.html( | |
|
1113 | '<i class="icon-plus-squared-alt icon-no-margin"></i>' + | |
|
1114 | _gettext('Expand all files')); | |
|
1115 | } | |
|
1116 | updateSticky() | |
|
1117 | } | |
|
1026 | 1118 | }); |
|
1027 | ||
|
1028 | 1119 | </script> |
|
1029 | % endif | |
|
1030 | 1120 | |
|
1031 | 1121 | </%def> |
@@ -39,7 +39,7 b'' | |||
|
39 | 39 | </script> |
|
40 | 40 | |
|
41 | 41 | <div> |
|
42 |
<div |
|
|
42 | <div> | |
|
43 | 43 | <%include file='files_pjax.mako'/> |
|
44 | 44 | </div> |
|
45 | 45 | </div> |
@@ -49,7 +49,7 b'' | |||
|
49 | 49 | </div> |
|
50 | 50 | |
|
51 | 51 | <div class="table"> |
|
52 |
<div |
|
|
52 | <div> | |
|
53 | 53 | |
|
54 | 54 | <div id="codeblock" class="codeblock"> |
|
55 | 55 | <div class="editor-items"> |
@@ -50,7 +50,7 b'' | |||
|
50 | 50 | </div> |
|
51 | 51 | |
|
52 | 52 | <div class="table"> |
|
53 |
<div |
|
|
53 | <div> | |
|
54 | 54 | |
|
55 | 55 | <div id="codeblock" class="codeblock"> |
|
56 | 56 | <div class="editor-items"> |
@@ -31,7 +31,6 b'' | |||
|
31 | 31 | <p>${_('File last commit')}</p> |
|
32 | 32 | <div class="right-label-summary"> |
|
33 | 33 | <code><a href="${h.route_path('repo_commit',repo_name=c.repo_name,commit_id=c.file_last_commit.raw_id)}">${h.show_id(c.file_last_commit)}</a></code> |
|
34 | ||
|
35 | 34 | ${file_base.refs(c.file_last_commit)} |
|
36 | 35 | </div> |
|
37 | 36 | </div> |
@@ -40,8 +39,11 b'' | |||
|
40 | 39 | |
|
41 | 40 | <div class="right-content"> |
|
42 | 41 | <div data-toggle="summary-details"> |
|
43 |
<div class="tags |
|
|
44 | <code><a href="${h.route_path('repo_commit',repo_name=c.repo_name,commit_id=c.commit.raw_id)}">${h.show_id(c.commit)}</a></code> | |
|
42 | <div class="tags tags-main"> | |
|
43 | <code> | |
|
44 | <a href="${h.route_path('repo_commit',repo_name=c.repo_name,commit_id=c.commit.raw_id)}">${h.show_id(c.commit)}</a> | |
|
45 | </code> | |
|
46 | <i class="tooltip icon-clipboard clipboard-action" data-clipboard-text="${c.commit.raw_id}" title="${_('Copy the full commit id')}"></i> | |
|
45 | 47 | ${file_base.refs(c.commit)} |
|
46 | 48 | </div> |
|
47 | 49 | </div> |
@@ -25,11 +25,12 b'' | |||
|
25 | 25 | </div> |
|
26 | 26 | |
|
27 | 27 | <div class="right-content"> |
|
28 |
<div class="tags |
|
|
28 | <div class="tags"> | |
|
29 | 29 | <code> |
|
30 | 30 | <a href="${h.route_path('repo_commit',repo_name=c.repo_name,commit_id=c.commit.raw_id)}">${h.show_id(c.commit)}</a> |
|
31 | 31 | </code> |
|
32 | 32 | |
|
33 | <i class="tooltip icon-clipboard clipboard-action" data-clipboard-text="${c.commit.raw_id}" title="${_('Copy the full commit id')}"></i> | |
|
33 | 34 | ${file_base.refs(c.commit)} |
|
34 | 35 | </div> |
|
35 | 36 | </div> |
General Comments 0
You need to be logged in to leave comments.
Login now