"use strict";var p=Object.create;var n=Object.defineProperty;var d=Object.getOwnPropertyDescriptor;var S=Object.getOwnPropertyNames;var g=Object.getPrototypeOf,M=Object.prototype.hasOwnProperty;var T=(t,e)=>{for(var s in e)n(t,s,{get:e[s],enumerable:!0})},u=(t,e,s,c)=>{if(e&&typeof e=="object"||typeof e=="function")for(let a of S(e))!M.call(t,a)&&a!==s&&n(t,a,{get:()=>e[a],enumerable:!(c=d(e,a))||c.enumerable});return t};var N=(t,e,s)=>(s=t!=null?p(g(t)):{},u(e||!t||!t.__esModule?n(s,"default",{value:t,enumerable:!0}):s,t)),x=t=>u(n({},"__esModule",{value:!0}),t);var v={};T(v,{default:()=>h});module.exports=x(v);var o=N(require("react")),y=({message:t,containerProps:e,stepProps:s,buttonProps:c})=>{let[a,b]=(0,o.useState)([]),i=async(r,l)=>{try{console.log(r),b([...a,l]),console.log(`Step ${l+1} executed successfully`)}catch(m){console.error(`Error executing step ${l+1}:`,m)}};return o.default.createElement("div",{...e,className:`text-black my-2  ${e?.className||""}`},o.default.createElement("h3",{className:"text-lg font-bold mb-2"},"Multi-Step Transaction"),t.steps.map((r,l)=>o.default.createElement("div",{key:l,...s,className:`border-b border-gray-400 pb-4 mb-4 last:border-b-0 last:pb-0 last:mb-0 ${s?.className||""}`},o.default.createElement("h4",{className:"font-semibold text-md mb-2"},r.title),o.default.createElement("p",{className:"text-sm mb-2"},r.description),o.default.createElement("p",{className:"text-sm mb-2"},o.default.createElement("strong",null,"Success Condition:")," ",r.successCondition),o.default.createElement("button",{...c,onClick:()=>i(r,l),disabled:a.includes(l),className:`px-4 py-2 rounded ${a.includes(l)?"bg-gray-300 cursor-not-allowed":"bg-blue-500 text-white hover:bg-blue-600"} ${c?.className||""}`},a.includes(l)?"Executed":"Execute Step"))))},h=y;
//# sourceMappingURL=MultiStepTransactionBubble.js.map