summaryrefslogtreecommitdiff
path: root/src/modules/launcher
diff options
context:
space:
mode:
Diffstat (limited to 'src/modules/launcher')
-rw-r--r--src/modules/launcher/actions.tsx4
-rw-r--r--src/modules/launcher/index.tsx9
-rw-r--r--src/modules/launcher/modes.tsx2
3 files changed, 10 insertions, 5 deletions
diff --git a/src/modules/launcher/actions.tsx b/src/modules/launcher/actions.tsx
index 11b07d0..e99c720 100644
--- a/src/modules/launcher/actions.tsx
+++ b/src/modules/launcher/actions.tsx
@@ -304,7 +304,7 @@ const Scheme = ({ scheme, name, colours }: { scheme?: string; name: string; colo
const Wallpaper = ({ path, thumbnail }: IWallpaper) => (
<Gtk.FlowBoxChild visible canFocus={false}>
<button
- className="result"
+ className="result wallpaper-container"
cursor="pointer"
onClicked={() => {
execAsync(`caelestia wallpaper -f ${path}`).catch(console.error);
@@ -326,7 +326,7 @@ const Wallpaper = ({ path, thumbnail }: IWallpaper) => (
const Category = ({ path, wallpapers }: ICategory) => (
<Gtk.FlowBoxChild visible canFocus={false}>
<button
- className="result"
+ className="result wallpaper-container"
cursor="pointer"
onClicked={() => {
execAsync(`caelestia wallpaper -d ${path}`).catch(console.error);
diff --git a/src/modules/launcher/index.tsx b/src/modules/launcher/index.tsx
index d355c79..b75ecce 100644
--- a/src/modules/launcher/index.tsx
+++ b/src/modules/launcher/index.tsx
@@ -24,7 +24,10 @@ const isAction = (text: string, action: string = "") => text.startsWith(config.a
const SearchBar = ({ mode, entry }: { mode: Variable<Mode>; entry: Widget.Entry }) => (
<box className="search-bar">
- <label className="mode" label={bind(mode)} />
+ <box className="mode">
+ <label className="icon" label={bind(mode).as(getModeIcon)} />
+ <label label={bind(mode).as(getPrettyMode)} />
+ </box>
{entry}
</box>
);
@@ -61,6 +64,7 @@ export default class Launcher extends PopupWindow {
const mode = Variable<Mode>("apps");
const content = Modes();
const actions = new Actions(mode, entry);
+ const className = Variable.derive([mode, config.style], (m, s) => `launcher ${m} ${s}`);
super({
name: "launcher",
@@ -86,7 +90,8 @@ export default class Launcher extends PopupWindow {
vertical
halign={Gtk.Align.CENTER}
valign={Gtk.Align.CENTER}
- className={bind(mode).as(m => `launcher ${m}`)}
+ className={bind(className)}
+ onDestroy={() => className.drop()}
>
<SearchBar mode={mode} entry={entry} />
<stack
diff --git a/src/modules/launcher/modes.tsx b/src/modules/launcher/modes.tsx
index 0db7cd5..fd9569b 100644
--- a/src/modules/launcher/modes.tsx
+++ b/src/modules/launcher/modes.tsx
@@ -186,7 +186,7 @@ class Math extends Widget.Box implements LauncherContent {
/>
</box>
</box>
- <box className="separator" />
+ <box visible={bind(config.style).as(s => s === "lines")} className="separator" />
</box>
</revealer>
);