Fix resizing state bug

master
Joshua Sigona 3 years ago
parent 911ba668a4
commit e487851f92
  1. 4
      src/skilltree/skillTreeEditor.js

@ -65,6 +65,7 @@ function SkillTreeEditor(p) {
for (var x=0;x<skillLines[y].length;x++) {
var padX = x!==0?gridPaddingX*x:0
var padY = y!==0?gridPaddingY*y:0
if (y<dimensionY&&x<dimensionX) {
controls.push(<SkillTreeSelector GetData={p.GetData} cl={Number(cl)} defaultValue={skillLines[y][x]} callback={(char,x,y)=>{
var string = [...skillLines]
var stringLine = string[y].split('')
@ -75,8 +76,9 @@ function SkillTreeEditor(p) {
} ADJUSTMENT={ADJUSTMENT} x={x} y={y} gridSizeX={gridSizeX} gridSizeY={gridSizeY} padX={padX} padY={padY}/>)
}
}
}
setRenderedInputs(controls)
},[skillLines,gridSizeX,gridSizeY,gridPaddingX,gridPaddingY,cl])
},[skillLines,gridSizeX,gridSizeY,gridPaddingX,gridPaddingY,cl,dimensionY,dimensionX])
return <>
<label for="classSelect">Class Select:</label><select id="classSelect" value={cl} onChange={(f)=>{setCl(f.currentTarget.value)}}>

Loading…
Cancel
Save