import React from 'react';
import type { Color } from '../types';

export const getMoralisLogo = (color: Color) => {
    switch (color) {
        case 'blue':
            return moralisLogoIconBlue();
        case 'black':
            return moralisLogoIconBlack();
        default:
        case 'white':
            return moralisLogoIconWhite();
    }
};

const moralisLogoIconBlue = () => {
    return (
        <svg
            width="29"
            height="24"
            viewBox="0 0 29 24"
            fill="none"
            xmlns="http://www.w3.org/2000/svg"
        >
            <path
                fillRule="evenodd"
                clipRule="evenodd"
                d="M0.000794955 9.9629C0.111307 5.13346 3.82658 1.25555 8.3883 1.25555C12.957 1.25555 16.6653 5.13519 16.7758 9.9629C16.8119 11.5393 15.6401 12.8484 14.1585 12.8867C12.677 12.9251 11.4467 11.6783 11.4106 10.1019C11.3708 8.36267 10.0343 6.96593 8.3883 6.96593C6.75598 6.96593 5.42205 8.34747 5.36687 10.0703C5.37579 12.3802 6.19923 14.6527 7.13472 16.4591C7.59419 17.3464 8.05422 18.0703 8.39522 18.5666C8.56495 18.8136 8.70305 19.0011 8.79389 19.121C8.83925 19.1808 8.87263 19.2235 8.89205 19.2481C8.90176 19.2604 8.90795 19.2681 8.9104 19.2711L8.90943 19.27L8.90819 19.2684C8.90912 19.2696 8.91006 19.2707 8.91099 19.2719C9.881 20.4593 9.76544 22.2588 8.65135 23.2947C7.53541 24.3323 5.84022 24.211 4.86502 23.0236L6.8856 21.1448C4.86502 23.0236 4.8645 23.0229 4.86397 23.0223L4.86023 23.0177L4.8539 23.01C4.84917 23.0042 4.84342 22.9971 4.83669 22.9887C4.82323 22.972 4.80583 22.9503 4.78476 22.9236C4.74262 22.8703 4.68572 22.7972 4.61618 22.7055C4.47721 22.5221 4.28701 22.2631 4.06279 21.9367C3.61588 21.2863 3.02536 20.3564 2.43428 19.215C1.27377 16.974 0 13.7054 0 10.0324V9.99764L0.000794955 9.9629ZM8.90761 19.2677L8.90799 19.2682L8.90819 19.2684C8.908 19.2682 8.9078 19.268 8.90761 19.2677Z"
                fill="#2E7DAF"
            />
            <path
                fillRule="evenodd"
                clipRule="evenodd"
                d="M16.9012 9.9649V10.3426C16.9012 11.9002 15.6998 13.1629 14.2178 13.1629C12.7358 13.1629 11.5344 11.9002 11.5344 10.3426V9.89088L11.5352 9.85656C11.6457 5.0861 15.361 1.25555 19.9227 1.25555C24.4845 1.25555 28.1997 5.0861 28.3102 9.85656L28.311 9.89088V9.92521C28.311 12.9187 27.4215 15.6034 26.6026 17.4609C26.1861 18.4057 25.769 19.1786 25.4515 19.7225C25.2922 19.9953 25.1566 20.213 25.0565 20.3686C25.0064 20.4464 24.9652 20.5089 24.9341 20.5551C24.9186 20.5782 24.9057 20.5973 24.8955 20.6122C24.8904 20.6197 24.8859 20.6261 24.8822 20.6315L24.8772 20.6388L24.8741 20.6433C24.8737 20.6439 24.8732 20.6445 22.7975 19.0473L24.8732 20.6445C23.9977 21.9013 22.3186 22.1742 21.1229 21.254C19.9294 20.3356 19.6685 18.5759 20.5379 17.3196C20.5392 17.3177 20.5425 17.3129 20.5476 17.3052C20.5594 17.2877 20.5808 17.2554 20.6106 17.2091C20.6702 17.1165 20.7626 16.9688 20.8771 16.7727C21.107 16.3789 21.4198 15.8001 21.7332 15.0894C22.3697 13.6456 22.9366 11.8184 22.9442 9.96254C22.8889 8.26081 21.555 6.89619 19.9227 6.89619C18.2897 6.89619 16.9553 8.26208 16.9012 9.9649Z"
                fill="#2E7DAF"
            />
            <path
                d="M22.7185 22.1659C24.2627 22.1659 25.5146 20.8519 25.5146 19.2311C25.5146 17.6103 24.2627 16.2963 22.7185 16.2963C21.1742 16.2963 19.9224 17.6103 19.9224 19.2311C19.9224 20.8519 21.1742 22.1659 22.7185 22.1659Z"
                fill="#51A5DA"
            />
        </svg>
    );
};

const moralisLogoIconWhite = () => {
    return (
        <svg
            width="29"
            height="23"
            viewBox="0 0 29 23"
            fill="none"
            xmlns="http://www.w3.org/2000/svg"
        >
            <path
                fillRule="evenodd"
                clipRule="evenodd"
                d="M0.000794955 8.9629C0.111307 4.13346 3.82658 0.255554 8.3883 0.255554C12.957 0.255554 16.6653 4.13519 16.7758 8.9629C16.8119 10.5393 15.6401 11.8484 14.1585 11.8867C12.677 11.9251 11.4467 10.6783 11.4106 9.10189C11.3708 7.36267 10.0343 5.96593 8.3883 5.96593C6.75598 5.96593 5.42205 7.34747 5.36687 9.07027C5.37579 11.3802 6.19923 13.6527 7.13472 15.4591C7.59419 16.3464 8.05422 17.0703 8.39522 17.5666C8.56495 17.8136 8.70305 18.0011 8.79389 18.121C8.83925 18.1808 8.87263 18.2235 8.89205 18.2481C8.90176 18.2604 8.90795 18.2681 8.9104 18.2711L8.90943 18.27L8.90819 18.2684C8.90912 18.2696 8.91006 18.2707 8.91099 18.2719C9.881 19.4593 9.76544 21.2588 8.65135 22.2947C7.53541 23.3323 5.84022 23.211 4.86502 22.0236L6.8856 20.1448C4.86502 22.0236 4.8645 22.0229 4.86397 22.0223L4.86023 22.0177L4.8539 22.01C4.84917 22.0042 4.84342 21.9971 4.83669 21.9887C4.82323 21.972 4.80583 21.9503 4.78476 21.9236C4.74262 21.8703 4.68572 21.7972 4.61618 21.7055C4.47721 21.5221 4.28701 21.2631 4.06279 20.9367C3.61588 20.2863 3.02536 19.3564 2.43428 18.215C1.27377 15.974 0 12.7054 0 9.0324V8.99764L0.000794955 8.9629ZM8.90761 18.2677L8.90799 18.2682L8.90819 18.2684C8.908 18.2682 8.9078 18.268 8.90761 18.2677Z"
                fill="white"
            />
            <path
                fillRule="evenodd"
                clipRule="evenodd"
                d="M16.9012 8.9649V9.34261C16.9012 10.9002 15.6998 12.1629 14.2178 12.1629C12.7358 12.1629 11.5344 10.9002 11.5344 9.34261V8.89088L11.5352 8.85656C11.6457 4.0861 15.361 0.255554 19.9227 0.255554C24.4845 0.255554 28.1997 4.0861 28.3102 8.85656L28.311 8.89088V8.92521C28.311 11.9187 27.4215 14.6034 26.6026 16.4609C26.1861 17.4057 25.769 18.1786 25.4515 18.7225C25.2922 18.9953 25.1566 19.213 25.0565 19.3686C25.0064 19.4464 24.9652 19.5089 24.9341 19.5551C24.9186 19.5782 24.9057 19.5973 24.8955 19.6122C24.8904 19.6197 24.8859 19.6261 24.8822 19.6315L24.8772 19.6388L24.8741 19.6433C24.8737 19.6439 24.8732 19.6445 22.7975 18.0473L24.8732 19.6445C23.9977 20.9013 22.3186 21.1742 21.1229 20.254C19.9294 19.3356 19.6685 17.5759 20.5379 16.3196C20.5392 16.3177 20.5425 16.3129 20.5476 16.3052C20.5594 16.2877 20.5808 16.2554 20.6106 16.2091C20.6702 16.1165 20.7626 15.9688 20.8771 15.7727C21.107 15.3789 21.4198 14.8001 21.7332 14.0894C22.3697 12.6456 22.9366 10.8184 22.9442 8.96254C22.8889 7.26081 21.555 5.89619 19.9227 5.89619C18.2897 5.89619 16.9553 7.26208 16.9012 8.9649Z"
                fill="white"
            />
            <path
                d="M22.7185 21.1659C24.2627 21.1659 25.5146 19.8519 25.5146 18.2311C25.5146 16.6103 24.2627 15.2963 22.7185 15.2963C21.1742 15.2963 19.9224 16.6103 19.9224 18.2311C19.9224 19.8519 21.1742 21.1659 22.7185 21.1659Z"
                fill="#B7E803"
            />
        </svg>
    );
};

const moralisLogoIconBlack = () => {
    return (
        <svg
            width="29"
            height="23"
            viewBox="0 0 29 23"
            fill="none"
            xmlns="http://www.w3.org/2000/svg"
        >
            <path
                fillRule="evenodd"
                clipRule="evenodd"
                d="M0.000794955 8.9629C0.111307 4.13346 3.82658 0.255554 8.3883 0.255554C12.957 0.255554 16.6653 4.13519 16.7758 8.9629C16.8119 10.5393 15.6401 11.8484 14.1585 11.8867C12.677 11.9251 11.4467 10.6783 11.4106 9.10189C11.3708 7.36267 10.0343 5.96593 8.3883 5.96593C6.75598 5.96593 5.42205 7.34747 5.36687 9.07027C5.37579 11.3802 6.19923 13.6527 7.13472 15.4591C7.59419 16.3464 8.05422 17.0703 8.39522 17.5666C8.56495 17.8136 8.70305 18.0011 8.79389 18.121C8.83925 18.1808 8.87263 18.2235 8.89205 18.2481C8.90176 18.2604 8.90795 18.2681 8.9104 18.2711L8.90943 18.27L8.90819 18.2684C8.90912 18.2696 8.91006 18.2707 8.91099 18.2719C9.881 19.4593 9.76544 21.2588 8.65135 22.2947C7.53541 23.3323 5.84022 23.211 4.86502 22.0236L6.8856 20.1448C4.86502 22.0236 4.8645 22.0229 4.86397 22.0223L4.86023 22.0177L4.8539 22.01C4.84917 22.0042 4.84342 21.9971 4.83669 21.9887C4.82323 21.972 4.80583 21.9503 4.78476 21.9236C4.74262 21.8703 4.68572 21.7972 4.61618 21.7055C4.47721 21.5221 4.28701 21.2631 4.06279 20.9367C3.61588 20.2863 3.02536 19.3564 2.43428 18.215C1.27377 15.974 0 12.7054 0 9.0324V8.99764L0.000794955 8.9629ZM8.90761 18.2677L8.90799 18.2682L8.90819 18.2684C8.908 18.2682 8.9078 18.268 8.90761 18.2677Z"
                fill="#041836"
            />
            <path
                fillRule="evenodd"
                clipRule="evenodd"
                d="M16.9012 8.9649V9.34261C16.9012 10.9002 15.6998 12.1629 14.2178 12.1629C12.7358 12.1629 11.5344 10.9002 11.5344 9.34261V8.89088L11.5352 8.85656C11.6457 4.0861 15.361 0.255554 19.9227 0.255554C24.4845 0.255554 28.1997 4.0861 28.3102 8.85656L28.311 8.89088V8.92521C28.311 11.9187 27.4215 14.6034 26.6026 16.4609C26.1861 17.4057 25.769 18.1786 25.4515 18.7225C25.2922 18.9953 25.1566 19.213 25.0565 19.3686C25.0064 19.4464 24.9652 19.5089 24.9341 19.5551C24.9186 19.5782 24.9057 19.5973 24.8955 19.6122C24.8904 19.6197 24.8859 19.6261 24.8822 19.6315L24.8772 19.6388L24.8741 19.6433C24.8737 19.6439 24.8732 19.6445 22.7975 18.0473L24.8732 19.6445C23.9977 20.9013 22.3186 21.1742 21.1229 20.254C19.9294 19.3356 19.6685 17.5759 20.5379 16.3196C20.5392 16.3177 20.5425 16.3129 20.5476 16.3052C20.5594 16.2877 20.5808 16.2554 20.6106 16.2091C20.6702 16.1165 20.7626 15.9688 20.8771 15.7727C21.107 15.3789 21.4198 14.8001 21.7332 14.0894C22.3697 12.6456 22.9366 10.8184 22.9442 8.96254C22.8889 7.26081 21.555 5.89619 19.9227 5.89619C18.2897 5.89619 16.9553 7.26208 16.9012 8.9649Z"
                fill="#041836"
            />
            <path
                d="M22.7185 21.1659C24.2627 21.1659 25.5146 19.8519 25.5146 18.2311C25.5146 16.6103 24.2627 15.2963 22.7185 15.2963C21.1742 15.2963 19.9224 16.6103 19.9224 18.2311C19.9224 19.8519 21.1742 21.1659 22.7185 21.1659Z"
                fill="#B7E803"
            />
        </svg>
    );
};
