Skip to content

Commit 35bdc55

Browse files
author
David Tai
committed
make scrollToError optional
1 parent 2f53f41 commit 35bdc55

File tree

5 files changed

+10
-8
lines changed

5 files changed

+10
-8
lines changed

el-controls.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6221,7 +6221,7 @@ var ElControls = (function (exports) {
62216221
rect = this.root.getBoundingClientRect();
62226222
elTop = rect.top - window.innerHeight / 2;
62236223
wTop = window.pageYOffset;
6224-
if (!scrolling && elTop <= wTop) {
6224+
if (this.scrollToError && !scrolling && elTop <= wTop) {
62256225
scrolling = true;
62266226
autoPlay(true);
62276227
t = new Tween({

el-controls.min.js

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

elcontrols.js.map

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

src/controls/control.coffee

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,8 @@ _controlId = 0
1111
export default class Control extends El.Input
1212
_controlId: 0
1313

14+
# scrollToError: false
15+
1416
name: null
1517

1618
init: ->
@@ -37,7 +39,7 @@ export default class Control extends El.Input
3739
elTop = rect.top - window.innerHeight / 2
3840
wTop = window.pageYOffset
3941

40-
if !scrolling && elTop <= wTop
42+
if @scrollToError && !scrolling && elTop <= wTop
4143
scrolling = true
4244

4345
autoPlay true

theme.css

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -102,16 +102,16 @@
102102
padding:0;
103103
background:transparent;
104104
}
105-
.input input:-moz-placeholder{
105+
.input input:-ms-input-placeholder{
106106
color:#000;
107107
}
108-
.input input::-moz-placeholder{
108+
.input input::-webkit-input-placeholder{
109109
color:#000;
110110
}
111-
.input input:-ms-input-placeholder{
111+
.input input::-ms-input-placeholder{
112112
color:#000;
113113
}
114-
.input input::-webkit-input-placeholder{
114+
.input input::placeholder{
115115
color:#000;
116116
}
117117
.input input[type=text],

0 commit comments

Comments
 (0)