WIP: Add yaak-mac-window to proxy app

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
Gregory Schier
2026-03-11 15:35:54 -07:00
parent f51f72a332
commit 7be53ca330
7 changed files with 9 additions and 9 deletions

1
Cargo.lock generated
View File

@@ -10310,6 +10310,7 @@ dependencies = [
"tauri", "tauri",
"tauri-build", "tauri-build",
"tauri-plugin-os", "tauri-plugin-os",
"yaak-mac-window",
"yaak-proxy-lib", "yaak-proxy-lib",
"yaak-rpc", "yaak-rpc",
"yaak-window", "yaak-window",

View File

@@ -17,6 +17,7 @@ log = { workspace = true }
serde_json = { workspace = true } serde_json = { workspace = true }
tauri = { workspace = true } tauri = { workspace = true }
tauri-plugin-os = "2.3.2" tauri-plugin-os = "2.3.2"
yaak-mac-window = { workspace = true }
yaak-proxy-lib = { workspace = true } yaak-proxy-lib = { workspace = true }
yaak-rpc = { workspace = true } yaak-rpc = { workspace = true }
yaak-window = { workspace = true } yaak-window = { workspace = true }

View File

@@ -13,6 +13,7 @@
"core:window:allow-maximize", "core:window:allow-maximize",
"core:window:allow-minimize", "core:window:allow-minimize",
"core:window:allow-start-dragging", "core:window:allow-start-dragging",
"core:window:allow-unmaximize" "core:window:allow-unmaximize",
"yaak-mac-window:default"
] ]
} }

View File

@@ -17,6 +17,7 @@ fn rpc(
pub fn run() { pub fn run() {
tauri::Builder::default() tauri::Builder::default()
.plugin(tauri_plugin_os::init()) .plugin(tauri_plugin_os::init())
.plugin(yaak_mac_window::init())
.setup(|app| { .setup(|app| {
let data_dir = app.path().app_data_dir().expect("no app data dir"); let data_dir = app.path().app_data_dir().expect("no app data dir");
std::fs::create_dir_all(&data_dir).expect("failed to create app data dir"); std::fs::create_dir_all(&data_dir).expect("failed to create app data dir");
@@ -44,7 +45,7 @@ pub fn run() {
if let RunEvent::Ready = event { if let RunEvent::Ready = event {
let config = CreateWindowConfig { let config = CreateWindowConfig {
url: "/", url: "/",
label: "main", label: "main_0",
title: "Yaak Proxy", title: "Yaak Proxy",
inner_size: Some((1000.0, 700.0)), inner_size: Some((1000.0, 700.0)),
visible: true, visible: true,

View File

@@ -54,7 +54,7 @@ const SHA256_MAP = {
const key = `${process.platform}_${process.env.YAAK_TARGET_ARCH ?? process.arch}`; const key = `${process.platform}_${process.env.YAAK_TARGET_ARCH ?? process.arch}`;
const destDir = path.join(__dirname, `..`, 'crates-tauri', 'yaak-app', 'vendored', 'node'); const destDir = path.join(__dirname, `..`, 'crates-tauri', 'yaak-app-client', 'vendored', 'node');
const binDest = path.join(destDir, DST_BIN_MAP[key]); const binDest = path.join(destDir, DST_BIN_MAP[key]);
console.log(`Vendoring NodeJS ${NODE_VERSION} for ${key}`); console.log(`Vendoring NodeJS ${NODE_VERSION} for ${key}`);

View File

@@ -23,11 +23,7 @@ for (const name of readdirSync(pluginsDir)) {
console.log(`Skipping ${name} (external plugin)`); console.log(`Skipping ${name} (external plugin)`);
continue; continue;
} }
const destDir = path.join( const destDir = path.join( __dirname, "..", 'crates-tauri','yaak-app-client','vendored','plugins', name);
__dirname,
"../crates-tauri/yaak-app-client/vendored/plugins/",
name,
);
mkdirSync(destDir, { recursive: true }); mkdirSync(destDir, { recursive: true });
console.log(`Copying ${name} to ${destDir}`); console.log(`Copying ${name} to ${destDir}`);
cpSync(path.join(dir, "package.json"), path.join(destDir, "package.json")); cpSync(path.join(dir, "package.json"), path.join(destDir, "package.json"));

View File

@@ -52,7 +52,7 @@ const SHA256_MAP = {
[WIN_ARM]: 'd7a207fb6eec0e4b1b6613be3b7d11905375b6fd1147a071116eb8e9f24ac53b', [WIN_ARM]: 'd7a207fb6eec0e4b1b6613be3b7d11905375b6fd1147a071116eb8e9f24ac53b',
}; };
const dstDir = path.join(__dirname, `..`, 'crates-tauri', 'yaak-app', 'vendored', 'protoc'); const dstDir = path.join(__dirname, `..`, 'crates-tauri', 'yaak-app-client', 'vendored', 'protoc');
const key = `${process.platform}_${process.env.YAAK_TARGET_ARCH ?? process.arch}`; const key = `${process.platform}_${process.env.YAAK_TARGET_ARCH ?? process.arch}`;
console.log(`Vendoring protoc ${VERSION} for ${key}`); console.log(`Vendoring protoc ${VERSION} for ${key}`);