import type { LucideIcon } from 'lucide-react'
import { TerminalIcon } from 'lucide-react'
import React from 'react'
import { type SVGProps } from 'react'

export function create({ icon: Icon }: { icon?: LucideIcon }): React.ReactElement {
  return (
    <div className="rounded-md border bg-gradient-to-b from-fd-secondary p-1 shadow-sm">
      {Icon ? <Icon /> : <TerminalIcon />}
    </div>
  )
}

export const SolanaIcon = (props: SVGProps<SVGSVGElement>) => {
  return (
    <svg width="40" height="40" viewBox="0 0 40 40" fill="none" xmlns="http://www.w3.org/2000/svg">
      <g clipPath="url(#clip0_903_158)">
        <rect width="40" height="40" />
        <g clipPath="url(#clip1_903_158)">
          <path
            d="M34.3616 27.4991L29.4894 32.6459C29.3835 32.7577 29.2554 32.8468 29.113 32.9078C28.9706 32.9687 28.817 33.0001 28.6617 33H5.56562C5.45541 33 5.34761 32.9683 5.25545 32.9088C5.1633 32.8492 5.0908 32.7645 5.04688 32.6649C5.00295 32.5654 4.9895 32.4554 5.00819 32.3484C5.02688 32.2414 5.07689 32.1421 5.15207 32.0628L10.0278 26.916C10.1335 26.8045 10.2612 26.7155 10.4031 26.6546C10.5451 26.5937 10.6982 26.5622 10.8531 26.5619H33.9479C34.0581 26.5619 34.1659 26.5936 34.2581 26.6531C34.3502 26.7127 34.4226 26.7974 34.4668 26.897C34.5106 26.9965 34.524 27.1065 34.5053 27.2135C34.4866 27.3205 34.4367 27.4198 34.3616 27.4991ZM29.4894 17.135C29.3835 17.0232 29.2554 16.9341 29.113 16.8732C28.9706 16.8123 28.817 16.7809 28.6617 16.781H5.56562C5.45541 16.781 5.34761 16.8127 5.25545 16.8722C5.1633 16.9317 5.0908 17.0165 5.04688 17.116C5.00295 17.2156 4.9895 17.3256 5.00819 17.4326C5.02688 17.5395 5.07689 17.6388 5.15207 17.7182L10.0278 22.865C10.1335 22.9765 10.2612 23.0654 10.4031 23.1263C10.5451 23.1872 10.6982 23.2188 10.8531 23.219H33.9479C34.0581 23.219 34.1659 23.1873 34.2581 23.1278C34.3502 23.0683 34.4226 22.9835 34.4668 22.884C34.5106 22.7844 34.524 22.6744 34.5053 22.5674C34.4866 22.4605 34.4367 22.3612 34.3616 22.2818L29.4894 17.135ZM5.56562 13.4381H28.6617C28.817 13.4382 28.9706 13.4068 29.113 13.3459C29.2554 13.2849 29.3835 13.1958 29.4894 13.084L34.3616 7.93724C34.4367 7.85787 34.4866 7.7586 34.5053 7.65162C34.524 7.54465 34.5106 7.43462 34.4668 7.33507C34.4226 7.23552 34.3502 7.15077 34.2581 7.09124C34.1659 7.03172 34.0581 7 33.9479 7H10.8531C10.6982 7.00026 10.5451 7.03182 10.4031 7.09273C10.2612 7.15364 10.1335 7.24259 10.0278 7.3541L5.15333 12.5009C5.07822 12.5801 5.02823 12.6793 5.0095 12.7862C4.99077 12.893 5.00411 13.003 5.04788 13.1025C5.09165 13.202 5.16396 13.2867 5.25592 13.3463C5.34789 13.406 5.45552 13.4378 5.56562 13.4381Z"
            fill="url(#paint0_linear_903_158)"
          />
        </g>
      </g>
      <defs>
        <linearGradient
          id="paint0_linear_903_158"
          x1="7.49129"
          y1="33.6197"
          x2="31.3025"
          y2="6.36876"
          gradientUnits="userSpaceOnUse"
        >
          <stop offset="0.08" stopColor="#9945FF" />
          <stop offset="0.3" stopColor="#8752F3" />
          <stop offset="0.5" stopColor="#5497D5" />
          <stop offset="0.6" stopColor="#43B4CA" />
          <stop offset="0.72" stopColor="#28E0B9" />
          <stop offset="0.97" stopColor="#19FB9B" />
        </linearGradient>
        <clipPath id="clip0_903_158">
          <rect width="40" height="40" fill="white" />
        </clipPath>
        <clipPath id="clip1_903_158">
          <rect width="29.5135" height="26" fill="white" transform="translate(5 7)" />
        </clipPath>
      </defs>
    </svg>
  )
}

export const StellarIcon = (props: SVGProps<SVGSVGElement>) => {
  return (
    <svg width="40" height="40" viewBox="0 0 40 40" fill="none" xmlns="http://www.w3.org/2000/svg">
      <g clipPath="url(#clip0_903_157)">
        <rect width="40" height="40" />
        <path
          fillRule="evenodd"
          clipRule="evenodd"
          d="M30.8999 10.4679L27.1286 12.3893L8.91751 21.6651C8.85593 21.1954 8.82494 20.7222 8.82475 20.2486C8.82724 18.3585 9.32346 16.5019 10.2642 14.8627C11.2051 13.2235 12.5578 11.8584 14.1884 10.9029C15.8191 9.94729 17.6711 9.4343 19.561 9.41471C21.451 9.39512 23.3132 9.86962 24.9633 10.7912L27.1219 9.69136L27.444 9.52705C25.4665 8.09179 23.1308 7.23123 20.6948 7.04046C18.2589 6.84968 15.8176 7.33613 13.6409 8.44604C11.4641 9.55595 9.63665 11.2461 8.36039 13.3297C7.08413 15.4132 6.40881 17.8092 6.40906 20.2526C6.40906 20.59 6.42187 20.9261 6.44749 21.261C6.48337 21.7351 6.37821 22.2092 6.14526 22.6238C5.91229 23.0383 5.56194 23.3747 5.13827 23.5905L4 24.1709V26.8781L7.35122 25.1701L8.43649 24.6162L9.50586 24.0715L28.7041 14.2895L30.8614 13.191L35.3204 10.9184V8.21253L30.8999 10.4679ZM35.3204 13.6282L10.5964 26.2168L8.43914 27.3179L4 29.5799V32.2845L8.40866 30.0384L12.1799 28.117L30.4096 18.8279C30.4712 19.3007 30.5022 19.777 30.5023 20.2537C30.5011 22.1459 30.0051 24.005 29.0634 25.6462C28.1217 27.2874 26.7671 28.6538 25.134 29.6097C23.501 30.5656 21.6464 31.0777 19.7542 31.0953C17.8621 31.1128 15.9983 30.6352 14.3478 29.7098L14.2153 29.78L11.8752 30.9726C13.8522 32.4079 16.1874 33.2687 18.623 33.46C21.0585 33.6512 23.4995 33.1654 25.6763 32.0562C27.853 30.9471 29.6808 29.2578 30.9576 27.1749C32.2344 25.0921 32.9106 22.6968 32.9114 20.2537C32.9114 19.9132 32.8981 19.5726 32.873 19.2361C32.8371 18.7621 32.9422 18.2881 33.1749 17.8736C33.4076 17.4591 33.7575 17.1227 34.1808 16.9065L35.3204 16.3261V13.6282ZM65.8457 22.6853C65.8457 18.2899 68.7795 15.5071 72.5615 15.5071C76.8059 15.5071 79.3024 19.0319 79.0188 23.4313H68.3673C68.4442 26.4155 70.6056 27.8559 72.6384 27.8559C74.6976 27.8559 75.8292 26.9296 76.4202 25.5661H78.8386C78.2211 27.9341 76.0095 29.9151 72.6384 29.9151C68.264 29.9151 65.8457 26.7759 65.8457 22.6853ZM72.5615 17.5133C70.5023 17.5133 68.5992 18.641 68.3926 21.4238H76.5488C76.4719 19.4692 75.0567 17.5133 72.5615 17.5133ZM51.6043 18.8744L49.4496 18.3854C47.6938 17.9985 46.4019 17.1769 46.4019 15.5298C46.4019 13.4453 48.9196 12.8027 50.364 12.8027C52.2191 12.8027 54.3777 13.5487 54.9952 15.6835H57.5434C56.7961 12.1056 53.8331 10.5897 50.4673 10.5897C47.4567 10.5897 43.7264 12.1083 43.7264 15.6835C43.7264 18.771 46.2733 20.2127 48.8467 20.7786L51.1723 21.2675C53.5138 21.8082 55.1861 22.5794 55.1861 24.5604C55.1861 26.4156 53.6171 27.6996 50.8383 27.6996C47.931 27.6996 46.1819 26.3613 45.6929 23.7892H43.1142C43.6032 27.4995 46.382 29.9126 50.7814 29.9126C54.4917 29.9126 57.8827 27.9567 57.8827 24.3285C57.8827 20.5732 54.4612 19.4919 51.6043 18.8744ZM60.5693 12.2616H62.9108V15.7348H65.5345V17.6138H62.9108V25.8216C62.9108 27.262 63.0128 27.6224 64.3511 27.6224H65.5345V29.5769H63.837C61.1868 29.5769 60.5693 28.9859 60.5693 26.1038V17.6138H58.3815V15.7348H60.5693V12.2616ZM109.306 15.6606C107.478 15.7374 106.09 16.5881 105.395 18.1558V15.7374H103.104V29.5796H105.446V22.3246C105.446 19.2371 106.527 18.0842 108.688 18.0842C109.127 18.0843 109.566 18.1189 110 18.1876V15.6857C109.769 15.6657 109.538 15.6573 109.306 15.6606ZM100.876 21.1692L100.851 24.3601C100.824 26.6976 100.928 28.2665 101.21 29.5824H98.8432C98.7431 28.9525 98.6829 28.3169 98.663 27.6795C97.8149 29.1226 96.3997 29.9176 93.9297 29.9176C91.3311 29.9176 89.1698 28.4759 89.1698 25.929C89.1698 22.656 92.8749 21.6847 98.5344 21.0658V20.7319C98.5344 18.185 97.1457 17.3621 95.3952 17.3621C93.4407 17.3621 92.3342 18.3918 92.2309 20.1144H89.8125C90.0179 17.1303 92.6947 15.458 95.3701 15.458C99.2553 15.458 100.902 17.2323 100.876 21.1692ZM94.4438 28.0651C96.6316 28.0651 98.7147 27.0607 98.7147 23.7943V22.9184C94.469 23.3305 91.7684 23.9732 91.7684 25.8773C91.7684 27.1905 92.7715 28.0651 94.4438 28.0651ZM82.9345 10.9158H80.593V29.5787H82.9345V10.9158ZM85.2747 10.9158H87.6161V29.5787H85.2747V10.9158Z"
          fill="white"
        />
      </g>
      <defs>
        <clipPath id="clip0_903_157">
          <rect width="40" height="40" fill="white" />
        </clipPath>
      </defs>
    </svg>
  )
}
export const StarknetIcon = (props: SVGProps<SVGSVGElement>) => {
  return (
    <svg width="40" height="40" viewBox="0 0 40 40" fill="none" xmlns="http://www.w3.org/2000/svg">
      <g clipPath="url(#clip0_904_172)">
        <g clipPath="url(#clip1_904_172)">
          <path
            d="M7 19.9998C7 27.1795 12.8201 32.9997 19.9998 32.9997C27.1795 32.9997 33 27.1795 33 19.9998C33 12.8201 27.1795 7 19.9998 7C12.8201 7 7 12.8201 7 19.9998Z"
            fill="#0C0C4F"
          />
          <path
            d="M14.2659 16.937L14.5868 15.9456C14.652 15.7439 14.8111 15.587 15.0135 15.5251L16.0098 15.2188C16.1477 15.1766 16.1488 14.9821 16.012 14.9377L15.0202 14.6168C14.819 14.5516 14.662 14.3924 14.5998 14.1901L14.2938 13.1938C14.2517 13.0563 14.0571 13.0548 14.0128 13.1919L13.6919 14.1834C13.6266 14.3846 13.4675 14.5415 13.2651 14.6038L12.2688 14.9098C12.1309 14.9523 12.1294 15.1465 12.2666 15.1908L13.2584 15.5117C13.4597 15.5769 13.6166 15.7365 13.6788 15.9389L13.9848 16.9348C14.0269 17.0727 14.2215 17.0741 14.2659 16.937Z"
            fill="#FAFAFA"
          />
          <path
            d="M30.013 16.3597C29.6022 15.9004 28.9613 15.6418 28.3381 15.5358C27.71 15.4339 27.0513 15.4434 26.4312 15.5536C25.1765 15.7658 24.0366 16.2853 23.0423 16.9263C22.526 17.2408 22.0858 17.6048 21.6296 17.9755C21.4098 18.1629 21.2094 18.3626 21.0007 18.5594L20.4305 19.1267C19.8109 19.7744 19.2002 20.3643 18.6093 20.8532C18.016 21.3399 17.4614 21.7096 16.9147 21.9677C16.3685 22.2272 15.7839 22.3798 15.0221 22.4042C14.2669 22.4308 13.3734 22.2945 12.4177 22.0696C11.4568 21.8456 10.4478 21.5263 9.32031 21.2516C9.71374 22.3431 10.3062 23.3076 11.0668 24.1893C11.8364 25.0557 12.7973 25.8453 14.0317 26.3646C15.2484 26.8955 16.7773 27.086 18.2068 26.7985C19.6402 26.5226 20.898 25.8594 21.9148 25.0922C22.9341 24.3173 23.7588 23.4346 24.4541 22.5169C24.6459 22.2634 24.7475 22.1215 24.8863 21.9233L25.2703 21.3547C25.537 21.0029 25.7799 20.6025 26.0438 20.254C26.5615 19.5242 27.072 18.7952 27.6651 18.1235C27.9636 17.7829 28.2784 17.457 28.6499 17.1439C28.8352 16.9911 29.0355 16.8415 29.2573 16.7067C29.4824 16.5614 29.7202 16.4477 30.013 16.3597Z"
            fill="#EC796B"
          />
          <path
            d="M30.013 16.3599C29.5718 15.2465 28.7515 14.3093 27.6504 13.6177C26.5561 12.9337 25.0363 12.5847 23.5301 12.8822C22.7861 13.0261 22.0652 13.3032 21.4326 13.6721C20.8029 14.0396 20.2386 14.482 19.7501 14.9565C19.5062 15.1946 19.2848 15.443 19.0649 15.6927L18.4949 16.4194L17.6146 17.5892C16.4922 19.0943 15.2836 20.8582 13.3003 21.3809C11.3532 21.894 10.5087 21.4396 9.32031 21.2518C9.53761 21.8128 9.80676 22.3576 10.1716 22.8369C10.5297 23.3259 10.9527 23.7851 11.4786 24.1789C11.7443 24.368 12.0249 24.5546 12.3365 24.7129C12.6467 24.8658 12.9812 25.0004 13.3383 25.1016C14.0485 25.2962 14.8481 25.3645 15.6223 25.2597C16.3968 25.1564 17.1372 24.911 17.7843 24.585C18.4362 24.262 19.0041 23.8687 19.5112 23.4537C20.5192 22.6166 21.3032 21.6917 21.9655 20.7568C22.2987 20.2893 22.601 19.8131 22.8807 19.3367L23.2099 18.7695C23.3105 18.6037 23.4123 18.4369 23.5156 18.2816C23.9327 17.6574 24.3407 17.1569 24.8362 16.7813C25.3247 16.3959 26.0052 16.1112 26.9143 16.0451C27.8197 15.9781 28.865 16.1018 30.013 16.3599Z"
            fill="#FAFAFA"
          />
          <path
            d="M25.1147 25.6109C25.1147 26.4287 25.7781 27.0919 26.5958 27.0919C27.4136 27.0919 28.0759 26.4287 28.0759 25.6109C28.0759 24.7932 27.4136 24.1299 26.5958 24.1299C25.7781 24.1299 25.1147 24.7932 25.1147 25.6109Z"
            fill="#EC796B"
          />
        </g>
      </g>
      <defs>
        <clipPath id="clip0_904_172">
          <rect width="40" height="40" fill="white" />
        </clipPath>
        <clipPath id="clip1_904_172">
          <rect width="26" height="26" fill="white" transform="translate(7 7)" />
        </clipPath>
      </defs>
    </svg>
  )
}
