@appscode/design-system 1.0.43-alpha.81 → 1.0.43-alpha.85
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -69,7 +69,7 @@
|
|
|
69
69
|
font-size: 14px;
|
|
70
70
|
color: $ac-color-text;
|
|
71
71
|
line-height: 160%;
|
|
72
|
-
margin-bottom:
|
|
72
|
+
margin-bottom: 10px;
|
|
73
73
|
}
|
|
74
74
|
|
|
75
75
|
.social-links {
|
|
@@ -103,7 +103,7 @@
|
|
|
103
103
|
}
|
|
104
104
|
|
|
105
105
|
img {
|
|
106
|
-
max-width:
|
|
106
|
+
max-width: 15px;
|
|
107
107
|
margin-right: 10px;
|
|
108
108
|
}
|
|
109
109
|
}
|
package/package.json
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
<template>
|
|
2
|
-
<li>
|
|
2
|
+
<li ref="sidebarItem">
|
|
3
3
|
<router-link
|
|
4
4
|
:id="id"
|
|
5
5
|
:title="title"
|
|
@@ -38,5 +38,27 @@ export default {
|
|
|
38
38
|
default: "@/assets/images/icons/basic.svg",
|
|
39
39
|
},
|
|
40
40
|
},
|
|
41
|
+
watch: {
|
|
42
|
+
isActive: {
|
|
43
|
+
immediate: true,
|
|
44
|
+
handler(n) {
|
|
45
|
+
if (n) {
|
|
46
|
+
this.$nextTick(() => {
|
|
47
|
+
setTimeout(() => {
|
|
48
|
+
const top = (this.$refs.sidebarItem && this.$refs.sidebarItem.getBoundingClientRect().top) || 0;
|
|
49
|
+
// preventing scroll to options that are already visible
|
|
50
|
+
if (top > window.innerHeight - 200) {
|
|
51
|
+
// scroll to selected option item
|
|
52
|
+
this.$refs.sidebarItem.scrollIntoView({
|
|
53
|
+
behavior: 'smooth',
|
|
54
|
+
block: "center"
|
|
55
|
+
});
|
|
56
|
+
}
|
|
57
|
+
}, 500);
|
|
58
|
+
});
|
|
59
|
+
}
|
|
60
|
+
}
|
|
61
|
+
}
|
|
62
|
+
}
|
|
41
63
|
};
|
|
42
64
|
</script>
|