File tree Expand file tree Collapse file tree 3 files changed +22
-1
lines changed
packages/pf3-component-mapper Expand file tree Collapse file tree 3 files changed +22
-1
lines changed Original file line number Diff line number Diff line change @@ -15,6 +15,7 @@ const selectSchema = {
1515 component : 'select-field' ,
1616 name : 'select-single' ,
1717 label : 'Select single' ,
18+ isDisabled : true ,
1819 options : [ {
1920 label : 'foo' ,
2021 value : 123
@@ -28,6 +29,7 @@ const selectSchema = {
2829 label : 'Select search' ,
2930 isRequired : true ,
3031 validateOnMount : true ,
32+ isDisabled : true ,
3133 isClearable : true ,
3234 multi : true ,
3335 isSearchable : true ,
Original file line number Diff line number Diff line change @@ -287,6 +287,8 @@ export class P3Select extends Component {
287287 < div className = { `${ props . classNamePrefix } -button` } >
288288 < DropdownButton
289289 onToggle = { ( ) => this . handleToggleOpen ( ) }
290+ disabled = { props . isDisabled }
291+ noCaret = { props . isDisabled }
290292 open = { isOpen }
291293 id = { props . id || props . input . name }
292294 title = { < SelectTitle
@@ -336,7 +338,7 @@ export class P3Select extends Component {
336338 components = { {
337339 ClearIndicator,
338340 Option,
339- DropdownIndicator,
341+ DropdownIndicator : props . isDisabled ? null : DropdownIndicator ,
340342 } }
341343 />
342344 ) ;
Original file line number Diff line number Diff line change @@ -199,6 +199,23 @@ div.field-group {
199199 }
200200 }
201201 }
202+ & .ddorg__pf3-component-mapper__select--is-disabled {
203+ cursor : not-allowed ;
204+ pointer-events : unset ;
205+ border-color : #d1d1d1 ;
206+ * {
207+ pointer-events : none ;
208+ cursor : not-allowed ;
209+ }
210+ .ddorg__pf3-component-mapper__select__control {
211+ background-color : #fafafa ;
212+ background-image : none ;
213+ border-color : #d1d1d1 ;
214+ color : #8b8d8f ;
215+ opacity : 1 ;
216+ box-shadow : none ;
217+ }
218+ }
202219}
203220.ddorg__pf3-component-mapper__select-dropdown {
204221 & .is-empty {
You can’t perform that action at this time.
0 commit comments