Amazon Interview Question

Asked to create a react component - a widget with tabs. Clicking each tab will flip to show different value.