Files

163 lines
6.3 KiB
HTML

<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>{{ title }} - {{ nick }}</title>
<meta property="og:title" content="{{ nick }}">
<meta property="og:description" content="{{ description }}">
<meta property="og:type" content="profile">
<meta property="og:url" content="{{ feed_url }}">
{% if has_avatar %}<meta property="og:image" content="{{ avatar_url }}">{% endif %}
<meta property="og:site_name" content="Org Social Previews">
<link rel="alternate" type="application/rss+xml" title="{{ nick }}'s blog (RSS)" href="{{ rss_url }}">
<style>
:root {
--brand: #663399;
--bg: #f4f1f8;
--card: #ffffff;
--text: #2a2533;
--muted: #6c6577;
--border: #e3dcef;
--link: #1d9bf0;
}
* { box-sizing: border-box; }
body {
font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
background-color: var(--bg);
margin: 0;
padding: 32px 16px 64px;
color: var(--text);
}
.wrapper { max-width: 720px; margin: 0 auto; }
.profile {
display: flex;
align-items: center;
gap: 16px;
padding: 24px;
background: var(--card);
border: 1px solid var(--border);
border-radius: 16px;
margin-bottom: 24px;
box-shadow: 0 4px 12px rgba(102, 51, 153, 0.06);
}
.avatar {
width: 72px; height: 72px; border-radius: 50%;
background-color: var(--brand);
display: flex; align-items: center; justify-content: center;
color: white; font-weight: bold; font-size: 28px;
object-fit: cover; flex-shrink: 0;
}
.profile h1 { margin: 0 0 4px; font-size: 22px; }
.profile .nick { color: var(--muted); margin: 0 0 8px; font-size: 14px; }
.profile .description { margin: 0; font-size: 15px; line-height: 1.5; }
.feed-links {
display: flex; gap: 14px; flex-wrap: wrap; margin-top: 8px;
}
.feed-link {
font-size: 13px;
color: var(--brand); text-decoration: none;
}
.feed-link:hover { text-decoration: underline; }
.post {
background: var(--card);
border: 1px solid var(--border);
border-radius: 16px;
padding: 20px 24px;
margin-bottom: 16px;
box-shadow: 0 4px 12px rgba(102, 51, 153, 0.04);
}
.post-header {
display: flex; justify-content: space-between; align-items: baseline;
margin-bottom: 12px; gap: 12px; flex-wrap: wrap;
}
.post-time { color: var(--muted); font-size: 13px; text-decoration: none; }
.post-time:hover { text-decoration: underline; }
.post-mood { font-size: 20px; }
.post-content {
font-size: 16px; line-height: 1.6;
word-wrap: break-word;
}
.post-content a { color: var(--link); }
.post-content img { max-width: 100%; height: auto; border-radius: 8px; }
.post-content pre {
background-color: #f6f8fa !important;
padding: 14px !important;
border-radius: 8px !important;
overflow-x: auto;
font-size: 13px;
}
.post-footer {
margin-top: 14px; padding-top: 12px;
border-top: 1px solid var(--border);
display: flex; gap: 14px; flex-wrap: wrap;
font-size: 12px; color: var(--muted);
}
.tags { color: var(--brand); }
.empty {
text-align: center; padding: 48px 16px;
color: var(--muted);
background: var(--card);
border: 1px solid var(--border);
border-radius: 16px;
}
footer {
text-align: center; margin-top: 32px;
font-size: 12px; color: var(--muted);
}
footer a { color: var(--brand); text-decoration: none; }
</style>
</head>
<body>
<div class="wrapper">
<header class="profile">
{% if has_avatar %}
<img src="{{ avatar_url }}" alt="{{ nick }}" class="avatar">
{% else %}
<div class="avatar">{{ user_initial }}</div>
{% endif %}
<div>
<h1>{{ title }}</h1>
<p class="nick">@{{ nick }}</p>
{% if description %}<p class="description">{{ description }}</p>{% endif %}
<div class="feed-links">
<a class="feed-link" href="{{ feed_url }}" target="_blank" rel="noopener">📡 social.org feed</a>
<a class="feed-link" href="{{ rss_url }}" target="_blank" rel="noopener">📰 RSS</a>
</div>
</div>
</header>
{% if posts %}
{% for post in posts %}
<article class="post" id="{{ post.id }}">
<div class="post-header">
<a class="post-time" href="{{ feed_url }}#{{ post.id }}" target="_blank" rel="noopener">
📅 {{ post.formatted_time }}
</a>
{% if post.mood %}<span class="post-mood">{{ post.mood }}</span>{% endif %}
</div>
<div class="post-content" lang="{{ post.lang }}">
{{ post.formatted_content | safe }}
</div>
{% if post.tags or post.client %}
<div class="post-footer">
{% if post.tags %}
<span class="tags">{% for tag in post.tags %}#{{ tag }}{% if not loop.last %} {% endif %}{% endfor %}</span>
{% endif %}
{% if post.client %}<span>📱 {{ post.client }}</span>{% endif %}
</div>
{% endif %}
</article>
{% endfor %}
{% else %}
<div class="empty">No posts yet.</div>
{% endif %}
<footer>
<a href="https://org-social.org/" target="_blank" rel="noopener">Powered by Org Social</a>
</footer>
</div>
</body>
</html>