Skip to content

Commit

Permalink
labels for input, autocomplete property, pathname
Browse files Browse the repository at this point in the history
  • Loading branch information
Lvyshnevska committed Oct 9, 2024
1 parent b9059bc commit 549efbc
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 7 deletions.
3 changes: 1 addition & 2 deletions FrontEnd/src/components/Header/Header.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,7 @@ import Navbar from './Navbar/Navbar';
import css from './Header.module.css';

function Header(props) {
const location = useLocation();
const { pathname } = location;
const { pathname } = useLocation();
const hideMenu = pathname === '/login' || pathname === '/sign-up' || pathname.includes('/customadmin');

return (
Expand Down
12 changes: 8 additions & 4 deletions FrontEnd/src/pages/AdminPage/AdminProfile/AdminInfo.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -68,14 +68,16 @@ const AdminInfo = ({ user }) => {
<div className={classes['admin-info-form__container']}>
<div className={classes['admin-info-form__column']}>
<div className={classes['admin-info-form__label']}>
<label className={classes['admin-info-form__label--required']}>
<label className={classes['admin-info-form__label--required']} htmlFor="name">
*
</label>
<label className={classes['admin-info-form__label--text']}>Ім‘я</label>
<label className={classes['admin-info-form__label--text']} htmlFor="name">Ім‘я</label>
</div>
<div className={classes['admin-info-form__field']}>
<input
className={classes['admin-info-form__input']}
id="name"
autoComplete="name"
type="text"
placeholder="Ім‘я"
{...register('name', {
Expand All @@ -95,16 +97,18 @@ const AdminInfo = ({ user }) => {
</div>
<div className={classes['admin-info-form__column']}>
<div className={classes['admin-info-form__label']}>
<label className={classes['admin-info-form__label--required']}>
<label className={classes['admin-info-form__label--required']} htmlFor="surname">
*
</label>
<label className={classes['admin-info-form__label--text']}>
<label className={classes['admin-info-form__label--text']} htmlFor="surname">
Прізвище
</label>
</div>
<div className={classes['admin-info-form__field']}>
<input
className={classes['admin-info-form__input']}
id="surname"
autoComplete="family-name"
type="text"
placeholder="Прізвище"
{...register('surname', {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ const PasswordField = (props) => {
{label}
</label>
{label !== 'Поточний пароль' &&
<label className={css['password-field__label--hint']}>
<label className={css['password-field__label--hint']} htmlFor={inputId}>
(Повинен містити від 8 символів, A-Z, a-z, 0-9)
</label>
}
Expand Down

0 comments on commit 549efbc

Please sign in to comment.