-
Notifications
You must be signed in to change notification settings - Fork 90
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Added js controls logic - control prepend or append for comments #15
base: master
Are you sure you want to change the base?
Conversation
…eversed to be specified
Hi! This is a neat feature to have, I like adding it. There are a few things I'd prefer to see updated though:
Thanks for your time, and thanks in advance for looking at these points. |
Hey there, sure no problem; thanks for the nice app that plugs neatly in :) 💯
My pleasure :) |
@@ -93,7 +98,7 @@ | |||
|
|||
function scrollToElement( $element, speed, offset ) | |||
{ | |||
if( $element.length ) | |||
if( $element.length && COMMENT_CONTROLS.scroll_to_comment === true ) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Out of curiosity, why the explicit === true
?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I was working on the assumption that if the user enters "false" it will evaluate as true.
var test = {};
test.item = 'false'
"false"
if (test.item) { console.log('yay') }
Hi, I've made some additional comments in the diff. Let me know what you think of these! I hope you don't mind a critical look here. |
Hi there Diederik, of course not :) critical comments are welcome! if were gonna release something we had better make sure its more than just "ok". I'm a touch busy atm but will give this a closer look soon! |
Before adding more features, is it better to rewrite the thing to a proper jQuery plugin? Actually I filed an issue #23 just for that. $('div.comments-container').fluentcomments({
append: true,
scrollToComment: false,
}); |
I totally agree on that one @euanlau! Nice idea. It would also make the new multi-form support (currently in master) easier to use. |
Added js controls logic which is backwards compatible but allows is_reversed to be specified