BigW Consortium Gitlab
Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
G
gitlab-ce
Project
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Commits
Issue Boards
Open sidebar
Forest Godfrey
gitlab-ce
Commits
4fb49156
Commit
4fb49156
authored
Aug 25, 2017
by
Clement Ho
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch '35721-auth-style-confirmation' into 'master'
Authorizations regarding OAuth - style confirmation Closes #35721 See merge request !13691
parents
c842e29a
5167a76f
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
54 additions
and
37 deletions
+54
-37
modal.scss
app/assets/stylesheets/framework/modal.scss
+8
-0
new.html.haml
app/views/doorkeeper/authorizations/new.html.haml
+41
-37
35721-auth-style-confirmation.yml
changelogs/unreleased/35721-auth-style-confirmation.yml
+5
-0
No files found.
app/assets/stylesheets/framework/modal.scss
View file @
4fb49156
...
...
@@ -16,6 +16,14 @@ body.modal-open {
overflow
:
hidden
;
}
.modal-no-backdrop
{
@extend
.modal-dialog
;
.modal-content
{
box-shadow
:
none
;
}
}
@media
(
min-width
:
$screen-md-min
)
{
.modal-dialog
{
width
:
860px
;
...
...
app/views/doorkeeper/authorizations/new.html.haml
View file @
4fb49156
%h3
.page-title
Authorization required
%main
{
:role
=>
"main"
}
%p
.h4
Authorize
%strong
.text-info
=
@pre_auth
.
client
.
name
to use your account?
.modal-no-backdrop
.modal-content
.modal-header
%h3
.page-title
Authorize
=
link_to
@pre_auth
.
client
.
name
,
@pre_auth
.
redirect_uri
,
target:
'_blank'
,
rel:
'noopener noreferrer'
to use your account?
-
if
current_user
.
admin?
.text-warning.prepend-top-20
%p
=
icon
(
"exclamation-triangle fw"
)
You are an admin, which means granting access to
%strong
=
@pre_auth
.
client
.
name
will allow them to interact with GitLab as an admin as well. Proceed with caution.
-
if
@pre_auth
.
scopes
#oauth-permissions
%p
This application will be able to:
%ul
.text-info
-
@pre_auth
.
scopes
.
each
do
|
scope
|
%li
=
t
scope
,
scope:
[
:doorkeeper
,
:scopes
]
%hr
/
.actions
=
form_tag
oauth_authorization_path
,
method: :post
do
=
hidden_field_tag
:client_id
,
@pre_auth
.
client
.
uid
=
hidden_field_tag
:redirect_uri
,
@pre_auth
.
redirect_uri
=
hidden_field_tag
:state
,
@pre_auth
.
state
=
hidden_field_tag
:response_type
,
@pre_auth
.
response_type
=
hidden_field_tag
:scope
,
@pre_auth
.
scope
=
hidden_field_tag
:nonce
,
@pre_auth
.
nonce
=
submit_tag
"Authorize"
,
class:
"btn btn-success wide pull-left"
=
form_tag
oauth_authorization_path
,
method: :delete
do
=
hidden_field_tag
:client_id
,
@pre_auth
.
client
.
uid
=
hidden_field_tag
:redirect_uri
,
@pre_auth
.
redirect_uri
=
hidden_field_tag
:state
,
@pre_auth
.
state
=
hidden_field_tag
:response_type
,
@pre_auth
.
response_type
=
hidden_field_tag
:scope
,
@pre_auth
.
scope
=
hidden_field_tag
:nonce
,
@pre_auth
.
nonce
=
submit_tag
"Deny"
,
class:
"btn btn-danger prepend-left-10"
.modal-body
-
if
current_user
.
admin?
.text-warning
%p
=
icon
(
"exclamation-triangle fw"
)
You are an admin, which means granting access to
%strong
=
@pre_auth
.
client
.
name
will allow them to interact with GitLab as an admin as well. Proceed with caution.
%p
You are about to authorize
=
link_to
@pre_auth
.
client
.
name
,
@pre_auth
.
redirect_uri
,
target:
'_blank'
,
rel:
'noopener noreferrer'
to use your account.
-
if
@pre_auth
.
scopes
This application will be able to:
%ul
-
@pre_auth
.
scopes
.
each
do
|
scope
|
%li
=
t
scope
,
scope:
[
:doorkeeper
,
:scopes
]
.form-actions.text-right
=
form_tag
oauth_authorization_path
,
method: :delete
,
class:
'inline'
do
=
hidden_field_tag
:client_id
,
@pre_auth
.
client
.
uid
=
hidden_field_tag
:redirect_uri
,
@pre_auth
.
redirect_uri
=
hidden_field_tag
:state
,
@pre_auth
.
state
=
hidden_field_tag
:response_type
,
@pre_auth
.
response_type
=
hidden_field_tag
:scope
,
@pre_auth
.
scope
=
hidden_field_tag
:nonce
,
@pre_auth
.
nonce
=
submit_tag
"Deny"
,
class:
"btn btn-danger"
=
form_tag
oauth_authorization_path
,
method: :post
,
class:
'inline'
do
=
hidden_field_tag
:client_id
,
@pre_auth
.
client
.
uid
=
hidden_field_tag
:redirect_uri
,
@pre_auth
.
redirect_uri
=
hidden_field_tag
:state
,
@pre_auth
.
state
=
hidden_field_tag
:response_type
,
@pre_auth
.
response_type
=
hidden_field_tag
:scope
,
@pre_auth
.
scope
=
hidden_field_tag
:nonce
,
@pre_auth
.
nonce
=
submit_tag
"Authorize"
,
class:
"btn btn-success prepend-left-10"
changelogs/unreleased/35721-auth-style-confirmation.yml
0 → 100644
View file @
4fb49156
---
title
:
restyling of OAuth authorization confirmation
merge_request
:
author
:
Jacopo Beschi @jacopo-beschi
type
:
changed
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment