diff --git a/config/ags/launcher/app.ts b/config/ags/launcher/app.ts index 83217ef..7428115 100644 --- a/config/ags/launcher/app.ts +++ b/config/ags/launcher/app.ts @@ -1,10 +1,9 @@ import { App } from "astal/gtk3" import style from "./style.scss" -import Bar from "./widget/Bar" +import Applauncher from "./ui/AppLauncher" App.start({ + instanceName: "launcher", css: style, - main() { - App.get_monitors().map(Bar) - }, -}) + main: Applauncher, +}); diff --git a/config/ags/launcher/ui/AppLauncher.tsx b/config/ags/launcher/ui/AppLauncher.tsx index e69de29..2ea91a5 100644 --- a/config/ags/launcher/ui/AppLauncher.tsx +++ b/config/ags/launcher/ui/AppLauncher.tsx @@ -0,0 +1,31 @@ +import { App, Astal, Gtk, Gdk } from "astal/gtk3" +import { Variable } from "astal" + +const time = Variable("").poll(1000, "date") + +export default function AppLauncher(gdkmonitor: Gdk.Monitor) { + const { TOP, LEFT, RIGHT } = Astal.WindowAnchor + + return + + + + + + +} diff --git a/config/ags/launcher/util/search.ts b/config/ags/launcher/util/search.ts index e69de29..895461e 100644 --- a/config/ags/launcher/util/search.ts +++ b/config/ags/launcher/util/search.ts @@ -0,0 +1,43 @@ +/* +* dotfiles - search.ts +* +* Created by Janis Hutz 03/22/2025, Licensed under the GPL V3 License +* https://janishutz.com, development@janishutz.com +* +* +*/ + +import subprocessRunner from "./subprocessRunner"; + +const preprocess = ( input: string ) => { + // Find out what kind of instruction to process + if ( input.startsWith( ':' ) ) { + processCommand( input.substring( 1, input.indexOf( ' ' ) ), input.substring( input.indexOf( ' ' ) ).split( ' ' ) ); + } else if ( input.startsWith( '!' ) ) { + processBang( input.substring( 1, input.indexOf( ' ' ) ), input.substring( input.indexOf( ' ' ) ) ); + } else { + // Determine if entered string is calculation or not + // We can easily do that by asking qalc (qalculate cli) if this is fine + subprocessRunner.executeCommand( 'qalc "' + input + '"' ).then( out => { + print( out ); + } ).catch( err => { + print( err ); + } ); + } +} + +const processSearch = ( input: string ) => { + +} + +const processCalculation = ( input: string ) => { + +} + +const processCommand = ( cmd: string, args: string[] ) => { + +} + +const processBang = ( bang: string, input: string ) => { + +}