remove unused file upload code (#1634)
this code is no longer used, since file uploads are handled via state/hooks provided in the upload component itself.
This commit is contained in:
parent
f5067d4050
commit
5c3685f0c4
@ -13,12 +13,6 @@ export default function Component() {
|
|||||||
const { {{const.color_mode}}, {{const.toggle_color_mode}} } = {{const.use_color_mode}}()
|
const { {{const.color_mode}}, {{const.toggle_color_mode}} } = {{const.use_color_mode}}()
|
||||||
const focusRef = useRef();
|
const focusRef = useRef();
|
||||||
|
|
||||||
// Function to add new files to be uploaded.
|
|
||||||
const File = files => {{state_name|react_setter}}(state => ({
|
|
||||||
...state,
|
|
||||||
files,
|
|
||||||
}))
|
|
||||||
|
|
||||||
// Main event loop.
|
// Main event loop.
|
||||||
const [Event, notConnected] = useContext(EventLoopContext)
|
const [Event, notConnected] = useContext(EventLoopContext)
|
||||||
|
|
||||||
|
@ -126,11 +126,6 @@ def compile_state(state: Type[State]) -> Dict:
|
|||||||
initial_state = state().dict()
|
initial_state = state().dict()
|
||||||
except Exception:
|
except Exception:
|
||||||
initial_state = state().dict(include_computed=False)
|
initial_state = state().dict(include_computed=False)
|
||||||
initial_state.update(
|
|
||||||
{
|
|
||||||
"files": [],
|
|
||||||
}
|
|
||||||
)
|
|
||||||
return format.format_state(initial_state)
|
return format.format_state(initial_state)
|
||||||
|
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user