prep: replace $$props.class with props
This commit is contained in:
1 parent
3ca72662ca
commit
0718c8e0c6
69 files changed
+383
-214
No files matched your search
@@ -93,6 +93,9 @@
|
||||
|
||||
$: data = typeData(type)
|
||||
$: embedUrl = urlToEmbed(url)
|
||||
|
||||
let clazz: string = ''
|
||||
export { clazz as class }
|
||||
</script>
|
||||
|
||||
<!--
|
||||
@@ -102,7 +105,7 @@
|
||||
{#if opened}
|
||||
{#if type == 'video'}
|
||||
<!-- svelte-ignore a11y-media-has-caption -->
|
||||
<video {autoplay} controls class="rounded-xl aspect-video {$$props.class}">
|
||||
<video {autoplay} controls class="rounded-xl aspect-video {clazz}">
|
||||
<source src={url} />
|
||||
</video>
|
||||
{:else}
|
||||
@@ -112,7 +115,7 @@
|
||||
frameborder="0"
|
||||
allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share"
|
||||
allowfullscreen
|
||||
class="aspect-video rounded-xl dark:bg-zinc-900 {$$props.class ?? ''}"
|
||||
class="aspect-video rounded-xl dark:bg-zinc-900 {clazz ?? ''}"
|
||||
/>
|
||||
{/if}
|
||||
{:else}
|
||||
|
||||
@@ -27,16 +27,17 @@
|
||||
view == 'compact' ? 'w-22 h-22 sm:w-28' : 'w-24 h-24 sm:w-32'
|
||||
|
||||
$: size = thumbnailSize(view)
|
||||
|
||||
export let style: string = ''
|
||||
let clazz: string = ''
|
||||
export { clazz as class }
|
||||
</script>
|
||||
|
||||
<!--
|
||||
@component
|
||||
Thumbnails for compact and list view posts.
|
||||
-->
|
||||
<div
|
||||
class="{size} relative group/media {$$props.class ?? ''}"
|
||||
style={$$props.style ?? ''}
|
||||
>
|
||||
<div class="{size} relative group/media {clazz ?? ''}" {style}>
|
||||
{#if post.alt_text}
|
||||
<Popover
|
||||
openOnHover
|
||||
|
||||
Reference in new issue
Block a user