LayerUI.scss 3.4 KB

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