diff --git a/src/lib/components/Browse/DrawerCreateChannel.svelte b/src/lib/components/Browse/DrawerCreateChannel.svelte index 09162087..6f0fa428 100644 --- a/src/lib/components/Browse/DrawerCreateChannel.svelte +++ b/src/lib/components/Browse/DrawerCreateChannel.svelte @@ -64,6 +64,12 @@ newChannel = newChannel } + const onTagValidation = (evt: any) => { + if (Number(evt.target.value) < 1) { + evt.target.setCustomValidity('Please fill out this field.') + } + } + let refToggle: any const toggleDrawer = () => { if (refToggle) { @@ -161,6 +167,16 @@ id="tags" placeholder={newChannel.tags.length > 0 ? '' : 'Tag'} /> ({maxTagLabel}) + {#if newChannel.tags.length === 0} + + {/if}
{ swiper = new Swiper('.carousel', { @@ -37,11 +38,18 @@ } onMount(async () => { - initSwiper() + channels.then((data: any) => { + if(data.length){ + initSwiper() + isMounted = true + } + }) }) + + $: swiperClass = isMounted ? 'opacity-1' : 'opacity-0' -{#if channels.length == 0} +{#await channels}
{#each Array(5) as _, index (index)} @@ -49,23 +57,27 @@ {/each}
-{:else} -
-
- -
-