Commit a2b314a9 authored by Sai Srinivas's avatar Sai Srinivas Committed by Sai Srinivas
Browse files

First commit after setup

parent f02044da
This diff is collapsed.
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 32 32" id="circle">
<path d="M16 0C7.178 0 0 7.178 0 16s7.178 16 16 16 16-7.178 16-16S24.822 0 16 0zm0 30C8.28 30 2 23.72 2 16S8.28 2 16 2s14 6.28 14 14-6.28 14-14 14z"></path>
<path d="M17 8h-2v7H8v2h7v7h2v-7h7v-2h-7z"></path>
</svg>
<svg width="28" height="27" viewBox="0 0 28 27" fill="none" xmlns="http://www.w3.org/2000/svg">
<ellipse cx="13.69" cy="13.32" rx="10.712" ry="10.8756" fill="#2D2D2D"/>
<path d="M13.69 1.10986C11.2081 1.10986 8.7818 1.82597 6.7181 3.16762C4.6544 4.50927 3.04594 6.41621 2.09612 8.6473C1.14631 10.8784 0.897791 13.3334 1.382 15.7019C1.86622 18.0704 3.06141 20.246 4.81644 21.9536C6.57147 23.6612 8.80752 24.8241 11.2418 25.2952C13.6761 25.7664 16.1993 25.5246 18.4924 24.6004C20.7855 23.6763 22.7454 22.1113 24.1243 20.1034C25.5032 18.0955 26.2392 15.7348 26.2392 13.3199C26.2392 10.0816 24.9171 6.97591 22.5636 4.68609C20.2102 2.39627 17.0183 1.10986 13.69 1.10986ZM16.7817 18.0818C16.8886 18.185 16.9735 18.3077 17.0314 18.443C17.0893 18.5782 17.1192 18.7233 17.1192 18.8699C17.1192 19.0164 17.0893 19.1615 17.0314 19.2967C16.9735 19.432 16.8886 19.5548 16.7817 19.658C16.6756 19.762 16.5495 19.8446 16.4104 19.9009C16.2714 19.9573 16.1223 19.9863 15.9717 19.9863C15.8211 19.9863 15.672 19.9573 15.533 19.9009C15.3939 19.8446 15.2678 19.762 15.1617 19.658L9.45755 14.108C9.35062 14.0048 9.26575 13.882 9.20783 13.7467C9.14991 13.6115 9.12009 13.4664 9.12009 13.3199C9.12009 13.1733 9.14991 13.0282 9.20783 12.893C9.26575 12.7577 9.35062 12.635 9.45755 12.5318L15.1617 6.98176C15.2681 6.87827 15.3944 6.79617 15.5333 6.74016C15.6723 6.68415 15.8213 6.65532 15.9717 6.65532C16.1221 6.65532 16.2711 6.68415 16.4101 6.74016C16.549 6.79617 16.6753 6.87827 16.7817 6.98176C16.8881 7.08526 16.9724 7.20812 17.03 7.34335C17.0876 7.47857 17.1172 7.6235 17.1172 7.76986C17.1172 7.91623 17.0876 8.06116 17.03 8.19638C16.9724 8.3316 16.8881 8.45447 16.7817 8.55796L11.8761 13.3199L16.7817 18.0818Z" fill="white"/>
</svg>
<svg width="24" height="23" viewBox="0 0 24 23" fill="none" xmlns="http://www.w3.org/2000/svg">
<circle cx="12.001" cy="11.5" r="9.38963" fill="white" />
<path
d="M12 0.958008C9.82441 0.958008 7.69767 1.57627 5.88873 2.7346C4.07979 3.89293 2.66989 5.53932 1.83733 7.46555C1.00477 9.39179 0.786929 11.5114 1.21137 13.5563C1.6358 15.6011 2.68345 17.4795 4.22183 18.9538C5.76021 20.428 7.72022 21.432 9.85401 21.8388C11.9878 22.2455 14.1995 22.0368 16.2095 21.2389C18.2195 20.441 19.9375 19.0899 21.1462 17.3563C22.3549 15.6227 23 13.5846 23 11.4997C23 8.70385 21.8411 6.02254 19.7782 4.04559C17.7153 2.06864 14.9174 0.958008 12 0.958008ZM14.71 15.6109C14.8037 15.7 14.8781 15.806 14.9289 15.9228C14.9797 16.0396 15.0058 16.1648 15.0058 16.2913C15.0058 16.4179 14.9797 16.5431 14.9289 16.6599C14.8781 16.7767 14.8037 16.8827 14.71 16.9718C14.617 17.0616 14.5064 17.1329 14.3846 17.1815C14.2627 17.2302 14.132 17.2552 14 17.2552C13.868 17.2552 13.7373 17.2302 13.6154 17.1815C13.4936 17.1329 13.383 17.0616 13.29 16.9718L8.29 12.1801C8.19628 12.091 8.12188 11.985 8.07111 11.8682C8.02034 11.7514 7.99421 11.6262 7.99421 11.4997C7.99421 11.3732 8.02034 11.2479 8.07111 11.1311C8.12188 11.0143 8.19628 10.9083 8.29 10.8193L13.29 6.02759C13.3832 5.93824 13.4939 5.86736 13.6158 5.819C13.7376 5.77064 13.8681 5.74575 14 5.74575C14.1319 5.74575 14.2624 5.77064 14.3843 5.819C14.5061 5.86736 14.6168 5.93824 14.71 6.02759C14.8032 6.11694 14.8772 6.22302 14.9277 6.33977C14.9781 6.45651 15.0041 6.58164 15.0041 6.70801C15.0041 6.83437 14.9781 6.9595 14.9277 7.07625C14.8772 7.19299 14.8032 7.29907 14.71 7.38842L10.41 11.4997L14.71 15.6109Z"
fill="#1487C9" />
</svg>
<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" id="down-drop-arrow">
<path fill="none" d="M0 0h24v24H0V0z"></path>
<path d="M8.71 11.71l2.59 2.59c.39.39 1.02.39 1.41 0l2.59-2.59c.63-.63.18-1.71-.71-1.71H9.41c-.89 0-1.33 1.08-.7 1.71z"></path>
</svg>
<svg width="24" height="23" viewBox="0 0 24 23" fill="none" xmlns="http://www.w3.org/2000/svg">
<circle cx="12" cy="11.5" r="9.38963" fill="#2D2D2D"/>
<path d="M12 0.958313C9.82441 0.958313 7.69767 1.57657 5.88873 2.7349C4.07979 3.89324 2.66989 5.53962 1.83733 7.46586C1.00477 9.3921 0.786929 11.5117 1.21137 13.5566C1.6358 15.6014 2.68345 17.4798 4.22183 18.9541C5.76021 20.4283 7.72022 21.4323 9.85401 21.8391C11.9878 22.2458 14.1995 22.0371 16.2095 21.2392C18.2195 20.4413 19.9375 19.0902 21.1462 17.3566C22.3549 15.623 23 13.5849 23 11.5C23 8.70416 21.8411 6.02284 19.7782 4.0459C17.7153 2.06895 14.9174 0.958313 12 0.958313ZM14.71 15.6112C14.8037 15.7003 14.8781 15.8063 14.9289 15.9231C14.9797 16.0399 15.0058 16.1651 15.0058 16.2916C15.0058 16.4182 14.9797 16.5434 14.9289 16.6602C14.8781 16.777 14.8037 16.883 14.71 16.9721C14.617 17.0619 14.5064 17.1332 14.3846 17.1818C14.2627 17.2305 14.132 17.2555 14 17.2555C13.868 17.2555 13.7373 17.2305 13.6154 17.1818C13.4936 17.1332 13.383 17.0619 13.29 16.9721L8.29 12.1804C8.19628 12.0913 8.12188 11.9853 8.07111 11.8685C8.02034 11.7517 7.99421 11.6265 7.99421 11.5C7.99421 11.3735 8.02034 11.2482 8.07111 11.1314C8.12188 11.0146 8.19628 10.9087 8.29 10.8196L13.29 6.0279C13.3832 5.93854 13.4939 5.86766 13.6158 5.81931C13.7376 5.77095 13.8681 5.74606 14 5.74606C14.1319 5.74606 14.2624 5.77095 14.3843 5.81931C14.5061 5.86766 14.6168 5.93854 14.71 6.0279C14.8032 6.11725 14.8772 6.22333 14.9277 6.34007C14.9781 6.45682 15.0041 6.58195 15.0041 6.70831C15.0041 6.83468 14.9781 6.95981 14.9277 7.07655C14.8772 7.1933 14.8032 7.29938 14.71 7.38873L10.41 11.5L14.71 15.6112Z" fill="white"/>
</svg>
<svg xmlns="http://www.w3.org/2000/svg" xml:space="preserve" id="right" x="0" y="0" version="1.1" viewBox="0 0 29 29">
<path fill="none" stroke="#000" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" stroke-width="2" d="m11.5 8.5 6 6-6 6" style="fill:none;stroke:#000;stroke-width:2;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:10"></path>
</svg>
\ No newline at end of file
<svg width="22" height="22" viewBox="0 0 22 22" fill="none" xmlns="http://www.w3.org/2000/svg">
<circle cx="11" cy="10.5417" r="9.38963" fill="#2D2D2D"/>
<path d="M11 21.0833C13.1756 21.0833 15.3023 20.4651 17.1113 19.3068C18.9202 18.1484 20.3301 16.502 21.1627 14.5758C21.9952 12.6496 22.2131 10.53 21.7886 8.4851C21.3642 6.44022 20.3165 4.56187 18.7782 3.08759C17.2398 1.61331 15.2798 0.60932 13.146 0.202567C11.0122 -0.204185 8.80047 0.00457529 6.79048 0.802449C4.78049 1.60032 3.06253 2.95147 1.85383 4.68504C0.645134 6.41861 -4.61819e-06 8.45673 -4.80046e-06 10.5417C-5.04488e-06 13.3375 1.15892 16.0188 3.22182 17.9958C5.28472 19.9727 8.08261 21.0833 11 21.0833ZM8.29 6.43043C8.19627 6.34134 8.12187 6.23535 8.07111 6.11856C8.02034 6.00178 7.9942 5.87652 7.9942 5.75001C7.9942 5.6235 8.02034 5.49824 8.07111 5.38146C8.12187 5.26468 8.19627 5.15868 8.29 5.06959C8.38296 4.97977 8.49356 4.90848 8.61542 4.85982C8.73728 4.81117 8.86798 4.78612 9 4.78612C9.13201 4.78612 9.26271 4.81117 9.38457 4.85982C9.50643 4.90848 9.61703 4.97977 9.71 5.06959L14.71 9.86126C14.8037 9.95035 14.8781 10.0563 14.9289 10.1731C14.9797 10.2899 15.0058 10.4152 15.0058 10.5417C15.0058 10.6682 14.9797 10.7934 14.9289 10.9102C14.8781 11.027 14.8037 11.133 14.71 11.2221L9.71 16.0138C9.61676 16.1031 9.50607 16.174 9.38425 16.2223C9.26242 16.2707 9.13185 16.2956 9 16.2956C8.86814 16.2956 8.73757 16.2707 8.61575 16.2223C8.49392 16.174 8.38323 16.1031 8.29 16.0138C8.19676 15.9244 8.1228 15.8183 8.07234 15.7016C8.02188 15.5848 7.9959 15.4597 7.9959 15.3333C7.9959 15.207 8.02188 15.0818 8.07234 14.9651C8.1228 14.8484 8.19676 14.7423 8.29 14.6529L12.59 10.5417L8.29 6.43043Z" fill="white"/>
</svg>
<svg width="30" height="31" viewBox="0 0 30 31" fill="none" xmlns="http://www.w3.org/2000/svg">
<path d="M29.5796 9.98328L22.7874 16.7725C22.263 17.2969 21.428 17.3204 20.8755 16.8434C20.2456 16.2997 20.2386 15.344 20.8269 14.7557L25.205 10.3776C25.2085 10.3741 25.2062 10.3677 25.2009 10.3677H1.41064C0.634277 10.3677 0.00439454 9.73777 0.00439454 8.9614C0.00439454 8.18503 0.634277 7.55515 1.41064 7.55515H25.2009C25.2062 7.55515 25.2085 7.54871 25.205 7.54519L20.7935 3.13367C20.2444 2.58464 20.2444 1.69402 20.7935 1.14441C21.3425 0.5948 22.2331 0.595386 22.7821 1.14441L29.579 7.93894C30.1438 8.5032 30.1438 9.41902 29.579 9.98328H29.5796ZM28.597 21.1032H4.80674C4.80146 21.1032 4.79912 21.0968 4.80264 21.0932L9.21416 16.6817C9.76318 16.1327 9.76318 15.2421 9.21416 14.6925C8.66514 14.1434 7.77451 14.1434 7.22549 14.6925L0.428027 21.4876C-0.136816 22.0518 -0.136816 22.9677 0.428027 23.5319L7.22021 30.3212C7.74463 30.8456 8.57959 30.869 9.13213 30.3927C9.76201 29.8489 9.76904 28.8932 9.18076 28.305L4.80264 23.9268C4.79912 23.9233 4.80146 23.9169 4.80674 23.9169H28.597C29.3733 23.9169 30.0032 23.287 30.0032 22.5106C30.0032 21.7343 29.3733 21.1044 28.597 21.1044V21.1032Z" fill="url(#paint0_linear_1211_3161)"/>
<defs>
<linearGradient id="paint0_linear_1211_3161" x1="3.81768" y1="26.9216" x2="26.1899" y2="4.54929" gradientUnits="userSpaceOnUse">
<stop stop-color="#EF486C"/>
<stop offset="1" stop-color="#F98F80"/>
</linearGradient>
</defs>
</svg>
<?xml version="1.0" encoding="iso-8859-1"?>
<!-- Uploaded to: SVG Repo, www.svgrepo.com, Generator: SVG Repo Mixer Tools -->
<svg height="800px" width="800px" version="1.1" id="Layer_1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink"
viewBox="0 0 512 512" xml:space="preserve">
<path style="fill:#20A83E;" d="M437.019,74.98C388.668,26.628,324.38,0,256,0S123.333,26.628,74.98,74.98S0,187.62,0,256
c0,51.485,15.154,100.938,43.874,143.34L0.69,500.106c-1.343,3.134-0.607,6.966,1.798,9.381c2.495,2.506,6.519,3.206,9.714,1.684
l96.358-45.885C151.858,495.866,202.721,512,256,512c68.38,0,132.668-26.628,181.019-74.98C485.371,388.667,512,324.38,512,256
S485.371,123.333,437.019,74.98z"/>
<circle style="fill:#E5E5E5;" cx="256" cy="256" r="213.333"/>
<circle style="fill:#FFFFFF;" cx="256" cy="256" r="187.733"/>
<path style="fill:#20A83E;" d="M392.391,342.641l-7.673-41.561c-0.635-3.432-3.295-6.133-6.718-6.818l-60.339-12.067
c-2.802-0.559-5.691,0.317-7.709,2.334l-24.514,24.514c-41.302-18.507-64.226-41.478-84.396-84.555l24.435-24.436
c2.018-2.017,2.893-4.91,2.334-7.708l-12.068-60.34c-0.685-3.423-3.386-6.084-6.819-6.718l-41.561-7.673
c-1.138-0.21-2.31-0.187-3.44,0.07c-10.974,2.494-20.987,8.023-28.956,15.994c-13.801,13.801-19.075,33.938-15.252,58.237
c6.418,40.801,26.409,97.583,63.289,134.61l0.502,0.5c37.001,36.855,93.782,56.846,134.583,63.265
c5.14,0.809,10.092,1.21,14.838,1.21c17.694,0,32.517-5.581,43.4-16.462c7.97-7.971,13.5-17.984,15.993-28.957
C392.578,344.951,392.602,343.78,392.391,342.641z"/>
<path style="fill:#189433;" d="M349.996,376.428c-4.747,0-9.698-0.401-14.838-1.21c-40.801-6.419-97.583-26.41-134.583-63.265
l-0.502-0.5c-36.88-37.027-56.87-93.809-63.289-134.61c-3.323-21.118,0.236-39.088,10.283-52.492
c-4.388,2.565-8.458,5.689-12.097,9.328c-13.801,13.801-19.075,33.938-15.252,58.237c6.418,40.801,26.409,97.583,63.289,134.61
l0.502,0.5c37.001,36.855,93.782,56.846,134.583,63.265c5.14,0.809,10.092,1.21,14.838,1.21c17.694,0,32.517-5.581,43.4-16.462
c1.974-1.974,3.797-4.075,5.463-6.284C372.747,373.836,362.037,376.428,349.996,376.428z"/>
</svg>
\ No newline at end of file
<svg width="30" height="31" viewBox="0 0 30 31" fill="none" xmlns="http://www.w3.org/2000/svg">
<g clip-path="url(#clip0_1211_3170)">
<path d="M6.74414 3.30371C13.3429 -1.3523 22.4248 0.159517 27.1689 6.64844C31.948 13.1854 30.5208 22.3738 24.0615 27.1865C19.4235 30.6421 13.1689 31.0224 8.09277 28.2744L0 30.8486L2.62598 22.9795C-1.35515 16.3641 0.461349 7.73692 6.74414 3.30371Z" fill="url(#paint0_linear_1211_3170)"/>
<rect x="6.95703" y="11.3125" width="17.251" height="3.25" rx="1.625" fill="white"/>
<rect x="6.95703" y="17.0625" width="14.2495" height="3.25" rx="1.625" fill="white"/>
</g>
<defs>
<linearGradient id="paint0_linear_1211_3170" x1="-1.32787" y1="4.05652" x2="15" y2="30.8484" gradientUnits="userSpaceOnUse">
<stop offset="0.136334" stop-color="#0D9C00"/>
<stop offset="1" stop-color="#13E200"/>
</linearGradient>
<clipPath id="clip0_1211_3170">
<rect width="30" height="30.2494" fill="white" transform="translate(0 0.599609)"/>
</clipPath>
</defs>
</svg>
<svg width="30" height="31" viewBox="0 0 30 31" fill="none" xmlns="http://www.w3.org/2000/svg">
<g clip-path="url(#clip0_1213_3198)">
<path d="M19.8368 1.81279C18.9482 1.152 17.8782 0.779856 16.7713 0.746618C13.547 0.667843 10.321 0.800592 7.1141 1.14401C4.97207 1.39249 2.91815 3.4464 2.66967 5.58844C2.10751 10.8444 2.10751 20.6038 2.66967 25.8589C2.91815 28.0018 4.97207 30.0557 7.1141 30.3042C12.3565 30.8658 17.6439 30.8658 22.8864 30.3042C25.0284 30.0557 27.0823 28.0018 27.3308 25.8589C27.7141 22.2797 27.8357 16.607 27.6973 11.6991V11.6788C27.6887 10.6199 27.345 9.59099 26.7158 8.73936C24.7784 6.10259 22.4601 3.76825 19.8368 1.81279Z" fill="url(#paint0_linear_1213_3198)"/>
<path d="M19.8368 1.81279C18.9482 1.152 17.8782 0.779856 16.7713 0.746618C13.547 0.667843 10.321 0.800592 7.1141 1.14401C4.97207 1.39249 2.91815 3.4464 2.66967 5.58844C2.10751 10.8444 2.10751 20.6038 2.66967 25.8589C2.91815 28.0018 4.97207 30.0557 7.1141 30.3042C12.3565 30.8658 17.6439 30.8658 22.8864 30.3042C25.0284 30.0557 27.0823 28.0018 27.3308 25.8589C27.7141 22.2797 27.8357 16.607 27.6973 11.6991V11.6788C27.6887 10.6199 27.345 9.59099 26.7158 8.73936C24.7784 6.10259 22.4601 3.76825 19.8368 1.81279Z" fill="url(#paint1_linear_1213_3198)"/>
<path d="M27.6916 11.6994C27.2827 11.7091 26.8748 11.7162 26.4686 11.7162C24.7432 11.7158 23.019 11.6237 21.3034 11.4404H21.2884C20.2663 11.3223 19.2618 10.8148 18.4591 10.0121C17.6564 9.20936 17.1488 8.20311 17.0308 7.17836C17.0303 7.17337 17.0303 7.16836 17.0308 7.16338C16.803 5.03233 16.7158 2.88859 16.7699 0.746094C17.8771 0.779153 18.9474 1.15131 19.8363 1.81226C22.4646 3.77242 24.7863 6.11313 26.725 8.75734C27.3499 9.60444 27.6893 10.6283 27.6942 11.6809L27.6916 11.6994Z" fill="url(#paint2_linear_1213_3198)"/>
<path d="M27.6916 11.6994C27.2827 11.7091 26.8748 11.7162 26.4686 11.7162C24.7432 11.7158 23.019 11.6237 21.3034 11.4404H21.2884C20.2663 11.3223 19.2618 10.8148 18.4591 10.0121C17.6564 9.20936 17.1488 8.20311 17.0308 7.17836C17.0303 7.17337 17.0303 7.16836 17.0308 7.16338C16.803 5.03233 16.7158 2.88859 16.7699 0.746094C17.8771 0.779153 18.9474 1.15131 19.8363 1.81226C22.4646 3.77242 24.7863 6.11313 26.725 8.75734C27.3499 9.60444 27.6893 10.6283 27.6942 11.6809L27.6916 11.6994Z" fill="#0A6502"/>
<g clip-path="url(#clip1_1213_3198)">
<path d="M7.94727 24.7505L9.18125 21.0827C7.31018 17.9993 8.16406 13.9785 11.1166 11.9124C14.2178 9.74238 18.4855 10.4474 20.7149 13.4718C22.9607 16.5185 22.2902 20.8006 19.2548 23.0436C17.0752 24.6542 14.1358 24.8314 11.7503 23.5504L7.94727 24.7505ZM9.71888 23.008L11.9408 22.3112C14.4498 23.9533 17.804 23.3973 19.6541 21.0675C21.6348 18.5733 21.1869 14.9677 18.6788 13.0166C16.1483 11.0486 12.5056 11.5174 10.546 14.0258C8.98573 16.0231 8.94435 18.8481 10.4417 20.8922L9.71888 23.0079V23.008Z" fill="white"/>
<path d="M12.7267 14.1696C12.8488 14.1563 12.9707 14.1835 13.0919 14.1947C13.1541 14.2004 13.2178 14.1879 13.2801 14.1983C13.4262 14.2227 13.4876 14.3944 13.5386 14.513C13.7105 14.912 13.9041 15.4324 14.0408 15.8453C14.0588 15.8995 14.0788 15.9587 14.0727 16.0162C14.0644 16.0933 13.9462 16.2876 13.8961 16.3541C13.7851 16.5019 13.5683 16.6657 13.4767 16.802C13.3667 16.9655 13.5487 17.2086 13.6393 17.3563C14.0641 18.0483 14.6761 18.6506 15.3924 19.0437C15.4938 19.0994 15.8375 19.284 15.9299 19.3014C16.0106 19.3166 16.0815 19.3092 16.1479 19.2608C16.3709 19.0983 16.6061 18.7269 16.8045 18.5211C16.9443 18.376 17.0372 18.4175 17.2088 18.4869C17.5878 18.6405 18.1883 18.969 18.5421 19.1852C18.7339 19.3023 18.7258 19.3458 18.7074 19.5739C18.6624 20.1343 18.41 20.4685 17.922 20.7276C17.4277 20.99 16.9389 21.0201 16.4063 20.8642C14.604 20.3363 13.4338 19.358 12.4198 17.819C11.8793 16.9989 11.4033 16.0971 11.8035 15.0988C11.9383 14.7626 12.3377 14.212 12.7269 14.1696H12.7267Z" fill="white"/>
</g>
</g>
<defs>
<linearGradient id="paint0_linear_1213_3198" x1="25.7782" y1="28.8283" x2="1.89339" y2="4.94433" gradientUnits="userSpaceOnUse">
<stop stop-color="#EF3739"/>
<stop offset="0.54" stop-color="#EF3739"/>
<stop offset="1" stop-color="#FF8C8B"/>
</linearGradient>
<linearGradient id="paint1_linear_1213_3198" x1="15.0003" y1="0.724609" x2="15.0003" y2="30.7254" gradientUnits="userSpaceOnUse">
<stop stop-color="#0D9C00"/>
<stop offset="1" stop-color="#13E200"/>
</linearGradient>
<linearGradient id="paint2_linear_1213_3198" x1="26.4351" y1="12.9551" x2="15.4985" y2="2.01845" gradientUnits="userSpaceOnUse">
<stop stop-color="#34344F"/>
<stop offset="0.26" stop-color="#3B3B57"/>
<stop offset="0.66" stop-color="#50506D"/>
<stop offset="1" stop-color="#666684"/>
</linearGradient>
<clipPath id="clip0_1213_3198">
<rect width="30" height="30" fill="white" transform="translate(0 0.724609)"/>
</clipPath>
<clipPath id="clip1_1213_3198">
<rect width="14.0981" height="14.0981" fill="white" transform="translate(7.94727 10.6523)"/>
</clipPath>
</defs>
</svg>
import 'package:flutter/material.dart';
import 'package:flutter_svg/flutter_svg.dart';
import 'package:provider/provider.dart';
import '../../Notifier/RentalContactProvider .dart';
import '../../Utility/AdvancedSnackbar.dart';
import '../../Utility/CustomSnackbar.dart';
class OtpScreen extends StatefulWidget {
final String mob; // ✅ phone number
final int otp; // ✅ backend OTP
const OtpScreen({
super.key,
required this.mob,
required this.otp,
});
@override
State<OtpScreen> createState() => _OtpScreenState();
}
class _OtpScreenState extends State<OtpScreen> {
final List<TextEditingController> _controllers =
List.generate(4, (_) => TextEditingController());
final List<FocusNode> _focusNodes = List.generate(4, (_) => FocusNode());
bool _isValid = false;
bool _isVerifying = false;
bool _isResending = false;
int _secondsRemaining = 22;
int _currentOtp = 0; // ✅ Store current OTP in state
@override
void initState() {
super.initState();
_currentOtp = widget.otp; // ✅ Initialize with passed OTP
_startTimer();
}
@override
void dispose() {
for (var controller in _controllers) {
controller.dispose();
}
for (var focusNode in _focusNodes) {
focusNode.dispose();
}
super.dispose();
}
void _startTimer() {
Future.doWhile(() async {
if (_secondsRemaining > 0) {
await Future.delayed(const Duration(seconds: 1));
if (mounted) {
setState(() => _secondsRemaining--);
}
return true;
}
return false;
});
}
void _onOtpChange() {
final otp = _controllers.map((c) => c.text).join();
setState(() {
_isValid = otp.length == 4 && RegExp(r'^[0-9]{4}$').hasMatch(otp);
});
}
Future<void> _verifyOtp() async {
final enteredOtp = _controllers.map((c) => c.text).join();
setState(() => _isVerifying = true);
await Future.delayed(const Duration(milliseconds: 800));
// ✅ Compare with current OTP (not widget.otp)
if (enteredOtp == _currentOtp.toString()) {
// ✅ OTP verified successfully
if (!mounted) return;
ScaffoldMessenger.of(context).showSnackBar(
const SnackBar(
content: Text("✅ OTP Verified Successfully!"),
backgroundColor: Colors.green,
),
);
// Example navigation:
// Navigator.pushReplacement(context, MaterialPageRoute(builder: (_) => const HomeScreen()));
} else {
// ❌ Invalid OTP
ScaffoldMessenger.of(context).showSnackBar(
const SnackBar(
content: Text("❌ Invalid OTP. Please try again."),
backgroundColor: Colors.redAccent,
),
);
}
if (mounted) setState(() => _isVerifying = false);
}
/// 🔁 Resend OTP Function
Future<void> _resendOtp(BuildContext context) async {
setState(() => _isResending = true);
try {
final rentalProvider =
Provider.of<RentalContactProvider>(context, listen: false);
await rentalProvider.fetchRentalContactData(
context,
"4d21382d9e1c4d6e0b7c426d53d89b6b7d48078877f185289092e6fa13bac4b11d417d37738b20b34151b8e638625b3ec013",
"5",
widget.mob,
);
if (rentalProvider.rentalContact != null &&
rentalProvider.rentalContact!.error == 0) {
// ✅ Update current OTP with the new one from API response
final newOtp = rentalProvider.rentalContact!.otp!;
setState(() {
_currentOtp = newOtp; // ✅ Update current OTP
_secondsRemaining = 22;
});
// ✅ Clear previous OTP fields
for (var controller in _controllers) {
controller.clear();
}
setState(() {
_isValid = false;
});
// ✅ Restart timer
_startTimer();
AnimatedSnackBar.success(
context: context,
title: "OTP Sent",
message: "${rentalProvider.rentalContact?.message} (OTP: $newOtp)",
);
} else {
CustomSnackBar.showWarning(
context: context,
title: "Error",
message: rentalProvider.rentalContact?.message ??
rentalProvider.errorMessage ??
"Failed to resend OTP",
);
}
} catch (e) {
CustomSnackBar.showError(
context: context,
title: "Network Error",
message: e.toString(),
);
} finally {
if (mounted) setState(() => _isResending = false);
}
}
Widget _buildOtpField(int index) {
return SizedBox(
width: 60,
height: 60,
child: TextField(
controller: _controllers[index],
focusNode: _focusNodes[index],
keyboardType: TextInputType.number,
textAlign: TextAlign.center,
maxLength: 1,
style: const TextStyle(
fontSize: 24,
color: Colors.black,
fontWeight: FontWeight.w600,
),
decoration: InputDecoration(
counterText: "",
filled: true,
fillColor: Colors.white,
enabledBorder: OutlineInputBorder(
borderRadius: BorderRadius.circular(50),
borderSide: BorderSide(color: Colors.grey.withOpacity(0.5), width: 1),
),
focusedBorder: OutlineInputBorder(
borderRadius: BorderRadius.circular(50),
borderSide: const BorderSide(color: Color(0xFF008CDE), width: 2),
),
),
onChanged: (value) {
_onOtpChange();
if (value.isNotEmpty && index < 3) {
FocusScope.of(context).requestFocus(_focusNodes[index + 1]);
} else if (value.isEmpty && index > 0) {
FocusScope.of(context).requestFocus(_focusNodes[index - 1]);
}
},
),
);
}
@override
Widget build(BuildContext context) {
return Scaffold(
resizeToAvoidBottomInset: true,
body: GestureDetector(
onTap: () => FocusScope.of(context).unfocus(),
child: Stack(
children: [
// 🏙️ Background image
Positioned.fill(
child: Image.asset(
'assets/images/background.jpg',
fit: BoxFit.cover,
),
),
// 🌑 Overlay
Positioned.fill(
child: Container(color: Colors.black.withOpacity(0.5)),
),
// 🌈 Gradient overlay
Positioned.fill(
child: Container(
decoration: const BoxDecoration(
gradient: LinearGradient(
begin: Alignment.topCenter,
end: Alignment.bottomCenter,
colors: [Colors.transparent, Colors.black54, Colors.black87],
),
),
),
),
// 📦 Foreground content
SingleChildScrollView(
padding: EdgeInsets.only(
bottom: MediaQuery.of(context).viewInsets.bottom + 20,
),
child: ConstrainedBox(
constraints:
BoxConstraints(minHeight: MediaQuery.of(context).size.height),
child: Column(
mainAxisAlignment: MainAxisAlignment.end,
children: [
const SizedBox(height: 40),
const Padding(
padding: EdgeInsets.symmetric(horizontal: 24),
child: Text(
"Rental Power,\nManaged in a Tap",
textAlign: TextAlign.center,
style: TextStyle(
color: Colors.white,
fontSize: 32,
fontWeight: FontWeight.w500,
height: 1.3,
),
),
),
const SizedBox(height: 40),
Padding(
padding: const EdgeInsets.symmetric(horizontal: 24),
child: Text(
"Enter the OTP sent to +91 ${widget.mob}",
textAlign: TextAlign.center,
style: const TextStyle(
color: Colors.white70,
fontSize: 14,
),
),
),
const SizedBox(height: 30),
Padding(
padding: const EdgeInsets.symmetric(horizontal: 24),
child: Row(
mainAxisAlignment: MainAxisAlignment.spaceEvenly,
children: List.generate(4, _buildOtpField),
),
),
const SizedBox(height: 20),
// 🔁 Resend OTP
TextButton(
onPressed: _secondsRemaining == 0 && !_isResending
? () => _resendOtp(context)
: null,
child: _isResending
? const SizedBox(
width: 20,
height: 20,
child: CircularProgressIndicator(
strokeWidth: 2,
color: Colors.white,
),
)
: Text(
_secondsRemaining == 0
? "Resend OTP"
: "Resend OTP in $_secondsRemaining s",
style: TextStyle(
color: _secondsRemaining == 0
? const Color(0xFF008CDE)
: Colors.white70,
fontSize: 14,
decoration: _secondsRemaining == 0
? TextDecoration.underline
: TextDecoration.none,
),
),
),
const SizedBox(height: 30),
// 🔘 Continue Button
Padding(
padding: const EdgeInsets.symmetric(horizontal: 24),
child: SizedBox(
width: double.infinity,
child: ElevatedButton(
onPressed: _isValid && !_isVerifying ? _verifyOtp : null,
style: ElevatedButton.styleFrom(
backgroundColor: _isValid
? const Color(0xFF008CDE)
: const Color(0xFF266E99),
foregroundColor: Colors.white,
disabledBackgroundColor:
const Color(0xFF266E99),
shape: RoundedRectangleBorder(
borderRadius: BorderRadius.circular(30),
),
padding: const EdgeInsets.symmetric(vertical: 16),
),
child: _isVerifying
? const SizedBox(
width: 22,
height: 22,
child: CircularProgressIndicator(
strokeWidth: 2,
color: Colors.white,
),
)
: Padding(
padding:
const EdgeInsets.symmetric(horizontal: 22),
child: Row(
mainAxisAlignment:
MainAxisAlignment.spaceBetween,
children: [
Text(
"Continue",
style: TextStyle(
color: _isValid
? Colors.white
: const Color(0xFF03456C),
fontSize: 16,
),
),
SvgPicture.asset(
"assets/svg/continue_ic.svg",
color: _isValid
? Colors.white
: const Color(0xFF03456C),
height: 25,
width: 25,
),
],
),
),
),
),
),
const SizedBox(height: 40),
],
),
),
),
],
),
),
);
}
}
\ No newline at end of file
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment