質問編集履歴
1
使用しているプラグインのURL、HTMLを追記しました。
title
CHANGED
File without changes
|
body
CHANGED
@@ -4,7 +4,7 @@
|
|
4
4
|
Material Design Liteを利用したサイトがあり、
|
5
5
|
そのフォームを修正しています。
|
6
6
|
|
7
|
-
生年月日の入力欄では
|
7
|
+
生年月日の入力欄では[pickadate.js](http://amsul.ca/pickadate.js/)を使用しているのですが、
|
8
8
|
入力の際、一度入力をキャンセルし空欄になったフォームのプレースホルダが
|
9
9
|
入力前の状態に戻ってくれません。
|
10
10
|
|
@@ -19,7 +19,18 @@
|
|
19
19
|
|
20
20
|
|
21
21
|
###該当のソースコード
|
22
|
-
```
|
22
|
+
```html
|
23
|
+
<div class="mdl-textfield mdl-js-textfield
|
24
|
+
string optional customer_born_on mdl-textfield--floating-label mdl-cell mdl-cell--12-col">
|
25
|
+
<label class="string optional mdl-textfield__label" for="customer_born_on">
|
26
|
+
生年月日
|
27
|
+
</label>
|
28
|
+
<input data-toggle="datepicker" class="string optional mdl-textfield__input"
|
29
|
+
type="text" name="customer[born_on]" id="customer_born_on" />
|
30
|
+
</div>
|
31
|
+
```
|
32
|
+
|
33
|
+
```js
|
23
34
|
var input_pickdate = $('[data-toggle="datepicker"]');
|
24
35
|
$.each(input_pickdate,function(i,e){
|
25
36
|
$(e).pickadate({
|