[origin-ui-192] Handle cartridges restricted by gear size

Can we first compute the domain sizes, and store it in $domain_sizes, then return [$domain_sizes, $cartridge_sizes, $quickstart_sizes] at the end?