fix: ALT text entered in the compose dialog is erased when you press "Edit" again (#1054)
This commit is contained in:
@@ -62,7 +62,7 @@ export const Component = observer(function ({image, gallery}: Props) {
|
|||||||
const [position, setPosition] = useState<Position | undefined>(
|
const [position, setPosition] = useState<Position | undefined>(
|
||||||
image.attributes.position,
|
image.attributes.position,
|
||||||
)
|
)
|
||||||
const [altText, setAltText] = useState('')
|
const [altText, setAltText] = useState(image?.altText ?? '')
|
||||||
|
|
||||||
const onFlipHorizontal = useCallback(() => {
|
const onFlipHorizontal = useCallback(() => {
|
||||||
image.flipHorizontal()
|
image.flipHorizontal()
|
||||||
|
|||||||
Reference in New Issue
Block a user