diff --git a/js/language.js b/js/language.js index b4da233..ede6016 100644 --- a/js/language.js +++ b/js/language.js @@ -1,14 +1,11 @@ - +// This code selects all elements in the HTML document with the "data-localize" attribute // and applies the jQuery "localize" function to them with the "main" localization file and a path prefix of "lang" $("[data-localize]").localize("main", { pathPrefix: "lang" }); -// You can also override the language detection, and pass in a language code -//$("[data-localize]").localize("main", { language: "fr" }); -function changeLangFR() { - $("[data-localize]").localize("main", { - pathPrefix: "lang", - language: "fr", - }); +// This is a function that changes the language to French by calling the "localize" function with a language code of "fr" +function changeLangFR() { $("[data-localize]").localize("main", { pathPrefix: "lang", language: "fr", }); } + +// This is a function that changes the language to English by calling the "localize" function with a language code of "en" function changeLangEN() { $("[data-localize]").localize("main", { pathPrefix: "lang", diff --git a/js/spells.js b/js/spells.js index bad9ef0..4660d0b 100644 --- a/js/spells.js +++ b/js/spells.js @@ -25,6 +25,7 @@ fetch(jsonsource) selectColumn: true }, multiSelect: true, + liveSearch: true, multiSearch: true, fixedBody: false, records: test,