Fix: add remaining BatteryInfo fields, fix TextWord cast in OcrAdapter
This commit is contained in:
parent
9e3c1a1486
commit
7dda953045
@ -64,7 +64,7 @@ export class OcrAdapter extends BaseAdapter {
|
|||||||
for (const block of data.blocks) {
|
for (const block of data.blocks) {
|
||||||
for (const line of block.lines) {
|
for (const line of block.lines) {
|
||||||
for (let word of line.words) {
|
for (let word of line.words) {
|
||||||
let word1: TextWord = word;
|
let word1: TextWord = { word: (word as any).text || '' };
|
||||||
wordsArray.push(word1);
|
wordsArray.push(word1);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@ -335,6 +335,9 @@ export interface BatteryInfo {
|
|||||||
batterySOC: number;
|
batterySOC: number;
|
||||||
chargingStatus: number;
|
chargingStatus: number;
|
||||||
isBatteryPresent: boolean;
|
isBatteryPresent: boolean;
|
||||||
|
estimatedRemainingChargeTime: number;
|
||||||
|
nowCurrent: number;
|
||||||
|
remainingEnergy: number;
|
||||||
}
|
}
|
||||||
|
|
||||||
export interface OcrAdapterImage {
|
export interface OcrAdapterImage {
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user