forked from gzzfw/frontEnd/gzDyh

zhangyongtian
2024-09-05 ea23af49874833b91e8bcecf1905a97124a2bd7a
1
2
3
4
5
6
7
8
9
10
11
12
<!--components/tooltip/index.wxml-->
<view
    class="tooltip"
    style="{{ placement === 'left' ? 'left:0;' : placement === 'right' ? 'right:0;' : 'left:50%;margin-left:-'+ width / 2 + 'rpx' }}"
    wx:if="{{ visible }}"
>
    <view
        class="tooltip-arrow"
        style="{{ placement === 'left' ? 'left:24rpx;' : placement === 'right' ? 'right:24rpx;' : 'left:50%;margin-left:-16rpx' }}"
    />
    <view class="tooltip-content" style="width:{{ width }}rpx;{{ fontsize ? 'font-size: ' + fontsize : '' }}">{{ content }}</view>
</view>