Mostly de-jQuery-ification. This refactor tries to closely preserve the original behavior. Changes: * Store the interval inside the class (allows using `clearLock()` on `LockOn` objects) * Extract the interval function to a separate method * Math.max result is never undefined (per MDN: "[Return value] The largest of the given numbers. If at least one of the arguments cannot be converted to a number, NaN is returned.") * Replace jQuery's `offset()` * Private methods be private * Native `scrollTop` (jQuery's just a wrapper for this) * `addEventListener`/`removeEventListener` |
||
|---|---|---|
| .. | ||
| admin | ||
| confirm-new-email | ||
| discourse/app | ||
| discourse-common | ||
| docs | ||
| ember-addons | ||
| locales | ||
| pretty-text | ||
| select-kit | ||
| wizard | ||
| activate-account.js | ||
| admin.js.erb | ||
| app-boot.js | ||
| application.js | ||
| auto-redirect.js | ||
| browser-detect.js | ||
| discourse-loader.js | ||
| discourse-objects.js | ||
| discourse-shims.js | ||
| embed-application.js | ||
| ember_include.js.erb | ||
| ember_jquery.js | ||
| env.js | ||
| google-tag-manager.js | ||
| google-universal-analytics.js | ||
| handlebars-shim.js | ||
| main_include_admin.js | ||
| markdown-it-bundle.js | ||
| onpopstate-handler.js | ||
| polyfills.js | ||
| pretty-text-bundle.js | ||
| print-page.js | ||
| service-worker.js.erb | ||
| set-prototype-polyfill.js | ||
| start-discourse.js | ||
| template_include.js | ||
| vendor.js | ||
| widget-runtime.js | ||
| wizard-application.js | ||
| wizard-start.js | ||
| wizard-vendor.js | ||