Skip to content
Snippets Groups Projects
Commit a20d99ed authored by Subliminal Guy's avatar Subliminal Guy
Browse files

:wrench: Ändere Lottie.vue, um array.filter hinzuzufügen und die Anpassung an...

:wrench: Ändere Lottie.vue, um array.filter hinzuzufügen und die Anpassung an verschiedene Lottie-Dateien zu verbessern.
:wrench: Füge temporär AnimationRechtsBB.layers[1] und AnimationLinksBB.layers[1] hinzu, um die anfängliche Animationsausgabe zu verbessern.
parent fe966bd6
No related branches found
No related tags found
No related merge requests found
...@@ -82,12 +82,17 @@ watch( ...@@ -82,12 +82,17 @@ watch(
const lottie = ref(0); const lottie = ref(0);
// Added array.filter to improve adaptability to different lottie files
watch( watch(
() => props.vorname, () => props.vorname,
() => { () => {
console.log(AnimationRechtsBB.layers[1].t.d.k[0].s.t); AnimationRechtsBB.layers.filter((layer) => {
AnimationRechtsBB.layers[1].t.d.k[0].s.t = props.vorname.toUpperCase(); return layer.nm === "VORNAME";
AnimationLinksBB.layers[1].t.d.k[0].s.t = props.vorname.toUpperCase(); })[0].t.d.k[0].s.t = props.vorname.toUpperCase();
AnimationLinksBB.layers.filter((layer) => {
return layer.nm === "VORNAME";
})[0].t.d.k[0].s.t = props.vorname.toUpperCase();
lottie.value++; lottie.value++;
} }
); );
...@@ -95,8 +100,12 @@ watch( ...@@ -95,8 +100,12 @@ watch(
watch( watch(
() => props.nachname, () => props.nachname,
() => { () => {
AnimationRechtsBB.layers[3].t.d.k[0].s.t = props.nachname.toUpperCase(); AnimationRechtsBB.layers.filter((layer) => {
AnimationLinksBB.layers[3].t.d.k[0].s.t = props.nachname.toUpperCase(); return layer.nm === "NACHNAME";
})[0].t.d.k[0].s.t = props.nachname.toUpperCase();
AnimationLinksBB.layers.filter((layer) => {
return layer.nm === "NACHNAME";
})[0].t.d.k[0].s.t = props.nachname.toUpperCase();
lottie.value++; lottie.value++;
} }
); );
...@@ -104,8 +113,12 @@ watch( ...@@ -104,8 +113,12 @@ watch(
watch( watch(
() => props.funktionZeileEins, () => props.funktionZeileEins,
() => { () => {
AnimationRechtsBB.layers[5].t.d.k[0].s.t = props.funktionZeileEins; AnimationRechtsBB.layers.filter((layer) => {
AnimationLinksBB.layers[5].t.d.k[0].s.t = props.funktionZeileEins; return layer.nm === "FUNKTION1";
})[0].t.d.k[0].s.t = props.funktionZeileEins;
AnimationLinksBB.layers.filter((layer) => {
return layer.nm === "FUNKTION1";
})[0].t.d.k[0].s.t = props.funktionZeileEins;
lottie.value++; lottie.value++;
} }
); );
...@@ -113,13 +126,18 @@ watch( ...@@ -113,13 +126,18 @@ watch(
watch( watch(
() => props.funktionZeileZwei, () => props.funktionZeileZwei,
() => { () => {
AnimationRechtsBB.layers[7].t.d.k[0].s.t = props.funktionZeileZwei; AnimationRechtsBB.layers.filter((layer) => {
AnimationLinksBB.layers[7].t.d.k[0].s.t = props.funktionZeileZwei; return layer.nm === "FUNKTION2";
})[0].t.d.k[0].s.t = props.funktionZeileZwei;
AnimationLinksBB.layers.filter((layer) => {
return layer.nm === "FUNKTION2";
})[0].t.d.k[0].s.t = props.funktionZeileZwei;
lottie.value++; lottie.value++;
} }
); );
onMounted(() => { onMounted(() => {
// Added this temporarily to improve initial animation output
AnimationRechtsBB.layers[1].t.d.k[0].s.t = "MAX"; AnimationRechtsBB.layers[1].t.d.k[0].s.t = "MAX";
AnimationLinksBB.layers[1].t.d.k[0].s.t = "MAX"; AnimationLinksBB.layers[1].t.d.k[0].s.t = "MAX";
AnimationRechtsBB.layers[3].t.d.k[0].s.t = "MUSTERMANN"; AnimationRechtsBB.layers[3].t.d.k[0].s.t = "MUSTERMANN";
...@@ -137,7 +155,7 @@ onMounted(() => { ...@@ -137,7 +155,7 @@ onMounted(() => {
</script> </script>
<template> <template>
<h2 v-if="BBUnselected"> <h2 v-if="BBUnselected">
Bitte eine Postion für<br /> Bitte eine Position für<br />
die Bauchbinde auswählen die Bauchbinde auswählen
</h2> </h2>
<div class="animation"> <div class="animation">
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment