Commit 7bdfd3d
fix(sweetlink): bind --serve to 0.0.0.0 + clipboard fallback for file://
Fixes two issues from hook feedback:
1. report --serve: Now binds to 0.0.0.0 (all interfaces) instead of
loopback. Prints both local and network URLs with LAN IP auto-detection.
Other devices on the network can now access the served viewer.
2. Viewer Copy Report: Falls back to document.execCommand('copy') when
navigator.clipboard is unavailable (file:// contexts, non-HTTPS).
The downloaded standalone viewer now works offline for clipboard copy.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>1 parent 8e6d86f commit 7bdfd3d
2 files changed
Lines changed: 33 additions & 4 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2874 | 2874 | | |
2875 | 2875 | | |
2876 | 2876 | | |
2877 | | - | |
2878 | | - | |
2879 | | - | |
| 2877 | + | |
| 2878 | + | |
| 2879 | + | |
| 2880 | + | |
| 2881 | + | |
| 2882 | + | |
| 2883 | + | |
| 2884 | + | |
| 2885 | + | |
| 2886 | + | |
| 2887 | + | |
| 2888 | + | |
| 2889 | + | |
| 2890 | + | |
| 2891 | + | |
| 2892 | + | |
2880 | 2893 | | |
2881 | 2894 | | |
2882 | 2895 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
524 | 524 | | |
525 | 525 | | |
526 | 526 | | |
| 527 | + | |
| 528 | + | |
| 529 | + | |
| 530 | + | |
| 531 | + | |
| 532 | + | |
| 533 | + | |
| 534 | + | |
| 535 | + | |
| 536 | + | |
| 537 | + | |
| 538 | + | |
| 539 | + | |
| 540 | + | |
| 541 | + | |
| 542 | + | |
527 | 543 | | |
528 | 544 | | |
529 | 545 | | |
530 | | - | |
| 546 | + | |
531 | 547 | | |
532 | 548 | | |
533 | 549 | | |
| |||
0 commit comments