From 331af4bcc9623cb8bffd2816933146d550b7201f Mon Sep 17 00:00:00 2001 From: Alexandre <44178713+alexbelgium@users.noreply.github.com> Date: Sun, 30 Aug 2026 07:59:04 +0200 Subject: [PATCH] fix(filebrowser_quantum): navigate in place instead of opening a new tab under ingress (#3026) The tool views (Tools -> File Size Analyzer, Duplicate Finder, the file list panel) always pass showLimitedOptions to the context menu, and the context menu's openParentFolder() hands that same flag to goToItem() as its newTab argument. The parent folder is therefore opened with window.open(, '_blank'). Behind Home Assistant ingress that popup lands on the raw /api/hassio_ingress// URL with no Home Assistant frontend around it to keep the ingress session alive, so the new tab answers 401 instead of showing the folder. The ingress vhost now injects the same window.open shim the komga add-on uses, scoped to the two SPA route prefixes goToItem() builds ('files/' and 'public/share/'), so download and preview popups keep their own tab. Co-authored-by: Claude Opus 5 --- filebrowser_quantum/CHANGELOG.md | 11 +++++++ filebrowser_quantum/config.yaml | 2 +- .../rootfs/etc/nginx/servers/ingress.conf | 31 ++++++++++++++++++- 3 files changed, 42 insertions(+), 2 deletions(-) diff --git a/filebrowser_quantum/CHANGELOG.md b/filebrowser_quantum/CHANGELOG.md index 96f1fa8e88..2830d0b05a 100644 --- a/filebrowser_quantum/CHANGELOG.md +++ b/filebrowser_quantum/CHANGELOG.md @@ -1,4 +1,15 @@ +## 1.5.3.1 (2026-08-29) +- Fix "open parent directory" in Tools -> File Size Analyzer under Home + Assistant ingress. FileBrowser opened the parent folder in a new tab, which + lands on the raw ingress URL with no Home Assistant frontend around it to + keep the ingress session alive, so the new tab answered 401 instead of + showing the folder. The ingress vhost now turns that popup into a navigation + of the panel itself. The same fix covers the other tool views and the "go to + item" action on search results, which open a new tab the same way. Download + and preview popups, links pointing out of the add-on, and direct access on + port 8071 are unchanged. + ## 1.5.3 (2026-08-29) - Update to latest version from gtsteffaniak/filebrowser (changelog : https://github.com/gtsteffaniak/filebrowser/releases) diff --git a/filebrowser_quantum/config.yaml b/filebrowser_quantum/config.yaml index c3be4e0041..3b289e8d3c 100644 --- a/filebrowser_quantum/config.yaml +++ b/filebrowser_quantum/config.yaml @@ -118,4 +118,4 @@ schema: slug: filebrowser_quantum udev: true url: https://github.com/alexbelgium/hassio-addons -version: "1.5.3" +version: "1.5.3.1" diff --git a/filebrowser_quantum/rootfs/etc/nginx/servers/ingress.conf b/filebrowser_quantum/rootfs/etc/nginx/servers/ingress.conf index f62b732e2d..119fe636f4 100644 --- a/filebrowser_quantum/rootfs/etc/nginx/servers/ingress.conf +++ b/filebrowser_quantum/rootfs/etc/nginx/servers/ingress.conf @@ -3,7 +3,7 @@ server { include /etc/nginx/includes/server_params.conf; include /etc/nginx/includes/proxy_params.conf; - + client_max_body_size 0; location / { @@ -12,6 +12,35 @@ server { proxy_send_timeout 30m; proxy_read_timeout 30m; proxy_pass %%protocol%%://backend%%subpath%%; + + # Tools -> File Size Analyzer (and the other tool views) open a result's + # parent folder with window.open(, '_blank'), because + # goToItem() takes its newTab argument from the context menu's + # showLimitedOptions flag, which those views always set. Behind ingress + # that popup lands on the raw /api/hassio_ingress// url with no + # Home Assistant frontend around it to keep the ingress session alive, + # so the new tab answers 401 instead of showing the folder. Turn that + # popup into a navigation of the panel itself. + # + # The context menu's "go to item" action, which search results and the + # tool views also offer, hardcodes the same new tab and is fixed too. + # + # Scoped to the two prefixes goToItem() builds, "files/" and + # "public/share/", so the window.open calls that download or preview a + # file (they go to api/resources/download) keep their own tab: sending + # an inline raw file to location.assign would replace the whole app. + # A link out of the add-on keeps its own tab as well, unless a user + # points a sidebar link (or a link inside a file open in the editor) at + # this same instance's files/ or public/share/ route, which then also + # opens in the panel. Same shape as the komga add-on's ingress filter. + # + # Injected into the page's existing nonce-carrying inline script rather + # than next to
: FileBrowser sends + # script-src 'self' 'nonce-', so a standalone inline