Add header_action method for panels

Rough implementation that seems to work. No tests yet, but wanted to open this one up for discussion.