uni.scss 1.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778
  1. page, block, view, scroll-view, swiper, movable-view, icon, text, progress,
  2. button, checkbox, form, input, label, picker, picker-view, radio, slider, switch,
  3. textarea, navigator, audio, image, video, map, canvas, contact-button, cover-image, cover-view{
  4. box-sizing: border-box;
  5. }
  6. // #ifdef MP-TOUTIAO
  7. * {
  8. box-sizing: border-box;
  9. }
  10. // #endif
  11. .text-center {
  12. text-align: center;
  13. }
  14. .font-weight {
  15. font-weight: bold;
  16. }
  17. // 屏幕宽度
  18. .page-width {
  19. width: 100%;
  20. }
  21. // 背景图片
  22. .background-image {
  23. background-repeat: no-repeat;
  24. background-size: 100% 100%;
  25. background-position: center;
  26. }
  27. // 重要
  28. $uni-important-color-red: #ff4544; // 小面积使用,用于特别强调和突出的文字,按钮和icon
  29. $uni-important-color-black: #353535;// 用于重要级文字信息、标题信息等
  30. // 一般
  31. $uni-general-color-one: #666666;// 用于普通段落信息
  32. $uni-general-color-two: #999999;// 用于辅助、次要文字信息
  33. $uni-general-color-three: #cdcdcd;// 用于灰按钮、占位文字
  34. // 较弱
  35. $uni-weak-color-one: #e2e2e2;// 用于分割线
  36. $uni-weak-color-two: #f7f7f7;// 用于内容区域底色
  37. // 重要
  38. $uni-font-size-import-one: 36rpx; // 用在少量标题
  39. $uni-line-height-import-one: 44rpx;
  40. $uni-font-size-import-two: 32rpx; // 用于一些较为重要的文字或操作按钮
  41. $uni-line-height-import-two: 40rpx;
  42. // 一般
  43. $uni-font-size-general-one: 28rpx;// 用于大多数文字
  44. $uni-line-height-general-one: 36rpx;
  45. $uni-font-size-general-two: 26rpx;// 用于大多数文字
  46. $uni-line-height-general-two: 32rpx;
  47. // 弱
  48. $uni-font-size-weak-one: 24rpx; // 用于辅助性文字
  49. $uni-line-height-weak-one: 30rpx;
  50. $uni-font-size-weak-two: 22rpx; // 用于辅助性文字
  51. $uni-line-height-weak-two: 28rpx;
  52. /*全局文字大小*/
  53. $uni-font-size: 32rpx;
  54. /* 屏幕宽度*/
  55. $screen-width: 750rpx;
  56. page {
  57. font-size: $uni-font-size;
  58. background: $uni-weak-color-two;
  59. }
  60. .page-width {
  61. width: 100%;
  62. }