Repository navigation
fix(settings): prevent false unsaved prompts and preserve drafts - #8704
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
|
@cubic-dev-ai review this PR |
@waleedlatif1 I have started the AI code review. It will take a few minutes to complete. |
There was a problem hiding this comment.
All reported issues were addressed across 3 files
Reply with feedback, questions, or to request a fix.
Fix all with cubic | Turn on auto-fix | Re-trigger cubic
|
045b060 to
22fe83b
Compare
|
@cubic-dev-ai review this PR |
@waleedlatif1 I have started the AI code review. It will take a few minutes to complete. |
|
@cubic-dev-ai review this PR |
@waleedlatif1 I have started the AI code review. It will take a few minutes to complete. |
There was a problem hiding this comment.
All reported issues were addressed across 53 files
Reply with feedback, questions, or to request a fix.
Fix all with cubic | Turn on auto-fix | Re-trigger cubic
|
@cubic-dev-ai review this PR |
@waleedlatif1 I have started the AI code review. It will take a few minutes to complete. |
There was a problem hiding this comment.
2 issues found across 53 files
You've manually re-run cubic several times on this PR. Each manual re-review checks the full PR again and counts toward your usage quota. To preserve your usage limits, we recommend letting cubic automatically review new commits.
Fix all with cubic | Turn on auto-fix | Re-trigger cubic
Prompt for AI agents (unresolved issues)
Check if these issues are valid — if so, understand the root cause of each and fix them. When an issue isn't valid or won't be fixed in this PR, reply in its thread with the reason and then resolve the thread. If appropriate, use sub-agents to investigate and fix each issue separately.
<file name="apps/sim/components/settings/use-settings-browser-navigation.ts">
<violation number="1" location="apps/sim/components/settings/use-settings-browser-navigation.ts:50">
P2: This stamp also rewrites non-plain structured-clone state: spreading a `Map` drops its entries, and spreading a `Date` drops its value. Stamp only plain-object state and leave other state types intact.</violation>
<violation number="2" location="apps/sim/components/settings/use-settings-browser-navigation.ts:101">
P2: A confirmed traversal beyond the history boundary emits no `popstate`, leaving `allowTraversal` set; a later Back with the same delta then bypasses the dirty-state check and can lose a new draft. Clear this authorization when a traversal is superseded or produces no matching event.</violation>
</file>
|
@cubic-dev-ai review this PR |
@waleedlatif1 I have started the AI code review. It will take a few minutes to complete. |
There was a problem hiding this comment.
All reported issues were addressed across 53 files
You've manually re-run cubic several times on this PR. Each manual re-review checks the full PR again and counts toward your usage quota. To preserve your usage limits, we recommend letting cubic automatically review new commits.
Fix all with cubic | Turn on auto-fix | Re-trigger cubic
|
@cubic-dev-ai review this PR |
@waleedlatif1 I have started the AI code review. It will take a few minutes to complete. |
There was a problem hiding this comment.
No issues found across 53 files
Confidence score: 5/5
- Automated review surfaced no issues in the provided summaries.
- No files require special attention.
You've manually re-run cubic several times on this PR. Each manual re-review checks the full PR again and counts toward your usage quota. To preserve your usage limits, we recommend letting cubic automatically review new commits.
Turn on auto-fix | Re-trigger cubic
Summary
Browser support boundary
Native Back/Forward uses Navigation API indexes or entries tracked by the app. Without the Navigation API, unindexed native entries cannot be cancelled reliably because popstate exposes no direction; those traversals pass through without guessing or rewriting the history stack. Programmatic traversal and beforeunload remain guarded. Unknown classic cross-document traversal may require native confirmation after the shared dialog; permission never suppresses later unload protection.
Type of Change
Testing
Checklist