Changeset 0091cb7 in Klonkt
- Timestamp:
- 06/16/2026 12:59:24 AM (3 months ago)
- Branches:
- main
- Children:
- efdde37
- Parents:
- 25d4041
- Location:
- src
- Files:
-
- 4 added
- 5 edited
-
config/database.js (modified) (1 diff)
-
routes/admin-circle.js (added)
-
routes/admin-settings.js (modified) (1 diff)
-
routes/circle.js (added)
-
server.js (modified) (3 diffs)
-
services/CircleFederation.js (modified) (1 diff)
-
views/pages/admin-circle.ejs (added)
-
views/pages/admin-settings.ejs (modified) (2 diffs)
-
views/pages/circle-feed.ejs (added)
Legend:
- Unmodified
- Added
- Removed
-
src/config/database.js
r25d4041 r0091cb7 47 47 // Per-site Prutter toggle: when off, DM endpoints/UI are hidden for that site. 48 48 ensureColumn('sites', 'enable_prutter', 'INTEGER DEFAULT 1'); 49 // Cirkels: mag deze site in cirkels van anderen verschijnen (surfacing opt-out). 50 ensureColumn('sites', 'allow_circle', 'INTEGER DEFAULT 1'); 49 51 50 52 // v9 audit additions ————————————————————————————————————————— -
src/routes/admin-settings.js
r25d4041 r0091cb7 33 33 router.post('/', requireGod, (req, res) => { 34 34 if (typeof req.body.tenancy !== 'undefined') { 35 setTenancy(req.body.tenancy === 'hub' ? 'hub' : 'solo');35 setTenancy(req.body.tenancy); // valideert naar solo | hub | circle 36 36 } 37 37 if (typeof req.body.hub_title !== 'undefined') { -
src/server.js
r25d4041 r0091cb7 45 45 import federationRoutes from './routes/federation.js'; 46 46 import { startCircleSyncLoop } from './services/CircleService.js'; 47 import adminCircleRoutes from './routes/admin-circle.js'; 48 import circleRoutes from './routes/circle.js'; 47 49 48 50 if (!process.env.SESSION_SECRET) { … … 225 227 app.use('/admin/comments', adminCommentsRoutes); 226 228 app.use('/admin/settings', adminSettingsRoutes); 229 app.use('/admin/circle', adminCircleRoutes); 227 230 app.use('/admin', adminRoutes); 228 231 app.use('/prutter', prutterRoutes); … … 238 241 app.get('/artiesten', (req, res) => res.redirect(301, req.originalUrl.replace(/^\/artiesten/, '/leden'))); // oude URL -> /leden 239 242 app.use('/', hubRoutes); // hub-overview op '/' (solo: next() -> postsRoutes) 243 app.use('/', circleRoutes); // /cirkel-feed (solo/hub: next() -> postsRoutes) 240 244 app.use('/', postsRoutes); 241 245 -
src/services/CircleFederation.js
r25d4041 r0091cb7 74 74 // aan is_public (aparte expliciete flag volgt in de Beheer-UX-stap). 75 75 function allowsCircle(site) { 76 return !!site && site.is_public !== 0 ;76 return !!site && site.is_public !== 0 && site.allow_circle !== 0; 77 77 } 78 78 -
src/views/pages/admin-settings.ejs
r25d4041 r0091cb7 25 25 <strong>Hub</strong> — bedrijfssite met <code>/user/</code>. 26 26 <small>Jij (admin) wijst gebruikers een eigen Klonkt Hub toe. Gesloten cirkel: geen open registratie.</small> 27 </span> 28 </label> 29 <label class="set-opt"> 30 <input type="radio" name="tenancy" value="circle" <%= tenancy === 'circle' ? 'checked' : '' %>> 31 <span> 32 <strong>Cirkels</strong> — solo + federatie. 33 <small>Eén eigen site die de publieke posts van andere Klonkt-sites toont. Asymmetrisch: jij bepaalt wie in jouw cirkel zit.</small> 27 34 </span> 28 35 </label> … … 59 66 </section> 60 67 <% } %> 68 69 <% if (tenancy === 'circle') { %> 70 <section class="set-card" style="margin-top:1rem"> 71 <h2>Cirkel</h2> 72 <p class="set-help"> 73 Beheer welke andere Klonkt-sites je in je cirkel toont, en of jouw site in 74 cirkels van anderen mag verschijnen. 75 </p> 76 <p><a href="/admin/circle" class="btn btn-primary">Beheer je cirkel →</a></p> 77 </section> 78 <% } %> 61 79 </div> 62 80
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)