const refNum = index + 1;
const refText = cite.getAttribute('ref') || cite.innerHTML;
- // Transform the inline tag into a superscript link
- cite.innerHTML = `<sup><a href="#note-${refNum}" id="cite-${refNum}">[${refNum}]</a></sup>`;
+ cite.innerHTML = `<a href="#note-${refNum}" id="cite-${refNum}">[${refNum}]</a>`;
cite.style.cursor = 'pointer';
cite.style.color = 'var(--rt-brand-link)';
cite.style.textDecoration = 'none';
s.setProperty(`--rt-${key.replace(/_/g, '-')}`, value);
}
+
// 3. Global Overrides
const style_id = 'rt-global-overrides';
if (!document.getElementById(style_id)) {
border-radius: 8px;
}
::-webkit-scrollbar-thumb:hover { background: var(--rt-brand-secondary); }
+
+ /* --- Citation & Endnote Styling --- */
+ rt-cite a, .rt-inline-cite a, rt-endnotes a {
+ color: var(--rt-brand-link);
+ text-decoration: none;
+ }
+ rt-cite a:hover, .rt-inline-cite a:hover, rt-endnotes a:hover {
+ text-decoration: underline;
+ }
+ rt-cite, .rt-inline-cite {
+ font-size: 1em;
+ vertical-align: baseline;
+ padding: 0 0.15em;
+ }
+
+ /* --- Image Inversion for Diagrams --- */
+ img.rt-diagram {
+ filter: invert(1) hue-rotate(180deg);
+ }
`;
+
document.head.appendChild(style);
}
};