yazi-proxy 0.2.4

Yazi event proxy
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
use yazi_shared::{emit, event::Cmd, Layer};

pub struct CompletionProxy;

impl CompletionProxy {
	#[inline]
	pub fn close() {
		emit!(Call(Cmd::new("close"), Layer::Completion));
	}

	#[inline]
	pub fn trigger(word: &str, ticket: usize) {
		emit!(Call(
			Cmd::args("trigger", vec![word.to_owned()]).with("ticket", ticket),
			Layer::Completion
		));
	}
}