From e16bf9a9adeeb8bf52803454f116cdcaea1fb168 Mon Sep 17 00:00:00 2001 From: 2 * r + 2 * t <61896496+soramanew@users.noreply.github.com> Date: Sat, 1 Mar 2025 00:00:25 +1100 Subject: launcher: better files Files shorten path Also tooltips for both apps and files --- src/modules/launcher.tsx | 24 +++++++++++++++++++----- 1 file changed, 19 insertions(+), 5 deletions(-) (limited to 'src/modules') diff --git a/src/modules/launcher.tsx b/src/modules/launcher.tsx index 8e83fe2..e38eb96 100644 --- a/src/modules/launcher.tsx +++ b/src/modules/launcher.tsx @@ -1,7 +1,7 @@ import { Apps as AppsService } from "@/services/apps"; import { getAppCategoryIcon } from "@/utils/icons"; import { launch } from "@/utils/system"; -import { FlowBox } from "@/utils/widgets"; +import { FlowBox, setupCustomTooltip } from "@/utils/widgets"; import PopupWindow from "@/widgets/popupwindow"; import { bind, execAsync, Gio, register, Variable } from "astal"; import { App, Astal, Gtk, Widget } from "astal/gtk3"; @@ -36,6 +36,8 @@ const getPrettyMode = (mode: Mode) => { const limitLength = (arr: T[], cfg: { maxResults: Variable }) => cfg.maxResults.get() > 0 && arr.length > cfg.maxResults.get() ? arr.slice(0, cfg.maxResults.get()) : arr; +const ContentBox = () => ; + const AppResult = ({ app }: { app: AstalApps.Application }) => ( @@ -94,7 +108,7 @@ class Apps extends Widget.Box implements ModeContent { constructor() { super({ name: "apps", className: "apps" }); - this.#content = () as FlowBox; + this.#content = () as FlowBox; this.add( @@ -122,7 +136,7 @@ class Files extends Widget.Box implements ModeContent { constructor() { super({ name: "files", className: "files" }); - this.#content = () as FlowBox; + this.#content = () as FlowBox; this.add( -- cgit v1.2.3-freya