mirror of
https://gitee.com/vant-contrib/vant.git
synced 2025-04-06 03:57:59 +08:00
fix(Tab): add key when render TabsTitle (#10392)
* fix(Tab): add key when render TabsTitle * fix(Tab): change key * fix(Tabs): use each TabRef.id as key
This commit is contained in:
parent
03c2f241b8
commit
334699d264
@ -365,6 +365,7 @@ export default defineComponent({
|
|||||||
const renderNav = () =>
|
const renderNav = () =>
|
||||||
children.map((item, index) => (
|
children.map((item, index) => (
|
||||||
<TabsTitle
|
<TabsTitle
|
||||||
|
key={item.id}
|
||||||
v-slots={{ title: item.$slots.title }}
|
v-slots={{ title: item.$slots.title }}
|
||||||
id={`${id}-${index}`}
|
id={`${id}-${index}`}
|
||||||
ref={setTitleRefs(index)}
|
ref={setTitleRefs(index)}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user