_vendor.tippy.scss 1.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475
  1. // stylelint-disable selector-attribute-name-disallowed-list
  2. @import '../../../node_modules/tippy.js/dist/tippy';
  3. .tippy-box {
  4. // Special font size 12px for tooltips
  5. @apply w-bg-surface-tooltip w-text-text-button w-text-[0.75rem] w-rounded-sm w-font-medium;
  6. }
  7. .tippy-box[data-placement^='top'] > .tippy-arrow::before {
  8. @apply w-border-t-surface-tooltip;
  9. }
  10. .tippy-box[data-placement^='bottom'] > .tippy-arrow::before {
  11. @apply w-border-b-surface-tooltip;
  12. }
  13. .tippy-box[data-placement^='left'] > .tippy-arrow::before {
  14. @apply w-border-l-surface-tooltip;
  15. }
  16. .tippy-box[data-placement^='right'] > .tippy-arrow::before {
  17. @apply w-border-r-surface-tooltip;
  18. }
  19. // Dropdown theme for tippy tooltips
  20. .tippy-box[data-theme='dropdown'] {
  21. @apply w-rounded;
  22. .tippy-content {
  23. @apply w-p-0;
  24. }
  25. }
  26. .tippy-box[data-theme='popup'] {
  27. @apply w-rounded w-bg-surface-page w-text-inherit w-shadow-md;
  28. &[data-placement^='bottom'] > .tippy-arrow::before {
  29. @apply w-border-b-surface-page;
  30. }
  31. .tippy-content {
  32. @apply w-p-0;
  33. }
  34. }
  35. .tippy-box[data-theme='drilldown'] {
  36. @apply w-rounded w-bg-surface-page w-text-inherit w-shadow-md;
  37. width: 300px;
  38. .tippy-content {
  39. @apply w-p-0;
  40. }
  41. }
  42. .tippy-box[data-theme='dropdown-button'] {
  43. @apply w-rounded-none w-w-full w-bg-transparent;
  44. .tippy-content {
  45. @apply w-p-0;
  46. }
  47. }
  48. // Media for Windows High Contrast mode
  49. @media (forced-colors: active) {
  50. .tippy-box {
  51. .tippy-content {
  52. border: 2px solid transparent;
  53. }
  54. }
  55. .tippy-box[data-placement^='bottom'] > .tippy-arrow::before {
  56. @apply w-border-b-surface-tooltip;
  57. clip-path: polygon(50% 0, 0 100%, 100% 100%);
  58. }
  59. }