dialog.css 2.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129
  1. /* [data-component="dialog-trigger"] { } */
  2. [data-component="dialog-overlay"] {
  3. position: fixed;
  4. inset: 0;
  5. z-index: 50;
  6. background-color: transparent;
  7. /* animation: overlayHide 250ms ease 100ms forwards; */
  8. /**/
  9. /* &[data-expanded] { */
  10. /* animation: overlayShow 250ms ease; */
  11. /* } */
  12. }
  13. [data-component="dialog"] {
  14. position: fixed;
  15. inset: 0;
  16. z-index: 50;
  17. display: flex;
  18. align-items: center;
  19. justify-content: center;
  20. [data-slot="container"] {
  21. position: relative;
  22. z-index: 50;
  23. width: min(calc(100vw - 16px), 624px);
  24. height: min(calc(100vh - 16px), 512px);
  25. display: flex;
  26. flex-direction: column;
  27. align-items: center;
  28. justify-items: start;
  29. [data-slot="content"] {
  30. display: flex;
  31. flex-direction: column;
  32. align-items: flex-start;
  33. align-self: stretch;
  34. gap: 8px;
  35. width: 100%;
  36. max-height: 100%;
  37. /* padding: 8px; */
  38. padding: 8px 8px 0 8px;
  39. border: 1px solid var(--border-base);
  40. border-radius: var(--radius-md);
  41. background: var(--surface-raised-stronger-non-alpha);
  42. box-shadow:
  43. 0 15px 45px 0 rgba(19, 16, 16, 0.22),
  44. 0 3.35px 10.051px 0 rgba(19, 16, 16, 0.13),
  45. 0 0.998px 2.993px 0 rgba(19, 16, 16, 0.09);
  46. /* animation: contentHide 300ms ease-in forwards; */
  47. /**/
  48. /* &[data-expanded] { */
  49. /* animation: contentShow 300ms ease-out; */
  50. /* } */
  51. [data-slot="header"] {
  52. display: flex;
  53. height: 40px;
  54. padding: 4px 4px 4px 8px;
  55. justify-content: space-between;
  56. align-items: center;
  57. flex-shrink: 0;
  58. align-self: stretch;
  59. [data-slot="title"] {
  60. color: var(--text-strong);
  61. /* text-16-medium */
  62. font-family: var(--font-family-sans);
  63. font-size: var(--font-size-large);
  64. font-style: normal;
  65. font-weight: var(--font-weight-medium);
  66. line-height: var(--line-height-x-large); /* 150% */
  67. letter-spacing: var(--letter-spacing-tight);
  68. }
  69. /* [data-slot="close-button"] {} */
  70. }
  71. /* [data-slot="description"] {} */
  72. [data-slot="body"] {
  73. width: 100%;
  74. position: relative;
  75. display: flex;
  76. flex-direction: column;
  77. flex: 1;
  78. overflow-y: auto;
  79. }
  80. }
  81. }
  82. }
  83. @keyframes overlayShow {
  84. from {
  85. opacity: 0;
  86. }
  87. to {
  88. opacity: 1;
  89. }
  90. }
  91. @keyframes overlayHide {
  92. from {
  93. opacity: 1;
  94. }
  95. to {
  96. opacity: 0;
  97. }
  98. }
  99. @keyframes contentShow {
  100. from {
  101. opacity: 0;
  102. transform: scale(0.96);
  103. }
  104. to {
  105. opacity: 1;
  106. transform: scale(1);
  107. }
  108. }
  109. @keyframes contentHide {
  110. from {
  111. opacity: 1;
  112. transform: scale(1);
  113. }
  114. to {
  115. opacity: 0;
  116. transform: scale(0.96);
  117. }
  118. }