Detect Editing is Started in TextBlock

Hello,

I want to set maxSize of textblock to something like

textBlock.maxSize = new go.Size(150,NaN); when user starts editing in textblock.

And on diagram.TextEdited event, I want to change maxSize property to

textBlock.maxSize = new go.Size(NaN, NaN).

When I am overriding textEditingTool.doStart method and setting initial config textBlock.maxSize = new go.Size(150,NaN); than it is showing me warnings like

Change not within a transaction: !d maxSize: Process old: Size(Infinity,Infinity) new: Size(150,Infinity)

Is there any other event, Where we can detect that editing inside textblock is started and we can change its property at run time?

During editing (i.e. during the operation of the TextEditingTool), the size of the edited TextBlock really doesn’t matter. It’s used for the initial sizing of the <textarea>, but once editing has started, the size of the <textarea> is independent of the TextBlock.

So I think you want to customize the text editor (not the TextBlock) not to have a particular width. That is set in the HTMLInfo.show function used by the default editor used by TextEditingTool. I suggest that you read GoJS HTML Interaction -- Northwoods Software and use a slightly modified version of the standard editor, which is given at https://gojs.net/latest/extensions/TextEditor.js and demo’ed at HTMLInfo Text Editor.