-
Notifications
You must be signed in to change notification settings - Fork 18
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
MarkupText only renders first child when using fallback #20
Comments
This is because the following code seems to pick only the first child. preact-i18n/src/components/text.js Line 44 in 0287d0f
|
That is likely the issue. I would be happy to review a PR that changes it to just |
I changed it to |
Sorry try changing preact-i18n/src/lib/translate-mapping.js Line 31 in 8a43fc7
Your working example: https://codesandbox.io/s/31rq37xnn5 |
Hey @azizhk, thank you. Although that fixes the problem, it lets a bunch of other test cases fail. |
Is there a chance of this getting fixed and released any time soon? It's currently blocking us from rolling out our app in another location. |
@pl12133 sure, but the fix brings a whole lot of other issues when you run the tests that I'm not able to fix. |
Created a PR #21 |
This is resolved in |
Same issue with the basic |
Steps:
en.json
and locatenews.title
property<span>This <em>should work</em></span>
news.title
inindex.js
tonews.whatever
Expected Result:
The default text
<span>This <b>This doesnt work</b></span>
is rendered in the result window
Actual Result:
<span>This </span>
is rendered in the result window
The text was updated successfully, but these errors were encountered: