DictDisplays
This file contains specialized components for displaying different types of dictionary data, such as JMdict entries, proper noun entries, and Kanji information.
Functions¶
ComprehensiveEntryCard()¶
Defined in: src/components/DictDisplays.tsx:155
A comprehensive card that displays multiple JMdict entries, JMnedict entries, Kanji information, and examples in a well-divided, responsive card with a tabbed interface.
Parameters¶
Parameter | Type | Description |
---|---|---|
props |
{ examples : string []; jmdictEntries : JMEntry []; jmnedictEntries : JMNEntry []; kanjiInfo : KanjiInfo []; word : string ; } |
The component props. |
props.examples |
string [] |
The example sentences. |
props.jmdictEntries |
JMEntry [] |
The standard dictionary entries. |
props.jmnedictEntries |
JMNEntry [] |
The proper noun dictionary entries. |
props.kanjiInfo |
KanjiInfo [] |
The Kanji information. |
props.word |
string |
The word that was looked up. |
Returns¶
Element
The rendered comprehensive card.
ExampleDisplay()¶
Defined in: src/components/DictDisplays.tsx:47
Displays an example sentence.
Parameters¶
Parameter | Type | Description |
---|---|---|
props |
{ example : string ; isLast : boolean ; } |
The component props. |
props.example |
string |
The example sentence text. |
props.isLast |
boolean |
True if this is the last item in a list, to omit the bottom border. |
Returns¶
Element
The rendered example.
JmdictEntryDisplay()¶
Defined in: src/components/DictDisplays.tsx:16
Displays a standard dictionary entry from JMdict.
Parameters¶
Parameter | Type | Description |
---|---|---|
props |
{ entry : JMEntry ; isLast : boolean ; } |
The component props. |
props.entry |
JMEntry |
The dictionary entry data. |
props.isLast |
boolean |
True if this is the last item in a list, to omit the bottom border. |
Returns¶
Element
The rendered JMdict entry.
JMEntryRow()¶
Defined in: src/components/DictDisplays.tsx:335
Renders a clickable row for a JMdict entry.
Parameters¶
Parameter | Type | Description |
---|---|---|
props |
{ entry : JMEntry ; onSelect : (word ) => void ; } |
The component props. |
props.entry |
JMEntry |
The JMdict entry. |
props.onSelect |
(word ) => void |
Callback for when the row is clicked. |
Returns¶
Element
The JMdict entry row component.
JmnedictEntryDisplay()¶
Defined in: src/components/DictDisplays.tsx:72
Displays a proper noun dictionary entry from JMnedict.
Parameters¶
Parameter | Type | Description |
---|---|---|
props |
{ entry : JMNEntry ; isLast : boolean ; } |
The component props. |
props.entry |
JMNEntry |
The proper noun entry data. |
props.isLast |
boolean |
True if this is the last item in a list, to omit the bottom border. |
Returns¶
Element
The rendered JMnedict entry.
KanjiInfoDisplay()¶
Defined in: src/components/DictDisplays.tsx:96
Displays detailed information about a single Kanji character.
Parameters¶
Parameter | Type | Description |
---|---|---|
props |
{ isLast : boolean ; kanjiInfo : KanjiInfo ; } |
The component props. |
props.isLast |
boolean |
True if this is the last item in a list, to omit the bottom border. |
props.kanjiInfo |
KanjiInfo |
The Kanji information object. |
Returns¶
Element
The rendered Kanji information display.
KanjiRow()¶
Defined in: src/components/DictDisplays.tsx:385
Renders a clickable row for a Kanji character.
Parameters¶
Parameter | Type | Description |
---|---|---|
props |
{ kanji : KanjiInfo ; onSelect : (word ) => void ; } |
The component props. |
props.kanji |
KanjiInfo |
The Kanji information. |
props.onSelect |
(word ) => void |
Callback for when the row is clicked. |
Returns¶
Element
The Kanji row component.
WildcardResults()¶
Defined in: src/components/DictDisplays.tsx:252
Displays the tabbed results from a wildcard search.
Parameters¶
Parameter | Type | Description |
---|---|---|
props |
{ onWordSelect : (word ) => void ; results : DictWildcardLookup ; } |
The component props. |
props.onWordSelect |
(word ) => void |
Callback to handle when a word is selected. |
props.results |
DictWildcardLookup |
The wildcard search results. |
Returns¶
Element
The wildcard results component.