diff --git a/public/assets/images/Logo_ND.png b/public/assets/images/Logo_ND.png index 2f966b9..e8f9b2c 100644 Binary files a/public/assets/images/Logo_ND.png and b/public/assets/images/Logo_ND.png differ diff --git a/src/App.js b/src/App.js index 60017a0..6fc9859 100644 --- a/src/App.js +++ b/src/App.js @@ -6,6 +6,7 @@ import { import { RegisterPage } from "./_containers/RegisterPage"; import { alertActions } from "./_actions"; import { history } from "./_helpers"; +import ChooseOrg from "./_containers/RegisterPage/components/ChooseOrg"; function App() { String.prototype.capitalize = function () { var letters = @@ -31,12 +32,17 @@ function App() {
+ - + diff --git a/src/_components/Auth/InputSelectSearch/index.scss b/src/_components/Auth/InputSelectSearch/index.scss index fe8939a..81e4bc5 100644 --- a/src/_components/Auth/InputSelectSearch/index.scss +++ b/src/_components/Auth/InputSelectSearch/index.scss @@ -75,7 +75,7 @@ $border-color: #4a4848; height: 100%; border: none; font-size: 18px; - line-height: 21px; + // line-height: 21px; flex: 1; background-color: transparent; opacity: 1; @@ -86,6 +86,7 @@ $border-color: #4a4848; @include screen_mobile { font-size: 0.9rem !important; + margin-top: 1%; } } } diff --git a/src/_components/Auth/InputText/index.scss b/src/_components/Auth/InputText/index.scss index e360809..5d60f84 100644 --- a/src/_components/Auth/InputText/index.scss +++ b/src/_components/Auth/InputText/index.scss @@ -88,7 +88,7 @@ $border-color: #4a4848; height: 100%; border: none; font-size: 18px; - line-height: 21px; + // line-height: 21px; flex: 1; background-color: transparent; @@ -98,6 +98,7 @@ $border-color: #4a4848; @include screen_mobile { font-size: 0.9rem !important; + margin-top: 1%; } } } diff --git a/src/_components/Header/HeaderLogoRegister/HeaderLogoRegister.js b/src/_components/Header/HeaderLogoRegister/HeaderLogoRegister.js index a548cd3..c425480 100644 --- a/src/_components/Header/HeaderLogoRegister/HeaderLogoRegister.js +++ b/src/_components/Header/HeaderLogoRegister/HeaderLogoRegister.js @@ -3,10 +3,10 @@ import { Link } from "react-router-dom"; import { useSelector } from "react-redux"; import './headerTS.style.scss' -function HeaderLogoRegister({srcImg, name, color}) { +function HeaderLogoRegister({srcImg, name, color, path}) { return (
- + {"Logo"} {!!registerInfo && - (orgLevel === 'namdinh' ? - - : - )} + + } {statusRegister.type !== "success" ? ( <>
{ @@ -99,6 +100,7 @@ export default function AddressStudying(props) { setOrganization({ title: "", value: "", + id: '', }); setDistrict(newDistrict); // getSchoolList(newDistrict.value); @@ -126,15 +128,15 @@ export default function AddressStudying(props) { props.setData({ province: province.value, district: district.value, - school: school.value, - school_id: school.id, + school: organization.title, + school_id: organization.id, organization: organization.value }) } useEffect(() => { if(!props?.registerInfo) { - history.push('/namdinh') + history.push('/') return; } if(province.value) { @@ -225,6 +227,7 @@ export default function AddressStudying(props) { return { value: item.token, title: item.name, + id: item.id }; })} placeholder="Trường" diff --git a/src/_containers/RegisterPage/components/ChooseOrg/ChooseOrg.logic.js b/src/_containers/RegisterPage/components/ChooseOrg/ChooseOrg.logic.js new file mode 100644 index 0000000..130366e --- /dev/null +++ b/src/_containers/RegisterPage/components/ChooseOrg/ChooseOrg.logic.js @@ -0,0 +1,13 @@ +import { useState } from "react" +import { registerValue } from "../../../../_constants/register" + +export const ChooseOrgLogic = () => { + const [organizationList, setOrganizationList] = useState(Object.values(registerValue)) + const [orgHover, setOrgHover] = useState(null) + + return { + organizationList, + orgHover, + setOrgHover + } +} \ No newline at end of file diff --git a/src/_containers/RegisterPage/components/ChooseOrg/ChooseOrg.style.scss b/src/_containers/RegisterPage/components/ChooseOrg/ChooseOrg.style.scss new file mode 100644 index 0000000..2b5dd60 --- /dev/null +++ b/src/_containers/RegisterPage/components/ChooseOrg/ChooseOrg.style.scss @@ -0,0 +1,98 @@ +@import "/src/_styles/mixin"; + +// .bg-register { +// max-height: 100vh; +// overflow-y: hidden; + +// @include screen_mobile { +// overflow: unset; +// max-height: unset; +// } +// } + +.choose-org-container { + width: 100%; + display: block; + padding: 5% 15% 0; + + @include screen_mobile { + padding: 10% 0; + } +} + +.choose-org-heading { + text-align: center; + font-size: 2rem; + font-weight: 600; + text-transform: uppercase; + + @include screen_mobile { + font-size: 1.6rem; + } +} + +.org-list-container { + margin-top: 94px; + display: flex; + justify-content: center; + overflow-y: auto; + + @include screen_mobile { + padding: 0 16px; + margin-top: 26px; + overflow-y: unset; + } + + @media screen and (max-height: 800px) { + margin-top: 40px; + } +} + +.org-list { + max-height: 64vh; + display: flex; + flex-wrap: wrap; + gap: 50px; + justify-content: center; + + @include screen_mobile { + max-height: unset; + gap: 32px; + } +} + +.org-item { + display: flex; + flex-direction: column; + gap: 8px; + cursor: pointer; +} + +.org-item-img { + display: flex; + justify-content: center; + + img { + width: 100px; + height: 100px; + border-radius: 50%; + object-fit: contain; + + @include screen_mobile { + width: 80px; + height: 80px; + } + } +} + +.org-item-name { + p { + font-size: 18px; + font-weight: 600; + text-align: center; + + @include screen_mobile { + font-size: 14px; + } + } +} \ No newline at end of file diff --git a/src/_containers/RegisterPage/components/ChooseOrg/index.jsx b/src/_containers/RegisterPage/components/ChooseOrg/index.jsx new file mode 100644 index 0000000..bb42270 --- /dev/null +++ b/src/_containers/RegisterPage/components/ChooseOrg/index.jsx @@ -0,0 +1,34 @@ +import { history } from '../../../../_helpers' +import { ChooseOrgLogic } from './ChooseOrg.logic' +import './ChooseOrg.style.scss' + +export default function ChooseOrg() { + const {organizationList, orgHover,setOrgHover,} = ChooseOrgLogic() + return ( +
+
+

Chọn tổ chức của bạn

+
+
+ {organizationList.map(item => ( +
setOrgHover(item)} + onMouseLeave={() => setOrgHover(null)} + onClick={() => history.push(`/${item.path}`)} + > +
+ {item.path} +
+
+

{item.organization}

+
+
+ ))} +
+
+
+
+ ) +} \ No newline at end of file diff --git a/src/_containers/RegisterPage/components/RegisterSuccess/index.js b/src/_containers/RegisterPage/components/RegisterSuccess/index.js index 32b0222..06edc49 100644 --- a/src/_containers/RegisterPage/components/RegisterSuccess/index.js +++ b/src/_containers/RegisterPage/components/RegisterSuccess/index.js @@ -32,9 +32,9 @@ const RegisterSuccess = ({handleReset}) => {
{/* */} - +