Upgrade to Bootstrap 5 - #144
Open
Mihai98924 wants to merge 31 commits into
Open
Mihai98924 wants to merge 31 commits into
Mihai98924 wants to merge 31 commits into
Conversation
Full rewrite of the calendar integration to match FullCalendar v7's new architecture: switch from the jQuery plugin API to the Calendar class API, vendor the new global bundle plus its required temporal-polyfill peer dependency and the Dutch and British-English locale files (plain 'en' is US English, which would flip dates to month/day order). For styling, use v7's bundled "classic" theme (skeleton.css + the theme's global.js, theme.css and palette.css), which restores the traditional FullCalendar look (grid borders, shaded headers, styled toolbar buttons) that v7's bare skeleton CSS alone no longer provides. The palette's CSS variables are overridden in application.css to match Bootstrap's .btn-primary colors. expandRows stretches the hour rows to fill the calendar height (successor of v1's weekMode: 'liquid'), and the dated column headers and date-range title are scoped to the week view only. Unlike the old calendar, all-day (month view) selections are no longer rejected, so planners can create multi-day events by dragging across days; the event form is prefilled with the selected midnight boundaries. Also updates EventCalendarFetch to parse ISO8601 start/end params (sent by the new client-side events callback) via Django's parse_datetime instead of Unix timestamps, and nests organizers/location/tenders under extendedProps to match how the rewritten template reads them.
Vendors the Bootstrap 5.3.8 dist files and removes the 4.6.2 ones along with the bootstrap-datepicker/timepicker plugins (replaced by native date/time inputs in a follow-up commit). The navbar moves to BS5 data-bs-* attributes and the theme-aware bg-body-tertiary style, and gains a Light/Dark/Auto selector. The chosen theme (localStorage key 'alexia-theme', 'auto' follows prefers-color-scheme) is applied to <html> as both data-bs-theme and data-color-scheme (the latter drives the FullCalendar palette) by a pre-paint script in base.html and the runtime logic in application.js, which also migrates tooltip initialization to the Bootstrap 5 API.
Replaces crispy-bootstrap4 with crispy-bootstrap5 (CRISPY_ALLOWED_TEMPLATE_PACKS must be set explicitly since crispy-forms' built-in allowlist stops at bootstrap4). The bootstrap-datepicker/timepicker jQuery plugins are replaced by a NativeSplitDateTimeWidget rendering <input type="date">/<input type="time">, which Bootstrap 5 styles natively in both themes; the widget is wired into the event form and both filter forms with ISO input formats.
Mechanical class and attribute migration across 30 templates: data-toggle/ target/parent/placement to data-bs-*, float-right/left to float-end/start, text-right to text-end, badge-<color> to badge text-bg-<color>, btn-block to w-100, form-group rows to row mb-3, sr-only to visually-hidden, ml-auto to ms-auto, dropdown-menu-right to dropdown-menu-end, and input-group append/prepend wrappers unwrapped. The four data-parent collapses (order list, consumption form/product lists, event list filters) are rebuilt as proper BS5 accordions with stable element ids. Juliana's standalone page now loads the 5.3.8 assets and applies the saved theme before first paint.
application.css: drop the obsolete .has-error/.help-block shims (the bootstrap5 crispy pack renders .is-invalid/.invalid-feedback), key the remaining custom colors (.page-header border, .tr-muted, .tr-yellow, row-add hover) off Bootstrap CSS variables so they follow data-bs-theme, and move the FullCalendar button palette to the Bootstrap 5 primary family. juliana.css: map the POS colors (flash display, receipt borders, age-check alert, countdown pill) onto theme-aware variables. juliana.js: tr.active to table-active (BS dropped row 'active' styling). dcf.js: replace the dead glyphicon with a bootstrap-icons glyph.
the same page when a new link is generated.
the buttons show inline
Mihai98924
marked this pull request as draft
August 19, 2026 15:15
Mihai98924
marked this pull request as ready for review
August 25, 2026 19:33
Member
Might take me a bit to review, seems like a bit more than a simple bootstrap update ;) ( I see most of it is replacing of the libraries, no worries. Will look at it soon! ) |
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.
No description provided.