@@ -76,11 +76,9 @@ export default class Row extends Component {
7676 * @return {Object } edit window dom config for Row
7777 */
7878 get editWindow ( ) {
79- const _this = this
80-
8179 const fieldsetInput = {
8280 tag : 'input' ,
83- id : _this . id + ' -fieldset' ,
81+ id : ` ${ this . id } -fieldset` ,
8482 attrs : {
8583 type : 'checkbox' ,
8684 checked : this . get ( 'config.fieldset' ) ,
@@ -118,11 +116,11 @@ export default class Row extends Component {
118116 attrs : {
119117 type : 'text' ,
120118 ariaLabel : 'Legend for fieldset' ,
121- value : _this . get ( 'config.legend' ) ,
119+ value : this . get ( 'config.legend' ) ,
122120 placeholder : 'Legend' ,
123121 } ,
124122 action : {
125- input : ( { target : { value } } ) => _this . set ( 'config.legend' , value ) ,
123+ input : ( { target : { value } } ) => this . set ( 'config.legend' , value ) ,
126124 } ,
127125 className : '' ,
128126 }
@@ -186,9 +184,9 @@ export default class Row extends Component {
186184 return
187185 }
188186
189- const width = parseFloat ( ( 100 / columns . length ) . toFixed ( 1 ) ) / 1
187+ const width = Number . parseFloat ( ( 100 / columns . length ) . toFixed ( 1 ) ) / 1
190188
191- columns . forEach ( column => {
189+ for ( const column of columns ) {
192190 column . removeClasses ( bsColRegExp )
193191 const colDom = column . dom
194192 const newColWidth = numToPercent ( width )
@@ -201,7 +199,7 @@ export default class Row extends Component {
201199 column . refreshFieldPanels ( )
202200 } , ANIMATION_SPEED_FAST )
203201 document . dispatchEvent ( events . columnResized )
204- } )
202+ }
205203
206204 this . updateColumnPreset ( )
207205 }
@@ -283,7 +281,6 @@ export default class Row extends Component {
283281 * @return {Object } columnPresetControlConfig
284282 */
285283 get columnPresetControlConfig ( ) {
286- const _this = this
287284 const layoutPreset = {
288285 tag : 'select' ,
289286 attrs : {
@@ -293,14 +290,7 @@ export default class Row extends Component {
293290 action : {
294291 change : ( { target } ) => {
295292 const { value } = target
296-
297- // forEach(target.children, option => {
298- // option.selected = option.value === value
299- // })
300- // if (value !== 'custom') {
301- // removeCustomOption(this.dom)
302- _this . setColumnWidths ( value )
303- // }
293+ this . setColumnWidths ( value )
304294 } ,
305295 } ,
306296 options : this . getColumnPresetOptions ,
0 commit comments