Hopefully a straightforward question, but perhaps not. For a site I’m working on at the moment, I’d like to be able to give users the ability to control the indentation inside a textarea field by entering spaces preceding lines of text. Currently, doing so would change the text to a code block. Is there any way to change this behaviour so the kirbytext processor turns each space preceding text on a new line into characters?
It’s an odd use case, but my users will be posting poetry that requires some quirky line indents. None of them are technical enough to know about adding classes to <P> tags for example, which is a solution I’d considered too.
You could probably use a kirbytext pre filter: https://getkirby.com/docs/developer-guide/kirbytext/filters to prevent the default markdown behaviour and convert those spaces to characters, maybe this is possible with some regex voodoo.
That Kirbytag could then also use a class with a left padding/margin instead of inserting spaces directly. Spaces are not very semantic as they are only used for presentation purposes in your use-case, so using CSS would make more sense.