Have got text transformations working
This commit is contained in:
parent
9f2fa96b92
commit
41daf7cfc9
14 changed files with 178 additions and 17 deletions
|
|
@ -1,6 +1,8 @@
|
|||
import { Controller } from "@hotwired/stimulus"
|
||||
|
||||
export default class extends Controller {
|
||||
import { textProcessor } from "../services.js";
|
||||
|
||||
export class CommandsController extends Controller {
|
||||
static targets = [
|
||||
"commandInput",
|
||||
"commandSelect",
|
||||
|
|
@ -30,7 +32,7 @@ export default class extends Controller {
|
|||
runCommand(ev) {
|
||||
ev.preventDefault();
|
||||
|
||||
console.log("Do this: " + this.commandSelectTarget.value);
|
||||
textProcessor.runTextCommand(this.commandSelectTarget.value);
|
||||
this.element.close();
|
||||
}
|
||||
|
||||
|
|
@ -49,4 +51,4 @@ export default class extends Controller {
|
|||
this.commandSelectTarget.selectedIndex = 0;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue