pake-cli 3.11.1 โ 3.11.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cli.js +1 -1
- package/package.json +1 -1
- package/src-tauri/Cargo.lock +1 -1
- package/src-tauri/Cargo.toml +1 -1
- package/src-tauri/src/app/window.rs +12 -3
- package/src-tauri/src/inject/event.js +4 -16
- package/src-tauri/tauri.conf.json +1 -1
package/dist/cli.js
CHANGED
|
@@ -22,7 +22,7 @@ import * as psl from 'psl';
|
|
|
22
22
|
import { InvalidArgumentError, program as program$1, Option } from 'commander';
|
|
23
23
|
|
|
24
24
|
var name = "pake-cli";
|
|
25
|
-
var version = "3.11.
|
|
25
|
+
var version = "3.11.2";
|
|
26
26
|
var description = "๐คฑ๐ป Turn any webpage into a desktop app with one command. ๐คฑ๐ป ไธ้ฎๆๅ
็ฝ้กต็ๆ่ฝป้ๆก้ขๅบ็จใ";
|
|
27
27
|
var engines = {
|
|
28
28
|
node: ">=18.0.0"
|
package/package.json
CHANGED
package/src-tauri/Cargo.lock
CHANGED
package/src-tauri/Cargo.toml
CHANGED
|
@@ -369,11 +369,20 @@ fn build_window(
|
|
|
369
369
|
}
|
|
370
370
|
|
|
371
371
|
if let Some(features) = new_window_features {
|
|
372
|
-
//
|
|
372
|
+
// macOS popup webviews must reuse the opener webview configuration.
|
|
373
373
|
#[cfg(target_os = "macos")]
|
|
374
374
|
{
|
|
375
|
-
let
|
|
376
|
-
|
|
375
|
+
if let Some(position) = features.position() {
|
|
376
|
+
window_builder = window_builder.position(position.x, position.y);
|
|
377
|
+
}
|
|
378
|
+
|
|
379
|
+
if let Some(size) = features.size() {
|
|
380
|
+
window_builder = window_builder.inner_size(size.width, size.height);
|
|
381
|
+
}
|
|
382
|
+
|
|
383
|
+
window_builder = window_builder
|
|
384
|
+
.with_webview_configuration(features.opener().target_configuration.clone())
|
|
385
|
+
.focused(true);
|
|
377
386
|
}
|
|
378
387
|
|
|
379
388
|
#[cfg(not(target_os = "macos"))]
|
|
@@ -534,7 +534,7 @@ document.addEventListener("DOMContentLoaded", () => {
|
|
|
534
534
|
return;
|
|
535
535
|
}
|
|
536
536
|
|
|
537
|
-
// Handle _blank links:
|
|
537
|
+
// Handle _blank links: internal links stay in-app, external links open in the system browser
|
|
538
538
|
if (target === "_blank") {
|
|
539
539
|
if (forceInternalNavigation) {
|
|
540
540
|
e.preventDefault();
|
|
@@ -550,13 +550,7 @@ document.addEventListener("DOMContentLoaded", () => {
|
|
|
550
550
|
|
|
551
551
|
e.preventDefault();
|
|
552
552
|
e.stopImmediatePropagation();
|
|
553
|
-
|
|
554
|
-
window,
|
|
555
|
-
absoluteUrl,
|
|
556
|
-
"_blank",
|
|
557
|
-
"width=1200,height=800,scrollbars=yes,resizable=yes",
|
|
558
|
-
);
|
|
559
|
-
if (!newWindow) handleExternalLink(absoluteUrl);
|
|
553
|
+
handleExternalLink(absoluteUrl);
|
|
560
554
|
return;
|
|
561
555
|
}
|
|
562
556
|
|
|
@@ -587,7 +581,7 @@ document.addEventListener("DOMContentLoaded", () => {
|
|
|
587
581
|
return;
|
|
588
582
|
}
|
|
589
583
|
|
|
590
|
-
// Handle regular links: internal URLs allow normal navigation, external
|
|
584
|
+
// Handle regular links: internal URLs allow normal navigation, external links open in the system browser
|
|
591
585
|
if (!target || target === "_self") {
|
|
592
586
|
// Optimization: Allow previewable media to be handled by the app/browser directly
|
|
593
587
|
// This fixes issues where CDN links are treated as external
|
|
@@ -602,13 +596,7 @@ document.addEventListener("DOMContentLoaded", () => {
|
|
|
602
596
|
|
|
603
597
|
e.preventDefault();
|
|
604
598
|
e.stopImmediatePropagation();
|
|
605
|
-
|
|
606
|
-
window,
|
|
607
|
-
absoluteUrl,
|
|
608
|
-
"_blank",
|
|
609
|
-
"width=1200,height=800,scrollbars=yes,resizable=yes",
|
|
610
|
-
);
|
|
611
|
-
if (!newWindow) handleExternalLink(absoluteUrl);
|
|
599
|
+
handleExternalLink(absoluteUrl);
|
|
612
600
|
}
|
|
613
601
|
}
|
|
614
602
|
}
|