Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
C
canifa_note
Project
Project
Details
Activity
Releases
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
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Vũ Hoàng Anh
canifa_note
Commits
05c6edfe
Commit
05c6edfe
authored
Jun 26, 2024
by
Steven
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
chore: tweak auth pages
parent
6325b3ee
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
15 additions
and
12 deletions
+15
-12
AccessTokenSection.tsx
web/src/components/Settings/AccessTokenSection.tsx
+1
-1
SignIn.tsx
web/src/pages/SignIn.tsx
+2
-2
SignUp.tsx
web/src/pages/SignUp.tsx
+12
-9
No files found.
web/src/components/Settings/AccessTokenSection.tsx
View file @
05c6edfe
...
@@ -13,7 +13,7 @@ import LearnMore from "../LearnMore";
...
@@ -13,7 +13,7 @@ import LearnMore from "../LearnMore";
const
listAccessTokens
=
async
(
name
:
string
)
=>
{
const
listAccessTokens
=
async
(
name
:
string
)
=>
{
const
{
accessTokens
}
=
await
userServiceClient
.
listUserAccessTokens
({
name
});
const
{
accessTokens
}
=
await
userServiceClient
.
listUserAccessTokens
({
name
});
return
accessTokens
;
return
accessTokens
.
sort
((
a
,
b
)
=>
(
b
.
issuedAt
?.
getTime
()
??
0
)
-
(
a
.
issuedAt
?.
getTime
()
??
0
))
;
};
};
const
AccessTokenSection
=
()
=>
{
const
AccessTokenSection
=
()
=>
{
...
...
web/src/pages/SignIn.tsx
View file @
05c6edfe
...
@@ -118,7 +118,7 @@ const SignIn = () => {
...
@@ -118,7 +118,7 @@ const SignIn = () => {
</
div
>
</
div
>
<
form
className=
"w-full mt-2"
onSubmit=
{
handleFormSubmit
}
>
<
form
className=
"w-full mt-2"
onSubmit=
{
handleFormSubmit
}
>
<
div
className=
"flex flex-col justify-start items-start w-full gap-4"
>
<
div
className=
"flex flex-col justify-start items-start w-full gap-4"
>
<
div
className=
"w-full flex flex-col justify-start items-start
gap-2
"
>
<
div
className=
"w-full flex flex-col justify-start items-start"
>
<
span
className=
"leading-8 text-gray-600"
>
{
t
(
"common.username"
)
}
</
span
>
<
span
className=
"leading-8 text-gray-600"
>
{
t
(
"common.username"
)
}
</
span
>
<
Input
<
Input
className=
"w-full"
className=
"w-full"
...
@@ -131,7 +131,7 @@ const SignIn = () => {
...
@@ -131,7 +131,7 @@ const SignIn = () => {
required
required
/>
/>
</
div
>
</
div
>
<
div
className=
"w-full flex flex-col justify-start items-start
gap-2
"
>
<
div
className=
"w-full flex flex-col justify-start items-start"
>
<
span
className=
"leading-8 text-gray-600"
>
{
t
(
"common.password"
)
}
</
span
>
<
span
className=
"leading-8 text-gray-600"
>
{
t
(
"common.password"
)
}
</
span
>
<
Input
<
Input
className=
"w-full"
className=
"w-full"
...
...
web/src/pages/SignUp.tsx
View file @
05c6edfe
...
@@ -88,7 +88,7 @@ const SignUp = () => {
...
@@ -88,7 +88,7 @@ const SignUp = () => {
<
p
className=
"w-full text-2xl mt-2 dark:text-gray-500"
>
{
t
(
"auth.create-your-account"
)
}
</
p
>
<
p
className=
"w-full text-2xl mt-2 dark:text-gray-500"
>
{
t
(
"auth.create-your-account"
)
}
</
p
>
<
form
className=
"w-full mt-2"
onSubmit=
{
handleFormSubmit
}
>
<
form
className=
"w-full mt-2"
onSubmit=
{
handleFormSubmit
}
>
<
div
className=
"flex flex-col justify-start items-start w-full gap-4"
>
<
div
className=
"flex flex-col justify-start items-start w-full gap-4"
>
<
div
className=
"w-full flex flex-col justify-start items-start
gap-2
"
>
<
div
className=
"w-full flex flex-col justify-start items-start"
>
<
span
className=
"leading-8 text-gray-600"
>
{
t
(
"common.username"
)
}
</
span
>
<
span
className=
"leading-8 text-gray-600"
>
{
t
(
"common.username"
)
}
</
span
>
<
Input
<
Input
className=
"w-full"
className=
"w-full"
...
@@ -101,7 +101,7 @@ const SignUp = () => {
...
@@ -101,7 +101,7 @@ const SignUp = () => {
required
required
/>
/>
</
div
>
</
div
>
<
div
className=
"w-full flex flex-col justify-start items-start
gap-2
"
>
<
div
className=
"w-full flex flex-col justify-start items-start"
>
<
span
className=
"leading-8 text-gray-600"
>
{
t
(
"common.password"
)
}
</
span
>
<
span
className=
"leading-8 text-gray-600"
>
{
t
(
"common.password"
)
}
</
span
>
<
Input
<
Input
className=
"w-full"
className=
"w-full"
...
@@ -128,13 +128,16 @@ const SignUp = () => {
...
@@ -128,13 +128,16 @@ const SignUp = () => {
</
Button
>
</
Button
>
</
div
>
</
div
>
</
form
>
</
form
>
{
!
commonContext
.
profile
.
owner
&&
<
p
className=
"w-full mt-4 text-sm font-medium dark:text-gray-500"
>
{
t
(
"auth.host-tip"
)
}
</
p
>
}
{
!
commonContext
.
profile
.
owner
?
(
<
p
className=
"w-full mt-4 text-sm"
>
<
p
className=
"w-full mt-4 text-sm font-medium dark:text-gray-500"
>
{
t
(
"auth.host-tip"
)
}
</
p
>
<
span
className=
"dark:text-gray-500"
>
{
t
(
"auth.sign-in-tip"
)
}
</
span
>
)
:
(
<
Link
to=
"/auth"
className=
"cursor-pointer ml-2 text-blue-600 hover:underline"
unstable_viewTransition
>
<
p
className=
"w-full mt-4 text-sm"
>
{
t
(
"common.sign-in"
)
}
<
span
className=
"dark:text-gray-500"
>
{
t
(
"auth.sign-in-tip"
)
}
</
span
>
</
Link
>
<
Link
to=
"/auth"
className=
"cursor-pointer ml-2 text-blue-600 hover:underline"
unstable_viewTransition
>
</
p
>
{
t
(
"common.sign-in"
)
}
</
Link
>
</
p
>
)
}
</
div
>
</
div
>
<
div
className=
"mt-4 flex flex-row items-center justify-center w-full gap-2"
>
<
div
className=
"mt-4 flex flex-row items-center justify-center w-full gap-2"
>
<
LocaleSelect
value=
{
commonContext
.
locale
}
onChange=
{
handleLocaleSelectChange
}
/>
<
LocaleSelect
value=
{
commonContext
.
locale
}
onChange=
{
handleLocaleSelectChange
}
/>
...
...
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