index.module.less 6.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320
  1. .card-section-content {
  2. border-radius: 14px;
  3. background: linear-gradient(270deg, #DBF1FF 0%, #E7F9FF 100%) !important;
  4. // :global {
  5. // .n-card-cover {
  6. // border-radius: 14px !important;
  7. // }
  8. // }
  9. // 图片禁止拖动
  10. img {
  11. -moz-user-select: none;
  12. /* 火狐浏览器 */
  13. -webkit-user-drag: none;
  14. /* 谷歌、Safari和Opera浏览器 */
  15. -webkit-user-select: none;
  16. /* 谷歌、Safari和Opera浏览器 */
  17. -ms-user-select: none;
  18. /* IE10+浏览器 */
  19. user-select: none;
  20. /* 通用 */
  21. -webkit-touch-callout: none;
  22. /* iOS Safari */
  23. }
  24. &.isActive {
  25. border: 2px solid rgba(0, 122, 254, 1) !important;
  26. }
  27. }
  28. .card-section {
  29. position: relative;
  30. box-sizing: border-box;
  31. width: 300px;
  32. height: 220px;
  33. border-radius: 14px;
  34. background: linear-gradient(270deg, #DBF1FF 0%, #E7F9FF 100%) !important;
  35. display: inline-flex;
  36. transition: all .3s ease-in-out;
  37. :global {
  38. .n-card--bordered {
  39. border: 1Px solid rgba(202, 228, 244, 1) !important;
  40. &:hover {
  41. border: 1Px solid rgba(0, 122, 254, 1) !important;
  42. }
  43. }
  44. }
  45. &.isError {
  46. :global {
  47. .n-card--bordered {
  48. border: 1Px solid #F51C08 !important;
  49. &:hover {
  50. border: 1Px solid #F51C08 !important;
  51. box-shadow: 0 0 0 2px rgba(245, 28, 8, 0.2);
  52. }
  53. }
  54. }
  55. }
  56. &.cardDrag {
  57. cursor: move;
  58. :global {
  59. .n-image:not(.n-image--preview-disabled) {
  60. cursor: move !important;
  61. }
  62. }
  63. }
  64. &.course {
  65. cursor: pointer;
  66. }
  67. // 鼠标经过时样式
  68. &:hover,
  69. &.showAddBtn {
  70. transform: scale(1.01);
  71. transition: all .3s ease-in-out;
  72. .addBtn {
  73. display: block;
  74. opacity: 1;
  75. transition: all .3s ease-in-out;
  76. }
  77. }
  78. // 封面样式
  79. .cover {
  80. width: 100%;
  81. height: 100%;
  82. background-color: #fff;
  83. border-radius: 14px 14px 0 0;
  84. overflow: hidden;
  85. img {
  86. height: fit-content;
  87. min-height: 100%;
  88. }
  89. }
  90. :global {
  91. .n-card__footer {
  92. padding: 10px 12px;
  93. }
  94. .n-card-cover {
  95. // height: 170px;
  96. position: relative;
  97. flex: 1 auto;
  98. }
  99. }
  100. .audioPlayTypeSection {
  101. position: absolute;
  102. bottom: 10px;
  103. right: 12px;
  104. font-size: 0;
  105. gap: 8px 10px !important;
  106. &.audioPlayTypeSmall {
  107. .iconType {
  108. display: inline-block;
  109. width: 22px;
  110. height: 22px;
  111. }
  112. }
  113. .iconType {
  114. display: inline-block;
  115. width: 26px;
  116. height: 26px;
  117. }
  118. .iconPlay {
  119. background: url('../../common/images/icon-play-default.png');
  120. background-size: contain;
  121. &:hover {
  122. background: url('../../common/images/icon-play-active.png');
  123. background-size: contain;
  124. }
  125. }
  126. .iconSing {
  127. background: url('../../common/images/icon-sing-default.png');
  128. background-size: contain;
  129. &:hover {
  130. background: url('../../common/images/icon-sing-active.png');
  131. background-size: contain;
  132. }
  133. }
  134. }
  135. .footer {
  136. // display: flex;
  137. // align-items: center;
  138. // justify-content: space-between;
  139. // padding: 3px 0;
  140. }
  141. .title {
  142. display: flex;
  143. align-items: center;
  144. flex: 1;
  145. .titleType {
  146. width: 13Px;
  147. height: 13Px;
  148. margin-top: 1px;
  149. flex-shrink: 0;
  150. }
  151. .titleContent {
  152. padding-left: 6px;
  153. font-size: max(16px, 12Px);
  154. // max-width: 160px;
  155. max-width: 78%;
  156. color: #131415;
  157. font-weight: 600 !important;
  158. // flex: 1;
  159. }
  160. .titleContentDownload {
  161. max-width: 64%;
  162. }
  163. }
  164. // 收藏按钮
  165. .btnGroup {
  166. position: absolute;
  167. top: -5px;
  168. right: 0;
  169. // right: 12px;
  170. flex-shrink: 0;
  171. display: flex;
  172. align-items: center;
  173. :global {
  174. .n-spin-content {
  175. display: flex;
  176. align-items: center;
  177. }
  178. }
  179. }
  180. .btnItem+.btnItem {
  181. margin-left: 12px;
  182. }
  183. .iconCollect {
  184. width: 34px;
  185. height: 34px;
  186. // background: url('../../common/images/icon-collect-default.png') no-repeat center;
  187. // background-size: contain;
  188. // position: absolute;
  189. // right: 0;
  190. transition: transform .2s ease;
  191. &:hover {
  192. transform: scale(1.1);
  193. transition: transform .2s ease;
  194. }
  195. &.isCollect {
  196. cursor: pointer;
  197. }
  198. }
  199. .iconDiv {
  200. right: 12px;
  201. }
  202. // 精选
  203. .iconSelected {
  204. background: url('../../common/images/icon-selected.png') no-repeat center;
  205. background-size: contain;
  206. position: absolute;
  207. top: 0px;
  208. left: 0px;
  209. z-index: 9;
  210. width: 58px;
  211. height: 29px;
  212. border-top-left-radius: 14px;
  213. }
  214. // 添加
  215. .addBtn {
  216. position: absolute;
  217. top: 6px;
  218. right: 6px;
  219. font-size: max(16px, 12Px);
  220. font-weight: 600 !important;
  221. height: 32px;
  222. border-radius: 8px;
  223. // display: none;
  224. // opacity: 0;
  225. z-index: 99;
  226. transition: all .3s ease-in-out;
  227. &.addBtnDisabled {
  228. background-color: #fff;
  229. color: #999;
  230. font-weight: bold !important;
  231. --n-border: 1px solid #fff !important;
  232. --n-border-hover: 1px solid #fff !important;
  233. --n-border-pressed: 1px solid #fff !important;
  234. --n-border-focus: 1px solid #fff !important;
  235. --n-border-disabled: 1px solid #fff !important;
  236. --n-opacity-disabled: 1 !important;
  237. }
  238. }
  239. .offShelfBg {
  240. position: absolute;
  241. top: 0;
  242. left: 0;
  243. width: 100%;
  244. height: 100%;
  245. border-radius: 14px;
  246. background-color: rgba(0, 0, 0, 0.7);
  247. z-index: 10;
  248. display: flex;
  249. align-items: center;
  250. justify-content: center;
  251. flex-direction: column;
  252. .offShelfTips {
  253. font-size: 22px;
  254. font-weight: 600;
  255. color: #FFFFFF;
  256. line-height: 30px;
  257. padding-bottom: 32px;
  258. }
  259. .offShelfBtn {
  260. height: 44px;
  261. border-radius: 10px;
  262. min-width: 124px;
  263. }
  264. }
  265. }