gets rid of Block for SREP support
This commit is contained in:
parent
87749bf6b8
commit
a4e4d66218
1 changed files with 5 additions and 5 deletions
|
|
@ -1,6 +1,6 @@
|
||||||
<script lang="ts">
|
<script lang="ts">
|
||||||
// Libraries & utils
|
// Libraries & utils
|
||||||
import { onDestroy, onMount, setContext } from 'svelte';
|
import { onMount, setContext } from 'svelte';
|
||||||
import { DotLottie } from '@lottiefiles/dotlottie-web';
|
import { DotLottie } from '@lottiefiles/dotlottie-web';
|
||||||
import { createLottieState } from './ts/lottieState.svelte';
|
import { createLottieState } from './ts/lottieState.svelte';
|
||||||
import { isEqual } from 'es-toolkit';
|
import { isEqual } from 'es-toolkit';
|
||||||
|
|
@ -15,7 +15,6 @@
|
||||||
import { Tween } from 'svelte/motion';
|
import { Tween } from 'svelte/motion';
|
||||||
|
|
||||||
// Components
|
// Components
|
||||||
import Block from '../Block/Block.svelte';
|
|
||||||
import Debug from './Debug.svelte';
|
import Debug from './Debug.svelte';
|
||||||
import WASM from './data/dotlottie-player.wasm?url';
|
import WASM from './data/dotlottie-player.wasm?url';
|
||||||
import DefaultLottie from './data/defaultLottie.lottie?url';
|
import DefaultLottie from './data/defaultLottie.lottie?url';
|
||||||
|
|
@ -51,7 +50,7 @@
|
||||||
layout = { fit: 'contain', align: [0.5, 0.5] },
|
layout = { fit: 'contain', align: [0.5, 0.5] },
|
||||||
animationId = '',
|
animationId = '',
|
||||||
lottiePlayer = $bindable(undefined),
|
lottiePlayer = $bindable(undefined),
|
||||||
width = 'widest',
|
width = 'normal',
|
||||||
height = '100lvh',
|
height = '100lvh',
|
||||||
showDebugInfo = false,
|
showDebugInfo = false,
|
||||||
lottieState = createLottieState(),
|
lottieState = createLottieState(),
|
||||||
|
|
@ -376,7 +375,7 @@
|
||||||
});
|
});
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<Block {width} class="lottie-block">
|
<div class="lottie-block">
|
||||||
{#if showDebugInfo && lottiePlayer}
|
{#if showDebugInfo && lottiePlayer}
|
||||||
<Debug componentState={lottieState} />
|
<Debug componentState={lottieState} />
|
||||||
{/if}
|
{/if}
|
||||||
|
|
@ -394,12 +393,13 @@
|
||||||
{#if children}
|
{#if children}
|
||||||
{@render children()}
|
{@render children()}
|
||||||
{/if}
|
{/if}
|
||||||
</Block>
|
</div>
|
||||||
|
|
||||||
<style lang="scss">
|
<style lang="scss">
|
||||||
:global(.lottie-block) {
|
:global(.lottie-block) {
|
||||||
position: relative;
|
position: relative;
|
||||||
height: 100%;
|
height: 100%;
|
||||||
|
outline: 2px solid blue;
|
||||||
|
|
||||||
.lottie-container {
|
.lottie-container {
|
||||||
width: 100%;
|
width: 100%;
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue