-
Notifications
You must be signed in to change notification settings - Fork 838
Open
Description
Describe the bug
The extension's response window fails to render Right-to-Left (RTL) text correctly on certain websites that enforce a global direction: ltr
style. For Persian (Farsi) responses, the text is incorrectly displayed as LTR.
To Reproduce
- Go to a website with aggressive global LTR styles, for example:
https://f95zone.to/
- Select any text and use a prompt that generates a Persian (Farsi) response.
- Observe the response window: the Persian text is aligned to the left (LTR) instead of the right (RTL).
Expected behavior
The response window should always respect the text's directionality, rendering RTL languages like Persian correctly, regardless of the host page's CSS.
Technical Suggestion for a permanent fix:
This is a classic CSS specificity issue. To make the extension more resilient, I recommend isolating its styles from the host page. The best architectural approaches would be:
- Using Shadow DOM: Encapsulate the extension's window in a Shadow DOM to create a completely isolated CSS scope. This is the most robust solution.
- Using higher specificity selectors or inline styles: As a simpler alternative, ensure the extension's CSS rules for directionality have extremely high specificity or are applied as inline styles to the container element to prevent overrides.
Thank you for this great extension!
Metadata
Metadata
Assignees
Labels
No labels