We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent c8e764a commit 2cc2c22Copy full SHA for 2cc2c22
packages/core/src/Tooltip/utils.ts
@@ -44,7 +44,7 @@ export function getLocation(
44
// 得到 三角 x 位置
45
if (pageOffsetX === (MainWidth - width) / 2) {
46
isStart = xLocation.center;
47
- style.left = pageOffsetX - 16;
+ style.left = (MainWidth - _W) / 2 ;
48
}
49
if (MainWidth - width - pageOffsetX > pageOffsetX) {
50
isStart = xLocation.start;
@@ -55,7 +55,7 @@ export function getLocation(
55
style.left = pageOffsetX - halfWidth + 16;
56
57
// cloud 宽度超出屏幕
58
- if (_W >= MainWidth - 40) {
+ if (_W+ pageOffsetX >= MainWidth - 40) {
59
style.width = MainWidth - 40;
60
triangle = pageOffsetX + halfWidth - 20 - 10 - 6;
61
style.left = 20;
0 commit comments