Using FF 2.0.0.5 (Windows) with latest 6.x development snapshot there is an extra space between the textarea and its dragger (see attached screenshot). This does for some reason not appear on all pages, e.g. not in create page/story, but on other pages (e.g. user settings).

Comments

dvessel’s picture

This also happens on Safari.

I suspect it's due to the text area and gripping being wrapped in a span tag which is really bad form.

dvessel’s picture

Okay, it's not due to the span. It's because a property was changed.

html.js .resizable-textarea textarea {
  margin-bottom: 0;
  width: 100%;
}

display: block; used to be in Drupal 5 and was removed.

Still that span has gotta go.

gábor hojtsy’s picture

That display: block used to cause other issues AFAIR. You can look up the CVS blame logs to find out the exact issue.

profix898’s picture

dvessel is right, adding 'display:block;' to 'html.js .resizable-textarea textarea' solves the problem.
see http://cvs.drupal.org/viewcvs/drupal/drupal/modules/system/system.css?r1...

gábor hojtsy’s picture

Yes, but it introduces a problem which looks worse: I'd rather see a few pixels space then a scrollbar. Read this: http://drupal.org/node/146462#comment-254921 (and the notes before). If you have a fix which does not exhibit any of the two problems, then show us please! It would be very welcome.

dvessel’s picture

Holy shit! What a messy queue.

Looks like the only issue for removing the block property is that it breaks teaser.js by displaying the teaser field when it shouldn't be doing so. --node edit form

The odd thing is that the textarea is always calculated as "display:block". Done by the script I guess but can't find where it's doing that. Must be jQuery itself.

Somehow, having the block display property is preventing the span tag from being hidden. The span is the parent wrapper so it shouldn't know about the css style of it's children. In this case being the textarea..

I'm confused.

dvessel’s picture

Component: Garland theme » theme system
Status: Active » Needs review
StatusFileSize
new596 bytes

Okay, never mind what I just said. I think this should fix it.

Setting "display: block" caused this bit here to inherit the display property.

    // Inherit visibility
    if ($(this).is(':hidden')) { // <- display: block != :hidden.
      $(this).parent().hide();
      $(this).show();
    }

All I did was change ":hidden" to "[@disabled]" which looks at its setting. Also added the block property to style.css.

And that span tag is fine I guess. Was generated with jQuery.

Please review.

dvessel’s picture

StatusFileSize
new1.07 KB

Whoops, forgot system.css.

dvessel’s picture

Let me just clarify that "disabled" is form attribute and [@disabled] just checks for its existence.

The code in teaser.js toggles it on and off when hitting the split button.

When the form is initially loaded, it has the disabled attribute in place if it was never split. Inversely, it doesn't exist when it is split. So, just checking if it's there works since the inherited visibility check is run only when it's loaded. Could be more verbose with [@disabled=disabled] but it doesn't look like it is needed.

dvessel’s picture

This patch also fixes another issue with Opera where resizable log field ends up getting hidden.

http://drupal.org/node/164698

dvessel’s picture

Priority: Normal » Critical

Marking this as critical due to the issue with Opera which breaks functionality.

dvessel’s picture

Yes, but it introduces a problem which looks worse: I'd rather see a few pixels space then a scrollbar. Read this: http://drupal.org/node/146462#comment-254921 (and the notes before). If you have a fix which does not exhibit any of the two problems, then show us please! It would be very welcome.

Gábor Hojtsy, That scroll bar issue while animating collapsable fieldsets has nothing to do with display: block. Not on the Mac side at least. I've run into that in other situations and there doesn't seem to be any workarounds.

I saw a bigger issue so I forgot to mention that.

dvessel’s picture

Title: Additional space between textarea and dragger in FF2 » Gap between textarea and grippie.

http://drupal.org/node/146462#comment-251029

...Have a look at admin/user/settings after updating your drupal install with this patch.
When you click any collapsible fieldset which has a textarea inside it with a vertical scrollbar, the scrollbar appears before the fieldset is expanded and hides after the fieldset is collapsed.

That's what http://drupal.org/node/146462#comment-254921 was referring to. It's an issue with FireFox. Easily reproducible on the Mac with no known workarounds. display: block does not cause it.

Might be different on the Windows or Linux. Would be great if someone took a closer look.

dvessel’s picture

I just tested this in IE6. Works there too.

Tested so far:
Safari 2
Opera 9.20/9.22
FireFox 2 win/mac
IE6

dvessel’s picture

Title: Gap between textarea and grippie. » fix hidden textareas in Opera. (and remove gap from grippie)

Uhm, maybe this'll grab more attention.

dmitrig01’s picture

Status: Needs review » Reviewed & tested by the community
litwol’s picture

shameless bump. this is rather important and must not be ignored. needs to be committed

dvessel’s picture

StatusFileSize
new1.07 KB

hunk offset fixed.

gábor hojtsy’s picture

Status: Reviewed & tested by the community » Fixed

Thanks, committed!

Anonymous’s picture

Status: Fixed » Closed (fixed)
gábor hojtsy’s picture

Hm, as reported by Lynn, this broke the display of #disabled and #resizable textareas (which are hidden due to this JS change). I am thinking about rolling back this patch, although it fixes two bugs at once, since it does introduce a critical bug with "information" textareas disappearing. Maybe someone can hop over to http://drupal.org/node/204756 and help us find a different solution there instead of rolling this back?