Closed GiacomoLaw closed 7 years ago
Sorry, the documentation is missing some information. I had been meaning to add this ever since I changed the way the code works, but it seems I just forgot.
In order for the icons to show up, you need to decorate the DOM items. The easiest way is to add the following code just before your closing </body>
tag (or, right after the last icon):
<script type="text/javascript">
PkSpr.process_dom();
</script>
Or, you can do this:
<span id="icon_1" class="pkspr pkmn-bulbasaur color-shiny"></span>
<script type="text/javascript">
PkSpr.decorate('icon_1');
</script>
The first version is simpler, the second one is slightly more efficient because it will make the icon show up before the whole page finishes loading.
Thank you so much!
It worked - yay!
Is this right for leftovers?
<span class="pkspr leftovers"></span>
It should be hold-item-leftovers
- they are all prefixed with the category, and leftovers is a hold item. The overview is the quickest way to double check.
Okay, thanks. Didn't see that page!
Thanks so much for the awesome work.
Hi all
I linked the CSS to the url sheet on the download site. However, the icons are not showing:
https://github.com/GiacomoLaw/pokemon-team
Anyone know why?
Thank you! 😄