summaryrefslogtreecommitdiff
path: root/docs
diff options
context:
space:
mode:
authortoasted-nutbread <toasted-nutbread@users.noreply.github.com>2021-10-14 21:26:53 -0400
committertoasted-nutbread <toasted-nutbread@users.noreply.github.com>2021-10-14 21:31:03 -0400
commit858fe7ae11850eaafb3e024289faf0c78e083abf (patch)
tree701390a05b3163199c06d7cf2482d13c6f61b1a2 /docs
parentf6c346136297c10389897b183db4f05c07d204fa (diff)
String frequency support (#1989)
* Restore support for string frequency values * Add support for {value, displayValue} frequencies * Update test data * Improve number parsing of string frequencies * Improve reading detection * Expose a displayValue property for frequency information * Update docs * Expose displayValue to Anki note data * Fix translator * Update display generation * Update test data * Update counts
Diffstat (limited to 'docs')
-rw-r--r--docs/interfaces/dictionary-entry.ts20
1 files changed, 18 insertions, 2 deletions
diff --git a/docs/interfaces/dictionary-entry.ts b/docs/interfaces/dictionary-entry.ts
index 253912d0..2609a42a 100644
--- a/docs/interfaces/dictionary-entry.ts
+++ b/docs/interfaces/dictionary-entry.ts
@@ -181,7 +181,15 @@ namespace Translation {
/**
* The frequency for the character, as a number of occurrences or an overall rank.
*/
- frequency: number | string;
+ frequency: number;
+ /**
+ * A display value to show to the user.
+ */
+ displayValue: string | null;
+ /**
+ * Whether or not the displayValue string was parsed to determine the frequency value.
+ */
+ displayValueParsed: boolean;
}
// Terms
@@ -400,7 +408,15 @@ namespace Translation {
/**
* The frequency for the term, as a number of occurrences or an overall rank.
*/
- frequency: number | string;
+ frequency: number;
+ /**
+ * A display value to show to the user.
+ */
+ displayValue: string | null;
+ /**
+ * Whether or not the displayValue string was parsed to determine the frequency value.
+ */
+ displayValueParsed: boolean;
}
/**