diff --git a/.gitignore b/.gitignore index ba87b49..67e81a8 100644 --- a/.gitignore +++ b/.gitignore @@ -2,3 +2,4 @@ config.js db.json __pycache__/ *.pyc +db_lite.json diff --git a/calc/calc.js b/calc/calc.js index f58e9e8..37c1a2c 100644 --- a/calc/calc.js +++ b/calc/calc.js @@ -60,6 +60,7 @@ var optHltSameCipher = false; var alphaHlt = 0.15; // opacity for values that do not match - change value here and in conf_SOM() var optAllowPhraseComments = true; // allow phrase comments, text inside [...] is not evaluated +var optPrioritizeIngglish = (typeof CALC_CONFIG !== 'undefined' && CALC_CONFIG.prioritizeIngglishMatches) ? true : false; // sort [Ingglish: ...] matches to top of query results var liveDatabaseMode = true; // live database mode var dbPageItems = (typeof CALC_CONFIG !== 'undefined' && CALC_CONFIG.resultsPerPage) ? CALC_CONFIG.resultsPerPage : 12; @@ -103,6 +104,7 @@ var calcOptionsArr = [ "optNewPhrasesGoFirst", "optShowExtraCiphers", "optAllowPhraseComments", + "optPrioritizeIngglish", "liveDatabaseMode", "optLetterWordCount", "optWordBreakdown", @@ -546,6 +548,8 @@ function createOptionsMenu() { if (optShowExtraCiphers) SECstate = "checked"; // Show Extra Ciphers if (optAllowPhraseComments) APCstate = "checked"; // Allow Phrase Comments + var PIMstate = ""; + if (optPrioritizeIngglish) PIMstate = "checked"; // Prioritize Ingglish [...] if (liveDatabaseMode) LDMstate = "checked"; // Live Database Mode if (optNewPhrasesGoFirst) NPGFstate = "checked"; // New Phrases Go First @@ -586,6 +590,10 @@ function createOptionsMenu() { '
'; + o += + '
'; o += '