mirror of https://github.com/espruino/BangleApps
Merge branch 'master' of github.com:espruino/BangleApps
commit
cc2e1bbd5f
46
apps.json
46
apps.json
|
@ -3488,18 +3488,36 @@
|
|||
{"name":"choozi.app.js","url":"app.js"},
|
||||
{"name":"choozi.img","url":"app-icon.js","evaluate":true}
|
||||
]
|
||||
},
|
||||
{ "id": "widclkbttm",
|
||||
"name": "Digital clock (Bottom) widget",
|
||||
"shortName":"Digital clock Bottom Widget",
|
||||
"icon": "widclkbttm.png",
|
||||
"version":"0.03",
|
||||
"description": "Displays time in the bottom area.",
|
||||
"readme": "README.md",
|
||||
"tags": "widget",
|
||||
"type": "widget",
|
||||
"storage": [
|
||||
{"name":"widclkbttm.wid.js","url":"widclkbttm.wid.js"}
|
||||
]
|
||||
}
|
||||
},
|
||||
{ "id": "widclkbttm",
|
||||
"name": "Digital clock (Bottom) widget",
|
||||
"shortName":"Digital clock Bottom Widget",
|
||||
"icon": "widclkbttm.png",
|
||||
"version":"0.03",
|
||||
"description": "Displays time in the bottom area.",
|
||||
"readme": "README.md",
|
||||
"tags": "widget",
|
||||
"type": "widget",
|
||||
"storage": [
|
||||
{"name":"widclkbttm.wid.js","url":"widclkbttm.wid.js"}
|
||||
]
|
||||
},
|
||||
{ "id": "pastel",
|
||||
"name": "Pastel Clock",
|
||||
"shortName": "Pastel",
|
||||
"icon": "pastel.png",
|
||||
"version":"0.01",
|
||||
"description": "A Configurable clock with custom fonts and background",
|
||||
"tags": "clock,b2",
|
||||
"type":"clock",
|
||||
"readme": "README.md",
|
||||
"storage": [
|
||||
{"name":"pastel.app.js","url":"pastel.app.js"},
|
||||
{"name":"pastel.img","url":"pastel.icon.js","evaluate":true},
|
||||
{"name":"pastel.settings.js","url":"pastel.settings.js"}
|
||||
],
|
||||
"data": [
|
||||
{"name":"pastel.json"}
|
||||
]
|
||||
}
|
||||
]
|
||||
|
|
|
@ -0,0 +1 @@
|
|||
0.01: First release
|
|
@ -0,0 +1,17 @@
|
|||
# Pastel Clock - a configurable clock with custom fonts and background
|
||||
|
||||
* Designed specifically for Bangle 1 and Bangle 2
|
||||
* A choice of 5 different custom fonts
|
||||
* Supports the Light and Dark themes
|
||||
* Has a settings menu, change font, enable/disable the grid and the date display
|
||||
|
||||
|
||||
I came up with the name Pastel due to the shade of the grid background.
|
||||
|
||||

|
||||

|
||||

|
||||
|
||||

|
||||

|
||||
|
File diff suppressed because one or more lines are too long
|
@ -0,0 +1 @@
|
|||
require("heatshrink").decompress(atob("mEwxH+AH4A1PYIqqAAUqp0kGMopCuVOvHHAAV4GEcAFQgAFuQwhLoIuJAAMqGEEAzovL44vgkguM49OGD0ApwvNzovfdpSQjF+FyEwskewyPFgAADX7kkA414EwIqCp14zmcuUkGJ5FEkgnFpwHHFgXBTQ0kFhpSBvAABD4KHHEY0ATAw7EFpTnHRA8Azg2FFxIvMCxGcHI0qG4kAlQuJF5gXJcIIwEvARDlSVGfZAwJuQWKSQwuCRpQAB4IvK/0kC5K0BGAouHzucvAIFL5bvHvAbCGAMkEAQuEzi0BAAZ9FX5QuH48kDgILB4IFCAAPB4IsCklySZIvKUxWdLYYABpyhBuUkIxAADHoJfSJI140SOBzgTNFxQwPQ4QuBAgK1FOoyiCF5QwBpwaIzgZBzlydgT2BCZGcHwMrmMHGJjnDAAd4JAImCvDRDGAIKBvF4uTJBA4MrrtjrljrowOAAIZCEQPBFQTuBHgpXBCYkGnBcCmVjsaTOJYOcFgZ+BeAXHkiRBAAprBrkxFAM4MAMyMgIvMkjaGKQICBMQUqfxInBlZ+DMIIGBF5QgGgAHBWQLCGAAnBgC5BFIUrR4KQNF4wGCki+DgCQHBwMySQNcFQMHSQKPTFQ4vJlS/BrhaBMgIwBd5ofHXwYALXALuCGQcxHAIvLznBD4q6JX41jmIvCdoKOBMB0ASQtyTJIADp0GdIVjgwvBMYQvMGISzEL5ucRIQAIg4vOzmdzpdBM4NOZA1OlUqBoUrFIZeCAAUrF5qSCAAIGDlSIEBgoNBGAVdBQMGmJoBgwvOG5JZBFgoNFLoIMCJgwxXO5wpYAH4A/AH4A/ABwA="))
|
|
@ -0,0 +1,7 @@
|
|||
require("Storage").write("pastel.info",{
|
||||
"id":"pastel",
|
||||
"name":"Configurable clock with custom fonts and background",
|
||||
"src":"pastel.app.js",
|
||||
"icon":"pastel.img",
|
||||
"type":"clock"
|
||||
});
|
Binary file not shown.
After Width: | Height: | Size: 3.0 KiB |
|
@ -0,0 +1,56 @@
|
|||
(function(back) {
|
||||
const SETTINGS_FILE = "pastel.json";
|
||||
|
||||
// initialize with default settings...
|
||||
let s = {
|
||||
'grid': false,
|
||||
'date': false,
|
||||
'font': "Lato"
|
||||
}
|
||||
|
||||
// ...and overwrite them with any saved values
|
||||
// This way saved values are preserved if a new version adds more settings
|
||||
const storage = require('Storage')
|
||||
let settings = storage.readJSON(SETTINGS_FILE, 1) || {}
|
||||
const saved = settings || {}
|
||||
for (const key in saved) {
|
||||
s[key] = saved[key]
|
||||
}
|
||||
|
||||
function save() {
|
||||
settings = s
|
||||
storage.write(SETTINGS_FILE, settings)
|
||||
}
|
||||
|
||||
var font_options = ["Lato","Architect","GochiHand","CabinSketch","Orbitron"];
|
||||
|
||||
E.showMenu({
|
||||
'': { 'title': 'Pastel Clock' },
|
||||
'Font': {
|
||||
value: 0 | font_options.indexOf(s.font),
|
||||
min: 0, max: 4,
|
||||
format: v => font_options[v],
|
||||
onchange: v => {
|
||||
s.font = font_options[v];
|
||||
save();
|
||||
},
|
||||
},
|
||||
'Show Grid': {
|
||||
value: s.grid,
|
||||
format: () => (s.grid ? 'Yes' : 'No'),
|
||||
onchange: () => {
|
||||
s.grid = !s.grid
|
||||
save()
|
||||
},
|
||||
},
|
||||
'Show Date': {
|
||||
value: s.date,
|
||||
format: () => (s.date ? 'Yes' : 'No'),
|
||||
onchange: () => {
|
||||
s.date = !s.date
|
||||
save()
|
||||
},
|
||||
},
|
||||
'< Back': back,
|
||||
})
|
||||
})
|
Binary file not shown.
After Width: | Height: | Size: 37 KiB |
Binary file not shown.
After Width: | Height: | Size: 45 KiB |
Binary file not shown.
After Width: | Height: | Size: 51 KiB |
Binary file not shown.
After Width: | Height: | Size: 40 KiB |
Binary file not shown.
After Width: | Height: | Size: 45 KiB |
|
@ -0,0 +1,6 @@
|
|||
const SETTINGS_FILE = "pastel.json";
|
||||
let settings = {"grid":false, "date":false, "font":"Lato"}
|
||||
|
||||
require("Storage").write(SETTINGS_FILE, settings);
|
||||
settings = require("Storage").readJSON(SETTINGS_FILE,1)||{};
|
||||
console.log(settings);
|
Loading…
Reference in New Issue