Merge evolutions feature into main branch #2

Merged
hexaitos merged 47 commits from dev into main 2026-08-08 07:42:44 +00:00
Owner

A bunch of stuff was done here! I added a new evolutions feature that shows the evolutions for each Pokémon, updated to the new database and did a few other things. The evolutions feature is still not 100% done but I think it works well enough that it can be released on the main branch.

A bunch of stuff was done here! I added a new evolutions feature that shows the evolutions for each Pokémon, updated to the new database and did a few other things. The evolutions feature is still not 100% done but I think it works well enough that it can be released on the main branch.
Actually show the evolution tree and add the baby / base form at the top
The evolution data is so much longer, still need to add a ton. Added held items in this
commit.
This is a lot of stuff. I got the new DB because it contained more information on the
evolutions and fixed some data that was missing. Unfortunately, that also made it so that
I had to re-write a lot. The hash now contains a nested hash that has the form data if it
exists. By default there's only "standard". Because of that, the entire
pokemon_evo_info.htmlerb had to be wrapped in yet *another* loop where we're looping
through each form first and then look at its data individually.

Additionally, there was a small bug in my move query that was exposed while I moved over
to the new database.

Lastly, because my database contained a few manual additions, I've put some .sql files
into app/db/migrations which can be run on a new database to add my manual additions to
the DB (especially the indices and the gmax data).
Now shows information about who the Pokémon evolves from as well as a bunch of design
improvements on the evolution page
It seems like folk really seem to want to have a search bar everywhere! And I think it is
in the spirit of this site being meant to be a site for fast lookups. So added the search
everywhere. Also a few sneaky <%= lang %> bugs in various links fixed.
Apparently, using a <main> tag is preferred
needed
Add a bunch more triggers to the evolution data
I added a NULLIF to the DB query so it doesn't need an explicit == 1 check anymore
leftover from when I removed all .gsub statements
Add a separate page which shows the information for a particular item. We already had
something similar (viewing the information for all items of a particular item pocket) so
it wasn't too hard adding this new route for viewing one item in particular.
This was fine on every browser I tested, even Servo and Falkon but *of course* Safari
needs to have its own Extrawurst so… removed it haha Granted there was no point in having
it in there anyway so
Why on God's green Earth do I have to fight my linter to let me use tabs. It's
understandable that it would be an option or even the default to have spaces, but to not
have tabs as an option? Maybe I am missing something, but it's very annoying. I do want to
try to use HERB for better and more consitent formatting, but I want to keep my tabs… so I
guess it won't be helping with my indentation formatting after all (which I really, really
would it would).
This is obviously terribly but it was the quickest fix I have found. tl;dr an update to
the database added specific Japanese versions to here. I have to look at this query a bit
more in-depth again but unfortunately the newly-added versions made it so that Red, Blue
and Yellow exist in the database *twice* now. This caused some frontend rendering issues.
Temporary (hopefully,,) fix is just disabling the Japan-specific versions outright.
A bunch of new mega evolutions don't yet have any move information. Since I am already
checking whether moves are nil and then fetching gmax information, I just went and added
another check. If gmax exists but if it is *empty* then the Pokémon is neither gmax nor
does it have any moves and an informational text is displayed instead.
I used a similar way of handling the meta tags in my Artefacts site so I am doing it the
same here. Instead of having this monster of a `case` in my layout, I just pass instance
variables to the layout through the route. Much easier to handle and much easier to adapt
the tags later on!
The /:lang/show namespace was a bit confusing with things strewn about everywhere. I dont
really wanna split it up further tho so just a bit of reordering so that they are more
logically ordered in there
I realised I still had these in there from when I was testing some other stuff but I can
remove these now. Not sure if it affects performance or anything but I don't need the
index anyway
Sign in to join this conversation.
No reviewers
No labels
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
hexaitos/theriodex!2
No description provided.