aboutsummaryrefslogtreecommitdiff
path: root/src/client/views/nodes/formattedText/FormattedTextBox.tsx
diff options
context:
space:
mode:
authorbobzel <zzzman@gmail.com>2024-10-09 13:28:02 -0400
committerbobzel <zzzman@gmail.com>2024-10-09 13:28:02 -0400
commit9d629f60f90628478f46b219f7ad8a9093972ae3 (patch)
treed9f80ba4aba98cfb9e6ffa75cd618ba7cd93c216 /src/client/views/nodes/formattedText/FormattedTextBox.tsx
parent01db98ebdd02729729222bdd20ab65b57cbbe94c (diff)
parent9c80914b41b1b964938370c7a0db8a643b6af23f (diff)
Merge branch 'alyssa-starter' of https://github.com/brown-dash/Dash-Web into alyssa-starter
Diffstat (limited to 'src/client/views/nodes/formattedText/FormattedTextBox.tsx')
-rw-r--r--src/client/views/nodes/formattedText/FormattedTextBox.tsx10
1 files changed, 0 insertions, 10 deletions
diff --git a/src/client/views/nodes/formattedText/FormattedTextBox.tsx b/src/client/views/nodes/formattedText/FormattedTextBox.tsx
index 93153b453..dac869f56 100644
--- a/src/client/views/nodes/formattedText/FormattedTextBox.tsx
+++ b/src/client/views/nodes/formattedText/FormattedTextBox.tsx
@@ -1006,26 +1006,16 @@ export class FormattedTextBox extends ViewBoxAnnotatableComponent<FormattedTextB
};
getImageDesc = async (u: string) => {
- // if (StrCast(this.dataDoc.description)) return StrCast(this.dataDoc.description); // Return existing description
- // const { href } = (u as URLField).url;
- const hrefParts = u.split('.');
- const hrefComplete = `${hrefParts[0]}_o.${hrefParts[1]}`;
try {
const hrefBase64 = await imageUrlToBase64(u);
const response = await gptImageLabel(
hrefBase64,
'Make flashcards out of this text and image with each question and answer labeled as question and answer. Do not label each flashcard and do not include asterisks: ' + (this.dataDoc.text as RichTextField)?.Text
);
- //const response = await gptImageLabel(u, 'Make flashcards out of this text with each question and answer labeled as question and answer. Do not label each flashcard and do not include asterisks: ');
- // console.log(response);
AnchorMenu.Instance.transferToFlashcard(response || 'Something went wrong', NumCast(this.dataDoc['x']), NumCast(this.dataDoc['y']));
- // this._props.addto_;
- // this.Document[DocData].description = response.trim();
- // return response; // Return the response
} catch (error) {
console.log('Error', error);
}
- // return '';
};
animateRes = (resIndex: number, newText: string) => {