classcard-ui 0.2.430 → 0.2.431
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.
- package/dist/classcard-ui.common.js +55 -65
- package/dist/classcard-ui.common.js.map +1 -1
- package/dist/classcard-ui.umd.js +55 -65
- package/dist/classcard-ui.umd.js.map +1 -1
- package/dist/classcard-ui.umd.min.js +1 -1
- package/dist/classcard-ui.umd.min.js.map +1 -1
- package/package.json +1 -1
- package/src/components/CAnchorTabs/CAnchorTabs.vue +3 -15
package/package.json
CHANGED
|
@@ -78,17 +78,6 @@ export default {
|
|
|
78
78
|
};
|
|
79
79
|
},
|
|
80
80
|
methods: {
|
|
81
|
-
scrollIfNeeded(element, container) {
|
|
82
|
-
if (element.offsetTop < container.scrollTop) {
|
|
83
|
-
container.scrollTop = element.offsetTop;
|
|
84
|
-
} else {
|
|
85
|
-
const offsetBottom = element.offsetTop + element.offsetHeight;
|
|
86
|
-
const scrollBottom = container.scrollTop + container.offsetHeight;
|
|
87
|
-
if (offsetBottom > scrollBottom) {
|
|
88
|
-
container.scrollTop = offsetBottom - container.offsetHeight;
|
|
89
|
-
}
|
|
90
|
-
}
|
|
91
|
-
},
|
|
92
81
|
switchTab(name) {
|
|
93
82
|
this.activeTab = name;
|
|
94
83
|
// document.getElementById(`${name}`).scrollIntoView({
|
|
@@ -97,10 +86,9 @@ export default {
|
|
|
97
86
|
// inline: "start",
|
|
98
87
|
// });
|
|
99
88
|
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
);
|
|
89
|
+
let myElement = document.getElementById(name);
|
|
90
|
+
let topPos = myElement.offsetTop;
|
|
91
|
+
document.getElementById("container").scrollTop = topPos;
|
|
104
92
|
},
|
|
105
93
|
switchTabForMobile(index) {
|
|
106
94
|
var selectedOption = this.tabs[index];
|