Commit graph

5,416 commits

Author SHA1 Message Date
github-actions[bot]
0143928943 chore(v3): bump to v3.0.0-alpha.66 and update changelog [skip ci] v3.0.0-alpha.66 2026-02-03 03:07:03 +00:00
Lea Anthony
cef60037fd fix(v3): implement file picker for input type=file on macOS (#4862)
Add WKUIDelegate protocol support to handle runOpenPanelWithParameters
delegate method, which is required for <input type="file"> elements to
work in WKWebView on macOS. This was a regression from V2 which had
this implementation.

Changes:
- Add WKUIDelegate to WebviewWindowDelegate protocol list
- Set UIDelegate on WKWebView during window creation
- Implement runOpenPanelWithParameters to show NSOpenPanel for file selection

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-02-03 06:59:57 +11:00
ddmoney420
1f45359485
fix(v3/linux): fix OpenFileDialog crash from GTK thread violation (#4926)
* fix(v3/linux): fix OpenFileDialog crash from GTK thread violation

The runChooserDialog function had a race condition that caused GTK
assertion failures and crashes on Linux:

1. InvokeAsync scheduled gtk_dialog_run on the GTK thread
2. After dialog closed, a goroutine was spawned OFF the GTK thread
3. gtk_widget_destroy was called immediately (before goroutine ran)
4. Goroutine tried to call gtk_file_chooser_get_filenames on destroyed widget

Fix:
- Extract filenames on GTK thread BEFORE destroying widget
- Call gtk_widget_destroy on GTK thread AFTER extraction
- Goroutine only handles sending Go strings (no GTK calls)

Fixes #3683

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>

* docs: add changelog entry for OpenFileDialog crash fix

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>

* fix: properly free all filenames to prevent memory leak

When more than 1024 files are selected, the previous code leaked memory
because g_slist_free() only frees list nodes, not the data pointers.
Now we iterate through ALL entries, freeing each filename string.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>

* refactor: remove arbitrary 1024 file selection limit

GTK's gtk_file_chooser_get_filenames() has no documented maximum.
The limit was arbitrary and unnecessary.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>

* docs: add comment about no file selection limit

Consistent with Windows/macOS behavior.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>

---------

Co-authored-by: ddmoney420 <ddmoney420@users.noreply.github.com>
Co-authored-by: Claude Opus 4.5 <noreply@anthropic.com>
Co-authored-by: Lea Anthony <lea.anthony@gmail.com>
2026-02-03 06:09:40 +11:00
ddmoney420
a572244e62
fix(v3): add nil check to Focus() to prevent SIGSEGV after Hide (#4922)
* fix(v3): add nil check to Focus() to prevent SIGSEGV after Hide

The Focus() method was missing a nil/destroyed check on w.impl,
causing a SIGSEGV when Focus() is called on a window that has been
hidden and potentially destroyed (e.g., when clicking the dock icon
after hiding the window on macOS).

This aligns Focus() with Show() and Hide() which already have proper
guards against nil/destroyed window implementations.

Fixes #4890

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>

* docs: add changelog entry for Focus() nil check fix

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>

---------

Co-authored-by: ddmoney420 <ddmoney420@users.noreply.github.com>
Co-authored-by: Claude Opus 4.5 <noreply@anthropic.com>
Co-authored-by: Lea Anthony <lea.anthony@gmail.com>
2026-02-02 10:10:36 +00:00
Lea Anthony
37e57f679d
fix(v3/windows): Move browser flags to application-level options (#4559) (#4946)
* fix(v3/windows): Move browser flags to application-level options (#4559)

WebView2 shares a single browser environment per user data path, so
browser flags (EnabledFeatures, DisabledFeatures, AdditionalBrowserArgs)
must be set at application level, not per-window.

Changes:
- Add EnabledFeatures, DisabledFeatures, AdditionalBrowserArgs to
  application.Options.Windows
- Mark per-window equivalents in WindowsWindow as deprecated
- Update webview_window_windows.go to read from app-level options

This fixes the crash when opening a second window with different
browser flags.

Fixes #4559

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>

* fix: address PR review comments

- Remove incorrectly added WebviewGpuPolicy field from WindowsOptions
  (it's a Linux-specific option that already exists in LinuxWindow)
- Clarify changelog: AdditionalLaunchArgs was renamed to AdditionalBrowserArgs

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>

* refactor!: remove per-window browser flags (breaking change)

BREAKING CHANGE: Remove EnabledFeatures, DisabledFeatures, and
AdditionalLaunchArgs from per-window WindowsWindow options.

Use application-level options instead:
- Options.Windows.EnabledFeatures
- Options.Windows.DisabledFeatures
- Options.Windows.AdditionalBrowserArgs

These flags apply globally to the shared WebView2 environment,
so per-window configuration was never actually supported.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>

* docs: add documentation for application-level browser flags

- Document EnabledFeatures, DisabledFeatures, AdditionalBrowserArgs
- Add examples showing how to configure WebView2 browser flags
- Explain that these flags apply globally to all windows
- Update application API reference with platform-specific options

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>

* chore: simplify browser flags documentation

Remove unnecessary warnings and overly prescriptive comments.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>

* docs: clarify that AdditionalBrowserArgs requires -- prefix

Chromium command-line switches require the -- prefix.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>

---------

Co-authored-by: Claude Opus 4.5 <noreply@anthropic.com>
2026-02-02 20:49:08 +11:00
Fabio Massaioli
04d99e376c
[v3] Fix global state in Collector.IsVoidAlias predicate (#4941)
* Accept obscure update to package-lock.json

* Make global state local in Collector.IsVoidAlias predicate

* Add protection against potential nil dereference

* Update test data

* Fix typo in doc comment

Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>

* Update UNRELEASED_CHANGELOG.md

---------

Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>
2026-02-02 09:44:56 +00:00
ddmoney420
5d0dd30685
fix(v3): guard dispatchWailsEvent against race condition on reload (#4925)
* fix(v3): guard dispatchWailsEvent against race condition on reload

When the page is reloaded, the WindowLoadFinished event can fire before
the JavaScript runtime has mounted dispatchWailsEvent on window._wails.
This causes a TypeError: window._wails.dispatchWailsEvent is not a function.

This fix adds a guard to check if window._wails and dispatchWailsEvent
exist before attempting to call the function. If the runtime isn't ready,
the event is silently skipped (which is correct since there's no handler).

Fixes #4872

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>

* docs: Add changelog entry for #4872

---------

Co-authored-by: ddmoney420 <ddmoney420@users.noreply.github.com>
Co-authored-by: Claude Opus 4.5 <noreply@anthropic.com>
Co-authored-by: Lea Anthony <lea.anthony@gmail.com>
2026-02-02 20:00:18 +11:00
Lea Anthony
8b99993faa docs: Add changelog entry for #4925
Fix race condition causing TypeError during page reload.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-02-02 19:57:15 +11:00
Lea Anthony
fa06d48497
feat(v3): Add UseApplicationMenu option for cross-platform menu support (#4944)
* feat(v3): Add UseApplicationMenu option for cross-platform menu support

Add `UseApplicationMenu` option to `WebviewWindowOptions` that allows
windows on Windows and Linux to inherit the application menu set via
`app.Menu.Set()`.

This provides a simpler cross-platform approach:
- On macOS: No effect (app menu is always global)
- On Windows/Linux: Window displays the application menu

Benefits:
- Eliminates need for platform-specific menu code
- Per-window opt-in maintains backwards compatibility
- Explicit window menus still take priority

Updated:
- webview_window_options.go: Added UseApplicationMenu bool field
- webview_window_windows.go: Check UseApplicationMenu when no window menu set
- webview_window_linux.go: Check UseApplicationMenu when no window menu set
- examples/dialogs: Use UseApplicationMenu instead of conditional SetMenu
- examples/menu: Use UseApplicationMenu instead of explicit SetMenu
- docs: Updated menu and window options documentation

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>

* docs: Remove incorrect 'Menu Options' section header

---------

Co-authored-by: Claude Opus 4.5 <noreply@anthropic.com>
2026-02-02 19:51:31 +11:00
Ndianabasi Udonkang
470c929b42
Make menus to be displayed on Windows OS in v3\examples\dialogs (#4928)
* fix: make menus to be displayed on Windows OS in `v3\examples\dialogs`

* refactor: use cross-platform user home dir in `v3/examples/dialogs/main.go`

* fix: handle os.UserHomeDir() error with fallback to os.TempDir()

* fix: use = instead of := for err (already declared)

---------

Co-authored-by: Lea Anthony <lea.anthony@gmail.com>
2026-02-02 19:41:35 +11:00
Lea Anthony
f4ff0c0fde docs: add changelog entry for #3631 fix 2026-02-02 19:02:07 +11:00
Lea Anthony
b16458f121 fix(darwin): prevent panic on empty Icon slice in dialogs
Change nil checks to length checks before accessing Icon[0] to prevent
panic when Icon is an empty slice rather than nil.

Fixes #3631

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-02-02 19:01:41 +11:00
ddmoney420
19b2ec7fbe
fix(v3/linux): use g_bytes_new instead of g_bytes_new_static for Go slices (#4923)
* fix(v3): add nil check to Focus() to prevent SIGSEGV after Hide

The Focus() method was missing a nil/destroyed check on w.impl,
causing a SIGSEGV when Focus() is called on a window that has been
hidden and potentially destroyed (e.g., when clicking the dock icon
after hiding the window on macOS).

This aligns Focus() with Show() and Hide() which already have proper
guards against nil/destroyed window implementations.

Fixes #4890

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>

* fix(v3/linux): use g_bytes_new instead of g_bytes_new_static for Go slices

g_bytes_new_static expects truly static data that is never freed or
moved, but Go's garbage collector can move or free slice memory at any
time. This causes SIGSEGV crashes in the GTK event loop when the GC
runs and frees memory that GTK still references.

The fix replaces g_bytes_new_static with g_bytes_new, which copies the
data to C-owned memory that is safe from Go's GC.

Also fixes memory leak in setIcon() by adding proper g_bytes_unref and
g_object_unref calls for the GBytes and stream objects.

Changes:
- linux_cgo.go: Replace g_bytes_new_static with g_bytes_new (4 places)
- linux_cgo.go: Add cleanup in setIcon() for gbytes and stream
- linux_purego.go: Add gBytesNew binding and use it instead of static

Fixes #4864

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>

* fix(linux): add empty slice guards to prevent panic

Adds guards to check for empty slices before taking &slice[0] which
would panic on empty input. Affects setIcon(), menuItemAddProperties(),
menuItemSetBitmap(), and runQuestionDialog() in both CGO and purego.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>

---------

Co-authored-by: ddmoney420 <ddmoney420@users.noreply.github.com>
Co-authored-by: Claude Opus 4.5 <noreply@anthropic.com>
Co-authored-by: Lea Anthony <lea.anthony@gmail.com>
2026-02-02 07:57:34 +00:00
Lea Anthony
77cb9866a2 Revert "fix(linux): add empty slice guards to prevent panic in icon/bitmap handling"
This reverts commit 05cbe108de.
2026-02-02 18:36:55 +11:00
Lea Anthony
05cbe108de fix(linux): add empty slice guards to prevent panic in icon/bitmap handling
Adds guards to check for empty slices before taking &slice[0] which would
panic. Affects setIcon(), menuItemAddProperties(), menuItemSetBitmap(),
and runQuestionDialog() in both CGO and purego implementations.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-02-02 18:36:26 +11:00
github-actions[bot]
9d6c03ca57 chore(v3): bump to v3.0.0-alpha.65 and update changelog [skip ci] v3.0.0-alpha.65 2026-02-01 03:10:36 +00:00
Lea Anthony
284c67d037 perf(ci): use native ARM64 runner for linux/arm64 builds
Use ubuntu-24.04-arm runner for linux/arm64 cross-compile tests
instead of QEMU emulation. This should reduce build time from ~20min
to ~3min.

- Remove QEMU and Buildx setup (not needed with native runner)
- Remove --platform flag from Docker commands
- Each matrix entry now specifies its runner

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-02-01 10:10:58 +11:00
Wilko
2db6a1c427
feat(v3): Support for Icon Composer Liquid Glass Icons (macOS) (#4934)
* feat(icons): implement Mac asset (.car) generation with actool

- Check actool version >= 26 requirement
- Generate asset.car from Icon Composer input
- Validate compilation output and cleanup temp files

* Wails Icon as Icon Composer file

* a generated assets.car from the wails icon

* handle absolute paths correctly in actool command

- Check if paths are absolute before prepending "./"
- Use filepath.Join for temp.plist path construction

* add test for Assets.car generation

* Skipping Asset.car generation and test on non mac-systems

* add CFBundleIconName generation to plist, if Assets.car exists

* also create .icns from .icon-File and use always absolut path

Use absolut path, because otherwise we got strange behavior from actool.

* update to use appicon as CFBundleIconName and optionally use the name from config

* update the Taskfiles

* remove log prints

* the awesome new LiquidGlass icon files

* update doc

* Update UNRELEASED_CHANGELOG.md

* Update UNRELEASED_CHANGELOG.md

* fix security bug

* Skip icon generation test with actool on CI

* fix error from coderabbitai

* solved the coderabbitai nitpicks

* fix coderabbitai findings

* Update changelog

---------

Co-authored-by: Lea Anthony <lea.anthony@gmail.com>
2026-02-01 10:07:56 +11:00
Lea Anthony
7e74a5d9d0 fix(build): use QEMU emulation for Linux cross-arch builds
For Linux ARM64 builds on x86_64 hosts, use Docker's QEMU emulation
instead of trying to cross-compile with Zig or install multi-arch packages.

Changes:
- Workflow: Set up QEMU and Docker Buildx for Linux cross-arch builds
- Workflow: Build Docker image with --platform for target architecture
- Dockerfile: Simplify to use native GCC (QEMU handles arch translation)
- Taskfile: Add --platform flag to docker run for Linux builds

This approach is slower but reliable and doesn't require complex
cross-compilation toolchain setup.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-02-01 00:25:41 +11:00
Lea Anthony
d9348686dc fix(build): use proper cross-compilation toolchain for Linux ARM64
Instead of trying to use Zig for Linux cross-compilation (which has
glibc header compatibility issues), install the proper aarch64-linux-gnu
cross-compilation toolchain and ARM64 GTK/WebKit libraries.

Changes:
- Enable multi-arch and install gcc-aarch64-linux-gnu toolchain
- Install ARM64 versions of libgtk-3-dev and libwebkit2gtk-4.1-dev
- Set PKG_CONFIG_PATH for ARM64 libraries when cross-compiling
- Use aarch64-linux-gnu-gcc as the cross-compiler

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-02-01 00:19:04 +11:00
Lea Anthony
e6bf084197 fix(build): use Zig for Linux cross-arch compilation in Docker
Add Zig CC wrappers for Linux ARM64 and AMD64 targets. The build script
now detects if host architecture matches target architecture:
- If match: use native GCC (faster, better optimization)
- If different: use Zig for cross-compilation

This allows building Linux ARM64 binaries from an x86_64 Docker host
without requiring multi-arch images or QEMU emulation.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-02-01 00:12:09 +11:00
Lea Anthony
985ce8deed fix(build): remove --platform flag from Linux cross-compile Docker
The wails-cross image is an x86_64 image that uses Zig for cross-compilation.
It doesn't need to run ON the target platform - it cross-compiles TO it.
Remove the --platform flag that was causing Docker to try pulling a
non-existent arm64 version of the image.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-02-01 00:05:00 +11:00
Lea Anthony
d5cd33d4fb fix(build): use Docker for cross-arch Linux compilation
When building Linux binaries with a different target architecture than
the host (e.g., arm64 on x86_64), use Docker-based cross-compilation
instead of native build. The native GCC cannot compile ARM64 assembly
on an x86_64 host.

Adds a third condition to the build task selection: target architecture
must match host architecture to use native build.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-31 23:53:41 +11:00
Lea Anthony
259c33dfda fix(ci): use absolute path for replace directive in Docker build
The Docker mounts v3 at the same absolute path, so change the replace
directive to use the absolute workspace path instead of removing it.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-31 23:45:05 +11:00
Lea Anthony
513669bf13 fix(ci): remove replace directive before Docker cross-compile
The project created by wails3 init has a replace directive pointing
to the local v3 source. This doesn't work inside Docker containers.
Remove it before running the cross-compile tasks.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-31 23:38:18 +11:00
Lea Anthony
4af09b43a8 fix(ci): use correct task names for cross-compilation
- common:setup:docker instead of setup:docker
- darwin:build, linux:build, windows:build instead of build:darwin, etc.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-31 23:24:42 +11:00
Lea Anthony
72fcf2fa1c fix(ci): use Go 1.25 and go install for wails3 CLI
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-31 22:57:56 +11:00
Lea Anthony
fb0f10ca70 fix(ci): add Linux dependencies for wails3 CLI build
The wails3 CLI requires webkit2gtk, gtk, and other Linux libraries
to compile due to CGO dependencies.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-31 22:57:16 +11:00
Lea Anthony
46d27c526b fix(ci): use wails3 init and task-based cross-compile workflow
Instead of building Docker images from scratch, the workflow now:
- Installs wails3 CLI
- Creates a test project with wails3 init
- Runs setup:docker to build the cross-compile image
- Uses task build:<platform> for cross-compilation

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-31 22:49:52 +11:00
Lea Anthony
df2175b950 fix(docker): add BuildKit syntax directive for heredoc support
The Dockerfiles use heredoc syntax which requires BuildKit's
dockerfile:1 syntax directive to parse correctly.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-31 22:48:41 +11:00
Lea Anthony
403be215a2 feat(ci): add cross-compile test workflow for v3 PRs
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-31 22:45:13 +11:00
Lea Anthony
cf42f57592 ci: add registry caching for faster Docker builds
Adds registry-based cache alongside GHA cache to improve build times
when GHA cache is evicted (7-day retention limit).

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-31 08:50:48 +11:00
Lea Anthony
9742aec9af ci: add linux/amd64 to cross-compile tests
Always use linux:build:docker for Linux targets to properly test
the Docker image for both amd64 and arm64 architectures.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-31 08:41:53 +11:00
drc5521
679e4843d2
Update 03-notes-vanilla.mdx (#4917)
* Update 03-notes-vanilla.mdx

The API has been hanged.
application.SaveFileDialog() -> application.Get().Dialog.SaveFile()
application.OpenFileDialog() -> application.Get().Dialog.OpenFile()
application.InfoDialog() -> application.Get().Dialog.Info()

Please refer to the document.
https://v3alpha.wails.io/reference/dialogs/

* Update docs/src/content/docs/tutorials/03-notes-vanilla.mdx

Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>

---------

Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>
2026-01-29 06:04:45 +11:00
Lea Anthony
ec78af1fee ci: remove darwin/amd64 from cross-compile tests
Intel Macs are EOL (last released 2020, support ending ~2027).
Focus testing on darwin/arm64 which is the current/future platform.
The Dockerfile still supports amd64 if needed.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-28 09:59:15 +11:00
Lea Anthony
c8b4d8534b ci: pull correct platform variant for Docker image
The task uses --platform flag which requires the matching architecture
variant. Pull arm64 variant explicitly for Linux arm64 test.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-28 09:38:07 +11:00
Lea Anthony
bc13f7377a ci: force Docker build for Linux arm64 cross-compilation
The linux:build task chooses native build when gcc is available,
but native x86_64 gcc can't cross-compile to arm64 (assembly errors).
Explicitly call linux:build:docker for Linux arm64 target.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-28 09:30:09 +11:00
Lea Anthony
c8fc68a66b ci: pull and tag Docker image as 'wails-cross' for task system
The wails3 task system expects a locally tagged 'wails-cross' image.
Pull from ghcr.io and tag it appropriately before running tasks.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-28 09:23:15 +11:00
Lea Anthony
2f534f0a5e ci: fix conflicting replace directive in test project
wails3 init already adds a replace directive with relative path.
Use sed to update it to absolute path instead of adding a duplicate.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-28 09:18:23 +11:00
Lea Anthony
282854a964 ci: add amd64 cross-compile tests for darwin and windows
Tests 5 cross-compilation targets from Linux/amd64 runner:
- darwin/amd64, darwin/arm64 (cross-platform)
- windows/amd64, windows/arm64 (cross-platform)
- linux/arm64 (cross-architecture)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-28 09:17:40 +11:00
Lea Anthony
65b1b838f2 ci: use wails3 task system for cross-compile tests
- Use `wails3 task {os}:build` instead of manual Docker commands
- Test actual cross-compilation only (skip host-to-host):
  - darwin/arm64 from Linux/amd64
  - windows/arm64 from Linux/amd64
  - linux/arm64 from Linux/amd64
- Let task system handle frontend build, bindings, etc.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-28 09:10:27 +11:00
Lea Anthony
7bbfc52ca7 ci: generate bindings before frontend build
The frontend build requires Go bindings to be generated first.
Run `wails3 generate bindings` on the host before building frontend.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-28 09:07:15 +11:00
Lea Anthony
39e5d47477 ci: install Linux dev dependencies for wails3 CLI build
The wails3 CLI requires GTK3/WebKit2GTK dev packages to build on
the GitHub runner (for CGO).

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-28 08:58:43 +11:00
Lea Anthony
7b7c27271d ci: simplify cross-compile tests to 3 parallel platform jobs
- Use 3 parallel jobs (darwin, linux, windows) instead of 6
- Each job builds both amd64 and arm64 architectures
- Use real wails3 projects via `wails3 init` instead of fake test programs
- Remove pointless non-CGO tests
- Keep library dependency verification for Linux binaries

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-28 08:55:37 +11:00
Lea Anthony
6592db81cb ci: add cross-compiler image build workflow
Adds workflow to build and test the wails-cross Docker image:
- Builds multi-arch image (amd64/arm64)
- Tests cross-compilation for all 6 platform/arch combinations
- Tests both CGO and non-CGO builds
- Verifies Linux binary library dependencies with readelf
- Publishes to ghcr.io/wailsapp/wails-cross

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-28 08:37:45 +11:00
Lea Anthony
70c969bf3b feat(build): use GCC for Linux cross-compilation
- Switch from Alpine to Debian (golang:1.25-bookworm)
- Install GTK3/GTK4 and WebKit2GTK 4.1/6.0 dev packages
- Use native GCC for Linux targets instead of Zig
- Add --platform flag to Docker run for architecture matching
- Remove unused zcc-linux-* wrappers (Zig had glibc header issues)
- Keep Zig for Darwin (macOS SDK) and Windows (bundled mingw)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-28 08:36:45 +11:00
Lea Anthony
f91b8cfeb1 feat: support ARM64 hosts in cross-compiler Docker image
Add TARGETARCH detection to download the correct Zig binary for
the host architecture (aarch64 vs x86_64). This enables native
performance on Apple Silicon Macs instead of requiring emulation.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-27 06:32:47 +11:00
github-actions[bot]
279eea9799 chore(v3): bump to v3.0.0-alpha.64 and update changelog [skip ci] v3.0.0-alpha.64 2026-01-26 02:56:39 +00:00
GitHub Actions
a23c3c4e87 [skip ci] Publish @wailsio/runtime v3.0.0-alpha.79 2026-01-25 03:34:50 +00:00
Lea Anthony
9a363d7be5
feat(v3): add server mode for headless HTTP deployment (#4903)
* feat(v3): add server mode for headless HTTP deployment

Server mode allows Wails applications to run as pure HTTP servers
without native GUI dependencies. Enable with `-tags server` build tag.

Features:
- HTTP server with configurable host/port via ServerOptions
- WAILS_SERVER_HOST and WAILS_SERVER_PORT env var overrides
- WebSocket event broadcasting to connected browsers
- Browser clients represented as BrowserWindow (Window interface)
- Health check endpoint at /health
- Graceful shutdown with configurable timeout
- Docker support with Dockerfile.server template and tasks

Build and run:
  wails3 task build:server
  wails3 task run:server
  wails3 task build:docker
  wails3 task run:docker

Documentation at docs/guides/server-build.mdx

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>

* feat(v3): add server mode for headless HTTP deployment

Server mode allows Wails applications to run as pure HTTP servers
without native GUI dependencies. Enable with `-tags server` build tag.

Features:
- HTTP server with configurable host/port via ServerOptions
- WAILS_SERVER_HOST and WAILS_SERVER_PORT env var overrides
- WebSocket event broadcasting to connected browsers
- Browser clients represented as BrowserWindow (Window interface)
- Health check endpoint at /health
- Graceful shutdown with configurable timeout
- Docker support with Dockerfile.server template and tasks

Build and run:
  wails3 task build:server
  wails3 task run:server
  wails3 task build:docker
  wails3 task run:docker

Documentation at docs/guides/server-build.mdx

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>

* fix: address CodeRabbit review comments

- Fix corrupted test file with embedded terminal output
- Fix module name mismatch in gin-routing (was gin-example)
- Fix replace directive version mismatch in gin-service
- Fix placeholder module name in ios example (was changeme)
- Fix Dockerfile COPY path to work from both build contexts
- Fix bare URL in README (MD034 compliance)
- Fix comment accuracy in getScreens (returns error, not empty slice)
- Remove deprecated docker-compose version field
- Add port documentation in Taskfile template

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>

* fix: address CodeRabbit review comments

- Add note about healthcheck wget not being available in distroless images
- Add !server build constraint to menu_windows.go and menu_darwin.go
- Downgrade window-visibility-test go.mod from 1.25 to 1.24 to match CI

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>

---------

Co-authored-by: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-25 14:33:44 +11:00