Merge branch 'dev' into next

This commit is contained in:
chenjiahan
2020-10-09 17:55:10 +08:00
22 changed files with 125 additions and 95 deletions
+7 -1
View File
@@ -54,7 +54,7 @@ export default createComponent({
},
},
emits: ['select'],
emits: ['select', 'change'],
setup(props, { emit, slots }) {
const root = ref();
@@ -172,6 +172,12 @@ export default createComponent({
}
);
watch(activeAnchor, (value) => {
if (value) {
emit('change', value);
}
});
const renderIndexes = () =>
props.indexList.map((index) => {
const active = index === activeAnchor.value;