@10yun/cv-mobile-ui 0.5.29 → 0.5.30

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (260) hide show
  1. package/package.json +1 -1
  2. package/plugins/luch-request/adapters/index.js +131 -0
  3. package/plugins/luch-request/core/InterceptorManager.js +50 -0
  4. package/plugins/luch-request/core/Request.js +199 -0
  5. package/plugins/luch-request/core/buildFullPath.js +20 -0
  6. package/plugins/luch-request/core/defaults.js +32 -0
  7. package/plugins/luch-request/core/dispatchRequest.js +5 -0
  8. package/plugins/luch-request/core/mergeConfig.js +125 -0
  9. package/plugins/luch-request/core/settle.js +16 -0
  10. package/plugins/luch-request/helpers/buildURL.js +71 -0
  11. package/plugins/luch-request/helpers/combineURLs.js +12 -0
  12. package/plugins/luch-request/helpers/isAbsoluteURL.js +14 -0
  13. package/plugins/luch-request/index.d.ts +197 -0
  14. package/plugins/luch-request/index.js +2 -0
  15. package/plugins/luch-request/readme.md +3 -0
  16. package/plugins/luch-request/utils/clone.js +264 -0
  17. package/plugins/luch-request/utils.js +131 -0
  18. package/plugins/request.js +2 -2
  19. package/ui-cv/components/cv-form-item/cv-form-item.vue +1 -1
  20. package/ui-fireui/fui-actionsheet/fui-actionsheet.vue +202 -0
  21. package/ui-fireui/fui-alert/fui-alert.vue +141 -0
  22. package/ui-fireui/fui-badge/fui-badge.vue +158 -0
  23. package/ui-fireui/fui-bottom-navigation/fui-bottom-navigation.vue +390 -0
  24. package/ui-fireui/fui-bottom-popup/fui-bottom-popup.vue +100 -0
  25. package/ui-fireui/fui-bubble-popup/fui-bubble-popup.vue +236 -0
  26. package/ui-fireui/fui-button/fui-button.vue +424 -0
  27. package/ui-fireui/fui-calendar/fui-calendar.js +915 -0
  28. package/ui-fireui/fui-calendar/fui-calendar.vue +868 -0
  29. package/ui-fireui/fui-card/fui-card.vue +231 -0
  30. package/ui-fireui/fui-cascade-selection/fui-cascade-selection.vue +538 -0
  31. package/ui-fireui/fui-circular-progress/fui-circular-progress.vue +261 -0
  32. package/ui-fireui/fui-collapse/fui-collapse.vue +179 -0
  33. package/ui-fireui/fui-countdown/fui-countdown.vue +301 -0
  34. package/ui-fireui/fui-datetime/fui-datetime.vue +570 -0
  35. package/ui-fireui/fui-divider/fui-divider.vue +118 -0
  36. package/ui-fireui/fui-drawer/fui-drawer.vue +103 -0
  37. package/ui-fireui/fui-dropdown-list/fui-dropdown-list.vue +70 -0
  38. package/ui-fireui/fui-fab/fui-fab.vue +284 -0
  39. package/ui-fireui/fui-footer/fui-footer.vue +131 -0
  40. package/ui-fireui/fui-grid/fui-grid.vue +42 -0
  41. package/ui-fireui/fui-grid-item/fui-grid-item.vue +142 -0
  42. package/ui-fireui/fui-icon/fui-icon.vue +820 -0
  43. package/ui-fireui/fui-image-cropper/fui-image-cropper.vue +1058 -0
  44. package/ui-fireui/fui-image-group/fui-image-group.vue +149 -0
  45. package/ui-fireui/fui-keyboard/fui-keyboard.vue +254 -0
  46. package/ui-fireui/fui-keyboard-input/fui-keyboard-input.vue +78 -0
  47. package/ui-fireui/fui-list-cell/fui-list-cell.vue +178 -0
  48. package/ui-fireui/fui-list-view/fui-list-view.vue +87 -0
  49. package/ui-fireui/fui-loading/fui-loading.vue +78 -0
  50. package/ui-fireui/fui-loadmore/fui-loadmore.vue +163 -0
  51. package/ui-fireui/fui-modal/fui-modal.vue +392 -0
  52. package/ui-fireui/fui-navigation-bar/fui-navigation-bar.vue +180 -0
  53. package/ui-fireui/fui-no-data/fui-no-data.vue +116 -0
  54. package/ui-fireui/fui-nomore/fui-nomore.vue +116 -0
  55. package/ui-fireui/fui-numberbox/fui-numberbox.vue +234 -0
  56. package/ui-fireui/fui-numberbox-border/fui-numberbox-border.vue +232 -0
  57. package/ui-fireui/fui-picture-cropper/fui-picture-cropper.vue +682 -0
  58. package/ui-fireui/fui-picture-cropper/fui-picture-cropper.wxs +560 -0
  59. package/ui-fireui/fui-rate/fui-rate.vue +167 -0
  60. package/ui-fireui/fui-round-progress/fui-round-progress.vue +306 -0
  61. package/ui-fireui/fui-scroll-top/fui-scroll-top.vue +189 -0
  62. package/ui-fireui/fui-sharemodel/fui-sharemodel.vue +181 -0
  63. package/ui-fireui/fui-skeleton/fui-skeleton.vue +248 -0
  64. package/ui-fireui/fui-steps/fui-steps.vue +214 -0
  65. package/ui-fireui/fui-sticky/fui-sticky.vue +155 -0
  66. package/ui-fireui/fui-sticky-wxs/fui-sticky-wxs.vue +133 -0
  67. package/ui-fireui/fui-sticky-wxs/fui-sticky.wxs +44 -0
  68. package/ui-fireui/fui-swipe-action/fui-swipe-action.vue +301 -0
  69. package/ui-fireui/fui-tabbar/fui-tabbar.vue +283 -0
  70. package/ui-fireui/fui-tabs/fui-tabs.vue +284 -0
  71. package/ui-fireui/fui-tabs2/fui-tabs2.vue +284 -0
  72. package/ui-fireui/fui-tag/fui-tag.vue +374 -0
  73. package/ui-fireui/fui-time-axis/fui-time-axis.vue +36 -0
  74. package/ui-fireui/fui-timeaxis-item/fui-timeaxis-item.vue +48 -0
  75. package/ui-fireui/fui-tips/fui-tips.vue +161 -0
  76. package/ui-fireui/fui-toast/fui-toast.vue +117 -0
  77. package/ui-fireui/fui-top-dropdown/fui-top-dropdown.vue +129 -0
  78. package/ui-fireui/fui-upload/fui-upload.vue +446 -0
  79. package/ui-fireui/fui-uploadsamll/fui-uploadsamll.vue +472 -0
  80. package/uview-plus/README.md +1 -1
  81. package/uview-plus/changelog-wu-tool.md +21 -0
  82. package/uview-plus/changelog-wu.md +91 -0
  83. package/uview-plus/components/u-action-sheet/_doc/changelog.md +12 -0
  84. package/uview-plus/components/u-action-sheet/_doc/package.json +92 -0
  85. package/uview-plus/components/u-action-sheet/_doc/readme.md +16 -0
  86. package/uview-plus/components/u-app-update/_doc/changelog.md +26 -0
  87. package/uview-plus/components/u-app-update/_doc/package.json +89 -0
  88. package/uview-plus/components/u-app-update/_doc/readme.md +16 -0
  89. package/uview-plus/components/u-app-update/config.js +120 -0
  90. package/uview-plus/components/u-app-update/img/act.png +0 -0
  91. package/uview-plus/components/u-app-update/img/appUploadAlertBoxBg.png +0 -0
  92. package/uview-plus/components/u-app-update/img/close.png +0 -0
  93. package/uview-plus/components/u-app-update/js-sdk/checkVersion.js +81 -0
  94. package/uview-plus/components/u-app-update/js-sdk/silentlyAppUpdate.js +41 -0
  95. package/uview-plus/components/u-app-update/pages/index.vue +8 -0
  96. package/uview-plus/components/u-app-update/u-app-update.vue +583 -0
  97. package/uview-plus/components/u-button-wu/_doc/changelog.md +6 -0
  98. package/uview-plus/components/u-button-wu/_doc/package.json +89 -0
  99. package/uview-plus/components/u-button-wu/_doc/readme.md +16 -0
  100. package/uview-plus/components/u-button-wu/u-button-wu.vue +522 -0
  101. package/uview-plus/components/u-button-wu/vue.scss +81 -0
  102. package/uview-plus/components/u-calendar-wu/_doc/changelog.md +145 -0
  103. package/uview-plus/components/u-calendar-wu/_doc/package.json +90 -0
  104. package/uview-plus/components/u-calendar-wu/_doc/readme.md +16 -0
  105. package/uview-plus/components/u-calendar-wu/calendar.js +664 -0
  106. package/uview-plus/components/u-calendar-wu/i18n/en.json +14 -0
  107. package/uview-plus/components/u-calendar-wu/i18n/index.js +8 -0
  108. package/uview-plus/components/u-calendar-wu/i18n/zh-Hans.json +14 -0
  109. package/uview-plus/components/u-calendar-wu/i18n/zh-Hant.json +14 -0
  110. package/uview-plus/components/u-calendar-wu/props.js +166 -0
  111. package/uview-plus/components/u-calendar-wu/style.css +196 -0
  112. package/uview-plus/components/u-calendar-wu/u-calendar-wu.vue +921 -0
  113. package/uview-plus/components/u-calendar-wu/util.js +552 -0
  114. package/uview-plus/components/u-calendar-wu/wu-calendar-block/props.js +73 -0
  115. package/uview-plus/components/u-calendar-wu/wu-calendar-block/wu-calendar-block.vue +122 -0
  116. package/uview-plus/components/u-calendar-wu/wu-calendar-item/props.js +55 -0
  117. package/uview-plus/components/u-calendar-wu/wu-calendar-item/wu-calendar-item.vue +293 -0
  118. package/uview-plus/components/u-cell/_doc/changelog.md +6 -0
  119. package/uview-plus/components/u-cell/_doc/package.json +89 -0
  120. package/uview-plus/components/u-cell/_doc/readme.md +25 -0
  121. package/uview-plus/components/u-checkbox/_doc/changelog.md +8 -0
  122. package/uview-plus/components/u-checkbox/_doc/package.json +88 -0
  123. package/uview-plus/components/u-checkbox/_doc/readme.md +25 -0
  124. package/uview-plus/components/u-code/_doc/changelog.md +6 -0
  125. package/uview-plus/components/u-code/_doc/package.json +86 -0
  126. package/uview-plus/components/u-code/_doc/readme.md +16 -0
  127. package/uview-plus/components/u-drag-sort/_doc/changelog.md +0 -0
  128. package/uview-plus/components/u-drag-sort/_doc/package.json +85 -0
  129. package/uview-plus/components/u-drag-sort/_doc/readme.md +16 -0
  130. package/uview-plus/components/u-drag-sort/u-drag-sort.vue +3 -0
  131. package/uview-plus/components/u-empty/u-empty.vue +27 -1
  132. package/uview-plus/components/u-gap/_doc/changelog.md +4 -0
  133. package/uview-plus/components/u-gap/_doc/package.json +86 -0
  134. package/uview-plus/components/u-gap/_doc/readme.md +22 -0
  135. package/uview-plus/components/u-icon/_doc/changelog.md +10 -0
  136. package/uview-plus/components/u-icon/_doc/package.json +85 -0
  137. package/uview-plus/components/u-icon/_doc/readme.md +10 -0
  138. package/uview-plus/components/u-icon/icon.js +23 -25
  139. package/uview-plus/components/u-icon/icons.js +213 -213
  140. package/uview-plus/components/u-icon/style.css +3 -3
  141. package/uview-plus/components/u-icon/u-icon2.vue +149 -0
  142. package/uview-plus/components/u-image-wu/_doc/changelog.md +21 -0
  143. package/uview-plus/components/u-image-wu/_doc/package.json +88 -0
  144. package/uview-plus/components/u-image-wu/_doc/readme.md +11 -0
  145. package/uview-plus/components/u-image-wu/props.js +94 -0
  146. package/uview-plus/components/u-image-wu/u-image-wu.vue +243 -0
  147. package/uview-plus/components/u-input/_doc/changelog.md +6 -0
  148. package/uview-plus/components/u-input/_doc/package.json +88 -0
  149. package/uview-plus/components/u-input/_doc/readme.md +16 -0
  150. package/uview-plus/components/u-line/_doc/changelog.md +8 -0
  151. package/uview-plus/components/u-line/_doc/package.json +86 -0
  152. package/uview-plus/components/u-line/_doc/readme.md +16 -0
  153. package/uview-plus/components/u-link/_doc/changelog.md +8 -0
  154. package/uview-plus/components/u-link/_doc/package.json +86 -0
  155. package/uview-plus/components/u-link/_doc/readme.md +20 -0
  156. package/uview-plus/components/u-loading-icon/_doc/changelog.md +12 -0
  157. package/uview-plus/components/u-loading-icon/_doc/package.json +86 -0
  158. package/uview-plus/components/u-loading-icon/_doc/readme.md +16 -0
  159. package/uview-plus/components/u-loading-icon/props.js +1 -1
  160. package/uview-plus/components/u-navbar/_doc/changelog.md +6 -0
  161. package/uview-plus/components/u-navbar/_doc/package.json +89 -0
  162. package/uview-plus/components/u-navbar/_doc/readme.md +16 -0
  163. package/uview-plus/components/u-navbar-wu/props.js +102 -0
  164. package/uview-plus/components/u-navbar-wu/u-navbar-wu.vue +196 -0
  165. package/uview-plus/components/u-number-box/_doc/changelog.md +19 -0
  166. package/uview-plus/components/u-number-box/_doc/package.json +88 -0
  167. package/uview-plus/components/u-number-box/_doc/readme.md +16 -0
  168. package/uview-plus/components/u-overlay/_doc/changelog.md +4 -0
  169. package/uview-plus/components/u-overlay/_doc/package.json +88 -0
  170. package/uview-plus/components/u-overlay/_doc/readme.md +16 -0
  171. package/uview-plus/components/u-popup/_doc/changelog.md +4 -0
  172. package/uview-plus/components/u-popup/_doc/package.json +92 -0
  173. package/uview-plus/components/u-popup/_doc/readme.md +16 -0
  174. package/uview-plus/components/u-popup-wu/keypress.js +45 -0
  175. package/uview-plus/components/u-popup-wu/u-popup-wu.vue +519 -0
  176. package/uview-plus/components/u-radio/_doc/changelog.md +6 -0
  177. package/uview-plus/components/u-radio/_doc/package.json +88 -0
  178. package/uview-plus/components/u-radio/_doc/readme.md +25 -0
  179. package/uview-plus/components/u-row/_doc/changelog.md +8 -0
  180. package/uview-plus/components/u-row/_doc/package.json +86 -0
  181. package/uview-plus/components/u-row/_doc/readme.md +16 -0
  182. package/uview-plus/components/u-safe-bottom/_doc/changelog.md +6 -0
  183. package/uview-plus/components/u-safe-bottom/_doc/package.json +86 -0
  184. package/uview-plus/components/u-safe-bottom/_doc/readme.md +16 -0
  185. package/uview-plus/components/u-sku-wu/_doc/changelog.md +27 -0
  186. package/uview-plus/components/u-sku-wu/_doc/package.json +93 -0
  187. package/uview-plus/components/u-sku-wu/_doc/readme.md +16 -0
  188. package/uview-plus/components/u-sku-wu/props.js +86 -0
  189. package/uview-plus/components/u-sku-wu/style.css +271 -0
  190. package/uview-plus/components/u-sku-wu/u-sku-wu.vue +864 -0
  191. package/uview-plus/components/u-status-bar/_doc/changelog.md +4 -0
  192. package/uview-plus/components/u-status-bar/_doc/package.json +86 -0
  193. package/uview-plus/components/u-status-bar/_doc/readme.md +16 -0
  194. package/uview-plus/components/u-text/_doc/changelog.md +10 -0
  195. package/uview-plus/components/u-text/_doc/package.json +89 -0
  196. package/uview-plus/components/u-text/_doc/readme.md +20 -0
  197. package/uview-plus/components/u-textarea/_doc/changelog.md +6 -0
  198. package/uview-plus/components/u-textarea/_doc/package.json +86 -0
  199. package/uview-plus/components/u-textarea/_doc/readme.md +25 -0
  200. package/uview-plus/components/u-transition/_doc/changelog.md +14 -0
  201. package/uview-plus/components/u-transition/_doc/package.json +86 -0
  202. package/uview-plus/components/u-transition/_doc/readme.md +16 -0
  203. package/uview-plus/components/u-transition-wu/createAnimation.js +148 -0
  204. package/uview-plus/components/u-transition-wu/props.js +32 -0
  205. package/uview-plus/components/u-transition-wu/u-transition.vue +300 -0
  206. package/uview-plus/components/u-verification-code/u-verification-code.vue +161 -0
  207. package/uview-plus/index.js +107 -94
  208. package/uview-plus/libs/config/config.js +46 -48
  209. package/uview-plus/libs/css/color.scss +32 -311
  210. package/uview-plus/libs/css/components-wu.scss +30 -0
  211. package/uview-plus/libs/css/vue.scss +10 -10
  212. package/uview-plus/libs/function/calc.js +61 -55
  213. package/uview-plus/libs/function/cc.js +66 -0
  214. package/uview-plus/libs/function/color/color-convert/CHANGELOG.md +54 -0
  215. package/uview-plus/libs/function/color/color-convert/LICENSE +21 -0
  216. package/uview-plus/libs/function/color/color-convert/README.md +68 -0
  217. package/uview-plus/libs/function/color/color-convert/conversions.js +839 -0
  218. package/uview-plus/libs/function/color/color-convert/index.js +81 -0
  219. package/uview-plus/libs/function/color/color-convert/package.json +48 -0
  220. package/uview-plus/libs/function/color/color-convert/route.js +97 -0
  221. package/uview-plus/libs/function/color/color-name/LICENSE +8 -0
  222. package/uview-plus/libs/function/color/color-name/README.md +11 -0
  223. package/uview-plus/libs/function/color/color-name/index.js +152 -0
  224. package/uview-plus/libs/function/color/color-name/package.json +28 -0
  225. package/uview-plus/libs/function/color/color-string/LICENSE +21 -0
  226. package/uview-plus/libs/function/color/color-string/README.md +62 -0
  227. package/uview-plus/libs/function/color/color-string/index.js +244 -0
  228. package/uview-plus/libs/function/color/color-string/package.json +39 -0
  229. package/uview-plus/libs/function/color/color.js +496 -0
  230. package/uview-plus/libs/function/color/index.js +158 -0
  231. package/uview-plus/libs/function/color/is-arrayish/LICENSE +21 -0
  232. package/uview-plus/libs/function/color/is-arrayish/README.md +16 -0
  233. package/uview-plus/libs/function/color/is-arrayish/index.js +9 -0
  234. package/uview-plus/libs/function/color/is-arrayish/package.json +45 -0
  235. package/uview-plus/libs/function/color/is-arrayish/yarn-error.log +1443 -0
  236. package/uview-plus/libs/function/color/simple-swizzle/LICENSE +21 -0
  237. package/uview-plus/libs/function/color/simple-swizzle/README.md +39 -0
  238. package/uview-plus/libs/function/color/simple-swizzle/index.js +29 -0
  239. package/uview-plus/libs/function/color/simple-swizzle/package.json +36 -0
  240. package/uview-plus/libs/function/colorGradient.js +108 -106
  241. package/uview-plus/libs/function/debounce.js +17 -17
  242. package/uview-plus/libs/function/digit.js +1 -3
  243. package/uview-plus/libs/function/http.js +3 -3
  244. package/uview-plus/libs/function/index-wu.js +231 -0
  245. package/uview-plus/libs/function/index.js +579 -566
  246. package/uview-plus/libs/function/platform.js +18 -18
  247. package/uview-plus/libs/function/test.js +135 -137
  248. package/uview-plus/libs/function/throttle.js +17 -17
  249. package/uview-plus/libs/luch-request/core/Request.js +199 -199
  250. package/uview-plus/libs/mixin/mpMixin.js +1 -0
  251. package/uview-plus/libs/mixin/openType.js +33 -0
  252. package/uview-plus/libs/util/async-validator.js +1343 -1343
  253. package/uview-plus/libs/util/dayjs.js +404 -0
  254. package/uview-plus/libs/util/route.js +101 -105
  255. package/uview-plus/package-wu-tool.json +84 -0
  256. package/uview-plus/package-wu.json +112 -0
  257. package/uview-plus/package.json +106 -95
  258. package/uview-plus/readme-wu.md +148 -0
  259. package/uview-ui/index.js +51 -52
  260. package/plugins/uni-upgrade.js +0 -294
@@ -0,0 +1,404 @@
1
+ var __getOwnPropNames = Object.getOwnPropertyNames;
2
+ var __commonJS = (cb, mod) =>
3
+ function __require() {
4
+ return mod || (0, cb[__getOwnPropNames(cb)[0]])((mod = { exports: {} }).exports, mod), mod.exports;
5
+ };
6
+
7
+ // C:/Users/LP/Downloads/wuui-plus_3.1.27_example/node_modules/dayjs/dayjs.min.js
8
+ var require_dayjs_min = __commonJS({
9
+ 'C:/Users/LP/Downloads/wuui-plus_3.1.27_example/node_modules/dayjs/dayjs.min.js'(exports, module) {
10
+ !(function (t, e) {
11
+ 'object' == typeof exports && 'undefined' != typeof module
12
+ ? (module.exports = e())
13
+ : 'function' == typeof define && define.amd
14
+ ? define(e)
15
+ : ((t = 'undefined' != typeof globalThis ? globalThis : t || self).dayjs = e());
16
+ })(exports, function () {
17
+ 'use strict';
18
+ var t = 1e3,
19
+ e = 6e4,
20
+ n = 36e5,
21
+ r = 'millisecond',
22
+ i = 'second',
23
+ s = 'minute',
24
+ u = 'hour',
25
+ a = 'day',
26
+ o = 'week',
27
+ f = 'month',
28
+ h = 'quarter',
29
+ c = 'year',
30
+ d = 'date',
31
+ l = 'Invalid Date',
32
+ $ = /^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/,
33
+ y = /\[([^\]]+)]|Y{1,4}|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g,
34
+ M = {
35
+ name: 'en',
36
+ weekdays: 'Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday'.split('_'),
37
+ months: 'January_February_March_April_May_June_July_August_September_October_November_December'.split('_'),
38
+ ordinal: function (t2) {
39
+ var e2 = ['th', 'st', 'nd', 'rd'],
40
+ n2 = t2 % 100;
41
+ return '[' + t2 + (e2[(n2 - 20) % 10] || e2[n2] || e2[0]) + ']';
42
+ }
43
+ },
44
+ m = function (t2, e2, n2) {
45
+ var r2 = String(t2);
46
+ return !r2 || r2.length >= e2 ? t2 : '' + Array(e2 + 1 - r2.length).join(n2) + t2;
47
+ },
48
+ v = {
49
+ s: m,
50
+ z: function (t2) {
51
+ var e2 = -t2.utcOffset(),
52
+ n2 = Math.abs(e2),
53
+ r2 = Math.floor(n2 / 60),
54
+ i2 = n2 % 60;
55
+ return (e2 <= 0 ? '+' : '-') + m(r2, 2, '0') + ':' + m(i2, 2, '0');
56
+ },
57
+ m: function t2(e2, n2) {
58
+ if (e2.date() < n2.date()) return -t2(n2, e2);
59
+ var r2 = 12 * (n2.year() - e2.year()) + (n2.month() - e2.month()),
60
+ i2 = e2.clone().add(r2, f),
61
+ s2 = n2 - i2 < 0,
62
+ u2 = e2.clone().add(r2 + (s2 ? -1 : 1), f);
63
+ return +(-(r2 + (n2 - i2) / (s2 ? i2 - u2 : u2 - i2)) || 0);
64
+ },
65
+ a: function (t2) {
66
+ return t2 < 0 ? Math.ceil(t2) || 0 : Math.floor(t2);
67
+ },
68
+ p: function (t2) {
69
+ return (
70
+ { M: f, y: c, w: o, d: a, D: d, h: u, m: s, s: i, ms: r, Q: h }[t2] ||
71
+ String(t2 || '')
72
+ .toLowerCase()
73
+ .replace(/s$/, '')
74
+ );
75
+ },
76
+ u: function (t2) {
77
+ return void 0 === t2;
78
+ }
79
+ },
80
+ g = 'en',
81
+ D = {};
82
+ D[g] = M;
83
+ var p = function (t2) {
84
+ return t2 instanceof _;
85
+ },
86
+ S = function t2(e2, n2, r2) {
87
+ var i2;
88
+ if (!e2) return g;
89
+ if ('string' == typeof e2) {
90
+ var s2 = e2.toLowerCase();
91
+ D[s2] && (i2 = s2), n2 && ((D[s2] = n2), (i2 = s2));
92
+ var u2 = e2.split('-');
93
+ if (!i2 && u2.length > 1) return t2(u2[0]);
94
+ } else {
95
+ var a2 = e2.name;
96
+ (D[a2] = e2), (i2 = a2);
97
+ }
98
+ return !r2 && i2 && (g = i2), i2 || (!r2 && g);
99
+ },
100
+ w = function (t2, e2) {
101
+ if (p(t2)) return t2.clone();
102
+ var n2 = 'object' == typeof e2 ? e2 : {};
103
+ return (n2.date = t2), (n2.args = arguments), new _(n2);
104
+ },
105
+ O = v;
106
+ (O.l = S),
107
+ (O.i = p),
108
+ (O.w = function (t2, e2) {
109
+ return w(t2, { locale: e2.$L, utc: e2.$u, x: e2.$x, $offset: e2.$offset });
110
+ });
111
+ var _ = (function () {
112
+ function M2(t2) {
113
+ (this.$L = S(t2.locale, null, true)), this.parse(t2);
114
+ }
115
+ var m2 = M2.prototype;
116
+ return (
117
+ (m2.parse = function (t2) {
118
+ (this.$d = (function (t3) {
119
+ var e2 = t3.date,
120
+ n2 = t3.utc;
121
+ if (null === e2) return new Date(NaN);
122
+ if (O.u(e2)) return new Date();
123
+ if (e2 instanceof Date) return new Date(e2);
124
+ if ('string' == typeof e2 && !/Z$/i.test(e2)) {
125
+ var r2 = e2.match($);
126
+ if (r2) {
127
+ var i2 = r2[2] - 1 || 0,
128
+ s2 = (r2[7] || '0').substring(0, 3);
129
+ return n2
130
+ ? new Date(Date.UTC(r2[1], i2, r2[3] || 1, r2[4] || 0, r2[5] || 0, r2[6] || 0, s2))
131
+ : new Date(r2[1], i2, r2[3] || 1, r2[4] || 0, r2[5] || 0, r2[6] || 0, s2);
132
+ }
133
+ }
134
+ return new Date(e2);
135
+ })(t2)),
136
+ (this.$x = t2.x || {}),
137
+ this.init();
138
+ }),
139
+ (m2.init = function () {
140
+ var t2 = this.$d;
141
+ (this.$y = t2.getFullYear()),
142
+ (this.$M = t2.getMonth()),
143
+ (this.$D = t2.getDate()),
144
+ (this.$W = t2.getDay()),
145
+ (this.$H = t2.getHours()),
146
+ (this.$m = t2.getMinutes()),
147
+ (this.$s = t2.getSeconds()),
148
+ (this.$ms = t2.getMilliseconds());
149
+ }),
150
+ (m2.$utils = function () {
151
+ return O;
152
+ }),
153
+ (m2.isValid = function () {
154
+ return !(this.$d.toString() === l);
155
+ }),
156
+ (m2.isSame = function (t2, e2) {
157
+ var n2 = w(t2);
158
+ return this.startOf(e2) <= n2 && n2 <= this.endOf(e2);
159
+ }),
160
+ (m2.isAfter = function (t2, e2) {
161
+ return w(t2) < this.startOf(e2);
162
+ }),
163
+ (m2.isBefore = function (t2, e2) {
164
+ return this.endOf(e2) < w(t2);
165
+ }),
166
+ (m2.$g = function (t2, e2, n2) {
167
+ return O.u(t2) ? this[e2] : this.set(n2, t2);
168
+ }),
169
+ (m2.unix = function () {
170
+ return Math.floor(this.valueOf() / 1e3);
171
+ }),
172
+ (m2.valueOf = function () {
173
+ return this.$d.getTime();
174
+ }),
175
+ (m2.startOf = function (t2, e2) {
176
+ var n2 = this,
177
+ r2 = !!O.u(e2) || e2,
178
+ h2 = O.p(t2),
179
+ l2 = function (t3, e3) {
180
+ var i2 = O.w(n2.$u ? Date.UTC(n2.$y, e3, t3) : new Date(n2.$y, e3, t3), n2);
181
+ return r2 ? i2 : i2.endOf(a);
182
+ },
183
+ $2 = function (t3, e3) {
184
+ return O.w(n2.toDate()[t3].apply(n2.toDate('s'), (r2 ? [0, 0, 0, 0] : [23, 59, 59, 999]).slice(e3)), n2);
185
+ },
186
+ y2 = this.$W,
187
+ M3 = this.$M,
188
+ m3 = this.$D,
189
+ v2 = 'set' + (this.$u ? 'UTC' : '');
190
+ switch (h2) {
191
+ case c:
192
+ return r2 ? l2(1, 0) : l2(31, 11);
193
+ case f:
194
+ return r2 ? l2(1, M3) : l2(0, M3 + 1);
195
+ case o:
196
+ var g2 = this.$locale().weekStart || 0,
197
+ D2 = (y2 < g2 ? y2 + 7 : y2) - g2;
198
+ return l2(r2 ? m3 - D2 : m3 + (6 - D2), M3);
199
+ case a:
200
+ case d:
201
+ return $2(v2 + 'Hours', 0);
202
+ case u:
203
+ return $2(v2 + 'Minutes', 1);
204
+ case s:
205
+ return $2(v2 + 'Seconds', 2);
206
+ case i:
207
+ return $2(v2 + 'Milliseconds', 3);
208
+ default:
209
+ return this.clone();
210
+ }
211
+ }),
212
+ (m2.endOf = function (t2) {
213
+ return this.startOf(t2, false);
214
+ }),
215
+ (m2.$set = function (t2, e2) {
216
+ var n2,
217
+ o2 = O.p(t2),
218
+ h2 = 'set' + (this.$u ? 'UTC' : ''),
219
+ l2 = ((n2 = {}),
220
+ (n2[a] = h2 + 'Date'),
221
+ (n2[d] = h2 + 'Date'),
222
+ (n2[f] = h2 + 'Month'),
223
+ (n2[c] = h2 + 'FullYear'),
224
+ (n2[u] = h2 + 'Hours'),
225
+ (n2[s] = h2 + 'Minutes'),
226
+ (n2[i] = h2 + 'Seconds'),
227
+ (n2[r] = h2 + 'Milliseconds'),
228
+ n2)[o2],
229
+ $2 = o2 === a ? this.$D + (e2 - this.$W) : e2;
230
+ if (o2 === f || o2 === c) {
231
+ var y2 = this.clone().set(d, 1);
232
+ y2.$d[l2]($2), y2.init(), (this.$d = y2.set(d, Math.min(this.$D, y2.daysInMonth())).$d);
233
+ } else l2 && this.$d[l2]($2);
234
+ return this.init(), this;
235
+ }),
236
+ (m2.set = function (t2, e2) {
237
+ return this.clone().$set(t2, e2);
238
+ }),
239
+ (m2.get = function (t2) {
240
+ return this[O.p(t2)]();
241
+ }),
242
+ (m2.add = function (r2, h2) {
243
+ var d2,
244
+ l2 = this;
245
+ r2 = Number(r2);
246
+ var $2 = O.p(h2),
247
+ y2 = function (t2) {
248
+ var e2 = w(l2);
249
+ return O.w(e2.date(e2.date() + Math.round(t2 * r2)), l2);
250
+ };
251
+ if ($2 === f) return this.set(f, this.$M + r2);
252
+ if ($2 === c) return this.set(c, this.$y + r2);
253
+ if ($2 === a) return y2(1);
254
+ if ($2 === o) return y2(7);
255
+ var M3 = ((d2 = {}), (d2[s] = e), (d2[u] = n), (d2[i] = t), d2)[$2] || 1,
256
+ m3 = this.$d.getTime() + r2 * M3;
257
+ return O.w(m3, this);
258
+ }),
259
+ (m2.subtract = function (t2, e2) {
260
+ return this.add(-1 * t2, e2);
261
+ }),
262
+ (m2.format = function (t2) {
263
+ var e2 = this,
264
+ n2 = this.$locale();
265
+ if (!this.isValid()) return n2.invalidDate || l;
266
+ var r2 = t2 || 'YYYY-MM-DDTHH:mm:ssZ',
267
+ i2 = O.z(this),
268
+ s2 = this.$H,
269
+ u2 = this.$m,
270
+ a2 = this.$M,
271
+ o2 = n2.weekdays,
272
+ f2 = n2.months,
273
+ h2 = function (t3, n3, i3, s3) {
274
+ return (t3 && (t3[n3] || t3(e2, r2))) || i3[n3].slice(0, s3);
275
+ },
276
+ c2 = function (t3) {
277
+ return O.s(s2 % 12 || 12, t3, '0');
278
+ },
279
+ d2 =
280
+ n2.meridiem ||
281
+ function (t3, e3, n3) {
282
+ var r3 = t3 < 12 ? 'AM' : 'PM';
283
+ return n3 ? r3.toLowerCase() : r3;
284
+ },
285
+ $2 = {
286
+ YY: String(this.$y).slice(-2),
287
+ YYYY: this.$y,
288
+ M: a2 + 1,
289
+ MM: O.s(a2 + 1, 2, '0'),
290
+ MMM: h2(n2.monthsShort, a2, f2, 3),
291
+ MMMM: h2(f2, a2),
292
+ D: this.$D,
293
+ DD: O.s(this.$D, 2, '0'),
294
+ d: String(this.$W),
295
+ dd: h2(n2.weekdaysMin, this.$W, o2, 2),
296
+ ddd: h2(n2.weekdaysShort, this.$W, o2, 3),
297
+ dddd: o2[this.$W],
298
+ H: String(s2),
299
+ HH: O.s(s2, 2, '0'),
300
+ h: c2(1),
301
+ hh: c2(2),
302
+ a: d2(s2, u2, true),
303
+ A: d2(s2, u2, false),
304
+ m: String(u2),
305
+ mm: O.s(u2, 2, '0'),
306
+ s: String(this.$s),
307
+ ss: O.s(this.$s, 2, '0'),
308
+ SSS: O.s(this.$ms, 3, '0'),
309
+ Z: i2
310
+ };
311
+ return r2.replace(y, function (t3, e3) {
312
+ return e3 || $2[t3] || i2.replace(':', '');
313
+ });
314
+ }),
315
+ (m2.utcOffset = function () {
316
+ return 15 * -Math.round(this.$d.getTimezoneOffset() / 15);
317
+ }),
318
+ (m2.diff = function (r2, d2, l2) {
319
+ var $2,
320
+ y2 = O.p(d2),
321
+ M3 = w(r2),
322
+ m3 = (M3.utcOffset() - this.utcOffset()) * e,
323
+ v2 = this - M3,
324
+ g2 = O.m(this, M3);
325
+ return (
326
+ (g2 =
327
+ (($2 = {}),
328
+ ($2[c] = g2 / 12),
329
+ ($2[f] = g2),
330
+ ($2[h] = g2 / 3),
331
+ ($2[o] = (v2 - m3) / 6048e5),
332
+ ($2[a] = (v2 - m3) / 864e5),
333
+ ($2[u] = v2 / n),
334
+ ($2[s] = v2 / e),
335
+ ($2[i] = v2 / t),
336
+ $2)[y2] || v2),
337
+ l2 ? g2 : O.a(g2)
338
+ );
339
+ }),
340
+ (m2.daysInMonth = function () {
341
+ return this.endOf(f).$D;
342
+ }),
343
+ (m2.$locale = function () {
344
+ return D[this.$L];
345
+ }),
346
+ (m2.locale = function (t2, e2) {
347
+ if (!t2) return this.$L;
348
+ var n2 = this.clone(),
349
+ r2 = S(t2, e2, true);
350
+ return r2 && (n2.$L = r2), n2;
351
+ }),
352
+ (m2.clone = function () {
353
+ return O.w(this.$d, this);
354
+ }),
355
+ (m2.toDate = function () {
356
+ return new Date(this.valueOf());
357
+ }),
358
+ (m2.toJSON = function () {
359
+ return this.isValid() ? this.toISOString() : null;
360
+ }),
361
+ (m2.toISOString = function () {
362
+ return this.$d.toISOString();
363
+ }),
364
+ (m2.toString = function () {
365
+ return this.$d.toUTCString();
366
+ }),
367
+ M2
368
+ );
369
+ })(),
370
+ T = _.prototype;
371
+ return (
372
+ (w.prototype = T),
373
+ [
374
+ ['$ms', r],
375
+ ['$s', i],
376
+ ['$m', s],
377
+ ['$H', u],
378
+ ['$W', a],
379
+ ['$M', f],
380
+ ['$y', c],
381
+ ['$D', d]
382
+ ].forEach(function (t2) {
383
+ T[t2[1]] = function (e2) {
384
+ return this.$g(e2, t2[0], t2[1]);
385
+ };
386
+ }),
387
+ (w.extend = function (t2, e2) {
388
+ return t2.$i || (t2(e2, _, w), (t2.$i = true)), w;
389
+ }),
390
+ (w.locale = S),
391
+ (w.isDayjs = p),
392
+ (w.unix = function (t2) {
393
+ return w(1e3 * t2);
394
+ }),
395
+ (w.en = D[g]),
396
+ (w.Ls = D),
397
+ (w.p = {}),
398
+ w
399
+ );
400
+ });
401
+ }
402
+ });
403
+ export default require_dayjs_min();
404
+ //# sourceMappingURL=dayjs.js.map
@@ -4,121 +4,117 @@
4
4
  */
5
5
  import { queryParams, deepMerge, page } from '../function/index';
6
6
  class Router {
7
- constructor() {
8
- // 原始属性定义
9
- this.config = {
10
- type: 'navigateTo',
11
- url: '',
12
- delta: 1, // navigateBack页面后退时,回退的层数
13
- params: {}, // 传递的参数
14
- animationType: 'pop-in', // 窗口动画,只在APP有效
15
- animationDuration: 300, // 窗口动画持续时间,单位毫秒,只在APP有效
16
- intercept: false // 是否需要拦截
17
- }
18
- // 因为route方法是需要对外赋值给另外的对象使用,同时route内部有使用this,会导致route失去上下文
19
- // 这里在构造函数中进行this绑定
20
- this.route = this.route.bind(this)
21
- }
7
+ constructor() {
8
+ // 原始属性定义
9
+ this.config = {
10
+ type: 'navigateTo',
11
+ url: '',
12
+ delta: 1, // navigateBack页面后退时,回退的层数
13
+ params: {}, // 传递的参数
14
+ animationType: 'pop-in', // 窗口动画,只在APP有效
15
+ animationDuration: 300, // 窗口动画持续时间,单位毫秒,只在APP有效
16
+ intercept: false // 是否需要拦截
17
+ };
18
+ // 因为route方法是需要对外赋值给另外的对象使用,同时route内部有使用this,会导致route失去上下文
19
+ // 这里在构造函数中进行this绑定
20
+ this.route = this.route.bind(this);
21
+ }
22
22
 
23
- // 判断url前面是否有"/",如果没有则加上,否则无法跳转
24
- addRootPath(url) {
25
- return url[0] === '/' ? url : `/${url}`
26
- }
23
+ // 判断url前面是否有"/",如果没有则加上,否则无法跳转
24
+ addRootPath(url) {
25
+ return url[0] === '/' ? url : `/${url}`;
26
+ }
27
27
 
28
- // 整合路由参数
29
- mixinParam(url, params) {
30
- url = url && this.addRootPath(url)
28
+ // 整合路由参数
29
+ mixinParam(url, params) {
30
+ url = url && this.addRootPath(url);
31
31
 
32
- // 使用正则匹配,主要依据是判断是否有"/","?","="等,如“/page/index/index?name=mary"
33
- // 如果有url中有get参数,转换后无需带上"?"
34
- let query = ''
35
- if (/.*\/.*\?.*=.*/.test(url)) {
36
- // object对象转为get类型的参数
37
- query = queryParams(params, false)
38
- // 因为已有get参数,所以后面拼接的参数需要带上"&"隔开
39
- return url += `&${query}`
40
- }
41
- // 直接拼接参数,因为此处url中没有后面的query参数,也就没有"?/&"之类的符号
42
- query = queryParams(params)
43
- return url += query
32
+ // 使用正则匹配,主要依据是判断是否有"/","?","="等,如“/page/index/index?name=mary"
33
+ // 如果有url中有get参数,转换后无需带上"?"
34
+ let query = '';
35
+ if (/.*\/.*\?.*=.*/.test(url)) {
36
+ // object对象转为get类型的参数
37
+ query = queryParams(params, false);
38
+ // 因为已有get参数,所以后面拼接的参数需要带上"&"隔开
39
+ return (url += `&${query}`);
44
40
  }
41
+ // 直接拼接参数,因为此处url中没有后面的query参数,也就没有"?/&"之类的符号
42
+ query = queryParams(params);
43
+ return (url += query);
44
+ }
45
45
 
46
- // 对外的方法名称
47
- async route(options = {}, params = {}) {
48
- // 合并用户的配置和内部的默认配置
49
- let mergeConfig = {}
46
+ // 对外的方法名称
47
+ async route(options = {}, params = {}) {
48
+ // 合并用户的配置和内部的默认配置
49
+ let mergeConfig = {};
50
50
 
51
- if (typeof options === 'string') {
52
- // 如果options为字符串,则为route(url, params)的形式
53
- mergeConfig.url = this.mixinParam(options, params)
54
- mergeConfig.type = 'navigateTo'
55
- } else {
56
- mergeConfig = deepMerge(this.config, options)
57
- // 否则正常使用mergeConfig中的url和params进行拼接
58
- mergeConfig.url = this.mixinParam(options.url, options.params)
59
- }
51
+ if (typeof options === 'string') {
52
+ // 如果options为字符串,则为route(url, params)的形式
53
+ mergeConfig.url = this.mixinParam(options, params);
54
+ mergeConfig.type = 'navigateTo';
55
+ } else {
56
+ mergeConfig = deepMerge(this.config, options);
57
+ // 否则正常使用mergeConfig中的url和params进行拼接
58
+ mergeConfig.url = this.mixinParam(options.url, options.params);
59
+ }
60
60
 
61
- // 如果本次跳转的路径和本页面路径一致,不执行跳转,防止用户快速点击跳转按钮,造成多次跳转同一个页面的问题
62
- if (mergeConfig.url === page()) return
61
+ // 如果本次跳转的路径和本页面路径一致,不执行跳转,防止用户快速点击跳转按钮,造成多次跳转同一个页面的问题
62
+ if (mergeConfig.url === page()) return;
63
63
 
64
- if (params.intercept) {
65
- this.config.intercept = params.intercept
66
- }
67
- // params参数也带给拦截器
68
- mergeConfig.params = params
69
- // 合并内外部参数
70
- mergeConfig = deepMerge(this.config, mergeConfig)
71
- // 判断用户是否定义了拦截器
72
- if (typeof uni.$u.routeIntercept === 'function') {
73
- // 定一个promise,根据用户执行resolve(true)或者resolve(false)来决定是否进行路由跳转
74
- const isNext = await new Promise((resolve, reject) => {
75
- uni.$u.routeIntercept(mergeConfig, resolve)
76
- })
77
- // 如果isNext为true,则执行路由跳转
78
- isNext && this.openPage(mergeConfig)
79
- } else {
80
- this.openPage(mergeConfig)
81
- }
64
+ if (params.intercept) {
65
+ this.config.intercept = params.intercept;
66
+ }
67
+ // params参数也带给拦截器
68
+ mergeConfig.params = params;
69
+ // 合并内外部参数
70
+ mergeConfig = deepMerge(this.config, mergeConfig);
71
+ // 判断用户是否定义了拦截器
72
+ // if (typeof routeIntercept === 'function') {
73
+ if (typeof uni.$u.routeIntercept === 'function') {
74
+ // 定一个promise,根据用户执行resolve(true)或者resolve(false)来决定是否进行路由跳转
75
+ const isNext = await new Promise((resolve, reject) => {
76
+ // routeIntercept(mergeConfig, resolve);
77
+ uni.$u.routeIntercept(mergeConfig, resolve);
78
+ });
79
+ // 如果isNext为true,则执行路由跳转
80
+ isNext && this.openPage(mergeConfig);
81
+ } else {
82
+ this.openPage(mergeConfig);
82
83
  }
84
+ }
83
85
 
84
- // 执行路由跳转
85
- openPage(config) {
86
- // 解构参数
87
- const {
88
- url,
89
- type,
90
- delta,
91
- animationType,
92
- animationDuration
93
- } = config
94
- if (config.type == 'navigateTo' || config.type == 'to') {
95
- uni.navigateTo({
96
- url,
97
- animationType,
98
- animationDuration
99
- })
100
- }
101
- if (config.type == 'redirectTo' || config.type == 'redirect') {
102
- uni.redirectTo({
103
- url
104
- })
105
- }
106
- if (config.type == 'switchTab' || config.type == 'tab') {
107
- uni.switchTab({
108
- url
109
- })
110
- }
111
- if (config.type == 'reLaunch' || config.type == 'launch') {
112
- uni.reLaunch({
113
- url
114
- })
115
- }
116
- if (config.type == 'navigateBack' || config.type == 'back') {
117
- uni.navigateBack({
118
- delta
119
- })
120
- }
86
+ // 执行路由跳转
87
+ openPage(config) {
88
+ // 解构参数
89
+ const { url, type, delta, animationType, animationDuration } = config;
90
+ if (config.type == 'navigateTo' || config.type == 'to') {
91
+ uni.navigateTo({
92
+ url,
93
+ animationType,
94
+ animationDuration
95
+ });
96
+ }
97
+ if (config.type == 'redirectTo' || config.type == 'redirect') {
98
+ uni.redirectTo({
99
+ url
100
+ });
101
+ }
102
+ if (config.type == 'switchTab' || config.type == 'tab') {
103
+ uni.switchTab({
104
+ url
105
+ });
106
+ }
107
+ if (config.type == 'reLaunch' || config.type == 'launch') {
108
+ uni.reLaunch({
109
+ url
110
+ });
111
+ }
112
+ if (config.type == 'navigateBack' || config.type == 'back') {
113
+ uni.navigateBack({
114
+ delta
115
+ });
121
116
  }
117
+ }
122
118
  }
123
119
 
124
- export default (new Router()).route
120
+ export default new Router().route;