Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
李少辉-开发者
gitlab-foss
提交
1dc00173
G
gitlab-foss
项目概览
李少辉-开发者
/
gitlab-foss
通知
15
Star
0
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
G
gitlab-foss
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
前往新版Gitcode,体验更适合开发者的 AI 搜索 >>
未验证
提交
1dc00173
编写于
6月 08, 2016
作者:
D
Dmitriy Zaporozhets
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
Cleanup and imrpove issue/mr buttons
Signed-off-by:
N
Dmitriy Zaporozhets
<
dmitriy.zaporozhets@gmail.com
>
上级
366ad9ff
变更
8
隐藏空白更改
内联
并排
Showing
8 changed file
with
27 addition
and
20 deletion
+27
-20
app/assets/stylesheets/framework/buttons.scss
app/assets/stylesheets/framework/buttons.scss
+13
-2
app/assets/stylesheets/framework/variables.scss
app/assets/stylesheets/framework/variables.scss
+3
-0
app/views/projects/issues/_new_branch.html.haml
app/views/projects/issues/_new_branch.html.haml
+6
-6
app/views/projects/issues/index.html.haml
app/views/projects/issues/index.html.haml
+0
-1
app/views/projects/issues/show.html.haml
app/views/projects/issues/show.html.haml
+2
-4
app/views/projects/merge_requests/_show.html.haml
app/views/projects/merge_requests/_show.html.haml
+1
-3
app/views/projects/merge_requests/index.html.haml
app/views/projects/merge_requests/index.html.haml
+0
-1
app/views/projects/merge_requests/show/_mr_title.html.haml
app/views/projects/merge_requests/show/_mr_title.html.haml
+2
-3
未找到文件。
app/assets/stylesheets/framework/buttons.scss
浏览文件 @
1dc00173
...
...
@@ -142,15 +142,26 @@
}
&
.btn-grouped
{
margin-right
:
7px
;
margin-right
:
$btn-side-margin
;
float
:
left
;
&
.inline
{
float
:
none
;
}
&
:last-child
{
margin-right
:
0
;
}
&
.btn-sm
{
margin-right
:
$btn-sm-side-margin
;
}
&
.btn-xs
{
margin-right
:
3px
;
margin-right
:
$btn-xs-side-margin
;
}
}
&
.disabled
{
pointer-events
:
auto
!
important
;
}
...
...
app/assets/stylesheets/framework/variables.scss
浏览文件 @
1dc00173
...
...
@@ -79,6 +79,9 @@ $provider-btn-not-active-color: #4688f1;
$link-underline-blue
:
#4a8bee
;
$layout-link-gray
:
#7e7c7c
;
$todo-alert-blue
:
#428bca
;
$btn-side-margin
:
7px
;
$btn-sm-side-margin
:
5px
;
$btn-xs-side-margin
:
5px
;
/*
* Color schema
...
...
app/views/projects/issues/_new_branch.html.haml
浏览文件 @
1dc00173
-
if
can?
(
current_user
,
:push_code
,
@project
)
.pull-right
#new-branch
{
'data-path'
=>
can_create_branch_namespace_project_issue_path
(
@project
.
namespace
,
@project
,
@issue
)}
=
link_to
namespace_project_branches_path
(
@project
.
namespace
,
@project
,
branch_name:
@issue
.
to_branch_name
,
issue_iid:
@issue
.
iid
),
method: :post
,
class:
'btn has-tooltip'
,
title:
@issue
.
to_branch_name
,
disabled:
'disabled'
do
=
link_to
namespace_project_branches_path
(
@project
.
namespace
,
@project
,
branch_name:
@issue
.
to_branch_name
,
issue_iid:
@issue
.
iid
),
method: :post
,
class:
'btn has-tooltip'
,
title:
@issue
.
to_branch_name
,
disabled:
'disabled'
do
.checking
%i
.fa.fa-spinner.fa-spin
=
icon
(
'spinner spin'
)
Checking branches
.available
(
style=
"display: none"
)
%i
.fa.fa-code-fork
.available.hide
New branch
.unavailable
(
style=
"display: none"
)
%i
.fa.fa-exclamation-triangle
.unavailable
.hide
=
icon
(
'exclamation-triangle'
)
New branch unavailable
app/views/projects/issues/index.html.haml
浏览文件 @
1dc00173
...
...
@@ -15,7 +15,6 @@
=
render
'shared/issuable/search_form'
,
path:
namespace_project_issues_path
(
@project
.
namespace
,
@project
)
-
if
can?
current_user
,
:create_issue
,
@project
=
link_to
new_namespace_project_issue_path
(
@project
.
namespace
,
@project
,
issue:
{
assignee_id:
@issuable_finder
.
assignee
.
try
(
:id
),
milestone_id:
@issuable_finder
.
milestones
.
try
(
:first
).
try
(
:id
)
}),
class:
"btn btn-new"
,
title:
"New Issue"
,
id:
"new_issue_link"
do
=
icon
(
'plus'
)
New Issue
=
render
'shared/issuable/filter'
,
type: :issues
...
...
app/views/projects/issues/show.html.haml
浏览文件 @
1dc00173
...
...
@@ -39,13 +39,11 @@
=
link_to
'Edit'
,
edit_namespace_project_issue_path
(
@project
.
namespace
,
@project
,
@issue
)
-
if
can?
(
current_user
,
:create_issue
,
@project
)
=
link_to
new_namespace_project_issue_path
(
@project
.
namespace
,
@project
),
class:
'hidden-xs hidden-sm btn btn-grouped new-issue-link btn-success'
,
title:
'New issue'
,
id:
'new_issue_link'
do
=
icon
(
'plus'
)
New issue
-
if
can?
(
current_user
,
:update_issue
,
@issue
)
=
link_to
'Reopen issue'
,
issue_path
(
@issue
,
issue:
{
state_event: :reopen
},
status_only:
true
,
format:
'json'
),
data:
{
no_turbolink:
true
},
class:
"hidden-xs hidden-sm btn btn-gr
ay btn-gr
ouped btn-reopen
#{
issue_button_visibility
(
@issue
,
false
)
}
"
,
title:
'Reopen issue'
=
link_to
'Reopen issue'
,
issue_path
(
@issue
,
issue:
{
state_event: :reopen
},
status_only:
true
,
format:
'json'
),
data:
{
no_turbolink:
true
},
class:
"hidden-xs hidden-sm btn btn-grouped btn-reopen
#{
issue_button_visibility
(
@issue
,
false
)
}
"
,
title:
'Reopen issue'
=
link_to
'Close issue'
,
issue_path
(
@issue
,
issue:
{
state_event: :close
},
status_only:
true
,
format:
'json'
),
data:
{
no_turbolink:
true
},
class:
"hidden-xs hidden-sm btn btn-grouped btn-close
#{
issue_button_visibility
(
@issue
,
true
)
}
"
,
title:
'Close issue'
=
link_to
edit_namespace_project_issue_path
(
@project
.
namespace
,
@project
,
@issue
),
class:
'hidden-xs hidden-sm btn btn-gray btn-grouped issuable-edit'
do
=
icon
(
'pencil-square-o'
)
=
link_to
edit_namespace_project_issue_path
(
@project
.
namespace
,
@project
,
@issue
),
class:
'hidden-xs hidden-sm btn btn-grouped issuable-edit'
do
Edit
...
...
app/views/projects/merge_requests/_show.html.haml
浏览文件 @
1dc00173
...
...
@@ -14,13 +14,11 @@
-
if
@merge_request
.
open?
.pull-right
-
if
@merge_request
.
source_branch_exists?
=
link_to
"#modal_merge_info"
,
class:
"btn btn-sm"
,
"data-toggle"
=>
"modal"
do
=
icon
(
'cloud-download fw'
)
=
link_to
"#modal_merge_info"
,
class:
"btn inline btn-grouped btn-sm"
,
"data-toggle"
=>
"modal"
do
Check out branch
%span
.dropdown
%a
.btn.btn-sm.dropdown-toggle
{
data:
{
toggle: :dropdown
}
}
=
icon
(
'download'
)
Download as
%span
.caret
%ul
.dropdown-menu
...
...
app/views/projects/merge_requests/index.html.haml
浏览文件 @
1dc00173
...
...
@@ -10,7 +10,6 @@
-
merge_project
=
can?
(
current_user
,
:create_merge_request
,
@project
)
?
@project
:
(
current_user
&&
current_user
.
fork_of
(
@project
))
-
if
merge_project
=
link_to
new_namespace_project_merge_request_path
(
merge_project
.
namespace
,
merge_project
),
class:
"btn btn-new"
,
title:
"New Merge Request"
do
=
icon
(
'plus'
)
New Merge Request
=
render
'shared/issuable/filter'
,
type: :merge_requests
...
...
app/views/projects/merge_requests/show/_mr_title.html.haml
浏览文件 @
1dc00173
...
...
@@ -26,7 +26,6 @@
%li
=
link_to
'Edit'
,
edit_namespace_project_merge_request_path
(
@project
.
namespace
,
@project
,
@merge_request
),
class:
'issuable-edit'
=
link_to
'Close'
,
merge_request_path
(
@merge_request
,
merge_request:
{
state_event: :close
}),
method: :put
,
class:
"hidden-xs hidden-sm btn btn-grouped btn-close
#{
issue_button_visibility
(
@merge_request
,
true
)
}
"
,
title:
'Close merge request'
=
link_to
'Reopen'
,
merge_request_path
(
@merge_request
,
merge_request:
{
state_event: :reopen
}),
method: :put
,
class:
"hidden-xs hidden-sm btn btn-gray btn-grouped btn-reopen reopen-mr-link
#{
issue_button_visibility
(
@merge_request
,
false
)
}
"
,
title:
'Reopen merge request'
=
link_to
edit_namespace_project_merge_request_path
(
@project
.
namespace
,
@project
,
@merge_request
),
class:
"hidden-xs hidden-sm btn btn-gray btn-grouped issuable-edit"
do
=
icon
(
'pencil-square-o'
)
=
link_to
'Reopen'
,
merge_request_path
(
@merge_request
,
merge_request:
{
state_event: :reopen
}),
method: :put
,
class:
"hidden-xs hidden-sm btn btn-grouped btn-reopen reopen-mr-link
#{
issue_button_visibility
(
@merge_request
,
false
)
}
"
,
title:
'Reopen merge request'
=
link_to
edit_namespace_project_merge_request_path
(
@project
.
namespace
,
@project
,
@merge_request
),
class:
"hidden-xs hidden-sm btn btn-grouped issuable-edit"
do
Edit
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录