I posted on Mastodon asking for guidance on doing a thing I was trying to do and got some helpful answers from @senders@tech.lgbt and @theo@soc.webair.xyz. The former linked me some Javascript documentation that I was able to use to almost do the thing, and I’m sure I would have had it eventually… until the latter showed up with a fully working piece of code that just did what I needed super simply.
Here it is, for Future Me’s reference, and also anyone else who might need it:
<form class="pronouns">
Azem’s pronouns:
<br>
<input type="radio" name="p" id="p1" onclick="changePronouns('they', 'They', 'them', 'are')" />
<label for="p1">They/Them</label>
<br>
<input type="radio" name="p" id="p2" onclick="changePronouns('she', 'She', 'her', 'is')" />
<label for="p2">She/Her</label>
<br>
<input type="radio" name="p" id="p3" onclick="changePronouns('he', 'He', 'him', 'is')" />
<label for="p3">He/Him</label>
<br>
</form>
<script>
function changePronouns(subject, subjCap, possessive, are){
let els = document.getElementsByClassName("subject");
for (let i=0; i < els.length; i++){
els[i].textContent=subject;
}
els = document.getElementsByClassName("object");
for (let i=0; i < els.length; i++){
els[i].textContent=object;
}
els = document.getElementsByClassName("subjCap");
for (let i=0; i < els.length; i++){
els[i].textContent=subjCap;
}
els = document.getElementsByClassName("are");
for (let i=0; i < els.length; i++){
els[i].textContent=arent;
}
}
</script>
<span class="subjCap">They</span> <span class="are">are</span> an absolute nuisance, but he loves <span class="object">them</span> anyway.
The fic in question is stacked to the heavens where our sins took root, in which I put to paper my own guess of how the Zodiark summoning went.