@@ -712,38 +712,16 @@ field[ns.ui('Classifier').uri] = function (
712712 if ( ! ok ) return callbackFunction ( ok , body )
713713 return callbackFunction ( ok , body )
714714 }
715- // Create container for label and select
716- const outerBox = dom . createElement ( 'div' )
717- outerBox . setAttribute ( 'class' , 'classifierBox' )
718- // Render label
719- const labelDiv = dom . createElement ( 'div' )
720- labelDiv . setAttribute ( 'class' , 'formFieldName classifierBox-label' )
721- // Use fieldLabel to render ui:label if present
722- labelDiv . appendChild ( fieldLabel ( dom , category , form ) )
723- outerBox . appendChild ( labelDiv )
724- // Render select
725- const selectBox = dom . createElement ( 'div' )
726- selectBox . setAttribute ( 'class' , 'formFieldValue classifierBox-selectBox' )
727- const selectElement = makeSelectForNestedCategory (
715+ const box = makeSelectForNestedCategory (
728716 dom ,
729717 kb ,
730718 subject ,
731719 category ,
732720 dataDoc ,
733721 checkOptions
734722 )
735- // Set readonly if not editable
736- if ( selectElement && selectElement . querySelector && selectElement . querySelector ( 'select' ) ) {
737- const select = selectElement . querySelector ( 'select' ) ;
738- if ( select && ! kb . updater . editable ( dataDoc . uri ) ) {
739- select . readOnly = true ;
740- select . style = style . textInputStyleUneditable ;
741- }
742- }
743- selectBox . appendChild ( selectElement )
744- outerBox . appendChild ( selectBox )
745- if ( container ) container . appendChild ( outerBox )
746- return outerBox
723+ if ( container ) container . appendChild ( box )
724+ return box
747725}
748726
749727/** Choice field
0 commit comments