"use strict";var e=require("react/jsx-runtime"),k=require("../containers/button.js");require("../containers/card.js"),require("../../lib/cn.js");var b=require("../icons/ico-arrow-down.js"),N=require("../icons/ico-arrow-up.js"),R=require("../icons/ico-lightning-fill.js"),S=require("../icons/ico-lock-unlocked-fill.js");require("../primitives/button.js"),require("../primitives/checkbox.js"),require("../primitives/dropdown-selector.js"),require("../primitives/popover.js"),require("../primitives/radio.js"),require("../primitives/segmented-control.js"),require("../primitives/switch.js");var l=require("../primitives/text.js"),s=require("react");require("../utils/client-asset-logo.js"),require("react-qrcode-logo"),require("../utils/secured-by-magic.js"),require("../containers/header.js"),require("../containers/menu.js"),require("../containers/modal.js"),require("../containers/overlay.js"),require("../feedback/callout.js");var x=require("../feedback/skeleton.js");require("../primitives/portal.js"),require("../../hooks/useToast.js"),require("../feedback/tooltip.js");var v=require("create-slots");const W={send:{title:"Send",primaryTextColor:"var(--color-text-primary)",secondaryTextColor:"var(--color-text-secondary)",icon:N.default,iconColor:"var(--color-negative-darker)",skeletonWidth:"89px"},receive:{title:"Receive",primaryTextColor:"var(--color-positive-base)",secondaryTextColor:"var(--color-positive-lighter)",icon:b.default,iconColor:"var(--color-positive-base)",skeletonWidth:"89px"},networkFee:{title:"Network Fee",primaryTextColor:"var(--color-text-primary)",secondaryTextColor:"var(--color-text-secondary)",icon:R.default,iconColor:"var(--color-brand-base)",skeletonWidth:"54px"},spendingCap:{title:"Spending Cap",primaryTextColor:"var(--color-warning-base)",secondaryTextColor:"var(--color-warning-base)",icon:S.default,iconColor:"var(--color-warning-base)",skeletonWidth:"89px"}},h=v.createSlot(({children:i,...o})=>e.jsx("div",{className:"flex items-center justify-center",children:s.Children.map(i,t=>s.cloneElement(t,o))})),F=i=>{const{variant:o,primaryText:t,secondaryText:a,children:p,onPress:n,loading:c,showTitle:q=!0}=i,{title:m,primaryTextColor:d,secondaryTextColor:f,icon:w,iconColor:y,skeletonWidth:u}=W[o],g=o==="send"||o==="networkFee",C=s.useRef(null),j=s.useCallback(()=>{n?.()},[n]);return v.createHost(p,T=>{const r=T.get(h);return e.jsxs("div",{className:"flex flex-row items-center w-full justify-between",children:[e.jsxs("div",{className:"flex flex-row items-center gap-2",children:[e.jsx(w,{width:16,height:16,color:y}),q&&e.jsx(l.default,{size:"sm",fontWeight:"medium",children:m})]}),e.jsxs("div",{className:"flex flex-row items-center gap-4",children:[a&&e.jsx(l.default,{styles:{color:f},children:a}),g?e.jsx(k.ButtonContainer,{ref:C,className:"px-4 py-2.5 bg-surface-secondary",borderRadius:"0.75rem",onPress:j,...i,children:e.jsxs("div",{className:"flex flex-row items-center gap-3",children:[c?e.jsx(x.Skeleton,{width:u}):e.jsx(l.default,{styles:{color:d},children:t}),r&&{...r,props:{...r.props,width:32,height:32}}]})}):e.jsxs("div",{className:"flex flex-row items-center gap-3",children:[c?e.jsx(x.Skeleton,{width:u}):e.jsx(l.default,{styles:{color:d},children:t}),r&&{...r,props:{...r.props,width:32,height:32}}]})]})]})})},L=Object.assign(F,{TokenIcon:h});exports.TransactionRow=L;
//# sourceMappingURL=transaction-row.js.map
