Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Rendering laid out plain text #145

Open
skwlilac opened this issue May 18, 2021 · 0 comments
Open

Rendering laid out plain text #145

skwlilac opened this issue May 18, 2021 · 0 comments
Assignees

Comments

@skwlilac
Copy link

skwlilac commented May 18, 2021

Sometime we received descriptions and occasionally other plain text or lang-tagged strings for inclusion in register entries.

Currently for a register item descriptions when given are rendered in 3 places in the UI:

  • Above the item's property table wrapped in a <p/> element - which looses any 'manual' layout of the text.
  • In the item's property table itself wrapped in a <td/> element and with the content entity escaped so that any embedded markup in the given description is rendered as part of the text rather than having its intended effect as markup
  • In the item's metadata again wrapped in a <td/> element and with entity escaping of the markup.

In the first case any manual layout is lost; and in the second and third cases any layout markup introduced to address the loss of layout (e.g. replacing line breaks in the text with <br /> elements) are then exposed in other places where the text is presented.

Other approaches, like wrapping the laid out description in a <pre /> tag encounter similar issues due to the different rendering approaches taken for the same string in different parts of the constructed UI page.

It would be nice to find a strategy for embedding and processing markdown text strings in order to provide for the layout of text values.

This seems related to #85.

In a similar way, one could conceive of using datatyping to indicate the presence of a markdown formatted string value, however there is also a need to be able to signal language tagging as well in order to support multi-lingual content (that applies to addressing #85 as well).

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

No branches or pull requests

2 participants