From 9462cec9a7dc5b6722df464559721cd2445636e6 Mon Sep 17 00:00:00 2001
From: Kristóf Marussy <kristof@marussy.com>
Date: Wed, 20 Apr 2022 00:28:38 +0200
Subject: feat: Always show location bar on error
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit

The location bar should be visible on error page to let people see and
change the URL if needed.

Additionally, it must be visible on insecure connections to show people
that the connection if not secure.

In the future, the location bar should also be shown if the loaded
website is uncommon in the context of the current service, i.e., it is
not explcitly allowlisted by the recipe.

Signed-off-by: Kristóf Marussy <kristof@marussy.com>
---
 packages/renderer/src/components/locationBar/LocationBar.tsx | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

(limited to 'packages/renderer/src/components/locationBar/LocationBar.tsx')

diff --git a/packages/renderer/src/components/locationBar/LocationBar.tsx b/packages/renderer/src/components/locationBar/LocationBar.tsx
index fc9c147..54ead8e 100644
--- a/packages/renderer/src/components/locationBar/LocationBar.tsx
+++ b/packages/renderer/src/components/locationBar/LocationBar.tsx
@@ -43,11 +43,12 @@ const LocationBarRoot = styled('header', {
 
 function LocationBar(): JSX.Element {
   const {
-    settings: { selectedService, showLocationBar },
+    shared: { locationBarVisible },
+    settings: { selectedService },
   } = useStore();
 
   return (
-    <LocationBarRoot id={LOCATION_BAR_ID} hidden={!showLocationBar}>
+    <LocationBarRoot id={LOCATION_BAR_ID} hidden={!locationBarVisible}>
       <NavigationButtons service={selectedService} />
       <LocationTextField service={selectedService} />
       <ExtraButtons service={selectedService} />
-- 
cgit v1.2.3-70-g09d2

