access+userpic-fix
This commit is contained in:
parent
f8bf3d86a0
commit
4ed15f405e
|
@ -378,6 +378,7 @@
|
|||
"There are unsaved changes in your profile settings. Are you sure you want to leave the page without saving?": "There are unsaved changes in your profile settings. Are you sure you want to leave the page without saving?",
|
||||
"There are unsaved changes in your publishing settings. Are you sure you want to leave the page without saving?": "There are unsaved changes in your publishing settings. Are you sure you want to leave the page without saving?",
|
||||
"This comment has not yet been rated": "This comment has not yet been rated",
|
||||
"This content is not published yet": "This content is not published yet",
|
||||
"This email is": "This email is",
|
||||
"This email is not verified": "This email is not verified",
|
||||
"This email is verified": "This email is verified",
|
||||
|
|
|
@ -148,6 +148,7 @@
|
|||
"Enter the code or click the link from email to confirm": "Введите код из письма или пройдите по ссылке в письме для подтверждения регистрации",
|
||||
"Enter your new password": "Введите новый пароль",
|
||||
"Enter": "Войти",
|
||||
"This content is not published yet": "Содержимое ещё не опубликовано",
|
||||
"Error": "Ошибка",
|
||||
"Please give us your email address": "Пожалуйста, укажите свою почту, чтобы получить ссылку для сброса пароля",
|
||||
"Experience": "Личный опыт",
|
||||
|
|
|
@ -51,10 +51,15 @@ const DialogAvatar = (props: Props) => {
|
|||
<Show when={Boolean(props.url)} fallback={<div class={styles.letter}>{nameFirstLetter()}</div>}>
|
||||
<div
|
||||
class={styles.imageHolder}
|
||||
style={{ 'background-image': `url(
|
||||
${props.url.includes('discours.io') ? getImageUrl(props.url, { width: 40, height: 40 }) : props.url }
|
||||
)`
|
||||
}}
|
||||
style={{
|
||||
'background-image': `url(
|
||||
${
|
||||
props.url.includes('discours.io')
|
||||
? getImageUrl(props.url, { width: 40, height: 40 })
|
||||
: props.url
|
||||
}
|
||||
)`,
|
||||
}}
|
||||
/>
|
||||
</Show>
|
||||
</div>
|
||||
|
|
|
@ -9,13 +9,15 @@ import { Shout } from '../graphql/schema/core.gen'
|
|||
import { useRouter } from '../stores/router'
|
||||
import { router } from '../stores/router'
|
||||
|
||||
import { redirectPage } from '@nanostores/router'
|
||||
import { useSnackbar } from '../context/snackbar'
|
||||
import { LayoutType } from './types'
|
||||
import { redirectPage } from "@nanostores/router";
|
||||
|
||||
const EditView = lazy(() => import('../components/Views/EditView/EditView'))
|
||||
|
||||
export const EditPage = () => {
|
||||
const { page } = useRouter()
|
||||
const snackbar = useSnackbar()
|
||||
const { t } = useLocalize()
|
||||
|
||||
const shoutId = createMemo(() => Number((page().params as Record<'shoutId', string>).shoutId))
|
||||
|
@ -27,8 +29,8 @@ export const EditPage = () => {
|
|||
console.log(loadedShout)
|
||||
if (loadedShout) {
|
||||
setShout(loadedShout)
|
||||
}
|
||||
else {
|
||||
} else {
|
||||
await snackbar?.showSnackbar({ type: 'error', body: t('This content is not published yet') })
|
||||
redirectPage(router, 'drafts')
|
||||
}
|
||||
})
|
||||
|
|
Loading…
Reference in New Issue
Block a user