diff --git a/src/web/control.js b/src/web/control.js index 5f4ea77..cee451c 100644 --- a/src/web/control.js +++ b/src/web/control.js @@ -119,6 +119,16 @@ function App({ wsEndpoint }) { ) }, []) + const handleClickId = useCallback((streamId) => { + const availableIdx = range(GRID_COUNT * GRID_COUNT).find( + (i) => !stateIdxMap.has(i), + ) + if (availableIdx === undefined) { + return + } + handleSetView(availableIdx, streamId) + }) + const handleChangeCustomStream = useCallback((idx, customStream) => { let newCustomStreams = [...customStreams] newCustomStreams[idx] = customStream @@ -170,7 +180,7 @@ function App({ wsEndpoint }) {