Fix/789#222
Open
conradmugabe wants to merge 4 commits into
Open
Conversation
The custom launcher icon configured on the Embed tab lived only in local
React state, so it reverted to the default on page refresh. Persist it to
the mentor settings: custom mode saves the bubble config as the
`embed_icon_selection_data` JSON map (plus the uploaded image as
`embed_custom_image`), and default mode clears it with an empty object `{}`
(the backend ignores `null`/`''`). Derive custom-vs-default from whether the
persisted JSON is a non-empty object via the form's reactive defaultValues,
rehydrate the bubble config from settings on load, and make the Icon
Selection select controlled so the trigger reflects the hydrated value.
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
`getBubbleImage` built the default launcher thumbnail URL from `config.axdUrl()`. On the unified API gateway that resolves to an invalid `/axd` prefix (HTTP 404 "Use /dm/, /asgi/, /lms/, /studio/"), so the generated embed code silently fell back to the bundled placeholder. The thumbnail is a DM endpoint — use `config.dmUrl()` (which the live-preview default already uses for the same path). Behavior is unchanged in the legacy config where the two URLs are identical. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
The Embed tab only had a "Create Embed" action, which always generates the embed snippet. Add a dedicated "Save" button (left of Create Embed) that persists the mentor settings without generating an embed — no website-URL requirement, redirect token, or embed dialog — and toasts on success. It reuses the extracted `saveMentorSettings`, so it persists the same payload as Create Embed. Style to match the settings tab: Save is the gradient primary, Create Embed becomes an outline button. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Unit tests for the Embed tab changes: the icon-selection persistence
helpers (`buildEmbedIconSelectionData`, `hasCustomIconData`,
`buildFloatingBubbleConfigFromSettings`, `dataUrlToFile`), the save/load
round-trip (custom JSON + image, `{}` clear, defaultValues-derived mode,
hydration), the controlled Select, the `getEmbedCode`/`getBubbleImage` dm
endpoint, and the save-only button (`handleSaveSettings`, `isSavingSettings`).
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Member
|
Claude finished @conradmugabe's task —— View job E2E Coverage Bot Analysis ✅Analyzing PR #222 for E2E test coverage requirements... Todo List
Analysis Complete ✅Changed files analysis:
Mechanical coverage check result: Decision: This falls under Case E - No new page.tsx files and mechanical check PASSED. Review Posted: ✅ APPROVED - No new app routes introduced, existing coverage intact. |
mamigot
approved these changes
Jun 5, 2026
mamigot
left a comment
Member
There was a problem hiding this comment.
✅ E2E Coverage — No Issues
No new app routes were introduced. All existing coverage is intact.
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.
Checklist
Changes