Procházet zdrojové kódy

Add a button to allow inline removal of tags.

Paulo Reis před 9 roky
rodič
revize
2708fdf159

+ 11 - 5
services/web/app/views/project/list/project-list.pug

@@ -152,11 +152,17 @@
 								span(
 									ng-controller="TagListController"
 								)
-									a.label.label-default.tag-label(
-										href,
-										ng-repeat='tag in project.tags',
-										ng-click="selectTag(tag)"
-									) {{tag.name}}
+									.tag-label(
+										ng-repeat='tag in project.tags'
+									)
+										a.label.label-default.tag-label-name(
+											href,
+											ng-click="selectTag(tag)"
+										) {{tag.name}} 
+										a.label.label-default.tag-label-remove(
+											href
+										) ×
+
 						.col-xs-2
 							span.owner {{ownerName()}}
 						.col-xs-4

+ 16 - 2
services/web/public/stylesheets/app/project-list.less

@@ -260,10 +260,24 @@ ul.project-list {
 			margin-left: @line-height-computed / 4;
 			position: relative;
 			top: -2px;
-			padding-top: 0.25em;
 			display: inline-block;
-			color: white;
 		}
+			.tag-label-name,
+			.tag-label-remove {
+				display: inline-block;
+				padding-top: 0.25em;
+				color: #FFF;
+			}
+			.tag-label-name {
+				padding-right: 0.3em;
+				border-top-right-radius: 0;
+				border-bottom-right-radius: 0;	
+			}
+			.tag-label-remove {
+				padding-left: 0.3em;
+				border-top-left-radius: 0;
+				border-bottom-left-radius: 0;
+			}
 	}
 	i.tablesort {
 		padding-left: 8px;