mirror of
https://github.com/ankitects/anki.git
synced 2026-01-14 06:23:57 -05:00
CONSTANT_CASE
This commit is contained in:
parent
ee1419b726
commit
c6eeaa0e8a
1 changed files with 6 additions and 6 deletions
|
|
@ -93,13 +93,13 @@ License: GNU AGPL, version 3 or later; http://www.gnu.org/licenses/agpl.html
|
|||
reviewOrder: $config.reviewOrder,
|
||||
});
|
||||
|
||||
const desiredRetentionLowThreshold = 0.8;
|
||||
const desiredRetentionHighThreshold = 0.95;
|
||||
const DESIRED_RETENTION_LOW_THRESHOLD = 0.8;
|
||||
const DESIRED_RETENTION_HIGH_THRESHOLD = 0.95;
|
||||
|
||||
function getRetentionLongShortWarning(retention: number) {
|
||||
if (retention < desiredRetentionLowThreshold) {
|
||||
if (retention < DESIRED_RETENTION_LOW_THRESHOLD) {
|
||||
return tr.deckConfigDesiredRetentionTooLow();
|
||||
} else if (retention > desiredRetentionHighThreshold) {
|
||||
} else if (retention > DESIRED_RETENTION_HIGH_THRESHOLD) {
|
||||
return tr.deckConfigDesiredRetentionTooHigh();
|
||||
} else {
|
||||
return "";
|
||||
|
|
@ -134,8 +134,8 @@ License: GNU AGPL, version 3 or later; http://www.gnu.org/licenses/agpl.html
|
|||
if (retention < 0.7 || retention > 0.97) {
|
||||
return "alert-danger";
|
||||
} else if (
|
||||
retention < desiredRetentionLowThreshold ||
|
||||
retention > desiredRetentionHighThreshold
|
||||
retention < DESIRED_RETENTION_LOW_THRESHOLD ||
|
||||
retention > DESIRED_RETENTION_HIGH_THRESHOLD
|
||||
) {
|
||||
return "alert-warning";
|
||||
} else {
|
||||
|
|
|
|||
Loading…
Reference in a new issue