Bug 63232 - Button is hidden unexpectedly
Summary: Button is hidden unexpectedly
Status: RESOLVED INVALID
Alias: None
Product: WebKit
Classification: Unclassified
Component: CSS (show other bugs)
Version: 528+ (Nightly build)
Hardware: Mac OS X 10.6
: P2 Normal
Assignee: Nobody
URL: http://economic.ideamanagment.ru/vk/
Keywords:
Depends on:
Blocks:
 
Reported: 2011-06-23 00:32 PDT by Anatoly
Modified: 2011-07-18 08:38 PDT (History)
2 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Anatoly 2011-06-23 00:32:02 PDT
At first I created this bug in chromium bug-tracker (http://code.google.com/p/chromium/issues/detail?id=87089). Chromium guys said that this bug in Webkit. So:

What steps will reproduce the problem?
1. Open link: http://economic.ideamanagment.ru/vk/  (sorry for russian language there)
2. Click in any text area with text "Оставить комментарий..." (you can see a button near text area on the right)
3. Go out from the text area and go in again

What is the expected result?
I can see the button near the text area.

What happens instead?
I don't see the button near the text area.

Please provide any additional information below.
Please, see attachments in http://code.google.com/p/chromium/issues/detail?id=87089

In Javascript (using jquery) I change css style for the button this way on focus and blur events:
$('#add_comment_92').css('display', 'inline-block'); - show
$('#add_comment_92').css('display', 'none'); - hide

or:
$('#add_comment_92').show();
$('#add_comment_92').hide();

Doesn't matter. And I'm sure that this bug is not in jquery.

UserAgentString: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_6_7) AppleWebKit/534.30 (KHTML, like Gecko) Chrome/12.0.742.100 Safari/534.30
Comment 1 Alexey Proskuryakov 2011-06-23 12:09:07 PDT
Do you have a reduced test case? Please attach it to this bug if you do.

It would be best if it didn't use jQuery, but any reduction would help.
Comment 2 Anatoly 2011-06-24 05:03:40 PDT
"Do you have a reduced test case? Please attach it to this bug if you do."

Sorry, but I don't have reduced test case. It's because I can't reproduce this bug only on JS (doesn't matter with jquery or not). The bug is happened only if I go in, go out and go in again in textarea manually. But you can reproduce it easy how I described above.

All JS code on this page that is important:
<script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.6.1/jquery.min.js"></script> 
<script type="text/javascript"> 
	$(document).ready(function() {
		var commentDescriptions = $('[id^="comment_description_"]');
 
	    commentDescriptions.live('focus', function() {
			var items = $(this).attr("id").split('_');
			var idea_id = items.pop();
			$('#add_comment_' + idea_id).css('display', 'inline-block');
	        $(this).addClass('open');
	    });
 
	    commentDescriptions.live('blur', function() {
	        if ($(this).val().length == 0 || $(this).val() == $(this).attr("hintValue"))
				var items = $(this).attr("id").split('_');
				var idea_id = items.pop();
	            $('#add_comment_' + idea_id).css('display', 'none');
				$(this).removeClass('open');
	    });
});
</script>
Comment 3 Anatoly 2011-06-24 05:05:13 PDT
I forgot to mention:
All works correctly in Firefox 4.x, Opera 11, IE7+. Bug is exactly on webkit.
Comment 4 Alexey Proskuryakov 2011-07-16 22:42:57 PDT
The site seems to have changed - I cannot follow the steps to reproduce.
Comment 5 Anatoly 2011-07-18 02:02:40 PDT
(In reply to comment #4)
> The site seems to have changed - I cannot follow the steps to reproduce.

Yes. Sorry but we couldn't wait any more and go ahead :( When we'll meet again this bug we'll try to describe it better and without jquery or any other libraries.
Comment 6 Alexey Proskuryakov 2011-07-18 08:38:31 PDT
OK - since we cannot do anything about this, closing the bug.