Skip to content

LearnR - Fix Bootstrap 5 compatibility issues - #55

Open
jlhollowell wants to merge 1 commit into
dbnschools:mainfrom
jlhollowell:moodle5-bootstrap-fix
Open

LearnR - Fix Bootstrap 5 compatibility issues#55
jlhollowell wants to merge 1 commit into
dbnschools:mainfrom
jlhollowell:moodle5-bootstrap-fix

Conversation

@jlhollowell

Copy link
Copy Markdown

Fix Bootstrap 5 compatibility issues (collapse, dropdown, utility classes)

Description
This PR updates the LearnR theme to improve compatibility with Moodle 5.x (Bootstrap 5), addressing several UI elements that no longer function due to deprecated Bootstrap 4 attributes and classes.
Key fixes
• Updated deprecated Bootstrap 4 attributes:
• data-toggle → data-bs-toggle
• data-target → data-bs-target
• Restored functionality of:
• Course Management panel (collapse toggle)
• Header dropdown menus (e.g., “My Courses”)
• Front page icon slider (collapse behavior)
• Updated Bootstrap utility classes:
• ml-* / mr-* → ms-* / me-*
• text-left → text-start
• Cleaned up minor HTML issues:
• Removed invalid alt attributes from elements
• Corrected duplicate class attribute in collapse panel
• Replaced invalid role="iconbtn" with role="button"
Notes
• These changes were tested on Moodle 5.1.
• No functional changes beyond restoring expected UI behavior.
• Changes are limited in scope to avoid impacting broader theme structure.
Version
• Bumped $plugin->version to reflect this update.
Summary

This PR restores broken interactive elements caused by Bootstrap 5 migration and improves overall compatibility with newer Moodle versions while keeping changes minimal and focused.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant