use a panel instead of a new tab
ported to support jpm