components.scss 16 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408
  1. /******************** 这里放组件样式 ********************/
  2. /***** view *****/
  3. view{box-sizing: border-box;}
  4. /***** 对齐方式 *****/
  5. .ezy-tl{text-align: left;}
  6. .ezy-tc{text-align: center;}
  7. .ezy-tr{text-align: right;}
  8. /***** 状态栏 *****/
  9. .ezy-status-bar{height: var(--status-bar-height);width: 100%;background-color: red;}
  10. /***** 超出省略 *****/
  11. // 文本超出省略号显示 (一行)
  12. @mixin single-line-ellipsis() {text-overflow: ellipsis;overflow: hidden;word-wrap: break-word;white-space: nowrap;word-break: break-all;}
  13. // 文本超出省略号显示 (多行)
  14. @mixin multi-line-ellipsis($rows: 3){-webkit-line-clamp:$rows;text-overflow: ellipsis;-o-text-overflow: ellipsis;overflow: hidden;word-wrap: break-word;display: -webkit-box;white-space: normal !important;-webkit-box-orient: vertical;}
  15. /***** 页面高度 *****/
  16. /* #ifdef H5 */
  17. //标题栏
  18. $titleBar-page: calc(100vh - var(--status-bar-height));
  19. //tabBar
  20. $titleBar-page: calc(100vh - var(--window-bottom));
  21. //标题栏 + tabBar
  22. $titleBar-tabBar-page: calc(100vh - var(--status-bar-height) - var(--window-bottom));
  23. /* #endif */
  24. /* #ifdef APP-PLUS */
  25. //标题栏
  26. $titleBar-page: calc(100vh - var(--status-bar-height));
  27. //tabBar
  28. $titleBar-page: 100vh;
  29. //标题栏 + tabBar
  30. $titleBar-tabBar-page: calc(100vh - var(--status-bar-height));
  31. /* #endif */
  32. /***** 页面背景图 *****/
  33. // no-repeat cover
  34. @mixin ezy-no-repeat-cover($position: center) {
  35. background-position: $position;background-size: cover;background-repeat: no-repeat;
  36. }
  37. // no-repeat contain
  38. @mixin ezy-no-repeat-contain($position: center) {
  39. background-position: $position;background-size: contain;background-repeat: no-repeat;
  40. }
  41. // active
  42. // 按钮缩小动画
  43. // .ezy-btn-active{transition: 0.3s;}
  44. .ezy-btn-active:active{transform:scale(0.92);}
  45. // 列表item 元素向下
  46. // .ezy-list-item-active{transition: 0.3s;}
  47. .ezy-list-item-active:active {transform: translateY(6rpx);opacity: 0.8;}
  48. // tab页 点击放大
  49. // .ezy-tab-item-active{transition: 0.3s;}
  50. .ezy-tab-item-active:active {transform: scale(1.05);}
  51. /***** 富文本处理 *****/
  52. @mixin ezy-rich-text() {
  53. div,p,span{margin: 0;padding: 0;}
  54. img{max-width: 100%;}
  55. }
  56. // 全屏的popup弹窗
  57. .ezy-popup-width-all{
  58. width: 100%;
  59. .uni-popup__wrapper{width: 100%;}
  60. }
  61. /***** tabbar *****/
  62. .ezy-custom-tabbar{
  63. width: 100%;height: 100rpx;position: fixed;left: 0;right: 0;background-color: #f9f9f9;box-shadow: 0 8rpx 24rpx rgba(0, 0, 0, 0.4);
  64. bottom: env(safe-area-inset-bottom);padding: 0 24rpx env(safe-area-inset-bottom) 24rpx;box-sizing: border-box;z-index: 9;
  65. display: flex;flex-direction: row;align-items: center;
  66. .tabbar-item-box{
  67. width: 25%;display: flex;flex-wrap: nowrap;justify-content: space-evenly;
  68. }
  69. .tabbar-item{width: 60rpx;height: 80rpx;@include ezy-no-repeat-cover;z-index: 2;}
  70. }
  71. /***** 标题栏 *****/
  72. // 三个元素
  73. .ezy-navBar-box{
  74. display: flex;align-items: center;justify-content: space-between;
  75. padding: 0 20rpx 20rpx;box-sizing: border-box;position: relative;
  76. .nav-bar-icon{
  77. width: 24rpx;height: 38rpx;
  78. background-image: url("@/static/images/common/navBar-return-btn.png");@include ezy-no-repeat-cover();
  79. }
  80. .nav-bar-title{font-size: 36rpx;color: #fff;}
  81. // 考试数字
  82. .nav-bar-other{
  83. font-size: 30rpx;color: #fff;margin-right: 2%;
  84. .key-note{color: #ffff01;}
  85. }
  86. // 文字按钮
  87. .text-btn{font-size: 26rpx;color: #fff;padding-top: 4rpx;box-sizing: border-box;}
  88. }
  89. // 两个元素
  90. .icon-title-navBar-box{
  91. display: flex;align-items: center;justify-content: center;
  92. padding: calc(6rpx + var(--status-bar-height)) 20rpx 16rpx;box-sizing: border-box;position: relative;
  93. .nav-bar-title{
  94. font-size: 34rpx;height: 63rpx;line-height: 63rpx;color: #fff;
  95. max-width: 70%;position: relative;z-index: 1;
  96. }
  97. .nav-bar-icon{
  98. width: 100rpx;height: 100rpx;display: flex;align-items: center;
  99. position: absolute;left: 0;top: calc( var(--status-bar-height) - 12rpx);z-index: 1;
  100. }
  101. .nav-bar-icon::before{
  102. width: 24rpx;height: 38rpx;content: '';display: block;margin-left: 24rpx;
  103. background-image: url("@/static/images/common/navBar-return-btn.png");@include ezy-no-repeat-cover();
  104. }
  105. }
  106. .icon-title-navBar-box::before{
  107. width: 100%;height: 356rpx;content: '';display: block;position: absolute;z-index: 0;top: 0;left: 0;
  108. background-image: url("@/static/images/common/page-header-bj.png");@include ezy-no-repeat-cover(top);
  109. }
  110. // 仅一个返回按钮
  111. .ezy-nav-bar-icon{width: 100rpx;height: 100rpx;position: absolute;left: 0;top: var(--status-bar-height);}
  112. .ezy-nav-bar-icon::after{
  113. width: 24rpx;height: 38rpx;content: '';display: block;margin: 12rpx 32rpx 12rpx;transform: rotate(180deg);
  114. background-image: url("@/static/images/common/h-jt-icon.png");@include ezy-no-repeat-cover();
  115. }
  116. /***** 试题 *****/
  117. // 标题
  118. .ezy-shiti-title{
  119. width: 208rpx;height: 91rpx;line-height: 91rpx;text-align: center;color: #fff;font-size: 32rpx;
  120. background-image: url("@/static/images/exam/shiti-title.png");@include ezy-no-repeat-cover();
  121. }
  122. // 题干
  123. .ezy-shiti-question{
  124. margin: 24rpx 0 42rpx;font-size: 32rpx;color: #333;line-height: 1.6;padding: 0 10rpx;box-sizing: border-box;
  125. text-align: justify;word-wrap: break-word;word-break: break-all;display: block;@include ezy-rich-text;
  126. }
  127. /***** 单选题 *****/
  128. .ezy-danxuan-box{
  129. margin: 0 10rpx;
  130. .danxuan-option-box{
  131. width: 100%;line-height:96rpx;border-radius: 8px;margin-bottom: 20rpx;
  132. font-size: 32rpx;color: #333;box-sizing: border-box;padding: 10rpx 24rpx;
  133. display: flex;
  134. .option-change{
  135. width: 48rpx;height: 48rpx;line-height: 48rpx;box-sizing: border-box;
  136. flex-shrink: 0;border-radius: 50%;border: 1rpx solid;margin-right: 16rpx;
  137. display: flex;align-items: center;justify-content: center;
  138. }
  139. .option-question{font-size: 32rpx;line-height: 1.6;margin-left: 6rpx;@include ezy-rich-text;
  140. text-align: justify;word-wrap: break-word;word-break: break-all;display: block;}
  141. }
  142. .danxuan-option-box.active .option-change{color: #FFF;background-color:#0589e9;border-color:#0589e9;}
  143. .danxuan-option-box.showError .option-change{color: #FFF;background-color:#ff5757;border-color:#ff5757;}
  144. .danxuan-option-box.active_right .option-change{color: #FFF;background-color:#1ac136;border-color:#1ac136;}
  145. }
  146. /***** 判断题 *****/
  147. .ezy-panduan-box{
  148. margin: 0 10rpx;
  149. .danxuan-option-box{
  150. width: 100%;line-height:96rpx;border-radius: 8px;margin-bottom: 20rpx;
  151. font-size: 32rpx;color: #333;box-sizing: border-box;padding: 10rpx 24rpx;
  152. }
  153. .uni-radio-input{
  154. width: 56rpx;height: 56rpx;border: 0;@include ezy-no-repeat-cover();
  155. background-image: url("@/static/images/exam/option-bj.png");}
  156. .option-question{display: flex;}
  157. .option-question.active .uni-radio-input{
  158. background-image: url("@/static/images/exam/option-active-img.png");
  159. background-color: transparent!important;
  160. svg{display: none;}
  161. }
  162. .option-question.showError .uni-radio-input{
  163. background-image: url("@/static/images/exam/option-error-img.png");
  164. background-color: transparent!important;
  165. svg{display: none;}
  166. }
  167. .option-question.active_right .uni-radio-input{
  168. background-image: url("@/static/images/exam/option-right-img.png");
  169. background-color: transparent!important;
  170. svg{display: none;}
  171. }
  172. }
  173. /***** 填空题 *****/
  174. .ezy-tiankong-box{
  175. margin: 0 10rpx;
  176. .tiankong-input {width: 116rpx!important;height: 52rpx;border: 1px solid #999;border-radius: 8rpx;}
  177. .tk-input-box{display: inline-block;position: relative;font-size: 0;margin: 0 4rpx;}
  178. .tiankong-input{text-align: center;}
  179. .tiankong-input.showError{color: #ff5757;}
  180. .tiankong-input.active_right{color: green;}
  181. .tk-input-box.showError::after{
  182. content: '';width: 30rpx;height: 30rpx;display: block;position: absolute;top: -12rpx;right: -6rpx;
  183. background-image: url("@/static/images/exam/option-error-img.png");@include ezy-no-repeat-cover;
  184. }
  185. .tk-input-box.active_right::after{
  186. content: '';width: 30rpx;height: 30rpx;display: block;position: absolute;top: -12rpx;right: -6rpx;
  187. background-image: url("@/static/images/exam/option-right-img.png");@include ezy-no-repeat-cover;
  188. }
  189. .ezy-shiti-question li{margin: 20rpx 0;}
  190. }
  191. /***** 英语题 *****/
  192. .ezy-yingyu-danxuan-box{
  193. .yingyu-danxuan-option-box{
  194. width: 100%;line-height:96rpx;border-radius: 8px;margin-bottom: 20rpx;
  195. font-size: 32rpx;color: #333;box-sizing: border-box;padding: 10rpx 24rpx;
  196. display: flex;
  197. .option-change{
  198. width: 48rpx;height: 48rpx;line-height: 48rpx;box-sizing: border-box;
  199. flex-shrink: 0;border-radius: 50%;border: 1rpx solid;margin-right: 16rpx;
  200. display: flex;align-items: center;justify-content: center;
  201. }
  202. .option-question{font-size: 32rpx;line-height: 1.6;margin-left: 6rpx;@include ezy-rich-text;
  203. text-align: justify;word-wrap: break-word;word-break: break-all;display: block;}
  204. }
  205. .yingyu-danxuan-option-box.active .option-change{color: #FFF;background-color:#0589e9;border-color:#0589e9;}
  206. .yingyu-danxuan-option-box.showError .option-change{color: #FFF;background-color:#ff5757;border-color:#ff5757;}
  207. .yingyu-danxuan-option-box.active_right .option-change{color: #FFF;background-color:#1ac136;border-color:#1ac136;}
  208. }
  209. /***** 英语题播放按钮 *****/
  210. .yingyu-canplay-img,.yingyu-playing-img{
  211. width: 48rpx;height: 48rpx;display: inline-block;margin: 0 24rpx 3rpx;
  212. vertical-align: middle;@include ezy-no-repeat-cover();
  213. }
  214. .yingyu-canplay-img{background-image: url("@/static/images/exam/yingyu-canplay-img.png");}
  215. .yingyu-playing-img{background-image: url("@/static/images/exam/yingyu-playing-img.gif");}
  216. /***** 试题白色的框 *****/
  217. .shiti-frame-box{
  218. width: 95%;height: auto;background-color: #fff;box-shadow: 0 0rpx 4rpx rgba(100, 159, 241, 0.2);
  219. flex: 1;position: relative;display: flex;flex-direction: column;
  220. border-radius: 16rpx;box-sizing: border-box;padding:32rpx 24rpx 36rpx;margin: 20rpx 2.5% 36rpx;
  221. }
  222. .ezy-page-body{
  223. display: flex;flex-direction: column;flex: 1;
  224. position: relative;background-color: #fff;z-index: 1;
  225. border-radius: 20rpx 20rpx 0 0;padding: 42rpx 0;overflow: hidden;
  226. }
  227. /***** 模拟标题栏 *****/
  228. .ezy-title-bar {
  229. height: calc(44px + env(safe-area-inset-top));
  230. position: fixed;top: var(--status-bar-height);left: var(--window-left);right: var(--window-right);
  231. background-color: rgb(248, 248, 248);color: rgb(0, 0, 0);box-sizing: border-box;
  232. display: flex;align-items: center;justify-content: center;overflow: hidden;z-index: 998;
  233. }
  234. // 小的提示弹窗
  235. .ezy-tip-dialog{
  236. .tip-content-box{@include ezy-no-repeat-cover;box-sizing: border-box;text-align:center;}
  237. .tip-title{
  238. color: #343434;font-size: 38rpx;margin-bottom: 24rpx;
  239. }
  240. .tip-content{
  241. color: #666;font-size: 32rpx;padding-bottom: 42rpx;
  242. border-bottom: 1px dashed #70cbf4;line-height: 1.6;
  243. }
  244. .tip-img{
  245. width: 260rpx;height: 260rpx;@include ezy-no-repeat-contain;margin: 0 auto;
  246. background-image: url("@/static/images/common/dialog-login-img.png");
  247. }
  248. .tip-btn-box{
  249. width: 100%;display: flex;justify-content: space-between;margin: 52rpx 0 0;
  250. .not-confirm-btn,.confirm-btn{
  251. width: 248rpx;height: 92rpx;line-height: 92rpx;
  252. color: #fff;@include ezy-no-repeat-cover;
  253. }
  254. .not-confirm-btn{background-image: url("@/static/images/common/tip-cancel-btn.png");}
  255. .confirm-btn{background-image: url("@/static/images/common/tip-confirm-btn.png");}
  256. }
  257. }
  258. .tip-small-dialog{
  259. .tip-content-box{
  260. width: 625rpx;height: 365rpx;padding: 42rpx 48rpx;
  261. background-image: url("@/static/images/common/tip-small-bj.png");
  262. }
  263. .tip-btn-box{
  264. margin: 0;
  265. .not-confirm-btn,.confirm-btn{
  266. width: 220rpx;height: 82rpx;line-height: 82rpx;margin: 30rpx 20rpx 0;
  267. }
  268. }
  269. }
  270. .tip-middle-dialog{
  271. .tip-content-box{
  272. width: 625rpx;height: 423rpx;padding: 42rpx 48rpx;
  273. background-image: url("@/static/images/common/tip-middle-bj.png");
  274. }
  275. }
  276. .tip-big-dialog{
  277. .tip-content-box{
  278. width: 625rpx;height: 519rpx;padding: 42rpx 48rpx;
  279. background-image: url("@/static/images/common/tip-big-bj.png");
  280. }
  281. .tip-content{min-height: 240rpx;text-align: justify;}
  282. }
  283. .tip-e-dialog{
  284. width: 625rpx;height: 519rpx;padding: 42rpx 48rpx;@include ezy-no-repeat-cover;
  285. background-image: url("@/static/images/common/tip-big-bj.png");position: relative;
  286. .close-btn{
  287. width: 100rpx;height: 100rpx;display: flex;align-items: center;justify-content: center;
  288. position: absolute;right: 12rpx;top: 12rpx;
  289. }
  290. .close-btn::after{
  291. content: '';width: 52rpx;height: 52rpx;@include ezy-no-repeat-cover;
  292. background-image: url("@/static/images/common/close-icon.png");
  293. }
  294. .e-img{height: 240rpx;@include ezy-no-repeat-cover;margin: 42rpx auto 24rpx;}
  295. .kx-e-img{width: 302rpx;background-image: url("@/static/images/xuexi/dialog-e-img1.png");}
  296. .bs-e-img{width: 219rpx;background-image: url("@/static/images/xuexi/dialog-e-img2.png");}
  297. .text-score{
  298. width: 100%;text-align: center;font-size: 36rpx;color: #333;
  299. }
  300. .time-tip-box{
  301. width: 100%;text-align: center;font-size: 30rpx;color: #9e9e9f;
  302. margin-top: 16rpx;
  303. }
  304. }
  305. .sxtk-sc-dialog{
  306. .tip-title{color: #343434;font-size: 38rpx;margin-bottom: 24rpx;}
  307. .tip-content-box{
  308. width: 625rpx;height: 587rpx;padding: 42rpx 48rpx;box-sizing: border-box;
  309. background-image: url("@/static/images/my/tk-dialog-bj.png");
  310. @include ezy-no-repeat-cover;box-sizing: border-box;text-align:center;
  311. }
  312. .tip-content{
  313. min-height: 180rpx;text-align: justify;border-bottom: 1px dashed #70cbf4;
  314. margin-bottom: 30rpx;color: #666;font-size: 32rpx;padding-bottom: 42rpx;
  315. border-bottom: 1px dashed #70cbf4;line-height: 1.8;}
  316. .not-confirm-btn,.confirm-btn{
  317. width: 519rpx;height: 98rpx;line-height: 98rpx;@include ezy-no-repeat-cover;
  318. color: #fff;
  319. }
  320. .not-confirm-btn{background-image: url("@/static/images/my/tk-dialog-qx.png");margin-top: 16rpx;}
  321. .confirm-btn{background-image: url("@/static/images/my/tk-dialog-sc.png");}
  322. }
  323. /*积分框*/
  324. .ezy-jf-box{
  325. width: 142rpx;height: 46rpx;display: flex;align-items: center;line-height: 1.2;font-size: 26rpx;
  326. @include ezy-no-repeat-cover;background-image: url("@/static/images/common/jf-bj.png");margin-top: 20rpx;
  327. .jf-icon{width: 35rpx;height: 35rpx;margin:0 4rpx 0 10rpx;flex-shrink: 0;
  328. @include ezy-no-repeat-cover;background-image: url("@/static/images/my/jf-qb.png");}
  329. .jf-text{min-width: 60rpx;text-align: center;color: #fff;}
  330. }
  331. // tab页面
  332. .ezy-tab-border{
  333. flex: 1;width: 92%;height: auto;background-color: rgba(255, 255, 255, 0.6);border-radius: 10px;
  334. margin: 12rpx auto 32rpx;position: relative;box-sizing: border-box;display: flex;flex-direction: column;
  335. }
  336. .ezy-tab-box{
  337. height: 82rpx!important;
  338. background-color: rgba(255, 255, 255, 0.6);z-index: 3;margin: 20rpx 20rpx 0;
  339. box-sizing: border-box;padding: 10rpx 12rpx;border-radius: 8rpx;
  340. .segmented-control__text{color: #333!important;}
  341. .segmented-control__item--button,.segmented-control__item--button--last{height: 62rpx;border: 0;border-width: 0!important;border-radius: 8rpx;}
  342. .segmented-control__item--button--active .segmented-control__text{color: #fff!important;}
  343. }
  344. //视频
  345. .ezy-video-box{
  346. width: 690rpx;height: 390rpx;margin: 0 auto 42rpx;
  347. box-shadow: 0 0rpx 16rpx rgba(100, 159, 241, 0.2);
  348. position: relative;box-sizing: border-box;padding: 0;
  349. .ezy-video{
  350. width: 100%;height: 100%!important;background-color: transparent;
  351. .prism-big-play-btn{
  352. width: 87rpx;height: 87rpx;@include ezy-no-repeat-cover;background-image: url("@/static/images/xuexi/play-btn.png");
  353. top: 52%;left: 50%!important;transform: translate(-50%, -50%);z-index: 20;
  354. .outter{border: 0;}
  355. }
  356. .prism-info-display{display: none;}
  357. .prism-time-display .time-bound,.prism-time-display .duration{color: #fff;}
  358. // 播放按钮动画
  359. .play-apply-animation{animation:unset;}
  360. }
  361. }
  362. // 升级提醒弹窗
  363. .phone-tip-dialog{
  364. width: 580rpx;border-radius: 12rpx;background-color: #fff;padding: 24rpx;
  365. .tip-title{padding-top: 24rpx;font-size: 34rpx;color: #333;text-align: center;}
  366. .tip-content{font-size: 32rpx;color: #666;margin:32rpx 32rpx 56rpx;line-height: 1.6;text-align: justify;}
  367. }
  368. // 暂无数据
  369. .ezy-no-sj{
  370. display: flex;align-items: center;flex-direction: column;
  371. flex: 1;justify-content: center;font-size: 32rpx;color: #666;
  372. icon{
  373. width: 219rpx;height: 240rpx;@include ezy-no-repeat-cover;
  374. margin: 0 auto 32rpx;
  375. background-image: url("@/static/images/xuexi/dialog-e-img2.png");
  376. }
  377. }