Upgrade web UI from Bootstrap 3 to Bootstrap 5.3#76
Conversation
Modernize the orchestrator web interface by upgrading to Bootstrap 5.3 via CDN, replacing the bundled Bootstrap 3 files. This addresses the outdated look and feel of the UI. Changes: - Update Bootstrap CSS/JS to 5.3.3 CDN links in layout.tmpl - Migrate navbar to BS5 markup (navbar-expand-md, nav-item, nav-link) - Replace BS3 data attributes (data-toggle -> data-bs-toggle, etc.) - Convert panel components to cards across all templates - Replace btn-default with btn-secondary - Replace sr-only with visually-hidden - Add CSS custom properties for theming (colors, fonts, shadows) - Add system font stack and improved navbar/card styling - Add BS3->BS5 compatibility helpers (pull-left/right, input-sm, btn-xs) - Add JS compatibility bridge for legacy data-toggle/data-dismiss attrs used by existing JavaScript (avoids rewriting JS logic) - Remove IE8 shim (no longer needed) Closes #74
|
Caution Review failedThe pull request is closed. ℹ️ Recent review info⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (12)
📝 WalkthroughWalkthroughThis pull request modernizes the web UI by migrating from Bootstrap 3 to Bootstrap 5 across all templates and stylesheets. Changes include introducing CSS theme variables, updating navbar and modal markup to Bootstrap 5 conventions, replacing panel-based layouts with card components, and adding a client-side compatibility layer for legacy Bootstrap 3 attributes. Changes
Estimated code review effort🎯 3 (Moderate) | ⏱️ ~25 minutes Poem
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
There was a problem hiding this comment.
Code Review
This pull request migrates the application's frontend from Bootstrap 3 to Bootstrap 5.3.3. Key changes include the introduction of modern theme variables in the global CSS, the replacement of legacy panel components with cards, and a comprehensive refactoring of the navbar and modals to align with Bootstrap 5 syntax and data attributes. The review feedback identifies several improvement opportunities related to the migration, specifically addressing the loss of Glyphicon support, the removal of obsolete caret elements, and the adoption of the Bootstrap Alert API for more robust element dismissal.
| } | ||
|
|
||
| .glyphicon { | ||
| font-family: "Glyphicons Halflings"; |
There was a problem hiding this comment.
Bootstrap 5 has dropped support for Glyphicons. Since the local Bootstrap 3 assets (including font files) are being removed in this PR, these icons will likely fail to render unless the font files are manually included or the project migrates to an alternative like Bootstrap Icons or FontAwesome. If you intend to keep using Glyphicons, ensure the font files are still accessible and correctly referenced via @font-face.
| <button type="button" class="btn btn-danger dropdown-toggle" data-toggle="dropdown"> | ||
| <span class="caret"></span> <span class="sr-only">Toggle Dropdown</span> | ||
| <button type="button" class="btn btn-danger dropdown-toggle" data-bs-toggle="dropdown"> | ||
| <span class="caret"></span> <span class="visually-hidden">Toggle Dropdown</span> |
| <button type="button" class="btn btn-success dropdown-toggle" data-toggle="dropdown"> | ||
| Safe revert to <span class="caret"></span> <span class="sr-only">Toggle Dropdown</span> | ||
| <button type="button" class="btn btn-success dropdown-toggle" data-bs-toggle="dropdown"> | ||
| Safe revert to <span class="caret"></span> <span class="visually-hidden">Toggle Dropdown</span> |
| var dismissAlert = e.target.closest('[data-dismiss="alert"]'); | ||
| if (dismissAlert) { | ||
| var alert = dismissAlert.closest('.alert'); | ||
| if (alert) alert.remove(); |
There was a problem hiding this comment.
Using alert.remove() directly removes the element from the DOM without triggering Bootstrap's transition effects or events. It is recommended to use the Bootstrap Alert API for a cleaner dismissal that respects the framework's lifecycle.
if (alert) {
var bsAlert = bootstrap.Alert.getOrCreateInstance(alert);
if (bsAlert) bsAlert.close();
}
Summary
Modernizes the orchestrator web UI by upgrading from Bootstrap 3 to Bootstrap 5.3, loaded via CDN. This replaces the bundled, outdated Bootstrap 3 assets with a current framework version.
nav-item,nav-link,dropdown-item), panels converted to cards,btn-defaulttobtn-secondary,sr-onlytovisually-hiddendata-toggle/data-dismissattributes to BS5 equivalents so existing JavaScript continues to work without modificationCloses #74
Test plan
go buildsucceeds (verified locally)Summary by CodeRabbit
New Features
UI/Styling