When iview uses render to create Input components, automatic focus can only be triggered once?

using the iview framework, I want to implement a click of a button to trigger the automatic focus function of Input. The key code is as follows:

render: (h, params) => {
    if(params.index == this.editIndex){ //Input
        return h("Input", {
            props: {
                value: params.row.name,
                autofocus: true    // iview Input
            },
            on: {
                "on-focus": (e) => {    //input
                    this.editIndexText = params.row.name
                    e.srcElement.select();
                },
                "on-blur": (e) => {    //index
                    this.editIndex = -1;
                    console.log(e)

                },
                "on-keyup": (e) => {
                    console.log(e)
                    if(e.code == "Enter"){
                        this.editIndex = -1;
                    }
                }
            }
        }, params.row.name)
    }else{    //
        return h("p", params.row.name)
    }

when you click modify, render renders the Input component and automatically gets the focus, but the effect is only displayed for the first time.

clipboard.png

the reason is why, is there a solution? I"ve been studying it for a long time. Ask the Great God to tell.

Sep.18,2021

the reason is unknown.
use ref to specify Input, and click the modified $nextTick to solve

. The reason for
  

is very simple. In fact, whether you use render or Input, directly used in template, if Input exists in the html document from beginning to end, autofocus will only be triggered once. Because when the Input is generated, the focus defaults to the Input element, so if you click somewhere else, does it still let the focus come back automatically? Although the Input box is sometimes hidden, it is still in the document, so when it is displayed again, it just changes the display property and certainly cannot focus the past again (focus again is unreasonable). The
solution is usually to use JS to call the focus function of the virtual DOM of the Input component when focus is needed. You can use refs.

Menu