mirror of
https://github.com/wassname/Mostly-Harmless.git
synced 2026-06-27 16:10:28 +08:00
31 lines
1.0 KiB
HTML
31 lines
1.0 KiB
HTML
<!doctype html>
|
|
<html>
|
|
<head>
|
|
<meta charset="utf-8">
|
|
<title>Mostly Harmless Popup</title>
|
|
<link type="text/css" rel="stylesheet" href="/css/popup.css">
|
|
<script type="text/javascript" src="/fancy-settings/lib/store.js"></script>
|
|
<script type="text/javascript" src="/js/common.js"></script>
|
|
<script type="text/javascript">
|
|
var popup;
|
|
|
|
popup = new Popup();
|
|
|
|
function initPopup() {
|
|
chrome.tabs.getSelected(null, function(currTab) {
|
|
if (cache.get(currTab.url) !== undefined && cache.get(currTab.url).count >= 1) {
|
|
document.getElementById('body').innerHTML = popup.createListHTML(currTab.url);
|
|
document.getElementById('body').style.width = settings.get('popupWidth') + 'px';
|
|
} else {
|
|
document.getElementById('body').innerHTML = popup.createSubmitForm(currTab.url);
|
|
}
|
|
});
|
|
}
|
|
|
|
window.addEventListener('load', initPopup);
|
|
</script>
|
|
</head>
|
|
<body id="body">
|
|
<img id="loading" src="/pix/ajaxload.info.gif" width="32" height="32" alt="Loading..." />
|
|
</body>
|
|
</html> |