Skip to content

Commit

Permalink
fix/filter select
Browse files Browse the repository at this point in the history
  • Loading branch information
k0t1k777 committed Aug 25, 2024
1 parent 0c8df49 commit c9089cf
Show file tree
Hide file tree
Showing 4 changed files with 17 additions and 2 deletions.
4 changes: 4 additions & 0 deletions src/components/Filter/Filter.module.scss
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,10 @@
overflow-y: auto;
}

.filterContainer {
width: 241px;
}

.container {
display: flex;
gap: 16px;
Expand Down
2 changes: 1 addition & 1 deletion src/components/Filter/Filter.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -128,7 +128,7 @@ export default function Filter({ droppedCards }: FilterProps) {

return (
<div ref={modalRef} className={styles.filter}>
<div>
<div className={styles.filterContainer}>
<Input
className={styles.input}
placeholder='Поиск'
Expand Down
4 changes: 4 additions & 0 deletions src/ui/Select/Select.module.scss
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,10 @@
background-color: white;
cursor: pointer;

&--mini {
width: 100%;
}

&__title {
color: $main-text-black;
box-sizing: border-box;
Expand Down
9 changes: 8 additions & 1 deletion src/ui/Select/Select.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -30,16 +30,23 @@ export default function Select({ text, value, setValue, options }: ISelect) {
setValue('');
}

const newTeamRout = location.pathname === '/new-team'
console.log('newTeamRout: ', newTeamRout);

return (
<div
ref={isOpen ? ref : null}
className={cx('select', {
'select--open': isOpen,
'select--mini': newTeamRout,
})}
aria-hidden='true'
>
{!value && (
<span onClick={toggleOpen} className={cx('select__title')}>
<span
onClick={toggleOpen}
className={cx('select__title')}
>
{text}
</span>
)}
Expand Down

0 comments on commit c9089cf

Please sign in to comment.