fix: tour arrow pointAtCenter (#46301)

This commit is contained in:
MadCcc 2023-12-07 13:57:26 +08:00 committed by GitHub
parent 43e7fed80c
commit a4286e170a
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 9 additions and 8 deletions

View File

@ -40,8 +40,9 @@ const Tour: React.FC<TourProps> & { _InternalPanelDoNotUseOrYouWillBeFired: type
[steps, type],
);
const builtinPlacements = getPlacements({
arrowPointAtCenter: true,
const builtinPlacements: TourProps['builtinPlacements'] = (config) =>
getPlacements({
arrowPointAtCenter: config?.arrowPointAtCenter ?? true,
autoAdjustOverflow: true,
offset: token.marginXXS,
arrowWidth: token.sizePopupArrow,

View File

@ -119,7 +119,7 @@
"@ctrl/tinycolor": "^3.6.1",
"@rc-component/color-picker": "~1.4.1",
"@rc-component/mutate-observer": "^1.1.0",
"@rc-component/tour": "~1.11.1",
"@rc-component/tour": "~1.12.0",
"@rc-component/trigger": "^1.18.2",
"classnames": "^2.3.2",
"copy-to-clipboard": "^3.3.3",