Template:TTS/aural: Difference between revisions
Appearance
m tts parameter |
use rp/rt |
||
| Line 1: | Line 1: | ||
{{HueCSS}}<!-- | {{HueCSS}}<!-- | ||
--><includeonly><onlyinclude>{{#if:{{{t1|}}}|<span aria-hidden="true">{{{t1|}}}</span>}}<{{{html| | --><includeonly><onlyinclude>{{#if:{{{t1|}}}|<span aria-hidden="true">{{{t1|}}}</span>}}<{{{html|ruby}}} {{#if:{{{lang|}}}|lang="{{{lang}}}"|}} class="tts {{{class|}}}" {{#switch: {{{NoTitle|}}}|y = title{{=}}""|{{{tts|}}}{{{2|}}}{{{title|}}} = title{{=}}""|{{{tts|}}}{{{title|}}} = title{{=}}"{{{2|}}}"|{{{2|}}}{{{title|}}} = title{{=}}"{{{tts|}}}"|#default = title{{=}}"{{{title|}}}"}}data-arg1="{{{1|}}}" data-arg1="{{{2|}}}" data-tts="{{{tts|}}}">{{#if:{{{tts|}}}{{{2|}}} | <span class="visual" aria-hidden="true">{{{1}}}</span><rp class="bracket" aria-hidden="true"> (</rp><rp class="help">pronounced </rp><rt {{#switch: {{{ParameterWhichShouldAlwaysBeEmpty|}}} | {{{lang2|}}}{{{lang|}}} = data-lang{{=}}"" | {{{lang|}}} = data-lang{{=}}"{{{lang2}}}" | {{{lang2|}}} = data-lang{{=}}"{{{lang}}}" | #default = data-lang{{=}}"" }} class="aural">{{#switch: {{{ParameterWhichShouldAlwaysBeEmpty|}}} | {{{tts|}}}{{{2|}}} = {{{1|error: TTS pronunciation missing}}} | {{{tts|}}} = {{{2|error: TTS pronunciation missing}}} | {{{2|}}} = {{{tts|error: TTS pronunciation missing}}} }}</rt><rp class="bracket" aria-hidden="true">)</rp> | {{{1|}}} }}</{{{html|span}}}>{{#if:{{{t3|}}}|<span aria-hidden="true">{{{t3|}}}</span>}}</onlyinclude></includeonly><!-- | ||
Put visually clearer version below for debug purposes: | Put visually clearer version below for debug purposes: | ||
{{#if:{{{t1|}}}|<span aria-hidden="true">{{{t1|}}}</span>}} | {{#if:{{{t1|}}}|<span aria-hidden="true">{{{t1|}}}</span>}} | ||
<{{{html| | <{{{html|ruby}}}_ | ||
{{#if:{{{lang|}}}|lang="{{{lang}}}"|}}_ | {{#if:{{{lang|}}}|lang="{{{lang}}}"|}}_ | ||
class="tts {{{class|}}}"_ | class="tts {{{class|}}}"_ | ||
| Line 17: | Line 17: | ||
{{#if:{{{tts|}}}{{{2|}}} | {{#if:{{{tts|}}}{{{2|}}} | ||
| <span class="visual" aria-hidden="true">{{{1}}}</span> | | <span class="visual" aria-hidden="true">{{{1}}}</span> | ||
< | <rp class="bracket" aria-hidden="true"> (</rp> | ||
< | <rp class="help">pronounced </rp> | ||
< | <rt | ||
{{#switch: {{{ParameterWhichShouldAlwaysBeEmpty|}}} | {{#switch: {{{ParameterWhichShouldAlwaysBeEmpty|}}} | ||
| {{{lang2|}}}{{{lang|}}} = data-lang{{=}}"" | | {{{lang2|}}}{{{lang|}}} = data-lang{{=}}"" | ||
| Line 32: | Line 32: | ||
| {{{2|}}} = {{{tts|error: TTS pronunciation missing}}}_ | | {{{2|}}} = {{{tts|error: TTS pronunciation missing}}}_ | ||
}} | }} | ||
</ | </rt> | ||
< | <rp class="bracket" aria-hidden="true">)</rp> | ||
| {{{1|}}} | | {{{1|}}} | ||
}} | }} | ||
Revision as of 13:42, 2 December 2025
Demo
oddly-pronounced word demo:
using this template just for an HTML tag: ordinary phrase
number list
Description
This is a template for giving bits of text a TTS pronunciation.
This page is the main "guts" of Template:TTS, which needed to be broken up to properly create linking capabilities.