Move the wallet-aware components out of ui into domain - #245
Closed
droplister wants to merge 1 commit into
Closed
Conversation
components/ splits ui/ - widgets that do not know what an asset is - from domain/, which is where the wallet-aware ones belong. The split existed but the population had gone the other way: domain/ held 4 files while ui/ held 27 referencing assets, dispensers, balances and wallets between 8 and 41 times each. asset-select-input alone had 41. Placed by subject rather than by widget kind, because that is how domain/ is already organised (approval, asset, price, tx): asset, balance, dispenser, wallet, utxo and address. A dispenser card and a dispenser input belong together more than two cards do. ui/ now has no file with eight or more domain references, measured the same way the list was built. Moves and import specifiers only. Claude-Session: https://claude.ai/code/session_01CcjnCrgosSeshymXLBxdGj
Member
Author
|
Squashed into #249. |
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.
Stacked on #244.
components/splitsui/— widgets that don't know what an asset is — fromdomain/, which is where wallet-aware ones belong. The split existed; the population had gone the other way.domain/held 4 files.ui/held 27 referencing assets, dispensers, balances and wallets between 8 and 41 times each:ui/inputs/asset-select-inputui/cards/asset-cardui/cards/dispenser-cardui/inputs/dispenser-inputui/menus/wallet-menuSame failure as
utils/, one level down: a folder whose admission test isn't enforced drifts.Placement
By subject, not widget kind — because that's how
domain/is already organised (approval,asset,price,tx). A dispenser card and a dispenser input belong together more than two cards do.asset/(9) ·balance/(5) ·dispenser/(5) ·wallet/(3) ·utxo/(3) ·address/(2)50 files moved including tests.
Result
ui/now has zero files with 8+ domain references, measured the same way the list was built.Verification
tsc --noEmitclean;biome check srccleanvitest run src— 4049 passed, 49 skippedwxt buildsucceeds, bundle unchanged at 2.46 MBplaywright test e2e/inputs/asset-select-input.spec.ts— 7 passedMoves and import specifiers only.