Merge pull request #143 from mkody/feature-more-form-types
Support more input form types
This commit is contained in:
commit
0658e4282e
|
@ -2,7 +2,7 @@
|
|||
* Milligram v1.3.0
|
||||
* https://milligram.github.io
|
||||
*
|
||||
* Copyright (c) 2017 CJ Patoilo
|
||||
* Copyright (c) 2018 CJ Patoilo
|
||||
* Licensed under the MIT license
|
||||
*/
|
||||
|
||||
|
@ -204,6 +204,13 @@ input[type='search'],
|
|||
input[type='tel'],
|
||||
input[type='text'],
|
||||
input[type='url'],
|
||||
input[type='color'],
|
||||
input[type='date'],
|
||||
input[type='month'],
|
||||
input[type='week'],
|
||||
input[type='datetime'],
|
||||
input[type='datetime-local'],
|
||||
input:not([type]),
|
||||
textarea,
|
||||
select {
|
||||
-webkit-appearance: none;
|
||||
|
@ -226,6 +233,13 @@ input[type='search']:focus,
|
|||
input[type='tel']:focus,
|
||||
input[type='text']:focus,
|
||||
input[type='url']:focus,
|
||||
input[type='color']:focus,
|
||||
input[type='date']:focus,
|
||||
input[type='month']:focus,
|
||||
input[type='week']:focus,
|
||||
input[type='datetime']:focus,
|
||||
input[type='datetime-local']:focus,
|
||||
input:not([type]):focus,
|
||||
textarea:focus,
|
||||
select:focus {
|
||||
border-color: #9b4dca;
|
||||
|
@ -233,12 +247,12 @@ select:focus {
|
|||
}
|
||||
|
||||
select {
|
||||
background: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" height="14" viewBox="0 0 29 14" width="29"><path fill="#d1d1d1" d="M9.37727 3.625l5.08154 6.93523L19.54036 3.625"/></svg>') center right no-repeat;
|
||||
background: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" height="14" viewBox="0 0 29 14" width="29"><path fill="%23d1d1d1" d="M9.37727 3.625l5.08154 6.93523L19.54036 3.625"/></svg>') center right no-repeat;
|
||||
padding-right: 3.0rem;
|
||||
}
|
||||
|
||||
select:focus {
|
||||
background-image: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" height="14" viewBox="0 0 29 14" width="29"><path fill="#9b4dca" d="M9.37727 3.625l5.08154 6.93523L19.54036 3.625"/></svg>');
|
||||
background-image: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" height="14" viewBox="0 0 29 14" width="29"><path fill="%239b4dca" d="M9.37727 3.625l5.08154 6.93523L19.54036 3.625"/></svg>');
|
||||
}
|
||||
|
||||
textarea {
|
||||
|
|
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
|
@ -9,6 +9,12 @@ input[type='search'],
|
|||
input[type='tel'],
|
||||
input[type='text'],
|
||||
input[type='url'],
|
||||
input[type='color'],
|
||||
input[type='date'],
|
||||
input[type='month'],
|
||||
input[type='week'],
|
||||
input[type='datetime'],
|
||||
input[type='datetime-local'],
|
||||
input:not([type]),
|
||||
textarea,
|
||||
select
|
||||
|
|
|
@ -193,6 +193,12 @@
|
|||
<option value="selectField3">Select field 3</option>
|
||||
<option value="selectField4">Select field 4</option>
|
||||
</select>
|
||||
<label for="colorField">Color field</label>
|
||||
<input type="color" id="colorField" placeholder="Your browser doesn't support this field.">
|
||||
<label for="weekField">Week field</label>
|
||||
<input type="week" id="weekField" placeholder="Your browser doesn't support this field.">
|
||||
<label for="datetimeField">Datetime field</label>
|
||||
<input type="datetime" id="datetimeField" placeholder="Your browser doesn't support this field.">
|
||||
<label for="searchField">Search field</label>
|
||||
<input type="search" id="searchField" placeholder="Search field">
|
||||
</div>
|
||||
|
@ -225,6 +231,12 @@
|
|||
</div>
|
||||
<label for="textareaField">Textarea field</label>
|
||||
<textarea placeholder="Textarea field" id="textareaField"></textarea>
|
||||
<label for="dateField">Date field</label>
|
||||
<input type="date" id="dateField" placeholder="Your browser doesn't support this field.">
|
||||
<label for="monthField">Month field</label>
|
||||
<input type="month" id="monthField" placeholder="Your browser doesn't support this field.">
|
||||
<label for="datetimeLocalField">Datetime-Local field</label>
|
||||
<input type="datetime-local" id="datetimeLocalField" placeholder="Your browser doesn't support this field.">
|
||||
<input type="submit">
|
||||
<input type="reset" class="button-clear">
|
||||
</div>
|
||||
|
|
40
yarn.lock
40
yarn.lock
|
@ -950,11 +950,17 @@ balanced-match@^0.4.1:
|
|||
version "0.4.2"
|
||||
resolved "https://registry.yarnpkg.com/balanced-match/-/balanced-match-0.4.2.tgz#cb3f3e3c732dc0f01ee70b403f302e61d7709838"
|
||||
|
||||
banner-cli@^0.9.2:
|
||||
version "0.9.2"
|
||||
resolved "https://registry.yarnpkg.com/banner-cli/-/banner-cli-0.9.2.tgz#ee7e98bb59b61f6a27e8f2f28103b1c1b420090d"
|
||||
balanced-match@^1.0.0:
|
||||
version "1.0.0"
|
||||
resolved "https://registry.yarnpkg.com/balanced-match/-/balanced-match-1.0.0.tgz#89b4d199ab2bee49de164ea02b89ce462d71b767"
|
||||
|
||||
banner-cli@^0.11.0:
|
||||
version "0.11.1"
|
||||
resolved "https://registry.yarnpkg.com/banner-cli/-/banner-cli-0.11.1.tgz#f871983346ef89ee8b8f25595dbf6356e26eaa55"
|
||||
dependencies:
|
||||
prepend-file "~1.3.1"
|
||||
glob "^7.1.2"
|
||||
minimist "^1.2.0"
|
||||
prepend-file "^1.3.1"
|
||||
|
||||
base64-arraybuffer@0.1.5:
|
||||
version "0.1.5"
|
||||
|
@ -1029,6 +1035,13 @@ brace-expansion@^1.0.0:
|
|||
balanced-match "^0.4.1"
|
||||
concat-map "0.0.1"
|
||||
|
||||
brace-expansion@^1.1.7:
|
||||
version "1.1.8"
|
||||
resolved "https://registry.yarnpkg.com/brace-expansion/-/brace-expansion-1.1.8.tgz#c07b211c7c952ec1f8efd51a77ef0d1d3990a292"
|
||||
dependencies:
|
||||
balanced-match "^1.0.0"
|
||||
concat-map "0.0.1"
|
||||
|
||||
braces@^1.8.2:
|
||||
version "1.8.5"
|
||||
resolved "https://registry.yarnpkg.com/braces/-/braces-1.8.5.tgz#ba77962e12dff969d6b76711e914b737857bf6a7"
|
||||
|
@ -2306,6 +2319,17 @@ glob@^7.0.0, glob@^7.0.3, glob@^7.0.5, glob@^7.0.6, glob@~7.1.1:
|
|||
once "^1.3.0"
|
||||
path-is-absolute "^1.0.0"
|
||||
|
||||
glob@^7.1.2:
|
||||
version "7.1.2"
|
||||
resolved "https://registry.yarnpkg.com/glob/-/glob-7.1.2.tgz#c19c9df9a028702d678612384a6552404c636d15"
|
||||
dependencies:
|
||||
fs.realpath "^1.0.0"
|
||||
inflight "^1.0.4"
|
||||
inherits "2"
|
||||
minimatch "^3.0.4"
|
||||
once "^1.3.0"
|
||||
path-is-absolute "^1.0.0"
|
||||
|
||||
globals@^9.0.0, globals@^9.14.0, globals@^9.2.0:
|
||||
version "9.14.0"
|
||||
resolved "https://registry.yarnpkg.com/globals/-/globals-9.14.0.tgz#8859936af0038741263053b39d0e76ca241e4034"
|
||||
|
@ -3214,6 +3238,12 @@ mime@1.3.4, "mime@>= 0.0.1":
|
|||
dependencies:
|
||||
brace-expansion "^1.0.0"
|
||||
|
||||
minimatch@^3.0.4:
|
||||
version "3.0.4"
|
||||
resolved "https://registry.yarnpkg.com/minimatch/-/minimatch-3.0.4.tgz#5166e286457f03306064be5497e8dbb0c3d32083"
|
||||
dependencies:
|
||||
brace-expansion "^1.1.7"
|
||||
|
||||
minimist@0.0.8, minimist@~0.0.1:
|
||||
version "0.0.8"
|
||||
resolved "https://registry.yarnpkg.com/minimist/-/minimist-0.0.8.tgz#857fcabfc3397d2625b8228262e86aa7a011b05d"
|
||||
|
@ -3839,7 +3869,7 @@ prelude-ls@~1.1.2:
|
|||
version "1.1.2"
|
||||
resolved "https://registry.yarnpkg.com/prelude-ls/-/prelude-ls-1.1.2.tgz#21932a549f5e52ffd9a827f570e04be62a97da54"
|
||||
|
||||
prepend-file@~1.3.1:
|
||||
prepend-file@^1.3.1:
|
||||
version "1.3.1"
|
||||
resolved "https://registry.yarnpkg.com/prepend-file/-/prepend-file-1.3.1.tgz#83b16e0b4ac1901fce88dbd945a22f4cc81df579"
|
||||
dependencies:
|
||||
|
|
Loading…
Reference in New Issue