Fix the type error

This commit is contained in:
Aria Minaei 2023-08-10 14:59:35 +02:00
parent fc849a5e7a
commit 59873689ac

View file

@ -3,6 +3,7 @@ import {Package, Trash} from '@theatre/studio/uiComponents/icons'
import React, {useCallback, useEffect} from 'react'
import styled, {css} from 'styled-components'
import type {ISimplePropEditorReactProps} from './ISimplePropEditorReactProps'
import type {$FixMe} from '@theatre/shared/utils/types'
const Container = styled.div<{empty: boolean}>`
display: flex;
@ -105,7 +106,7 @@ function FilePropEditor({
}, [value])
const onChange = useCallback(
async (event) => {
async (event: React.ChangeEvent<$FixMe>) => {
const file = event.target.files[0]
editingTools.permanentlySetValue({type: 'file', id: undefined})
const fileId = await editingTools.createAsset(file)