Skip to content

Commit

Permalink
Merge pull request #127 from capstone-five-ai/develop
Browse files Browse the repository at this point in the history
v0.1.7
  • Loading branch information
AAminha authored Jun 15, 2024
2 parents 1633066 + 88d4dbe commit 17fec4e
Show file tree
Hide file tree
Showing 8 changed files with 6 additions and 19 deletions.
2 changes: 1 addition & 1 deletion src/components/Button/PlainButton.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ const getVariantStyle = ($variant: PlainButtonVariant) => {
&:hover {
color: ${({ theme }) => theme.colors.grayScale02};
box-shadow: 4px 2px 16px 0px rgba(142, 142, 142, 0.24);
box-shadow: 0px 2px 8px 0px rgba(142, 142, 142, 0.12);
}
`;
}
Expand Down
16 changes: 4 additions & 12 deletions src/components/Button/SaveToCategoryButton.tsx
Original file line number Diff line number Diff line change
@@ -1,21 +1,13 @@
import { ReactComponent as SaveIcon } from '@/assets/icons/save.svg';
import PlainButton from '@/components/Button/PlainButton';
import { CATEGORY_TYPE } from '@/constants';
import { ServiceType } from '@/types/category.type';

interface SaveToCategoryButtonProps
extends React.ButtonHTMLAttributes<HTMLButtonElement> {
generateType: ServiceType;
}

function SaveToCategoryButton({
generateType,
...props
}: SaveToCategoryButtonProps) {
function SaveToCategoryButton(
props: React.ButtonHTMLAttributes<HTMLButtonElement>
) {
return (
<PlainButton {...props}>
<SaveIcon />
카테고리에 {CATEGORY_TYPE[generateType]} 추가
카테고리에 저장
</PlainButton>
);
}
Expand Down
1 change: 0 additions & 1 deletion src/containers/CategoryDetailPage/CategorySidebar.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -159,7 +159,6 @@ function CategorySidebar({
<StyledButtonContainer>
<ShareLinkButton link={window.location.href} />
<SaveToCategoryButton
generateType={contentType}
onClick={() => setShowAddCategoryModal(true)}
disabled={!isAuthenticated}
/>
Expand Down
1 change: 0 additions & 1 deletion src/containers/QuizAIPage/ResultSection.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,6 @@ function ResultSection() {
)}
</ContentInnerContainer>
<SaveToCategoryButton
generateType="QUIZ"
disabled={!isAuthenticated}
onClick={() => setShowModal(true)}
/>
Expand Down
1 change: 0 additions & 1 deletion src/containers/QuizUserPage/ResultSection.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,6 @@ function ResultSection() {
<ShareLinkButton link={window.location.href} />
</StyledButtonContainer>
<SaveToCategoryButton
generateType="QUIZ"
disabled={!isAuthenticated}
onClick={() => setShowModal(true)}
/>
Expand Down
1 change: 0 additions & 1 deletion src/containers/SummaryAIPage/ResultSection.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,6 @@ function ResultSection() {
)}
</StyledButtonContainer>
<SaveToCategoryButton
generateType="SUMMARY"
disabled={!isAuthenticated}
onClick={() => setShowModal(true)}
/>
Expand Down
1 change: 0 additions & 1 deletion src/containers/SummaryUserPage/ResultSection.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,6 @@ function ResultSection() {
)}
</StyledButtonContainer>
<SaveToCategoryButton
generateType="SUMMARY"
disabled={!isAuthenticated}
onClick={() => setShowModal(true)}
/>
Expand Down
2 changes: 1 addition & 1 deletion src/pages/CategorySummaryEditPage.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ export default CategorySummaryEditPage;

const StyledContent = styled.div`
flex: 1;
padding: 24px 20px 24px 40px;
padding: 24px 24px 40px;
display: flex;
flex-direction: column;
Expand Down

0 comments on commit 17fec4e

Please sign in to comment.