Skip to content

Commit

Permalink
Add token component
Browse files Browse the repository at this point in the history
  • Loading branch information
Pivi authored and Pivi committed Aug 1, 2023
1 parent 525e4fe commit 948455e
Show file tree
Hide file tree
Showing 9 changed files with 493 additions and 1 deletion.
183 changes: 183 additions & 0 deletions src/components/Icons/Svg/Massa/Mrc20.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,183 @@
export function Mrc20({ ...props }) {
const { size } = props;
return (
<svg
width={size || 16}
height={size || 16}
viewBox="0 0 40 40"
fill="none"
xmlns="http://www.w3.org/2000/svg"
>
<circle cx="20" cy="20" r="20" fill="#FF0000" />
<path
d="M10.6543 17.3519V22.8862H9.92651V18.7595L8.08707
22.8862H7.57522L5.72778 18.7515V22.8862H5V17.3519H5.78376L7.83115
21.9265L9.87853 17.3519H10.6543Z"
fill="white"
/>
<path
d="M14.8237 22.8862L13.4961
20.6069H12.6163V22.8862H11.8885V17.3119H13.688C14.1092
17.3119 14.4638 17.3839 14.7517 17.5278C15.0449 17.6718
15.2635 17.8664 15.4075 18.1117C15.5514
18.3569 15.6234 18.6368 15.6234 18.9514C15.6234
19.3353 15.5115 19.6739 15.2875 19.9671C15.0689
20.2603 14.7384 20.455 14.2958 20.5509L15.6954
22.8862H14.8237ZM12.6163 20.0231H13.688C14.0825
20.0231 14.3785 19.9271 14.5757 19.7352C14.773
19.5379 14.8716 19.2766 14.8716 18.9514C14.8716
18.6208 14.773 18.3649 14.5757 18.1836C14.3838
18.0024 14.0879 17.9117 13.688 17.9117H12.6163V20.0231Z"
fill="white"
/>
<path
d="M16.4823 20.0951C16.4823 19.5512 16.605
19.0634 16.8502 18.6315C17.0955 18.1943 17.4287
17.8531 17.8499 17.6078C18.2765 17.3626 18.7483
17.2399 19.2655 17.2399C19.8733 17.2399 20.4038
17.3866 20.857 17.6798C21.3102 17.973 21.6408
18.3889 21.8487 18.9274H20.977C20.8224 18.5915
20.5984 18.3329 20.3052 18.1517C20.0173 17.9704
19.6707 17.8797 19.2655 17.8797C18.8763 17.8797
18.5271 17.9704 18.2178 18.1517C17.9086 18.3329
17.666 18.5915 17.49 18.9274C17.3141 19.258 17.2261
19.6472 17.2261 20.0951C17.2261 20.5376 17.3141
20.9268 17.49 21.2627C17.666 21.5933 17.9086
21.8492 18.2178 22.0305C18.5271 22.2118 18.8763
22.3024 19.2655 22.3024C19.6707 22.3024 20.0173
22.2144 20.3052 22.0385C20.5984 21.8572 20.8224
21.5986 20.977 21.2627H21.8487C21.6408 21.7959
21.3102 22.2091 20.857 22.5023C20.4038 22.7903
19.8733 22.9342 19.2655 22.9342C18.7483 22.9342
18.2765 22.8142 17.8499 22.5743C17.4287 22.3291
17.0955 21.9905 16.8502 21.5586C16.605 21.1268
16.4823 20.6389 16.4823 20.0951Z"
fill="white"
/>
<path d="M25.9712 19.6472V20.263H22.7801V19.6472H25.9712Z" fill="white" />
<path
d="M27.1291 22.3024C27.8062 21.7586 28.3367 21.3134
28.7206 20.9668C29.1045 20.6149 29.427 20.2497 29.6883
19.8711C29.9549 19.4872 30.0882 19.1114 30.0882 18.7435C30.0882
18.3969 30.0029 18.125 29.8323 17.9277C29.667 17.7251 29.3977
17.6238 29.0245 17.6238C28.6619 17.6238 28.3794 17.7384
28.1768 17.9677C27.9795 18.1916 27.8728 18.4929 27.8568
18.8714H27.1531C27.1744 18.2743 27.3557 17.8131 27.6969
17.4879C28.0381 17.1626 28.478 17 29.0165 17C29.5657
17 30.0002 17.152 30.3201 17.4559C30.6453 17.7598
30.808 18.1783 30.808 18.7115C30.808 19.154 30.6747
19.5859 30.4081 20.0071C30.1468 20.423 29.8482 20.7909
29.5123 21.1108C29.1764 21.4253 28.7472 21.7932 28.2247
22.2144H30.9759V22.8222H27.1291V22.3024Z"
fill="white"
/>
<path
d="M31.8172 19.9351C31.8172 19.0181 31.9665
18.3036 32.2651 17.7918C32.5637 17.2746 33.0862
17.016 33.8326 17.016C34.5737 17.016 35.0936 17.2746
35.3921 17.7918C35.6907 18.3036 35.84 19.0181 35.84
19.9351C35.84 20.8682 35.6907 21.5933 35.3921 22.1105C35.0936
22.6276 34.5737 22.8862 33.8326 22.8862C33.0862 22.8862 32.5637
22.6276 32.2651 22.1105C31.9665 21.5933 31.8172 20.8682 31.8172
19.9351ZM35.1202 19.9351C35.1202 19.4713 35.0882 19.0794 35.0242
18.7595C34.9656 18.4342 34.8403 18.173 34.6484 17.9757C34.4617
17.7784 34.1898 17.6798 33.8326 17.6798C33.4701 17.6798 33.1928
17.7784 33.0009 17.9757C32.8142 18.173 32.689 18.4342 32.625
18.7595C32.5663 19.0794 32.537 19.4713 32.537 19.9351C32.537
20.415 32.5663 20.8175 32.625 21.1427C32.689 21.468 32.8142
21.7292 33.0009 21.9265C33.1928 22.1238 33.4701 22.2224
33.8326 22.2224C34.1898 22.2224 34.4617 22.1238 34.6484
21.9265C34.8403 21.7292 34.9656 21.468 35.0242 21.1427C35.0882
20.8175 35.1202 20.415 35.1202 19.9351Z"
fill="white"
/>
<path
d="M10.6543 17.3519V22.8862H9.92651V18.7595L8.08707
22.8862H7.57522L5.72778 18.7515V22.8862H5V17.3519H5.78376L7.83115
21.9265L9.87853 17.3519H10.6543Z"
stroke="white"
stroke-width="0.25"
/>
<path
d="M14.8237 22.8862L13.4961 20.6069H12.6163V22.8862H11.8885V17.3119H13.688C14.1092
17.3119 14.4638 17.3839 14.7517 17.5278C15.0449 17.6718 15.2635 17.8664 15.4075 18.1117C15.5514
18.3569 15.6234 18.6368 15.6234 18.9514C15.6234 19.3353 15.5115 19.6739 15.2875
19.9671C15.0689 20.2603 14.7384 20.455 14.2958 20.5509L15.6954
22.8862H14.8237ZM12.6163 20.0231H13.688C14.0825 20.0231
14.3785 19.9271 14.5757 19.7352C14.773 19.5379 14.8716
19.2766 14.8716 18.9514C14.8716 18.6208 14.773 18.3649
14.5757 18.1836C14.3838 18.0024 14.0879 17.9117 13.688
17.9117H12.6163V20.0231Z"
stroke="white"
stroke-width="0.25"
/>
<path
d="M16.4823 20.0951C16.4823 19.5512 16.605 19.0634
16.8502 18.6315C17.0955 18.1943 17.4287 17.8531 17.8499
17.6078C18.2765 17.3626 18.7483 17.2399 19.2655 17.2399C19.8733
17.2399 20.4038 17.3866 20.857 17.6798C21.3102 17.973 21.6408
18.3889 21.8487 18.9274H20.977C20.8224 18.5915 20.5984 18.3329
20.3052 18.1517C20.0173 17.9704 19.6707 17.8797 19.2655
17.8797C18.8763 17.8797 18.5271 17.9704 18.2178 18.1517C17.9086
18.3329 17.666 18.5915 17.49 18.9274C17.3141 19.258 17.2261
19.6472 17.2261 20.0951C17.2261 20.5376 17.3141 20.9268 17.49
21.2627C17.666 21.5933 17.9086 21.8492 18.2178 22.0305C18.5271
22.2118 18.8763 22.3024 19.2655 22.3024C19.6707 22.3024 20.0173
22.2144 20.3052 22.0385C20.5984 21.8572 20.8224 21.5986 20.977
21.2627H21.8487C21.6408 21.7959 21.3102 22.2091 20.857 22.5023C20.4038
22.7903 19.8733 22.9342 19.2655 22.9342C18.7483 22.9342 18.2765 22.8142
17.8499 22.5743C17.4287 22.3291 17.0955 21.9905 16.8502 21.5586C16.605
21.1268 16.4823 20.6389 16.4823 20.0951Z"
stroke="white"
stroke-width="0.25"
/>
<path
d="M25.9712 19.6472V20.263H22.7801V19.6472H25.9712Z"
stroke="white"
stroke-width="0.25"
/>
<path
d="M27.1291 22.3024C27.8062 21.7586 28.3367 21.3134
28.7206 20.9668C29.1045 20.6149 29.427 20.2497 29.6883
19.8711C29.9549 19.4872 30.0882 19.1114 30.0882 18.7435C30.0882
18.3969 30.0029 18.125 29.8323 17.9277C29.667 17.7251 29.3977
17.6238 29.0245 17.6238C28.6619 17.6238 28.3794 17.7384 28.1768
17.9677C27.9795 18.1916 27.8728 18.4929 27.8568 18.8714H27.1531C27.1744
18.2743 27.3557 17.8131 27.6969 17.4879C28.0381 17.1626 28.478 17 29.0165
17C29.5657 17 30.0002 17.152 30.3201 17.4559C30.6453 17.7598 30.808
18.1783 30.808 18.7115C30.808 19.154 30.6747 19.5859 30.4081
20.0071C30.1468 20.423 29.8482 20.7909 29.5123 21.1108C29.1764
21.4253 28.7472 21.7932 28.2247
22.2144H30.9759V22.8222H27.1291V22.3024Z"
stroke="white"
stroke-width="0.25"
/>
<path
d="M31.8172 19.9351C31.8172 19.0181
31.9665 18.3036 32.2651 17.7918C32.5637
17.2746 33.0862 17.016 33.8326 17.016C34.5737
17.016 35.0936 17.2746 35.3921 17.7918C35.6907
18.3036 35.84 19.0181 35.84 19.9351C35.84 20.8682
35.6907 21.5933 35.3921 22.1105C35.0936 22.6276
34.5737 22.8862 33.8326 22.8862C33.0862 22.8862
32.5637 22.6276 32.2651 22.1105C31.9665 21.5933
31.8172 20.8682 31.8172 19.9351ZM35.1202
19.9351C35.1202 19.4713 35.0882 19.0794 35.0242
18.7595C34.9656 18.4342 34.8403 18.173 34.6484
17.9757C34.4617 17.7784 34.1898 17.6798 33.8326
17.6798C33.4701 17.6798 33.1928 17.7784 33.0009
17.9757C32.8142 18.173 32.689 18.4342 32.625
18.7595C32.5663 19.0794 32.537 19.4713 32.537
19.9351C32.537 20.415 32.5663 20.8175 32.625
21.1427C32.689 21.468 32.8142 21.7292 33.0009
21.9265C33.1928 22.1238 33.4701 22.2224 33.8326
22.2224C34.1898 22.2224 34.4617 22.1238 34.6484
21.9265C34.8403 21.7292 34.9656 21.468 35.0242
21.1427C35.0882 20.8175 35.1202 20.415 35.1202
19.9351Z"
stroke="white"
stroke-width="0.25"
/>
</svg>
);
}
168 changes: 168 additions & 0 deletions src/components/Icons/Svg/Massa/Mrc721.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,168 @@
export function Mrc721({ ...props }) {
const { size } = props;
return (
<svg
width={size || 16}
height={size || 16}
viewBox="0 0 40 40"
fill="none"
xmlns="http://www.w3.org/2000/svg"
>
<circle cx="20" cy="20" r="20" fill="#F1F1F1" />
<path
d="M9.40522 17.3844V22.9197H8.67732V18.7922L6.83757
22.9197H6.32564L4.4779 18.7842V22.9197H3.75V17.3844H4.53389L6.58161
21.9598L8.62932 17.3844H9.40522Z"
fill="#FF0000"
/>
<path
d="M13.5753 22.9197L12.2474
20.64H11.3676V22.9197H10.6397V17.3444H12.4394C12.8607
17.3444 13.2153 17.4164 13.5033 17.5604C13.7966
17.7044 14.0152 17.899 14.1592 18.1443C14.3032
18.3896 14.3752 18.6696 14.3752 18.9842C14.3752
19.3681 14.2632 19.7068 14.0392 20.0001C13.8206
20.2934 13.4899 20.488 13.0473 20.584L14.4471
22.9197H13.5753ZM11.3676 20.0561H12.4394C12.834
20.0561 13.13 19.9601 13.3273 19.7681C13.5246
19.5708 13.6233 19.3095 13.6233 18.9842C13.6233
18.6536 13.5246 18.3976 13.3273 18.2163C13.1353
18.035 12.8394 17.9443 12.4394 17.9443H11.3676V20.0561Z"
fill="#FF0000"
/>
<path
d="M15.2342 20.128C15.2342 19.5841 15.3569
19.0962 15.6022 18.6642C15.8475 18.227 16.1808 17.8857
16.602 17.6404C17.0286 17.3951 17.5006 17.2724 18.0178
17.2724C18.6258 17.2724 19.1563 17.4191 19.6096
17.7124C20.0629 18.0057 20.3935 18.4216 20.6015
18.9602H19.7296C19.575 18.6243 19.351 18.3656 19.0577
18.1843C18.7697 18.003 18.4231 17.9123 18.0178 17.9123C17.6286
17.9123 17.2793 18.003 16.97 18.1843C16.6607 18.3656 16.4181
18.6243 16.2421 18.9602C16.0661 19.2908 15.9781 19.6801
15.9781 20.128C15.9781 20.5706 16.0661 20.9599 16.2421
21.2959C16.4181 21.6265 16.6607 21.8825 16.97
22.0638C17.2793 22.2451 17.6286 22.3357 18.0178
22.3357C18.4231 22.3357 18.7697 22.2477 19.0577
22.0718C19.351 21.8905 19.575 21.6318 19.7296
21.2959H20.6015C20.3935 21.8291 20.0629 22.2424
19.6096 22.5357C19.1563 22.8237 18.6258 22.9677
18.0178 22.9677C17.5006 22.9677 17.0286 22.8477
16.602 22.6077C16.1808 22.3624 15.8475 22.0238
15.6022 21.5918C15.3569 21.1599 15.2342 20.672
15.2342 20.128Z"
fill="#FF0000"
/>
<path
d="M24.7246 19.6801V20.296H21.533V19.6801H24.7246Z"
fill="#FF0000"
/>
<path
d="M29.5302 17.7044L27.3065 22.9197H26.5706L28.8263
17.7764H25.7387V17.1525H29.5302V17.7044Z"
fill="#FF0000"
/>
<path
d="M30.2493 22.3357C30.9265 21.7918
31.4571 21.3465 31.8411 20.9999C32.225
20.648 32.5476 20.2827 32.8089 19.9041C33.0755
19.5201 33.2089 19.1442 33.2089 18.7762C33.2089
18.4296 33.1235 18.1576 32.9529 17.9603C32.7876
17.7577 32.5183 17.6564 32.145 17.6564C31.7824
17.6564 31.4998 17.771 31.2971 18.0003C31.0998
18.2243 30.9932 18.5256 30.9772 18.9042H30.2733C30.2946
18.307 30.4759 17.8457 30.8172 17.5204C31.1585
17.1951 31.5984 17.0325 32.137 17.0325C32.6863
17.0325 33.1209 17.1844 33.4408 17.4884C33.7661
17.7924 33.9288 18.211 33.9288 18.7442C33.9288
19.1868 33.7954 19.6188 33.5288 20.0401C33.2675
20.456 32.9689 20.8239 32.6329 21.1439C32.297
21.4585 31.8677 21.8265 31.3451 22.2477H34.0967V22.8557H30.2493V22.3357Z"
fill="#FF0000"
/>
<path
d="M34.7462 17.8004V17.1365H36.25V22.9197H35.5141V17.8004H34.7462Z"
fill="#FF0000"
/>
<path
d="M9.40522 17.3844V22.9197H8.67732V18.7922L6.83757
22.9197H6.32564L4.4779 18.7842V22.9197H3.75V17.3844H4.53389L6.58161
21.9598L8.62932 17.3844H9.40522Z"
stroke="#FF0000"
stroke-width="0.25"
/>
<path
d="M13.5753 22.9197L12.2474
20.64H11.3676V22.9197H10.6397V17.3444H12.4394C12.8607
17.3444 13.2153 17.4164 13.5033 17.5604C13.7966 17.7044
14.0152 17.899 14.1592 18.1443C14.3032 18.3896 14.3752
18.6696 14.3752 18.9842C14.3752 19.3681 14.2632 19.7068
14.0392 20.0001C13.8206 20.2934 13.4899 20.488 13.0473
20.584L14.4471 22.9197H13.5753ZM11.3676 20.0561H12.4394C12.834
20.0561 13.13 19.9601 13.3273 19.7681C13.5246 19.5708 13.6233
19.3095 13.6233 18.9842C13.6233 18.6536 13.5246 18.3976 13.3273
18.2163C13.1353 18.035 12.8394 17.9443 12.4394
17.9443H11.3676V20.0561Z"
stroke="#FF0000"
stroke-width="0.25"
/>
<path
d="M15.2342 20.128C15.2342 19.5841
15.3569 19.0962 15.6022 18.6642C15.8475 18.227 16.1808
17.8857 16.602 17.6404C17.0286 17.3951 17.5006 17.2724
18.0178 17.2724C18.6258 17.2724 19.1563 17.4191 19.6096
17.7124C20.0629 18.0057 20.3935 18.4216 20.6015
18.9602H19.7296C19.575 18.6243 19.351 18.3656 19.0577
18.1843C18.7697 18.003 18.4231 17.9123 18.0178 17.9123C17.6286
17.9123 17.2793 18.003 16.97 18.1843C16.6607 18.3656 16.4181
18.6243 16.2421 18.9602C16.0661 19.2908 15.9781 19.6801
15.9781 20.128C15.9781 20.5706 16.0661 20.9599 16.2421
21.2959C16.4181 21.6265 16.6607 21.8825 16.97
22.0638C17.2793 22.2451 17.6286 22.3357 18.0178 22.3357C18.4231
22.3357 18.7697 22.2477 19.0577 22.0718C19.351 21.8905 19.575
21.6318 19.7296 21.2959H20.6015C20.3935 21.8291 20.0629 22.2424
19.6096 22.5357C19.1563 22.8237 18.6258 22.9677 18.0178 22.9677C17.5006
22.9677 17.0286 22.8477 16.602 22.6077C16.1808 22.3624 15.8475 22.0238
15.6022 21.5918C15.3569 21.1599 15.2342 20.672 15.2342 20.128Z"
stroke="#FF0000"
stroke-width="0.25"
/>
<path
d="M24.7246 19.6801V20.296H21.533V19.6801H24.7246Z"
stroke="#FF0000"
stroke-width="0.25"
/>
<path
d="M29.5302 17.7044L27.3065 22.9197H26.5706L28.8263
17.7764H25.7387V17.1525H29.5302V17.7044Z"
stroke="#FF0000"
stroke-width="0.25"
/>
<path
d="M30.2493 22.3357C30.9265 21.7918 31.4571 21.3465
31.8411 20.9999C32.225 20.648 32.5476 20.2827 32.8089
19.9041C33.0755 19.5201 33.2089 19.1442 33.2089
18.7762C33.2089 18.4296 33.1235 18.1576 32.9529
17.9603C32.7876 17.7577 32.5183 17.6564 32.145
17.6564C31.7824 17.6564 31.4998 17.771 31.2971
18.0003C31.0998 18.2243 30.9932 18.5256 30.9772
18.9042H30.2733C30.2946 18.307 30.4759 17.8457
30.8172 17.5204C31.1585 17.1951 31.5984 17.0325
32.137 17.0325C32.6863 17.0325 33.1209 17.1844
33.4408 17.4884C33.7661 17.7924 33.9288 18.211
33.9288 18.7442C33.9288 19.1868 33.7954 19.6188
33.5288 20.0401C33.2675 20.456 32.9689 20.8239
32.6329 21.1439C32.297 21.4585 31.8677 21.8265
31.3451 22.2477H34.0967V22.8557H30.2493V22.3357Z"
stroke="#FF0000"
stroke-width="0.25"
/>
<path
d="M34.7462
17.8004V17.1365H36.25V22.9197H35.5141V17.8004H34.7462Z"
stroke="#FF0000"
stroke-width="0.25"
/>
</svg>
);
}
2 changes: 2 additions & 0 deletions src/components/Icons/Svg/Massa/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,3 +4,5 @@ export * from './MassaWallet';
export * from './StationLogo';
export * from './Certificate';
export * from './BridgeLogo';
export * from './Mrc20';
export * from './Mrc721';
10 changes: 10 additions & 0 deletions src/components/Icons/Svg/SvgIcon.stories.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,8 @@ import {
MassaWallet,
StationLogo,
BridgeLogo,
Mrc20,
Mrc721,
} from './Massa';

export default { title: 'Icons/Massa' };
Expand Down Expand Up @@ -39,3 +41,11 @@ export const _BridgeLogo = {
</>
),
};

export const _Mrc20 = {
render: () => <Mrc20 size={40} />,
};

export const _Mrc721 = {
render: () => <Mrc721 size={40} />,
};
Loading

0 comments on commit 948455e

Please sign in to comment.