components.scss 16 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400
  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. .phone-status-bar{height: var(--status-bar-height);width: 100%;}
  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. // no-repeat cover
  17. @mixin ezy-no-repeat-cover($position: center) {
  18. background-position: $position;background-size: cover;background-repeat: no-repeat;
  19. }
  20. // no-repeat contain
  21. @mixin ezy-no-repeat-contain($position: center) {
  22. background-position: $position;background-size: contain;background-repeat: no-repeat;
  23. }
  24. /***** tabbar *****/
  25. .phone-custom-tabbar,.phone-client-tabbar{
  26. width: 100%;height: 100rpx;background-color: #fff;border-top: 1rpx solid #e5e4e4;z-index: 9;
  27. position: fixed;left: var(-window-left);right: var(-window right);bottom: var(--window-bottom);
  28. box-sizing: border-box;padding-bottom: env(safe-area-inset-bottom);display: flex;justify-content: space-around;align-items: center;
  29. .tabbar-item{text-align: center;width: 160rpx;}
  30. .tabbar-item-icon{width: 40rpx;height: 40rpx;display: block;@include ezy-no-repeat-cover();margin: 0 auto 2rpx;}
  31. .tabbar-item-text{font-size: 28rpx;color: #333;}
  32. .tabbar-item-text.active{color: #3fd2a1;}
  33. }
  34. .phone-client-tabbar{
  35. background-color: #0abf8a;border: 0;
  36. .tabbar-item-text{color: #fff;}
  37. }
  38. /***** list列表滚动 *****/
  39. .phone-scroll-view{
  40. .uni-load-more{margin-bottom:var(--status-bar-height);}
  41. .uni-list--border-bottom{display: none;}
  42. }
  43. /***** 富文本处理 *****/
  44. @mixin ezy-rich-text() {
  45. white-space: pre-wrap;text-align: justify;
  46. div,p,span{margin: 0;padding: 0;}
  47. img{max-width: 100%;}
  48. .ql-align-center{text-align: center}
  49. .ql-align-right{text-align: right}
  50. // 9号字
  51. .ql-size-9px{font-size: 18rpx;}
  52. // 12号字
  53. .ql-size-12px{font-size: 24rpx;}
  54. // 14号字
  55. .ql-size-14px{font-size: 28rpx;}
  56. // 16号字
  57. .ql-size-16px{font-size: 32rpx;}
  58. // 18号字
  59. .ql-size-18px{font-size: 36rpx;}
  60. // 24号字
  61. .ql-size-24px{font-size: 48rpx;}
  62. // 32号字
  63. .ql-size-32px{font-size: 64rpx;}
  64. // 单倍行距
  65. .line-height-lineHeight1{line-height: 1;}
  66. // 1.5倍行距
  67. .line-height-lineHeight1-5{line-height: 1.5;}
  68. // 2倍行距
  69. .line-height-lineHeight2{line-height: 2;}
  70. // 2.5倍行距
  71. .line-height-lineHeight2-5{line-height: 2.5;}
  72. // 3倍行距
  73. .line-height-lineHeight3{line-height: 3;}
  74. }
  75. /***** 按钮 *****/
  76. // 按钮
  77. .phone-green-btn[type='default']{background-color: #3fd2a1;color: #fff;}
  78. .phone-white-btn[type='default']{background-color: #fff;color: #3fd2a1;border: 1rpx solid #3fd2a1;}
  79. .phone-white-btn[type='default']:after{display: none;}
  80. .phone-green-btn[type='default']:hover{background-color: #34c595;color: #fff;}
  81. /***** 标题栏 *****/
  82. // 三个元素
  83. .phone-navBar-box{
  84. display: flex;align-items: center;justify-content: space-between;background-color: #fff;
  85. padding: var(--status-bar-height) 20rpx 20rpx;box-sizing: border-box;position: relative;
  86. .nav-bar-icon{
  87. width: 24rpx;height: 38rpx;
  88. background-image: url("@/static/images/common/nav-bar-jt.svg");@include ezy-no-repeat-cover();
  89. }
  90. .nav-bar-title{font-size: 36rpx;color: #333;}
  91. // 考试数字
  92. .nav-bar-other{
  93. font-size: 30rpx;color: #fff;margin-right: 2%;
  94. .key-note{color: #ffff01;}
  95. }
  96. // 文字按钮
  97. .text-btn{font-size: 26rpx;color: #666;padding-top: 4rpx;box-sizing: border-box;}
  98. // 图标
  99. .nav-bar-icon-box{
  100. .nav-bar-right-icon{font-size: 42rpx;color: #666;}
  101. .nav-bar-right-icon + .nav-bar-right-icon{margin-left: 16rpx;}
  102. }
  103. }
  104. // 两个元素
  105. .icon-title-navBar-box,.icon-title-bjcolor-navBar-box{
  106. display: flex;align-items: center;justify-content: center;background-color: #fff;
  107. padding: var(--status-bar-height) 20rpx 20rpx;box-sizing: border-box;position: relative;
  108. .nav-bar-title{
  109. font-size: 32rpx;height: 63rpx;line-height: 63rpx;color: #333;max-width: 70%;
  110. }
  111. .nav-bar-icon{
  112. width: 24rpx;height: 38rpx;position: absolute;left: 24rpx;top: calc(12rpx + var(--status-bar-height));;
  113. background-image: url("@/static/images/common/nav-bar-jt.svg");@include ezy-no-repeat-cover();
  114. }
  115. }
  116. // 带背景色client使用
  117. .icon-title-bjcolor-navBar-box{
  118. background-color: #fff;padding: 10rpx;border-bottom: 1rpx solid #e0e0e0;
  119. .nav-bar-title{color: #3fd2a1;}
  120. .nav-bar-icon{width: 100rpx;height: 63rpx;background-image:unset;}
  121. .nav-bar-icon::before{content:'';width:50rpx;height: 50rpx;display: inline-block;margin-top: 6rpx;
  122. @include ezy-no-repeat-cover();
  123. background-image: url("@/static/images/common/return-icon.png");}
  124. }
  125. // 仅一个返回按钮
  126. .phone-nav-bar-icon{width: 24rpx;height: 38rpx;position: absolute;left: 24rpx;top: var(--status-bar-height);
  127. background-image: url("@/static/images/common/nav-bar-jt.svg");@include ezy-no-repeat-cover();
  128. }
  129. /***** tab *****/
  130. // client
  131. .phone-tab-box{
  132. .segmented-control--text{height: 80rpx!important;}
  133. .segmented-control__text{font-size: 32rpx!important;}
  134. }
  135. // admin
  136. .admin-tab-box{
  137. uni-scroll-view{z-index: 99!important;}
  138. .v-tabs__container-item.active{color: #3fd2a1!important;}
  139. .v-tabs__container-line.animation{height:4rpx!important;background-color: #3fd2a1!important;}
  140. }
  141. /***** 查询框 *****/
  142. .phone-search-box{
  143. width: 100%;height: 110rpx;background-color:#f4f6fa;
  144. padding: 20rpx 42rpx;box-sizing: border-box;
  145. position: relative;
  146. .search-input {
  147. height: 70rpx;line-height: 70rpx;font-size: 28rpx;background-color:#fff;
  148. border-radius: 35rpx;padding: 0 70rpx 0 20rpx;
  149. }
  150. .uni-input-placeholder{color:#a4a4a4;}
  151. .search-icon {
  152. width: 100rpx;height: 60rpx;line-height: 60rpx;text-align: center;
  153. position: absolute;right: 52rpx;top: 25rpx;
  154. background-color: #3fd2a1;
  155. border-radius: 40rpx;
  156. }
  157. }
  158. // 前面带线的标题
  159. .phone-line-title {display: block;color: #333;font-size: 36rpx;line-height: 1;}
  160. .phone-line-title:before{content: ' ';width: 4rpx;height: 36rpx;background-color:#3fd2a1;
  161. margin-right: 18rpx;display: inline-block;vertical-align: middle;}
  162. /***** 试题---题干 *****/
  163. .phone-shiti-question{
  164. font-size: 32rpx;color: #333;line-height: 1.6;margin-bottom: 24rpx;
  165. text-align: justify;word-wrap: break-word;word-break: break-all;display: block;@include ezy-rich-text;
  166. display: flex;flex-direction: row;justify-content: flex-start;
  167. .question-num{flex-shrink: 0;}
  168. }
  169. /***** 单选题 *****/
  170. .phone-danxuan-box{
  171. margin: 0 10rpx;overflow: auto;height: calc(100vh - 440rpx - var(--status-bar-height));
  172. .danxuan-option-box{
  173. width: 100%;line-height:96rpx;border-radius: 8px;margin-bottom: 20rpx;
  174. font-size: 32rpx;color: #666;box-sizing: border-box;padding: 10rpx 24rpx;
  175. display: flex;
  176. .option-change{
  177. width: 48rpx;height: 48rpx;line-height: 48rpx;box-sizing: border-box;
  178. flex-shrink: 0;border-radius: 50%;border: 1rpx solid;margin-right: 16rpx;
  179. display: flex;align-items: center;justify-content: center;
  180. }
  181. .option-question{font-size: 32rpx;line-height: 1.6;margin-left: 6rpx;@include ezy-rich-text;
  182. text-align: justify;word-wrap: break-word;word-break: break-all;display: block;}
  183. }
  184. .danxuan-option-box.active .option-change{color: #FFF;background-color:#6186fb;border-color:#6186fb;}
  185. .danxuan-option-box.showError .option-change{color: #FFF;background-color:#ff5757;border-color:#ff5757;}
  186. .danxuan-option-box.active_right .option-change{color: #FFF;background-color:#1ac136;border-color:#1ac136;}
  187. }
  188. /***** 判断题 *****/
  189. .phone-duoxuan-box{
  190. margin: 0 10rpx;overflow: auto;height: calc(100vh - 440rpx - var(--status-bar-height));
  191. .duoxuan-option-box{
  192. width: 100%;line-height:96rpx;border-radius: 8px;margin-bottom: 20rpx;
  193. font-size: 32rpx;color: #666;box-sizing: border-box;padding: 10rpx 24rpx;
  194. display: flex;
  195. .option-change{
  196. width: 48rpx;height: 48rpx;line-height: 48rpx;box-sizing: border-box;
  197. flex-shrink: 0;border-radius: 50%;border: 1rpx solid;margin-right: 16rpx;
  198. display: flex;align-items: center;justify-content: center;
  199. }
  200. .option-question{font-size: 32rpx;line-height: 1.6;margin-left: 6rpx;@include ezy-rich-text;
  201. text-align: justify;word-wrap: break-word;word-break: break-all;display: block;}
  202. }
  203. // active background-color:#0589e9;
  204. .duoxuan-option-box.active .option-change{color: #FFF;background-color:#6186fb;border-color:#6186fb;}
  205. .duoxuan-option-box.showError .option-change{color: #FFF;background-color:#ff5757;border-color:#ff5757;}
  206. .duoxuan-option-box.active_right .option-change{color: #FFF;background-color:#1ac136;border-color:#1ac136;}
  207. }
  208. /***** 判断题 *****/
  209. .phone-panduan-box{
  210. margin: 0 10rpx;overflow: auto;height: calc(100vh - 440rpx - var(--status-bar-height));
  211. .panduan-option-box{
  212. width: 100%;line-height:96rpx;border-radius: 8px;margin-bottom: 20rpx;
  213. font-size: 32rpx;color: #666;box-sizing: border-box;padding: 10rpx 24rpx;
  214. .option-question{font-size: 32rpx;line-height: 1.6;margin-left: 16rpx;margin-bottom: 24rpx;
  215. text-align: justify;word-wrap: break-word;word-break: break-all;display: flex;
  216. .uni-radio-input{margin-right: 20rpx;}
  217. }
  218. }
  219. // active background-color:#0589e9;
  220. .option-question.active .uni-radio-input{color: #FFF;background-color:#6186fb!important;border-color:#6186fb!important;}
  221. .option-question.showError .uni-radio-input{color: #FFF;background-color:#ff5757!important;border-color:#ff5757!important;}
  222. .option-question.active_right .uni-radio-input{color: #FFF;background-color:#1ac136!important;border-color:#1ac136!important;}
  223. }
  224. /***** 填空题 *****/
  225. .phone-tiankong-box{
  226. overflow: auto;height: calc(100vh - 440rpx - var(--status-bar-height));
  227. .tiankong-option-box{
  228. padding:0 40rpx;box-sizing: border-box;margin-bottom: 36rpx;
  229. .option-question{font-size: 30rpx;color: #333;}
  230. .option-question-text{font-size: 30rpx;color: #333;margin-top: 16rpx;background: #f0f0f0;padding: 10px;border-radius: 4px;}
  231. }
  232. }
  233. /***** 考试须知 *****/
  234. .phone-ksxz-dialog{
  235. position: relative;
  236. .uni-dialog-title{
  237. padding: 24rpx 0!important;font-size: 30rpx;border-bottom: 1px solid #f5f5f5;
  238. .uni-popup__info{color: #333!important;}
  239. }
  240. .ksxz-close-icon{width: 36rpx;height: 36rpx;@include ezy-no-repeat-cover;
  241. position: absolute;top: 26rpx;right: 20rpx;
  242. background-image: url("@/static/images/common/close-icon.svg");}
  243. .uni-dialog-content{justify-content: flex-start!important;}
  244. .uni-dialog-button-text{color: #999!important;}
  245. .uni-dialog-button-text.uni-button-color{color: #3fd2a1!important;}
  246. .ksxz-content-box{
  247. width: 100%;font-size: 28rpx;color: #333;max-height: 70vh;overflow: auto;
  248. >view{margin-bottom: 12rpx;line-height: 1.6;}
  249. .ksms-row{margin-bottom: 12rpx;}
  250. .ksms-intro{color: #666;}
  251. .ksxz-img-box{
  252. text-align: center;
  253. img{max-width: 100%;max-height: 260rpx;}
  254. }
  255. }
  256. }
  257. /***** 默认头像 *****/
  258. .phone-default-userImg{
  259. width: 170rpx;height: 170rpx;margin: 0 auto;
  260. background-image: url("@/static/images/my/user-default-img.png");@include ezy-no-repeat-cover();}
  261. /***** form *****/
  262. // label-input
  263. .form-label-input{
  264. width: 100%;display: flex;justify-content: space-between;align-items: center;
  265. background-color: #fff;font-size: 30rpx;color: #333;
  266. padding: 20rpx;box-sizing: border-box;margin-bottom: 2rpx;
  267. .form-label-require{color: #ff0101;margin-right: 6rpx;display: inline-block;}
  268. .phone-form-label{min-width: 180rpx;}
  269. input{text-align: right;flex: 1;}
  270. .is-input-border{border:0!important;}
  271. .uni-input-placeholder{overflow: unset;}
  272. .uni-easyinput__placeholder-class{font-size: 30rpx!important;}
  273. .content-clear-icon{color: rgb(192, 196, 204)!important;}
  274. icon{width: 30rpx;height: 30rpx;@include ezy-no-repeat-cover;
  275. background-image: url("@/static/images/common/nav-bar-jt-bottom.svg");
  276. transform: rotate(270deg);margin-left: 4rpx;}
  277. }
  278. // label-radio
  279. .form-label-radio{
  280. width: 100%;display: flex;justify-content: space-between;align-items: center;
  281. background-color: #fff;font-size: 30rpx;color: #333;
  282. padding: 6rpx 20rpx;box-sizing: border-box;margin-bottom: 2rpx;
  283. .form-label-require{color: #ff0101;margin-right: 6rpx;width:16rpx;display: inline-block;}
  284. .phone-form-label{min-width: 180rpx;line-height:52rpx;}
  285. .form-radio-group{display: flex;flex-wrap: wrap;flex: 1;}
  286. .form-radio-double-group{justify-content: space-between;}
  287. .form-radio-item{
  288. width: 29%;height:60rpx;line-height:60rpx;border-radius: 6rpx;box-sizing: border-box;
  289. background-color:#f5f5f5;text-align: center;margin:10rpx 2%;border:1rpx solid #f5f5f5;
  290. box-sizing: border-box;padding: 0 6rpx;font-size: 26rpx;
  291. }
  292. .genderActive{background-color:#e5f8f4;border:1rpx solid #6bccb0;color:#6bccb0;}
  293. // btn
  294. .radio-add-btn{
  295. width: 29%;height:60rpx;line-height:60rpx;border-radius: 6rpx;box-sizing: border-box;
  296. text-align: center;margin:10rpx 2%;border:1rpx solid #6bccb0;color:#6bccb0;
  297. box-sizing: border-box;padding: 0 6rpx;font-size: 26rpx;background-color:#e5f8f4;
  298. }
  299. .radio-btn-box{
  300. width: 100%;display:block;text-align: center;
  301. .radio-btn{color:#6bccb0;display:inline-block;margin: 16rpx 0;}
  302. .radio-btn::after{
  303. content: '';width: 30rpx;height: 30rpx;@include ezy-no-repeat-cover;
  304. background-image: url("@/static/images/common/nav-bar-jt-bottom-green.svg");
  305. display: inline-block;vertical-align: middle;margin-left: 10rpx;font-size: 30rpx;
  306. }
  307. .collapsed-btn::after{transform: rotate(180deg);}
  308. }
  309. .label-radio-btn-box{margin-right: 180rpx;}
  310. }
  311. // label-select
  312. .form-label-select{
  313. width: 100%;display: flex;justify-content: space-between;
  314. background-color: #fff;font-size: 30rpx;color: #333;
  315. padding: 20rpx;box-sizing: border-box;margin-bottom: 2rpx;
  316. .form-label-require{color: #ff0101;margin-right: 6rpx;width:16rpx;display: inline-block;}
  317. .phone-form-label{min-width: 180rpx;line-height:60rpx;}
  318. .form-radio-picker{width:auto!important;flex: unset!important;display: flex;align-items: center;}
  319. .form-radio-select{
  320. display: flex;align-items: center;
  321. icon{width: 30rpx;height: 30rpx;@include ezy-no-repeat-cover;
  322. background-image: url("@/static/images/common/nav-bar-jt-bottom.svg");
  323. transform: rotate(270deg);margin-left: 4rpx;}
  324. }
  325. }
  326. // label-switch
  327. .form-label-switch{
  328. width: 100%;display: flex;justify-content: space-between;align-items: center;
  329. background-color: #fff;font-size: 30rpx;color: #333;
  330. padding: 20rpx;box-sizing: border-box;margin-bottom: 2rpx;
  331. .form-label-require{color: #ff0101;margin-right: 6rpx;width:16rpx;display: inline-block;}
  332. .phone-form-label{min-width: 180rpx;line-height:52rpx;}
  333. }
  334. /***** admin上传 *****/
  335. .admin-upload-btn-box{
  336. width: 100px;height: 100px;border: 1rpx dashed #ccc;margin: 0 auto;
  337. display: flex;align-items: center;justify-content: center;border-radius: 8rpx;
  338. text{font-size: 42rpx;color:#d7d7d7;}
  339. }
  340. .upload-bottom-text {font-size: 24rpx;color: #666;text-align: center;margin-top: 10rpx;}
  341. /***** 通用弹窗 *****/
  342. .phone-common-dialog{
  343. width: 660rpx;border-radius: 12rpx;background-color: #fff;padding-top: 24rpx;
  344. .common-title{padding-top: 24rpx;font-size: 34rpx;color: #333;text-align: center;}
  345. .common-content{font-size: 32rpx;color: #666;margin:32rpx 48rpx 48rpx;line-height: 1.6;}
  346. .common-input-box{
  347. padding: 32rpx 0 20rpx;
  348. .common-input-row{display: flex;align-items: center;margin-bottom: 24rpx;}
  349. .common-label-require{color: #ff0101;margin-right: 6rpx;width:16rpx;display: inline-block;flex-shrink: 0;}
  350. .common-input-label{width: 200rpx;line-height:70rpx;font-size: 28rpx;color: #333;text-align: right;}
  351. .common-input{
  352. height: 70rpx;min-height: 70rpx;padding: 20rpx;box-sizing: border-box;margin-right: 30rpx;
  353. border: 1rpx solid #f0f0f0;border-radius: 10rpx;display: block;flex: 1;font-size: 28rpx;}
  354. }
  355. .content-center-class{text-align: center;}
  356. .content-left-class{text-align: left;}
  357. .content-margin-bottom{margin-bottom: 20rpx;}
  358. .common-btn-box{display: flex;flex-direction: row;border-top-color: #f5f5f5;border-top-style: solid;border-top-width: 1px;}
  359. .not-confirm-btn,.confirm-btn{height: 90rpx;line-height: 90rpx;flex:1;text-align: center;font-size: 30rpx;}
  360. .not-confirm-btn{color: #666;}
  361. .confirm-btn{border-left-color: #f0f0f0;border-left-style: solid;border-left-width: 1px;color: #3fd2a1;}
  362. }