forked from FOSS/BangleApps
* Added progress bar on Bangle.js for uploads
* Provide a proper error message in case JSON decode fails * Check you're connecting with a Bangle.js of the correct versionmaster
parent
0ec2bad835
commit
785b48f47a
|
@ -26,3 +26,6 @@ Changed for individual apps are listed in `apps/appname/ChangeLog`
|
||||||
* Added ability to specify dependencies (used for `notify` at the moment)
|
* Added ability to specify dependencies (used for `notify` at the moment)
|
||||||
* Fixed Promise-based bug in removeApp
|
* Fixed Promise-based bug in removeApp
|
||||||
* Fixed bin/firmwaremaker and bin/apploader CLI to handle binary file uploads correctly
|
* Fixed bin/firmwaremaker and bin/apploader CLI to handle binary file uploads correctly
|
||||||
|
* Added progress bar on Bangle.js for uploads
|
||||||
|
* Provide a proper error message in case JSON decode fails
|
||||||
|
* Check you're connecting with a Bangle.js of the correct version
|
||||||
|
|
2
core
2
core
|
@ -1 +1 @@
|
||||||
Subproject commit 62615f6ea4855381e0b4b4b74f8ca69aa594181e
|
Subproject commit 06204c852d5cd8101fc8e23ef8d43903c25a4edc
|
14
loader.js
14
loader.js
|
@ -11,10 +11,20 @@ if (window.location.host=="banglejs.com") {
|
||||||
'This is not the official Bangle.js App Loader - you can try the <a href="https://banglejs.com/apps/">Official Version</a> here.';
|
'This is not the official Bangle.js App Loader - you can try the <a href="https://banglejs.com/apps/">Official Version</a> here.';
|
||||||
}
|
}
|
||||||
|
|
||||||
var APP_SOURCECODE_URL;
|
var RECOMMENDED_VERSION = "2v08";
|
||||||
|
// could check http://www.espruino.com/json/BANGLEJS.json for this
|
||||||
|
|
||||||
(function() {
|
(function() {
|
||||||
let username = "espruino";
|
let username = "espruino";
|
||||||
let githubMatch = window.location.href.match(/\/(\w+)\.github\.io/);
|
let githubMatch = window.location.href.match(/\/(\w+)\.github\.io/);
|
||||||
if (githubMatch) username = githubMatch[1];
|
if (githubMatch) username = githubMatch[1];
|
||||||
APP_SOURCECODE_URL = `https://github.com/${username}/BangleApps/tree/master/apps`;
|
Const.APP_SOURCECODE_URL = `https://github.com/${username}/BangleApps/tree/master/apps`;
|
||||||
})();
|
})();
|
||||||
|
|
||||||
|
function onFoundDeviceInfo(deviceId, deviceVersion) {
|
||||||
|
if (deviceId != "BANGLEJS") {
|
||||||
|
showToast(`You're using ${deviceId}, not a Bangle.js. Did you want <a href="https://espruino.com/apps">espruino.com/apps</a> instead?` ,"warning", 20000);
|
||||||
|
} else if (versionLess(deviceVersion, RECOMMENDED_VERSION)) {
|
||||||
|
showToast(`You're using an old Bangle.js firmware (${deviceVersion}). You can <a href="https://www.espruino.com/Bangle.js#firmware-updates" target="_blank">update with the instructions here</a>` ,"warning", 20000);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
Loading…
Reference in New Issue