Conversation
- add sticky course headers on tracking page - add right-side scroll-to-bottom floating button near tracking controls - switch accept-terms success navigation to router.replace to prevent back nav to terms - update legal policy text (Turnstile clarity, AWS ap-south-1 disclosure, Kochi jurisdiction) - bump terms version to 2.5 and align legal effective date docs/env examples - enhance legal page external link visibility and secure external link behavior - update related tests and mocks (tracking + save-token terms version)
|
✅ Version already bumped to No automatic version bump needed - the PR already includes a version update. This PR is ready for review! 🚀 |
There was a problem hiding this comment.
Pull request overview
Improves tracking UX (sticky course headers + scroll-to-bottom control) and updates legal/terms semantics (terms version bump + effective date/policy text), alongside related navigation and test updates.
Changes:
- Enhanced PWA back-to-exit behavior to better handle non-dashboard routes with deep history.
- Updated terms acceptance flow to use
router.replace()and refreshed legal/terms policy content + versions/dates. - Added tracking UI affordances (sticky headers + floating scroll-to-bottom button) and updated mocks/tests accordingly.
Reviewed changes
Copilot reviewed 13 out of 14 changed files in this pull request and generated 4 comments.
Show a summary per file
| File | Description |
|---|---|
| src/hooks/useBackToExit.ts | Adds “deep history” back-to-exit flow, centralizes toast/reset helpers. |
| src/hooks/tests/useBackToExit.test.ts | Adds tests for the new non-dashboard/deep-history exit behavior. |
| src/components/legal/AcceptTermsForm.tsx | Uses router.replace("/dashboard") after accepting terms to prevent back navigation to terms. |
| src/components/legal/tests/AcceptTermsForm.test.tsx | Adjusts router mock + assertions for replace() navigation. |
| src/app/config/legal.ts | Bumps terms version and updates legal effective date + policy text. |
| src/app/api/auth/save-token/tests/route.test.ts | Aligns terms cookie branching expectations with terms version bump. |
| src/app/(public)/legal/LegalClient.tsx | Improves external link visibility and adds secure external link behavior. |
| src/app/(protected)/tracking/TrackingClient.tsx | Adds floating scroll-to-bottom button and sticky course headers. |
| src/app/(protected)/tracking/tests/TrackingClient.test.tsx | Updates mocks to support new tracking behaviors/icons. |
| public/openapi/openapi.yaml | Bumps API version to 3.0.4. |
| package.json | Bumps app version to 3.0.4. |
| docs/DEVELOPER_GUIDE.md | Updates env var example for legal effective date. |
| .example.env | Updates app version and legal effective date example. |
Codecov Report❌ Patch coverage is 📢 Thoughts on this report? Let us know! |
…it state - use header-based scroll detection for pinned course title timing - adjust scroll-to-end FAB margins slightly on mobile and md breakpoints - reset non-dashboard back counter when exit state/toast is cleared - add regression test for deep-mode threshold expiry re-arming behavior
|
@copilot open a new pull request to apply changes based on the unresolved comments in this thread. Use depth then. |
…er into navDepthRef, fix Tailwind utilities (#583) * Initial plan * fix(pwa,tracking): extract clearState helper, use navDepthRef for deep-back tracking, fix Tailwind utilities Co-authored-by: devakesu <61821107+devakesu@users.noreply.github.com> * refine(pwa): clarify navDepthRef semantics and add comment on intentional separation from clearState Co-authored-by: devakesu <61821107+devakesu@users.noreply.github.com> * fix(pwa): merge navDepthRef into single qualifying-back counter, remove nonDashboardBackCountRef Co-authored-by: devakesu <61821107+devakesu@users.noreply.github.com> --------- Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com> Co-authored-by: devakesu <61821107+devakesu@users.noreply.github.com>
|
@copilot open a new pull request to apply changes based on the comments in this thread |
…n, activeCourseMeta lookup trim consistency (#584) * Initial plan * fix(tracking,pwa): guard toast callbacks, deduplicate scroll setState, fix activeCourseMeta lookups Co-authored-by: devakesu <61821107+devakesu@users.noreply.github.com> --------- Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com> Co-authored-by: devakesu <61821107+devakesu@users.noreply.github.com>
… logic in useBackToExit
There was a problem hiding this comment.
Pull request overview
Copilot reviewed 13 out of 14 changed files in this pull request and generated 1 comment.
Comments suppressed due to low confidence (1)
src/hooks/useBackToExit.ts:132
- The comment above this conditional says mid-app back presses are ignored, but the implementation now handles non-sentinel popstate events for “deep mode” (counts backs and may show the exit toast / close). Please update/remove this comment so it matches the new behavior to avoid misleading future changes.
// Ignore mid-app back presses — their state doesn't carry a true sentinel.
// Strict === true check avoids accidental matches if __gce ever appears
// with a falsy value in some other history entry.
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com> Signed-off-by: Devanarayanan <fusion@devakesu.com>
|
@copilot open a new pull request to apply changes based on the comments in this thread |
…mments (#585) * Initial plan * fix(tracking,hooks): add aria-hidden to decorative BookOpen icons and update stale comments Co-authored-by: devakesu <61821107+devakesu@users.noreply.github.com> --------- Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com> Co-authored-by: devakesu <61821107+devakesu@users.noreply.github.com>
Pull Request
Description
feat(tracking,legal): improve tracking UX and align legal policy updates
Type of Change
Version Bump
node scripts/bump-version.js(fork PRs)