图书馆小程序
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

313 lines
5.3 KiB

2 months ago
2 months ago
2 months ago
2 months ago
2 months ago
1 month ago
1 month ago
1 month ago
2 months ago
  1. /**
  2. * 这里是共用样式的定义位置
  3. */
  4. .line-clamp-2 {
  5. overflow: hidden;
  6. text-overflow: ellipsis;
  7. display: -webkit-box;
  8. -webkit-box-orient: vertical;
  9. -webkit-line-clamp: 2;
  10. }
  11. .line-clamp-3 {
  12. overflow: hidden;
  13. text-overflow: ellipsis;
  14. display: -webkit-box;
  15. -webkit-box-orient: vertical;
  16. -webkit-line-clamp: 3;
  17. }
  18. // 卡片视图
  19. .card {
  20. border: 1px solid #f9f9f9;
  21. border-radius: 5px;
  22. margin: 12px;
  23. padding: 12px;
  24. box-shadow: 2px 2px 5px 1px rgba(143, 143, 143, 0.1);
  25. }
  26. // 单行不换行
  27. .nowrap {
  28. white-space: nowrap;
  29. text-overflow: ellipsis;
  30. overflow: hidden;
  31. }
  32. // 头像
  33. .avatar {
  34. width: 32px;
  35. height: 32px;
  36. border-radius: 50%;
  37. border: 2px solid #e5e5e5;
  38. }
  39. // 顶部图书馆头像等
  40. .top-bar{
  41. position: relative;
  42. width: 100%;
  43. height: 150px;
  44. display: flex;
  45. align-items: center;
  46. color: $uni-white;
  47. overflow: hidden;
  48. .top-bar-bg{
  49. position: absolute;
  50. left: 0;
  51. top: 0;
  52. display: block;
  53. width: 100%;
  54. height: 100%;
  55. z-index: 1;
  56. }
  57. .library-info{
  58. width: 100%;
  59. height: 100%;
  60. display: flex;
  61. flex-direction: column;
  62. justify-content: center;
  63. align-items: center;
  64. z-index: 22;
  65. .avatar{
  66. width: 65px;
  67. height: 65px;
  68. border-radius: 50%;
  69. overflow: hidden;
  70. margin-bottom: 10px;
  71. }
  72. .library-name {
  73. font-size: 16px;
  74. font-weight: bold;
  75. margin-top: 8px;
  76. text-shadow: 0 2px 5px rgba(0,0,0,0.2);
  77. }
  78. .sub-title {
  79. font-size: 12px;
  80. opacity: 0.9;
  81. margin-top: 4px;
  82. }
  83. }
  84. }
  85. // 图书列表
  86. .recommendation-list {
  87. display: flex;
  88. justify-content: space-around;
  89. padding: 0 5px;
  90. }
  91. .book-item {
  92. flex: 0 0 110px;
  93. display: flex;
  94. flex-direction: column;
  95. align-items: center;
  96. }
  97. .book-cover {
  98. width: 160rpx;
  99. height: 110px;
  100. border-radius: 4px;
  101. margin-bottom: 15px;
  102. box-shadow: 0 1px 4px rgba(0, 0, 0, 0.1);
  103. }
  104. .book-title {
  105. font-size: 12px;
  106. color: #333;
  107. text-align: center;
  108. line-height: 1.3;
  109. display: -webkit-box;
  110. -webkit-line-clamp: 2;
  111. -webkit-box-orient: vertical;
  112. overflow: hidden;
  113. text-overflow: ellipsis;
  114. width: 100%;
  115. }
  116. // 活动列表
  117. .activity-item {
  118. border-radius: 10px;
  119. background-color: #fff;
  120. margin-bottom: 20px;
  121. overflow: hidden;
  122. .activity-img {
  123. width: 100%;
  124. height: 150px;
  125. }
  126. .activity-info {
  127. display: flex;
  128. justify-content: space-between;
  129. align-items: center;
  130. padding: 10px;
  131. .activity-info-left {
  132. display: flex;
  133. flex-direction: column;
  134. justify-content: flex-start;
  135. margin-right: 6px;
  136. .title {
  137. font-size: 16px;
  138. font-weight: bold;
  139. color: #333;
  140. padding-bottom: 10px;
  141. }
  142. .time {
  143. display: flex;
  144. justify-content: flex-start;
  145. align-items: flex-start;
  146. font-size: 12px;
  147. color: #999;
  148. .time-icon{
  149. margin-top: 1px;
  150. margin-right: 2px;
  151. }
  152. // ::v-deep .uni-icons{
  153. // margin-left: 2px;
  154. // }
  155. }
  156. }
  157. .activity-btn {
  158. width: 80px;
  159. height: 32px;
  160. line-height: 32px;
  161. font-size: 14px;
  162. background-color: #01a4fe;
  163. margin: 0 !important;
  164. padding: 0 !important;
  165. border-radius: 16px;
  166. &::after {
  167. border: none !important;
  168. }
  169. &.disabled-btn {
  170. color: #797979;
  171. background-color: #e5e5e5;
  172. }
  173. }
  174. }
  175. }
  176. // 详情底部菜单(活动/图书)
  177. .detail-bottom{
  178. position: fixed;
  179. left: 0;
  180. bottom: 0;
  181. right: 0;
  182. background-color: #fff;
  183. display: flex;
  184. justify-content: space-between;
  185. align-items: center;
  186. padding: 6px 15px;
  187. }
  188. // .detail-bottom-mark{
  189. // height: 60px;
  190. // }
  191. .detail-left{
  192. display: flex;
  193. justify-content: flex;
  194. align-items: center;
  195. }
  196. .handle-btn{
  197. display: flex;
  198. justify-content: flex-start;
  199. align-items: center;
  200. background-color: transparent !important;
  201. margin: 0 !important;
  202. &::after{
  203. border: none !important;
  204. }
  205. .share-text{
  206. margin-left: 10px;
  207. font-size: 14px;
  208. }
  209. }
  210. .join-btn{
  211. font-size: 14px;
  212. color: #fff;
  213. margin: 0 !important;
  214. background-color: #01a4fe !important;
  215. border-radius: 23px;
  216. padding: 0 30px;
  217. &::after{
  218. border: none !important;
  219. }
  220. &.disabled-btn {
  221. color: #797979;
  222. background-color: #e5e5e5 !important;
  223. }
  224. }
  225. .empty {
  226. display: flex;
  227. flex-direction: column;
  228. justify-content: center;
  229. align-items: center;
  230. padding: 20px;
  231. color: #999;
  232. font-size: 15px;
  233. }
  234. // 覆盖 uni-popup 层级
  235. .uni-popup {
  236. z-index: 9999 !important;
  237. }
  238. .uni-popup__mask {
  239. z-index: 9998 !important;
  240. }
  241. .uni-popup__wrapper {
  242. z-index: 9999 !important;
  243. overflow: hidden;
  244. }
  245. .qrcode-popup {
  246. width: 240px;
  247. padding: 20px;
  248. background: #fff;
  249. border-radius: 12px;
  250. display: flex;
  251. flex-direction: column;
  252. align-items: center;
  253. }
  254. .qrcode-title {
  255. font-size: 16px;
  256. font-weight: bold;
  257. margin-bottom: 15px;
  258. }
  259. .qrcode-num {
  260. margin: 10px 0;
  261. font-size: 14px;
  262. color: #333;
  263. }
  264. .close-btn {
  265. margin-top: 10px;
  266. background: #01a4fe;
  267. color: #fff;
  268. border-radius: 20px;
  269. font-size: 14px;
  270. padding: 5px 20px;
  271. }
  272. .register-btn {
  273. position: fixed;
  274. bottom: 40px;
  275. left: 50%;
  276. transform: translateX(-50%);
  277. width: calc(100% - 40px);
  278. height: 44px;
  279. line-height: 44px;
  280. border-radius: 24px;
  281. background-color: #fff !important;
  282. color: #01a4fe !important;
  283. border: 1px solid #01a4fe !important;
  284. font-size: 16px;
  285. font-weight: 500;
  286. &::after {
  287. border: none !important;
  288. }
  289. }