mirror of
https://github.com/yzh503/obsidian-aicommander-plugin.git
synced 2026-07-22 07:40:26 +00:00
Fix command ID
This commit is contained in:
parent
ca66fb7641
commit
7490303a87
1 changed files with 4 additions and 2 deletions
6
main.ts
6
main.ts
|
|
@ -65,6 +65,8 @@ export default class AICommanderPlugin extends Plugin {
|
||||||
}
|
}
|
||||||
|
|
||||||
const messages = [];
|
const messages = [];
|
||||||
|
|
||||||
|
console.log(contextPrompt);
|
||||||
|
|
||||||
if (contextPrompt) {
|
if (contextPrompt) {
|
||||||
messages.push({
|
messages.push({
|
||||||
|
|
@ -382,7 +384,7 @@ export default class AICommanderPlugin extends Plugin {
|
||||||
});
|
});
|
||||||
|
|
||||||
this.addCommand({
|
this.addCommand({
|
||||||
id: 'prompt-text',
|
id: 'pdf-text',
|
||||||
name: 'Generate text from prompt in context of the above PDF',
|
name: 'Generate text from prompt in context of the above PDF',
|
||||||
editorCallback: (editor: Editor, view: MarkdownView) => {
|
editorCallback: (editor: Editor, view: MarkdownView) => {
|
||||||
const onSubmit = (prompt: string) => {
|
const onSubmit = (prompt: string) => {
|
||||||
|
|
@ -403,7 +405,7 @@ export default class AICommanderPlugin extends Plugin {
|
||||||
});
|
});
|
||||||
|
|
||||||
this.addCommand({
|
this.addCommand({
|
||||||
id: 'prompt-text-selected',
|
id: 'pdf-text-selected',
|
||||||
name: 'Generate text from the selected text in context of the above PDF',
|
name: 'Generate text from the selected text in context of the above PDF',
|
||||||
editorCallback: (editor: Editor, view: MarkdownView) => {
|
editorCallback: (editor: Editor, view: MarkdownView) => {
|
||||||
const selectedText = editor.getSelection();
|
const selectedText = editor.getSelection();
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue