[css-d] a:hover: size of Background-color?

2013-09-19 Thread John
What attribute governs the size (H x W) of background-color for the 
hover state? I have background-color as rgb black, which appears on 
hover, but only just around the text. I'd like the background color to 
cover a larger area, as delineated by the red border (which will go 
away) in the top left menu. I know this has got to be something 
incredibly simple.


thank you!

John

link:  http://coffeeonmars.com/new/
__
css-discuss [css-d@lists.css-discuss.org]
http://www.css-discuss.org/mailman/listinfo/css-d
List wiki/FAQ -- http://css-discuss.incutio.com/
List policies -- http://css-discuss.org/policies.html
Supported by evolt.org -- http://www.evolt.org/help_support_evolt/


Re: [css-d] a:hover: size of Background-color?

2013-09-19 Thread David Laakso
On Thu, Sep 19, 2013 at 6:43 PM, John j...@coffeeonmars.com wrote:
 What attribute governs the size (H x W) of background-color for the hover
 state? I have background-color as rgb black, which appears on hover, but
 only just around the text. I'd like the background color to cover a larger
 area, as delineated by the red border (which will go away) in the top left
 menu. I know this has got to be something incredibly simple.

 thank you!

 John

Try:

nav ul li a:hover{
display:block;
color:red;
background-color:rgb(0,0,0);
}

Best,
David Laakso

-- 
Chelsea Creek Studio
http://ccstudi.com
__
css-discuss [css-d@lists.css-discuss.org]
http://www.css-discuss.org/mailman/listinfo/css-d
List wiki/FAQ -- http://css-discuss.incutio.com/
List policies -- http://css-discuss.org/policies.html
Supported by evolt.org -- http://www.evolt.org/help_support_evolt/


Re: [css-d] a:hover: size of Background-color?

2013-09-19 Thread John

On 9/19/13 4:09 PM, David Laakso wrote:

nav ul li a:hover{
display:block;
color:red;
background-color:rgb(0,0,0);
}
Thank you and that works, but why doesn't a:hover simply inheret 
display:block from nav ul li, its parent?


John
__
css-discuss [css-d@lists.css-discuss.org]
http://www.css-discuss.org/mailman/listinfo/css-d
List wiki/FAQ -- http://css-discuss.incutio.com/
List policies -- http://css-discuss.org/policies.html
Supported by evolt.org -- http://www.evolt.org/help_support_evolt/


Re: [css-d] a:hover: size of Background-color?

2013-09-19 Thread Philippe Wittenbergh

Le 20 sept. 2013 à 08:13, John j...@coffeeonmars.com a écrit :

 why doesn't a:hover simply inherit display:block from nav ul li, its parent?

The 'display' property is never inherited!

http://www.w3.org/TR/CSS21/visuren.html#propdef-display
 Inherited:no


You should set  'nav ul li a' to display:block; the hover state will also be 
block - and as a side benefit, you get a much bigger 'click' area.

Philippe
--
Philippe Wittenbergh
http://l-c-n.com




__
css-discuss [css-d@lists.css-discuss.org]
http://www.css-discuss.org/mailman/listinfo/css-d
List wiki/FAQ -- http://css-discuss.incutio.com/
List policies -- http://css-discuss.org/policies.html
Supported by evolt.org -- http://www.evolt.org/help_support_evolt/