Changeset 62b899d in Klonkt for src/services


Ignore:
Timestamp:
06/16/2026 07:02:15 PM (3 months ago)
Author:
roboburr <roboburr@…>
Branches:
main
Children:
fb02cc0
Parents:
682d504
Message:

Circle: strip shortcodes from summary + "Sync all now" button

[[playlist:..]]/[[track:..]]/[[album:..]]-shortcodes survived stripHtml (not
HTML) → appeared raw in the circle summary (buggy). Now stripped on ingest
(consumer) and on publish. Also added a global sync button on
Admin → Circle.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@…>

Location:
src/services
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • src/services/CircleFederation.js

    r682d504 r62b899d  
    7878
    7979function stripHtml(s) {
    80   return String(s || '').replace(/<[^>]+>/g, ' ').replace(/\s+/g, ' ').trim();
     80  return String(s || '')
     81    .replace(/<[^>]+>/g, ' ')
     82    .replace(/\[\[[^\]]*\]\]/g, ' ')   // [[playlist:..]]/[[track:..]]/[[album:..]]-shortcodes weg
     83    .replace(/\s+/g, ' ')
     84    .trim();
    8185}
    8286
  • src/services/CircleService.js

    r682d504 r62b899d  
    1414
    1515function stripHtml(s) {
    16   return String(s || '').replace(/<[^>]+>/g, ' ').replace(/\s+/g, ' ').trim();
     16  return String(s || '')
     17    .replace(/<[^>]+>/g, ' ')
     18    .replace(/\[\[[^\]]*\]\]/g, ' ')   // [[playlist:..]]/[[track:..]]/[[album:..]]-shortcodes weg
     19    .replace(/\s+/g, ' ')
     20    .trim();
    1721}
    1822function iso(d) {
Note: See TracChangeset for help on using the changeset viewer.