Sort cards by name before sorting by code. Encode Decks.js. Sort mages