Skip to content
This repository was archived by the owner on Sep 5, 2025. It is now read-only.

Commit d40faf1

Browse files
committed
Merge pull request #887 from mrwweb/html5-inputs
List all HTML5 input types. Props @mrwweb
2 parents cdd101e + 9ccc1fa commit d40faf1

2 files changed

Lines changed: 61 additions & 3 deletions

File tree

sass/forms/_fields.scss

Lines changed: 25 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,16 @@ input[type="email"],
33
input[type="url"],
44
input[type="password"],
55
input[type="search"],
6+
input[type="number"],
7+
input[type="tel"],
8+
input[type="range"],
9+
input[type="date"],
10+
input[type="month"],
11+
input[type="week"],
12+
input[type="time"],
13+
input[type="datetime"],
14+
input[type="datetime-local"],
15+
input[type="color"],
616
textarea {
717
color: $color__text-input;
818
border: 1px solid $color__border-input;
@@ -13,11 +23,25 @@ textarea {
1323
}
1424
}
1525

26+
select {
27+
border: 1px solid $color__border-input;
28+
}
29+
1630
input[type="text"],
1731
input[type="email"],
1832
input[type="url"],
1933
input[type="password"],
20-
input[type="search"] {
34+
input[type="search"],
35+
input[type="number"],
36+
input[type="tel"],
37+
input[type="range"],
38+
input[type="date"],
39+
input[type="month"],
40+
input[type="week"],
41+
input[type="time"],
42+
input[type="datetime"],
43+
input[type="datetime-local"],
44+
input[type="color"] {
2145
padding: 3px;
2246
}
2347

style.css

Lines changed: 36 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ Nicolas Gallagher and Jonathan Neal http://necolas.github.com/normalize.css/
3535
# Clearings
3636
# Widgets
3737
# Content
38-
## Posts and pages
38+
## Posts and pages
3939
## Asides
4040
## Comments
4141
# Infinite scroll
@@ -461,17 +461,41 @@ input[type="email"],
461461
input[type="url"],
462462
input[type="password"],
463463
input[type="search"],
464+
input[type="number"],
465+
input[type="tel"],
466+
input[type="range"],
467+
input[type="date"],
468+
input[type="month"],
469+
input[type="week"],
470+
input[type="time"],
471+
input[type="datetime"],
472+
input[type="datetime-local"],
473+
input[type="color"],
464474
textarea {
465475
color: #666;
466476
border: 1px solid #ccc;
467477
border-radius: 3px;
468478
}
469479

480+
select {
481+
border: 1px solid #ccc;
482+
}
483+
470484
input[type="text"]:focus,
471485
input[type="email"]:focus,
472486
input[type="url"]:focus,
473487
input[type="password"]:focus,
474488
input[type="search"]:focus,
489+
input[type="number"]:focus,
490+
input[type="tel"]:focus,
491+
input[type="range"]:focus,
492+
input[type="date"]:focus,
493+
input[type="month"]:focus,
494+
input[type="week"]:focus,
495+
input[type="time"]:focus,
496+
input[type="datetime"]:focus,
497+
input[type="datetime-local"]:focus,
498+
input[type="color"]:focus,
475499
textarea:focus {
476500
color: #111;
477501
}
@@ -480,7 +504,17 @@ input[type="text"],
480504
input[type="email"],
481505
input[type="url"],
482506
input[type="password"],
483-
input[type="search"] {
507+
input[type="search"],
508+
input[type="number"],
509+
input[type="tel"],
510+
input[type="range"],
511+
input[type="date"],
512+
input[type="month"],
513+
input[type="week"],
514+
input[type="time"],
515+
input[type="datetime"],
516+
input[type="datetime-local"],
517+
input[type="color"] {
484518
padding: 3px;
485519
}
486520

0 commit comments

Comments
 (0)