|
|
(未显示同一用户的3个中间版本) |
第1行: |
第1行: |
| <!DOCTYPE html>
| | {{#css: |
| <html lang="zh-CN">
| | .rounded-container { |
| <head>
| | padding: 10px; |
| <meta charset="UTF-8">
| | box-shadow: 0 0 10px rgba(0,0,0,0.1); |
| <meta name="viewport" content="width=device-width, initial-scale=1.0">
| | } |
| <title>中文人物目录</title>
| | .custom-dpl-table { |
| <style>
| | font-family: Arial, sans-serif; |
| body {
| | font-size: 14px; |
| font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
| | border-collapse: separate; |
| background: linear-gradient(135deg, #e0e7ff, #f3e8ff);
| | border-spacing: 0; |
| margin: 0;
| | width: 100%; |
| padding: 20px;
| | } |
| color: #333;
| | .custom-dpl-table th, .custom-dpl-table td { |
| }
| | padding: 12px; |
| | border: 1px solid #ddd; |
| | } |
| | .custom-dpl-table th { |
| | background-color: #007bff; |
| | color: white; |
| | text-align: left; |
| | } |
| | .custom-dpl-table tr > *:first-child { |
| | border-top-left-radius: 10px; |
| | border-bottom-left-radius: 10px; |
| | } |
| | .custom-dpl-table tr > *:last-child { |
| | border-top-right-radius: 10px; |
| | border-bottom-right-radius: 10px; |
| | } |
| | .custom-dpl-table tr:nth-child(even) td { |
| | background-color: #f8f9fa; |
| | } |
| | .custom-dpl-table tr:hover td { |
| | background-color: #e9ecef; |
| | } |
| | .custom-dpl-table .page-column { |
| | text-align: left; |
| | } |
| | .custom-dpl-table .author-column { |
| | text-align: right; |
| | } |
| | .custom-dpl-table .date-column { |
| | text-align: right; |
| | } |
| | }} |
|
| |
|
| .directory-container {
| | <div class="rounded-container"> |
| max-width: 1200px;
| | {{#dpl: |
| margin: 0 auto;
| | | category = 中文人物 |
| padding: 20px;
| | | addauthor = true |
| }
| | | addfirsteditdate = true |
| | | | mode = table |
| .directory-header {
| | | columns = page,author,firsteditdate |
| text-align: center;
| | | class = wikitable custom-dpl-table |
| margin-bottom: 30px;
| | | tableattr = data-column-classes=page-column,author-column,date-column |
| }
| | }} |
| | | </div> |
| .directory-header h1 {
| |
| font-size: 2.5em;
| |
| color: #1e3a8a;
| |
| margin: 0;
| |
| }
| |
| | |
| .directory-grid {
| |
| display: grid;
| |
| grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
| |
| gap: 20px;
| |
| }
| |
| | |
| .directory-card {
| |
| background: #ffffff;
| |
| border-radius: 16px;
| |
| box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
| |
| padding: 20px;
| |
| transition: transform 0.3s ease, box-shadow 0.3s ease;
| |
| overflow: hidden;
| |
| }
| |
| | |
| .directory-card:hover {
| |
| transform: translateY(-5px);
| |
| box-shadow: 0 8px 24px rgba(0, 0, 0, 0.15);
| |
| }
| |
| | |
| .directory-card h3 {
| |
| font-size: 1.5em;
| |
| color: #1e3a8a;
| |
| margin: 0 0 10px;
| |
| }
| |
| | |
| .directory-card p {
| |
| margin: 5px 0;
| |
| font-size: 1em;
| |
| color: #4b5563;
| |
| }
| |
| | |
| .directory-card p.label {
| |
| font-weight: bold;
| |
| color: #1e40af;
| |
| }
| |
| | |
| /* 响应式设计 */
| |
| @media (max-width: 600px) {
| |
| .directory-grid {
| |
| grid-template-columns: 1fr;
| |
| }
| |
| | |
| .directory-header h1 {
| |
| font-size: 2em;
| |
| }
| |
| }
| |
| </style>
| |
| </head>
| |
| <body>
| |
| <div class="directory-container">
| |
| <div class="directory-header">
| |
| <h1>中文人物目录</h1>
| |
| </div>
| |
| <div class="directory-grid">
| |
| <!-- 使用 DynamicPageList3 查询 -->
| |
| <div class="dynamic-content">
| |
| {{#dpl:
| |
| |category=中文人物
| |
| |namespace=
| |
| |ordermethod=created
| |
| |order=descending
| |
| |addpagecounter=true
| |
| |addauthor=true
| |
| |addcreationdate=true
| |
| |resultsheader=<div class="directory-grid">
| |
| |noresultsheader=<p>暂无页面数据</p>
| |
| |format=,<div class="directory-card"><h3>%PAGE%</h3><p class="label">创建时间:</p><p>%DATE%</p><p class="label">创建人:</p><p>%USER%</p></div>,
| |
| |resultsfooter=</div>
| |
| }}
| |
| </div>
| |
| </div>
| |
| </div>
| |
| | |
| <script>
| |
| // 可选:添加动态效果(如平滑滚动)
| |
| document.querySelectorAll('.directory-card').forEach(card => {
| |
| card.addEventListener('click', () => {
| |
| const pageName = card.querySelector('h3').textContent;
| |
| window.location.href = `/wiki/${encodeURIComponent(pageName)}`;
| |
| });
| |
| });
| |
| </script>
| |
| </body>
| |
| </html>
| |