import React from 'react';
import styled from 'styled-components';
interface ResultViewType {
type?: "login" | "profile" | "logout" | "unlink"
state: any
}
const ResultView = ({ type, state }: ResultViewType) => {
console.log(state, 'state');
return (
() => {
switch (type) {
case "login": {
return (
로그인 토큰
{state}
);
}
case "profile": {
return (
프로필
{state.nickname}
);
}
case "logout": {
return (
로그아웃 완료
);
}
case "unlink": {
return (
링크 해제 완료
);
}
default: {
return (
카카오 로그인
{state}
);
}
}
}
)();
};
const ResultBox = styled.div`
display: flex;
flex-direction: column;
align-items: center;
justify-content: center;
margin-bottom: 10px;
`;
export default ResultView;