Conversation
wenzhixin
commented
Feb 28, 2026
Owner
- Update: Replaced jQuery utilities with ES6+ alternatives.
- Update: Fixed Bootstrap theme checkbox focus state outline being clipped.
Fixed bootstrap theme checkbox focus state outline being clipped
This PR refactors the codebase to replace jQuery utility methods with modern ES6+ alternatives, making the code more idiomatic and maintainable. Changes: - Replace $.extend() with native extend() function * Uses proven implementation from bootstrap-table * Supports both shallow and deep merging * Maintains full jQuery API compatibility - Replace $.each() with native for...of loops * More idiomatic ES6+ syntax * Better performance and readability - Replace $.inArray() with Array.prototype.includes() * Simpler and more intuitive API - Add extend() and isObject() utilities to src/utils/index.js * No separate compatibility layer needed * Consistent with existing code style Benefits: - More native JavaScript, less jQuery dependency - Better performance with native methods - Future-proof for jQuery 4.0+ - Cleaner, more maintainable code All tests pass and lint checks are clean.
Refactor: Replace jQuery utilities with ES6+ alternatives
Fixes #677 - View source code not working after jQuery upgrade Changes: - Replace $.trim() with String.prototype.trim() - Replace $.map() with Array.prototype.map() - Replace $.each() with Array.prototype.forEach() - Replace $.extend() with Object.assign() - Replace $.param() with URLSearchParams implementation This ensures compatibility with jQuery 4.0+ where utility methods like $.trim() have been removed. Files modified: - site/website/static/js/template.js - site/website/static/templates/refresh.html
Fix: Replace jQuery utilities with ES6+ in site templates
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.