Extra an handleEvents helper
Remove unused param
Use custom element to tabs