173 lines
3.2 KiB
HTML
173 lines
3.2 KiB
HTML
<div class="pdf-container">
|
|
<div class="pdf-viewer">
|
|
<iframe
|
|
src="cv_tiny.pdf#toolbar=0&navpanes=0"
|
|
width="100%"
|
|
height="100%"
|
|
style="border: none;"
|
|
title="简历预览 - 点击在新窗口全屏查看">
|
|
</iframe>
|
|
|
|
<div class="pdf-overlay" onclick="window.open('cv_tiny.pdf', '_blank')">
|
|
<div class="overlay-content">
|
|
<svg class="fullscreen-icon" viewBox="0 0 24 24" fill="white">
|
|
<path d="M7 14H5v5h5v-2H7v-3zm-2-4h2V7h3V5H5v5zm12 7h-3v2h5v-5h-2v3zM14 5v2h3v3h2V5h-5z"/>
|
|
</svg>
|
|
<span class="overlay-text">点击全屏查看</span>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
|
|
<div class="pdf-actions">
|
|
<a href="cv_tiny.pdf" target="_blank" class="btn btn-primary">
|
|
<svg class="btn-icon" viewBox="0 0 24 24">
|
|
<path d="M19 19H5V5h7V3H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2v-7h-2v7zM14 3v2h3.59l-9.83 9.83 1.41 1.41L19 6.41V10h2V3h-7z"/>
|
|
</svg>
|
|
在新窗口打开
|
|
</a>
|
|
<a href="cv_tiny.pdf" download class="btn btn-secondary">
|
|
<svg class="btn-icon" viewBox="0 0 24 24">
|
|
<path d="M19 9h-4V3H9v6H5l7 7 7-7zM5 18v2h14v-2H5z"/>
|
|
</svg>
|
|
下载PDF
|
|
</a>
|
|
</div>
|
|
</div>
|
|
|
|
<style>
|
|
.pdf-container {
|
|
width: 100%;
|
|
max-width: 800px;
|
|
margin: 2rem auto;
|
|
text-align: center;
|
|
}
|
|
|
|
.pdf-viewer {
|
|
position: relative;
|
|
width: 100%;
|
|
height: 600px;
|
|
border-radius: 12px;
|
|
overflow: hidden;
|
|
box-shadow: 0 6px 20px rgba(0,0,0,0.1);
|
|
}
|
|
|
|
.pdf-overlay {
|
|
position: absolute;
|
|
top: 0;
|
|
left: 0;
|
|
width: 100%;
|
|
height: 100%;
|
|
background: rgba(0,0,0,0.5);
|
|
cursor: pointer;
|
|
display: flex;
|
|
align-items: center;
|
|
justify-content: center;
|
|
opacity: 0;
|
|
transition: opacity 0.3s ease;
|
|
}
|
|
|
|
.pdf-viewer:hover .pdf-overlay {
|
|
opacity: 1;
|
|
}
|
|
|
|
.overlay-content {
|
|
background: rgba(0,0,0,0.8);
|
|
padding: 20px 30px;
|
|
border-radius: 30px;
|
|
display: flex;
|
|
align-items: center;
|
|
gap: 12px;
|
|
backdrop-filter: blur(10px);
|
|
border: 1px solid rgba(255,255,255,0.1);
|
|
}
|
|
|
|
.fullscreen-icon {
|
|
width: 24px;
|
|
height: 24px;
|
|
}
|
|
|
|
.overlay-text {
|
|
color: white;
|
|
font-size: 16px;
|
|
font-weight: 500;
|
|
}
|
|
|
|
.pdf-actions {
|
|
display: flex;
|
|
gap: 15px;
|
|
justify-content: center;
|
|
margin-top: 20px;
|
|
flex-wrap: wrap;
|
|
}
|
|
|
|
.btn {
|
|
padding: 12px 24px;
|
|
text-decoration: none;
|
|
border-radius: 8px;
|
|
font-weight: 500;
|
|
display: inline-flex;
|
|
align-items: center;
|
|
gap: 8px;
|
|
transition: all 0.3s;
|
|
border: 2px solid transparent;
|
|
}
|
|
|
|
.btn-primary {
|
|
background: #007bff;
|
|
color: white;
|
|
}
|
|
|
|
.btn-primary:hover {
|
|
background: #0056b3;
|
|
transform: translateY(-2px);
|
|
box-shadow: 0 4px 12px rgba(0,123,255,0.3);
|
|
}
|
|
|
|
.btn-secondary {
|
|
background: #28a745;
|
|
color: white;
|
|
}
|
|
|
|
.btn-secondary:hover {
|
|
background: #1e7e34;
|
|
transform: translateY(-2px);
|
|
box-shadow: 0 4px 12px rgba(40,167,69,0.3);
|
|
}
|
|
|
|
.btn-icon {
|
|
width: 18px;
|
|
height: 18px;
|
|
}
|
|
|
|
/* 响应式设计 */
|
|
@media (max-width: 768px) {
|
|
.pdf-viewer {
|
|
height: 500px;
|
|
}
|
|
|
|
.pdf-actions {
|
|
flex-direction: column;
|
|
align-items: center;
|
|
}
|
|
|
|
.btn {
|
|
width: 200px;
|
|
justify-content: center;
|
|
}
|
|
}
|
|
|
|
@media (max-width: 480px) {
|
|
.pdf-viewer {
|
|
height: 400px;
|
|
}
|
|
|
|
.overlay-content {
|
|
padding: 15px 20px;
|
|
}
|
|
|
|
.overlay-text {
|
|
font-size: 14px;
|
|
}
|
|
}
|
|
</style>
|