Skip to content

Commit

Permalink
feat: 답변 수정 가능하지 못하도록 변경
Browse files Browse the repository at this point in the history
  • Loading branch information
Yoon-Hae-Min committed Nov 30, 2023
1 parent d9c5ffb commit c7d569f
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 9 deletions.
22 changes: 13 additions & 9 deletions FE/src/components/common/QuestionAccordion/QuestionAccordion.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ type QuestionAccordionProps = {
question: Question;
workbookId: number;
isSelected: boolean;
isEditable?: boolean;
toggleSelected?: () => void;
};

Expand All @@ -31,6 +32,7 @@ const QuestionAccordion: React.FC<QuestionAccordionProps> = ({
question,
workbookId,
isSelected,
isEditable,
toggleSelected,
}) => {
const queryClient = useQueryClient();
Expand Down Expand Up @@ -88,15 +90,17 @@ const QuestionAccordion: React.FC<QuestionAccordionProps> = ({
{question.answerContent}
</Typography>
</LeadingDot>
<Icon
id="edit"
css={css`
flex-shrink: 0;
`}
width="2rem"
height="2rem"
onClick={userInfo ? handleEditModal : handleEditGuestUser}
/>
{isEditable && (
<Icon
id="edit"
css={css`
flex-shrink: 0;
`}
width="2rem"
height="2rem"
onClick={userInfo ? handleEditModal : handleEditGuestUser}
/>
)}
</AccordionDetails>
</Accordion>
);
Expand Down
1 change: 1 addition & 0 deletions FE/src/page/interviewWorkbookDetailPage/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -105,6 +105,7 @@ const InterviewWorkbookDetailPage = () => {
question={question}
workbookId={workbookId}
isSelected={isSelected}
isEditable={false}
toggleSelected={() =>
isSelected
? selectQuestion(question.questionId)
Expand Down

0 comments on commit c7d569f

Please sign in to comment.