refactor: move ShellContext to contexts directory

This commit is contained in:
Jeremy Kahn 2022-09-05 12:17:10 -05:00
parent 38378f0dfb
commit 82673d54fd
5 changed files with 4 additions and 4 deletions

View File

@ -8,7 +8,7 @@ import Fab from '@mui/material/Fab'
import Divider from '@mui/material/Divider' import Divider from '@mui/material/Divider'
import ArrowUpward from '@mui/icons-material/ArrowUpward' import ArrowUpward from '@mui/icons-material/ArrowUpward'
import { ShellContext } from 'ShellContext' import { ShellContext } from 'contexts/ShellContext'
import { usePeerRoom, usePeerRoomAction } from 'hooks/usePeerRoom' import { usePeerRoom, usePeerRoomAction } from 'hooks/usePeerRoom'
import { PeerActions } from 'models/network' import { PeerActions } from 'models/network'
import { UnsentMessage, ReceivedMessage } from 'models/chat' import { UnsentMessage, ReceivedMessage } from 'models/chat'

View File

@ -33,7 +33,7 @@ import Home from '@mui/icons-material/Home'
import Brightness4Icon from '@mui/icons-material/Brightness4' import Brightness4Icon from '@mui/icons-material/Brightness4'
import Brightness7Icon from '@mui/icons-material/Brightness7' import Brightness7Icon from '@mui/icons-material/Brightness7'
import { ShellContext } from 'ShellContext' import { ShellContext } from 'contexts/ShellContext'
import { AlertOptions } from 'models/shell' import { AlertOptions } from 'models/shell'
import { PeerNameDisplay } from 'components/PeerNameDisplay' import { PeerNameDisplay } from 'components/PeerNameDisplay'

View File

@ -7,7 +7,7 @@ import Typography from '@mui/material/Typography'
import TextField from '@mui/material/TextField' import TextField from '@mui/material/TextField'
import { v4 as uuid } from 'uuid' import { v4 as uuid } from 'uuid'
import { ShellContext } from 'ShellContext' import { ShellContext } from 'contexts/ShellContext'
export function Home() { export function Home() {
const { setTitle } = useContext(ShellContext) const { setTitle } = useContext(ShellContext)

View File

@ -2,7 +2,7 @@ import { useContext, useEffect } from 'react'
import { Room } from 'components/Room' import { Room } from 'components/Room'
import { useParams } from 'react-router-dom' import { useParams } from 'react-router-dom'
import { ShellContext } from 'ShellContext' import { ShellContext } from 'contexts/ShellContext'
interface PublicRoomProps { interface PublicRoomProps {
userId: string userId: string