shell.css 4.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209
  1. /* mixins & extensions */
  2. @keyframes in {
  3. 0% {
  4. opacity: 0;
  5. }
  6. 100% {
  7. opacity: 1;
  8. }
  9. }
  10. @keyframes in-down {
  11. 0% {
  12. opacity: 0;
  13. transform: translate3D(0, -5px, 0);
  14. }
  15. 100% {
  16. opacity: 1;
  17. transform: translate3D(0, 0, 0);
  18. }
  19. }
  20. @keyframes in-up {
  21. 0% {
  22. opacity: 0;
  23. transform: translate3D(0, 5px, 0);
  24. }
  25. 100% {
  26. opacity: 1;
  27. transform: translate3D(0, 0, 0);
  28. }
  29. }
  30. @keyframes in-scale {
  31. 0% {
  32. opacity: 0;
  33. transform: scale3D(0.95, 0.95, 1);
  34. }
  35. 100% {
  36. opacity: 1;
  37. transform: scale3D(1, 1, 1);
  38. }
  39. }
  40. :root {
  41. --calcite-animation-timing: calc(150ms * var(--calcite-internal-duration-factor));
  42. --calcite-internal-duration-factor: var(--calcite-duration-factor, 1);
  43. --calcite-internal-animation-timing-fast: calc(100ms * var(--calcite-internal-duration-factor));
  44. --calcite-internal-animation-timing-medium: calc(200ms * var(--calcite-internal-duration-factor));
  45. --calcite-internal-animation-timing-slow: calc(300ms * var(--calcite-internal-duration-factor));
  46. }
  47. .calcite-animate {
  48. opacity: 0;
  49. animation-fill-mode: both;
  50. animation-duration: var(--calcite-animation-timing);
  51. }
  52. .calcite-animate__in {
  53. animation-name: in;
  54. }
  55. .calcite-animate__in-down {
  56. animation-name: in-down;
  57. }
  58. .calcite-animate__in-up {
  59. animation-name: in-up;
  60. }
  61. .calcite-animate__in-scale {
  62. animation-name: in-scale;
  63. }
  64. /**
  65. * Currently only used in Checkbox.
  66. */
  67. :host {
  68. /* Base ":host" styles for the component */
  69. box-sizing: border-box;
  70. background-color: var(--calcite-ui-foreground-1);
  71. color: var(--calcite-ui-text-2);
  72. font-size: var(--calcite-font-size--1);
  73. }
  74. :host * {
  75. box-sizing: border-box;
  76. }
  77. :root {
  78. --calcite-popper-transition: var(--calcite-animation-timing);
  79. }
  80. :host([hidden]) {
  81. display: none;
  82. }
  83. /**
  84. * CSS Custom Properties
  85. *
  86. * These properties can be overridden using the component's tag as selector.
  87. *
  88. * @prop --calcite-shell-tip-spacing: the left/right positioning of the tip-manager when slotted within a shell
  89. */
  90. :host {
  91. position: absolute;
  92. top: 0px;
  93. right: 0px;
  94. bottom: 0px;
  95. left: 0px;
  96. display: flex;
  97. height: 100%;
  98. width: 100%;
  99. flex-direction: column;
  100. overflow: hidden;
  101. --calcite-shell-tip-spacing: 26vw;
  102. }
  103. .main {
  104. position: relative;
  105. display: flex;
  106. height: 100%;
  107. width: 100%;
  108. flex: 1 1 auto;
  109. flex-direction: row;
  110. justify-content: space-between;
  111. overflow: hidden;
  112. }
  113. .main--reversed {
  114. flex-direction: row-reverse;
  115. }
  116. .content {
  117. display: flex;
  118. height: 100%;
  119. width: 100%;
  120. flex-direction: column;
  121. flex-wrap: nowrap;
  122. overflow: auto;
  123. }
  124. .content ::slotted(calcite-shell-center-row), .content ::slotted(calcite-panel), .content ::slotted(calcite-flow) {
  125. flex: 1 1 auto;
  126. align-self: stretch;
  127. max-height: unset;
  128. }
  129. .content--behind {
  130. position: absolute;
  131. top: 0px;
  132. right: 0px;
  133. bottom: 0px;
  134. left: 0px;
  135. z-index: 0;
  136. border-width: 0px;
  137. display: initial;
  138. }
  139. ::slotted(calcite-shell-center-row) {
  140. width: unset;
  141. }
  142. ::slotted(.header .heading) {
  143. font-size: var(--calcite-font-size--2);
  144. line-height: 1.375;
  145. font-weight: var(--calcite-font-weight-normal);
  146. }
  147. ::slotted(calcite-shell-panel), ::slotted(calcite-shell-center-row) {
  148. position: relative;
  149. z-index: 1;
  150. }
  151. ::slotted(calcite-panel), ::slotted(calcite-flow) {
  152. border-width: 1px;
  153. border-left-width: 0px;
  154. border-right-width: 0px;
  155. border-style: solid;
  156. border-color: var(--calcite-ui-border-3);
  157. }
  158. slot[name=center-row]::slotted(calcite-shell-center-row:not([detached])) {
  159. border-left-width: 1px;
  160. border-right-width: 1px;
  161. border-color: var(--calcite-ui-border-3);
  162. }
  163. ::slotted(calcite-tip-manager) {
  164. position: absolute;
  165. box-sizing: border-box;
  166. }
  167. @keyframes in-up {
  168. 0% {
  169. opacity: 0;
  170. transform: translate3D(0, 5px, 0);
  171. }
  172. 100% {
  173. opacity: 1;
  174. transform: translate3D(0, 0, 0);
  175. }
  176. }
  177. ::slotted(calcite-tip-manager) {
  178. animation: in-up var(--calcite-internal-animation-timing-slow) ease-in-out;
  179. border-radius: 0.25rem;
  180. --tw-shadow: 0 6px 20px -4px rgba(0, 0, 0, 0.1), 0 4px 12px -2px rgba(0, 0, 0, 0.08);
  181. --tw-shadow-colored: 0 6px 20px -4px var(--tw-shadow-color), 0 4px 12px -2px var(--tw-shadow-color);
  182. box-shadow: var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow);
  183. bottom: 0.5rem;
  184. left: var(--calcite-shell-tip-spacing);
  185. right: var(--calcite-shell-tip-spacing);
  186. z-index: 2;
  187. }