var c=Object.create;var a=Object.defineProperty;var f=Object.getOwnPropertyDescriptor;var u=Object.getOwnPropertyNames;var S=Object.getPrototypeOf,g=Object.prototype.hasOwnProperty;var x=(o,i)=>{for(var n in i)a(o,n,{get:i[n],enumerable:!0})},d=(o,i,n,l)=>{if(i&&typeof i=="object"||typeof i=="function")for(let r of u(i))!g.call(o,r)&&r!==n&&a(o,r,{get:()=>i[r],enumerable:!(l=f(i,r))||l.enumerable});return o};var b=(o,i,n)=>(n=o!=null?c(S(o)):{},d(i||!o||!o.__esModule?a(n,"default",{value:o,enumerable:!0}):n,o)),p=o=>d(a({},"__esModule",{value:!0}),o);var y={};x(y,{default:()=>w});module.exports=p(y);var e=require("@chakra-ui/react"),s=b(require("@emotion/styled"),1),m=require("@solana/web3.js"),t=require("react/jsx-runtime"),h="https://docs.bonfida.org/collection/naming-service/how-to-create-a-solana-domain-name/purchasing-a-domain-name/direct-registration",T=(0,s.default)(e.Flex)`
  position: relative;
`,z=({size:o,setSize:i,loading:n,subTotalPrice:l})=>(0,t.jsxs)(T,{paddingY:4,flexDir:"column",alignItems:"center",children:[(0,t.jsxs)(e.Slider,{defaultValue:0,min:1,max:10,step:1,w:"94%",onChange:i,value:o,children:[(0,t.jsxs)(e.SliderTrack,{bg:"muted",children:[(0,t.jsx)(e.Box,{position:"relative",right:10}),(0,t.jsx)(e.SliderFilledTrack,{bg:"mutedForeground"})]}),(0,t.jsx)(e.SliderThumb,{boxSize:4,borderColor:"mutedForeground",borderWidth:"1"})]}),(0,t.jsxs)(e.Flex,{justifyContent:"space-between",w:"full",mt:"1",children:[(0,t.jsx)(e.Text,{fontSize:"12",children:"1 Kb"}),(0,t.jsx)(e.Text,{fontSize:"12",children:"10 Kb"})]}),(0,t.jsxs)(e.Flex,{w:"full",justifyContent:"space-between",children:[(0,t.jsxs)(e.Text,{fontSize:14,mt:4,fontWeight:"semibold",children:["Selected Size: ",`${o} Kb`]}),(0,t.jsx)(e.Text,{fontSize:14,mt:4,textDecoration:"underline",cursor:"pointer",onClick:()=>window.open(h),textAlign:"right",children:"How much storage is right for you?"})]}),(0,t.jsxs)(e.Flex,{w:"full",justifyContent:"space-between",alignItems:"center",children:[(0,t.jsx)(e.Text,{fontSize:14,mt:4,fontWeight:"bold",children:"Storage cost"}),(0,t.jsxs)(e.Flex,{alignItems:"flex-end",justifyContent:"center",mt:4,children:[n?(0,t.jsx)(e.Spinner,{size:"xs",mb:"1"}):(0,t.jsxs)(e.Text,{fontSize:14,fontWeight:"bold",children:["+",`${(l/m.LAMPORTS_PER_SOL).toFixed(5)}`]}),(0,t.jsx)(e.Text,{ml:"1",fontSize:14,fontWeight:"bold",children:"SOL"})]})]})]}),w=z;
