简体   繁体   English

工具提示未显示在适当的按钮上

[英]Tool tip is not showing on the appropriate nob

i'm having issues in my UI, which the Tool Tip not displying in appropriate nob after i scroll down. 我的UI出现问题,向下滚动后,工具提示没有以适当的方式显示。

<div ng-init="hideTooltip[$index]=1" ng-click="toggleTooltip($index, $event);" style="float:right;margin-top:7px" class="menu-toggle-black" ng-show="hideTooltip[$index]==1&&isNotAdmin(permission)"> 
    <ul class="menu-tooltip margin-left-140px" ng-show="showTooltip[$index] == 1">
        <li ng-apply-privilege="VRM_ADD_PERMISSIONS" class="logout" ng-click="editButton($index, permission);"><span><a translate="usermanagement.view.EDIT"></a></span></li>
        <li ng-apply-privilege="VRM_DELETE_PERMISSIONS" class="logout" ng-click="deleteButton($index);"><span><a translate="usermanagement.view.DELETE"></a></span></li>
    </ul>
</div>

<style>
    .menu-tooltip{position:fixed;}
</style>

When you set tooltip position fixed, it would not move when page scroll, 当您将工具提示位置设置为固定时,页面滚动时它不会移动,

You should set container position relative, and tolltip position absolute. 您应该将容器位置设置为相对,将话费提示位置设置为绝对。

Something like below 像下面这样

.menu-toggle-black {
    position:relative;
 }
 .menu-tooltip{
   position:absolute;
   top:0; /* or positive or negative value you need.*/
   left:100%; /* or positive or negative value you need.*/
  }

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM