run prettier
This commit is contained in:
parent
6de0f8ef60
commit
8f6c2fc8b8
|
|
@ -13,7 +13,7 @@
|
|||
"dev": "webpack-dev-server",
|
||||
"build": "webpack --mode=production -p --progress",
|
||||
"lint": "eslint --ext=ts -f=beauty .",
|
||||
"fmt": "prettier --write 'resources/assets/**/*.{ts,tsx}'",
|
||||
"fmt": "prettier --write resources/assets",
|
||||
"test": "jest"
|
||||
},
|
||||
"dependencies": {
|
||||
|
|
|
|||
|
|
@ -8,7 +8,8 @@ a {
|
|||
outline: none;
|
||||
}
|
||||
|
||||
.brand-link, .navbar-brand {
|
||||
.brand-link,
|
||||
.navbar-brand {
|
||||
font-family: Minecraft;
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -8,13 +8,13 @@ export default async function handler(event: Event) {
|
|||
const email: string = form.email.value
|
||||
const password: string = form.password.value
|
||||
|
||||
const {
|
||||
code,
|
||||
message,
|
||||
}: ResponseBody = await post('/user/profile?action=email', {
|
||||
new_email: email,
|
||||
password,
|
||||
})
|
||||
const { code, message }: ResponseBody = await post(
|
||||
'/user/profile?action=email',
|
||||
{
|
||||
new_email: email,
|
||||
password,
|
||||
},
|
||||
)
|
||||
await showModal({ mode: 'alert', text: message })
|
||||
if (code === 0) {
|
||||
window.location.href = `${blessing.base_url}/auth/login`
|
||||
|
|
|
|||
|
|
@ -7,12 +7,12 @@ export default async function handler(event: Event) {
|
|||
const form = event.target as HTMLFormElement
|
||||
const nickname: string = form.nickname.value
|
||||
|
||||
const {
|
||||
code,
|
||||
message,
|
||||
}: ResponseBody = await post('/user/profile?action=nickname', {
|
||||
new_nickname: nickname,
|
||||
})
|
||||
const { code, message }: ResponseBody = await post(
|
||||
'/user/profile?action=nickname',
|
||||
{
|
||||
new_nickname: nickname,
|
||||
},
|
||||
)
|
||||
showModal({ mode: 'alert', text: message })
|
||||
if (code === 0) {
|
||||
document.querySelectorAll('[data-mark="nickname"]').forEach((el) => {
|
||||
|
|
|
|||
|
|
@ -16,13 +16,13 @@ export default async function handler(event: Event) {
|
|||
return
|
||||
}
|
||||
|
||||
const {
|
||||
code,
|
||||
message,
|
||||
}: ResponseBody = await post('/user/profile?action=password', {
|
||||
current_password: oldPassword,
|
||||
new_password: newPassword,
|
||||
})
|
||||
const { code, message }: ResponseBody = await post(
|
||||
'/user/profile?action=password',
|
||||
{
|
||||
current_password: oldPassword,
|
||||
new_password: newPassword,
|
||||
},
|
||||
)
|
||||
await showModal({ mode: 'alert', text: message })
|
||||
if (code === 0) {
|
||||
window.location.href = `${blessing.base_url}/auth/login`
|
||||
|
|
|
|||
|
|
@ -4,20 +4,11 @@
|
|||
"baseUrl": "..",
|
||||
"noEmit": true,
|
||||
"paths": {
|
||||
"@/scripts/*": [
|
||||
"./tests/ts-shims/*",
|
||||
"./src/scripts/*"
|
||||
],
|
||||
"@/components/*": [
|
||||
"./src/components/*"
|
||||
],
|
||||
"@/views/*": [
|
||||
"./src/views/*"
|
||||
],
|
||||
"@/scripts/*": ["./tests/ts-shims/*", "./src/scripts/*"],
|
||||
"@/components/*": ["./src/components/*"],
|
||||
"@/views/*": ["./src/views/*"],
|
||||
"@/*": ["./src/*"]
|
||||
}
|
||||
},
|
||||
"include": [
|
||||
"."
|
||||
]
|
||||
"include": ["."]
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user