Toggle display/edit of inline footnotes
Posted: Thu Apr 04, 2019 11:14 pm
I've been tasked with an implementation challenge and I'd appreciate any suggestions. In a future specification of our content model, footnotes will be placed inline, at the point of reference, within the text. The footnotes in this code is the lds:footnote elements (there are two):
In Author, by default I need to suppress display of these footnotes to allow for normal proofing/editing of the main body of content. I also need to provide users a way to toggle display of the footnotes so they can be individually edited. Ideally, this toggle would be accomplished with some sort of button or link icon, rather than toggling activation of alternate CSS using the Styles menu. This solution would be needed in both Web Author and standalone XML Editor applications.
Interestingly, the footnotes are in a paragraph (html5 p element), and each footnote itself contains one or more paragraphs (bound to a proprietary namespace implementation).
Any suggestions for the best way to handle this? I don't need actual code, but rather some direction as to what part of the Author API might be best to extend.
Thanks,
Jeff
Code: Select all
<test>
<p>Another paragraph</p>
<p id="89e3951b-6739-4bab-a0d7-61930eab9ec7">Today I feel compelled to discuss with you a matter of great importance. Some weeks ago, I released a statement regarding a course correction for the name of the Church.<lds:footnote lds:id="9ae0ed0a-1ef1-440c-9924-21cba0017aa6"><lds:p lds:id="236a3dd9-1766-4a1b-9969-78b63d1c005a">“The Lord has impressed upon my mind the importance of the name He has revealed for His Church, even The Church of Jesus Christ of Latter-day Saints. We have work before us to bring ourselves in harmony with His will. In recent weeks, various Church leaders and departments have initiated the necessary steps to do so. Additional information about this important matter will be made available in the coming months” (Russell M. Nelson, in “<lds:a href="https://www.mormonnewsroom.org/article/name-of-the-church">The Name of the Church</lds:a>” [official statement, Aug. 16, 2018], mormonnewsroom.org).</lds:p></lds:footnote> I did this because the Lord impressed upon my mind the importance of the name He decreed for His Church, even The Church of Jesus Christ of Latter-day Saints.<lds:footnote lds:id="b1067924-aa2f-4680-b9bb-ed62ce70100b"><lds:p lds:id="945ca76c-8513-45bc-8274-ba7b5d2e3d5c">Preceding Presidents of the Church have made similar requests. For example, President George Albert Smith said: “Don’t let the Lord down by calling this the Mormon Church. He didn’t call it the Mormon Church” (in Conference Report, Apr. 1948, 160).</lds:p></lds:footnote></p>
<p>Another paragraph</p>
</test>
Interestingly, the footnotes are in a paragraph (html5 p element), and each footnote itself contains one or more paragraphs (bound to a proprietary namespace implementation).
Any suggestions for the best way to handle this? I don't need actual code, but rather some direction as to what part of the Author API might be best to extend.
Thanks,
Jeff