element()

in src/ui/editor/complex/AIntDiff.tsx [19:37]


  element() {
    const value = super.getValue();
    const sign = this._radio ?? MUtil.sign(value);
    const radioStyle = {
      display: 'block',
      marginBottom: 3
    };

    return <Radio.Group key={this.state.ctrlVersion} defaultValue={sign} onChange={(v)=>{
      const sign = v.target.value;
      if(sign < 0){
        super.changeValue(this._negInputBoxValue);
      } else if(sign > 0){
        super.changeValue(this._posInputBoxValue);
      } else {
        super.changeValue(0);
      }
      this._radio = sign;
      }}>