Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
  • Loading branch information
khj0426 committed Nov 29, 2023
2 parents 8625583 + c61d5d1 commit 8a17c40
Show file tree
Hide file tree
Showing 11 changed files with 28 additions and 49 deletions.
22 changes: 0 additions & 22 deletions src/assets/icons/basic-profile.svg

This file was deleted.

1 change: 0 additions & 1 deletion src/assets/icons/index.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
export { default as CloseInTheCircleIcon } from './close-in-the-circle.svg?react'
export { default as MenuIcon } from './menu.svg?react'
export { default as BasicProfileIcon } from './basic-profile.svg?react'
export { default as EyeOffIcon } from './eye-off.svg?react'
export { default as EyeOnIcon } from './eye-on.svg?react'
export { default as StarIcon } from './star.svg?react'
Expand Down
Binary file added src/assets/images/basic-profile.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
1 change: 1 addition & 0 deletions src/assets/images/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,3 +6,4 @@ export { default as errorLightImg } from './error-white.png'
export { default as sansDark } from './sans-dark.png'
export { default as sansLight } from './sans-light.png'
export { default as rangerCleanHead } from './clean-head.png'
export { default as BasicProfile } from './basic-profile.png'
5 changes: 2 additions & 3 deletions src/components/Header/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -6,11 +6,10 @@ import {
LogoRowIcon,
LogoShortIcon,
ArrowLeftIcon,
BasicProfileIcon,
SunIcon,
MoonIcon,
} from '@/assets/icons'
import { rangerCleanHead } from '@/assets/images'
import { rangerCleanHead, BasicProfile } from '@/assets/images'
import { Modal } from '..'
import Dropdown from '../Dropdown'

Expand Down Expand Up @@ -81,7 +80,7 @@ const Header = memo(({ handleGoBack }: HeaderProps) => {
<img src={user.path} alt="my" />
</div>
) : (
<BasicProfileIcon className="h-7 w-7 md:h-9 md:w-9" />
<img src={BasicProfile} className="h-7 w-7 md:h-9 md:w-9" />
)}
</Dropdown.Toggle>
<Dropdown.Menu className="w-40 rounded-sm">
Expand Down
10 changes: 2 additions & 8 deletions src/components/Profile/index.tsx
Original file line number Diff line number Diff line change
@@ -1,18 +1,12 @@
import { BasicProfileIcon } from '@/assets/icons'
import { BasicProfile } from '@/assets/images'

interface ProfileProps {
image?: string | JSX.Element
name: string
className?: string
}

const Profile = ({
image = (
<BasicProfileIcon className="visible h-4 w-4 bg-white dark:bg-black" />
),
name,
className,
}: ProfileProps) => {
const Profile = ({ image = BasicProfile, name, className }: ProfileProps) => {
return (
<div className="flex flex-row items-center gap-2">
<div className="flex h-5 w-5 items-center justify-center overflow-hidden rounded-full border">
Expand Down
17 changes: 13 additions & 4 deletions src/pages/CreatedReviewManagePage/components/AnswerGroup/index.tsx
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import { nanoid } from 'nanoid'
import { useState } from 'react'
import { StarRatingList } from '@/components'
import { BasicProfileIcon } from '@/assets/icons'
import { BasicProfile } from '@/assets/images'
import { QUESTION_TYPE } from '../../constants'
import RenderRefinedSubjective from './RenderRefinedSubjective'

Expand Down Expand Up @@ -29,7 +29,10 @@ interface Answer {
const renderStarRating = (value: Answer) => (
<div>
<h3 className="flex items-center">
<BasicProfileIcon className="avatar h-[1.25rem] w-[1.25rem] border dark:bg-white dark:fill-white" />
<img
src={BasicProfile}
className="avatar h-[1.25rem] w-[1.25rem] border dark:bg-white dark:fill-white"
/>
<p className="ml-[1.31rem] text-sm">{value.userName}</p>
</h3>
<div className="ml-[42.96px] mt-[0.5rem] text-base leading-5 md:mt-[0.62rem]">
Expand All @@ -51,7 +54,10 @@ const renderHexaStat = (value: Answer, answers: Answer[]) => {
<div className="flex">
{filteredAnswers.map((value) => (
<div className="flex w-3/6 flex-wrap gap-[0.31rem]" key={nanoid()}>
<BasicProfileIcon className="avatar h-[1.25rem] w-[1.25rem] border dark:bg-white dark:fill-white" />
<img
src={BasicProfile}
className="avatar h-[1.25rem] w-[1.25rem] border dark:bg-white dark:fill-white"
/>
<p className="text-sm">{value?.userName}</p>
<p className="text-sm text-sub-wine">{value?.value}</p>
</div>
Expand All @@ -64,7 +70,10 @@ const renderHexaStat = (value: Answer, answers: Answer[]) => {
const renderDefault = (value: Answer) => (
<>
<h3 className="flex items-center ">
<BasicProfileIcon className="avatar h-[1.25rem] w-[1.25rem] border dark:bg-white dark:fill-white" />
<img
src={BasicProfile}
className="avatar h-[1.25rem] w-[1.25rem] border dark:bg-white dark:fill-white"
/>
<p className="ml-[1.31rem] text-sm">{value?.userName}</p>
</h3>
<p className="ml-[42.96px] mt-[0.5rem] break-all text-base leading-5 md:mt-[0.62rem]">
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { BasicProfileIcon } from '@/assets/icons'
import { BasicProfile } from '@/assets/images'

interface ProfileGroupProps {
name: string
Expand All @@ -9,7 +9,10 @@ interface ProfileGroupProps {
const ProfileGroup = ({ name, responserSize, type }: ProfileGroupProps) => {
return (
<div className="flex">
<BasicProfileIcon className="avatar h-[2.8125rem] w-[2.8125rem] border dark:bg-white dark:fill-white md:h-[3.5rem] md:w-[3.5rem]" />
<img
src={BasicProfile}
className="avatar h-[2.8125rem] w-[2.8125rem] border dark:bg-white dark:fill-white md:h-[3.5rem] md:w-[3.5rem]"
/>

<div className="ml-[0.63rem] flex flex-col md:ml-[1.44rem]">
{type === 'receiver' ? (
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ const SelectResponseUser = ({
className={`flex h-fit shrink-0 cursor-pointer items-center justify-center gap-2 rounded-md border px-2 py-1.5
${
name === selectedName
? 'border-black border-sub-green bg-main-yellow dark:border-white dark:bg-main-red-300'
? 'border-black bg-main-yellow dark:border-white dark:bg-main-red-300'
: 'border-gray-100 bg-white dark:border-gray-300 dark:bg-main-red-200'
}`}
>
Expand Down
10 changes: 3 additions & 7 deletions src/pages/MyPage/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,8 @@ import { ChangeEvent, useRef } from 'react'
import { useNameCheck, usePasswordCheck, useToast } from '@/hooks'
import { Header, Input, Modal } from '@/components'
import { useEditImage, useUser } from '@/apis/hooks'
import {
BasicProfileIcon,
CheckIcon,
EditIcon,
ImageIcon,
} from '@/assets/icons'
import { CheckIcon, EditIcon, ImageIcon } from '@/assets/icons'
import { BasicProfile } from '@/assets/images'
import { useEditNameCheck, useEditPasswordCheck } from './hooks'

const MyPage = () => {
Expand Down Expand Up @@ -99,7 +95,7 @@ const MyPage = () => {
className="h-full w-full"
/>
) : (
<BasicProfileIcon className="h-20 w-20" />
<img src={BasicProfile} className="h-20 w-20" />
)}
</div>
<div className="absolute bottom-0 right-0 flex h-6 w-6 items-center justify-center rounded-full border bg-white dark:bg-main-red-200">
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -149,7 +149,7 @@ const ReceiverSelect = ({ setReviewStep, questions }: ReceiverSelectProps) => {
setName('')
}}
>
<Profile name={nonReceiver.name} className="visible z-10" />
<Profile name={nonReceiver.name} />
</Dropdown.Item>
))
) : (
Expand Down

0 comments on commit 8a17c40

Please sign in to comment.