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

add fallback template for HTML tags #196

Merged
merged 2 commits into from
Feb 8, 2024
Merged

add fallback template for HTML tags #196

merged 2 commits into from
Feb 8, 2024

Conversation

peterstadler
Copy link
Member

This PR fixes #193 by introducing a fallback template for arbitrary HTML tags.
Unknown HTML tags will be stripped off which needs to be documented/warned about in the FAQ.

Copy link
Collaborator

@peterprovaznik peterprovaznik left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks very good to me!

Edit: Sorry, when checking with the image just to be sure, I noticed that the content that used to be in for example a <h2> tag is now a direct child of the <annot> element... are we ok with that?

<annot>
  ...
  <p>
    <rend fontstyle="italic">Please note: The content of this file has been modified for demonstration purposes and does not represent accurate real-world data.</rend>
    </p>
     add fallback template for HTML tags
    <rend>#196</rend>
  </annot>

@peterstadler
Copy link
Member Author

I agree that the result is not "great" in terms of MEI (or text structure in general) but there seems to be no easy solution to filter out all possible (eventually nested) HTML elements and wrap them appropriately.

My proposal would be to merge this PR since it fixes the initial bug of destroyed TinyMCE editor and look after improving the output in a later step.

@daniel-jettka daniel-jettka merged commit 615725c into develop Feb 8, 2024
6 checks passed
@daniel-jettka daniel-jettka deleted the issue-193 branch February 8, 2024 13:18
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.

Problem with pasting HTML into TinyMCE
4 participants