refactor(components): [tour] improve TourContext type (#21605)

This commit is contained in:
thinkasany
2025-08-04 17:47:48 +08:00
committed by GitHub
parent 382d393020
commit a4babd542e
2 changed files with 3 additions and 3 deletions

View File

@@ -150,7 +150,7 @@ export interface TourContext {
current: Ref<number>
total: Ref<number>
showClose: Ref<boolean>
closeIcon: Ref<string | Component>
closeIcon: Ref<string | Component | undefined>
mergedType: Ref<'default' | 'primary' | undefined>
ns: UseNamespaceReturn
slots: SetupContext['slots']

View File

@@ -129,8 +129,8 @@ provide(tourKey, {
current,
total,
showClose: toRef(props, 'showClose'),
closeIcon: toRef(props, 'closeIcon') as any,
mergedType: mergedType as any,
closeIcon: toRef(props, 'closeIcon'),
mergedType,
ns,
slots,
updateModelValue(modelValue) {