Permalink
Browse files

Update parchment.debug.js (#52)

* Update parchment.debug.js

Auto-scrolling for Chrome (fix issue #50)

* Update parchment.debug.js

* Update input.js

line: 163 "parchment/src/structio/input.js"
```javascript
self.scrollParent = /webkit/i.test( navigator.userAgent ) ? $body : $( 'html' );
```
If "self.scroolParent = $body", then "this.scrollParent.scrollTop()" always is 0.
  • Loading branch information...
cHameleonRu authored and curiousdannii committed Dec 28, 2017
1 parent 87fa74a commit 0d2720d619dbda5840966e1105a33f7e25ca415e
Showing with 2 additions and 2 deletions.
  1. +2 −2 src/structio/input.js
View
@@ -160,7 +160,7 @@ TextInput = Object.subClass({
// Find the element which we calculate scroll offsets from
// For now just decide by browser
self.scrollParent = /webkit/i.test( navigator.userAgent ) ? $body : $( 'html' );
self.scrollParent = /edge/i.test( navigator.userAgent ) ? $body : $( 'html' );
},
// Cleanup so we can deconstruct
@@ -321,4 +321,4 @@ TextInput = Object.subClass({
this.order.response = input;
this.callback( this.order );
}
});
});

0 comments on commit 0d2720d

Please sign in to comment.