Regenerate types: ShortBoolean
parent
663ea983e4
commit
f68abbd33d
|
|
@ -90,6 +90,8 @@ type Widget = {
|
||||||
};
|
};
|
||||||
declare const WIDGETS: { [key: string]: Widget };
|
declare const WIDGETS: { [key: string]: Widget };
|
||||||
|
|
||||||
|
type ShortBoolean = boolean | 0 | 1;
|
||||||
|
|
||||||
type AccelData = {
|
type AccelData = {
|
||||||
x: number;
|
x: number;
|
||||||
y: number;
|
y: number;
|
||||||
|
|
@ -153,13 +155,13 @@ type LCDMode =
|
||||||
| "120x120"
|
| "120x120"
|
||||||
| "80x80"
|
| "80x80"
|
||||||
|
|
||||||
type BangleOptions = {
|
type BangleOptions<Boolean = boolean> = {
|
||||||
wakeOnBTN1: boolean;
|
wakeOnBTN1: Boolean;
|
||||||
wakeOnBTN2: boolean;
|
wakeOnBTN2: Boolean;
|
||||||
wakeOnBTN3: boolean;
|
wakeOnBTN3: Boolean;
|
||||||
wakeOnFaceUp: boolean;
|
wakeOnFaceUp: Boolean;
|
||||||
wakeOnTouch: boolean;
|
wakeOnTouch: Boolean;
|
||||||
wakeOnTwist: boolean;
|
wakeOnTwist: Boolean;
|
||||||
twistThreshold: number;
|
twistThreshold: number;
|
||||||
twistMaxY: number;
|
twistMaxY: number;
|
||||||
twistTimeout: number;
|
twistTimeout: number;
|
||||||
|
|
@ -3789,7 +3791,7 @@ declare class Bangle {
|
||||||
* @param {any} options
|
* @param {any} options
|
||||||
* @url http://www.espruino.com/Reference#l_Bangle_setOptions
|
* @url http://www.espruino.com/Reference#l_Bangle_setOptions
|
||||||
*/
|
*/
|
||||||
static setOptions(options: { [key in keyof BangleOptions]?: BangleOptions[key] }): void;
|
static setOptions(options: { [key in keyof BangleOptions]?: BangleOptions<ShortBoolean>[key] }): void;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Return the current state of options as set by `Bangle.setOptions`
|
* Return the current state of options as set by `Bangle.setOptions`
|
||||||
|
|
@ -3850,7 +3852,7 @@ declare class Bangle {
|
||||||
* @returns {boolean} Is HRM on?
|
* @returns {boolean} Is HRM on?
|
||||||
* @url http://www.espruino.com/Reference#l_Bangle_setHRMPower
|
* @url http://www.espruino.com/Reference#l_Bangle_setHRMPower
|
||||||
*/
|
*/
|
||||||
static setHRMPower(isOn: boolean, appID: string): boolean;
|
static setHRMPower(isOn: ShortBoolean, appID: string): boolean;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Is the Heart rate monitor powered?
|
* Is the Heart rate monitor powered?
|
||||||
|
|
@ -3874,7 +3876,7 @@ declare class Bangle {
|
||||||
* @returns {boolean} Is the GPS on?
|
* @returns {boolean} Is the GPS on?
|
||||||
* @url http://www.espruino.com/Reference#l_Bangle_setGPSPower
|
* @url http://www.espruino.com/Reference#l_Bangle_setGPSPower
|
||||||
*/
|
*/
|
||||||
static setGPSPower(isOn: boolean, appID: string): boolean;
|
static setGPSPower(isOn: ShortBoolean, appID: string): boolean;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Is the GPS powered?
|
* Is the GPS powered?
|
||||||
|
|
@ -3906,7 +3908,7 @@ declare class Bangle {
|
||||||
* @returns {boolean} Is the Compass on?
|
* @returns {boolean} Is the Compass on?
|
||||||
* @url http://www.espruino.com/Reference#l_Bangle_setCompassPower
|
* @url http://www.espruino.com/Reference#l_Bangle_setCompassPower
|
||||||
*/
|
*/
|
||||||
static setCompassPower(isOn: boolean, appID: string): boolean;
|
static setCompassPower(isOn: ShortBoolean, appID: string): boolean;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Is the compass powered?
|
* Is the compass powered?
|
||||||
|
|
@ -3934,7 +3936,7 @@ declare class Bangle {
|
||||||
* @returns {boolean} Is the Barometer on?
|
* @returns {boolean} Is the Barometer on?
|
||||||
* @url http://www.espruino.com/Reference#l_Bangle_setBarometerPower
|
* @url http://www.espruino.com/Reference#l_Bangle_setBarometerPower
|
||||||
*/
|
*/
|
||||||
static setBarometerPower(isOn: boolean, appID: string): boolean;
|
static setBarometerPower(isOn: ShortBoolean, appID: string): boolean;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Is the Barometer powered?
|
* Is the Barometer powered?
|
||||||
|
|
@ -4326,7 +4328,7 @@ declare class Bangle {
|
||||||
*/
|
*/
|
||||||
static appRect: { x: number, y: number, w: number, h: number, x2: number, y2: number };
|
static appRect: { x: number, y: number, w: number, h: number, x2: number, y2: number };
|
||||||
|
|
||||||
static CLOCK: boolean;
|
static CLOCK: ShortBoolean;
|
||||||
static strokes: undefined | { [key: string]: Unistroke };
|
static strokes: undefined | { [key: string]: Unistroke };
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue