refactor(rating): use optional binding for `readonly`