-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
13 changed files
with
443 additions
and
288 deletions.
There are no files selected for viewing
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
import { AxiosResponse } from 'axios'; | ||
import { http } from '../../../config'; | ||
import { IMember, MembershipType } from '../../types/Member'; | ||
|
||
interface ICreateMember { | ||
firstName: string; | ||
lastName: string; | ||
email: string; | ||
number: string; | ||
file: File; | ||
membershipType: MembershipType; | ||
occupation: string; | ||
} | ||
interface ICreateResponse { | ||
success: string; | ||
message: string; | ||
result: IMember; | ||
} | ||
|
||
const createMemberAction = async (body: ICreateMember) => { | ||
const formData = new FormData(); | ||
|
||
Object.entries(body).forEach(([key, value]) => { | ||
formData.append(key, value); | ||
}); | ||
|
||
try { | ||
const response = await http.post<typeof formData, AxiosResponse<ICreateResponse>>('/members', formData); | ||
return response.data; | ||
} catch (error) { | ||
throw new Error(); | ||
} | ||
}; | ||
|
||
export default createMemberAction; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
163 changes: 92 additions & 71 deletions
163
client/src/modules/common/components/SingleSelect/SingleSelect.module.scss
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,80 +1,101 @@ | ||
.root { | ||
z-index: 20; | ||
.input_wraper { | ||
min-height: 50px; | ||
box-shadow: 0 1px 0 0 #e8e8e8; | ||
background-color: #fafafa; | ||
.item_wraper { | ||
font-size: 11px; | ||
width: calc(100% - 40px); | ||
display: flex; | ||
gap: 5px; | ||
} | ||
.arrow_wrraper { | ||
.arrow { | ||
border-left: 5px solid transparent; | ||
border-right: 5px solid transparent; | ||
border-top: 5px solid #bebebe; | ||
} | ||
} | ||
} | ||
z-index: 20; | ||
.input_wraper { | ||
min-height: 50px; | ||
box-shadow: 0 1px 0 0 #e8e8e8; | ||
background-color: #fafafa; | ||
.item_wraper { | ||
font-size: 11px; | ||
width: calc(100% - 40px); | ||
display: flex; | ||
gap: 5px; | ||
} | ||
.arrow_wrraper { | ||
.arrow { | ||
border-left: 5px solid transparent; | ||
border-right: 5px solid transparent; | ||
border-top: 5px solid #bebebe; | ||
} | ||
} | ||
} | ||
.error_text { | ||
color: #ff5b43; | ||
font-size: 11px; | ||
font-weight: 500; | ||
} | ||
|
||
ul { | ||
width: calc(100% - 40px); | ||
top: calc(100% + 2px); | ||
box-shadow: 5px 15px 20px 0 rgba(0, 0, 0, 0.1); | ||
ul { | ||
width: calc(100% - 40px); | ||
top: calc(100% + 2px); | ||
box-shadow: 5px 15px 20px 0 rgba(0, 0, 0, 0.1); | ||
|
||
li { | ||
width: 100%; | ||
display: block; | ||
padding: 9px; | ||
font-size: 14px; | ||
border-radius: 4px; | ||
&:hover { | ||
background: #f4f4f4; | ||
// color: #63636a; | ||
} | ||
} | ||
} | ||
li { | ||
width: 100%; | ||
display: block; | ||
padding: 9px; | ||
font-size: 14px; | ||
border-radius: 4px; | ||
&:hover { | ||
background: #f4f4f4; | ||
// color: #63636a; | ||
} | ||
} | ||
} | ||
|
||
.error { | ||
border-color: #ff5b43 !important; | ||
} | ||
.error { | ||
border-color: #ff5b43 !important; | ||
} | ||
|
||
.error_text { | ||
color: #ff5b43; | ||
font-size: 11px; | ||
font-weight: 500; | ||
} | ||
.error_text { | ||
color: #ff5b43; | ||
font-size: 11px; | ||
font-weight: 500; | ||
} | ||
|
||
&:focus-within { | ||
.input_wraper { | ||
background-color: white; | ||
border: 1px solid #01896a; | ||
box-shadow: 0 1px 0 0 #01896a; | ||
} | ||
&:focus-within { | ||
.input_wraper { | ||
background-color: white; | ||
border: 1px solid #9c51e0; | ||
box-shadow: 0 1px 0 0 #9c51e0; | ||
} | ||
|
||
.span_label { | ||
top: -22px; | ||
left: 0; | ||
font-size: 0.875rem; | ||
color: #01896a; | ||
} | ||
} | ||
.span_label_active { | ||
top: -22px !important; | ||
left: 0px !important; | ||
} | ||
.span_label { | ||
top: -22px; | ||
left: 0; | ||
font-size: 0.875rem; | ||
color: #9c51e0; | ||
} | ||
} | ||
.span_label_active { | ||
top: -22px !important; | ||
left: 0px !important; | ||
} | ||
|
||
.span_label { | ||
top: 16px; | ||
left: 14px; | ||
position: absolute; | ||
font-size: 0.875rem; | ||
font-weight: 500; | ||
text-align: left; | ||
color: #9797a0; | ||
letter-spacing: 0.65px; | ||
transition: all 0.15s ease-in-out 0s; | ||
} | ||
.span_label { | ||
top: 16px; | ||
left: 14px; | ||
position: absolute; | ||
font-size: 0.875rem; | ||
font-weight: 500; | ||
text-align: left; | ||
color: #9797a0; | ||
letter-spacing: 0.65px; | ||
transition: all 0.15s ease-in-out 0s; | ||
} | ||
} | ||
|
||
.error { | ||
.input_wraper { | ||
box-shadow: 0 1px 0 0 #ff5b43 !important; | ||
} | ||
&:focus-within { | ||
.input_wraper { | ||
border: 1px solid #ff5b43 !important; | ||
box-shadow: 0 1px 0 0 #ff5b43 !important; | ||
} | ||
|
||
.span_label { | ||
color: #ff5b43 !important; | ||
} | ||
} | ||
} |
Oops, something went wrong.