common.css 3.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230
  1. image {
  2. display: block;
  3. }
  4. /* 隐藏scroll-view 滚动条 */
  5. ::-webkit-scrollbar {
  6. display: none;
  7. }
  8. .iPhone-bottom {
  9. padding-bottom: constant(safe-area-inset-bottom);
  10. padding-bottom: env(safe-area-inset-bottom);
  11. }
  12. /* 不换行 */
  13. .view-nowrap{
  14. white-space: nowrap;
  15. }
  16. /* 数字和文字不自动换行 */
  17. .overflowWrap{
  18. overflowWrap:break-word;
  19. word-break: break-all;
  20. }
  21. /* 自动换行 */
  22. .view-word-wrap{
  23. white-space: pre-wrap;
  24. word-wrap: break-word;
  25. }
  26. /*超出三行... */
  27. .text-overflow-ellipsis-t {
  28. text-overflow: -o-ellipsis-lastline;
  29. overflow: hidden;
  30. text-overflow: ellipsis;
  31. display: -webkit-box;
  32. -webkit-line-clamp: 3;
  33. line-clamp: 3;
  34. -webkit-box-orient: vertical;
  35. white-space: pre-wrap;
  36. word-wrap: break-word;
  37. }
  38. /*超出两行... */
  39. .text-overflow-ellipsis {
  40. text-overflow: -o-ellipsis-lastline;
  41. overflow: hidden;
  42. text-overflow: ellipsis;
  43. display: -webkit-box;
  44. -webkit-line-clamp: 2;
  45. line-clamp: 2;
  46. -webkit-box-orient: vertical;
  47. white-space: pre-wrap;
  48. word-wrap: break-word;
  49. }
  50. /*超出一行... */
  51. .text-overflow-ellipsis-one {
  52. white-space: nowrap;
  53. text-overflow: ellipsis;
  54. overflow: hidden;
  55. word-break: break-all;
  56. }
  57. /* 内部盒子 */
  58. .box-border-box{
  59. box-sizing: border-box;
  60. }
  61. .flex-common-css {
  62. width: 100%;
  63. height: 100vh;
  64. display: flex;
  65. flex-direction: column;
  66. }
  67. .flex-index-css {
  68. width: 100%;
  69. height: 100%;
  70. display: flex;
  71. flex-direction: column;
  72. }
  73. .flex-direction-column {
  74. display: flex;
  75. flex-direction: column;
  76. }
  77. .display-flex {
  78. display: flex;
  79. }
  80. .flex-justify-space {
  81. display: flex;
  82. justify-content: space-between;
  83. }
  84. .flex-justify-around {
  85. display: flex;
  86. justify-content: space-around;
  87. }
  88. .flex-justify-center {
  89. display: flex;
  90. justify-content: center;
  91. }
  92. .flex-justify-end {
  93. display: flex;
  94. justify-content: flex-end;
  95. }
  96. .flex-justify-start {
  97. display: flex;
  98. justify-content: flex-start;
  99. }
  100. .align-items-start {
  101. display: flex;
  102. align-items: flex-start;
  103. }
  104. .align-items-center {
  105. display: flex;
  106. align-items: center;
  107. }
  108. .align-items-flex-end {
  109. display: flex;
  110. align-items: flex-end;
  111. }
  112. .flex-wrap-wrap {
  113. display: flex;
  114. flex-wrap: wrap;
  115. }
  116. .common-view-css{
  117. width: 100%;
  118. flex: 1;
  119. }
  120. .scroll-view-css {
  121. width: 100%;
  122. flex: 1;
  123. overflow: auto;
  124. }
  125. .box-sizing-border {
  126. box-sizing: border-box;
  127. }
  128. .text-align-center {
  129. text-align: center;
  130. }
  131. .text-align-right {
  132. text-align: right;
  133. }
  134. .text-align-left {
  135. text-align: left;
  136. }
  137. .flex-1{
  138. flex: 1;
  139. }
  140. .flex-shrink0{
  141. flex-shrink: 0;
  142. }
  143. /* 字体大小 */
  144. .fs-20{
  145. font-size: 20rpx;
  146. }
  147. .fs-22{
  148. font-size: 22rpx;
  149. }
  150. .fs-24{
  151. font-size: 24rpx;
  152. }
  153. /* 字体粗细 */
  154. .fw-b{
  155. font-weight: bold;
  156. }
  157. .fw-400{
  158. font-weight: 400;
  159. }
  160. .fw-500{
  161. font-weight: 500;
  162. }
  163. .fw-600{
  164. font-weight: 600;
  165. }
  166. /* 字体颜色 */
  167. .fc-f{
  168. color: #fff;
  169. }
  170. .fc-0{
  171. color: #000;
  172. }
  173. .fc-3{
  174. color: #333;
  175. }
  176. .fc-6{
  177. color: #666;
  178. }
  179. .fc-9{
  180. color: #999;
  181. }
  182. /* 背景颜色 */
  183. .bgc-f{
  184. background-color: #fff;
  185. }
  186. .bgc-c{
  187. background-color: #ccc;
  188. }
  189. .bgc-3{
  190. background-color: #333;
  191. }
  192. .bgc-9{
  193. background-color: #999;
  194. }
  195. /* 内边距 */
  196. .p-16{
  197. padding: 16rpx;
  198. }
  199. .p-24{
  200. padding: 24rpx;
  201. }
  202. .p-30{
  203. padding: 30rpx;
  204. }
  205. .p-32{
  206. padding: 32rpx;
  207. }
  208. /* 外边距 */
  209. .m-24{
  210. margin: 24rpx;
  211. }