mirror of
https://github.com/Frooodle/Stirling-PDF.git
synced 2026-04-22 23:08:53 +02:00
Desktop: Fallback to local backend if self-hosted server is offline (#5880)
* Adds a fallback mechanism so the desktop app routes tool operations to the local bundled backend when the user's self-hosted Stirling-PDF server goes offline, and disables tools in the UI that aren't supported locally. * `selfHostedServerMonitor.ts` independently polls the self-hosted server every 15s and exposes which tool endpoints are unavailable when it goes offline * `operationRouter.ts` intercepts operations destined for the self-hosted server and reroutes them to the local bundled backend when the monitor reports it offline * `useSelfHostedToolAvailability.ts` feeds the offline tool set into useToolManagement, disabling affected tools in the UI with a selfHostedOffline reason and banner warning - `SelfHostedOfflineBanner `is a dismissable (session-only) gray bar shown at the top of the UI when in self-hosted mode and the server goes offline. It shows:
This commit is contained in:
@@ -5726,6 +5726,40 @@ placeholder = "Enter search term..."
|
||||
searching = "Searching..."
|
||||
title = "Search PDF"
|
||||
|
||||
[selfHosted]
|
||||
|
||||
[selfHosted.offline]
|
||||
hideTools = "Hide unavailable tools ▴"
|
||||
messageNoFallback = "Tools are unavailable until your server comes back online."
|
||||
messageWithFallback = "Some tools require a server connection."
|
||||
showTools = "View unavailable tools ▾"
|
||||
title = "Your Stirling-PDF server is unreachable"
|
||||
toolNotAvailableLocally = "Your Stirling-PDF server is offline and \"{{endpoint}}\" is not available on the local backend."
|
||||
|
||||
[selfHosted.offline.conversionTypes]
|
||||
cbr-to-pdf = "CBR → PDF"
|
||||
cbz-to-pdf = "CBZ → PDF"
|
||||
eml-to-pdf = "Email → PDF"
|
||||
ebook-to-pdf = "eBook → PDF"
|
||||
file-to-pdf = "Office/Document → PDF"
|
||||
html-to-pdf = "HTML → PDF"
|
||||
img-to-pdf = "Image → PDF"
|
||||
markdown-to-pdf = "Markdown → PDF"
|
||||
pdf-to-cbr = "PDF → CBR"
|
||||
pdf-to-cbz = "PDF → CBZ"
|
||||
pdf-to-csv = "PDF → CSV"
|
||||
pdf-to-epub = "PDF → EPUB"
|
||||
pdf-to-html = "PDF → HTML"
|
||||
pdf-to-img = "PDF → Image"
|
||||
pdf-to-markdown = "PDF → Markdown"
|
||||
pdf-to-pdfa = "PDF → PDF/A"
|
||||
pdf-to-presentation = "PDF → Presentation"
|
||||
pdf-to-text = "PDF → Text"
|
||||
pdf-to-word = "PDF → Word"
|
||||
pdf-to-xml = "PDF → XML"
|
||||
pdf-to-xlsx = "PDF → XLSX"
|
||||
svg-to-pdf = "SVG → PDF"
|
||||
|
||||
[session]
|
||||
expired = "Your session has expired. Please refresh the page and try again."
|
||||
refreshPage = "Refresh Page"
|
||||
@@ -6531,6 +6565,7 @@ favorites = "Favourites"
|
||||
heading = "All tools (fullscreen view)"
|
||||
noResults = "Try adjusting your search or toggle descriptions to find what you need."
|
||||
recommended = "Recommended"
|
||||
selfHostedOffline = "Requires your Stirling-PDF server (currently offline):"
|
||||
showDetails = "Show Details"
|
||||
unavailable = "Disabled by server administrator:"
|
||||
unavailableDependency = "Unavailable - required tool missing on server:"
|
||||
|
||||
Reference in New Issue
Block a user