added some comments

This commit is contained in:
mic 2024-12-10 22:51:32 +01:00
parent f5e27f299a
commit 8adaccae38

View file

@ -179,9 +179,9 @@ export class mzta_Menus {
// const tabs = await browser.tabs.query({ active: true, currentWindow: true }); // const tabs = await browser.tabs.query({ active: true, currentWindow: true });
// add custom text if needed // add custom text if needed
//browser.runtime.sendMessage({command: "chatgpt_open", prompt: fullPrompt, action: curr_prompt.action, tabId: tabs[0].id}); //browser.runtime.sendMessage({command: "chatgpt_open", prompt: fullPrompt, action: curr_prompt.action, tabId: tabs[0].id});
if(curr_prompt.is_special == '1'){ if(curr_prompt.is_special == '1'){ // Special prompts
switch(curr_prompt.id){ switch(curr_prompt.id){
case 'prompt_add_tags': case 'prompt_add_tags': // Add tags to the email
const tabs_debug = await browser.tabs.query({ active: true, currentWindow: true }); const tabs_debug = await browser.tabs.query({ active: true, currentWindow: true });
console.log("[ThunderAI] Add tags for this message: " + tabs_debug[0].url); console.log("[ThunderAI] Add tags for this message: " + tabs_debug[0].url);
break; break;
@ -189,7 +189,7 @@ export class mzta_Menus {
console.error("[ThunderAI] Unknown special prompt id: " + curr_prompt.id); console.error("[ThunderAI] Unknown special prompt id: " + curr_prompt.id);
break; break;
} }
}else{ }else{ // Classic prompts for the API webchat
this.openChatGPT(fullPrompt, curr_prompt.action, tabs[0].id, curr_prompt.name, curr_prompt.need_custom_text); this.openChatGPT(fullPrompt, curr_prompt.action, tabs[0].id, curr_prompt.name, curr_prompt.need_custom_text);
} }
}; };