File tree Expand file tree Collapse file tree 1 file changed +16
-13
lines changed
src/Shared/Components/FilterChips Expand file tree Collapse file tree 1 file changed +16
-13
lines changed Original file line number Diff line number Diff line change @@ -18,19 +18,22 @@ const FilterChip = ({
18
18
const valueToDisplay = getFormattedValue ( label , value ) ?? value
19
19
20
20
return (
21
- < div className = "flexbox flex-align-center br-4 dc__border dc__bg-n50 pl-6 pr-6 pt-2 pb-2 dc__user-select-none h-24 dc__gap-6 fs-12 lh-20 cn-9 fw-4 dc__ellipsis-right" >
22
- < span className = "fw-6 dc__capitalize" > { labelToDisplay } </ span >
23
- < span className = "dc__divider h-24" />
24
- < span className = "dc__ellipsis-right" > { valueToDisplay } </ span >
25
- < button
26
- type = "button"
27
- className = "flex p-0 dc__transparent"
28
- onClick = { removeFilter }
29
- aria-label = "Remove filter"
30
- >
31
- < CloseIcon className = "icon-dim-12 icon-use-fill-n6" />
32
- </ button >
33
- </ div >
21
+ labelToDisplay &&
22
+ valueToDisplay && (
23
+ < div className = "flexbox flex-align-center br-4 dc__border dc__bg-n50 pl-6 pr-6 pt-2 pb-2 dc__user-select-none h-24 dc__gap-6 fs-12 lh-20 cn-9 fw-4 dc__ellipsis-right" >
24
+ < span className = "fw-6 dc__capitalize" > { labelToDisplay } </ span >
25
+ < span className = "dc__divider h-24" />
26
+ < span className = "dc__ellipsis-right" > { valueToDisplay } </ span >
27
+ < button
28
+ type = "button"
29
+ className = "flex p-0 dc__transparent"
30
+ onClick = { removeFilter }
31
+ aria-label = "Remove filter"
32
+ >
33
+ < CloseIcon className = "icon-dim-12 icon-use-fill-n6" />
34
+ </ button >
35
+ </ div >
36
+ )
34
37
)
35
38
}
36
39
You can’t perform that action at this time.
0 commit comments