LayerUI.scss 3.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150
  1. @import "open-color/open-color";
  2. .layer-ui__library {
  3. margin: auto;
  4. display: flex;
  5. align-items: center;
  6. justify-content: center;
  7. }
  8. .layer-ui__library-message {
  9. padding: 10px 20px;
  10. max-width: 200px;
  11. }
  12. .layer-ui__library-items {
  13. max-height: 50vh;
  14. overflow: auto;
  15. }
  16. .layer-ui__wrapper {
  17. .encrypted-icon {
  18. position: relative;
  19. margin-inline-start: 15px;
  20. display: flex;
  21. justify-content: center;
  22. align-items: center;
  23. border-radius: var(--space-factor);
  24. color: $oc-green-9;
  25. svg {
  26. width: 1.2rem;
  27. height: 1.2rem;
  28. }
  29. &.tooltip .tooltip-text {
  30. visibility: hidden;
  31. width: 20rem;
  32. bottom: calc(50% + 0.8rem + 6px);
  33. :root[dir="ltr"] & {
  34. left: -5px;
  35. }
  36. :root[dir="rtl"] & {
  37. right: -5px;
  38. }
  39. background-color: $oc-black;
  40. color: $oc-white;
  41. text-align: center;
  42. border-radius: 6px;
  43. padding: 5px;
  44. position: absolute;
  45. z-index: 10;
  46. font-size: 13px;
  47. line-height: 1.5;
  48. white-space: pre-wrap;
  49. &::after {
  50. --size: 6px;
  51. content: "";
  52. border: var(--size) solid transparent;
  53. border-top-color: $oc-black;
  54. position: absolute;
  55. bottom: calc(-2 * var(--size));
  56. :root[dir="ltr"] & {
  57. left: calc(5px + var(--size) / 2);
  58. }
  59. :root[dir="rtl"] & {
  60. right: calc(5px + var(--size) / 2);
  61. }
  62. }
  63. }
  64. // the following 3 rules ensure that the tooltip doesn't show (nor affect
  65. // the cursor) when you drag over when you draw on canvas, but at the same
  66. // time it still works when clicking on the link/shield
  67. body:active &.tooltip:not(:hover) {
  68. pointer-events: none;
  69. }
  70. body:not(:active) &.tooltip:hover .tooltip-text {
  71. visibility: visible;
  72. }
  73. .tooltip-text:hover {
  74. visibility: visible;
  75. }
  76. }
  77. &__github-corner {
  78. top: 0;
  79. :root[dir="ltr"] & {
  80. right: 0;
  81. }
  82. :root[dir="rtl"] & {
  83. left: 0;
  84. }
  85. position: absolute;
  86. width: 40px;
  87. }
  88. &__footer {
  89. position: absolute;
  90. bottom: 0px;
  91. :root[dir="ltr"] & {
  92. right: 0;
  93. }
  94. :root[dir="rtl"] & {
  95. left: 0;
  96. }
  97. width: 190px;
  98. }
  99. .zen-mode-transition {
  100. transition: transform 0.5s ease-in-out;
  101. :root[dir="ltr"] &.transition-left {
  102. transform: translate(-999px, 0);
  103. }
  104. :root[dir="ltr"] &.transition-right {
  105. transform: translate(999px, 0px);
  106. }
  107. :root[dir="rtl"] &.transition-left {
  108. transform: translate(999px, 0);
  109. }
  110. :root[dir="rtl"] &.transition-right {
  111. transform: translate(-999px, 0);
  112. }
  113. &.App-menu_bottom--transition-left {
  114. transform: translate(-92px, 0);
  115. }
  116. }
  117. .disable-zen-mode {
  118. height: 30px;
  119. position: absolute;
  120. bottom: 10px;
  121. right: 15px;
  122. font-size: 10px;
  123. padding: 10px;
  124. font-weight: 500;
  125. opacity: 0;
  126. visibility: hidden;
  127. transition: visibility 0s linear 0s, opacity 0.5s;
  128. &--visible {
  129. opacity: 1;
  130. visibility: visible;
  131. transition: visibility 0s linear 300ms, opacity 0.5s;
  132. transition-delay: 0.8s;
  133. }
  134. }
  135. }