diff options
author | Dimitrie Hoekstra <dimitriehoekstra@gmail.com> | 2016-11-29 17:52:36 +0100 |
---|---|---|
committer | Dimitrie Hoekstra <dimitriehoekstra@gmail.com> | 2016-11-29 17:52:36 +0100 |
commit | d2d866a2ef516d51e4ba7f00ded3226484185d10 (patch) | |
tree | 442a2d3340658210f63bff7dccb62ada418e8146 | |
parent | a7a3636de2a82b34cf057207bd3ad419f3964b7e (diff) | |
download | gitlab-ce-create-collapsed-todo-button.tar.gz |
added initial todo functionalitycreate-collapsed-todo-button
-rw-r--r-- | app/assets/stylesheets/pages/issuable.scss | 2 | ||||
-rw-r--r-- | app/views/shared/issuable/_sidebar.html.haml | 9 |
2 files changed, 10 insertions, 1 deletions
diff --git a/app/assets/stylesheets/pages/issuable.scss b/app/assets/stylesheets/pages/issuable.scss index 773155fe80a..0cfb705dcb4 100644 --- a/app/assets/stylesheets/pages/issuable.scss +++ b/app/assets/stylesheets/pages/issuable.scss @@ -206,7 +206,7 @@ width: $sidebar_collapsed_width; padding-top: 0; - .block { + .project-todo, .block { width: $sidebar_collapsed_width - 2px; margin-left: -19px; padding: 15px 0 0; diff --git a/app/views/shared/issuable/_sidebar.html.haml b/app/views/shared/issuable/_sidebar.html.haml index 02427650219..3214b4d475e 100644 --- a/app/views/shared/issuable/_sidebar.html.haml +++ b/app/views/shared/issuable/_sidebar.html.haml @@ -18,6 +18,15 @@ = icon('spin spinner', class: 'hidden js-issuable-todo-loading') = form_for [@project.namespace.becomes(Namespace), @project, issuable], remote: true, format: :json, html: {class: 'issuable-context-form inline-update js-issuable-update'} do |f| + - if current_user + .project-todo + .sidebar-collapsed-icon.dont-change-state.js-issuable-todo{ type: "div", aria: { label: (todo.nil? ? icon('bell-o') : icon('bell')) }, data: { todo_text: icon('bell-o'), mark_text: icon('bell'), issuable_id: issuable.id, issuable_type: issuable.class.name.underscore, url: namespace_project_todos_path(@project.namespace, @project), delete_path: (dashboard_todo_path(todo) if todo) } } + - if todo + = icon('bell') + - else + = icon('bell-o') + = icon('spin spinner', class: 'hidden js-issuable-todo-loading') + .block.assignee .sidebar-collapsed-icon.sidebar-collapsed-user{data: {toggle: "tooltip", placement: "left", container: "body"}, title: (issuable.assignee.name if issuable.assignee)} - if issuable.assignee |