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 AccordionSingle from "../Flowbite/AccordionSingle.svelte"
|
||||||
import GlobeAlt from "@babeard/svelte-heroicons/mini/GlobeAlt"
|
import GlobeAlt from "@babeard/svelte-heroicons/mini/GlobeAlt"
|
||||||
import { ComparisonState } from "./ComparisonState"
|
import { ComparisonState } from "./ComparisonState"
|
||||||
|
import LoginToggle from "../Base/LoginToggle.svelte"
|
||||||
|
|
||||||
export let externalData: Store<
|
export let externalData: Store<
|
||||||
| { success: { content: Record<string, string> } }
|
| { success: { content: Record<string, string> } }
|
||||||
|
@ -45,6 +46,8 @@
|
||||||
let enableLogin = state.featureSwitches.featureSwitchEnableLogin
|
let enableLogin = state.featureSwitches.featureSwitchEnableLogin
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
|
<LoginToggle {state} silentFail>
|
||||||
|
|
||||||
{#if !$sourceUrl || !$enableLogin}
|
{#if !$sourceUrl || !$enableLogin}
|
||||||
<!-- empty block -->
|
<!-- empty block -->
|
||||||
{:else if $externalData === undefined}
|
{:else if $externalData === undefined}
|
||||||
|
@ -77,3 +80,4 @@
|
||||||
/>
|
/>
|
||||||
</AccordionSingle>
|
</AccordionSingle>
|
||||||
{/if}
|
{/if}
|
||||||
|
</LoginToggle>
|
||||||
|
|
Loading…
Reference in a new issue