basic.vue 2.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128
  1. <template>
  2. <div class="tooltip-base-box">
  3. <div class="row center">
  4. <el-tooltip
  5. class="box-item"
  6. effect="dark"
  7. content="Top Left prompts info"
  8. placement="top-start"
  9. >
  10. <el-button>top-start</el-button>
  11. </el-tooltip>
  12. <el-tooltip
  13. class="box-item"
  14. effect="dark"
  15. content="Top Center prompts info"
  16. placement="top"
  17. >
  18. <el-button>top</el-button>
  19. </el-tooltip>
  20. <el-tooltip
  21. class="box-item"
  22. effect="dark"
  23. content="Top Right prompts info"
  24. placement="top-end"
  25. >
  26. <el-button>top-end</el-button>
  27. </el-tooltip>
  28. </div>
  29. <div class="row">
  30. <el-tooltip
  31. class="box-item"
  32. effect="dark"
  33. content="Left Top prompts info"
  34. placement="left-start"
  35. >
  36. <el-button>left-start</el-button>
  37. </el-tooltip>
  38. <el-tooltip
  39. class="box-item"
  40. effect="dark"
  41. content="Right Top prompts info"
  42. placement="right-start"
  43. >
  44. <el-button>right-start</el-button>
  45. </el-tooltip>
  46. </div>
  47. <div class="row">
  48. <el-tooltip
  49. class="box-item"
  50. effect="dark"
  51. content="Left Center prompts info"
  52. placement="left"
  53. >
  54. <el-button class="mt-3 mb-3">left</el-button>
  55. </el-tooltip>
  56. <el-tooltip
  57. class="box-item"
  58. effect="dark"
  59. content="Right Center prompts info"
  60. placement="right"
  61. >
  62. <el-button>right</el-button>
  63. </el-tooltip>
  64. </div>
  65. <div class="row">
  66. <el-tooltip
  67. class="box-item"
  68. effect="dark"
  69. content="Left Bottom prompts info"
  70. placement="left-end"
  71. >
  72. <el-button>left-end</el-button>
  73. </el-tooltip>
  74. <el-tooltip
  75. class="box-item"
  76. effect="dark"
  77. content="Right Bottom prompts info"
  78. placement="right-end"
  79. >
  80. <el-button>right-end</el-button>
  81. </el-tooltip>
  82. </div>
  83. <div class="row center">
  84. <el-tooltip
  85. class="box-item"
  86. effect="dark"
  87. content="Bottom Left prompts info"
  88. placement="bottom-start"
  89. >
  90. <el-button>bottom-start</el-button>
  91. </el-tooltip>
  92. <el-tooltip
  93. class="box-item"
  94. effect="dark"
  95. content="Bottom Center prompts info"
  96. placement="bottom"
  97. >
  98. <el-button>bottom</el-button>
  99. </el-tooltip>
  100. <el-tooltip
  101. class="box-item"
  102. effect="dark"
  103. content="Bottom Right prompts info"
  104. placement="bottom-end"
  105. >
  106. <el-button>bottom-end</el-button>
  107. </el-tooltip>
  108. </div>
  109. </div>
  110. </template>
  111. <style>
  112. .tooltip-base-box {
  113. width: 600px;
  114. }
  115. .tooltip-base-box .row {
  116. display: flex;
  117. align-items: center;
  118. justify-content: space-between;
  119. }
  120. .tooltip-base-box .center {
  121. justify-content: center;
  122. }
  123. .tooltip-base-box .box-item {
  124. width: 110px;
  125. margin-top: 10px;
  126. }
  127. </style>