Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@
"@sentry/browser": "^10.0.0",
"@tanstack/react-query": "^5.66.0",
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Bug: The upgrade to Bootstrap 5 is incomplete. Old data-toggle and data-target attributes were not migrated to the new data-bs-* format, which will break UI components.
Severity: CRITICAL

Suggested Fix

Globally search and replace all legacy Bootstrap 4 data attributes with their new Bootstrap 5 equivalents. For example, update data-toggle="modal" to data-bs-toggle="modal", data-dismiss="modal" to data-bs-dismiss="modal", and data-target="#foo" to data-bs-target="#foo". This change must be applied to all HTML templates and components that use Bootstrap's JavaScript plugins.

Prompt for AI Agent
Review the code at the location below. A potential bug has been identified by an AI
agent.
Verify if this is a real issue. If it is, propose a fix; if not, explain why it's not
valid.

Location: package.json#L50

Potential issue: The upgrade to Bootstrap 5.0.0 requires migrating HTML data attributes,
but this has not been done. The codebase contains numerous instances of Bootstrap 4
attributes like `data-toggle`, `data-dismiss`, and `data-target`. Bootstrap 5 does not
support these legacy attributes and instead requires the `data-bs-*` prefix (e.g.,
`data-bs-toggle`). As a result, UI components that rely on these attributes for
functionality—such as modals, dropdown menus, and collapsible navigation elements—will
fail to work. Users will be unable to open or close modals, expand menus, or toggle
navigation, leading to widespread broken UI functionality.

Did we get this right? 👍 / 👎 to inform future reviews.

"array-flat-polyfill": "^1.0.1",
"bootstrap": "^4.3.1",
"bootstrap": "^5.0.0",
"casual": "^1.6.2",
"core-js": "^3.38.1",
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Bug: The offcanvas-bootstrap package and its data-toggle attributes are incompatible with Bootstrap 5's native offcanvas component, which expects data-bs-toggle attributes, breaking mobile navigation.
Severity: CRITICAL

Suggested Fix

Remove the offcanvas-bootstrap dependency. Update all HTML to use Bootstrap 5's native offcanvas attributes, such as data-bs-toggle="offcanvas" and data-bs-target. Replace custom event triggers like offcanvas.close with the corresponding Bootstrap 5 native events, such as hidden.bs.offcanvas.

Prompt for AI Agent
Review the code at the location below. A potential bug has been identified by an AI
agent.
Verify if this is a real issue. If it is, propose a fix; if not, explain why it's not
valid.

Location: package.json#L54

Potential issue: The application uses the `offcanvas-bootstrap` library for mobile
navigation drawers. However, the upgrade to Bootstrap 5 introduces a native offcanvas
component that conflicts with this library. The HTML uses `data-toggle="offcanvas"`
attributes, which are not recognized by Bootstrap 5's JavaScript, causing the mobile
navigation toggle buttons to fail. Additionally, JavaScript code triggers a custom event
`offcanvas.close`, which is specific to the old library and will not work with Bootstrap
5's native component. This will break the mobile course menu functionality.

"es6-promise": "^4.2.8",
Expand Down
13 changes: 6 additions & 7 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -6126,13 +6126,12 @@ __metadata:
languageName: node
linkType: hard

"bootstrap@npm:^4.3.1":
version: 4.6.2
resolution: "bootstrap@npm:4.6.2"
"bootstrap@npm:^5.0.0":
version: 5.3.8
resolution: "bootstrap@npm:5.3.8"
peerDependencies:
jquery: 1.9.1 - 3
popper.js: ^1.16.1
checksum: 10c0/aae7178a306cd9376d10302bf557e00ba7e3bffffb4c0533687c1e0de90f9d30d8883a9b0ac629a2e64131954eca4e03ee06ee665e52b8c44ca66b3599024e8a
"@popperjs/core": ^2.11.8
checksum: 10c0/0039a9df2c3e7bfa04f1abca199c299ff3b75869d578c0cb1721c6f1f203c91531788a5631ecbee01513481979314d0e4ba0d90c2011e6ce18fc2e0bc93e18d9
languageName: node
linkType: hard

Expand Down Expand Up @@ -13567,7 +13566,7 @@ __metadata:
"@typescript-eslint/eslint-plugin": "npm:^5.40.1"
ansi-colors: "npm:^4.1.3"
array-flat-polyfill: "npm:^1.0.1"
bootstrap: "npm:^4.3.1"
bootstrap: "npm:^5.0.0"
casual: "npm:^1.6.2"
clean-webpack-plugin: "npm:^4.0.0"
cli-table3: "npm:^0.6.3"
Expand Down
Loading