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

Different style gets applied to same tag(strong, em, del) in Android for single html render which considers either tag(strong), tag(body) or baseStyle properties #626

Open
11 of 15 tasks
Pujan92 opened this issue Mar 20, 2023 · 2 comments
Labels
bug:upstream The bug is caused by a third party library. bug Crush'em all.

Comments

@Pujan92
Copy link

Pujan92 commented Mar 20, 2023

Decision Table

  • My issue does not look like “The HTML attribute 'xxx' is ignored” (unless we claim support for it)
  • My issue does not look like “The HTML element <yyy> is not rendered”

Good Faith Declaration

Description

For the same tag(strong) in html render

  • for some <strong> elements it is applying the styles of tagsStyles
  • for some <strong> elements it is considering body tag style or baseStyle in case of TRenderEngineProvider

It is happening only for Android.

Screenshot 2023-03-20 at 11 01 09 PM

React Native Information

confer snack

RNRH Version

6.3.1

Tested Platforms

  • Android
  • iOS
  • Web
  • MacOS
  • Windows

Reproduction Platforms

  • Android
  • iOS
  • Web
  • MacOS
  • Windows

Minimal, Reproducible Example

https://snack.expo.dev/@pujan92/render-html-snippet?platform=android

Additional Notes

No response

@Pujan92 Pujan92 added the bug Crush'em all. label Mar 20, 2023
@Pujan92 Pujan92 changed the title TagsStyles & BaseStyle ambiguity in Android which causes different style gets applied to same tag(strong) in single html content Different style gets applied to same tag(strong) in Android single html render which considers either tag(strong), tag(body) or baseStyle properties Mar 20, 2023
@Pujan92 Pujan92 changed the title Different style gets applied to same tag(strong) in Android single html render which considers either tag(strong), tag(body) or baseStyle properties Different style gets applied to same tag(strong) in Android for single html render which considers either tag(strong), tag(body) or baseStyle properties Mar 20, 2023
@Pujan92 Pujan92 changed the title Different style gets applied to same tag(strong) in Android for single html render which considers either tag(strong), tag(body) or baseStyle properties Different style gets applied to same tag(strong, em, del) in Android for single html render which considers either tag(strong), tag(body) or baseStyle properties Mar 20, 2023
@jsamr
Copy link
Collaborator

jsamr commented Mar 20, 2023

@Pujan92

It is happening only for Android.

That's clearly a hint that the bug is with React Native; strongly reminds me of this one: facebook/react-native#31826

You may want to try the Fabric rendering engine, which might have a fix for this.

@jsamr jsamr added the bug:upstream The bug is caused by a third party library. label Mar 20, 2023
@Pujan92
Copy link
Author

Pujan92 commented Mar 21, 2023

I thought as we are passing the different sets of styles to the RenderHtml which might be responsible for the issue cause, but Thanks @jsamr for informing about the issue persists with React Native.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug:upstream The bug is caused by a third party library. bug Crush'em all.
Projects
None yet
Development

No branches or pull requests

2 participants