Open Navipro70 opened 1 year ago
Maybe someone else meet this issue, just add next code to props, it will fix it
customHTMLElementModels = {{
lh: HTMLElementModel.fromCustomModel({
contentModel: HTMLContentModel.textual,
mixedUAStyles: {
backgroundColor: colors.white,
transform: [{ translateX: -12 }],
},
tagName: 'li',
})
}}
We should definitely support LH tag properly. Reopening to track this effort
Decision Table
<yyy>
is not rendered”Good Faith Declaration
Description
I have next html with
<lh></lh>
tag:Current behavior: Library ignores
<lh></lh>
tag and renders as standard<li></li>
tag, but without text and with bulletExpected behavior: Library renders it as list header tag without marker (bullet, etc.) and with text
Maybe library has posibility to ignore marker (bullet) for specific tag, for example with
<lh style="list-style-type: none;"></lh>
or by overriding the tag specs incustomHTMLElementModels
, but I've read docs and didn't find any solutionReact Native Information
RNRH Version
"react-native-render-html": "^6.3.4"
Tested Platforms
Reproduction Platforms
Minimal, Reproducible Example
-
Additional Notes
Example with screenshots for html:
Current behavior:
Expected behavior: