Scripture App Builder (SAB) allows custom styling (non-USFM) tags in wordlist entry (\w ... \w+). We have a project with data like* this:
\c 1
\q1 \k serpent \k* snake
\q1 \k subtle \k* crafty, or smart; commonly used to describe \w \+lw serpents \+lw* |lemma="serpent" \w*
\q1 \k \lw eternal\lw* life\k* life with no end
For the Scripture Progressive Web App, we use Proskomma, which is designed to be a strict USFM parser. When SAB allows non-USFM tags (e.g. `\zvideo ID`), we normally have to convert these to a milestone (e.g. `\zvideo-s |id="ID"\*\zvideo-e\*`).
Are milestones allowed inside a wordlist entry? Can we convert the above USFM to:
\c 1
\q1 \k serpent \k* snake
\q1 \k subtle \k* crafty, or smart; commonly used to describe \w \+zwrapper-s |id="lw"\* serpents \+zwrapper-e\* |lemma="serpent" \w*
\q1 \k \zwrapper-s |id="lw"\* eternal\zwrapper-e\* life\k* life with no end
And then we can convert this to HTML when we present it.
Thanks,
Chris
*We fabricated the english based on minority language entries for demonstration purposes.
Explanation: The reason why these `\lw` markers are there is to "wrap words in non-breaking format markers". SAB supports changes and there is an entry for:
find: ([\u1780-\u17dd“”‘’«»!?()\[\]]+)([ ,\u2002])(?!\d)
replace: \\lw \1\\lw*\2
This end up with `<span class="lw">SOME WORDS</span> around these words (with the css `.lw { white-space: nowrap; }` ).