diff --git a/app/coffee/modules/common/components.coffee b/app/coffee/modules/common/components.coffee index 8f3c04c8..a74f5cba 100644 --- a/app/coffee/modules/common/components.coffee +++ b/app/coffee/modules/common/components.coffee @@ -396,7 +396,7 @@ module.directive("tgBlockButton", ["$rootScope", "$tgLoading", BlockButtonDirect DeleteButtonDirective = ($repo, $confirm, $navurls, $location) -> template = _.template(""" - Delete + Delete """) link = ($scope, $el, $attrs, $model) -> @@ -439,17 +439,15 @@ module.directive("tgDeleteButton", ["$tgRepo", "$tgConfirm", "$tgNavUrls", "$tgL EditableSubjectDirective = ($rootscope, $repo, $confirm, $loading) -> viewTemplate = _.template(""" - <%- item.subject %> - <% if (canEdit) { %> - - <% } %> + <%- item.subject %> + <% if (canEdit) { %> + + <% } %> """) editTemplate = _.template(""" - -
""") link = ($scope, $el, $attrs, $model) -> @@ -528,9 +526,7 @@ EditableDescriptionDirective = ($rootscope, $repo, $confirm, $compile, $loading) - + """) link = ($scope, $el, $attrs, $model) -> diff --git a/app/coffee/modules/common/tags.coffee b/app/coffee/modules/common/tags.coffee index 5ba46b6b..c2e242ba 100644 --- a/app/coffee/modules/common/tags.coffee +++ b/app/coffee/modules/common/tags.coffee @@ -95,19 +95,20 @@ TagLineDirective = ($rootscope, $log, $rs, $tgrepo, $confirm) -> # Main directive template (rendered by angular) template = """ - + + """ # Tags template (rendered manually using lodash) templateTags = _.template(""" <% _.each(tags, function(tag) { %> - + <% }); %>""") renderTags = ($el, tags, editable, tagsColors) -> @@ -201,6 +202,12 @@ TagLineDirective = ($rootscope, $log, $rs, $tgrepo, $confirm) -> $el.on "click", ".save", saveInputTag + $el.on "click", ".add-tag", (event) -> + event.preventDefault() + target = angular.element(event.currentTarget) + target.hide() + target.siblings('input').removeClass('hidden') + $el.on "click", ".icon-delete", (event) -> event.preventDefault() target = angular.element(event.currentTarget) diff --git a/app/styles/components/tag.scss b/app/styles/components/tag.scss index 3797a2e7..22a01e09 100644 --- a/app/styles/components/tag.scss +++ b/app/styles/components/tag.scss @@ -33,7 +33,6 @@ vertical-align: middle; } input { - display: inline-block; padding: .4rem; width: 14rem; } diff --git a/app/styles/layout/us-detail.scss b/app/styles/layout/us-detail.scss index 88459e82..5fb06ab3 100644 --- a/app/styles/layout/us-detail.scss +++ b/app/styles/layout/us-detail.scss @@ -86,8 +86,10 @@ display: inline-block; line-height: 2.2rem; padding-right: 1rem; + width: 100%; } - .save { + .icon-edit, + .icon-floppy { @extend %large; color: $gray-light; margin-left: .5rem; @@ -153,6 +155,17 @@ } } +.tags-block { + .icon-plus { + @extend %large; + color: $gray-light; + vertical-align: top; + &:hover { + color: $fresh-taiga; + } + } +} + .us-content { textarea { background: $white;