Template:Chord: Difference between revisions

From Puella Magi Wiki
Jump to navigation Jump to search
No edit summary
No edit summary
Line 10: Line 10:
* The first parameter is the text. The second parameter is the chord.
* The first parameter is the text. The second parameter is the chord.
* It will automatically convert <tt>b</tt> to ♭ and <tt>#</tt> to ♯ for you.
* It will automatically convert <tt>b</tt> to ♭ and <tt>#</tt> to ♯ for you.
* If several longer chords are placed close together, they will overlap, so avoid this.
* If several longer chords are placed close together, they will overlap.
* If you need to avoid this, you can specify the optional '''width''' parameter, which reserves space for a specified number of letters.
</noinclude><includeonly><templatestyles
</noinclude><includeonly><templatestyles
src="Chord/styles.css"
src="Chord/styles.css"
/><span
/><span
{{#if:{{{width|}}}|style="display: inline-block; width:{{{width}}}ch"}}
data-chord="{{#replace:{{#replace:{{{2}}}|b|♭}}|#|♯}}">{{{1}}}</span></includeonly>
data-chord="{{#replace:{{#replace:{{{2}}}|b|♭}}|#|♯}}">{{{1}}}</span></includeonly>

Revision as of 06:38, 23 February 2024

Use this template to place a chord above a line of text. Usage example:

"Sore ja {{chord|ma|F}}ta ne" tte te o {{chord|fu|A}}tte

"Sore ja mata ne" tte te o futte

Notes:

  • Generally the template should enclose a single syllable or mora.
  • The first parameter is the text. The second parameter is the chord.
  • It will automatically convert b to ♭ and # to ♯ for you.
  • If several longer chords are placed close together, they will overlap.
  • If you need to avoid this, you can specify the optional width parameter, which reserves space for a specified number of letters.