Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
* @method invokeWithFixedScrollbar
* @param {Function} callback invoked after saving current scrollbar position
*/
invokeWithFixedScrollbar(callback) {
if (navigator.userAgent.indexOf('Chrome') > -1) {
const scrollY = window.pageYOffset;
callback();
window.scroll(window.pageXOffset, scrollY);
} else {
callback();
}
}
}
AlloyEditor.Buttons[EzBtnLinkEdit.key] = AlloyEditor.ButtonLinkEdit = EzBtnLinkEdit;
eZ.addConfig('ezAlloyEditor.ezBtnLinkEdit', EzBtnLinkEdit);
* @method invokeWithFixedScrollbar
* @param {Function} callback invoked after saving current scrollbar position
*/
invokeWithFixedScrollbar(callback) {
if (navigator.userAgent.indexOf('Chrome') > -1) {
const scrollY = window.pageYOffset;
callback();
window.scroll(window.pageXOffset, scrollY);
} else {
callback();
}
}
}
AlloyEditor.Buttons[EzBtnLinkEdit.key] = AlloyEditor.ButtonLinkEdit = EzBtnLinkEdit;
const eZ = (window.eZ = window.eZ || {});
eZ.ezAlloyEditor = eZ.ezAlloyEditor || {};
eZ.ezAlloyEditor.ezBtnLinkEdit = EzBtnLinkEdit;