create.css 4.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210
  1. /**
  2. * 这里是uni-app内置的常用样式变量
  3. *
  4. * uni-app 官方扩展插件及插件市场(https://ext.dcloud.net.cn)上很多三方插件均使用了这些样式变量
  5. * 如果你是插件开发者,建议你使用scss预处理,并在插件代码中直接使用这些变量(无需 import 这个文件),方便用户通过搭积木的方式开发整体风格一致的App
  6. *
  7. */
  8. /**
  9. * 如果你是App开发者(插件使用者),你可以通过修改这些变量来定制自己的插件主题,实现自定义主题功能
  10. *
  11. * 如果你的项目同样使用了scss预处理,你也可以直接在你的 scss 代码中使用如下变量,同时无需 import 这个文件
  12. */
  13. /* 颜色变量 */
  14. /* 行为相关颜色 */
  15. /* 文字基本颜色 */
  16. /* 背景颜色 */
  17. /* 边框颜色 */
  18. /* 尺寸变量 */
  19. /* 文字尺寸 */
  20. /* 图片尺寸 */
  21. /* Border Radius */
  22. /* 水平间距 */
  23. /* 垂直间距 */
  24. /* 透明度 */
  25. /* 文章场景相关 */
  26. body {
  27. display: flex;
  28. flex-direction: column;
  29. height: 100%;
  30. overflow: hidden;
  31. background-color: #f4f4f4;
  32. }
  33. .symbol::before {
  34. content: "¥";
  35. font-size: 80%;
  36. margin-right: 0.15625rem;
  37. }
  38. .shipment {
  39. margin: 0.625rem;
  40. padding: 0.9375rem 0.9375rem 0.9375rem 2.625rem;
  41. font-size: 0.8125rem;
  42. border-radius: 0.3125rem;
  43. background: url(https://pcapi-xiaotuxian-front-devtest.itheima.net/miniapp/images/locate.png) 0.625rem center/1.5625rem no-repeat #fff;
  44. position: relative;
  45. }
  46. .shipment .icon {
  47. font-size: 1.125rem;
  48. color: #333;
  49. transform: translateY(-50%);
  50. position: absolute;
  51. top: 50%;
  52. right: 0.625rem;
  53. }
  54. .shipment .user {
  55. color: #333;
  56. margin-bottom: 0.15625rem;
  57. }
  58. .shipment .address {
  59. color: #666;
  60. }
  61. .goods {
  62. margin: 0.625rem;
  63. padding: 0 0.625rem;
  64. border-radius: 0.3125rem;
  65. background-color: #fff;
  66. }
  67. .goods .item {
  68. display: flex;
  69. padding: 0.9375rem 0;
  70. border-top: 0.03125rem solid #eee;
  71. }
  72. .goods .item:first-child {
  73. border-top: none;
  74. }
  75. .goods .item .picture {
  76. width: 5.3125rem;
  77. height: 5.3125rem;
  78. border-radius: 0.3125rem;
  79. margin-right: 0.625rem;
  80. }
  81. .goods .item .meta {
  82. flex: 1;
  83. display: flex;
  84. flex-direction: column;
  85. justify-content: center;
  86. position: relative;
  87. }
  88. .goods .item .name {
  89. height: 2.5rem;
  90. font-size: 0.8125rem;
  91. color: #444;
  92. }
  93. .goods .item .attrs {
  94. line-height: 1.8;
  95. padding: 0 0.46875rem;
  96. margin-top: 0.1875rem;
  97. font-size: 0.75rem;
  98. align-self: flex-start;
  99. border-radius: 0.125rem;
  100. color: #888;
  101. background-color: #f7f7f8;
  102. }
  103. .goods .item .prices {
  104. display: flex;
  105. align-items: baseline;
  106. margin-top: 0.1875rem;
  107. font-size: 0.875rem;
  108. }
  109. .goods .item .prices .pay-price {
  110. margin-right: 0.3125rem;
  111. color: #cf4444;
  112. }
  113. .goods .item .prices .price {
  114. font-size: 0.75rem;
  115. color: #999;
  116. text-decoration: line-through;
  117. }
  118. .goods .item .count {
  119. position: absolute;
  120. bottom: 0;
  121. right: 0;
  122. font-size: 0.8125rem;
  123. color: #444;
  124. }
  125. .related {
  126. margin: 0.625rem;
  127. padding: 0 0.625rem;
  128. border-radius: 0.3125rem;
  129. background-color: #fff;
  130. }
  131. .related .item {
  132. display: flex;
  133. justify-content: space-between;
  134. align-items: center;
  135. min-height: 2.5rem;
  136. font-size: 0.8125rem;
  137. color: #333;
  138. }
  139. .related .input {
  140. flex: 1;
  141. text-align: right;
  142. margin: 0.625rem 0;
  143. padding-right: 0.625rem;
  144. font-size: 0.8125rem;
  145. color: #999;
  146. }
  147. .related .item .text {
  148. width: 3.90625rem;
  149. }
  150. .related .picker {
  151. color: #666;
  152. }
  153. .related .picker::after {
  154. content: "\e6c2";
  155. }
  156. /* 结算清单 */
  157. .settlement {
  158. margin: 0.625rem;
  159. padding: 0 0.625rem;
  160. border-radius: 0.3125rem;
  161. background-color: #fff;
  162. }
  163. .settlement .item {
  164. display: flex;
  165. align-items: center;
  166. justify-content: space-between;
  167. height: 2.5rem;
  168. font-size: 0.8125rem;
  169. color: #333;
  170. }
  171. .settlement .danger {
  172. color: #cf4444;
  173. }
  174. /* 吸底工具栏 */
  175. .toolbar {
  176. position: fixed;
  177. left: 0;
  178. right: 0;
  179. bottom: calc(var(--window-bottom));
  180. z-index: 1;
  181. background-color: #fff;
  182. height: 3.125rem;
  183. padding: 0 0.625rem;
  184. border-top: 0.03125rem solid #eaeaea;
  185. display: flex;
  186. justify-content: space-between;
  187. align-items: center;
  188. box-sizing: content-box;
  189. }
  190. .toolbar .total-pay {
  191. font-size: 1.25rem;
  192. color: #cf4444;
  193. }
  194. .toolbar .total-pay .decimal {
  195. font-size: 75%;
  196. }
  197. .toolbar .button {
  198. width: 6.875rem;
  199. text-align: center;
  200. line-height: 2.25rem;
  201. font-size: 0.8125rem;
  202. color: #fff;
  203. border-radius: 2.25rem;
  204. background-color: #27ba9b;
  205. }
  206. .toolbar .disabled {
  207. opacity: 0.6;
  208. }