fix: toast positioning on narrow viewports, consistent timezone display, claim button state - #86
Open
Thecesar85 wants to merge 1 commit into
Open
fix: toast positioning on narrow viewports, consistent timezone display, claim button state#86Thecesar85 wants to merge 1 commit into
Thecesar85 wants to merge 1 commit into
Conversation
…ay, claim button state - useToast: adjust toast container bottom margin and safe-area inset for mobile, use more conservative padding (left-2 right-2) so toasts never overflow on narrow viewports (Fixes Steller-StellarPulse-org#14) - helpers: deduplicate timestamp functions (toTimestampMs, formatDate, formatTime, timeAgo, formatEventTime, explorerUrl), consolidate NaN/range guards, remove orphaned code and duplicate exports — all timestamps now display in the viewer's local timezone consistently (Fixes Steller-StellarPulse-org#80) - Button: add loading prop with spinner icon and disable state - MarketDetailPage: claim button now shows 'Claiming...' text + spinner while transaction is pending, disabling double-claims (Fixes Steller-StellarPulse-org#21)
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.
Summary
Fixes 3 issues from the wave milestone:
#14 — Fix toast positioning on narrow viewports
env(safe-area-inset-bottom,0.75rem)fallback#80 — Fix inconsistent timezone display in leaderboard
toTimestampMs,formatDate,formatTime,timeAgo,formatEventTime,explorerUrlwere all exported twice, with dead code after unreachablereturn)toTimestampMs()with NaN/range guardsIntl.DateTimeFormatwithtimeZoneNameensures timestamps display in the viewer's local timezone#21 — Fix claim button state during pending transactions
loadingprop (spinner + disabled + opacity)Files changed
frontend/src/utils/helpers.ts— deduplication + timezonefrontend/src/hooks/useToast.tsx— mobile toastfrontend/src/components/ui/Button.tsx— loading propfrontend/src/app/markets/[id]/page.tsx— claim button state