UX: Disable comparison tool if not logged in
This commit is contained in:
parent
5c56651b5e
commit
065f03691f
1 changed files with 29 additions and 25 deletions
|
@ -15,6 +15,7 @@
|
|||
import AccordionSingle from "../Flowbite/AccordionSingle.svelte"
|
||||
import GlobeAlt from "@babeard/svelte-heroicons/mini/GlobeAlt"
|
||||
import { ComparisonState } from "./ComparisonState"
|
||||
import LoginToggle from "../Base/LoginToggle.svelte"
|
||||
|
||||
export let externalData: Store<
|
||||
| { success: { content: Record<string, string> } }
|
||||
|
@ -45,6 +46,8 @@
|
|||
let enableLogin = state.featureSwitches.featureSwitchEnableLogin
|
||||
</script>
|
||||
|
||||
<LoginToggle {state} silentFail>
|
||||
|
||||
{#if !$sourceUrl || !$enableLogin}
|
||||
<!-- empty block -->
|
||||
{:else if $externalData === undefined}
|
||||
|
@ -77,3 +80,4 @@
|
|||
/>
|
||||
</AccordionSingle>
|
||||
{/if}
|
||||
</LoginToggle>
|
||||
|
|
Loading…
Reference in a new issue