theme.scss 4.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316
  1. // 字体
  2. @for $i from 20 through 100{
  3. .fs#{$i} {
  4. font-size: #{$i}rpx;
  5. }
  6. }
  7. // 颜色
  8. @for $i from 0 through 9{
  9. .color#{$i} {
  10. color: #{$i}#{$i}#{$i};
  11. }
  12. }
  13. // padding
  14. @for $i from 1 through 100{
  15. .p#{$i} {
  16. padding: #{$i}rpx;
  17. }
  18. }
  19. @for $i from 1 through 100{
  20. .ptb#{$i} {
  21. padding-top: #{$i}rpx ;
  22. padding-bottom: #{$i}rpx ;
  23. }
  24. }
  25. @for $i from 1 through 100{
  26. .plr#{$i} {
  27. padding-left: #{$i}rpx;
  28. padding-right: #{$i}rpx;
  29. }
  30. }
  31. @for $i from 1 through 200{
  32. .pt#{$i} {
  33. padding-top: #{$i}rpx;
  34. }
  35. }
  36. @for $i from 1 through 100{
  37. .pl#{$i} {
  38. padding-left: #{$i}rpx;
  39. }
  40. }
  41. @for $i from 1 through 100{
  42. .pr#{$i} {
  43. padding-right: #{$i}rpx;
  44. }
  45. }
  46. @for $i from 1 through 200{
  47. .pb#{$i} {
  48. padding-bottom: #{$i}rpx;
  49. }
  50. }
  51. // margin
  52. @for $i from 1 through 100{
  53. .m#{$i} {
  54. margin: #{$i}rpx;
  55. }
  56. }
  57. @for $i from 1 through 100{
  58. .mtb#{$i} {
  59. margin-top: #{$i}rpx ;
  60. margin-bottom: #{$i}rpx ;
  61. }
  62. }
  63. @for $i from 1 through 100{
  64. .mlr#{$i} {
  65. margin-left: #{$i}rpx;
  66. margin-right: #{$i}rpx;
  67. }
  68. }
  69. @for $i from 1 through 100{
  70. .mt#{$i} {
  71. margin-top: #{$i}rpx;
  72. }
  73. }
  74. @for $i from 1 through 100{
  75. .ml#{$i} {
  76. margin-left: #{$i}rpx;
  77. }
  78. }
  79. @for $i from 1 through 100{
  80. .mr#{$i} {
  81. margin-right: #{$i}rpx;
  82. }
  83. }
  84. @for $i from 1 through 100{
  85. .mb#{$i} {
  86. margin-bottom: #{$i}rpx;
  87. }
  88. }
  89. // 圆角
  90. @for $i from 0 through 100{
  91. .radius#{$i} {
  92. border-radius: #{$i}rpx;
  93. }
  94. }
  95. // padding 左右+width自动计算
  96. @for $i from 10 through 60{
  97. .w-calc-#{$i} {
  98. width: calc(100% - #{$i*2}rpx);
  99. padding-left: #{$i}rpx;
  100. padding-right: #{$i}rpx;
  101. }
  102. }
  103. // gap
  104. @for $i from 1 through 100{
  105. .gap#{$i} {
  106. gap: #{$i}rpx;
  107. }
  108. }
  109. // 高
  110. @for $i from 1 through 900{
  111. .h#{$i} {
  112. height: #{$i}rpx;
  113. }
  114. }
  115. // 宽
  116. @for $i from 1 through 900{
  117. .w#{$i} {
  118. width: #{$i}rpx;
  119. }
  120. }
  121. // 宽
  122. @for $i from 1 through 900{
  123. .lh#{$i} {
  124. line-height: #{$i}rpx;
  125. }
  126. }
  127. // font-weight
  128. $steps: 100 200 300 400 500 600 700 800 bold;
  129. @each $i in $steps {
  130. .weight-#{$i} {
  131. font-weight: $i;
  132. }
  133. }
  134. .bold {
  135. font-weight: bold;
  136. }
  137. .scrollx {
  138. overflow-x: scroll;
  139. }
  140. .scrolly {
  141. overflow-y: scroll;
  142. }
  143. .color9{
  144. color: #999;
  145. }
  146. .color6{
  147. color: #666;
  148. }
  149. .bgf{
  150. background-color: #fff;
  151. }
  152. .base-color{
  153. color: #018C39;
  154. }
  155. .colorf {
  156. color: #fff;
  157. }
  158. .bgf {
  159. background: #fff;
  160. }
  161. .fixed {
  162. position: fixed;
  163. }
  164. .absolute {
  165. position: absolute;
  166. }
  167. .relative {
  168. position: relative;
  169. }
  170. .w100 {
  171. width: 100%;
  172. }
  173. .h100 {
  174. height: 100%;
  175. }
  176. .card {
  177. background: #fff;
  178. border-radius: 15rpx;
  179. }
  180. .cover-height {
  181. height: 100%;
  182. display: flex;
  183. flex-direction: column;
  184. box-sizing: border-box;
  185. }
  186. .row {
  187. display: flex;
  188. flex-direction: row;
  189. }
  190. .column {
  191. display: flex;
  192. flex-direction: column;
  193. }
  194. .justify-start {
  195. display: flex;
  196. justify-content: flex-start;
  197. }
  198. .justify-center {
  199. display: flex;
  200. justify-content: center;
  201. }
  202. .justify-end {
  203. display: flex;
  204. justify-content: flex-end;
  205. }
  206. .justify-around {
  207. display: flex;
  208. justify-content: space-around;
  209. }
  210. .justify-evenly {
  211. display: flex;
  212. justify-content: space-evenly;
  213. }
  214. .justify-between {
  215. display: flex;
  216. justify-content: space-between;
  217. }
  218. .align-start {
  219. display: flex;
  220. align-items: flex-start;
  221. }
  222. .align-center {
  223. display: flex;
  224. align-items: center;
  225. }
  226. .align-end {
  227. display: flex;
  228. align-items: flex-end;
  229. }
  230. .center {
  231. display: flex;
  232. justify-content: center;
  233. align-items: center;
  234. }
  235. .centerV {
  236. display: flex;
  237. justify-content: center;
  238. align-items: center;
  239. flex-direction: column;
  240. }
  241. .wrap {
  242. flex-wrap: wrap;
  243. }
  244. .flex-1 {
  245. flex: 1;
  246. }
  247. .ellipsis {
  248. overflow: hidden;
  249. text-overflow: ellipsis;
  250. display: -webkit-box;
  251. -webkit-box-orient: vertical;
  252. box-sizing: border-box;
  253. width: 100%;
  254. -webkit-line-clamp: 1;
  255. }
  256. .lines-2 {
  257. -webkit-line-clamp: 2 !important;
  258. }
  259. .lines-3 {
  260. -webkit-line-clamp: 3 !important;
  261. }
  262. .bold {
  263. font-weight: bold;
  264. }
  265. .line-through {
  266. text-decoration: line-through;
  267. }
  268. .nowrap {
  269. white-space: nowrap;
  270. }
  271. .scrollx {
  272. overflow-x: scroll;
  273. }
  274. .scrolly {
  275. overflow-y: scroll;
  276. }
  277. .cvauto {
  278. content-visibility: auto;
  279. }