Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 9 May 2006 14:58:48 GMT
From:      Atsushi SUGAWARA <peanutsjamjam@w9.dion.ne.jp>
To:        freebsd-gnats-submit@FreeBSD.org
Subject:   www/97043: [PATCH] Please change the order of a:hover and a:active in text.css
Message-ID:  <200605091458.k49EwmwQ081767@www.freebsd.org>
Resent-Message-ID: <200605091500.k49F0brX022476@freefall.freebsd.org>

next in thread | raw e-mail | index | archive | help

>Number:         97043
>Category:       www
>Synopsis:       [PATCH] Please change the order of a:hover and a:active in text.css
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    freebsd-www
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          change-request
>Submitter-Id:   current-users
>Arrival-Date:   Tue May 09 15:00:37 GMT 2006
>Closed-Date:
>Last-Modified:
>Originator:     Atsushi SUGAWARA
>Release:        FreeBSD 6.1-STABLE i386
>Organization:
>Environment:
System: FreeBSD sweet.local 6.1-STABLE FreeBSD 6.1-STABLE #19: Tue May 9 19:13:09 JST 2006 sugawara@sweet.local:/usr/src/sys/i386/compile/JAMKERNEL i386
>Description:
Please change the order of a:hover and a:active in text.css.

We can not currently see the 'active' color '#990000" while we are pressing mouse button over the links in some FreeBSD Project pages.

URL of text.css:
  http://www.freebsd.org/layout/css/text.css

This file has following 4 lines in this order.
 a:link                          { color:#990000; text-decoration: underline; }
 a:visited                       { color:#990000; text-decoration: underline; }
 a:active                        { color:#990000; text-decoration: underline; }
 a:hover                         { color:#000000; text-decoration: underline; }

Note 'a:hover' rule is currently placed after 'a:active' rule.
This causes the 'a:active' rule to be meaningless.

Because:
 1: While you are pressing mouse button over the A element, the A element's state is both 'active' and 'hover' a
t the same time.
 2: The latter rule would win.

In conclusion, we should place dynamic pseudo-classes in this order:
 link
 visited
 hover
 active

>How-To-Repeat:
1: Go to "The FreeBSD Project" home page http://www.freebsd.org/.
2: Move mouse pointer onto a normal link in the page, e.g. "LATEST RELEASES".
3: You will see the color of the link changes to black. The 'a:hover' rule works. :)
4: Press (do not click) the mouse buttton on the link text.
5: You will see the color of the link does not change to '#990000'. :(

>Fix:
To fix it, we need only to change the order of lines.

--- patch begins here ---
Index: text.css
===================================================================
RCS file: /home/ncvs/www/en/layout/css/text.css,v
retrieving revision 1.3
diff -u -r1.3 text.css
--- text.css    23 Nov 2005 14:22:06 -0000  1.3
+++ text.css    9 May 2006 14:38:33 -0000
@@ -99,13 +99,13 @@

 a:link                          { color:#990000; text-decoration: underline; }
 a:visited                       { color:#990000; text-decoration: underline; }
-a:active                        { color:#990000; text-decoration: underline; }
 a:hover                         { color:#000000; text-decoration: underline; }
+a:active                        { color:#990000; text-decoration: underline; }

 #FOOTER a:link, #footer a:link                { color:#666; text-decoration: underline; }
 #FOOTER a:visited, #footer a:visited             { color:#666; text-decoration: underline; }
-#FOOTER a:active, #footer a:active              { color:#666; text-decoration: underline; }
 #FOOTER a:hover, #footer a:hover               { color:#000000; text-decoration: underline; }
+#FOOTER a:active, #footer a:active              { color:#666; text-decoration: underline; }

 #FRONTNEMSCONTAINER h2, #frontnemscontainer h2 {
   margin: 0;
--- patch ends here ---

>Release-Note:
>Audit-Trail:
>Unformatted:



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200605091458.k49EwmwQ081767>