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 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.1";
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
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "pake-cli",
3
- "version": "3.11.1",
3
+ "version": "3.11.2",
4
4
  "description": "๐Ÿคฑ๐Ÿป Turn any webpage into a desktop app with one command. ๐Ÿคฑ๐Ÿป ไธ€้”ฎๆ‰“ๅŒ…็ฝ‘้กต็”Ÿๆˆ่ฝป้‡ๆกŒ้ขๅบ”็”จใ€‚",
5
5
  "engines": {
6
6
  "node": ">=18.0.0"
@@ -2564,7 +2564,7 @@ dependencies = [
2564
2564
 
2565
2565
  [[package]]
2566
2566
  name = "pake"
2567
- version = "3.11.1"
2567
+ version = "3.11.2"
2568
2568
  dependencies = [
2569
2569
  "serde",
2570
2570
  "serde_json",
@@ -1,6 +1,6 @@
1
1
  [package]
2
2
  name = "pake"
3
- version = "3.11.1"
3
+ version = "3.11.2"
4
4
  description = "๐Ÿคฑ๐Ÿป Turn any webpage into a desktop app with Rust."
5
5
  authors = ["Tw93"]
6
6
  license = "MIT"
@@ -369,11 +369,20 @@ fn build_window(
369
369
  }
370
370
 
371
371
  if let Some(features) = new_window_features {
372
- // window_features() crashes on macOS; only apply on other platforms.
372
+ // macOS popup webviews must reuse the opener webview configuration.
373
373
  #[cfg(target_os = "macos")]
374
374
  {
375
- let _ = features;
376
- window_builder = window_builder.focused(true);
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: same domain navigates in-app, cross-domain opens new window
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
- const newWindow = originalWindowOpen.call(
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 opens new window
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
- const newWindow = originalWindowOpen.call(
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
  }
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "productName": "Weekly",
3
3
  "identifier": "com.pake.weekly",
4
- "version": "3.11.1",
4
+ "version": "3.11.2",
5
5
  "app": {
6
6
  "withGlobalTauri": true,
7
7
  "trayIcon": {