| 1 | <div class="hub<%= hub.heroImage ? ' hub--img' : '' %>">
|
|---|
| 2 |
|
|---|
| 3 | <%# ── HERO (label) — the mini topnav bar sits above it (chrome.ejs);
|
|---|
| 4 | the hero itself is the "large" header of the hub home ──────────────── %>
|
|---|
| 5 | <header class="hub-hero<%= hub.heroImage ? ' has-img' : '' %>"<% if (hub.heroImage) { %> style="--hero-img:url('<%= hub.heroImage %>'); --hero-ov:<%= ((hub.heroOverlay == null ? 45 : hub.heroOverlay)/100).toFixed(2) %>"<% } %>>
|
|---|
| 6 | <div class="hub-hero-inner container">
|
|---|
| 7 | <h1 class="hub-hero-title"><%= hub.title %></h1>
|
|---|
| 8 | <% if (hub.tagline) { %>
|
|---|
| 9 | <p class="hub-hero-tag"><%= hub.tagline %></p>
|
|---|
| 10 | <% } %>
|
|---|
| 11 | <% if (hub.intro) { %>
|
|---|
| 12 | <p class="hub-hero-desc"><%= hub.intro %></p>
|
|---|
| 13 | <% } %>
|
|---|
| 14 | </div>
|
|---|
| 15 | </header>
|
|---|
| 16 |
|
|---|
| 17 | <div class="container hub-body">
|
|---|
| 18 |
|
|---|
| 19 | <%# ── MAIN PAGE (label-/primary account — not an artist) ──────────── %>
|
|---|
| 20 | <% if (mainSite) { %>
|
|---|
| 21 | <section class="hub-sec hub-sec-main">
|
|---|
| 22 | <a class="hub-main-card" href="/user/<%= mainSite.slug %>"
|
|---|
| 23 | hx-get="/user/<%= mainSite.slug %>?partial=1" hx-target="#pcms-main" hx-swap="innerHTML"
|
|---|
| 24 | hx-push-url="/user/<%= mainSite.slug %>" hx-indicator="#pcms-loading">
|
|---|
| 25 | <% var _mAva = mainSite.profile_photo || mainSite.owner_avatar; %>
|
|---|
| 26 | <span class="hub-main-avatar"<% if (_mAva) { %> style="background-image:url('<%= _mAva %>')"<% } else { %> style="background:<%= mainSite.accent || 'var(--accent)' %>;color:#fff"<% } %>>
|
|---|
| 27 | <% if (!_mAva) { %><%= (mainSite.title || mainSite.slug).charAt(0).toUpperCase() %><% } %>
|
|---|
| 28 | </span>
|
|---|
| 29 | <span class="hub-main-info">
|
|---|
| 30 | <span class="hub-main-badge"><%= t('phub.main_badge') %></span>
|
|---|
| 31 | <span class="hub-main-name"><%= mainSite.title %></span>
|
|---|
| 32 | <% if (mainSite.tagline) { %><span class="hub-main-tag"><%= mainSite.tagline %></span><% } %>
|
|---|
| 33 | </span>
|
|---|
| 34 | <span class="hub-main-cta"><%= t('phub.view_page') %> <span aria-hidden="true">→</span></span>
|
|---|
| 35 | </a>
|
|---|
| 36 | </section>
|
|---|
| 37 | <% } %>
|
|---|
| 38 |
|
|---|
| 39 | <%# ── ARTIST ROSTER ─────────────────────────────────────────── %>
|
|---|
| 40 | <% if (artists && artists.length) { %>
|
|---|
| 41 | <% var _total = (typeof totalArtists !== 'undefined') ? totalArtists : artists.length; %>
|
|---|
| 42 | <% var _hasMore = _total > artists.length; %>
|
|---|
| 43 | <section class="hub-sec">
|
|---|
| 44 | <h2 class="hub-sec-title">
|
|---|
| 45 | <%= t('phub.members') %>
|
|---|
| 46 | <% if (_hasMore) { %><span class="hub-sec-count"><%= _total %></span><% } %>
|
|---|
| 47 | </h2>
|
|---|
| 48 | <div class="roster">
|
|---|
| 49 | <% artists.forEach(function(a){ %>
|
|---|
| 50 | <a class="roster-card" href="/user/<%= a.slug %>"
|
|---|
| 51 | hx-get="/user/<%= a.slug %>?partial=1" hx-target="#pcms-main" hx-swap="innerHTML"
|
|---|
| 52 | hx-push-url="/user/<%= a.slug %>" hx-indicator="#pcms-loading">
|
|---|
| 53 | <% var _ava = a.profile_photo || a.owner_avatar; %>
|
|---|
| 54 | <span class="roster-avatar"<% if (_ava) { %> style="background-image:url('<%= _ava %>')"<% } else { %> style="background:<%= a.accent || 'var(--accent)' %>;color:#fff"<% } %>>
|
|---|
| 55 | <% if (!_ava) { %><%= (a.title || a.slug).charAt(0).toUpperCase() %><% } %>
|
|---|
| 56 | </span>
|
|---|
| 57 | <span class="roster-name"><%= a.title %></span>
|
|---|
| 58 | <% if (a.tagline) { %><span class="roster-tag"><%= a.tagline %></span><% } %>
|
|---|
| 59 | <span class="roster-count"><%= a.post_count %> <%= a.post_count === 1 ? t('phub.post_one') : t('phub.post_many') %></span>
|
|---|
| 60 | </a>
|
|---|
| 61 | <% }); %>
|
|---|
| 62 | </div>
|
|---|
| 63 | <% if (_hasMore) { %>
|
|---|
| 64 | <div class="hub-more">
|
|---|
| 65 | <a class="hub-more-link" href="/leden"><%= t('phub.all_members', { n: _total }) %> <span aria-hidden="true">→</span></a>
|
|---|
| 66 | </div>
|
|---|
| 67 | <% } %>
|
|---|
| 68 | </section>
|
|---|
| 69 | <% } %>
|
|---|
| 70 |
|
|---|
| 71 | <%# ── LATEST POSTS ────────────────────────────────────────────── %>
|
|---|
| 72 | <% if (posts && posts.length) { %>
|
|---|
| 73 | <section class="hub-sec">
|
|---|
| 74 | <h2 class="hub-sec-title"><%= t('phub.latest_posts') %></h2>
|
|---|
| 75 | <div class="hub-feed">
|
|---|
| 76 | <% posts.forEach(function(p){ %>
|
|---|
| 77 | <a class="feed-item" href="/user/<%= p.site_slug %>/<%= p.slug %>"
|
|---|
| 78 | hx-get="/user/<%= p.site_slug %>/<%= p.slug %>?partial=1" hx-target="#pcms-main" hx-swap="innerHTML"
|
|---|
| 79 | hx-push-url="/user/<%= p.site_slug %>/<%= p.slug %>" hx-indicator="#pcms-loading">
|
|---|
| 80 | <% if (p.cover_image_url) { %>
|
|---|
| 81 | <span class="feed-cover" style="background-image:url('<%= p.cover_image_url %>')"></span>
|
|---|
| 82 | <% } %>
|
|---|
| 83 | <span class="feed-body">
|
|---|
| 84 | <span class="feed-meta"><%= p.site_title %> · <%= formatDate(p.published_at || p.created_at) %></span>
|
|---|
| 85 | <span class="feed-title"><%= p.title %></span>
|
|---|
| 86 | <% if (p.excerpt) { %><span class="feed-excerpt"><%= p.excerpt %></span><% } %>
|
|---|
| 87 | </span>
|
|---|
| 88 | <span class="feed-arrow" aria-hidden="true">→</span>
|
|---|
| 89 | </a>
|
|---|
| 90 | <% }); %>
|
|---|
| 91 | </div>
|
|---|
| 92 | </section>
|
|---|
| 93 | <% } %>
|
|---|
| 94 |
|
|---|
| 95 | </div>
|
|---|
| 96 | </div>
|
|---|
| 97 |
|
|---|
| 98 | <style>
|
|---|
| 99 | .hub { width: 100%; position: relative; }
|
|---|
| 100 |
|
|---|
| 101 | /* Hero connects directly to the mini topnav bar — no gap above the
|
|---|
| 102 | hub home (overrides the global main-padding-top). */
|
|---|
| 103 | .pcms-main { padding-top: 0; }
|
|---|
| 104 | .hub-hero { margin-top: 0; }
|
|---|
| 105 |
|
|---|
| 106 | /* ── Hero ─────────────────────────────────────────────────────────── */
|
|---|
| 107 | .hub-hero {
|
|---|
| 108 | display: flex; align-items: center; justify-content: center;
|
|---|
| 109 | min-height: clamp(340px, 58vh, 560px);
|
|---|
| 110 | text-align: center;
|
|---|
| 111 | background:
|
|---|
| 112 | radial-gradient(130% 130% at 50% -10%, color-mix(in srgb, var(--accent) 26%, var(--paper)) 0%, var(--paper) 62%);
|
|---|
| 113 | border-bottom: 1px solid var(--rule);
|
|---|
| 114 | }
|
|---|
| 115 | .hub-hero.has-img {
|
|---|
| 116 | background:
|
|---|
| 117 | linear-gradient(rgba(0,0,0,var(--hero-ov,.45)), rgba(0,0,0,var(--hero-ov,.45))),
|
|---|
| 118 | var(--hero-img) center / cover no-repeat;
|
|---|
| 119 | border-bottom: 0;
|
|---|
| 120 | color: #fff;
|
|---|
| 121 | }
|
|---|
| 122 | .hub-hero-inner { padding: 3.5rem 1rem; }
|
|---|
| 123 | .hub-hero-title {
|
|---|
| 124 | font-family: var(--font-display, serif);
|
|---|
| 125 | font-size: clamp(2.6rem, 7vw, 4.4rem);
|
|---|
| 126 | line-height: 1.02; margin: 0; letter-spacing: -0.015em;
|
|---|
| 127 | }
|
|---|
| 128 | .hub-hero-tag {
|
|---|
| 129 | margin: 0.7rem 0 0; font-size: 1.05rem; font-weight: 600;
|
|---|
| 130 | text-transform: uppercase; letter-spacing: 0.1em;
|
|---|
| 131 | color: var(--accent);
|
|---|
| 132 | }
|
|---|
| 133 | .hub-hero.has-img .hub-hero-tag { color: #fff; opacity: 0.92; }
|
|---|
| 134 | .hub-hero-desc {
|
|---|
| 135 | margin: 1.1rem auto 0; max-width: 48ch;
|
|---|
| 136 | font-size: 1.1rem; line-height: 1.55; color: var(--ink-muted);
|
|---|
| 137 | }
|
|---|
| 138 | .hub-hero.has-img .hub-hero-desc { color: rgba(255,255,255,.9); }
|
|---|
| 139 |
|
|---|
| 140 | .hub-body { padding-bottom: 4.5rem; }
|
|---|
| 141 | .hub-sec { margin-top: 3rem; }
|
|---|
| 142 | .hub-sec-title {
|
|---|
| 143 | font-family: var(--font-display, serif);
|
|---|
| 144 | font-size: 1.5rem; margin: 0 0 1.2rem;
|
|---|
| 145 | display: flex; align-items: center; gap: 0.75rem;
|
|---|
| 146 | }
|
|---|
| 147 | .hub-sec-title::after { content: ''; flex: 1; height: 1px; background: var(--rule); }
|
|---|
| 148 | .hub-sec-count {
|
|---|
| 149 | font-family: var(--font-ui, system-ui); font-size: 0.8rem; font-weight: 700;
|
|---|
| 150 | color: var(--accent); background: color-mix(in srgb, var(--accent) 12%, transparent);
|
|---|
| 151 | padding: 0.1rem 0.55rem; border-radius: 99px; order: 1;
|
|---|
| 152 | }
|
|---|
| 153 | .hub-more { margin-top: 1.25rem; text-align: center; }
|
|---|
| 154 | .hub-more-link {
|
|---|
| 155 | display: inline-flex; align-items: center; gap: 0.4rem;
|
|---|
| 156 | padding: 0.6rem 1.3rem; border: 1px solid var(--rule); border-radius: 99px;
|
|---|
| 157 | background: var(--paper-2); color: var(--ink); text-decoration: none;
|
|---|
| 158 | font-weight: 600; font-size: 0.92rem; transition: border-color 140ms, background 140ms;
|
|---|
| 159 | }
|
|---|
| 160 | .hub-more-link:hover { border-color: var(--accent); background: color-mix(in srgb, var(--accent) 7%, var(--paper-2)); }
|
|---|
| 161 |
|
|---|
| 162 | /* ── Main page card (label-/primary account, separate from the artists) ── */
|
|---|
| 163 | .hub-sec-main { margin-top: 2.25rem; }
|
|---|
| 164 | .hub-main-card {
|
|---|
| 165 | display: flex; align-items: center; gap: 1.25rem;
|
|---|
| 166 | padding: 1.2rem 1.5rem;
|
|---|
| 167 | border: 1px solid color-mix(in srgb, var(--accent) 40%, var(--rule));
|
|---|
| 168 | border-radius: 18px;
|
|---|
| 169 | background: linear-gradient(120deg, color-mix(in srgb, var(--accent) 11%, var(--paper-2)) 0%, var(--paper-2) 72%);
|
|---|
| 170 | color: var(--ink); text-decoration: none;
|
|---|
| 171 | transition: border-color 140ms, transform 140ms, box-shadow 140ms;
|
|---|
| 172 | }
|
|---|
| 173 | .hub-main-card:hover {
|
|---|
| 174 | border-color: var(--accent); transform: translateY(-2px);
|
|---|
| 175 | box-shadow: 0 12px 30px -16px color-mix(in srgb, var(--accent) 60%, transparent);
|
|---|
| 176 | }
|
|---|
| 177 | .hub-main-avatar {
|
|---|
| 178 | width: 72px; height: 72px; border-radius: 50%; flex-shrink: 0;
|
|---|
| 179 | background-size: cover; background-position: center;
|
|---|
| 180 | display: inline-flex; align-items: center; justify-content: center;
|
|---|
| 181 | font-family: var(--font-display, serif); font-size: 1.8rem; font-weight: 700; color: #fff;
|
|---|
| 182 | box-shadow: inset 0 0 0 2px rgba(255,255,255,.18);
|
|---|
| 183 | }
|
|---|
| 184 | .hub-main-info { display: flex; flex-direction: column; gap: 0.25rem; min-width: 0; flex: 1; }
|
|---|
| 185 | .hub-main-badge {
|
|---|
| 186 | align-self: flex-start; font-size: 0.65rem; font-weight: 700;
|
|---|
| 187 | text-transform: uppercase; letter-spacing: 0.08em;
|
|---|
| 188 | color: var(--accent); background: color-mix(in srgb, var(--accent) 14%, transparent);
|
|---|
| 189 | padding: 0.12rem 0.55rem; border-radius: 99px;
|
|---|
| 190 | }
|
|---|
| 191 | .hub-main-name { font-family: var(--font-display, serif); font-size: 1.5rem; font-weight: 700; line-height: 1.1; }
|
|---|
| 192 | .hub-main-tag { color: var(--ink-muted); font-size: 0.9rem; }
|
|---|
| 193 | .hub-main-cta { color: var(--accent); font-weight: 600; font-size: 0.9rem; white-space: nowrap; flex-shrink: 0; }
|
|---|
| 194 | @media (max-width: 560px) {
|
|---|
| 195 | .hub-main-card { flex-direction: column; text-align: center; }
|
|---|
| 196 | .hub-main-info { align-items: center; }
|
|---|
| 197 | .hub-main-badge { align-self: center; }
|
|---|
| 198 | .hub-main-cta { display: none; }
|
|---|
| 199 | }
|
|---|
| 200 |
|
|---|
| 201 | /* ── Roster (artists) ───────────────────────────────────────────── */
|
|---|
| 202 | .roster {
|
|---|
| 203 | display: grid;
|
|---|
| 204 | grid-template-columns: repeat(auto-fill, minmax(190px, 1fr));
|
|---|
| 205 | gap: 1rem;
|
|---|
| 206 | }
|
|---|
| 207 | .roster-card {
|
|---|
| 208 | display: flex; flex-direction: column; align-items: center; text-align: center;
|
|---|
| 209 | gap: 0.4rem; padding: 1.6rem 1rem 1.3rem;
|
|---|
| 210 | border: 1px solid var(--rule); border-radius: 16px;
|
|---|
| 211 | background: var(--paper-2); color: var(--ink); text-decoration: none;
|
|---|
| 212 | transition: border-color 140ms, transform 140ms, box-shadow 140ms;
|
|---|
| 213 | }
|
|---|
| 214 | .roster-card:hover {
|
|---|
| 215 | border-color: var(--accent); transform: translateY(-3px);
|
|---|
| 216 | box-shadow: 0 10px 28px -14px color-mix(in srgb, var(--accent) 55%, transparent);
|
|---|
| 217 | }
|
|---|
| 218 | .roster-avatar {
|
|---|
| 219 | width: 88px; height: 88px; border-radius: 50%; margin-bottom: 0.45rem;
|
|---|
| 220 | background-size: cover; background-position: center;
|
|---|
| 221 | display: inline-flex; align-items: center; justify-content: center;
|
|---|
| 222 | font-family: var(--font-display, serif); font-size: 2.1rem; font-weight: 700; color: #fff;
|
|---|
| 223 | box-shadow: inset 0 0 0 2px rgba(255,255,255,.18);
|
|---|
| 224 | }
|
|---|
| 225 | .roster-name { font-weight: 700; font-size: 1.1rem; }
|
|---|
| 226 | .roster-tag { color: var(--ink-muted); font-size: 0.82rem; }
|
|---|
| 227 | .roster-count {
|
|---|
| 228 | margin-top: 0.35rem; font-size: 0.72rem; text-transform: uppercase; letter-spacing: 0.06em;
|
|---|
| 229 | color: var(--accent); background: color-mix(in srgb, var(--accent) 12%, transparent);
|
|---|
| 230 | padding: 0.15rem 0.6rem; border-radius: 99px;
|
|---|
| 231 | }
|
|---|
| 232 |
|
|---|
| 233 | /* ── Feed (latest posts) ─────────────────────────────────────────── */
|
|---|
| 234 | .hub-feed { display: flex; flex-direction: column; gap: 0.6rem; }
|
|---|
| 235 | .feed-item {
|
|---|
| 236 | display: flex; align-items: center; gap: 1rem;
|
|---|
| 237 | padding: 0.9rem 1rem; border: 1px solid var(--rule); border-radius: 12px;
|
|---|
| 238 | background: var(--paper-2); color: var(--ink); text-decoration: none;
|
|---|
| 239 | transition: border-color 140ms, background 140ms;
|
|---|
| 240 | }
|
|---|
| 241 | .feed-item:hover { border-color: var(--accent); background: color-mix(in srgb, var(--accent) 5%, var(--paper-2)); }
|
|---|
| 242 | .feed-cover {
|
|---|
| 243 | width: 64px; height: 64px; border-radius: 8px; flex-shrink: 0;
|
|---|
| 244 | background-size: cover; background-position: center; background-color: var(--paper);
|
|---|
| 245 | }
|
|---|
| 246 | .feed-body { display: flex; flex-direction: column; gap: 0.2rem; min-width: 0; flex: 1; }
|
|---|
| 247 | .feed-meta { font-size: 0.76rem; text-transform: uppercase; letter-spacing: 0.05em; color: var(--accent); }
|
|---|
| 248 | .feed-title { font-weight: 600; font-size: 1.05rem; line-height: 1.25; }
|
|---|
| 249 | .feed-excerpt {
|
|---|
| 250 | color: var(--ink-muted); font-size: 0.88rem; line-height: 1.4;
|
|---|
| 251 | display: -webkit-box; -webkit-line-clamp: 1; -webkit-box-orient: vertical; overflow: hidden;
|
|---|
| 252 | }
|
|---|
| 253 | .feed-arrow { color: var(--ink-muted); font-size: 1.2rem; flex-shrink: 0; transition: transform 140ms, color 140ms; }
|
|---|
| 254 | .feed-item:hover .feed-arrow { color: var(--accent); transform: translateX(3px); }
|
|---|
| 255 |
|
|---|
| 256 | @media (max-width: 560px) {
|
|---|
| 257 | .hub-hero-inner { padding: 2.5rem 1rem; }
|
|---|
| 258 | .feed-cover { width: 52px; height: 52px; }
|
|---|
| 259 | .feed-arrow { display: none; }
|
|---|
| 260 | }
|
|---|
| 261 | </style>
|
|---|