Fix: TextWord uses 'value' not 'text' to match SDK TextRecognitionResult

This commit is contained in:
Eiloud 2026-05-13 22:19:46 +08:00
parent b895a370ca
commit a19d3f8ed4
2 changed files with 2 additions and 2 deletions

View File

@ -64,7 +64,7 @@ export class OcrAdapter extends BaseAdapter {
for (const block of data.blocks) {
for (const line of block.lines) {
for (let word of line.words) {
let word1: TextWord = { text: word.text || '' };
let word1: TextWord = { value: word.value || '' };
wordsArray.push(word1);
}
}

View File

@ -347,7 +347,7 @@ export interface OcrAdapterImage {
}
export interface TextWord {
text: string;
value: string;
confidence?: number;
}