Releases: NEOSidekick/NEOSidekick.HtmlContent
Releases · NEOSidekick/NEOSidekick.HtmlContent
Release list
v2.0.3: Fix HTML parsing to preserve script tags and UTF-8 encoding
BUGFIX: Fix HTML parsing to preserve script tags and UTF-8 encoding When using DOMDocument::loadHTML, script tags at the beginning of the content were being moved to the head and subsequently lost when extracting the body content. Additionally, UTF-8 characters were not always parsed correctly. This change wraps the input HTML in a body tag and adds an XML encoding declaration before loading it into DOMDocument. This forces DOMDocument to keep script tags in the body and correctly parse UTF-8 characters. Additionally, moved JavaScript detection and removal logic to the DTO and added comprehensive unit tests.
v2.0.2: Compatibility with NEOSidekick.AiAssistant
Resolved naming conflict in EelHelper namespace
v2.0.1: Edge case fixes
Bug fixes
- Fix: No error when HTML property is empty or whitespace (prevents “DOMDocument::loadHTML(): Argument #1 must not be empty”).
- Fix: No false “autofixed closing tags” notice for plain text and valid inline SVG; only fatal libxml issues are treated as invalid; benign warnings (incl. unknown tag 801) are ignored.
- Improvement: More robust post-processing (cleans libxml error buffer, restores state, safer body extraction) with proper handling of mixed HTML + inline SVG.
v2.0.0: Improved error handling and new namespace
There are no more errors about unknown tags, as we now omit this error code. The reason is, that the LibXML library does not correctly detect valid HTML tag names. Moreover, missing closing tags are now automatically fixed and a warning is displayed if there are any.
We also moved the package from codeq/htmlcontent to neosidekick/htmlcontent. To migrate, please do the following steps:
- Run node migration:
./flow node:migrate --version 20240619160000 - The role was renamed from
CodeQ.HtmlContent:EditortoNEOSidekick.HtmlContent:Editor. Please adapt this if you use it as aparentRolein yourPolicy.yaml. Don't forget to re-add the new role to the users. - The following privilege targets were renamed, please change it in your
Policy.yamlNEOSidekick.HtmlContent:CreateNEOSidekick.HtmlContent:EditNEOSidekick.HtmlContent:RemoveNEOSidekick.HtmlContent:EditProperty
Full Changelog: v1.0.0...v2.0.0
v1.0.0 Stable Release
TASK: Add demo video can exclude .idea folder