Build Add Module Modal UX with Module Type Selection and Search#282
Merged
smattymatty merged 1 commit intomainfrom Feb 13, 2026
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
PR Template CheckAll checks passed. |
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.
Build Add Module Modal UX with Module Type Selection and Search
Description
Replaces the placeholder "Coming Soon" add module modal with a fully functional multi-step flow. Teachers can now select a module type (Slideshow), search for content with a debounced autocomplete, and attach it to their course — all in a clean step-based UI.
Closes #263
Mandatory Checklist
mainWhat Changed
Modified Files
src/services/slideshowApi.tssearchSlideshows(params)—GET /api/slideshows/search/withq(required),mine,page,page_sizeparamsgetSafeErrorMessage, 10s timeout)src/components/courses/AddModuleModal.tsx(rewrite)Multi-step flow replacing the placeholder:
Step 1 — Type Selection:
HiPresentationChartBaricon)Step 2 — Search & Select:
mine=truefilter)/api/slideshows/search/?q=<query>listMySlideshows()line-clamp-2), Published/Draft badge, slide count, visibility labelcancelledflag patternStep 3 — Confirm & Add:
flex-col-reverse sm:flex-row)onSubmit({ title, content_type: "slideshows.slideshow", object_id })Edit mode (when
editModuleprop is provided):editModule.content_typeeditModule.titleGeneral:
ModulesTab.tsxmax-w-sm sm:max-w-lg,max-h-[90vh] overflow-y-autofor responsive sizingstart-/end-logical properties,rtl:rotate-180on back arrowsrc/i18n/locales/en.jsonReplaced old placeholder keys (
comingSoon,contentTypeLabel,contentTypePlaceholder,objectIdLabel,objectIdPlaceholder) with 20 new keys for the step-based flow: type labels, search UX, toggle labels, badges, empty states, confirm step.src/i18n/locales/ar.jsonMatching Arabic translations for all new keys.
New Files
src/components/courses/__tests__/AddModuleModal.test.tsx(26 tests)How to Test
make uporcd Frontend/EduLiteFrontend && npm run devFull Add Flow
Edit Flow
Edge Cases
RTL Testing
Run Tests
Screenshots (if applicable)