treewide: format
This commit is contained in:
@@ -27,10 +27,8 @@ List<Character> parseKANJIDICData(XmlElement root) {
|
||||
jlpt: int.tryParse(
|
||||
misc.findElements('jlpt').firstOrNull?.innerText ?? '',
|
||||
),
|
||||
radicalName: misc
|
||||
.findElements('rad_name')
|
||||
.map((e) => e.innerText)
|
||||
.toList(),
|
||||
radicalName:
|
||||
misc.findElements('rad_name').map((e) => e.innerText).toList(),
|
||||
codepoints: codepoint
|
||||
?.findElements('cp_value')
|
||||
.map(
|
||||
@@ -43,15 +41,15 @@ List<Character> parseKANJIDICData(XmlElement root) {
|
||||
.toList() ??
|
||||
[],
|
||||
radical: radical
|
||||
?.findElements('rad_value')
|
||||
.where((e) => e.getAttribute('rad_type') == 'classical')
|
||||
.map(
|
||||
(e) => Radical(
|
||||
kanji: kanji,
|
||||
radicalId: int.parse(e.innerText),
|
||||
),
|
||||
)
|
||||
.firstOrNull,
|
||||
?.findElements('rad_value')
|
||||
.where((e) => e.getAttribute('rad_type') == 'classical')
|
||||
.map(
|
||||
(e) => Radical(
|
||||
kanji: kanji,
|
||||
radicalId: int.parse(e.innerText),
|
||||
),
|
||||
)
|
||||
.firstOrNull,
|
||||
strokeMiscounts: misc
|
||||
.findElements('stroke_count')
|
||||
.skip(1)
|
||||
|
||||
@@ -175,9 +175,9 @@ Future<KanjiSearchResult?> searchKanjiWithDbConnection(
|
||||
|
||||
// TODO: Add `volume` and `page` to the entries
|
||||
final dictionaryReferences = {
|
||||
for (final entry in dictionary_references)
|
||||
entry['type'] as String: entry['ref'] as String,
|
||||
};
|
||||
for (final entry in dictionary_references)
|
||||
entry['type'] as String: entry['ref'] as String,
|
||||
};
|
||||
|
||||
final String? grade = {
|
||||
1: 'grade 1',
|
||||
|
||||
Reference in New Issue
Block a user