mirror of
https://github.com/ArchiveBox/ArchiveBox
synced 2024-11-26 14:10:20 +00:00
add status column and tweak index css
This commit is contained in:
parent
f7015d2594
commit
4a2e74a3ac
4 changed files with 99 additions and 40 deletions
|
@ -6,7 +6,7 @@
|
||||||
html, body {
|
html, body {
|
||||||
width: 100%;
|
width: 100%;
|
||||||
height: 100%;
|
height: 100%;
|
||||||
font-size: 20px;
|
font-size: 18px;
|
||||||
font-weight: 200;
|
font-weight: 200;
|
||||||
text-align: center;
|
text-align: center;
|
||||||
margin: 0px;
|
margin: 0px;
|
||||||
|
@ -17,16 +17,22 @@
|
||||||
background-color: #aa1e55;
|
background-color: #aa1e55;
|
||||||
color: white;
|
color: white;
|
||||||
padding: 10px;
|
padding: 10px;
|
||||||
|
padding-top: 0px;
|
||||||
|
padding-bottom: 15px;
|
||||||
|
height: 100px;
|
||||||
}
|
}
|
||||||
header h1 {
|
header h1 {
|
||||||
|
font-size: 36px;
|
||||||
font-weight: 300;
|
font-weight: 300;
|
||||||
color: black;
|
color: black;
|
||||||
margin-top: 10px;
|
margin-top: 2px;
|
||||||
margin-bottom: 12px;
|
line-height: 1.4;
|
||||||
}
|
}
|
||||||
header h1 small {
|
header h1 small {
|
||||||
color: white;
|
color: white;
|
||||||
font-size:0.5em;
|
font-size:0.45em;
|
||||||
|
margin-left: 10px;
|
||||||
|
display: block;
|
||||||
}
|
}
|
||||||
header h1 small a {
|
header h1 small a {
|
||||||
text-decoration: none;
|
text-decoration: none;
|
||||||
|
@ -37,6 +43,13 @@
|
||||||
header h1 small a:hover {
|
header h1 small a:hover {
|
||||||
opacity: 1;
|
opacity: 1;
|
||||||
}
|
}
|
||||||
|
.header-right {
|
||||||
|
float: right;
|
||||||
|
width: 50px;
|
||||||
|
height: 60px;
|
||||||
|
text-align: center;
|
||||||
|
padding: 20px;
|
||||||
|
}
|
||||||
table {
|
table {
|
||||||
padding: 6px;
|
padding: 6px;
|
||||||
width: 100%;
|
width: 100%;
|
||||||
|
@ -54,30 +67,48 @@
|
||||||
padding-top: 0.4em;
|
padding-top: 0.4em;
|
||||||
padding-left: 2px;
|
padding-left: 2px;
|
||||||
}
|
}
|
||||||
table tr td img {
|
table tr td img, table tr td object {
|
||||||
|
display: inline-block;
|
||||||
|
margin: auto;
|
||||||
height: 24px;
|
height: 24px;
|
||||||
|
width: 24px;
|
||||||
padding: 0px;
|
padding: 0px;
|
||||||
padding-right: 5px;
|
padding-right: 5px;
|
||||||
text-indent: -10000px;
|
vertical-align: middle;
|
||||||
|
margin-left: 4px;
|
||||||
}
|
}
|
||||||
</style>
|
</style>
|
||||||
</head>
|
</head>
|
||||||
<body>
|
<body>
|
||||||
<header>
|
<header>
|
||||||
<h1 title="Last modified $time_updated">
|
<div class="header-right">
|
||||||
<img src="https://nicksweeting.com/images/archive.png" height="36px">
|
<a href="?">
|
||||||
Archived Sites <img src="https://getpocket.com/favicon.ico" height="36px"> <br/>
|
<img src="static/archive.png" style="height: 100%;"/>
|
||||||
<small>
|
</a>
|
||||||
<a href="https://github.com/pirate/bookmark-archiver">Bookmark Archiver</a>
|
<br/>
|
||||||
</small>
|
<a href="https://pirate.github.io/bookmark-archiver">
|
||||||
</h1>
|
Docs
|
||||||
|
</a>
|
||||||
|
</div>
|
||||||
|
<div style="float:left; height: 50px">
|
||||||
|
<h1 title="Last modified 2017-10-30 05:19" style="text-align:left">
|
||||||
|
Archived Sites
|
||||||
|
<br/>
|
||||||
|
|
||||||
|
<small>
|
||||||
|
$num_links links, last updated $time_updated<br/>
|
||||||
|
Using <a href="https://github.com/pirate/bookmark-archiver" target="_blank" rel="noopener">Bookmark Archiver</a>.
|
||||||
|
</small>
|
||||||
|
</h1>
|
||||||
|
</div>
|
||||||
</header>
|
</header>
|
||||||
<table style="width:100%;height: 90%; overflow-y: scroll;table-layout: fixed">
|
<table style="width:100%;height: 90%; overflow-y: scroll;table-layout: fixed">
|
||||||
<thead>
|
<thead>
|
||||||
<tr>
|
<tr>
|
||||||
<th style="width: 120px;"><img src="https://getpocket.com/favicon.ico" height="12px"> Bookmarked</th>
|
<th style="width: 120px;">Bookmarked On</th>
|
||||||
<th style="width: 45vw;">Saved Articles ($num_links)</th>
|
<th style="width: 2vw;">Status</th>
|
||||||
<th style="width: 50px">Files</th>
|
<th style="width: 43vw;">Saved Articles ($num_links)</th>
|
||||||
|
<th style="width: 50px">Index</th>
|
||||||
<th style="width: 50px">PDF</th>
|
<th style="width: 50px">PDF</th>
|
||||||
<th style="width: 60px;font-size:0.8em;">Screenshot</th>
|
<th style="width: 60px;font-size:0.8em;">Screenshot</th>
|
||||||
<th style="width: 50px">A.org</th>
|
<th style="width: 50px">A.org</th>
|
||||||
|
|
|
@ -1,7 +1,9 @@
|
||||||
<tr>
|
<tr>
|
||||||
<td title="Bookmarked timestamp: $timestamp">$date</td>
|
<td title="Bookmarked timestamp: $timestamp">$date</td>
|
||||||
|
<td>
|
||||||
|
<img src="$favicon_url" onerror="this.src='static/spinner.gif'" class="link-favicon">
|
||||||
|
</td>
|
||||||
<td><a href="$archive_url" style="font-size:1.4em;text-decoration:none;color:black;" title="$title">
|
<td><a href="$archive_url" style="font-size:1.4em;text-decoration:none;color:black;" title="$title">
|
||||||
<img src="$favicon_url">
|
|
||||||
$title <small style="background-color: #eee;border-radius:4px; float:right">$tags</small>
|
$title <small style="background-color: #eee;border-radius:4px; float:right">$tags</small>
|
||||||
</td>
|
</td>
|
||||||
<td style="text-align:center"><a href="$files_url" title="Files">📂</a></td>
|
<td style="text-align:center"><a href="$files_url" title="Files">📂</a></td>
|
||||||
|
|
|
@ -12,6 +12,7 @@
|
||||||
}
|
}
|
||||||
header {
|
header {
|
||||||
width: 100%;
|
width: 100%;
|
||||||
|
height: 90px;
|
||||||
background-color: #aa1e55;
|
background-color: #aa1e55;
|
||||||
margin: 0px;
|
margin: 0px;
|
||||||
text-align: center;
|
text-align: center;
|
||||||
|
@ -25,18 +26,18 @@
|
||||||
font-family: "Gill Sans", Helvetica, sans-serif;
|
font-family: "Gill Sans", Helvetica, sans-serif;
|
||||||
}
|
}
|
||||||
.collapse-icon {
|
.collapse-icon {
|
||||||
float: right;
|
float: left;
|
||||||
color: black;
|
color: black;
|
||||||
width: 126px;
|
width: 126px;
|
||||||
font-size: 0.7em;
|
font-size: 0.7em;
|
||||||
margin-top: 20px;
|
margin-top: 20px;
|
||||||
margin-right: -30px;
|
margin-right: 0px;
|
||||||
margin-left: -150px;
|
margin-left: -35px;
|
||||||
}
|
}
|
||||||
.nav-icon img {
|
.nav-icon img {
|
||||||
display: inline-block;
|
float: right;
|
||||||
margin-right: -200px;
|
display: block;
|
||||||
float: left;
|
margin-right: 13px;
|
||||||
color: black;
|
color: black;
|
||||||
height: 53px;
|
height: 53px;
|
||||||
margin-top: 7px;
|
margin-top: 7px;
|
||||||
|
@ -52,6 +53,9 @@
|
||||||
margin-top: 5px;
|
margin-top: 5px;
|
||||||
margin-bottom: 5px;
|
margin-bottom: 5px;
|
||||||
}
|
}
|
||||||
|
.archive-page-header .alert {
|
||||||
|
margin-bottom: 0px;
|
||||||
|
}
|
||||||
h1 small {
|
h1 small {
|
||||||
opacity: 0.4;
|
opacity: 0.4;
|
||||||
font-size: 0.6em;
|
font-size: 0.6em;
|
||||||
|
@ -67,10 +71,11 @@
|
||||||
}
|
}
|
||||||
.card-body {
|
.card-body {
|
||||||
font-size: 1vw;
|
font-size: 1vw;
|
||||||
padding-top: 2vw;
|
padding-top: 1.2vw;
|
||||||
padding-left: 1vw;
|
padding-left: 1vw;
|
||||||
padding-right: 1vw;
|
padding-right: 1vw;
|
||||||
padding-bottom: 5vw;
|
padding-bottom: 1vw;
|
||||||
|
line-height: 1.1;
|
||||||
word-wrap: break-word;
|
word-wrap: break-word;
|
||||||
max-height: 102px;
|
max-height: 102px;
|
||||||
overflow: hidden;
|
overflow: hidden;
|
||||||
|
@ -84,7 +89,7 @@
|
||||||
border-top: 1px solid gray;
|
border-top: 1px solid gray;
|
||||||
border-radius: 3px;
|
border-radius: 3px;
|
||||||
border-bottom: 1px solid #ddd;
|
border-bottom: 1px solid #ddd;
|
||||||
height: 425px;
|
height: 430px;
|
||||||
width: 400%;
|
width: 400%;
|
||||||
margin-bottom: -330px;
|
margin-bottom: -330px;
|
||||||
|
|
||||||
|
@ -107,6 +112,17 @@
|
||||||
height: 93%;
|
height: 93%;
|
||||||
margin-top: -10px;
|
margin-top: -10px;
|
||||||
}
|
}
|
||||||
|
img.external {
|
||||||
|
height: 30px;
|
||||||
|
margin-right: -10px;
|
||||||
|
padding: 3px;
|
||||||
|
border-radius: 4px;
|
||||||
|
vertical-align: middle;
|
||||||
|
border: 4px solid rgba(0,0,0,0);
|
||||||
|
}
|
||||||
|
img.external:hover {
|
||||||
|
border: 4px solid green;
|
||||||
|
}
|
||||||
|
|
||||||
@media(max-width: 1092px) {
|
@media(max-width: 1092px) {
|
||||||
iframe {
|
iframe {
|
||||||
|
@ -140,11 +156,11 @@
|
||||||
<body>
|
<body>
|
||||||
<header>
|
<header>
|
||||||
<h1 class="page-title">
|
<h1 class="page-title">
|
||||||
<a href="#" class="collapse-icon" title="Collapse Navbar">
|
<a href="../../index.html" class="nav-icon" title="Go to Main Index...">
|
||||||
[-]
|
<img src="../../static/archive.png" alt="Archive Icon">
|
||||||
</a>
|
</a>
|
||||||
<a href="./../../index.html" class="nav-icon" title="Archived Sites">
|
<a href="#" class="collapse-icon" title="Toggle info panel...">
|
||||||
<img src="https://nicksweeting.com/images/archive.png" alt="Archive Icon">
|
[-]
|
||||||
</a>
|
</a>
|
||||||
$title<br/>
|
$title<br/>
|
||||||
<a href="$url" class="title-url">
|
<a href="$url" class="title-url">
|
||||||
|
@ -172,7 +188,9 @@
|
||||||
<div class="card selected-card">
|
<div class="card selected-card">
|
||||||
<iframe class="card-img-top" src="$wget" sandbox="allow-same-origin allow-scripts allow-forms"></iframe>
|
<iframe class="card-img-top" src="$wget" sandbox="allow-same-origin allow-scripts allow-forms"></iframe>
|
||||||
<div class="card-body">
|
<div class="card-body">
|
||||||
<a href="$wget" style="float:right"><small>➡️</small></a>
|
<a href="$wget" style="float:right" title="Open in new tab..." target="_blank" rel="noopener">
|
||||||
|
<img src="../../static/external.png" class="external"/>
|
||||||
|
</a>
|
||||||
<a href="$wget" target="preview"><h4 class="card-title">Local Archive</h4></a>
|
<a href="$wget" target="preview"><h4 class="card-title">Local Archive</h4></a>
|
||||||
<p class="card-text">archive/$domain</p>
|
<p class="card-text">archive/$domain</p>
|
||||||
</div>
|
</div>
|
||||||
|
@ -182,7 +200,9 @@
|
||||||
<div class="card">
|
<div class="card">
|
||||||
<iframe class="card-img-top" src="$pdf"></iframe>
|
<iframe class="card-img-top" src="$pdf"></iframe>
|
||||||
<div class="card-body">
|
<div class="card-body">
|
||||||
<a href="$pdf" style="float:right"><small>➡️</small></a>
|
<a href="$pdf" style="float:right" title="Open in new tab..." target="_blank" rel="noopener">
|
||||||
|
<img src="../../static/external.png" class="external"/>
|
||||||
|
</a>
|
||||||
<a href="$pdf" target="preview" id="pdf-btn"><h4 class="card-title">PDF</h4></a>
|
<a href="$pdf" target="preview" id="pdf-btn"><h4 class="card-title">PDF</h4></a>
|
||||||
<p class="card-text">archive/output.pdf</p>
|
<p class="card-text">archive/output.pdf</p>
|
||||||
</div>
|
</div>
|
||||||
|
@ -192,7 +212,9 @@
|
||||||
<div class="card">
|
<div class="card">
|
||||||
<iframe class="card-img-top" src="$screenshot" sandbox="allow-same-origin allow-scripts allow-forms"></iframe>
|
<iframe class="card-img-top" src="$screenshot" sandbox="allow-same-origin allow-scripts allow-forms"></iframe>
|
||||||
<div class="card-body">
|
<div class="card-body">
|
||||||
<a href="$screenshot" style="float:right"><small>➡️</small></a>
|
<a href="$screenshot" style="float:right" title="Open in new tab..." target="_blank" rel="noopener">
|
||||||
|
<img src="../../static/external.png" class="external"/>
|
||||||
|
</a>
|
||||||
<a href="$screenshot" target="preview"><h4 class="card-title">Screenshot</h4></a>
|
<a href="$screenshot" target="preview"><h4 class="card-title">Screenshot</h4></a>
|
||||||
<p class="card-text">archive/screenshot.png</p>
|
<p class="card-text">archive/screenshot.png</p>
|
||||||
</div>
|
</div>
|
||||||
|
@ -202,7 +224,9 @@
|
||||||
<div class="card">
|
<div class="card">
|
||||||
<iframe class="card-img-top" src="$url" sandbox="allow-same-origin allow-scripts allow-forms"></iframe>
|
<iframe class="card-img-top" src="$url" sandbox="allow-same-origin allow-scripts allow-forms"></iframe>
|
||||||
<div class="card-body">
|
<div class="card-body">
|
||||||
<a href="$url" style="float:right"><small>➡️</small></a>
|
<a href="$url" style="float:right" title="Open in new tab..." target="_blank" rel="noopener">
|
||||||
|
<img src="../../static/external.png" class="external"/>
|
||||||
|
</a>
|
||||||
<a href="$url" target="preview"><h4 class="card-title">Original</h4></a>
|
<a href="$url" target="preview"><h4 class="card-title">Original</h4></a>
|
||||||
<p class="card-text">$domain</p>
|
<p class="card-text">$domain</p>
|
||||||
</div>
|
</div>
|
||||||
|
@ -212,7 +236,9 @@
|
||||||
<div class="card">
|
<div class="card">
|
||||||
<iframe class="card-img-top" src="$archive_org" sandbox="allow-same-origin allow-scripts allow-forms"></iframe>
|
<iframe class="card-img-top" src="$archive_org" sandbox="allow-same-origin allow-scripts allow-forms"></iframe>
|
||||||
<div class="card-body">
|
<div class="card-body">
|
||||||
<a href="$archive_org" style="float:right"><small>➡️</small></a>
|
<a href="$archive_org" style="float:right" title="Open in new tab..." target="_blank" rel="noopener">
|
||||||
|
<img src="../../static/external.png" class="external"/>
|
||||||
|
</a>
|
||||||
<a href="$archive_org" target="preview"><h4 class="card-title">Archive.Org</h4></a>
|
<a href="$archive_org" target="preview"><h4 class="card-title">Archive.Org</h4></a>
|
||||||
<p class="card-text">web.archive.org/web/...</p>
|
<p class="card-text">web.archive.org/web/...</p>
|
||||||
</div>
|
</div>
|
||||||
|
|
10
util.py
10
util.py
|
@ -434,11 +434,11 @@ def derived_link_info(link):
|
||||||
**link,
|
**link,
|
||||||
'date': datetime.fromtimestamp(float(link['timestamp'])).strftime('%Y-%m-%d %H:%M'),
|
'date': datetime.fromtimestamp(float(link['timestamp'])).strftime('%Y-%m-%d %H:%M'),
|
||||||
'google_favicon_url': 'https://www.google.com/s2/favicons?domain={domain}'.format(**link),
|
'google_favicon_url': 'https://www.google.com/s2/favicons?domain={domain}'.format(**link),
|
||||||
'favicon_url': './archive/{timestamp}/favicon.ico'.format(**link),
|
'favicon_url': 'archive/{timestamp}/favicon.ico'.format(**link),
|
||||||
'files_url': './archive/{timestamp}/index.html'.format(**link),
|
'files_url': 'archive/{timestamp}/index.html'.format(**link),
|
||||||
'archive_url': './archive/{}/{}'.format(link['timestamp'], html_appended_url(link)),
|
'archive_url': 'archive/{}/{}'.format(link['timestamp'], html_appended_url(link)),
|
||||||
'pdf_link': './archive/{timestamp}/output.pdf'.format(**link),
|
'pdf_link': 'archive/{timestamp}/output.pdf'.format(**link),
|
||||||
'screenshot_link': './archive/{timestamp}/screenshot.png'.format(**link),
|
'screenshot_link': 'archive/{timestamp}/screenshot.png'.format(**link),
|
||||||
'archive_org_url': 'https://web.archive.org/web/{base_url}'.format(**link),
|
'archive_org_url': 'https://web.archive.org/web/{base_url}'.format(**link),
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue