Witaj Gościu! ( Zaloguj | Rejestruj )

Forum PHP.pl

 
Reply to this topicStart new topic
> [CSS] Zmiana stylu tooltipa
Maker5
post 12.02.2019, 22:36:15
Post #1





Grupa: Zarejestrowani
Postów: 139
Pomógł: 0
Dołączył: 2.04.2008

Ostrzeżenie: (0%)
-----


Witam

mam nowy boostrap wersja 4 i chciałbym zmodyfikować wygląd tooltopa.

To mój kod aktualny.

  1. .tooltip-inner {
  2. max-width: 200px;
  3. padding: 3px 8px;
  4. color: #fff;
  5. text-align: center;
  6. background-color: #000;
  7. border-radius: .25rem;
  8. }
  9. .tooltip.bs-tooltip-auto[x-placement^=top] .arrow::before, .tooltip.bs-tooltip-top .arrow::before {
  10. margin-left: -3px;
  11. content: "";
  12. border-width: 5px 5px 0;
  13. border-top-color: #000;
  14. }
  15. .tooltip.bs-tooltip-auto[x-placement^=right] .arrow::before, .tooltip.bs-tooltip-right .arrow::before {
  16. margin-top: -3px;
  17. content: "";
  18. border-width: 5px 5px 5px 0;
  19. border-right-color: #000;
  20. }
  21. .tooltip.bs-tooltip-auto[x-placement^=bottom] .arrow::before, .tooltip.bs-tooltip-bottom .arrow::before {
  22. margin-left: -3px;
  23. content: "";
  24. border-width: 0 5px 5px;
  25. border-bottom-color: #000;
  26. }
  27. .tooltip.bs-tooltip-auto[x-placement^=left] .arrow::before, .tooltip.bs-tooltip-left .arrow::before {
  28. right: 0;
  29. margin-top: -3px;
  30. content: "";
  31. border-width: 5px 0 5px 5px;
  32. border-left-color: #000;
  33. }


A ze starej wersji boostrapa mam taki kod i tak właśnie chciałbym aby wyglądał ten tootip

  1. a.tooltips {
  2. position: relative;
  3. display: inline;
  4. }
  5. a.tooltips span {
  6. position: absolute;
  7. width:140px;
  8. color: #2F4475;
  9. background: #C5D2D9;
  10. height: 24px;
  11. line-height: 24px;
  12. text-align: center;
  13. visibility: hidden;
  14. border-radius: 5px;
  15. box-shadow: 0px 0px 5px #6A7680;
  16. }
  17. a.tooltips span:after {
  18. content: '';
  19. position: absolute;
  20. top: 100%;
  21. left: 50%;
  22. margin-left: -8px;
  23. width: 0; height: 0;
  24. border-top: 8px solid #C5D2D9;
  25. border-right: 8px solid transparent;
  26. border-left: 8px solid transparent;
  27. }
  28. a:hover.tooltips span {
  29. visibility: visible;
  30. opacity: 0.5;
  31. bottom: 30px;
  32. left: 50%;
  33. margin-left: -76px;
  34. z-index: 999;
  35. }


Proszę o pomoc jak zmodyfikować pierwszy kod aby tootlip wyglądał jak z drugiego kodu.
Go to the top of the page
+Quote Post

Reply to this topicStart new topic
1 Użytkowników czyta ten temat (1 Gości i 0 Anonimowych użytkowników)
0 Zarejestrowanych:

 



RSS Wersja Lo-Fi Aktualny czas: 28.03.2024 - 09:50