aboutsummaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
-rw-r--r--assets/index/Picker.less7
-rw-r--r--assets/index/Select.less6
-rw-r--r--examples/disabled.js30
3 files changed, 28 insertions, 15 deletions
diff --git a/assets/index/Picker.less b/assets/index/Picker.less
index 76bf834..610c2b0 100644
--- a/assets/index/Picker.less
+++ b/assets/index/Picker.less
@@ -12,7 +12,12 @@
12 background-color: #fff; 12 background-color: #fff;
13 background-image: none; 13 background-image: none;
14 border: 1px solid #d9d9d9; 14 border: 1px solid #d9d9d9;
15 border-radius: 6px; 15 border-radius: 4px;
16 transition: border .2s cubic-bezier(0.645, 0.045, 0.355, 1), background .2s cubic-bezier(0.645, 0.045, 0.355, 1), box-shadow .2s cubic-bezier(0.645, 0.045, 0.355, 1); 16 transition: border .2s cubic-bezier(0.645, 0.045, 0.355, 1), background .2s cubic-bezier(0.645, 0.045, 0.355, 1), box-shadow .2s cubic-bezier(0.645, 0.045, 0.355, 1);
17 &[disabled] {
18 color: #ccc;
19 background: #f7f7f7;
20 cursor: not-allowed;
21 }
17 } 22 }
18} 23}
diff --git a/assets/index/Select.less b/assets/index/Select.less
index ecef8a8..86c73c1 100644
--- a/assets/index/Select.less
+++ b/assets/index/Select.less
@@ -49,12 +49,12 @@
49 } 49 }
50 50
51 li&-option-selected { 51 li&-option-selected {
52 background: #edfaff; 52 background: #f7f7f7;
53 color: #2db7f5; 53 font-weight: bold;
54 } 54 }
55 55
56 li&-option-disabled { 56 li&-option-disabled {
57 color: #bfbfbf; 57 color: #ccc;
58 &:hover { 58 &:hover {
59 background: transparent; 59 background: transparent;
60 cursor: not-allowed; 60 cursor: not-allowed;
diff --git a/examples/disabled.js b/examples/disabled.js
index 9d74002..a38ce16 100644
--- a/examples/disabled.js
+++ b/examples/disabled.js
@@ -48,14 +48,22 @@ function disabledSeconds(h, m) {
48} 48}
49 49
50ReactDom.render( 50ReactDom.render(
51 <TimePicker 51 <div>
52 showSecond={showSecond} 52 <h3>Disabled picker</h3>
53 defaultValue={now} 53 <TimePicker
54 className="xxx" 54 defaultValue={now}
55 onChange={onChange} 55 disabled
56 disabledHours={disabledHours} 56 onChange={onChange}
57 disabledMinutes={disabledMinutes} 57 />
58 disabledSeconds={disabledSeconds} 58 <h3>Disabled options</h3>
59 />, 59 <TimePicker
60 document.getElementById('__react-content') 60 showSecond={showSecond}
61); 61 defaultValue={now}
62 className="xxx"
63 onChange={onChange}
64 disabledHours={disabledHours}
65 disabledMinutes={disabledMinutes}
66 disabledSeconds={disabledSeconds}
67 />
68 </div>
69, document.getElementById('__react-content'));