1 | # property-case
|
2 |
|
3 | Specify lowercase or uppercase for properties.
|
4 |
|
5 |
|
6 | ```css
|
7 | a { width: 1px; }
|
8 | /** ↑
|
9 | * This property */
|
10 | ```
|
11 |
|
12 | The [`fix` option](../../../docs/user-guide/usage/options.md#fix) can automatically fix all of the problems reported by this rule.
|
13 |
|
14 | ## Options
|
15 |
|
16 | `string`: `"lower"|"upper"`
|
17 |
|
18 | ### `"lower"`
|
19 |
|
20 | The following patterns are considered violations:
|
21 |
|
22 |
|
23 | ```css
|
24 | a {
|
25 | Width: 1px
|
26 | }
|
27 | ```
|
28 |
|
29 |
|
30 | ```css
|
31 | a {
|
32 | WIDTH: 1px
|
33 | }
|
34 | ```
|
35 |
|
36 |
|
37 | ```css
|
38 | a {
|
39 | widtH: 1px
|
40 | }
|
41 | ```
|
42 |
|
43 |
|
44 | ```css
|
45 | a {
|
46 | border-Radius: 5px;
|
47 | }
|
48 | ```
|
49 |
|
50 |
|
51 | ```css
|
52 | a {
|
53 | -WEBKIT-animation-duration: 3s;
|
54 | }
|
55 | ```
|
56 |
|
57 |
|
58 | ```css
|
59 | @media screen and (orientation: landscape) {
|
60 | WiDtH: 500px;
|
61 | }
|
62 | ```
|
63 |
|
64 | The following patterns are _not_ considered violations:
|
65 |
|
66 |
|
67 | ```css
|
68 | a {
|
69 | width: 1px
|
70 | }
|
71 | ```
|
72 |
|
73 |
|
74 | ```css
|
75 | a {
|
76 | border-radius: 5px;
|
77 | }
|
78 | ```
|
79 |
|
80 |
|
81 | ```css
|
82 | a {
|
83 | -webkit-animation-duration: 3s;
|
84 | }
|
85 | ```
|
86 |
|
87 |
|
88 | ```css
|
89 | @media screen and (orientation: landscape) {
|
90 | width: 500px;
|
91 | }
|
92 | ```
|
93 |
|
94 | ### `"upper"`
|
95 |
|
96 | The following patterns are considered violations:
|
97 |
|
98 |
|
99 | ```css
|
100 | a {
|
101 | Width: 1px
|
102 | }
|
103 | ```
|
104 |
|
105 |
|
106 | ```css
|
107 | a {
|
108 | width: 1px
|
109 | }
|
110 | ```
|
111 |
|
112 |
|
113 | ```css
|
114 | a {
|
115 | widtH: 1px
|
116 | }
|
117 | ```
|
118 |
|
119 |
|
120 | ```css
|
121 | a {
|
122 | border-Radius: 5px;
|
123 | }
|
124 | ```
|
125 |
|
126 |
|
127 | ```css
|
128 | a {
|
129 | -WEBKIT-animation-duration: 3s;
|
130 | }
|
131 | ```
|
132 |
|
133 |
|
134 | ```css
|
135 | @media screen and (orientation: landscape) {
|
136 | WiDtH: 500px;
|
137 | }
|
138 | ```
|
139 |
|
140 | The following patterns are _not_ considered violations:
|
141 |
|
142 |
|
143 | ```css
|
144 | a {
|
145 | WIDTH: 1px
|
146 | }
|
147 | ```
|
148 |
|
149 |
|
150 | ```css
|
151 | a {
|
152 | BORDER-RADIUS: 5px;
|
153 | }
|
154 | ```
|
155 |
|
156 |
|
157 | ```css
|
158 | a {
|
159 | -WEBKIT-ANIMATION-DURATION: 3s;
|
160 | }
|
161 | ```
|
162 |
|
163 |
|
164 | ```css
|
165 | @media screen and (orientation: landscape) {
|
166 | WIDTH: 500px;
|
167 | }
|
168 | ```
|