-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathscript.js
More file actions
38 lines (28 loc) · 1.07 KB
/
script.js
File metadata and controls
38 lines (28 loc) · 1.07 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
/*
Polyglot
Copyright (C) LiveG. All Rights Reserved.
https://opensource.liveg.tech/polyglot
Licensed by the LiveG Open-Source Licence, which can be found at LICENCE.md.
*/
import * as $g from "https://opensource.liveg.tech/Adapt-UI/src/adaptui.js";
import * as astronaut from "https://opensource.liveg.tech/Adapt-UI/astronaut/astronaut.js";
import * as main from "./main.js";
window.$g = $g;
astronaut.unpack();
$g.waitForLoad().then(function() {
return $g.l10n.selectLocaleFromResources({
"en_GB": "locales/en_GB.json"
});
}).then(function(locale) {
window._ = function() {
return locale.translate(...arguments);
};
$g.theme.setProperty("primaryHue", "120");
$g.theme.setProperty("primarySaturation", "60%");
$g.theme.setProperty("primaryLightness", "30%");
$g.theme.setProperty("secondaryHue", "120");
$g.theme.setProperty("secondarySaturation", "60%");
$g.theme.setProperty("secondaryLightness", "40%");
$g.sel("title").setText(_("polyglot"));
astronaut.render(main.MainScreen({showing: true}) ());
});