Replying to Avatar balas

don't you want to use cameri's solution? I get it that it's easier to use the last, but if suddenly there's pow on the last chars instead of the first, we're back at the same problem.. so excluding leading zeroes from the beginning and using that for hex is more resilient in giving you not so dark colors.. would be good to have a common simple ground on the colors because they're really good to recognise a pubkey. the more it works across different apps the better..

Avatar
jb55 3y ago

Never heard of this. Seems fine. I was lazy and just did a quick fix. Maybe will get back to this when there's a nip.

Reply to this note

Please Login to reply.

Discussion

Avatar
balas 3y ago

`hex_value.replace(/^0*([1-9a-f][0-9a-f]{5}).*$/, (m, p1) => p1)`

Thread collapsed