Implementing color selection for us status

stable
Alejandro Alonso 2014-07-22 15:14:01 +02:00
parent 775defad3f
commit da101a1247
1 changed files with 7 additions and 3 deletions

View File

@ -234,9 +234,13 @@ ProjectUsStatusDirective = ($log, $repo, $confirm, $location) ->
status = target.scope().status
$el.find(".select-color").hide()
target.siblings(".select-color").show()
#body = angular.element("body")
#body.one "click", (event) ->
# $el.find(".select-color").hide()
# Hide when click outside
body = angular.element("body")
body.on "click", (event) =>
if angular.element(event.target).parent(".select-color").length == 0
$el.find(".select-color").hide()
body.ubind("click")
$el.on "click", ".select-color .color", (event) ->
# Selecting one color on color selector