feat(sandbox): rebuild sandbox with shell UI and expanded templates (#773)

This commit is contained in:
Sam Potts
2026-03-09 14:20:53 +11:00
committed by GitHub
parent d751fdabea
commit b4e01250b4
59 changed files with 1126 additions and 693 deletions
@@ -0,0 +1,9 @@
import { useEffect, useState } from 'react';
import { getInitialSource, onSourceChange } from '../sandbox-listener';
import type { SourceId } from '../sources';
export function useSource(audioOnly?: boolean): SourceId {
const [source, setSource] = useState(() => getInitialSource(audioOnly));
useEffect(() => onSourceChange(setSource), []);
return source;
}