diff options
| author | yo momma <shutup@oops.wtf> | 2026-02-03 21:30:24 +0000 |
|---|---|---|
| committer | yo momma <shutup@oops.wtf> | 2026-02-03 21:30:24 +0000 |
| commit | 263677a46ee031277fae07109acac17b5ef821c4 (patch) | |
| tree | 0bbd6da3ca4fc9e4809f20be713161d39a5a525a /static/js/pages/scroll_pane_init.js | |
| parent | b3928bc192cdf729d4b9e53ff5603905ae446fb7 (diff) | |
Refactor: extract page init snippets
Diffstat (limited to 'static/js/pages/scroll_pane_init.js')
| -rw-r--r-- | static/js/pages/scroll_pane_init.js | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/static/js/pages/scroll_pane_init.js b/static/js/pages/scroll_pane_init.js new file mode 100644 index 0000000..1508418 --- /dev/null +++ b/static/js/pages/scroll_pane_init.js @@ -0,0 +1,13 @@ +// Optional jScrollPane initializer for legacy pages that use `.scroll-pane`. +// Keep it defensive: some pages may not load the plugin. + +(function() { + if (typeof jQuery !== 'function') { return; } + + jQuery(function() { + if (jQuery.fn && typeof jQuery.fn.jScrollPane === 'function') { + jQuery('.scroll-pane').jScrollPane(); + } + }); +})(); + |
