ui-lib.module.scss 5.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307
  1. @import "../styles/animation.scss";
  2. .card {
  3. background-color: var(--white);
  4. border-radius: 10px;
  5. box-shadow: var(--card-shadow);
  6. padding: 10px;
  7. }
  8. .popover {
  9. position: relative;
  10. z-index: 2;
  11. }
  12. .popover-content {
  13. position: absolute;
  14. animation: slide-in 0.3s ease;
  15. right: 0;
  16. top: calc(100% + 10px);
  17. }
  18. .popover-mask {
  19. position: fixed;
  20. top: 0;
  21. left: 0;
  22. width: 100vw;
  23. height: 100vh;
  24. }
  25. .list-item {
  26. display: flex;
  27. justify-content: space-between;
  28. align-items: center;
  29. min-height: 40px;
  30. border-bottom: var(--border-in-light);
  31. padding: 10px 20px;
  32. animation: slide-in ease 0.6s;
  33. .list-header {
  34. display: flex;
  35. align-items: center;
  36. .list-icon {
  37. margin-right: 10px;
  38. }
  39. .list-item-title {
  40. font-size: 14px;
  41. font-weight: bolder;
  42. }
  43. .list-item-sub-title {
  44. font-size: 12px;
  45. font-weight: normal;
  46. }
  47. }
  48. }
  49. .list {
  50. border: var(--border-in-light);
  51. border-radius: 10px;
  52. box-shadow: var(--card-shadow);
  53. margin-bottom: 20px;
  54. animation: slide-in ease 0.3s;
  55. background: var(--white);
  56. }
  57. .list .list-item:last-child {
  58. border: 0;
  59. }
  60. .modal-container {
  61. box-shadow: var(--card-shadow);
  62. background-color: var(--white);
  63. border-radius: 12px;
  64. width: 80vw;
  65. max-width: 900px;
  66. min-width: 300px;
  67. animation: slide-in ease 0.3s;
  68. --modal-padding: 20px;
  69. &-max {
  70. width: 95vw;
  71. max-width: unset;
  72. height: 95vh;
  73. display: flex;
  74. flex-direction: column;
  75. .modal-content {
  76. max-height: unset !important;
  77. flex-grow: 1;
  78. }
  79. }
  80. .modal-header {
  81. padding: var(--modal-padding);
  82. display: flex;
  83. align-items: center;
  84. justify-content: space-between;
  85. border-bottom: var(--border-in-light);
  86. .modal-title {
  87. font-weight: bolder;
  88. font-size: 16px;
  89. }
  90. .modal-header-actions {
  91. display: flex;
  92. .modal-header-action {
  93. cursor: pointer;
  94. &:not(:last-child) {
  95. margin-right: 20px;
  96. }
  97. &:hover {
  98. filter: brightness(1.2);
  99. }
  100. }
  101. }
  102. }
  103. .modal-content {
  104. max-height: 40vh;
  105. padding: var(--modal-padding);
  106. overflow: auto;
  107. }
  108. .modal-footer {
  109. padding: var(--modal-padding);
  110. display: flex;
  111. justify-content: flex-end;
  112. border-top: var(--border-in-light);
  113. box-shadow: var(--shadow);
  114. .modal-actions {
  115. display: flex;
  116. align-items: center;
  117. .modal-action {
  118. &:not(:last-child) {
  119. margin-right: 20px;
  120. }
  121. }
  122. }
  123. }
  124. }
  125. @media screen and (max-width: 600px) {
  126. .modal-container {
  127. width: 100vw;
  128. border-bottom-left-radius: 0;
  129. border-bottom-right-radius: 0;
  130. .modal-content {
  131. max-height: 50vh;
  132. }
  133. }
  134. }
  135. .show {
  136. opacity: 1;
  137. transition: all ease 0.3s;
  138. transform: translateY(0);
  139. position: fixed;
  140. left: 0;
  141. bottom: 0;
  142. animation: slide-in ease 0.6s;
  143. z-index: 99999;
  144. }
  145. .hide {
  146. opacity: 0;
  147. transition: all ease 0.3s;
  148. transform: translateY(20px);
  149. }
  150. .toast-container {
  151. position: fixed;
  152. bottom: 5vh;
  153. left: 0;
  154. width: 100vw;
  155. display: flex;
  156. justify-content: center;
  157. pointer-events: none;
  158. .toast-content {
  159. max-width: 80vw;
  160. word-break: break-all;
  161. font-size: 14px;
  162. background-color: var(--white);
  163. box-shadow: var(--card-shadow);
  164. border: var(--border-in-light);
  165. color: var(--black);
  166. padding: 10px 20px;
  167. border-radius: 50px;
  168. margin-bottom: 20px;
  169. display: flex;
  170. align-items: center;
  171. pointer-events: all;
  172. .toast-action {
  173. padding-left: 20px;
  174. color: var(--primary);
  175. opacity: 0.8;
  176. border: 0;
  177. background: none;
  178. cursor: pointer;
  179. font-family: inherit;
  180. &:hover {
  181. opacity: 1;
  182. }
  183. }
  184. }
  185. }
  186. .input {
  187. border: var(--border-in-light);
  188. border-radius: 10px;
  189. padding: 10px;
  190. font-family: inherit;
  191. background-color: var(--white);
  192. color: var(--black);
  193. resize: none;
  194. min-width: 50px;
  195. }
  196. .select-with-icon {
  197. position: relative;
  198. max-width: fit-content;
  199. .select-with-icon-select {
  200. height: 100%;
  201. border: var(--border-in-light);
  202. padding: 10px 35px 10px 10px;
  203. border-radius: 10px;
  204. appearance: none;
  205. cursor: pointer;
  206. background-color: var(--white);
  207. color: var(--black);
  208. text-align: center;
  209. }
  210. .select-with-icon-icon {
  211. position: absolute;
  212. top: 50%;
  213. right: 10px;
  214. transform: translateY(-50%);
  215. pointer-events: none;
  216. }
  217. }
  218. .modal-input {
  219. height: 100%;
  220. width: 100%;
  221. border-radius: 10px;
  222. border: var(--border-in-light);
  223. box-shadow: 0 -2px 5px rgba(0, 0, 0, 0.03);
  224. background-color: var(--white);
  225. color: var(--black);
  226. font-family: inherit;
  227. padding: 10px;
  228. resize: none;
  229. outline: none;
  230. box-sizing: border-box;
  231. &:focus {
  232. border: 1px solid var(--primary);
  233. }
  234. }
  235. .selector {
  236. position: fixed;
  237. top: 0;
  238. left: 0;
  239. height: 100vh;
  240. width: 100vw;
  241. background-color: rgba(0, 0, 0, 0.5);
  242. display: flex;
  243. align-items: center;
  244. justify-content: center;
  245. z-index: 999;
  246. &-content {
  247. .list {
  248. max-height: 90vh;
  249. overflow-x: hidden;
  250. overflow-y: auto;
  251. .list-item {
  252. cursor: pointer;
  253. background-color: var(--white);
  254. &:hover {
  255. filter: brightness(0.95);
  256. }
  257. &:active {
  258. filter: brightness(0.9);
  259. }
  260. }
  261. }
  262. }
  263. }