Edit report at https://bugs.php.net/bug.php?id=80177&edit=1

 ID:                 80177
 User updated by:    php-bugs-2020 at ryandesign dot com
 Reported by:        php-bugs-2020 at ryandesign dot com
 Summary:            Bug tracker package affected lists behave wrong in
                     Safari
 Status:             Open
 Type:               Bug
 Package:            Website problem
 Operating System:   macOS 10.13.6
 PHP Version:        Irrelevant
 Block user comment: N
 Private report:     N

 New Comment:

I think I understand your package-affected.js script now and how this UI widget 
works. The rightmost list is the only list in the HTML and it defines an 
optgroup for each category and options inside them. The JavaScript builds the 
leftmost list by using the optgroup names. It then applies style="display:none" 
to the optgroups on the right so that they disappear. When selecting something 
in the leftmost list, all of the options from the corresponding optgroup in the 
rightmost list are moved to the top level of the rightmost list and become 
visible.

The problem seems to just be that Safari does not honor style="display:none" on 
optgroups. The list manipulation is working, I just have to scroll all the way 
to the bottom of the rightmost list to see the items from the currently 
selected category.

Here is a WebKit bug report from 2006 about not supporting style="display:none" 
on options:

https://bugs.webkit.org/show_bug.cgi?id=8351

Here's one from 2011 about not supporting style="display:hidden" on optgroups:

https://bugs.webkit.org/show_bug.cgi?id=69014

Since WebKit seems not to be fixing these, perhaps your JavaScript could use a 
different strategy. For example, the original full select list could be hidden 
entirely and two new visible select lists could be created: the leftmost one 
the same way it is now, and the rightmost one would be created empty except for 
the "select a category" instructions, and when a category is selected, the 
instructions element would be deleted and the relevant options from the hidden 
list would be moved to the visible list.


Previous Comments:
------------------------------------------------------------------------
[2020-10-02 16:56:42] php-bugs-2020 at ryandesign dot com

Here is a screenshot showing the difference between what happens in Chrome and 
what happens in Safari:

http://ryandesign.com/tmp/bugs.php.net.screen.shot.2020-10-02.png

------------------------------------------------------------------------
[2020-10-02 16:53:13] php-bugs-2020 at ryandesign dot com

Description:
------------
In this bug tracker, the "Package affected" lists are intended to function as a 
two-level selector: first you select the category in the leftmost list, then 
the rightmost list populates with more specific problem types in that category.

This works fine for me in Google Chrome on macOS. When the page loads, no 
selection is made in the leftmost list and the rightmost list is empty except 
for the instruction to select a category. Selecting an item in the leftmost 
list populates the relevant list of choices in the rightmost list.

But it does not work in Apple Safari on macOS. In Safari, it works exactly 
backward. When the page loads, no selection is made in the leftmost list and 
EVERY CATEGORY'S SUBITEMS are shown in the rightmost list. Selecting any 
category in the leftmost list HIDES THAT CATEGORY'S SUBITEMS in the rightmost 
list. It has been this way forever.



------------------------------------------------------------------------



--
Edit this bug report at https://bugs.php.net/bug.php?id=80177&edit=1

-- 
PHP Webmaster List Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to