You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
This file contains ambiguous Unicode characters that may be confused with others in your current locale. If your use case is intentional and legitimate, you can safely ignore this warning. Use the Escape button to highlight these characters.
< docs >
-- -
order : 3
title :
zh - CN : 自定义提示
en - US : Customize tooltip
-- -
# # zh - CN
使用 ` tipFormatter ` 可以格式化 ` Tooltip ` 的内容 , 设置 ` tipFormatter={null} ` , 则隐藏 ` Tooltip ` 。
# # en - US
Use ` tipFormatter ` to format content of ` Tooltip ` . If ` tipFormatter ` is null , hide it .
< / docs >
< template >
< div >
< a -slider :tip-formatter ="formatter" / >
< a -slider :tip-formatter ="null" / >
< / div >
< / template >
< script lang = "ts" >
import { defineComponent , ref } from 'vue' ;
export default defineComponent ( {
setup ( ) {
const disabled = ref < boolean > ( false ) ;
const formatter = ( value : number ) => {
return ` ${ value } % ` ;
} ;
return {
disabled ,
formatter ,
} ;
} ,
} ) ;
< / script >
` ` `