You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Mar 4, 2020. It is now read-only.
Based on discussion from #5
In general, we need to get to a state where the text nodes are inside of elements that have dir='auto' attribute. This allows the browser to detect the text direction.
Proposed solution
If the text is composed of multiple parts (typically a translation with parameters), each of the parts needs to be separated in element. This is however out of scope for Stardust and should be handled in the i18n layer of the application.
Requirements:
use Text component to render any text inside of standard Stardust components
Text component renders <span dir='auto>{content} if the type of content is a string
if user provides HTML/React nodes as an input for the component content, the user is responsible for adding dir='auto' by himself. This needs to be documented
revisit applying of truncateStyle in buttonStyles.ts - it needs to be applied even if the content contains or other elements
The text was updated successfully, but these errors were encountered:
jurokapsiar
changed the title
RTL text renderingin components
RTL text rendering in components
Dec 11, 2018
Feature Request
Problem description
Based on discussion from #5
In general, we need to get to a state where the text nodes are inside of elements that have dir='auto' attribute. This allows the browser to detect the text direction.
Proposed solution
If the text is composed of multiple parts (typically a translation with parameters), each of the parts needs to be separated in element. This is however out of scope for Stardust and should be handled in the i18n layer of the application.
Requirements:
if user provides HTML/React nodes as an input for the component content, the user is responsible for adding dir='auto' by himself. This needs to be documented
The text was updated successfully, but these errors were encountered: