selectiveSizeSum = (size, types) => {
	let sum = 0;
	for (const key of Object.keys(size)) {
		if (size[key] !== 0 && types.has(key)) sum += size[key];
	}
	return sum;
}
@param {Record<string, number>} size size
@param {Set<string>} types types
@returns {number} selective size sum