index.wxss 4.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215
  1. .wux-calendar {
  2. position: relative;
  3. background: #fff;
  4. height: 600rpx;
  5. width: 100%;
  6. overflow: hidden
  7. }
  8. .wux-calendar__content {
  9. position: relative;
  10. width: 100%;
  11. height: 100%;
  12. transition: transform .3s
  13. }
  14. .wux-calendar__bd {
  15. height: 100%;
  16. position: relative;
  17. overflow: hidden
  18. }
  19. .wux-calendar__hd {
  20. position: relative;
  21. width: 100%
  22. }
  23. .wux-calendar__hd::before {
  24. content: " ";
  25. position: absolute;
  26. left: 0;
  27. top: 0;
  28. right: 0;
  29. height: 1PX;
  30. border-top: 1PX solid #d9d9d9;
  31. color: #d9d9d9;
  32. transform-origin: 0 0;
  33. transform: scaleY(.5)
  34. }
  35. .wux-calendar__hd + .wux-calendar__bd {
  36. height: calc(97.8%)
  37. }
  38. .wux-calendar__toolbar {
  39. height: 2.2rem;
  40. display: -ms-flexbox;
  41. display: flex;
  42. text-align: center
  43. }
  44. .wux-calendar__picker {
  45. display: -ms-flexbox;
  46. display: flex;
  47. -ms-flex-align: center;
  48. align-items: center;
  49. -ms-flex-pack: justify;
  50. justify-content: space-between;
  51. width: 50%;
  52. max-width: 400rpx;
  53. -ms-flex-negative: 10;
  54. flex-shrink: 10;
  55. display: block;
  56. line-height: 2.2rem
  57. }
  58. .wux-calendar__link {
  59. float: left;
  60. width: 25%;
  61. height: 2.2rem;
  62. line-height: 2rem;
  63. min-width: 72rpx
  64. }
  65. .wux-calendar__icon {
  66. display: inline-block;
  67. vertical-align: middle;
  68. background-size: 100% auto;
  69. background-position: center
  70. }
  71. .wux-calendar__icon--next,
  72. .wux-calendar__icon--prev {
  73. width: .75rem;
  74. height: .75rem
  75. }
  76. .wux-calendar__icon--next {
  77. background-image: url("data:image/svg+xml;charset=utf-8,%3Csvg%20xmlns%3D'http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg'%20viewBox%3D'0%200%2015%2015'%3E%3Cg%3E%3Cpath%20fill%3D'%23007aff'%20d%3D'M1%2C1.6l11.8%2C5.8L1%2C13.4V1.6%20M0%2C0v15l15-7.6L0%2C0L0%2C0z'%2F%3E%3C%2Fg%3E%3C%2Fsvg%3E")
  78. }
  79. .wux-calendar__icon--prev {
  80. background-image: url("data:image/svg+xml;charset=utf-8,%3Csvg%20xmlns%3D'http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg'%20viewBox%3D'0%200%2015%2015'%3E%3Cg%3E%3Cpath%20fill%3D'%23007aff'%20d%3D'M14%2C1.6v11.8L2.2%2C7.6L14%2C1.6%20M15%2C0L0%2C7.6L15%2C15V0L15%2C0z'%2F%3E%3C%2Fg%3E%3C%2Fsvg%3E")
  81. }
  82. .wux-calendar__value {
  83. -ms-flex-negative: 1;
  84. flex-shrink: 1;
  85. position: relative;
  86. overflow: hidden;
  87. text-overflow: ellipsis;
  88. float: left;
  89. width: 50%;
  90. height: 2.2rem
  91. }
  92. .wux-calendar__weekdays {
  93. height: 36rpx;
  94. background: #f7f7f8;
  95. display: -ms-flexbox;
  96. display: flex;
  97. font-size: 22rpx;
  98. box-sizing: border-box;
  99. position: relative
  100. }
  101. .wux-calendar__weekdays::after {
  102. content: " ";
  103. position: absolute;
  104. left: 0;
  105. bottom: 0;
  106. right: 0;
  107. height: 1PX;
  108. border-bottom: 1PX solid #d9d9d9;
  109. color: #d9d9d9;
  110. transform-origin: 0 100%;
  111. transform: scaleY(.5)
  112. }
  113. .wux-calendar__weekdays + .wux-calendar__months {
  114. height: calc(82%)
  115. }
  116. .wux-calendar__weekday {
  117. -ms-flex-negative: 1;
  118. flex-shrink: 1;
  119. width: 14.28571429%;
  120. width: calc(14.28571429%);
  121. line-height: 34rpx;
  122. text-align: center
  123. }
  124. .wux-calendar__months {
  125. width: 100%;
  126. height: 100%;
  127. overflow: hidden;
  128. position: relative
  129. }
  130. .wux-calendar__months-content {
  131. width: 100%;
  132. height: 100%;
  133. display: -ms-flexbox;
  134. display: flex;
  135. position: relative;
  136. -webkit-backface-visibility: hidden;
  137. transform: translate3d(0,0,0)
  138. }
  139. .wux-calendar__month {
  140. display: -ms-flexbox;
  141. display: flex;
  142. -ms-flex-direction: column;
  143. flex-direction: column;
  144. width: 100%;
  145. height: 100%;
  146. position: absolute;
  147. left: 0;
  148. top: 0
  149. }
  150. .wux-calendar__days {
  151. height: 16.66666667%;
  152. height: calc(16.66666667%);
  153. display: -ms-flexbox;
  154. display: flex;
  155. -ms-flex-negative: 1;
  156. flex-shrink: 1;
  157. width: 100%;
  158. position: relative
  159. }
  160. .wux-calendar__days::after {
  161. content: " ";
  162. position: absolute;
  163. left: 0;
  164. bottom: 0;
  165. right: 0;
  166. height: 1PX;
  167. border-bottom: 1PX solid #d9d9d9;
  168. color: #d9d9d9;
  169. transform-origin: 0 100%;
  170. transform: scaleY(.5)
  171. }
  172. .wux-calendar__days:last-child::after {
  173. display: none
  174. }
  175. .wux-calendar__day {
  176. -ms-flex-negative: 1;
  177. flex-shrink: 1;
  178. display: -ms-flexbox;
  179. display: flex;
  180. -ms-flex-pack: center;
  181. justify-content: center;
  182. -ms-flex-align: center;
  183. align-items: center;
  184. box-sizing: border-box;
  185. width: 14.28571429%;
  186. width: calc(14.28571429%);
  187. text-align: center;
  188. color: #3d4145;
  189. font-size: 30rpx;
  190. cursor: pointer
  191. }
  192. .wux-calendar__day--prev {
  193. color: #ccc
  194. }
  195. .wux-calendar__day--next {
  196. color: #ccc
  197. }
  198. .wux-calendar__day--disabled {
  199. color: #d4d4d4;
  200. cursor: auto
  201. }
  202. .wux-calendar__day--today .wux-calendar__text {
  203. background: #e3e3e3
  204. }
  205. .wux-calendar__day--selected .wux-calendar__text {
  206. background: #0894ec;
  207. color: #fff
  208. }
  209. .wux-calendar__text {
  210. display: inline-block;
  211. border-radius: 100%;
  212. width: 60rpx;
  213. height: 60rpx;
  214. line-height: 60rpx
  215. }