Skip to content
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

AO3-5204 Upgrade scrollTo plugin to fix problem in Chrome #3108

Merged
merged 2 commits into from Apr 2, 2019

Conversation

sarken
Copy link
Member

@sarken sarken commented Oct 19, 2017

Issue

https://otwarchive.atlassian.net/browse/AO3-5204

Purpose

Upgrades the scrollTo plugin so scrolling to comments works in Chrome.

Testing

Refer to JIRA.

@@ -1,7 +1,7 @@
/**
* Copyright (c) 2007-2012 Ariel Flesler - aflesler(at)gmail(dot)com | http://flesler.blogspot.com
* Dual licensed under MIT and GPL.
* Copyright (c) 2007 Ariel Flesler - aflesler ○ gmail • com | https://github.com/flesler

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Line is too long.

define(['jquery'], factory);
} else if (typeof module !== 'undefined' && module.exports) {
// CommonJS
module.exports = factory(require('jquery'));

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

'require' is not defined.

'use strict';
if (typeof define === 'function' && define.amd) {
// AMD
define(['jquery'], factory);

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

'define' is not defined.

$(window).scrollTo( target, duration, settings );
;(function(factory) {
'use strict';
if (typeof define === 'function' && define.amd) {

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

'define' is not defined.

function both( val ){
return typeof val == 'object' ? val : { top:val, left:val };
function both(val) {
return $.isFunction(val) || $.isPlainObject(val) ? val : { top:val, left:val };

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Line is too long.

case 'object':
if (targ.length === 0) return;

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Expected '{' and instead saw 'return'.

// Null target yields nothing, just like jQuery does
if (target == null) return;
if (target === null) return;

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Expected '{' and instead saw 'return'.

};
function isWin(elem) {
return !elem.nodeName ||
$.inArray(elem.nodeName.toLowerCase(), ['iframe','#document','html','body']) !== -1;

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Line is too long.

* Copyright (c) 2007 Ariel Flesler - aflesler ○ gmail • com | https://github.com/flesler
* Licensed under MIT
* https://github.com/flesler/jquery.scrollTo
* @projectDescription Lightweight, cross-browser and highly customizable animated scrolling with jQuery

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Line is too long.

* @projectDescription Easy element scrolling using jQuery.
* http://flesler.blogspot.com/2007/10/jqueryscrollto.html
* jQuery.scrollTo
* Copyright (c) 2007 Ariel Flesler - aflesler ○ gmail • com | https://github.com/flesler

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Line is too long.

@redsummernight redsummernight merged commit f569622 into otwcode:master Apr 2, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
6 participants