appRoot.component.scss 2.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163
  1. :host {
  2. display: flex;
  3. width: 100vw;
  4. height: 100vh;
  5. flex-direction: column;
  6. overflow: hidden;
  7. user-select: none;
  8. -webkit-user-drag: none;
  9. -webkit-font-smoothing: antialiased;
  10. will-change: transform;
  11. cursor: default;
  12. animation: 0.5s ease-out fadeIn;
  13. transition: 0.25s background;
  14. }
  15. $tabs-height: 38px;
  16. $tab-border-radius: 4px;
  17. $side-tab-width: 200px;
  18. .wrap {
  19. display: flex;
  20. width: 100vw;
  21. height: 100vh;
  22. flex-direction: row;
  23. }
  24. .content {
  25. width: 100vw;
  26. flex: 1 1 0;
  27. display: flex;
  28. flex-direction: column-reverse;
  29. &.tabs-on-top {
  30. flex-direction: column;
  31. }
  32. &.tabs-on-side {
  33. flex-direction: row-reverse;
  34. &.tabs-on-top {
  35. flex-direction: row;
  36. }
  37. }
  38. }
  39. .content.tabs-on-side > .tab-bar {
  40. height: 100%;
  41. width: $side-tab-width;
  42. overflow-y: auto;
  43. overflow-x: hidden;
  44. flex-direction: column;
  45. background: rgba(0, 0, 0, 0.25);
  46. .tabs {
  47. width: $side-tab-width;
  48. flex: none;
  49. flex-direction: column;
  50. tab-header {
  51. flex: 0 0 $tabs-height;
  52. }
  53. }
  54. .drag-space {
  55. flex: auto;
  56. }
  57. &>.inset {
  58. opacity: 0;
  59. }
  60. }
  61. .tab-bar {
  62. flex: none;
  63. height: $tabs-height;
  64. display: flex;
  65. width: 100%;
  66. .btn-tab-bar {
  67. line-height: $tabs-height + 2px;
  68. height: $tabs-height;
  69. cursor: pointer;
  70. display: flex;
  71. padding: 0 15px;
  72. flex: 0 0 auto;
  73. border-bottom: 2px solid transparent;
  74. transition: 0.25s all;
  75. font-size: 12px;
  76. text-transform: uppercase;
  77. font-weight: bold;
  78. color: #aaa;
  79. border: none;
  80. border-radius: 0;
  81. align-items: center;
  82. &.dropdown-toggle::after {
  83. display: none;
  84. }
  85. }
  86. &>.tabs {
  87. flex: 0 1 auto;
  88. display: flex;
  89. min-width: 0;
  90. }
  91. &>.drag-space {
  92. min-width: 1px;
  93. flex: 1 0 1%;
  94. margin-top: 2px; // for window resizing
  95. -webkit-app-region: drag;
  96. &.persistent {
  97. min-width: 72px; // 2 x 36 px height, ie 2 squares
  98. }
  99. }
  100. & > .inset {
  101. width: 85px;
  102. height: $tabs-height;
  103. flex: none;
  104. -webkit-app-region: drag;
  105. }
  106. window-controls {
  107. padding-left: 10px;
  108. }
  109. }
  110. .tabs-content {
  111. flex: auto;
  112. display: flex;
  113. }
  114. hotkey-hint {
  115. position: absolute;
  116. bottom: 0;
  117. right: 0;
  118. max-width: 300px;
  119. }
  120. ::ng-deep .btn-tab-bar svg,
  121. ::ng-deep .btn-tab-bar + .dropdown-menu svg {
  122. width: 16px;
  123. height: 16px;
  124. fill: white;
  125. fill-opacity: 0.75;
  126. }
  127. .icon-wrapper {
  128. display: flex;
  129. width: 16px;
  130. height: 17px;
  131. }
  132. ::ng-deep .btn-update svg {
  133. fill: cyan;
  134. }