diff --git a/components/tooltip/demo/index.vue b/components/tooltip/demo/index.vue
index a1e0451d3..178db3bff 100644
--- a/components/tooltip/demo/index.vue
+++ b/components/tooltip/demo/index.vue
@@ -2,19 +2,37 @@
- This is just a test, put your cursor here
+ :title="showText"
+ :autoAdjustOverflow="autoAdjustOverflow"
+ >
+ 撞到边缘翻转位置 & 点击更新
-
{{showText}}
+
{{autoAdjustOverflow ? '启用' : '关闭'}}自动调整中
+
切换arrowPointAtCenter模式
+
{{arrowPointAtCenter}}
+
+
+
+ arrowPointAtCenter arrowPointAtCenter arrowPointAtCenter
+
+
+
@@ -33,7 +51,9 @@
['left', '', '', '', 'right'],
['leftBottom', '', '', '', 'rightBottom'],
['', 'bottomLeft', 'bottom', 'bottomRight', ''],
- ]
+ ],
+ arrowPointAtCenter: false,
+ autoAdjustOverflow: true,
}
},
methods: {
@@ -43,6 +63,12 @@
} else {
this.showText += ' '
}
+ },
+ change() {
+ this.arrowPointAtCenter = !this.arrowPointAtCenter
+ },
+ reverse() {
+ this.autoAdjustOverflow = !this.autoAdjustOverflow
}
},
components: {
@@ -52,6 +78,10 @@
}