Skip to content

Commit e74bd0e

Browse files
authored
feat: hide sorting (#197)
2 parents d68a5d8 + d4a3b8b commit e74bd0e

File tree

2 files changed

+13
-1
lines changed

2 files changed

+13
-1
lines changed

frontend/src/pages/admin/MainPage/components/ChatsBlock/ChatsBlock.module.scss

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -43,4 +43,12 @@
4343
min-width: 36px;
4444
height: 36px;
4545
padding: 6px 0;
46+
opacity: 1;
47+
visibility: visible;
48+
transition: 0.2s;
49+
}
50+
51+
.orderByContainerHide {
52+
opacity: 0;
53+
visibility: hidden;
4654
}

frontend/src/pages/admin/MainPage/components/ChatsBlock/ChatsBlock.tsx

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
import { BlockNew, Dropdown, Icon, TabsContainer } from '@components'
22
import { ChatsActiveTab, ChatsPopularOrderBy } from '@types'
33
import { hapticFeedback } from '@utils'
4+
import cn from 'classnames'
45
import { useRef, useState } from 'react'
56

67
import { useAdminChatsQuery, useChatsPopularQuery } from '@store-new'
@@ -62,7 +63,10 @@ export const ChatsBlock = () => {
6263
onChangeTab={handleChangeActiveTab}
6364
/>
6465
<div
65-
className={styles.orderByContainer}
66+
className={cn(
67+
styles.orderByContainer,
68+
activeTab !== 'explore' && styles.orderByContainerHide
69+
)}
6670
onClick={() => handleToggleDropdown()}
6771
ref={buttonRef}
6872
>

0 commit comments

Comments
 (0)