Skip to content

TokenizedText

Renders stitched JapaneseWords as clickable tokens with optional furigana. Shared by the text analyzer, subtitle player, and transcribe chat. Font size + color are inherited from the parent (so the subtitle style settings apply); the interaction accent is the theme's vermilion. No blanket underline — affordance is a subtle hover highlight.

Interfaces

TokenizedTextProps

Defined in: src/shared/components/TokenizedText.tsx:13

Properties

Property Type Defined in
onWordClick (sentence, word) => void src/shared/components/TokenizedText.tsx:17
selectedLemma? string | null src/shared/components/TokenizedText.tsx:18
sentence string src/shared/components/TokenizedText.tsx:15
showFurigana boolean src/shared/components/TokenizedText.tsx:16
words JapaneseWord[] src/shared/components/TokenizedText.tsx:14

Functions

TokenizedText()

function TokenizedText(props): Element;

Defined in: src/shared/components/TokenizedText.tsx:27

The TokenizedText component.

Parameters

Parameter Type Description
props TokenizedTextProps The props.

Returns

Element

The clickable tokens.