-
Notifications
You must be signed in to change notification settings - Fork 0
/
linda.css
55 lines (49 loc) · 1.03 KB
/
linda.css
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
/*
Description: Linting HTML
Author: Andre Kokowin
Author URI: connect2.gmbh
*/
/* Style to make the Inline elements noticeable */
*[style]:after {
content: 'This element has inline styles';
color: red;
outline: 2px dotted red;
}
/* Faulty or Missing Link Targets */
a:not([href]):after,
a[href='#']:after,
a[href='']:after,
a[href*='javascript:void(0)']:after {
content: 'Faulty or Missing Link Targets';
padding: 0 0.5rem;
color: red;
}
/* Unaccessible Images */
img:not([alt]) {
outline: 2px dotted red;
}
/* Missing Document Language */
html:not([lang]):before,
html[lang='']:before {
content: 'Missing Document Language';
color: red;
outline: 2px dotted red;
}
/* Unlabelled Form Elements */
input:not([id]),
select:not([id]),
textarea:not([id]),
label:not([for]),
input:not([name]),
select:not([name]),
textarea:not([name]),
form:not([name]):not([id]) {
outline: 2px dotted red;
}
/* Empty Interactive Elements */
button:empty:after,
a:empty:after {
content: 'Link/Button is empty';
color: red;
padding: 1rem;
}