There's some code in textarea.js in charge of aligning the grippie by adding a margin (usually negative). For RTL layouts it should be a left margin rather than a right one.
Replacing:

    grippie.style.marginRight = (grippie.offsetWidth - $(this)[0].offsetWidth) +'px';

with:

    if( $(this).css("direction") === "rtl" ) {
      grippie.style.marginLeft = (grippie.offsetWidth - $(this)[0].offsetWidth) +'px';
    } else {
      grippie.style.marginRight = (grippie.offsetWidth - $(this)[0].offsetWidth) +'px';
    }

did the trick for me (tested on FF3 and IE6).

Comments

adrinux’s picture

Version: 6.12 » 6.17
Status: Active » Needs review
StatusFileSize
new698 bytes

Just came across this on 6.17 (not my site, I'm just theming), and above snippet does fix the issue.

Attached is a patch with the same code.

Status: Needs review » Needs work

The last submitted patch, 470488_d6_grippie_rtl.patch, failed testing.

adrinux’s picture

StatusFileSize
new14.13 KB

Here's a screenie of the issue in safari. It's the core contact page textarea, after add 'Arabic' language and switching to it. This is from Drupal-6.20.

adrinux’s picture

Title: RTL grippie glitch » Textarea grippie shifts several px to the right on RTL pages
Version: 6.17 » 6.20
Priority: Minor » Normal
Status: Needs work » Needs review
StatusFileSize
new747 bytes

More verbose title, update version since it still exists, priority to normal and set to needs review. New patch attached, generated from git 6.x branch.
Apply patch with:
patch -p1 < 470488_d6_grippie_rtl-2.patch

(Lets hope the testing bot can apply this one.)

Status: Needs review » Needs work

The last submitted patch, 470488_d6_grippie_rtl-2.patch, failed testing.

adrinux’s picture

Status: Needs work » Needs review
StatusFileSize
new739 bytes

OK test bot. this one is made with git diff's --no-prefix flag. Maybe you can handle that?

Status: Needs review » Needs work

The last submitted patch, 470488_d6_grippie_rtl-3.patch, failed testing.

adrinux’s picture

Status: Needs work » Needs review
StatusFileSize
new739 bytes

Does test bot only test against d7 now or something? This patch applies perfectly to the remotes/origin/6.x branch on git.drupalcode.org. One more try for test bot.

For any humans which which need the patch please just pop in in your drupal root folder and do:

patch -p0 < 470488_d6_grippie_rtl-5.patch

Status: Needs review » Needs work

The last submitted patch, 470488_d6_grippie_rtl-5.patch, failed testing.

adrinux’s picture

Status: Needs work » Reviewed & tested by the community

Giving up. Patch works and can be easily applied by me.

sepla’s picture

Status: Reviewed & tested by the community » Needs work

adrinux is right, I second it. The patch also works fine for me, I'll attach a well-formed one asap, so it might pass the PIFR tests. I wonder why this issue is so unloved in the queue, thanks adrinux.

adrinux’s picture

Status: Needs work » Needs review

#8: 470488_d6_grippie_rtl-5.patch queued for re-testing.

Status: Needs review » Needs work

The last submitted patch, 470488_d6_grippie_rtl-5.patch, failed testing.

sepla’s picture

Version: 6.20 » 6.x-dev

I had the same testbot issue in #1091000: uc_store_format_price_field_value() does not respect decimal marker:

The testbot doesn't currently work properly on fixed-point releases, so I'm changing the version of this issue to 6.x-2.x-dev.

So I'm changing this to 6.x-dev to see if it works.

sepla’s picture

Status: Needs work » Needs review

#8: 470488_d6_grippie_rtl-5.patch queued for re-testing.

Status: Needs review » Needs work

The last submitted patch, 470488_d6_grippie_rtl-5.patch, failed testing.

tr’s picture

Issue tags: +RTL

Tagging

josevitalsouto’s picture

Title: Textarea grippie shifts several px to the right on RTL pages » Fix for grippie position on RTL pages
Assigned: Unassigned » josevitalsouto
StatusFileSize
new829 bytes
josevitalsouto’s picture

StatusFileSize
new870 bytes
sepla’s picture

AFAIK you need to provide a --no-prefix patch..

josevitalsouto’s picture

Priority: Normal » Major
Status: Needs work » Active
josevitalsouto’s picture

Status: Active » Needs review
StatusFileSize
new870 bytes
good_man’s picture

Status: Needs review » Needs work
+++ b/misc/textarea.js
@@ -13,7 +13,11 @@ Drupal.behaviors.textarea = function(context) {
+    } else {
+      grippie.style.marginRight = (grippie.offsetWidth - $(this)[0].offsetWidth) +'px';
+    }

Follow Drupal conventions, else should be located on new line.

1 days to next Drupal core point release.

Status: Needs work » Closed (outdated)

Automatically closed because Drupal 6 is no longer supported. If the issue verifiably applies to later versions, please reopen with details and update the version.