From 61db80a036b947939b6f293d321457bb75b64efd Mon Sep 17 00:00:00 2001 From: "kipp%netscape.com" Date: Mon, 1 Nov 1999 22:54:14 +0000 Subject: [PATCH] r=rods; bug=17518; I updated the html.css file to select on 'a[href]' instead of 'a' so that the focus properties and related style properties would only apply to anchors with href's --- layout/html/document/src/html.css | 23 +++++++---------------- layout/style/html.css | 23 +++++++---------------- 2 files changed, 14 insertions(+), 32 deletions(-) diff --git a/layout/html/document/src/html.css b/layout/html/document/src/html.css index f1774372379..a5d2daa52ea 100644 --- a/layout/html/document/src/html.css +++ b/layout/html/document/src/html.css @@ -202,26 +202,22 @@ q:after { content: close-quote; } -a:link { - display: inline; +a[href]:link { color: blue; text-decoration: underline; cursor: pointer; } -a:visited { - display: inline; +a[href]:visited { color: purple; text-decoration: underline; cursor: pointer; } -a:active { - display: inline; +a[href]:active { color: red; text-decoration: underline; cursor: pointer; } -a:out-of-date { - display: inline; +a[href]:out-of-date { color: lime; text-decoration: underline; cursor: pointer; @@ -425,9 +421,8 @@ img[align=left] { img[align=right] { margin-left: 4px; } -a:link img, a:visited img, a:active img, -a:out-of-date img, img[usemap], object[usemap] { - display: inline; +a[href]:link img, a[href]:visited img, a[href]:active img, +a[href]:out-of-date img, img[usemap], object[usemap] { border: 2px solid; cursor: pointer; } @@ -528,11 +523,7 @@ input[type=hidden] { } /*------- Focus ------*/ -a:focus { - outline: 1px dotted black; -} - -a:focus img { +a[href]:focus, a[href]:focus img { outline: 1px dotted black; } diff --git a/layout/style/html.css b/layout/style/html.css index f1774372379..a5d2daa52ea 100644 --- a/layout/style/html.css +++ b/layout/style/html.css @@ -202,26 +202,22 @@ q:after { content: close-quote; } -a:link { - display: inline; +a[href]:link { color: blue; text-decoration: underline; cursor: pointer; } -a:visited { - display: inline; +a[href]:visited { color: purple; text-decoration: underline; cursor: pointer; } -a:active { - display: inline; +a[href]:active { color: red; text-decoration: underline; cursor: pointer; } -a:out-of-date { - display: inline; +a[href]:out-of-date { color: lime; text-decoration: underline; cursor: pointer; @@ -425,9 +421,8 @@ img[align=left] { img[align=right] { margin-left: 4px; } -a:link img, a:visited img, a:active img, -a:out-of-date img, img[usemap], object[usemap] { - display: inline; +a[href]:link img, a[href]:visited img, a[href]:active img, +a[href]:out-of-date img, img[usemap], object[usemap] { border: 2px solid; cursor: pointer; } @@ -528,11 +523,7 @@ input[type=hidden] { } /*------- Focus ------*/ -a:focus { - outline: 1px dotted black; -} - -a:focus img { +a[href]:focus, a[href]:focus img { outline: 1px dotted black; }