Starting rehype rework.

This commit is contained in:
Benjamin A. Shelton 2026-06-29 16:13:41 -06:00
commit 4324ad3443
Signed by: zancarius
GPG key ID: 8BD42DBD6C337E01

View file

@ -9,6 +9,7 @@ export const ScriptureLinks = () => {
let isQuote = false; let isQuote = false;
let isCite = false; let isCite = false;
let tag = ''; let tag = '';
let rest = '';
const url = node.properties.href; const url = node.properties.href;
if (node.tagName !== 'a') { if (node.tagName !== 'a') {
return; return;
@ -17,12 +18,26 @@ export const ScriptureLinks = () => {
return; return;
} }
if (url.indexOf('=') != -1) { if (url.indexOf('=') != -1) {
tag = url.substring(0, url.indexOf('='));
rest = url.substring(url.indexOf('='));
} else { } else {
tag = url.substring(1); tag = url.substring(1);
} }
switch (tag) {
// Scripture reference.
case 'scripture':
break;
// Quoting Jesus' words.
case 'jesus':
break;
// Bible quote.
case 'quote':
break;
// Source citation.
case 'cite':
break;
}
if (!url.startsWith(':scripture')) { if (!url.startsWith(':scripture')) {