Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Code refactoring & docs and Token logos #8

Open
JonathonDunford opened this issue Mar 28, 2018 · 4 comments
Open

Code refactoring & docs and Token logos #8

JonathonDunford opened this issue Mar 28, 2018 · 4 comments

Comments

@JonathonDunford
Copy link
Member

Issue by mrmm
Monday Feb 26, 2018 at 23:16 GMT
Originally opened as forkdelta/tokenbase#274


Code formatting and documentation.


mrmm included the following code: https://github.com/forkdelta/tokenbase/pull/274/commits

@JonathonDunford
Copy link
Member Author

Comment by mrmm
Tuesday Feb 27, 2018 at 01:04 GMT


Added Tokens logos as mentioned in forkdelta/forkdelta.github.io#81.

YAML file

The following example shows the added logos field in YAML file:

---

addr: '0x9294c0be711473f24de4441ff2de0773bfd96eae'
decimals: 18
description: >-
  # The following options were found                                                                       #
  # You may need to edit them and you MUST delete commented lines                                          #
  # From the website: description meta tag                                                                 #
  ArcBlock
links:
- Facebook: https://www.facebook.com/arcblock.io/
- Github: https://github.com/arcblock
- Instagram: https://www.instagram.com/arcblock/
- Linkedin: https://www.linkedin.com/in/flaviencharlon
- Linkedin: https://www.linkedin.com/in/jiaxi-lin-a536133/
- Linkedin: https://www.linkedin.com/in/violin-wang-b81a6673/
- Linkedin: https://www.linkedin.com/in/cartwrightx/
- Linkedin: https://www.linkedin.com/in/jeancheninchina
- Linkedin: https://www.linkedin.com/in/robertmao
- Linkedin: https://www.linkedin.com/in/justin-tomboulian-69b61919/
- Linkedin: https://www.linkedin.com/company/18355951/
- Linkedin: https://www.linkedin.com/in/wallin
- Linkedin: https://www.linkedin.com/in/huishen-cui-7254b362/
- Linkedin: https://www.linkedin.com/in/lawrencelerner/
- Linkedin: https://www.linkedin.com/in/maggie-wu-164a0797/
- Linkedin: https://www.linkedin.com/in/saldhanani/
- Reddit: https://www.reddit.com/r/arcblock/
- Telegram: https://t.me/ArcBlock
- Twitter: https://twitter.com/ArcBlock_io
- Website: https://www.arcblock.io/
- Whitepaper: ADD OR DELETE LINE
- Bitcointalk: ADD OR DELETE LINE
- Blog: ADD OR DELETE LINE
logos:
  default: https://www.arcblock.io/images/favicons/apple-touch-icon.png
  md: https://www.arcblock.io/images/favicons/apple-touch-icon.png
  sizes:
  - 32x32: https://www.arcblock.io/images/favicons/favicon-32x32.png
  - 16x16: https://www.arcblock.io/images/favicons/favicon-16x16.png
name: ArcBlock
symbol: ABT

Possible sub-fields

default the best resolution found for the token logo
favicon the favicon scrapped from the website (if exists)
md medium size token logo
sizes list of the different sizes scraped from the website

@JonathonDunford
Copy link
Member Author

Comment by mrmm
Wednesday Feb 28, 2018 at 11:05 GMT


Past updates:

  • Delete sizes sub-field from logos field.
  • Scrape logos by priority from CoinMarketCap, Twitter and token official website.

The new format is :

addr: '0x827d41446a2cb012d3011b94f525d6c46b32866d'
decimals: 9
description: >-
  FILL ME IN
links:
- Facebook: https://www.facebook.com/OceanSafe-1576498739103338/
- Twitter: https://twitter.com/OceanSafeCoin
- Website: http://oceansafe.io
- Reddit: ADD OR DELETE LINE
- Bitcointalk: ADD OR DELETE LINE
- Whitepaper: ADD OR DELETE LINE
- Telegram: ADD OR DELETE LINE
- Blog: ADD OR DELETE LINE
logos:
  default: https://pbs.twimg.com/profile_images/930178730751905792/d3qhLKJn_200x200.jpg
  hd: https://pbs.twimg.com/profile_images/930178730751905792/d3qhLKJn_400x400.jpg
  icon: https://pbs.twimg.com/profile_images/930178730751905792/d3qhLKJn_normal.jpg
  md: https://pbs.twimg.com/profile_images/930178730751905792/d3qhLKJn_200x200.jpg
  sd: https://pbs.twimg.com/profile_images/930178730751905792/d3qhLKJn_bigger.jpg
name: OceanSafe Coin
symbol: OSC

cc @freeatnet @JonathonDunford review needed, thanks.

@JonathonDunford
Copy link
Member Author

Comment by freeatnet
Wednesday Feb 28, 2018 at 22:45 GMT


@mrmm Had a brief look. Definitely a change for the better. Two concerns though:

  1. It looks like definitions of sd, md, hd formats depend on the source. I wonder if using sizes as originally implemented would work better in the long-term.
  2. I'm a bit concerned with how fast those links would expire. Twitter profile pics tend to change somewhat frequently, and coinmarketcap, I understand, changes their image URLs without notice. Is there any way we can store them in a more permanent manner?

@JonathonDunford
Copy link
Member Author

Comment by mrmm
Wednesday Feb 28, 2018 at 23:03 GMT


@freeatnet To clarify a little bit:

  1. At first is used sizes to list scrapped sizes from different sources and it is better long-term usage but the problem with that is you cant be sure to find the same sizes. I think the best solution is to use the biggest format found and generate two or three predefined sizes (64x64, 100x100 and 200x200).
  2. Totally agree with that, I am planing to do this and store them very likely on S3.

I will work on that asap ;)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant