Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
Sharkey
Manage
Activity
Members
Labels
Plan
Issues
342
Issue boards
Milestones
Iterations
Wiki
Requirements
Code
Merge requests
27
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Test cases
Artifacts
Deploy
Releases
Package Registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Issue analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
TransFem.org
Sharkey
Commits
cb16cb06
Commit
cb16cb06
authored
4 years ago
by
syuilo
Browse files
Options
Downloads
Patches
Plain Diff
Fix #6781
parent
0baed1a2
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
src/client/components/signin-dialog.vue
+1
-3
1 addition, 3 deletions
src/client/components/signin-dialog.vue
src/client/components/signin.vue
+48
-42
48 additions, 42 deletions
src/client/components/signin.vue
src/client/style.scss
+15
-0
15 additions, 0 deletions
src/client/style.scss
with
64 additions
and
45 deletions
src/client/components/signin-dialog.vue
+
1
−
3
View file @
cb16cb06
...
...
@@ -7,9 +7,7 @@
>
<template
#header
>
{{
$t
(
'
login
'
)
}}
</
template
>
<div
class=
"_section"
>
<MkSignin
:auto-set=
"autoSet"
@
login=
"onLogin"
/>
</div>
<MkSignin
:auto-set=
"autoSet"
@
login=
"onLogin"
/>
</XModalWindow>
</template>
...
...
This diff is collapsed.
Click to expand it.
src/client/components/signin.vue
+
48
−
42
View file @
cb16cb06
<
template
>
<form
class=
"eppvobhk"
:class=
"
{ signing, totpLogin }" @submit.prevent="onSubmit">
<div
class=
"avatar"
:style=
"
{ backgroundImage: user ? `url('${ user.avatarUrl }')` : null }" v-show="withAvatar">
</div>
<div
class=
"normal-signin"
v-if=
"!totpLogin"
>
<MkInput
v-model:value=
"username"
type=
"text"
pattern=
"^[a-zA-Z0-9_]+$"
spellcheck=
"false"
autofocus
required
@
update:value=
"onUsernameChange"
>
<span>
{{
$t
(
'
username
'
)
}}
</span>
<template
#prefix
>
@
</
template
>
<
template
#suffix
>
@
{{
host
}}
</
template
>
</MkInput>
<MkInput
v-model:value=
"password"
type=
"password"
:with-password-toggle=
"true"
v-if=
"!user || user && !user.usePasswordLessLogin"
required
>
<span>
{{ $t('password') }}
</span>
<
template
#prefix
><Fa
:icon=
"faLock"
/></
template
>
</MkInput>
<MkButton
type=
"submit"
primary
:disabled=
"signing"
style=
"margin: 0 auto;"
>
{{ signing ? $t('loggingIn') : $t('login') }}
</MkButton>
<a
class=
"_panelButton"
style=
"margin: 8px auto;"
v-if=
"meta && meta.enableTwitterIntegration"
:href=
"`${apiUrl}/signin/twitter`"
><Fa
:icon=
"faTwitter"
style=
"margin-right: 4px;"
/>
{{ $t('signinWith', { x: 'Twitter' }) }}
</a>
<a
class=
"_panelButton"
style=
"margin: 8px auto;"
v-if=
"meta && meta.enableGithubIntegration"
:href=
"`${apiUrl}/signin/github`"
><Fa
:icon=
"faGithub"
style=
"margin-right: 4px;"
/>
{{ $t('signinWith', { x: 'GitHub' }) }}
</a>
<a
class=
"_panelButton"
style=
"margin: 8px auto;"
v-if=
"meta && meta.enableDiscordIntegration"
:href=
"`${apiUrl}/signin/discord`"
><Fa
:icon=
"faDiscord"
style=
"margin-right: 4px;"
/>
{{ $t('signinWith', { x: 'Discord' }) }}
</a>
</div>
<div
class=
"2fa-signin"
v-if=
"totpLogin"
:class=
"{ securityKeys: user && user.securityKeys }"
>
<div
v-if=
"user && user.securityKeys"
class=
"twofa-group tap-group"
>
<p>
{{ $t('tapSecurityKey') }}
</p>
<MkButton
@
click=
"queryKey"
v-if=
"!queryingKey"
>
{{ $t('retry') }}
</MkButton>
</div>
<div
class=
"or-hr"
v-if=
"user && user.securityKeys"
>
<p
class=
"or-msg"
>
{{ $t('or') }}
</p>
</div>
<div
class=
"twofa-group totp-group"
>
<p
style=
"margin-bottom:0;"
>
{{ $t('twoStepAuthentication') }}
</p>
<MkInput
v-model:value=
"password"
type=
"password"
:with-password-toggle=
"true"
v-if=
"user && user.usePasswordLessLogin"
required
>
<div
class=
"auth _section"
>
<div
class=
"avatar"
:style=
"
{ backgroundImage: user ? `url('${ user.avatarUrl }')` : null }" v-show="withAvatar">
</div>
<div
class=
"normal-signin"
v-if=
"!totpLogin"
>
<MkInput
v-model:value=
"username"
type=
"text"
pattern=
"^[a-zA-Z0-9_]+$"
spellcheck=
"false"
autofocus
required
@
update:value=
"onUsernameChange"
>
<span>
{{
$t
(
'
username
'
)
}}
</span>
<template
#prefix
>
@
</
template
>
<
template
#suffix
>
@
{{
host
}}
</
template
>
</MkInput>
<MkInput
v-model:value=
"password"
type=
"password"
:with-password-toggle=
"true"
v-if=
"!user || user && !user.usePasswordLessLogin"
required
>
<span>
{{ $t('password') }}
</span>
<
template
#prefix
><Fa
:icon=
"faLock"
/></
template
>
</MkInput>
<MkInput
v-model:value=
"token"
type=
"text"
pattern=
"^[0-9]{6}$"
autocomplete=
"off"
spellcheck=
"false"
required
>
<span>
{{ $t('token') }}
</span>
<
template
#prefix
><Fa
:icon=
"faGavel"
/></
template
>
</MkInput>
<MkButton
type=
"submit"
:disabled=
"signing"
primary
style=
"margin: 0 auto;"
>
{{ signing ? $t('loggingIn') : $t('login') }}
</MkButton>
<MkButton
type=
"submit"
primary
:disabled=
"signing"
style=
"margin: 0 auto;"
>
{{ signing ? $t('loggingIn') : $t('login') }}
</MkButton>
</div>
<div
class=
"2fa-signin"
v-if=
"totpLogin"
:class=
"{ securityKeys: user && user.securityKeys }"
>
<div
v-if=
"user && user.securityKeys"
class=
"twofa-group tap-group"
>
<p>
{{ $t('tapSecurityKey') }}
</p>
<MkButton
@
click=
"queryKey"
v-if=
"!queryingKey"
>
{{ $t('retry') }}
</MkButton>
</div>
<div
class=
"or-hr"
v-if=
"user && user.securityKeys"
>
<p
class=
"or-msg"
>
{{ $t('or') }}
</p>
</div>
<div
class=
"twofa-group totp-group"
>
<p
style=
"margin-bottom:0;"
>
{{ $t('twoStepAuthentication') }}
</p>
<MkInput
v-model:value=
"password"
type=
"password"
:with-password-toggle=
"true"
v-if=
"user && user.usePasswordLessLogin"
required
>
<span>
{{ $t('password') }}
</span>
<
template
#prefix
><Fa
:icon=
"faLock"
/></
template
>
</MkInput>
<MkInput
v-model:value=
"token"
type=
"text"
pattern=
"^[0-9]{6}$"
autocomplete=
"off"
spellcheck=
"false"
required
>
<span>
{{ $t('token') }}
</span>
<
template
#prefix
><Fa
:icon=
"faGavel"
/></
template
>
</MkInput>
<MkButton
type=
"submit"
:disabled=
"signing"
primary
style=
"margin: 0 auto;"
>
{{ signing ? $t('loggingIn') : $t('login') }}
</MkButton>
</div>
</div>
</div>
<div
class=
"social _section"
>
<a
class=
"_borderButton _vMargin"
v-if=
"meta && meta.enableTwitterIntegration"
:href=
"`${apiUrl}/signin/twitter`"
><Fa
:icon=
"faTwitter"
style=
"margin-right: 4px;"
/>
{{ $t('signinWith', { x: 'Twitter' }) }}
</a>
<a
class=
"_borderButton _vMargin"
v-if=
"meta && meta.enableGithubIntegration"
:href=
"`${apiUrl}/signin/github`"
><Fa
:icon=
"faGithub"
style=
"margin-right: 4px;"
/>
{{ $t('signinWith', { x: 'GitHub' }) }}
</a>
<a
class=
"_borderButton _vMargin"
v-if=
"meta && meta.enableDiscordIntegration"
:href=
"`${apiUrl}/signin/discord`"
><Fa
:icon=
"faDiscord"
style=
"margin-right: 4px;"
/>
{{ $t('signinWith', { x: 'Discord' }) }}
</a>
</div>
</form>
</template>
...
...
@@ -203,14 +207,16 @@ export default defineComponent({
<
style
lang=
"scss"
scoped
>
.eppvobhk
{
>
.avatar
{
margin
:
0
auto
0
auto
;
width
:
64px
;
height
:
64px
;
background
:
#ddd
;
background-position
:
center
;
background-size
:
cover
;
border-radius
:
100%
;
>
.auth
{
>
.avatar
{
margin
:
0
auto
0
auto
;
width
:
64px
;
height
:
64px
;
background
:
#ddd
;
background-position
:
center
;
background-size
:
cover
;
border-radius
:
100%
;
}
}
}
</
style
>
This diff is collapsed.
Click to expand it.
src/client/style.scss
+
15
−
0
View file @
cb16cb06
...
...
@@ -297,6 +297,21 @@ hr {
padding
:
12px
0
;
}
._borderButton
{
@extend
._button
;
display
:
block
;
width
:
100%
;
padding
:
10px
;
box-sizing
:
border-box
;
text-align
:
center
;
border
:
solid
1px
var
(
--
divider
);
border-radius
:
var
(
--
radius
);
&
:active
{
border-color
:
var
(
--
accent
);
}
}
._popup
{
background
:
var
(
--
panel
);
border-radius
:
var
(
--
radius
);
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment