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.

tooltip.scss 2.6KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129
  1. /**
  2. * @copyright Copyright (c) 2016, John Molakvoæ <skjnldsv@protonmail.com>
  3. * @copyright Copyright (c) 2016, Robin Appelman <robin@icewind.nl>
  4. * @copyright Copyright (c) 2016, Jan-Christoph Borchardt <hey@jancborchardt.net>
  5. * @copyright Copyright (c) 2016, Erik Pellikka <erik@pellikka.org>
  6. * @copyright Copyright (c) 2015, Vincent Petry <pvince81@owncloud.com>
  7. *
  8. * Bootstrap v3.3.5 (http://getbootstrap.com)
  9. * Copyright 2011-2015 Twitter, Inc.
  10. * Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)
  11. */
  12. .tooltip {
  13. position: absolute;
  14. display: block;
  15. font-family: 'Open Sans', Frutiger, Calibri, 'Myriad Pro', Myriad, sans-serif;
  16. font-style: normal;
  17. font-weight: 400;
  18. letter-spacing: normal;
  19. line-break: auto;
  20. line-height: 1.6;
  21. text-align: left;
  22. text-align: start;
  23. text-decoration: none;
  24. text-shadow: none;
  25. text-transform: none;
  26. white-space: normal;
  27. word-break: normal;
  28. word-spacing: normal;
  29. word-wrap: normal;
  30. font-size: 12px;
  31. opacity: 0;
  32. z-index: 100000;
  33. &.in {
  34. opacity: 1;
  35. }
  36. &.top {
  37. margin-top: -3px;
  38. padding: 10px 0;
  39. }
  40. &.bottom {
  41. margin-top: 3px;
  42. padding: 10px 0;
  43. }
  44. &.right {
  45. margin-left: 3px;
  46. padding: 0 10px;
  47. .tooltip-arrow {
  48. top: 50%;
  49. left: 0;
  50. margin-top: -10px;
  51. border-width: 10px 10px 10px 0;
  52. border-right-color: $color-main-background;
  53. }
  54. }
  55. &.left {
  56. margin-left: -3px;
  57. padding: 0 5px;
  58. .tooltip-arrow {
  59. top: 50%;
  60. right: 0;
  61. margin-top: -10px;
  62. border-width: 10px 0 10px 10px;
  63. border-left-color: $color-main-background;
  64. }
  65. }
  66. /* TOP */
  67. &.top .tooltip-arrow,
  68. &.top-left .tooltip-arrow,
  69. &.top-right .tooltip-arrow {
  70. bottom: 0;
  71. border-width: 10px 10px 0;
  72. border-top-color: $color-main-background;
  73. }
  74. &.top .tooltip-arrow {
  75. left: 50%;
  76. margin-left: -10px;
  77. }
  78. &.top-left .tooltip-arrow {
  79. right: 10px;
  80. margin-bottom: -10px;
  81. }
  82. &.top-right .tooltip-arrow {
  83. left: 10px;
  84. margin-bottom: -10px;
  85. }
  86. /* BOTTOM */
  87. &.bottom .tooltip-arrow,
  88. &.bottom-left .tooltip-arrow,
  89. &.bottom-right .tooltip-arrow {
  90. top: 0;
  91. border-width: 0 10px 10px;
  92. border-bottom-color: $color-main-background;
  93. }
  94. &.bottom .tooltip-arrow {
  95. left: 50%;
  96. margin-left: -10px;
  97. }
  98. &.bottom-left .tooltip-arrow {
  99. right: 10px;
  100. margin-top: -10px;
  101. }
  102. &.bottom-right .tooltip-arrow {
  103. left: 10px;
  104. margin-top: -10px;
  105. }
  106. }
  107. .tooltip-inner {
  108. max-width: 350px;
  109. padding: 5px 8px;
  110. background-color: $color-main-background;
  111. color: $color-main-text;
  112. box-shadow: 0 1px 10px $color-box-shadow;
  113. text-align: center;
  114. border-radius: $border-radius;
  115. }
  116. .tooltip-arrow {
  117. position: absolute;
  118. width: 0;
  119. height: 0;
  120. border-color: transparent;
  121. border-style: solid;
  122. }