This commit is contained in:
@@ -6,13 +6,15 @@ import TextArea from '@/components/common/TextArea'
|
||||
import { Button } from '@/components/ui/button'
|
||||
import { API_BASE_URL } from '@/config'
|
||||
|
||||
import type { FC } from 'react'
|
||||
|
||||
import type { Post } from '@/types'
|
||||
|
||||
type Props = { post: Post
|
||||
onSave: (newPost: Post) => void }
|
||||
type Props = { post: Post
|
||||
onSave: (newPost: Post) => void }
|
||||
|
||||
|
||||
export default ({ post, onSave }: Props) => {
|
||||
export default (({ post, onSave }: Props) => {
|
||||
const [title, setTitle] = useState (post.title)
|
||||
const [tags, setTags] = useState<string> (post.tags
|
||||
.filter (t => t.category !== 'nico')
|
||||
@@ -55,4 +57,4 @@ export default ({ post, onSave }: Props) => {
|
||||
更新
|
||||
</Button>
|
||||
</div>)
|
||||
}
|
||||
}) satisfies FC<Props>
|
||||
|
||||
Reference in New Issue
Block a user