Refactored rack/tile display code