Removed ~580 lines of duplicate code from tangle-dapp and tangle-cloud that already exist in tangle-shared-ui.
Files Deleted:
apps/tangle-cloud/src/components/ErrorMessage.tsx✅apps/tangle-dapp/src/components/ErrorMessage.tsx✅
Imports Updated: 20 files now import from @tangle-network/tangle-shared-ui/components/ErrorMessage
Files Deleted:
apps/tangle-dapp/src/components/InputWrapper.tsx✅
Imports Updated: AmountInput, TextInput, PercentageInput, AddressInput
Files Deleted:
apps/tangle-dapp/src/components/InputAction.tsx✅
Files Deleted:
apps/tangle-dapp/src/hooks/useInputAmount.ts✅
Imports Updated: AmountInput.tsx
Files Deleted:
apps/tangle-dapp/src/utils/parseChainUnits.ts✅
Files Deleted:
apps/tangle-dapp/src/utils/cleanNumericInputString.ts✅
Imports Updated: useCustomInputValue.ts
Files Deleted:
apps/tangle-dapp/src/context/ErrorsContext/ErrorsContext.ts✅apps/tangle-dapp/src/context/ErrorsContext/useErrorCountContext.ts✅apps/tangle-dapp/src/context/ErrorsContext/index.ts✅
- ✅ tangle-cloud: Builds successfully
⚠️ tangle-dapp: Has pre-existing build errors unrelated to this PR (graphql export issue)
- tangle-dapp version is almost identical but kept for now
- Only difference is import paths (uses full package path vs relative)
- Could be unified in future PR
- Different implementations serving different purposes
- tangle-dapp version wraps the shared-ui version
- Intentionally different
| Category | Lines Removed |
|---|---|
| Components | 297 |
| Hooks | 192 |
| Utils | 83 |
| Context | 55 |
| Total | ~580 lines |