Changeset 22d2f5a8 in Klonkt
- Timestamp:
- 07/20/2026 07:35:55 AM (7 weeks ago)
- Branches:
- main
- Children:
- 9209cfa
- Parents:
- 520e477
- git-author:
- Robin <roboburr@…> (07/20/2026 07:31:47 AM)
- git-committer:
- Robin <roboburr@…> (07/20/2026 07:35:55 AM)
- File:
-
- 1 edited
-
src/views/pages/post.ejs (modified) (3 diffs)
Legend:
- Unmodified
- Added
- Removed
-
src/views/pages/post.ejs
r520e477 r22d2f5a8 86 86 <div class="post-share" style="margin:1.25rem 0;display:flex;align-items:center;gap:.6rem;flex-wrap:wrap"> 87 87 <button type="button" class="btn post-share-btn" data-share data-share-title="<%= post.title %>">🔗 <%= t('post.share') %></button> 88 <%# Interact via the fediverse — for VISITORS (reply/like/boost from their own 89 server). Same flow as the CTA in the fediverse section; hidden for the 90 owner/admin (their own post) and when AP is off. %> 91 <% if (post.status === 'published' && (typeof apEnabled === 'undefined' || apEnabled) && (typeof canManageSite === 'undefined' || !canManageSite)) { %> 92 <% var _shareAbsUrl = (typeof ogOrigin !== 'undefined' && ogOrigin ? ogOrigin : '') + (typeof _base !== 'undefined' && _base ? _base : '') + '/' + post.slug; %> 93 <button type="button" class="btn fedi-remote-reply-btn" data-fedi-uri="<%= _shareAbsUrl %>" data-fedi-ph="<%= t('fedi.remote_ph') %>"> 94 <svg viewBox="0 0 24 24" width="16" height="16" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" aria-hidden="true"><polyline points="17 1 21 5 17 9"/><path d="M3 11V9a4 4 0 0 1 4-4h14"/><polyline points="7 23 3 19 7 15"/><path d="M21 13v2a4 4 0 0 1-4 4H3"/></svg> 95 <%= t('fedi.remote_interact') %> 96 </button> 97 <% } %> 88 98 <span class="post-share-feedback" id="post-share-feedback" style="color:var(--accent);font-size:.85rem" hidden><%= t('post.share_copied') %></span> 89 99 </div> … … 108 118 109 119 <!-- Fediverse interactions — single place: ⭐ like (clickable) + 🔁/💬 counts + reply --> 110 <% var _postAbsUrl = (typeof ogOrigin !== 'undefined' && ogOrigin ? ogOrigin : '') + (typeof _base !== 'undefined' && _base ? _base : '') + '/' + post.slug; %>111 120 <% var _fedi = (typeof fediverse !== 'undefined' && fediverse) ? fediverse : { thread: [], likeCount: 0, announceCount: 0 }; %> 112 121 <% if (post.status === 'published' && (typeof apEnabled === 'undefined' || apEnabled)) { %> … … 134 143 </ol> 135 144 <% } %> 136 <%# "Interact via the fediverse" is for VISITORS (reply from their own server). 137 The owner/admin has their own controls + it's their post → hide it for them. %> 138 <% if (typeof canManageSite === 'undefined' || !canManageSite) { %> 139 <div class="post-fediverse-cta"> 140 <button type="button" class="btn fedi-remote-reply-btn" data-fedi-uri="<%= _postAbsUrl %>" data-fedi-ph="<%= t('fedi.remote_ph') %>"> 141 <svg viewBox="0 0 24 24" width="16" height="16" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" aria-hidden="true"><polyline points="17 1 21 5 17 9"/><path d="M3 11V9a4 4 0 0 1 4-4h14"/><polyline points="7 23 3 19 7 15"/><path d="M21 13v2a4 4 0 0 1-4 4H3"/></svg> 142 <%= t('fedi.remote_interact') %> 143 </button> 144 </div> 145 <% } %> 145 <%# The "Interact via the fediverse" button for visitors now lives next to 146 the Share button at the top of the post (single, prominent place). %> 146 147 </section> 147 148 <% } %>
Note:
See TracChangeset
for help on using the changeset viewer.
![(please configure the [header_logo] section in trac.ini)](/chrome/site/your_project_logo.png)