Disable editor after certain height/lines

Hi guys, I would like to have a fixed height editor and disable editing beyond a maximum height. The user should still be able to update the content before the maximum height but not be able to add text after that. I am trying to prevent scrolling and just provide a fixed height editing experience.

I am able to set the fixed height in css but the editor still allows editing. Is there a way to achieve this?

1 Like

A transaction filter that blocks transactions that make the content too high might work for this. But that works purely on the state level, so unless you want to simply limit it at a given number of blocks, it might be somewhat involved to get the accurate content height at that point (where it hasn’t even been drawn yet).

Thank you for the suggestion. I will try using a transaction filter.