forked from MapComplete/MapComplete
		
	fix: hidden theme link not working
This commit is contained in:
		
							parent
							
								
									e185606e73
								
							
						
					
					
						commit
						d5e128b1ed
					
				
					 2 changed files with 6 additions and 7 deletions
				
			
		|  | @ -27,7 +27,7 @@ | ||||||
|   $: knownThemes = hiddenThemes.filter((theme) => knownThemesId.includes(theme.id)) |   $: knownThemes = hiddenThemes.filter((theme) => knownThemesId.includes(theme.id)) | ||||||
| </script> | </script> | ||||||
| 
 | 
 | ||||||
| <ThemesList {search} {state} {onMainScreen} themes={knownThemes} isCustom={true} hideThemes={false}> | <ThemesList {search} {state} {onMainScreen} themes={knownThemes} isCustom={false} hideThemes={false}> | ||||||
|   <svelte:fragment slot="title"> |   <svelte:fragment slot="title"> | ||||||
|     <h3>{t.previouslyHiddenTitle.toString()}</h3> |     <h3>{t.previouslyHiddenTitle.toString()}</h3> | ||||||
|     <p> |     <p> | ||||||
|  |  | ||||||
|  | @ -8,7 +8,7 @@ | ||||||
|   import CustomGeneratorButton from "./CustomGeneratorButton.svelte" |   import CustomGeneratorButton from "./CustomGeneratorButton.svelte" | ||||||
|   import ProfessionalServicesButton from "./ProfessionalServicesButton.svelte" |   import ProfessionalServicesButton from "./ProfessionalServicesButton.svelte" | ||||||
|   import ThemeButton from "./ThemeButton.svelte" |   import ThemeButton from "./ThemeButton.svelte" | ||||||
|   import { LayoutInformation } from "../../Models/ThemeConfig/LayoutConfig"; |   import { LayoutInformation } from "../../Models/ThemeConfig/LayoutConfig" | ||||||
| 
 | 
 | ||||||
|   export let search: UIEventSource<string> |   export let search: UIEventSource<string> | ||||||
|   export let themes: LayoutInformation[] |   export let themes: LayoutInformation[] | ||||||
|  | @ -44,7 +44,7 @@ | ||||||
|   <slot name="title" /> |   <slot name="title" /> | ||||||
|   {#if onMainScreen} |   {#if onMainScreen} | ||||||
|     <div class="md:grid md:grid-flow-row md:grid-cols-2 lg:grid-cols-3 gap-4"> |     <div class="md:grid md:grid-flow-row md:grid-cols-2 lg:grid-cols-3 gap-4"> | ||||||
|       {#if ($search === undefined || $search === "") && !isCustom} |       {#if ($search === undefined || $search === "") && !isCustom && hideThemes} | ||||||
|         <CustomGeneratorButton userDetails={state.osmConnection.userDetails} /> |         <CustomGeneratorButton userDetails={state.osmConnection.userDetails} /> | ||||||
|         <ProfessionalServicesButton /> |         <ProfessionalServicesButton /> | ||||||
|       {/if} |       {/if} | ||||||
|  | @ -55,9 +55,9 @@ | ||||||
|         {/if} |         {/if} | ||||||
|       {/each} |       {/each} | ||||||
|     </div> |     </div> | ||||||
|     {:else } |   {:else} | ||||||
|     <div> |     <div> | ||||||
|       {#if ($search === undefined || $search === "") && !isCustom} |       {#if ($search === undefined || $search === "") && !isCustom && hideThemes} | ||||||
|         <CustomGeneratorButton userDetails={state.osmConnection.userDetails} /> |         <CustomGeneratorButton userDetails={state.osmConnection.userDetails} /> | ||||||
|         <ProfessionalServicesButton /> |         <ProfessionalServicesButton /> | ||||||
|       {/if} |       {/if} | ||||||
|  | @ -68,8 +68,7 @@ | ||||||
|         {/if} |         {/if} | ||||||
|       {/each} |       {/each} | ||||||
|     </div> |     </div> | ||||||
|     {/if} |   {/if} | ||||||
|   |  | ||||||
| 
 | 
 | ||||||
|   {#if filteredThemes.length == 0} |   {#if filteredThemes.length == 0} | ||||||
|     <NoThemeResultButton {search} /> |     <NoThemeResultButton {search} /> | ||||||
|  |  | ||||||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue