Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Dev/fe #287

Merged
merged 19 commits into from
Jan 11, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 1 addition & 4 deletions .github/workflows/deployment.yml
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,4 @@ jobs:
aws-region: ${{ secrets.AWS_REGION }}

- name: Deploy to S3
run: aws s3 sync ./client/build s3://${{ secrets.DEV_AWS_S3_BUCKET }} --delete

- name: Invalidate CloudFront Cache
run: aws cloudfront create-invalidation --distribution-id ${{secrets.DEV_AWS_DISTRIBUTION_ID}} --paths "/*"
run: aws s3 sync ./client/build s3://${{ secrets.DEV_AWS_S3_BUCKETNAME }} --delete
2 changes: 1 addition & 1 deletion .github/workflows/gradle.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ permissions:
contents: read

env:
S3_BUCKET_NAME: 004-s3-bucket
S3_BUCKET_NAME: fe-004-s3-bucket

jobs:
build:
Expand Down
2 changes: 1 addition & 1 deletion client/public/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
/>
<meta
property="og:image"
content="https://wrieating.kro.kr/static/main.png"
content="http://fe-004-s3-bucket.s3-website.ap-northeast-2.amazonaws.com/static/main.png"
/>
<link
href="https://fonts.googleapis.com/css?family=Material+Icons+Round"
Expand Down
2 changes: 0 additions & 2 deletions client/src/components/Common/Input.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -61,9 +61,7 @@ const Input = (props: inputProps) => {
</InputWrapper>
)
}

const InputWrapper = styled.div`
height: 6rem;
flex: 1;
`

Expand Down
29 changes: 19 additions & 10 deletions client/src/components/Common/Radio.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ const Radio = (props: radioProps) => {
<Legend>{legend}</Legend>
<RadioWrapper>
{radioArray.map((i) => (
<div key={i.id} className="radio-div">
<RadioInputWrapper key={i.id}>
<input
id={i.id}
type="radio"
Expand All @@ -20,7 +20,7 @@ const Radio = (props: radioProps) => {
onChange={onChange}
/>
<StyledLabel htmlFor={i.id}>{i.label}</StyledLabel>
</div>
</RadioInputWrapper>
))}
</RadioWrapper>
</div>
Expand All @@ -30,29 +30,38 @@ const Radio = (props: radioProps) => {
const RadioWrapper = styled.div`
display: flex;
flex-wrap: wrap;
gap: 2rem;
gap: 1rem;
row-gap: 2rem;

input[type='radio'] {
display: none;
}

input[type='radio'],
input[type='radio']:checked + label {
color: var(--color-point);
accent-color: var(--color-point);
color: var(--color-white);
background-color: var(--color-primary);
font-weight: 600;
transition: all 0.1s;
}
`

.radio-div {
margin-top: 0.8rem;
}
const RadioInputWrapper = styled.div`
margin-top: 1rem;
`

const Legend = styled.legend`
display: inline-block;
margin: 0 0 0.4rem 0.4rem;
font-size: 1.4rem;
font-weight: 700;
`

const StyledLabel = styled.label`
font-size: 1.4rem;
color: var(--color-secondary);
border: 1px solid var(--color-secondary);
border-radius: 1rem;
padding: 0.8rem 1rem;
cursor: pointer;
`

export default Radio
5 changes: 3 additions & 2 deletions client/src/components/Common/Tab.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ const Tab = ({ tabItem }: TabMenus) => {
}, [])

return (
<div>
<>
<TabsWrapper>
{tabItem.map((i, idx) => (
<TabLink
Expand All @@ -31,7 +31,7 @@ const Tab = ({ tabItem }: TabMenus) => {
<SubpageContainer>
<Outlet />
</SubpageContainer>
</div>
</>
)
}

Expand All @@ -52,6 +52,7 @@ const TabLink = styled(Link)`
}
`
const SubpageContainer = styled.div`
width: 100%;
min-height: 30rem;
padding: 2.6rem;
border: 1px solid var(--color-light-gray);
Expand Down
82 changes: 40 additions & 42 deletions client/src/components/User/ChangePwd.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -106,38 +106,36 @@ const ChangePwd = () => {
return (
<>
<TabFrame title="비밀번호 변경">
<Wrapper>
<Form>
<Input
type="password"
label="현재 비밀번호"
placeholder="현재 비밀번호"
name="currentPassword"
value={currentPassword}
error={error.currentPassword}
onChange={handleInput}
/>
<Input
type="password"
label="새 비밀번호"
placeholder="새 비밀번호"
name="newPassword"
value={newPassword}
error={error.newPassword}
onChange={handleInput}
/>
<Input
type="password"
label="새 비밀번호 확인"
placeholder="비밀번호 확인"
name="ckPassword"
value={ckPassword}
error={error.ckPassword}
onChange={handleInput}
/>
<Button onClick={changePassword}>변경하기</Button>
</Form>
</Wrapper>
<Form>
<Input
type="password"
label="현재 비밀번호"
placeholder="현재 비밀번호"
name="currentPassword"
value={currentPassword}
error={error.currentPassword}
onChange={handleInput}
/>
<Input
type="password"
label="새 비밀번호"
placeholder="새 비밀번호"
name="newPassword"
value={newPassword}
error={error.newPassword}
onChange={handleInput}
/>
<Input
type="password"
label="새 비밀번호 확인"
placeholder="비밀번호 확인"
name="ckPassword"
value={ckPassword}
error={error.ckPassword}
onChange={handleInput}
/>
<Button onClick={changePassword}>변경하기</Button>
</Form>
</TabFrame>
<Modal
state={isOpen}
Expand All @@ -150,24 +148,24 @@ const ChangePwd = () => {
)
}

const Wrapper = styled.div`
width: 63.7rem;
min-height: 40rem;

@media ${({ theme }) => theme.device.tablet} {
width: 88vw;
}
`

const Form = styled.form`
width: 35rem;
width: 40rem;
display: flex;
flex-direction: column;
gap: 1rem;

> button {
margin-top: 0.8rem;
}

@media ${({ theme }) => theme.device.tablet} {
width: 80%;
min-width: 20rem;
}

@media ${({ theme }) => theme.device.mobile} {
width: 100%;
}
`

export default ChangePwd
Loading
Loading