* first attempt at stream sidebar, tasks, and events * fix folder from root * cleanup folders and events, and condense changes * cleanup and add toggle for sidebar * cleanup * fix nits
16 lines
554 B
TypeScript
16 lines
554 B
TypeScript
import { useParams } from 'react-router-dom';
|
|
import { particlePath } from '@/lib/particle-path';
|
|
import { ContainerView } from '@/features/particles/container-view';
|
|
|
|
/**
|
|
* Route-level component for /:networkId (index). The network root behaves
|
|
* like a folder: a container of streams, folders, and loose particles.
|
|
*/
|
|
export default function NetworkRoot() {
|
|
const { networkId } = useParams();
|
|
if (!networkId)
|
|
throw new Error('NetworkRoot requires a :networkId route param');
|
|
|
|
return <ContainerView path={particlePath(networkId, [])} />;
|
|
}
|