docs: add hypercerts-lexicon v0.11.0 release notes with site-wide banner#116
Conversation
Add a dedicated release notes page covering breaking changes (evaluation scores, badge strong refs, funding receipt normalization), new lexicons (EVM identity linking, vendored Leaflet), and schema refinements. A dismissible announcement banner appears site-wide above the header linking directly to the release notes. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (4)
✅ Files skipped from review due to trivial changes (2)
🚧 Files skipped from review as they are similar to previous changes (2)
📝 WalkthroughWalkthroughA dismissible, localStorage-persisted AnnouncementBanner component and its styles were added and inserted into Layout; a release-notes page for Changes
Sequence Diagram(s)sequenceDiagram
participant User
participant Banner as AnnouncementBanner (client)
participant Storage as localStorage
participant Router as Next.js Link
User->>Banner: Page load / mount
Banner->>Storage: read "banner-dismissed-lexicon-v0.11.0"
alt key absent
Storage-->>Banner: null
Banner->>Banner: set dismissed = false (show)
else key present
Storage-->>Banner: "true"
Banner->>Banner: keep dismissed = true (hide)
end
User->>Banner: click close
Banner->>Storage: write "banner-dismissed-lexicon-v0.11.0" = "true"
User->>Banner: click release link
Banner->>Router: navigate to /reference/release-notes-v0-11-0
Estimated code review effort🎯 3 (Moderate) | ⏱️ ~20 minutes Possibly related PRs
Poem
🚥 Pre-merge checks | ✅ 2 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (2 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
Comment |
There was a problem hiding this comment.
🧹 Nitpick comments (2)
components/AnnouncementBanner.js (2)
9-12: Consider wrappinglocalStorageaccess in a try-catch.
localStoragecan throw exceptions in certain scenarios (e.g., Safari private browsing, storage quota exceeded). While the component will still work (defaulting to hidden), adding defensive error handling prevents console errors.🛡️ Proposed defensive localStorage access
useEffect(() => { - const stored = localStorage.getItem(`banner-dismissed-${BANNER_ID}`); - if (!stored) setDismissed(false); + try { + const stored = localStorage.getItem(`banner-dismissed-${BANNER_ID}`); + if (!stored) setDismissed(false); + } catch { + // localStorage unavailable; keep banner hidden + } }, []);🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed. In `@components/AnnouncementBanner.js` around lines 9 - 12, The useEffect in AnnouncementBanner uses localStorage.getItem with BANNER_ID and can throw in some environments; wrap the access in a try-catch around the localStorage.getItem call inside the useEffect (referencing useEffect, BANNER_ID, and setDismissed) and on error treat it as “no stored value” (e.g., leave dismissed false) while optionally logging the caught error to avoid uncaught exceptions in the console.
14-17: Same defensive handling applies to the dismiss function.If
localStorage.setItemthrows, the banner will still be hidden for the current session (state is set first), but the dismissal won't persist.🛡️ Proposed fix
const dismiss = () => { setDismissed(true); - localStorage.setItem(`banner-dismissed-${BANNER_ID}`, 'true'); + try { + localStorage.setItem(`banner-dismissed-${BANNER_ID}`, 'true'); + } catch { + // Persist failed; dismissal is session-only + } };🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed. In `@components/AnnouncementBanner.js` around lines 14 - 17, The dismiss function currently sets state then calls localStorage.setItem which can throw and prevent persistence; wrap the localStorage.setItem call in a try/catch (or guard with a typeof window !== 'undefined' && window.localStorage) inside the dismiss function, still call setDismissed(true) first, and on error swallow or log the exception via console.error (or a provided logger) while ensuring the UI remains dismissed; reference the dismiss function and BANNER_ID/localStorage.setItem when making this change.
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.
Nitpick comments:
In `@components/AnnouncementBanner.js`:
- Around line 9-12: The useEffect in AnnouncementBanner uses
localStorage.getItem with BANNER_ID and can throw in some environments; wrap the
access in a try-catch around the localStorage.getItem call inside the useEffect
(referencing useEffect, BANNER_ID, and setDismissed) and on error treat it as
“no stored value” (e.g., leave dismissed false) while optionally logging the
caught error to avoid uncaught exceptions in the console.
- Around line 14-17: The dismiss function currently sets state then calls
localStorage.setItem which can throw and prevent persistence; wrap the
localStorage.setItem call in a try/catch (or guard with a typeof window !==
'undefined' && window.localStorage) inside the dismiss function, still call
setDismissed(true) first, and on error swallow or log the exception via
console.error (or a provided logger) while ensuring the UI remains dismissed;
reference the dismiss function and BANNER_ID/localStorage.setItem when making
this change.
ℹ️ Review info
⚙️ Run configuration
Configuration used: defaults
Review profile: CHILL
Plan: Pro
Run ID: 706dff52-988f-4a69-aa9f-a43fb15ee366
📒 Files selected for processing (5)
components/AnnouncementBanner.jscomponents/Layout.jslib/navigation.jspages/reference/release-notes-v0-11-0.mdstyles/globals.css
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Resolve merge conflicts: - Layout.js: keep both AnnouncementBanner and CopyRawButton imports + SEO constants - lastUpdated.json: use main's newer timestamps and preserve release-notes entry Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Add a dedicated release notes page covering breaking changes (evaluation scores, badge strong refs, funding receipt normalization), new lexicons (EVM identity linking, vendored Leaflet), and schema refinements. A dismissible announcement banner appears site-wide above the header linking directly to the release notes.
Summary by CodeRabbit