Skip to content

⬆️(frontend) update widget logic to latest version#649

Merged
sylvinus merged 1 commit intomainfrom
deps/widget-upgrade
Apr 30, 2026
Merged

⬆️(frontend) update widget logic to latest version#649
sylvinus merged 1 commit intomainfrom
deps/widget-upgrade

Conversation

@jbpenrath
Copy link
Copy Markdown
Contributor

@jbpenrath jbpenrath commented Apr 30, 2026

Purpose

The new widget loader consume window._lasuite_widget property to know which widget to load. The previous version was using window._stmsg_header.

/!\ Update NEXT_PUBLIC_LAGAUFRE_WIDGET_PATH and
NEXT_PUBLIC_FEEDBACK_WIDGET_PATH
to target the new widget version before deploying this commit.

Summary by CodeRabbit

  • Refactor
    • Updated internal widget initialization mechanism across multiple components to use a standardized global queue reference.

The new widget loader consume `window._lasuite_widget` property to
know which widget to load. The previous version was using
`window._stmsg_header`.

/!\ Update NEXT_PUBLIC_LAGAUFRE_WIDGET_PATH and
NEXT_PUBLIC_FEEDBACK_WIDGET_PATH
to target the new widget version before deploying this commit.
@jbpenrath jbpenrath self-assigned this Apr 30, 2026
@coderabbitai
Copy link
Copy Markdown

coderabbitai Bot commented Apr 30, 2026

📝 Walkthrough

Walkthrough

Three feedback and widget components are being updated to reference a different global queue on the window object, changing from window._stmsg_widget to window._lasuite_widget. The widget initialization and command queueing logic uses the new queue name, while all other control flows remain unchanged.

Changes

Cohort / File(s) Summary
Widget Queue Migration
src/frontend/src/features/ui/components/feedback-button/index.tsx, src/frontend/src/features/ui/components/feedback-widget/index.tsx, src/frontend/src/features/ui/components/lagaufre/index.tsx
Replaced global widget queue references from window._stmsg_widget to window._lasuite_widget in widget initialization and command queueing logic.

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~5 minutes

🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 0.00% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (4 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title clearly conveys the main change: updating widget logic to a latest version across multiple frontend components.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share
Review rate limit: 0/1 reviews remaining, refill in 60 minutes.

Comment @coderabbitai help to get the list of available commands and usage tips.

Copy link
Copy Markdown

@coderabbitai coderabbitai Bot left a comment

Choose a reason for hiding this comment

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

Caution

Some comments are outside the diff and can’t be posted inline due to platform limitations.

⚠️ Outside diff range comments (1)
src/frontend/src/features/ui/components/feedback-widget/index.tsx (1)

31-63: 🧹 Nitpick | 🔵 Trivial | ⚡ Quick win

Confirm rollout sequencing for the new widget queue name.

This now writes only to window._lasuite_widget; if NEXT_PUBLIC_FEEDBACK_WIDGET_PATH still serves the older bundle, these init payloads will be dropped and the widget will stop bootstrapping. Please verify the new bundle is deployed atomically with this rename, or keep a temporary compatibility alias during rollout.

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@src/frontend/src/features/ui/components/feedback-widget/index.tsx` around
lines 31 - 63, The PR currently only writes init payloads to
window._lasuite_widget which can break bootstrapping if the deployed bundle
still expects the legacy global; update the widget initialization in index.tsx
so it maintains a compatibility alias: ensure both the new global
(window._lasuite_widget) and the legacy global (check for the previous global
name and/or create one) reference the same array or receive the same push, then
push the same payload (using loaderScript, feedbackScript, widget, params, etc.)
to both globals so older bundles still receive init events during rollout.
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Outside diff comments:
In `@src/frontend/src/features/ui/components/feedback-widget/index.tsx`:
- Around line 31-63: The PR currently only writes init payloads to
window._lasuite_widget which can break bootstrapping if the deployed bundle
still expects the legacy global; update the widget initialization in index.tsx
so it maintains a compatibility alias: ensure both the new global
(window._lasuite_widget) and the legacy global (check for the previous global
name and/or create one) reference the same array or receive the same push, then
push the same payload (using loaderScript, feedbackScript, widget, params, etc.)
to both globals so older bundles still receive init events during rollout.

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: ASSERTIVE

Plan: Pro

Run ID: 17b2123a-9c48-49f6-bd57-d8f2d33f1722

📥 Commits

Reviewing files that changed from the base of the PR and between 3cd2fd1 and b64c3ea.

📒 Files selected for processing (3)
  • src/frontend/src/features/ui/components/feedback-button/index.tsx
  • src/frontend/src/features/ui/components/feedback-widget/index.tsx
  • src/frontend/src/features/ui/components/lagaufre/index.tsx

@sylvinus sylvinus merged commit b12ebbf into main Apr 30, 2026
19 of 20 checks passed
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.

2 participants