Factor ruler into a component.