forked from FoundKeyGang/FoundKey
chore: fix error
This commit is contained in:
parent
816493e01f
commit
abd3efa318
1 changed files with 10 additions and 3 deletions
|
@ -153,9 +153,15 @@ export default defineComponent({
|
||||||
|
|
||||||
if (el.value.parentElement) {
|
if (el.value.parentElement) {
|
||||||
narrow.value = el.value.parentElement.offsetWidth < 500;
|
narrow.value = el.value.parentElement.offsetWidth < 500;
|
||||||
new ResizeObserver((entries, observer) => {
|
const ro = new ResizeObserver((entries, observer) => {
|
||||||
narrow.value = el.value.parentElement.offsetWidth < 500;
|
if (el.value) {
|
||||||
}).observe(el.value.parentElement);
|
narrow.value = el.value.parentElement.offsetWidth < 500;
|
||||||
|
}
|
||||||
|
});
|
||||||
|
ro.observe(el.value.parentElement);
|
||||||
|
onUnmounted(() => {
|
||||||
|
ro.disconnect();
|
||||||
|
});
|
||||||
setTimeout(() => {
|
setTimeout(() => {
|
||||||
const currentStickyTop = getComputedStyle(el.value.parentElement).getPropertyValue('--stickyTop') || '0px';
|
const currentStickyTop = getComputedStyle(el.value.parentElement).getPropertyValue('--stickyTop') || '0px';
|
||||||
el.value.style.setProperty('--stickyTop', currentStickyTop);
|
el.value.style.setProperty('--stickyTop', currentStickyTop);
|
||||||
|
@ -191,6 +197,7 @@ export default defineComponent({
|
||||||
width: 100%;
|
width: 100%;
|
||||||
-webkit-backdrop-filter: var(--blur, blur(15px));
|
-webkit-backdrop-filter: var(--blur, blur(15px));
|
||||||
backdrop-filter: var(--blur, blur(15px));
|
backdrop-filter: var(--blur, blur(15px));
|
||||||
|
border-bottom: solid 0.5px var(--divider);
|
||||||
|
|
||||||
&.thin {
|
&.thin {
|
||||||
--height: 50px;
|
--height: 50px;
|
||||||
|
|
Loading…
Reference in a new issue