Documentation for සැකිල්ල:ja-r. [edit]
This page contains usage information, categories, interwiki links and other content describing the template.

This is a wrapper for {{l}} that does two things:

  1. automatic romanization (which is italicized here and put in l's tr parameter)
  2. placing of furigana aka ruby over the linked term (the term with furigana is put in l's third unnamed parameter)

The "r" stands for "ruby". This template generates content using the modules Module:ja-link and Module:ja.

Parameters සංස්කරණය

|1=
The term itself that we want to link to (which is put directly into l's second unnamed parameter)
|2= (if the first term contains non-kana characters)
The term written entirely in kana with regular ASCII spaces between words (so that there will be spaces in the romanization, not relevant to the placing of furigana)
|3= or |gloss= (optional)
Same as the gloss field of l.
|lit=
Literal meaning.
|pos=
Part of speech.
|linkto= (optional)
Make the link point to this. Useful for -na adjectives or suru verbs where you want the link to point to the lemma but be displayed as the form plus suru or -na, e.g. 入手(にゅうしゅ)する (nyūshu suru) which displays 入手する with ruby but points to 入手.
|caps= (optional)
set to any value to capitalize the first letters of each word (for proper nouns)
|self= (optional)
if set to true, links referring to the page the link is on are displayed in bold (akin to {{l-self}} and {{m-self}})
|rom=
Override the romaji. It can be set to - to disable romaji
|hist=
Use "romaji for the historical kana orthography", e.g. ()はる (wofaru).

For example, Lua දෝෂය in Module:table at line 557: attempt to call upvalue 'string_sort' (a nil value). produces (さる)()から()ちる (saru mo ki kara ochiru).

Ruby and transliteration සංස්කරණය

The following description applies to {{ja-r}}, {{ja-usex}}, {{ja-compound}} and all Japanese header templates.

Transliteration format සංස්කරණය

  • Use a period (full stop) between two kana to force a two consecutive vowels to be transliterated separately rather than as a long vowel.
    Lua දෝෂය in Module:table at line 557: attempt to call upvalue 'string_sort' (a nil value).(うらや)ましい (urayamashī)
    Lua දෝෂය in Module:table at line 557: attempt to call upvalue 'string_sort' (a nil value).(うらや)ましい (urayamashii)
  • Spaces and hyphens in the kana text will appear in the transliteration as they are.
    Lua දෝෂය in Module:table at line 557: attempt to call upvalue 'string_sort' (a nil value).()(はい) (te ni hairu)
    Lua දෝෂය in Module:table at line 557: attempt to call upvalue 'string_sort' (a nil value).理想的(りそうてき) (risō-teki)
  • A caret ^ capitalizes the following letter.
    Lua දෝෂය in Module:table at line 557: attempt to call upvalue 'string_sort' (a nil value).任天堂(ニンテンドー) (Nintendō)

Dividing kana between kanji සංස්කරණය

In certain cases, a manual division of kana between kanji is desired.

In such cases, use a percent sign (%) in both the kanji and kana parameters to determine which kana go above which kanji:

  • Lua දෝෂය in Module:table at line 557: attempt to call upvalue 'string_sort' (a nil value).平仮名(ひらがな) (hiragana)
  • Lua දෝෂය in Module:table at line 557: attempt to call upvalue 'string_sort' (a nil value). or Lua දෝෂය in Module:table at line 557: attempt to call upvalue 'string_sort' (a nil value).(ひら)仮名(がな) (hiragana)

Spaces can also be used, if the corresponding kana contains a space:

  • Lua දෝෂය in Module:table at line 557: attempt to call upvalue 'string_sort' (a nil value).

    酒飲(さけの)みに()かない?
    Sake nomi ni ikanai?
    Why not go for a drink?
  • Lua දෝෂය in Module:table at line 557: attempt to call upvalue 'string_sort' (a nil value).

    (さけ)()みに()かない?
    Sake nomi ni ikanai?
    Why not go for a drink?

The automatic placement of ruby fails in rare cases, for instance when the same kana occurs in both the parameter containing kanji and the parameter containing kana, and the parameter containing kana has two instances of this kana. (Below, the kana in question is .)

Use spaces or percent signs to prevent this. For example:

Special characters සංස්කරණය

Symbol Name Effect Position
 
Space Add space Kana-reading parameter, sometimes original-form parameter
-
Hyphen Add hyphen Kana-reading parameter only
.
Full stop Stop long vowel detection on this point Kana-reading parameter only
^
Caret Capitalise words Kana-reading parameter only
%
Percent sign Separate ruby above a word Original-form parameter and kana-reading parameter, corresponding needed


TemplateData සංස්කරණය

This is the TemplateData documentation for this template used by VisualEditor and other tools.

TemplateData for ja-r

Creates a link to a kanji/kana term with automatic romanization and placing ruby text (furigana) above the kanji

Template parameters[Edit template data]

This template prefers inline formatting of parameters.

ParameterDescriptionTypeStatus
kanji/kana1

The term itself that we want to link to (which is put directly into l's second unnamed parameter)

Example
寿司
Page namerequired
kana term2

no description

Example
すし
Lineoptional
gloss3 gloss

no description

Example
sushi
Lineoptional
literal meaninglit

no description

Example
sour rice
Lineoptional
part of speechpos

no description

Example
noun
Lineoptional
"https://si.wiktionary.org/w/index.php?title=සැකිල්ල:ja-r/documentation&oldid=41430" වෙතින් සම්ප්‍රවේශනය කෙරිණි