You have to establish a communication protocol between module and content script. This is done with port
.
In your main.js
panel.port.on('askactivetaburl', function(){
panel.port.emit('sentactivetaburl', tabs.activeTab.url);
})
and in your panel script
self.port.on('sentactivetaburl', function(activetaburl){
// work with activetaburl
});
self.port.emit('askactivetaburl');