Skip to content

Commit 3ffe2a5

Browse files
committed
Document appearance-none
Also create appearance-none lol
1 parent 0ff468c commit 3ffe2a5

File tree

3 files changed

+42
-19
lines changed

3 files changed

+42
-19
lines changed

__tests__/fixtures/tailwind.css

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -586,7 +586,7 @@ button,
586586
}
587587
}
588588

589-
.input-reset {
589+
.appearance-none {
590590
appearance: none;
591591
}
592592

@@ -3525,7 +3525,7 @@ button,
35253525
}
35263526

35273527
@media (min-width: 576px) {
3528-
.sm\:input-reset {
3528+
.sm\:appearance-none {
35293529
appearance: none;
35303530
}
35313531

@@ -6465,7 +6465,7 @@ button,
64656465
}
64666466

64676467
@media (min-width: 768px) {
6468-
.md\:input-reset {
6468+
.md\:appearance-none {
64696469
appearance: none;
64706470
}
64716471

@@ -9405,7 +9405,7 @@ button,
94059405
}
94069406

94079407
@media (min-width: 992px) {
9408-
.lg\:input-reset {
9408+
.lg\:appearance-none {
94099409
appearance: none;
94109410
}
94119411

@@ -12345,7 +12345,7 @@ button,
1234512345
}
1234612346

1234712347
@media (min-width: 1200px) {
12348-
.xl\:input-reset {
12348+
.xl\:appearance-none {
1234912349
appearance: none;
1235012350
}
1235112351

docs/source/docs/forms.blade.md

Lines changed: 36 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -5,18 +5,41 @@ title: "Forms"
55

66
# Forms
77

8-
<div class="mt-8">
9-
<div class="bg-blue-lightest border-l-4 border-blue-light rounded-b text-blue-darkest px-4 py-3">
10-
<div class="flex">
11-
<div class="py-1">
12-
<svg class="h-6 w-6 text-blue-light mr-4" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 20 20"><path d="M10 20C4.477 20 0 15.523 0 10S4.477 0 10 0s10 4.477 10 10-4.477 10-10 10zm0-2c4.418 0 8-3.582 8-8s-3.582-8-8-8-8 3.582-8 8 3.582 8 8 8zm-.5-5h1c.276 0 .5.224.5.5v1c0 .276-.224.5-.5.5h-1c-.276 0-.5-.224-.5-.5v-1c0-.276.224-.5.5-.5zm0-8h1c.276 0 .5.224.5.5V8l-.5 3-1 .5L9 8V5.5c0-.276.224-.5.5-.5z"/></svg>
13-
</div>
14-
<div>
15-
<p class="font-semibold">Work in progress!</p>
16-
<p class="text-sm">More detailed documentation is coming soon.</p>
17-
</div>
18-
</div>
19-
</div>
8+
<div class="text-xl text-slate-light mb-4">
9+
Utilities for styling form controls.
10+
</div>
11+
12+
@include('_partials.feature-badges', [
13+
'responsive' => true,
14+
'customizable' => false,
15+
'hover' => false,
16+
'focus' => false
17+
])
18+
19+
@include('_partials.work-in-progress')
20+
21+
<div class="border-t border-grey-lighter">
22+
<table class="w-full text-left" style="border-collapse: collapse;">
23+
<colgroup>
24+
<col class="w-1/5">
25+
<col class="w-1/3">
26+
<col>
27+
</colgroup>
28+
<thead>
29+
<tr>
30+
<th class="text-sm font-semibold text-grey-darker p-2 bg-grey-lightest">Class</th>
31+
<th class="text-sm font-semibold text-grey-darker p-2 bg-grey-lightest">Properties</th>
32+
<th class="text-sm font-semibold text-grey-darker p-2 bg-grey-lightest">Description</th>
33+
</tr>
34+
</thead>
35+
<tbody class="align-baseline">
36+
<tr>
37+
<td class="p-2 border-t border-smoke font-mono text-xs text-purple-dark">.appearance-none</td>
38+
<td class="p-2 border-t border-smoke font-mono text-xs text-blue-dark">appearance: none;</td>
39+
<td class="p-2 border-t border-smoke text-sm text-grey-darker">Remove any special styling applied to an element by the browser.</td>
40+
</tr>
41+
</tbody>
42+
</table>
2043
</div>
2144

2245
### Custom Select
@@ -25,7 +48,7 @@ Form controls are great candidates for component classes, but just for fun, here
2548

2649
@component('_partials.code-sample', ['lang' => 'html', 'class' => 'text-center'])
2750
<div class="inline-block relative w-64">
28-
<select class="block input-reset w-full bg-white border border-smoke-dark hover:border-slate-light px-4 py-2 pr-8 rounded shadow">
51+
<select class="block appearance-none w-full bg-white border border-grey-light hover:border-grey px-4 py-2 pr-8 rounded shadow">
2952
<option>Really long option that will likely overlap the chevron</option>
3053
<option>Option 2</option>
3154
<option>Option 3</option>

src/generators/forms.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,6 @@ import defineClasses from '../util/defineClasses'
22

33
export default function() {
44
return defineClasses({
5-
'input-reset': { 'appearance': 'none' },
5+
'appearance-none': { 'appearance': 'none' },
66
})
77
}

0 commit comments

Comments
 (0)