Skip to content

Commit f938906

Browse files
committed
refactor: 모달 열림 수정
1 parent 096f8b4 commit f938906

File tree

3 files changed

+8
-8
lines changed

3 files changed

+8
-8
lines changed

frontend/src/components/host/OfflineView.tsx

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,16 @@
11
import styled from 'styled-components';
22

33
interface OfflineViewProps {
4-
closeModal: () => void;
4+
openModal: () => void;
55
}
66

7-
export default function OfflineView({ closeModal }: OfflineViewProps) {
7+
export default function OfflineView({ openModal }: OfflineViewProps) {
88
return (
99
<LivePlayerInner>
1010
<PlayerTitle>라이브 스트리밍을 시작하려면 스트리밍 소프트웨어를 연결하세요.</PlayerTitle>
1111
<PlayerDescription>방송 시작 및 종료는 스트리밍 소프트웨어에서 가능합니다.</PlayerDescription>
1212
<PlayerWrapper>
13-
<Button type="button" onClick={closeModal}>
13+
<Button type="button" onClick={openModal}>
1414
스트리밍 설정 안내
1515
</Button>
1616
</PlayerWrapper>

frontend/src/components/host/Player.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,13 +11,13 @@ interface PlayerProps {
1111
}
1212

1313
export default function Player({ onStreaming }: PlayerProps) {
14-
const { isOpen, closeModal } = useModal();
14+
const { isOpen, closeModal, openModal } = useModal();
1515
const createPortal = usePortal();
1616

1717
return (
1818
<>
1919
<Container onStreaming={onStreaming}>
20-
<StreamingView onStreaming={onStreaming} closeModal={closeModal} />
20+
<StreamingView onStreaming={onStreaming} openModal={openModal} />
2121
</Container>
2222
<StreamingStatus onStreaming={onStreaming} />
2323
{isOpen && createPortal(<SettingInfo closeModal={closeModal} />)}

frontend/src/components/host/StreamingView.tsx

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,13 +3,13 @@ import OnlineView from './OnlineView';
33

44
interface StreamingViewProps {
55
onStreaming: boolean;
6-
closeModal: () => void;
6+
openModal: () => void;
77
}
88

9-
export default function StreamingView({ onStreaming, closeModal }: StreamingViewProps) {
9+
export default function StreamingView({ onStreaming, openModal }: StreamingViewProps) {
1010
if (onStreaming) {
1111
return <OnlineView />;
1212
}
1313

14-
return <OfflineView closeModal={closeModal} />;
14+
return <OfflineView openModal={openModal} />;
1515
}

0 commit comments

Comments
 (0)