Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add multiple nodes #2

Closed
wants to merge 4 commits into from
Closed

Add multiple nodes #2

wants to merge 4 commits into from

Conversation

rhochmayr
Copy link
Owner

This pull request introduces a new feature to support the addition of multiple nodes at once and includes several updates to the relevant components and documentation. The most important changes include updates to the README.md, modifications to the Input component to support multiline input, and enhancements to the AddWalletForm and useWalletData to handle multiple wallet addresses.

New Feature: Bulk Addition of Nodes

  • README.md: Added instructions for adding multiple nodes at once, including details on input formats and validation. [1] [2]

Component Updates

Form Enhancements

Hook Improvements

* **Form Handling**: Update form to accept multiple node addresses, validate each address individually, and handle bulk addition.
* **UI Adjustments**: Adjust UI to support multiline input and update placeholder text.
* **Error Handling**: Report invalid addresses without stopping the addition of valid ones.

Update addWallet function in useWalletData to handle multiple addresses

* **Validation**: Validate each address individually and report invalid ones.
* **Error Handling**: Ensure error handling for each address.

Update README.md to reflect new feature

* **Instructions**: Add instructions for adding multiple nodes at once.
…th `Textarea` in `AddWalletForm`

* **Input Component**
  - Remove `multiline` prop from `Input` component in `src/components/ui/input.tsx`

* **AddWalletForm Component**
  - Replace `Input` component with `Textarea` component for wallet addresses in `src/components/wallet/AddWalletForm.tsx`
  - Set `maxLength` prop of `Textarea` component to 2500 characters
  - Update `handleKeyDown` function to use `HTMLTextAreaElement` instead of `HTMLInputElement`
…dresses

* Modify `addWallet` function in `useWalletData.ts` to accept an array of addresses and fetch data sequentially
* Adjust `handleSubmit` function in `AddWalletForm.tsx` to call `onAddWallet` with an array of valid addresses
* Update `AddWalletFormProps` interface to reflect the change in `onAddWallet` parameter
@rhochmayr rhochmayr closed this Oct 28, 2024
@rhochmayr rhochmayr deleted the add-multiple-nodes branch October 28, 2024 01:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant