{"id":311,"date":"2016-10-20T09:17:26","date_gmt":"2016-10-20T00:17:26","guid":{"rendered":"https:\/\/p-corporate-blog-cms.mmmcorp.co.jp\/blog\/2016\/10\/20\/input_date_style"},"modified":"2016-10-20T09:17:26","modified_gmt":"2016-10-20T00:17:26","slug":"input_date_style","status":"publish","type":"post","link":"https:\/\/p-corporate-blog-cms.mmmcorp.co.jp\/blog\/2016\/10\/20\/input_date_style\/","title":{"rendered":"HTML5\u306e\u65e5\u4ed8\u5165\u529b\u30d5\u30a9\u30fc\u30e0\u306e\u30b9\u30bf\u30a4\u30eb\u3092\u5909\u3048\u3066\u307f\u308b"},"content":{"rendered":"

\u30a8\u30f3\u30b8\u30cb\u30a2\u3070\u304b\u308a\u306eMMM\u3067\u30c7\u30b6\u30a4\u30ca\u30fc\u3092\u3084\u3063\u3066\u3044\u308b\u6c60\u5cf6\u3067\u3059\u3002\u30c7\u30b6\u30a4\u30f3\u306b\u30b3\u30fc\u30c7\u30a3\u30f3\u30b0\u3001\u3055\u3089\u306bSEO\u5bfe\u7b56\u306a\u3069\u3082\u884c\u3063\u3066\u3044\u307e\u3059\u3002<\/p>\n

\u3068\u3053\u308d\u3067\u3001\u5148\u65e5\u62c5\u5f53\u3057\u305f\u30d7\u30ed\u30b8\u30a7\u30af\u30c8\u306e\u4e2d\u3067\u3001HTML5\u3092\u4f7f\u3063\u3066\u30ab\u30ec\u30f3\u30c0\u30fc\u6a5f\u80fd\u3092\u5b9f\u88c5\u3057\u307e\u3057\u305f\u3002<\/p>\n

IE\u3084Firefox\u306a\u3069\u3001HTML5\u306b\u975e\u5bfe\u5fdc\u306e\u30d6\u30e9\u30a6\u30b6\u3082\u3042\u308b\u3082\u306e\u306e\u3001\u30e6\u30fc\u30b6\u30fc\u8996\u70b9\u306b\u7acb\u3064\u3068\u30ab\u30ec\u30f3\u30c0\u30fcUI\u304b\u3089\u65e5\u4ed8\u3092\u9078\u629e\u3059\u308b\u3053\u3068\u304c\u3067\u304d\u308b\u306e\u306f\u975e\u5e38\u306b\u5206\u304b\u308a\u3084\u3059\u3044\u3067\u3059\u3088\u306d\u3002<\/p>\n

\u65e5\u4ed8\u9078\u629e\u30d5\u30a9\u30fc\u30e0\u306e\u30b9\u30bf\u30a4\u30eb\u5909\u66f4\u3092\u884c\u3063\u305f\u308a\u3082\u3057\u305f\u306e\u3067\u3001\u5099\u5fd8\u9332\u3082\u517c\u306d\u3066\u305d\u306e\u65b9\u6cd5\u3092\u66f8\u3044\u3066\u304a\u3053\u3046\u3068\u601d\u3044\u307e\u3059\u3002<\/p>\n

HTML5\u306b\u3088\u308b\u30ab\u30ec\u30f3\u30c0\u30fc\u306e\u30c7\u30b6\u30a4\u30f3\u4f8b<\/h2>\n

Mac\u306eChrome\u3067\u306f\u30c7\u30d5\u30a9\u30eb\u30c8\u3067\u6b21\u306e\u3088\u3046\u306b\u8868\u793a\u3055\u308c\u307e\u3059\u3002
\n\"\"<\/p>\n

\u30de\u30a6\u30b9\u3092\u8f09\u305b\u308b\u3068\u3001\u77e2\u5370\u304c\u51fa\u3066\u304d\u307e\u3059\u3002\uff08\u4e2d\u592e\uff09
\n\u53f3\u306e\u25bc\u304c\u30ab\u30ec\u30f3\u30c0\u30fc\u3092\u51fa\u3059\u30dc\u30bf\u30f3\u3001\u5de6\u306e\u4e0a\u4e0b\u77e2\u5370\u304c\u5e74\u30fb\u6708\u30fb\u65e5\u306e\u6570\u5b57\u3092\uff11\u3064\u305a\u3064\u4e0a\u4e0b\u3055\u305b\u308b\u30dc\u30bf\u30f3\uff08\u30b9\u30d4\u30f3\u30dc\u30bf\u30f3\uff09\u3067\u3059\u3002
\n\u5165\u529b\u3059\u308b\u3068\u3001\u30af\u30ea\u30a2\u30dc\u30bf\u30f3\u3082\u51fa\u3066\u304f\u308b\u3088\u3046\u306b\u306a\u308a\u307e\u3059\u3002\uff08\u53f3\uff09<\/p>\n

\u4eca\u56de\u306f\u3001\u6b21\u306e\u3088\u3046\u306b\u30ab\u30ec\u30f3\u30c0\u30fc\u3092\u8868\u793a\u3059\u308b\u30dc\u30bf\u30f3\u3060\u3051\u3092\u8a2d\u7f6e\u3059\u308b\u5f62\u306b\u3057\u307e\u3057\u305f\u3002
\n\u30b9\u30d4\u30f3\u30dc\u30bf\u30f3\u3068\u30af\u30ea\u30a2\u30dc\u30bf\u30f3\u306f\u7121\u304f\u3057\u3001\u89d2\u4e38\u306e\u5916\u67a0\u3068\u30ab\u30ec\u30f3\u30c0\u30fc\u30a2\u30a4\u30b3\u30f3\u306e\u30dc\u30bf\u30f3\u3060\u3051\u3067\u69cb\u6210\u3057\u307e\u3059\u3002
\n\"\"<\/p>\n

\u30ab\u30ec\u30f3\u30c0\u30fc\u306e\u30b9\u30bf\u30a4\u30eb\u3092\u5909\u66f4\u3059\u308b\u30b3\u30fc\u30c7\u30a3\u30f3\u30b0\u65b9\u6cd5<\/h2>\n

1. \u30d5\u30a9\u30fc\u30e0\u306e\u5916\u67a0\u306e\u30b9\u30bf\u30a4\u30eb\u3092\u4f5c\u6210\u3059\u308b<\/h3>\n

label<\/code>\u306b\u898b\u305f\u76ee\u306e\u30c7\u30b6\u30a4\u30f3\u3092\u4f5c\u3063\u3066\u3044\u304d\u307e\u3059\u3002
\ninput<\/code>\u672c\u4f53\u306f\u3001\u67a0\u3084\u80cc\u666f\u3092\u6d88\u3057\u3066\u3001\u6587\u5b57\u3060\u3051\u898b\u3048\u308b\u3088\u3046\u306b\u3057\u307e\u3059\u3002
\n\"\"<\/p>\n

HTML\u3068CSS\u306f\u305d\u308c\u305e\u308c\u6b21\u306e\u901a\u308a\u3067\u3059\u3002<\/p>\n

HTML<\/strong><\/p>\n

<form>\n  <lavel>\n    <input type="date" \/>\n  <\/label>\n<\/form><\/code><\/pre>\n

CSS<\/strong><\/p>\n

label {\n  position: relative;\n  display: inline-block;\n  width: 200px;\n  height: 36px;\n  border: 2px solid #ccc;\n  border-radius: 15px;\n}\ninput[type="date"] {\n  position: relative;\n  padding: 0 10px;\n  width: 200px;\n  height: 36px;\n  border: 0;\n  background: transparent;\n  box-sizing: border-box;\n  font-size: 14px;\n  color: #999;\n}<\/code><\/pre>\n

2. \u30ab\u30ec\u30f3\u30c0\u30fc\u3092\u8868\u793a\u3059\u308b\u30dc\u30bf\u30f3\u3092\u4f5c\u6210\u3059\u308b<\/h3>\n

label<\/code>\u5185\u306b\u30dc\u30bf\u30f3\u306e\u898b\u305f\u76ee\u3060\u3051\u3092\u4f5c\u308a\u307e\u3059\u3002
\n\u5b9f\u969b\u306b\u62bc\u3059\u306e\u306f\u3001input<\/code>\u306e\u8981\u7d20\u306e\u30dc\u30bf\u30f3\u3067\u3059\u3002
\n\"\"<\/p>\n

CSS\u306f\u6b21\u306e\u901a\u308a\u3067\u3059\u3002<\/p>\n

CSS<\/strong><\/p>\n

label::before {\n  position: absolute;\n  content: "";\n  top: 0;\n  right: -43px;\n  width: 36px;\n  height: 36px;\n  background-color: #06c;\n  background-image: url("icon_calendar.png");\n  background-repeat: no-repeat;\n  background-position: center;\n  border-radius: 10px;\n}<\/code><\/pre>\n

3. \u4e0d\u8981\u306a\u8981\u7d20\u3092\u975e\u8868\u793a\u306b\u3059\u308b<\/h3>\n

\u7d9a\u3044\u3066\u3001\u30b9\u30d4\u30f3\u30dc\u30bf\u30f3\u3068\u30af\u30ea\u30a2\u30dc\u30bf\u30f3\u3092\u975e\u8868\u793a\u306b\u3057\u307e\u3059\u3002<\/p>\n

CSS\u306f\u6b21\u306e\u901a\u308a\u3067\u3059\u3002<\/p>\n

CSS<\/strong><\/p>\n

input[type="date"]::-webkit-inner-spin-button{\n  -webkit-appearance: none;\n}\ninput[type="date"]::-webkit-clear-button{\n  -webkit-appearance: none;\n}<\/code><\/pre>\n

4. \u30dc\u30bf\u30f3\u306e\u5927\u304d\u3055\u30fb\u4f4d\u7f6e\u3092\u8abf\u6574\u3059\u308b<\/h3>\n

\u30ab\u30ec\u30f3\u30c0\u30fc\u3092\u8868\u793a\u3059\u308b\u30dc\u30bf\u30f3\u3092\u3001label\u306e\u30dc\u30bf\u30f3\u3068\u540c\u3058\u5927\u304d\u3055\u30fb\u4f4d\u7f6e\u306b\u8a2d\u5b9a\u3057\u307e\u3059\u3002\u3044\u308f\u3070\u3001\u300c\u672c\u7269\u306e\u30dc\u30bf\u30f3\u300d\u3092\u300c\u898b\u305f\u76ee\u3060\u3051\u30dc\u30bf\u30f3\u300d\u306e\u4e0a\u306b\u8f09\u305b\u308b\u3068\u3044\u3046\u3053\u3068\u3067\u3059\u3002<\/p>\n

\u5927\u304d\u3055\u3068\u4f4d\u7f6e\u3092\u8abf\u6574\u3059\u308b\u305f\u3081\u306b\u306f\u3001\u534a\u900f\u660e\u306e\u80cc\u666f\u8272\u3092\u7f6e\u304f\u3068\u5206\u304b\u308a\u3084\u3059\u304f\u306a\u308a\u307e\u3059\u3002\u30dc\u30bf\u30f3\u306e\u4f4d\u7f6e\u306b\u30de\u30a6\u30b9\u30ab\u30fc\u30bd\u30eb\u3092\u8f09\u305b\u306a\u3044\u3068\u51fa\u73fe\u3057\u306a\u3044\u306e\u3067\u6c17\u3092\u3064\u3051\u307e\u3057\u3087\u3046\u3002<\/p>\n

\"\"<\/p>\n

CSS\u306f\u6b21\u306e\u901a\u308a\u3067\u3059\u3002<\/p>\n

CSS<\/strong><\/p>\n

input[type="date"]::-webkit-calendar-picker-indicator{\n  position: absolute;\n  right: 0px;\n  top: 0px;\n  padding: 0;\n  width: 36px;\n  height: 36px;\n  background: rgba(255, 0, 0, 0.5); \/\/ \u4e00\u65e6\u80cc\u666f\u8272\u3092\u4ed8\u3051\u3066\u3001\u898b\u3084\u3059\u304f\u3057\u307e\u3059\n  color: transparent;\n  cursor: pointer;\n}<\/code><\/pre>\n

5. \u30dc\u30bf\u30f3\u306e\u80cc\u666f\u8272\u3092\u900f\u660e\u306b\u3059\u308b<\/h3>\n

\u6700\u5f8c\u306b\u3001\u30dc\u30bf\u30f3\u306e\u80cc\u666f\u8272\u3092
\nbackground: transparent;<\/code>
\n\u306b\u5909\u66f4\u3059\u308c\u3070\u5b8c\u6210\u3067\u3059\uff01
\n\"\"<\/p>\n

HTML5\u306e\u30ab\u30ec\u30f3\u30c0\u30fc\u6a5f\u80fd\u306e\u5bfe\u5fdc\u30d6\u30e9\u30a6\u30b6\u306b\u3064\u3044\u3066<\/h2>\n

\u8a18\u4e8b\u57f7\u7b46\u6642\u70b9\u3067\u3001HTML5\u306e\u30ab\u30ec\u30f3\u30c0\u30fc\u6a5f\u80fd\u306e\u5bfe\u5fdc\u30d6\u30e9\u30a6\u30b6\u306f\u3001Chrome\u3001Edge\u3001Opera\u3068iOS\u7248\u306eSafari\uff08iOS\u306eSafari,Chrome\u3067\u4e00\u90e8\u6a5f\u80fd\u304c\u975e\u5bfe\u5fdc\uff09\u3068\u306a\u3063\u3066\u3044\u307e\u3059\u3002<\/p>\n

\"\"<\/p>\n

\u975e\u5bfe\u5fdc\u306e\u30d6\u30e9\u30a6\u30b6\u3067\u306f\u3001\u30c6\u30ad\u30b9\u30c8\u5165\u529b\u30d5\u30a9\u30fc\u30e0\u3068\u3057\u3066\u52d5\u4f5c\u3057\u307e\u3059\u3002
\nyyyy\/mm\/dd<\/code> \u306e\u3088\u3046\u306b\u3001\u30d5\u30a9\u30fc\u30de\u30c3\u30c8\u3092\u6ce8\u610f\u66f8\u304d\u306a\u3069\u3067\u6307\u5b9a\u3057\u3066\u304a\u304f\u3068\u3044\u3044\u304b\u3082\u3057\u308c\u307e\u305b\u3093\u3002
\n\"Mac\u306eFirefox\u3067\u306e\u898b\u305f\u76ee\"<\/p>\n

\u3068\u3066\u3082\u30b9\u30c6\u30ad\u306a\u6a5f\u80fd\u306a\u306e\u306b\u3001IE\u3084Safari\u306e\u3088\u3046\u306aOS\u6a19\u6e96\u306e\u30d6\u30e9\u30a6\u30b6\u3067\u5bfe\u5fdc\u3057\u3066\u3044\u306a\u3044\u306e\u304c\u6b8b\u5ff5\u3067\u3059\u3002
\nPC\u3092\u8cb7\u3063\u3066\u6765\u305f\u307e\u307e\u4f7f\u3063\u305f\u308a\u3059\u308b\u4eba\u306b\u3053\u305d\u3001\u5fc5\u8981\u306a\u6a5f\u80fd\u3067\u306f\u306a\u3044\u3067\u3057\u3087\u3046\u304b\u3002
\n\u4ed6\u306e\u6a5f\u80fd\u3082\u542b\u3081\u3001\u4eca\u5f8c\u306e\u5bfe\u5fdc\u306b\u671f\u5f85\u3057\u305f\u3044\u3068\u3053\u308d\u3067\u3059\u3002<\/p>\n

\u53c2\u8003<\/h2>\n

HTML5\u306e\u30d5\u30a9\u30fc\u30e0\u6a5f\u80fd\u306b\u3064\u3044\u3066\u5b66\u3076\u306b\u3042\u305f\u3063\u3066\u3001\u4ee5\u4e0b\u306e\u8a18\u4e8b\u3092\u53c2\u8003\u306b\u3057\u307e\u3057\u305f\u3002<\/p>\n

input[type='date']\u306e\u898b\u305f\u76ee\u3092CSS\u3067\u5909\u66f4\u3059\u308b - R42\u65e5\u8a18<\/a>
\n
<input type="date">\u3092css\u3068fontAwsome\u3067\u4f7f\u3044\u3084\u3059\u304f\u3059\u308b - Qiita<\/a><\/p>\n","protected":false},"excerpt":{"rendered":"

\u30a8\u30f3\u30b8\u30cb\u30a2\u3070\u304b\u308a\u306eMMM\u3067\u30c7\u30b6\u30a4\u30ca\u30fc\u3092\u3084\u3063\u3066\u3044\u308b\u6c60\u5cf6\u3067\u3059\u3002\u30c7\u30b6\u30a4\u30f3\u306b\u30b3\u30fc\u30c7\u30a3\u30f3\u30b0\u3001\u3055\u3089\u306bSEO\u5bfe\u7b56\u306a\u3069\u3082\u884c\u3063\u3066\u3044\u307e\u3059\u3002 \u3068\u3053\u308d\u3067\u3001\u5148\u65e5\u62c5\u5f53\u3057\u305f\u30d7\u30ed\u30b8\u30a7\u30af\u30c8\u306e\u4e2d\u3067\u3001HTML5\u3092\u4f7f\u3063\u3066\u30ab\u30ec\u30f3\u30c0\u30fc\u6a5f\u80fd\u3092\u5b9f\u88c5\u3057\u307e\u3057\u305f\u3002 IE\u3084Firefox\u306a\u3069\u3001HTML5\u306b\u975e\u5bfe\u5fdc\u306e\u30d6\u30e9\u30a6\u30b6\u3082\u3042\u308b\u3082\u306e\u306e\u3001\u30e6\u30fc\u30b6\u30fc\u8996\u70b9\u306b\u7acb\u3064\u3068\u30ab\u30ec\u30f3\u30c0\u30fcUI\u304b\u3089\u65e5\u4ed8\u3092\u9078\u629e\u3059\u308b\u3053\u3068\u304c\u3067\u304d\u308b\u306e\u306f\u975e\u5e38\u306b\u5206\u304b\u308a\u3084\u3059\u3044\u3067\u3059\u3088\u306d\u3002 \u65e5\u4ed8\u9078\u629e\u30d5\u30a9\u30fc\u30e0\u306e\u30b9\u30bf […]<\/p>\n","protected":false},"author":1,"featured_media":826,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":[],"categories":[10],"tags":[160],"aioseo_notices":[],"_links":{"self":[{"href":"https:\/\/p-corporate-blog-cms.mmmcorp.co.jp\/wp-json\/wp\/v2\/posts\/311"}],"collection":[{"href":"https:\/\/p-corporate-blog-cms.mmmcorp.co.jp\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/p-corporate-blog-cms.mmmcorp.co.jp\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/p-corporate-blog-cms.mmmcorp.co.jp\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/p-corporate-blog-cms.mmmcorp.co.jp\/wp-json\/wp\/v2\/comments?post=311"}],"version-history":[{"count":0,"href":"https:\/\/p-corporate-blog-cms.mmmcorp.co.jp\/wp-json\/wp\/v2\/posts\/311\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/p-corporate-blog-cms.mmmcorp.co.jp\/wp-json\/wp\/v2\/media\/826"}],"wp:attachment":[{"href":"https:\/\/p-corporate-blog-cms.mmmcorp.co.jp\/wp-json\/wp\/v2\/media?parent=311"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/p-corporate-blog-cms.mmmcorp.co.jp\/wp-json\/wp\/v2\/categories?post=311"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/p-corporate-blog-cms.mmmcorp.co.jp\/wp-json\/wp\/v2\/tags?post=311"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}