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

feature: collateral settings/manager #2703

Merged
merged 24 commits into from
Sep 25, 2023
Merged

feature: collateral settings/manager #2703

merged 24 commits into from
Sep 25, 2023

Conversation

stackchain
Copy link
Member

@stackchain stackchain commented Sep 24, 2023

  • add collateral to utxos manager
  • set initial state to load collateral
  • remove collateral from other utxos when set (affects balance)
  • auto assign a pure utxo as collateral
  • create a tx to create the collateral
  • remove selected collateral
  • check copies with product
  • check suggested layout with product
  • check states (with collateral, with collateral consumed, without collateral)
  • check state - no balance for collateral (tx creation, balance - deposit >= min collateral)
  • check collateral range 5-10 ADA with product (defined 2-5 ADA)
  • the yoroi-lib is complaining when sending to own external (missing vkey)
  • between the dispatch of unsingedTx and navigation it needs a little delay, the state is not committed when navigating to confirmTx (unsingedTx is empty)
  • wrap collateral stories within SendProvider (added later)
  • translations

},
)

const {isLoading: isLoadingCollateral, setCollateralId} = useSetCollateralId(wallet)
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is there any way we can call setCollateralId right after we submit the TX? If not, do we have to navigate back to this screen and click "generate collateral" again?

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@stackchain ⬆️

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should setCollateralId(`${signedTx.signedTx.id}:0`); in onSuccess in ConfirmTxScreen work? I don't quite like the index is hardcoded

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

can you read the outputs of the unsigned tx?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

let's create task for these 3 remaining items

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hello @stackchain 3 remaining items, you mean the following?

  1. setCollateralId after tx is completed
  2. check copies with product
  3. check suggested layout with product

@stackchain stackchain merged commit cb36531 into develop Sep 25, 2023
@stackchain stackchain deleted the feature/collateral branch September 25, 2023 17:40
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants