feature (plg_widget_console): add new commands

This commit is contained in:
MickaelK
2026-04-11 01:40:37 +10:00
parent e7a15d05df
commit fdc5f871aa
2 changed files with 98 additions and 6 deletions
@@ -45,3 +45,99 @@ register({
shell.classList.add("hidden");
},
});
// register({
// id: "mimetype",
// description: "Determine file type",
// run(shell) {
// // TODO
// },
// });
// register({
// id: "whoami",
// description: "Print effective user name",
// run(shell) {
// // TODO
// },
// });
// register({
// id: "pwd",
// description: "Print current/working directory",
// run(shell) {
// // TODO
// },
// });
// register({
// id: "mkdir",
// description: "Make directories",
// run(shell) {
// // TODO
// },
// });
// register({
// id: "rm",
// description: "Remove files or directories",
// run(shell) {
// // TODO
// },
// });
// register({
// id: "mv",
// description: "Move files",
// run(shell) {
// // TODO
// },
// });
// register({
// id: "touch",
// description: "Create a file",
// run(shell) {
// // TODO
// },
// });
// register({
// id: "save",
// description: "Save a file",
// run(shell) {
// // TODO
// },
// });
// register({
// id: "cd",
// description: "Change working directory",
// run(shell) {
// // TODO
// },
// });
// register({
// id: "ls",
// description: "List directory contents",
// run(shell) {
// // TODO
// },
// });
// register({
// id: "stat",
// description: "Display file info",
// run(shell) {
// // TODO
// },
// });
// register({
// id: "xdg-open",
// description: "Open a file",
// run(shell) {
// // TODO
// },
// });
@@ -4,9 +4,9 @@ import { getSession } from "../model/session.js";
import { all as allCommands, get as getCommand, register as registerCommand } from "./registry.js";
import("./commands.js");
export function init() {
console.log("INIT");
return ;
return;
}
class ComponentShell extends HTMLElement {
@@ -21,10 +21,6 @@ class ComponentShell extends HTMLElement {
this.clear();
}
getCommands() {
return allCommands();
}
static get observedAttributes() {
return ["class", "path"];
}