mirror of
https://github.com/apache/skywalking-booster-ui.git
synced 2025-05-15 09:48:43 +00:00
cleanups
This commit is contained in:
parent
7f2464cc28
commit
ff913ecc58
@ -205,19 +205,19 @@ export default defineComponent({
|
|||||||
function scrollToGraph(e: any) {
|
function scrollToGraph(e: any) {
|
||||||
document?.getElementById(`tabitem${e}`)?.scrollIntoView();
|
document?.getElementById(`tabitem${e}`)?.scrollIntoView();
|
||||||
}
|
}
|
||||||
function debounce(func: any, wait: number) {
|
// function debounce(func: any, wait: number) {
|
||||||
let timeout = null;
|
// let timeout: any = null;
|
||||||
return function (func, delayMs) {
|
// return function (func, delayMs) {
|
||||||
clearTimeout(timeout);
|
// clearTimeout(timeout);
|
||||||
timeout = setTimeout(() => {
|
// timeout = setTimeout(() => {
|
||||||
func();
|
// func();
|
||||||
}, delayMs || 500);
|
// }, delayMs || 500);
|
||||||
};
|
// };
|
||||||
}
|
// }
|
||||||
function scrollDecider() {
|
// function scrollDecider() {
|
||||||
console.log("runing debounce");
|
// console.log("runing debounce");
|
||||||
console.log(window.scrollY);
|
// console.log(window.scrollY);
|
||||||
}
|
// }
|
||||||
function observeItems(kill = false) {
|
function observeItems(kill = false) {
|
||||||
const observer = new IntersectionObserver((entries) => {
|
const observer = new IntersectionObserver((entries) => {
|
||||||
entries.forEach((element) => {
|
entries.forEach((element) => {
|
||||||
@ -332,9 +332,9 @@ export default defineComponent({
|
|||||||
);
|
);
|
||||||
onMounted(() => {
|
onMounted(() => {
|
||||||
tabObserveContainer?.value?.addEventListener("scroll", (e: Event) => {
|
tabObserveContainer?.value?.addEventListener("scroll", (e: Event) => {
|
||||||
debounce(() => {
|
// debounce(() => {
|
||||||
console.log("Yeah!");
|
// console.log("Yeah!");
|
||||||
}, 100);
|
// }, 100);
|
||||||
});
|
});
|
||||||
tabRef?.value["parentElement"]?.classList?.toggle("item");
|
tabRef?.value["parentElement"]?.classList?.toggle("item");
|
||||||
if (dashboardStore.fullView) {
|
if (dashboardStore.fullView) {
|
||||||
|
Loading…
Reference in New Issue
Block a user