|
|
@ -123,17 +123,17 @@ watch( |
|
|
{ immediate: true }, |
|
|
{ immediate: true }, |
|
|
); |
|
|
); |
|
|
|
|
|
|
|
|
watch( |
|
|
// watch( |
|
|
() => [showLoading.value, submitting.value], |
|
|
// () => [showLoading.value, submitting.value], |
|
|
([l, s]) => { |
|
|
// ([l, s]) => { |
|
|
if ((s || l) && wrapperRef.value) { |
|
|
// if ((s || l) && wrapperRef.value) { |
|
|
wrapperRef.value.scrollTo({ |
|
|
// wrapperRef.value.scrollTo({ |
|
|
// behavior: 'smooth', |
|
|
// // behavior: 'smooth', |
|
|
top: 0, |
|
|
// top: 0, |
|
|
}); |
|
|
// }); |
|
|
} |
|
|
// } |
|
|
}, |
|
|
// }, |
|
|
); |
|
|
// ); |
|
|
|
|
|
|
|
|
function handleFullscreen() { |
|
|
function handleFullscreen() { |
|
|
props.modalApi?.setState((prev) => { |
|
|
props.modalApi?.setState((prev) => { |
|
|
@ -274,18 +274,13 @@ function handleClosed() { |
|
|
ref="wrapperRef" |
|
|
ref="wrapperRef" |
|
|
:class=" |
|
|
:class=" |
|
|
cn('relative min-h-40 flex-1 overflow-y-auto p-3', contentClass, { |
|
|
cn('relative min-h-40 flex-1 overflow-y-auto p-3', contentClass, { |
|
|
'overflow-hidden': showLoading || submitting, |
|
|
'pointer-events-none': showLoading || submitting, |
|
|
}) |
|
|
}) |
|
|
" |
|
|
" |
|
|
> |
|
|
> |
|
|
<VbenLoading |
|
|
|
|
|
v-if="showLoading || submitting" |
|
|
|
|
|
class="size-full h-auto min-h-full" |
|
|
|
|
|
spinning |
|
|
|
|
|
/> |
|
|
|
|
|
<slot></slot> |
|
|
<slot></slot> |
|
|
</div> |
|
|
</div> |
|
|
|
|
|
<VbenLoading v-if="showLoading || submitting" spinning /> |
|
|
<VbenIconButton |
|
|
<VbenIconButton |
|
|
v-if="fullscreenButton" |
|
|
v-if="fullscreenButton" |
|
|
class="hover:bg-accent hover:text-accent-foreground text-foreground/80 flex-center absolute right-10 top-3 hidden size-6 rounded-full px-1 text-lg opacity-70 transition-opacity hover:opacity-100 focus:outline-none disabled:pointer-events-none sm:block" |
|
|
class="hover:bg-accent hover:text-accent-foreground text-foreground/80 flex-center absolute right-10 top-3 hidden size-6 rounded-full px-1 text-lg opacity-70 transition-opacity hover:opacity-100 focus:outline-none disabled:pointer-events-none sm:block" |
|
|
|