File tree Expand file tree Collapse file tree 2 files changed +25
-1
lines changed
ui/src/app/applications/components/filter Expand file tree Collapse file tree 2 files changed +25
-1
lines changed Original file line number Diff line number Diff line change @@ -109,6 +109,16 @@ $slate: #191826;
109109 font-weight : 500 ;
110110 }
111111 }
112+
113+ & __tooltip {
114+ max-width : 300px ;
115+ word-wrap : break-word ;
116+ overflow-wrap : break-word ;
117+ white-space : normal ;
118+ @media screen and (max-width : 590px ) {
119+ max-width : 250px ;
120+ }
121+ }
112122}
113123
114124.filters-group {
Original file line number Diff line number Diff line change 11import { Autocomplete , Checkbox } from 'argo-ui/v2' ;
2+ import { Tooltip } from 'argo-ui' ;
23import * as React from 'react' ;
34
45import './filter.scss' ;
@@ -31,6 +32,17 @@ export const CheckboxRow = (props: {value: boolean; onChange?: (value: boolean)
3132 setValue ( props . value ) ;
3233 } , [ props . value ] ) ;
3334
35+ const tooltipProps : Partial < React . ComponentProps < typeof Tooltip > > = {
36+ placement : 'top' ,
37+ popperOptions : {
38+ modifiers : {
39+ preventOverflow : {
40+ boundariesElement : 'window'
41+ }
42+ }
43+ }
44+ } ;
45+
3446 return (
3547 < div className = { `filter__item ${ value ? 'filter__item--selected' : '' } ` } onClick = { ( ) => setValue ( ! value ) } >
3648 < Checkbox
@@ -46,7 +58,9 @@ export const CheckboxRow = (props: {value: boolean; onChange?: (value: boolean)
4658 } }
4759 />
4860 { props . option . icon && < div style = { { marginRight : '5px' } } > { props . option . icon } </ div > }
49- < div className = 'filter__item__label' > { props . option . label } </ div >
61+ < Tooltip content = { < div className = 'filter__tooltip' > { props . option . label } </ div > } { ...tooltipProps } >
62+ < div className = 'filter__item__label' > { props . option . label } </ div >
63+ </ Tooltip >
5064 < div style = { { marginLeft : 'auto' } } > { props . option . count } </ div >
5165 </ div >
5266 ) ;
You can’t perform that action at this time.
0 commit comments