animation tweaks
This commit is contained in:
parent
3f96155321
commit
445c7358a9
2 changed files with 7 additions and 7 deletions
|
|
@ -80,19 +80,19 @@ onMounted(() => {
|
||||||
gifWindow.value,
|
gifWindow.value,
|
||||||
{ opacity: 0, height: 0 },
|
{ opacity: 0, height: 0 },
|
||||||
{ opacity: 1, height: 'auto', ...ANIMATION_SETTINGS },
|
{ opacity: 1, height: 'auto', ...ANIMATION_SETTINGS },
|
||||||
'+0.1',
|
'<+0.1',
|
||||||
)
|
)
|
||||||
tl.value.fromTo(
|
tl.value.fromTo(
|
||||||
contentWindow.value,
|
contentWindow.value,
|
||||||
{ opacity: 0, height: 0 },
|
{ opacity: 0, height: 0 },
|
||||||
{ opacity: 1, height: 'auto', ...ANIMATION_SETTINGS },
|
{ opacity: 1, height: 'auto', ...ANIMATION_SETTINGS },
|
||||||
'+0.1',
|
'<+0.1',
|
||||||
)
|
)
|
||||||
tl.value.fromTo(
|
tl.value.fromTo(
|
||||||
closeWindow.value,
|
closeWindow.value,
|
||||||
{ opacity: 0, height: 0 },
|
{ opacity: 0 },
|
||||||
{ opacity: 1, height: 'auto', ...ANIMATION_SETTINGS },
|
{ opacity: 1, ...ANIMATION_SETTINGS },
|
||||||
'+0.1',
|
'<+0.1',
|
||||||
)
|
)
|
||||||
|
|
||||||
tl.value.pause(0)
|
tl.value.pause(0)
|
||||||
|
|
@ -210,7 +210,7 @@ defineExpose({ animateIn, animateOut })
|
||||||
}
|
}
|
||||||
&.content {
|
&.content {
|
||||||
grid-column: 1/-1;
|
grid-column: 1/-1;
|
||||||
height: 100%;
|
max-height: 100%;
|
||||||
overflow: hidden;
|
overflow: hidden;
|
||||||
position: relative;
|
position: relative;
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -83,7 +83,7 @@ const ratio = computed(() => {
|
||||||
const aspect = computed(() => {
|
const aspect = computed(() => {
|
||||||
// calculate if no aspect provided
|
// calculate if no aspect provided
|
||||||
if (props.aspect === -1) {
|
if (props.aspect === -1) {
|
||||||
return ratio.value * 100
|
return ratio.value ? ratio.value * 100 : 100
|
||||||
}
|
}
|
||||||
|
|
||||||
// otherwise, parse provided aspect, handling both 56.25 and 0.5625 style
|
// otherwise, parse provided aspect, handling both 56.25 and 0.5625 style
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue