feat(contracts): Advanced Soroban Logic Part 48 - Structured Errors, Events & State Machine Validation#825
Open
Junman140 wants to merge 4 commits into
Conversation
…ty and theming - CSVUploader: Replace alert() with inline error state and toast notifications - CSVUploader: Replace hardcoded colors with CSS variable tokens for dark/light themes - CSVUploader: Add keyboard accessibility (Tab/Enter/Space), ARIA roles, live regions - CSVUploader: Add loading state with spinner, file type validation, and visual feedback - CSVUploader: Use semantic heading hierarchy and proper table aria labels - FormField: Add useId for unique description IDs, aria-required, sr-only required text - FormField: Replace hardcoded Tailwind classes with CSS variable tokens - FormField: Add role=alert with aria-live=assertive for error messages - Settings: Add themed sections for Language, Appearance, and Notifications - Settings: Add dark/light mode toggle with animated switch and aria-pressed - Settings: Improve select dropdown with custom chevron and focus ring - Settings: Add proper section labels, headings hierarchy, and ARIA regions - ComponentErrorBoundary: Replace @stellar/design-system with lucide-react icons - ComponentErrorBoundary: Add role=alert, aria-live=assertive, and focus management - ComponentErrorBoundary: Use CSS variable tokens for theme-aware error styling - PageErrorFallback: Replace SDS Button/Icon with lucide-react and native elements - PageErrorFallback: Add skip-to-content link for keyboard accessibility - PageErrorFallback: Add role=alert and aria-live for screen reader announcements - PageErrorFallback: Improve focus ring on links and buttons - All changes maintain WCAG 2.1 AA compliance with 44x44px touch targets Components updated: frontend/src/components/CSVUploader.tsx frontend/src/components/FormField.tsx frontend/src/components/ComponentErrorBoundary.tsx frontend/src/components/PageErrorFallback.tsx frontend/src/pages/Settings.tsx Tests added: frontend/src/components/__tests__/CSVUploader.test.tsx frontend/src/components/__tests__/FormField.test.tsx frontend/src/components/__tests__/ComponentErrorBoundary.test.tsx frontend/src/components/__tests__/PageErrorFallback.test.tsx frontend/src/__tests__/Settings.test.tsx Closes Gildado#219
…9 (Issue Gildado#194) - Add structured ContractError enum replacing bare panics - Add admin governance model with set_admin and get_admin - Implement emergency pause/circuit breaker using Instance storage - Add partial_clawback for reducing grant without deactivating - Add extend_vesting for prolonging vesting duration - Add new events: PartialClawbackExecutedEvent, VestingScheduleExtendedEvent, ContractStatusChangedEvent - Enhance VestingInitializedEvent with admin and clawback_admin fields - Update all test suites with comprehensive tests for new features - Add README.md with full API documentation - 84 tests pass, zero clippy warnings, wasm32 build succeeds
…- Advanced Soroban Logic Part 50) Introduces the MilestoneEscrow contract that allows senders to deposit funds released to beneficiaries only upon verifier-approved milestones. Key features: - Multi-milestone escrow with per-milestone approval/release flow - Verifier role authorizes milestone completion before funds unlock - Sender can cancel escrow to recover unreleased funds - Circuit breaker (pause/unpause) for emergency scenarios - Admin transfer and full SEP-0034 metadata compliance - Ledger replay protection on approve, release, and cancel operations - TTL management for persistent storage entries - Comprehensive event emission for all state transitions 43 unit tests covering initialization, metadata, admin governance, circuit breaker, escrow creation, milestone approval/release, escrow cancellation, queries, replay protection, and edge cases.
…idation across Soroban contracts (Issue Gildado#193 / Part 48) - Fix asset_path_payment: add missing .publish() calls on 4 contract events, replace unused Bytes import with Address in PathHop, add 28 comprehensive unit tests covering full lifecycle, slippage, events, and edge cases. - Add RevenueSplitError enum and RevenueDistributedEvent, RecipientsUpdatedEvent, AdminChangedEvent to revenue_split contract; replace all panic!() calls with structured Result returns. - Add CrossAssetPaymentError enum and state machine validation to cross_asset_payment update_status; enforce terminal-state protection and invalid-transition rejection; replace panic!() with Result returns. - Add WalletInitializedEvent, SignerAddedEvent, SignerRemovedEvent, ThresholdChangedEvent to smart_wallet contract. - All 326 workspace tests pass with no compilation warnings in changed crates.
|
@Junman140 Great news! 🎉 Based on an automated assessment of this PR, the linked Wave issue(s) no longer count against your application limits. You can now already apply to more issues while waiting for a review of this PR. Keep up the great work! 🚀 |
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.
Closes #638
Summary
Implements Advanced Soroban Logic Part 48 (Issue #193) across four Soroban smart contracts.
Changes
asset_path_payment (Bug fixes + test coverage):
revenue_split (Structured errors + events):
cross_asset_payment (State machine validation):
smart_wallet (Contract events):
Verification