ui-lib.module.scss 5.4 KB

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