From 8a4dad6eed052405dd73a2b13548d7dac75aedf4 Mon Sep 17 00:00:00 2001 From: Suwon Chae Date: Mon, 23 Mar 2015 23:07:10 +0900 Subject: [PATCH 1/3] issue: fix wrong contextual message & key --- app/views/issue/view.scala.html | 4 ++-- conf/messages | 2 ++ conf/messages.ko-KR | 3 ++- 3 files changed, 6 insertions(+), 3 deletions(-) diff --git a/app/views/issue/view.scala.html b/app/views/issue/view.scala.html index 97a89113f..e48e2e55e 100644 --- a/app/views/issue/view.scala.html +++ b/app/views/issue/view.scala.html @@ -110,9 +110,9 @@ } diff --git a/conf/messages b/conf/messages index 99d1f45f0..54010750d 100644 --- a/conf/messages +++ b/conf/messages @@ -274,6 +274,7 @@ issue.state.closed = Closed issue.state.enrolled = Status entered issue.state.open = Open issue.unvote.description = Click here if you no longer agree with this issue. +issue.unwatch = unwatch this issue issue.unwatch.start = You will no longer get notifications about this issue issue.update.assignee.id = Update assignee issue.update.attachLabel = Attach label @@ -286,6 +287,7 @@ issue.vote = Agree issue.vote.description = Click here if you agree with this issue. issue.voters = People who agree with this issue.voters.more = and {0} others +issue.watch = watch issue.watch.start =Now you will get notifications about this issue label = Label label.add = Add label diff --git a/conf/messages.ko-KR b/conf/messages.ko-KR index 3baea9ff8..e8abff195 100644 --- a/conf/messages.ko-KR +++ b/conf/messages.ko-KR @@ -274,6 +274,7 @@ issue.state.closed = 닫힘 issue.state.enrolled = 등록 issue.state.open = 열림 issue.unvote.description = 공감을 취소하려면 버튼을 누릅니다. +issue.unwatch = 이슈 그만지켜보기 issue.unwatch.start = 이제 이 이슈에 관한 알림을 받지 않습니다 issue.update.assignee.id = 담당자 변경 issue.update.attachLabel = 라벨 추가 @@ -286,6 +287,7 @@ issue.vote = 공감 issue.vote.description = 이 이슈에 공감하기 위해 버튼을 누릅니다. issue.voters = 이 이슈에 공감하는 사람들 issue.voters.more = 외 {0}명 +issue.watch = 이슈 지켜보기 issue.watch.start = 이제 이 이슈에 관한 알림을 받습니다 label = 라벨 label.add = 라벨 추가 @@ -610,7 +612,6 @@ project.transfer.this = 프로젝트를 이관합니다. project.unwatch = 그만 지켜보기 project.unwatch.start = 프로젝트를 더 이상 지켜보지 않습니다 project.vcs = 코드 저장소 타입 -project.watch = 지켜보기 project.watching = 지켜보기 중 project.you.are.not.watching = {0} 프로젝트를 지켜보고 있지 않습니다. project.you.are.watching = {0} 프로젝트를 지켜보는 중입니다. From e4618735f6fdc5473cc723d371edc2dc9f7d0f7c Mon Sep 17 00:00:00 2001 From: Suwon Chae Date: Mon, 23 Mar 2015 23:10:03 +0900 Subject: [PATCH 2/3] project: show project watcher count --- app/assets/stylesheets/less/_page.less | 19 +++++ app/assets/stylesheets/less/_yobiUI.less | 17 ++++- app/views/project/header.scala.html | 88 +++++++++++++----------- conf/messages | 3 +- conf/messages.ko-KR | 2 + 5 files changed, 85 insertions(+), 44 deletions(-) diff --git a/app/assets/stylesheets/less/_page.less b/app/assets/stylesheets/less/_page.less index bc900211a..6f0a645ec 100644 --- a/app/assets/stylesheets/less/_page.less +++ b/app/assets/stylesheets/less/_page.less @@ -6204,3 +6204,22 @@ div.diff-body[data-outdated="true"] tr:hover .icon-comment { vertical-align: middle; } +.watcher-count{ + opacity: 0.9 !important; + border: 0 !important; + text-shadow: none; +} + +.watch-on { + opacity: 1 !important; + background-color: #b6da54 !important; +} + +.nofocus{ + outline:0 !important; +} + +.watch-btn > button { + padding: 4px 10px; +} + diff --git a/app/assets/stylesheets/less/_yobiUI.less b/app/assets/stylesheets/less/_yobiUI.less index bc306dbb2..81fd856d2 100644 --- a/app/assets/stylesheets/less/_yobiUI.less +++ b/app/assets/stylesheets/less/_yobiUI.less @@ -717,7 +717,7 @@ span.issue-label { } &.ybtn-small { - padding: 2px 10px !important; + padding: 3px 10px !important; font-size: 13px !important; } @@ -1355,3 +1355,18 @@ span.issue-label { padding: 4px 4px 0px 4px; color: 666; } + +.down-arrow{ + &:after { + margin-left: 5px; + display: inline-block; + vertical-align: middle !important; + width: 0; + .transition(all 0.3s ease); + height: 0; + border-top: 4px solid @yobi-inverse; + border-right: 4px solid transparent; + border-left: 4px solid transparent; + content: ""; + } +} diff --git a/app/views/project/header.scala.html b/app/views/project/header.scala.html index 731d02fcb..a5fa5a3eb 100644 --- a/app/views/project/header.scala.html +++ b/app/views/project/header.scala.html @@ -27,6 +27,24 @@ @import models.enumeration.Operation @import controllers.UserApp +@watchHelpMessages = { +
+

@Messages("notification.help")

+
    +
  • @Messages("notification.help.new")
  • +
  • @Messages("notification.help.new.comment")
  • +
  • @Messages("notification.help.update.issue")
  • +
  • @Messages("notification.help.update.pullrequest")
  • +
+
+} + +@amIWatching = @{ + if(User.isWatching(project)) { + "watch-on" + } +} +
@@ -94,52 +112,38 @@ } @if(isAllowed(UserApp.currentUser(), project.asResource(), Operation.WATCH)) {
  • +
  • } diff --git a/conf/messages b/conf/messages index 54010750d..8789ab520 100644 --- a/conf/messages +++ b/conf/messages @@ -287,7 +287,7 @@ issue.vote = Agree issue.vote.description = Click here if you agree with this issue. issue.voters = People who agree with this issue.voters.more = and {0} others -issue.watch = watch +issue.watch = watch this issue issue.watch.start =Now you will get notifications about this issue label = Label label.add = Add label @@ -613,6 +613,7 @@ project.unwatch = Unwatch project.unwatch.start = Notifications of this project has muted project.vcs = Repository type project.watch = Watch +project.watcher.number = number of watcher project.watching = Watching project.you.are.not.watching = You are not watching {0} project. project.you.are.watching = You are watching {0} project. diff --git a/conf/messages.ko-KR b/conf/messages.ko-KR index e8abff195..db400df33 100644 --- a/conf/messages.ko-KR +++ b/conf/messages.ko-KR @@ -612,6 +612,8 @@ project.transfer.this = 프로젝트를 이관합니다. project.unwatch = 그만 지켜보기 project.unwatch.start = 프로젝트를 더 이상 지켜보지 않습니다 project.vcs = 코드 저장소 타입 +project.watch = 프로젝트 지켜보기 +project.watcher.number = 지켜보는 사람 수 project.watching = 지켜보기 중 project.you.are.not.watching = {0} 프로젝트를 지켜보고 있지 않습니다. project.you.are.watching = {0} 프로젝트를 지켜보는 중입니다. From 1130559c080cb3c87d161d5141b97779e50d02c7 Mon Sep 17 00:00:00 2001 From: Suwon Chae Date: Sat, 25 Apr 2015 17:59:21 +0900 Subject: [PATCH 3/3] project: add notification setting button at project watch/unwatch menu --- app/assets/stylesheets/less/_page.less | 1 - app/views/project/header.scala.html | 11 +++++++++-- 2 files changed, 9 insertions(+), 3 deletions(-) diff --git a/app/assets/stylesheets/less/_page.less b/app/assets/stylesheets/less/_page.less index 6f0a645ec..28e71796b 100644 --- a/app/assets/stylesheets/less/_page.less +++ b/app/assets/stylesheets/less/_page.less @@ -6211,7 +6211,6 @@ div.diff-body[data-outdated="true"] tr:hover .icon-comment { } .watch-on { - opacity: 1 !important; background-color: #b6da54 !important; } diff --git a/app/views/project/header.scala.html b/app/views/project/header.scala.html index a5fa5a3eb..baef3c15b 100644 --- a/app/views/project/header.scala.html +++ b/app/views/project/header.scala.html @@ -119,8 +119,11 @@
    @Messages("project.you.are.watching", project.name)
    @watchHelpMessages