const e=require(`../../constants/chains.constants.cjs`),t=require(`../../functions/utils/token-check.utils.cjs`),n=require(`../../functions/utils/getRecipientInfoFromUserKeys.cjs`),r=require(`./hinkalSolanaDeposit.cjs`);var i=async(i,a,o,s,c,l=!1)=>{if(a.length===0)throw Error(`erc20Tokens must not be empty`);if(a.length!==o.length)throw Error(`erc20Tokens and amountChanges length mismatch`);if(!e.isSolanaLike(t.validateAndGetChainId(a)))throw Error(`hinkalSolanaProoflessDepositHash: non-Solana chain`);let u=a[0];if(!a.every(e=>e.erc20TokenAddress===u.erc20TokenAddress))throw Error(`Solana prooflessDeposit supports one mint per transaction`);if(s&&s.length!==o.length)throw Error(`Stealth address structures length mismatch`);return r.submitSolanaProoflessDeposit(i,u,o,s??o.map(()=>n.getStealthAddressStructureFromUserKeys(i.userKeys)),c,l)};exports.hinkalSolanaProoflessDeposit=i;