mirror of
https://gitee.com/ant-design-vue/ant-design-vue.git
synced 2024-12-02 12:07:54 +08:00
fix: tour center
This commit is contained in:
parent
e5787c2ed2
commit
429172b345
@ -209,10 +209,24 @@ const Tour = defineComponent({
|
||||
rootClassName={rootClassName}
|
||||
/>
|
||||
<Trigger
|
||||
builtinPlacements={getPlacements(arrowPointAtCenter.value)}
|
||||
{...restProps}
|
||||
builtinPlacements={
|
||||
!curStep.value.target
|
||||
? undefined
|
||||
: restProps.builtinPlacements ?? getPlacements(arrowPointAtCenter.value)
|
||||
}
|
||||
ref={triggerRef}
|
||||
popupStyle={curStep.value.style}
|
||||
popupStyle={
|
||||
!curStep.value.target
|
||||
? {
|
||||
...curStep.value.style,
|
||||
position: 'fixed',
|
||||
left: CENTER_PLACEHOLDER.left,
|
||||
top: CENTER_PLACEHOLDER.top,
|
||||
transform: 'translate(-50%, -50%)',
|
||||
}
|
||||
: curStep.value.style
|
||||
}
|
||||
popupPlacement={mergedPlacement.value}
|
||||
popupVisible={mergedOpen.value}
|
||||
popupClassName={classNames(rootClassName, curStep.value.className)}
|
||||
|
Loading…
Reference in New Issue
Block a user