Skip to content

Conversation

@wanglin86769
Copy link
Contributor

It seems that the previous PR #3413 affects the behavior of Olog, and the approach is not appropriate. So this PR takes a different approach.

For Elog, there are three kind of encodings as follows,

plain
image

ELCode
image

HTML
image

For HTML encoding, the newline is controlled by the <p> tag and whitespace by &nbsp;, so there is no problem when displayed on Olog UI.

For plain encoding, this PR wraps the Elog text inside <p style="white-space: pre-wrap;"></p> tag in order to preserve whitespaces.

@shroffk
Copy link
Member

shroffk commented Jun 6, 2025

@georgweiss can we merge this

@wanglin86769
Copy link
Contributor Author

I just observed that when editing a log entry with plain text encoding, the <p> tag for wrapping also shows up as follows, which is not expected.

Probably this PR is not a good solution either and I am closing it.

image

@georgweiss
Copy link
Collaborator

georgweiss commented Jun 11, 2025

Actually embedding HTML in Markdown is OK, and that's why you see the <p> tags in the editor. That said, the "editor" is a plain TextArea component, so it won't process neither HTML or Markdown.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants