mirror of
https://github.com/omnivore-app/omnivore.git
synced 2026-03-11 08:54:26 +00:00
Use the pointer cursor for labels, invert query logic
This commit is contained in:
parent
2924d542be
commit
41a601f199
1 changed files with 3 additions and 2 deletions
|
|
@ -507,6 +507,7 @@ function LabelButton(props: LabelButtonProps): JSX.Element {
|
|||
>
|
||||
<label
|
||||
style={{
|
||||
cursor: 'pointer',
|
||||
width: '100%',
|
||||
maxWidth: '170px',
|
||||
overflow: 'hidden',
|
||||
|
|
@ -516,11 +517,11 @@ function LabelButton(props: LabelButtonProps): JSX.Element {
|
|||
onClick={() => {
|
||||
const query = props.searchTerm?.replace(/label:\"(.*)\"/, '') ?? ''
|
||||
if (checkboxRef.current?.checked) {
|
||||
props.applySearchQuery(query.trim())
|
||||
} else {
|
||||
props.applySearchQuery(
|
||||
`${query.trim()} label:\"${props.label.name}\"`
|
||||
)
|
||||
} else {
|
||||
props.applySearchQuery(query.trim())
|
||||
}
|
||||
}}
|
||||
>
|
||||
|
|
|
|||
Loading…
Reference in a new issue